1#! /bin/sh 2 3# Guess values for system-dependent variables and create Makefiles. 4# Generated automatically using autoconf version 2.13 5# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc. 6# 7# This configure script is free software; the Free Software Foundation 8# gives unlimited permission to copy, distribute and modify it. 9 10# Defaults: 11ac_help= 12ac_default_prefix=/usr/local 13# Any additions from configure.in: 14 15# Initialize some variables set by options. 16# The variables have the same names as the options, with 17# dashes changed to underlines. 18build=NONE 19cache_file=./config.cache 20exec_prefix=NONE 21host=NONE 22no_create= 23nonopt=NONE 24no_recursion= 25prefix=NONE 26program_prefix=NONE 27program_suffix=NONE 28program_transform_name=s,x,x, 29silent= 30site= 31srcdir= 32target=NONE 33verbose= 34x_includes=NONE 35x_libraries=NONE 36bindir='${exec_prefix}/bin' 37sbindir='${exec_prefix}/sbin' 38libexecdir='${exec_prefix}/libexec' 39datadir='${prefix}/share' 40sysconfdir='${prefix}/etc' 41sharedstatedir='${prefix}/com' 42localstatedir='${prefix}/var' 43libdir='${exec_prefix}/lib' 44includedir='${prefix}/include' 45oldincludedir='/usr/include' 46infodir='${prefix}/info' 47mandir='${prefix}/man' 48 49# Initialize some other variables. 50subdirs= 51MFLAGS= MAKEFLAGS= 52SHELL=${CONFIG_SHELL-/bin/sh} 53# Maximum number of lines to put in a shell here document. 54ac_max_here_lines=12 55 56ac_prev= 57for ac_option 58do 59 60 # If the previous option needs an argument, assign it. 61 if test -n "$ac_prev"; then 62 eval "$ac_prev=\$ac_option" 63 ac_prev= 64 continue 65 fi 66 67 case "$ac_option" in 68 -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;; 69 *) ac_optarg= ;; 70 esac 71 72 # Accept the important Cygnus configure options, so we can diagnose typos. 73 74 case "$ac_option" in 75 76 -bindir | --bindir | --bindi | --bind | --bin | --bi) 77 ac_prev=bindir ;; 78 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) 79 bindir="$ac_optarg" ;; 80 81 -build | --build | --buil | --bui | --bu) 82 ac_prev=build ;; 83 -build=* | --build=* | --buil=* | --bui=* | --bu=*) 84 build="$ac_optarg" ;; 85 86 -cache-file | --cache-file | --cache-fil | --cache-fi \ 87 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) 88 ac_prev=cache_file ;; 89 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ 90 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) 91 cache_file="$ac_optarg" ;; 92 93 -datadir | --datadir | --datadi | --datad | --data | --dat | --da) 94 ac_prev=datadir ;; 95 -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \ 96 | --da=*) 97 datadir="$ac_optarg" ;; 98 99 -disable-* | --disable-*) 100 ac_feature=`echo $ac_option|sed -e 's/-*disable-//'` 101 # Reject names that are not valid shell variable names. 102 if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then 103 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } 104 fi 105 ac_feature=`echo $ac_feature| sed 's/-/_/g'` 106 eval "enable_${ac_feature}=no" ;; 107 108 -enable-* | --enable-*) 109 ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'` 110 # Reject names that are not valid shell variable names. 111 if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then 112 { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; } 113 fi 114 ac_feature=`echo $ac_feature| sed 's/-/_/g'` 115 case "$ac_option" in 116 *=*) ;; 117 *) ac_optarg=yes ;; 118 esac 119 eval "enable_${ac_feature}='$ac_optarg'" ;; 120 121 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ 122 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ 123 | --exec | --exe | --ex) 124 ac_prev=exec_prefix ;; 125 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ 126 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ 127 | --exec=* | --exe=* | --ex=*) 128 exec_prefix="$ac_optarg" ;; 129 130 -gas | --gas | --ga | --g) 131 # Obsolete; use --with-gas. 132 with_gas=yes ;; 133 134 -help | --help | --hel | --he) 135 # Omit some internal or obsolete options to make the list less imposing. 136 # This message is too long to be a string in the A/UX 3.1 sh. 137 cat << EOF 138Usage: configure [options] [host] 139Options: [defaults in brackets after descriptions] 140Configuration: 141 --cache-file=FILE cache test results in FILE 142 --help print this message 143 --no-create do not create output files 144 --quiet, --silent do not print \`checking...' messages 145 --version print the version of autoconf that created configure 146Directory and file names: 147 --prefix=PREFIX install architecture-independent files in PREFIX 148 [$ac_default_prefix] 149 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX 150 [same as prefix] 151 --bindir=DIR user executables in DIR [EPREFIX/bin] 152 --sbindir=DIR system admin executables in DIR [EPREFIX/sbin] 153 --libexecdir=DIR program executables in DIR [EPREFIX/libexec] 154 --datadir=DIR read-only architecture-independent data in DIR 155 [PREFIX/share] 156 --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc] 157 --sharedstatedir=DIR modifiable architecture-independent data in DIR 158 [PREFIX/com] 159 --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var] 160 --libdir=DIR object code libraries in DIR [EPREFIX/lib] 161 --includedir=DIR C header files in DIR [PREFIX/include] 162 --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include] 163 --infodir=DIR info documentation in DIR [PREFIX/info] 164 --mandir=DIR man documentation in DIR [PREFIX/man] 165 --srcdir=DIR find the sources in DIR [configure dir or ..] 166 --program-prefix=PREFIX prepend PREFIX to installed program names 167 --program-suffix=SUFFIX append SUFFIX to installed program names 168 --program-transform-name=PROGRAM 169 run sed PROGRAM on installed program names 170EOF 171 cat << EOF 172Host type: 173 --build=BUILD configure for building on BUILD [BUILD=HOST] 174 --host=HOST configure for HOST [guessed] 175 --target=TARGET configure for TARGET [TARGET=HOST] 176Features and packages: 177 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) 178 --enable-FEATURE[=ARG] include FEATURE [ARG=yes] 179 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] 180 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) 181 --x-includes=DIR X include files are in DIR 182 --x-libraries=DIR X library files are in DIR 183EOF 184 if test -n "$ac_help"; then 185 echo "--enable and --with options recognized:$ac_help" 186 fi 187 exit 0 ;; 188 189 -host | --host | --hos | --ho) 190 ac_prev=host ;; 191 -host=* | --host=* | --hos=* | --ho=*) 192 host="$ac_optarg" ;; 193 194 -includedir | --includedir | --includedi | --included | --include \ 195 | --includ | --inclu | --incl | --inc) 196 ac_prev=includedir ;; 197 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ 198 | --includ=* | --inclu=* | --incl=* | --inc=*) 199 includedir="$ac_optarg" ;; 200 201 -infodir | --infodir | --infodi | --infod | --info | --inf) 202 ac_prev=infodir ;; 203 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) 204 infodir="$ac_optarg" ;; 205 206 -libdir | --libdir | --libdi | --libd) 207 ac_prev=libdir ;; 208 -libdir=* | --libdir=* | --libdi=* | --libd=*) 209 libdir="$ac_optarg" ;; 210 211 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ 212 | --libexe | --libex | --libe) 213 ac_prev=libexecdir ;; 214 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ 215 | --libexe=* | --libex=* | --libe=*) 216 libexecdir="$ac_optarg" ;; 217 218 -localstatedir | --localstatedir | --localstatedi | --localstated \ 219 | --localstate | --localstat | --localsta | --localst \ 220 | --locals | --local | --loca | --loc | --lo) 221 ac_prev=localstatedir ;; 222 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ 223 | --localstate=* | --localstat=* | --localsta=* | --localst=* \ 224 | --locals=* | --local=* | --loca=* | --loc=* | --lo=*) 225 localstatedir="$ac_optarg" ;; 226 227 -mandir | --mandir | --mandi | --mand | --man | --ma | --m) 228 ac_prev=mandir ;; 229 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) 230 mandir="$ac_optarg" ;; 231 232 -nfp | --nfp | --nf) 233 # Obsolete; use --without-fp. 234 with_fp=no ;; 235 236 -no-create | --no-create | --no-creat | --no-crea | --no-cre \ 237 | --no-cr | --no-c) 238 no_create=yes ;; 239 240 -no-recursion | --no-recursion | --no-recursio | --no-recursi \ 241 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) 242 no_recursion=yes ;; 243 244 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ 245 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ 246 | --oldin | --oldi | --old | --ol | --o) 247 ac_prev=oldincludedir ;; 248 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ 249 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ 250 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) 251 oldincludedir="$ac_optarg" ;; 252 253 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) 254 ac_prev=prefix ;; 255 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) 256 prefix="$ac_optarg" ;; 257 258 -program-prefix | --program-prefix | --program-prefi | --program-pref \ 259 | --program-pre | --program-pr | --program-p) 260 ac_prev=program_prefix ;; 261 -program-prefix=* | --program-prefix=* | --program-prefi=* \ 262 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) 263 program_prefix="$ac_optarg" ;; 264 265 -program-suffix | --program-suffix | --program-suffi | --program-suff \ 266 | --program-suf | --program-su | --program-s) 267 ac_prev=program_suffix ;; 268 -program-suffix=* | --program-suffix=* | --program-suffi=* \ 269 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) 270 program_suffix="$ac_optarg" ;; 271 272 -program-transform-name | --program-transform-name \ 273 | --program-transform-nam | --program-transform-na \ 274 | --program-transform-n | --program-transform- \ 275 | --program-transform | --program-transfor \ 276 | --program-transfo | --program-transf \ 277 | --program-trans | --program-tran \ 278 | --progr-tra | --program-tr | --program-t) 279 ac_prev=program_transform_name ;; 280 -program-transform-name=* | --program-transform-name=* \ 281 | --program-transform-nam=* | --program-transform-na=* \ 282 | --program-transform-n=* | --program-transform-=* \ 283 | --program-transform=* | --program-transfor=* \ 284 | --program-transfo=* | --program-transf=* \ 285 | --program-trans=* | --program-tran=* \ 286 | --progr-tra=* | --program-tr=* | --program-t=*) 287 program_transform_name="$ac_optarg" ;; 288 289 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 290 | -silent | --silent | --silen | --sile | --sil) 291 silent=yes ;; 292 293 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) 294 ac_prev=sbindir ;; 295 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ 296 | --sbi=* | --sb=*) 297 sbindir="$ac_optarg" ;; 298 299 -sharedstatedir | --sharedstatedir | --sharedstatedi \ 300 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ 301 | --sharedst | --shareds | --shared | --share | --shar \ 302 | --sha | --sh) 303 ac_prev=sharedstatedir ;; 304 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ 305 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ 306 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ 307 | --sha=* | --sh=*) 308 sharedstatedir="$ac_optarg" ;; 309 310 -site | --site | --sit) 311 ac_prev=site ;; 312 -site=* | --site=* | --sit=*) 313 site="$ac_optarg" ;; 314 315 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) 316 ac_prev=srcdir ;; 317 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) 318 srcdir="$ac_optarg" ;; 319 320 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ 321 | --syscon | --sysco | --sysc | --sys | --sy) 322 ac_prev=sysconfdir ;; 323 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ 324 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) 325 sysconfdir="$ac_optarg" ;; 326 327 -target | --target | --targe | --targ | --tar | --ta | --t) 328 ac_prev=target ;; 329 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) 330 target="$ac_optarg" ;; 331 332 -v | -verbose | --verbose | --verbos | --verbo | --verb) 333 verbose=yes ;; 334 335 -version | --version | --versio | --versi | --vers) 336 echo "configure generated by autoconf version 2.13" 337 exit 0 ;; 338 339 -with-* | --with-*) 340 ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'` 341 # Reject names that are not valid shell variable names. 342 if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then 343 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } 344 fi 345 ac_package=`echo $ac_package| sed 's/-/_/g'` 346 case "$ac_option" in 347 *=*) ;; 348 *) ac_optarg=yes ;; 349 esac 350 eval "with_${ac_package}='$ac_optarg'" ;; 351 352 -without-* | --without-*) 353 ac_package=`echo $ac_option|sed -e 's/-*without-//'` 354 # Reject names that are not valid shell variable names. 355 if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then 356 { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; } 357 fi 358 ac_package=`echo $ac_package| sed 's/-/_/g'` 359 eval "with_${ac_package}=no" ;; 360 361 --x) 362 # Obsolete; use --with-x. 363 with_x=yes ;; 364 365 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ 366 | --x-incl | --x-inc | --x-in | --x-i) 367 ac_prev=x_includes ;; 368 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ 369 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) 370 x_includes="$ac_optarg" ;; 371 372 -x-libraries | --x-libraries | --x-librarie | --x-librari \ 373 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) 374 ac_prev=x_libraries ;; 375 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ 376 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) 377 x_libraries="$ac_optarg" ;; 378 379 -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; } 380 ;; 381 382 *) 383 if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then 384 echo "configure: warning: $ac_option: invalid host type" 1>&2 385 fi 386 if test "x$nonopt" != xNONE; then 387 { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } 388 fi 389 nonopt="$ac_option" 390 ;; 391 392 esac 393done 394 395if test -n "$ac_prev"; then 396 { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; } 397fi 398 399trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 400 401# File descriptor usage: 402# 0 standard input 403# 1 file creation 404# 2 errors and warnings 405# 3 some systems may open it to /dev/tty 406# 4 used on the Kubota Titan 407# 6 checking for... messages and results 408# 5 compiler messages saved in config.log 409if test "$silent" = yes; then 410 exec 6>/dev/null 411else 412 exec 6>&1 413fi 414exec 5>./config.log 415 416echo "\ 417This file contains any messages produced by compilers while 418running configure, to aid debugging if configure makes a mistake. 419" 1>&5 420 421# Strip out --no-create and --no-recursion so they do not pile up. 422# Also quote any args containing shell metacharacters. 423ac_configure_args= 424for ac_arg 425do 426 case "$ac_arg" in 427 -no-create | --no-create | --no-creat | --no-crea | --no-cre \ 428 | --no-cr | --no-c) ;; 429 -no-recursion | --no-recursion | --no-recursio | --no-recursi \ 430 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;; 431 *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*) 432 ac_configure_args="$ac_configure_args '$ac_arg'" ;; 433 *) ac_configure_args="$ac_configure_args $ac_arg" ;; 434 esac 435done 436 437# NLS nuisances. 438# Only set these to C if already set. These must not be set unconditionally 439# because not all systems understand e.g. LANG=C (notably SCO). 440# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'! 441# Non-C LC_CTYPE values break the ctype check. 442if test "${LANG+set}" = set; then LANG=C; export LANG; fi 443if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi 444if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi 445if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi 446 447# confdefs.h avoids OS command line length limits that DEFS can exceed. 448rm -rf conftest* confdefs.h 449# AIX cpp loses on an empty file, so make sure it contains at least a newline. 450echo > confdefs.h 451 452# A filename unique to this package, relative to the directory that 453# configure is in, which we can look for to find out if srcdir is correct. 454ac_unique_file=thttpd.c 455 456# Find the source files, if location was not specified. 457if test -z "$srcdir"; then 458 ac_srcdir_defaulted=yes 459 # Try the directory containing this script, then its parent. 460 ac_prog=$0 461 ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'` 462 test "x$ac_confdir" = "x$ac_prog" && ac_confdir=. 463 srcdir=$ac_confdir 464 if test ! -r $srcdir/$ac_unique_file; then 465 srcdir=.. 466 fi 467else 468 ac_srcdir_defaulted=no 469fi 470if test ! -r $srcdir/$ac_unique_file; then 471 if test "$ac_srcdir_defaulted" = yes; then 472 { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; } 473 else 474 { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; } 475 fi 476fi 477srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'` 478 479# Prefer explicitly selected file to automatically selected ones. 480if test -z "$CONFIG_SITE"; then 481 if test "x$prefix" != xNONE; then 482 CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site" 483 else 484 CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site" 485 fi 486fi 487for ac_site_file in $CONFIG_SITE; do 488 if test -r "$ac_site_file"; then 489 echo "loading site script $ac_site_file" 490 . "$ac_site_file" 491 fi 492done 493 494if test -r "$cache_file"; then 495 echo "loading cache $cache_file" 496 . $cache_file 497else 498 echo "creating cache $cache_file" 499 > $cache_file 500fi 501 502ac_ext=c 503# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. 504ac_cpp='$CPP $CPPFLAGS' 505ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' 506ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' 507cross_compiling=$ac_cv_prog_cc_cross 508 509ac_exeext= 510ac_objext=o 511if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then 512 # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu. 513 if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then 514 ac_n= ac_c=' 515' ac_t=' ' 516 else 517 ac_n=-n ac_c= ac_t= 518 fi 519else 520 ac_n= ac_c='\c' ac_t= 521fi 522 523 524 525ac_aux_dir= 526for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do 527 if test -f $ac_dir/install-sh; then 528 ac_aux_dir=$ac_dir 529 ac_install_sh="$ac_aux_dir/install-sh -c" 530 break 531 elif test -f $ac_dir/install.sh; then 532 ac_aux_dir=$ac_dir 533 ac_install_sh="$ac_aux_dir/install.sh -c" 534 break 535 fi 536done 537if test -z "$ac_aux_dir"; then 538 { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; } 539fi 540ac_config_guess=$ac_aux_dir/config.guess 541ac_config_sub=$ac_aux_dir/config.sub 542ac_configure=$ac_aux_dir/configure # This should be Cygnus configure. 543 544 545# Do some error checking and defaulting for the host and target type. 546# The inputs are: 547# configure --host=HOST --target=TARGET --build=BUILD NONOPT 548# 549# The rules are: 550# 1. You are not allowed to specify --host, --target, and nonopt at the 551# same time. 552# 2. Host defaults to nonopt. 553# 3. If nonopt is not specified, then host defaults to the current host, 554# as determined by config.guess. 555# 4. Target and build default to nonopt. 556# 5. If nonopt is not specified, then target and build default to host. 557 558# The aliases save the names the user supplied, while $host etc. 559# will get canonicalized. 560case $host---$target---$nonopt in 561NONE---*---* | *---NONE---* | *---*---NONE) ;; 562*) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;; 563esac 564 565 566# Make sure we can run config.sub. 567if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then : 568else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; } 569fi 570 571echo $ac_n "checking host system type""... $ac_c" 1>&6 572echo "configure:573: checking host system type" >&5 573 574host_alias=$host 575case "$host_alias" in 576NONE) 577 case $nonopt in 578 NONE) 579 if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then : 580 else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; } 581 fi ;; 582 *) host_alias=$nonopt ;; 583 esac ;; 584esac 585 586host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias` 587host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` 588host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` 589host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` 590echo "$ac_t""$host" 1>&6 591 592echo $ac_n "checking target system type""... $ac_c" 1>&6 593echo "configure:594: checking target system type" >&5 594 595target_alias=$target 596case "$target_alias" in 597NONE) 598 case $nonopt in 599 NONE) target_alias=$host_alias ;; 600 *) target_alias=$nonopt ;; 601 esac ;; 602esac 603 604target=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $target_alias` 605target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` 606target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` 607target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` 608echo "$ac_t""$target" 1>&6 609 610echo $ac_n "checking build system type""... $ac_c" 1>&6 611echo "configure:612: checking build system type" >&5 612 613build_alias=$build 614case "$build_alias" in 615NONE) 616 case $nonopt in 617 NONE) build_alias=$host_alias ;; 618 *) build_alias=$nonopt ;; 619 esac ;; 620esac 621 622build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias` 623build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'` 624build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'` 625build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'` 626echo "$ac_t""$build" 1>&6 627 628test "$host_alias" != "$target_alias" && 629 test "$program_prefix$program_suffix$program_transform_name" = \ 630 NONENONEs,x,x, && 631 program_prefix=${target_alias}- 632 633 634# Extract the first word of "gcc", so it can be a program name with args. 635set dummy gcc; ac_word=$2 636echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 637echo "configure:638: checking for $ac_word" >&5 638if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then 639 echo $ac_n "(cached) $ac_c" 1>&6 640else 641 if test -n "$CC"; then 642 ac_cv_prog_CC="$CC" # Let the user override the test. 643else 644 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" 645 ac_dummy="$PATH" 646 for ac_dir in $ac_dummy; do 647 test -z "$ac_dir" && ac_dir=. 648 if test -f $ac_dir/$ac_word; then 649 ac_cv_prog_CC="gcc" 650 break 651 fi 652 done 653 IFS="$ac_save_ifs" 654fi 655fi 656CC="$ac_cv_prog_CC" 657if test -n "$CC"; then 658 echo "$ac_t""$CC" 1>&6 659else 660 echo "$ac_t""no" 1>&6 661fi 662 663if test -z "$CC"; then 664 # Extract the first word of "cc", so it can be a program name with args. 665set dummy cc; ac_word=$2 666echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 667echo "configure:668: checking for $ac_word" >&5 668if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then 669 echo $ac_n "(cached) $ac_c" 1>&6 670else 671 if test -n "$CC"; then 672 ac_cv_prog_CC="$CC" # Let the user override the test. 673else 674 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" 675 ac_prog_rejected=no 676 ac_dummy="$PATH" 677 for ac_dir in $ac_dummy; do 678 test -z "$ac_dir" && ac_dir=. 679 if test -f $ac_dir/$ac_word; then 680 if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then 681 ac_prog_rejected=yes 682 continue 683 fi 684 ac_cv_prog_CC="cc" 685 break 686 fi 687 done 688 IFS="$ac_save_ifs" 689if test $ac_prog_rejected = yes; then 690 # We found a bogon in the path, so make sure we never use it. 691 set dummy $ac_cv_prog_CC 692 shift 693 if test $# -gt 0; then 694 # We chose a different compiler from the bogus one. 695 # However, it has the same basename, so the bogon will be chosen 696 # first if we set CC to just the basename; use the full file name. 697 shift 698 set dummy "$ac_dir/$ac_word" "$@" 699 shift 700 ac_cv_prog_CC="$@" 701 fi 702fi 703fi 704fi 705CC="$ac_cv_prog_CC" 706if test -n "$CC"; then 707 echo "$ac_t""$CC" 1>&6 708else 709 echo "$ac_t""no" 1>&6 710fi 711 712 if test -z "$CC"; then 713 case "`uname -s`" in 714 *win32* | *WIN32*) 715 # Extract the first word of "cl", so it can be a program name with args. 716set dummy cl; ac_word=$2 717echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 718echo "configure:719: checking for $ac_word" >&5 719if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then 720 echo $ac_n "(cached) $ac_c" 1>&6 721else 722 if test -n "$CC"; then 723 ac_cv_prog_CC="$CC" # Let the user override the test. 724else 725 IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":" 726 ac_dummy="$PATH" 727 for ac_dir in $ac_dummy; do 728 test -z "$ac_dir" && ac_dir=. 729 if test -f $ac_dir/$ac_word; then 730 ac_cv_prog_CC="cl" 731 break 732 fi 733 done 734 IFS="$ac_save_ifs" 735fi 736fi 737CC="$ac_cv_prog_CC" 738if test -n "$CC"; then 739 echo "$ac_t""$CC" 1>&6 740else 741 echo "$ac_t""no" 1>&6 742fi 743 ;; 744 esac 745 fi 746 test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; } 747fi 748 749echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6 750echo "configure:751: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5 751 752ac_ext=c 753# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. 754ac_cpp='$CPP $CPPFLAGS' 755ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' 756ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' 757cross_compiling=$ac_cv_prog_cc_cross 758 759cat > conftest.$ac_ext << EOF 760 761#line 762 "configure" 762#include "confdefs.h" 763 764main(){return(0);} 765EOF 766if { (eval echo configure:767: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 767 ac_cv_prog_cc_works=yes 768 # If we can't run a trivial program, we are probably using a cross compiler. 769 if (./conftest; exit) 2>/dev/null; then 770 ac_cv_prog_cc_cross=no 771 else 772 ac_cv_prog_cc_cross=yes 773 fi 774else 775 echo "configure: failed program was:" >&5 776 cat conftest.$ac_ext >&5 777 ac_cv_prog_cc_works=no 778fi 779rm -fr conftest* 780ac_ext=c 781# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options. 782ac_cpp='$CPP $CPPFLAGS' 783ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5' 784ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5' 785cross_compiling=$ac_cv_prog_cc_cross 786 787echo "$ac_t""$ac_cv_prog_cc_works" 1>&6 788if test $ac_cv_prog_cc_works = no; then 789 { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; } 790fi 791echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6 792echo "configure:793: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5 793echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6 794cross_compiling=$ac_cv_prog_cc_cross 795 796echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6 797echo "configure:798: checking whether we are using GNU C" >&5 798if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then 799 echo $ac_n "(cached) $ac_c" 1>&6 800else 801 cat > conftest.c <<EOF 802#ifdef __GNUC__ 803 yes; 804#endif 805EOF 806if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:807: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then 807 ac_cv_prog_gcc=yes 808else 809 ac_cv_prog_gcc=no 810fi 811fi 812 813echo "$ac_t""$ac_cv_prog_gcc" 1>&6 814 815if test $ac_cv_prog_gcc = yes; then 816 GCC=yes 817else 818 GCC= 819fi 820 821ac_test_CFLAGS="${CFLAGS+set}" 822ac_save_CFLAGS="$CFLAGS" 823CFLAGS= 824echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6 825echo "configure:826: checking whether ${CC-cc} accepts -g" >&5 826if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then 827 echo $ac_n "(cached) $ac_c" 1>&6 828else 829 echo 'void f(){}' > conftest.c 830if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then 831 ac_cv_prog_cc_g=yes 832else 833 ac_cv_prog_cc_g=no 834fi 835rm -f conftest* 836 837fi 838 839echo "$ac_t""$ac_cv_prog_cc_g" 1>&6 840if test "$ac_test_CFLAGS" = set; then 841 CFLAGS="$ac_save_CFLAGS" 842elif test $ac_cv_prog_cc_g = yes; then 843 if test "$GCC" = yes; then 844 CFLAGS="-g -O2" 845 else 846 CFLAGS="-g" 847 fi 848else 849 if test "$GCC" = yes; then 850 CFLAGS="-O2" 851 else 852 CFLAGS= 853 fi 854fi 855 856 857V_CCOPT="-O" 858if test "$GCC" = yes ; then 859 echo $ac_n "checking gcc version""... $ac_c" 1>&6 860echo "configure:861: checking gcc version" >&5 861 if eval "test \"`echo '$''{'ac_cv_lbl_gcc_vers'+set}'`\" = set"; then 862 echo $ac_n "(cached) $ac_c" 1>&6 863else 864 ac_cv_lbl_gcc_vers=`$CC -dumpversion 2>&1 | \ 865 sed -e 's/\..*//'` 866fi 867 868 echo "$ac_t""$ac_cv_lbl_gcc_vers" 1>&6 869 if test "$ac_cv_lbl_gcc_vers" -gt 1 ; then 870 V_CCOPT="-O2" 871 fi 872fi 873if test -f .devel ; then 874 V_CCOPT="-g $V_CCOPT -ansi -pedantic -U__STRICT_ANSI__ -Wall -Wpointer-arith -Wshadow -Wcast-qual -Wcast-align -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wredundant-decls -Wno-long-long" 875fi 876 877echo $ac_n "checking how to link static binaries""... $ac_c" 1>&6 878echo "configure:879: checking how to link static binaries" >&5 879if eval "test \"`echo '$''{'ac_cv_lbl_static_flag'+set}'`\" = set"; then 880 echo $ac_n "(cached) $ac_c" 1>&6 881else 882 ac_cv_lbl_static_flag=unknown 883 echo 'main() {}' > conftest.c 884 if test "$GCC" != yes ; then 885 trial_flag="-Bstatic" 886 test=`$CC $trial_flag -o conftest conftest.c 2>&1` 887 if test -z "$test" ; then 888 ac_cv_lbl_static_flag="$trial_flag" 889 fi 890 rm -f conftest 891 fi 892 if test "$ac_cv_lbl_static_flag" = unknown ; then 893 trial_flag="-static" 894 test=`$CC $trial_flag -o conftest conftest.c 2>&1` 895 if test -z "$test" ; then 896 ac_cv_lbl_static_flag="$trial_flag" 897 fi 898 rm -f conftest 899 fi 900 rm conftest.c 901fi 902 903echo "$ac_t""$ac_cv_lbl_static_flag" 1>&6 904if test "$ac_cv_lbl_static_flag" != unknown ; then 905 V_STATICFLAG="$ac_cv_lbl_static_flag" 906fi 907 908echo $ac_n "checking for __progname""... $ac_c" 1>&6 909echo "configure:910: checking for __progname" >&5 910if eval "test \"`echo '$''{'ac_cv_extern__progname'+set}'`\" = set"; then 911 echo $ac_n "(cached) $ac_c" 1>&6 912else 913 cat > conftest.$ac_ext <<EOF 914#line 915 "configure" 915#include "confdefs.h" 916 917int main() { 918extern char *__progname; 919 puts(__progname) 920; return 0; } 921EOF 922if { (eval echo configure:923: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 923 rm -rf conftest* 924 ac_cv_extern__progname=yes 925else 926 echo "configure: failed program was:" >&5 927 cat conftest.$ac_ext >&5 928 rm -rf conftest* 929 ac_cv_extern__progname=no 930fi 931rm -f conftest* 932fi 933 934if test $ac_cv_extern__progname = yes ; then 935 cat >> confdefs.h <<\EOF 936#define HAVE__PROGNAME 1 937EOF 938 939 echo "$ac_t""yes" 1>&6 940else 941 echo "$ac_t""no" 1>&6 942fi 943 944echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6 945echo "configure:946: checking how to run the C preprocessor" >&5 946# On Suns, sometimes $CPP names a directory. 947if test -n "$CPP" && test -d "$CPP"; then 948 CPP= 949fi 950if test -z "$CPP"; then 951if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then 952 echo $ac_n "(cached) $ac_c" 1>&6 953else 954 # This must be in double quotes, not single quotes, because CPP may get 955 # substituted into the Makefile and "${CC-cc}" will confuse make. 956 CPP="${CC-cc} -E" 957 # On the NeXT, cc -E runs the code through the compiler's parser, 958 # not just through cpp. 959 cat > conftest.$ac_ext <<EOF 960#line 961 "configure" 961#include "confdefs.h" 962#include <assert.h> 963Syntax Error 964EOF 965ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" 966{ (eval echo configure:967: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } 967ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` 968if test -z "$ac_err"; then 969 : 970else 971 echo "$ac_err" >&5 972 echo "configure: failed program was:" >&5 973 cat conftest.$ac_ext >&5 974 rm -rf conftest* 975 CPP="${CC-cc} -E -traditional-cpp" 976 cat > conftest.$ac_ext <<EOF 977#line 978 "configure" 978#include "confdefs.h" 979#include <assert.h> 980Syntax Error 981EOF 982ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" 983{ (eval echo configure:984: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } 984ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` 985if test -z "$ac_err"; then 986 : 987else 988 echo "$ac_err" >&5 989 echo "configure: failed program was:" >&5 990 cat conftest.$ac_ext >&5 991 rm -rf conftest* 992 CPP="${CC-cc} -nologo -E" 993 cat > conftest.$ac_ext <<EOF 994#line 995 "configure" 995#include "confdefs.h" 996#include <assert.h> 997Syntax Error 998EOF 999ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" 1000{ (eval echo configure:1001: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } 1001ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` 1002if test -z "$ac_err"; then 1003 : 1004else 1005 echo "$ac_err" >&5 1006 echo "configure: failed program was:" >&5 1007 cat conftest.$ac_ext >&5 1008 rm -rf conftest* 1009 CPP=/lib/cpp 1010fi 1011rm -f conftest* 1012fi 1013rm -f conftest* 1014fi 1015rm -f conftest* 1016 ac_cv_prog_CPP="$CPP" 1017fi 1018 CPP="$ac_cv_prog_CPP" 1019else 1020 ac_cv_prog_CPP="$CPP" 1021fi 1022echo "$ac_t""$CPP" 1>&6 1023 1024for ac_hdr in fcntl.h grp.h memory.h paths.h poll.h sys/poll.h sys/devpoll.h sys/event.h osreldate.h 1025do 1026ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` 1027echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 1028echo "configure:1029: checking for $ac_hdr" >&5 1029if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then 1030 echo $ac_n "(cached) $ac_c" 1>&6 1031else 1032 cat > conftest.$ac_ext <<EOF 1033#line 1034 "configure" 1034#include "confdefs.h" 1035#include <$ac_hdr> 1036EOF 1037ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" 1038{ (eval echo configure:1039: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } 1039ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` 1040if test -z "$ac_err"; then 1041 rm -rf conftest* 1042 eval "ac_cv_header_$ac_safe=yes" 1043else 1044 echo "$ac_err" >&5 1045 echo "configure: failed program was:" >&5 1046 cat conftest.$ac_ext >&5 1047 rm -rf conftest* 1048 eval "ac_cv_header_$ac_safe=no" 1049fi 1050rm -f conftest* 1051fi 1052if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then 1053 echo "$ac_t""yes" 1>&6 1054 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` 1055 cat >> confdefs.h <<EOF 1056#define $ac_tr_hdr 1 1057EOF 1058 1059else 1060 echo "$ac_t""no" 1>&6 1061fi 1062done 1063 1064echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6 1065echo "configure:1066: checking whether time.h and sys/time.h may both be included" >&5 1066if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then 1067 echo $ac_n "(cached) $ac_c" 1>&6 1068else 1069 cat > conftest.$ac_ext <<EOF 1070#line 1071 "configure" 1071#include "confdefs.h" 1072#include <sys/types.h> 1073#include <sys/time.h> 1074#include <time.h> 1075int main() { 1076struct tm *tp; 1077; return 0; } 1078EOF 1079if { (eval echo configure:1080: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then 1080 rm -rf conftest* 1081 ac_cv_header_time=yes 1082else 1083 echo "configure: failed program was:" >&5 1084 cat conftest.$ac_ext >&5 1085 rm -rf conftest* 1086 ac_cv_header_time=no 1087fi 1088rm -f conftest* 1089fi 1090 1091echo "$ac_t""$ac_cv_header_time" 1>&6 1092if test $ac_cv_header_time = yes; then 1093 cat >> confdefs.h <<\EOF 1094#define TIME_WITH_SYS_TIME 1 1095EOF 1096 1097fi 1098 1099ac_header_dirent=no 1100for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h 1101do 1102ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` 1103echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6 1104echo "configure:1105: checking for $ac_hdr that defines DIR" >&5 1105if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then 1106 echo $ac_n "(cached) $ac_c" 1>&6 1107else 1108 cat > conftest.$ac_ext <<EOF 1109#line 1110 "configure" 1110#include "confdefs.h" 1111#include <sys/types.h> 1112#include <$ac_hdr> 1113int main() { 1114DIR *dirp = 0; 1115; return 0; } 1116EOF 1117if { (eval echo configure:1118: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then 1118 rm -rf conftest* 1119 eval "ac_cv_header_dirent_$ac_safe=yes" 1120else 1121 echo "configure: failed program was:" >&5 1122 cat conftest.$ac_ext >&5 1123 rm -rf conftest* 1124 eval "ac_cv_header_dirent_$ac_safe=no" 1125fi 1126rm -f conftest* 1127fi 1128if eval "test \"`echo '$ac_cv_header_dirent_'$ac_safe`\" = yes"; then 1129 echo "$ac_t""yes" 1>&6 1130 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` 1131 cat >> confdefs.h <<EOF 1132#define $ac_tr_hdr 1 1133EOF 1134 ac_header_dirent=$ac_hdr; break 1135else 1136 echo "$ac_t""no" 1>&6 1137fi 1138done 1139# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. 1140if test $ac_header_dirent = dirent.h; then 1141echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6 1142echo "configure:1143: checking for opendir in -ldir" >&5 1143ac_lib_var=`echo dir'_'opendir | sed 'y%./+-%__p_%'` 1144if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then 1145 echo $ac_n "(cached) $ac_c" 1>&6 1146else 1147 ac_save_LIBS="$LIBS" 1148LIBS="-ldir $LIBS" 1149cat > conftest.$ac_ext <<EOF 1150#line 1151 "configure" 1151#include "confdefs.h" 1152/* Override any gcc2 internal prototype to avoid an error. */ 1153/* We use char because int might match the return type of a gcc2 1154 builtin and then its argument prototype would still apply. */ 1155char opendir(); 1156 1157int main() { 1158opendir() 1159; return 0; } 1160EOF 1161if { (eval echo configure:1162: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 1162 rm -rf conftest* 1163 eval "ac_cv_lib_$ac_lib_var=yes" 1164else 1165 echo "configure: failed program was:" >&5 1166 cat conftest.$ac_ext >&5 1167 rm -rf conftest* 1168 eval "ac_cv_lib_$ac_lib_var=no" 1169fi 1170rm -f conftest* 1171LIBS="$ac_save_LIBS" 1172 1173fi 1174if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then 1175 echo "$ac_t""yes" 1>&6 1176 LIBS="$LIBS -ldir" 1177else 1178 echo "$ac_t""no" 1>&6 1179fi 1180 1181else 1182echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6 1183echo "configure:1184: checking for opendir in -lx" >&5 1184ac_lib_var=`echo x'_'opendir | sed 'y%./+-%__p_%'` 1185if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then 1186 echo $ac_n "(cached) $ac_c" 1>&6 1187else 1188 ac_save_LIBS="$LIBS" 1189LIBS="-lx $LIBS" 1190cat > conftest.$ac_ext <<EOF 1191#line 1192 "configure" 1192#include "confdefs.h" 1193/* Override any gcc2 internal prototype to avoid an error. */ 1194/* We use char because int might match the return type of a gcc2 1195 builtin and then its argument prototype would still apply. */ 1196char opendir(); 1197 1198int main() { 1199opendir() 1200; return 0; } 1201EOF 1202if { (eval echo configure:1203: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 1203 rm -rf conftest* 1204 eval "ac_cv_lib_$ac_lib_var=yes" 1205else 1206 echo "configure: failed program was:" >&5 1207 cat conftest.$ac_ext >&5 1208 rm -rf conftest* 1209 eval "ac_cv_lib_$ac_lib_var=no" 1210fi 1211rm -f conftest* 1212LIBS="$ac_save_LIBS" 1213 1214fi 1215if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then 1216 echo "$ac_t""yes" 1>&6 1217 LIBS="$LIBS -lx" 1218else 1219 echo "$ac_t""no" 1>&6 1220fi 1221 1222fi 1223 1224 1225d="/usr/local/v6/lib" 1226echo $ac_n "checking for $d""... $ac_c" 1>&6 1227echo "configure:1228: checking for $d" >&5 1228if test -d $d; then 1229 echo "$ac_t""yes (Adding -L$d to LDFLAGS)" 1>&6 1230 LDFLAGS="$LDFLAGS -L$d" 1231else 1232 echo "$ac_t""no" 1>&6 1233fi 1234 1235V_NETLIBS="" 1236echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6 1237echo "configure:1238: checking for gethostbyname" >&5 1238if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then 1239 echo $ac_n "(cached) $ac_c" 1>&6 1240else 1241 cat > conftest.$ac_ext <<EOF 1242#line 1243 "configure" 1243#include "confdefs.h" 1244/* System header to define __stub macros and hopefully few prototypes, 1245 which can conflict with char gethostbyname(); below. */ 1246#include <assert.h> 1247/* Override any gcc2 internal prototype to avoid an error. */ 1248/* We use char because int might match the return type of a gcc2 1249 builtin and then its argument prototype would still apply. */ 1250char gethostbyname(); 1251 1252int main() { 1253 1254/* The GNU C library defines this for functions which it implements 1255 to always fail with ENOSYS. Some functions are actually named 1256 something starting with __ and the normal name is an alias. */ 1257#if defined (__stub_gethostbyname) || defined (__stub___gethostbyname) 1258choke me 1259#else 1260gethostbyname(); 1261#endif 1262 1263; return 0; } 1264EOF 1265if { (eval echo configure:1266: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 1266 rm -rf conftest* 1267 eval "ac_cv_func_gethostbyname=yes" 1268else 1269 echo "configure: failed program was:" >&5 1270 cat conftest.$ac_ext >&5 1271 rm -rf conftest* 1272 eval "ac_cv_func_gethostbyname=no" 1273fi 1274rm -f conftest* 1275fi 1276 1277if eval "test \"`echo '$ac_cv_func_'gethostbyname`\" = yes"; then 1278 echo "$ac_t""yes" 1>&6 1279 : 1280else 1281 echo "$ac_t""no" 1>&6 1282# Some OSes (eg. Solaris) place it in libnsl: 1283 echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6 1284echo "configure:1285: checking for gethostbyname in -lnsl" >&5 1285ac_lib_var=`echo nsl'_'gethostbyname'_' | sed 'y%./+- %__p__%'` 1286if eval "test \"`echo '$''{'ac_cv_lbl_lib_$ac_lib_var'+set}'`\" = set"; then 1287 echo $ac_n "(cached) $ac_c" 1>&6 1288else 1289 ac_save_LIBS="$LIBS" 1290LIBS="-lnsl $LIBS" 1291cat > conftest.$ac_ext <<EOF 1292#line 1293 "configure" 1293#include "confdefs.h" 1294/* Override any gcc2 internal prototype to avoid an error. */ 1295/* We use char because int might match the return type of a gcc2 1296 builtin and then its argument prototype would still apply. */ 1297char gethostbyname(); 1298 1299int main() { 1300gethostbyname() 1301; return 0; } 1302EOF 1303if { (eval echo configure:1304: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 1304 rm -rf conftest* 1305 eval "ac_cv_lbl_lib_$ac_lib_var=yes" 1306else 1307 echo "configure: failed program was:" >&5 1308 cat conftest.$ac_ext >&5 1309 rm -rf conftest* 1310 eval "ac_cv_lbl_lib_$ac_lib_var=no" 1311fi 1312rm -f conftest* 1313LIBS="$ac_save_LIBS" 1314 1315fi 1316if eval "test \"`echo '$ac_cv_lbl_lib_'$ac_lib_var`\" = yes"; then 1317 echo "$ac_t""yes" 1>&6 1318 V_NETLIBS="-lnsl $V_NETLIBS" 1319else 1320 echo "$ac_t""no" 1>&6 1321# Some strange OSes (SINIX) have it in libsocket: 1322 echo $ac_n "checking for gethostbyname in -lsocket""... $ac_c" 1>&6 1323echo "configure:1324: checking for gethostbyname in -lsocket" >&5 1324ac_lib_var=`echo socket'_'gethostbyname'_' | sed 'y%./+- %__p__%'` 1325if eval "test \"`echo '$''{'ac_cv_lbl_lib_$ac_lib_var'+set}'`\" = set"; then 1326 echo $ac_n "(cached) $ac_c" 1>&6 1327else 1328 ac_save_LIBS="$LIBS" 1329LIBS="-lsocket $LIBS" 1330cat > conftest.$ac_ext <<EOF 1331#line 1332 "configure" 1332#include "confdefs.h" 1333/* Override any gcc2 internal prototype to avoid an error. */ 1334/* We use char because int might match the return type of a gcc2 1335 builtin and then its argument prototype would still apply. */ 1336char gethostbyname(); 1337 1338int main() { 1339gethostbyname() 1340; return 0; } 1341EOF 1342if { (eval echo configure:1343: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 1343 rm -rf conftest* 1344 eval "ac_cv_lbl_lib_$ac_lib_var=yes" 1345else 1346 echo "configure: failed program was:" >&5 1347 cat conftest.$ac_ext >&5 1348 rm -rf conftest* 1349 eval "ac_cv_lbl_lib_$ac_lib_var=no" 1350fi 1351rm -f conftest* 1352LIBS="$ac_save_LIBS" 1353 1354fi 1355if eval "test \"`echo '$ac_cv_lbl_lib_'$ac_lib_var`\" = yes"; then 1356 echo "$ac_t""yes" 1>&6 1357 V_NETLIBS="-lsocket $V_NETLIBS" 1358else 1359 echo "$ac_t""no" 1>&6 1360# Unfortunately libsocket sometimes depends on libnsl. 1361 # AC_CHECK_LIB's API is essentially broken so the 1362 # following ugliness is necessary: 1363 echo $ac_n "checking for gethostbyname in -lsocket""... $ac_c" 1>&6 1364echo "configure:1365: checking for gethostbyname in -lsocket" >&5 1365ac_lib_var=`echo socket'_'gethostbyname'_'-lnsl | sed 'y%./+- %__p__%'` 1366if eval "test \"`echo '$''{'ac_cv_lbl_lib_$ac_lib_var'+set}'`\" = set"; then 1367 echo $ac_n "(cached) $ac_c" 1>&6 1368else 1369 ac_save_LIBS="$LIBS" 1370LIBS="-lsocket -lnsl $LIBS" 1371cat > conftest.$ac_ext <<EOF 1372#line 1373 "configure" 1373#include "confdefs.h" 1374/* Override any gcc2 internal prototype to avoid an error. */ 1375/* We use char because int might match the return type of a gcc2 1376 builtin and then its argument prototype would still apply. */ 1377char gethostbyname(); 1378 1379int main() { 1380gethostbyname() 1381; return 0; } 1382EOF 1383if { (eval echo configure:1384: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 1384 rm -rf conftest* 1385 eval "ac_cv_lbl_lib_$ac_lib_var=yes" 1386else 1387 echo "configure: failed program was:" >&5 1388 cat conftest.$ac_ext >&5 1389 rm -rf conftest* 1390 eval "ac_cv_lbl_lib_$ac_lib_var=no" 1391fi 1392rm -f conftest* 1393LIBS="$ac_save_LIBS" 1394 1395fi 1396if eval "test \"`echo '$ac_cv_lbl_lib_'$ac_lib_var`\" = yes"; then 1397 echo "$ac_t""yes" 1>&6 1398 V_NETLIBS="-lsocket -lnsl $V_NETLIBS" 1399else 1400 echo "$ac_t""no" 1>&6 1401echo $ac_n "checking for gethostbyname in -lresolv""... $ac_c" 1>&6 1402echo "configure:1403: checking for gethostbyname in -lresolv" >&5 1403ac_lib_var=`echo resolv'_'gethostbyname | sed 'y%./+-%__p_%'` 1404if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then 1405 echo $ac_n "(cached) $ac_c" 1>&6 1406else 1407 ac_save_LIBS="$LIBS" 1408LIBS="-lresolv $LIBS" 1409cat > conftest.$ac_ext <<EOF 1410#line 1411 "configure" 1411#include "confdefs.h" 1412/* Override any gcc2 internal prototype to avoid an error. */ 1413/* We use char because int might match the return type of a gcc2 1414 builtin and then its argument prototype would still apply. */ 1415char gethostbyname(); 1416 1417int main() { 1418gethostbyname() 1419; return 0; } 1420EOF 1421if { (eval echo configure:1422: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 1422 rm -rf conftest* 1423 eval "ac_cv_lib_$ac_lib_var=yes" 1424else 1425 echo "configure: failed program was:" >&5 1426 cat conftest.$ac_ext >&5 1427 rm -rf conftest* 1428 eval "ac_cv_lib_$ac_lib_var=no" 1429fi 1430rm -f conftest* 1431LIBS="$ac_save_LIBS" 1432 1433fi 1434if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then 1435 echo "$ac_t""yes" 1>&6 1436 V_NETLIBS="-lresolv $V_NETLIBS" 1437else 1438 echo "$ac_t""no" 1>&6 1439fi 1440 1441fi 1442 1443fi 1444 1445fi 1446 1447fi 1448 1449echo $ac_n "checking for socket""... $ac_c" 1>&6 1450echo "configure:1451: checking for socket" >&5 1451if eval "test \"`echo '$''{'ac_cv_func_socket'+set}'`\" = set"; then 1452 echo $ac_n "(cached) $ac_c" 1>&6 1453else 1454 cat > conftest.$ac_ext <<EOF 1455#line 1456 "configure" 1456#include "confdefs.h" 1457/* System header to define __stub macros and hopefully few prototypes, 1458 which can conflict with char socket(); below. */ 1459#include <assert.h> 1460/* Override any gcc2 internal prototype to avoid an error. */ 1461/* We use char because int might match the return type of a gcc2 1462 builtin and then its argument prototype would still apply. */ 1463char socket(); 1464 1465int main() { 1466 1467/* The GNU C library defines this for functions which it implements 1468 to always fail with ENOSYS. Some functions are actually named 1469 something starting with __ and the normal name is an alias. */ 1470#if defined (__stub_socket) || defined (__stub___socket) 1471choke me 1472#else 1473socket(); 1474#endif 1475 1476; return 0; } 1477EOF 1478if { (eval echo configure:1479: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 1479 rm -rf conftest* 1480 eval "ac_cv_func_socket=yes" 1481else 1482 echo "configure: failed program was:" >&5 1483 cat conftest.$ac_ext >&5 1484 rm -rf conftest* 1485 eval "ac_cv_func_socket=no" 1486fi 1487rm -f conftest* 1488fi 1489 1490if eval "test \"`echo '$ac_cv_func_'socket`\" = yes"; then 1491 echo "$ac_t""yes" 1>&6 1492 : 1493else 1494 echo "$ac_t""no" 1>&6 1495echo $ac_n "checking for socket in -lsocket""... $ac_c" 1>&6 1496echo "configure:1497: checking for socket in -lsocket" >&5 1497ac_lib_var=`echo socket'_'socket | sed 'y%./+-%__p_%'` 1498if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then 1499 echo $ac_n "(cached) $ac_c" 1>&6 1500else 1501 ac_save_LIBS="$LIBS" 1502LIBS="-lsocket $LIBS" 1503cat > conftest.$ac_ext <<EOF 1504#line 1505 "configure" 1505#include "confdefs.h" 1506/* Override any gcc2 internal prototype to avoid an error. */ 1507/* We use char because int might match the return type of a gcc2 1508 builtin and then its argument prototype would still apply. */ 1509char socket(); 1510 1511int main() { 1512socket() 1513; return 0; } 1514EOF 1515if { (eval echo configure:1516: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 1516 rm -rf conftest* 1517 eval "ac_cv_lib_$ac_lib_var=yes" 1518else 1519 echo "configure: failed program was:" >&5 1520 cat conftest.$ac_ext >&5 1521 rm -rf conftest* 1522 eval "ac_cv_lib_$ac_lib_var=no" 1523fi 1524rm -f conftest* 1525LIBS="$ac_save_LIBS" 1526 1527fi 1528if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then 1529 echo "$ac_t""yes" 1>&6 1530 V_NETLIBS="-lsocket $V_NETLIBS" 1531else 1532 echo "$ac_t""no" 1>&6 1533echo $ac_n "checking for socket in -lsocket""... $ac_c" 1>&6 1534echo "configure:1535: checking for socket in -lsocket" >&5 1535ac_lib_var=`echo socket'_'socket'_'-lnsl | sed 'y%./+- %__p__%'` 1536if eval "test \"`echo '$''{'ac_cv_lbl_lib_$ac_lib_var'+set}'`\" = set"; then 1537 echo $ac_n "(cached) $ac_c" 1>&6 1538else 1539 ac_save_LIBS="$LIBS" 1540LIBS="-lsocket -lnsl $LIBS" 1541cat > conftest.$ac_ext <<EOF 1542#line 1543 "configure" 1543#include "confdefs.h" 1544/* Override any gcc2 internal prototype to avoid an error. */ 1545/* We use char because int might match the return type of a gcc2 1546 builtin and then its argument prototype would still apply. */ 1547char socket(); 1548 1549int main() { 1550socket() 1551; return 0; } 1552EOF 1553if { (eval echo configure:1554: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 1554 rm -rf conftest* 1555 eval "ac_cv_lbl_lib_$ac_lib_var=yes" 1556else 1557 echo "configure: failed program was:" >&5 1558 cat conftest.$ac_ext >&5 1559 rm -rf conftest* 1560 eval "ac_cv_lbl_lib_$ac_lib_var=no" 1561fi 1562rm -f conftest* 1563LIBS="$ac_save_LIBS" 1564 1565fi 1566if eval "test \"`echo '$ac_cv_lbl_lib_'$ac_lib_var`\" = yes"; then 1567 echo "$ac_t""yes" 1>&6 1568 V_NETLIBS="-lsocket -lnsl $V_NETLIBS" 1569else 1570 echo "$ac_t""no" 1>&6 1571fi 1572 1573fi 1574 1575fi 1576 1577 1578echo $ac_n "checking for main in -linet6""... $ac_c" 1>&6 1579echo "configure:1580: checking for main in -linet6" >&5 1580ac_lib_var=`echo inet6'_'main | sed 'y%./+-%__p_%'` 1581if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then 1582 echo $ac_n "(cached) $ac_c" 1>&6 1583else 1584 ac_save_LIBS="$LIBS" 1585LIBS="-linet6 $LIBS" 1586cat > conftest.$ac_ext <<EOF 1587#line 1588 "configure" 1588#include "confdefs.h" 1589 1590int main() { 1591main() 1592; return 0; } 1593EOF 1594if { (eval echo configure:1595: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 1595 rm -rf conftest* 1596 eval "ac_cv_lib_$ac_lib_var=yes" 1597else 1598 echo "configure: failed program was:" >&5 1599 cat conftest.$ac_ext >&5 1600 rm -rf conftest* 1601 eval "ac_cv_lib_$ac_lib_var=no" 1602fi 1603rm -f conftest* 1604LIBS="$ac_save_LIBS" 1605 1606fi 1607if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then 1608 echo "$ac_t""yes" 1>&6 1609 ac_tr_lib=HAVE_LIB`echo inet6 | sed -e 's/[^a-zA-Z0-9_]/_/g' \ 1610 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` 1611 cat >> confdefs.h <<EOF 1612#define $ac_tr_lib 1 1613EOF 1614 1615 LIBS="-linet6 $LIBS" 1616 1617else 1618 echo "$ac_t""no" 1>&6 1619fi 1620 1621 1622echo $ac_n "checking for crypt""... $ac_c" 1>&6 1623echo "configure:1624: checking for crypt" >&5 1624if eval "test \"`echo '$''{'ac_cv_func_crypt'+set}'`\" = set"; then 1625 echo $ac_n "(cached) $ac_c" 1>&6 1626else 1627 cat > conftest.$ac_ext <<EOF 1628#line 1629 "configure" 1629#include "confdefs.h" 1630/* System header to define __stub macros and hopefully few prototypes, 1631 which can conflict with char crypt(); below. */ 1632#include <assert.h> 1633/* Override any gcc2 internal prototype to avoid an error. */ 1634/* We use char because int might match the return type of a gcc2 1635 builtin and then its argument prototype would still apply. */ 1636char crypt(); 1637 1638int main() { 1639 1640/* The GNU C library defines this for functions which it implements 1641 to always fail with ENOSYS. Some functions are actually named 1642 something starting with __ and the normal name is an alias. */ 1643#if defined (__stub_crypt) || defined (__stub___crypt) 1644choke me 1645#else 1646crypt(); 1647#endif 1648 1649; return 0; } 1650EOF 1651if { (eval echo configure:1652: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 1652 rm -rf conftest* 1653 eval "ac_cv_func_crypt=yes" 1654else 1655 echo "configure: failed program was:" >&5 1656 cat conftest.$ac_ext >&5 1657 rm -rf conftest* 1658 eval "ac_cv_func_crypt=no" 1659fi 1660rm -f conftest* 1661fi 1662 1663if eval "test \"`echo '$ac_cv_func_'crypt`\" = yes"; then 1664 echo "$ac_t""yes" 1>&6 1665 : 1666else 1667 echo "$ac_t""no" 1>&6 1668echo $ac_n "checking for crypt in -lcrypt""... $ac_c" 1>&6 1669echo "configure:1670: checking for crypt in -lcrypt" >&5 1670ac_lib_var=`echo crypt'_'crypt | sed 'y%./+-%__p_%'` 1671if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then 1672 echo $ac_n "(cached) $ac_c" 1>&6 1673else 1674 ac_save_LIBS="$LIBS" 1675LIBS="-lcrypt $LIBS" 1676cat > conftest.$ac_ext <<EOF 1677#line 1678 "configure" 1678#include "confdefs.h" 1679/* Override any gcc2 internal prototype to avoid an error. */ 1680/* We use char because int might match the return type of a gcc2 1681 builtin and then its argument prototype would still apply. */ 1682char crypt(); 1683 1684int main() { 1685crypt() 1686; return 0; } 1687EOF 1688if { (eval echo configure:1689: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 1689 rm -rf conftest* 1690 eval "ac_cv_lib_$ac_lib_var=yes" 1691else 1692 echo "configure: failed program was:" >&5 1693 cat conftest.$ac_ext >&5 1694 rm -rf conftest* 1695 eval "ac_cv_lib_$ac_lib_var=no" 1696fi 1697rm -f conftest* 1698LIBS="$ac_save_LIBS" 1699 1700fi 1701if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then 1702 echo "$ac_t""yes" 1>&6 1703 ac_tr_lib=HAVE_LIB`echo crypt | sed -e 's/^a-zA-Z0-9_/_/g' \ 1704 -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` 1705 cat >> confdefs.h <<EOF 1706#define $ac_tr_lib 1 1707EOF 1708 1709 LIBS="-lcrypt $LIBS" 1710 1711else 1712 echo "$ac_t""no" 1>&6 1713fi 1714 1715fi 1716 1717echo $ac_n "checking for hstrerror""... $ac_c" 1>&6 1718echo "configure:1719: checking for hstrerror" >&5 1719if eval "test \"`echo '$''{'ac_cv_func_hstrerror'+set}'`\" = set"; then 1720 echo $ac_n "(cached) $ac_c" 1>&6 1721else 1722 cat > conftest.$ac_ext <<EOF 1723#line 1724 "configure" 1724#include "confdefs.h" 1725/* System header to define __stub macros and hopefully few prototypes, 1726 which can conflict with char hstrerror(); below. */ 1727#include <assert.h> 1728/* Override any gcc2 internal prototype to avoid an error. */ 1729/* We use char because int might match the return type of a gcc2 1730 builtin and then its argument prototype would still apply. */ 1731char hstrerror(); 1732 1733int main() { 1734 1735/* The GNU C library defines this for functions which it implements 1736 to always fail with ENOSYS. Some functions are actually named 1737 something starting with __ and the normal name is an alias. */ 1738#if defined (__stub_hstrerror) || defined (__stub___hstrerror) 1739choke me 1740#else 1741hstrerror(); 1742#endif 1743 1744; return 0; } 1745EOF 1746if { (eval echo configure:1747: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 1747 rm -rf conftest* 1748 eval "ac_cv_func_hstrerror=yes" 1749else 1750 echo "configure: failed program was:" >&5 1751 cat conftest.$ac_ext >&5 1752 rm -rf conftest* 1753 eval "ac_cv_func_hstrerror=no" 1754fi 1755rm -f conftest* 1756fi 1757 1758if eval "test \"`echo '$ac_cv_func_'hstrerror`\" = yes"; then 1759 echo "$ac_t""yes" 1>&6 1760 : 1761else 1762 echo "$ac_t""no" 1>&6 1763echo $ac_n "checking for hstrerror in -lresolv""... $ac_c" 1>&6 1764echo "configure:1765: checking for hstrerror in -lresolv" >&5 1765ac_lib_var=`echo resolv'_'hstrerror | sed 'y%./+-%__p_%'` 1766if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then 1767 echo $ac_n "(cached) $ac_c" 1>&6 1768else 1769 ac_save_LIBS="$LIBS" 1770LIBS="-lresolv $LIBS" 1771cat > conftest.$ac_ext <<EOF 1772#line 1773 "configure" 1773#include "confdefs.h" 1774/* Override any gcc2 internal prototype to avoid an error. */ 1775/* We use char because int might match the return type of a gcc2 1776 builtin and then its argument prototype would still apply. */ 1777char hstrerror(); 1778 1779int main() { 1780hstrerror() 1781; return 0; } 1782EOF 1783if { (eval echo configure:1784: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 1784 rm -rf conftest* 1785 eval "ac_cv_lib_$ac_lib_var=yes" 1786else 1787 echo "configure: failed program was:" >&5 1788 cat conftest.$ac_ext >&5 1789 rm -rf conftest* 1790 eval "ac_cv_lib_$ac_lib_var=no" 1791fi 1792rm -f conftest* 1793LIBS="$ac_save_LIBS" 1794 1795fi 1796if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then 1797 echo "$ac_t""yes" 1>&6 1798 V_NETLIBS="-lresolv $V_NETLIBS" 1799else 1800 echo "$ac_t""no" 1>&6 1801fi 1802 1803fi 1804 1805 1806for ac_func in strerror 1807do 1808echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 1809echo "configure:1810: checking for $ac_func" >&5 1810if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then 1811 echo $ac_n "(cached) $ac_c" 1>&6 1812else 1813 cat > conftest.$ac_ext <<EOF 1814#line 1815 "configure" 1815#include "confdefs.h" 1816/* System header to define __stub macros and hopefully few prototypes, 1817 which can conflict with char $ac_func(); below. */ 1818#include <assert.h> 1819/* Override any gcc2 internal prototype to avoid an error. */ 1820/* We use char because int might match the return type of a gcc2 1821 builtin and then its argument prototype would still apply. */ 1822char $ac_func(); 1823 1824int main() { 1825 1826/* The GNU C library defines this for functions which it implements 1827 to always fail with ENOSYS. Some functions are actually named 1828 something starting with __ and the normal name is an alias. */ 1829#if defined (__stub_$ac_func) || defined (__stub___$ac_func) 1830choke me 1831#else 1832$ac_func(); 1833#endif 1834 1835; return 0; } 1836EOF 1837if { (eval echo configure:1838: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 1838 rm -rf conftest* 1839 eval "ac_cv_func_$ac_func=yes" 1840else 1841 echo "configure: failed program was:" >&5 1842 cat conftest.$ac_ext >&5 1843 rm -rf conftest* 1844 eval "ac_cv_func_$ac_func=no" 1845fi 1846rm -f conftest* 1847fi 1848 1849if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then 1850 echo "$ac_t""yes" 1>&6 1851 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` 1852 cat >> confdefs.h <<EOF 1853#define $ac_tr_func 1 1854EOF 1855 1856else 1857 echo "$ac_t""no" 1>&6 1858LIBOBJS="$LIBOBJS ${ac_func}.${ac_objext}" 1859fi 1860done 1861 1862 1863for ac_func in waitpid vsnprintf daemon setsid setlogin getaddrinfo getnameinfo gai_strerror kqueue sigset atoll 1864do 1865echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 1866echo "configure:1867: checking for $ac_func" >&5 1867if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then 1868 echo $ac_n "(cached) $ac_c" 1>&6 1869else 1870 cat > conftest.$ac_ext <<EOF 1871#line 1872 "configure" 1872#include "confdefs.h" 1873/* System header to define __stub macros and hopefully few prototypes, 1874 which can conflict with char $ac_func(); below. */ 1875#include <assert.h> 1876/* Override any gcc2 internal prototype to avoid an error. */ 1877/* We use char because int might match the return type of a gcc2 1878 builtin and then its argument prototype would still apply. */ 1879char $ac_func(); 1880 1881int main() { 1882 1883/* The GNU C library defines this for functions which it implements 1884 to always fail with ENOSYS. Some functions are actually named 1885 something starting with __ and the normal name is an alias. */ 1886#if defined (__stub_$ac_func) || defined (__stub___$ac_func) 1887choke me 1888#else 1889$ac_func(); 1890#endif 1891 1892; return 0; } 1893EOF 1894if { (eval echo configure:1895: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 1895 rm -rf conftest* 1896 eval "ac_cv_func_$ac_func=yes" 1897else 1898 echo "configure: failed program was:" >&5 1899 cat conftest.$ac_ext >&5 1900 rm -rf conftest* 1901 eval "ac_cv_func_$ac_func=no" 1902fi 1903rm -f conftest* 1904fi 1905 1906if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then 1907 echo "$ac_t""yes" 1>&6 1908 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` 1909 cat >> confdefs.h <<EOF 1910#define $ac_tr_func 1 1911EOF 1912 1913else 1914 echo "$ac_t""no" 1>&6 1915fi 1916done 1917 1918for ac_hdr in unistd.h 1919do 1920ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'` 1921echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6 1922echo "configure:1923: checking for $ac_hdr" >&5 1923if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then 1924 echo $ac_n "(cached) $ac_c" 1>&6 1925else 1926 cat > conftest.$ac_ext <<EOF 1927#line 1928 "configure" 1928#include "confdefs.h" 1929#include <$ac_hdr> 1930EOF 1931ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" 1932{ (eval echo configure:1933: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } 1933ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` 1934if test -z "$ac_err"; then 1935 rm -rf conftest* 1936 eval "ac_cv_header_$ac_safe=yes" 1937else 1938 echo "$ac_err" >&5 1939 echo "configure: failed program was:" >&5 1940 cat conftest.$ac_ext >&5 1941 rm -rf conftest* 1942 eval "ac_cv_header_$ac_safe=no" 1943fi 1944rm -f conftest* 1945fi 1946if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then 1947 echo "$ac_t""yes" 1>&6 1948 ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'` 1949 cat >> confdefs.h <<EOF 1950#define $ac_tr_hdr 1 1951EOF 1952 1953else 1954 echo "$ac_t""no" 1>&6 1955fi 1956done 1957 1958for ac_func in getpagesize 1959do 1960echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 1961echo "configure:1962: checking for $ac_func" >&5 1962if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then 1963 echo $ac_n "(cached) $ac_c" 1>&6 1964else 1965 cat > conftest.$ac_ext <<EOF 1966#line 1967 "configure" 1967#include "confdefs.h" 1968/* System header to define __stub macros and hopefully few prototypes, 1969 which can conflict with char $ac_func(); below. */ 1970#include <assert.h> 1971/* Override any gcc2 internal prototype to avoid an error. */ 1972/* We use char because int might match the return type of a gcc2 1973 builtin and then its argument prototype would still apply. */ 1974char $ac_func(); 1975 1976int main() { 1977 1978/* The GNU C library defines this for functions which it implements 1979 to always fail with ENOSYS. Some functions are actually named 1980 something starting with __ and the normal name is an alias. */ 1981#if defined (__stub_$ac_func) || defined (__stub___$ac_func) 1982choke me 1983#else 1984$ac_func(); 1985#endif 1986 1987; return 0; } 1988EOF 1989if { (eval echo configure:1990: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 1990 rm -rf conftest* 1991 eval "ac_cv_func_$ac_func=yes" 1992else 1993 echo "configure: failed program was:" >&5 1994 cat conftest.$ac_ext >&5 1995 rm -rf conftest* 1996 eval "ac_cv_func_$ac_func=no" 1997fi 1998rm -f conftest* 1999fi 2000 2001if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then 2002 echo "$ac_t""yes" 1>&6 2003 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` 2004 cat >> confdefs.h <<EOF 2005#define $ac_tr_func 1 2006EOF 2007 2008else 2009 echo "$ac_t""no" 1>&6 2010fi 2011done 2012 2013echo $ac_n "checking for working mmap""... $ac_c" 1>&6 2014echo "configure:2015: checking for working mmap" >&5 2015if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then 2016 echo $ac_n "(cached) $ac_c" 1>&6 2017else 2018 if test "$cross_compiling" = yes; then 2019 ac_cv_func_mmap_fixed_mapped=no 2020else 2021 cat > conftest.$ac_ext <<EOF 2022#line 2023 "configure" 2023#include "confdefs.h" 2024 2025/* Thanks to Mike Haertel and Jim Avera for this test. 2026 Here is a matrix of mmap possibilities: 2027 mmap private not fixed 2028 mmap private fixed at somewhere currently unmapped 2029 mmap private fixed at somewhere already mapped 2030 mmap shared not fixed 2031 mmap shared fixed at somewhere currently unmapped 2032 mmap shared fixed at somewhere already mapped 2033 For private mappings, we should verify that changes cannot be read() 2034 back from the file, nor mmap's back from the file at a different 2035 address. (There have been systems where private was not correctly 2036 implemented like the infamous i386 svr4.0, and systems where the 2037 VM page cache was not coherent with the filesystem buffer cache 2038 like early versions of FreeBSD and possibly contemporary NetBSD.) 2039 For shared mappings, we should conversely verify that changes get 2040 propogated back to all the places they're supposed to be. 2041 2042 Grep wants private fixed already mapped. 2043 The main things grep needs to know about mmap are: 2044 * does it exist and is it safe to write into the mmap'd area 2045 * how to use it (BSD variants) */ 2046#include <sys/types.h> 2047#include <fcntl.h> 2048#include <sys/mman.h> 2049 2050/* This mess was copied from the GNU getpagesize.h. */ 2051#ifndef HAVE_GETPAGESIZE 2052# ifdef HAVE_UNISTD_H 2053# include <unistd.h> 2054# endif 2055 2056/* Assume that all systems that can run configure have sys/param.h. */ 2057# ifndef HAVE_SYS_PARAM_H 2058# define HAVE_SYS_PARAM_H 1 2059# endif 2060 2061# ifdef _SC_PAGESIZE 2062# define getpagesize() sysconf(_SC_PAGESIZE) 2063# else /* no _SC_PAGESIZE */ 2064# ifdef HAVE_SYS_PARAM_H 2065# include <sys/param.h> 2066# ifdef EXEC_PAGESIZE 2067# define getpagesize() EXEC_PAGESIZE 2068# else /* no EXEC_PAGESIZE */ 2069# ifdef NBPG 2070# define getpagesize() NBPG * CLSIZE 2071# ifndef CLSIZE 2072# define CLSIZE 1 2073# endif /* no CLSIZE */ 2074# else /* no NBPG */ 2075# ifdef NBPC 2076# define getpagesize() NBPC 2077# else /* no NBPC */ 2078# ifdef PAGESIZE 2079# define getpagesize() PAGESIZE 2080# endif /* PAGESIZE */ 2081# endif /* no NBPC */ 2082# endif /* no NBPG */ 2083# endif /* no EXEC_PAGESIZE */ 2084# else /* no HAVE_SYS_PARAM_H */ 2085# define getpagesize() 8192 /* punt totally */ 2086# endif /* no HAVE_SYS_PARAM_H */ 2087# endif /* no _SC_PAGESIZE */ 2088 2089#endif /* no HAVE_GETPAGESIZE */ 2090 2091#ifdef __cplusplus 2092extern "C" { void *malloc(unsigned); } 2093#else 2094char *malloc(); 2095#endif 2096 2097int 2098main() 2099{ 2100 char *data, *data2, *data3; 2101 int i, pagesize; 2102 int fd; 2103 2104 pagesize = getpagesize(); 2105 2106 /* 2107 * First, make a file with some known garbage in it. 2108 */ 2109 data = malloc(pagesize); 2110 if (!data) 2111 exit(1); 2112 for (i = 0; i < pagesize; ++i) 2113 *(data + i) = rand(); 2114 umask(0); 2115 fd = creat("conftestmmap", 0600); 2116 if (fd < 0) 2117 exit(1); 2118 if (write(fd, data, pagesize) != pagesize) 2119 exit(1); 2120 close(fd); 2121 2122 /* 2123 * Next, try to mmap the file at a fixed address which 2124 * already has something else allocated at it. If we can, 2125 * also make sure that we see the same garbage. 2126 */ 2127 fd = open("conftestmmap", O_RDWR); 2128 if (fd < 0) 2129 exit(1); 2130 data2 = malloc(2 * pagesize); 2131 if (!data2) 2132 exit(1); 2133 data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1); 2134 if (data2 != mmap(data2, pagesize, PROT_READ | PROT_WRITE, 2135 MAP_PRIVATE | MAP_FIXED, fd, 0L)) 2136 exit(1); 2137 for (i = 0; i < pagesize; ++i) 2138 if (*(data + i) != *(data2 + i)) 2139 exit(1); 2140 2141 /* 2142 * Finally, make sure that changes to the mapped area 2143 * do not percolate back to the file as seen by read(). 2144 * (This is a bug on some variants of i386 svr4.0.) 2145 */ 2146 for (i = 0; i < pagesize; ++i) 2147 *(data2 + i) = *(data2 + i) + 1; 2148 data3 = malloc(pagesize); 2149 if (!data3) 2150 exit(1); 2151 if (read(fd, data3, pagesize) != pagesize) 2152 exit(1); 2153 for (i = 0; i < pagesize; ++i) 2154 if (*(data + i) != *(data3 + i)) 2155 exit(1); 2156 close(fd); 2157 unlink("conftestmmap"); 2158 exit(0); 2159} 2160 2161EOF 2162if { (eval echo configure:2163: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null 2163then 2164 ac_cv_func_mmap_fixed_mapped=yes 2165else 2166 echo "configure: failed program was:" >&5 2167 cat conftest.$ac_ext >&5 2168 rm -fr conftest* 2169 ac_cv_func_mmap_fixed_mapped=no 2170fi 2171rm -fr conftest* 2172fi 2173 2174fi 2175 2176echo "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6 2177if test $ac_cv_func_mmap_fixed_mapped = yes; then 2178 cat >> confdefs.h <<\EOF 2179#define HAVE_MMAP 1 2180EOF 2181 2182fi 2183 2184 2185case "$target_os" in 2186solaris*) 2187 for ac_func in poll 2188do 2189echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 2190echo "configure:2191: checking for $ac_func" >&5 2191if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then 2192 echo $ac_n "(cached) $ac_c" 1>&6 2193else 2194 cat > conftest.$ac_ext <<EOF 2195#line 2196 "configure" 2196#include "confdefs.h" 2197/* System header to define __stub macros and hopefully few prototypes, 2198 which can conflict with char $ac_func(); below. */ 2199#include <assert.h> 2200/* Override any gcc2 internal prototype to avoid an error. */ 2201/* We use char because int might match the return type of a gcc2 2202 builtin and then its argument prototype would still apply. */ 2203char $ac_func(); 2204 2205int main() { 2206 2207/* The GNU C library defines this for functions which it implements 2208 to always fail with ENOSYS. Some functions are actually named 2209 something starting with __ and the normal name is an alias. */ 2210#if defined (__stub_$ac_func) || defined (__stub___$ac_func) 2211choke me 2212#else 2213$ac_func(); 2214#endif 2215 2216; return 0; } 2217EOF 2218if { (eval echo configure:2219: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 2219 rm -rf conftest* 2220 eval "ac_cv_func_$ac_func=yes" 2221else 2222 echo "configure: failed program was:" >&5 2223 cat conftest.$ac_ext >&5 2224 rm -rf conftest* 2225 eval "ac_cv_func_$ac_func=no" 2226fi 2227rm -f conftest* 2228fi 2229 2230if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then 2231 echo "$ac_t""yes" 1>&6 2232 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` 2233 cat >> confdefs.h <<EOF 2234#define $ac_tr_func 1 2235EOF 2236 2237else 2238 echo "$ac_t""no" 1>&6 2239fi 2240done 2241 2242 ;; 2243*) 2244 for ac_func in select poll 2245do 2246echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 2247echo "configure:2248: checking for $ac_func" >&5 2248if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then 2249 echo $ac_n "(cached) $ac_c" 1>&6 2250else 2251 cat > conftest.$ac_ext <<EOF 2252#line 2253 "configure" 2253#include "confdefs.h" 2254/* System header to define __stub macros and hopefully few prototypes, 2255 which can conflict with char $ac_func(); below. */ 2256#include <assert.h> 2257/* Override any gcc2 internal prototype to avoid an error. */ 2258/* We use char because int might match the return type of a gcc2 2259 builtin and then its argument prototype would still apply. */ 2260char $ac_func(); 2261 2262int main() { 2263 2264/* The GNU C library defines this for functions which it implements 2265 to always fail with ENOSYS. Some functions are actually named 2266 something starting with __ and the normal name is an alias. */ 2267#if defined (__stub_$ac_func) || defined (__stub___$ac_func) 2268choke me 2269#else 2270$ac_func(); 2271#endif 2272 2273; return 0; } 2274EOF 2275if { (eval echo configure:2276: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then 2276 rm -rf conftest* 2277 eval "ac_cv_func_$ac_func=yes" 2278else 2279 echo "configure: failed program was:" >&5 2280 cat conftest.$ac_ext >&5 2281 rm -rf conftest* 2282 eval "ac_cv_func_$ac_func=no" 2283fi 2284rm -f conftest* 2285fi 2286 2287if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then 2288 echo "$ac_t""yes" 1>&6 2289 ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` 2290 cat >> confdefs.h <<EOF 2291#define $ac_tr_func 1 2292EOF 2293 2294else 2295 echo "$ac_t""no" 1>&6 2296fi 2297done 2298 2299 ;; 2300esac 2301 2302echo $ac_n "checking if struct tm has tm_gmtoff member""... $ac_c" 1>&6 2303echo "configure:2304: checking if struct tm has tm_gmtoff member" >&5 2304 if eval "test \"`echo '$''{'ac_cv_acme_tm_has_tm_gmtoff'+set}'`\" = set"; then 2305 echo $ac_n "(cached) $ac_c" 1>&6 2306else 2307 cat > conftest.$ac_ext <<EOF 2308#line 2309 "configure" 2309#include "confdefs.h" 2310 2311# include <sys/types.h> 2312# include <time.h> 2313int main() { 2314u_int i = sizeof(((struct tm *)0)->tm_gmtoff) 2315; return 0; } 2316EOF 2317if { (eval echo configure:2318: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then 2318 rm -rf conftest* 2319 ac_cv_acme_tm_has_tm_gmtoff=yes 2320else 2321 echo "configure: failed program was:" >&5 2322 cat conftest.$ac_ext >&5 2323 rm -rf conftest* 2324 ac_cv_acme_tm_has_tm_gmtoff=no 2325fi 2326rm -f conftest* 2327fi 2328 2329 echo "$ac_t""$ac_cv_acme_tm_has_tm_gmtoff" 1>&6 2330 if test $ac_cv_acme_tm_has_tm_gmtoff = yes ; then 2331 cat >> confdefs.h <<\EOF 2332#define HAVE_TM_GMTOFF 1 2333EOF 2334 2335 fi 2336echo $ac_n "checking if int64_t exists""... $ac_c" 1>&6 2337echo "configure:2338: checking if int64_t exists" >&5 2338 if eval "test \"`echo '$''{'ac_cv_acme_int64_t'+set}'`\" = set"; then 2339 echo $ac_n "(cached) $ac_c" 1>&6 2340else 2341 cat > conftest.$ac_ext <<EOF 2342#line 2343 "configure" 2343#include "confdefs.h" 2344 2345# include <sys/types.h> 2346int main() { 2347int64_t i64 2348; return 0; } 2349EOF 2350if { (eval echo configure:2351: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then 2351 rm -rf conftest* 2352 ac_cv_acme_int64_t=yes 2353else 2354 echo "configure: failed program was:" >&5 2355 cat conftest.$ac_ext >&5 2356 rm -rf conftest* 2357 ac_cv_acme_int64_t=no 2358fi 2359rm -f conftest* 2360fi 2361 2362 echo "$ac_t""$ac_cv_acme_int64_t" 1>&6 2363 if test $ac_cv_acme_int64_t = yes ; then 2364 cat >> confdefs.h <<\EOF 2365#define HAVE_INT64T 1 2366EOF 2367 2368 fi 2369echo $ac_n "checking if socklen_t exists""... $ac_c" 1>&6 2370echo "configure:2371: checking if socklen_t exists" >&5 2371 if eval "test \"`echo '$''{'ac_cv_acme_socklen_t'+set}'`\" = set"; then 2372 echo $ac_n "(cached) $ac_c" 1>&6 2373else 2374 cat > conftest.$ac_ext <<EOF 2375#line 2376 "configure" 2376#include "confdefs.h" 2377 2378# include <sys/types.h> 2379# include <sys/socket.h> 2380int main() { 2381socklen_t slen 2382; return 0; } 2383EOF 2384if { (eval echo configure:2385: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then 2385 rm -rf conftest* 2386 ac_cv_acme_socklen_t=yes 2387else 2388 echo "configure: failed program was:" >&5 2389 cat conftest.$ac_ext >&5 2390 rm -rf conftest* 2391 ac_cv_acme_socklen_t=no 2392fi 2393rm -f conftest* 2394fi 2395 2396 echo "$ac_t""$ac_cv_acme_socklen_t" 1>&6 2397 if test $ac_cv_acme_socklen_t = yes ; then 2398 cat >> confdefs.h <<\EOF 2399#define HAVE_SOCKLENT 1 2400EOF 2401 2402 fi 2403 2404echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6 2405echo "configure:2406: checking whether ${MAKE-make} sets \${MAKE}" >&5 2406set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'` 2407if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then 2408 echo $ac_n "(cached) $ac_c" 1>&6 2409else 2410 cat > conftestmake <<\EOF 2411all: 2412 @echo 'ac_maketemp="${MAKE}"' 2413EOF 2414# GNU make sometimes prints "make[1]: Entering...", which would confuse us. 2415eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=` 2416if test -n "$ac_maketemp"; then 2417 eval ac_cv_prog_make_${ac_make}_set=yes 2418else 2419 eval ac_cv_prog_make_${ac_make}_set=no 2420fi 2421rm -f conftestmake 2422fi 2423if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then 2424 echo "$ac_t""yes" 1>&6 2425 SET_MAKE= 2426else 2427 echo "$ac_t""no" 1>&6 2428 SET_MAKE="MAKE=${MAKE-make}" 2429fi 2430 2431# Find a good install program. We prefer a C program (faster), 2432# so one script is as good as another. But avoid the broken or 2433# incompatible versions: 2434# SysV /etc/install, /usr/sbin/install 2435# SunOS /usr/etc/install 2436# IRIX /sbin/install 2437# AIX /bin/install 2438# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag 2439# AFS /usr/afsws/bin/install, which mishandles nonexistent args 2440# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" 2441# ./install, which can be erroneously created by make from ./install.sh. 2442echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6 2443echo "configure:2444: checking for a BSD compatible install" >&5 2444if test -z "$INSTALL"; then 2445if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then 2446 echo $ac_n "(cached) $ac_c" 1>&6 2447else 2448 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":" 2449 for ac_dir in $PATH; do 2450 # Account for people who put trailing slashes in PATH elements. 2451 case "$ac_dir/" in 2452 /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;; 2453 *) 2454 # OSF1 and SCO ODT 3.0 have their own names for install. 2455 # Don't use installbsd from OSF since it installs stuff as root 2456 # by default. 2457 for ac_prog in ginstall scoinst install; do 2458 if test -f $ac_dir/$ac_prog; then 2459 if test $ac_prog = install && 2460 grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then 2461 # AIX install. It has an incompatible calling convention. 2462 : 2463 else 2464 ac_cv_path_install="$ac_dir/$ac_prog -c" 2465 break 2 2466 fi 2467 fi 2468 done 2469 ;; 2470 esac 2471 done 2472 IFS="$ac_save_IFS" 2473 2474fi 2475 if test "${ac_cv_path_install+set}" = set; then 2476 INSTALL="$ac_cv_path_install" 2477 else 2478 # As a last resort, use the slow shell script. We don't cache a 2479 # path for INSTALL within a source directory, because that will 2480 # break other packages using the cache if that directory is 2481 # removed, or if the path is relative. 2482 INSTALL="$ac_install_sh" 2483 fi 2484fi 2485echo "$ac_t""$INSTALL" 1>&6 2486 2487# Use test -z because SunOS4 sh mishandles braces in ${var-val}. 2488# It thinks the first close brace ends the variable substitution. 2489test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' 2490 2491test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}' 2492 2493test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' 2494 2495 2496 2497 2498 2499 2500 2501trap '' 1 2 15 2502cat > confcache <<\EOF 2503# This file is a shell script that caches the results of configure 2504# tests run on this system so they can be shared between configure 2505# scripts and configure runs. It is not useful on other systems. 2506# If it contains results you don't want to keep, you may remove or edit it. 2507# 2508# By default, configure uses ./config.cache as the cache file, 2509# creating it if it does not exist already. You can give configure 2510# the --cache-file=FILE option to use a different cache file; that is 2511# what configure does when it calls configure scripts in 2512# subdirectories, so they share the cache. 2513# Giving --cache-file=/dev/null disables caching, for debugging configure. 2514# config.status only pays attention to the cache file if you give it the 2515# --recheck option to rerun configure. 2516# 2517EOF 2518# The following way of writing the cache mishandles newlines in values, 2519# but we know of no workaround that is simple, portable, and efficient. 2520# So, don't put newlines in cache variables' values. 2521# Ultrix sh set writes to stderr and can't be redirected directly, 2522# and sets the high bit in the cache file unless we assign to the vars. 2523(set) 2>&1 | 2524 case `(ac_space=' '; set | grep ac_space) 2>&1` in 2525 *ac_space=\ *) 2526 # `set' does not quote correctly, so add quotes (double-quote substitution 2527 # turns \\\\ into \\, and sed turns \\ into \). 2528 sed -n \ 2529 -e "s/'/'\\\\''/g" \ 2530 -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p" 2531 ;; 2532 *) 2533 # `set' quotes correctly as required by POSIX, so do not add quotes. 2534 sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p' 2535 ;; 2536 esac >> confcache 2537if cmp -s $cache_file confcache; then 2538 : 2539else 2540 if test -w $cache_file; then 2541 echo "updating cache $cache_file" 2542 cat confcache > $cache_file 2543 else 2544 echo "not updating unwritable cache $cache_file" 2545 fi 2546fi 2547rm -f confcache 2548 2549trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15 2550 2551test "x$prefix" = xNONE && prefix=$ac_default_prefix 2552# Let make expand exec_prefix. 2553test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' 2554 2555# Any assignment to VPATH causes Sun make to only execute 2556# the first set of double-colon rules, so remove it if not needed. 2557# If there is a colon in the path, we need to keep it. 2558if test "x$srcdir" = x.; then 2559 ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d' 2560fi 2561 2562trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15 2563 2564# Transform confdefs.h into DEFS. 2565# Protect against shell expansion while executing Makefile rules. 2566# Protect against Makefile macro expansion. 2567cat > conftest.defs <<\EOF 2568s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%-D\1=\2%g 2569s%[ `~#$^&*(){}\\|;'"<>?]%\\&%g 2570s%\[%\\&%g 2571s%\]%\\&%g 2572s%\$%$$%g 2573EOF 2574DEFS=`sed -f conftest.defs confdefs.h | tr '\012' ' '` 2575rm -f conftest.defs 2576 2577 2578# Without the "./", some shells look in PATH for config.status. 2579: ${CONFIG_STATUS=./config.status} 2580 2581echo creating $CONFIG_STATUS 2582rm -f $CONFIG_STATUS 2583cat > $CONFIG_STATUS <<EOF 2584#! /bin/sh 2585# Generated automatically by configure. 2586# Run this file to recreate the current configuration. 2587# This directory was configured as follows, 2588# on host `(hostname || uname -n) 2>/dev/null | sed 1q`: 2589# 2590# $0 $ac_configure_args 2591# 2592# Compiler output produced by configure, useful for debugging 2593# configure, is in ./config.log if it exists. 2594 2595ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]" 2596for ac_option 2597do 2598 case "\$ac_option" in 2599 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) 2600 echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion" 2601 exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;; 2602 -version | --version | --versio | --versi | --vers | --ver | --ve | --v) 2603 echo "$CONFIG_STATUS generated by autoconf version 2.13" 2604 exit 0 ;; 2605 -help | --help | --hel | --he | --h) 2606 echo "\$ac_cs_usage"; exit 0 ;; 2607 *) echo "\$ac_cs_usage"; exit 1 ;; 2608 esac 2609done 2610 2611ac_given_srcdir=$srcdir 2612ac_given_INSTALL="$INSTALL" 2613 2614trap 'rm -fr `echo "Makefile cgi-src/Makefile extras/Makefile" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 2615EOF 2616cat >> $CONFIG_STATUS <<EOF 2617 2618# Protect against being on the right side of a sed subst in config.status. 2619sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g; 2620 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF 2621$ac_vpsub 2622$extrasub 2623s%@SHELL@%$SHELL%g 2624s%@CFLAGS@%$CFLAGS%g 2625s%@CPPFLAGS@%$CPPFLAGS%g 2626s%@CXXFLAGS@%$CXXFLAGS%g 2627s%@FFLAGS@%$FFLAGS%g 2628s%@DEFS@%$DEFS%g 2629s%@LDFLAGS@%$LDFLAGS%g 2630s%@LIBS@%$LIBS%g 2631s%@exec_prefix@%$exec_prefix%g 2632s%@prefix@%$prefix%g 2633s%@program_transform_name@%$program_transform_name%g 2634s%@bindir@%$bindir%g 2635s%@sbindir@%$sbindir%g 2636s%@libexecdir@%$libexecdir%g 2637s%@datadir@%$datadir%g 2638s%@sysconfdir@%$sysconfdir%g 2639s%@sharedstatedir@%$sharedstatedir%g 2640s%@localstatedir@%$localstatedir%g 2641s%@libdir@%$libdir%g 2642s%@includedir@%$includedir%g 2643s%@oldincludedir@%$oldincludedir%g 2644s%@infodir@%$infodir%g 2645s%@mandir@%$mandir%g 2646s%@host@%$host%g 2647s%@host_alias@%$host_alias%g 2648s%@host_cpu@%$host_cpu%g 2649s%@host_vendor@%$host_vendor%g 2650s%@host_os@%$host_os%g 2651s%@target@%$target%g 2652s%@target_alias@%$target_alias%g 2653s%@target_cpu@%$target_cpu%g 2654s%@target_vendor@%$target_vendor%g 2655s%@target_os@%$target_os%g 2656s%@build@%$build%g 2657s%@build_alias@%$build_alias%g 2658s%@build_cpu@%$build_cpu%g 2659s%@build_vendor@%$build_vendor%g 2660s%@build_os@%$build_os%g 2661s%@CC@%$CC%g 2662s%@CPP@%$CPP%g 2663s%@LIBOBJS@%$LIBOBJS%g 2664s%@SET_MAKE@%$SET_MAKE%g 2665s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g 2666s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g 2667s%@INSTALL_DATA@%$INSTALL_DATA%g 2668s%@V_CCOPT@%$V_CCOPT%g 2669s%@V_STATICFLAG@%$V_STATICFLAG%g 2670s%@V_NETLIBS@%$V_NETLIBS%g 2671 2672CEOF 2673EOF 2674 2675cat >> $CONFIG_STATUS <<\EOF 2676 2677# Split the substitutions into bite-sized pieces for seds with 2678# small command number limits, like on Digital OSF/1 and HP-UX. 2679ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script. 2680ac_file=1 # Number of current file. 2681ac_beg=1 # First line for current file. 2682ac_end=$ac_max_sed_cmds # Line after last line for current file. 2683ac_more_lines=: 2684ac_sed_cmds="" 2685while $ac_more_lines; do 2686 if test $ac_beg -gt 1; then 2687 sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file 2688 else 2689 sed "${ac_end}q" conftest.subs > conftest.s$ac_file 2690 fi 2691 if test ! -s conftest.s$ac_file; then 2692 ac_more_lines=false 2693 rm -f conftest.s$ac_file 2694 else 2695 if test -z "$ac_sed_cmds"; then 2696 ac_sed_cmds="sed -f conftest.s$ac_file" 2697 else 2698 ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file" 2699 fi 2700 ac_file=`expr $ac_file + 1` 2701 ac_beg=$ac_end 2702 ac_end=`expr $ac_end + $ac_max_sed_cmds` 2703 fi 2704done 2705if test -z "$ac_sed_cmds"; then 2706 ac_sed_cmds=cat 2707fi 2708EOF 2709 2710cat >> $CONFIG_STATUS <<EOF 2711 2712CONFIG_FILES=\${CONFIG_FILES-"Makefile cgi-src/Makefile extras/Makefile"} 2713EOF 2714cat >> $CONFIG_STATUS <<\EOF 2715for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then 2716 # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in". 2717 case "$ac_file" in 2718 *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'` 2719 ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; 2720 *) ac_file_in="${ac_file}.in" ;; 2721 esac 2722 2723 # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories. 2724 2725 # Remove last slash and all that follows it. Not all systems have dirname. 2726 ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'` 2727 if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then 2728 # The file is in a subdirectory. 2729 test ! -d "$ac_dir" && mkdir "$ac_dir" 2730 ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`" 2731 # A "../" for each directory in $ac_dir_suffix. 2732 ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'` 2733 else 2734 ac_dir_suffix= ac_dots= 2735 fi 2736 2737 case "$ac_given_srcdir" in 2738 .) srcdir=. 2739 if test -z "$ac_dots"; then top_srcdir=. 2740 else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;; 2741 /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;; 2742 *) # Relative path. 2743 srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix" 2744 top_srcdir="$ac_dots$ac_given_srcdir" ;; 2745 esac 2746 2747 case "$ac_given_INSTALL" in 2748 [/$]*) INSTALL="$ac_given_INSTALL" ;; 2749 *) INSTALL="$ac_dots$ac_given_INSTALL" ;; 2750 esac 2751 2752 echo creating "$ac_file" 2753 rm -f "$ac_file" 2754 configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure." 2755 case "$ac_file" in 2756 *Makefile*) ac_comsub="1i\\ 2757# $configure_input" ;; 2758 *) ac_comsub= ;; 2759 esac 2760 2761 ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"` 2762 sed -e "$ac_comsub 2763s%@configure_input@%$configure_input%g 2764s%@srcdir@%$srcdir%g 2765s%@top_srcdir@%$top_srcdir%g 2766s%@INSTALL@%$INSTALL%g 2767" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file 2768fi; done 2769rm -f conftest.s* 2770 2771EOF 2772cat >> $CONFIG_STATUS <<EOF 2773 2774EOF 2775cat >> $CONFIG_STATUS <<\EOF 2776 2777exit 0 2778EOF 2779chmod +x $CONFIG_STATUS 2780rm -fr confdefs* $ac_clean_files 2781test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1 2782 2783