1#! /bin/sh 2# Guess values for system-dependent variables and create Makefiles. 3# Generated by GNU Autoconf 2.71 for OpenSSH Portable. 4# 5# Report bugs to <openssh-unix-dev@mindrot.org>. 6# 7# 8# Copyright (C) 1992-1996, 1998-2017, 2020-2021 Free Software Foundation, 9# Inc. 10# 11# 12# This configure script is free software; the Free Software Foundation 13# gives unlimited permission to copy, distribute and modify it. 14## -------------------- ## 15## M4sh Initialization. ## 16## -------------------- ## 17 18# Be more Bourne compatible 19DUALCASE=1; export DUALCASE # for MKS sh 20as_nop=: 21if test ${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1 22then : 23 emulate sh 24 NULLCMD=: 25 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which 26 # is contrary to our usage. Disable this feature. 27 alias -g '${1+"$@"}'='"$@"' 28 setopt NO_GLOB_SUBST 29else $as_nop 30 case `(set -o) 2>/dev/null` in #( 31 *posix*) : 32 set -o posix ;; #( 33 *) : 34 ;; 35esac 36fi 37 38 39 40# Reset variables that may have inherited troublesome values from 41# the environment. 42 43# IFS needs to be set, to space, tab, and newline, in precisely that order. 44# (If _AS_PATH_WALK were called with IFS unset, it would have the 45# side effect of setting IFS to empty, thus disabling word splitting.) 46# Quoting is to prevent editors from complaining about space-tab. 47as_nl=' 48' 49export as_nl 50IFS=" "" $as_nl" 51 52PS1='$ ' 53PS2='> ' 54PS4='+ ' 55 56# Ensure predictable behavior from utilities with locale-dependent output. 57LC_ALL=C 58export LC_ALL 59LANGUAGE=C 60export LANGUAGE 61 62# We cannot yet rely on "unset" to work, but we need these variables 63# to be unset--not just set to an empty or harmless value--now, to 64# avoid bugs in old shells (e.g. pre-3.0 UWIN ksh). This construct 65# also avoids known problems related to "unset" and subshell syntax 66# in other old shells (e.g. bash 2.01 and pdksh 5.2.14). 67for as_var in BASH_ENV ENV MAIL MAILPATH CDPATH 68do eval test \${$as_var+y} \ 69 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : 70done 71 72# Ensure that fds 0, 1, and 2 are open. 73if (exec 3>&0) 2>/dev/null; then :; else exec 0</dev/null; fi 74if (exec 3>&1) 2>/dev/null; then :; else exec 1>/dev/null; fi 75if (exec 3>&2) ; then :; else exec 2>/dev/null; fi 76 77# The user is always right. 78if ${PATH_SEPARATOR+false} :; then 79 PATH_SEPARATOR=: 80 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { 81 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || 82 PATH_SEPARATOR=';' 83 } 84fi 85 86 87# Find who we are. Look in the path if we contain no directory separator. 88as_myself= 89case $0 in #(( 90 *[\\/]* ) as_myself=$0 ;; 91 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 92for as_dir in $PATH 93do 94 IFS=$as_save_IFS 95 case $as_dir in #((( 96 '') as_dir=./ ;; 97 */) ;; 98 *) as_dir=$as_dir/ ;; 99 esac 100 test -r "$as_dir$0" && as_myself=$as_dir$0 && break 101 done 102IFS=$as_save_IFS 103 104 ;; 105esac 106# We did not find ourselves, most probably we were run as `sh COMMAND' 107# in which case we are not to be found in the path. 108if test "x$as_myself" = x; then 109 as_myself=$0 110fi 111if test ! -f "$as_myself"; then 112 printf "%s\n" "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 113 exit 1 114fi 115 116 117# Use a proper internal environment variable to ensure we don't fall 118 # into an infinite loop, continuously re-executing ourselves. 119 if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then 120 _as_can_reexec=no; export _as_can_reexec; 121 # We cannot yet assume a decent shell, so we have to provide a 122# neutralization value for shells without unset; and this also 123# works around shells that cannot unset nonexistent variables. 124# Preserve -v and -x to the replacement shell. 125BASH_ENV=/dev/null 126ENV=/dev/null 127(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV 128case $- in # (((( 129 *v*x* | *x*v* ) as_opts=-vx ;; 130 *v* ) as_opts=-v ;; 131 *x* ) as_opts=-x ;; 132 * ) as_opts= ;; 133esac 134exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} 135# Admittedly, this is quite paranoid, since all the known shells bail 136# out after a failed `exec'. 137printf "%s\n" "$0: could not re-execute with $CONFIG_SHELL" >&2 138exit 255 139 fi 140 # We don't want this to propagate to other subprocesses. 141 { _as_can_reexec=; unset _as_can_reexec;} 142if test "x$CONFIG_SHELL" = x; then 143 as_bourne_compatible="as_nop=: 144if test \${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1 145then : 146 emulate sh 147 NULLCMD=: 148 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which 149 # is contrary to our usage. Disable this feature. 150 alias -g '\${1+\"\$@\"}'='\"\$@\"' 151 setopt NO_GLOB_SUBST 152else \$as_nop 153 case \`(set -o) 2>/dev/null\` in #( 154 *posix*) : 155 set -o posix ;; #( 156 *) : 157 ;; 158esac 159fi 160" 161 as_required="as_fn_return () { (exit \$1); } 162as_fn_success () { as_fn_return 0; } 163as_fn_failure () { as_fn_return 1; } 164as_fn_ret_success () { return 0; } 165as_fn_ret_failure () { return 1; } 166 167exitcode=0 168as_fn_success || { exitcode=1; echo as_fn_success failed.; } 169as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } 170as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } 171as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } 172if ( set x; as_fn_ret_success y && test x = \"\$1\" ) 173then : 174 175else \$as_nop 176 exitcode=1; echo positional parameters were not saved. 177fi 178test x\$exitcode = x0 || exit 1 179blah=\$(echo \$(echo blah)) 180test x\"\$blah\" = xblah || exit 1 181test -x / || exit 1" 182 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO 183 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO 184 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && 185 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 186test \$(( 1 + 1 )) = 2 || exit 1" 187 if (eval "$as_required") 2>/dev/null 188then : 189 as_have_required=yes 190else $as_nop 191 as_have_required=no 192fi 193 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null 194then : 195 196else $as_nop 197 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 198as_found=false 199for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH 200do 201 IFS=$as_save_IFS 202 case $as_dir in #((( 203 '') as_dir=./ ;; 204 */) ;; 205 *) as_dir=$as_dir/ ;; 206 esac 207 as_found=: 208 case $as_dir in #( 209 /*) 210 for as_base in sh bash ksh sh5; do 211 # Try only shells that exist, to save several forks. 212 as_shell=$as_dir$as_base 213 if { test -f "$as_shell" || test -f "$as_shell.exe"; } && 214 as_run=a "$as_shell" -c "$as_bourne_compatible""$as_required" 2>/dev/null 215then : 216 CONFIG_SHELL=$as_shell as_have_required=yes 217 if as_run=a "$as_shell" -c "$as_bourne_compatible""$as_suggested" 2>/dev/null 218then : 219 break 2 220fi 221fi 222 done;; 223 esac 224 as_found=false 225done 226IFS=$as_save_IFS 227if $as_found 228then : 229 230else $as_nop 231 if { test -f "$SHELL" || test -f "$SHELL.exe"; } && 232 as_run=a "$SHELL" -c "$as_bourne_compatible""$as_required" 2>/dev/null 233then : 234 CONFIG_SHELL=$SHELL as_have_required=yes 235fi 236fi 237 238 239 if test "x$CONFIG_SHELL" != x 240then : 241 export CONFIG_SHELL 242 # We cannot yet assume a decent shell, so we have to provide a 243# neutralization value for shells without unset; and this also 244# works around shells that cannot unset nonexistent variables. 245# Preserve -v and -x to the replacement shell. 246BASH_ENV=/dev/null 247ENV=/dev/null 248(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV 249case $- in # (((( 250 *v*x* | *x*v* ) as_opts=-vx ;; 251 *v* ) as_opts=-v ;; 252 *x* ) as_opts=-x ;; 253 * ) as_opts= ;; 254esac 255exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} 256# Admittedly, this is quite paranoid, since all the known shells bail 257# out after a failed `exec'. 258printf "%s\n" "$0: could not re-execute with $CONFIG_SHELL" >&2 259exit 255 260fi 261 262 if test x$as_have_required = xno 263then : 264 printf "%s\n" "$0: This script requires a shell more modern than all" 265 printf "%s\n" "$0: the shells that I found on your system." 266 if test ${ZSH_VERSION+y} ; then 267 printf "%s\n" "$0: In particular, zsh $ZSH_VERSION has bugs and should" 268 printf "%s\n" "$0: be upgraded to zsh 4.3.4 or later." 269 else 270 printf "%s\n" "$0: Please tell bug-autoconf@gnu.org and 271$0: openssh-unix-dev@mindrot.org about your system, 272$0: including any error possibly output before this 273$0: message. Then install a modern shell, or manually run 274$0: the script under such a shell if you do have one." 275 fi 276 exit 1 277fi 278fi 279fi 280SHELL=${CONFIG_SHELL-/bin/sh} 281export SHELL 282# Unset more variables known to interfere with behavior of common tools. 283CLICOLOR_FORCE= GREP_OPTIONS= 284unset CLICOLOR_FORCE GREP_OPTIONS 285 286## --------------------- ## 287## M4sh Shell Functions. ## 288## --------------------- ## 289# as_fn_unset VAR 290# --------------- 291# Portably unset VAR. 292as_fn_unset () 293{ 294 { eval $1=; unset $1;} 295} 296as_unset=as_fn_unset 297 298 299# as_fn_set_status STATUS 300# ----------------------- 301# Set $? to STATUS, without forking. 302as_fn_set_status () 303{ 304 return $1 305} # as_fn_set_status 306 307# as_fn_exit STATUS 308# ----------------- 309# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. 310as_fn_exit () 311{ 312 set +e 313 as_fn_set_status $1 314 exit $1 315} # as_fn_exit 316# as_fn_nop 317# --------- 318# Do nothing but, unlike ":", preserve the value of $?. 319as_fn_nop () 320{ 321 return $? 322} 323as_nop=as_fn_nop 324 325# as_fn_mkdir_p 326# ------------- 327# Create "$as_dir" as a directory, including parents if necessary. 328as_fn_mkdir_p () 329{ 330 331 case $as_dir in #( 332 -*) as_dir=./$as_dir;; 333 esac 334 test -d "$as_dir" || eval $as_mkdir_p || { 335 as_dirs= 336 while :; do 337 case $as_dir in #( 338 *\'*) as_qdir=`printf "%s\n" "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( 339 *) as_qdir=$as_dir;; 340 esac 341 as_dirs="'$as_qdir' $as_dirs" 342 as_dir=`$as_dirname -- "$as_dir" || 343$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 344 X"$as_dir" : 'X\(//\)[^/]' \| \ 345 X"$as_dir" : 'X\(//\)$' \| \ 346 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || 347printf "%s\n" X"$as_dir" | 348 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 349 s//\1/ 350 q 351 } 352 /^X\(\/\/\)[^/].*/{ 353 s//\1/ 354 q 355 } 356 /^X\(\/\/\)$/{ 357 s//\1/ 358 q 359 } 360 /^X\(\/\).*/{ 361 s//\1/ 362 q 363 } 364 s/.*/./; q'` 365 test -d "$as_dir" && break 366 done 367 test -z "$as_dirs" || eval "mkdir $as_dirs" 368 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" 369 370 371} # as_fn_mkdir_p 372 373# as_fn_executable_p FILE 374# ----------------------- 375# Test if FILE is an executable regular file. 376as_fn_executable_p () 377{ 378 test -f "$1" && test -x "$1" 379} # as_fn_executable_p 380# as_fn_append VAR VALUE 381# ---------------------- 382# Append the text in VALUE to the end of the definition contained in VAR. Take 383# advantage of any shell optimizations that allow amortized linear growth over 384# repeated appends, instead of the typical quadratic growth present in naive 385# implementations. 386if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null 387then : 388 eval 'as_fn_append () 389 { 390 eval $1+=\$2 391 }' 392else $as_nop 393 as_fn_append () 394 { 395 eval $1=\$$1\$2 396 } 397fi # as_fn_append 398 399# as_fn_arith ARG... 400# ------------------ 401# Perform arithmetic evaluation on the ARGs, and store the result in the 402# global $as_val. Take advantage of shells that can avoid forks. The arguments 403# must be portable across $(()) and expr. 404if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null 405then : 406 eval 'as_fn_arith () 407 { 408 as_val=$(( $* )) 409 }' 410else $as_nop 411 as_fn_arith () 412 { 413 as_val=`expr "$@" || test $? -eq 1` 414 } 415fi # as_fn_arith 416 417# as_fn_nop 418# --------- 419# Do nothing but, unlike ":", preserve the value of $?. 420as_fn_nop () 421{ 422 return $? 423} 424as_nop=as_fn_nop 425 426# as_fn_error STATUS ERROR [LINENO LOG_FD] 427# ---------------------------------------- 428# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are 429# provided, also output the error to LOG_FD, referencing LINENO. Then exit the 430# script with STATUS, using 1 if that was 0. 431as_fn_error () 432{ 433 as_status=$1; test $as_status -eq 0 && as_status=1 434 if test "$4"; then 435 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 436 printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 437 fi 438 printf "%s\n" "$as_me: error: $2" >&2 439 as_fn_exit $as_status 440} # as_fn_error 441 442if expr a : '\(a\)' >/dev/null 2>&1 && 443 test "X`expr 00001 : '.*\(...\)'`" = X001; then 444 as_expr=expr 445else 446 as_expr=false 447fi 448 449if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then 450 as_basename=basename 451else 452 as_basename=false 453fi 454 455if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then 456 as_dirname=dirname 457else 458 as_dirname=false 459fi 460 461as_me=`$as_basename -- "$0" || 462$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ 463 X"$0" : 'X\(//\)$' \| \ 464 X"$0" : 'X\(/\)' \| . 2>/dev/null || 465printf "%s\n" X/"$0" | 466 sed '/^.*\/\([^/][^/]*\)\/*$/{ 467 s//\1/ 468 q 469 } 470 /^X\/\(\/\/\)$/{ 471 s//\1/ 472 q 473 } 474 /^X\/\(\/\).*/{ 475 s//\1/ 476 q 477 } 478 s/.*/./; q'` 479 480# Avoid depending upon Character Ranges. 481as_cr_letters='abcdefghijklmnopqrstuvwxyz' 482as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' 483as_cr_Letters=$as_cr_letters$as_cr_LETTERS 484as_cr_digits='0123456789' 485as_cr_alnum=$as_cr_Letters$as_cr_digits 486 487 488 as_lineno_1=$LINENO as_lineno_1a=$LINENO 489 as_lineno_2=$LINENO as_lineno_2a=$LINENO 490 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && 491 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { 492 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) 493 sed -n ' 494 p 495 /[$]LINENO/= 496 ' <$as_myself | 497 sed ' 498 s/[$]LINENO.*/&-/ 499 t lineno 500 b 501 :lineno 502 N 503 :loop 504 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ 505 t loop 506 s/-\n.*// 507 ' >$as_me.lineno && 508 chmod +x "$as_me.lineno" || 509 { printf "%s\n" "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } 510 511 # If we had to re-execute with $CONFIG_SHELL, we're ensured to have 512 # already done that, so ensure we don't try to do so again and fall 513 # in an infinite loop. This has already happened in practice. 514 _as_can_reexec=no; export _as_can_reexec 515 # Don't try to exec as it changes $[0], causing all sort of problems 516 # (the dirname of $[0] is not the place where we might find the 517 # original and so on. Autoconf is especially sensitive to this). 518 . "./$as_me.lineno" 519 # Exit status is that of the last command. 520 exit 521} 522 523 524# Determine whether it's possible to make 'echo' print without a newline. 525# These variables are no longer used directly by Autoconf, but are AC_SUBSTed 526# for compatibility with existing Makefiles. 527ECHO_C= ECHO_N= ECHO_T= 528case `echo -n x` in #((((( 529-n*) 530 case `echo 'xy\c'` in 531 *c*) ECHO_T=' ';; # ECHO_T is single tab character. 532 xy) ECHO_C='\c';; 533 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null 534 ECHO_T=' ';; 535 esac;; 536*) 537 ECHO_N='-n';; 538esac 539 540# For backward compatibility with old third-party macros, we provide 541# the shell variables $as_echo and $as_echo_n. New code should use 542# AS_ECHO(["message"]) and AS_ECHO_N(["message"]), respectively. 543as_echo='printf %s\n' 544as_echo_n='printf %s' 545 546 547rm -f conf$$ conf$$.exe conf$$.file 548if test -d conf$$.dir; then 549 rm -f conf$$.dir/conf$$.file 550else 551 rm -f conf$$.dir 552 mkdir conf$$.dir 2>/dev/null 553fi 554if (echo >conf$$.file) 2>/dev/null; then 555 if ln -s conf$$.file conf$$ 2>/dev/null; then 556 as_ln_s='ln -s' 557 # ... but there are two gotchas: 558 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. 559 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. 560 # In both cases, we have to default to `cp -pR'. 561 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || 562 as_ln_s='cp -pR' 563 elif ln conf$$.file conf$$ 2>/dev/null; then 564 as_ln_s=ln 565 else 566 as_ln_s='cp -pR' 567 fi 568else 569 as_ln_s='cp -pR' 570fi 571rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file 572rmdir conf$$.dir 2>/dev/null 573 574if mkdir -p . 2>/dev/null; then 575 as_mkdir_p='mkdir -p "$as_dir"' 576else 577 test -d ./-p && rmdir ./-p 578 as_mkdir_p=false 579fi 580 581as_test_x='test -x' 582as_executable_p=as_fn_executable_p 583 584# Sed expression to map a string onto a valid CPP name. 585as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" 586 587# Sed expression to map a string onto a valid variable name. 588as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" 589 590 591test -n "$DJDIR" || exec 7<&0 </dev/null 592exec 6>&1 593 594# Name of the host. 595# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, 596# so uname gets run too. 597ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` 598 599# 600# Initializations. 601# 602ac_default_prefix=/usr/local 603ac_clean_files= 604ac_config_libobj_dir=. 605LIBOBJS= 606cross_compiling=no 607subdirs= 608MFLAGS= 609MAKEFLAGS= 610 611# Identity of this package. 612PACKAGE_NAME='OpenSSH' 613PACKAGE_TARNAME='openssh' 614PACKAGE_VERSION='Portable' 615PACKAGE_STRING='OpenSSH Portable' 616PACKAGE_BUGREPORT='openssh-unix-dev@mindrot.org' 617PACKAGE_URL='' 618 619ac_unique_file="ssh.c" 620# Factoring default headers for most tests. 621ac_includes_default="\ 622#include <stddef.h> 623#ifdef HAVE_STDIO_H 624# include <stdio.h> 625#endif 626#ifdef HAVE_STDLIB_H 627# include <stdlib.h> 628#endif 629#ifdef HAVE_STRING_H 630# include <string.h> 631#endif 632#ifdef HAVE_INTTYPES_H 633# include <inttypes.h> 634#endif 635#ifdef HAVE_STDINT_H 636# include <stdint.h> 637#endif 638#ifdef HAVE_STRINGS_H 639# include <strings.h> 640#endif 641#ifdef HAVE_SYS_TYPES_H 642# include <sys/types.h> 643#endif 644#ifdef HAVE_SYS_STAT_H 645# include <sys/stat.h> 646#endif 647#ifdef HAVE_UNISTD_H 648# include <unistd.h> 649#endif" 650 651ac_header_c_list= 652ac_subst_vars='LTLIBOBJS 653CFLAGS_NOPIE 654LDFLAGS_NOPIE 655DROPBEARCONVERT 656DROPBEARKEY 657DBCLIENT 658DROPBEAR 659CONCH 660PUTTYGEN 661PLINK 662DEPEND 663UNSUPPORTED_ALGORITHMS 664TEST_MALLOC_OPTIONS 665TEST_SSH_UTF8 666TEST_SSH_IPV6 667piddir 668user_path 669mansubdir 670MANTYPE 671XAUTH_PATH 672STRIP_OPT 673xauth_path 674PRIVSEP_PATH 675CHANNELLIBS 676K5LIBS 677GSSLIBS 678KRB5CONF 679SSHDLIBS 680SSH_PRIVSEP_USER 681LIBFIDO2 682SK_DUMMY_LIBRARY 683OPENSSL_BIN 684openssl_bin 685PICFLAG 686LIBEDIT 687LDNSCONFIG 688LIBOBJS 689LD 690PATH_PASSWD_PROG 691STARTUP_SCRIPT_SHELL 692MAKE_PACKAGE_SUPPORTED 693PATH_USERADD_PROG 694PATH_GROUPADD_PROG 695MANFMT 696TEST_SHELL 697PKGCONFIG 698MANDOC 699NROFF 700GROFF 701SH 702TEST_MINUS_S_SH 703SED 704KILL 705CAT 706ac_ct_AR 707AR 708MKDIR_P 709EGREP 710GREP 711INSTALL_DATA 712INSTALL_SCRIPT 713INSTALL_PROGRAM 714RANLIB 715CPP 716AWK 717host_os 718host_vendor 719host_cpu 720host 721build_os 722build_vendor 723build_cpu 724build 725OBJEXT 726EXEEXT 727ac_ct_CC 728CPPFLAGS 729LDFLAGS 730CFLAGS 731CC 732target_alias 733host_alias 734build_alias 735LIBS 736ECHO_T 737ECHO_N 738ECHO_C 739DEFS 740mandir 741localedir 742libdir 743psdir 744pdfdir 745dvidir 746htmldir 747infodir 748docdir 749oldincludedir 750includedir 751runstatedir 752localstatedir 753sharedstatedir 754sysconfdir 755datadir 756datarootdir 757libexecdir 758sbindir 759bindir 760program_transform_name 761prefix 762exec_prefix 763PACKAGE_URL 764PACKAGE_BUGREPORT 765PACKAGE_STRING 766PACKAGE_VERSION 767PACKAGE_TARNAME 768PACKAGE_NAME 769PATH_SEPARATOR 770SHELL' 771ac_subst_files='' 772ac_user_opts=' 773enable_option_checking 774enable_largefile 775with_openssl 776with_stackprotect 777with_hardening 778with_retpoline 779with_rpath 780with_cflags 781with_cflags_after 782with_cppflags 783with_ldflags 784with_ldflags_after 785with_libs 786with_Werror 787with_solaris_contracts 788with_solaris_projects 789with_solaris_privs 790with_osfsia 791with_zlib 792with_zlib_version_check 793with_ldns 794with_libedit 795with_audit 796with_pie 797enable_pkcs11 798enable_security_key 799with_security_key_builtin 800enable_dsa_keys 801with_ssl_dir 802with_openssl_header_check 803with_ssl_engine 804with_prngd_port 805with_prngd_socket 806with_pam 807with_pam_service 808with_privsep_user 809with_sandbox 810with_selinux 811with_kerberos5 812with_privsep_path 813with_xauth 814enable_strip 815with_maildir 816with_mantype 817with_shadow 818with_ipaddr_display 819enable_etc_default_login 820with_default_path 821with_superuser_path 822with_4in6 823with_bsd_auth 824with_pid_dir 825enable_fd_passing 826enable_lastlog 827enable_utmp 828enable_utmpx 829enable_wtmp 830enable_wtmpx 831enable_libutil 832enable_pututline 833enable_pututxline 834with_lastlog 835' 836 ac_precious_vars='build_alias 837host_alias 838target_alias 839CC 840CFLAGS 841LDFLAGS 842LIBS 843CPPFLAGS 844CPP' 845 846 847# Initialize some variables set by options. 848ac_init_help= 849ac_init_version=false 850ac_unrecognized_opts= 851ac_unrecognized_sep= 852# The variables have the same names as the options, with 853# dashes changed to underlines. 854cache_file=/dev/null 855exec_prefix=NONE 856no_create= 857no_recursion= 858prefix=NONE 859program_prefix=NONE 860program_suffix=NONE 861program_transform_name=s,x,x, 862silent= 863site= 864srcdir= 865verbose= 866x_includes=NONE 867x_libraries=NONE 868 869# Installation directory options. 870# These are left unexpanded so users can "make install exec_prefix=/foo" 871# and all the variables that are supposed to be based on exec_prefix 872# by default will actually change. 873# Use braces instead of parens because sh, perl, etc. also accept them. 874# (The list follows the same order as the GNU Coding Standards.) 875bindir='${exec_prefix}/bin' 876sbindir='${exec_prefix}/sbin' 877libexecdir='${exec_prefix}/libexec' 878datarootdir='${prefix}/share' 879datadir='${datarootdir}' 880sysconfdir='${prefix}/etc' 881sharedstatedir='${prefix}/com' 882localstatedir='${prefix}/var' 883runstatedir='${localstatedir}/run' 884includedir='${prefix}/include' 885oldincludedir='/usr/include' 886docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' 887infodir='${datarootdir}/info' 888htmldir='${docdir}' 889dvidir='${docdir}' 890pdfdir='${docdir}' 891psdir='${docdir}' 892libdir='${exec_prefix}/lib' 893localedir='${datarootdir}/locale' 894mandir='${datarootdir}/man' 895 896ac_prev= 897ac_dashdash= 898for ac_option 899do 900 # If the previous option needs an argument, assign it. 901 if test -n "$ac_prev"; then 902 eval $ac_prev=\$ac_option 903 ac_prev= 904 continue 905 fi 906 907 case $ac_option in 908 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; 909 *=) ac_optarg= ;; 910 *) ac_optarg=yes ;; 911 esac 912 913 case $ac_dashdash$ac_option in 914 --) 915 ac_dashdash=yes ;; 916 917 -bindir | --bindir | --bindi | --bind | --bin | --bi) 918 ac_prev=bindir ;; 919 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) 920 bindir=$ac_optarg ;; 921 922 -build | --build | --buil | --bui | --bu) 923 ac_prev=build_alias ;; 924 -build=* | --build=* | --buil=* | --bui=* | --bu=*) 925 build_alias=$ac_optarg ;; 926 927 -cache-file | --cache-file | --cache-fil | --cache-fi \ 928 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) 929 ac_prev=cache_file ;; 930 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ 931 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) 932 cache_file=$ac_optarg ;; 933 934 --config-cache | -C) 935 cache_file=config.cache ;; 936 937 -datadir | --datadir | --datadi | --datad) 938 ac_prev=datadir ;; 939 -datadir=* | --datadir=* | --datadi=* | --datad=*) 940 datadir=$ac_optarg ;; 941 942 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ 943 | --dataroo | --dataro | --datar) 944 ac_prev=datarootdir ;; 945 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ 946 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) 947 datarootdir=$ac_optarg ;; 948 949 -disable-* | --disable-*) 950 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` 951 # Reject names that are not valid shell variable names. 952 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 953 as_fn_error $? "invalid feature name: \`$ac_useropt'" 954 ac_useropt_orig=$ac_useropt 955 ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'` 956 case $ac_user_opts in 957 *" 958"enable_$ac_useropt" 959"*) ;; 960 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" 961 ac_unrecognized_sep=', ';; 962 esac 963 eval enable_$ac_useropt=no ;; 964 965 -docdir | --docdir | --docdi | --doc | --do) 966 ac_prev=docdir ;; 967 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) 968 docdir=$ac_optarg ;; 969 970 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) 971 ac_prev=dvidir ;; 972 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) 973 dvidir=$ac_optarg ;; 974 975 -enable-* | --enable-*) 976 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` 977 # Reject names that are not valid shell variable names. 978 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 979 as_fn_error $? "invalid feature name: \`$ac_useropt'" 980 ac_useropt_orig=$ac_useropt 981 ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'` 982 case $ac_user_opts in 983 *" 984"enable_$ac_useropt" 985"*) ;; 986 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" 987 ac_unrecognized_sep=', ';; 988 esac 989 eval enable_$ac_useropt=\$ac_optarg ;; 990 991 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ 992 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ 993 | --exec | --exe | --ex) 994 ac_prev=exec_prefix ;; 995 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ 996 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ 997 | --exec=* | --exe=* | --ex=*) 998 exec_prefix=$ac_optarg ;; 999 1000 -gas | --gas | --ga | --g) 1001 # Obsolete; use --with-gas. 1002 with_gas=yes ;; 1003 1004 -help | --help | --hel | --he | -h) 1005 ac_init_help=long ;; 1006 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) 1007 ac_init_help=recursive ;; 1008 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) 1009 ac_init_help=short ;; 1010 1011 -host | --host | --hos | --ho) 1012 ac_prev=host_alias ;; 1013 -host=* | --host=* | --hos=* | --ho=*) 1014 host_alias=$ac_optarg ;; 1015 1016 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) 1017 ac_prev=htmldir ;; 1018 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ 1019 | --ht=*) 1020 htmldir=$ac_optarg ;; 1021 1022 -includedir | --includedir | --includedi | --included | --include \ 1023 | --includ | --inclu | --incl | --inc) 1024 ac_prev=includedir ;; 1025 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ 1026 | --includ=* | --inclu=* | --incl=* | --inc=*) 1027 includedir=$ac_optarg ;; 1028 1029 -infodir | --infodir | --infodi | --infod | --info | --inf) 1030 ac_prev=infodir ;; 1031 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) 1032 infodir=$ac_optarg ;; 1033 1034 -libdir | --libdir | --libdi | --libd) 1035 ac_prev=libdir ;; 1036 -libdir=* | --libdir=* | --libdi=* | --libd=*) 1037 libdir=$ac_optarg ;; 1038 1039 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ 1040 | --libexe | --libex | --libe) 1041 ac_prev=libexecdir ;; 1042 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ 1043 | --libexe=* | --libex=* | --libe=*) 1044 libexecdir=$ac_optarg ;; 1045 1046 -localedir | --localedir | --localedi | --localed | --locale) 1047 ac_prev=localedir ;; 1048 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) 1049 localedir=$ac_optarg ;; 1050 1051 -localstatedir | --localstatedir | --localstatedi | --localstated \ 1052 | --localstate | --localstat | --localsta | --localst | --locals) 1053 ac_prev=localstatedir ;; 1054 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ 1055 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) 1056 localstatedir=$ac_optarg ;; 1057 1058 -mandir | --mandir | --mandi | --mand | --man | --ma | --m) 1059 ac_prev=mandir ;; 1060 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) 1061 mandir=$ac_optarg ;; 1062 1063 -nfp | --nfp | --nf) 1064 # Obsolete; use --without-fp. 1065 with_fp=no ;; 1066 1067 -no-create | --no-create | --no-creat | --no-crea | --no-cre \ 1068 | --no-cr | --no-c | -n) 1069 no_create=yes ;; 1070 1071 -no-recursion | --no-recursion | --no-recursio | --no-recursi \ 1072 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) 1073 no_recursion=yes ;; 1074 1075 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ 1076 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ 1077 | --oldin | --oldi | --old | --ol | --o) 1078 ac_prev=oldincludedir ;; 1079 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ 1080 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ 1081 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) 1082 oldincludedir=$ac_optarg ;; 1083 1084 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) 1085 ac_prev=prefix ;; 1086 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) 1087 prefix=$ac_optarg ;; 1088 1089 -program-prefix | --program-prefix | --program-prefi | --program-pref \ 1090 | --program-pre | --program-pr | --program-p) 1091 ac_prev=program_prefix ;; 1092 -program-prefix=* | --program-prefix=* | --program-prefi=* \ 1093 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) 1094 program_prefix=$ac_optarg ;; 1095 1096 -program-suffix | --program-suffix | --program-suffi | --program-suff \ 1097 | --program-suf | --program-su | --program-s) 1098 ac_prev=program_suffix ;; 1099 -program-suffix=* | --program-suffix=* | --program-suffi=* \ 1100 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) 1101 program_suffix=$ac_optarg ;; 1102 1103 -program-transform-name | --program-transform-name \ 1104 | --program-transform-nam | --program-transform-na \ 1105 | --program-transform-n | --program-transform- \ 1106 | --program-transform | --program-transfor \ 1107 | --program-transfo | --program-transf \ 1108 | --program-trans | --program-tran \ 1109 | --progr-tra | --program-tr | --program-t) 1110 ac_prev=program_transform_name ;; 1111 -program-transform-name=* | --program-transform-name=* \ 1112 | --program-transform-nam=* | --program-transform-na=* \ 1113 | --program-transform-n=* | --program-transform-=* \ 1114 | --program-transform=* | --program-transfor=* \ 1115 | --program-transfo=* | --program-transf=* \ 1116 | --program-trans=* | --program-tran=* \ 1117 | --progr-tra=* | --program-tr=* | --program-t=*) 1118 program_transform_name=$ac_optarg ;; 1119 1120 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) 1121 ac_prev=pdfdir ;; 1122 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) 1123 pdfdir=$ac_optarg ;; 1124 1125 -psdir | --psdir | --psdi | --psd | --ps) 1126 ac_prev=psdir ;; 1127 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) 1128 psdir=$ac_optarg ;; 1129 1130 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 1131 | -silent | --silent | --silen | --sile | --sil) 1132 silent=yes ;; 1133 1134 -runstatedir | --runstatedir | --runstatedi | --runstated \ 1135 | --runstate | --runstat | --runsta | --runst | --runs \ 1136 | --run | --ru | --r) 1137 ac_prev=runstatedir ;; 1138 -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \ 1139 | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \ 1140 | --run=* | --ru=* | --r=*) 1141 runstatedir=$ac_optarg ;; 1142 1143 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) 1144 ac_prev=sbindir ;; 1145 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ 1146 | --sbi=* | --sb=*) 1147 sbindir=$ac_optarg ;; 1148 1149 -sharedstatedir | --sharedstatedir | --sharedstatedi \ 1150 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ 1151 | --sharedst | --shareds | --shared | --share | --shar \ 1152 | --sha | --sh) 1153 ac_prev=sharedstatedir ;; 1154 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ 1155 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ 1156 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ 1157 | --sha=* | --sh=*) 1158 sharedstatedir=$ac_optarg ;; 1159 1160 -site | --site | --sit) 1161 ac_prev=site ;; 1162 -site=* | --site=* | --sit=*) 1163 site=$ac_optarg ;; 1164 1165 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) 1166 ac_prev=srcdir ;; 1167 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) 1168 srcdir=$ac_optarg ;; 1169 1170 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ 1171 | --syscon | --sysco | --sysc | --sys | --sy) 1172 ac_prev=sysconfdir ;; 1173 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ 1174 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) 1175 sysconfdir=$ac_optarg ;; 1176 1177 -target | --target | --targe | --targ | --tar | --ta | --t) 1178 ac_prev=target_alias ;; 1179 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) 1180 target_alias=$ac_optarg ;; 1181 1182 -v | -verbose | --verbose | --verbos | --verbo | --verb) 1183 verbose=yes ;; 1184 1185 -version | --version | --versio | --versi | --vers | -V) 1186 ac_init_version=: ;; 1187 1188 -with-* | --with-*) 1189 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` 1190 # Reject names that are not valid shell variable names. 1191 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1192 as_fn_error $? "invalid package name: \`$ac_useropt'" 1193 ac_useropt_orig=$ac_useropt 1194 ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'` 1195 case $ac_user_opts in 1196 *" 1197"with_$ac_useropt" 1198"*) ;; 1199 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" 1200 ac_unrecognized_sep=', ';; 1201 esac 1202 eval with_$ac_useropt=\$ac_optarg ;; 1203 1204 -without-* | --without-*) 1205 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` 1206 # Reject names that are not valid shell variable names. 1207 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1208 as_fn_error $? "invalid package name: \`$ac_useropt'" 1209 ac_useropt_orig=$ac_useropt 1210 ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'` 1211 case $ac_user_opts in 1212 *" 1213"with_$ac_useropt" 1214"*) ;; 1215 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" 1216 ac_unrecognized_sep=', ';; 1217 esac 1218 eval with_$ac_useropt=no ;; 1219 1220 --x) 1221 # Obsolete; use --with-x. 1222 with_x=yes ;; 1223 1224 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ 1225 | --x-incl | --x-inc | --x-in | --x-i) 1226 ac_prev=x_includes ;; 1227 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ 1228 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) 1229 x_includes=$ac_optarg ;; 1230 1231 -x-libraries | --x-libraries | --x-librarie | --x-librari \ 1232 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) 1233 ac_prev=x_libraries ;; 1234 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ 1235 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) 1236 x_libraries=$ac_optarg ;; 1237 1238 -*) as_fn_error $? "unrecognized option: \`$ac_option' 1239Try \`$0 --help' for more information" 1240 ;; 1241 1242 *=*) 1243 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` 1244 # Reject names that are not valid shell variable names. 1245 case $ac_envvar in #( 1246 '' | [0-9]* | *[!_$as_cr_alnum]* ) 1247 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; 1248 esac 1249 eval $ac_envvar=\$ac_optarg 1250 export $ac_envvar ;; 1251 1252 *) 1253 # FIXME: should be removed in autoconf 3.0. 1254 printf "%s\n" "$as_me: WARNING: you should use --build, --host, --target" >&2 1255 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && 1256 printf "%s\n" "$as_me: WARNING: invalid host type: $ac_option" >&2 1257 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" 1258 ;; 1259 1260 esac 1261done 1262 1263if test -n "$ac_prev"; then 1264 ac_option=--`echo $ac_prev | sed 's/_/-/g'` 1265 as_fn_error $? "missing argument to $ac_option" 1266fi 1267 1268if test -n "$ac_unrecognized_opts"; then 1269 case $enable_option_checking in 1270 no) ;; 1271 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; 1272 *) printf "%s\n" "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; 1273 esac 1274fi 1275 1276# Check all directory arguments for consistency. 1277for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ 1278 datadir sysconfdir sharedstatedir localstatedir includedir \ 1279 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ 1280 libdir localedir mandir runstatedir 1281do 1282 eval ac_val=\$$ac_var 1283 # Remove trailing slashes. 1284 case $ac_val in 1285 */ ) 1286 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` 1287 eval $ac_var=\$ac_val;; 1288 esac 1289 # Be sure to have absolute directory names. 1290 case $ac_val in 1291 [\\/$]* | ?:[\\/]* ) continue;; 1292 NONE | '' ) case $ac_var in *prefix ) continue;; esac;; 1293 esac 1294 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" 1295done 1296 1297# There might be people who depend on the old broken behavior: `$host' 1298# used to hold the argument of --host etc. 1299# FIXME: To remove some day. 1300build=$build_alias 1301host=$host_alias 1302target=$target_alias 1303 1304# FIXME: To remove some day. 1305if test "x$host_alias" != x; then 1306 if test "x$build_alias" = x; then 1307 cross_compiling=maybe 1308 elif test "x$build_alias" != "x$host_alias"; then 1309 cross_compiling=yes 1310 fi 1311fi 1312 1313ac_tool_prefix= 1314test -n "$host_alias" && ac_tool_prefix=$host_alias- 1315 1316test "$silent" = yes && exec 6>/dev/null 1317 1318 1319ac_pwd=`pwd` && test -n "$ac_pwd" && 1320ac_ls_di=`ls -di .` && 1321ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || 1322 as_fn_error $? "working directory cannot be determined" 1323test "X$ac_ls_di" = "X$ac_pwd_ls_di" || 1324 as_fn_error $? "pwd does not report name of working directory" 1325 1326 1327# Find the source files, if location was not specified. 1328if test -z "$srcdir"; then 1329 ac_srcdir_defaulted=yes 1330 # Try the directory containing this script, then the parent directory. 1331 ac_confdir=`$as_dirname -- "$as_myself" || 1332$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 1333 X"$as_myself" : 'X\(//\)[^/]' \| \ 1334 X"$as_myself" : 'X\(//\)$' \| \ 1335 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || 1336printf "%s\n" X"$as_myself" | 1337 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 1338 s//\1/ 1339 q 1340 } 1341 /^X\(\/\/\)[^/].*/{ 1342 s//\1/ 1343 q 1344 } 1345 /^X\(\/\/\)$/{ 1346 s//\1/ 1347 q 1348 } 1349 /^X\(\/\).*/{ 1350 s//\1/ 1351 q 1352 } 1353 s/.*/./; q'` 1354 srcdir=$ac_confdir 1355 if test ! -r "$srcdir/$ac_unique_file"; then 1356 srcdir=.. 1357 fi 1358else 1359 ac_srcdir_defaulted=no 1360fi 1361if test ! -r "$srcdir/$ac_unique_file"; then 1362 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." 1363 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" 1364fi 1365ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" 1366ac_abs_confdir=`( 1367 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" 1368 pwd)` 1369# When building in place, set srcdir=. 1370if test "$ac_abs_confdir" = "$ac_pwd"; then 1371 srcdir=. 1372fi 1373# Remove unnecessary trailing slashes from srcdir. 1374# Double slashes in file names in object file debugging info 1375# mess up M-x gdb in Emacs. 1376case $srcdir in 1377*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; 1378esac 1379for ac_var in $ac_precious_vars; do 1380 eval ac_env_${ac_var}_set=\${${ac_var}+set} 1381 eval ac_env_${ac_var}_value=\$${ac_var} 1382 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} 1383 eval ac_cv_env_${ac_var}_value=\$${ac_var} 1384done 1385 1386# 1387# Report the --help message. 1388# 1389if test "$ac_init_help" = "long"; then 1390 # Omit some internal or obsolete options to make the list less imposing. 1391 # This message is too long to be a string in the A/UX 3.1 sh. 1392 cat <<_ACEOF 1393\`configure' configures OpenSSH Portable to adapt to many kinds of systems. 1394 1395Usage: $0 [OPTION]... [VAR=VALUE]... 1396 1397To assign environment variables (e.g., CC, CFLAGS...), specify them as 1398VAR=VALUE. See below for descriptions of some of the useful variables. 1399 1400Defaults for the options are specified in brackets. 1401 1402Configuration: 1403 -h, --help display this help and exit 1404 --help=short display options specific to this package 1405 --help=recursive display the short help of all the included packages 1406 -V, --version display version information and exit 1407 -q, --quiet, --silent do not print \`checking ...' messages 1408 --cache-file=FILE cache test results in FILE [disabled] 1409 -C, --config-cache alias for \`--cache-file=config.cache' 1410 -n, --no-create do not create output files 1411 --srcdir=DIR find the sources in DIR [configure dir or \`..'] 1412 1413Installation directories: 1414 --prefix=PREFIX install architecture-independent files in PREFIX 1415 [$ac_default_prefix] 1416 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX 1417 [PREFIX] 1418 1419By default, \`make install' will install all the files in 1420\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify 1421an installation prefix other than \`$ac_default_prefix' using \`--prefix', 1422for instance \`--prefix=\$HOME'. 1423 1424For better control, use the options below. 1425 1426Fine tuning of the installation directories: 1427 --bindir=DIR user executables [EPREFIX/bin] 1428 --sbindir=DIR system admin executables [EPREFIX/sbin] 1429 --libexecdir=DIR program executables [EPREFIX/libexec] 1430 --sysconfdir=DIR read-only single-machine data [PREFIX/etc] 1431 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] 1432 --localstatedir=DIR modifiable single-machine data [PREFIX/var] 1433 --runstatedir=DIR modifiable per-process data [LOCALSTATEDIR/run] 1434 --libdir=DIR object code libraries [EPREFIX/lib] 1435 --includedir=DIR C header files [PREFIX/include] 1436 --oldincludedir=DIR C header files for non-gcc [/usr/include] 1437 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] 1438 --datadir=DIR read-only architecture-independent data [DATAROOTDIR] 1439 --infodir=DIR info documentation [DATAROOTDIR/info] 1440 --localedir=DIR locale-dependent data [DATAROOTDIR/locale] 1441 --mandir=DIR man documentation [DATAROOTDIR/man] 1442 --docdir=DIR documentation root [DATAROOTDIR/doc/openssh] 1443 --htmldir=DIR html documentation [DOCDIR] 1444 --dvidir=DIR dvi documentation [DOCDIR] 1445 --pdfdir=DIR pdf documentation [DOCDIR] 1446 --psdir=DIR ps documentation [DOCDIR] 1447_ACEOF 1448 1449 cat <<\_ACEOF 1450 1451System types: 1452 --build=BUILD configure for building on BUILD [guessed] 1453 --host=HOST cross-compile to build programs to run on HOST [BUILD] 1454_ACEOF 1455fi 1456 1457if test -n "$ac_init_help"; then 1458 case $ac_init_help in 1459 short | recursive ) echo "Configuration of OpenSSH Portable:";; 1460 esac 1461 cat <<\_ACEOF 1462 1463Optional Features: 1464 --disable-option-checking ignore unrecognized --enable/--with options 1465 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) 1466 --enable-FEATURE[=ARG] include FEATURE [ARG=yes] 1467 --disable-largefile omit support for large files 1468 --disable-pkcs11 disable PKCS#11 support code [no] 1469 --disable-security-key disable U2F/FIDO support code no 1470 --enable-dsa-keys enable DSA key support no 1471 --disable-strip Disable calling strip(1) on install 1472 --disable-etc-default-login Disable using PATH from /etc/default/login no 1473 --disable-fd-passing disable file descriptor passsing no 1474 --disable-lastlog disable use of lastlog even if detected no 1475 --disable-utmp disable use of utmp even if detected no 1476 --disable-utmpx disable use of utmpx even if detected no 1477 --disable-wtmp disable use of wtmp even if detected no 1478 --disable-wtmpx disable use of wtmpx even if detected no 1479 --disable-libutil disable use of libutil (login() etc.) no 1480 --disable-pututline disable use of pututline() etc. (uwtmp) no 1481 --disable-pututxline disable use of pututxline() etc. (uwtmpx) no 1482 1483Optional Packages: 1484 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] 1485 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) 1486 --without-openssl Disable use of OpenSSL; use only limited internal crypto **EXPERIMENTAL** 1487 --without-stackprotect Don't use compiler's stack protection 1488 --without-hardening Don't use toolchain hardening flags 1489 --without-retpoline Enable retpoline spectre mitigation 1490 --without-rpath Disable auto-added -R linker paths 1491 --with-cflags Specify additional flags to pass to compiler 1492 --with-cflags-after Specify additional flags to pass to compiler after configure 1493 --with-cppflags Specify additional flags to pass to preprocessor 1494 --with-ldflags Specify additional flags to pass to linker 1495 --with-ldflags-after Specify additional flags to pass to linker after configure 1496 --with-libs Specify additional libraries to link with 1497 --with-Werror Build main code with -Werror 1498 --with-solaris-contracts Enable Solaris process contracts (experimental) 1499 --with-solaris-projects Enable Solaris projects (experimental) 1500 --with-solaris-privs Enable Solaris/Illumos privileges (experimental) 1501 --with-osfsia Enable Digital Unix SIA 1502 --with-zlib=PATH Use zlib in PATH 1503 --without-zlib-version-check Disable zlib version check 1504 --with-ldns[=PATH] Use ldns for DNSSEC support (optionally in PATH) 1505 --with-libedit[=PATH] Enable libedit support for sftp 1506 --with-audit=module Enable audit support (modules=debug,bsm,linux) 1507 --with-pie Build Position Independent Executables if possible 1508 --with-security-key-builtin include builtin U2F/FIDO support 1509 --with-ssl-dir=PATH Specify path to OpenSSL installation 1510 --without-openssl-header-check Disable OpenSSL version consistency check 1511 --with-ssl-engine Enable OpenSSL (hardware) ENGINE support 1512 --with-prngd-port=PORT read entropy from PRNGD/EGD TCP localhost:PORT 1513 --with-prngd-socket=FILE read entropy from PRNGD/EGD socket FILE (default=/var/run/egd-pool) 1514 --with-pam Enable PAM support 1515 --with-pam-service=name Specify PAM service name 1516 --with-privsep-user=user Specify non-privileged user for privilege separation 1517 --with-sandbox=style Specify privilege separation sandbox (no, capsicum, darwin, rlimit, seccomp_filter, systrace, pledge) 1518 --with-selinux Enable SELinux support 1519 --with-kerberos5=PATH Enable Kerberos 5 support 1520 --with-privsep-path=xxx Path for privilege separation chroot (default=/var/empty) 1521 --with-xauth=PATH Specify path to xauth program 1522 --with-maildir=/path/to/mail Specify your system mail directory 1523 --with-mantype=man|cat|doc Set man page type 1524 --without-shadow Disable shadow password support 1525 --with-ipaddr-display Use ip address instead of hostname in $DISPLAY 1526 --with-default-path= Specify default $PATH environment for server 1527 --with-superuser-path= Specify different path for super-user 1528 --with-4in6 Check for and convert IPv4 in IPv6 mapped addresses 1529 --with-bsd-auth Enable BSD auth support 1530 --with-pid-dir=PATH Specify location of sshd.pid file 1531 --with-lastlog=FILE|DIR specify lastlog location common locations 1532 1533Some influential environment variables: 1534 CC C compiler command 1535 CFLAGS C compiler flags 1536 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a 1537 nonstandard directory <lib dir> 1538 LIBS libraries to pass to the linker, e.g. -l<library> 1539 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if 1540 you have headers in a nonstandard directory <include dir> 1541 CPP C preprocessor 1542 1543Use these variables to override the choices made by `configure' or to help 1544it to find libraries and programs with nonstandard names/locations. 1545 1546Report bugs to <openssh-unix-dev@mindrot.org>. 1547_ACEOF 1548ac_status=$? 1549fi 1550 1551if test "$ac_init_help" = "recursive"; then 1552 # If there are subdirs, report their specific --help. 1553 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue 1554 test -d "$ac_dir" || 1555 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || 1556 continue 1557 ac_builddir=. 1558 1559case "$ac_dir" in 1560.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; 1561*) 1562 ac_dir_suffix=/`printf "%s\n" "$ac_dir" | sed 's|^\.[\\/]||'` 1563 # A ".." for each directory in $ac_dir_suffix. 1564 ac_top_builddir_sub=`printf "%s\n" "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` 1565 case $ac_top_builddir_sub in 1566 "") ac_top_builddir_sub=. ac_top_build_prefix= ;; 1567 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; 1568 esac ;; 1569esac 1570ac_abs_top_builddir=$ac_pwd 1571ac_abs_builddir=$ac_pwd$ac_dir_suffix 1572# for backward compatibility: 1573ac_top_builddir=$ac_top_build_prefix 1574 1575case $srcdir in 1576 .) # We are building in place. 1577 ac_srcdir=. 1578 ac_top_srcdir=$ac_top_builddir_sub 1579 ac_abs_top_srcdir=$ac_pwd ;; 1580 [\\/]* | ?:[\\/]* ) # Absolute name. 1581 ac_srcdir=$srcdir$ac_dir_suffix; 1582 ac_top_srcdir=$srcdir 1583 ac_abs_top_srcdir=$srcdir ;; 1584 *) # Relative name. 1585 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix 1586 ac_top_srcdir=$ac_top_build_prefix$srcdir 1587 ac_abs_top_srcdir=$ac_pwd/$srcdir ;; 1588esac 1589ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix 1590 1591 cd "$ac_dir" || { ac_status=$?; continue; } 1592 # Check for configure.gnu first; this name is used for a wrapper for 1593 # Metaconfig's "Configure" on case-insensitive file systems. 1594 if test -f "$ac_srcdir/configure.gnu"; then 1595 echo && 1596 $SHELL "$ac_srcdir/configure.gnu" --help=recursive 1597 elif test -f "$ac_srcdir/configure"; then 1598 echo && 1599 $SHELL "$ac_srcdir/configure" --help=recursive 1600 else 1601 printf "%s\n" "$as_me: WARNING: no configuration information is in $ac_dir" >&2 1602 fi || ac_status=$? 1603 cd "$ac_pwd" || { ac_status=$?; break; } 1604 done 1605fi 1606 1607test -n "$ac_init_help" && exit $ac_status 1608if $ac_init_version; then 1609 cat <<\_ACEOF 1610OpenSSH configure Portable 1611generated by GNU Autoconf 2.71 1612 1613Copyright (C) 2021 Free Software Foundation, Inc. 1614This configure script is free software; the Free Software Foundation 1615gives unlimited permission to copy, distribute and modify it. 1616_ACEOF 1617 exit 1618fi 1619 1620## ------------------------ ## 1621## Autoconf initialization. ## 1622## ------------------------ ## 1623 1624# ac_fn_c_try_compile LINENO 1625# -------------------------- 1626# Try to compile conftest.$ac_ext, and return whether this succeeded. 1627ac_fn_c_try_compile () 1628{ 1629 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 1630 rm -f conftest.$ac_objext conftest.beam 1631 if { { ac_try="$ac_compile" 1632case "(($ac_try" in 1633 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 1634 *) ac_try_echo=$ac_try;; 1635esac 1636eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 1637printf "%s\n" "$ac_try_echo"; } >&5 1638 (eval "$ac_compile") 2>conftest.err 1639 ac_status=$? 1640 if test -s conftest.err; then 1641 grep -v '^ *+' conftest.err >conftest.er1 1642 cat conftest.er1 >&5 1643 mv -f conftest.er1 conftest.err 1644 fi 1645 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 1646 test $ac_status = 0; } && { 1647 test -z "$ac_c_werror_flag" || 1648 test ! -s conftest.err 1649 } && test -s conftest.$ac_objext 1650then : 1651 ac_retval=0 1652else $as_nop 1653 printf "%s\n" "$as_me: failed program was:" >&5 1654sed 's/^/| /' conftest.$ac_ext >&5 1655 1656 ac_retval=1 1657fi 1658 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 1659 as_fn_set_status $ac_retval 1660 1661} # ac_fn_c_try_compile 1662 1663# ac_fn_c_try_run LINENO 1664# ---------------------- 1665# Try to run conftest.$ac_ext, and return whether this succeeded. Assumes that 1666# executables *can* be run. 1667ac_fn_c_try_run () 1668{ 1669 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 1670 if { { ac_try="$ac_link" 1671case "(($ac_try" in 1672 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 1673 *) ac_try_echo=$ac_try;; 1674esac 1675eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 1676printf "%s\n" "$ac_try_echo"; } >&5 1677 (eval "$ac_link") 2>&5 1678 ac_status=$? 1679 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 1680 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' 1681 { { case "(($ac_try" in 1682 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 1683 *) ac_try_echo=$ac_try;; 1684esac 1685eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 1686printf "%s\n" "$ac_try_echo"; } >&5 1687 (eval "$ac_try") 2>&5 1688 ac_status=$? 1689 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 1690 test $ac_status = 0; }; } 1691then : 1692 ac_retval=0 1693else $as_nop 1694 printf "%s\n" "$as_me: program exited with status $ac_status" >&5 1695 printf "%s\n" "$as_me: failed program was:" >&5 1696sed 's/^/| /' conftest.$ac_ext >&5 1697 1698 ac_retval=$ac_status 1699fi 1700 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 1701 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 1702 as_fn_set_status $ac_retval 1703 1704} # ac_fn_c_try_run 1705 1706# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES 1707# ------------------------------------------------------- 1708# Tests whether HEADER exists and can be compiled using the include files in 1709# INCLUDES, setting the cache variable VAR accordingly. 1710ac_fn_c_check_header_compile () 1711{ 1712 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 1713 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 1714printf %s "checking for $2... " >&6; } 1715if eval test \${$3+y} 1716then : 1717 printf %s "(cached) " >&6 1718else $as_nop 1719 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 1720/* end confdefs.h. */ 1721$4 1722#include <$2> 1723_ACEOF 1724if ac_fn_c_try_compile "$LINENO" 1725then : 1726 eval "$3=yes" 1727else $as_nop 1728 eval "$3=no" 1729fi 1730rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 1731fi 1732eval ac_res=\$$3 1733 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 1734printf "%s\n" "$ac_res" >&6; } 1735 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 1736 1737} # ac_fn_c_check_header_compile 1738 1739# ac_fn_c_try_cpp LINENO 1740# ---------------------- 1741# Try to preprocess conftest.$ac_ext, and return whether this succeeded. 1742ac_fn_c_try_cpp () 1743{ 1744 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 1745 if { { ac_try="$ac_cpp conftest.$ac_ext" 1746case "(($ac_try" in 1747 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 1748 *) ac_try_echo=$ac_try;; 1749esac 1750eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 1751printf "%s\n" "$ac_try_echo"; } >&5 1752 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err 1753 ac_status=$? 1754 if test -s conftest.err; then 1755 grep -v '^ *+' conftest.err >conftest.er1 1756 cat conftest.er1 >&5 1757 mv -f conftest.er1 conftest.err 1758 fi 1759 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 1760 test $ac_status = 0; } > conftest.i && { 1761 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || 1762 test ! -s conftest.err 1763 } 1764then : 1765 ac_retval=0 1766else $as_nop 1767 printf "%s\n" "$as_me: failed program was:" >&5 1768sed 's/^/| /' conftest.$ac_ext >&5 1769 1770 ac_retval=1 1771fi 1772 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 1773 as_fn_set_status $ac_retval 1774 1775} # ac_fn_c_try_cpp 1776 1777# ac_fn_check_decl LINENO SYMBOL VAR INCLUDES EXTRA-OPTIONS FLAG-VAR 1778# ------------------------------------------------------------------ 1779# Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR 1780# accordingly. Pass EXTRA-OPTIONS to the compiler, using FLAG-VAR. 1781ac_fn_check_decl () 1782{ 1783 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 1784 as_decl_name=`echo $2|sed 's/ *(.*//'` 1785 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5 1786printf %s "checking whether $as_decl_name is declared... " >&6; } 1787if eval test \${$3+y} 1788then : 1789 printf %s "(cached) " >&6 1790else $as_nop 1791 as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'` 1792 eval ac_save_FLAGS=\$$6 1793 as_fn_append $6 " $5" 1794 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 1795/* end confdefs.h. */ 1796$4 1797int 1798main (void) 1799{ 1800#ifndef $as_decl_name 1801#ifdef __cplusplus 1802 (void) $as_decl_use; 1803#else 1804 (void) $as_decl_name; 1805#endif 1806#endif 1807 1808 ; 1809 return 0; 1810} 1811_ACEOF 1812if ac_fn_c_try_compile "$LINENO" 1813then : 1814 eval "$3=yes" 1815else $as_nop 1816 eval "$3=no" 1817fi 1818rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 1819 eval $6=\$ac_save_FLAGS 1820 1821fi 1822eval ac_res=\$$3 1823 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 1824printf "%s\n" "$ac_res" >&6; } 1825 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 1826 1827} # ac_fn_check_decl 1828 1829# ac_fn_c_try_link LINENO 1830# ----------------------- 1831# Try to link conftest.$ac_ext, and return whether this succeeded. 1832ac_fn_c_try_link () 1833{ 1834 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 1835 rm -f conftest.$ac_objext conftest.beam conftest$ac_exeext 1836 if { { ac_try="$ac_link" 1837case "(($ac_try" in 1838 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 1839 *) ac_try_echo=$ac_try;; 1840esac 1841eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 1842printf "%s\n" "$ac_try_echo"; } >&5 1843 (eval "$ac_link") 2>conftest.err 1844 ac_status=$? 1845 if test -s conftest.err; then 1846 grep -v '^ *+' conftest.err >conftest.er1 1847 cat conftest.er1 >&5 1848 mv -f conftest.er1 conftest.err 1849 fi 1850 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 1851 test $ac_status = 0; } && { 1852 test -z "$ac_c_werror_flag" || 1853 test ! -s conftest.err 1854 } && test -s conftest$ac_exeext && { 1855 test "$cross_compiling" = yes || 1856 test -x conftest$ac_exeext 1857 } 1858then : 1859 ac_retval=0 1860else $as_nop 1861 printf "%s\n" "$as_me: failed program was:" >&5 1862sed 's/^/| /' conftest.$ac_ext >&5 1863 1864 ac_retval=1 1865fi 1866 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information 1867 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would 1868 # interfere with the next link command; also delete a directory that is 1869 # left behind by Apple's compiler. We do this before executing the actions. 1870 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 1871 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 1872 as_fn_set_status $ac_retval 1873 1874} # ac_fn_c_try_link 1875 1876# ac_fn_c_check_func LINENO FUNC VAR 1877# ---------------------------------- 1878# Tests whether FUNC exists, setting the cache variable VAR accordingly 1879ac_fn_c_check_func () 1880{ 1881 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 1882 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 1883printf %s "checking for $2... " >&6; } 1884if eval test \${$3+y} 1885then : 1886 printf %s "(cached) " >&6 1887else $as_nop 1888 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 1889/* end confdefs.h. */ 1890/* Define $2 to an innocuous variant, in case <limits.h> declares $2. 1891 For example, HP-UX 11i <limits.h> declares gettimeofday. */ 1892#define $2 innocuous_$2 1893 1894/* System header to define __stub macros and hopefully few prototypes, 1895 which can conflict with char $2 (); below. */ 1896 1897#include <limits.h> 1898#undef $2 1899 1900/* Override any GCC internal prototype to avoid an error. 1901 Use char because int might match the return type of a GCC 1902 builtin and then its argument prototype would still apply. */ 1903#ifdef __cplusplus 1904extern "C" 1905#endif 1906char $2 (); 1907/* The GNU C library defines this for functions which it implements 1908 to always fail with ENOSYS. Some functions are actually named 1909 something starting with __ and the normal name is an alias. */ 1910#if defined __stub_$2 || defined __stub___$2 1911choke me 1912#endif 1913 1914int 1915main (void) 1916{ 1917return $2 (); 1918 ; 1919 return 0; 1920} 1921_ACEOF 1922if ac_fn_c_try_link "$LINENO" 1923then : 1924 eval "$3=yes" 1925else $as_nop 1926 eval "$3=no" 1927fi 1928rm -f core conftest.err conftest.$ac_objext conftest.beam \ 1929 conftest$ac_exeext conftest.$ac_ext 1930fi 1931eval ac_res=\$$3 1932 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 1933printf "%s\n" "$ac_res" >&6; } 1934 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 1935 1936} # ac_fn_c_check_func 1937 1938# ac_fn_c_check_type LINENO TYPE VAR INCLUDES 1939# ------------------------------------------- 1940# Tests whether TYPE exists after having included INCLUDES, setting cache 1941# variable VAR accordingly. 1942ac_fn_c_check_type () 1943{ 1944 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 1945 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 1946printf %s "checking for $2... " >&6; } 1947if eval test \${$3+y} 1948then : 1949 printf %s "(cached) " >&6 1950else $as_nop 1951 eval "$3=no" 1952 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 1953/* end confdefs.h. */ 1954$4 1955int 1956main (void) 1957{ 1958if (sizeof ($2)) 1959 return 0; 1960 ; 1961 return 0; 1962} 1963_ACEOF 1964if ac_fn_c_try_compile "$LINENO" 1965then : 1966 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 1967/* end confdefs.h. */ 1968$4 1969int 1970main (void) 1971{ 1972if (sizeof (($2))) 1973 return 0; 1974 ; 1975 return 0; 1976} 1977_ACEOF 1978if ac_fn_c_try_compile "$LINENO" 1979then : 1980 1981else $as_nop 1982 eval "$3=yes" 1983fi 1984rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 1985fi 1986rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 1987fi 1988eval ac_res=\$$3 1989 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 1990printf "%s\n" "$ac_res" >&6; } 1991 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 1992 1993} # ac_fn_c_check_type 1994 1995# ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES 1996# ---------------------------------------------------- 1997# Tries to find if the field MEMBER exists in type AGGR, after including 1998# INCLUDES, setting cache variable VAR accordingly. 1999ac_fn_c_check_member () 2000{ 2001 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2002 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5 2003printf %s "checking for $2.$3... " >&6; } 2004if eval test \${$4+y} 2005then : 2006 printf %s "(cached) " >&6 2007else $as_nop 2008 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2009/* end confdefs.h. */ 2010$5 2011int 2012main (void) 2013{ 2014static $2 ac_aggr; 2015if (ac_aggr.$3) 2016return 0; 2017 ; 2018 return 0; 2019} 2020_ACEOF 2021if ac_fn_c_try_compile "$LINENO" 2022then : 2023 eval "$4=yes" 2024else $as_nop 2025 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2026/* end confdefs.h. */ 2027$5 2028int 2029main (void) 2030{ 2031static $2 ac_aggr; 2032if (sizeof ac_aggr.$3) 2033return 0; 2034 ; 2035 return 0; 2036} 2037_ACEOF 2038if ac_fn_c_try_compile "$LINENO" 2039then : 2040 eval "$4=yes" 2041else $as_nop 2042 eval "$4=no" 2043fi 2044rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 2045fi 2046rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 2047fi 2048eval ac_res=\$$4 2049 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2050printf "%s\n" "$ac_res" >&6; } 2051 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2052 2053} # ac_fn_c_check_member 2054 2055# ac_fn_c_compute_int LINENO EXPR VAR INCLUDES 2056# -------------------------------------------- 2057# Tries to find the compile-time value of EXPR in a program that includes 2058# INCLUDES, setting VAR accordingly. Returns whether the value could be 2059# computed 2060ac_fn_c_compute_int () 2061{ 2062 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2063 if test "$cross_compiling" = yes; then 2064 # Depending upon the size, compute the lo and hi bounds. 2065cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2066/* end confdefs.h. */ 2067$4 2068int 2069main (void) 2070{ 2071static int test_array [1 - 2 * !(($2) >= 0)]; 2072test_array [0] = 0; 2073return test_array [0]; 2074 2075 ; 2076 return 0; 2077} 2078_ACEOF 2079if ac_fn_c_try_compile "$LINENO" 2080then : 2081 ac_lo=0 ac_mid=0 2082 while :; do 2083 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2084/* end confdefs.h. */ 2085$4 2086int 2087main (void) 2088{ 2089static int test_array [1 - 2 * !(($2) <= $ac_mid)]; 2090test_array [0] = 0; 2091return test_array [0]; 2092 2093 ; 2094 return 0; 2095} 2096_ACEOF 2097if ac_fn_c_try_compile "$LINENO" 2098then : 2099 ac_hi=$ac_mid; break 2100else $as_nop 2101 as_fn_arith $ac_mid + 1 && ac_lo=$as_val 2102 if test $ac_lo -le $ac_mid; then 2103 ac_lo= ac_hi= 2104 break 2105 fi 2106 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val 2107fi 2108rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 2109 done 2110else $as_nop 2111 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2112/* end confdefs.h. */ 2113$4 2114int 2115main (void) 2116{ 2117static int test_array [1 - 2 * !(($2) < 0)]; 2118test_array [0] = 0; 2119return test_array [0]; 2120 2121 ; 2122 return 0; 2123} 2124_ACEOF 2125if ac_fn_c_try_compile "$LINENO" 2126then : 2127 ac_hi=-1 ac_mid=-1 2128 while :; do 2129 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2130/* end confdefs.h. */ 2131$4 2132int 2133main (void) 2134{ 2135static int test_array [1 - 2 * !(($2) >= $ac_mid)]; 2136test_array [0] = 0; 2137return test_array [0]; 2138 2139 ; 2140 return 0; 2141} 2142_ACEOF 2143if ac_fn_c_try_compile "$LINENO" 2144then : 2145 ac_lo=$ac_mid; break 2146else $as_nop 2147 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val 2148 if test $ac_mid -le $ac_hi; then 2149 ac_lo= ac_hi= 2150 break 2151 fi 2152 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val 2153fi 2154rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 2155 done 2156else $as_nop 2157 ac_lo= ac_hi= 2158fi 2159rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 2160fi 2161rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 2162# Binary search between lo and hi bounds. 2163while test "x$ac_lo" != "x$ac_hi"; do 2164 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val 2165 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2166/* end confdefs.h. */ 2167$4 2168int 2169main (void) 2170{ 2171static int test_array [1 - 2 * !(($2) <= $ac_mid)]; 2172test_array [0] = 0; 2173return test_array [0]; 2174 2175 ; 2176 return 0; 2177} 2178_ACEOF 2179if ac_fn_c_try_compile "$LINENO" 2180then : 2181 ac_hi=$ac_mid 2182else $as_nop 2183 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val 2184fi 2185rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 2186done 2187case $ac_lo in #(( 2188?*) eval "$3=\$ac_lo"; ac_retval=0 ;; 2189'') ac_retval=1 ;; 2190esac 2191 else 2192 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2193/* end confdefs.h. */ 2194$4 2195static long int longval (void) { return $2; } 2196static unsigned long int ulongval (void) { return $2; } 2197#include <stdio.h> 2198#include <stdlib.h> 2199int 2200main (void) 2201{ 2202 2203 FILE *f = fopen ("conftest.val", "w"); 2204 if (! f) 2205 return 1; 2206 if (($2) < 0) 2207 { 2208 long int i = longval (); 2209 if (i != ($2)) 2210 return 1; 2211 fprintf (f, "%ld", i); 2212 } 2213 else 2214 { 2215 unsigned long int i = ulongval (); 2216 if (i != ($2)) 2217 return 1; 2218 fprintf (f, "%lu", i); 2219 } 2220 /* Do not output a trailing newline, as this causes \r\n confusion 2221 on some platforms. */ 2222 return ferror (f) || fclose (f) != 0; 2223 2224 ; 2225 return 0; 2226} 2227_ACEOF 2228if ac_fn_c_try_run "$LINENO" 2229then : 2230 echo >>conftest.val; read $3 <conftest.val; ac_retval=0 2231else $as_nop 2232 ac_retval=1 2233fi 2234rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 2235 conftest.$ac_objext conftest.beam conftest.$ac_ext 2236rm -f conftest.val 2237 2238 fi 2239 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2240 as_fn_set_status $ac_retval 2241 2242} # ac_fn_c_compute_int 2243ac_configure_args_raw= 2244for ac_arg 2245do 2246 case $ac_arg in 2247 *\'*) 2248 ac_arg=`printf "%s\n" "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; 2249 esac 2250 as_fn_append ac_configure_args_raw " '$ac_arg'" 2251done 2252 2253case $ac_configure_args_raw in 2254 *$as_nl*) 2255 ac_safe_unquote= ;; 2256 *) 2257 ac_unsafe_z='|&;<>()$`\\"*?[ '' ' # This string ends in space, tab. 2258 ac_unsafe_a="$ac_unsafe_z#~" 2259 ac_safe_unquote="s/ '\\([^$ac_unsafe_a][^$ac_unsafe_z]*\\)'/ \\1/g" 2260 ac_configure_args_raw=` printf "%s\n" "$ac_configure_args_raw" | sed "$ac_safe_unquote"`;; 2261esac 2262 2263cat >config.log <<_ACEOF 2264This file contains any messages produced by compilers while 2265running configure, to aid debugging if configure makes a mistake. 2266 2267It was created by OpenSSH $as_me Portable, which was 2268generated by GNU Autoconf 2.71. Invocation command line was 2269 2270 $ $0$ac_configure_args_raw 2271 2272_ACEOF 2273exec 5>>config.log 2274{ 2275cat <<_ASUNAME 2276## --------- ## 2277## Platform. ## 2278## --------- ## 2279 2280hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` 2281uname -m = `(uname -m) 2>/dev/null || echo unknown` 2282uname -r = `(uname -r) 2>/dev/null || echo unknown` 2283uname -s = `(uname -s) 2>/dev/null || echo unknown` 2284uname -v = `(uname -v) 2>/dev/null || echo unknown` 2285 2286/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` 2287/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` 2288 2289/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` 2290/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` 2291/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` 2292/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` 2293/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` 2294/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` 2295/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` 2296 2297_ASUNAME 2298 2299as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 2300for as_dir in $PATH 2301do 2302 IFS=$as_save_IFS 2303 case $as_dir in #((( 2304 '') as_dir=./ ;; 2305 */) ;; 2306 *) as_dir=$as_dir/ ;; 2307 esac 2308 printf "%s\n" "PATH: $as_dir" 2309 done 2310IFS=$as_save_IFS 2311 2312} >&5 2313 2314cat >&5 <<_ACEOF 2315 2316 2317## ----------- ## 2318## Core tests. ## 2319## ----------- ## 2320 2321_ACEOF 2322 2323 2324# Keep a trace of the command line. 2325# Strip out --no-create and --no-recursion so they do not pile up. 2326# Strip out --silent because we don't want to record it for future runs. 2327# Also quote any args containing shell meta-characters. 2328# Make two passes to allow for proper duplicate-argument suppression. 2329ac_configure_args= 2330ac_configure_args0= 2331ac_configure_args1= 2332ac_must_keep_next=false 2333for ac_pass in 1 2 2334do 2335 for ac_arg 2336 do 2337 case $ac_arg in 2338 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; 2339 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 2340 | -silent | --silent | --silen | --sile | --sil) 2341 continue ;; 2342 *\'*) 2343 ac_arg=`printf "%s\n" "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; 2344 esac 2345 case $ac_pass in 2346 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; 2347 2) 2348 as_fn_append ac_configure_args1 " '$ac_arg'" 2349 if test $ac_must_keep_next = true; then 2350 ac_must_keep_next=false # Got value, back to normal. 2351 else 2352 case $ac_arg in 2353 *=* | --config-cache | -C | -disable-* | --disable-* \ 2354 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ 2355 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ 2356 | -with-* | --with-* | -without-* | --without-* | --x) 2357 case "$ac_configure_args0 " in 2358 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; 2359 esac 2360 ;; 2361 -* ) ac_must_keep_next=true ;; 2362 esac 2363 fi 2364 as_fn_append ac_configure_args " '$ac_arg'" 2365 ;; 2366 esac 2367 done 2368done 2369{ ac_configure_args0=; unset ac_configure_args0;} 2370{ ac_configure_args1=; unset ac_configure_args1;} 2371 2372# When interrupted or exit'd, cleanup temporary files, and complete 2373# config.log. We remove comments because anyway the quotes in there 2374# would cause problems or look ugly. 2375# WARNING: Use '\'' to represent an apostrophe within the trap. 2376# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. 2377trap 'exit_status=$? 2378 # Sanitize IFS. 2379 IFS=" "" $as_nl" 2380 # Save into config.log some information that might help in debugging. 2381 { 2382 echo 2383 2384 printf "%s\n" "## ---------------- ## 2385## Cache variables. ## 2386## ---------------- ##" 2387 echo 2388 # The following way of writing the cache mishandles newlines in values, 2389( 2390 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do 2391 eval ac_val=\$$ac_var 2392 case $ac_val in #( 2393 *${as_nl}*) 2394 case $ac_var in #( 2395 *_cv_*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 2396printf "%s\n" "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; 2397 esac 2398 case $ac_var in #( 2399 _ | IFS | as_nl) ;; #( 2400 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( 2401 *) { eval $ac_var=; unset $ac_var;} ;; 2402 esac ;; 2403 esac 2404 done 2405 (set) 2>&1 | 2406 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( 2407 *${as_nl}ac_space=\ *) 2408 sed -n \ 2409 "s/'\''/'\''\\\\'\'''\''/g; 2410 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" 2411 ;; #( 2412 *) 2413 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" 2414 ;; 2415 esac | 2416 sort 2417) 2418 echo 2419 2420 printf "%s\n" "## ----------------- ## 2421## Output variables. ## 2422## ----------------- ##" 2423 echo 2424 for ac_var in $ac_subst_vars 2425 do 2426 eval ac_val=\$$ac_var 2427 case $ac_val in 2428 *\'\''*) ac_val=`printf "%s\n" "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; 2429 esac 2430 printf "%s\n" "$ac_var='\''$ac_val'\''" 2431 done | sort 2432 echo 2433 2434 if test -n "$ac_subst_files"; then 2435 printf "%s\n" "## ------------------- ## 2436## File substitutions. ## 2437## ------------------- ##" 2438 echo 2439 for ac_var in $ac_subst_files 2440 do 2441 eval ac_val=\$$ac_var 2442 case $ac_val in 2443 *\'\''*) ac_val=`printf "%s\n" "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; 2444 esac 2445 printf "%s\n" "$ac_var='\''$ac_val'\''" 2446 done | sort 2447 echo 2448 fi 2449 2450 if test -s confdefs.h; then 2451 printf "%s\n" "## ----------- ## 2452## confdefs.h. ## 2453## ----------- ##" 2454 echo 2455 cat confdefs.h 2456 echo 2457 fi 2458 test "$ac_signal" != 0 && 2459 printf "%s\n" "$as_me: caught signal $ac_signal" 2460 printf "%s\n" "$as_me: exit $exit_status" 2461 } >&5 2462 rm -f core *.core core.conftest.* && 2463 rm -f -r conftest* confdefs* conf$$* $ac_clean_files && 2464 exit $exit_status 2465' 0 2466for ac_signal in 1 2 13 15; do 2467 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal 2468done 2469ac_signal=0 2470 2471# confdefs.h avoids OS command line length limits that DEFS can exceed. 2472rm -f -r conftest* confdefs.h 2473 2474printf "%s\n" "/* confdefs.h */" > confdefs.h 2475 2476# Predefined preprocessor variables. 2477 2478printf "%s\n" "#define PACKAGE_NAME \"$PACKAGE_NAME\"" >>confdefs.h 2479 2480printf "%s\n" "#define PACKAGE_TARNAME \"$PACKAGE_TARNAME\"" >>confdefs.h 2481 2482printf "%s\n" "#define PACKAGE_VERSION \"$PACKAGE_VERSION\"" >>confdefs.h 2483 2484printf "%s\n" "#define PACKAGE_STRING \"$PACKAGE_STRING\"" >>confdefs.h 2485 2486printf "%s\n" "#define PACKAGE_BUGREPORT \"$PACKAGE_BUGREPORT\"" >>confdefs.h 2487 2488printf "%s\n" "#define PACKAGE_URL \"$PACKAGE_URL\"" >>confdefs.h 2489 2490 2491# Let the site file select an alternate cache file if it wants to. 2492# Prefer an explicitly selected file to automatically selected ones. 2493if test -n "$CONFIG_SITE"; then 2494 ac_site_files="$CONFIG_SITE" 2495elif test "x$prefix" != xNONE; then 2496 ac_site_files="$prefix/share/config.site $prefix/etc/config.site" 2497else 2498 ac_site_files="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site" 2499fi 2500 2501for ac_site_file in $ac_site_files 2502do 2503 case $ac_site_file in #( 2504 */*) : 2505 ;; #( 2506 *) : 2507 ac_site_file=./$ac_site_file ;; 2508esac 2509 if test -f "$ac_site_file" && test -r "$ac_site_file"; then 2510 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 2511printf "%s\n" "$as_me: loading site script $ac_site_file" >&6;} 2512 sed 's/^/| /' "$ac_site_file" >&5 2513 . "$ac_site_file" \ 2514 || { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 2515printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} 2516as_fn_error $? "failed to load site script $ac_site_file 2517See \`config.log' for more details" "$LINENO" 5; } 2518 fi 2519done 2520 2521if test -r "$cache_file"; then 2522 # Some versions of bash will fail to source /dev/null (special files 2523 # actually), so we avoid doing that. DJGPP emulates it as a regular file. 2524 if test /dev/null != "$cache_file" && test -f "$cache_file"; then 2525 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 2526printf "%s\n" "$as_me: loading cache $cache_file" >&6;} 2527 case $cache_file in 2528 [\\/]* | ?:[\\/]* ) . "$cache_file";; 2529 *) . "./$cache_file";; 2530 esac 2531 fi 2532else 2533 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 2534printf "%s\n" "$as_me: creating cache $cache_file" >&6;} 2535 >$cache_file 2536fi 2537 2538# Test code for whether the C compiler supports C89 (global declarations) 2539ac_c_conftest_c89_globals=' 2540/* Does the compiler advertise C89 conformance? 2541 Do not test the value of __STDC__, because some compilers set it to 0 2542 while being otherwise adequately conformant. */ 2543#if !defined __STDC__ 2544# error "Compiler does not advertise C89 conformance" 2545#endif 2546 2547#include <stddef.h> 2548#include <stdarg.h> 2549struct stat; 2550/* Most of the following tests are stolen from RCS 5.7 src/conf.sh. */ 2551struct buf { int x; }; 2552struct buf * (*rcsopen) (struct buf *, struct stat *, int); 2553static char *e (p, i) 2554 char **p; 2555 int i; 2556{ 2557 return p[i]; 2558} 2559static char *f (char * (*g) (char **, int), char **p, ...) 2560{ 2561 char *s; 2562 va_list v; 2563 va_start (v,p); 2564 s = g (p, va_arg (v,int)); 2565 va_end (v); 2566 return s; 2567} 2568 2569/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has 2570 function prototypes and stuff, but not \xHH hex character constants. 2571 These do not provoke an error unfortunately, instead are silently treated 2572 as an "x". The following induces an error, until -std is added to get 2573 proper ANSI mode. Curiously \x00 != x always comes out true, for an 2574 array size at least. It is necessary to write \x00 == 0 to get something 2575 that is true only with -std. */ 2576int osf4_cc_array ['\''\x00'\'' == 0 ? 1 : -1]; 2577 2578/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters 2579 inside strings and character constants. */ 2580#define FOO(x) '\''x'\'' 2581int xlc6_cc_array[FOO(a) == '\''x'\'' ? 1 : -1]; 2582 2583int test (int i, double x); 2584struct s1 {int (*f) (int a);}; 2585struct s2 {int (*f) (double a);}; 2586int pairnames (int, char **, int *(*)(struct buf *, struct stat *, int), 2587 int, int);' 2588 2589# Test code for whether the C compiler supports C89 (body of main). 2590ac_c_conftest_c89_main=' 2591ok |= (argc == 0 || f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]); 2592' 2593 2594# Test code for whether the C compiler supports C99 (global declarations) 2595ac_c_conftest_c99_globals=' 2596// Does the compiler advertise C99 conformance? 2597#if !defined __STDC_VERSION__ || __STDC_VERSION__ < 199901L 2598# error "Compiler does not advertise C99 conformance" 2599#endif 2600 2601#include <stdbool.h> 2602extern int puts (const char *); 2603extern int printf (const char *, ...); 2604extern int dprintf (int, const char *, ...); 2605extern void *malloc (size_t); 2606 2607// Check varargs macros. These examples are taken from C99 6.10.3.5. 2608// dprintf is used instead of fprintf to avoid needing to declare 2609// FILE and stderr. 2610#define debug(...) dprintf (2, __VA_ARGS__) 2611#define showlist(...) puts (#__VA_ARGS__) 2612#define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__)) 2613static void 2614test_varargs_macros (void) 2615{ 2616 int x = 1234; 2617 int y = 5678; 2618 debug ("Flag"); 2619 debug ("X = %d\n", x); 2620 showlist (The first, second, and third items.); 2621 report (x>y, "x is %d but y is %d", x, y); 2622} 2623 2624// Check long long types. 2625#define BIG64 18446744073709551615ull 2626#define BIG32 4294967295ul 2627#define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0) 2628#if !BIG_OK 2629 #error "your preprocessor is broken" 2630#endif 2631#if BIG_OK 2632#else 2633 #error "your preprocessor is broken" 2634#endif 2635static long long int bignum = -9223372036854775807LL; 2636static unsigned long long int ubignum = BIG64; 2637 2638struct incomplete_array 2639{ 2640 int datasize; 2641 double data[]; 2642}; 2643 2644struct named_init { 2645 int number; 2646 const wchar_t *name; 2647 double average; 2648}; 2649 2650typedef const char *ccp; 2651 2652static inline int 2653test_restrict (ccp restrict text) 2654{ 2655 // See if C++-style comments work. 2656 // Iterate through items via the restricted pointer. 2657 // Also check for declarations in for loops. 2658 for (unsigned int i = 0; *(text+i) != '\''\0'\''; ++i) 2659 continue; 2660 return 0; 2661} 2662 2663// Check varargs and va_copy. 2664static bool 2665test_varargs (const char *format, ...) 2666{ 2667 va_list args; 2668 va_start (args, format); 2669 va_list args_copy; 2670 va_copy (args_copy, args); 2671 2672 const char *str = ""; 2673 int number = 0; 2674 float fnumber = 0; 2675 2676 while (*format) 2677 { 2678 switch (*format++) 2679 { 2680 case '\''s'\'': // string 2681 str = va_arg (args_copy, const char *); 2682 break; 2683 case '\''d'\'': // int 2684 number = va_arg (args_copy, int); 2685 break; 2686 case '\''f'\'': // float 2687 fnumber = va_arg (args_copy, double); 2688 break; 2689 default: 2690 break; 2691 } 2692 } 2693 va_end (args_copy); 2694 va_end (args); 2695 2696 return *str && number && fnumber; 2697} 2698' 2699 2700# Test code for whether the C compiler supports C99 (body of main). 2701ac_c_conftest_c99_main=' 2702 // Check bool. 2703 _Bool success = false; 2704 success |= (argc != 0); 2705 2706 // Check restrict. 2707 if (test_restrict ("String literal") == 0) 2708 success = true; 2709 char *restrict newvar = "Another string"; 2710 2711 // Check varargs. 2712 success &= test_varargs ("s, d'\'' f .", "string", 65, 34.234); 2713 test_varargs_macros (); 2714 2715 // Check flexible array members. 2716 struct incomplete_array *ia = 2717 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10)); 2718 ia->datasize = 10; 2719 for (int i = 0; i < ia->datasize; ++i) 2720 ia->data[i] = i * 1.234; 2721 2722 // Check named initializers. 2723 struct named_init ni = { 2724 .number = 34, 2725 .name = L"Test wide string", 2726 .average = 543.34343, 2727 }; 2728 2729 ni.number = 58; 2730 2731 int dynamic_array[ni.number]; 2732 dynamic_array[0] = argv[0][0]; 2733 dynamic_array[ni.number - 1] = 543; 2734 2735 // work around unused variable warnings 2736 ok |= (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == '\''x'\'' 2737 || dynamic_array[ni.number - 1] != 543); 2738' 2739 2740# Test code for whether the C compiler supports C11 (global declarations) 2741ac_c_conftest_c11_globals=' 2742// Does the compiler advertise C11 conformance? 2743#if !defined __STDC_VERSION__ || __STDC_VERSION__ < 201112L 2744# error "Compiler does not advertise C11 conformance" 2745#endif 2746 2747// Check _Alignas. 2748char _Alignas (double) aligned_as_double; 2749char _Alignas (0) no_special_alignment; 2750extern char aligned_as_int; 2751char _Alignas (0) _Alignas (int) aligned_as_int; 2752 2753// Check _Alignof. 2754enum 2755{ 2756 int_alignment = _Alignof (int), 2757 int_array_alignment = _Alignof (int[100]), 2758 char_alignment = _Alignof (char) 2759}; 2760_Static_assert (0 < -_Alignof (int), "_Alignof is signed"); 2761 2762// Check _Noreturn. 2763int _Noreturn does_not_return (void) { for (;;) continue; } 2764 2765// Check _Static_assert. 2766struct test_static_assert 2767{ 2768 int x; 2769 _Static_assert (sizeof (int) <= sizeof (long int), 2770 "_Static_assert does not work in struct"); 2771 long int y; 2772}; 2773 2774// Check UTF-8 literals. 2775#define u8 syntax error! 2776char const utf8_literal[] = u8"happens to be ASCII" "another string"; 2777 2778// Check duplicate typedefs. 2779typedef long *long_ptr; 2780typedef long int *long_ptr; 2781typedef long_ptr long_ptr; 2782 2783// Anonymous structures and unions -- taken from C11 6.7.2.1 Example 1. 2784struct anonymous 2785{ 2786 union { 2787 struct { int i; int j; }; 2788 struct { int k; long int l; } w; 2789 }; 2790 int m; 2791} v1; 2792' 2793 2794# Test code for whether the C compiler supports C11 (body of main). 2795ac_c_conftest_c11_main=' 2796 _Static_assert ((offsetof (struct anonymous, i) 2797 == offsetof (struct anonymous, w.k)), 2798 "Anonymous union alignment botch"); 2799 v1.i = 2; 2800 v1.w.k = 5; 2801 ok |= v1.i != 5; 2802' 2803 2804# Test code for whether the C compiler supports C11 (complete). 2805ac_c_conftest_c11_program="${ac_c_conftest_c89_globals} 2806${ac_c_conftest_c99_globals} 2807${ac_c_conftest_c11_globals} 2808 2809int 2810main (int argc, char **argv) 2811{ 2812 int ok = 0; 2813 ${ac_c_conftest_c89_main} 2814 ${ac_c_conftest_c99_main} 2815 ${ac_c_conftest_c11_main} 2816 return ok; 2817} 2818" 2819 2820# Test code for whether the C compiler supports C99 (complete). 2821ac_c_conftest_c99_program="${ac_c_conftest_c89_globals} 2822${ac_c_conftest_c99_globals} 2823 2824int 2825main (int argc, char **argv) 2826{ 2827 int ok = 0; 2828 ${ac_c_conftest_c89_main} 2829 ${ac_c_conftest_c99_main} 2830 return ok; 2831} 2832" 2833 2834# Test code for whether the C compiler supports C89 (complete). 2835ac_c_conftest_c89_program="${ac_c_conftest_c89_globals} 2836 2837int 2838main (int argc, char **argv) 2839{ 2840 int ok = 0; 2841 ${ac_c_conftest_c89_main} 2842 return ok; 2843} 2844" 2845 2846as_fn_append ac_header_c_list " stdio.h stdio_h HAVE_STDIO_H" 2847as_fn_append ac_header_c_list " stdlib.h stdlib_h HAVE_STDLIB_H" 2848as_fn_append ac_header_c_list " string.h string_h HAVE_STRING_H" 2849as_fn_append ac_header_c_list " inttypes.h inttypes_h HAVE_INTTYPES_H" 2850as_fn_append ac_header_c_list " stdint.h stdint_h HAVE_STDINT_H" 2851as_fn_append ac_header_c_list " strings.h strings_h HAVE_STRINGS_H" 2852as_fn_append ac_header_c_list " sys/stat.h sys_stat_h HAVE_SYS_STAT_H" 2853as_fn_append ac_header_c_list " sys/types.h sys_types_h HAVE_SYS_TYPES_H" 2854as_fn_append ac_header_c_list " unistd.h unistd_h HAVE_UNISTD_H" 2855 2856# Auxiliary files required by this configure script. 2857ac_aux_files="install-sh config.guess config.sub" 2858 2859# Locations in which to look for auxiliary files. 2860ac_aux_dir_candidates="${srcdir}${PATH_SEPARATOR}${srcdir}/..${PATH_SEPARATOR}${srcdir}/../.." 2861 2862# Search for a directory containing all of the required auxiliary files, 2863# $ac_aux_files, from the $PATH-style list $ac_aux_dir_candidates. 2864# If we don't find one directory that contains all the files we need, 2865# we report the set of missing files from the *first* directory in 2866# $ac_aux_dir_candidates and give up. 2867ac_missing_aux_files="" 2868ac_first_candidate=: 2869printf "%s\n" "$as_me:${as_lineno-$LINENO}: looking for aux files: $ac_aux_files" >&5 2870as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 2871as_found=false 2872for as_dir in $ac_aux_dir_candidates 2873do 2874 IFS=$as_save_IFS 2875 case $as_dir in #((( 2876 '') as_dir=./ ;; 2877 */) ;; 2878 *) as_dir=$as_dir/ ;; 2879 esac 2880 as_found=: 2881 2882 printf "%s\n" "$as_me:${as_lineno-$LINENO}: trying $as_dir" >&5 2883 ac_aux_dir_found=yes 2884 ac_install_sh= 2885 for ac_aux in $ac_aux_files 2886 do 2887 # As a special case, if "install-sh" is required, that requirement 2888 # can be satisfied by any of "install-sh", "install.sh", or "shtool", 2889 # and $ac_install_sh is set appropriately for whichever one is found. 2890 if test x"$ac_aux" = x"install-sh" 2891 then 2892 if test -f "${as_dir}install-sh"; then 2893 printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}install-sh found" >&5 2894 ac_install_sh="${as_dir}install-sh -c" 2895 elif test -f "${as_dir}install.sh"; then 2896 printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}install.sh found" >&5 2897 ac_install_sh="${as_dir}install.sh -c" 2898 elif test -f "${as_dir}shtool"; then 2899 printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}shtool found" >&5 2900 ac_install_sh="${as_dir}shtool install -c" 2901 else 2902 ac_aux_dir_found=no 2903 if $ac_first_candidate; then 2904 ac_missing_aux_files="${ac_missing_aux_files} install-sh" 2905 else 2906 break 2907 fi 2908 fi 2909 else 2910 if test -f "${as_dir}${ac_aux}"; then 2911 printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}${ac_aux} found" >&5 2912 else 2913 ac_aux_dir_found=no 2914 if $ac_first_candidate; then 2915 ac_missing_aux_files="${ac_missing_aux_files} ${ac_aux}" 2916 else 2917 break 2918 fi 2919 fi 2920 fi 2921 done 2922 if test "$ac_aux_dir_found" = yes; then 2923 ac_aux_dir="$as_dir" 2924 break 2925 fi 2926 ac_first_candidate=false 2927 2928 as_found=false 2929done 2930IFS=$as_save_IFS 2931if $as_found 2932then : 2933 2934else $as_nop 2935 as_fn_error $? "cannot find required auxiliary files:$ac_missing_aux_files" "$LINENO" 5 2936fi 2937 2938 2939# These three variables are undocumented and unsupported, 2940# and are intended to be withdrawn in a future Autoconf release. 2941# They can cause serious problems if a builder's source tree is in a directory 2942# whose full name contains unusual characters. 2943if test -f "${ac_aux_dir}config.guess"; then 2944 ac_config_guess="$SHELL ${ac_aux_dir}config.guess" 2945fi 2946if test -f "${ac_aux_dir}config.sub"; then 2947 ac_config_sub="$SHELL ${ac_aux_dir}config.sub" 2948fi 2949if test -f "$ac_aux_dir/configure"; then 2950 ac_configure="$SHELL ${ac_aux_dir}configure" 2951fi 2952 2953# Check that the precious variables saved in the cache have kept the same 2954# value. 2955ac_cache_corrupted=false 2956for ac_var in $ac_precious_vars; do 2957 eval ac_old_set=\$ac_cv_env_${ac_var}_set 2958 eval ac_new_set=\$ac_env_${ac_var}_set 2959 eval ac_old_val=\$ac_cv_env_${ac_var}_value 2960 eval ac_new_val=\$ac_env_${ac_var}_value 2961 case $ac_old_set,$ac_new_set in 2962 set,) 2963 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 2964printf "%s\n" "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} 2965 ac_cache_corrupted=: ;; 2966 ,set) 2967 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 2968printf "%s\n" "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} 2969 ac_cache_corrupted=: ;; 2970 ,);; 2971 *) 2972 if test "x$ac_old_val" != "x$ac_new_val"; then 2973 # differences in whitespace do not lead to failure. 2974 ac_old_val_w=`echo x $ac_old_val` 2975 ac_new_val_w=`echo x $ac_new_val` 2976 if test "$ac_old_val_w" != "$ac_new_val_w"; then 2977 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 2978printf "%s\n" "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} 2979 ac_cache_corrupted=: 2980 else 2981 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 2982printf "%s\n" "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} 2983 eval $ac_var=\$ac_old_val 2984 fi 2985 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 2986printf "%s\n" "$as_me: former value: \`$ac_old_val'" >&2;} 2987 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 2988printf "%s\n" "$as_me: current value: \`$ac_new_val'" >&2;} 2989 fi;; 2990 esac 2991 # Pass precious variables to config.status. 2992 if test "$ac_new_set" = set; then 2993 case $ac_new_val in 2994 *\'*) ac_arg=$ac_var=`printf "%s\n" "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; 2995 *) ac_arg=$ac_var=$ac_new_val ;; 2996 esac 2997 case " $ac_configure_args " in 2998 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. 2999 *) as_fn_append ac_configure_args " '$ac_arg'" ;; 3000 esac 3001 fi 3002done 3003if $ac_cache_corrupted; then 3004 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 3005printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} 3006 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 3007printf "%s\n" "$as_me: error: changes in the environment can compromise the build" >&2;} 3008 as_fn_error $? "run \`${MAKE-make} distclean' and/or \`rm $cache_file' 3009 and start over" "$LINENO" 5 3010fi 3011## -------------------- ## 3012## Main body of script. ## 3013## -------------------- ## 3014 3015ac_ext=c 3016ac_cpp='$CPP $CPPFLAGS' 3017ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 3018ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 3019ac_compiler_gnu=$ac_cv_c_compiler_gnu 3020 3021 3022 3023 3024 3025# Check for stale configure as early as possible. 3026for i in $srcdir/configure.ac $srcdir/m4/*.m4; do 3027 if test "$i" -nt "$srcdir/configure"; then 3028 as_fn_error $? "$i newer than configure, run autoreconf" "$LINENO" 5 3029 fi 3030done 3031 3032ac_ext=c 3033ac_cpp='$CPP $CPPFLAGS' 3034ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 3035ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 3036ac_compiler_gnu=$ac_cv_c_compiler_gnu 3037 3038 3039ac_config_headers="$ac_config_headers config.h" 3040 3041 3042 3043 3044 3045 3046 3047 3048 3049 3050ac_ext=c 3051ac_cpp='$CPP $CPPFLAGS' 3052ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 3053ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 3054ac_compiler_gnu=$ac_cv_c_compiler_gnu 3055if test -n "$ac_tool_prefix"; then 3056 for ac_prog in cc gcc clang 3057 do 3058 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 3059set dummy $ac_tool_prefix$ac_prog; ac_word=$2 3060{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 3061printf %s "checking for $ac_word... " >&6; } 3062if test ${ac_cv_prog_CC+y} 3063then : 3064 printf %s "(cached) " >&6 3065else $as_nop 3066 if test -n "$CC"; then 3067 ac_cv_prog_CC="$CC" # Let the user override the test. 3068else 3069as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 3070for as_dir in $PATH 3071do 3072 IFS=$as_save_IFS 3073 case $as_dir in #((( 3074 '') as_dir=./ ;; 3075 */) ;; 3076 *) as_dir=$as_dir/ ;; 3077 esac 3078 for ac_exec_ext in '' $ac_executable_extensions; do 3079 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 3080 ac_cv_prog_CC="$ac_tool_prefix$ac_prog" 3081 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 3082 break 2 3083 fi 3084done 3085 done 3086IFS=$as_save_IFS 3087 3088fi 3089fi 3090CC=$ac_cv_prog_CC 3091if test -n "$CC"; then 3092 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 3093printf "%s\n" "$CC" >&6; } 3094else 3095 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 3096printf "%s\n" "no" >&6; } 3097fi 3098 3099 3100 test -n "$CC" && break 3101 done 3102fi 3103if test -z "$CC"; then 3104 ac_ct_CC=$CC 3105 for ac_prog in cc gcc clang 3106do 3107 # Extract the first word of "$ac_prog", so it can be a program name with args. 3108set dummy $ac_prog; ac_word=$2 3109{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 3110printf %s "checking for $ac_word... " >&6; } 3111if test ${ac_cv_prog_ac_ct_CC+y} 3112then : 3113 printf %s "(cached) " >&6 3114else $as_nop 3115 if test -n "$ac_ct_CC"; then 3116 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. 3117else 3118as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 3119for as_dir in $PATH 3120do 3121 IFS=$as_save_IFS 3122 case $as_dir in #((( 3123 '') as_dir=./ ;; 3124 */) ;; 3125 *) as_dir=$as_dir/ ;; 3126 esac 3127 for ac_exec_ext in '' $ac_executable_extensions; do 3128 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 3129 ac_cv_prog_ac_ct_CC="$ac_prog" 3130 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 3131 break 2 3132 fi 3133done 3134 done 3135IFS=$as_save_IFS 3136 3137fi 3138fi 3139ac_ct_CC=$ac_cv_prog_ac_ct_CC 3140if test -n "$ac_ct_CC"; then 3141 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 3142printf "%s\n" "$ac_ct_CC" >&6; } 3143else 3144 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 3145printf "%s\n" "no" >&6; } 3146fi 3147 3148 3149 test -n "$ac_ct_CC" && break 3150done 3151 3152 if test "x$ac_ct_CC" = x; then 3153 CC="" 3154 else 3155 case $cross_compiling:$ac_tool_warned in 3156yes:) 3157{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 3158printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 3159ac_tool_warned=yes ;; 3160esac 3161 CC=$ac_ct_CC 3162 fi 3163fi 3164 3165 3166test -z "$CC" && { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 3167printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} 3168as_fn_error $? "no acceptable C compiler found in \$PATH 3169See \`config.log' for more details" "$LINENO" 5; } 3170 3171# Provide some information about the compiler. 3172printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 3173set X $ac_compile 3174ac_compiler=$2 3175for ac_option in --version -v -V -qversion -version; do 3176 { { ac_try="$ac_compiler $ac_option >&5" 3177case "(($ac_try" in 3178 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 3179 *) ac_try_echo=$ac_try;; 3180esac 3181eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 3182printf "%s\n" "$ac_try_echo"; } >&5 3183 (eval "$ac_compiler $ac_option >&5") 2>conftest.err 3184 ac_status=$? 3185 if test -s conftest.err; then 3186 sed '10a\ 3187... rest of stderr output deleted ... 3188 10q' conftest.err >conftest.er1 3189 cat conftest.er1 >&5 3190 fi 3191 rm -f conftest.er1 conftest.err 3192 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 3193 test $ac_status = 0; } 3194done 3195 3196cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3197/* end confdefs.h. */ 3198 3199int 3200main (void) 3201{ 3202 3203 ; 3204 return 0; 3205} 3206_ACEOF 3207ac_clean_files_save=$ac_clean_files 3208ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" 3209# Try to create an executable without -o first, disregard a.out. 3210# It will help us diagnose broken compilers, and finding out an intuition 3211# of exeext. 3212{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 3213printf %s "checking whether the C compiler works... " >&6; } 3214ac_link_default=`printf "%s\n" "$ac_link" | sed 's/ -o *conftest[^ ]*//'` 3215 3216# The possible output files: 3217ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" 3218 3219ac_rmfiles= 3220for ac_file in $ac_files 3221do 3222 case $ac_file in 3223 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; 3224 * ) ac_rmfiles="$ac_rmfiles $ac_file";; 3225 esac 3226done 3227rm -f $ac_rmfiles 3228 3229if { { ac_try="$ac_link_default" 3230case "(($ac_try" in 3231 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 3232 *) ac_try_echo=$ac_try;; 3233esac 3234eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 3235printf "%s\n" "$ac_try_echo"; } >&5 3236 (eval "$ac_link_default") 2>&5 3237 ac_status=$? 3238 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 3239 test $ac_status = 0; } 3240then : 3241 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. 3242# So ignore a value of `no', otherwise this would lead to `EXEEXT = no' 3243# in a Makefile. We should not override ac_cv_exeext if it was cached, 3244# so that the user can short-circuit this test for compilers unknown to 3245# Autoconf. 3246for ac_file in $ac_files '' 3247do 3248 test -f "$ac_file" || continue 3249 case $ac_file in 3250 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) 3251 ;; 3252 [ab].out ) 3253 # We found the default executable, but exeext='' is most 3254 # certainly right. 3255 break;; 3256 *.* ) 3257 if test ${ac_cv_exeext+y} && test "$ac_cv_exeext" != no; 3258 then :; else 3259 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` 3260 fi 3261 # We set ac_cv_exeext here because the later test for it is not 3262 # safe: cross compilers may not add the suffix if given an `-o' 3263 # argument, so we may need to know it at that point already. 3264 # Even if this section looks crufty: it has the advantage of 3265 # actually working. 3266 break;; 3267 * ) 3268 break;; 3269 esac 3270done 3271test "$ac_cv_exeext" = no && ac_cv_exeext= 3272 3273else $as_nop 3274 ac_file='' 3275fi 3276if test -z "$ac_file" 3277then : 3278 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 3279printf "%s\n" "no" >&6; } 3280printf "%s\n" "$as_me: failed program was:" >&5 3281sed 's/^/| /' conftest.$ac_ext >&5 3282 3283{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 3284printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} 3285as_fn_error 77 "C compiler cannot create executables 3286See \`config.log' for more details" "$LINENO" 5; } 3287else $as_nop 3288 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 3289printf "%s\n" "yes" >&6; } 3290fi 3291{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 3292printf %s "checking for C compiler default output file name... " >&6; } 3293{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 3294printf "%s\n" "$ac_file" >&6; } 3295ac_exeext=$ac_cv_exeext 3296 3297rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out 3298ac_clean_files=$ac_clean_files_save 3299{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 3300printf %s "checking for suffix of executables... " >&6; } 3301if { { ac_try="$ac_link" 3302case "(($ac_try" in 3303 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 3304 *) ac_try_echo=$ac_try;; 3305esac 3306eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 3307printf "%s\n" "$ac_try_echo"; } >&5 3308 (eval "$ac_link") 2>&5 3309 ac_status=$? 3310 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 3311 test $ac_status = 0; } 3312then : 3313 # If both `conftest.exe' and `conftest' are `present' (well, observable) 3314# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will 3315# work properly (i.e., refer to `conftest.exe'), while it won't with 3316# `rm'. 3317for ac_file in conftest.exe conftest conftest.*; do 3318 test -f "$ac_file" || continue 3319 case $ac_file in 3320 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; 3321 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` 3322 break;; 3323 * ) break;; 3324 esac 3325done 3326else $as_nop 3327 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 3328printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} 3329as_fn_error $? "cannot compute suffix of executables: cannot compile and link 3330See \`config.log' for more details" "$LINENO" 5; } 3331fi 3332rm -f conftest conftest$ac_cv_exeext 3333{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 3334printf "%s\n" "$ac_cv_exeext" >&6; } 3335 3336rm -f conftest.$ac_ext 3337EXEEXT=$ac_cv_exeext 3338ac_exeext=$EXEEXT 3339cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3340/* end confdefs.h. */ 3341#include <stdio.h> 3342int 3343main (void) 3344{ 3345FILE *f = fopen ("conftest.out", "w"); 3346 return ferror (f) || fclose (f) != 0; 3347 3348 ; 3349 return 0; 3350} 3351_ACEOF 3352ac_clean_files="$ac_clean_files conftest.out" 3353# Check that the compiler produces executables we can run. If not, either 3354# the compiler is broken, or we cross compile. 3355{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 3356printf %s "checking whether we are cross compiling... " >&6; } 3357if test "$cross_compiling" != yes; then 3358 { { ac_try="$ac_link" 3359case "(($ac_try" in 3360 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 3361 *) ac_try_echo=$ac_try;; 3362esac 3363eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 3364printf "%s\n" "$ac_try_echo"; } >&5 3365 (eval "$ac_link") 2>&5 3366 ac_status=$? 3367 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 3368 test $ac_status = 0; } 3369 if { ac_try='./conftest$ac_cv_exeext' 3370 { { case "(($ac_try" in 3371 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 3372 *) ac_try_echo=$ac_try;; 3373esac 3374eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 3375printf "%s\n" "$ac_try_echo"; } >&5 3376 (eval "$ac_try") 2>&5 3377 ac_status=$? 3378 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 3379 test $ac_status = 0; }; }; then 3380 cross_compiling=no 3381 else 3382 if test "$cross_compiling" = maybe; then 3383 cross_compiling=yes 3384 else 3385 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 3386printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} 3387as_fn_error 77 "cannot run C compiled programs. 3388If you meant to cross compile, use \`--host'. 3389See \`config.log' for more details" "$LINENO" 5; } 3390 fi 3391 fi 3392fi 3393{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 3394printf "%s\n" "$cross_compiling" >&6; } 3395 3396rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out 3397ac_clean_files=$ac_clean_files_save 3398{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 3399printf %s "checking for suffix of object files... " >&6; } 3400if test ${ac_cv_objext+y} 3401then : 3402 printf %s "(cached) " >&6 3403else $as_nop 3404 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3405/* end confdefs.h. */ 3406 3407int 3408main (void) 3409{ 3410 3411 ; 3412 return 0; 3413} 3414_ACEOF 3415rm -f conftest.o conftest.obj 3416if { { ac_try="$ac_compile" 3417case "(($ac_try" in 3418 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 3419 *) ac_try_echo=$ac_try;; 3420esac 3421eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 3422printf "%s\n" "$ac_try_echo"; } >&5 3423 (eval "$ac_compile") 2>&5 3424 ac_status=$? 3425 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 3426 test $ac_status = 0; } 3427then : 3428 for ac_file in conftest.o conftest.obj conftest.*; do 3429 test -f "$ac_file" || continue; 3430 case $ac_file in 3431 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; 3432 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` 3433 break;; 3434 esac 3435done 3436else $as_nop 3437 printf "%s\n" "$as_me: failed program was:" >&5 3438sed 's/^/| /' conftest.$ac_ext >&5 3439 3440{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 3441printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} 3442as_fn_error $? "cannot compute suffix of object files: cannot compile 3443See \`config.log' for more details" "$LINENO" 5; } 3444fi 3445rm -f conftest.$ac_cv_objext conftest.$ac_ext 3446fi 3447{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 3448printf "%s\n" "$ac_cv_objext" >&6; } 3449OBJEXT=$ac_cv_objext 3450ac_objext=$OBJEXT 3451{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports GNU C" >&5 3452printf %s "checking whether the compiler supports GNU C... " >&6; } 3453if test ${ac_cv_c_compiler_gnu+y} 3454then : 3455 printf %s "(cached) " >&6 3456else $as_nop 3457 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3458/* end confdefs.h. */ 3459 3460int 3461main (void) 3462{ 3463#ifndef __GNUC__ 3464 choke me 3465#endif 3466 3467 ; 3468 return 0; 3469} 3470_ACEOF 3471if ac_fn_c_try_compile "$LINENO" 3472then : 3473 ac_compiler_gnu=yes 3474else $as_nop 3475 ac_compiler_gnu=no 3476fi 3477rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 3478ac_cv_c_compiler_gnu=$ac_compiler_gnu 3479 3480fi 3481{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 3482printf "%s\n" "$ac_cv_c_compiler_gnu" >&6; } 3483ac_compiler_gnu=$ac_cv_c_compiler_gnu 3484 3485if test $ac_compiler_gnu = yes; then 3486 GCC=yes 3487else 3488 GCC= 3489fi 3490ac_test_CFLAGS=${CFLAGS+y} 3491ac_save_CFLAGS=$CFLAGS 3492{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 3493printf %s "checking whether $CC accepts -g... " >&6; } 3494if test ${ac_cv_prog_cc_g+y} 3495then : 3496 printf %s "(cached) " >&6 3497else $as_nop 3498 ac_save_c_werror_flag=$ac_c_werror_flag 3499 ac_c_werror_flag=yes 3500 ac_cv_prog_cc_g=no 3501 CFLAGS="-g" 3502 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3503/* end confdefs.h. */ 3504 3505int 3506main (void) 3507{ 3508 3509 ; 3510 return 0; 3511} 3512_ACEOF 3513if ac_fn_c_try_compile "$LINENO" 3514then : 3515 ac_cv_prog_cc_g=yes 3516else $as_nop 3517 CFLAGS="" 3518 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3519/* end confdefs.h. */ 3520 3521int 3522main (void) 3523{ 3524 3525 ; 3526 return 0; 3527} 3528_ACEOF 3529if ac_fn_c_try_compile "$LINENO" 3530then : 3531 3532else $as_nop 3533 ac_c_werror_flag=$ac_save_c_werror_flag 3534 CFLAGS="-g" 3535 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3536/* end confdefs.h. */ 3537 3538int 3539main (void) 3540{ 3541 3542 ; 3543 return 0; 3544} 3545_ACEOF 3546if ac_fn_c_try_compile "$LINENO" 3547then : 3548 ac_cv_prog_cc_g=yes 3549fi 3550rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 3551fi 3552rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 3553fi 3554rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 3555 ac_c_werror_flag=$ac_save_c_werror_flag 3556fi 3557{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 3558printf "%s\n" "$ac_cv_prog_cc_g" >&6; } 3559if test $ac_test_CFLAGS; then 3560 CFLAGS=$ac_save_CFLAGS 3561elif test $ac_cv_prog_cc_g = yes; then 3562 if test "$GCC" = yes; then 3563 CFLAGS="-g -O2" 3564 else 3565 CFLAGS="-g" 3566 fi 3567else 3568 if test "$GCC" = yes; then 3569 CFLAGS="-O2" 3570 else 3571 CFLAGS= 3572 fi 3573fi 3574ac_prog_cc_stdc=no 3575if test x$ac_prog_cc_stdc = xno 3576then : 3577 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C11 features" >&5 3578printf %s "checking for $CC option to enable C11 features... " >&6; } 3579if test ${ac_cv_prog_cc_c11+y} 3580then : 3581 printf %s "(cached) " >&6 3582else $as_nop 3583 ac_cv_prog_cc_c11=no 3584ac_save_CC=$CC 3585cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3586/* end confdefs.h. */ 3587$ac_c_conftest_c11_program 3588_ACEOF 3589for ac_arg in '' -std=gnu11 3590do 3591 CC="$ac_save_CC $ac_arg" 3592 if ac_fn_c_try_compile "$LINENO" 3593then : 3594 ac_cv_prog_cc_c11=$ac_arg 3595fi 3596rm -f core conftest.err conftest.$ac_objext conftest.beam 3597 test "x$ac_cv_prog_cc_c11" != "xno" && break 3598done 3599rm -f conftest.$ac_ext 3600CC=$ac_save_CC 3601fi 3602 3603if test "x$ac_cv_prog_cc_c11" = xno 3604then : 3605 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 3606printf "%s\n" "unsupported" >&6; } 3607else $as_nop 3608 if test "x$ac_cv_prog_cc_c11" = x 3609then : 3610 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 3611printf "%s\n" "none needed" >&6; } 3612else $as_nop 3613 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c11" >&5 3614printf "%s\n" "$ac_cv_prog_cc_c11" >&6; } 3615 CC="$CC $ac_cv_prog_cc_c11" 3616fi 3617 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c11 3618 ac_prog_cc_stdc=c11 3619fi 3620fi 3621if test x$ac_prog_cc_stdc = xno 3622then : 3623 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C99 features" >&5 3624printf %s "checking for $CC option to enable C99 features... " >&6; } 3625if test ${ac_cv_prog_cc_c99+y} 3626then : 3627 printf %s "(cached) " >&6 3628else $as_nop 3629 ac_cv_prog_cc_c99=no 3630ac_save_CC=$CC 3631cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3632/* end confdefs.h. */ 3633$ac_c_conftest_c99_program 3634_ACEOF 3635for ac_arg in '' -std=gnu99 -std=c99 -c99 -qlanglvl=extc1x -qlanglvl=extc99 -AC99 -D_STDC_C99= 3636do 3637 CC="$ac_save_CC $ac_arg" 3638 if ac_fn_c_try_compile "$LINENO" 3639then : 3640 ac_cv_prog_cc_c99=$ac_arg 3641fi 3642rm -f core conftest.err conftest.$ac_objext conftest.beam 3643 test "x$ac_cv_prog_cc_c99" != "xno" && break 3644done 3645rm -f conftest.$ac_ext 3646CC=$ac_save_CC 3647fi 3648 3649if test "x$ac_cv_prog_cc_c99" = xno 3650then : 3651 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 3652printf "%s\n" "unsupported" >&6; } 3653else $as_nop 3654 if test "x$ac_cv_prog_cc_c99" = x 3655then : 3656 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 3657printf "%s\n" "none needed" >&6; } 3658else $as_nop 3659 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5 3660printf "%s\n" "$ac_cv_prog_cc_c99" >&6; } 3661 CC="$CC $ac_cv_prog_cc_c99" 3662fi 3663 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99 3664 ac_prog_cc_stdc=c99 3665fi 3666fi 3667if test x$ac_prog_cc_stdc = xno 3668then : 3669 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C89 features" >&5 3670printf %s "checking for $CC option to enable C89 features... " >&6; } 3671if test ${ac_cv_prog_cc_c89+y} 3672then : 3673 printf %s "(cached) " >&6 3674else $as_nop 3675 ac_cv_prog_cc_c89=no 3676ac_save_CC=$CC 3677cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3678/* end confdefs.h. */ 3679$ac_c_conftest_c89_program 3680_ACEOF 3681for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" 3682do 3683 CC="$ac_save_CC $ac_arg" 3684 if ac_fn_c_try_compile "$LINENO" 3685then : 3686 ac_cv_prog_cc_c89=$ac_arg 3687fi 3688rm -f core conftest.err conftest.$ac_objext conftest.beam 3689 test "x$ac_cv_prog_cc_c89" != "xno" && break 3690done 3691rm -f conftest.$ac_ext 3692CC=$ac_save_CC 3693fi 3694 3695if test "x$ac_cv_prog_cc_c89" = xno 3696then : 3697 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 3698printf "%s\n" "unsupported" >&6; } 3699else $as_nop 3700 if test "x$ac_cv_prog_cc_c89" = x 3701then : 3702 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 3703printf "%s\n" "none needed" >&6; } 3704else $as_nop 3705 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 3706printf "%s\n" "$ac_cv_prog_cc_c89" >&6; } 3707 CC="$CC $ac_cv_prog_cc_c89" 3708fi 3709 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89 3710 ac_prog_cc_stdc=c89 3711fi 3712fi 3713 3714ac_ext=c 3715ac_cpp='$CPP $CPPFLAGS' 3716ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 3717ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 3718ac_compiler_gnu=$ac_cv_c_compiler_gnu 3719 3720 3721# XXX relax this after reimplementing logit() etc. 3722{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC supports C99-style variadic macros" >&5 3723printf %s "checking if $CC supports C99-style variadic macros... " >&6; } 3724 3725cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3726/* end confdefs.h. */ 3727 3728int f(int a, int b, int c) { return a + b + c; } 3729#define F(a, ...) f(a, __VA_ARGS__) 3730 3731int 3732main (void) 3733{ 3734return F(1, 2, -3); 3735 ; 3736 return 0; 3737} 3738_ACEOF 3739if ac_fn_c_try_compile "$LINENO" 3740then : 3741 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 3742printf "%s\n" "yes" >&6; } 3743else $as_nop 3744 as_fn_error $? "*** OpenSSH requires support for C99-style variadic macros" "$LINENO" 5 3745 3746fi 3747rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 3748 3749 3750 3751 3752 # Make sure we can run config.sub. 3753$SHELL "${ac_aux_dir}config.sub" sun4 >/dev/null 2>&1 || 3754 as_fn_error $? "cannot run $SHELL ${ac_aux_dir}config.sub" "$LINENO" 5 3755 3756{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 3757printf %s "checking build system type... " >&6; } 3758if test ${ac_cv_build+y} 3759then : 3760 printf %s "(cached) " >&6 3761else $as_nop 3762 ac_build_alias=$build_alias 3763test "x$ac_build_alias" = x && 3764 ac_build_alias=`$SHELL "${ac_aux_dir}config.guess"` 3765test "x$ac_build_alias" = x && 3766 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 3767ac_cv_build=`$SHELL "${ac_aux_dir}config.sub" $ac_build_alias` || 3768 as_fn_error $? "$SHELL ${ac_aux_dir}config.sub $ac_build_alias failed" "$LINENO" 5 3769 3770fi 3771{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 3772printf "%s\n" "$ac_cv_build" >&6; } 3773case $ac_cv_build in 3774*-*-*) ;; 3775*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; 3776esac 3777build=$ac_cv_build 3778ac_save_IFS=$IFS; IFS='-' 3779set x $ac_cv_build 3780shift 3781build_cpu=$1 3782build_vendor=$2 3783shift; shift 3784# Remember, the first character of IFS is used to create $*, 3785# except with old shells: 3786build_os=$* 3787IFS=$ac_save_IFS 3788case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac 3789 3790 3791{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 3792printf %s "checking host system type... " >&6; } 3793if test ${ac_cv_host+y} 3794then : 3795 printf %s "(cached) " >&6 3796else $as_nop 3797 if test "x$host_alias" = x; then 3798 ac_cv_host=$ac_cv_build 3799else 3800 ac_cv_host=`$SHELL "${ac_aux_dir}config.sub" $host_alias` || 3801 as_fn_error $? "$SHELL ${ac_aux_dir}config.sub $host_alias failed" "$LINENO" 5 3802fi 3803 3804fi 3805{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 3806printf "%s\n" "$ac_cv_host" >&6; } 3807case $ac_cv_host in 3808*-*-*) ;; 3809*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; 3810esac 3811host=$ac_cv_host 3812ac_save_IFS=$IFS; IFS='-' 3813set x $ac_cv_host 3814shift 3815host_cpu=$1 3816host_vendor=$2 3817shift; shift 3818# Remember, the first character of IFS is used to create $*, 3819# except with old shells: 3820host_os=$* 3821IFS=$ac_save_IFS 3822case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac 3823 3824 3825ac_header= ac_cache= 3826for ac_item in $ac_header_c_list 3827do 3828 if test $ac_cache; then 3829 ac_fn_c_check_header_compile "$LINENO" $ac_header ac_cv_header_$ac_cache "$ac_includes_default" 3830 if eval test \"x\$ac_cv_header_$ac_cache\" = xyes; then 3831 printf "%s\n" "#define $ac_item 1" >> confdefs.h 3832 fi 3833 ac_header= ac_cache= 3834 elif test $ac_header; then 3835 ac_cache=$ac_item 3836 else 3837 ac_header=$ac_item 3838 fi 3839done 3840 3841 3842 3843 3844 3845 3846 3847 3848if test $ac_cv_header_stdlib_h = yes && test $ac_cv_header_string_h = yes 3849then : 3850 3851printf "%s\n" "#define STDC_HEADERS 1" >>confdefs.h 3852 3853fi 3854 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 3855printf %s "checking whether byte ordering is bigendian... " >&6; } 3856if test ${ac_cv_c_bigendian+y} 3857then : 3858 printf %s "(cached) " >&6 3859else $as_nop 3860 ac_cv_c_bigendian=unknown 3861 # See if we're dealing with a universal compiler. 3862 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3863/* end confdefs.h. */ 3864#ifndef __APPLE_CC__ 3865 not a universal capable compiler 3866 #endif 3867 typedef int dummy; 3868 3869_ACEOF 3870if ac_fn_c_try_compile "$LINENO" 3871then : 3872 3873 # Check for potential -arch flags. It is not universal unless 3874 # there are at least two -arch flags with different values. 3875 ac_arch= 3876 ac_prev= 3877 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do 3878 if test -n "$ac_prev"; then 3879 case $ac_word in 3880 i?86 | x86_64 | ppc | ppc64) 3881 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then 3882 ac_arch=$ac_word 3883 else 3884 ac_cv_c_bigendian=universal 3885 break 3886 fi 3887 ;; 3888 esac 3889 ac_prev= 3890 elif test "x$ac_word" = "x-arch"; then 3891 ac_prev=arch 3892 fi 3893 done 3894fi 3895rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 3896 if test $ac_cv_c_bigendian = unknown; then 3897 # See if sys/param.h defines the BYTE_ORDER macro. 3898 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3899/* end confdefs.h. */ 3900#include <sys/types.h> 3901 #include <sys/param.h> 3902 3903int 3904main (void) 3905{ 3906#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ 3907 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ 3908 && LITTLE_ENDIAN) 3909 bogus endian macros 3910 #endif 3911 3912 ; 3913 return 0; 3914} 3915_ACEOF 3916if ac_fn_c_try_compile "$LINENO" 3917then : 3918 # It does; now see whether it defined to BIG_ENDIAN or not. 3919 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3920/* end confdefs.h. */ 3921#include <sys/types.h> 3922 #include <sys/param.h> 3923 3924int 3925main (void) 3926{ 3927#if BYTE_ORDER != BIG_ENDIAN 3928 not big endian 3929 #endif 3930 3931 ; 3932 return 0; 3933} 3934_ACEOF 3935if ac_fn_c_try_compile "$LINENO" 3936then : 3937 ac_cv_c_bigendian=yes 3938else $as_nop 3939 ac_cv_c_bigendian=no 3940fi 3941rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 3942fi 3943rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 3944 fi 3945 if test $ac_cv_c_bigendian = unknown; then 3946 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). 3947 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3948/* end confdefs.h. */ 3949#include <limits.h> 3950 3951int 3952main (void) 3953{ 3954#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) 3955 bogus endian macros 3956 #endif 3957 3958 ; 3959 return 0; 3960} 3961_ACEOF 3962if ac_fn_c_try_compile "$LINENO" 3963then : 3964 # It does; now see whether it defined to _BIG_ENDIAN or not. 3965 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3966/* end confdefs.h. */ 3967#include <limits.h> 3968 3969int 3970main (void) 3971{ 3972#ifndef _BIG_ENDIAN 3973 not big endian 3974 #endif 3975 3976 ; 3977 return 0; 3978} 3979_ACEOF 3980if ac_fn_c_try_compile "$LINENO" 3981then : 3982 ac_cv_c_bigendian=yes 3983else $as_nop 3984 ac_cv_c_bigendian=no 3985fi 3986rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 3987fi 3988rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 3989 fi 3990 if test $ac_cv_c_bigendian = unknown; then 3991 # Compile a test program. 3992 if test "$cross_compiling" = yes 3993then : 3994 # Try to guess by grepping values from an object file. 3995 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3996/* end confdefs.h. */ 3997unsigned short int ascii_mm[] = 3998 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; 3999 unsigned short int ascii_ii[] = 4000 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; 4001 int use_ascii (int i) { 4002 return ascii_mm[i] + ascii_ii[i]; 4003 } 4004 unsigned short int ebcdic_ii[] = 4005 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; 4006 unsigned short int ebcdic_mm[] = 4007 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; 4008 int use_ebcdic (int i) { 4009 return ebcdic_mm[i] + ebcdic_ii[i]; 4010 } 4011 extern int foo; 4012 4013int 4014main (void) 4015{ 4016return use_ascii (foo) == use_ebcdic (foo); 4017 ; 4018 return 0; 4019} 4020_ACEOF 4021if ac_fn_c_try_compile "$LINENO" 4022then : 4023 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then 4024 ac_cv_c_bigendian=yes 4025 fi 4026 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then 4027 if test "$ac_cv_c_bigendian" = unknown; then 4028 ac_cv_c_bigendian=no 4029 else 4030 # finding both strings is unlikely to happen, but who knows? 4031 ac_cv_c_bigendian=unknown 4032 fi 4033 fi 4034fi 4035rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 4036else $as_nop 4037 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 4038/* end confdefs.h. */ 4039$ac_includes_default 4040int 4041main (void) 4042{ 4043 4044 /* Are we little or big endian? From Harbison&Steele. */ 4045 union 4046 { 4047 long int l; 4048 char c[sizeof (long int)]; 4049 } u; 4050 u.l = 1; 4051 return u.c[sizeof (long int) - 1] == 1; 4052 4053 ; 4054 return 0; 4055} 4056_ACEOF 4057if ac_fn_c_try_run "$LINENO" 4058then : 4059 ac_cv_c_bigendian=no 4060else $as_nop 4061 ac_cv_c_bigendian=yes 4062fi 4063rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 4064 conftest.$ac_objext conftest.beam conftest.$ac_ext 4065fi 4066 4067 fi 4068fi 4069{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 4070printf "%s\n" "$ac_cv_c_bigendian" >&6; } 4071 case $ac_cv_c_bigendian in #( 4072 yes) 4073 printf "%s\n" "#define WORDS_BIGENDIAN 1" >>confdefs.h 4074;; #( 4075 no) 4076 ;; #( 4077 universal) 4078 4079printf "%s\n" "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h 4080 4081 ;; #( 4082 *) 4083 as_fn_error $? "unknown endianness 4084 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;; 4085 esac 4086 4087 4088# Checks for programs. 4089for ac_prog in gawk mawk nawk awk 4090do 4091 # Extract the first word of "$ac_prog", so it can be a program name with args. 4092set dummy $ac_prog; ac_word=$2 4093{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4094printf %s "checking for $ac_word... " >&6; } 4095if test ${ac_cv_prog_AWK+y} 4096then : 4097 printf %s "(cached) " >&6 4098else $as_nop 4099 if test -n "$AWK"; then 4100 ac_cv_prog_AWK="$AWK" # Let the user override the test. 4101else 4102as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4103for as_dir in $PATH 4104do 4105 IFS=$as_save_IFS 4106 case $as_dir in #((( 4107 '') as_dir=./ ;; 4108 */) ;; 4109 *) as_dir=$as_dir/ ;; 4110 esac 4111 for ac_exec_ext in '' $ac_executable_extensions; do 4112 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 4113 ac_cv_prog_AWK="$ac_prog" 4114 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 4115 break 2 4116 fi 4117done 4118 done 4119IFS=$as_save_IFS 4120 4121fi 4122fi 4123AWK=$ac_cv_prog_AWK 4124if test -n "$AWK"; then 4125 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 4126printf "%s\n" "$AWK" >&6; } 4127else 4128 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 4129printf "%s\n" "no" >&6; } 4130fi 4131 4132 4133 test -n "$AWK" && break 4134done 4135 4136ac_ext=c 4137ac_cpp='$CPP $CPPFLAGS' 4138ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 4139ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 4140ac_compiler_gnu=$ac_cv_c_compiler_gnu 4141{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 4142printf %s "checking how to run the C preprocessor... " >&6; } 4143# On Suns, sometimes $CPP names a directory. 4144if test -n "$CPP" && test -d "$CPP"; then 4145 CPP= 4146fi 4147if test -z "$CPP"; then 4148 if test ${ac_cv_prog_CPP+y} 4149then : 4150 printf %s "(cached) " >&6 4151else $as_nop 4152 # Double quotes because $CC needs to be expanded 4153 for CPP in "$CC -E" "$CC -E -traditional-cpp" cpp /lib/cpp 4154 do 4155 ac_preproc_ok=false 4156for ac_c_preproc_warn_flag in '' yes 4157do 4158 # Use a header file that comes with gcc, so configuring glibc 4159 # with a fresh cross-compiler works. 4160 # On the NeXT, cc -E runs the code through the compiler's parser, 4161 # not just through cpp. "Syntax error" is here to catch this case. 4162 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 4163/* end confdefs.h. */ 4164#include <limits.h> 4165 Syntax error 4166_ACEOF 4167if ac_fn_c_try_cpp "$LINENO" 4168then : 4169 4170else $as_nop 4171 # Broken: fails on valid input. 4172continue 4173fi 4174rm -f conftest.err conftest.i conftest.$ac_ext 4175 4176 # OK, works on sane cases. Now check whether nonexistent headers 4177 # can be detected and how. 4178 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 4179/* end confdefs.h. */ 4180#include <ac_nonexistent.h> 4181_ACEOF 4182if ac_fn_c_try_cpp "$LINENO" 4183then : 4184 # Broken: success on invalid input. 4185continue 4186else $as_nop 4187 # Passes both tests. 4188ac_preproc_ok=: 4189break 4190fi 4191rm -f conftest.err conftest.i conftest.$ac_ext 4192 4193done 4194# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 4195rm -f conftest.i conftest.err conftest.$ac_ext 4196if $ac_preproc_ok 4197then : 4198 break 4199fi 4200 4201 done 4202 ac_cv_prog_CPP=$CPP 4203 4204fi 4205 CPP=$ac_cv_prog_CPP 4206else 4207 ac_cv_prog_CPP=$CPP 4208fi 4209{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 4210printf "%s\n" "$CPP" >&6; } 4211ac_preproc_ok=false 4212for ac_c_preproc_warn_flag in '' yes 4213do 4214 # Use a header file that comes with gcc, so configuring glibc 4215 # with a fresh cross-compiler works. 4216 # On the NeXT, cc -E runs the code through the compiler's parser, 4217 # not just through cpp. "Syntax error" is here to catch this case. 4218 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 4219/* end confdefs.h. */ 4220#include <limits.h> 4221 Syntax error 4222_ACEOF 4223if ac_fn_c_try_cpp "$LINENO" 4224then : 4225 4226else $as_nop 4227 # Broken: fails on valid input. 4228continue 4229fi 4230rm -f conftest.err conftest.i conftest.$ac_ext 4231 4232 # OK, works on sane cases. Now check whether nonexistent headers 4233 # can be detected and how. 4234 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 4235/* end confdefs.h. */ 4236#include <ac_nonexistent.h> 4237_ACEOF 4238if ac_fn_c_try_cpp "$LINENO" 4239then : 4240 # Broken: success on invalid input. 4241continue 4242else $as_nop 4243 # Passes both tests. 4244ac_preproc_ok=: 4245break 4246fi 4247rm -f conftest.err conftest.i conftest.$ac_ext 4248 4249done 4250# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 4251rm -f conftest.i conftest.err conftest.$ac_ext 4252if $ac_preproc_ok 4253then : 4254 4255else $as_nop 4256 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 4257printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} 4258as_fn_error $? "C preprocessor \"$CPP\" fails sanity check 4259See \`config.log' for more details" "$LINENO" 5; } 4260fi 4261 4262ac_ext=c 4263ac_cpp='$CPP $CPPFLAGS' 4264ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 4265ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 4266ac_compiler_gnu=$ac_cv_c_compiler_gnu 4267 4268if test -n "$ac_tool_prefix"; then 4269 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. 4270set dummy ${ac_tool_prefix}ranlib; ac_word=$2 4271{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4272printf %s "checking for $ac_word... " >&6; } 4273if test ${ac_cv_prog_RANLIB+y} 4274then : 4275 printf %s "(cached) " >&6 4276else $as_nop 4277 if test -n "$RANLIB"; then 4278 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. 4279else 4280as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4281for as_dir in $PATH 4282do 4283 IFS=$as_save_IFS 4284 case $as_dir in #((( 4285 '') as_dir=./ ;; 4286 */) ;; 4287 *) as_dir=$as_dir/ ;; 4288 esac 4289 for ac_exec_ext in '' $ac_executable_extensions; do 4290 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 4291 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" 4292 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 4293 break 2 4294 fi 4295done 4296 done 4297IFS=$as_save_IFS 4298 4299fi 4300fi 4301RANLIB=$ac_cv_prog_RANLIB 4302if test -n "$RANLIB"; then 4303 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 4304printf "%s\n" "$RANLIB" >&6; } 4305else 4306 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 4307printf "%s\n" "no" >&6; } 4308fi 4309 4310 4311fi 4312if test -z "$ac_cv_prog_RANLIB"; then 4313 ac_ct_RANLIB=$RANLIB 4314 # Extract the first word of "ranlib", so it can be a program name with args. 4315set dummy ranlib; ac_word=$2 4316{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4317printf %s "checking for $ac_word... " >&6; } 4318if test ${ac_cv_prog_ac_ct_RANLIB+y} 4319then : 4320 printf %s "(cached) " >&6 4321else $as_nop 4322 if test -n "$ac_ct_RANLIB"; then 4323 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. 4324else 4325as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4326for as_dir in $PATH 4327do 4328 IFS=$as_save_IFS 4329 case $as_dir in #((( 4330 '') as_dir=./ ;; 4331 */) ;; 4332 *) as_dir=$as_dir/ ;; 4333 esac 4334 for ac_exec_ext in '' $ac_executable_extensions; do 4335 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 4336 ac_cv_prog_ac_ct_RANLIB="ranlib" 4337 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 4338 break 2 4339 fi 4340done 4341 done 4342IFS=$as_save_IFS 4343 4344fi 4345fi 4346ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB 4347if test -n "$ac_ct_RANLIB"; then 4348 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 4349printf "%s\n" "$ac_ct_RANLIB" >&6; } 4350else 4351 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 4352printf "%s\n" "no" >&6; } 4353fi 4354 4355 if test "x$ac_ct_RANLIB" = x; then 4356 RANLIB=":" 4357 else 4358 case $cross_compiling:$ac_tool_warned in 4359yes:) 4360{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 4361printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 4362ac_tool_warned=yes ;; 4363esac 4364 RANLIB=$ac_ct_RANLIB 4365 fi 4366else 4367 RANLIB="$ac_cv_prog_RANLIB" 4368fi 4369 4370 4371 # Find a good install program. We prefer a C program (faster), 4372# so one script is as good as another. But avoid the broken or 4373# incompatible versions: 4374# SysV /etc/install, /usr/sbin/install 4375# SunOS /usr/etc/install 4376# IRIX /sbin/install 4377# AIX /bin/install 4378# AmigaOS /C/install, which installs bootblocks on floppy discs 4379# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag 4380# AFS /usr/afsws/bin/install, which mishandles nonexistent args 4381# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" 4382# OS/2's system install, which has a completely different semantic 4383# ./install, which can be erroneously created by make from ./install.sh. 4384# Reject install programs that cannot install multiple files. 4385{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 4386printf %s "checking for a BSD-compatible install... " >&6; } 4387if test -z "$INSTALL"; then 4388if test ${ac_cv_path_install+y} 4389then : 4390 printf %s "(cached) " >&6 4391else $as_nop 4392 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4393for as_dir in $PATH 4394do 4395 IFS=$as_save_IFS 4396 case $as_dir in #((( 4397 '') as_dir=./ ;; 4398 */) ;; 4399 *) as_dir=$as_dir/ ;; 4400 esac 4401 # Account for fact that we put trailing slashes in our PATH walk. 4402case $as_dir in #(( 4403 ./ | /[cC]/* | \ 4404 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ 4405 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ 4406 /usr/ucb/* ) ;; 4407 *) 4408 # OSF1 and SCO ODT 3.0 have their own names for install. 4409 # Don't use installbsd from OSF since it installs stuff as root 4410 # by default. 4411 for ac_prog in ginstall scoinst install; do 4412 for ac_exec_ext in '' $ac_executable_extensions; do 4413 if as_fn_executable_p "$as_dir$ac_prog$ac_exec_ext"; then 4414 if test $ac_prog = install && 4415 grep dspmsg "$as_dir$ac_prog$ac_exec_ext" >/dev/null 2>&1; then 4416 # AIX install. It has an incompatible calling convention. 4417 : 4418 elif test $ac_prog = install && 4419 grep pwplus "$as_dir$ac_prog$ac_exec_ext" >/dev/null 2>&1; then 4420 # program-specific install script used by HP pwplus--don't use. 4421 : 4422 else 4423 rm -rf conftest.one conftest.two conftest.dir 4424 echo one > conftest.one 4425 echo two > conftest.two 4426 mkdir conftest.dir 4427 if "$as_dir$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir/" && 4428 test -s conftest.one && test -s conftest.two && 4429 test -s conftest.dir/conftest.one && 4430 test -s conftest.dir/conftest.two 4431 then 4432 ac_cv_path_install="$as_dir$ac_prog$ac_exec_ext -c" 4433 break 3 4434 fi 4435 fi 4436 fi 4437 done 4438 done 4439 ;; 4440esac 4441 4442 done 4443IFS=$as_save_IFS 4444 4445rm -rf conftest.one conftest.two conftest.dir 4446 4447fi 4448 if test ${ac_cv_path_install+y}; then 4449 INSTALL=$ac_cv_path_install 4450 else 4451 # As a last resort, use the slow shell script. Don't cache a 4452 # value for INSTALL within a source directory, because that will 4453 # break other packages using the cache if that directory is 4454 # removed, or if the value is a relative name. 4455 INSTALL=$ac_install_sh 4456 fi 4457fi 4458{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 4459printf "%s\n" "$INSTALL" >&6; } 4460 4461# Use test -z because SunOS4 sh mishandles braces in ${var-val}. 4462# It thinks the first close brace ends the variable substitution. 4463test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' 4464 4465test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' 4466 4467test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' 4468 4469{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 4470printf %s "checking for grep that handles long lines and -e... " >&6; } 4471if test ${ac_cv_path_GREP+y} 4472then : 4473 printf %s "(cached) " >&6 4474else $as_nop 4475 if test -z "$GREP"; then 4476 ac_path_GREP_found=false 4477 # Loop through the user's path and test for each of PROGNAME-LIST 4478 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4479for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 4480do 4481 IFS=$as_save_IFS 4482 case $as_dir in #((( 4483 '') as_dir=./ ;; 4484 */) ;; 4485 *) as_dir=$as_dir/ ;; 4486 esac 4487 for ac_prog in grep ggrep 4488 do 4489 for ac_exec_ext in '' $ac_executable_extensions; do 4490 ac_path_GREP="$as_dir$ac_prog$ac_exec_ext" 4491 as_fn_executable_p "$ac_path_GREP" || continue 4492# Check for GNU ac_path_GREP and select it if it is found. 4493 # Check for GNU $ac_path_GREP 4494case `"$ac_path_GREP" --version 2>&1` in 4495*GNU*) 4496 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; 4497*) 4498 ac_count=0 4499 printf %s 0123456789 >"conftest.in" 4500 while : 4501 do 4502 cat "conftest.in" "conftest.in" >"conftest.tmp" 4503 mv "conftest.tmp" "conftest.in" 4504 cp "conftest.in" "conftest.nl" 4505 printf "%s\n" 'GREP' >> "conftest.nl" 4506 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break 4507 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 4508 as_fn_arith $ac_count + 1 && ac_count=$as_val 4509 if test $ac_count -gt ${ac_path_GREP_max-0}; then 4510 # Best one so far, save it but keep looking for a better one 4511 ac_cv_path_GREP="$ac_path_GREP" 4512 ac_path_GREP_max=$ac_count 4513 fi 4514 # 10*(2^10) chars as input seems more than enough 4515 test $ac_count -gt 10 && break 4516 done 4517 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 4518esac 4519 4520 $ac_path_GREP_found && break 3 4521 done 4522 done 4523 done 4524IFS=$as_save_IFS 4525 if test -z "$ac_cv_path_GREP"; then 4526 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 4527 fi 4528else 4529 ac_cv_path_GREP=$GREP 4530fi 4531 4532fi 4533{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 4534printf "%s\n" "$ac_cv_path_GREP" >&6; } 4535 GREP="$ac_cv_path_GREP" 4536 4537 4538{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 4539printf %s "checking for egrep... " >&6; } 4540if test ${ac_cv_path_EGREP+y} 4541then : 4542 printf %s "(cached) " >&6 4543else $as_nop 4544 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 4545 then ac_cv_path_EGREP="$GREP -E" 4546 else 4547 if test -z "$EGREP"; then 4548 ac_path_EGREP_found=false 4549 # Loop through the user's path and test for each of PROGNAME-LIST 4550 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4551for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 4552do 4553 IFS=$as_save_IFS 4554 case $as_dir in #((( 4555 '') as_dir=./ ;; 4556 */) ;; 4557 *) as_dir=$as_dir/ ;; 4558 esac 4559 for ac_prog in egrep 4560 do 4561 for ac_exec_ext in '' $ac_executable_extensions; do 4562 ac_path_EGREP="$as_dir$ac_prog$ac_exec_ext" 4563 as_fn_executable_p "$ac_path_EGREP" || continue 4564# Check for GNU ac_path_EGREP and select it if it is found. 4565 # Check for GNU $ac_path_EGREP 4566case `"$ac_path_EGREP" --version 2>&1` in 4567*GNU*) 4568 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; 4569*) 4570 ac_count=0 4571 printf %s 0123456789 >"conftest.in" 4572 while : 4573 do 4574 cat "conftest.in" "conftest.in" >"conftest.tmp" 4575 mv "conftest.tmp" "conftest.in" 4576 cp "conftest.in" "conftest.nl" 4577 printf "%s\n" 'EGREP' >> "conftest.nl" 4578 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break 4579 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 4580 as_fn_arith $ac_count + 1 && ac_count=$as_val 4581 if test $ac_count -gt ${ac_path_EGREP_max-0}; then 4582 # Best one so far, save it but keep looking for a better one 4583 ac_cv_path_EGREP="$ac_path_EGREP" 4584 ac_path_EGREP_max=$ac_count 4585 fi 4586 # 10*(2^10) chars as input seems more than enough 4587 test $ac_count -gt 10 && break 4588 done 4589 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 4590esac 4591 4592 $ac_path_EGREP_found && break 3 4593 done 4594 done 4595 done 4596IFS=$as_save_IFS 4597 if test -z "$ac_cv_path_EGREP"; then 4598 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 4599 fi 4600else 4601 ac_cv_path_EGREP=$EGREP 4602fi 4603 4604 fi 4605fi 4606{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 4607printf "%s\n" "$ac_cv_path_EGREP" >&6; } 4608 EGREP="$ac_cv_path_EGREP" 4609 4610 4611 4612 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a race-free mkdir -p" >&5 4613printf %s "checking for a race-free mkdir -p... " >&6; } 4614if test -z "$MKDIR_P"; then 4615 if test ${ac_cv_path_mkdir+y} 4616then : 4617 printf %s "(cached) " >&6 4618else $as_nop 4619 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4620for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin 4621do 4622 IFS=$as_save_IFS 4623 case $as_dir in #((( 4624 '') as_dir=./ ;; 4625 */) ;; 4626 *) as_dir=$as_dir/ ;; 4627 esac 4628 for ac_prog in mkdir gmkdir; do 4629 for ac_exec_ext in '' $ac_executable_extensions; do 4630 as_fn_executable_p "$as_dir$ac_prog$ac_exec_ext" || continue 4631 case `"$as_dir$ac_prog$ac_exec_ext" --version 2>&1` in #( 4632 'mkdir ('*'coreutils) '* | \ 4633 'BusyBox '* | \ 4634 'mkdir (fileutils) '4.1*) 4635 ac_cv_path_mkdir=$as_dir$ac_prog$ac_exec_ext 4636 break 3;; 4637 esac 4638 done 4639 done 4640 done 4641IFS=$as_save_IFS 4642 4643fi 4644 4645 test -d ./--version && rmdir ./--version 4646 if test ${ac_cv_path_mkdir+y}; then 4647 MKDIR_P="$ac_cv_path_mkdir -p" 4648 else 4649 # As a last resort, use the slow shell script. Don't cache a 4650 # value for MKDIR_P within a source directory, because that will 4651 # break other packages using the cache if that directory is 4652 # removed, or if the value is a relative name. 4653 MKDIR_P="$ac_install_sh -d" 4654 fi 4655fi 4656{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5 4657printf "%s\n" "$MKDIR_P" >&6; } 4658 4659if test -n "$ac_tool_prefix"; then 4660 for ac_prog in ar 4661 do 4662 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 4663set dummy $ac_tool_prefix$ac_prog; ac_word=$2 4664{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4665printf %s "checking for $ac_word... " >&6; } 4666if test ${ac_cv_prog_AR+y} 4667then : 4668 printf %s "(cached) " >&6 4669else $as_nop 4670 if test -n "$AR"; then 4671 ac_cv_prog_AR="$AR" # Let the user override the test. 4672else 4673as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4674for as_dir in $PATH 4675do 4676 IFS=$as_save_IFS 4677 case $as_dir in #((( 4678 '') as_dir=./ ;; 4679 */) ;; 4680 *) as_dir=$as_dir/ ;; 4681 esac 4682 for ac_exec_ext in '' $ac_executable_extensions; do 4683 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 4684 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 4685 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 4686 break 2 4687 fi 4688done 4689 done 4690IFS=$as_save_IFS 4691 4692fi 4693fi 4694AR=$ac_cv_prog_AR 4695if test -n "$AR"; then 4696 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 4697printf "%s\n" "$AR" >&6; } 4698else 4699 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 4700printf "%s\n" "no" >&6; } 4701fi 4702 4703 4704 test -n "$AR" && break 4705 done 4706fi 4707if test -z "$AR"; then 4708 ac_ct_AR=$AR 4709 for ac_prog in ar 4710do 4711 # Extract the first word of "$ac_prog", so it can be a program name with args. 4712set dummy $ac_prog; ac_word=$2 4713{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4714printf %s "checking for $ac_word... " >&6; } 4715if test ${ac_cv_prog_ac_ct_AR+y} 4716then : 4717 printf %s "(cached) " >&6 4718else $as_nop 4719 if test -n "$ac_ct_AR"; then 4720 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 4721else 4722as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4723for as_dir in $PATH 4724do 4725 IFS=$as_save_IFS 4726 case $as_dir in #((( 4727 '') as_dir=./ ;; 4728 */) ;; 4729 *) as_dir=$as_dir/ ;; 4730 esac 4731 for ac_exec_ext in '' $ac_executable_extensions; do 4732 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 4733 ac_cv_prog_ac_ct_AR="$ac_prog" 4734 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 4735 break 2 4736 fi 4737done 4738 done 4739IFS=$as_save_IFS 4740 4741fi 4742fi 4743ac_ct_AR=$ac_cv_prog_ac_ct_AR 4744if test -n "$ac_ct_AR"; then 4745 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 4746printf "%s\n" "$ac_ct_AR" >&6; } 4747else 4748 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 4749printf "%s\n" "no" >&6; } 4750fi 4751 4752 4753 test -n "$ac_ct_AR" && break 4754done 4755 4756 if test "x$ac_ct_AR" = x; then 4757 AR="" 4758 else 4759 case $cross_compiling:$ac_tool_warned in 4760yes:) 4761{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 4762printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 4763ac_tool_warned=yes ;; 4764esac 4765 AR=$ac_ct_AR 4766 fi 4767fi 4768 4769# Extract the first word of "cat", so it can be a program name with args. 4770set dummy cat; ac_word=$2 4771{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4772printf %s "checking for $ac_word... " >&6; } 4773if test ${ac_cv_path_CAT+y} 4774then : 4775 printf %s "(cached) " >&6 4776else $as_nop 4777 case $CAT in 4778 [\\/]* | ?:[\\/]*) 4779 ac_cv_path_CAT="$CAT" # Let the user override the test with a path. 4780 ;; 4781 *) 4782 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4783for as_dir in $PATH 4784do 4785 IFS=$as_save_IFS 4786 case $as_dir in #((( 4787 '') as_dir=./ ;; 4788 */) ;; 4789 *) as_dir=$as_dir/ ;; 4790 esac 4791 for ac_exec_ext in '' $ac_executable_extensions; do 4792 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 4793 ac_cv_path_CAT="$as_dir$ac_word$ac_exec_ext" 4794 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 4795 break 2 4796 fi 4797done 4798 done 4799IFS=$as_save_IFS 4800 4801 ;; 4802esac 4803fi 4804CAT=$ac_cv_path_CAT 4805if test -n "$CAT"; then 4806 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5 4807printf "%s\n" "$CAT" >&6; } 4808else 4809 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 4810printf "%s\n" "no" >&6; } 4811fi 4812 4813 4814# Extract the first word of "kill", so it can be a program name with args. 4815set dummy kill; ac_word=$2 4816{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4817printf %s "checking for $ac_word... " >&6; } 4818if test ${ac_cv_path_KILL+y} 4819then : 4820 printf %s "(cached) " >&6 4821else $as_nop 4822 case $KILL in 4823 [\\/]* | ?:[\\/]*) 4824 ac_cv_path_KILL="$KILL" # Let the user override the test with a path. 4825 ;; 4826 *) 4827 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4828for as_dir in $PATH 4829do 4830 IFS=$as_save_IFS 4831 case $as_dir in #((( 4832 '') as_dir=./ ;; 4833 */) ;; 4834 *) as_dir=$as_dir/ ;; 4835 esac 4836 for ac_exec_ext in '' $ac_executable_extensions; do 4837 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 4838 ac_cv_path_KILL="$as_dir$ac_word$ac_exec_ext" 4839 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 4840 break 2 4841 fi 4842done 4843 done 4844IFS=$as_save_IFS 4845 4846 ;; 4847esac 4848fi 4849KILL=$ac_cv_path_KILL 4850if test -n "$KILL"; then 4851 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $KILL" >&5 4852printf "%s\n" "$KILL" >&6; } 4853else 4854 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 4855printf "%s\n" "no" >&6; } 4856fi 4857 4858 4859# Extract the first word of "sed", so it can be a program name with args. 4860set dummy sed; ac_word=$2 4861{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4862printf %s "checking for $ac_word... " >&6; } 4863if test ${ac_cv_path_SED+y} 4864then : 4865 printf %s "(cached) " >&6 4866else $as_nop 4867 case $SED in 4868 [\\/]* | ?:[\\/]*) 4869 ac_cv_path_SED="$SED" # Let the user override the test with a path. 4870 ;; 4871 *) 4872 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4873for as_dir in $PATH 4874do 4875 IFS=$as_save_IFS 4876 case $as_dir in #((( 4877 '') as_dir=./ ;; 4878 */) ;; 4879 *) as_dir=$as_dir/ ;; 4880 esac 4881 for ac_exec_ext in '' $ac_executable_extensions; do 4882 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 4883 ac_cv_path_SED="$as_dir$ac_word$ac_exec_ext" 4884 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 4885 break 2 4886 fi 4887done 4888 done 4889IFS=$as_save_IFS 4890 4891 ;; 4892esac 4893fi 4894SED=$ac_cv_path_SED 4895if test -n "$SED"; then 4896 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $SED" >&5 4897printf "%s\n" "$SED" >&6; } 4898else 4899 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 4900printf "%s\n" "no" >&6; } 4901fi 4902 4903 4904# Extract the first word of "bash", so it can be a program name with args. 4905set dummy bash; ac_word=$2 4906{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4907printf %s "checking for $ac_word... " >&6; } 4908if test ${ac_cv_path_TEST_MINUS_S_SH+y} 4909then : 4910 printf %s "(cached) " >&6 4911else $as_nop 4912 case $TEST_MINUS_S_SH in 4913 [\\/]* | ?:[\\/]*) 4914 ac_cv_path_TEST_MINUS_S_SH="$TEST_MINUS_S_SH" # Let the user override the test with a path. 4915 ;; 4916 *) 4917 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4918for as_dir in $PATH 4919do 4920 IFS=$as_save_IFS 4921 case $as_dir in #((( 4922 '') as_dir=./ ;; 4923 */) ;; 4924 *) as_dir=$as_dir/ ;; 4925 esac 4926 for ac_exec_ext in '' $ac_executable_extensions; do 4927 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 4928 ac_cv_path_TEST_MINUS_S_SH="$as_dir$ac_word$ac_exec_ext" 4929 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 4930 break 2 4931 fi 4932done 4933 done 4934IFS=$as_save_IFS 4935 4936 ;; 4937esac 4938fi 4939TEST_MINUS_S_SH=$ac_cv_path_TEST_MINUS_S_SH 4940if test -n "$TEST_MINUS_S_SH"; then 4941 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $TEST_MINUS_S_SH" >&5 4942printf "%s\n" "$TEST_MINUS_S_SH" >&6; } 4943else 4944 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 4945printf "%s\n" "no" >&6; } 4946fi 4947 4948 4949# Extract the first word of "ksh", so it can be a program name with args. 4950set dummy ksh; ac_word=$2 4951{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4952printf %s "checking for $ac_word... " >&6; } 4953if test ${ac_cv_path_TEST_MINUS_S_SH+y} 4954then : 4955 printf %s "(cached) " >&6 4956else $as_nop 4957 case $TEST_MINUS_S_SH in 4958 [\\/]* | ?:[\\/]*) 4959 ac_cv_path_TEST_MINUS_S_SH="$TEST_MINUS_S_SH" # Let the user override the test with a path. 4960 ;; 4961 *) 4962 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4963for as_dir in $PATH 4964do 4965 IFS=$as_save_IFS 4966 case $as_dir in #((( 4967 '') as_dir=./ ;; 4968 */) ;; 4969 *) as_dir=$as_dir/ ;; 4970 esac 4971 for ac_exec_ext in '' $ac_executable_extensions; do 4972 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 4973 ac_cv_path_TEST_MINUS_S_SH="$as_dir$ac_word$ac_exec_ext" 4974 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 4975 break 2 4976 fi 4977done 4978 done 4979IFS=$as_save_IFS 4980 4981 ;; 4982esac 4983fi 4984TEST_MINUS_S_SH=$ac_cv_path_TEST_MINUS_S_SH 4985if test -n "$TEST_MINUS_S_SH"; then 4986 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $TEST_MINUS_S_SH" >&5 4987printf "%s\n" "$TEST_MINUS_S_SH" >&6; } 4988else 4989 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 4990printf "%s\n" "no" >&6; } 4991fi 4992 4993 4994# Extract the first word of "sh", so it can be a program name with args. 4995set dummy sh; ac_word=$2 4996{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4997printf %s "checking for $ac_word... " >&6; } 4998if test ${ac_cv_path_TEST_MINUS_S_SH+y} 4999then : 5000 printf %s "(cached) " >&6 5001else $as_nop 5002 case $TEST_MINUS_S_SH in 5003 [\\/]* | ?:[\\/]*) 5004 ac_cv_path_TEST_MINUS_S_SH="$TEST_MINUS_S_SH" # Let the user override the test with a path. 5005 ;; 5006 *) 5007 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5008for as_dir in $PATH 5009do 5010 IFS=$as_save_IFS 5011 case $as_dir in #((( 5012 '') as_dir=./ ;; 5013 */) ;; 5014 *) as_dir=$as_dir/ ;; 5015 esac 5016 for ac_exec_ext in '' $ac_executable_extensions; do 5017 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 5018 ac_cv_path_TEST_MINUS_S_SH="$as_dir$ac_word$ac_exec_ext" 5019 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 5020 break 2 5021 fi 5022done 5023 done 5024IFS=$as_save_IFS 5025 5026 ;; 5027esac 5028fi 5029TEST_MINUS_S_SH=$ac_cv_path_TEST_MINUS_S_SH 5030if test -n "$TEST_MINUS_S_SH"; then 5031 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $TEST_MINUS_S_SH" >&5 5032printf "%s\n" "$TEST_MINUS_S_SH" >&6; } 5033else 5034 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 5035printf "%s\n" "no" >&6; } 5036fi 5037 5038 5039# Extract the first word of "bash", so it can be a program name with args. 5040set dummy bash; ac_word=$2 5041{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5042printf %s "checking for $ac_word... " >&6; } 5043if test ${ac_cv_path_SH+y} 5044then : 5045 printf %s "(cached) " >&6 5046else $as_nop 5047 case $SH in 5048 [\\/]* | ?:[\\/]*) 5049 ac_cv_path_SH="$SH" # Let the user override the test with a path. 5050 ;; 5051 *) 5052 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5053for as_dir in $PATH 5054do 5055 IFS=$as_save_IFS 5056 case $as_dir in #((( 5057 '') as_dir=./ ;; 5058 */) ;; 5059 *) as_dir=$as_dir/ ;; 5060 esac 5061 for ac_exec_ext in '' $ac_executable_extensions; do 5062 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 5063 ac_cv_path_SH="$as_dir$ac_word$ac_exec_ext" 5064 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 5065 break 2 5066 fi 5067done 5068 done 5069IFS=$as_save_IFS 5070 5071 ;; 5072esac 5073fi 5074SH=$ac_cv_path_SH 5075if test -n "$SH"; then 5076 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $SH" >&5 5077printf "%s\n" "$SH" >&6; } 5078else 5079 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 5080printf "%s\n" "no" >&6; } 5081fi 5082 5083 5084# Extract the first word of "ksh", so it can be a program name with args. 5085set dummy ksh; ac_word=$2 5086{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5087printf %s "checking for $ac_word... " >&6; } 5088if test ${ac_cv_path_SH+y} 5089then : 5090 printf %s "(cached) " >&6 5091else $as_nop 5092 case $SH in 5093 [\\/]* | ?:[\\/]*) 5094 ac_cv_path_SH="$SH" # Let the user override the test with a path. 5095 ;; 5096 *) 5097 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5098for as_dir in $PATH 5099do 5100 IFS=$as_save_IFS 5101 case $as_dir in #((( 5102 '') as_dir=./ ;; 5103 */) ;; 5104 *) as_dir=$as_dir/ ;; 5105 esac 5106 for ac_exec_ext in '' $ac_executable_extensions; do 5107 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 5108 ac_cv_path_SH="$as_dir$ac_word$ac_exec_ext" 5109 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 5110 break 2 5111 fi 5112done 5113 done 5114IFS=$as_save_IFS 5115 5116 ;; 5117esac 5118fi 5119SH=$ac_cv_path_SH 5120if test -n "$SH"; then 5121 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $SH" >&5 5122printf "%s\n" "$SH" >&6; } 5123else 5124 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 5125printf "%s\n" "no" >&6; } 5126fi 5127 5128 5129# Extract the first word of "sh", so it can be a program name with args. 5130set dummy sh; ac_word=$2 5131{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5132printf %s "checking for $ac_word... " >&6; } 5133if test ${ac_cv_path_SH+y} 5134then : 5135 printf %s "(cached) " >&6 5136else $as_nop 5137 case $SH in 5138 [\\/]* | ?:[\\/]*) 5139 ac_cv_path_SH="$SH" # Let the user override the test with a path. 5140 ;; 5141 *) 5142 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5143for as_dir in $PATH 5144do 5145 IFS=$as_save_IFS 5146 case $as_dir in #((( 5147 '') as_dir=./ ;; 5148 */) ;; 5149 *) as_dir=$as_dir/ ;; 5150 esac 5151 for ac_exec_ext in '' $ac_executable_extensions; do 5152 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 5153 ac_cv_path_SH="$as_dir$ac_word$ac_exec_ext" 5154 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 5155 break 2 5156 fi 5157done 5158 done 5159IFS=$as_save_IFS 5160 5161 ;; 5162esac 5163fi 5164SH=$ac_cv_path_SH 5165if test -n "$SH"; then 5166 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $SH" >&5 5167printf "%s\n" "$SH" >&6; } 5168else 5169 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 5170printf "%s\n" "no" >&6; } 5171fi 5172 5173 5174# Extract the first word of "groff", so it can be a program name with args. 5175set dummy groff; ac_word=$2 5176{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5177printf %s "checking for $ac_word... " >&6; } 5178if test ${ac_cv_path_GROFF+y} 5179then : 5180 printf %s "(cached) " >&6 5181else $as_nop 5182 case $GROFF in 5183 [\\/]* | ?:[\\/]*) 5184 ac_cv_path_GROFF="$GROFF" # Let the user override the test with a path. 5185 ;; 5186 *) 5187 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5188for as_dir in $PATH 5189do 5190 IFS=$as_save_IFS 5191 case $as_dir in #((( 5192 '') as_dir=./ ;; 5193 */) ;; 5194 *) as_dir=$as_dir/ ;; 5195 esac 5196 for ac_exec_ext in '' $ac_executable_extensions; do 5197 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 5198 ac_cv_path_GROFF="$as_dir$ac_word$ac_exec_ext" 5199 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 5200 break 2 5201 fi 5202done 5203 done 5204IFS=$as_save_IFS 5205 5206 ;; 5207esac 5208fi 5209GROFF=$ac_cv_path_GROFF 5210if test -n "$GROFF"; then 5211 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $GROFF" >&5 5212printf "%s\n" "$GROFF" >&6; } 5213else 5214 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 5215printf "%s\n" "no" >&6; } 5216fi 5217 5218 5219# Extract the first word of "nroff awf", so it can be a program name with args. 5220set dummy nroff awf; ac_word=$2 5221{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5222printf %s "checking for $ac_word... " >&6; } 5223if test ${ac_cv_path_NROFF+y} 5224then : 5225 printf %s "(cached) " >&6 5226else $as_nop 5227 case $NROFF in 5228 [\\/]* | ?:[\\/]*) 5229 ac_cv_path_NROFF="$NROFF" # Let the user override the test with a path. 5230 ;; 5231 *) 5232 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5233for as_dir in $PATH 5234do 5235 IFS=$as_save_IFS 5236 case $as_dir in #((( 5237 '') as_dir=./ ;; 5238 */) ;; 5239 *) as_dir=$as_dir/ ;; 5240 esac 5241 for ac_exec_ext in '' $ac_executable_extensions; do 5242 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 5243 ac_cv_path_NROFF="$as_dir$ac_word$ac_exec_ext" 5244 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 5245 break 2 5246 fi 5247done 5248 done 5249IFS=$as_save_IFS 5250 5251 ;; 5252esac 5253fi 5254NROFF=$ac_cv_path_NROFF 5255if test -n "$NROFF"; then 5256 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $NROFF" >&5 5257printf "%s\n" "$NROFF" >&6; } 5258else 5259 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 5260printf "%s\n" "no" >&6; } 5261fi 5262 5263 5264# Extract the first word of "mandoc", so it can be a program name with args. 5265set dummy mandoc; ac_word=$2 5266{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5267printf %s "checking for $ac_word... " >&6; } 5268if test ${ac_cv_path_MANDOC+y} 5269then : 5270 printf %s "(cached) " >&6 5271else $as_nop 5272 case $MANDOC in 5273 [\\/]* | ?:[\\/]*) 5274 ac_cv_path_MANDOC="$MANDOC" # Let the user override the test with a path. 5275 ;; 5276 *) 5277 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5278for as_dir in $PATH 5279do 5280 IFS=$as_save_IFS 5281 case $as_dir in #((( 5282 '') as_dir=./ ;; 5283 */) ;; 5284 *) as_dir=$as_dir/ ;; 5285 esac 5286 for ac_exec_ext in '' $ac_executable_extensions; do 5287 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 5288 ac_cv_path_MANDOC="$as_dir$ac_word$ac_exec_ext" 5289 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 5290 break 2 5291 fi 5292done 5293 done 5294IFS=$as_save_IFS 5295 5296 ;; 5297esac 5298fi 5299MANDOC=$ac_cv_path_MANDOC 5300if test -n "$MANDOC"; then 5301 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MANDOC" >&5 5302printf "%s\n" "$MANDOC" >&6; } 5303else 5304 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 5305printf "%s\n" "no" >&6; } 5306fi 5307 5308 5309if test -n "$ac_tool_prefix"; then 5310 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. 5311set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 5312{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5313printf %s "checking for $ac_word... " >&6; } 5314if test ${ac_cv_path_PKGCONFIG+y} 5315then : 5316 printf %s "(cached) " >&6 5317else $as_nop 5318 case $PKGCONFIG in 5319 [\\/]* | ?:[\\/]*) 5320 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path. 5321 ;; 5322 *) 5323 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5324for as_dir in $PATH 5325do 5326 IFS=$as_save_IFS 5327 case $as_dir in #((( 5328 '') as_dir=./ ;; 5329 */) ;; 5330 *) as_dir=$as_dir/ ;; 5331 esac 5332 for ac_exec_ext in '' $ac_executable_extensions; do 5333 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 5334 ac_cv_path_PKGCONFIG="$as_dir$ac_word$ac_exec_ext" 5335 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 5336 break 2 5337 fi 5338done 5339 done 5340IFS=$as_save_IFS 5341 5342 ;; 5343esac 5344fi 5345PKGCONFIG=$ac_cv_path_PKGCONFIG 5346if test -n "$PKGCONFIG"; then 5347 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5 5348printf "%s\n" "$PKGCONFIG" >&6; } 5349else 5350 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 5351printf "%s\n" "no" >&6; } 5352fi 5353 5354 5355fi 5356if test -z "$ac_cv_path_PKGCONFIG"; then 5357 ac_pt_PKGCONFIG=$PKGCONFIG 5358 # Extract the first word of "pkg-config", so it can be a program name with args. 5359set dummy pkg-config; ac_word=$2 5360{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5361printf %s "checking for $ac_word... " >&6; } 5362if test ${ac_cv_path_ac_pt_PKGCONFIG+y} 5363then : 5364 printf %s "(cached) " >&6 5365else $as_nop 5366 case $ac_pt_PKGCONFIG in 5367 [\\/]* | ?:[\\/]*) 5368 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path. 5369 ;; 5370 *) 5371 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5372for as_dir in $PATH 5373do 5374 IFS=$as_save_IFS 5375 case $as_dir in #((( 5376 '') as_dir=./ ;; 5377 */) ;; 5378 *) as_dir=$as_dir/ ;; 5379 esac 5380 for ac_exec_ext in '' $ac_executable_extensions; do 5381 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 5382 ac_cv_path_ac_pt_PKGCONFIG="$as_dir$ac_word$ac_exec_ext" 5383 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 5384 break 2 5385 fi 5386done 5387 done 5388IFS=$as_save_IFS 5389 5390 ;; 5391esac 5392fi 5393ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG 5394if test -n "$ac_pt_PKGCONFIG"; then 5395 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5 5396printf "%s\n" "$ac_pt_PKGCONFIG" >&6; } 5397else 5398 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 5399printf "%s\n" "no" >&6; } 5400fi 5401 5402 if test "x$ac_pt_PKGCONFIG" = x; then 5403 PKGCONFIG="no" 5404 else 5405 case $cross_compiling:$ac_tool_warned in 5406yes:) 5407{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 5408printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 5409ac_tool_warned=yes ;; 5410esac 5411 PKGCONFIG=$ac_pt_PKGCONFIG 5412 fi 5413else 5414 PKGCONFIG="$ac_cv_path_PKGCONFIG" 5415fi 5416 5417TEST_SHELL=sh 5418 5419 5420if test "x$MANDOC" != "x" ; then 5421 MANFMT="$MANDOC" 5422elif test "x$NROFF" != "x" ; then 5423 MANFMT="$NROFF -mandoc" 5424elif test "x$GROFF" != "x" ; then 5425 MANFMT="$GROFF -mandoc -Tascii" 5426else 5427 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: no manpage formatter found" >&5 5428printf "%s\n" "$as_me: WARNING: no manpage formatter found" >&2;} 5429 MANFMT="false" 5430fi 5431 5432 5433# Extract the first word of "groupadd", so it can be a program name with args. 5434set dummy groupadd; ac_word=$2 5435{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5436printf %s "checking for $ac_word... " >&6; } 5437if test ${ac_cv_path_PATH_GROUPADD_PROG+y} 5438then : 5439 printf %s "(cached) " >&6 5440else $as_nop 5441 case $PATH_GROUPADD_PROG in 5442 [\\/]* | ?:[\\/]*) 5443 ac_cv_path_PATH_GROUPADD_PROG="$PATH_GROUPADD_PROG" # Let the user override the test with a path. 5444 ;; 5445 *) 5446 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5447for as_dir in /usr/sbin${PATH_SEPARATOR}/etc 5448do 5449 IFS=$as_save_IFS 5450 case $as_dir in #((( 5451 '') as_dir=./ ;; 5452 */) ;; 5453 *) as_dir=$as_dir/ ;; 5454 esac 5455 for ac_exec_ext in '' $ac_executable_extensions; do 5456 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 5457 ac_cv_path_PATH_GROUPADD_PROG="$as_dir$ac_word$ac_exec_ext" 5458 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 5459 break 2 5460 fi 5461done 5462 done 5463IFS=$as_save_IFS 5464 5465 test -z "$ac_cv_path_PATH_GROUPADD_PROG" && ac_cv_path_PATH_GROUPADD_PROG="groupadd" 5466 ;; 5467esac 5468fi 5469PATH_GROUPADD_PROG=$ac_cv_path_PATH_GROUPADD_PROG 5470if test -n "$PATH_GROUPADD_PROG"; then 5471 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PATH_GROUPADD_PROG" >&5 5472printf "%s\n" "$PATH_GROUPADD_PROG" >&6; } 5473else 5474 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 5475printf "%s\n" "no" >&6; } 5476fi 5477 5478 5479# Extract the first word of "useradd", so it can be a program name with args. 5480set dummy useradd; ac_word=$2 5481{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5482printf %s "checking for $ac_word... " >&6; } 5483if test ${ac_cv_path_PATH_USERADD_PROG+y} 5484then : 5485 printf %s "(cached) " >&6 5486else $as_nop 5487 case $PATH_USERADD_PROG in 5488 [\\/]* | ?:[\\/]*) 5489 ac_cv_path_PATH_USERADD_PROG="$PATH_USERADD_PROG" # Let the user override the test with a path. 5490 ;; 5491 *) 5492 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5493for as_dir in /usr/sbin${PATH_SEPARATOR}/etc 5494do 5495 IFS=$as_save_IFS 5496 case $as_dir in #((( 5497 '') as_dir=./ ;; 5498 */) ;; 5499 *) as_dir=$as_dir/ ;; 5500 esac 5501 for ac_exec_ext in '' $ac_executable_extensions; do 5502 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 5503 ac_cv_path_PATH_USERADD_PROG="$as_dir$ac_word$ac_exec_ext" 5504 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 5505 break 2 5506 fi 5507done 5508 done 5509IFS=$as_save_IFS 5510 5511 test -z "$ac_cv_path_PATH_USERADD_PROG" && ac_cv_path_PATH_USERADD_PROG="useradd" 5512 ;; 5513esac 5514fi 5515PATH_USERADD_PROG=$ac_cv_path_PATH_USERADD_PROG 5516if test -n "$PATH_USERADD_PROG"; then 5517 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PATH_USERADD_PROG" >&5 5518printf "%s\n" "$PATH_USERADD_PROG" >&6; } 5519else 5520 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 5521printf "%s\n" "no" >&6; } 5522fi 5523 5524 5525# Extract the first word of "pkgmk", so it can be a program name with args. 5526set dummy pkgmk; ac_word=$2 5527{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5528printf %s "checking for $ac_word... " >&6; } 5529if test ${ac_cv_prog_MAKE_PACKAGE_SUPPORTED+y} 5530then : 5531 printf %s "(cached) " >&6 5532else $as_nop 5533 if test -n "$MAKE_PACKAGE_SUPPORTED"; then 5534 ac_cv_prog_MAKE_PACKAGE_SUPPORTED="$MAKE_PACKAGE_SUPPORTED" # Let the user override the test. 5535else 5536as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5537for as_dir in $PATH 5538do 5539 IFS=$as_save_IFS 5540 case $as_dir in #((( 5541 '') as_dir=./ ;; 5542 */) ;; 5543 *) as_dir=$as_dir/ ;; 5544 esac 5545 for ac_exec_ext in '' $ac_executable_extensions; do 5546 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 5547 ac_cv_prog_MAKE_PACKAGE_SUPPORTED="yes" 5548 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 5549 break 2 5550 fi 5551done 5552 done 5553IFS=$as_save_IFS 5554 5555 test -z "$ac_cv_prog_MAKE_PACKAGE_SUPPORTED" && ac_cv_prog_MAKE_PACKAGE_SUPPORTED="no" 5556fi 5557fi 5558MAKE_PACKAGE_SUPPORTED=$ac_cv_prog_MAKE_PACKAGE_SUPPORTED 5559if test -n "$MAKE_PACKAGE_SUPPORTED"; then 5560 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MAKE_PACKAGE_SUPPORTED" >&5 5561printf "%s\n" "$MAKE_PACKAGE_SUPPORTED" >&6; } 5562else 5563 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 5564printf "%s\n" "no" >&6; } 5565fi 5566 5567 5568if test -x /sbin/sh; then 5569 STARTUP_SCRIPT_SHELL=/sbin/sh 5570 5571else 5572 STARTUP_SCRIPT_SHELL=/bin/sh 5573 5574fi 5575 5576# System features 5577# Check whether --enable-largefile was given. 5578if test ${enable_largefile+y} 5579then : 5580 enableval=$enable_largefile; 5581fi 5582 5583if test "$enable_largefile" != no; then 5584 5585 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5 5586printf %s "checking for special C compiler options needed for large files... " >&6; } 5587if test ${ac_cv_sys_largefile_CC+y} 5588then : 5589 printf %s "(cached) " >&6 5590else $as_nop 5591 ac_cv_sys_largefile_CC=no 5592 if test "$GCC" != yes; then 5593 ac_save_CC=$CC 5594 while :; do 5595 # IRIX 6.2 and later do not support large files by default, 5596 # so use the C compiler's -n32 option if that helps. 5597 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 5598/* end confdefs.h. */ 5599#include <sys/types.h> 5600 /* Check that off_t can represent 2**63 - 1 correctly. 5601 We can't simply define LARGE_OFF_T to be 9223372036854775807, 5602 since some C++ compilers masquerading as C compilers 5603 incorrectly reject 9223372036854775807. */ 5604#define LARGE_OFF_T (((off_t) 1 << 31 << 31) - 1 + ((off_t) 1 << 31 << 31)) 5605 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 5606 && LARGE_OFF_T % 2147483647 == 1) 5607 ? 1 : -1]; 5608int 5609main (void) 5610{ 5611 5612 ; 5613 return 0; 5614} 5615_ACEOF 5616 if ac_fn_c_try_compile "$LINENO" 5617then : 5618 break 5619fi 5620rm -f core conftest.err conftest.$ac_objext conftest.beam 5621 CC="$CC -n32" 5622 if ac_fn_c_try_compile "$LINENO" 5623then : 5624 ac_cv_sys_largefile_CC=' -n32'; break 5625fi 5626rm -f core conftest.err conftest.$ac_objext conftest.beam 5627 break 5628 done 5629 CC=$ac_save_CC 5630 rm -f conftest.$ac_ext 5631 fi 5632fi 5633{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5 5634printf "%s\n" "$ac_cv_sys_largefile_CC" >&6; } 5635 if test "$ac_cv_sys_largefile_CC" != no; then 5636 CC=$CC$ac_cv_sys_largefile_CC 5637 fi 5638 5639 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5 5640printf %s "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; } 5641if test ${ac_cv_sys_file_offset_bits+y} 5642then : 5643 printf %s "(cached) " >&6 5644else $as_nop 5645 while :; do 5646 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 5647/* end confdefs.h. */ 5648#include <sys/types.h> 5649 /* Check that off_t can represent 2**63 - 1 correctly. 5650 We can't simply define LARGE_OFF_T to be 9223372036854775807, 5651 since some C++ compilers masquerading as C compilers 5652 incorrectly reject 9223372036854775807. */ 5653#define LARGE_OFF_T (((off_t) 1 << 31 << 31) - 1 + ((off_t) 1 << 31 << 31)) 5654 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 5655 && LARGE_OFF_T % 2147483647 == 1) 5656 ? 1 : -1]; 5657int 5658main (void) 5659{ 5660 5661 ; 5662 return 0; 5663} 5664_ACEOF 5665if ac_fn_c_try_compile "$LINENO" 5666then : 5667 ac_cv_sys_file_offset_bits=no; break 5668fi 5669rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 5670 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 5671/* end confdefs.h. */ 5672#define _FILE_OFFSET_BITS 64 5673#include <sys/types.h> 5674 /* Check that off_t can represent 2**63 - 1 correctly. 5675 We can't simply define LARGE_OFF_T to be 9223372036854775807, 5676 since some C++ compilers masquerading as C compilers 5677 incorrectly reject 9223372036854775807. */ 5678#define LARGE_OFF_T (((off_t) 1 << 31 << 31) - 1 + ((off_t) 1 << 31 << 31)) 5679 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 5680 && LARGE_OFF_T % 2147483647 == 1) 5681 ? 1 : -1]; 5682int 5683main (void) 5684{ 5685 5686 ; 5687 return 0; 5688} 5689_ACEOF 5690if ac_fn_c_try_compile "$LINENO" 5691then : 5692 ac_cv_sys_file_offset_bits=64; break 5693fi 5694rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 5695 ac_cv_sys_file_offset_bits=unknown 5696 break 5697done 5698fi 5699{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5 5700printf "%s\n" "$ac_cv_sys_file_offset_bits" >&6; } 5701case $ac_cv_sys_file_offset_bits in #( 5702 no | unknown) ;; 5703 *) 5704printf "%s\n" "#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits" >>confdefs.h 5705;; 5706esac 5707rm -rf conftest* 5708 if test $ac_cv_sys_file_offset_bits = unknown; then 5709 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5 5710printf %s "checking for _LARGE_FILES value needed for large files... " >&6; } 5711if test ${ac_cv_sys_large_files+y} 5712then : 5713 printf %s "(cached) " >&6 5714else $as_nop 5715 while :; do 5716 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 5717/* end confdefs.h. */ 5718#include <sys/types.h> 5719 /* Check that off_t can represent 2**63 - 1 correctly. 5720 We can't simply define LARGE_OFF_T to be 9223372036854775807, 5721 since some C++ compilers masquerading as C compilers 5722 incorrectly reject 9223372036854775807. */ 5723#define LARGE_OFF_T (((off_t) 1 << 31 << 31) - 1 + ((off_t) 1 << 31 << 31)) 5724 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 5725 && LARGE_OFF_T % 2147483647 == 1) 5726 ? 1 : -1]; 5727int 5728main (void) 5729{ 5730 5731 ; 5732 return 0; 5733} 5734_ACEOF 5735if ac_fn_c_try_compile "$LINENO" 5736then : 5737 ac_cv_sys_large_files=no; break 5738fi 5739rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 5740 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 5741/* end confdefs.h. */ 5742#define _LARGE_FILES 1 5743#include <sys/types.h> 5744 /* Check that off_t can represent 2**63 - 1 correctly. 5745 We can't simply define LARGE_OFF_T to be 9223372036854775807, 5746 since some C++ compilers masquerading as C compilers 5747 incorrectly reject 9223372036854775807. */ 5748#define LARGE_OFF_T (((off_t) 1 << 31 << 31) - 1 + ((off_t) 1 << 31 << 31)) 5749 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 5750 && LARGE_OFF_T % 2147483647 == 1) 5751 ? 1 : -1]; 5752int 5753main (void) 5754{ 5755 5756 ; 5757 return 0; 5758} 5759_ACEOF 5760if ac_fn_c_try_compile "$LINENO" 5761then : 5762 ac_cv_sys_large_files=1; break 5763fi 5764rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 5765 ac_cv_sys_large_files=unknown 5766 break 5767done 5768fi 5769{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5 5770printf "%s\n" "$ac_cv_sys_large_files" >&6; } 5771case $ac_cv_sys_large_files in #( 5772 no | unknown) ;; 5773 *) 5774printf "%s\n" "#define _LARGE_FILES $ac_cv_sys_large_files" >>confdefs.h 5775;; 5776esac 5777rm -rf conftest* 5778 fi 5779fi 5780 5781 5782if test -z "$AR" ; then 5783 as_fn_error $? "*** 'ar' missing, please install or fix your \$PATH ***" "$LINENO" 5 5784fi 5785 5786# Extract the first word of "passwd", so it can be a program name with args. 5787set dummy passwd; ac_word=$2 5788{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5789printf %s "checking for $ac_word... " >&6; } 5790if test ${ac_cv_path_PATH_PASSWD_PROG+y} 5791then : 5792 printf %s "(cached) " >&6 5793else $as_nop 5794 case $PATH_PASSWD_PROG in 5795 [\\/]* | ?:[\\/]*) 5796 ac_cv_path_PATH_PASSWD_PROG="$PATH_PASSWD_PROG" # Let the user override the test with a path. 5797 ;; 5798 *) 5799 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5800for as_dir in $PATH 5801do 5802 IFS=$as_save_IFS 5803 case $as_dir in #((( 5804 '') as_dir=./ ;; 5805 */) ;; 5806 *) as_dir=$as_dir/ ;; 5807 esac 5808 for ac_exec_ext in '' $ac_executable_extensions; do 5809 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 5810 ac_cv_path_PATH_PASSWD_PROG="$as_dir$ac_word$ac_exec_ext" 5811 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 5812 break 2 5813 fi 5814done 5815 done 5816IFS=$as_save_IFS 5817 5818 ;; 5819esac 5820fi 5821PATH_PASSWD_PROG=$ac_cv_path_PATH_PASSWD_PROG 5822if test -n "$PATH_PASSWD_PROG"; then 5823 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PATH_PASSWD_PROG" >&5 5824printf "%s\n" "$PATH_PASSWD_PROG" >&6; } 5825else 5826 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 5827printf "%s\n" "no" >&6; } 5828fi 5829 5830 5831if test ! -z "$PATH_PASSWD_PROG" ; then 5832 5833printf "%s\n" "#define _PATH_PASSWD_PROG \"$PATH_PASSWD_PROG\"" >>confdefs.h 5834 5835fi 5836 5837LD="$CC" 5838 5839 5840{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 5841printf %s "checking for inline... " >&6; } 5842if test ${ac_cv_c_inline+y} 5843then : 5844 printf %s "(cached) " >&6 5845else $as_nop 5846 ac_cv_c_inline=no 5847for ac_kw in inline __inline__ __inline; do 5848 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 5849/* end confdefs.h. */ 5850#ifndef __cplusplus 5851typedef int foo_t; 5852static $ac_kw foo_t static_foo (void) {return 0; } 5853$ac_kw foo_t foo (void) {return 0; } 5854#endif 5855 5856_ACEOF 5857if ac_fn_c_try_compile "$LINENO" 5858then : 5859 ac_cv_c_inline=$ac_kw 5860fi 5861rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 5862 test "$ac_cv_c_inline" != no && break 5863done 5864 5865fi 5866{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 5867printf "%s\n" "$ac_cv_c_inline" >&6; } 5868 5869case $ac_cv_c_inline in 5870 inline | yes) ;; 5871 *) 5872 case $ac_cv_c_inline in 5873 no) ac_val=;; 5874 *) ac_val=$ac_cv_c_inline;; 5875 esac 5876 cat >>confdefs.h <<_ACEOF 5877#ifndef __cplusplus 5878#define inline $ac_val 5879#endif 5880_ACEOF 5881 ;; 5882esac 5883 5884 5885{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC options needed to detect all undeclared functions" >&5 5886printf %s "checking for $CC options needed to detect all undeclared functions... " >&6; } 5887if test ${ac_cv_c_undeclared_builtin_options+y} 5888then : 5889 printf %s "(cached) " >&6 5890else $as_nop 5891 ac_save_CFLAGS=$CFLAGS 5892 ac_cv_c_undeclared_builtin_options='cannot detect' 5893 for ac_arg in '' -fno-builtin; do 5894 CFLAGS="$ac_save_CFLAGS $ac_arg" 5895 # This test program should *not* compile successfully. 5896 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 5897/* end confdefs.h. */ 5898 5899int 5900main (void) 5901{ 5902(void) strchr; 5903 ; 5904 return 0; 5905} 5906_ACEOF 5907if ac_fn_c_try_compile "$LINENO" 5908then : 5909 5910else $as_nop 5911 # This test program should compile successfully. 5912 # No library function is consistently available on 5913 # freestanding implementations, so test against a dummy 5914 # declaration. Include always-available headers on the 5915 # off chance that they somehow elicit warnings. 5916 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 5917/* end confdefs.h. */ 5918#include <float.h> 5919#include <limits.h> 5920#include <stdarg.h> 5921#include <stddef.h> 5922extern void ac_decl (int, char *); 5923 5924int 5925main (void) 5926{ 5927(void) ac_decl (0, (char *) 0); 5928 (void) ac_decl; 5929 5930 ; 5931 return 0; 5932} 5933_ACEOF 5934if ac_fn_c_try_compile "$LINENO" 5935then : 5936 if test x"$ac_arg" = x 5937then : 5938 ac_cv_c_undeclared_builtin_options='none needed' 5939else $as_nop 5940 ac_cv_c_undeclared_builtin_options=$ac_arg 5941fi 5942 break 5943fi 5944rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 5945fi 5946rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 5947 done 5948 CFLAGS=$ac_save_CFLAGS 5949 5950fi 5951{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_undeclared_builtin_options" >&5 5952printf "%s\n" "$ac_cv_c_undeclared_builtin_options" >&6; } 5953 case $ac_cv_c_undeclared_builtin_options in #( 5954 'cannot detect') : 5955 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 5956printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} 5957as_fn_error $? "cannot make $CC report undeclared builtins 5958See \`config.log' for more details" "$LINENO" 5; } ;; #( 5959 'none needed') : 5960 ac_c_undeclared_builtin_options='' ;; #( 5961 *) : 5962 ac_c_undeclared_builtin_options=$ac_cv_c_undeclared_builtin_options ;; 5963esac 5964 5965ac_fn_check_decl "$LINENO" "LLONG_MAX" "ac_cv_have_decl_LLONG_MAX" "#include <limits.h> 5966" "$ac_c_undeclared_builtin_options" "CFLAGS" 5967if test "x$ac_cv_have_decl_LLONG_MAX" = xyes 5968then : 5969 have_llong_max=1 5970fi 5971ac_fn_check_decl "$LINENO" "LONG_LONG_MAX" "ac_cv_have_decl_LONG_LONG_MAX" "#include <limits.h> 5972" "$ac_c_undeclared_builtin_options" "CFLAGS" 5973if test "x$ac_cv_have_decl_LONG_LONG_MAX" = xyes 5974then : 5975 have_long_long_max=1 5976fi 5977ac_fn_check_decl "$LINENO" "SYSTR_POLICY_KILL" "ac_cv_have_decl_SYSTR_POLICY_KILL" " 5978 #include <sys/types.h> 5979 #include <sys/param.h> 5980 #include <dev/systrace.h> 5981 5982" "$ac_c_undeclared_builtin_options" "CFLAGS" 5983if test "x$ac_cv_have_decl_SYSTR_POLICY_KILL" = xyes 5984then : 5985 have_systr_policy_kill=1 5986fi 5987ac_fn_check_decl "$LINENO" "RLIMIT_NPROC" "ac_cv_have_decl_RLIMIT_NPROC" " 5988 #include <sys/types.h> 5989 #include <sys/resource.h> 5990 5991" "$ac_c_undeclared_builtin_options" "CFLAGS" 5992if test "x$ac_cv_have_decl_RLIMIT_NPROC" = xyes 5993then : 5994 5995printf "%s\n" "#define HAVE_RLIMIT_NPROC /**/" >>confdefs.h 5996 5997fi 5998ac_fn_check_decl "$LINENO" "PR_SET_NO_NEW_PRIVS" "ac_cv_have_decl_PR_SET_NO_NEW_PRIVS" " 5999 #include <sys/types.h> 6000 #include <linux/prctl.h> 6001 6002" "$ac_c_undeclared_builtin_options" "CFLAGS" 6003if test "x$ac_cv_have_decl_PR_SET_NO_NEW_PRIVS" = xyes 6004then : 6005 have_linux_no_new_privs=1 6006fi 6007 6008openssl=yes 6009openssl_bin=openssl 6010 6011# Check whether --with-openssl was given. 6012if test ${with_openssl+y} 6013then : 6014 withval=$with_openssl; if test "x$withval" = "xno" ; then 6015 openssl=no 6016 openssl_bin="" 6017 fi 6018 6019 6020fi 6021 6022{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether OpenSSL will be used for cryptography" >&5 6023printf %s "checking whether OpenSSL will be used for cryptography... " >&6; } 6024if test "x$openssl" = "xyes" ; then 6025 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 6026printf "%s\n" "yes" >&6; } 6027 6028printf "%s\n" "#define WITH_OPENSSL 1" >>confdefs.h 6029 6030else 6031 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 6032printf "%s\n" "no" >&6; } 6033fi 6034 6035use_stack_protector=1 6036use_toolchain_hardening=1 6037use_retpoline=1 6038 6039# Check whether --with-stackprotect was given. 6040if test ${with_stackprotect+y} 6041then : 6042 withval=$with_stackprotect; 6043 if test "x$withval" = "xno"; then 6044 use_stack_protector=0 6045 fi 6046fi 6047 6048 6049# Check whether --with-hardening was given. 6050if test ${with_hardening+y} 6051then : 6052 withval=$with_hardening; 6053 if test "x$withval" = "xno"; then 6054 use_toolchain_hardening=0 6055 fi 6056fi 6057 6058 6059# Check whether --with-retpoline was given. 6060if test ${with_retpoline+y} 6061then : 6062 withval=$with_retpoline; 6063 if test "x$withval" = "xno"; then 6064 use_retpoline=0 6065 fi 6066fi 6067 6068 6069# We use -Werror for the tests only so that we catch warnings like "this is 6070# on by default" for things like -fPIE. 6071{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC supports -Werror" >&5 6072printf %s "checking if $CC supports -Werror... " >&6; } 6073saved_CFLAGS="$CFLAGS" 6074CFLAGS="$CFLAGS -Werror" 6075cat confdefs.h - <<_ACEOF >conftest.$ac_ext 6076/* end confdefs.h. */ 6077int main(void) { return 0; } 6078_ACEOF 6079if ac_fn_c_try_compile "$LINENO" 6080then : 6081 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 6082printf "%s\n" "yes" >&6; } 6083 WERROR="-Werror" 6084else $as_nop 6085 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 6086printf "%s\n" "no" >&6; } 6087 WERROR="" 6088 6089fi 6090rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 6091CFLAGS="$saved_CFLAGS" 6092 6093if test "$GCC" = "yes" || test "$GCC" = "egcs"; then 6094 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking gcc version" >&5 6095printf %s "checking gcc version... " >&6; } 6096 GCC_VER=`$CC -v 2>&1 | $AWK '/gcc version /{print $3}'` 6097 case "$GCC_VER" in 6098 1.*) no_attrib_nonnull=1 ;; 6099 2.8* | 2.9*) 6100 no_attrib_nonnull=1 6101 ;; 6102 2.*) no_attrib_nonnull=1 ;; 6103 *) ;; 6104 esac 6105 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $GCC_VER" >&5 6106printf "%s\n" "$GCC_VER" >&6; } 6107 6108 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking clang version" >&5 6109printf %s "checking clang version... " >&6; } 6110 ver="`$CC -v 2>&1`" 6111 if echo "$ver" | grep "Apple" >/dev/null; then 6112 CLANG_VER=apple-`echo "$ver" | grep 'clang version' | \ 6113 $SED 's/.*clang version //g' | $AWK '{print $1}'` 6114 else 6115 CLANG_VER=`echo "$ver" | grep 'clang version' | \ 6116 $SED 's/.*clang version //g' | $AWK '{print $1}'` 6117 fi 6118 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CLANG_VER" >&5 6119printf "%s\n" "$CLANG_VER" >&6; } 6120 6121 { 6122 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC supports compile flag -pipe" >&5 6123printf %s "checking if $CC supports compile flag -pipe... " >&6; } 6124 saved_CFLAGS="$CFLAGS" 6125 CFLAGS="$CFLAGS $WERROR -pipe" 6126 _define_flag="" 6127 test "x$_define_flag" = "x" && _define_flag="-pipe" 6128 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 6129/* end confdefs.h. */ 6130 6131#include <stdlib.h> 6132#include <stdarg.h> 6133#include <stdio.h> 6134#include <string.h> 6135#include <unistd.h> 6136/* Trivial function to help test for -fzero-call-used-regs */ 6137int f(int n) {return rand() % n;} 6138char *f2(char *s, ...) { 6139 char ret[64]; 6140 va_list args; 6141 va_start(args, s); 6142 vsnprintf(ret, sizeof(ret), s, args); 6143 va_end(args); 6144 return strdup(ret); 6145} 6146int i; 6147double d; 6148const char *f3(int s) { 6149 i = (int)d; 6150 return s ? "good" : "gooder"; 6151} 6152int main(int argc, char **argv) { 6153 char b[256], *cp; 6154 const char *s; 6155 /* Some math to catch -ftrapv problems in the toolchain */ 6156 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 6157 float l = i * 2.1; 6158 double m = l / 0.5; 6159 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 6160 (void)argv; 6161 f(1); 6162 s = f3(f(2)); 6163 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 6164 if (write(1, b, 0) == -1) exit(0); 6165 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 6166 if (write(1, cp, 0) == -1) exit(0); 6167 free(cp); 6168 /* 6169 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 6170 * not understand comments and we don't use the "fallthrough" attribute 6171 * that it's looking for. 6172 */ 6173 switch(i){ 6174 case 0: j += i; 6175 /* FALLTHROUGH */ 6176 default: j += k; 6177 } 6178 exit(0); 6179} 6180 6181 6182_ACEOF 6183if ac_fn_c_try_compile "$LINENO" 6184then : 6185 6186if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 6187then 6188 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 6189printf "%s\n" "no" >&6; } 6190 CFLAGS="$saved_CFLAGS" 6191else 6192 if test "$cross_compiling" = yes 6193then : 6194 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 6195printf "%s\n" "yes" >&6; } 6196 CFLAGS="$saved_CFLAGS $_define_flag" 6197else $as_nop 6198 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 6199/* end confdefs.h. */ 6200 6201#include <stdlib.h> 6202#include <stdarg.h> 6203#include <stdio.h> 6204#include <string.h> 6205#include <unistd.h> 6206/* Trivial function to help test for -fzero-call-used-regs */ 6207int f(int n) {return rand() % n;} 6208char *f2(char *s, ...) { 6209 char ret[64]; 6210 va_list args; 6211 va_start(args, s); 6212 vsnprintf(ret, sizeof(ret), s, args); 6213 va_end(args); 6214 return strdup(ret); 6215} 6216int i; 6217double d; 6218const char *f3(int s) { 6219 i = (int)d; 6220 return s ? "good" : "gooder"; 6221} 6222int main(int argc, char **argv) { 6223 char b[256], *cp; 6224 const char *s; 6225 /* Some math to catch -ftrapv problems in the toolchain */ 6226 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 6227 float l = i * 2.1; 6228 double m = l / 0.5; 6229 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 6230 (void)argv; 6231 f(1); 6232 s = f3(f(2)); 6233 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 6234 if (write(1, b, 0) == -1) exit(0); 6235 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 6236 if (write(1, cp, 0) == -1) exit(0); 6237 free(cp); 6238 /* 6239 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 6240 * not understand comments and we don't use the "fallthrough" attribute 6241 * that it's looking for. 6242 */ 6243 switch(i){ 6244 case 0: j += i; 6245 /* FALLTHROUGH */ 6246 default: j += k; 6247 } 6248 exit(0); 6249} 6250 6251 6252_ACEOF 6253if ac_fn_c_try_run "$LINENO" 6254then : 6255 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 6256printf "%s\n" "yes" >&6; } 6257 CFLAGS="$saved_CFLAGS $_define_flag" 6258else $as_nop 6259 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 6260printf "%s\n" "no, fails at run time" >&6; } 6261 CFLAGS="$saved_CFLAGS" 6262fi 6263rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 6264 conftest.$ac_objext conftest.beam conftest.$ac_ext 6265fi 6266 6267fi 6268else $as_nop 6269 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 6270printf "%s\n" "no" >&6; } 6271 CFLAGS="$saved_CFLAGS" 6272 6273fi 6274rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 6275} 6276 { 6277 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC supports compile flag -Wunknown-warning-option" >&5 6278printf %s "checking if $CC supports compile flag -Wunknown-warning-option... " >&6; } 6279 saved_CFLAGS="$CFLAGS" 6280 CFLAGS="$CFLAGS $WERROR -Wunknown-warning-option" 6281 _define_flag="" 6282 test "x$_define_flag" = "x" && _define_flag="-Wunknown-warning-option" 6283 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 6284/* end confdefs.h. */ 6285 6286#include <stdlib.h> 6287#include <stdarg.h> 6288#include <stdio.h> 6289#include <string.h> 6290#include <unistd.h> 6291/* Trivial function to help test for -fzero-call-used-regs */ 6292int f(int n) {return rand() % n;} 6293char *f2(char *s, ...) { 6294 char ret[64]; 6295 va_list args; 6296 va_start(args, s); 6297 vsnprintf(ret, sizeof(ret), s, args); 6298 va_end(args); 6299 return strdup(ret); 6300} 6301int i; 6302double d; 6303const char *f3(int s) { 6304 i = (int)d; 6305 return s ? "good" : "gooder"; 6306} 6307int main(int argc, char **argv) { 6308 char b[256], *cp; 6309 const char *s; 6310 /* Some math to catch -ftrapv problems in the toolchain */ 6311 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 6312 float l = i * 2.1; 6313 double m = l / 0.5; 6314 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 6315 (void)argv; 6316 f(1); 6317 s = f3(f(2)); 6318 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 6319 if (write(1, b, 0) == -1) exit(0); 6320 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 6321 if (write(1, cp, 0) == -1) exit(0); 6322 free(cp); 6323 /* 6324 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 6325 * not understand comments and we don't use the "fallthrough" attribute 6326 * that it's looking for. 6327 */ 6328 switch(i){ 6329 case 0: j += i; 6330 /* FALLTHROUGH */ 6331 default: j += k; 6332 } 6333 exit(0); 6334} 6335 6336 6337_ACEOF 6338if ac_fn_c_try_compile "$LINENO" 6339then : 6340 6341if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 6342then 6343 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 6344printf "%s\n" "no" >&6; } 6345 CFLAGS="$saved_CFLAGS" 6346else 6347 if test "$cross_compiling" = yes 6348then : 6349 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 6350printf "%s\n" "yes" >&6; } 6351 CFLAGS="$saved_CFLAGS $_define_flag" 6352else $as_nop 6353 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 6354/* end confdefs.h. */ 6355 6356#include <stdlib.h> 6357#include <stdarg.h> 6358#include <stdio.h> 6359#include <string.h> 6360#include <unistd.h> 6361/* Trivial function to help test for -fzero-call-used-regs */ 6362int f(int n) {return rand() % n;} 6363char *f2(char *s, ...) { 6364 char ret[64]; 6365 va_list args; 6366 va_start(args, s); 6367 vsnprintf(ret, sizeof(ret), s, args); 6368 va_end(args); 6369 return strdup(ret); 6370} 6371int i; 6372double d; 6373const char *f3(int s) { 6374 i = (int)d; 6375 return s ? "good" : "gooder"; 6376} 6377int main(int argc, char **argv) { 6378 char b[256], *cp; 6379 const char *s; 6380 /* Some math to catch -ftrapv problems in the toolchain */ 6381 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 6382 float l = i * 2.1; 6383 double m = l / 0.5; 6384 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 6385 (void)argv; 6386 f(1); 6387 s = f3(f(2)); 6388 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 6389 if (write(1, b, 0) == -1) exit(0); 6390 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 6391 if (write(1, cp, 0) == -1) exit(0); 6392 free(cp); 6393 /* 6394 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 6395 * not understand comments and we don't use the "fallthrough" attribute 6396 * that it's looking for. 6397 */ 6398 switch(i){ 6399 case 0: j += i; 6400 /* FALLTHROUGH */ 6401 default: j += k; 6402 } 6403 exit(0); 6404} 6405 6406 6407_ACEOF 6408if ac_fn_c_try_run "$LINENO" 6409then : 6410 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 6411printf "%s\n" "yes" >&6; } 6412 CFLAGS="$saved_CFLAGS $_define_flag" 6413else $as_nop 6414 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 6415printf "%s\n" "no, fails at run time" >&6; } 6416 CFLAGS="$saved_CFLAGS" 6417fi 6418rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 6419 conftest.$ac_objext conftest.beam conftest.$ac_ext 6420fi 6421 6422fi 6423else $as_nop 6424 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 6425printf "%s\n" "no" >&6; } 6426 CFLAGS="$saved_CFLAGS" 6427 6428fi 6429rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 6430} 6431 { 6432 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC supports compile flag -Wno-error=format-truncation" >&5 6433printf %s "checking if $CC supports compile flag -Wno-error=format-truncation... " >&6; } 6434 saved_CFLAGS="$CFLAGS" 6435 CFLAGS="$CFLAGS $WERROR -Wno-error=format-truncation" 6436 _define_flag="" 6437 test "x$_define_flag" = "x" && _define_flag="-Wno-error=format-truncation" 6438 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 6439/* end confdefs.h. */ 6440 6441#include <stdlib.h> 6442#include <stdarg.h> 6443#include <stdio.h> 6444#include <string.h> 6445#include <unistd.h> 6446/* Trivial function to help test for -fzero-call-used-regs */ 6447int f(int n) {return rand() % n;} 6448char *f2(char *s, ...) { 6449 char ret[64]; 6450 va_list args; 6451 va_start(args, s); 6452 vsnprintf(ret, sizeof(ret), s, args); 6453 va_end(args); 6454 return strdup(ret); 6455} 6456int i; 6457double d; 6458const char *f3(int s) { 6459 i = (int)d; 6460 return s ? "good" : "gooder"; 6461} 6462int main(int argc, char **argv) { 6463 char b[256], *cp; 6464 const char *s; 6465 /* Some math to catch -ftrapv problems in the toolchain */ 6466 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 6467 float l = i * 2.1; 6468 double m = l / 0.5; 6469 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 6470 (void)argv; 6471 f(1); 6472 s = f3(f(2)); 6473 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 6474 if (write(1, b, 0) == -1) exit(0); 6475 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 6476 if (write(1, cp, 0) == -1) exit(0); 6477 free(cp); 6478 /* 6479 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 6480 * not understand comments and we don't use the "fallthrough" attribute 6481 * that it's looking for. 6482 */ 6483 switch(i){ 6484 case 0: j += i; 6485 /* FALLTHROUGH */ 6486 default: j += k; 6487 } 6488 exit(0); 6489} 6490 6491 6492_ACEOF 6493if ac_fn_c_try_compile "$LINENO" 6494then : 6495 6496if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 6497then 6498 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 6499printf "%s\n" "no" >&6; } 6500 CFLAGS="$saved_CFLAGS" 6501else 6502 if test "$cross_compiling" = yes 6503then : 6504 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 6505printf "%s\n" "yes" >&6; } 6506 CFLAGS="$saved_CFLAGS $_define_flag" 6507else $as_nop 6508 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 6509/* end confdefs.h. */ 6510 6511#include <stdlib.h> 6512#include <stdarg.h> 6513#include <stdio.h> 6514#include <string.h> 6515#include <unistd.h> 6516/* Trivial function to help test for -fzero-call-used-regs */ 6517int f(int n) {return rand() % n;} 6518char *f2(char *s, ...) { 6519 char ret[64]; 6520 va_list args; 6521 va_start(args, s); 6522 vsnprintf(ret, sizeof(ret), s, args); 6523 va_end(args); 6524 return strdup(ret); 6525} 6526int i; 6527double d; 6528const char *f3(int s) { 6529 i = (int)d; 6530 return s ? "good" : "gooder"; 6531} 6532int main(int argc, char **argv) { 6533 char b[256], *cp; 6534 const char *s; 6535 /* Some math to catch -ftrapv problems in the toolchain */ 6536 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 6537 float l = i * 2.1; 6538 double m = l / 0.5; 6539 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 6540 (void)argv; 6541 f(1); 6542 s = f3(f(2)); 6543 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 6544 if (write(1, b, 0) == -1) exit(0); 6545 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 6546 if (write(1, cp, 0) == -1) exit(0); 6547 free(cp); 6548 /* 6549 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 6550 * not understand comments and we don't use the "fallthrough" attribute 6551 * that it's looking for. 6552 */ 6553 switch(i){ 6554 case 0: j += i; 6555 /* FALLTHROUGH */ 6556 default: j += k; 6557 } 6558 exit(0); 6559} 6560 6561 6562_ACEOF 6563if ac_fn_c_try_run "$LINENO" 6564then : 6565 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 6566printf "%s\n" "yes" >&6; } 6567 CFLAGS="$saved_CFLAGS $_define_flag" 6568else $as_nop 6569 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 6570printf "%s\n" "no, fails at run time" >&6; } 6571 CFLAGS="$saved_CFLAGS" 6572fi 6573rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 6574 conftest.$ac_objext conftest.beam conftest.$ac_ext 6575fi 6576 6577fi 6578else $as_nop 6579 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 6580printf "%s\n" "no" >&6; } 6581 CFLAGS="$saved_CFLAGS" 6582 6583fi 6584rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 6585} 6586 { 6587 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC supports compile flag -Qunused-arguments" >&5 6588printf %s "checking if $CC supports compile flag -Qunused-arguments... " >&6; } 6589 saved_CFLAGS="$CFLAGS" 6590 CFLAGS="$CFLAGS $WERROR -Qunused-arguments" 6591 _define_flag="" 6592 test "x$_define_flag" = "x" && _define_flag="-Qunused-arguments" 6593 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 6594/* end confdefs.h. */ 6595 6596#include <stdlib.h> 6597#include <stdarg.h> 6598#include <stdio.h> 6599#include <string.h> 6600#include <unistd.h> 6601/* Trivial function to help test for -fzero-call-used-regs */ 6602int f(int n) {return rand() % n;} 6603char *f2(char *s, ...) { 6604 char ret[64]; 6605 va_list args; 6606 va_start(args, s); 6607 vsnprintf(ret, sizeof(ret), s, args); 6608 va_end(args); 6609 return strdup(ret); 6610} 6611int i; 6612double d; 6613const char *f3(int s) { 6614 i = (int)d; 6615 return s ? "good" : "gooder"; 6616} 6617int main(int argc, char **argv) { 6618 char b[256], *cp; 6619 const char *s; 6620 /* Some math to catch -ftrapv problems in the toolchain */ 6621 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 6622 float l = i * 2.1; 6623 double m = l / 0.5; 6624 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 6625 (void)argv; 6626 f(1); 6627 s = f3(f(2)); 6628 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 6629 if (write(1, b, 0) == -1) exit(0); 6630 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 6631 if (write(1, cp, 0) == -1) exit(0); 6632 free(cp); 6633 /* 6634 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 6635 * not understand comments and we don't use the "fallthrough" attribute 6636 * that it's looking for. 6637 */ 6638 switch(i){ 6639 case 0: j += i; 6640 /* FALLTHROUGH */ 6641 default: j += k; 6642 } 6643 exit(0); 6644} 6645 6646 6647_ACEOF 6648if ac_fn_c_try_compile "$LINENO" 6649then : 6650 6651if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 6652then 6653 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 6654printf "%s\n" "no" >&6; } 6655 CFLAGS="$saved_CFLAGS" 6656else 6657 if test "$cross_compiling" = yes 6658then : 6659 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 6660printf "%s\n" "yes" >&6; } 6661 CFLAGS="$saved_CFLAGS $_define_flag" 6662else $as_nop 6663 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 6664/* end confdefs.h. */ 6665 6666#include <stdlib.h> 6667#include <stdarg.h> 6668#include <stdio.h> 6669#include <string.h> 6670#include <unistd.h> 6671/* Trivial function to help test for -fzero-call-used-regs */ 6672int f(int n) {return rand() % n;} 6673char *f2(char *s, ...) { 6674 char ret[64]; 6675 va_list args; 6676 va_start(args, s); 6677 vsnprintf(ret, sizeof(ret), s, args); 6678 va_end(args); 6679 return strdup(ret); 6680} 6681int i; 6682double d; 6683const char *f3(int s) { 6684 i = (int)d; 6685 return s ? "good" : "gooder"; 6686} 6687int main(int argc, char **argv) { 6688 char b[256], *cp; 6689 const char *s; 6690 /* Some math to catch -ftrapv problems in the toolchain */ 6691 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 6692 float l = i * 2.1; 6693 double m = l / 0.5; 6694 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 6695 (void)argv; 6696 f(1); 6697 s = f3(f(2)); 6698 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 6699 if (write(1, b, 0) == -1) exit(0); 6700 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 6701 if (write(1, cp, 0) == -1) exit(0); 6702 free(cp); 6703 /* 6704 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 6705 * not understand comments and we don't use the "fallthrough" attribute 6706 * that it's looking for. 6707 */ 6708 switch(i){ 6709 case 0: j += i; 6710 /* FALLTHROUGH */ 6711 default: j += k; 6712 } 6713 exit(0); 6714} 6715 6716 6717_ACEOF 6718if ac_fn_c_try_run "$LINENO" 6719then : 6720 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 6721printf "%s\n" "yes" >&6; } 6722 CFLAGS="$saved_CFLAGS $_define_flag" 6723else $as_nop 6724 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 6725printf "%s\n" "no, fails at run time" >&6; } 6726 CFLAGS="$saved_CFLAGS" 6727fi 6728rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 6729 conftest.$ac_objext conftest.beam conftest.$ac_ext 6730fi 6731 6732fi 6733else $as_nop 6734 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 6735printf "%s\n" "no" >&6; } 6736 CFLAGS="$saved_CFLAGS" 6737 6738fi 6739rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 6740} 6741 { 6742 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC supports compile flag -Wall" >&5 6743printf %s "checking if $CC supports compile flag -Wall... " >&6; } 6744 saved_CFLAGS="$CFLAGS" 6745 CFLAGS="$CFLAGS $WERROR -Wall" 6746 _define_flag="" 6747 test "x$_define_flag" = "x" && _define_flag="-Wall" 6748 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 6749/* end confdefs.h. */ 6750 6751#include <stdlib.h> 6752#include <stdarg.h> 6753#include <stdio.h> 6754#include <string.h> 6755#include <unistd.h> 6756/* Trivial function to help test for -fzero-call-used-regs */ 6757int f(int n) {return rand() % n;} 6758char *f2(char *s, ...) { 6759 char ret[64]; 6760 va_list args; 6761 va_start(args, s); 6762 vsnprintf(ret, sizeof(ret), s, args); 6763 va_end(args); 6764 return strdup(ret); 6765} 6766int i; 6767double d; 6768const char *f3(int s) { 6769 i = (int)d; 6770 return s ? "good" : "gooder"; 6771} 6772int main(int argc, char **argv) { 6773 char b[256], *cp; 6774 const char *s; 6775 /* Some math to catch -ftrapv problems in the toolchain */ 6776 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 6777 float l = i * 2.1; 6778 double m = l / 0.5; 6779 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 6780 (void)argv; 6781 f(1); 6782 s = f3(f(2)); 6783 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 6784 if (write(1, b, 0) == -1) exit(0); 6785 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 6786 if (write(1, cp, 0) == -1) exit(0); 6787 free(cp); 6788 /* 6789 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 6790 * not understand comments and we don't use the "fallthrough" attribute 6791 * that it's looking for. 6792 */ 6793 switch(i){ 6794 case 0: j += i; 6795 /* FALLTHROUGH */ 6796 default: j += k; 6797 } 6798 exit(0); 6799} 6800 6801 6802_ACEOF 6803if ac_fn_c_try_compile "$LINENO" 6804then : 6805 6806if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 6807then 6808 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 6809printf "%s\n" "no" >&6; } 6810 CFLAGS="$saved_CFLAGS" 6811else 6812 if test "$cross_compiling" = yes 6813then : 6814 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 6815printf "%s\n" "yes" >&6; } 6816 CFLAGS="$saved_CFLAGS $_define_flag" 6817else $as_nop 6818 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 6819/* end confdefs.h. */ 6820 6821#include <stdlib.h> 6822#include <stdarg.h> 6823#include <stdio.h> 6824#include <string.h> 6825#include <unistd.h> 6826/* Trivial function to help test for -fzero-call-used-regs */ 6827int f(int n) {return rand() % n;} 6828char *f2(char *s, ...) { 6829 char ret[64]; 6830 va_list args; 6831 va_start(args, s); 6832 vsnprintf(ret, sizeof(ret), s, args); 6833 va_end(args); 6834 return strdup(ret); 6835} 6836int i; 6837double d; 6838const char *f3(int s) { 6839 i = (int)d; 6840 return s ? "good" : "gooder"; 6841} 6842int main(int argc, char **argv) { 6843 char b[256], *cp; 6844 const char *s; 6845 /* Some math to catch -ftrapv problems in the toolchain */ 6846 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 6847 float l = i * 2.1; 6848 double m = l / 0.5; 6849 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 6850 (void)argv; 6851 f(1); 6852 s = f3(f(2)); 6853 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 6854 if (write(1, b, 0) == -1) exit(0); 6855 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 6856 if (write(1, cp, 0) == -1) exit(0); 6857 free(cp); 6858 /* 6859 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 6860 * not understand comments and we don't use the "fallthrough" attribute 6861 * that it's looking for. 6862 */ 6863 switch(i){ 6864 case 0: j += i; 6865 /* FALLTHROUGH */ 6866 default: j += k; 6867 } 6868 exit(0); 6869} 6870 6871 6872_ACEOF 6873if ac_fn_c_try_run "$LINENO" 6874then : 6875 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 6876printf "%s\n" "yes" >&6; } 6877 CFLAGS="$saved_CFLAGS $_define_flag" 6878else $as_nop 6879 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 6880printf "%s\n" "no, fails at run time" >&6; } 6881 CFLAGS="$saved_CFLAGS" 6882fi 6883rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 6884 conftest.$ac_objext conftest.beam conftest.$ac_ext 6885fi 6886 6887fi 6888else $as_nop 6889 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 6890printf "%s\n" "no" >&6; } 6891 CFLAGS="$saved_CFLAGS" 6892 6893fi 6894rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 6895} 6896 { 6897 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC supports compile flag -Wextra" >&5 6898printf %s "checking if $CC supports compile flag -Wextra... " >&6; } 6899 saved_CFLAGS="$CFLAGS" 6900 CFLAGS="$CFLAGS $WERROR -Wextra" 6901 _define_flag="" 6902 test "x$_define_flag" = "x" && _define_flag="-Wextra" 6903 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 6904/* end confdefs.h. */ 6905 6906#include <stdlib.h> 6907#include <stdarg.h> 6908#include <stdio.h> 6909#include <string.h> 6910#include <unistd.h> 6911/* Trivial function to help test for -fzero-call-used-regs */ 6912int f(int n) {return rand() % n;} 6913char *f2(char *s, ...) { 6914 char ret[64]; 6915 va_list args; 6916 va_start(args, s); 6917 vsnprintf(ret, sizeof(ret), s, args); 6918 va_end(args); 6919 return strdup(ret); 6920} 6921int i; 6922double d; 6923const char *f3(int s) { 6924 i = (int)d; 6925 return s ? "good" : "gooder"; 6926} 6927int main(int argc, char **argv) { 6928 char b[256], *cp; 6929 const char *s; 6930 /* Some math to catch -ftrapv problems in the toolchain */ 6931 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 6932 float l = i * 2.1; 6933 double m = l / 0.5; 6934 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 6935 (void)argv; 6936 f(1); 6937 s = f3(f(2)); 6938 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 6939 if (write(1, b, 0) == -1) exit(0); 6940 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 6941 if (write(1, cp, 0) == -1) exit(0); 6942 free(cp); 6943 /* 6944 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 6945 * not understand comments and we don't use the "fallthrough" attribute 6946 * that it's looking for. 6947 */ 6948 switch(i){ 6949 case 0: j += i; 6950 /* FALLTHROUGH */ 6951 default: j += k; 6952 } 6953 exit(0); 6954} 6955 6956 6957_ACEOF 6958if ac_fn_c_try_compile "$LINENO" 6959then : 6960 6961if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 6962then 6963 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 6964printf "%s\n" "no" >&6; } 6965 CFLAGS="$saved_CFLAGS" 6966else 6967 if test "$cross_compiling" = yes 6968then : 6969 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 6970printf "%s\n" "yes" >&6; } 6971 CFLAGS="$saved_CFLAGS $_define_flag" 6972else $as_nop 6973 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 6974/* end confdefs.h. */ 6975 6976#include <stdlib.h> 6977#include <stdarg.h> 6978#include <stdio.h> 6979#include <string.h> 6980#include <unistd.h> 6981/* Trivial function to help test for -fzero-call-used-regs */ 6982int f(int n) {return rand() % n;} 6983char *f2(char *s, ...) { 6984 char ret[64]; 6985 va_list args; 6986 va_start(args, s); 6987 vsnprintf(ret, sizeof(ret), s, args); 6988 va_end(args); 6989 return strdup(ret); 6990} 6991int i; 6992double d; 6993const char *f3(int s) { 6994 i = (int)d; 6995 return s ? "good" : "gooder"; 6996} 6997int main(int argc, char **argv) { 6998 char b[256], *cp; 6999 const char *s; 7000 /* Some math to catch -ftrapv problems in the toolchain */ 7001 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 7002 float l = i * 2.1; 7003 double m = l / 0.5; 7004 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 7005 (void)argv; 7006 f(1); 7007 s = f3(f(2)); 7008 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 7009 if (write(1, b, 0) == -1) exit(0); 7010 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 7011 if (write(1, cp, 0) == -1) exit(0); 7012 free(cp); 7013 /* 7014 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 7015 * not understand comments and we don't use the "fallthrough" attribute 7016 * that it's looking for. 7017 */ 7018 switch(i){ 7019 case 0: j += i; 7020 /* FALLTHROUGH */ 7021 default: j += k; 7022 } 7023 exit(0); 7024} 7025 7026 7027_ACEOF 7028if ac_fn_c_try_run "$LINENO" 7029then : 7030 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 7031printf "%s\n" "yes" >&6; } 7032 CFLAGS="$saved_CFLAGS $_define_flag" 7033else $as_nop 7034 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 7035printf "%s\n" "no, fails at run time" >&6; } 7036 CFLAGS="$saved_CFLAGS" 7037fi 7038rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 7039 conftest.$ac_objext conftest.beam conftest.$ac_ext 7040fi 7041 7042fi 7043else $as_nop 7044 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 7045printf "%s\n" "no" >&6; } 7046 CFLAGS="$saved_CFLAGS" 7047 7048fi 7049rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 7050} 7051 { 7052 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC supports compile flag -Wpointer-arith" >&5 7053printf %s "checking if $CC supports compile flag -Wpointer-arith... " >&6; } 7054 saved_CFLAGS="$CFLAGS" 7055 CFLAGS="$CFLAGS $WERROR -Wpointer-arith" 7056 _define_flag="" 7057 test "x$_define_flag" = "x" && _define_flag="-Wpointer-arith" 7058 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 7059/* end confdefs.h. */ 7060 7061#include <stdlib.h> 7062#include <stdarg.h> 7063#include <stdio.h> 7064#include <string.h> 7065#include <unistd.h> 7066/* Trivial function to help test for -fzero-call-used-regs */ 7067int f(int n) {return rand() % n;} 7068char *f2(char *s, ...) { 7069 char ret[64]; 7070 va_list args; 7071 va_start(args, s); 7072 vsnprintf(ret, sizeof(ret), s, args); 7073 va_end(args); 7074 return strdup(ret); 7075} 7076int i; 7077double d; 7078const char *f3(int s) { 7079 i = (int)d; 7080 return s ? "good" : "gooder"; 7081} 7082int main(int argc, char **argv) { 7083 char b[256], *cp; 7084 const char *s; 7085 /* Some math to catch -ftrapv problems in the toolchain */ 7086 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 7087 float l = i * 2.1; 7088 double m = l / 0.5; 7089 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 7090 (void)argv; 7091 f(1); 7092 s = f3(f(2)); 7093 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 7094 if (write(1, b, 0) == -1) exit(0); 7095 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 7096 if (write(1, cp, 0) == -1) exit(0); 7097 free(cp); 7098 /* 7099 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 7100 * not understand comments and we don't use the "fallthrough" attribute 7101 * that it's looking for. 7102 */ 7103 switch(i){ 7104 case 0: j += i; 7105 /* FALLTHROUGH */ 7106 default: j += k; 7107 } 7108 exit(0); 7109} 7110 7111 7112_ACEOF 7113if ac_fn_c_try_compile "$LINENO" 7114then : 7115 7116if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 7117then 7118 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 7119printf "%s\n" "no" >&6; } 7120 CFLAGS="$saved_CFLAGS" 7121else 7122 if test "$cross_compiling" = yes 7123then : 7124 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 7125printf "%s\n" "yes" >&6; } 7126 CFLAGS="$saved_CFLAGS $_define_flag" 7127else $as_nop 7128 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 7129/* end confdefs.h. */ 7130 7131#include <stdlib.h> 7132#include <stdarg.h> 7133#include <stdio.h> 7134#include <string.h> 7135#include <unistd.h> 7136/* Trivial function to help test for -fzero-call-used-regs */ 7137int f(int n) {return rand() % n;} 7138char *f2(char *s, ...) { 7139 char ret[64]; 7140 va_list args; 7141 va_start(args, s); 7142 vsnprintf(ret, sizeof(ret), s, args); 7143 va_end(args); 7144 return strdup(ret); 7145} 7146int i; 7147double d; 7148const char *f3(int s) { 7149 i = (int)d; 7150 return s ? "good" : "gooder"; 7151} 7152int main(int argc, char **argv) { 7153 char b[256], *cp; 7154 const char *s; 7155 /* Some math to catch -ftrapv problems in the toolchain */ 7156 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 7157 float l = i * 2.1; 7158 double m = l / 0.5; 7159 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 7160 (void)argv; 7161 f(1); 7162 s = f3(f(2)); 7163 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 7164 if (write(1, b, 0) == -1) exit(0); 7165 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 7166 if (write(1, cp, 0) == -1) exit(0); 7167 free(cp); 7168 /* 7169 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 7170 * not understand comments and we don't use the "fallthrough" attribute 7171 * that it's looking for. 7172 */ 7173 switch(i){ 7174 case 0: j += i; 7175 /* FALLTHROUGH */ 7176 default: j += k; 7177 } 7178 exit(0); 7179} 7180 7181 7182_ACEOF 7183if ac_fn_c_try_run "$LINENO" 7184then : 7185 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 7186printf "%s\n" "yes" >&6; } 7187 CFLAGS="$saved_CFLAGS $_define_flag" 7188else $as_nop 7189 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 7190printf "%s\n" "no, fails at run time" >&6; } 7191 CFLAGS="$saved_CFLAGS" 7192fi 7193rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 7194 conftest.$ac_objext conftest.beam conftest.$ac_ext 7195fi 7196 7197fi 7198else $as_nop 7199 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 7200printf "%s\n" "no" >&6; } 7201 CFLAGS="$saved_CFLAGS" 7202 7203fi 7204rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 7205} 7206 { 7207 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC supports compile flag -Wuninitialized" >&5 7208printf %s "checking if $CC supports compile flag -Wuninitialized... " >&6; } 7209 saved_CFLAGS="$CFLAGS" 7210 CFLAGS="$CFLAGS $WERROR -Wuninitialized" 7211 _define_flag="" 7212 test "x$_define_flag" = "x" && _define_flag="-Wuninitialized" 7213 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 7214/* end confdefs.h. */ 7215 7216#include <stdlib.h> 7217#include <stdarg.h> 7218#include <stdio.h> 7219#include <string.h> 7220#include <unistd.h> 7221/* Trivial function to help test for -fzero-call-used-regs */ 7222int f(int n) {return rand() % n;} 7223char *f2(char *s, ...) { 7224 char ret[64]; 7225 va_list args; 7226 va_start(args, s); 7227 vsnprintf(ret, sizeof(ret), s, args); 7228 va_end(args); 7229 return strdup(ret); 7230} 7231int i; 7232double d; 7233const char *f3(int s) { 7234 i = (int)d; 7235 return s ? "good" : "gooder"; 7236} 7237int main(int argc, char **argv) { 7238 char b[256], *cp; 7239 const char *s; 7240 /* Some math to catch -ftrapv problems in the toolchain */ 7241 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 7242 float l = i * 2.1; 7243 double m = l / 0.5; 7244 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 7245 (void)argv; 7246 f(1); 7247 s = f3(f(2)); 7248 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 7249 if (write(1, b, 0) == -1) exit(0); 7250 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 7251 if (write(1, cp, 0) == -1) exit(0); 7252 free(cp); 7253 /* 7254 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 7255 * not understand comments and we don't use the "fallthrough" attribute 7256 * that it's looking for. 7257 */ 7258 switch(i){ 7259 case 0: j += i; 7260 /* FALLTHROUGH */ 7261 default: j += k; 7262 } 7263 exit(0); 7264} 7265 7266 7267_ACEOF 7268if ac_fn_c_try_compile "$LINENO" 7269then : 7270 7271if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 7272then 7273 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 7274printf "%s\n" "no" >&6; } 7275 CFLAGS="$saved_CFLAGS" 7276else 7277 if test "$cross_compiling" = yes 7278then : 7279 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 7280printf "%s\n" "yes" >&6; } 7281 CFLAGS="$saved_CFLAGS $_define_flag" 7282else $as_nop 7283 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 7284/* end confdefs.h. */ 7285 7286#include <stdlib.h> 7287#include <stdarg.h> 7288#include <stdio.h> 7289#include <string.h> 7290#include <unistd.h> 7291/* Trivial function to help test for -fzero-call-used-regs */ 7292int f(int n) {return rand() % n;} 7293char *f2(char *s, ...) { 7294 char ret[64]; 7295 va_list args; 7296 va_start(args, s); 7297 vsnprintf(ret, sizeof(ret), s, args); 7298 va_end(args); 7299 return strdup(ret); 7300} 7301int i; 7302double d; 7303const char *f3(int s) { 7304 i = (int)d; 7305 return s ? "good" : "gooder"; 7306} 7307int main(int argc, char **argv) { 7308 char b[256], *cp; 7309 const char *s; 7310 /* Some math to catch -ftrapv problems in the toolchain */ 7311 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 7312 float l = i * 2.1; 7313 double m = l / 0.5; 7314 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 7315 (void)argv; 7316 f(1); 7317 s = f3(f(2)); 7318 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 7319 if (write(1, b, 0) == -1) exit(0); 7320 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 7321 if (write(1, cp, 0) == -1) exit(0); 7322 free(cp); 7323 /* 7324 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 7325 * not understand comments and we don't use the "fallthrough" attribute 7326 * that it's looking for. 7327 */ 7328 switch(i){ 7329 case 0: j += i; 7330 /* FALLTHROUGH */ 7331 default: j += k; 7332 } 7333 exit(0); 7334} 7335 7336 7337_ACEOF 7338if ac_fn_c_try_run "$LINENO" 7339then : 7340 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 7341printf "%s\n" "yes" >&6; } 7342 CFLAGS="$saved_CFLAGS $_define_flag" 7343else $as_nop 7344 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 7345printf "%s\n" "no, fails at run time" >&6; } 7346 CFLAGS="$saved_CFLAGS" 7347fi 7348rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 7349 conftest.$ac_objext conftest.beam conftest.$ac_ext 7350fi 7351 7352fi 7353else $as_nop 7354 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 7355printf "%s\n" "no" >&6; } 7356 CFLAGS="$saved_CFLAGS" 7357 7358fi 7359rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 7360} 7361 { 7362 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC supports compile flag -Wsign-compare" >&5 7363printf %s "checking if $CC supports compile flag -Wsign-compare... " >&6; } 7364 saved_CFLAGS="$CFLAGS" 7365 CFLAGS="$CFLAGS $WERROR -Wsign-compare" 7366 _define_flag="" 7367 test "x$_define_flag" = "x" && _define_flag="-Wsign-compare" 7368 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 7369/* end confdefs.h. */ 7370 7371#include <stdlib.h> 7372#include <stdarg.h> 7373#include <stdio.h> 7374#include <string.h> 7375#include <unistd.h> 7376/* Trivial function to help test for -fzero-call-used-regs */ 7377int f(int n) {return rand() % n;} 7378char *f2(char *s, ...) { 7379 char ret[64]; 7380 va_list args; 7381 va_start(args, s); 7382 vsnprintf(ret, sizeof(ret), s, args); 7383 va_end(args); 7384 return strdup(ret); 7385} 7386int i; 7387double d; 7388const char *f3(int s) { 7389 i = (int)d; 7390 return s ? "good" : "gooder"; 7391} 7392int main(int argc, char **argv) { 7393 char b[256], *cp; 7394 const char *s; 7395 /* Some math to catch -ftrapv problems in the toolchain */ 7396 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 7397 float l = i * 2.1; 7398 double m = l / 0.5; 7399 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 7400 (void)argv; 7401 f(1); 7402 s = f3(f(2)); 7403 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 7404 if (write(1, b, 0) == -1) exit(0); 7405 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 7406 if (write(1, cp, 0) == -1) exit(0); 7407 free(cp); 7408 /* 7409 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 7410 * not understand comments and we don't use the "fallthrough" attribute 7411 * that it's looking for. 7412 */ 7413 switch(i){ 7414 case 0: j += i; 7415 /* FALLTHROUGH */ 7416 default: j += k; 7417 } 7418 exit(0); 7419} 7420 7421 7422_ACEOF 7423if ac_fn_c_try_compile "$LINENO" 7424then : 7425 7426if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 7427then 7428 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 7429printf "%s\n" "no" >&6; } 7430 CFLAGS="$saved_CFLAGS" 7431else 7432 if test "$cross_compiling" = yes 7433then : 7434 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 7435printf "%s\n" "yes" >&6; } 7436 CFLAGS="$saved_CFLAGS $_define_flag" 7437else $as_nop 7438 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 7439/* end confdefs.h. */ 7440 7441#include <stdlib.h> 7442#include <stdarg.h> 7443#include <stdio.h> 7444#include <string.h> 7445#include <unistd.h> 7446/* Trivial function to help test for -fzero-call-used-regs */ 7447int f(int n) {return rand() % n;} 7448char *f2(char *s, ...) { 7449 char ret[64]; 7450 va_list args; 7451 va_start(args, s); 7452 vsnprintf(ret, sizeof(ret), s, args); 7453 va_end(args); 7454 return strdup(ret); 7455} 7456int i; 7457double d; 7458const char *f3(int s) { 7459 i = (int)d; 7460 return s ? "good" : "gooder"; 7461} 7462int main(int argc, char **argv) { 7463 char b[256], *cp; 7464 const char *s; 7465 /* Some math to catch -ftrapv problems in the toolchain */ 7466 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 7467 float l = i * 2.1; 7468 double m = l / 0.5; 7469 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 7470 (void)argv; 7471 f(1); 7472 s = f3(f(2)); 7473 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 7474 if (write(1, b, 0) == -1) exit(0); 7475 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 7476 if (write(1, cp, 0) == -1) exit(0); 7477 free(cp); 7478 /* 7479 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 7480 * not understand comments and we don't use the "fallthrough" attribute 7481 * that it's looking for. 7482 */ 7483 switch(i){ 7484 case 0: j += i; 7485 /* FALLTHROUGH */ 7486 default: j += k; 7487 } 7488 exit(0); 7489} 7490 7491 7492_ACEOF 7493if ac_fn_c_try_run "$LINENO" 7494then : 7495 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 7496printf "%s\n" "yes" >&6; } 7497 CFLAGS="$saved_CFLAGS $_define_flag" 7498else $as_nop 7499 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 7500printf "%s\n" "no, fails at run time" >&6; } 7501 CFLAGS="$saved_CFLAGS" 7502fi 7503rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 7504 conftest.$ac_objext conftest.beam conftest.$ac_ext 7505fi 7506 7507fi 7508else $as_nop 7509 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 7510printf "%s\n" "no" >&6; } 7511 CFLAGS="$saved_CFLAGS" 7512 7513fi 7514rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 7515} 7516 { 7517 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC supports compile flag -Wformat-security" >&5 7518printf %s "checking if $CC supports compile flag -Wformat-security... " >&6; } 7519 saved_CFLAGS="$CFLAGS" 7520 CFLAGS="$CFLAGS $WERROR -Wformat-security" 7521 _define_flag="" 7522 test "x$_define_flag" = "x" && _define_flag="-Wformat-security" 7523 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 7524/* end confdefs.h. */ 7525 7526#include <stdlib.h> 7527#include <stdarg.h> 7528#include <stdio.h> 7529#include <string.h> 7530#include <unistd.h> 7531/* Trivial function to help test for -fzero-call-used-regs */ 7532int f(int n) {return rand() % n;} 7533char *f2(char *s, ...) { 7534 char ret[64]; 7535 va_list args; 7536 va_start(args, s); 7537 vsnprintf(ret, sizeof(ret), s, args); 7538 va_end(args); 7539 return strdup(ret); 7540} 7541int i; 7542double d; 7543const char *f3(int s) { 7544 i = (int)d; 7545 return s ? "good" : "gooder"; 7546} 7547int main(int argc, char **argv) { 7548 char b[256], *cp; 7549 const char *s; 7550 /* Some math to catch -ftrapv problems in the toolchain */ 7551 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 7552 float l = i * 2.1; 7553 double m = l / 0.5; 7554 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 7555 (void)argv; 7556 f(1); 7557 s = f3(f(2)); 7558 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 7559 if (write(1, b, 0) == -1) exit(0); 7560 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 7561 if (write(1, cp, 0) == -1) exit(0); 7562 free(cp); 7563 /* 7564 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 7565 * not understand comments and we don't use the "fallthrough" attribute 7566 * that it's looking for. 7567 */ 7568 switch(i){ 7569 case 0: j += i; 7570 /* FALLTHROUGH */ 7571 default: j += k; 7572 } 7573 exit(0); 7574} 7575 7576 7577_ACEOF 7578if ac_fn_c_try_compile "$LINENO" 7579then : 7580 7581if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 7582then 7583 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 7584printf "%s\n" "no" >&6; } 7585 CFLAGS="$saved_CFLAGS" 7586else 7587 if test "$cross_compiling" = yes 7588then : 7589 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 7590printf "%s\n" "yes" >&6; } 7591 CFLAGS="$saved_CFLAGS $_define_flag" 7592else $as_nop 7593 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 7594/* end confdefs.h. */ 7595 7596#include <stdlib.h> 7597#include <stdarg.h> 7598#include <stdio.h> 7599#include <string.h> 7600#include <unistd.h> 7601/* Trivial function to help test for -fzero-call-used-regs */ 7602int f(int n) {return rand() % n;} 7603char *f2(char *s, ...) { 7604 char ret[64]; 7605 va_list args; 7606 va_start(args, s); 7607 vsnprintf(ret, sizeof(ret), s, args); 7608 va_end(args); 7609 return strdup(ret); 7610} 7611int i; 7612double d; 7613const char *f3(int s) { 7614 i = (int)d; 7615 return s ? "good" : "gooder"; 7616} 7617int main(int argc, char **argv) { 7618 char b[256], *cp; 7619 const char *s; 7620 /* Some math to catch -ftrapv problems in the toolchain */ 7621 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 7622 float l = i * 2.1; 7623 double m = l / 0.5; 7624 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 7625 (void)argv; 7626 f(1); 7627 s = f3(f(2)); 7628 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 7629 if (write(1, b, 0) == -1) exit(0); 7630 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 7631 if (write(1, cp, 0) == -1) exit(0); 7632 free(cp); 7633 /* 7634 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 7635 * not understand comments and we don't use the "fallthrough" attribute 7636 * that it's looking for. 7637 */ 7638 switch(i){ 7639 case 0: j += i; 7640 /* FALLTHROUGH */ 7641 default: j += k; 7642 } 7643 exit(0); 7644} 7645 7646 7647_ACEOF 7648if ac_fn_c_try_run "$LINENO" 7649then : 7650 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 7651printf "%s\n" "yes" >&6; } 7652 CFLAGS="$saved_CFLAGS $_define_flag" 7653else $as_nop 7654 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 7655printf "%s\n" "no, fails at run time" >&6; } 7656 CFLAGS="$saved_CFLAGS" 7657fi 7658rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 7659 conftest.$ac_objext conftest.beam conftest.$ac_ext 7660fi 7661 7662fi 7663else $as_nop 7664 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 7665printf "%s\n" "no" >&6; } 7666 CFLAGS="$saved_CFLAGS" 7667 7668fi 7669rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 7670} 7671 { 7672 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC supports compile flag -Wsizeof-pointer-memaccess" >&5 7673printf %s "checking if $CC supports compile flag -Wsizeof-pointer-memaccess... " >&6; } 7674 saved_CFLAGS="$CFLAGS" 7675 CFLAGS="$CFLAGS $WERROR -Wsizeof-pointer-memaccess" 7676 _define_flag="" 7677 test "x$_define_flag" = "x" && _define_flag="-Wsizeof-pointer-memaccess" 7678 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 7679/* end confdefs.h. */ 7680 7681#include <stdlib.h> 7682#include <stdarg.h> 7683#include <stdio.h> 7684#include <string.h> 7685#include <unistd.h> 7686/* Trivial function to help test for -fzero-call-used-regs */ 7687int f(int n) {return rand() % n;} 7688char *f2(char *s, ...) { 7689 char ret[64]; 7690 va_list args; 7691 va_start(args, s); 7692 vsnprintf(ret, sizeof(ret), s, args); 7693 va_end(args); 7694 return strdup(ret); 7695} 7696int i; 7697double d; 7698const char *f3(int s) { 7699 i = (int)d; 7700 return s ? "good" : "gooder"; 7701} 7702int main(int argc, char **argv) { 7703 char b[256], *cp; 7704 const char *s; 7705 /* Some math to catch -ftrapv problems in the toolchain */ 7706 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 7707 float l = i * 2.1; 7708 double m = l / 0.5; 7709 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 7710 (void)argv; 7711 f(1); 7712 s = f3(f(2)); 7713 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 7714 if (write(1, b, 0) == -1) exit(0); 7715 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 7716 if (write(1, cp, 0) == -1) exit(0); 7717 free(cp); 7718 /* 7719 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 7720 * not understand comments and we don't use the "fallthrough" attribute 7721 * that it's looking for. 7722 */ 7723 switch(i){ 7724 case 0: j += i; 7725 /* FALLTHROUGH */ 7726 default: j += k; 7727 } 7728 exit(0); 7729} 7730 7731 7732_ACEOF 7733if ac_fn_c_try_compile "$LINENO" 7734then : 7735 7736if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 7737then 7738 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 7739printf "%s\n" "no" >&6; } 7740 CFLAGS="$saved_CFLAGS" 7741else 7742 if test "$cross_compiling" = yes 7743then : 7744 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 7745printf "%s\n" "yes" >&6; } 7746 CFLAGS="$saved_CFLAGS $_define_flag" 7747else $as_nop 7748 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 7749/* end confdefs.h. */ 7750 7751#include <stdlib.h> 7752#include <stdarg.h> 7753#include <stdio.h> 7754#include <string.h> 7755#include <unistd.h> 7756/* Trivial function to help test for -fzero-call-used-regs */ 7757int f(int n) {return rand() % n;} 7758char *f2(char *s, ...) { 7759 char ret[64]; 7760 va_list args; 7761 va_start(args, s); 7762 vsnprintf(ret, sizeof(ret), s, args); 7763 va_end(args); 7764 return strdup(ret); 7765} 7766int i; 7767double d; 7768const char *f3(int s) { 7769 i = (int)d; 7770 return s ? "good" : "gooder"; 7771} 7772int main(int argc, char **argv) { 7773 char b[256], *cp; 7774 const char *s; 7775 /* Some math to catch -ftrapv problems in the toolchain */ 7776 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 7777 float l = i * 2.1; 7778 double m = l / 0.5; 7779 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 7780 (void)argv; 7781 f(1); 7782 s = f3(f(2)); 7783 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 7784 if (write(1, b, 0) == -1) exit(0); 7785 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 7786 if (write(1, cp, 0) == -1) exit(0); 7787 free(cp); 7788 /* 7789 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 7790 * not understand comments and we don't use the "fallthrough" attribute 7791 * that it's looking for. 7792 */ 7793 switch(i){ 7794 case 0: j += i; 7795 /* FALLTHROUGH */ 7796 default: j += k; 7797 } 7798 exit(0); 7799} 7800 7801 7802_ACEOF 7803if ac_fn_c_try_run "$LINENO" 7804then : 7805 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 7806printf "%s\n" "yes" >&6; } 7807 CFLAGS="$saved_CFLAGS $_define_flag" 7808else $as_nop 7809 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 7810printf "%s\n" "no, fails at run time" >&6; } 7811 CFLAGS="$saved_CFLAGS" 7812fi 7813rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 7814 conftest.$ac_objext conftest.beam conftest.$ac_ext 7815fi 7816 7817fi 7818else $as_nop 7819 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 7820printf "%s\n" "no" >&6; } 7821 CFLAGS="$saved_CFLAGS" 7822 7823fi 7824rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 7825} 7826 { 7827 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC supports compile flag -Wpointer-sign" >&5 7828printf %s "checking if $CC supports compile flag -Wpointer-sign... " >&6; } 7829 saved_CFLAGS="$CFLAGS" 7830 CFLAGS="$CFLAGS $WERROR -Wpointer-sign" 7831 _define_flag="-Wno-pointer-sign" 7832 test "x$_define_flag" = "x" && _define_flag="-Wpointer-sign" 7833 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 7834/* end confdefs.h. */ 7835 7836#include <stdlib.h> 7837#include <stdarg.h> 7838#include <stdio.h> 7839#include <string.h> 7840#include <unistd.h> 7841/* Trivial function to help test for -fzero-call-used-regs */ 7842int f(int n) {return rand() % n;} 7843char *f2(char *s, ...) { 7844 char ret[64]; 7845 va_list args; 7846 va_start(args, s); 7847 vsnprintf(ret, sizeof(ret), s, args); 7848 va_end(args); 7849 return strdup(ret); 7850} 7851int i; 7852double d; 7853const char *f3(int s) { 7854 i = (int)d; 7855 return s ? "good" : "gooder"; 7856} 7857int main(int argc, char **argv) { 7858 char b[256], *cp; 7859 const char *s; 7860 /* Some math to catch -ftrapv problems in the toolchain */ 7861 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 7862 float l = i * 2.1; 7863 double m = l / 0.5; 7864 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 7865 (void)argv; 7866 f(1); 7867 s = f3(f(2)); 7868 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 7869 if (write(1, b, 0) == -1) exit(0); 7870 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 7871 if (write(1, cp, 0) == -1) exit(0); 7872 free(cp); 7873 /* 7874 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 7875 * not understand comments and we don't use the "fallthrough" attribute 7876 * that it's looking for. 7877 */ 7878 switch(i){ 7879 case 0: j += i; 7880 /* FALLTHROUGH */ 7881 default: j += k; 7882 } 7883 exit(0); 7884} 7885 7886 7887_ACEOF 7888if ac_fn_c_try_compile "$LINENO" 7889then : 7890 7891if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 7892then 7893 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 7894printf "%s\n" "no" >&6; } 7895 CFLAGS="$saved_CFLAGS" 7896else 7897 if test "$cross_compiling" = yes 7898then : 7899 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 7900printf "%s\n" "yes" >&6; } 7901 CFLAGS="$saved_CFLAGS $_define_flag" 7902else $as_nop 7903 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 7904/* end confdefs.h. */ 7905 7906#include <stdlib.h> 7907#include <stdarg.h> 7908#include <stdio.h> 7909#include <string.h> 7910#include <unistd.h> 7911/* Trivial function to help test for -fzero-call-used-regs */ 7912int f(int n) {return rand() % n;} 7913char *f2(char *s, ...) { 7914 char ret[64]; 7915 va_list args; 7916 va_start(args, s); 7917 vsnprintf(ret, sizeof(ret), s, args); 7918 va_end(args); 7919 return strdup(ret); 7920} 7921int i; 7922double d; 7923const char *f3(int s) { 7924 i = (int)d; 7925 return s ? "good" : "gooder"; 7926} 7927int main(int argc, char **argv) { 7928 char b[256], *cp; 7929 const char *s; 7930 /* Some math to catch -ftrapv problems in the toolchain */ 7931 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 7932 float l = i * 2.1; 7933 double m = l / 0.5; 7934 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 7935 (void)argv; 7936 f(1); 7937 s = f3(f(2)); 7938 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 7939 if (write(1, b, 0) == -1) exit(0); 7940 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 7941 if (write(1, cp, 0) == -1) exit(0); 7942 free(cp); 7943 /* 7944 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 7945 * not understand comments and we don't use the "fallthrough" attribute 7946 * that it's looking for. 7947 */ 7948 switch(i){ 7949 case 0: j += i; 7950 /* FALLTHROUGH */ 7951 default: j += k; 7952 } 7953 exit(0); 7954} 7955 7956 7957_ACEOF 7958if ac_fn_c_try_run "$LINENO" 7959then : 7960 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 7961printf "%s\n" "yes" >&6; } 7962 CFLAGS="$saved_CFLAGS $_define_flag" 7963else $as_nop 7964 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 7965printf "%s\n" "no, fails at run time" >&6; } 7966 CFLAGS="$saved_CFLAGS" 7967fi 7968rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 7969 conftest.$ac_objext conftest.beam conftest.$ac_ext 7970fi 7971 7972fi 7973else $as_nop 7974 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 7975printf "%s\n" "no" >&6; } 7976 CFLAGS="$saved_CFLAGS" 7977 7978fi 7979rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 7980} 7981 { 7982 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC supports compile flag -Wunused-parameter" >&5 7983printf %s "checking if $CC supports compile flag -Wunused-parameter... " >&6; } 7984 saved_CFLAGS="$CFLAGS" 7985 CFLAGS="$CFLAGS $WERROR -Wunused-parameter" 7986 _define_flag="-Wno-unused-parameter" 7987 test "x$_define_flag" = "x" && _define_flag="-Wunused-parameter" 7988 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 7989/* end confdefs.h. */ 7990 7991#include <stdlib.h> 7992#include <stdarg.h> 7993#include <stdio.h> 7994#include <string.h> 7995#include <unistd.h> 7996/* Trivial function to help test for -fzero-call-used-regs */ 7997int f(int n) {return rand() % n;} 7998char *f2(char *s, ...) { 7999 char ret[64]; 8000 va_list args; 8001 va_start(args, s); 8002 vsnprintf(ret, sizeof(ret), s, args); 8003 va_end(args); 8004 return strdup(ret); 8005} 8006int i; 8007double d; 8008const char *f3(int s) { 8009 i = (int)d; 8010 return s ? "good" : "gooder"; 8011} 8012int main(int argc, char **argv) { 8013 char b[256], *cp; 8014 const char *s; 8015 /* Some math to catch -ftrapv problems in the toolchain */ 8016 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 8017 float l = i * 2.1; 8018 double m = l / 0.5; 8019 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 8020 (void)argv; 8021 f(1); 8022 s = f3(f(2)); 8023 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 8024 if (write(1, b, 0) == -1) exit(0); 8025 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 8026 if (write(1, cp, 0) == -1) exit(0); 8027 free(cp); 8028 /* 8029 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 8030 * not understand comments and we don't use the "fallthrough" attribute 8031 * that it's looking for. 8032 */ 8033 switch(i){ 8034 case 0: j += i; 8035 /* FALLTHROUGH */ 8036 default: j += k; 8037 } 8038 exit(0); 8039} 8040 8041 8042_ACEOF 8043if ac_fn_c_try_compile "$LINENO" 8044then : 8045 8046if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 8047then 8048 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 8049printf "%s\n" "no" >&6; } 8050 CFLAGS="$saved_CFLAGS" 8051else 8052 if test "$cross_compiling" = yes 8053then : 8054 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 8055printf "%s\n" "yes" >&6; } 8056 CFLAGS="$saved_CFLAGS $_define_flag" 8057else $as_nop 8058 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 8059/* end confdefs.h. */ 8060 8061#include <stdlib.h> 8062#include <stdarg.h> 8063#include <stdio.h> 8064#include <string.h> 8065#include <unistd.h> 8066/* Trivial function to help test for -fzero-call-used-regs */ 8067int f(int n) {return rand() % n;} 8068char *f2(char *s, ...) { 8069 char ret[64]; 8070 va_list args; 8071 va_start(args, s); 8072 vsnprintf(ret, sizeof(ret), s, args); 8073 va_end(args); 8074 return strdup(ret); 8075} 8076int i; 8077double d; 8078const char *f3(int s) { 8079 i = (int)d; 8080 return s ? "good" : "gooder"; 8081} 8082int main(int argc, char **argv) { 8083 char b[256], *cp; 8084 const char *s; 8085 /* Some math to catch -ftrapv problems in the toolchain */ 8086 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 8087 float l = i * 2.1; 8088 double m = l / 0.5; 8089 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 8090 (void)argv; 8091 f(1); 8092 s = f3(f(2)); 8093 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 8094 if (write(1, b, 0) == -1) exit(0); 8095 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 8096 if (write(1, cp, 0) == -1) exit(0); 8097 free(cp); 8098 /* 8099 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 8100 * not understand comments and we don't use the "fallthrough" attribute 8101 * that it's looking for. 8102 */ 8103 switch(i){ 8104 case 0: j += i; 8105 /* FALLTHROUGH */ 8106 default: j += k; 8107 } 8108 exit(0); 8109} 8110 8111 8112_ACEOF 8113if ac_fn_c_try_run "$LINENO" 8114then : 8115 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 8116printf "%s\n" "yes" >&6; } 8117 CFLAGS="$saved_CFLAGS $_define_flag" 8118else $as_nop 8119 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 8120printf "%s\n" "no, fails at run time" >&6; } 8121 CFLAGS="$saved_CFLAGS" 8122fi 8123rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 8124 conftest.$ac_objext conftest.beam conftest.$ac_ext 8125fi 8126 8127fi 8128else $as_nop 8129 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 8130printf "%s\n" "no" >&6; } 8131 CFLAGS="$saved_CFLAGS" 8132 8133fi 8134rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 8135} 8136 { 8137 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC supports compile flag -Wunused-result" >&5 8138printf %s "checking if $CC supports compile flag -Wunused-result... " >&6; } 8139 saved_CFLAGS="$CFLAGS" 8140 CFLAGS="$CFLAGS $WERROR -Wunused-result" 8141 _define_flag="-Wno-unused-result" 8142 test "x$_define_flag" = "x" && _define_flag="-Wunused-result" 8143 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 8144/* end confdefs.h. */ 8145 8146#include <stdlib.h> 8147#include <stdarg.h> 8148#include <stdio.h> 8149#include <string.h> 8150#include <unistd.h> 8151/* Trivial function to help test for -fzero-call-used-regs */ 8152int f(int n) {return rand() % n;} 8153char *f2(char *s, ...) { 8154 char ret[64]; 8155 va_list args; 8156 va_start(args, s); 8157 vsnprintf(ret, sizeof(ret), s, args); 8158 va_end(args); 8159 return strdup(ret); 8160} 8161int i; 8162double d; 8163const char *f3(int s) { 8164 i = (int)d; 8165 return s ? "good" : "gooder"; 8166} 8167int main(int argc, char **argv) { 8168 char b[256], *cp; 8169 const char *s; 8170 /* Some math to catch -ftrapv problems in the toolchain */ 8171 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 8172 float l = i * 2.1; 8173 double m = l / 0.5; 8174 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 8175 (void)argv; 8176 f(1); 8177 s = f3(f(2)); 8178 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 8179 if (write(1, b, 0) == -1) exit(0); 8180 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 8181 if (write(1, cp, 0) == -1) exit(0); 8182 free(cp); 8183 /* 8184 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 8185 * not understand comments and we don't use the "fallthrough" attribute 8186 * that it's looking for. 8187 */ 8188 switch(i){ 8189 case 0: j += i; 8190 /* FALLTHROUGH */ 8191 default: j += k; 8192 } 8193 exit(0); 8194} 8195 8196 8197_ACEOF 8198if ac_fn_c_try_compile "$LINENO" 8199then : 8200 8201if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 8202then 8203 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 8204printf "%s\n" "no" >&6; } 8205 CFLAGS="$saved_CFLAGS" 8206else 8207 if test "$cross_compiling" = yes 8208then : 8209 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 8210printf "%s\n" "yes" >&6; } 8211 CFLAGS="$saved_CFLAGS $_define_flag" 8212else $as_nop 8213 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 8214/* end confdefs.h. */ 8215 8216#include <stdlib.h> 8217#include <stdarg.h> 8218#include <stdio.h> 8219#include <string.h> 8220#include <unistd.h> 8221/* Trivial function to help test for -fzero-call-used-regs */ 8222int f(int n) {return rand() % n;} 8223char *f2(char *s, ...) { 8224 char ret[64]; 8225 va_list args; 8226 va_start(args, s); 8227 vsnprintf(ret, sizeof(ret), s, args); 8228 va_end(args); 8229 return strdup(ret); 8230} 8231int i; 8232double d; 8233const char *f3(int s) { 8234 i = (int)d; 8235 return s ? "good" : "gooder"; 8236} 8237int main(int argc, char **argv) { 8238 char b[256], *cp; 8239 const char *s; 8240 /* Some math to catch -ftrapv problems in the toolchain */ 8241 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 8242 float l = i * 2.1; 8243 double m = l / 0.5; 8244 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 8245 (void)argv; 8246 f(1); 8247 s = f3(f(2)); 8248 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 8249 if (write(1, b, 0) == -1) exit(0); 8250 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 8251 if (write(1, cp, 0) == -1) exit(0); 8252 free(cp); 8253 /* 8254 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 8255 * not understand comments and we don't use the "fallthrough" attribute 8256 * that it's looking for. 8257 */ 8258 switch(i){ 8259 case 0: j += i; 8260 /* FALLTHROUGH */ 8261 default: j += k; 8262 } 8263 exit(0); 8264} 8265 8266 8267_ACEOF 8268if ac_fn_c_try_run "$LINENO" 8269then : 8270 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 8271printf "%s\n" "yes" >&6; } 8272 CFLAGS="$saved_CFLAGS $_define_flag" 8273else $as_nop 8274 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 8275printf "%s\n" "no, fails at run time" >&6; } 8276 CFLAGS="$saved_CFLAGS" 8277fi 8278rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 8279 conftest.$ac_objext conftest.beam conftest.$ac_ext 8280fi 8281 8282fi 8283else $as_nop 8284 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 8285printf "%s\n" "no" >&6; } 8286 CFLAGS="$saved_CFLAGS" 8287 8288fi 8289rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 8290} 8291 { 8292 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC supports compile flag -Wimplicit-fallthrough" >&5 8293printf %s "checking if $CC supports compile flag -Wimplicit-fallthrough... " >&6; } 8294 saved_CFLAGS="$CFLAGS" 8295 CFLAGS="$CFLAGS $WERROR -Wimplicit-fallthrough" 8296 _define_flag="" 8297 test "x$_define_flag" = "x" && _define_flag="-Wimplicit-fallthrough" 8298 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 8299/* end confdefs.h. */ 8300 8301#include <stdlib.h> 8302#include <stdarg.h> 8303#include <stdio.h> 8304#include <string.h> 8305#include <unistd.h> 8306/* Trivial function to help test for -fzero-call-used-regs */ 8307int f(int n) {return rand() % n;} 8308char *f2(char *s, ...) { 8309 char ret[64]; 8310 va_list args; 8311 va_start(args, s); 8312 vsnprintf(ret, sizeof(ret), s, args); 8313 va_end(args); 8314 return strdup(ret); 8315} 8316int i; 8317double d; 8318const char *f3(int s) { 8319 i = (int)d; 8320 return s ? "good" : "gooder"; 8321} 8322int main(int argc, char **argv) { 8323 char b[256], *cp; 8324 const char *s; 8325 /* Some math to catch -ftrapv problems in the toolchain */ 8326 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 8327 float l = i * 2.1; 8328 double m = l / 0.5; 8329 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 8330 (void)argv; 8331 f(1); 8332 s = f3(f(2)); 8333 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 8334 if (write(1, b, 0) == -1) exit(0); 8335 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 8336 if (write(1, cp, 0) == -1) exit(0); 8337 free(cp); 8338 /* 8339 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 8340 * not understand comments and we don't use the "fallthrough" attribute 8341 * that it's looking for. 8342 */ 8343 switch(i){ 8344 case 0: j += i; 8345 /* FALLTHROUGH */ 8346 default: j += k; 8347 } 8348 exit(0); 8349} 8350 8351 8352_ACEOF 8353if ac_fn_c_try_compile "$LINENO" 8354then : 8355 8356if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 8357then 8358 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 8359printf "%s\n" "no" >&6; } 8360 CFLAGS="$saved_CFLAGS" 8361else 8362 if test "$cross_compiling" = yes 8363then : 8364 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 8365printf "%s\n" "yes" >&6; } 8366 CFLAGS="$saved_CFLAGS $_define_flag" 8367else $as_nop 8368 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 8369/* end confdefs.h. */ 8370 8371#include <stdlib.h> 8372#include <stdarg.h> 8373#include <stdio.h> 8374#include <string.h> 8375#include <unistd.h> 8376/* Trivial function to help test for -fzero-call-used-regs */ 8377int f(int n) {return rand() % n;} 8378char *f2(char *s, ...) { 8379 char ret[64]; 8380 va_list args; 8381 va_start(args, s); 8382 vsnprintf(ret, sizeof(ret), s, args); 8383 va_end(args); 8384 return strdup(ret); 8385} 8386int i; 8387double d; 8388const char *f3(int s) { 8389 i = (int)d; 8390 return s ? "good" : "gooder"; 8391} 8392int main(int argc, char **argv) { 8393 char b[256], *cp; 8394 const char *s; 8395 /* Some math to catch -ftrapv problems in the toolchain */ 8396 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 8397 float l = i * 2.1; 8398 double m = l / 0.5; 8399 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 8400 (void)argv; 8401 f(1); 8402 s = f3(f(2)); 8403 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 8404 if (write(1, b, 0) == -1) exit(0); 8405 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 8406 if (write(1, cp, 0) == -1) exit(0); 8407 free(cp); 8408 /* 8409 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 8410 * not understand comments and we don't use the "fallthrough" attribute 8411 * that it's looking for. 8412 */ 8413 switch(i){ 8414 case 0: j += i; 8415 /* FALLTHROUGH */ 8416 default: j += k; 8417 } 8418 exit(0); 8419} 8420 8421 8422_ACEOF 8423if ac_fn_c_try_run "$LINENO" 8424then : 8425 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 8426printf "%s\n" "yes" >&6; } 8427 CFLAGS="$saved_CFLAGS $_define_flag" 8428else $as_nop 8429 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 8430printf "%s\n" "no, fails at run time" >&6; } 8431 CFLAGS="$saved_CFLAGS" 8432fi 8433rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 8434 conftest.$ac_objext conftest.beam conftest.$ac_ext 8435fi 8436 8437fi 8438else $as_nop 8439 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 8440printf "%s\n" "no" >&6; } 8441 CFLAGS="$saved_CFLAGS" 8442 8443fi 8444rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 8445} 8446 { 8447 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC supports compile flag -Wmisleading-indentation" >&5 8448printf %s "checking if $CC supports compile flag -Wmisleading-indentation... " >&6; } 8449 saved_CFLAGS="$CFLAGS" 8450 CFLAGS="$CFLAGS $WERROR -Wmisleading-indentation" 8451 _define_flag="" 8452 test "x$_define_flag" = "x" && _define_flag="-Wmisleading-indentation" 8453 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 8454/* end confdefs.h. */ 8455 8456#include <stdlib.h> 8457#include <stdarg.h> 8458#include <stdio.h> 8459#include <string.h> 8460#include <unistd.h> 8461/* Trivial function to help test for -fzero-call-used-regs */ 8462int f(int n) {return rand() % n;} 8463char *f2(char *s, ...) { 8464 char ret[64]; 8465 va_list args; 8466 va_start(args, s); 8467 vsnprintf(ret, sizeof(ret), s, args); 8468 va_end(args); 8469 return strdup(ret); 8470} 8471int i; 8472double d; 8473const char *f3(int s) { 8474 i = (int)d; 8475 return s ? "good" : "gooder"; 8476} 8477int main(int argc, char **argv) { 8478 char b[256], *cp; 8479 const char *s; 8480 /* Some math to catch -ftrapv problems in the toolchain */ 8481 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 8482 float l = i * 2.1; 8483 double m = l / 0.5; 8484 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 8485 (void)argv; 8486 f(1); 8487 s = f3(f(2)); 8488 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 8489 if (write(1, b, 0) == -1) exit(0); 8490 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 8491 if (write(1, cp, 0) == -1) exit(0); 8492 free(cp); 8493 /* 8494 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 8495 * not understand comments and we don't use the "fallthrough" attribute 8496 * that it's looking for. 8497 */ 8498 switch(i){ 8499 case 0: j += i; 8500 /* FALLTHROUGH */ 8501 default: j += k; 8502 } 8503 exit(0); 8504} 8505 8506 8507_ACEOF 8508if ac_fn_c_try_compile "$LINENO" 8509then : 8510 8511if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 8512then 8513 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 8514printf "%s\n" "no" >&6; } 8515 CFLAGS="$saved_CFLAGS" 8516else 8517 if test "$cross_compiling" = yes 8518then : 8519 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 8520printf "%s\n" "yes" >&6; } 8521 CFLAGS="$saved_CFLAGS $_define_flag" 8522else $as_nop 8523 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 8524/* end confdefs.h. */ 8525 8526#include <stdlib.h> 8527#include <stdarg.h> 8528#include <stdio.h> 8529#include <string.h> 8530#include <unistd.h> 8531/* Trivial function to help test for -fzero-call-used-regs */ 8532int f(int n) {return rand() % n;} 8533char *f2(char *s, ...) { 8534 char ret[64]; 8535 va_list args; 8536 va_start(args, s); 8537 vsnprintf(ret, sizeof(ret), s, args); 8538 va_end(args); 8539 return strdup(ret); 8540} 8541int i; 8542double d; 8543const char *f3(int s) { 8544 i = (int)d; 8545 return s ? "good" : "gooder"; 8546} 8547int main(int argc, char **argv) { 8548 char b[256], *cp; 8549 const char *s; 8550 /* Some math to catch -ftrapv problems in the toolchain */ 8551 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 8552 float l = i * 2.1; 8553 double m = l / 0.5; 8554 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 8555 (void)argv; 8556 f(1); 8557 s = f3(f(2)); 8558 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 8559 if (write(1, b, 0) == -1) exit(0); 8560 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 8561 if (write(1, cp, 0) == -1) exit(0); 8562 free(cp); 8563 /* 8564 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 8565 * not understand comments and we don't use the "fallthrough" attribute 8566 * that it's looking for. 8567 */ 8568 switch(i){ 8569 case 0: j += i; 8570 /* FALLTHROUGH */ 8571 default: j += k; 8572 } 8573 exit(0); 8574} 8575 8576 8577_ACEOF 8578if ac_fn_c_try_run "$LINENO" 8579then : 8580 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 8581printf "%s\n" "yes" >&6; } 8582 CFLAGS="$saved_CFLAGS $_define_flag" 8583else $as_nop 8584 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 8585printf "%s\n" "no, fails at run time" >&6; } 8586 CFLAGS="$saved_CFLAGS" 8587fi 8588rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 8589 conftest.$ac_objext conftest.beam conftest.$ac_ext 8590fi 8591 8592fi 8593else $as_nop 8594 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 8595printf "%s\n" "no" >&6; } 8596 CFLAGS="$saved_CFLAGS" 8597 8598fi 8599rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 8600} 8601 { 8602 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC supports compile flag -Wbitwise-instead-of-logical" >&5 8603printf %s "checking if $CC supports compile flag -Wbitwise-instead-of-logical... " >&6; } 8604 saved_CFLAGS="$CFLAGS" 8605 CFLAGS="$CFLAGS $WERROR -Wbitwise-instead-of-logical" 8606 _define_flag="" 8607 test "x$_define_flag" = "x" && _define_flag="-Wbitwise-instead-of-logical" 8608 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 8609/* end confdefs.h. */ 8610 8611#include <stdlib.h> 8612#include <stdarg.h> 8613#include <stdio.h> 8614#include <string.h> 8615#include <unistd.h> 8616/* Trivial function to help test for -fzero-call-used-regs */ 8617int f(int n) {return rand() % n;} 8618char *f2(char *s, ...) { 8619 char ret[64]; 8620 va_list args; 8621 va_start(args, s); 8622 vsnprintf(ret, sizeof(ret), s, args); 8623 va_end(args); 8624 return strdup(ret); 8625} 8626int i; 8627double d; 8628const char *f3(int s) { 8629 i = (int)d; 8630 return s ? "good" : "gooder"; 8631} 8632int main(int argc, char **argv) { 8633 char b[256], *cp; 8634 const char *s; 8635 /* Some math to catch -ftrapv problems in the toolchain */ 8636 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 8637 float l = i * 2.1; 8638 double m = l / 0.5; 8639 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 8640 (void)argv; 8641 f(1); 8642 s = f3(f(2)); 8643 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 8644 if (write(1, b, 0) == -1) exit(0); 8645 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 8646 if (write(1, cp, 0) == -1) exit(0); 8647 free(cp); 8648 /* 8649 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 8650 * not understand comments and we don't use the "fallthrough" attribute 8651 * that it's looking for. 8652 */ 8653 switch(i){ 8654 case 0: j += i; 8655 /* FALLTHROUGH */ 8656 default: j += k; 8657 } 8658 exit(0); 8659} 8660 8661 8662_ACEOF 8663if ac_fn_c_try_compile "$LINENO" 8664then : 8665 8666if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 8667then 8668 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 8669printf "%s\n" "no" >&6; } 8670 CFLAGS="$saved_CFLAGS" 8671else 8672 if test "$cross_compiling" = yes 8673then : 8674 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 8675printf "%s\n" "yes" >&6; } 8676 CFLAGS="$saved_CFLAGS $_define_flag" 8677else $as_nop 8678 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 8679/* end confdefs.h. */ 8680 8681#include <stdlib.h> 8682#include <stdarg.h> 8683#include <stdio.h> 8684#include <string.h> 8685#include <unistd.h> 8686/* Trivial function to help test for -fzero-call-used-regs */ 8687int f(int n) {return rand() % n;} 8688char *f2(char *s, ...) { 8689 char ret[64]; 8690 va_list args; 8691 va_start(args, s); 8692 vsnprintf(ret, sizeof(ret), s, args); 8693 va_end(args); 8694 return strdup(ret); 8695} 8696int i; 8697double d; 8698const char *f3(int s) { 8699 i = (int)d; 8700 return s ? "good" : "gooder"; 8701} 8702int main(int argc, char **argv) { 8703 char b[256], *cp; 8704 const char *s; 8705 /* Some math to catch -ftrapv problems in the toolchain */ 8706 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 8707 float l = i * 2.1; 8708 double m = l / 0.5; 8709 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 8710 (void)argv; 8711 f(1); 8712 s = f3(f(2)); 8713 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 8714 if (write(1, b, 0) == -1) exit(0); 8715 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 8716 if (write(1, cp, 0) == -1) exit(0); 8717 free(cp); 8718 /* 8719 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 8720 * not understand comments and we don't use the "fallthrough" attribute 8721 * that it's looking for. 8722 */ 8723 switch(i){ 8724 case 0: j += i; 8725 /* FALLTHROUGH */ 8726 default: j += k; 8727 } 8728 exit(0); 8729} 8730 8731 8732_ACEOF 8733if ac_fn_c_try_run "$LINENO" 8734then : 8735 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 8736printf "%s\n" "yes" >&6; } 8737 CFLAGS="$saved_CFLAGS $_define_flag" 8738else $as_nop 8739 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 8740printf "%s\n" "no, fails at run time" >&6; } 8741 CFLAGS="$saved_CFLAGS" 8742fi 8743rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 8744 conftest.$ac_objext conftest.beam conftest.$ac_ext 8745fi 8746 8747fi 8748else $as_nop 8749 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 8750printf "%s\n" "no" >&6; } 8751 CFLAGS="$saved_CFLAGS" 8752 8753fi 8754rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 8755} 8756 { 8757 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC supports compile flag -fno-strict-aliasing" >&5 8758printf %s "checking if $CC supports compile flag -fno-strict-aliasing... " >&6; } 8759 saved_CFLAGS="$CFLAGS" 8760 CFLAGS="$CFLAGS $WERROR -fno-strict-aliasing" 8761 _define_flag="" 8762 test "x$_define_flag" = "x" && _define_flag="-fno-strict-aliasing" 8763 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 8764/* end confdefs.h. */ 8765 8766#include <stdlib.h> 8767#include <stdarg.h> 8768#include <stdio.h> 8769#include <string.h> 8770#include <unistd.h> 8771/* Trivial function to help test for -fzero-call-used-regs */ 8772int f(int n) {return rand() % n;} 8773char *f2(char *s, ...) { 8774 char ret[64]; 8775 va_list args; 8776 va_start(args, s); 8777 vsnprintf(ret, sizeof(ret), s, args); 8778 va_end(args); 8779 return strdup(ret); 8780} 8781int i; 8782double d; 8783const char *f3(int s) { 8784 i = (int)d; 8785 return s ? "good" : "gooder"; 8786} 8787int main(int argc, char **argv) { 8788 char b[256], *cp; 8789 const char *s; 8790 /* Some math to catch -ftrapv problems in the toolchain */ 8791 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 8792 float l = i * 2.1; 8793 double m = l / 0.5; 8794 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 8795 (void)argv; 8796 f(1); 8797 s = f3(f(2)); 8798 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 8799 if (write(1, b, 0) == -1) exit(0); 8800 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 8801 if (write(1, cp, 0) == -1) exit(0); 8802 free(cp); 8803 /* 8804 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 8805 * not understand comments and we don't use the "fallthrough" attribute 8806 * that it's looking for. 8807 */ 8808 switch(i){ 8809 case 0: j += i; 8810 /* FALLTHROUGH */ 8811 default: j += k; 8812 } 8813 exit(0); 8814} 8815 8816 8817_ACEOF 8818if ac_fn_c_try_compile "$LINENO" 8819then : 8820 8821if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 8822then 8823 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 8824printf "%s\n" "no" >&6; } 8825 CFLAGS="$saved_CFLAGS" 8826else 8827 if test "$cross_compiling" = yes 8828then : 8829 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 8830printf "%s\n" "yes" >&6; } 8831 CFLAGS="$saved_CFLAGS $_define_flag" 8832else $as_nop 8833 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 8834/* end confdefs.h. */ 8835 8836#include <stdlib.h> 8837#include <stdarg.h> 8838#include <stdio.h> 8839#include <string.h> 8840#include <unistd.h> 8841/* Trivial function to help test for -fzero-call-used-regs */ 8842int f(int n) {return rand() % n;} 8843char *f2(char *s, ...) { 8844 char ret[64]; 8845 va_list args; 8846 va_start(args, s); 8847 vsnprintf(ret, sizeof(ret), s, args); 8848 va_end(args); 8849 return strdup(ret); 8850} 8851int i; 8852double d; 8853const char *f3(int s) { 8854 i = (int)d; 8855 return s ? "good" : "gooder"; 8856} 8857int main(int argc, char **argv) { 8858 char b[256], *cp; 8859 const char *s; 8860 /* Some math to catch -ftrapv problems in the toolchain */ 8861 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 8862 float l = i * 2.1; 8863 double m = l / 0.5; 8864 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 8865 (void)argv; 8866 f(1); 8867 s = f3(f(2)); 8868 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 8869 if (write(1, b, 0) == -1) exit(0); 8870 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 8871 if (write(1, cp, 0) == -1) exit(0); 8872 free(cp); 8873 /* 8874 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 8875 * not understand comments and we don't use the "fallthrough" attribute 8876 * that it's looking for. 8877 */ 8878 switch(i){ 8879 case 0: j += i; 8880 /* FALLTHROUGH */ 8881 default: j += k; 8882 } 8883 exit(0); 8884} 8885 8886 8887_ACEOF 8888if ac_fn_c_try_run "$LINENO" 8889then : 8890 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 8891printf "%s\n" "yes" >&6; } 8892 CFLAGS="$saved_CFLAGS $_define_flag" 8893else $as_nop 8894 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 8895printf "%s\n" "no, fails at run time" >&6; } 8896 CFLAGS="$saved_CFLAGS" 8897fi 8898rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 8899 conftest.$ac_objext conftest.beam conftest.$ac_ext 8900fi 8901 8902fi 8903else $as_nop 8904 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 8905printf "%s\n" "no" >&6; } 8906 CFLAGS="$saved_CFLAGS" 8907 8908fi 8909rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 8910} 8911 if test "x$use_toolchain_hardening" = "x1"; then 8912 { 8913 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC supports compile flag -D_FORTIFY_SOURCE=2" >&5 8914printf %s "checking if $CC supports compile flag -D_FORTIFY_SOURCE=2... " >&6; } 8915 saved_CFLAGS="$CFLAGS" 8916 CFLAGS="$CFLAGS $WERROR -D_FORTIFY_SOURCE=2" 8917 _define_flag="" 8918 test "x$_define_flag" = "x" && _define_flag="-D_FORTIFY_SOURCE=2" 8919 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 8920/* end confdefs.h. */ 8921 8922#include <stdlib.h> 8923#include <stdarg.h> 8924#include <stdio.h> 8925#include <string.h> 8926#include <unistd.h> 8927/* Trivial function to help test for -fzero-call-used-regs */ 8928int f(int n) {return rand() % n;} 8929char *f2(char *s, ...) { 8930 char ret[64]; 8931 va_list args; 8932 va_start(args, s); 8933 vsnprintf(ret, sizeof(ret), s, args); 8934 va_end(args); 8935 return strdup(ret); 8936} 8937int i; 8938double d; 8939const char *f3(int s) { 8940 i = (int)d; 8941 return s ? "good" : "gooder"; 8942} 8943int main(int argc, char **argv) { 8944 char b[256], *cp; 8945 const char *s; 8946 /* Some math to catch -ftrapv problems in the toolchain */ 8947 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 8948 float l = i * 2.1; 8949 double m = l / 0.5; 8950 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 8951 (void)argv; 8952 f(1); 8953 s = f3(f(2)); 8954 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 8955 if (write(1, b, 0) == -1) exit(0); 8956 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 8957 if (write(1, cp, 0) == -1) exit(0); 8958 free(cp); 8959 /* 8960 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 8961 * not understand comments and we don't use the "fallthrough" attribute 8962 * that it's looking for. 8963 */ 8964 switch(i){ 8965 case 0: j += i; 8966 /* FALLTHROUGH */ 8967 default: j += k; 8968 } 8969 exit(0); 8970} 8971 8972 8973_ACEOF 8974if ac_fn_c_try_compile "$LINENO" 8975then : 8976 8977if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 8978then 8979 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 8980printf "%s\n" "no" >&6; } 8981 CFLAGS="$saved_CFLAGS" 8982else 8983 if test "$cross_compiling" = yes 8984then : 8985 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 8986printf "%s\n" "yes" >&6; } 8987 CFLAGS="$saved_CFLAGS $_define_flag" 8988else $as_nop 8989 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 8990/* end confdefs.h. */ 8991 8992#include <stdlib.h> 8993#include <stdarg.h> 8994#include <stdio.h> 8995#include <string.h> 8996#include <unistd.h> 8997/* Trivial function to help test for -fzero-call-used-regs */ 8998int f(int n) {return rand() % n;} 8999char *f2(char *s, ...) { 9000 char ret[64]; 9001 va_list args; 9002 va_start(args, s); 9003 vsnprintf(ret, sizeof(ret), s, args); 9004 va_end(args); 9005 return strdup(ret); 9006} 9007int i; 9008double d; 9009const char *f3(int s) { 9010 i = (int)d; 9011 return s ? "good" : "gooder"; 9012} 9013int main(int argc, char **argv) { 9014 char b[256], *cp; 9015 const char *s; 9016 /* Some math to catch -ftrapv problems in the toolchain */ 9017 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 9018 float l = i * 2.1; 9019 double m = l / 0.5; 9020 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 9021 (void)argv; 9022 f(1); 9023 s = f3(f(2)); 9024 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 9025 if (write(1, b, 0) == -1) exit(0); 9026 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 9027 if (write(1, cp, 0) == -1) exit(0); 9028 free(cp); 9029 /* 9030 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 9031 * not understand comments and we don't use the "fallthrough" attribute 9032 * that it's looking for. 9033 */ 9034 switch(i){ 9035 case 0: j += i; 9036 /* FALLTHROUGH */ 9037 default: j += k; 9038 } 9039 exit(0); 9040} 9041 9042 9043_ACEOF 9044if ac_fn_c_try_run "$LINENO" 9045then : 9046 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 9047printf "%s\n" "yes" >&6; } 9048 CFLAGS="$saved_CFLAGS $_define_flag" 9049else $as_nop 9050 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 9051printf "%s\n" "no, fails at run time" >&6; } 9052 CFLAGS="$saved_CFLAGS" 9053fi 9054rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 9055 conftest.$ac_objext conftest.beam conftest.$ac_ext 9056fi 9057 9058fi 9059else $as_nop 9060 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 9061printf "%s\n" "no" >&6; } 9062 CFLAGS="$saved_CFLAGS" 9063 9064fi 9065rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 9066} 9067 { 9068 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $LD supports link flag -Wl,-z,relro" >&5 9069printf %s "checking if $LD supports link flag -Wl,-z,relro... " >&6; } 9070 saved_LDFLAGS="$LDFLAGS" 9071 LDFLAGS="$LDFLAGS $WERROR -Wl,-z,relro" 9072 _define_flag="" 9073 test "x$_define_flag" = "x" && _define_flag="-Wl,-z,relro" 9074 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 9075/* end confdefs.h. */ 9076 9077#include <stdlib.h> 9078#include <stdarg.h> 9079#include <stdio.h> 9080#include <string.h> 9081#include <unistd.h> 9082/* Trivial function to help test for -fzero-call-used-regs */ 9083int f(int n) {return rand() % n;} 9084char *f2(char *s, ...) { 9085 char ret[64]; 9086 va_list args; 9087 va_start(args, s); 9088 vsnprintf(ret, sizeof(ret), s, args); 9089 va_end(args); 9090 return strdup(ret); 9091} 9092int i; 9093double d; 9094const char *f3(int s) { 9095 i = (int)d; 9096 return s ? "good" : "gooder"; 9097} 9098int main(int argc, char **argv) { 9099 char b[256], *cp; 9100 const char *s; 9101 /* Some math to catch -ftrapv problems in the toolchain */ 9102 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 9103 float l = i * 2.1; 9104 double m = l / 0.5; 9105 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 9106 (void)argv; 9107 f(1); 9108 s = f3(f(2)); 9109 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 9110 if (write(1, b, 0) == -1) exit(0); 9111 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 9112 if (write(1, cp, 0) == -1) exit(0); 9113 free(cp); 9114 /* 9115 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 9116 * not understand comments and we don't use the "fallthrough" attribute 9117 * that it's looking for. 9118 */ 9119 switch(i){ 9120 case 0: j += i; 9121 /* FALLTHROUGH */ 9122 default: j += k; 9123 } 9124 exit(0); 9125} 9126 9127 9128_ACEOF 9129if ac_fn_c_try_link "$LINENO" 9130then : 9131 9132if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 9133then 9134 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 9135printf "%s\n" "no" >&6; } 9136 LDFLAGS="$saved_LDFLAGS" 9137else 9138 if test "$cross_compiling" = yes 9139then : 9140 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 9141printf "%s\n" "yes" >&6; } 9142 LDFLAGS="$saved_LDFLAGS $_define_flag" 9143 9144else $as_nop 9145 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 9146/* end confdefs.h. */ 9147 9148#include <stdlib.h> 9149#include <stdarg.h> 9150#include <stdio.h> 9151#include <string.h> 9152#include <unistd.h> 9153/* Trivial function to help test for -fzero-call-used-regs */ 9154int f(int n) {return rand() % n;} 9155char *f2(char *s, ...) { 9156 char ret[64]; 9157 va_list args; 9158 va_start(args, s); 9159 vsnprintf(ret, sizeof(ret), s, args); 9160 va_end(args); 9161 return strdup(ret); 9162} 9163int i; 9164double d; 9165const char *f3(int s) { 9166 i = (int)d; 9167 return s ? "good" : "gooder"; 9168} 9169int main(int argc, char **argv) { 9170 char b[256], *cp; 9171 const char *s; 9172 /* Some math to catch -ftrapv problems in the toolchain */ 9173 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 9174 float l = i * 2.1; 9175 double m = l / 0.5; 9176 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 9177 (void)argv; 9178 f(1); 9179 s = f3(f(2)); 9180 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 9181 if (write(1, b, 0) == -1) exit(0); 9182 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 9183 if (write(1, cp, 0) == -1) exit(0); 9184 free(cp); 9185 /* 9186 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 9187 * not understand comments and we don't use the "fallthrough" attribute 9188 * that it's looking for. 9189 */ 9190 switch(i){ 9191 case 0: j += i; 9192 /* FALLTHROUGH */ 9193 default: j += k; 9194 } 9195 exit(0); 9196} 9197 9198 9199_ACEOF 9200if ac_fn_c_try_run "$LINENO" 9201then : 9202 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 9203printf "%s\n" "yes" >&6; } 9204 LDFLAGS="$saved_LDFLAGS $_define_flag" 9205else $as_nop 9206 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 9207printf "%s\n" "no, fails at run time" >&6; } 9208 LDFLAGS="$saved_LDFLAGS" 9209fi 9210rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 9211 conftest.$ac_objext conftest.beam conftest.$ac_ext 9212fi 9213 9214fi 9215else $as_nop 9216 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 9217printf "%s\n" "no" >&6; } 9218 LDFLAGS="$saved_LDFLAGS" 9219 9220fi 9221rm -f core conftest.err conftest.$ac_objext conftest.beam \ 9222 conftest$ac_exeext conftest.$ac_ext 9223} 9224 { 9225 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $LD supports link flag -Wl,-z,now" >&5 9226printf %s "checking if $LD supports link flag -Wl,-z,now... " >&6; } 9227 saved_LDFLAGS="$LDFLAGS" 9228 LDFLAGS="$LDFLAGS $WERROR -Wl,-z,now" 9229 _define_flag="" 9230 test "x$_define_flag" = "x" && _define_flag="-Wl,-z,now" 9231 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 9232/* end confdefs.h. */ 9233 9234#include <stdlib.h> 9235#include <stdarg.h> 9236#include <stdio.h> 9237#include <string.h> 9238#include <unistd.h> 9239/* Trivial function to help test for -fzero-call-used-regs */ 9240int f(int n) {return rand() % n;} 9241char *f2(char *s, ...) { 9242 char ret[64]; 9243 va_list args; 9244 va_start(args, s); 9245 vsnprintf(ret, sizeof(ret), s, args); 9246 va_end(args); 9247 return strdup(ret); 9248} 9249int i; 9250double d; 9251const char *f3(int s) { 9252 i = (int)d; 9253 return s ? "good" : "gooder"; 9254} 9255int main(int argc, char **argv) { 9256 char b[256], *cp; 9257 const char *s; 9258 /* Some math to catch -ftrapv problems in the toolchain */ 9259 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 9260 float l = i * 2.1; 9261 double m = l / 0.5; 9262 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 9263 (void)argv; 9264 f(1); 9265 s = f3(f(2)); 9266 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 9267 if (write(1, b, 0) == -1) exit(0); 9268 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 9269 if (write(1, cp, 0) == -1) exit(0); 9270 free(cp); 9271 /* 9272 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 9273 * not understand comments and we don't use the "fallthrough" attribute 9274 * that it's looking for. 9275 */ 9276 switch(i){ 9277 case 0: j += i; 9278 /* FALLTHROUGH */ 9279 default: j += k; 9280 } 9281 exit(0); 9282} 9283 9284 9285_ACEOF 9286if ac_fn_c_try_link "$LINENO" 9287then : 9288 9289if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 9290then 9291 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 9292printf "%s\n" "no" >&6; } 9293 LDFLAGS="$saved_LDFLAGS" 9294else 9295 if test "$cross_compiling" = yes 9296then : 9297 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 9298printf "%s\n" "yes" >&6; } 9299 LDFLAGS="$saved_LDFLAGS $_define_flag" 9300 9301else $as_nop 9302 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 9303/* end confdefs.h. */ 9304 9305#include <stdlib.h> 9306#include <stdarg.h> 9307#include <stdio.h> 9308#include <string.h> 9309#include <unistd.h> 9310/* Trivial function to help test for -fzero-call-used-regs */ 9311int f(int n) {return rand() % n;} 9312char *f2(char *s, ...) { 9313 char ret[64]; 9314 va_list args; 9315 va_start(args, s); 9316 vsnprintf(ret, sizeof(ret), s, args); 9317 va_end(args); 9318 return strdup(ret); 9319} 9320int i; 9321double d; 9322const char *f3(int s) { 9323 i = (int)d; 9324 return s ? "good" : "gooder"; 9325} 9326int main(int argc, char **argv) { 9327 char b[256], *cp; 9328 const char *s; 9329 /* Some math to catch -ftrapv problems in the toolchain */ 9330 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 9331 float l = i * 2.1; 9332 double m = l / 0.5; 9333 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 9334 (void)argv; 9335 f(1); 9336 s = f3(f(2)); 9337 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 9338 if (write(1, b, 0) == -1) exit(0); 9339 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 9340 if (write(1, cp, 0) == -1) exit(0); 9341 free(cp); 9342 /* 9343 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 9344 * not understand comments and we don't use the "fallthrough" attribute 9345 * that it's looking for. 9346 */ 9347 switch(i){ 9348 case 0: j += i; 9349 /* FALLTHROUGH */ 9350 default: j += k; 9351 } 9352 exit(0); 9353} 9354 9355 9356_ACEOF 9357if ac_fn_c_try_run "$LINENO" 9358then : 9359 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 9360printf "%s\n" "yes" >&6; } 9361 LDFLAGS="$saved_LDFLAGS $_define_flag" 9362else $as_nop 9363 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 9364printf "%s\n" "no, fails at run time" >&6; } 9365 LDFLAGS="$saved_LDFLAGS" 9366fi 9367rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 9368 conftest.$ac_objext conftest.beam conftest.$ac_ext 9369fi 9370 9371fi 9372else $as_nop 9373 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 9374printf "%s\n" "no" >&6; } 9375 LDFLAGS="$saved_LDFLAGS" 9376 9377fi 9378rm -f core conftest.err conftest.$ac_objext conftest.beam \ 9379 conftest$ac_exeext conftest.$ac_ext 9380} 9381 { 9382 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $LD supports link flag -Wl,-z,noexecstack" >&5 9383printf %s "checking if $LD supports link flag -Wl,-z,noexecstack... " >&6; } 9384 saved_LDFLAGS="$LDFLAGS" 9385 LDFLAGS="$LDFLAGS $WERROR -Wl,-z,noexecstack" 9386 _define_flag="" 9387 test "x$_define_flag" = "x" && _define_flag="-Wl,-z,noexecstack" 9388 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 9389/* end confdefs.h. */ 9390 9391#include <stdlib.h> 9392#include <stdarg.h> 9393#include <stdio.h> 9394#include <string.h> 9395#include <unistd.h> 9396/* Trivial function to help test for -fzero-call-used-regs */ 9397int f(int n) {return rand() % n;} 9398char *f2(char *s, ...) { 9399 char ret[64]; 9400 va_list args; 9401 va_start(args, s); 9402 vsnprintf(ret, sizeof(ret), s, args); 9403 va_end(args); 9404 return strdup(ret); 9405} 9406int i; 9407double d; 9408const char *f3(int s) { 9409 i = (int)d; 9410 return s ? "good" : "gooder"; 9411} 9412int main(int argc, char **argv) { 9413 char b[256], *cp; 9414 const char *s; 9415 /* Some math to catch -ftrapv problems in the toolchain */ 9416 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 9417 float l = i * 2.1; 9418 double m = l / 0.5; 9419 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 9420 (void)argv; 9421 f(1); 9422 s = f3(f(2)); 9423 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 9424 if (write(1, b, 0) == -1) exit(0); 9425 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 9426 if (write(1, cp, 0) == -1) exit(0); 9427 free(cp); 9428 /* 9429 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 9430 * not understand comments and we don't use the "fallthrough" attribute 9431 * that it's looking for. 9432 */ 9433 switch(i){ 9434 case 0: j += i; 9435 /* FALLTHROUGH */ 9436 default: j += k; 9437 } 9438 exit(0); 9439} 9440 9441 9442_ACEOF 9443if ac_fn_c_try_link "$LINENO" 9444then : 9445 9446if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 9447then 9448 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 9449printf "%s\n" "no" >&6; } 9450 LDFLAGS="$saved_LDFLAGS" 9451else 9452 if test "$cross_compiling" = yes 9453then : 9454 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 9455printf "%s\n" "yes" >&6; } 9456 LDFLAGS="$saved_LDFLAGS $_define_flag" 9457 9458else $as_nop 9459 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 9460/* end confdefs.h. */ 9461 9462#include <stdlib.h> 9463#include <stdarg.h> 9464#include <stdio.h> 9465#include <string.h> 9466#include <unistd.h> 9467/* Trivial function to help test for -fzero-call-used-regs */ 9468int f(int n) {return rand() % n;} 9469char *f2(char *s, ...) { 9470 char ret[64]; 9471 va_list args; 9472 va_start(args, s); 9473 vsnprintf(ret, sizeof(ret), s, args); 9474 va_end(args); 9475 return strdup(ret); 9476} 9477int i; 9478double d; 9479const char *f3(int s) { 9480 i = (int)d; 9481 return s ? "good" : "gooder"; 9482} 9483int main(int argc, char **argv) { 9484 char b[256], *cp; 9485 const char *s; 9486 /* Some math to catch -ftrapv problems in the toolchain */ 9487 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 9488 float l = i * 2.1; 9489 double m = l / 0.5; 9490 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 9491 (void)argv; 9492 f(1); 9493 s = f3(f(2)); 9494 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 9495 if (write(1, b, 0) == -1) exit(0); 9496 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 9497 if (write(1, cp, 0) == -1) exit(0); 9498 free(cp); 9499 /* 9500 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 9501 * not understand comments and we don't use the "fallthrough" attribute 9502 * that it's looking for. 9503 */ 9504 switch(i){ 9505 case 0: j += i; 9506 /* FALLTHROUGH */ 9507 default: j += k; 9508 } 9509 exit(0); 9510} 9511 9512 9513_ACEOF 9514if ac_fn_c_try_run "$LINENO" 9515then : 9516 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 9517printf "%s\n" "yes" >&6; } 9518 LDFLAGS="$saved_LDFLAGS $_define_flag" 9519else $as_nop 9520 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 9521printf "%s\n" "no, fails at run time" >&6; } 9522 LDFLAGS="$saved_LDFLAGS" 9523fi 9524rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 9525 conftest.$ac_objext conftest.beam conftest.$ac_ext 9526fi 9527 9528fi 9529else $as_nop 9530 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 9531printf "%s\n" "no" >&6; } 9532 LDFLAGS="$saved_LDFLAGS" 9533 9534fi 9535rm -f core conftest.err conftest.$ac_objext conftest.beam \ 9536 conftest$ac_exeext conftest.$ac_ext 9537} 9538 # NB. -ftrapv expects certain support functions to be present in 9539 # the compiler library (libgcc or similar) to detect integer operations 9540 # that can overflow. We must check that the result of enabling it 9541 # actually links. The test program compiled/linked includes a number 9542 # of integer operations that should exercise this. 9543 { 9544 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC supports compile flag -ftrapv and linking succeeds" >&5 9545printf %s "checking if $CC supports compile flag -ftrapv and linking succeeds... " >&6; } 9546 saved_CFLAGS="$CFLAGS" 9547 CFLAGS="$CFLAGS $WERROR -ftrapv" 9548 _define_flag="" 9549 test "x$_define_flag" = "x" && _define_flag="-ftrapv" 9550 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 9551/* end confdefs.h. */ 9552 9553#include <stdlib.h> 9554#include <stdarg.h> 9555#include <stdio.h> 9556#include <string.h> 9557#include <unistd.h> 9558/* Trivial function to help test for -fzero-call-used-regs */ 9559int f(int n) {return rand() % n;} 9560char *f2(char *s, ...) { 9561 char ret[64]; 9562 va_list args; 9563 va_start(args, s); 9564 vsnprintf(ret, sizeof(ret), s, args); 9565 va_end(args); 9566 return strdup(ret); 9567} 9568int i; 9569double d; 9570const char *f3(int s) { 9571 i = (int)d; 9572 return s ? "good" : "gooder"; 9573} 9574int main(int argc, char **argv) { 9575 char b[256], *cp; 9576 const char *s; 9577 /* Some math to catch -ftrapv problems in the toolchain */ 9578 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 9579 float l = i * 2.1; 9580 double m = l / 0.5; 9581 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 9582 (void)argv; 9583 f(1); 9584 s = f3(f(2)); 9585 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 9586 if (write(1, b, 0) == -1) exit(0); 9587 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 9588 if (write(1, cp, 0) == -1) exit(0); 9589 free(cp); 9590 /* 9591 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 9592 * not understand comments and we don't use the "fallthrough" attribute 9593 * that it's looking for. 9594 */ 9595 switch(i){ 9596 case 0: j += i; 9597 /* FALLTHROUGH */ 9598 default: j += k; 9599 } 9600 exit(0); 9601} 9602 9603 9604_ACEOF 9605if ac_fn_c_try_link "$LINENO" 9606then : 9607 9608if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 9609then 9610 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 9611printf "%s\n" "no" >&6; } 9612 CFLAGS="$saved_CFLAGS" 9613else 9614 if test "$cross_compiling" = yes 9615then : 9616 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 9617printf "%s\n" "yes" >&6; } 9618 CFLAGS="$saved_CFLAGS $_define_flag" 9619else $as_nop 9620 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 9621/* end confdefs.h. */ 9622 9623#include <stdlib.h> 9624#include <stdarg.h> 9625#include <stdio.h> 9626#include <string.h> 9627#include <unistd.h> 9628/* Trivial function to help test for -fzero-call-used-regs */ 9629int f(int n) {return rand() % n;} 9630char *f2(char *s, ...) { 9631 char ret[64]; 9632 va_list args; 9633 va_start(args, s); 9634 vsnprintf(ret, sizeof(ret), s, args); 9635 va_end(args); 9636 return strdup(ret); 9637} 9638int i; 9639double d; 9640const char *f3(int s) { 9641 i = (int)d; 9642 return s ? "good" : "gooder"; 9643} 9644int main(int argc, char **argv) { 9645 char b[256], *cp; 9646 const char *s; 9647 /* Some math to catch -ftrapv problems in the toolchain */ 9648 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 9649 float l = i * 2.1; 9650 double m = l / 0.5; 9651 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 9652 (void)argv; 9653 f(1); 9654 s = f3(f(2)); 9655 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 9656 if (write(1, b, 0) == -1) exit(0); 9657 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 9658 if (write(1, cp, 0) == -1) exit(0); 9659 free(cp); 9660 /* 9661 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 9662 * not understand comments and we don't use the "fallthrough" attribute 9663 * that it's looking for. 9664 */ 9665 switch(i){ 9666 case 0: j += i; 9667 /* FALLTHROUGH */ 9668 default: j += k; 9669 } 9670 exit(0); 9671} 9672 9673 9674_ACEOF 9675if ac_fn_c_try_run "$LINENO" 9676then : 9677 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 9678printf "%s\n" "yes" >&6; } 9679 CFLAGS="$saved_CFLAGS $_define_flag" 9680else $as_nop 9681 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 9682printf "%s\n" "no, fails at run time" >&6; } 9683 CFLAGS="$saved_CFLAGS" 9684fi 9685rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 9686 conftest.$ac_objext conftest.beam conftest.$ac_ext 9687fi 9688 9689fi 9690else $as_nop 9691 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 9692printf "%s\n" "no" >&6; } 9693 CFLAGS="$saved_CFLAGS" 9694 9695fi 9696rm -f core conftest.err conftest.$ac_objext conftest.beam \ 9697 conftest$ac_exeext conftest.$ac_ext 9698} 9699 # clang 15 seems to have a bug in -fzero-call-used-regs=all. See 9700 # https://bugzilla.mindrot.org/show_bug.cgi?id=3475 and 9701 # https://github.com/llvm/llvm-project/issues/59242 9702 # clang 17 has a different bug that causes an ICE when using this 9703 # flag at all (https://bugzilla.mindrot.org/show_bug.cgi?id=3629) 9704 case "$CLANG_VER" in 9705 apple-15*) { 9706 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC supports compile flag -fzero-call-used-regs=used and linking succeeds" >&5 9707printf %s "checking if $CC supports compile flag -fzero-call-used-regs=used and linking succeeds... " >&6; } 9708 saved_CFLAGS="$CFLAGS" 9709 CFLAGS="$CFLAGS $WERROR -fzero-call-used-regs=used" 9710 _define_flag="" 9711 test "x$_define_flag" = "x" && _define_flag="-fzero-call-used-regs=used" 9712 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 9713/* end confdefs.h. */ 9714 9715#include <stdlib.h> 9716#include <stdarg.h> 9717#include <stdio.h> 9718#include <string.h> 9719#include <unistd.h> 9720/* Trivial function to help test for -fzero-call-used-regs */ 9721int f(int n) {return rand() % n;} 9722char *f2(char *s, ...) { 9723 char ret[64]; 9724 va_list args; 9725 va_start(args, s); 9726 vsnprintf(ret, sizeof(ret), s, args); 9727 va_end(args); 9728 return strdup(ret); 9729} 9730int i; 9731double d; 9732const char *f3(int s) { 9733 i = (int)d; 9734 return s ? "good" : "gooder"; 9735} 9736int main(int argc, char **argv) { 9737 char b[256], *cp; 9738 const char *s; 9739 /* Some math to catch -ftrapv problems in the toolchain */ 9740 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 9741 float l = i * 2.1; 9742 double m = l / 0.5; 9743 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 9744 (void)argv; 9745 f(1); 9746 s = f3(f(2)); 9747 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 9748 if (write(1, b, 0) == -1) exit(0); 9749 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 9750 if (write(1, cp, 0) == -1) exit(0); 9751 free(cp); 9752 /* 9753 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 9754 * not understand comments and we don't use the "fallthrough" attribute 9755 * that it's looking for. 9756 */ 9757 switch(i){ 9758 case 0: j += i; 9759 /* FALLTHROUGH */ 9760 default: j += k; 9761 } 9762 exit(0); 9763} 9764 9765 9766_ACEOF 9767if ac_fn_c_try_link "$LINENO" 9768then : 9769 9770if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 9771then 9772 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 9773printf "%s\n" "no" >&6; } 9774 CFLAGS="$saved_CFLAGS" 9775else 9776 if test "$cross_compiling" = yes 9777then : 9778 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 9779printf "%s\n" "yes" >&6; } 9780 CFLAGS="$saved_CFLAGS $_define_flag" 9781else $as_nop 9782 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 9783/* end confdefs.h. */ 9784 9785#include <stdlib.h> 9786#include <stdarg.h> 9787#include <stdio.h> 9788#include <string.h> 9789#include <unistd.h> 9790/* Trivial function to help test for -fzero-call-used-regs */ 9791int f(int n) {return rand() % n;} 9792char *f2(char *s, ...) { 9793 char ret[64]; 9794 va_list args; 9795 va_start(args, s); 9796 vsnprintf(ret, sizeof(ret), s, args); 9797 va_end(args); 9798 return strdup(ret); 9799} 9800int i; 9801double d; 9802const char *f3(int s) { 9803 i = (int)d; 9804 return s ? "good" : "gooder"; 9805} 9806int main(int argc, char **argv) { 9807 char b[256], *cp; 9808 const char *s; 9809 /* Some math to catch -ftrapv problems in the toolchain */ 9810 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 9811 float l = i * 2.1; 9812 double m = l / 0.5; 9813 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 9814 (void)argv; 9815 f(1); 9816 s = f3(f(2)); 9817 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 9818 if (write(1, b, 0) == -1) exit(0); 9819 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 9820 if (write(1, cp, 0) == -1) exit(0); 9821 free(cp); 9822 /* 9823 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 9824 * not understand comments and we don't use the "fallthrough" attribute 9825 * that it's looking for. 9826 */ 9827 switch(i){ 9828 case 0: j += i; 9829 /* FALLTHROUGH */ 9830 default: j += k; 9831 } 9832 exit(0); 9833} 9834 9835 9836_ACEOF 9837if ac_fn_c_try_run "$LINENO" 9838then : 9839 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 9840printf "%s\n" "yes" >&6; } 9841 CFLAGS="$saved_CFLAGS $_define_flag" 9842else $as_nop 9843 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 9844printf "%s\n" "no, fails at run time" >&6; } 9845 CFLAGS="$saved_CFLAGS" 9846fi 9847rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 9848 conftest.$ac_objext conftest.beam conftest.$ac_ext 9849fi 9850 9851fi 9852else $as_nop 9853 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 9854printf "%s\n" "no" >&6; } 9855 CFLAGS="$saved_CFLAGS" 9856 9857fi 9858rm -f core conftest.err conftest.$ac_objext conftest.beam \ 9859 conftest$ac_exeext conftest.$ac_ext 9860} ;; 9861 17*) ;; 9862 *) { 9863 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC supports compile flag -fzero-call-used-regs=used and linking succeeds" >&5 9864printf %s "checking if $CC supports compile flag -fzero-call-used-regs=used and linking succeeds... " >&6; } 9865 saved_CFLAGS="$CFLAGS" 9866 CFLAGS="$CFLAGS $WERROR -fzero-call-used-regs=used" 9867 _define_flag="" 9868 test "x$_define_flag" = "x" && _define_flag="-fzero-call-used-regs=used" 9869 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 9870/* end confdefs.h. */ 9871 9872#include <stdlib.h> 9873#include <stdarg.h> 9874#include <stdio.h> 9875#include <string.h> 9876#include <unistd.h> 9877/* Trivial function to help test for -fzero-call-used-regs */ 9878int f(int n) {return rand() % n;} 9879char *f2(char *s, ...) { 9880 char ret[64]; 9881 va_list args; 9882 va_start(args, s); 9883 vsnprintf(ret, sizeof(ret), s, args); 9884 va_end(args); 9885 return strdup(ret); 9886} 9887int i; 9888double d; 9889const char *f3(int s) { 9890 i = (int)d; 9891 return s ? "good" : "gooder"; 9892} 9893int main(int argc, char **argv) { 9894 char b[256], *cp; 9895 const char *s; 9896 /* Some math to catch -ftrapv problems in the toolchain */ 9897 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 9898 float l = i * 2.1; 9899 double m = l / 0.5; 9900 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 9901 (void)argv; 9902 f(1); 9903 s = f3(f(2)); 9904 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 9905 if (write(1, b, 0) == -1) exit(0); 9906 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 9907 if (write(1, cp, 0) == -1) exit(0); 9908 free(cp); 9909 /* 9910 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 9911 * not understand comments and we don't use the "fallthrough" attribute 9912 * that it's looking for. 9913 */ 9914 switch(i){ 9915 case 0: j += i; 9916 /* FALLTHROUGH */ 9917 default: j += k; 9918 } 9919 exit(0); 9920} 9921 9922 9923_ACEOF 9924if ac_fn_c_try_link "$LINENO" 9925then : 9926 9927if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 9928then 9929 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 9930printf "%s\n" "no" >&6; } 9931 CFLAGS="$saved_CFLAGS" 9932else 9933 if test "$cross_compiling" = yes 9934then : 9935 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 9936printf "%s\n" "yes" >&6; } 9937 CFLAGS="$saved_CFLAGS $_define_flag" 9938else $as_nop 9939 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 9940/* end confdefs.h. */ 9941 9942#include <stdlib.h> 9943#include <stdarg.h> 9944#include <stdio.h> 9945#include <string.h> 9946#include <unistd.h> 9947/* Trivial function to help test for -fzero-call-used-regs */ 9948int f(int n) {return rand() % n;} 9949char *f2(char *s, ...) { 9950 char ret[64]; 9951 va_list args; 9952 va_start(args, s); 9953 vsnprintf(ret, sizeof(ret), s, args); 9954 va_end(args); 9955 return strdup(ret); 9956} 9957int i; 9958double d; 9959const char *f3(int s) { 9960 i = (int)d; 9961 return s ? "good" : "gooder"; 9962} 9963int main(int argc, char **argv) { 9964 char b[256], *cp; 9965 const char *s; 9966 /* Some math to catch -ftrapv problems in the toolchain */ 9967 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 9968 float l = i * 2.1; 9969 double m = l / 0.5; 9970 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 9971 (void)argv; 9972 f(1); 9973 s = f3(f(2)); 9974 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 9975 if (write(1, b, 0) == -1) exit(0); 9976 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 9977 if (write(1, cp, 0) == -1) exit(0); 9978 free(cp); 9979 /* 9980 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 9981 * not understand comments and we don't use the "fallthrough" attribute 9982 * that it's looking for. 9983 */ 9984 switch(i){ 9985 case 0: j += i; 9986 /* FALLTHROUGH */ 9987 default: j += k; 9988 } 9989 exit(0); 9990} 9991 9992 9993_ACEOF 9994if ac_fn_c_try_run "$LINENO" 9995then : 9996 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 9997printf "%s\n" "yes" >&6; } 9998 CFLAGS="$saved_CFLAGS $_define_flag" 9999else $as_nop 10000 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 10001printf "%s\n" "no, fails at run time" >&6; } 10002 CFLAGS="$saved_CFLAGS" 10003fi 10004rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 10005 conftest.$ac_objext conftest.beam conftest.$ac_ext 10006fi 10007 10008fi 10009else $as_nop 10010 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 10011printf "%s\n" "no" >&6; } 10012 CFLAGS="$saved_CFLAGS" 10013 10014fi 10015rm -f core conftest.err conftest.$ac_objext conftest.beam \ 10016 conftest$ac_exeext conftest.$ac_ext 10017} ;; 10018 esac 10019 { 10020 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC supports compile flag -ftrivial-auto-var-init=zero" >&5 10021printf %s "checking if $CC supports compile flag -ftrivial-auto-var-init=zero... " >&6; } 10022 saved_CFLAGS="$CFLAGS" 10023 CFLAGS="$CFLAGS $WERROR -ftrivial-auto-var-init=zero" 10024 _define_flag="" 10025 test "x$_define_flag" = "x" && _define_flag="-ftrivial-auto-var-init=zero" 10026 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 10027/* end confdefs.h. */ 10028 10029#include <stdlib.h> 10030#include <stdarg.h> 10031#include <stdio.h> 10032#include <string.h> 10033#include <unistd.h> 10034/* Trivial function to help test for -fzero-call-used-regs */ 10035int f(int n) {return rand() % n;} 10036char *f2(char *s, ...) { 10037 char ret[64]; 10038 va_list args; 10039 va_start(args, s); 10040 vsnprintf(ret, sizeof(ret), s, args); 10041 va_end(args); 10042 return strdup(ret); 10043} 10044int i; 10045double d; 10046const char *f3(int s) { 10047 i = (int)d; 10048 return s ? "good" : "gooder"; 10049} 10050int main(int argc, char **argv) { 10051 char b[256], *cp; 10052 const char *s; 10053 /* Some math to catch -ftrapv problems in the toolchain */ 10054 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 10055 float l = i * 2.1; 10056 double m = l / 0.5; 10057 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 10058 (void)argv; 10059 f(1); 10060 s = f3(f(2)); 10061 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 10062 if (write(1, b, 0) == -1) exit(0); 10063 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 10064 if (write(1, cp, 0) == -1) exit(0); 10065 free(cp); 10066 /* 10067 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 10068 * not understand comments and we don't use the "fallthrough" attribute 10069 * that it's looking for. 10070 */ 10071 switch(i){ 10072 case 0: j += i; 10073 /* FALLTHROUGH */ 10074 default: j += k; 10075 } 10076 exit(0); 10077} 10078 10079 10080_ACEOF 10081if ac_fn_c_try_compile "$LINENO" 10082then : 10083 10084if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 10085then 10086 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 10087printf "%s\n" "no" >&6; } 10088 CFLAGS="$saved_CFLAGS" 10089else 10090 if test "$cross_compiling" = yes 10091then : 10092 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 10093printf "%s\n" "yes" >&6; } 10094 CFLAGS="$saved_CFLAGS $_define_flag" 10095else $as_nop 10096 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 10097/* end confdefs.h. */ 10098 10099#include <stdlib.h> 10100#include <stdarg.h> 10101#include <stdio.h> 10102#include <string.h> 10103#include <unistd.h> 10104/* Trivial function to help test for -fzero-call-used-regs */ 10105int f(int n) {return rand() % n;} 10106char *f2(char *s, ...) { 10107 char ret[64]; 10108 va_list args; 10109 va_start(args, s); 10110 vsnprintf(ret, sizeof(ret), s, args); 10111 va_end(args); 10112 return strdup(ret); 10113} 10114int i; 10115double d; 10116const char *f3(int s) { 10117 i = (int)d; 10118 return s ? "good" : "gooder"; 10119} 10120int main(int argc, char **argv) { 10121 char b[256], *cp; 10122 const char *s; 10123 /* Some math to catch -ftrapv problems in the toolchain */ 10124 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 10125 float l = i * 2.1; 10126 double m = l / 0.5; 10127 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 10128 (void)argv; 10129 f(1); 10130 s = f3(f(2)); 10131 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 10132 if (write(1, b, 0) == -1) exit(0); 10133 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 10134 if (write(1, cp, 0) == -1) exit(0); 10135 free(cp); 10136 /* 10137 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 10138 * not understand comments and we don't use the "fallthrough" attribute 10139 * that it's looking for. 10140 */ 10141 switch(i){ 10142 case 0: j += i; 10143 /* FALLTHROUGH */ 10144 default: j += k; 10145 } 10146 exit(0); 10147} 10148 10149 10150_ACEOF 10151if ac_fn_c_try_run "$LINENO" 10152then : 10153 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 10154printf "%s\n" "yes" >&6; } 10155 CFLAGS="$saved_CFLAGS $_define_flag" 10156else $as_nop 10157 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 10158printf "%s\n" "no, fails at run time" >&6; } 10159 CFLAGS="$saved_CFLAGS" 10160fi 10161rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 10162 conftest.$ac_objext conftest.beam conftest.$ac_ext 10163fi 10164 10165fi 10166else $as_nop 10167 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 10168printf "%s\n" "no" >&6; } 10169 CFLAGS="$saved_CFLAGS" 10170 10171fi 10172rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 10173} 10174 fi 10175 if test "x$use_retpoline" = "x1"; then 10176 { 10177 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC supports compile flag -mretpoline" >&5 10178printf %s "checking if $CC supports compile flag -mretpoline... " >&6; } 10179 saved_CFLAGS="$CFLAGS" 10180 CFLAGS="$CFLAGS $WERROR -mretpoline" 10181 _define_flag="" 10182 test "x$_define_flag" = "x" && _define_flag="-mretpoline" 10183 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 10184/* end confdefs.h. */ 10185 10186#include <stdlib.h> 10187#include <stdarg.h> 10188#include <stdio.h> 10189#include <string.h> 10190#include <unistd.h> 10191/* Trivial function to help test for -fzero-call-used-regs */ 10192int f(int n) {return rand() % n;} 10193char *f2(char *s, ...) { 10194 char ret[64]; 10195 va_list args; 10196 va_start(args, s); 10197 vsnprintf(ret, sizeof(ret), s, args); 10198 va_end(args); 10199 return strdup(ret); 10200} 10201int i; 10202double d; 10203const char *f3(int s) { 10204 i = (int)d; 10205 return s ? "good" : "gooder"; 10206} 10207int main(int argc, char **argv) { 10208 char b[256], *cp; 10209 const char *s; 10210 /* Some math to catch -ftrapv problems in the toolchain */ 10211 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 10212 float l = i * 2.1; 10213 double m = l / 0.5; 10214 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 10215 (void)argv; 10216 f(1); 10217 s = f3(f(2)); 10218 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 10219 if (write(1, b, 0) == -1) exit(0); 10220 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 10221 if (write(1, cp, 0) == -1) exit(0); 10222 free(cp); 10223 /* 10224 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 10225 * not understand comments and we don't use the "fallthrough" attribute 10226 * that it's looking for. 10227 */ 10228 switch(i){ 10229 case 0: j += i; 10230 /* FALLTHROUGH */ 10231 default: j += k; 10232 } 10233 exit(0); 10234} 10235 10236 10237_ACEOF 10238if ac_fn_c_try_compile "$LINENO" 10239then : 10240 10241if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 10242then 10243 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 10244printf "%s\n" "no" >&6; } 10245 CFLAGS="$saved_CFLAGS" 10246else 10247 if test "$cross_compiling" = yes 10248then : 10249 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 10250printf "%s\n" "yes" >&6; } 10251 CFLAGS="$saved_CFLAGS $_define_flag" 10252else $as_nop 10253 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 10254/* end confdefs.h. */ 10255 10256#include <stdlib.h> 10257#include <stdarg.h> 10258#include <stdio.h> 10259#include <string.h> 10260#include <unistd.h> 10261/* Trivial function to help test for -fzero-call-used-regs */ 10262int f(int n) {return rand() % n;} 10263char *f2(char *s, ...) { 10264 char ret[64]; 10265 va_list args; 10266 va_start(args, s); 10267 vsnprintf(ret, sizeof(ret), s, args); 10268 va_end(args); 10269 return strdup(ret); 10270} 10271int i; 10272double d; 10273const char *f3(int s) { 10274 i = (int)d; 10275 return s ? "good" : "gooder"; 10276} 10277int main(int argc, char **argv) { 10278 char b[256], *cp; 10279 const char *s; 10280 /* Some math to catch -ftrapv problems in the toolchain */ 10281 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 10282 float l = i * 2.1; 10283 double m = l / 0.5; 10284 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 10285 (void)argv; 10286 f(1); 10287 s = f3(f(2)); 10288 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 10289 if (write(1, b, 0) == -1) exit(0); 10290 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 10291 if (write(1, cp, 0) == -1) exit(0); 10292 free(cp); 10293 /* 10294 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 10295 * not understand comments and we don't use the "fallthrough" attribute 10296 * that it's looking for. 10297 */ 10298 switch(i){ 10299 case 0: j += i; 10300 /* FALLTHROUGH */ 10301 default: j += k; 10302 } 10303 exit(0); 10304} 10305 10306 10307_ACEOF 10308if ac_fn_c_try_run "$LINENO" 10309then : 10310 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 10311printf "%s\n" "yes" >&6; } 10312 CFLAGS="$saved_CFLAGS $_define_flag" 10313else $as_nop 10314 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 10315printf "%s\n" "no, fails at run time" >&6; } 10316 CFLAGS="$saved_CFLAGS" 10317fi 10318rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 10319 conftest.$ac_objext conftest.beam conftest.$ac_ext 10320fi 10321 10322fi 10323else $as_nop 10324 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 10325printf "%s\n" "no" >&6; } 10326 CFLAGS="$saved_CFLAGS" 10327 10328fi 10329rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 10330} # clang 10331 { 10332 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $LD supports link flag -Wl,-z,retpolineplt" >&5 10333printf %s "checking if $LD supports link flag -Wl,-z,retpolineplt... " >&6; } 10334 saved_LDFLAGS="$LDFLAGS" 10335 LDFLAGS="$LDFLAGS $WERROR -Wl,-z,retpolineplt" 10336 _define_flag="" 10337 test "x$_define_flag" = "x" && _define_flag="-Wl,-z,retpolineplt" 10338 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 10339/* end confdefs.h. */ 10340 10341#include <stdlib.h> 10342#include <stdarg.h> 10343#include <stdio.h> 10344#include <string.h> 10345#include <unistd.h> 10346/* Trivial function to help test for -fzero-call-used-regs */ 10347int f(int n) {return rand() % n;} 10348char *f2(char *s, ...) { 10349 char ret[64]; 10350 va_list args; 10351 va_start(args, s); 10352 vsnprintf(ret, sizeof(ret), s, args); 10353 va_end(args); 10354 return strdup(ret); 10355} 10356int i; 10357double d; 10358const char *f3(int s) { 10359 i = (int)d; 10360 return s ? "good" : "gooder"; 10361} 10362int main(int argc, char **argv) { 10363 char b[256], *cp; 10364 const char *s; 10365 /* Some math to catch -ftrapv problems in the toolchain */ 10366 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 10367 float l = i * 2.1; 10368 double m = l / 0.5; 10369 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 10370 (void)argv; 10371 f(1); 10372 s = f3(f(2)); 10373 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 10374 if (write(1, b, 0) == -1) exit(0); 10375 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 10376 if (write(1, cp, 0) == -1) exit(0); 10377 free(cp); 10378 /* 10379 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 10380 * not understand comments and we don't use the "fallthrough" attribute 10381 * that it's looking for. 10382 */ 10383 switch(i){ 10384 case 0: j += i; 10385 /* FALLTHROUGH */ 10386 default: j += k; 10387 } 10388 exit(0); 10389} 10390 10391 10392_ACEOF 10393if ac_fn_c_try_link "$LINENO" 10394then : 10395 10396if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 10397then 10398 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 10399printf "%s\n" "no" >&6; } 10400 LDFLAGS="$saved_LDFLAGS" 10401else 10402 if test "$cross_compiling" = yes 10403then : 10404 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 10405printf "%s\n" "yes" >&6; } 10406 LDFLAGS="$saved_LDFLAGS $_define_flag" 10407 10408else $as_nop 10409 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 10410/* end confdefs.h. */ 10411 10412#include <stdlib.h> 10413#include <stdarg.h> 10414#include <stdio.h> 10415#include <string.h> 10416#include <unistd.h> 10417/* Trivial function to help test for -fzero-call-used-regs */ 10418int f(int n) {return rand() % n;} 10419char *f2(char *s, ...) { 10420 char ret[64]; 10421 va_list args; 10422 va_start(args, s); 10423 vsnprintf(ret, sizeof(ret), s, args); 10424 va_end(args); 10425 return strdup(ret); 10426} 10427int i; 10428double d; 10429const char *f3(int s) { 10430 i = (int)d; 10431 return s ? "good" : "gooder"; 10432} 10433int main(int argc, char **argv) { 10434 char b[256], *cp; 10435 const char *s; 10436 /* Some math to catch -ftrapv problems in the toolchain */ 10437 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 10438 float l = i * 2.1; 10439 double m = l / 0.5; 10440 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 10441 (void)argv; 10442 f(1); 10443 s = f3(f(2)); 10444 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 10445 if (write(1, b, 0) == -1) exit(0); 10446 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 10447 if (write(1, cp, 0) == -1) exit(0); 10448 free(cp); 10449 /* 10450 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 10451 * not understand comments and we don't use the "fallthrough" attribute 10452 * that it's looking for. 10453 */ 10454 switch(i){ 10455 case 0: j += i; 10456 /* FALLTHROUGH */ 10457 default: j += k; 10458 } 10459 exit(0); 10460} 10461 10462 10463_ACEOF 10464if ac_fn_c_try_run "$LINENO" 10465then : 10466 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 10467printf "%s\n" "yes" >&6; } 10468 LDFLAGS="$saved_LDFLAGS $_define_flag" 10469else $as_nop 10470 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 10471printf "%s\n" "no, fails at run time" >&6; } 10472 LDFLAGS="$saved_LDFLAGS" 10473fi 10474rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 10475 conftest.$ac_objext conftest.beam conftest.$ac_ext 10476fi 10477 10478fi 10479else $as_nop 10480 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 10481printf "%s\n" "no" >&6; } 10482 LDFLAGS="$saved_LDFLAGS" 10483 10484fi 10485rm -f core conftest.err conftest.$ac_objext conftest.beam \ 10486 conftest$ac_exeext conftest.$ac_ext 10487} 10488 fi 10489 10490 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC accepts -fno-builtin-memset" >&5 10491printf %s "checking if $CC accepts -fno-builtin-memset... " >&6; } 10492 saved_CFLAGS="$CFLAGS" 10493 CFLAGS="$CFLAGS -fno-builtin-memset" 10494 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 10495/* end confdefs.h. */ 10496 #include <string.h> 10497int 10498main (void) 10499{ 10500 char b[10]; memset(b, 0, sizeof(b)); 10501 ; 10502 return 0; 10503} 10504_ACEOF 10505if ac_fn_c_try_link "$LINENO" 10506then : 10507 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 10508printf "%s\n" "yes" >&6; } 10509else $as_nop 10510 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 10511printf "%s\n" "no" >&6; } 10512 CFLAGS="$saved_CFLAGS" 10513 10514fi 10515rm -f core conftest.err conftest.$ac_objext conftest.beam \ 10516 conftest$ac_exeext conftest.$ac_ext 10517 10518 # -fstack-protector-all doesn't always work for some GCC versions 10519 # and/or platforms, so we test if we can. If it's not supported 10520 # on a given platform gcc will emit a warning so we use -Werror. 10521 if test "x$use_stack_protector" = "x1"; then 10522 for t in -fstack-protector-strong -fstack-protector-all \ 10523 -fstack-protector; do 10524 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC supports $t" >&5 10525printf %s "checking if $CC supports $t... " >&6; } 10526 saved_CFLAGS="$CFLAGS" 10527 saved_LDFLAGS="$LDFLAGS" 10528 CFLAGS="$CFLAGS $t -Werror" 10529 LDFLAGS="$LDFLAGS $t -Werror" 10530 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 10531/* end confdefs.h. */ 10532 10533 #include <stdio.h> 10534 int func (int t) {char b[100]; snprintf(b,sizeof b,"%d",t); return t;} 10535 10536int 10537main (void) 10538{ 10539 10540 char x[256]; 10541 snprintf(x, sizeof(x), "XXX%d", func(1)); 10542 10543 ; 10544 return 0; 10545} 10546_ACEOF 10547if ac_fn_c_try_link "$LINENO" 10548then : 10549 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 10550printf "%s\n" "yes" >&6; } 10551 CFLAGS="$saved_CFLAGS $t" 10552 LDFLAGS="$saved_LDFLAGS $t" 10553 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $t works" >&5 10554printf %s "checking if $t works... " >&6; } 10555 if test "$cross_compiling" = yes 10556then : 10557 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: cannot test" >&5 10558printf "%s\n" "$as_me: WARNING: cross compiling: cannot test" >&2;} 10559 break 10560 10561else $as_nop 10562 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 10563/* end confdefs.h. */ 10564 10565 #include <stdio.h> 10566 int func (int t) {char b[100]; snprintf(b,sizeof b,"%d",t); return t;} 10567 10568int 10569main (void) 10570{ 10571 10572 char x[256]; 10573 snprintf(x, sizeof(x), "XXX%d", func(1)); 10574 10575 ; 10576 return 0; 10577} 10578_ACEOF 10579if ac_fn_c_try_run "$LINENO" 10580then : 10581 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 10582printf "%s\n" "yes" >&6; } 10583 break 10584else $as_nop 10585 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 10586printf "%s\n" "no" >&6; } 10587fi 10588rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 10589 conftest.$ac_objext conftest.beam conftest.$ac_ext 10590fi 10591 10592 10593else $as_nop 10594 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 10595printf "%s\n" "no" >&6; } 10596 10597fi 10598rm -f core conftest.err conftest.$ac_objext conftest.beam \ 10599 conftest$ac_exeext conftest.$ac_ext 10600 CFLAGS="$saved_CFLAGS" 10601 LDFLAGS="$saved_LDFLAGS" 10602 done 10603 fi 10604 10605 if test -z "$have_llong_max"; then 10606 # retry LLONG_MAX with -std=gnu99, needed on some Linuxes 10607 unset ac_cv_have_decl_LLONG_MAX 10608 saved_CFLAGS="$CFLAGS" 10609 CFLAGS="$CFLAGS -std=gnu99" 10610 ac_fn_check_decl "$LINENO" "LLONG_MAX" "ac_cv_have_decl_LLONG_MAX" "#include <limits.h> 10611 10612" "$ac_c_undeclared_builtin_options" "CFLAGS" 10613if test "x$ac_cv_have_decl_LLONG_MAX" = xyes 10614then : 10615 have_llong_max=1 10616else $as_nop 10617 CFLAGS="$saved_CFLAGS" 10618fi 10619 fi 10620fi 10621 10622{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if compiler allows __attribute__ on return types" >&5 10623printf %s "checking if compiler allows __attribute__ on return types... " >&6; } 10624cat confdefs.h - <<_ACEOF >conftest.$ac_ext 10625/* end confdefs.h. */ 10626 10627#include <stdlib.h> 10628__attribute__((__unused__)) static void foo(void){return;} 10629int 10630main (void) 10631{ 10632 exit(0); 10633 ; 10634 return 0; 10635} 10636_ACEOF 10637if ac_fn_c_try_compile "$LINENO" 10638then : 10639 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 10640printf "%s\n" "yes" >&6; } 10641else $as_nop 10642 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 10643printf "%s\n" "no" >&6; } 10644 10645printf "%s\n" "#define NO_ATTRIBUTE_ON_RETURN_TYPE 1" >>confdefs.h 10646 10647 10648fi 10649rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 10650 10651{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if compiler allows __attribute__ prototype args" >&5 10652printf %s "checking if compiler allows __attribute__ prototype args... " >&6; } 10653cat confdefs.h - <<_ACEOF >conftest.$ac_ext 10654/* end confdefs.h. */ 10655 10656#include <stdlib.h> 10657typedef void foo(const char *, ...) __attribute__((format(printf, 1, 2))); 10658int 10659main (void) 10660{ 10661 exit(0); 10662 ; 10663 return 0; 10664} 10665_ACEOF 10666if ac_fn_c_try_compile "$LINENO" 10667then : 10668 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 10669printf "%s\n" "yes" >&6; } 10670else $as_nop 10671 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 10672printf "%s\n" "no" >&6; } 10673 10674printf "%s\n" "#define NO_ATTRIBUTE_ON_PROTOTYPE_ARGS 1" >>confdefs.h 10675 10676 10677fi 10678rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 10679 10680{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if compiler supports variable length arrays" >&5 10681printf %s "checking if compiler supports variable length arrays... " >&6; } 10682cat confdefs.h - <<_ACEOF >conftest.$ac_ext 10683/* end confdefs.h. */ 10684#include <stdlib.h> 10685int 10686main (void) 10687{ 10688 int i; for (i=0; i<3; i++){int a[i]; a[i-1]=0;} exit(0); 10689 ; 10690 return 0; 10691} 10692_ACEOF 10693if ac_fn_c_try_compile "$LINENO" 10694then : 10695 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 10696printf "%s\n" "yes" >&6; } 10697 10698printf "%s\n" "#define VARIABLE_LENGTH_ARRAYS 1" >>confdefs.h 10699 10700else $as_nop 10701 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 10702printf "%s\n" "no" >&6; } 10703 10704fi 10705rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 10706 10707{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if compiler accepts variable declarations after code" >&5 10708printf %s "checking if compiler accepts variable declarations after code... " >&6; } 10709cat confdefs.h - <<_ACEOF >conftest.$ac_ext 10710/* end confdefs.h. */ 10711#include <stdlib.h> 10712int 10713main (void) 10714{ 10715 int a; a = 1; int b = 1; exit(a-b); 10716 ; 10717 return 0; 10718} 10719_ACEOF 10720if ac_fn_c_try_compile "$LINENO" 10721then : 10722 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 10723printf "%s\n" "yes" >&6; } 10724 10725printf "%s\n" "#define VARIABLE_DECLARATION_AFTER_CODE 1" >>confdefs.h 10726 10727else $as_nop 10728 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 10729printf "%s\n" "no" >&6; } 10730 10731fi 10732rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 10733 10734if test "x$no_attrib_nonnull" != "x1" ; then 10735 10736printf "%s\n" "#define HAVE_ATTRIBUTE__NONNULL__ 1" >>confdefs.h 10737 10738fi 10739 10740 10741# Check whether --with-rpath was given. 10742if test ${with_rpath+y} 10743then : 10744 withval=$with_rpath; 10745 if test "x$withval" = "xno" ; then 10746 rpath_opt="" 10747 elif test "x$withval" = "xyes" ; then 10748 rpath_opt="-R" 10749 else 10750 rpath_opt="$withval" 10751 fi 10752 10753 10754fi 10755 10756 10757# Allow user to specify flags 10758 10759# Check whether --with-cflags was given. 10760if test ${with_cflags+y} 10761then : 10762 withval=$with_cflags; 10763 if test -n "$withval" && test "x$withval" != "xno" && \ 10764 test "x${withval}" != "xyes"; then 10765 CFLAGS="$CFLAGS $withval" 10766 fi 10767 10768 10769fi 10770 10771 10772 10773# Check whether --with-cflags-after was given. 10774if test ${with_cflags_after+y} 10775then : 10776 withval=$with_cflags_after; 10777 if test -n "$withval" && test "x$withval" != "xno" && \ 10778 test "x${withval}" != "xyes"; then 10779 CFLAGS_AFTER="$withval" 10780 fi 10781 10782 10783fi 10784 10785 10786# Check whether --with-cppflags was given. 10787if test ${with_cppflags+y} 10788then : 10789 withval=$with_cppflags; 10790 if test -n "$withval" && test "x$withval" != "xno" && \ 10791 test "x${withval}" != "xyes"; then 10792 CPPFLAGS="$CPPFLAGS $withval" 10793 fi 10794 10795 10796fi 10797 10798 10799# Check whether --with-ldflags was given. 10800if test ${with_ldflags+y} 10801then : 10802 withval=$with_ldflags; 10803 if test -n "$withval" && test "x$withval" != "xno" && \ 10804 test "x${withval}" != "xyes"; then 10805 LDFLAGS="$LDFLAGS $withval" 10806 fi 10807 10808 10809fi 10810 10811 10812# Check whether --with-ldflags-after was given. 10813if test ${with_ldflags_after+y} 10814then : 10815 withval=$with_ldflags_after; 10816 if test -n "$withval" && test "x$withval" != "xno" && \ 10817 test "x${withval}" != "xyes"; then 10818 LDFLAGS_AFTER="$withval" 10819 fi 10820 10821 10822fi 10823 10824 10825# Check whether --with-libs was given. 10826if test ${with_libs+y} 10827then : 10828 withval=$with_libs; 10829 if test -n "$withval" && test "x$withval" != "xno" && \ 10830 test "x${withval}" != "xyes"; then 10831 LIBS="$LIBS $withval" 10832 fi 10833 10834 10835fi 10836 10837 10838# Check whether --with-Werror was given. 10839if test ${with_Werror+y} 10840then : 10841 withval=$with_Werror; 10842 if test -n "$withval" && test "x$withval" != "xno"; then 10843 werror_flags="-Werror" 10844 if test "x${withval}" != "xyes"; then 10845 werror_flags="$withval" 10846 fi 10847 fi 10848 10849 10850fi 10851 10852 10853if test "x$ac_cv_header_sys_stat_h" != "xyes"; then 10854 unset ac_cv_header_sys_stat_h 10855 ac_fn_c_check_header_compile "$LINENO" "sys/stat.h" "ac_cv_header_sys_stat_h" "$ac_includes_default" 10856if test "x$ac_cv_header_sys_stat_h" = xyes 10857then : 10858 printf "%s\n" "#define HAVE_SYS_STAT_H 1" >>confdefs.h 10859 10860fi 10861 10862fi 10863 10864ac_fn_c_check_header_compile "$LINENO" "blf.h" "ac_cv_header_blf_h" "$ac_includes_default" 10865if test "x$ac_cv_header_blf_h" = xyes 10866then : 10867 printf "%s\n" "#define HAVE_BLF_H 1" >>confdefs.h 10868 10869fi 10870ac_fn_c_check_header_compile "$LINENO" "bstring.h" "ac_cv_header_bstring_h" "$ac_includes_default" 10871if test "x$ac_cv_header_bstring_h" = xyes 10872then : 10873 printf "%s\n" "#define HAVE_BSTRING_H 1" >>confdefs.h 10874 10875fi 10876ac_fn_c_check_header_compile "$LINENO" "crypt.h" "ac_cv_header_crypt_h" "$ac_includes_default" 10877if test "x$ac_cv_header_crypt_h" = xyes 10878then : 10879 printf "%s\n" "#define HAVE_CRYPT_H 1" >>confdefs.h 10880 10881fi 10882ac_fn_c_check_header_compile "$LINENO" "crypto/sha2.h" "ac_cv_header_crypto_sha2_h" "$ac_includes_default" 10883if test "x$ac_cv_header_crypto_sha2_h" = xyes 10884then : 10885 printf "%s\n" "#define HAVE_CRYPTO_SHA2_H 1" >>confdefs.h 10886 10887fi 10888ac_fn_c_check_header_compile "$LINENO" "dirent.h" "ac_cv_header_dirent_h" "$ac_includes_default" 10889if test "x$ac_cv_header_dirent_h" = xyes 10890then : 10891 printf "%s\n" "#define HAVE_DIRENT_H 1" >>confdefs.h 10892 10893fi 10894ac_fn_c_check_header_compile "$LINENO" "endian.h" "ac_cv_header_endian_h" "$ac_includes_default" 10895if test "x$ac_cv_header_endian_h" = xyes 10896then : 10897 printf "%s\n" "#define HAVE_ENDIAN_H 1" >>confdefs.h 10898 10899fi 10900ac_fn_c_check_header_compile "$LINENO" "elf.h" "ac_cv_header_elf_h" "$ac_includes_default" 10901if test "x$ac_cv_header_elf_h" = xyes 10902then : 10903 printf "%s\n" "#define HAVE_ELF_H 1" >>confdefs.h 10904 10905fi 10906ac_fn_c_check_header_compile "$LINENO" "err.h" "ac_cv_header_err_h" "$ac_includes_default" 10907if test "x$ac_cv_header_err_h" = xyes 10908then : 10909 printf "%s\n" "#define HAVE_ERR_H 1" >>confdefs.h 10910 10911fi 10912ac_fn_c_check_header_compile "$LINENO" "features.h" "ac_cv_header_features_h" "$ac_includes_default" 10913if test "x$ac_cv_header_features_h" = xyes 10914then : 10915 printf "%s\n" "#define HAVE_FEATURES_H 1" >>confdefs.h 10916 10917fi 10918ac_fn_c_check_header_compile "$LINENO" "fcntl.h" "ac_cv_header_fcntl_h" "$ac_includes_default" 10919if test "x$ac_cv_header_fcntl_h" = xyes 10920then : 10921 printf "%s\n" "#define HAVE_FCNTL_H 1" >>confdefs.h 10922 10923fi 10924ac_fn_c_check_header_compile "$LINENO" "floatingpoint.h" "ac_cv_header_floatingpoint_h" "$ac_includes_default" 10925if test "x$ac_cv_header_floatingpoint_h" = xyes 10926then : 10927 printf "%s\n" "#define HAVE_FLOATINGPOINT_H 1" >>confdefs.h 10928 10929fi 10930ac_fn_c_check_header_compile "$LINENO" "fnmatch.h" "ac_cv_header_fnmatch_h" "$ac_includes_default" 10931if test "x$ac_cv_header_fnmatch_h" = xyes 10932then : 10933 printf "%s\n" "#define HAVE_FNMATCH_H 1" >>confdefs.h 10934 10935fi 10936ac_fn_c_check_header_compile "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default" 10937if test "x$ac_cv_header_getopt_h" = xyes 10938then : 10939 printf "%s\n" "#define HAVE_GETOPT_H 1" >>confdefs.h 10940 10941fi 10942ac_fn_c_check_header_compile "$LINENO" "glob.h" "ac_cv_header_glob_h" "$ac_includes_default" 10943if test "x$ac_cv_header_glob_h" = xyes 10944then : 10945 printf "%s\n" "#define HAVE_GLOB_H 1" >>confdefs.h 10946 10947fi 10948ac_fn_c_check_header_compile "$LINENO" "ia.h" "ac_cv_header_ia_h" "$ac_includes_default" 10949if test "x$ac_cv_header_ia_h" = xyes 10950then : 10951 printf "%s\n" "#define HAVE_IA_H 1" >>confdefs.h 10952 10953fi 10954ac_fn_c_check_header_compile "$LINENO" "iaf.h" "ac_cv_header_iaf_h" "$ac_includes_default" 10955if test "x$ac_cv_header_iaf_h" = xyes 10956then : 10957 printf "%s\n" "#define HAVE_IAF_H 1" >>confdefs.h 10958 10959fi 10960ac_fn_c_check_header_compile "$LINENO" "ifaddrs.h" "ac_cv_header_ifaddrs_h" "$ac_includes_default" 10961if test "x$ac_cv_header_ifaddrs_h" = xyes 10962then : 10963 printf "%s\n" "#define HAVE_IFADDRS_H 1" >>confdefs.h 10964 10965fi 10966ac_fn_c_check_header_compile "$LINENO" "inttypes.h" "ac_cv_header_inttypes_h" "$ac_includes_default" 10967if test "x$ac_cv_header_inttypes_h" = xyes 10968then : 10969 printf "%s\n" "#define HAVE_INTTYPES_H 1" >>confdefs.h 10970 10971fi 10972ac_fn_c_check_header_compile "$LINENO" "langinfo.h" "ac_cv_header_langinfo_h" "$ac_includes_default" 10973if test "x$ac_cv_header_langinfo_h" = xyes 10974then : 10975 printf "%s\n" "#define HAVE_LANGINFO_H 1" >>confdefs.h 10976 10977fi 10978ac_fn_c_check_header_compile "$LINENO" "limits.h" "ac_cv_header_limits_h" "$ac_includes_default" 10979if test "x$ac_cv_header_limits_h" = xyes 10980then : 10981 printf "%s\n" "#define HAVE_LIMITS_H 1" >>confdefs.h 10982 10983fi 10984ac_fn_c_check_header_compile "$LINENO" "locale.h" "ac_cv_header_locale_h" "$ac_includes_default" 10985if test "x$ac_cv_header_locale_h" = xyes 10986then : 10987 printf "%s\n" "#define HAVE_LOCALE_H 1" >>confdefs.h 10988 10989fi 10990ac_fn_c_check_header_compile "$LINENO" "login.h" "ac_cv_header_login_h" "$ac_includes_default" 10991if test "x$ac_cv_header_login_h" = xyes 10992then : 10993 printf "%s\n" "#define HAVE_LOGIN_H 1" >>confdefs.h 10994 10995fi 10996ac_fn_c_check_header_compile "$LINENO" "maillock.h" "ac_cv_header_maillock_h" "$ac_includes_default" 10997if test "x$ac_cv_header_maillock_h" = xyes 10998then : 10999 printf "%s\n" "#define HAVE_MAILLOCK_H 1" >>confdefs.h 11000 11001fi 11002ac_fn_c_check_header_compile "$LINENO" "ndir.h" "ac_cv_header_ndir_h" "$ac_includes_default" 11003if test "x$ac_cv_header_ndir_h" = xyes 11004then : 11005 printf "%s\n" "#define HAVE_NDIR_H 1" >>confdefs.h 11006 11007fi 11008ac_fn_c_check_header_compile "$LINENO" "net/if_tun.h" "ac_cv_header_net_if_tun_h" "$ac_includes_default" 11009if test "x$ac_cv_header_net_if_tun_h" = xyes 11010then : 11011 printf "%s\n" "#define HAVE_NET_IF_TUN_H 1" >>confdefs.h 11012 11013fi 11014ac_fn_c_check_header_compile "$LINENO" "netdb.h" "ac_cv_header_netdb_h" "$ac_includes_default" 11015if test "x$ac_cv_header_netdb_h" = xyes 11016then : 11017 printf "%s\n" "#define HAVE_NETDB_H 1" >>confdefs.h 11018 11019fi 11020ac_fn_c_check_header_compile "$LINENO" "netgroup.h" "ac_cv_header_netgroup_h" "$ac_includes_default" 11021if test "x$ac_cv_header_netgroup_h" = xyes 11022then : 11023 printf "%s\n" "#define HAVE_NETGROUP_H 1" >>confdefs.h 11024 11025fi 11026ac_fn_c_check_header_compile "$LINENO" "pam/pam_appl.h" "ac_cv_header_pam_pam_appl_h" "$ac_includes_default" 11027if test "x$ac_cv_header_pam_pam_appl_h" = xyes 11028then : 11029 printf "%s\n" "#define HAVE_PAM_PAM_APPL_H 1" >>confdefs.h 11030 11031fi 11032ac_fn_c_check_header_compile "$LINENO" "paths.h" "ac_cv_header_paths_h" "$ac_includes_default" 11033if test "x$ac_cv_header_paths_h" = xyes 11034then : 11035 printf "%s\n" "#define HAVE_PATHS_H 1" >>confdefs.h 11036 11037fi 11038ac_fn_c_check_header_compile "$LINENO" "poll.h" "ac_cv_header_poll_h" "$ac_includes_default" 11039if test "x$ac_cv_header_poll_h" = xyes 11040then : 11041 printf "%s\n" "#define HAVE_POLL_H 1" >>confdefs.h 11042 11043fi 11044ac_fn_c_check_header_compile "$LINENO" "pty.h" "ac_cv_header_pty_h" "$ac_includes_default" 11045if test "x$ac_cv_header_pty_h" = xyes 11046then : 11047 printf "%s\n" "#define HAVE_PTY_H 1" >>confdefs.h 11048 11049fi 11050ac_fn_c_check_header_compile "$LINENO" "readpassphrase.h" "ac_cv_header_readpassphrase_h" "$ac_includes_default" 11051if test "x$ac_cv_header_readpassphrase_h" = xyes 11052then : 11053 printf "%s\n" "#define HAVE_READPASSPHRASE_H 1" >>confdefs.h 11054 11055fi 11056ac_fn_c_check_header_compile "$LINENO" "rpc/types.h" "ac_cv_header_rpc_types_h" "$ac_includes_default" 11057if test "x$ac_cv_header_rpc_types_h" = xyes 11058then : 11059 printf "%s\n" "#define HAVE_RPC_TYPES_H 1" >>confdefs.h 11060 11061fi 11062ac_fn_c_check_header_compile "$LINENO" "security/pam_appl.h" "ac_cv_header_security_pam_appl_h" "$ac_includes_default" 11063if test "x$ac_cv_header_security_pam_appl_h" = xyes 11064then : 11065 printf "%s\n" "#define HAVE_SECURITY_PAM_APPL_H 1" >>confdefs.h 11066 11067fi 11068ac_fn_c_check_header_compile "$LINENO" "sha2.h" "ac_cv_header_sha2_h" "$ac_includes_default" 11069if test "x$ac_cv_header_sha2_h" = xyes 11070then : 11071 printf "%s\n" "#define HAVE_SHA2_H 1" >>confdefs.h 11072 11073fi 11074ac_fn_c_check_header_compile "$LINENO" "shadow.h" "ac_cv_header_shadow_h" "$ac_includes_default" 11075if test "x$ac_cv_header_shadow_h" = xyes 11076then : 11077 printf "%s\n" "#define HAVE_SHADOW_H 1" >>confdefs.h 11078 11079fi 11080ac_fn_c_check_header_compile "$LINENO" "stddef.h" "ac_cv_header_stddef_h" "$ac_includes_default" 11081if test "x$ac_cv_header_stddef_h" = xyes 11082then : 11083 printf "%s\n" "#define HAVE_STDDEF_H 1" >>confdefs.h 11084 11085fi 11086ac_fn_c_check_header_compile "$LINENO" "stdint.h" "ac_cv_header_stdint_h" "$ac_includes_default" 11087if test "x$ac_cv_header_stdint_h" = xyes 11088then : 11089 printf "%s\n" "#define HAVE_STDINT_H 1" >>confdefs.h 11090 11091fi 11092ac_fn_c_check_header_compile "$LINENO" "string.h" "ac_cv_header_string_h" "$ac_includes_default" 11093if test "x$ac_cv_header_string_h" = xyes 11094then : 11095 printf "%s\n" "#define HAVE_STRING_H 1" >>confdefs.h 11096 11097fi 11098ac_fn_c_check_header_compile "$LINENO" "strings.h" "ac_cv_header_strings_h" "$ac_includes_default" 11099if test "x$ac_cv_header_strings_h" = xyes 11100then : 11101 printf "%s\n" "#define HAVE_STRINGS_H 1" >>confdefs.h 11102 11103fi 11104ac_fn_c_check_header_compile "$LINENO" "sys/bitypes.h" "ac_cv_header_sys_bitypes_h" "$ac_includes_default" 11105if test "x$ac_cv_header_sys_bitypes_h" = xyes 11106then : 11107 printf "%s\n" "#define HAVE_SYS_BITYPES_H 1" >>confdefs.h 11108 11109fi 11110ac_fn_c_check_header_compile "$LINENO" "sys/byteorder.h" "ac_cv_header_sys_byteorder_h" "$ac_includes_default" 11111if test "x$ac_cv_header_sys_byteorder_h" = xyes 11112then : 11113 printf "%s\n" "#define HAVE_SYS_BYTEORDER_H 1" >>confdefs.h 11114 11115fi 11116ac_fn_c_check_header_compile "$LINENO" "sys/bsdtty.h" "ac_cv_header_sys_bsdtty_h" "$ac_includes_default" 11117if test "x$ac_cv_header_sys_bsdtty_h" = xyes 11118then : 11119 printf "%s\n" "#define HAVE_SYS_BSDTTY_H 1" >>confdefs.h 11120 11121fi 11122ac_fn_c_check_header_compile "$LINENO" "sys/cdefs.h" "ac_cv_header_sys_cdefs_h" "$ac_includes_default" 11123if test "x$ac_cv_header_sys_cdefs_h" = xyes 11124then : 11125 printf "%s\n" "#define HAVE_SYS_CDEFS_H 1" >>confdefs.h 11126 11127fi 11128ac_fn_c_check_header_compile "$LINENO" "sys/dir.h" "ac_cv_header_sys_dir_h" "$ac_includes_default" 11129if test "x$ac_cv_header_sys_dir_h" = xyes 11130then : 11131 printf "%s\n" "#define HAVE_SYS_DIR_H 1" >>confdefs.h 11132 11133fi 11134ac_fn_c_check_header_compile "$LINENO" "sys/file.h" "ac_cv_header_sys_file_h" "$ac_includes_default" 11135if test "x$ac_cv_header_sys_file_h" = xyes 11136then : 11137 printf "%s\n" "#define HAVE_SYS_FILE_H 1" >>confdefs.h 11138 11139fi 11140ac_fn_c_check_header_compile "$LINENO" "sys/mman.h" "ac_cv_header_sys_mman_h" "$ac_includes_default" 11141if test "x$ac_cv_header_sys_mman_h" = xyes 11142then : 11143 printf "%s\n" "#define HAVE_SYS_MMAN_H 1" >>confdefs.h 11144 11145fi 11146ac_fn_c_check_header_compile "$LINENO" "sys/label.h" "ac_cv_header_sys_label_h" "$ac_includes_default" 11147if test "x$ac_cv_header_sys_label_h" = xyes 11148then : 11149 printf "%s\n" "#define HAVE_SYS_LABEL_H 1" >>confdefs.h 11150 11151fi 11152ac_fn_c_check_header_compile "$LINENO" "sys/ndir.h" "ac_cv_header_sys_ndir_h" "$ac_includes_default" 11153if test "x$ac_cv_header_sys_ndir_h" = xyes 11154then : 11155 printf "%s\n" "#define HAVE_SYS_NDIR_H 1" >>confdefs.h 11156 11157fi 11158ac_fn_c_check_header_compile "$LINENO" "sys/param.h" "ac_cv_header_sys_param_h" "$ac_includes_default" 11159if test "x$ac_cv_header_sys_param_h" = xyes 11160then : 11161 printf "%s\n" "#define HAVE_SYS_PARAM_H 1" >>confdefs.h 11162 11163fi 11164ac_fn_c_check_header_compile "$LINENO" "sys/poll.h" "ac_cv_header_sys_poll_h" "$ac_includes_default" 11165if test "x$ac_cv_header_sys_poll_h" = xyes 11166then : 11167 printf "%s\n" "#define HAVE_SYS_POLL_H 1" >>confdefs.h 11168 11169fi 11170ac_fn_c_check_header_compile "$LINENO" "sys/prctl.h" "ac_cv_header_sys_prctl_h" "$ac_includes_default" 11171if test "x$ac_cv_header_sys_prctl_h" = xyes 11172then : 11173 printf "%s\n" "#define HAVE_SYS_PRCTL_H 1" >>confdefs.h 11174 11175fi 11176ac_fn_c_check_header_compile "$LINENO" "sys/procctl.h" "ac_cv_header_sys_procctl_h" "$ac_includes_default" 11177if test "x$ac_cv_header_sys_procctl_h" = xyes 11178then : 11179 printf "%s\n" "#define HAVE_SYS_PROCCTL_H 1" >>confdefs.h 11180 11181fi 11182ac_fn_c_check_header_compile "$LINENO" "sys/pstat.h" "ac_cv_header_sys_pstat_h" "$ac_includes_default" 11183if test "x$ac_cv_header_sys_pstat_h" = xyes 11184then : 11185 printf "%s\n" "#define HAVE_SYS_PSTAT_H 1" >>confdefs.h 11186 11187fi 11188ac_fn_c_check_header_compile "$LINENO" "sys/ptrace.h" "ac_cv_header_sys_ptrace_h" "$ac_includes_default" 11189if test "x$ac_cv_header_sys_ptrace_h" = xyes 11190then : 11191 printf "%s\n" "#define HAVE_SYS_PTRACE_H 1" >>confdefs.h 11192 11193fi 11194ac_fn_c_check_header_compile "$LINENO" "sys/random.h" "ac_cv_header_sys_random_h" "$ac_includes_default" 11195if test "x$ac_cv_header_sys_random_h" = xyes 11196then : 11197 printf "%s\n" "#define HAVE_SYS_RANDOM_H 1" >>confdefs.h 11198 11199fi 11200ac_fn_c_check_header_compile "$LINENO" "sys/select.h" "ac_cv_header_sys_select_h" "$ac_includes_default" 11201if test "x$ac_cv_header_sys_select_h" = xyes 11202then : 11203 printf "%s\n" "#define HAVE_SYS_SELECT_H 1" >>confdefs.h 11204 11205fi 11206ac_fn_c_check_header_compile "$LINENO" "sys/stream.h" "ac_cv_header_sys_stream_h" "$ac_includes_default" 11207if test "x$ac_cv_header_sys_stream_h" = xyes 11208then : 11209 printf "%s\n" "#define HAVE_SYS_STREAM_H 1" >>confdefs.h 11210 11211fi 11212ac_fn_c_check_header_compile "$LINENO" "sys/stropts.h" "ac_cv_header_sys_stropts_h" "$ac_includes_default" 11213if test "x$ac_cv_header_sys_stropts_h" = xyes 11214then : 11215 printf "%s\n" "#define HAVE_SYS_STROPTS_H 1" >>confdefs.h 11216 11217fi 11218ac_fn_c_check_header_compile "$LINENO" "sys/strtio.h" "ac_cv_header_sys_strtio_h" "$ac_includes_default" 11219if test "x$ac_cv_header_sys_strtio_h" = xyes 11220then : 11221 printf "%s\n" "#define HAVE_SYS_STRTIO_H 1" >>confdefs.h 11222 11223fi 11224ac_fn_c_check_header_compile "$LINENO" "sys/statvfs.h" "ac_cv_header_sys_statvfs_h" "$ac_includes_default" 11225if test "x$ac_cv_header_sys_statvfs_h" = xyes 11226then : 11227 printf "%s\n" "#define HAVE_SYS_STATVFS_H 1" >>confdefs.h 11228 11229fi 11230ac_fn_c_check_header_compile "$LINENO" "sys/sysmacros.h" "ac_cv_header_sys_sysmacros_h" "$ac_includes_default" 11231if test "x$ac_cv_header_sys_sysmacros_h" = xyes 11232then : 11233 printf "%s\n" "#define HAVE_SYS_SYSMACROS_H 1" >>confdefs.h 11234 11235fi 11236ac_fn_c_check_header_compile "$LINENO" "sys/time.h" "ac_cv_header_sys_time_h" "$ac_includes_default" 11237if test "x$ac_cv_header_sys_time_h" = xyes 11238then : 11239 printf "%s\n" "#define HAVE_SYS_TIME_H 1" >>confdefs.h 11240 11241fi 11242ac_fn_c_check_header_compile "$LINENO" "sys/timers.h" "ac_cv_header_sys_timers_h" "$ac_includes_default" 11243if test "x$ac_cv_header_sys_timers_h" = xyes 11244then : 11245 printf "%s\n" "#define HAVE_SYS_TIMERS_H 1" >>confdefs.h 11246 11247fi 11248ac_fn_c_check_header_compile "$LINENO" "sys/vfs.h" "ac_cv_header_sys_vfs_h" "$ac_includes_default" 11249if test "x$ac_cv_header_sys_vfs_h" = xyes 11250then : 11251 printf "%s\n" "#define HAVE_SYS_VFS_H 1" >>confdefs.h 11252 11253fi 11254ac_fn_c_check_header_compile "$LINENO" "time.h" "ac_cv_header_time_h" "$ac_includes_default" 11255if test "x$ac_cv_header_time_h" = xyes 11256then : 11257 printf "%s\n" "#define HAVE_TIME_H 1" >>confdefs.h 11258 11259fi 11260ac_fn_c_check_header_compile "$LINENO" "tmpdir.h" "ac_cv_header_tmpdir_h" "$ac_includes_default" 11261if test "x$ac_cv_header_tmpdir_h" = xyes 11262then : 11263 printf "%s\n" "#define HAVE_TMPDIR_H 1" >>confdefs.h 11264 11265fi 11266ac_fn_c_check_header_compile "$LINENO" "ttyent.h" "ac_cv_header_ttyent_h" "$ac_includes_default" 11267if test "x$ac_cv_header_ttyent_h" = xyes 11268then : 11269 printf "%s\n" "#define HAVE_TTYENT_H 1" >>confdefs.h 11270 11271fi 11272ac_fn_c_check_header_compile "$LINENO" "ucred.h" "ac_cv_header_ucred_h" "$ac_includes_default" 11273if test "x$ac_cv_header_ucred_h" = xyes 11274then : 11275 printf "%s\n" "#define HAVE_UCRED_H 1" >>confdefs.h 11276 11277fi 11278ac_fn_c_check_header_compile "$LINENO" "unistd.h" "ac_cv_header_unistd_h" "$ac_includes_default" 11279if test "x$ac_cv_header_unistd_h" = xyes 11280then : 11281 printf "%s\n" "#define HAVE_UNISTD_H 1" >>confdefs.h 11282 11283fi 11284ac_fn_c_check_header_compile "$LINENO" "usersec.h" "ac_cv_header_usersec_h" "$ac_includes_default" 11285if test "x$ac_cv_header_usersec_h" = xyes 11286then : 11287 printf "%s\n" "#define HAVE_USERSEC_H 1" >>confdefs.h 11288 11289fi 11290ac_fn_c_check_header_compile "$LINENO" "util.h" "ac_cv_header_util_h" "$ac_includes_default" 11291if test "x$ac_cv_header_util_h" = xyes 11292then : 11293 printf "%s\n" "#define HAVE_UTIL_H 1" >>confdefs.h 11294 11295fi 11296ac_fn_c_check_header_compile "$LINENO" "utime.h" "ac_cv_header_utime_h" "$ac_includes_default" 11297if test "x$ac_cv_header_utime_h" = xyes 11298then : 11299 printf "%s\n" "#define HAVE_UTIME_H 1" >>confdefs.h 11300 11301fi 11302ac_fn_c_check_header_compile "$LINENO" "utmp.h" "ac_cv_header_utmp_h" "$ac_includes_default" 11303if test "x$ac_cv_header_utmp_h" = xyes 11304then : 11305 printf "%s\n" "#define HAVE_UTMP_H 1" >>confdefs.h 11306 11307fi 11308ac_fn_c_check_header_compile "$LINENO" "utmpx.h" "ac_cv_header_utmpx_h" "$ac_includes_default" 11309if test "x$ac_cv_header_utmpx_h" = xyes 11310then : 11311 printf "%s\n" "#define HAVE_UTMPX_H 1" >>confdefs.h 11312 11313fi 11314ac_fn_c_check_header_compile "$LINENO" "vis.h" "ac_cv_header_vis_h" "$ac_includes_default" 11315if test "x$ac_cv_header_vis_h" = xyes 11316then : 11317 printf "%s\n" "#define HAVE_VIS_H 1" >>confdefs.h 11318 11319fi 11320ac_fn_c_check_header_compile "$LINENO" "wchar.h" "ac_cv_header_wchar_h" "$ac_includes_default" 11321if test "x$ac_cv_header_wchar_h" = xyes 11322then : 11323 printf "%s\n" "#define HAVE_WCHAR_H 1" >>confdefs.h 11324 11325fi 11326 11327 11328# On some platforms (eg SunOS4) sys/audit.h requires sys/[time|types|label.h] 11329# to be included first. 11330ac_fn_c_check_header_compile "$LINENO" "sys/audit.h" "ac_cv_header_sys_audit_h" " 11331#ifdef HAVE_SYS_TIME_H 11332# include <sys/time.h> 11333#endif 11334#ifdef HAVE_SYS_TYPES_H 11335# include <sys/types.h> 11336#endif 11337#ifdef HAVE_SYS_LABEL_H 11338# include <sys/label.h> 11339#endif 11340 11341" 11342if test "x$ac_cv_header_sys_audit_h" = xyes 11343then : 11344 printf "%s\n" "#define HAVE_SYS_AUDIT_H 1" >>confdefs.h 11345 11346fi 11347 11348 11349# sys/capsicum.h requires sys/types.h 11350ac_fn_c_check_header_compile "$LINENO" "sys/capsicum.h" "ac_cv_header_sys_capsicum_h" " 11351#ifdef HAVE_SYS_TYPES_H 11352# include <sys/types.h> 11353#endif 11354 11355" 11356if test "x$ac_cv_header_sys_capsicum_h" = xyes 11357then : 11358 printf "%s\n" "#define HAVE_SYS_CAPSICUM_H 1" >>confdefs.h 11359 11360fi 11361ac_fn_c_check_header_compile "$LINENO" "capsicum_helpers.h" "ac_cv_header_capsicum_helpers_h" " 11362#ifdef HAVE_SYS_TYPES_H 11363# include <sys/types.h> 11364#endif 11365 11366" 11367if test "x$ac_cv_header_capsicum_helpers_h" = xyes 11368then : 11369 printf "%s\n" "#define HAVE_CAPSICUM_HELPERS_H 1" >>confdefs.h 11370 11371fi 11372 11373 11374{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for caph_cache_tzdata" >&5 11375printf %s "checking for caph_cache_tzdata... " >&6; } 11376cat confdefs.h - <<_ACEOF >conftest.$ac_ext 11377/* end confdefs.h. */ 11378 #include <capsicum_helpers.h> 11379int 11380main (void) 11381{ 11382caph_cache_tzdata(); 11383 ; 11384 return 0; 11385} 11386_ACEOF 11387if ac_fn_c_try_link "$LINENO" 11388then : 11389 11390 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 11391printf "%s\n" "yes" >&6; } 11392 11393printf "%s\n" "#define HAVE_CAPH_CACHE_TZDATA 1" >>confdefs.h 11394 11395 11396else $as_nop 11397 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 11398printf "%s\n" "no" >&6; } 11399 11400fi 11401rm -f core conftest.err conftest.$ac_objext conftest.beam \ 11402 conftest$ac_exeext conftest.$ac_ext 11403 11404# net/route.h requires sys/socket.h and sys/types.h. 11405# sys/sysctl.h also requires sys/param.h 11406ac_fn_c_check_header_compile "$LINENO" "net/route.h" "ac_cv_header_net_route_h" " 11407#ifdef HAVE_SYS_TYPES_H 11408# include <sys/types.h> 11409#endif 11410#include <sys/param.h> 11411#include <sys/socket.h> 11412 11413" 11414if test "x$ac_cv_header_net_route_h" = xyes 11415then : 11416 printf "%s\n" "#define HAVE_NET_ROUTE_H 1" >>confdefs.h 11417 11418fi 11419ac_fn_c_check_header_compile "$LINENO" "sys/sysctl.h" "ac_cv_header_sys_sysctl_h" " 11420#ifdef HAVE_SYS_TYPES_H 11421# include <sys/types.h> 11422#endif 11423#include <sys/param.h> 11424#include <sys/socket.h> 11425 11426" 11427if test "x$ac_cv_header_sys_sysctl_h" = xyes 11428then : 11429 printf "%s\n" "#define HAVE_SYS_SYSCTL_H 1" >>confdefs.h 11430 11431fi 11432 11433 11434# lastlog.h requires sys/time.h to be included first on Solaris 11435ac_fn_c_check_header_compile "$LINENO" "lastlog.h" "ac_cv_header_lastlog_h" " 11436#ifdef HAVE_SYS_TIME_H 11437# include <sys/time.h> 11438#endif 11439 11440" 11441if test "x$ac_cv_header_lastlog_h" = xyes 11442then : 11443 printf "%s\n" "#define HAVE_LASTLOG_H 1" >>confdefs.h 11444 11445fi 11446 11447 11448# sys/ptms.h requires sys/stream.h to be included first on Solaris 11449ac_fn_c_check_header_compile "$LINENO" "sys/ptms.h" "ac_cv_header_sys_ptms_h" " 11450#ifdef HAVE_SYS_STREAM_H 11451# include <sys/stream.h> 11452#endif 11453 11454" 11455if test "x$ac_cv_header_sys_ptms_h" = xyes 11456then : 11457 printf "%s\n" "#define HAVE_SYS_PTMS_H 1" >>confdefs.h 11458 11459fi 11460 11461 11462# login_cap.h requires sys/types.h on NetBSD 11463ac_fn_c_check_header_compile "$LINENO" "login_cap.h" "ac_cv_header_login_cap_h" " 11464#include <sys/types.h> 11465 11466" 11467if test "x$ac_cv_header_login_cap_h" = xyes 11468then : 11469 printf "%s\n" "#define HAVE_LOGIN_CAP_H 1" >>confdefs.h 11470 11471fi 11472 11473 11474# older BSDs need sys/param.h before sys/mount.h 11475ac_fn_c_check_header_compile "$LINENO" "sys/mount.h" "ac_cv_header_sys_mount_h" " 11476#include <sys/param.h> 11477 11478" 11479if test "x$ac_cv_header_sys_mount_h" = xyes 11480then : 11481 printf "%s\n" "#define HAVE_SYS_MOUNT_H 1" >>confdefs.h 11482 11483fi 11484 11485 11486# Android requires sys/socket.h to be included before sys/un.h 11487ac_fn_c_check_header_compile "$LINENO" "sys/un.h" "ac_cv_header_sys_un_h" " 11488#include <sys/types.h> 11489#include <sys/socket.h> 11490 11491" 11492if test "x$ac_cv_header_sys_un_h" = xyes 11493then : 11494 printf "%s\n" "#define HAVE_SYS_UN_H 1" >>confdefs.h 11495 11496fi 11497 11498 11499# Messages for features tested for in target-specific section 11500SIA_MSG="no" 11501SPC_MSG="no" 11502SP_MSG="no" 11503SPP_MSG="no" 11504 11505# Support for Solaris/Illumos privileges (this test is used by both 11506# the --with-solaris-privs option and --with-sandbox=solaris). 11507SOLARIS_PRIVS="no" 11508 11509# Check for some target-specific stuff 11510case "$host" in 11511*-*-aix*) 11512 # Some versions of VAC won't allow macro redefinitions at 11513 # -qlanglevel=ansi, and autoconf 2.60 sometimes insists on using that 11514 # particularly with older versions of vac or xlc. 11515 # It also throws errors about null macro arguments, but these are 11516 # not fatal. 11517 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if compiler allows macro redefinitions" >&5 11518printf %s "checking if compiler allows macro redefinitions... " >&6; } 11519 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 11520/* end confdefs.h. */ 11521 11522#define testmacro foo 11523#define testmacro bar 11524int 11525main (void) 11526{ 11527 exit(0); 11528 ; 11529 return 0; 11530} 11531_ACEOF 11532if ac_fn_c_try_compile "$LINENO" 11533then : 11534 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 11535printf "%s\n" "yes" >&6; } 11536else $as_nop 11537 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 11538printf "%s\n" "no" >&6; } 11539 CC="`echo $CC | sed 's/-qlanglvl\=ansi//g'`" 11540 CFLAGS="`echo $CFLAGS | sed 's/-qlanglvl\=ansi//g'`" 11541 CPPFLAGS="`echo $CPPFLAGS | sed 's/-qlanglvl\=ansi//g'`" 11542 11543 11544fi 11545rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 11546 11547 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to specify blibpath for linker ($LD)" >&5 11548printf %s "checking how to specify blibpath for linker ($LD)... " >&6; } 11549 if (test -z "$blibpath"); then 11550 blibpath="/usr/lib:/lib" 11551 fi 11552 saved_LDFLAGS="$LDFLAGS" 11553 if test "$GCC" = "yes"; then 11554 flags="-Wl,-blibpath: -Wl,-rpath, -blibpath:" 11555 else 11556 flags="-blibpath: -Wl,-blibpath: -Wl,-rpath," 11557 fi 11558 for tryflags in $flags ;do 11559 if (test -z "$blibflags"); then 11560 LDFLAGS="$saved_LDFLAGS $tryflags$blibpath" 11561 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 11562/* end confdefs.h. */ 11563 11564int 11565main (void) 11566{ 11567 11568 ; 11569 return 0; 11570} 11571_ACEOF 11572if ac_fn_c_try_link "$LINENO" 11573then : 11574 blibflags=$tryflags 11575fi 11576rm -f core conftest.err conftest.$ac_objext conftest.beam \ 11577 conftest$ac_exeext conftest.$ac_ext 11578 fi 11579 done 11580 if (test -z "$blibflags"); then 11581 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11582printf "%s\n" "not found" >&6; } 11583 as_fn_error $? "*** must be able to specify blibpath on AIX - check config.log" "$LINENO" 5 11584 else 11585 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $blibflags" >&5 11586printf "%s\n" "$blibflags" >&6; } 11587 fi 11588 LDFLAGS="$saved_LDFLAGS" 11589 ac_fn_c_check_func "$LINENO" "authenticate" "ac_cv_func_authenticate" 11590if test "x$ac_cv_func_authenticate" = xyes 11591then : 11592 11593printf "%s\n" "#define WITH_AIXAUTHENTICATE 1" >>confdefs.h 11594 11595else $as_nop 11596 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for authenticate in -ls" >&5 11597printf %s "checking for authenticate in -ls... " >&6; } 11598if test ${ac_cv_lib_s_authenticate+y} 11599then : 11600 printf %s "(cached) " >&6 11601else $as_nop 11602 ac_check_lib_save_LIBS=$LIBS 11603LIBS="-ls $LIBS" 11604cat confdefs.h - <<_ACEOF >conftest.$ac_ext 11605/* end confdefs.h. */ 11606 11607/* Override any GCC internal prototype to avoid an error. 11608 Use char because int might match the return type of a GCC 11609 builtin and then its argument prototype would still apply. */ 11610char authenticate (); 11611int 11612main (void) 11613{ 11614return authenticate (); 11615 ; 11616 return 0; 11617} 11618_ACEOF 11619if ac_fn_c_try_link "$LINENO" 11620then : 11621 ac_cv_lib_s_authenticate=yes 11622else $as_nop 11623 ac_cv_lib_s_authenticate=no 11624fi 11625rm -f core conftest.err conftest.$ac_objext conftest.beam \ 11626 conftest$ac_exeext conftest.$ac_ext 11627LIBS=$ac_check_lib_save_LIBS 11628fi 11629{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_s_authenticate" >&5 11630printf "%s\n" "$ac_cv_lib_s_authenticate" >&6; } 11631if test "x$ac_cv_lib_s_authenticate" = xyes 11632then : 11633 printf "%s\n" "#define WITH_AIXAUTHENTICATE 1" >>confdefs.h 11634 11635 LIBS="$LIBS -ls" 11636 11637fi 11638 11639 11640fi 11641 11642 ac_fn_check_decl "$LINENO" "authenticate" "ac_cv_have_decl_authenticate" "#include <usersec.h> 11643" "$ac_c_undeclared_builtin_options" "CFLAGS" 11644if test "x$ac_cv_have_decl_authenticate" = xyes 11645then : 11646 ac_have_decl=1 11647else $as_nop 11648 ac_have_decl=0 11649fi 11650printf "%s\n" "#define HAVE_DECL_AUTHENTICATE $ac_have_decl" >>confdefs.h 11651ac_fn_check_decl "$LINENO" "loginrestrictions" "ac_cv_have_decl_loginrestrictions" "#include <usersec.h> 11652" "$ac_c_undeclared_builtin_options" "CFLAGS" 11653if test "x$ac_cv_have_decl_loginrestrictions" = xyes 11654then : 11655 ac_have_decl=1 11656else $as_nop 11657 ac_have_decl=0 11658fi 11659printf "%s\n" "#define HAVE_DECL_LOGINRESTRICTIONS $ac_have_decl" >>confdefs.h 11660ac_fn_check_decl "$LINENO" "loginsuccess" "ac_cv_have_decl_loginsuccess" "#include <usersec.h> 11661" "$ac_c_undeclared_builtin_options" "CFLAGS" 11662if test "x$ac_cv_have_decl_loginsuccess" = xyes 11663then : 11664 ac_have_decl=1 11665else $as_nop 11666 ac_have_decl=0 11667fi 11668printf "%s\n" "#define HAVE_DECL_LOGINSUCCESS $ac_have_decl" >>confdefs.h 11669ac_fn_check_decl "$LINENO" "passwdexpired" "ac_cv_have_decl_passwdexpired" "#include <usersec.h> 11670" "$ac_c_undeclared_builtin_options" "CFLAGS" 11671if test "x$ac_cv_have_decl_passwdexpired" = xyes 11672then : 11673 ac_have_decl=1 11674else $as_nop 11675 ac_have_decl=0 11676fi 11677printf "%s\n" "#define HAVE_DECL_PASSWDEXPIRED $ac_have_decl" >>confdefs.h 11678ac_fn_check_decl "$LINENO" "setauthdb" "ac_cv_have_decl_setauthdb" "#include <usersec.h> 11679" "$ac_c_undeclared_builtin_options" "CFLAGS" 11680if test "x$ac_cv_have_decl_setauthdb" = xyes 11681then : 11682 ac_have_decl=1 11683else $as_nop 11684 ac_have_decl=0 11685fi 11686printf "%s\n" "#define HAVE_DECL_SETAUTHDB $ac_have_decl" >>confdefs.h 11687 11688 ac_fn_check_decl "$LINENO" "loginfailed" "ac_cv_have_decl_loginfailed" "#include <usersec.h> 11689 11690" "$ac_c_undeclared_builtin_options" "CFLAGS" 11691if test "x$ac_cv_have_decl_loginfailed" = xyes 11692then : 11693 ac_have_decl=1 11694else $as_nop 11695 ac_have_decl=0 11696fi 11697printf "%s\n" "#define HAVE_DECL_LOGINFAILED $ac_have_decl" >>confdefs.h 11698if test $ac_have_decl = 1 11699then : 11700 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if loginfailed takes 4 arguments" >&5 11701printf %s "checking if loginfailed takes 4 arguments... " >&6; } 11702 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 11703/* end confdefs.h. */ 11704 #include <usersec.h> 11705int 11706main (void) 11707{ 11708 (void)loginfailed("user","host","tty",0); 11709 ; 11710 return 0; 11711} 11712_ACEOF 11713if ac_fn_c_try_compile "$LINENO" 11714then : 11715 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 11716printf "%s\n" "yes" >&6; } 11717 11718printf "%s\n" "#define AIX_LOGINFAILED_4ARG 1" >>confdefs.h 11719 11720else $as_nop 11721 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 11722printf "%s\n" "no" >&6; } 11723 11724fi 11725rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 11726fi 11727 11728 ac_fn_c_check_func "$LINENO" "getgrset" "ac_cv_func_getgrset" 11729if test "x$ac_cv_func_getgrset" = xyes 11730then : 11731 printf "%s\n" "#define HAVE_GETGRSET 1" >>confdefs.h 11732 11733fi 11734ac_fn_c_check_func "$LINENO" "setauthdb" "ac_cv_func_setauthdb" 11735if test "x$ac_cv_func_setauthdb" = xyes 11736then : 11737 printf "%s\n" "#define HAVE_SETAUTHDB 1" >>confdefs.h 11738 11739fi 11740 11741 ac_fn_check_decl "$LINENO" "F_CLOSEM" "ac_cv_have_decl_F_CLOSEM" " #include <limits.h> 11742 #include <fcntl.h> 11743 11744" "$ac_c_undeclared_builtin_options" "CFLAGS" 11745if test "x$ac_cv_have_decl_F_CLOSEM" = xyes 11746then : 11747 11748printf "%s\n" "#define HAVE_FCNTL_CLOSEM 1" >>confdefs.h 11749 11750fi 11751 check_for_aix_broken_getaddrinfo=1 11752 11753printf "%s\n" "#define SETEUID_BREAKS_SETUID 1" >>confdefs.h 11754 11755 11756printf "%s\n" "#define BROKEN_SETREUID 1" >>confdefs.h 11757 11758 11759printf "%s\n" "#define BROKEN_SETREGID 1" >>confdefs.h 11760 11761 11762printf "%s\n" "#define DISABLE_LASTLOG 1" >>confdefs.h 11763 11764 11765printf "%s\n" "#define LOGIN_NEEDS_UTMPX 1" >>confdefs.h 11766 11767 11768printf "%s\n" "#define SPT_TYPE SPT_REUSEARGV" >>confdefs.h 11769 11770 11771printf "%s\n" "#define SSHPAM_CHAUTHTOK_NEEDS_RUID 1" >>confdefs.h 11772 11773 11774printf "%s\n" "#define PTY_ZEROREAD 1" >>confdefs.h 11775 11776 11777printf "%s\n" "#define PLATFORM_SYS_DIR_UID 2" >>confdefs.h 11778 11779 11780printf "%s\n" "#define BROKEN_STRNDUP 1" >>confdefs.h 11781 11782 11783printf "%s\n" "#define BROKEN_STRNLEN 1" >>confdefs.h 11784 11785 ;; 11786*-*-android*) 11787 11788printf "%s\n" "#define DISABLE_UTMP 1" >>confdefs.h 11789 11790 11791printf "%s\n" "#define DISABLE_WTMP 1" >>confdefs.h 11792 11793 ;; 11794*-*-cygwin*) 11795 LIBS="$LIBS /usr/lib/textreadmode.o" 11796 11797printf "%s\n" "#define HAVE_CYGWIN 1" >>confdefs.h 11798 11799 11800printf "%s\n" "#define USE_PIPES 1" >>confdefs.h 11801 11802 11803printf "%s\n" "#define NO_UID_RESTORATION_TEST 1" >>confdefs.h 11804 11805 11806printf "%s\n" "#define DISABLE_SHADOW 1" >>confdefs.h 11807 11808 11809printf "%s\n" "#define NO_X11_UNIX_SOCKETS 1" >>confdefs.h 11810 11811 11812printf "%s\n" "#define DISABLE_FD_PASSING 1" >>confdefs.h 11813 11814 11815printf "%s\n" "#define SSH_IOBUFSZ 65535" >>confdefs.h 11816 11817 11818printf "%s\n" "#define FILESYSTEM_NO_BACKSLASH 1" >>confdefs.h 11819 11820 # Cygwin defines optargs, optargs as declspec(dllimport) for historical 11821 # reasons which cause compile warnings, so we disable those warnings. 11822 { 11823 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC supports compile flag -Wno-attributes" >&5 11824printf %s "checking if $CC supports compile flag -Wno-attributes... " >&6; } 11825 saved_CFLAGS="$CFLAGS" 11826 CFLAGS="$CFLAGS $WERROR -Wno-attributes" 11827 _define_flag="" 11828 test "x$_define_flag" = "x" && _define_flag="-Wno-attributes" 11829 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 11830/* end confdefs.h. */ 11831 11832#include <stdlib.h> 11833#include <stdarg.h> 11834#include <stdio.h> 11835#include <string.h> 11836#include <unistd.h> 11837/* Trivial function to help test for -fzero-call-used-regs */ 11838int f(int n) {return rand() % n;} 11839char *f2(char *s, ...) { 11840 char ret[64]; 11841 va_list args; 11842 va_start(args, s); 11843 vsnprintf(ret, sizeof(ret), s, args); 11844 va_end(args); 11845 return strdup(ret); 11846} 11847int i; 11848double d; 11849const char *f3(int s) { 11850 i = (int)d; 11851 return s ? "good" : "gooder"; 11852} 11853int main(int argc, char **argv) { 11854 char b[256], *cp; 11855 const char *s; 11856 /* Some math to catch -ftrapv problems in the toolchain */ 11857 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 11858 float l = i * 2.1; 11859 double m = l / 0.5; 11860 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 11861 (void)argv; 11862 f(1); 11863 s = f3(f(2)); 11864 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 11865 if (write(1, b, 0) == -1) exit(0); 11866 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 11867 if (write(1, cp, 0) == -1) exit(0); 11868 free(cp); 11869 /* 11870 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 11871 * not understand comments and we don't use the "fallthrough" attribute 11872 * that it's looking for. 11873 */ 11874 switch(i){ 11875 case 0: j += i; 11876 /* FALLTHROUGH */ 11877 default: j += k; 11878 } 11879 exit(0); 11880} 11881 11882 11883_ACEOF 11884if ac_fn_c_try_compile "$LINENO" 11885then : 11886 11887if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 11888then 11889 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 11890printf "%s\n" "no" >&6; } 11891 CFLAGS="$saved_CFLAGS" 11892else 11893 if test "$cross_compiling" = yes 11894then : 11895 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 11896printf "%s\n" "yes" >&6; } 11897 CFLAGS="$saved_CFLAGS $_define_flag" 11898else $as_nop 11899 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 11900/* end confdefs.h. */ 11901 11902#include <stdlib.h> 11903#include <stdarg.h> 11904#include <stdio.h> 11905#include <string.h> 11906#include <unistd.h> 11907/* Trivial function to help test for -fzero-call-used-regs */ 11908int f(int n) {return rand() % n;} 11909char *f2(char *s, ...) { 11910 char ret[64]; 11911 va_list args; 11912 va_start(args, s); 11913 vsnprintf(ret, sizeof(ret), s, args); 11914 va_end(args); 11915 return strdup(ret); 11916} 11917int i; 11918double d; 11919const char *f3(int s) { 11920 i = (int)d; 11921 return s ? "good" : "gooder"; 11922} 11923int main(int argc, char **argv) { 11924 char b[256], *cp; 11925 const char *s; 11926 /* Some math to catch -ftrapv problems in the toolchain */ 11927 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 11928 float l = i * 2.1; 11929 double m = l / 0.5; 11930 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 11931 (void)argv; 11932 f(1); 11933 s = f3(f(2)); 11934 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 11935 if (write(1, b, 0) == -1) exit(0); 11936 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 11937 if (write(1, cp, 0) == -1) exit(0); 11938 free(cp); 11939 /* 11940 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 11941 * not understand comments and we don't use the "fallthrough" attribute 11942 * that it's looking for. 11943 */ 11944 switch(i){ 11945 case 0: j += i; 11946 /* FALLTHROUGH */ 11947 default: j += k; 11948 } 11949 exit(0); 11950} 11951 11952 11953_ACEOF 11954if ac_fn_c_try_run "$LINENO" 11955then : 11956 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 11957printf "%s\n" "yes" >&6; } 11958 CFLAGS="$saved_CFLAGS $_define_flag" 11959else $as_nop 11960 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 11961printf "%s\n" "no, fails at run time" >&6; } 11962 CFLAGS="$saved_CFLAGS" 11963fi 11964rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 11965 conftest.$ac_objext conftest.beam conftest.$ac_ext 11966fi 11967 11968fi 11969else $as_nop 11970 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 11971printf "%s\n" "no" >&6; } 11972 CFLAGS="$saved_CFLAGS" 11973 11974fi 11975rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 11976} 11977 ;; 11978*-*-dgux*) 11979 11980printf "%s\n" "#define IP_TOS_IS_BROKEN 1" >>confdefs.h 11981 11982 printf "%s\n" "#define SETEUID_BREAKS_SETUID 1" >>confdefs.h 11983 11984 printf "%s\n" "#define BROKEN_SETREUID 1" >>confdefs.h 11985 11986 printf "%s\n" "#define BROKEN_SETREGID 1" >>confdefs.h 11987 11988 ;; 11989*-*-darwin*) 11990 use_pie=auto 11991 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if we have working getaddrinfo" >&5 11992printf %s "checking if we have working getaddrinfo... " >&6; } 11993 if test "$cross_compiling" = yes 11994then : 11995 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: assume it is working" >&5 11996printf "%s\n" "assume it is working" >&6; } 11997else $as_nop 11998 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 11999/* end confdefs.h. */ 12000 12001#include <mach-o/dyld.h> 12002#include <stdlib.h> 12003int main(void) { if (NSVersionOfRunTimeLibrary("System") >= (60 << 16)) 12004 exit(0); 12005 else 12006 exit(1); 12007} 12008 12009_ACEOF 12010if ac_fn_c_try_run "$LINENO" 12011then : 12012 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: working" >&5 12013printf "%s\n" "working" >&6; } 12014else $as_nop 12015 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: buggy" >&5 12016printf "%s\n" "buggy" >&6; } 12017 12018printf "%s\n" "#define BROKEN_GETADDRINFO 1" >>confdefs.h 12019 12020 12021fi 12022rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 12023 conftest.$ac_objext conftest.beam conftest.$ac_ext 12024fi 12025 12026 printf "%s\n" "#define SETEUID_BREAKS_SETUID 1" >>confdefs.h 12027 12028 printf "%s\n" "#define BROKEN_SETREUID 1" >>confdefs.h 12029 12030 printf "%s\n" "#define BROKEN_SETREGID 1" >>confdefs.h 12031 12032 12033printf "%s\n" "#define BROKEN_GLOB 1" >>confdefs.h 12034 12035 12036printf "%s\n" "#define BIND_8_COMPAT 1" >>confdefs.h 12037 12038 12039printf "%s\n" "#define SSH_TUN_FREEBSD 1" >>confdefs.h 12040 12041 12042printf "%s\n" "#define SSH_TUN_COMPAT_AF 1" >>confdefs.h 12043 12044 12045printf "%s\n" "#define SSH_TUN_PREPEND_AF 1" >>confdefs.h 12046 12047 12048 ac_fn_check_decl "$LINENO" "AU_IPv4" "ac_cv_have_decl_AU_IPv4" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS" 12049if test "x$ac_cv_have_decl_AU_IPv4" = xyes 12050then : 12051 12052else $as_nop 12053 12054printf "%s\n" "#define AU_IPv4 0" >>confdefs.h 12055 12056 #include <bsm/audit.h> 12057 12058printf "%s\n" "#define LASTLOG_WRITE_PUTUTXLINE 1" >>confdefs.h 12059 12060 12061fi 12062 12063printf "%s\n" "#define SPT_TYPE SPT_REUSEARGV" >>confdefs.h 12064 12065 ac_fn_c_check_func "$LINENO" "sandbox_init" "ac_cv_func_sandbox_init" 12066if test "x$ac_cv_func_sandbox_init" = xyes 12067then : 12068 printf "%s\n" "#define HAVE_SANDBOX_INIT 1" >>confdefs.h 12069 12070fi 12071 12072 ac_fn_c_check_header_compile "$LINENO" "sandbox.h" "ac_cv_header_sandbox_h" "$ac_includes_default" 12073if test "x$ac_cv_header_sandbox_h" = xyes 12074then : 12075 printf "%s\n" "#define HAVE_SANDBOX_H 1" >>confdefs.h 12076 12077fi 12078 12079 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sandbox_apply in -lsandbox" >&5 12080printf %s "checking for sandbox_apply in -lsandbox... " >&6; } 12081if test ${ac_cv_lib_sandbox_sandbox_apply+y} 12082then : 12083 printf %s "(cached) " >&6 12084else $as_nop 12085 ac_check_lib_save_LIBS=$LIBS 12086LIBS="-lsandbox $LIBS" 12087cat confdefs.h - <<_ACEOF >conftest.$ac_ext 12088/* end confdefs.h. */ 12089 12090/* Override any GCC internal prototype to avoid an error. 12091 Use char because int might match the return type of a GCC 12092 builtin and then its argument prototype would still apply. */ 12093char sandbox_apply (); 12094int 12095main (void) 12096{ 12097return sandbox_apply (); 12098 ; 12099 return 0; 12100} 12101_ACEOF 12102if ac_fn_c_try_link "$LINENO" 12103then : 12104 ac_cv_lib_sandbox_sandbox_apply=yes 12105else $as_nop 12106 ac_cv_lib_sandbox_sandbox_apply=no 12107fi 12108rm -f core conftest.err conftest.$ac_objext conftest.beam \ 12109 conftest$ac_exeext conftest.$ac_ext 12110LIBS=$ac_check_lib_save_LIBS 12111fi 12112{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_sandbox_sandbox_apply" >&5 12113printf "%s\n" "$ac_cv_lib_sandbox_sandbox_apply" >&6; } 12114if test "x$ac_cv_lib_sandbox_sandbox_apply" = xyes 12115then : 12116 12117 SSHDLIBS="$SSHDLIBS -lsandbox" 12118 12119fi 12120 12121 # proc_pidinfo()-based closefrom() replacement. 12122 ac_fn_c_check_header_compile "$LINENO" "libproc.h" "ac_cv_header_libproc_h" "$ac_includes_default" 12123if test "x$ac_cv_header_libproc_h" = xyes 12124then : 12125 printf "%s\n" "#define HAVE_LIBPROC_H 1" >>confdefs.h 12126 12127fi 12128 12129 ac_fn_c_check_func "$LINENO" "proc_pidinfo" "ac_cv_func_proc_pidinfo" 12130if test "x$ac_cv_func_proc_pidinfo" = xyes 12131then : 12132 printf "%s\n" "#define HAVE_PROC_PIDINFO 1" >>confdefs.h 12133 12134fi 12135 12136 # poll(2) is broken for character-special devices (at least). 12137 # cf. Apple bug 3710161 (not public, but searchable) 12138 12139printf "%s\n" "#define BROKEN_POLL 1" >>confdefs.h 12140 12141 ;; 12142*-*-dragonfly*) 12143 SSHDLIBS="$SSHDLIBS" 12144 TEST_MALLOC_OPTIONS="AFGJPRX" 12145 ;; 12146*-*-haiku*) 12147 LIBS="$LIBS -lbsd " 12148 CFLAGS="$CFLAGS -D_BSD_SOURCE" 12149 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for socket in -lnetwork" >&5 12150printf %s "checking for socket in -lnetwork... " >&6; } 12151if test ${ac_cv_lib_network_socket+y} 12152then : 12153 printf %s "(cached) " >&6 12154else $as_nop 12155 ac_check_lib_save_LIBS=$LIBS 12156LIBS="-lnetwork $LIBS" 12157cat confdefs.h - <<_ACEOF >conftest.$ac_ext 12158/* end confdefs.h. */ 12159 12160/* Override any GCC internal prototype to avoid an error. 12161 Use char because int might match the return type of a GCC 12162 builtin and then its argument prototype would still apply. */ 12163char socket (); 12164int 12165main (void) 12166{ 12167return socket (); 12168 ; 12169 return 0; 12170} 12171_ACEOF 12172if ac_fn_c_try_link "$LINENO" 12173then : 12174 ac_cv_lib_network_socket=yes 12175else $as_nop 12176 ac_cv_lib_network_socket=no 12177fi 12178rm -f core conftest.err conftest.$ac_objext conftest.beam \ 12179 conftest$ac_exeext conftest.$ac_ext 12180LIBS=$ac_check_lib_save_LIBS 12181fi 12182{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_network_socket" >&5 12183printf "%s\n" "$ac_cv_lib_network_socket" >&6; } 12184if test "x$ac_cv_lib_network_socket" = xyes 12185then : 12186 printf "%s\n" "#define HAVE_LIBNETWORK 1" >>confdefs.h 12187 12188 LIBS="-lnetwork $LIBS" 12189 12190fi 12191 12192 printf "%s\n" "#define HAVE_U_INT64_T 1" >>confdefs.h 12193 12194 12195printf "%s\n" "#define DISABLE_UTMPX 1" >>confdefs.h 12196 12197 MANTYPE=man 12198 ;; 12199*-*-hpux*) 12200 # first we define all of the options common to all HP-UX releases 12201 CPPFLAGS="$CPPFLAGS -D_HPUX_SOURCE -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED=1" 12202 IPADDR_IN_DISPLAY=yes 12203 printf "%s\n" "#define USE_PIPES 1" >>confdefs.h 12204 12205 printf "%s\n" "#define LOGIN_NEEDS_UTMPX 1" >>confdefs.h 12206 12207 12208printf "%s\n" "#define LOCKED_PASSWD_STRING \"*\"" >>confdefs.h 12209 12210 printf "%s\n" "#define SPT_TYPE SPT_PSTAT" >>confdefs.h 12211 12212 12213printf "%s\n" "#define PLATFORM_SYS_DIR_UID 2" >>confdefs.h 12214 12215 maildir="/var/mail" 12216 LIBS="$LIBS -lsec" 12217 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for t_error in -lxnet" >&5 12218printf %s "checking for t_error in -lxnet... " >&6; } 12219if test ${ac_cv_lib_xnet_t_error+y} 12220then : 12221 printf %s "(cached) " >&6 12222else $as_nop 12223 ac_check_lib_save_LIBS=$LIBS 12224LIBS="-lxnet $LIBS" 12225cat confdefs.h - <<_ACEOF >conftest.$ac_ext 12226/* end confdefs.h. */ 12227 12228/* Override any GCC internal prototype to avoid an error. 12229 Use char because int might match the return type of a GCC 12230 builtin and then its argument prototype would still apply. */ 12231char t_error (); 12232int 12233main (void) 12234{ 12235return t_error (); 12236 ; 12237 return 0; 12238} 12239_ACEOF 12240if ac_fn_c_try_link "$LINENO" 12241then : 12242 ac_cv_lib_xnet_t_error=yes 12243else $as_nop 12244 ac_cv_lib_xnet_t_error=no 12245fi 12246rm -f core conftest.err conftest.$ac_objext conftest.beam \ 12247 conftest$ac_exeext conftest.$ac_ext 12248LIBS=$ac_check_lib_save_LIBS 12249fi 12250{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xnet_t_error" >&5 12251printf "%s\n" "$ac_cv_lib_xnet_t_error" >&6; } 12252if test "x$ac_cv_lib_xnet_t_error" = xyes 12253then : 12254 printf "%s\n" "#define HAVE_LIBXNET 1" >>confdefs.h 12255 12256 LIBS="-lxnet $LIBS" 12257 12258else $as_nop 12259 as_fn_error $? "*** -lxnet needed on HP-UX - check config.log ***" "$LINENO" 5 12260fi 12261 12262 12263 # next, we define all of the options specific to major releases 12264 case "$host" in 12265 *-*-hpux10*) 12266 if test -z "$GCC"; then 12267 CFLAGS="$CFLAGS -Ae" 12268 fi 12269 12270printf "%s\n" "#define BROKEN_GETLINE 1" >>confdefs.h 12271 12272 ;; 12273 *-*-hpux11*) 12274 12275printf "%s\n" "#define PAM_SUN_CODEBASE 1" >>confdefs.h 12276 12277 12278printf "%s\n" "#define DISABLE_UTMP 1" >>confdefs.h 12279 12280 12281printf "%s\n" "#define USE_BTMP 1" >>confdefs.h 12282 12283 check_for_hpux_broken_getaddrinfo=1 12284 check_for_conflicting_getspnam=1 12285 ;; 12286 esac 12287 12288 # lastly, we define options specific to minor releases 12289 case "$host" in 12290 *-*-hpux10.26) 12291 12292printf "%s\n" "#define HAVE_SECUREWARE 1" >>confdefs.h 12293 12294 disable_ptmx_check=yes 12295 LIBS="$LIBS -lsecpw" 12296 ;; 12297 esac 12298 ;; 12299*-*-irix5*) 12300 PATH="$PATH:/usr/etc" 12301 12302printf "%s\n" "#define BROKEN_INET_NTOA 1" >>confdefs.h 12303 12304 printf "%s\n" "#define SETEUID_BREAKS_SETUID 1" >>confdefs.h 12305 12306 printf "%s\n" "#define BROKEN_SETREUID 1" >>confdefs.h 12307 12308 printf "%s\n" "#define BROKEN_SETREGID 1" >>confdefs.h 12309 12310 12311printf "%s\n" "#define WITH_ABBREV_NO_TTY 1" >>confdefs.h 12312 12313 printf "%s\n" "#define LOCKED_PASSWD_STRING \"*LK*\"" >>confdefs.h 12314 12315 ;; 12316*-*-irix6*) 12317 PATH="$PATH:/usr/etc" 12318 12319printf "%s\n" "#define WITH_IRIX_ARRAY 1" >>confdefs.h 12320 12321 12322printf "%s\n" "#define WITH_IRIX_PROJECT 1" >>confdefs.h 12323 12324 12325printf "%s\n" "#define WITH_IRIX_AUDIT 1" >>confdefs.h 12326 12327 ac_fn_c_check_func "$LINENO" "jlimit_startjob" "ac_cv_func_jlimit_startjob" 12328if test "x$ac_cv_func_jlimit_startjob" = xyes 12329then : 12330 12331printf "%s\n" "#define WITH_IRIX_JOBS 1" >>confdefs.h 12332 12333fi 12334 12335 printf "%s\n" "#define BROKEN_INET_NTOA 1" >>confdefs.h 12336 12337 printf "%s\n" "#define SETEUID_BREAKS_SETUID 1" >>confdefs.h 12338 12339 printf "%s\n" "#define BROKEN_SETREUID 1" >>confdefs.h 12340 12341 printf "%s\n" "#define BROKEN_SETREGID 1" >>confdefs.h 12342 12343 12344printf "%s\n" "#define BROKEN_UPDWTMPX 1" >>confdefs.h 12345 12346 printf "%s\n" "#define WITH_ABBREV_NO_TTY 1" >>confdefs.h 12347 12348 printf "%s\n" "#define LOCKED_PASSWD_STRING \"*LK*\"" >>confdefs.h 12349 12350 ;; 12351*-*-k*bsd*-gnu | *-*-kopensolaris*-gnu) 12352 printf "%s\n" "#define PAM_TTY_KLUDGE 1" >>confdefs.h 12353 12354 printf "%s\n" "#define LOCKED_PASSWD_PREFIX \"!\"" >>confdefs.h 12355 12356 printf "%s\n" "#define SPT_TYPE SPT_REUSEARGV" >>confdefs.h 12357 12358 12359printf "%s\n" "#define _PATH_BTMP \"/var/log/btmp\"" >>confdefs.h 12360 12361 12362printf "%s\n" "#define USE_BTMP 1" >>confdefs.h 12363 12364 ;; 12365*-*-linux*) 12366 no_dev_ptmx=1 12367 use_pie=auto 12368 check_for_openpty_ctty_bug=1 12369 CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=600 -D_BSD_SOURCE -D_DEFAULT_SOURCE -D_GNU_SOURCE" 12370 12371printf "%s\n" "#define BROKEN_CLOSEFROM 1" >>confdefs.h 12372 12373 12374printf "%s\n" "#define PAM_TTY_KLUDGE 1" >>confdefs.h 12375 12376 12377printf "%s\n" "#define LOCKED_PASSWD_PREFIX \"!\"" >>confdefs.h 12378 12379 printf "%s\n" "#define SPT_TYPE SPT_REUSEARGV" >>confdefs.h 12380 12381 12382printf "%s\n" "#define LINK_OPNOTSUPP_ERRNO EPERM" >>confdefs.h 12383 12384 12385printf "%s\n" "#define _PATH_BTMP \"/var/log/btmp\"" >>confdefs.h 12386 12387 printf "%s\n" "#define USE_BTMP 1" >>confdefs.h 12388 12389 12390printf "%s\n" "#define LINUX_OOM_ADJUST 1" >>confdefs.h 12391 12392 12393printf "%s\n" "#define SYSTEMD_NOTIFY 1" >>confdefs.h 12394 12395 inet6_default_4in6=yes 12396 case `uname -r` in 12397 1.*|2.0.*) 12398 12399printf "%s\n" "#define BROKEN_CMSG_TYPE 1" >>confdefs.h 12400 12401 ;; 12402 esac 12403 # tun(4) forwarding compat code 12404 ac_fn_c_check_header_compile "$LINENO" "linux/if_tun.h" "ac_cv_header_linux_if_tun_h" "$ac_includes_default" 12405if test "x$ac_cv_header_linux_if_tun_h" = xyes 12406then : 12407 printf "%s\n" "#define HAVE_LINUX_IF_TUN_H 1" >>confdefs.h 12408 12409fi 12410 12411 if test "x$ac_cv_header_linux_if_tun_h" = "xyes" ; then 12412 12413printf "%s\n" "#define SSH_TUN_LINUX 1" >>confdefs.h 12414 12415 12416printf "%s\n" "#define SSH_TUN_COMPAT_AF 1" >>confdefs.h 12417 12418 12419printf "%s\n" "#define SSH_TUN_PREPEND_AF 1" >>confdefs.h 12420 12421 fi 12422 ac_fn_c_check_header_compile "$LINENO" "linux/if.h" "ac_cv_header_linux_if_h" " 12423#ifdef HAVE_SYS_TYPES_H 12424# include <sys/types.h> 12425#endif 12426 12427" 12428if test "x$ac_cv_header_linux_if_h" = xyes 12429then : 12430 12431printf "%s\n" "#define SYS_RDOMAIN_LINUX 1" >>confdefs.h 12432 12433fi 12434 12435 ac_fn_c_check_header_compile "$LINENO" "linux/seccomp.h" "ac_cv_header_linux_seccomp_h" "#include <linux/types.h> 12436" 12437if test "x$ac_cv_header_linux_seccomp_h" = xyes 12438then : 12439 printf "%s\n" "#define HAVE_LINUX_SECCOMP_H 1" >>confdefs.h 12440 12441fi 12442ac_fn_c_check_header_compile "$LINENO" "linux/filter.h" "ac_cv_header_linux_filter_h" "#include <linux/types.h> 12443" 12444if test "x$ac_cv_header_linux_filter_h" = xyes 12445then : 12446 printf "%s\n" "#define HAVE_LINUX_FILTER_H 1" >>confdefs.h 12447 12448fi 12449ac_fn_c_check_header_compile "$LINENO" "linux/audit.h" "ac_cv_header_linux_audit_h" "#include <linux/types.h> 12450" 12451if test "x$ac_cv_header_linux_audit_h" = xyes 12452then : 12453 printf "%s\n" "#define HAVE_LINUX_AUDIT_H 1" >>confdefs.h 12454 12455fi 12456 12457 # Obtain MIPS ABI 12458 case "$host" in 12459 mips*) 12460 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 12461/* end confdefs.h. */ 12462 12463#if _MIPS_SIM != _ABIO32 12464#error 12465#endif 12466 12467int 12468main (void) 12469{ 12470 12471 ; 12472 return 0; 12473} 12474_ACEOF 12475if ac_fn_c_try_compile "$LINENO" 12476then : 12477 mips_abi="o32" 12478else $as_nop 12479 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 12480/* end confdefs.h. */ 12481 12482#if _MIPS_SIM != _ABIN32 12483#error 12484#endif 12485 12486int 12487main (void) 12488{ 12489 12490 ; 12491 return 0; 12492} 12493_ACEOF 12494if ac_fn_c_try_compile "$LINENO" 12495then : 12496 mips_abi="n32" 12497else $as_nop 12498 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 12499/* end confdefs.h. */ 12500 12501#if _MIPS_SIM != _ABI64 12502#error 12503#endif 12504 12505int 12506main (void) 12507{ 12508 12509 ; 12510 return 0; 12511} 12512_ACEOF 12513if ac_fn_c_try_compile "$LINENO" 12514then : 12515 mips_abi="n64" 12516else $as_nop 12517 as_fn_error $? "unknown MIPS ABI" "$LINENO" 5 12518 12519fi 12520rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 12521 12522fi 12523rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 12524 12525fi 12526rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 12527 ;; 12528 esac 12529 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for seccomp architecture" >&5 12530printf %s "checking for seccomp architecture... " >&6; } 12531 seccomp_audit_arch= 12532 case "$host" in 12533 x86_64-*) 12534 seccomp_audit_arch=AUDIT_ARCH_X86_64 12535 ;; 12536 i*86-*) 12537 seccomp_audit_arch=AUDIT_ARCH_I386 12538 ;; 12539 arm*-*) 12540 seccomp_audit_arch=AUDIT_ARCH_ARM 12541 ;; 12542 aarch64*-*) 12543 seccomp_audit_arch=AUDIT_ARCH_AARCH64 12544 ;; 12545 s390x-*) 12546 seccomp_audit_arch=AUDIT_ARCH_S390X 12547 ;; 12548 s390-*) 12549 seccomp_audit_arch=AUDIT_ARCH_S390 12550 ;; 12551 powerpc-*) 12552 seccomp_audit_arch=AUDIT_ARCH_PPC 12553 ;; 12554 powerpc64-*) 12555 seccomp_audit_arch=AUDIT_ARCH_PPC64 12556 ;; 12557 powerpc64le-*) 12558 seccomp_audit_arch=AUDIT_ARCH_PPC64LE 12559 ;; 12560 mips-*) 12561 seccomp_audit_arch=AUDIT_ARCH_MIPS 12562 ;; 12563 mipsel-*) 12564 seccomp_audit_arch=AUDIT_ARCH_MIPSEL 12565 ;; 12566 mips64-*) 12567 case "$mips_abi" in 12568 "n32") 12569 seccomp_audit_arch=AUDIT_ARCH_MIPS64N32 12570 ;; 12571 "n64") 12572 seccomp_audit_arch=AUDIT_ARCH_MIPS64 12573 ;; 12574 esac 12575 ;; 12576 mips64el-*) 12577 case "$mips_abi" in 12578 "n32") 12579 seccomp_audit_arch=AUDIT_ARCH_MIPSEL64N32 12580 ;; 12581 "n64") 12582 seccomp_audit_arch=AUDIT_ARCH_MIPSEL64 12583 ;; 12584 esac 12585 ;; 12586 riscv64-*) 12587 seccomp_audit_arch=AUDIT_ARCH_RISCV64 12588 ;; 12589 esac 12590 if test "x$seccomp_audit_arch" != "x" ; then 12591 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: \"$seccomp_audit_arch\"" >&5 12592printf "%s\n" "\"$seccomp_audit_arch\"" >&6; } 12593 12594printf "%s\n" "#define SECCOMP_AUDIT_ARCH $seccomp_audit_arch" >>confdefs.h 12595 12596 else 12597 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: architecture not supported" >&5 12598printf "%s\n" "architecture not supported" >&6; } 12599 fi 12600 ;; 12601*-*-minix) 12602 printf "%s\n" "#define SETEUID_BREAKS_SETUID 1" >>confdefs.h 12603 12604 # poll(2) seems to choke on /dev/null; "Bad file descriptor" 12605 12606printf "%s\n" "#define BROKEN_POLL 1" >>confdefs.h 12607 12608 ;; 12609mips-sony-bsd|mips-sony-newsos4) 12610 12611printf "%s\n" "#define NEED_SETPGRP 1" >>confdefs.h 12612 12613 SONY=1 12614 ;; 12615*-*-netbsd*) 12616 if test "x$withval" != "xno" ; then 12617 rpath_opt="-R" 12618 fi 12619 CPPFLAGS="$CPPFLAGS -D_OPENBSD_SOURCE" 12620 12621printf "%s\n" "#define SSH_TUN_FREEBSD 1" >>confdefs.h 12622 12623 ac_fn_c_check_header_compile "$LINENO" "net/if_tap.h" "ac_cv_header_net_if_tap_h" "$ac_includes_default" 12624if test "x$ac_cv_header_net_if_tap_h" = xyes 12625then : 12626 12627else $as_nop 12628 12629printf "%s\n" "#define SSH_TUN_NO_L2 1" >>confdefs.h 12630 12631fi 12632 12633 12634printf "%s\n" "#define SSH_TUN_PREPEND_AF 1" >>confdefs.h 12635 12636 TEST_MALLOC_OPTIONS="AJRX" 12637 12638printf "%s\n" "#define BROKEN_READ_COMPARISON 1" >>confdefs.h 12639 12640 ;; 12641*-*-freebsd*) 12642 12643printf "%s\n" "#define LOCKED_PASSWD_PREFIX \"*LOCKED*\"" >>confdefs.h 12644 12645 12646printf "%s\n" "#define SSH_TUN_FREEBSD 1" >>confdefs.h 12647 12648 ac_fn_c_check_header_compile "$LINENO" "net/if_tap.h" "ac_cv_header_net_if_tap_h" "$ac_includes_default" 12649if test "x$ac_cv_header_net_if_tap_h" = xyes 12650then : 12651 12652else $as_nop 12653 12654printf "%s\n" "#define SSH_TUN_NO_L2 1" >>confdefs.h 12655 12656fi 12657 12658 12659printf "%s\n" "#define BROKEN_GLOB 1" >>confdefs.h 12660 12661 TEST_MALLOC_OPTIONS="AJRX" 12662 # Preauth crypto occasionally uses file descriptors for crypto offload 12663 # and will crash if they cannot be opened. 12664 12665printf "%s\n" "#define SANDBOX_SKIP_RLIMIT_NOFILE 1" >>confdefs.h 12666 12667 case "$host" in 12668 *-*-freebsd9.*|*-*-freebsd10.*) 12669 # Capsicum on 9 and 10 do not allow ppoll() so don't auto-enable. 12670 disable_capsicum=yes 12671 esac 12672 ;; 12673*-*-bsdi*) 12674 printf "%s\n" "#define SETEUID_BREAKS_SETUID 1" >>confdefs.h 12675 12676 printf "%s\n" "#define BROKEN_SETREUID 1" >>confdefs.h 12677 12678 printf "%s\n" "#define BROKEN_SETREGID 1" >>confdefs.h 12679 12680 ;; 12681*-next-*) 12682 conf_lastlog_location="/usr/adm/lastlog" 12683 conf_utmp_location=/etc/utmp 12684 conf_wtmp_location=/usr/adm/wtmp 12685 maildir=/usr/spool/mail 12686 12687printf "%s\n" "#define HAVE_NEXT 1" >>confdefs.h 12688 12689 printf "%s\n" "#define USE_PIPES 1" >>confdefs.h 12690 12691 12692printf "%s\n" "#define BROKEN_SAVED_UIDS 1" >>confdefs.h 12693 12694 ;; 12695*-*-openbsd*) 12696 use_pie=auto 12697 12698printf "%s\n" "#define HAVE_ATTRIBUTE__SENTINEL__ 1" >>confdefs.h 12699 12700 12701printf "%s\n" "#define HAVE_ATTRIBUTE__BOUNDED__ 1" >>confdefs.h 12702 12703 12704printf "%s\n" "#define SSH_TUN_OPENBSD 1" >>confdefs.h 12705 12706 12707printf "%s\n" "#define SYSLOG_R_SAFE_IN_SIGHAND 1" >>confdefs.h 12708 12709 TEST_MALLOC_OPTIONS="AFGJPRX" 12710 ;; 12711*-*-solaris*) 12712 if test "x$withval" != "xno" ; then 12713 rpath_opt="-R" 12714 fi 12715 printf "%s\n" "#define PAM_SUN_CODEBASE 1" >>confdefs.h 12716 12717 printf "%s\n" "#define LOGIN_NEEDS_UTMPX 1" >>confdefs.h 12718 12719 printf "%s\n" "#define PAM_TTY_KLUDGE 1" >>confdefs.h 12720 12721 12722printf "%s\n" "#define SSHPAM_CHAUTHTOK_NEEDS_RUID 1" >>confdefs.h 12723 12724 printf "%s\n" "#define LOCKED_PASSWD_STRING \"*LK*\"" >>confdefs.h 12725 12726 # Pushing STREAMS modules will cause sshd to acquire a controlling tty. 12727 12728printf "%s\n" "#define SSHD_ACQUIRES_CTTY 1" >>confdefs.h 12729 12730 12731printf "%s\n" "#define PASSWD_NEEDS_USERNAME 1" >>confdefs.h 12732 12733 12734printf "%s\n" "#define BROKEN_TCGETATTR_ICANON 1" >>confdefs.h 12735 12736 external_path_file=/etc/default/login 12737 # hardwire lastlog location (can't detect it on some versions) 12738 conf_lastlog_location="/var/adm/lastlog" 12739 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for obsolete utmp and wtmp in solaris2.x" >&5 12740printf %s "checking for obsolete utmp and wtmp in solaris2.x... " >&6; } 12741 sol2ver=`echo "$host"| sed -e 's/.*[0-9]\.//'` 12742 if test "$sol2ver" -ge 8; then 12743 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 12744printf "%s\n" "yes" >&6; } 12745 printf "%s\n" "#define DISABLE_UTMP 1" >>confdefs.h 12746 12747 12748printf "%s\n" "#define DISABLE_WTMP 1" >>confdefs.h 12749 12750 else 12751 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 12752printf "%s\n" "no" >&6; } 12753 fi 12754 ac_fn_c_check_func "$LINENO" "setpflags" "ac_cv_func_setpflags" 12755if test "x$ac_cv_func_setpflags" = xyes 12756then : 12757 printf "%s\n" "#define HAVE_SETPFLAGS 1" >>confdefs.h 12758 12759fi 12760 12761 ac_fn_c_check_func "$LINENO" "setppriv" "ac_cv_func_setppriv" 12762if test "x$ac_cv_func_setppriv" = xyes 12763then : 12764 printf "%s\n" "#define HAVE_SETPPRIV 1" >>confdefs.h 12765 12766fi 12767 12768 ac_fn_c_check_func "$LINENO" "priv_basicset" "ac_cv_func_priv_basicset" 12769if test "x$ac_cv_func_priv_basicset" = xyes 12770then : 12771 printf "%s\n" "#define HAVE_PRIV_BASICSET 1" >>confdefs.h 12772 12773fi 12774 12775 ac_fn_c_check_header_compile "$LINENO" "priv.h" "ac_cv_header_priv_h" "$ac_includes_default" 12776if test "x$ac_cv_header_priv_h" = xyes 12777then : 12778 printf "%s\n" "#define HAVE_PRIV_H 1" >>confdefs.h 12779 12780fi 12781 12782 12783# Check whether --with-solaris-contracts was given. 12784if test ${with_solaris_contracts+y} 12785then : 12786 withval=$with_solaris_contracts; 12787 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ct_tmpl_activate in -lcontract" >&5 12788printf %s "checking for ct_tmpl_activate in -lcontract... " >&6; } 12789if test ${ac_cv_lib_contract_ct_tmpl_activate+y} 12790then : 12791 printf %s "(cached) " >&6 12792else $as_nop 12793 ac_check_lib_save_LIBS=$LIBS 12794LIBS="-lcontract $LIBS" 12795cat confdefs.h - <<_ACEOF >conftest.$ac_ext 12796/* end confdefs.h. */ 12797 12798/* Override any GCC internal prototype to avoid an error. 12799 Use char because int might match the return type of a GCC 12800 builtin and then its argument prototype would still apply. */ 12801char ct_tmpl_activate (); 12802int 12803main (void) 12804{ 12805return ct_tmpl_activate (); 12806 ; 12807 return 0; 12808} 12809_ACEOF 12810if ac_fn_c_try_link "$LINENO" 12811then : 12812 ac_cv_lib_contract_ct_tmpl_activate=yes 12813else $as_nop 12814 ac_cv_lib_contract_ct_tmpl_activate=no 12815fi 12816rm -f core conftest.err conftest.$ac_objext conftest.beam \ 12817 conftest$ac_exeext conftest.$ac_ext 12818LIBS=$ac_check_lib_save_LIBS 12819fi 12820{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_contract_ct_tmpl_activate" >&5 12821printf "%s\n" "$ac_cv_lib_contract_ct_tmpl_activate" >&6; } 12822if test "x$ac_cv_lib_contract_ct_tmpl_activate" = xyes 12823then : 12824 12825printf "%s\n" "#define USE_SOLARIS_PROCESS_CONTRACTS 1" >>confdefs.h 12826 12827 LIBS="$LIBS -lcontract" 12828 SPC_MSG="yes" 12829fi 12830 12831 12832fi 12833 12834 12835# Check whether --with-solaris-projects was given. 12836if test ${with_solaris_projects+y} 12837then : 12838 withval=$with_solaris_projects; 12839 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for setproject in -lproject" >&5 12840printf %s "checking for setproject in -lproject... " >&6; } 12841if test ${ac_cv_lib_project_setproject+y} 12842then : 12843 printf %s "(cached) " >&6 12844else $as_nop 12845 ac_check_lib_save_LIBS=$LIBS 12846LIBS="-lproject $LIBS" 12847cat confdefs.h - <<_ACEOF >conftest.$ac_ext 12848/* end confdefs.h. */ 12849 12850/* Override any GCC internal prototype to avoid an error. 12851 Use char because int might match the return type of a GCC 12852 builtin and then its argument prototype would still apply. */ 12853char setproject (); 12854int 12855main (void) 12856{ 12857return setproject (); 12858 ; 12859 return 0; 12860} 12861_ACEOF 12862if ac_fn_c_try_link "$LINENO" 12863then : 12864 ac_cv_lib_project_setproject=yes 12865else $as_nop 12866 ac_cv_lib_project_setproject=no 12867fi 12868rm -f core conftest.err conftest.$ac_objext conftest.beam \ 12869 conftest$ac_exeext conftest.$ac_ext 12870LIBS=$ac_check_lib_save_LIBS 12871fi 12872{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_project_setproject" >&5 12873printf "%s\n" "$ac_cv_lib_project_setproject" >&6; } 12874if test "x$ac_cv_lib_project_setproject" = xyes 12875then : 12876 12877printf "%s\n" "#define USE_SOLARIS_PROJECTS 1" >>confdefs.h 12878 12879 LIBS="$LIBS -lproject" 12880 SP_MSG="yes" 12881fi 12882 12883 12884fi 12885 12886 12887# Check whether --with-solaris-privs was given. 12888if test ${with_solaris_privs+y} 12889then : 12890 withval=$with_solaris_privs; 12891 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for Solaris/Illumos privilege support" >&5 12892printf %s "checking for Solaris/Illumos privilege support... " >&6; } 12893 if test "x$ac_cv_func_setppriv" = "xyes" -a \ 12894 "x$ac_cv_header_priv_h" = "xyes" ; then 12895 SOLARIS_PRIVS=yes 12896 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: found" >&5 12897printf "%s\n" "found" >&6; } 12898 12899printf "%s\n" "#define NO_UID_RESTORATION_TEST 1" >>confdefs.h 12900 12901 12902printf "%s\n" "#define USE_SOLARIS_PRIVS 1" >>confdefs.h 12903 12904 SPP_MSG="yes" 12905 else 12906 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12907printf "%s\n" "not found" >&6; } 12908 as_fn_error $? "*** must have support for Solaris privileges to use --with-solaris-privs" "$LINENO" 5 12909 fi 12910 12911fi 12912 12913 TEST_SHELL=$SHELL # let configure find us a capable shell 12914 ;; 12915*-*-sunos4*) 12916 CPPFLAGS="$CPPFLAGS -DSUNOS4" 12917 ac_fn_c_check_func "$LINENO" "getpwanam" "ac_cv_func_getpwanam" 12918if test "x$ac_cv_func_getpwanam" = xyes 12919then : 12920 printf "%s\n" "#define HAVE_GETPWANAM 1" >>confdefs.h 12921 12922fi 12923 12924 printf "%s\n" "#define PAM_SUN_CODEBASE 1" >>confdefs.h 12925 12926 conf_utmp_location=/etc/utmp 12927 conf_wtmp_location=/var/adm/wtmp 12928 conf_lastlog_location=/var/adm/lastlog 12929 printf "%s\n" "#define USE_PIPES 1" >>confdefs.h 12930 12931 12932printf "%s\n" "#define DISABLE_UTMPX 1" >>confdefs.h 12933 12934 ;; 12935*-ncr-sysv*) 12936 LIBS="$LIBS -lc89" 12937 printf "%s\n" "#define USE_PIPES 1" >>confdefs.h 12938 12939 printf "%s\n" "#define SSHD_ACQUIRES_CTTY 1" >>confdefs.h 12940 12941 printf "%s\n" "#define SETEUID_BREAKS_SETUID 1" >>confdefs.h 12942 12943 printf "%s\n" "#define BROKEN_SETREUID 1" >>confdefs.h 12944 12945 printf "%s\n" "#define BROKEN_SETREGID 1" >>confdefs.h 12946 12947 ;; 12948*-sni-sysv*) 12949 # /usr/ucblib MUST NOT be searched on ReliantUNIX 12950 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dlsym in -ldl" >&5 12951printf %s "checking for dlsym in -ldl... " >&6; } 12952if test ${ac_cv_lib_dl_dlsym+y} 12953then : 12954 printf %s "(cached) " >&6 12955else $as_nop 12956 ac_check_lib_save_LIBS=$LIBS 12957LIBS="-ldl $LIBS" 12958cat confdefs.h - <<_ACEOF >conftest.$ac_ext 12959/* end confdefs.h. */ 12960 12961/* Override any GCC internal prototype to avoid an error. 12962 Use char because int might match the return type of a GCC 12963 builtin and then its argument prototype would still apply. */ 12964char dlsym (); 12965int 12966main (void) 12967{ 12968return dlsym (); 12969 ; 12970 return 0; 12971} 12972_ACEOF 12973if ac_fn_c_try_link "$LINENO" 12974then : 12975 ac_cv_lib_dl_dlsym=yes 12976else $as_nop 12977 ac_cv_lib_dl_dlsym=no 12978fi 12979rm -f core conftest.err conftest.$ac_objext conftest.beam \ 12980 conftest$ac_exeext conftest.$ac_ext 12981LIBS=$ac_check_lib_save_LIBS 12982fi 12983{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlsym" >&5 12984printf "%s\n" "$ac_cv_lib_dl_dlsym" >&6; } 12985if test "x$ac_cv_lib_dl_dlsym" = xyes 12986then : 12987 printf "%s\n" "#define HAVE_LIBDL 1" >>confdefs.h 12988 12989 LIBS="-ldl $LIBS" 12990 12991fi 12992 12993 # -lresolv needs to be at the end of LIBS or DNS lookups break 12994 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for res_query in -lresolv" >&5 12995printf %s "checking for res_query in -lresolv... " >&6; } 12996if test ${ac_cv_lib_resolv_res_query+y} 12997then : 12998 printf %s "(cached) " >&6 12999else $as_nop 13000 ac_check_lib_save_LIBS=$LIBS 13001LIBS="-lresolv $LIBS" 13002cat confdefs.h - <<_ACEOF >conftest.$ac_ext 13003/* end confdefs.h. */ 13004 13005/* Override any GCC internal prototype to avoid an error. 13006 Use char because int might match the return type of a GCC 13007 builtin and then its argument prototype would still apply. */ 13008char res_query (); 13009int 13010main (void) 13011{ 13012return res_query (); 13013 ; 13014 return 0; 13015} 13016_ACEOF 13017if ac_fn_c_try_link "$LINENO" 13018then : 13019 ac_cv_lib_resolv_res_query=yes 13020else $as_nop 13021 ac_cv_lib_resolv_res_query=no 13022fi 13023rm -f core conftest.err conftest.$ac_objext conftest.beam \ 13024 conftest$ac_exeext conftest.$ac_ext 13025LIBS=$ac_check_lib_save_LIBS 13026fi 13027{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_res_query" >&5 13028printf "%s\n" "$ac_cv_lib_resolv_res_query" >&6; } 13029if test "x$ac_cv_lib_resolv_res_query" = xyes 13030then : 13031 LIBS="$LIBS -lresolv" 13032fi 13033 13034 IPADDR_IN_DISPLAY=yes 13035 printf "%s\n" "#define USE_PIPES 1" >>confdefs.h 13036 13037 printf "%s\n" "#define IP_TOS_IS_BROKEN 1" >>confdefs.h 13038 13039 printf "%s\n" "#define SETEUID_BREAKS_SETUID 1" >>confdefs.h 13040 13041 printf "%s\n" "#define BROKEN_SETREUID 1" >>confdefs.h 13042 13043 printf "%s\n" "#define BROKEN_SETREGID 1" >>confdefs.h 13044 13045 printf "%s\n" "#define SSHD_ACQUIRES_CTTY 1" >>confdefs.h 13046 13047 external_path_file=/etc/default/login 13048 # /usr/ucblib/libucb.a no longer needed on ReliantUNIX 13049 # Attention: always take care to bind libsocket and libnsl before libc, 13050 # otherwise you will find lots of "SIOCGPGRP errno 22" on syslog 13051 ;; 13052# UnixWare 1.x, UnixWare 2.x, and others based on code from Univel. 13053*-*-sysv4.2*) 13054 printf "%s\n" "#define USE_PIPES 1" >>confdefs.h 13055 13056 printf "%s\n" "#define SETEUID_BREAKS_SETUID 1" >>confdefs.h 13057 13058 printf "%s\n" "#define BROKEN_SETREUID 1" >>confdefs.h 13059 13060 printf "%s\n" "#define BROKEN_SETREGID 1" >>confdefs.h 13061 13062 13063printf "%s\n" "#define PASSWD_NEEDS_USERNAME 1" >>confdefs.h 13064 13065 printf "%s\n" "#define LOCKED_PASSWD_STRING \"*LK*\"" >>confdefs.h 13066 13067 TEST_SHELL=$SHELL # let configure find us a capable shell 13068 ;; 13069# UnixWare 7.x, OpenUNIX 8 13070*-*-sysv5*) 13071 CPPFLAGS="$CPPFLAGS -Dvsnprintf=_xvsnprintf -Dsnprintf=_xsnprintf" 13072 13073printf "%s\n" "#define UNIXWARE_LONG_PASSWORDS 1" >>confdefs.h 13074 13075 printf "%s\n" "#define USE_PIPES 1" >>confdefs.h 13076 13077 printf "%s\n" "#define SETEUID_BREAKS_SETUID 1" >>confdefs.h 13078 13079 printf "%s\n" "#define BROKEN_GETADDRINFO 1" >>confdefs.h 13080 13081 printf "%s\n" "#define BROKEN_SETREUID 1" >>confdefs.h 13082 13083 printf "%s\n" "#define BROKEN_SETREGID 1" >>confdefs.h 13084 13085 printf "%s\n" "#define PASSWD_NEEDS_USERNAME 1" >>confdefs.h 13086 13087 printf "%s\n" "#define BROKEN_TCGETATTR_ICANON 1" >>confdefs.h 13088 13089 TEST_SHELL=$SHELL # let configure find us a capable shell 13090 case "$host" in 13091 *-*-sysv5SCO_SV*) # SCO OpenServer 6.x 13092 maildir=/var/spool/mail 13093 printf "%s\n" "#define BROKEN_UPDWTMPX 1" >>confdefs.h 13094 13095 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for getluid in -lprot" >&5 13096printf %s "checking for getluid in -lprot... " >&6; } 13097if test ${ac_cv_lib_prot_getluid+y} 13098then : 13099 printf %s "(cached) " >&6 13100else $as_nop 13101 ac_check_lib_save_LIBS=$LIBS 13102LIBS="-lprot $LIBS" 13103cat confdefs.h - <<_ACEOF >conftest.$ac_ext 13104/* end confdefs.h. */ 13105 13106/* Override any GCC internal prototype to avoid an error. 13107 Use char because int might match the return type of a GCC 13108 builtin and then its argument prototype would still apply. */ 13109char getluid (); 13110int 13111main (void) 13112{ 13113return getluid (); 13114 ; 13115 return 0; 13116} 13117_ACEOF 13118if ac_fn_c_try_link "$LINENO" 13119then : 13120 ac_cv_lib_prot_getluid=yes 13121else $as_nop 13122 ac_cv_lib_prot_getluid=no 13123fi 13124rm -f core conftest.err conftest.$ac_objext conftest.beam \ 13125 conftest$ac_exeext conftest.$ac_ext 13126LIBS=$ac_check_lib_save_LIBS 13127fi 13128{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_prot_getluid" >&5 13129printf "%s\n" "$ac_cv_lib_prot_getluid" >&6; } 13130if test "x$ac_cv_lib_prot_getluid" = xyes 13131then : 13132 LIBS="$LIBS -lprot" 13133 ac_fn_c_check_func "$LINENO" "getluid" "ac_cv_func_getluid" 13134if test "x$ac_cv_func_getluid" = xyes 13135then : 13136 printf "%s\n" "#define HAVE_GETLUID 1" >>confdefs.h 13137 13138fi 13139ac_fn_c_check_func "$LINENO" "setluid" "ac_cv_func_setluid" 13140if test "x$ac_cv_func_setluid" = xyes 13141then : 13142 printf "%s\n" "#define HAVE_SETLUID 1" >>confdefs.h 13143 13144fi 13145 13146 13147fi 13148 13149 ;; 13150 *) printf "%s\n" "#define LOCKED_PASSWD_STRING \"*LK*\"" >>confdefs.h 13151 13152 ;; 13153 esac 13154 ;; 13155*-*-sysv*) 13156 ;; 13157# SCO UNIX and OEM versions of SCO UNIX 13158*-*-sco3.2v4*) 13159 as_fn_error $? "\"This Platform is no longer supported.\"" "$LINENO" 5 13160 ;; 13161# SCO OpenServer 5.x 13162*-*-sco3.2v5*) 13163 if test -z "$GCC"; then 13164 CFLAGS="$CFLAGS -belf" 13165 fi 13166 LIBS="$LIBS -lprot -lx -ltinfo -lm" 13167 no_dev_ptmx=1 13168 printf "%s\n" "#define USE_PIPES 1" >>confdefs.h 13169 13170 printf "%s\n" "#define HAVE_SECUREWARE 1" >>confdefs.h 13171 13172 printf "%s\n" "#define DISABLE_SHADOW 1" >>confdefs.h 13173 13174 printf "%s\n" "#define DISABLE_FD_PASSING 1" >>confdefs.h 13175 13176 printf "%s\n" "#define SETEUID_BREAKS_SETUID 1" >>confdefs.h 13177 13178 printf "%s\n" "#define BROKEN_GETADDRINFO 1" >>confdefs.h 13179 13180 printf "%s\n" "#define BROKEN_SETREUID 1" >>confdefs.h 13181 13182 printf "%s\n" "#define BROKEN_SETREGID 1" >>confdefs.h 13183 13184 printf "%s\n" "#define WITH_ABBREV_NO_TTY 1" >>confdefs.h 13185 13186 printf "%s\n" "#define BROKEN_UPDWTMPX 1" >>confdefs.h 13187 13188 printf "%s\n" "#define PASSWD_NEEDS_USERNAME 1" >>confdefs.h 13189 13190 ac_fn_c_check_func "$LINENO" "getluid" "ac_cv_func_getluid" 13191if test "x$ac_cv_func_getluid" = xyes 13192then : 13193 printf "%s\n" "#define HAVE_GETLUID 1" >>confdefs.h 13194 13195fi 13196ac_fn_c_check_func "$LINENO" "setluid" "ac_cv_func_setluid" 13197if test "x$ac_cv_func_setluid" = xyes 13198then : 13199 printf "%s\n" "#define HAVE_SETLUID 1" >>confdefs.h 13200 13201fi 13202 13203 MANTYPE=man 13204 TEST_SHELL=$SHELL # let configure find us a capable shell 13205 SKIP_DISABLE_LASTLOG_DEFINE=yes 13206 ;; 13207*-dec-osf*) 13208 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for Digital Unix SIA" >&5 13209printf %s "checking for Digital Unix SIA... " >&6; } 13210 no_osfsia="" 13211 13212# Check whether --with-osfsia was given. 13213if test ${with_osfsia+y} 13214then : 13215 withval=$with_osfsia; 13216 if test "x$withval" = "xno" ; then 13217 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13218printf "%s\n" "disabled" >&6; } 13219 no_osfsia=1 13220 fi 13221 13222fi 13223 13224 if test -z "$no_osfsia" ; then 13225 if test -f /etc/sia/matrix.conf; then 13226 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 13227printf "%s\n" "yes" >&6; } 13228 13229printf "%s\n" "#define HAVE_OSF_SIA 1" >>confdefs.h 13230 13231 13232printf "%s\n" "#define DISABLE_LOGIN 1" >>confdefs.h 13233 13234 printf "%s\n" "#define DISABLE_FD_PASSING 1" >>confdefs.h 13235 13236 LIBS="$LIBS -lsecurity -ldb -lm -laud" 13237 SIA_MSG="yes" 13238 else 13239 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 13240printf "%s\n" "no" >&6; } 13241 13242printf "%s\n" "#define LOCKED_PASSWD_SUBSTR \"Nologin\"" >>confdefs.h 13243 13244 fi 13245 fi 13246 printf "%s\n" "#define BROKEN_GETADDRINFO 1" >>confdefs.h 13247 13248 printf "%s\n" "#define SETEUID_BREAKS_SETUID 1" >>confdefs.h 13249 13250 printf "%s\n" "#define BROKEN_SETREUID 1" >>confdefs.h 13251 13252 printf "%s\n" "#define BROKEN_SETREGID 1" >>confdefs.h 13253 13254 13255printf "%s\n" "#define BROKEN_READV_COMPARISON 1" >>confdefs.h 13256 13257 ;; 13258 13259*-*-nto-qnx*) 13260 printf "%s\n" "#define USE_PIPES 1" >>confdefs.h 13261 13262 printf "%s\n" "#define NO_X11_UNIX_SOCKETS 1" >>confdefs.h 13263 13264 printf "%s\n" "#define DISABLE_LASTLOG 1" >>confdefs.h 13265 13266 printf "%s\n" "#define SSHD_ACQUIRES_CTTY 1" >>confdefs.h 13267 13268 13269printf "%s\n" "#define BROKEN_SHADOW_EXPIRE 1" >>confdefs.h 13270 13271 enable_etc_default_login=no # has incompatible /etc/default/login 13272 case "$host" in 13273 *-*-nto-qnx6*) 13274 printf "%s\n" "#define DISABLE_FD_PASSING 1" >>confdefs.h 13275 13276 ;; 13277 esac 13278 ;; 13279 13280*-*-ultrix*) 13281 13282printf "%s\n" "#define BROKEN_GETGROUPS 1" >>confdefs.h 13283 13284 13285printf "%s\n" "#define NEED_SETPGRP 1" >>confdefs.h 13286 13287 13288printf "%s\n" "#define HAVE_SYS_SYSLOG_H 1" >>confdefs.h 13289 13290 13291printf "%s\n" "#define DISABLE_UTMPX 1" >>confdefs.h 13292 13293 # DISABLE_FD_PASSING so that we call setpgrp as root, otherwise we 13294 # don't get a controlling tty. 13295 13296printf "%s\n" "#define DISABLE_FD_PASSING 1" >>confdefs.h 13297 13298 # On Ultrix some headers are not protected against multiple includes, 13299 # so we create wrappers and put it where the compiler will find it. 13300 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: creating compat wrappers for headers" >&5 13301printf "%s\n" "$as_me: WARNING: creating compat wrappers for headers" >&2;} 13302 mkdir -p netinet 13303 for header in netinet/ip.h netdb.h resolv.h; do 13304 name=`echo $header | tr 'a-z/.' 'A-Z__'` 13305 cat >$header <<EOD 13306#ifndef _SSH_COMPAT_${name} 13307#define _SSH_COMPAT_${name} 13308#include "/usr/include/${header}" 13309#endif 13310EOD 13311 done 13312 ;; 13313 13314*-*-lynxos) 13315 CFLAGS="$CFLAGS -D__NO_INCLUDE_WARN__" 13316 13317printf "%s\n" "#define BROKEN_SETVBUF 1" >>confdefs.h 13318 13319 ;; 13320esac 13321 13322{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking compiler and flags for sanity" >&5 13323printf %s "checking compiler and flags for sanity... " >&6; } 13324if test "$cross_compiling" = yes 13325then : 13326 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: not checking compiler sanity" >&5 13327printf "%s\n" "$as_me: WARNING: cross compiling: not checking compiler sanity" >&2;} 13328 13329else $as_nop 13330 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 13331/* end confdefs.h. */ 13332 #include <stdlib.h> 13333int 13334main (void) 13335{ 13336 exit(0); 13337 ; 13338 return 0; 13339} 13340_ACEOF 13341if ac_fn_c_try_run "$LINENO" 13342then : 13343 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 13344printf "%s\n" "yes" >&6; } 13345else $as_nop 13346 13347 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 13348printf "%s\n" "no" >&6; } 13349 as_fn_error $? "*** compiler cannot create working executables, check config.log ***" "$LINENO" 5 13350 13351fi 13352rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 13353 conftest.$ac_objext conftest.beam conftest.$ac_ext 13354fi 13355 13356 13357# Checks for libraries. 13358ac_fn_c_check_func "$LINENO" "setsockopt" "ac_cv_func_setsockopt" 13359if test "x$ac_cv_func_setsockopt" = xyes 13360then : 13361 13362else $as_nop 13363 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for setsockopt in -lsocket" >&5 13364printf %s "checking for setsockopt in -lsocket... " >&6; } 13365if test ${ac_cv_lib_socket_setsockopt+y} 13366then : 13367 printf %s "(cached) " >&6 13368else $as_nop 13369 ac_check_lib_save_LIBS=$LIBS 13370LIBS="-lsocket $LIBS" 13371cat confdefs.h - <<_ACEOF >conftest.$ac_ext 13372/* end confdefs.h. */ 13373 13374/* Override any GCC internal prototype to avoid an error. 13375 Use char because int might match the return type of a GCC 13376 builtin and then its argument prototype would still apply. */ 13377char setsockopt (); 13378int 13379main (void) 13380{ 13381return setsockopt (); 13382 ; 13383 return 0; 13384} 13385_ACEOF 13386if ac_fn_c_try_link "$LINENO" 13387then : 13388 ac_cv_lib_socket_setsockopt=yes 13389else $as_nop 13390 ac_cv_lib_socket_setsockopt=no 13391fi 13392rm -f core conftest.err conftest.$ac_objext conftest.beam \ 13393 conftest$ac_exeext conftest.$ac_ext 13394LIBS=$ac_check_lib_save_LIBS 13395fi 13396{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_setsockopt" >&5 13397printf "%s\n" "$ac_cv_lib_socket_setsockopt" >&6; } 13398if test "x$ac_cv_lib_socket_setsockopt" = xyes 13399then : 13400 printf "%s\n" "#define HAVE_LIBSOCKET 1" >>confdefs.h 13401 13402 LIBS="-lsocket $LIBS" 13403 13404fi 13405 13406fi 13407 13408 13409 13410 for ac_func in dirname 13411do : 13412 ac_fn_c_check_func "$LINENO" "dirname" "ac_cv_func_dirname" 13413if test "x$ac_cv_func_dirname" = xyes 13414then : 13415 printf "%s\n" "#define HAVE_DIRNAME 1" >>confdefs.h 13416 ac_fn_c_check_header_compile "$LINENO" "libgen.h" "ac_cv_header_libgen_h" "$ac_includes_default" 13417if test "x$ac_cv_header_libgen_h" = xyes 13418then : 13419 printf "%s\n" "#define HAVE_LIBGEN_H 1" >>confdefs.h 13420 13421fi 13422 13423else $as_nop 13424 13425 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dirname in -lgen" >&5 13426printf %s "checking for dirname in -lgen... " >&6; } 13427if test ${ac_cv_lib_gen_dirname+y} 13428then : 13429 printf %s "(cached) " >&6 13430else $as_nop 13431 ac_check_lib_save_LIBS=$LIBS 13432LIBS="-lgen $LIBS" 13433cat confdefs.h - <<_ACEOF >conftest.$ac_ext 13434/* end confdefs.h. */ 13435 13436/* Override any GCC internal prototype to avoid an error. 13437 Use char because int might match the return type of a GCC 13438 builtin and then its argument prototype would still apply. */ 13439char dirname (); 13440int 13441main (void) 13442{ 13443return dirname (); 13444 ; 13445 return 0; 13446} 13447_ACEOF 13448if ac_fn_c_try_link "$LINENO" 13449then : 13450 ac_cv_lib_gen_dirname=yes 13451else $as_nop 13452 ac_cv_lib_gen_dirname=no 13453fi 13454rm -f core conftest.err conftest.$ac_objext conftest.beam \ 13455 conftest$ac_exeext conftest.$ac_ext 13456LIBS=$ac_check_lib_save_LIBS 13457fi 13458{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gen_dirname" >&5 13459printf "%s\n" "$ac_cv_lib_gen_dirname" >&6; } 13460if test "x$ac_cv_lib_gen_dirname" = xyes 13461then : 13462 13463 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for broken dirname" >&5 13464printf %s "checking for broken dirname... " >&6; } 13465if test ${ac_cv_have_broken_dirname+y} 13466then : 13467 printf %s "(cached) " >&6 13468else $as_nop 13469 13470 save_LIBS="$LIBS" 13471 LIBS="$LIBS -lgen" 13472 if test "$cross_compiling" = yes 13473then : 13474 ac_cv_have_broken_dirname="no" 13475else $as_nop 13476 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 13477/* end confdefs.h. */ 13478 13479#include <libgen.h> 13480#include <string.h> 13481#include <stdlib.h> 13482 13483int main(int argc, char **argv) { 13484 char *s, buf[32]; 13485 13486 strncpy(buf,"/etc", 32); 13487 s = dirname(buf); 13488 if (!s || strncmp(s, "/", 32) != 0) { 13489 exit(1); 13490 } else { 13491 exit(0); 13492 } 13493} 13494 13495_ACEOF 13496if ac_fn_c_try_run "$LINENO" 13497then : 13498 ac_cv_have_broken_dirname="no" 13499else $as_nop 13500 ac_cv_have_broken_dirname="yes" 13501fi 13502rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 13503 conftest.$ac_objext conftest.beam conftest.$ac_ext 13504fi 13505 13506 LIBS="$save_LIBS" 13507 13508fi 13509{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_broken_dirname" >&5 13510printf "%s\n" "$ac_cv_have_broken_dirname" >&6; } 13511 if test "x$ac_cv_have_broken_dirname" = "xno" ; then 13512 LIBS="$LIBS -lgen" 13513 printf "%s\n" "#define HAVE_DIRNAME 1" >>confdefs.h 13514 13515 ac_fn_c_check_header_compile "$LINENO" "libgen.h" "ac_cv_header_libgen_h" "$ac_includes_default" 13516if test "x$ac_cv_header_libgen_h" = xyes 13517then : 13518 printf "%s\n" "#define HAVE_LIBGEN_H 1" >>confdefs.h 13519 13520fi 13521 13522 fi 13523 13524fi 13525 13526 13527fi 13528 13529done 13530 13531ac_fn_c_check_func "$LINENO" "getspnam" "ac_cv_func_getspnam" 13532if test "x$ac_cv_func_getspnam" = xyes 13533then : 13534 13535else $as_nop 13536 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for getspnam in -lgen" >&5 13537printf %s "checking for getspnam in -lgen... " >&6; } 13538if test ${ac_cv_lib_gen_getspnam+y} 13539then : 13540 printf %s "(cached) " >&6 13541else $as_nop 13542 ac_check_lib_save_LIBS=$LIBS 13543LIBS="-lgen $LIBS" 13544cat confdefs.h - <<_ACEOF >conftest.$ac_ext 13545/* end confdefs.h. */ 13546 13547/* Override any GCC internal prototype to avoid an error. 13548 Use char because int might match the return type of a GCC 13549 builtin and then its argument prototype would still apply. */ 13550char getspnam (); 13551int 13552main (void) 13553{ 13554return getspnam (); 13555 ; 13556 return 0; 13557} 13558_ACEOF 13559if ac_fn_c_try_link "$LINENO" 13560then : 13561 ac_cv_lib_gen_getspnam=yes 13562else $as_nop 13563 ac_cv_lib_gen_getspnam=no 13564fi 13565rm -f core conftest.err conftest.$ac_objext conftest.beam \ 13566 conftest$ac_exeext conftest.$ac_ext 13567LIBS=$ac_check_lib_save_LIBS 13568fi 13569{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gen_getspnam" >&5 13570printf "%s\n" "$ac_cv_lib_gen_getspnam" >&6; } 13571if test "x$ac_cv_lib_gen_getspnam" = xyes 13572then : 13573 LIBS="$LIBS -lgen" 13574fi 13575 13576fi 13577 13578{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing basename" >&5 13579printf %s "checking for library containing basename... " >&6; } 13580if test ${ac_cv_search_basename+y} 13581then : 13582 printf %s "(cached) " >&6 13583else $as_nop 13584 ac_func_search_save_LIBS=$LIBS 13585cat confdefs.h - <<_ACEOF >conftest.$ac_ext 13586/* end confdefs.h. */ 13587 13588/* Override any GCC internal prototype to avoid an error. 13589 Use char because int might match the return type of a GCC 13590 builtin and then its argument prototype would still apply. */ 13591char basename (); 13592int 13593main (void) 13594{ 13595return basename (); 13596 ; 13597 return 0; 13598} 13599_ACEOF 13600for ac_lib in '' gen 13601do 13602 if test -z "$ac_lib"; then 13603 ac_res="none required" 13604 else 13605 ac_res=-l$ac_lib 13606 LIBS="-l$ac_lib $ac_func_search_save_LIBS" 13607 fi 13608 if ac_fn_c_try_link "$LINENO" 13609then : 13610 ac_cv_search_basename=$ac_res 13611fi 13612rm -f core conftest.err conftest.$ac_objext conftest.beam \ 13613 conftest$ac_exeext 13614 if test ${ac_cv_search_basename+y} 13615then : 13616 break 13617fi 13618done 13619if test ${ac_cv_search_basename+y} 13620then : 13621 13622else $as_nop 13623 ac_cv_search_basename=no 13624fi 13625rm conftest.$ac_ext 13626LIBS=$ac_func_search_save_LIBS 13627fi 13628{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_basename" >&5 13629printf "%s\n" "$ac_cv_search_basename" >&6; } 13630ac_res=$ac_cv_search_basename 13631if test "$ac_res" != no 13632then : 13633 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" 13634 13635printf "%s\n" "#define HAVE_BASENAME 1" >>confdefs.h 13636 13637fi 13638 13639 13640zlib=yes 13641 13642# Check whether --with-zlib was given. 13643if test ${with_zlib+y} 13644then : 13645 withval=$with_zlib; if test "x$withval" = "xno" ; then 13646 zlib=no 13647 elif test "x$withval" != "xyes"; then 13648 if test -d "$withval/lib"; then 13649 if test -n "${rpath_opt}"; then 13650 LDFLAGS="-L${withval}/lib ${rpath_opt}${withval}/lib ${LDFLAGS}" 13651 else 13652 LDFLAGS="-L${withval}/lib ${LDFLAGS}" 13653 fi 13654 else 13655 if test -n "${rpath_opt}"; then 13656 LDFLAGS="-L${withval} ${rpath_opt}${withval} ${LDFLAGS}" 13657 else 13658 LDFLAGS="-L${withval} ${LDFLAGS}" 13659 fi 13660 fi 13661 if test -d "$withval/include"; then 13662 CPPFLAGS="-I${withval}/include ${CPPFLAGS}" 13663 else 13664 CPPFLAGS="-I${withval} ${CPPFLAGS}" 13665 fi 13666 fi 13667 13668fi 13669 13670 13671# These libraries are needed for anything that links in the channel code. 13672CHANNELLIBS="" 13673{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for zlib" >&5 13674printf %s "checking for zlib... " >&6; } 13675if test "x${zlib}" = "xno"; then 13676 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 13677printf "%s\n" "no" >&6; } 13678else 13679 saved_LIBS="$LIBS" 13680 CHANNELLIBS="$CHANNELLIBS -lz" 13681 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 13682printf "%s\n" "yes" >&6; } 13683 13684printf "%s\n" "#define WITH_ZLIB 1" >>confdefs.h 13685 13686 ac_fn_c_check_header_compile "$LINENO" "zlib.h" "ac_cv_header_zlib_h" "$ac_includes_default" 13687if test "x$ac_cv_header_zlib_h" = xyes 13688then : 13689 13690else $as_nop 13691 as_fn_error $? "*** zlib.h missing - please install first or check config.log ***" "$LINENO" 5 13692fi 13693 13694 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for deflate in -lz" >&5 13695printf %s "checking for deflate in -lz... " >&6; } 13696if test ${ac_cv_lib_z_deflate+y} 13697then : 13698 printf %s "(cached) " >&6 13699else $as_nop 13700 ac_check_lib_save_LIBS=$LIBS 13701LIBS="-lz $LIBS" 13702cat confdefs.h - <<_ACEOF >conftest.$ac_ext 13703/* end confdefs.h. */ 13704 13705/* Override any GCC internal prototype to avoid an error. 13706 Use char because int might match the return type of a GCC 13707 builtin and then its argument prototype would still apply. */ 13708char deflate (); 13709int 13710main (void) 13711{ 13712return deflate (); 13713 ; 13714 return 0; 13715} 13716_ACEOF 13717if ac_fn_c_try_link "$LINENO" 13718then : 13719 ac_cv_lib_z_deflate=yes 13720else $as_nop 13721 ac_cv_lib_z_deflate=no 13722fi 13723rm -f core conftest.err conftest.$ac_objext conftest.beam \ 13724 conftest$ac_exeext conftest.$ac_ext 13725LIBS=$ac_check_lib_save_LIBS 13726fi 13727{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_deflate" >&5 13728printf "%s\n" "$ac_cv_lib_z_deflate" >&6; } 13729if test "x$ac_cv_lib_z_deflate" = xyes 13730then : 13731 printf "%s\n" "#define HAVE_LIBZ 1" >>confdefs.h 13732 13733 LIBS="-lz $LIBS" 13734 13735else $as_nop 13736 13737 saved_CPPFLAGS="$CPPFLAGS" 13738 saved_LDFLAGS="$LDFLAGS" 13739 if test -n "${rpath_opt}"; then 13740 LDFLAGS="-L/usr/local/lib ${rpath_opt}/usr/local/lib ${saved_LDFLAGS}" 13741 else 13742 LDFLAGS="-L/usr/local/lib ${saved_LDFLAGS}" 13743 fi 13744 CPPFLAGS="-I/usr/local/include ${saved_CPPFLAGS}" 13745 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 13746/* end confdefs.h. */ 13747 13748/* Override any GCC internal prototype to avoid an error. 13749 Use char because int might match the return type of a GCC 13750 builtin and then its argument prototype would still apply. */ 13751char deflate (); 13752int 13753main (void) 13754{ 13755return deflate (); 13756 ; 13757 return 0; 13758} 13759_ACEOF 13760if ac_fn_c_try_link "$LINENO" 13761then : 13762 printf "%s\n" "#define HAVE_LIBZ 1" >>confdefs.h 13763 13764else $as_nop 13765 13766 as_fn_error $? "*** zlib missing - please install first or check config.log ***" "$LINENO" 5 13767 13768 13769fi 13770rm -f core conftest.err conftest.$ac_objext conftest.beam \ 13771 conftest$ac_exeext conftest.$ac_ext 13772 13773 13774fi 13775 13776 13777 13778# Check whether --with-zlib-version-check was given. 13779if test ${with_zlib_version_check+y} 13780then : 13781 withval=$with_zlib_version_check; if test "x$withval" = "xno" ; then 13782 zlib_check_nonfatal=1 13783 fi 13784 13785 13786fi 13787 13788 13789 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for possibly buggy zlib" >&5 13790printf %s "checking for possibly buggy zlib... " >&6; } 13791 if test "$cross_compiling" = yes 13792then : 13793 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: not checking zlib version" >&5 13794printf "%s\n" "$as_me: WARNING: cross compiling: not checking zlib version" >&2;} 13795 13796else $as_nop 13797 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 13798/* end confdefs.h. */ 13799 13800#include <stdio.h> 13801#include <stdlib.h> 13802#include <zlib.h> 13803 13804int 13805main (void) 13806{ 13807 13808 int a=0, b=0, c=0, d=0, n, v; 13809 n = sscanf(ZLIB_VERSION, "%d.%d.%d.%d", &a, &b, &c, &d); 13810 if (n < 1) 13811 exit(1); 13812 v = a*1000000 + b*10000 + c*100 + d; 13813 fprintf(stderr, "found zlib version %s (%d)\n", ZLIB_VERSION, v); 13814 13815 /* 1.1.4 is OK */ 13816 if (a == 1 && b == 1 && c >= 4) 13817 exit(0); 13818 13819 /* 1.2.3 and up are OK */ 13820 if (v >= 1020300) 13821 exit(0); 13822 13823 exit(2); 13824 13825 ; 13826 return 0; 13827} 13828_ACEOF 13829if ac_fn_c_try_run "$LINENO" 13830then : 13831 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 13832printf "%s\n" "no" >&6; } 13833else $as_nop 13834 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 13835printf "%s\n" "yes" >&6; } 13836 if test -z "$zlib_check_nonfatal" ; then 13837 as_fn_error $? "*** zlib too old - check config.log *** 13838Your reported zlib version has known security problems. It's possible your 13839vendor has fixed these problems without changing the version number. If you 13840are sure this is the case, you can disable the check by running 13841\"./configure --without-zlib-version-check\". 13842If you are in doubt, upgrade zlib to version 1.2.3 or greater. 13843See http://www.gzip.org/zlib/ for details." "$LINENO" 5 13844 else 13845 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: zlib version may have security problems" >&5 13846printf "%s\n" "$as_me: WARNING: zlib version may have security problems" >&2;} 13847 fi 13848 13849fi 13850rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 13851 conftest.$ac_objext conftest.beam conftest.$ac_ext 13852fi 13853 13854 LIBS="$saved_LIBS" 13855fi 13856 13857ac_fn_c_check_func "$LINENO" "strcasecmp" "ac_cv_func_strcasecmp" 13858if test "x$ac_cv_func_strcasecmp" = xyes 13859then : 13860 13861else $as_nop 13862 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for strcasecmp in -lresolv" >&5 13863printf %s "checking for strcasecmp in -lresolv... " >&6; } 13864if test ${ac_cv_lib_resolv_strcasecmp+y} 13865then : 13866 printf %s "(cached) " >&6 13867else $as_nop 13868 ac_check_lib_save_LIBS=$LIBS 13869LIBS="-lresolv $LIBS" 13870cat confdefs.h - <<_ACEOF >conftest.$ac_ext 13871/* end confdefs.h. */ 13872 13873/* Override any GCC internal prototype to avoid an error. 13874 Use char because int might match the return type of a GCC 13875 builtin and then its argument prototype would still apply. */ 13876char strcasecmp (); 13877int 13878main (void) 13879{ 13880return strcasecmp (); 13881 ; 13882 return 0; 13883} 13884_ACEOF 13885if ac_fn_c_try_link "$LINENO" 13886then : 13887 ac_cv_lib_resolv_strcasecmp=yes 13888else $as_nop 13889 ac_cv_lib_resolv_strcasecmp=no 13890fi 13891rm -f core conftest.err conftest.$ac_objext conftest.beam \ 13892 conftest$ac_exeext conftest.$ac_ext 13893LIBS=$ac_check_lib_save_LIBS 13894fi 13895{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_strcasecmp" >&5 13896printf "%s\n" "$ac_cv_lib_resolv_strcasecmp" >&6; } 13897if test "x$ac_cv_lib_resolv_strcasecmp" = xyes 13898then : 13899 LIBS="$LIBS -lresolv" 13900fi 13901 13902 13903fi 13904 13905 13906 for ac_func in utimes 13907do : 13908 ac_fn_c_check_func "$LINENO" "utimes" "ac_cv_func_utimes" 13909if test "x$ac_cv_func_utimes" = xyes 13910then : 13911 printf "%s\n" "#define HAVE_UTIMES 1" >>confdefs.h 13912 13913else $as_nop 13914 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for utimes in -lc89" >&5 13915printf %s "checking for utimes in -lc89... " >&6; } 13916if test ${ac_cv_lib_c89_utimes+y} 13917then : 13918 printf %s "(cached) " >&6 13919else $as_nop 13920 ac_check_lib_save_LIBS=$LIBS 13921LIBS="-lc89 $LIBS" 13922cat confdefs.h - <<_ACEOF >conftest.$ac_ext 13923/* end confdefs.h. */ 13924 13925/* Override any GCC internal prototype to avoid an error. 13926 Use char because int might match the return type of a GCC 13927 builtin and then its argument prototype would still apply. */ 13928char utimes (); 13929int 13930main (void) 13931{ 13932return utimes (); 13933 ; 13934 return 0; 13935} 13936_ACEOF 13937if ac_fn_c_try_link "$LINENO" 13938then : 13939 ac_cv_lib_c89_utimes=yes 13940else $as_nop 13941 ac_cv_lib_c89_utimes=no 13942fi 13943rm -f core conftest.err conftest.$ac_objext conftest.beam \ 13944 conftest$ac_exeext conftest.$ac_ext 13945LIBS=$ac_check_lib_save_LIBS 13946fi 13947{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c89_utimes" >&5 13948printf "%s\n" "$ac_cv_lib_c89_utimes" >&6; } 13949if test "x$ac_cv_lib_c89_utimes" = xyes 13950then : 13951 printf "%s\n" "#define HAVE_UTIMES 1" >>confdefs.h 13952 13953 LIBS="$LIBS -lc89" 13954fi 13955 13956 13957fi 13958 13959done 13960 13961ac_fn_c_check_header_compile "$LINENO" "bsd/libutil.h" "ac_cv_header_bsd_libutil_h" "$ac_includes_default" 13962if test "x$ac_cv_header_bsd_libutil_h" = xyes 13963then : 13964 printf "%s\n" "#define HAVE_BSD_LIBUTIL_H 1" >>confdefs.h 13965 13966fi 13967ac_fn_c_check_header_compile "$LINENO" "libutil.h" "ac_cv_header_libutil_h" "$ac_includes_default" 13968if test "x$ac_cv_header_libutil_h" = xyes 13969then : 13970 printf "%s\n" "#define HAVE_LIBUTIL_H 1" >>confdefs.h 13971 13972fi 13973 13974{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing fmt_scaled" >&5 13975printf %s "checking for library containing fmt_scaled... " >&6; } 13976if test ${ac_cv_search_fmt_scaled+y} 13977then : 13978 printf %s "(cached) " >&6 13979else $as_nop 13980 ac_func_search_save_LIBS=$LIBS 13981cat confdefs.h - <<_ACEOF >conftest.$ac_ext 13982/* end confdefs.h. */ 13983 13984/* Override any GCC internal prototype to avoid an error. 13985 Use char because int might match the return type of a GCC 13986 builtin and then its argument prototype would still apply. */ 13987char fmt_scaled (); 13988int 13989main (void) 13990{ 13991return fmt_scaled (); 13992 ; 13993 return 0; 13994} 13995_ACEOF 13996for ac_lib in '' util bsd 13997do 13998 if test -z "$ac_lib"; then 13999 ac_res="none required" 14000 else 14001 ac_res=-l$ac_lib 14002 LIBS="-l$ac_lib $ac_func_search_save_LIBS" 14003 fi 14004 if ac_fn_c_try_link "$LINENO" 14005then : 14006 ac_cv_search_fmt_scaled=$ac_res 14007fi 14008rm -f core conftest.err conftest.$ac_objext conftest.beam \ 14009 conftest$ac_exeext 14010 if test ${ac_cv_search_fmt_scaled+y} 14011then : 14012 break 14013fi 14014done 14015if test ${ac_cv_search_fmt_scaled+y} 14016then : 14017 14018else $as_nop 14019 ac_cv_search_fmt_scaled=no 14020fi 14021rm conftest.$ac_ext 14022LIBS=$ac_func_search_save_LIBS 14023fi 14024{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_fmt_scaled" >&5 14025printf "%s\n" "$ac_cv_search_fmt_scaled" >&6; } 14026ac_res=$ac_cv_search_fmt_scaled 14027if test "$ac_res" != no 14028then : 14029 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" 14030 14031fi 14032 14033{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing scan_scaled" >&5 14034printf %s "checking for library containing scan_scaled... " >&6; } 14035if test ${ac_cv_search_scan_scaled+y} 14036then : 14037 printf %s "(cached) " >&6 14038else $as_nop 14039 ac_func_search_save_LIBS=$LIBS 14040cat confdefs.h - <<_ACEOF >conftest.$ac_ext 14041/* end confdefs.h. */ 14042 14043/* Override any GCC internal prototype to avoid an error. 14044 Use char because int might match the return type of a GCC 14045 builtin and then its argument prototype would still apply. */ 14046char scan_scaled (); 14047int 14048main (void) 14049{ 14050return scan_scaled (); 14051 ; 14052 return 0; 14053} 14054_ACEOF 14055for ac_lib in '' util bsd 14056do 14057 if test -z "$ac_lib"; then 14058 ac_res="none required" 14059 else 14060 ac_res=-l$ac_lib 14061 LIBS="-l$ac_lib $ac_func_search_save_LIBS" 14062 fi 14063 if ac_fn_c_try_link "$LINENO" 14064then : 14065 ac_cv_search_scan_scaled=$ac_res 14066fi 14067rm -f core conftest.err conftest.$ac_objext conftest.beam \ 14068 conftest$ac_exeext 14069 if test ${ac_cv_search_scan_scaled+y} 14070then : 14071 break 14072fi 14073done 14074if test ${ac_cv_search_scan_scaled+y} 14075then : 14076 14077else $as_nop 14078 ac_cv_search_scan_scaled=no 14079fi 14080rm conftest.$ac_ext 14081LIBS=$ac_func_search_save_LIBS 14082fi 14083{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_scan_scaled" >&5 14084printf "%s\n" "$ac_cv_search_scan_scaled" >&6; } 14085ac_res=$ac_cv_search_scan_scaled 14086if test "$ac_res" != no 14087then : 14088 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" 14089 14090fi 14091 14092{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing login" >&5 14093printf %s "checking for library containing login... " >&6; } 14094if test ${ac_cv_search_login+y} 14095then : 14096 printf %s "(cached) " >&6 14097else $as_nop 14098 ac_func_search_save_LIBS=$LIBS 14099cat confdefs.h - <<_ACEOF >conftest.$ac_ext 14100/* end confdefs.h. */ 14101 14102/* Override any GCC internal prototype to avoid an error. 14103 Use char because int might match the return type of a GCC 14104 builtin and then its argument prototype would still apply. */ 14105char login (); 14106int 14107main (void) 14108{ 14109return login (); 14110 ; 14111 return 0; 14112} 14113_ACEOF 14114for ac_lib in '' util bsd 14115do 14116 if test -z "$ac_lib"; then 14117 ac_res="none required" 14118 else 14119 ac_res=-l$ac_lib 14120 LIBS="-l$ac_lib $ac_func_search_save_LIBS" 14121 fi 14122 if ac_fn_c_try_link "$LINENO" 14123then : 14124 ac_cv_search_login=$ac_res 14125fi 14126rm -f core conftest.err conftest.$ac_objext conftest.beam \ 14127 conftest$ac_exeext 14128 if test ${ac_cv_search_login+y} 14129then : 14130 break 14131fi 14132done 14133if test ${ac_cv_search_login+y} 14134then : 14135 14136else $as_nop 14137 ac_cv_search_login=no 14138fi 14139rm conftest.$ac_ext 14140LIBS=$ac_func_search_save_LIBS 14141fi 14142{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_login" >&5 14143printf "%s\n" "$ac_cv_search_login" >&6; } 14144ac_res=$ac_cv_search_login 14145if test "$ac_res" != no 14146then : 14147 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" 14148 14149fi 14150 14151{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing logout" >&5 14152printf %s "checking for library containing logout... " >&6; } 14153if test ${ac_cv_search_logout+y} 14154then : 14155 printf %s "(cached) " >&6 14156else $as_nop 14157 ac_func_search_save_LIBS=$LIBS 14158cat confdefs.h - <<_ACEOF >conftest.$ac_ext 14159/* end confdefs.h. */ 14160 14161/* Override any GCC internal prototype to avoid an error. 14162 Use char because int might match the return type of a GCC 14163 builtin and then its argument prototype would still apply. */ 14164char logout (); 14165int 14166main (void) 14167{ 14168return logout (); 14169 ; 14170 return 0; 14171} 14172_ACEOF 14173for ac_lib in '' util bsd 14174do 14175 if test -z "$ac_lib"; then 14176 ac_res="none required" 14177 else 14178 ac_res=-l$ac_lib 14179 LIBS="-l$ac_lib $ac_func_search_save_LIBS" 14180 fi 14181 if ac_fn_c_try_link "$LINENO" 14182then : 14183 ac_cv_search_logout=$ac_res 14184fi 14185rm -f core conftest.err conftest.$ac_objext conftest.beam \ 14186 conftest$ac_exeext 14187 if test ${ac_cv_search_logout+y} 14188then : 14189 break 14190fi 14191done 14192if test ${ac_cv_search_logout+y} 14193then : 14194 14195else $as_nop 14196 ac_cv_search_logout=no 14197fi 14198rm conftest.$ac_ext 14199LIBS=$ac_func_search_save_LIBS 14200fi 14201{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_logout" >&5 14202printf "%s\n" "$ac_cv_search_logout" >&6; } 14203ac_res=$ac_cv_search_logout 14204if test "$ac_res" != no 14205then : 14206 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" 14207 14208fi 14209 14210{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing logwtmp" >&5 14211printf %s "checking for library containing logwtmp... " >&6; } 14212if test ${ac_cv_search_logwtmp+y} 14213then : 14214 printf %s "(cached) " >&6 14215else $as_nop 14216 ac_func_search_save_LIBS=$LIBS 14217cat confdefs.h - <<_ACEOF >conftest.$ac_ext 14218/* end confdefs.h. */ 14219 14220/* Override any GCC internal prototype to avoid an error. 14221 Use char because int might match the return type of a GCC 14222 builtin and then its argument prototype would still apply. */ 14223char logwtmp (); 14224int 14225main (void) 14226{ 14227return logwtmp (); 14228 ; 14229 return 0; 14230} 14231_ACEOF 14232for ac_lib in '' util bsd 14233do 14234 if test -z "$ac_lib"; then 14235 ac_res="none required" 14236 else 14237 ac_res=-l$ac_lib 14238 LIBS="-l$ac_lib $ac_func_search_save_LIBS" 14239 fi 14240 if ac_fn_c_try_link "$LINENO" 14241then : 14242 ac_cv_search_logwtmp=$ac_res 14243fi 14244rm -f core conftest.err conftest.$ac_objext conftest.beam \ 14245 conftest$ac_exeext 14246 if test ${ac_cv_search_logwtmp+y} 14247then : 14248 break 14249fi 14250done 14251if test ${ac_cv_search_logwtmp+y} 14252then : 14253 14254else $as_nop 14255 ac_cv_search_logwtmp=no 14256fi 14257rm conftest.$ac_ext 14258LIBS=$ac_func_search_save_LIBS 14259fi 14260{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_logwtmp" >&5 14261printf "%s\n" "$ac_cv_search_logwtmp" >&6; } 14262ac_res=$ac_cv_search_logwtmp 14263if test "$ac_res" != no 14264then : 14265 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" 14266 14267fi 14268 14269{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing openpty" >&5 14270printf %s "checking for library containing openpty... " >&6; } 14271if test ${ac_cv_search_openpty+y} 14272then : 14273 printf %s "(cached) " >&6 14274else $as_nop 14275 ac_func_search_save_LIBS=$LIBS 14276cat confdefs.h - <<_ACEOF >conftest.$ac_ext 14277/* end confdefs.h. */ 14278 14279/* Override any GCC internal prototype to avoid an error. 14280 Use char because int might match the return type of a GCC 14281 builtin and then its argument prototype would still apply. */ 14282char openpty (); 14283int 14284main (void) 14285{ 14286return openpty (); 14287 ; 14288 return 0; 14289} 14290_ACEOF 14291for ac_lib in '' util bsd 14292do 14293 if test -z "$ac_lib"; then 14294 ac_res="none required" 14295 else 14296 ac_res=-l$ac_lib 14297 LIBS="-l$ac_lib $ac_func_search_save_LIBS" 14298 fi 14299 if ac_fn_c_try_link "$LINENO" 14300then : 14301 ac_cv_search_openpty=$ac_res 14302fi 14303rm -f core conftest.err conftest.$ac_objext conftest.beam \ 14304 conftest$ac_exeext 14305 if test ${ac_cv_search_openpty+y} 14306then : 14307 break 14308fi 14309done 14310if test ${ac_cv_search_openpty+y} 14311then : 14312 14313else $as_nop 14314 ac_cv_search_openpty=no 14315fi 14316rm conftest.$ac_ext 14317LIBS=$ac_func_search_save_LIBS 14318fi 14319{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_openpty" >&5 14320printf "%s\n" "$ac_cv_search_openpty" >&6; } 14321ac_res=$ac_cv_search_openpty 14322if test "$ac_res" != no 14323then : 14324 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" 14325 14326fi 14327 14328{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing updwtmp" >&5 14329printf %s "checking for library containing updwtmp... " >&6; } 14330if test ${ac_cv_search_updwtmp+y} 14331then : 14332 printf %s "(cached) " >&6 14333else $as_nop 14334 ac_func_search_save_LIBS=$LIBS 14335cat confdefs.h - <<_ACEOF >conftest.$ac_ext 14336/* end confdefs.h. */ 14337 14338/* Override any GCC internal prototype to avoid an error. 14339 Use char because int might match the return type of a GCC 14340 builtin and then its argument prototype would still apply. */ 14341char updwtmp (); 14342int 14343main (void) 14344{ 14345return updwtmp (); 14346 ; 14347 return 0; 14348} 14349_ACEOF 14350for ac_lib in '' util bsd 14351do 14352 if test -z "$ac_lib"; then 14353 ac_res="none required" 14354 else 14355 ac_res=-l$ac_lib 14356 LIBS="-l$ac_lib $ac_func_search_save_LIBS" 14357 fi 14358 if ac_fn_c_try_link "$LINENO" 14359then : 14360 ac_cv_search_updwtmp=$ac_res 14361fi 14362rm -f core conftest.err conftest.$ac_objext conftest.beam \ 14363 conftest$ac_exeext 14364 if test ${ac_cv_search_updwtmp+y} 14365then : 14366 break 14367fi 14368done 14369if test ${ac_cv_search_updwtmp+y} 14370then : 14371 14372else $as_nop 14373 ac_cv_search_updwtmp=no 14374fi 14375rm conftest.$ac_ext 14376LIBS=$ac_func_search_save_LIBS 14377fi 14378{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_updwtmp" >&5 14379printf "%s\n" "$ac_cv_search_updwtmp" >&6; } 14380ac_res=$ac_cv_search_updwtmp 14381if test "$ac_res" != no 14382then : 14383 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" 14384 14385fi 14386 14387ac_fn_c_check_func "$LINENO" "fmt_scaled" "ac_cv_func_fmt_scaled" 14388if test "x$ac_cv_func_fmt_scaled" = xyes 14389then : 14390 printf "%s\n" "#define HAVE_FMT_SCALED 1" >>confdefs.h 14391 14392fi 14393ac_fn_c_check_func "$LINENO" "scan_scaled" "ac_cv_func_scan_scaled" 14394if test "x$ac_cv_func_scan_scaled" = xyes 14395then : 14396 printf "%s\n" "#define HAVE_SCAN_SCALED 1" >>confdefs.h 14397 14398fi 14399ac_fn_c_check_func "$LINENO" "login" "ac_cv_func_login" 14400if test "x$ac_cv_func_login" = xyes 14401then : 14402 printf "%s\n" "#define HAVE_LOGIN 1" >>confdefs.h 14403 14404fi 14405ac_fn_c_check_func "$LINENO" "logout" "ac_cv_func_logout" 14406if test "x$ac_cv_func_logout" = xyes 14407then : 14408 printf "%s\n" "#define HAVE_LOGOUT 1" >>confdefs.h 14409 14410fi 14411ac_fn_c_check_func "$LINENO" "openpty" "ac_cv_func_openpty" 14412if test "x$ac_cv_func_openpty" = xyes 14413then : 14414 printf "%s\n" "#define HAVE_OPENPTY 1" >>confdefs.h 14415 14416fi 14417ac_fn_c_check_func "$LINENO" "updwtmp" "ac_cv_func_updwtmp" 14418if test "x$ac_cv_func_updwtmp" = xyes 14419then : 14420 printf "%s\n" "#define HAVE_UPDWTMP 1" >>confdefs.h 14421 14422fi 14423ac_fn_c_check_func "$LINENO" "logwtmp" "ac_cv_func_logwtmp" 14424if test "x$ac_cv_func_logwtmp" = xyes 14425then : 14426 printf "%s\n" "#define HAVE_LOGWTMP 1" >>confdefs.h 14427 14428fi 14429 14430 14431# On some platforms, inet_ntop and gethostbyname may be found in libresolv 14432# or libnsl. 14433{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing inet_ntop" >&5 14434printf %s "checking for library containing inet_ntop... " >&6; } 14435if test ${ac_cv_search_inet_ntop+y} 14436then : 14437 printf %s "(cached) " >&6 14438else $as_nop 14439 ac_func_search_save_LIBS=$LIBS 14440cat confdefs.h - <<_ACEOF >conftest.$ac_ext 14441/* end confdefs.h. */ 14442 14443/* Override any GCC internal prototype to avoid an error. 14444 Use char because int might match the return type of a GCC 14445 builtin and then its argument prototype would still apply. */ 14446char inet_ntop (); 14447int 14448main (void) 14449{ 14450return inet_ntop (); 14451 ; 14452 return 0; 14453} 14454_ACEOF 14455for ac_lib in '' resolv nsl 14456do 14457 if test -z "$ac_lib"; then 14458 ac_res="none required" 14459 else 14460 ac_res=-l$ac_lib 14461 LIBS="-l$ac_lib $ac_func_search_save_LIBS" 14462 fi 14463 if ac_fn_c_try_link "$LINENO" 14464then : 14465 ac_cv_search_inet_ntop=$ac_res 14466fi 14467rm -f core conftest.err conftest.$ac_objext conftest.beam \ 14468 conftest$ac_exeext 14469 if test ${ac_cv_search_inet_ntop+y} 14470then : 14471 break 14472fi 14473done 14474if test ${ac_cv_search_inet_ntop+y} 14475then : 14476 14477else $as_nop 14478 ac_cv_search_inet_ntop=no 14479fi 14480rm conftest.$ac_ext 14481LIBS=$ac_func_search_save_LIBS 14482fi 14483{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inet_ntop" >&5 14484printf "%s\n" "$ac_cv_search_inet_ntop" >&6; } 14485ac_res=$ac_cv_search_inet_ntop 14486if test "$ac_res" != no 14487then : 14488 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" 14489 14490fi 14491 14492{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing gethostbyname" >&5 14493printf %s "checking for library containing gethostbyname... " >&6; } 14494if test ${ac_cv_search_gethostbyname+y} 14495then : 14496 printf %s "(cached) " >&6 14497else $as_nop 14498 ac_func_search_save_LIBS=$LIBS 14499cat confdefs.h - <<_ACEOF >conftest.$ac_ext 14500/* end confdefs.h. */ 14501 14502/* Override any GCC internal prototype to avoid an error. 14503 Use char because int might match the return type of a GCC 14504 builtin and then its argument prototype would still apply. */ 14505char gethostbyname (); 14506int 14507main (void) 14508{ 14509return gethostbyname (); 14510 ; 14511 return 0; 14512} 14513_ACEOF 14514for ac_lib in '' resolv nsl 14515do 14516 if test -z "$ac_lib"; then 14517 ac_res="none required" 14518 else 14519 ac_res=-l$ac_lib 14520 LIBS="-l$ac_lib $ac_func_search_save_LIBS" 14521 fi 14522 if ac_fn_c_try_link "$LINENO" 14523then : 14524 ac_cv_search_gethostbyname=$ac_res 14525fi 14526rm -f core conftest.err conftest.$ac_objext conftest.beam \ 14527 conftest$ac_exeext 14528 if test ${ac_cv_search_gethostbyname+y} 14529then : 14530 break 14531fi 14532done 14533if test ${ac_cv_search_gethostbyname+y} 14534then : 14535 14536else $as_nop 14537 ac_cv_search_gethostbyname=no 14538fi 14539rm conftest.$ac_ext 14540LIBS=$ac_func_search_save_LIBS 14541fi 14542{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_gethostbyname" >&5 14543printf "%s\n" "$ac_cv_search_gethostbyname" >&6; } 14544ac_res=$ac_cv_search_gethostbyname 14545if test "$ac_res" != no 14546then : 14547 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" 14548 14549fi 14550 14551 14552# Some Linux distribtions ship the BSD libc hashing functions in 14553# separate libraries. 14554{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing SHA256Update" >&5 14555printf %s "checking for library containing SHA256Update... " >&6; } 14556if test ${ac_cv_search_SHA256Update+y} 14557then : 14558 printf %s "(cached) " >&6 14559else $as_nop 14560 ac_func_search_save_LIBS=$LIBS 14561cat confdefs.h - <<_ACEOF >conftest.$ac_ext 14562/* end confdefs.h. */ 14563 14564/* Override any GCC internal prototype to avoid an error. 14565 Use char because int might match the return type of a GCC 14566 builtin and then its argument prototype would still apply. */ 14567char SHA256Update (); 14568int 14569main (void) 14570{ 14571return SHA256Update (); 14572 ; 14573 return 0; 14574} 14575_ACEOF 14576for ac_lib in '' md bsd 14577do 14578 if test -z "$ac_lib"; then 14579 ac_res="none required" 14580 else 14581 ac_res=-l$ac_lib 14582 LIBS="-l$ac_lib $ac_func_search_save_LIBS" 14583 fi 14584 if ac_fn_c_try_link "$LINENO" 14585then : 14586 ac_cv_search_SHA256Update=$ac_res 14587fi 14588rm -f core conftest.err conftest.$ac_objext conftest.beam \ 14589 conftest$ac_exeext 14590 if test ${ac_cv_search_SHA256Update+y} 14591then : 14592 break 14593fi 14594done 14595if test ${ac_cv_search_SHA256Update+y} 14596then : 14597 14598else $as_nop 14599 ac_cv_search_SHA256Update=no 14600fi 14601rm conftest.$ac_ext 14602LIBS=$ac_func_search_save_LIBS 14603fi 14604{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_SHA256Update" >&5 14605printf "%s\n" "$ac_cv_search_SHA256Update" >&6; } 14606ac_res=$ac_cv_search_SHA256Update 14607if test "$ac_res" != no 14608then : 14609 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" 14610 14611fi 14612 14613 14614# "Particular Function Checks" 14615# see https://www.gnu.org/software/autoconf/manual/autoconf-2.69/html_node/Particular-Functions.html 14616 14617 for ac_func in strftime 14618do : 14619 ac_fn_c_check_func "$LINENO" "strftime" "ac_cv_func_strftime" 14620if test "x$ac_cv_func_strftime" = xyes 14621then : 14622 printf "%s\n" "#define HAVE_STRFTIME 1" >>confdefs.h 14623 14624else $as_nop 14625 # strftime is in -lintl on SCO UNIX. 14626{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for strftime in -lintl" >&5 14627printf %s "checking for strftime in -lintl... " >&6; } 14628if test ${ac_cv_lib_intl_strftime+y} 14629then : 14630 printf %s "(cached) " >&6 14631else $as_nop 14632 ac_check_lib_save_LIBS=$LIBS 14633LIBS="-lintl $LIBS" 14634cat confdefs.h - <<_ACEOF >conftest.$ac_ext 14635/* end confdefs.h. */ 14636 14637/* Override any GCC internal prototype to avoid an error. 14638 Use char because int might match the return type of a GCC 14639 builtin and then its argument prototype would still apply. */ 14640char strftime (); 14641int 14642main (void) 14643{ 14644return strftime (); 14645 ; 14646 return 0; 14647} 14648_ACEOF 14649if ac_fn_c_try_link "$LINENO" 14650then : 14651 ac_cv_lib_intl_strftime=yes 14652else $as_nop 14653 ac_cv_lib_intl_strftime=no 14654fi 14655rm -f core conftest.err conftest.$ac_objext conftest.beam \ 14656 conftest$ac_exeext conftest.$ac_ext 14657LIBS=$ac_check_lib_save_LIBS 14658fi 14659{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_strftime" >&5 14660printf "%s\n" "$ac_cv_lib_intl_strftime" >&6; } 14661if test "x$ac_cv_lib_intl_strftime" = xyes 14662then : 14663 printf "%s\n" "#define HAVE_STRFTIME 1" >>confdefs.h 14664 14665LIBS="-lintl $LIBS" 14666fi 14667 14668fi 14669 14670done 14671{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GNU libc compatible malloc" >&5 14672printf %s "checking for GNU libc compatible malloc... " >&6; } 14673if test ${ac_cv_func_malloc_0_nonnull+y} 14674then : 14675 printf %s "(cached) " >&6 14676else $as_nop 14677 if test "$cross_compiling" = yes 14678then : 14679 case "$host_os" in # (( 14680 # Guess yes on platforms where we know the result. 14681 *-gnu* | freebsd* | netbsd* | openbsd* | bitrig* \ 14682 | hpux* | solaris* | cygwin* | mingw* | msys* ) 14683 ac_cv_func_malloc_0_nonnull=yes ;; 14684 # If we don't know, assume the worst. 14685 *) ac_cv_func_malloc_0_nonnull=no ;; 14686 esac 14687else $as_nop 14688 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 14689/* end confdefs.h. */ 14690#include <stdlib.h> 14691 14692int 14693main (void) 14694{ 14695void *p = malloc (0); 14696 int result = !p; 14697 free (p); 14698 return result; 14699 ; 14700 return 0; 14701} 14702_ACEOF 14703if ac_fn_c_try_run "$LINENO" 14704then : 14705 ac_cv_func_malloc_0_nonnull=yes 14706else $as_nop 14707 ac_cv_func_malloc_0_nonnull=no 14708fi 14709rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 14710 conftest.$ac_objext conftest.beam conftest.$ac_ext 14711fi 14712 14713fi 14714{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_malloc_0_nonnull" >&5 14715printf "%s\n" "$ac_cv_func_malloc_0_nonnull" >&6; } 14716if test $ac_cv_func_malloc_0_nonnull = yes 14717then : 14718 14719printf "%s\n" "#define HAVE_MALLOC 1" >>confdefs.h 14720 14721else $as_nop 14722 printf "%s\n" "#define HAVE_MALLOC 0" >>confdefs.h 14723 14724 case " $LIBOBJS " in 14725 *" malloc.$ac_objext "* ) ;; 14726 *) LIBOBJS="$LIBOBJS malloc.$ac_objext" 14727 ;; 14728esac 14729 14730 14731printf "%s\n" "#define malloc rpl_malloc" >>confdefs.h 14732 14733fi 14734 14735 14736{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GNU libc compatible realloc" >&5 14737printf %s "checking for GNU libc compatible realloc... " >&6; } 14738if test ${ac_cv_func_realloc_0_nonnull+y} 14739then : 14740 printf %s "(cached) " >&6 14741else $as_nop 14742 if test "$cross_compiling" = yes 14743then : 14744 case "$host_os" in # (( 14745 # Guess yes on platforms where we know the result. 14746 *-gnu* | freebsd* | netbsd* | openbsd* | bitrig* \ 14747 | hpux* | solaris* | cygwin* | mingw* | msys* ) 14748 ac_cv_func_realloc_0_nonnull=yes ;; 14749 # If we don't know, assume the worst. 14750 *) ac_cv_func_realloc_0_nonnull=no ;; 14751 esac 14752else $as_nop 14753 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 14754/* end confdefs.h. */ 14755#include <stdlib.h> 14756 14757int 14758main (void) 14759{ 14760void *p = realloc (0, 0); 14761 int result = !p; 14762 free (p); 14763 return result; 14764 ; 14765 return 0; 14766} 14767_ACEOF 14768if ac_fn_c_try_run "$LINENO" 14769then : 14770 ac_cv_func_realloc_0_nonnull=yes 14771else $as_nop 14772 ac_cv_func_realloc_0_nonnull=no 14773fi 14774rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 14775 conftest.$ac_objext conftest.beam conftest.$ac_ext 14776fi 14777 14778fi 14779{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_realloc_0_nonnull" >&5 14780printf "%s\n" "$ac_cv_func_realloc_0_nonnull" >&6; } 14781if test $ac_cv_func_realloc_0_nonnull = yes 14782then : 14783 14784printf "%s\n" "#define HAVE_REALLOC 1" >>confdefs.h 14785 14786else $as_nop 14787 printf "%s\n" "#define HAVE_REALLOC 0" >>confdefs.h 14788 14789 case " $LIBOBJS " in 14790 *" realloc.$ac_objext "* ) ;; 14791 *) LIBOBJS="$LIBOBJS realloc.$ac_objext" 14792 ;; 14793esac 14794 14795 14796printf "%s\n" "#define realloc rpl_realloc" >>confdefs.h 14797 14798fi 14799 14800 14801# autoconf doesn't have AC_FUNC_CALLOC so fake it if malloc returns NULL; 14802{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if calloc(0, N) returns non-null" >&5 14803printf %s "checking if calloc(0, N) returns non-null... " >&6; } 14804if test "$cross_compiling" = yes 14805then : 14806 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: assuming same as malloc" >&5 14807printf "%s\n" "$as_me: WARNING: cross compiling: assuming same as malloc" >&2;} 14808 func_calloc_0_nonnull="$ac_cv_func_malloc_0_nonnull" 14809 14810else $as_nop 14811 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 14812/* end confdefs.h. */ 14813 #include <stdlib.h> 14814int 14815main (void) 14816{ 14817 void *p = calloc(0, 1); exit(p == NULL); 14818 14819 ; 14820 return 0; 14821} 14822_ACEOF 14823if ac_fn_c_try_run "$LINENO" 14824then : 14825 func_calloc_0_nonnull=yes 14826else $as_nop 14827 func_calloc_0_nonnull=no 14828fi 14829rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 14830 conftest.$ac_objext conftest.beam conftest.$ac_ext 14831fi 14832 14833{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $func_calloc_0_nonnull" >&5 14834printf "%s\n" "$func_calloc_0_nonnull" >&6; } 14835 14836if test "x$func_calloc_0_nonnull" = "xyes"; then 14837 14838printf "%s\n" "#define HAVE_CALLOC 1" >>confdefs.h 14839 14840else 14841 14842printf "%s\n" "#define HAVE_CALLOC 0" >>confdefs.h 14843 14844 14845printf "%s\n" "#define calloc rpl_calloc" >>confdefs.h 14846 14847fi 14848 14849# Check for ALTDIRFUNC glob() extension 14850{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GLOB_ALTDIRFUNC support" >&5 14851printf %s "checking for GLOB_ALTDIRFUNC support... " >&6; } 14852 14853cat confdefs.h - <<_ACEOF >conftest.$ac_ext 14854/* end confdefs.h. */ 14855 14856 #include <glob.h> 14857 #ifdef GLOB_ALTDIRFUNC 14858 FOUNDIT 14859 #endif 14860 14861_ACEOF 14862if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 14863 $EGREP "FOUNDIT" >/dev/null 2>&1 14864then : 14865 14866 14867printf "%s\n" "#define GLOB_HAS_ALTDIRFUNC 1" >>confdefs.h 14868 14869 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 14870printf "%s\n" "yes" >&6; } 14871 14872else $as_nop 14873 14874 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 14875printf "%s\n" "no" >&6; } 14876 14877 14878fi 14879rm -rf conftest* 14880 14881 14882# Check for g.gl_matchc glob() extension 14883{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gl_matchc field in glob_t" >&5 14884printf %s "checking for gl_matchc field in glob_t... " >&6; } 14885cat confdefs.h - <<_ACEOF >conftest.$ac_ext 14886/* end confdefs.h. */ 14887 #include <glob.h> 14888int 14889main (void) 14890{ 14891 glob_t g; g.gl_matchc = 1; 14892 ; 14893 return 0; 14894} 14895_ACEOF 14896if ac_fn_c_try_compile "$LINENO" 14897then : 14898 14899 14900printf "%s\n" "#define GLOB_HAS_GL_MATCHC 1" >>confdefs.h 14901 14902 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 14903printf "%s\n" "yes" >&6; } 14904 14905else $as_nop 14906 14907 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 14908printf "%s\n" "no" >&6; } 14909 14910fi 14911rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 14912 14913# Check for g.gl_statv glob() extension 14914{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gl_statv and GLOB_KEEPSTAT extensions for glob" >&5 14915printf %s "checking for gl_statv and GLOB_KEEPSTAT extensions for glob... " >&6; } 14916cat confdefs.h - <<_ACEOF >conftest.$ac_ext 14917/* end confdefs.h. */ 14918 #include <glob.h> 14919int 14920main (void) 14921{ 14922 14923#ifndef GLOB_KEEPSTAT 14924#error "glob does not support GLOB_KEEPSTAT extension" 14925#endif 14926glob_t g; 14927g.gl_statv = NULL; 14928 14929 ; 14930 return 0; 14931} 14932_ACEOF 14933if ac_fn_c_try_compile "$LINENO" 14934then : 14935 14936 14937printf "%s\n" "#define GLOB_HAS_GL_STATV 1" >>confdefs.h 14938 14939 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 14940printf "%s\n" "yes" >&6; } 14941 14942else $as_nop 14943 14944 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 14945printf "%s\n" "no" >&6; } 14946 14947 14948fi 14949rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 14950 14951ac_fn_check_decl "$LINENO" "GLOB_NOMATCH" "ac_cv_have_decl_GLOB_NOMATCH" "#include <glob.h> 14952" "$ac_c_undeclared_builtin_options" "CFLAGS" 14953if test "x$ac_cv_have_decl_GLOB_NOMATCH" = xyes 14954then : 14955 ac_have_decl=1 14956else $as_nop 14957 ac_have_decl=0 14958fi 14959printf "%s\n" "#define HAVE_DECL_GLOB_NOMATCH $ac_have_decl" >>confdefs.h 14960 14961 14962ac_fn_check_decl "$LINENO" "VIS_ALL" "ac_cv_have_decl_VIS_ALL" "#include <vis.h> 14963" "$ac_c_undeclared_builtin_options" "CFLAGS" 14964if test "x$ac_cv_have_decl_VIS_ALL" = xyes 14965then : 14966 14967else $as_nop 14968 14969printf "%s\n" "#define BROKEN_STRNVIS 1" >>confdefs.h 14970 14971fi 14972 14973{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether struct dirent allocates space for d_name" >&5 14974printf %s "checking whether struct dirent allocates space for d_name... " >&6; } 14975if test "$cross_compiling" = yes 14976then : 14977 14978 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: assuming BROKEN_ONE_BYTE_DIRENT_D_NAME" >&5 14979printf "%s\n" "$as_me: WARNING: cross compiling: assuming BROKEN_ONE_BYTE_DIRENT_D_NAME" >&2;} 14980 printf "%s\n" "#define BROKEN_ONE_BYTE_DIRENT_D_NAME 1" >>confdefs.h 14981 14982 14983 14984else $as_nop 14985 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 14986/* end confdefs.h. */ 14987 14988#include <sys/types.h> 14989#include <dirent.h> 14990#include <stdlib.h> 14991 14992int 14993main (void) 14994{ 14995 14996 struct dirent d; 14997 exit(sizeof(d.d_name)<=sizeof(char)); 14998 14999 ; 15000 return 0; 15001} 15002_ACEOF 15003if ac_fn_c_try_run "$LINENO" 15004then : 15005 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 15006printf "%s\n" "yes" >&6; } 15007else $as_nop 15008 15009 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 15010printf "%s\n" "no" >&6; } 15011 15012printf "%s\n" "#define BROKEN_ONE_BYTE_DIRENT_D_NAME 1" >>confdefs.h 15013 15014 15015fi 15016rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 15017 conftest.$ac_objext conftest.beam conftest.$ac_ext 15018fi 15019 15020 15021{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for /proc/pid/fd directory" >&5 15022printf %s "checking for /proc/pid/fd directory... " >&6; } 15023if test -d "/proc/$$/fd" ; then 15024 15025printf "%s\n" "#define HAVE_PROC_PID 1" >>confdefs.h 15026 15027 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 15028printf "%s\n" "yes" >&6; } 15029else 15030 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 15031printf "%s\n" "no" >&6; } 15032fi 15033 15034# Check whether user wants to use ldns 15035LDNS_MSG="no" 15036 15037# Check whether --with-ldns was given. 15038if test ${with_ldns+y} 15039then : 15040 withval=$with_ldns; 15041 ldns="" 15042 if test "x$withval" = "xyes" ; then 15043 if test -n "$ac_tool_prefix"; then 15044 # Extract the first word of "${ac_tool_prefix}ldns-config", so it can be a program name with args. 15045set dummy ${ac_tool_prefix}ldns-config; ac_word=$2 15046{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15047printf %s "checking for $ac_word... " >&6; } 15048if test ${ac_cv_path_LDNSCONFIG+y} 15049then : 15050 printf %s "(cached) " >&6 15051else $as_nop 15052 case $LDNSCONFIG in 15053 [\\/]* | ?:[\\/]*) 15054 ac_cv_path_LDNSCONFIG="$LDNSCONFIG" # Let the user override the test with a path. 15055 ;; 15056 *) 15057 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15058for as_dir in $PATH 15059do 15060 IFS=$as_save_IFS 15061 case $as_dir in #((( 15062 '') as_dir=./ ;; 15063 */) ;; 15064 *) as_dir=$as_dir/ ;; 15065 esac 15066 for ac_exec_ext in '' $ac_executable_extensions; do 15067 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 15068 ac_cv_path_LDNSCONFIG="$as_dir$ac_word$ac_exec_ext" 15069 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 15070 break 2 15071 fi 15072done 15073 done 15074IFS=$as_save_IFS 15075 15076 ;; 15077esac 15078fi 15079LDNSCONFIG=$ac_cv_path_LDNSCONFIG 15080if test -n "$LDNSCONFIG"; then 15081 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LDNSCONFIG" >&5 15082printf "%s\n" "$LDNSCONFIG" >&6; } 15083else 15084 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 15085printf "%s\n" "no" >&6; } 15086fi 15087 15088 15089fi 15090if test -z "$ac_cv_path_LDNSCONFIG"; then 15091 ac_pt_LDNSCONFIG=$LDNSCONFIG 15092 # Extract the first word of "ldns-config", so it can be a program name with args. 15093set dummy ldns-config; ac_word=$2 15094{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15095printf %s "checking for $ac_word... " >&6; } 15096if test ${ac_cv_path_ac_pt_LDNSCONFIG+y} 15097then : 15098 printf %s "(cached) " >&6 15099else $as_nop 15100 case $ac_pt_LDNSCONFIG in 15101 [\\/]* | ?:[\\/]*) 15102 ac_cv_path_ac_pt_LDNSCONFIG="$ac_pt_LDNSCONFIG" # Let the user override the test with a path. 15103 ;; 15104 *) 15105 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15106for as_dir in $PATH 15107do 15108 IFS=$as_save_IFS 15109 case $as_dir in #((( 15110 '') as_dir=./ ;; 15111 */) ;; 15112 *) as_dir=$as_dir/ ;; 15113 esac 15114 for ac_exec_ext in '' $ac_executable_extensions; do 15115 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 15116 ac_cv_path_ac_pt_LDNSCONFIG="$as_dir$ac_word$ac_exec_ext" 15117 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 15118 break 2 15119 fi 15120done 15121 done 15122IFS=$as_save_IFS 15123 15124 ;; 15125esac 15126fi 15127ac_pt_LDNSCONFIG=$ac_cv_path_ac_pt_LDNSCONFIG 15128if test -n "$ac_pt_LDNSCONFIG"; then 15129 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_pt_LDNSCONFIG" >&5 15130printf "%s\n" "$ac_pt_LDNSCONFIG" >&6; } 15131else 15132 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 15133printf "%s\n" "no" >&6; } 15134fi 15135 15136 if test "x$ac_pt_LDNSCONFIG" = x; then 15137 LDNSCONFIG="no" 15138 else 15139 case $cross_compiling:$ac_tool_warned in 15140yes:) 15141{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 15142printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 15143ac_tool_warned=yes ;; 15144esac 15145 LDNSCONFIG=$ac_pt_LDNSCONFIG 15146 fi 15147else 15148 LDNSCONFIG="$ac_cv_path_LDNSCONFIG" 15149fi 15150 15151 if test "x$LDNSCONFIG" = "xno"; then 15152 LIBS="-lldns $LIBS" 15153 ldns=yes 15154 else 15155 LIBS="$LIBS `$LDNSCONFIG --libs`" 15156 CPPFLAGS="$CPPFLAGS `$LDNSCONFIG --cflags`" 15157 ldns=yes 15158 fi 15159 elif test "x$withval" != "xno" ; then 15160 CPPFLAGS="$CPPFLAGS -I${withval}/include" 15161 LDFLAGS="$LDFLAGS -L${withval}/lib" 15162 LIBS="-lldns $LIBS" 15163 ldns=yes 15164 fi 15165 15166 # Verify that it works. 15167 if test "x$ldns" = "xyes" ; then 15168 15169printf "%s\n" "#define HAVE_LDNS 1" >>confdefs.h 15170 15171 LDNS_MSG="yes" 15172 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ldns support" >&5 15173printf %s "checking for ldns support... " >&6; } 15174 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 15175/* end confdefs.h. */ 15176 15177#include <stdio.h> 15178#include <stdlib.h> 15179#ifdef HAVE_STDINT_H 15180# include <stdint.h> 15181#endif 15182#include <ldns/ldns.h> 15183int main(void) { ldns_status status = ldns_verify_trusted(NULL, NULL, NULL, NULL); status=LDNS_STATUS_OK; exit(0); } 15184 15185 15186_ACEOF 15187if ac_fn_c_try_link "$LINENO" 15188then : 15189 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 15190printf "%s\n" "yes" >&6; } 15191else $as_nop 15192 15193 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 15194printf "%s\n" "no" >&6; } 15195 as_fn_error $? "** Incomplete or missing ldns libraries." "$LINENO" 5 15196 15197fi 15198rm -f core conftest.err conftest.$ac_objext conftest.beam \ 15199 conftest$ac_exeext conftest.$ac_ext 15200 fi 15201 15202fi 15203 15204 15205# Check whether user wants libedit support 15206LIBEDIT_MSG="no" 15207 15208# Check whether --with-libedit was given. 15209if test ${with_libedit+y} 15210then : 15211 withval=$with_libedit; if test "x$withval" != "xno" ; then 15212 if test "x$withval" = "xyes" ; then 15213 if test "x$PKGCONFIG" != "xno"; then 15214 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $PKGCONFIG knows about libedit" >&5 15215printf %s "checking if $PKGCONFIG knows about libedit... " >&6; } 15216 if "$PKGCONFIG" libedit; then 15217 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 15218printf "%s\n" "yes" >&6; } 15219 use_pkgconfig_for_libedit=yes 15220 else 15221 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 15222printf "%s\n" "no" >&6; } 15223 fi 15224 fi 15225 else 15226 CPPFLAGS="$CPPFLAGS -I${withval}/include" 15227 if test -n "${rpath_opt}"; then 15228 LDFLAGS="-L${withval}/lib ${rpath_opt}${withval}/lib ${LDFLAGS}" 15229 else 15230 LDFLAGS="-L${withval}/lib ${LDFLAGS}" 15231 fi 15232 fi 15233 if test "x$use_pkgconfig_for_libedit" = "xyes"; then 15234 LIBEDIT=`$PKGCONFIG --libs libedit` 15235 CPPFLAGS="$CPPFLAGS `$PKGCONFIG --cflags libedit`" 15236 else 15237 LIBEDIT="-ledit -lcurses" 15238 fi 15239 OTHERLIBS=`echo $LIBEDIT | sed 's/-ledit//'` 15240 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for el_init in -ledit" >&5 15241printf %s "checking for el_init in -ledit... " >&6; } 15242if test ${ac_cv_lib_edit_el_init+y} 15243then : 15244 printf %s "(cached) " >&6 15245else $as_nop 15246 ac_check_lib_save_LIBS=$LIBS 15247LIBS="-ledit $OTHERLIBS 15248 $LIBS" 15249cat confdefs.h - <<_ACEOF >conftest.$ac_ext 15250/* end confdefs.h. */ 15251 15252/* Override any GCC internal prototype to avoid an error. 15253 Use char because int might match the return type of a GCC 15254 builtin and then its argument prototype would still apply. */ 15255char el_init (); 15256int 15257main (void) 15258{ 15259return el_init (); 15260 ; 15261 return 0; 15262} 15263_ACEOF 15264if ac_fn_c_try_link "$LINENO" 15265then : 15266 ac_cv_lib_edit_el_init=yes 15267else $as_nop 15268 ac_cv_lib_edit_el_init=no 15269fi 15270rm -f core conftest.err conftest.$ac_objext conftest.beam \ 15271 conftest$ac_exeext conftest.$ac_ext 15272LIBS=$ac_check_lib_save_LIBS 15273fi 15274{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_edit_el_init" >&5 15275printf "%s\n" "$ac_cv_lib_edit_el_init" >&6; } 15276if test "x$ac_cv_lib_edit_el_init" = xyes 15277then : 15278 15279printf "%s\n" "#define USE_LIBEDIT 1" >>confdefs.h 15280 15281 LIBEDIT_MSG="yes" 15282 15283 15284else $as_nop 15285 as_fn_error $? "libedit not found" "$LINENO" 5 15286fi 15287 15288 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if libedit version is compatible" >&5 15289printf %s "checking if libedit version is compatible... " >&6; } 15290 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 15291/* end confdefs.h. */ 15292 15293#include <histedit.h> 15294#include <stdlib.h> 15295 15296int 15297main (void) 15298{ 15299 15300 int i = H_SETSIZE; 15301 el_init("", NULL, NULL, NULL); 15302 exit(0); 15303 15304 ; 15305 return 0; 15306} 15307_ACEOF 15308if ac_fn_c_try_compile "$LINENO" 15309then : 15310 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 15311printf "%s\n" "yes" >&6; } 15312else $as_nop 15313 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 15314printf "%s\n" "no" >&6; } 15315 as_fn_error $? "libedit version is not compatible" "$LINENO" 5 15316 15317fi 15318rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 15319 fi 15320 15321fi 15322 15323 15324AUDIT_MODULE=none 15325 15326# Check whether --with-audit was given. 15327if test ${with_audit+y} 15328then : 15329 withval=$with_audit; 15330 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for supported audit module" >&5 15331printf %s "checking for supported audit module... " >&6; } 15332 case "$withval" in 15333 bsm) 15334 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: bsm" >&5 15335printf "%s\n" "bsm" >&6; } 15336 AUDIT_MODULE=bsm 15337 for ac_header in bsm/audit.h 15338do : 15339 ac_fn_c_check_header_compile "$LINENO" "bsm/audit.h" "ac_cv_header_bsm_audit_h" " 15340#ifdef HAVE_TIME_H 15341# include <time.h> 15342#endif 15343 15344 15345" 15346if test "x$ac_cv_header_bsm_audit_h" = xyes 15347then : 15348 printf "%s\n" "#define HAVE_BSM_AUDIT_H 1" >>confdefs.h 15349 15350else $as_nop 15351 as_fn_error $? "BSM enabled and bsm/audit.h not found" "$LINENO" 5 15352fi 15353 15354done 15355 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for getaudit in -lbsm" >&5 15356printf %s "checking for getaudit in -lbsm... " >&6; } 15357if test ${ac_cv_lib_bsm_getaudit+y} 15358then : 15359 printf %s "(cached) " >&6 15360else $as_nop 15361 ac_check_lib_save_LIBS=$LIBS 15362LIBS="-lbsm $LIBS" 15363cat confdefs.h - <<_ACEOF >conftest.$ac_ext 15364/* end confdefs.h. */ 15365 15366/* Override any GCC internal prototype to avoid an error. 15367 Use char because int might match the return type of a GCC 15368 builtin and then its argument prototype would still apply. */ 15369char getaudit (); 15370int 15371main (void) 15372{ 15373return getaudit (); 15374 ; 15375 return 0; 15376} 15377_ACEOF 15378if ac_fn_c_try_link "$LINENO" 15379then : 15380 ac_cv_lib_bsm_getaudit=yes 15381else $as_nop 15382 ac_cv_lib_bsm_getaudit=no 15383fi 15384rm -f core conftest.err conftest.$ac_objext conftest.beam \ 15385 conftest$ac_exeext conftest.$ac_ext 15386LIBS=$ac_check_lib_save_LIBS 15387fi 15388{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsm_getaudit" >&5 15389printf "%s\n" "$ac_cv_lib_bsm_getaudit" >&6; } 15390if test "x$ac_cv_lib_bsm_getaudit" = xyes 15391then : 15392 printf "%s\n" "#define HAVE_LIBBSM 1" >>confdefs.h 15393 15394 LIBS="-lbsm $LIBS" 15395 15396else $as_nop 15397 as_fn_error $? "BSM enabled and required library not found" "$LINENO" 5 15398fi 15399 15400 15401 for ac_func in getaudit 15402do : 15403 ac_fn_c_check_func "$LINENO" "getaudit" "ac_cv_func_getaudit" 15404if test "x$ac_cv_func_getaudit" = xyes 15405then : 15406 printf "%s\n" "#define HAVE_GETAUDIT 1" >>confdefs.h 15407 15408else $as_nop 15409 as_fn_error $? "BSM enabled and required function not found" "$LINENO" 5 15410fi 15411 15412done 15413 # These are optional 15414 ac_fn_c_check_func "$LINENO" "getaudit_addr" "ac_cv_func_getaudit_addr" 15415if test "x$ac_cv_func_getaudit_addr" = xyes 15416then : 15417 printf "%s\n" "#define HAVE_GETAUDIT_ADDR 1" >>confdefs.h 15418 15419fi 15420ac_fn_c_check_func "$LINENO" "aug_get_machine" "ac_cv_func_aug_get_machine" 15421if test "x$ac_cv_func_aug_get_machine" = xyes 15422then : 15423 printf "%s\n" "#define HAVE_AUG_GET_MACHINE 1" >>confdefs.h 15424 15425fi 15426 15427 15428printf "%s\n" "#define USE_BSM_AUDIT 1" >>confdefs.h 15429 15430 if test "$sol2ver" -ge 11; then 15431 SSHDLIBS="$SSHDLIBS -lscf" 15432 15433printf "%s\n" "#define BROKEN_BSM_API 1" >>confdefs.h 15434 15435 fi 15436 ;; 15437 linux) 15438 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: linux" >&5 15439printf "%s\n" "linux" >&6; } 15440 AUDIT_MODULE=linux 15441 ac_fn_c_check_header_compile "$LINENO" "libaudit.h" "ac_cv_header_libaudit_h" "$ac_includes_default" 15442if test "x$ac_cv_header_libaudit_h" = xyes 15443then : 15444 printf "%s\n" "#define HAVE_LIBAUDIT_H 1" >>confdefs.h 15445 15446fi 15447 15448 SSHDLIBS="$SSHDLIBS -laudit" 15449 15450printf "%s\n" "#define USE_LINUX_AUDIT 1" >>confdefs.h 15451 15452 ;; 15453 debug) 15454 AUDIT_MODULE=debug 15455 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: debug" >&5 15456printf "%s\n" "debug" >&6; } 15457 15458printf "%s\n" "#define SSH_AUDIT_EVENTS 1" >>confdefs.h 15459 15460 ;; 15461 no) 15462 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 15463printf "%s\n" "no" >&6; } 15464 ;; 15465 *) 15466 as_fn_error $? "Unknown audit module $withval" "$LINENO" 5 15467 ;; 15468 esac 15469 15470fi 15471 15472 15473 15474# Check whether --with-pie was given. 15475if test ${with_pie+y} 15476then : 15477 withval=$with_pie; 15478 if test "x$withval" = "xno"; then 15479 use_pie=no 15480 fi 15481 if test "x$withval" = "xyes"; then 15482 use_pie=yes 15483 fi 15484 15485 15486fi 15487 15488if test "x$use_pie" = "x"; then 15489 use_pie=no 15490fi 15491if test "x$use_toolchain_hardening" != "x1" && test "x$use_pie" = "xauto"; then 15492 # Turn off automatic PIE when toolchain hardening is off. 15493 use_pie=no 15494fi 15495if test "x$use_pie" = "xauto"; then 15496 # Automatic PIE requires gcc >= 4.x 15497 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gcc >= 4.x" >&5 15498printf %s "checking for gcc >= 4.x... " >&6; } 15499 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 15500/* end confdefs.h. */ 15501 15502#if !defined(__GNUC__) || __GNUC__ < 4 15503#error gcc is too old 15504#endif 15505 15506_ACEOF 15507if ac_fn_c_try_compile "$LINENO" 15508then : 15509 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 15510printf "%s\n" "yes" >&6; } 15511else $as_nop 15512 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 15513printf "%s\n" "no" >&6; } 15514 use_pie=no 15515 15516fi 15517rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 15518fi 15519if test "x$use_pie" != "xno"; then 15520 SAVED_CFLAGS="$CFLAGS" 15521 SAVED_LDFLAGS="$LDFLAGS" 15522 { 15523 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $CC supports compile flag -fPIE" >&5 15524printf %s "checking if $CC supports compile flag -fPIE... " >&6; } 15525 saved_CFLAGS="$CFLAGS" 15526 CFLAGS="$CFLAGS $WERROR -fPIE" 15527 _define_flag="" 15528 test "x$_define_flag" = "x" && _define_flag="-fPIE" 15529 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 15530/* end confdefs.h. */ 15531 15532#include <stdlib.h> 15533#include <stdarg.h> 15534#include <stdio.h> 15535#include <string.h> 15536#include <unistd.h> 15537/* Trivial function to help test for -fzero-call-used-regs */ 15538int f(int n) {return rand() % n;} 15539char *f2(char *s, ...) { 15540 char ret[64]; 15541 va_list args; 15542 va_start(args, s); 15543 vsnprintf(ret, sizeof(ret), s, args); 15544 va_end(args); 15545 return strdup(ret); 15546} 15547int i; 15548double d; 15549const char *f3(int s) { 15550 i = (int)d; 15551 return s ? "good" : "gooder"; 15552} 15553int main(int argc, char **argv) { 15554 char b[256], *cp; 15555 const char *s; 15556 /* Some math to catch -ftrapv problems in the toolchain */ 15557 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 15558 float l = i * 2.1; 15559 double m = l / 0.5; 15560 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 15561 (void)argv; 15562 f(1); 15563 s = f3(f(2)); 15564 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 15565 if (write(1, b, 0) == -1) exit(0); 15566 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 15567 if (write(1, cp, 0) == -1) exit(0); 15568 free(cp); 15569 /* 15570 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 15571 * not understand comments and we don't use the "fallthrough" attribute 15572 * that it's looking for. 15573 */ 15574 switch(i){ 15575 case 0: j += i; 15576 /* FALLTHROUGH */ 15577 default: j += k; 15578 } 15579 exit(0); 15580} 15581 15582 15583_ACEOF 15584if ac_fn_c_try_compile "$LINENO" 15585then : 15586 15587if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 15588then 15589 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 15590printf "%s\n" "no" >&6; } 15591 CFLAGS="$saved_CFLAGS" 15592else 15593 if test "$cross_compiling" = yes 15594then : 15595 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 15596printf "%s\n" "yes" >&6; } 15597 CFLAGS="$saved_CFLAGS $_define_flag" 15598else $as_nop 15599 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 15600/* end confdefs.h. */ 15601 15602#include <stdlib.h> 15603#include <stdarg.h> 15604#include <stdio.h> 15605#include <string.h> 15606#include <unistd.h> 15607/* Trivial function to help test for -fzero-call-used-regs */ 15608int f(int n) {return rand() % n;} 15609char *f2(char *s, ...) { 15610 char ret[64]; 15611 va_list args; 15612 va_start(args, s); 15613 vsnprintf(ret, sizeof(ret), s, args); 15614 va_end(args); 15615 return strdup(ret); 15616} 15617int i; 15618double d; 15619const char *f3(int s) { 15620 i = (int)d; 15621 return s ? "good" : "gooder"; 15622} 15623int main(int argc, char **argv) { 15624 char b[256], *cp; 15625 const char *s; 15626 /* Some math to catch -ftrapv problems in the toolchain */ 15627 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 15628 float l = i * 2.1; 15629 double m = l / 0.5; 15630 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 15631 (void)argv; 15632 f(1); 15633 s = f3(f(2)); 15634 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 15635 if (write(1, b, 0) == -1) exit(0); 15636 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 15637 if (write(1, cp, 0) == -1) exit(0); 15638 free(cp); 15639 /* 15640 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 15641 * not understand comments and we don't use the "fallthrough" attribute 15642 * that it's looking for. 15643 */ 15644 switch(i){ 15645 case 0: j += i; 15646 /* FALLTHROUGH */ 15647 default: j += k; 15648 } 15649 exit(0); 15650} 15651 15652 15653_ACEOF 15654if ac_fn_c_try_run "$LINENO" 15655then : 15656 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 15657printf "%s\n" "yes" >&6; } 15658 CFLAGS="$saved_CFLAGS $_define_flag" 15659else $as_nop 15660 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 15661printf "%s\n" "no, fails at run time" >&6; } 15662 CFLAGS="$saved_CFLAGS" 15663fi 15664rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 15665 conftest.$ac_objext conftest.beam conftest.$ac_ext 15666fi 15667 15668fi 15669else $as_nop 15670 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 15671printf "%s\n" "no" >&6; } 15672 CFLAGS="$saved_CFLAGS" 15673 15674fi 15675rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 15676} 15677 { 15678 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $LD supports link flag -pie" >&5 15679printf %s "checking if $LD supports link flag -pie... " >&6; } 15680 saved_LDFLAGS="$LDFLAGS" 15681 LDFLAGS="$LDFLAGS $WERROR -pie" 15682 _define_flag="" 15683 test "x$_define_flag" = "x" && _define_flag="-pie" 15684 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 15685/* end confdefs.h. */ 15686 15687#include <stdlib.h> 15688#include <stdarg.h> 15689#include <stdio.h> 15690#include <string.h> 15691#include <unistd.h> 15692/* Trivial function to help test for -fzero-call-used-regs */ 15693int f(int n) {return rand() % n;} 15694char *f2(char *s, ...) { 15695 char ret[64]; 15696 va_list args; 15697 va_start(args, s); 15698 vsnprintf(ret, sizeof(ret), s, args); 15699 va_end(args); 15700 return strdup(ret); 15701} 15702int i; 15703double d; 15704const char *f3(int s) { 15705 i = (int)d; 15706 return s ? "good" : "gooder"; 15707} 15708int main(int argc, char **argv) { 15709 char b[256], *cp; 15710 const char *s; 15711 /* Some math to catch -ftrapv problems in the toolchain */ 15712 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 15713 float l = i * 2.1; 15714 double m = l / 0.5; 15715 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 15716 (void)argv; 15717 f(1); 15718 s = f3(f(2)); 15719 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 15720 if (write(1, b, 0) == -1) exit(0); 15721 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 15722 if (write(1, cp, 0) == -1) exit(0); 15723 free(cp); 15724 /* 15725 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 15726 * not understand comments and we don't use the "fallthrough" attribute 15727 * that it's looking for. 15728 */ 15729 switch(i){ 15730 case 0: j += i; 15731 /* FALLTHROUGH */ 15732 default: j += k; 15733 } 15734 exit(0); 15735} 15736 15737 15738_ACEOF 15739if ac_fn_c_try_link "$LINENO" 15740then : 15741 15742if $ac_cv_path_EGREP -i "unrecognized option|warning.*ignored" conftest.err >/dev/null 15743then 15744 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 15745printf "%s\n" "no" >&6; } 15746 LDFLAGS="$saved_LDFLAGS" 15747else 15748 if test "$cross_compiling" = yes 15749then : 15750 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 15751printf "%s\n" "yes" >&6; } 15752 LDFLAGS="$saved_LDFLAGS $_define_flag" 15753 15754else $as_nop 15755 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 15756/* end confdefs.h. */ 15757 15758#include <stdlib.h> 15759#include <stdarg.h> 15760#include <stdio.h> 15761#include <string.h> 15762#include <unistd.h> 15763/* Trivial function to help test for -fzero-call-used-regs */ 15764int f(int n) {return rand() % n;} 15765char *f2(char *s, ...) { 15766 char ret[64]; 15767 va_list args; 15768 va_start(args, s); 15769 vsnprintf(ret, sizeof(ret), s, args); 15770 va_end(args); 15771 return strdup(ret); 15772} 15773int i; 15774double d; 15775const char *f3(int s) { 15776 i = (int)d; 15777 return s ? "good" : "gooder"; 15778} 15779int main(int argc, char **argv) { 15780 char b[256], *cp; 15781 const char *s; 15782 /* Some math to catch -ftrapv problems in the toolchain */ 15783 int i = 123 * argc, j = 456 + argc, k = 789 - argc; 15784 float l = i * 2.1; 15785 double m = l / 0.5; 15786 long long int n = argc * 12345LL, o = 12345LL * (long long int)argc; 15787 (void)argv; 15788 f(1); 15789 s = f3(f(2)); 15790 snprintf(b, sizeof b, "%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 15791 if (write(1, b, 0) == -1) exit(0); 15792 cp = f2("%d %d %d %f %f %lld %lld %s\n", i,j,k,l,m,n,o,s); 15793 if (write(1, cp, 0) == -1) exit(0); 15794 free(cp); 15795 /* 15796 * Test fallthrough behaviour. clang 10's -Wimplicit-fallthrough does 15797 * not understand comments and we don't use the "fallthrough" attribute 15798 * that it's looking for. 15799 */ 15800 switch(i){ 15801 case 0: j += i; 15802 /* FALLTHROUGH */ 15803 default: j += k; 15804 } 15805 exit(0); 15806} 15807 15808 15809_ACEOF 15810if ac_fn_c_try_run "$LINENO" 15811then : 15812 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 15813printf "%s\n" "yes" >&6; } 15814 LDFLAGS="$saved_LDFLAGS $_define_flag" 15815else $as_nop 15816 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no, fails at run time" >&5 15817printf "%s\n" "no, fails at run time" >&6; } 15818 LDFLAGS="$saved_LDFLAGS" 15819fi 15820rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 15821 conftest.$ac_objext conftest.beam conftest.$ac_ext 15822fi 15823 15824fi 15825else $as_nop 15826 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 15827printf "%s\n" "no" >&6; } 15828 LDFLAGS="$saved_LDFLAGS" 15829 15830fi 15831rm -f core conftest.err conftest.$ac_objext conftest.beam \ 15832 conftest$ac_exeext conftest.$ac_ext 15833} 15834 # We use both -fPIE and -pie or neither. 15835 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether both -fPIE and -pie are supported" >&5 15836printf %s "checking whether both -fPIE and -pie are supported... " >&6; } 15837 if echo "x $CFLAGS" | grep ' -fPIE' >/dev/null 2>&1 && \ 15838 echo "x $LDFLAGS" | grep ' -pie' >/dev/null 2>&1 ; then 15839 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 15840printf "%s\n" "yes" >&6; } 15841 else 15842 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 15843printf "%s\n" "no" >&6; } 15844 CFLAGS="$SAVED_CFLAGS" 15845 LDFLAGS="$SAVED_LDFLAGS" 15846 fi 15847fi 15848 15849{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether -fPIC is accepted" >&5 15850printf %s "checking whether -fPIC is accepted... " >&6; } 15851SAVED_CFLAGS="$CFLAGS" 15852CFLAGS="$CFLAGS -fPIC" 15853cat confdefs.h - <<_ACEOF >conftest.$ac_ext 15854/* end confdefs.h. */ 15855 #include <stdlib.h> 15856int 15857main (void) 15858{ 15859 exit(0); 15860 ; 15861 return 0; 15862} 15863_ACEOF 15864if ac_fn_c_try_compile "$LINENO" 15865then : 15866 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 15867printf "%s\n" "yes" >&6; } 15868 PICFLAG="-fPIC"; 15869else $as_nop 15870 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 15871printf "%s\n" "no" >&6; } 15872 PICFLAG=""; 15873fi 15874rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 15875CFLAGS="$SAVED_CFLAGS" 15876 15877 15878ac_fn_c_check_func "$LINENO" "Blowfish_initstate" "ac_cv_func_Blowfish_initstate" 15879if test "x$ac_cv_func_Blowfish_initstate" = xyes 15880then : 15881 printf "%s\n" "#define HAVE_BLOWFISH_INITSTATE 1" >>confdefs.h 15882 15883fi 15884ac_fn_c_check_func "$LINENO" "Blowfish_expandstate" "ac_cv_func_Blowfish_expandstate" 15885if test "x$ac_cv_func_Blowfish_expandstate" = xyes 15886then : 15887 printf "%s\n" "#define HAVE_BLOWFISH_EXPANDSTATE 1" >>confdefs.h 15888 15889fi 15890ac_fn_c_check_func "$LINENO" "Blowfish_expand0state" "ac_cv_func_Blowfish_expand0state" 15891if test "x$ac_cv_func_Blowfish_expand0state" = xyes 15892then : 15893 printf "%s\n" "#define HAVE_BLOWFISH_EXPAND0STATE 1" >>confdefs.h 15894 15895fi 15896ac_fn_c_check_func "$LINENO" "Blowfish_stream2word" "ac_cv_func_Blowfish_stream2word" 15897if test "x$ac_cv_func_Blowfish_stream2word" = xyes 15898then : 15899 printf "%s\n" "#define HAVE_BLOWFISH_STREAM2WORD 1" >>confdefs.h 15900 15901fi 15902ac_fn_c_check_func "$LINENO" "SHA256Update" "ac_cv_func_SHA256Update" 15903if test "x$ac_cv_func_SHA256Update" = xyes 15904then : 15905 printf "%s\n" "#define HAVE_SHA256UPDATE 1" >>confdefs.h 15906 15907fi 15908ac_fn_c_check_func "$LINENO" "SHA384Update" "ac_cv_func_SHA384Update" 15909if test "x$ac_cv_func_SHA384Update" = xyes 15910then : 15911 printf "%s\n" "#define HAVE_SHA384UPDATE 1" >>confdefs.h 15912 15913fi 15914ac_fn_c_check_func "$LINENO" "SHA512Update" "ac_cv_func_SHA512Update" 15915if test "x$ac_cv_func_SHA512Update" = xyes 15916then : 15917 printf "%s\n" "#define HAVE_SHA512UPDATE 1" >>confdefs.h 15918 15919fi 15920ac_fn_c_check_func "$LINENO" "asprintf" "ac_cv_func_asprintf" 15921if test "x$ac_cv_func_asprintf" = xyes 15922then : 15923 printf "%s\n" "#define HAVE_ASPRINTF 1" >>confdefs.h 15924 15925fi 15926ac_fn_c_check_func "$LINENO" "b64_ntop" "ac_cv_func_b64_ntop" 15927if test "x$ac_cv_func_b64_ntop" = xyes 15928then : 15929 printf "%s\n" "#define HAVE_B64_NTOP 1" >>confdefs.h 15930 15931fi 15932ac_fn_c_check_func "$LINENO" "__b64_ntop" "ac_cv_func___b64_ntop" 15933if test "x$ac_cv_func___b64_ntop" = xyes 15934then : 15935 printf "%s\n" "#define HAVE___B64_NTOP 1" >>confdefs.h 15936 15937fi 15938ac_fn_c_check_func "$LINENO" "b64_pton" "ac_cv_func_b64_pton" 15939if test "x$ac_cv_func_b64_pton" = xyes 15940then : 15941 printf "%s\n" "#define HAVE_B64_PTON 1" >>confdefs.h 15942 15943fi 15944ac_fn_c_check_func "$LINENO" "__b64_pton" "ac_cv_func___b64_pton" 15945if test "x$ac_cv_func___b64_pton" = xyes 15946then : 15947 printf "%s\n" "#define HAVE___B64_PTON 1" >>confdefs.h 15948 15949fi 15950ac_fn_c_check_func "$LINENO" "bcopy" "ac_cv_func_bcopy" 15951if test "x$ac_cv_func_bcopy" = xyes 15952then : 15953 printf "%s\n" "#define HAVE_BCOPY 1" >>confdefs.h 15954 15955fi 15956ac_fn_c_check_func "$LINENO" "bcrypt_pbkdf" "ac_cv_func_bcrypt_pbkdf" 15957if test "x$ac_cv_func_bcrypt_pbkdf" = xyes 15958then : 15959 printf "%s\n" "#define HAVE_BCRYPT_PBKDF 1" >>confdefs.h 15960 15961fi 15962ac_fn_c_check_func "$LINENO" "bindresvport_sa" "ac_cv_func_bindresvport_sa" 15963if test "x$ac_cv_func_bindresvport_sa" = xyes 15964then : 15965 printf "%s\n" "#define HAVE_BINDRESVPORT_SA 1" >>confdefs.h 15966 15967fi 15968ac_fn_c_check_func "$LINENO" "blf_enc" "ac_cv_func_blf_enc" 15969if test "x$ac_cv_func_blf_enc" = xyes 15970then : 15971 printf "%s\n" "#define HAVE_BLF_ENC 1" >>confdefs.h 15972 15973fi 15974ac_fn_c_check_func "$LINENO" "bzero" "ac_cv_func_bzero" 15975if test "x$ac_cv_func_bzero" = xyes 15976then : 15977 printf "%s\n" "#define HAVE_BZERO 1" >>confdefs.h 15978 15979fi 15980ac_fn_c_check_func "$LINENO" "cap_rights_limit" "ac_cv_func_cap_rights_limit" 15981if test "x$ac_cv_func_cap_rights_limit" = xyes 15982then : 15983 printf "%s\n" "#define HAVE_CAP_RIGHTS_LIMIT 1" >>confdefs.h 15984 15985fi 15986ac_fn_c_check_func "$LINENO" "clock" "ac_cv_func_clock" 15987if test "x$ac_cv_func_clock" = xyes 15988then : 15989 printf "%s\n" "#define HAVE_CLOCK 1" >>confdefs.h 15990 15991fi 15992ac_fn_c_check_func "$LINENO" "closefrom" "ac_cv_func_closefrom" 15993if test "x$ac_cv_func_closefrom" = xyes 15994then : 15995 printf "%s\n" "#define HAVE_CLOSEFROM 1" >>confdefs.h 15996 15997fi 15998ac_fn_c_check_func "$LINENO" "close_range" "ac_cv_func_close_range" 15999if test "x$ac_cv_func_close_range" = xyes 16000then : 16001 printf "%s\n" "#define HAVE_CLOSE_RANGE 1" >>confdefs.h 16002 16003fi 16004ac_fn_c_check_func "$LINENO" "dirfd" "ac_cv_func_dirfd" 16005if test "x$ac_cv_func_dirfd" = xyes 16006then : 16007 printf "%s\n" "#define HAVE_DIRFD 1" >>confdefs.h 16008 16009fi 16010ac_fn_c_check_func "$LINENO" "endgrent" "ac_cv_func_endgrent" 16011if test "x$ac_cv_func_endgrent" = xyes 16012then : 16013 printf "%s\n" "#define HAVE_ENDGRENT 1" >>confdefs.h 16014 16015fi 16016ac_fn_c_check_func "$LINENO" "err" "ac_cv_func_err" 16017if test "x$ac_cv_func_err" = xyes 16018then : 16019 printf "%s\n" "#define HAVE_ERR 1" >>confdefs.h 16020 16021fi 16022ac_fn_c_check_func "$LINENO" "errx" "ac_cv_func_errx" 16023if test "x$ac_cv_func_errx" = xyes 16024then : 16025 printf "%s\n" "#define HAVE_ERRX 1" >>confdefs.h 16026 16027fi 16028ac_fn_c_check_func "$LINENO" "explicit_bzero" "ac_cv_func_explicit_bzero" 16029if test "x$ac_cv_func_explicit_bzero" = xyes 16030then : 16031 printf "%s\n" "#define HAVE_EXPLICIT_BZERO 1" >>confdefs.h 16032 16033fi 16034ac_fn_c_check_func "$LINENO" "explicit_memset" "ac_cv_func_explicit_memset" 16035if test "x$ac_cv_func_explicit_memset" = xyes 16036then : 16037 printf "%s\n" "#define HAVE_EXPLICIT_MEMSET 1" >>confdefs.h 16038 16039fi 16040ac_fn_c_check_func "$LINENO" "fchmod" "ac_cv_func_fchmod" 16041if test "x$ac_cv_func_fchmod" = xyes 16042then : 16043 printf "%s\n" "#define HAVE_FCHMOD 1" >>confdefs.h 16044 16045fi 16046ac_fn_c_check_func "$LINENO" "fchmodat" "ac_cv_func_fchmodat" 16047if test "x$ac_cv_func_fchmodat" = xyes 16048then : 16049 printf "%s\n" "#define HAVE_FCHMODAT 1" >>confdefs.h 16050 16051fi 16052ac_fn_c_check_func "$LINENO" "fchown" "ac_cv_func_fchown" 16053if test "x$ac_cv_func_fchown" = xyes 16054then : 16055 printf "%s\n" "#define HAVE_FCHOWN 1" >>confdefs.h 16056 16057fi 16058ac_fn_c_check_func "$LINENO" "fchownat" "ac_cv_func_fchownat" 16059if test "x$ac_cv_func_fchownat" = xyes 16060then : 16061 printf "%s\n" "#define HAVE_FCHOWNAT 1" >>confdefs.h 16062 16063fi 16064ac_fn_c_check_func "$LINENO" "flock" "ac_cv_func_flock" 16065if test "x$ac_cv_func_flock" = xyes 16066then : 16067 printf "%s\n" "#define HAVE_FLOCK 1" >>confdefs.h 16068 16069fi 16070ac_fn_c_check_func "$LINENO" "fnmatch" "ac_cv_func_fnmatch" 16071if test "x$ac_cv_func_fnmatch" = xyes 16072then : 16073 printf "%s\n" "#define HAVE_FNMATCH 1" >>confdefs.h 16074 16075fi 16076ac_fn_c_check_func "$LINENO" "freeaddrinfo" "ac_cv_func_freeaddrinfo" 16077if test "x$ac_cv_func_freeaddrinfo" = xyes 16078then : 16079 printf "%s\n" "#define HAVE_FREEADDRINFO 1" >>confdefs.h 16080 16081fi 16082ac_fn_c_check_func "$LINENO" "freezero" "ac_cv_func_freezero" 16083if test "x$ac_cv_func_freezero" = xyes 16084then : 16085 printf "%s\n" "#define HAVE_FREEZERO 1" >>confdefs.h 16086 16087fi 16088ac_fn_c_check_func "$LINENO" "fstatfs" "ac_cv_func_fstatfs" 16089if test "x$ac_cv_func_fstatfs" = xyes 16090then : 16091 printf "%s\n" "#define HAVE_FSTATFS 1" >>confdefs.h 16092 16093fi 16094ac_fn_c_check_func "$LINENO" "fstatvfs" "ac_cv_func_fstatvfs" 16095if test "x$ac_cv_func_fstatvfs" = xyes 16096then : 16097 printf "%s\n" "#define HAVE_FSTATVFS 1" >>confdefs.h 16098 16099fi 16100ac_fn_c_check_func "$LINENO" "futimes" "ac_cv_func_futimes" 16101if test "x$ac_cv_func_futimes" = xyes 16102then : 16103 printf "%s\n" "#define HAVE_FUTIMES 1" >>confdefs.h 16104 16105fi 16106ac_fn_c_check_func "$LINENO" "getaddrinfo" "ac_cv_func_getaddrinfo" 16107if test "x$ac_cv_func_getaddrinfo" = xyes 16108then : 16109 printf "%s\n" "#define HAVE_GETADDRINFO 1" >>confdefs.h 16110 16111fi 16112ac_fn_c_check_func "$LINENO" "getcwd" "ac_cv_func_getcwd" 16113if test "x$ac_cv_func_getcwd" = xyes 16114then : 16115 printf "%s\n" "#define HAVE_GETCWD 1" >>confdefs.h 16116 16117fi 16118ac_fn_c_check_func "$LINENO" "getentropy" "ac_cv_func_getentropy" 16119if test "x$ac_cv_func_getentropy" = xyes 16120then : 16121 printf "%s\n" "#define HAVE_GETENTROPY 1" >>confdefs.h 16122 16123fi 16124ac_fn_c_check_func "$LINENO" "getgrouplist" "ac_cv_func_getgrouplist" 16125if test "x$ac_cv_func_getgrouplist" = xyes 16126then : 16127 printf "%s\n" "#define HAVE_GETGROUPLIST 1" >>confdefs.h 16128 16129fi 16130ac_fn_c_check_func "$LINENO" "getline" "ac_cv_func_getline" 16131if test "x$ac_cv_func_getline" = xyes 16132then : 16133 printf "%s\n" "#define HAVE_GETLINE 1" >>confdefs.h 16134 16135fi 16136ac_fn_c_check_func "$LINENO" "getnameinfo" "ac_cv_func_getnameinfo" 16137if test "x$ac_cv_func_getnameinfo" = xyes 16138then : 16139 printf "%s\n" "#define HAVE_GETNAMEINFO 1" >>confdefs.h 16140 16141fi 16142ac_fn_c_check_func "$LINENO" "getopt" "ac_cv_func_getopt" 16143if test "x$ac_cv_func_getopt" = xyes 16144then : 16145 printf "%s\n" "#define HAVE_GETOPT 1" >>confdefs.h 16146 16147fi 16148ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize" 16149if test "x$ac_cv_func_getpagesize" = xyes 16150then : 16151 printf "%s\n" "#define HAVE_GETPAGESIZE 1" >>confdefs.h 16152 16153fi 16154ac_fn_c_check_func "$LINENO" "getpeereid" "ac_cv_func_getpeereid" 16155if test "x$ac_cv_func_getpeereid" = xyes 16156then : 16157 printf "%s\n" "#define HAVE_GETPEEREID 1" >>confdefs.h 16158 16159fi 16160ac_fn_c_check_func "$LINENO" "getpeerucred" "ac_cv_func_getpeerucred" 16161if test "x$ac_cv_func_getpeerucred" = xyes 16162then : 16163 printf "%s\n" "#define HAVE_GETPEERUCRED 1" >>confdefs.h 16164 16165fi 16166ac_fn_c_check_func "$LINENO" "getpgid" "ac_cv_func_getpgid" 16167if test "x$ac_cv_func_getpgid" = xyes 16168then : 16169 printf "%s\n" "#define HAVE_GETPGID 1" >>confdefs.h 16170 16171fi 16172ac_fn_c_check_func "$LINENO" "_getpty" "ac_cv_func__getpty" 16173if test "x$ac_cv_func__getpty" = xyes 16174then : 16175 printf "%s\n" "#define HAVE__GETPTY 1" >>confdefs.h 16176 16177fi 16178ac_fn_c_check_func "$LINENO" "getrlimit" "ac_cv_func_getrlimit" 16179if test "x$ac_cv_func_getrlimit" = xyes 16180then : 16181 printf "%s\n" "#define HAVE_GETRLIMIT 1" >>confdefs.h 16182 16183fi 16184ac_fn_c_check_func "$LINENO" "getrandom" "ac_cv_func_getrandom" 16185if test "x$ac_cv_func_getrandom" = xyes 16186then : 16187 printf "%s\n" "#define HAVE_GETRANDOM 1" >>confdefs.h 16188 16189fi 16190ac_fn_c_check_func "$LINENO" "getsid" "ac_cv_func_getsid" 16191if test "x$ac_cv_func_getsid" = xyes 16192then : 16193 printf "%s\n" "#define HAVE_GETSID 1" >>confdefs.h 16194 16195fi 16196ac_fn_c_check_func "$LINENO" "getttyent" "ac_cv_func_getttyent" 16197if test "x$ac_cv_func_getttyent" = xyes 16198then : 16199 printf "%s\n" "#define HAVE_GETTTYENT 1" >>confdefs.h 16200 16201fi 16202ac_fn_c_check_func "$LINENO" "glob" "ac_cv_func_glob" 16203if test "x$ac_cv_func_glob" = xyes 16204then : 16205 printf "%s\n" "#define HAVE_GLOB 1" >>confdefs.h 16206 16207fi 16208ac_fn_c_check_func "$LINENO" "group_from_gid" "ac_cv_func_group_from_gid" 16209if test "x$ac_cv_func_group_from_gid" = xyes 16210then : 16211 printf "%s\n" "#define HAVE_GROUP_FROM_GID 1" >>confdefs.h 16212 16213fi 16214ac_fn_c_check_func "$LINENO" "inet_aton" "ac_cv_func_inet_aton" 16215if test "x$ac_cv_func_inet_aton" = xyes 16216then : 16217 printf "%s\n" "#define HAVE_INET_ATON 1" >>confdefs.h 16218 16219fi 16220ac_fn_c_check_func "$LINENO" "inet_ntoa" "ac_cv_func_inet_ntoa" 16221if test "x$ac_cv_func_inet_ntoa" = xyes 16222then : 16223 printf "%s\n" "#define HAVE_INET_NTOA 1" >>confdefs.h 16224 16225fi 16226ac_fn_c_check_func "$LINENO" "inet_ntop" "ac_cv_func_inet_ntop" 16227if test "x$ac_cv_func_inet_ntop" = xyes 16228then : 16229 printf "%s\n" "#define HAVE_INET_NTOP 1" >>confdefs.h 16230 16231fi 16232ac_fn_c_check_func "$LINENO" "innetgr" "ac_cv_func_innetgr" 16233if test "x$ac_cv_func_innetgr" = xyes 16234then : 16235 printf "%s\n" "#define HAVE_INNETGR 1" >>confdefs.h 16236 16237fi 16238ac_fn_c_check_func "$LINENO" "killpg" "ac_cv_func_killpg" 16239if test "x$ac_cv_func_killpg" = xyes 16240then : 16241 printf "%s\n" "#define HAVE_KILLPG 1" >>confdefs.h 16242 16243fi 16244ac_fn_c_check_func "$LINENO" "llabs" "ac_cv_func_llabs" 16245if test "x$ac_cv_func_llabs" = xyes 16246then : 16247 printf "%s\n" "#define HAVE_LLABS 1" >>confdefs.h 16248 16249fi 16250ac_fn_c_check_func "$LINENO" "localtime_r" "ac_cv_func_localtime_r" 16251if test "x$ac_cv_func_localtime_r" = xyes 16252then : 16253 printf "%s\n" "#define HAVE_LOCALTIME_R 1" >>confdefs.h 16254 16255fi 16256ac_fn_c_check_func "$LINENO" "login_getcapbool" "ac_cv_func_login_getcapbool" 16257if test "x$ac_cv_func_login_getcapbool" = xyes 16258then : 16259 printf "%s\n" "#define HAVE_LOGIN_GETCAPBOOL 1" >>confdefs.h 16260 16261fi 16262ac_fn_c_check_func "$LINENO" "login_getpwclass" "ac_cv_func_login_getpwclass" 16263if test "x$ac_cv_func_login_getpwclass" = xyes 16264then : 16265 printf "%s\n" "#define HAVE_LOGIN_GETPWCLASS 1" >>confdefs.h 16266 16267fi 16268ac_fn_c_check_func "$LINENO" "memmem" "ac_cv_func_memmem" 16269if test "x$ac_cv_func_memmem" = xyes 16270then : 16271 printf "%s\n" "#define HAVE_MEMMEM 1" >>confdefs.h 16272 16273fi 16274ac_fn_c_check_func "$LINENO" "memmove" "ac_cv_func_memmove" 16275if test "x$ac_cv_func_memmove" = xyes 16276then : 16277 printf "%s\n" "#define HAVE_MEMMOVE 1" >>confdefs.h 16278 16279fi 16280ac_fn_c_check_func "$LINENO" "memset_s" "ac_cv_func_memset_s" 16281if test "x$ac_cv_func_memset_s" = xyes 16282then : 16283 printf "%s\n" "#define HAVE_MEMSET_S 1" >>confdefs.h 16284 16285fi 16286ac_fn_c_check_func "$LINENO" "mkdtemp" "ac_cv_func_mkdtemp" 16287if test "x$ac_cv_func_mkdtemp" = xyes 16288then : 16289 printf "%s\n" "#define HAVE_MKDTEMP 1" >>confdefs.h 16290 16291fi 16292ac_fn_c_check_func "$LINENO" "ngetaddrinfo" "ac_cv_func_ngetaddrinfo" 16293if test "x$ac_cv_func_ngetaddrinfo" = xyes 16294then : 16295 printf "%s\n" "#define HAVE_NGETADDRINFO 1" >>confdefs.h 16296 16297fi 16298ac_fn_c_check_func "$LINENO" "nsleep" "ac_cv_func_nsleep" 16299if test "x$ac_cv_func_nsleep" = xyes 16300then : 16301 printf "%s\n" "#define HAVE_NSLEEP 1" >>confdefs.h 16302 16303fi 16304ac_fn_c_check_func "$LINENO" "ogetaddrinfo" "ac_cv_func_ogetaddrinfo" 16305if test "x$ac_cv_func_ogetaddrinfo" = xyes 16306then : 16307 printf "%s\n" "#define HAVE_OGETADDRINFO 1" >>confdefs.h 16308 16309fi 16310ac_fn_c_check_func "$LINENO" "openlog_r" "ac_cv_func_openlog_r" 16311if test "x$ac_cv_func_openlog_r" = xyes 16312then : 16313 printf "%s\n" "#define HAVE_OPENLOG_R 1" >>confdefs.h 16314 16315fi 16316ac_fn_c_check_func "$LINENO" "pledge" "ac_cv_func_pledge" 16317if test "x$ac_cv_func_pledge" = xyes 16318then : 16319 printf "%s\n" "#define HAVE_PLEDGE 1" >>confdefs.h 16320 16321fi 16322ac_fn_c_check_func "$LINENO" "poll" "ac_cv_func_poll" 16323if test "x$ac_cv_func_poll" = xyes 16324then : 16325 printf "%s\n" "#define HAVE_POLL 1" >>confdefs.h 16326 16327fi 16328ac_fn_c_check_func "$LINENO" "ppoll" "ac_cv_func_ppoll" 16329if test "x$ac_cv_func_ppoll" = xyes 16330then : 16331 printf "%s\n" "#define HAVE_PPOLL 1" >>confdefs.h 16332 16333fi 16334ac_fn_c_check_func "$LINENO" "prctl" "ac_cv_func_prctl" 16335if test "x$ac_cv_func_prctl" = xyes 16336then : 16337 printf "%s\n" "#define HAVE_PRCTL 1" >>confdefs.h 16338 16339fi 16340ac_fn_c_check_func "$LINENO" "procctl" "ac_cv_func_procctl" 16341if test "x$ac_cv_func_procctl" = xyes 16342then : 16343 printf "%s\n" "#define HAVE_PROCCTL 1" >>confdefs.h 16344 16345fi 16346ac_fn_c_check_func "$LINENO" "pselect" "ac_cv_func_pselect" 16347if test "x$ac_cv_func_pselect" = xyes 16348then : 16349 printf "%s\n" "#define HAVE_PSELECT 1" >>confdefs.h 16350 16351fi 16352ac_fn_c_check_func "$LINENO" "pstat" "ac_cv_func_pstat" 16353if test "x$ac_cv_func_pstat" = xyes 16354then : 16355 printf "%s\n" "#define HAVE_PSTAT 1" >>confdefs.h 16356 16357fi 16358ac_fn_c_check_func "$LINENO" "raise" "ac_cv_func_raise" 16359if test "x$ac_cv_func_raise" = xyes 16360then : 16361 printf "%s\n" "#define HAVE_RAISE 1" >>confdefs.h 16362 16363fi 16364ac_fn_c_check_func "$LINENO" "readpassphrase" "ac_cv_func_readpassphrase" 16365if test "x$ac_cv_func_readpassphrase" = xyes 16366then : 16367 printf "%s\n" "#define HAVE_READPASSPHRASE 1" >>confdefs.h 16368 16369fi 16370ac_fn_c_check_func "$LINENO" "reallocarray" "ac_cv_func_reallocarray" 16371if test "x$ac_cv_func_reallocarray" = xyes 16372then : 16373 printf "%s\n" "#define HAVE_REALLOCARRAY 1" >>confdefs.h 16374 16375fi 16376ac_fn_c_check_func "$LINENO" "realpath" "ac_cv_func_realpath" 16377if test "x$ac_cv_func_realpath" = xyes 16378then : 16379 printf "%s\n" "#define HAVE_REALPATH 1" >>confdefs.h 16380 16381fi 16382ac_fn_c_check_func "$LINENO" "recvmsg" "ac_cv_func_recvmsg" 16383if test "x$ac_cv_func_recvmsg" = xyes 16384then : 16385 printf "%s\n" "#define HAVE_RECVMSG 1" >>confdefs.h 16386 16387fi 16388ac_fn_c_check_func "$LINENO" "recallocarray" "ac_cv_func_recallocarray" 16389if test "x$ac_cv_func_recallocarray" = xyes 16390then : 16391 printf "%s\n" "#define HAVE_RECALLOCARRAY 1" >>confdefs.h 16392 16393fi 16394ac_fn_c_check_func "$LINENO" "rresvport_af" "ac_cv_func_rresvport_af" 16395if test "x$ac_cv_func_rresvport_af" = xyes 16396then : 16397 printf "%s\n" "#define HAVE_RRESVPORT_AF 1" >>confdefs.h 16398 16399fi 16400ac_fn_c_check_func "$LINENO" "sendmsg" "ac_cv_func_sendmsg" 16401if test "x$ac_cv_func_sendmsg" = xyes 16402then : 16403 printf "%s\n" "#define HAVE_SENDMSG 1" >>confdefs.h 16404 16405fi 16406ac_fn_c_check_func "$LINENO" "setdtablesize" "ac_cv_func_setdtablesize" 16407if test "x$ac_cv_func_setdtablesize" = xyes 16408then : 16409 printf "%s\n" "#define HAVE_SETDTABLESIZE 1" >>confdefs.h 16410 16411fi 16412ac_fn_c_check_func "$LINENO" "setegid" "ac_cv_func_setegid" 16413if test "x$ac_cv_func_setegid" = xyes 16414then : 16415 printf "%s\n" "#define HAVE_SETEGID 1" >>confdefs.h 16416 16417fi 16418ac_fn_c_check_func "$LINENO" "setenv" "ac_cv_func_setenv" 16419if test "x$ac_cv_func_setenv" = xyes 16420then : 16421 printf "%s\n" "#define HAVE_SETENV 1" >>confdefs.h 16422 16423fi 16424ac_fn_c_check_func "$LINENO" "seteuid" "ac_cv_func_seteuid" 16425if test "x$ac_cv_func_seteuid" = xyes 16426then : 16427 printf "%s\n" "#define HAVE_SETEUID 1" >>confdefs.h 16428 16429fi 16430ac_fn_c_check_func "$LINENO" "setgroupent" "ac_cv_func_setgroupent" 16431if test "x$ac_cv_func_setgroupent" = xyes 16432then : 16433 printf "%s\n" "#define HAVE_SETGROUPENT 1" >>confdefs.h 16434 16435fi 16436ac_fn_c_check_func "$LINENO" "setgroups" "ac_cv_func_setgroups" 16437if test "x$ac_cv_func_setgroups" = xyes 16438then : 16439 printf "%s\n" "#define HAVE_SETGROUPS 1" >>confdefs.h 16440 16441fi 16442ac_fn_c_check_func "$LINENO" "setlinebuf" "ac_cv_func_setlinebuf" 16443if test "x$ac_cv_func_setlinebuf" = xyes 16444then : 16445 printf "%s\n" "#define HAVE_SETLINEBUF 1" >>confdefs.h 16446 16447fi 16448ac_fn_c_check_func "$LINENO" "setlogin" "ac_cv_func_setlogin" 16449if test "x$ac_cv_func_setlogin" = xyes 16450then : 16451 printf "%s\n" "#define HAVE_SETLOGIN 1" >>confdefs.h 16452 16453fi 16454ac_fn_c_check_func "$LINENO" "setpassent" "ac_cv_func_setpassent" 16455if test "x$ac_cv_func_setpassent" = xyes 16456then : 16457 printf "%s\n" "#define HAVE_SETPASSENT 1" >>confdefs.h 16458 16459fi 16460ac_fn_c_check_func "$LINENO" "setpcred" "ac_cv_func_setpcred" 16461if test "x$ac_cv_func_setpcred" = xyes 16462then : 16463 printf "%s\n" "#define HAVE_SETPCRED 1" >>confdefs.h 16464 16465fi 16466ac_fn_c_check_func "$LINENO" "setproctitle" "ac_cv_func_setproctitle" 16467if test "x$ac_cv_func_setproctitle" = xyes 16468then : 16469 printf "%s\n" "#define HAVE_SETPROCTITLE 1" >>confdefs.h 16470 16471fi 16472ac_fn_c_check_func "$LINENO" "setregid" "ac_cv_func_setregid" 16473if test "x$ac_cv_func_setregid" = xyes 16474then : 16475 printf "%s\n" "#define HAVE_SETREGID 1" >>confdefs.h 16476 16477fi 16478ac_fn_c_check_func "$LINENO" "setreuid" "ac_cv_func_setreuid" 16479if test "x$ac_cv_func_setreuid" = xyes 16480then : 16481 printf "%s\n" "#define HAVE_SETREUID 1" >>confdefs.h 16482 16483fi 16484ac_fn_c_check_func "$LINENO" "setrlimit" "ac_cv_func_setrlimit" 16485if test "x$ac_cv_func_setrlimit" = xyes 16486then : 16487 printf "%s\n" "#define HAVE_SETRLIMIT 1" >>confdefs.h 16488 16489fi 16490ac_fn_c_check_func "$LINENO" "setsid" "ac_cv_func_setsid" 16491if test "x$ac_cv_func_setsid" = xyes 16492then : 16493 printf "%s\n" "#define HAVE_SETSID 1" >>confdefs.h 16494 16495fi 16496ac_fn_c_check_func "$LINENO" "setvbuf" "ac_cv_func_setvbuf" 16497if test "x$ac_cv_func_setvbuf" = xyes 16498then : 16499 printf "%s\n" "#define HAVE_SETVBUF 1" >>confdefs.h 16500 16501fi 16502ac_fn_c_check_func "$LINENO" "sigaction" "ac_cv_func_sigaction" 16503if test "x$ac_cv_func_sigaction" = xyes 16504then : 16505 printf "%s\n" "#define HAVE_SIGACTION 1" >>confdefs.h 16506 16507fi 16508ac_fn_c_check_func "$LINENO" "sigvec" "ac_cv_func_sigvec" 16509if test "x$ac_cv_func_sigvec" = xyes 16510then : 16511 printf "%s\n" "#define HAVE_SIGVEC 1" >>confdefs.h 16512 16513fi 16514ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf" 16515if test "x$ac_cv_func_snprintf" = xyes 16516then : 16517 printf "%s\n" "#define HAVE_SNPRINTF 1" >>confdefs.h 16518 16519fi 16520ac_fn_c_check_func "$LINENO" "socketpair" "ac_cv_func_socketpair" 16521if test "x$ac_cv_func_socketpair" = xyes 16522then : 16523 printf "%s\n" "#define HAVE_SOCKETPAIR 1" >>confdefs.h 16524 16525fi 16526ac_fn_c_check_func "$LINENO" "statfs" "ac_cv_func_statfs" 16527if test "x$ac_cv_func_statfs" = xyes 16528then : 16529 printf "%s\n" "#define HAVE_STATFS 1" >>confdefs.h 16530 16531fi 16532ac_fn_c_check_func "$LINENO" "statvfs" "ac_cv_func_statvfs" 16533if test "x$ac_cv_func_statvfs" = xyes 16534then : 16535 printf "%s\n" "#define HAVE_STATVFS 1" >>confdefs.h 16536 16537fi 16538ac_fn_c_check_func "$LINENO" "strcasestr" "ac_cv_func_strcasestr" 16539if test "x$ac_cv_func_strcasestr" = xyes 16540then : 16541 printf "%s\n" "#define HAVE_STRCASESTR 1" >>confdefs.h 16542 16543fi 16544ac_fn_c_check_func "$LINENO" "strdup" "ac_cv_func_strdup" 16545if test "x$ac_cv_func_strdup" = xyes 16546then : 16547 printf "%s\n" "#define HAVE_STRDUP 1" >>confdefs.h 16548 16549fi 16550ac_fn_c_check_func "$LINENO" "strerror" "ac_cv_func_strerror" 16551if test "x$ac_cv_func_strerror" = xyes 16552then : 16553 printf "%s\n" "#define HAVE_STRERROR 1" >>confdefs.h 16554 16555fi 16556ac_fn_c_check_func "$LINENO" "strlcat" "ac_cv_func_strlcat" 16557if test "x$ac_cv_func_strlcat" = xyes 16558then : 16559 printf "%s\n" "#define HAVE_STRLCAT 1" >>confdefs.h 16560 16561fi 16562ac_fn_c_check_func "$LINENO" "strlcpy" "ac_cv_func_strlcpy" 16563if test "x$ac_cv_func_strlcpy" = xyes 16564then : 16565 printf "%s\n" "#define HAVE_STRLCPY 1" >>confdefs.h 16566 16567fi 16568ac_fn_c_check_func "$LINENO" "strmode" "ac_cv_func_strmode" 16569if test "x$ac_cv_func_strmode" = xyes 16570then : 16571 printf "%s\n" "#define HAVE_STRMODE 1" >>confdefs.h 16572 16573fi 16574ac_fn_c_check_func "$LINENO" "strndup" "ac_cv_func_strndup" 16575if test "x$ac_cv_func_strndup" = xyes 16576then : 16577 printf "%s\n" "#define HAVE_STRNDUP 1" >>confdefs.h 16578 16579fi 16580ac_fn_c_check_func "$LINENO" "strnlen" "ac_cv_func_strnlen" 16581if test "x$ac_cv_func_strnlen" = xyes 16582then : 16583 printf "%s\n" "#define HAVE_STRNLEN 1" >>confdefs.h 16584 16585fi 16586ac_fn_c_check_func "$LINENO" "strnvis" "ac_cv_func_strnvis" 16587if test "x$ac_cv_func_strnvis" = xyes 16588then : 16589 printf "%s\n" "#define HAVE_STRNVIS 1" >>confdefs.h 16590 16591fi 16592ac_fn_c_check_func "$LINENO" "strptime" "ac_cv_func_strptime" 16593if test "x$ac_cv_func_strptime" = xyes 16594then : 16595 printf "%s\n" "#define HAVE_STRPTIME 1" >>confdefs.h 16596 16597fi 16598ac_fn_c_check_func "$LINENO" "strsignal" "ac_cv_func_strsignal" 16599if test "x$ac_cv_func_strsignal" = xyes 16600then : 16601 printf "%s\n" "#define HAVE_STRSIGNAL 1" >>confdefs.h 16602 16603fi 16604ac_fn_c_check_func "$LINENO" "strtonum" "ac_cv_func_strtonum" 16605if test "x$ac_cv_func_strtonum" = xyes 16606then : 16607 printf "%s\n" "#define HAVE_STRTONUM 1" >>confdefs.h 16608 16609fi 16610ac_fn_c_check_func "$LINENO" "strtoll" "ac_cv_func_strtoll" 16611if test "x$ac_cv_func_strtoll" = xyes 16612then : 16613 printf "%s\n" "#define HAVE_STRTOLL 1" >>confdefs.h 16614 16615fi 16616ac_fn_c_check_func "$LINENO" "strtoul" "ac_cv_func_strtoul" 16617if test "x$ac_cv_func_strtoul" = xyes 16618then : 16619 printf "%s\n" "#define HAVE_STRTOUL 1" >>confdefs.h 16620 16621fi 16622ac_fn_c_check_func "$LINENO" "strtoull" "ac_cv_func_strtoull" 16623if test "x$ac_cv_func_strtoull" = xyes 16624then : 16625 printf "%s\n" "#define HAVE_STRTOULL 1" >>confdefs.h 16626 16627fi 16628ac_fn_c_check_func "$LINENO" "swap32" "ac_cv_func_swap32" 16629if test "x$ac_cv_func_swap32" = xyes 16630then : 16631 printf "%s\n" "#define HAVE_SWAP32 1" >>confdefs.h 16632 16633fi 16634ac_fn_c_check_func "$LINENO" "sysconf" "ac_cv_func_sysconf" 16635if test "x$ac_cv_func_sysconf" = xyes 16636then : 16637 printf "%s\n" "#define HAVE_SYSCONF 1" >>confdefs.h 16638 16639fi 16640ac_fn_c_check_func "$LINENO" "tcgetpgrp" "ac_cv_func_tcgetpgrp" 16641if test "x$ac_cv_func_tcgetpgrp" = xyes 16642then : 16643 printf "%s\n" "#define HAVE_TCGETPGRP 1" >>confdefs.h 16644 16645fi 16646ac_fn_c_check_func "$LINENO" "timegm" "ac_cv_func_timegm" 16647if test "x$ac_cv_func_timegm" = xyes 16648then : 16649 printf "%s\n" "#define HAVE_TIMEGM 1" >>confdefs.h 16650 16651fi 16652ac_fn_c_check_func "$LINENO" "timingsafe_bcmp" "ac_cv_func_timingsafe_bcmp" 16653if test "x$ac_cv_func_timingsafe_bcmp" = xyes 16654then : 16655 printf "%s\n" "#define HAVE_TIMINGSAFE_BCMP 1" >>confdefs.h 16656 16657fi 16658ac_fn_c_check_func "$LINENO" "truncate" "ac_cv_func_truncate" 16659if test "x$ac_cv_func_truncate" = xyes 16660then : 16661 printf "%s\n" "#define HAVE_TRUNCATE 1" >>confdefs.h 16662 16663fi 16664ac_fn_c_check_func "$LINENO" "unsetenv" "ac_cv_func_unsetenv" 16665if test "x$ac_cv_func_unsetenv" = xyes 16666then : 16667 printf "%s\n" "#define HAVE_UNSETENV 1" >>confdefs.h 16668 16669fi 16670ac_fn_c_check_func "$LINENO" "updwtmpx" "ac_cv_func_updwtmpx" 16671if test "x$ac_cv_func_updwtmpx" = xyes 16672then : 16673 printf "%s\n" "#define HAVE_UPDWTMPX 1" >>confdefs.h 16674 16675fi 16676ac_fn_c_check_func "$LINENO" "utimensat" "ac_cv_func_utimensat" 16677if test "x$ac_cv_func_utimensat" = xyes 16678then : 16679 printf "%s\n" "#define HAVE_UTIMENSAT 1" >>confdefs.h 16680 16681fi 16682ac_fn_c_check_func "$LINENO" "user_from_uid" "ac_cv_func_user_from_uid" 16683if test "x$ac_cv_func_user_from_uid" = xyes 16684then : 16685 printf "%s\n" "#define HAVE_USER_FROM_UID 1" >>confdefs.h 16686 16687fi 16688ac_fn_c_check_func "$LINENO" "usleep" "ac_cv_func_usleep" 16689if test "x$ac_cv_func_usleep" = xyes 16690then : 16691 printf "%s\n" "#define HAVE_USLEEP 1" >>confdefs.h 16692 16693fi 16694ac_fn_c_check_func "$LINENO" "vasprintf" "ac_cv_func_vasprintf" 16695if test "x$ac_cv_func_vasprintf" = xyes 16696then : 16697 printf "%s\n" "#define HAVE_VASPRINTF 1" >>confdefs.h 16698 16699fi 16700ac_fn_c_check_func "$LINENO" "vsnprintf" "ac_cv_func_vsnprintf" 16701if test "x$ac_cv_func_vsnprintf" = xyes 16702then : 16703 printf "%s\n" "#define HAVE_VSNPRINTF 1" >>confdefs.h 16704 16705fi 16706ac_fn_c_check_func "$LINENO" "waitpid" "ac_cv_func_waitpid" 16707if test "x$ac_cv_func_waitpid" = xyes 16708then : 16709 printf "%s\n" "#define HAVE_WAITPID 1" >>confdefs.h 16710 16711fi 16712ac_fn_c_check_func "$LINENO" "warn" "ac_cv_func_warn" 16713if test "x$ac_cv_func_warn" = xyes 16714then : 16715 printf "%s\n" "#define HAVE_WARN 1" >>confdefs.h 16716 16717fi 16718 16719 16720ac_fn_check_decl "$LINENO" "bzero" "ac_cv_have_decl_bzero" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS" 16721if test "x$ac_cv_have_decl_bzero" = xyes 16722then : 16723 ac_have_decl=1 16724else $as_nop 16725 ac_have_decl=0 16726fi 16727printf "%s\n" "#define HAVE_DECL_BZERO $ac_have_decl" >>confdefs.h 16728ac_fn_check_decl "$LINENO" "memmem" "ac_cv_have_decl_memmem" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS" 16729if test "x$ac_cv_have_decl_memmem" = xyes 16730then : 16731 ac_have_decl=1 16732else $as_nop 16733 ac_have_decl=0 16734fi 16735printf "%s\n" "#define HAVE_DECL_MEMMEM $ac_have_decl" >>confdefs.h 16736 16737 16738ac_fn_c_check_func "$LINENO" "mblen" "ac_cv_func_mblen" 16739if test "x$ac_cv_func_mblen" = xyes 16740then : 16741 printf "%s\n" "#define HAVE_MBLEN 1" >>confdefs.h 16742 16743fi 16744ac_fn_c_check_func "$LINENO" "mbtowc" "ac_cv_func_mbtowc" 16745if test "x$ac_cv_func_mbtowc" = xyes 16746then : 16747 printf "%s\n" "#define HAVE_MBTOWC 1" >>confdefs.h 16748 16749fi 16750ac_fn_c_check_func "$LINENO" "nl_langinfo" "ac_cv_func_nl_langinfo" 16751if test "x$ac_cv_func_nl_langinfo" = xyes 16752then : 16753 printf "%s\n" "#define HAVE_NL_LANGINFO 1" >>confdefs.h 16754 16755fi 16756ac_fn_c_check_func "$LINENO" "wcwidth" "ac_cv_func_wcwidth" 16757if test "x$ac_cv_func_wcwidth" = xyes 16758then : 16759 printf "%s\n" "#define HAVE_WCWIDTH 1" >>confdefs.h 16760 16761fi 16762 16763 16764TEST_SSH_UTF8=${TEST_SSH_UTF8:=yes} 16765{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for utf8 locale support" >&5 16766printf %s "checking for utf8 locale support... " >&6; } 16767if test "$cross_compiling" = yes 16768then : 16769 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: assuming yes" >&5 16770printf "%s\n" "$as_me: WARNING: cross compiling: assuming yes" >&2;} 16771 16772else $as_nop 16773 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 16774/* end confdefs.h. */ 16775 16776#include <locale.h> 16777#include <stdlib.h> 16778 16779int 16780main (void) 16781{ 16782 16783 char *loc = setlocale(LC_CTYPE, "en_US.UTF-8"); 16784 if (loc != NULL) 16785 exit(0); 16786 exit(1); 16787 16788 ; 16789 return 0; 16790} 16791_ACEOF 16792if ac_fn_c_try_run "$LINENO" 16793then : 16794 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 16795printf "%s\n" "yes" >&6; } 16796else $as_nop 16797 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 16798printf "%s\n" "no" >&6; } 16799 TEST_SSH_UTF8=no 16800fi 16801rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 16802 conftest.$ac_objext conftest.beam conftest.$ac_ext 16803fi 16804 16805 16806cat confdefs.h - <<_ACEOF >conftest.$ac_ext 16807/* end confdefs.h. */ 16808 #include <ctype.h> 16809int 16810main (void) 16811{ 16812 return (isblank('a')); 16813 ; 16814 return 0; 16815} 16816_ACEOF 16817if ac_fn_c_try_link "$LINENO" 16818then : 16819 16820printf "%s\n" "#define HAVE_ISBLANK 1" >>confdefs.h 16821 16822 16823fi 16824rm -f core conftest.err conftest.$ac_objext conftest.beam \ 16825 conftest$ac_exeext conftest.$ac_ext 16826 16827disable_pkcs11= 16828# Check whether --enable-pkcs11 was given. 16829if test ${enable_pkcs11+y} 16830then : 16831 enableval=$enable_pkcs11; 16832 if test "x$enableval" = "xno" ; then 16833 disable_pkcs11=1 16834 fi 16835 16836 16837fi 16838 16839 16840disable_sk= 16841# Check whether --enable-security-key was given. 16842if test ${enable_security_key+y} 16843then : 16844 enableval=$enable_security_key; 16845 if test "x$enableval" = "xno" ; then 16846 disable_sk=1 16847 fi 16848 16849 16850fi 16851 16852enable_sk_internal= 16853 16854# Check whether --with-security-key-builtin was given. 16855if test ${with_security_key_builtin+y} 16856then : 16857 withval=$with_security_key_builtin; enable_sk_internal=$withval 16858 16859fi 16860 16861 16862enable_dsa= 16863# Check whether --enable-dsa-keys was given. 16864if test ${enable_dsa_keys+y} 16865then : 16866 enableval=$enable_dsa_keys; 16867 if test "x$enableval" != "xno" ; then 16868 enable_dsa=1 16869 fi 16870 16871 16872fi 16873 16874 16875{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing dlopen" >&5 16876printf %s "checking for library containing dlopen... " >&6; } 16877if test ${ac_cv_search_dlopen+y} 16878then : 16879 printf %s "(cached) " >&6 16880else $as_nop 16881 ac_func_search_save_LIBS=$LIBS 16882cat confdefs.h - <<_ACEOF >conftest.$ac_ext 16883/* end confdefs.h. */ 16884 16885/* Override any GCC internal prototype to avoid an error. 16886 Use char because int might match the return type of a GCC 16887 builtin and then its argument prototype would still apply. */ 16888char dlopen (); 16889int 16890main (void) 16891{ 16892return dlopen (); 16893 ; 16894 return 0; 16895} 16896_ACEOF 16897for ac_lib in '' dl 16898do 16899 if test -z "$ac_lib"; then 16900 ac_res="none required" 16901 else 16902 ac_res=-l$ac_lib 16903 LIBS="-l$ac_lib $ac_func_search_save_LIBS" 16904 fi 16905 if ac_fn_c_try_link "$LINENO" 16906then : 16907 ac_cv_search_dlopen=$ac_res 16908fi 16909rm -f core conftest.err conftest.$ac_objext conftest.beam \ 16910 conftest$ac_exeext 16911 if test ${ac_cv_search_dlopen+y} 16912then : 16913 break 16914fi 16915done 16916if test ${ac_cv_search_dlopen+y} 16917then : 16918 16919else $as_nop 16920 ac_cv_search_dlopen=no 16921fi 16922rm conftest.$ac_ext 16923LIBS=$ac_func_search_save_LIBS 16924fi 16925{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlopen" >&5 16926printf "%s\n" "$ac_cv_search_dlopen" >&6; } 16927ac_res=$ac_cv_search_dlopen 16928if test "$ac_res" != no 16929then : 16930 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" 16931 16932fi 16933 16934ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" 16935if test "x$ac_cv_func_dlopen" = xyes 16936then : 16937 printf "%s\n" "#define HAVE_DLOPEN 1" >>confdefs.h 16938 16939fi 16940 16941ac_fn_check_decl "$LINENO" "RTLD_NOW" "ac_cv_have_decl_RTLD_NOW" "#include <dlfcn.h> 16942" "$ac_c_undeclared_builtin_options" "CFLAGS" 16943if test "x$ac_cv_have_decl_RTLD_NOW" = xyes 16944then : 16945 16946fi 16947 16948# IRIX has a const char return value for gai_strerror() 16949 16950 for ac_func in gai_strerror 16951do : 16952 ac_fn_c_check_func "$LINENO" "gai_strerror" "ac_cv_func_gai_strerror" 16953if test "x$ac_cv_func_gai_strerror" = xyes 16954then : 16955 printf "%s\n" "#define HAVE_GAI_STRERROR 1" >>confdefs.h 16956 16957 printf "%s\n" "#define HAVE_GAI_STRERROR 1" >>confdefs.h 16958 16959 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 16960/* end confdefs.h. */ 16961 16962#include <sys/types.h> 16963#include <sys/socket.h> 16964#include <netdb.h> 16965 16966const char *gai_strerror(int); 16967 16968int 16969main (void) 16970{ 16971 16972 char *str; 16973 str = gai_strerror(0); 16974 16975 ; 16976 return 0; 16977} 16978_ACEOF 16979if ac_fn_c_try_compile "$LINENO" 16980then : 16981 16982 16983printf "%s\n" "#define HAVE_CONST_GAI_STRERROR_PROTO 1" >>confdefs.h 16984 16985fi 16986rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 16987fi 16988 16989done 16990 16991{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing nanosleep" >&5 16992printf %s "checking for library containing nanosleep... " >&6; } 16993if test ${ac_cv_search_nanosleep+y} 16994then : 16995 printf %s "(cached) " >&6 16996else $as_nop 16997 ac_func_search_save_LIBS=$LIBS 16998cat confdefs.h - <<_ACEOF >conftest.$ac_ext 16999/* end confdefs.h. */ 17000 17001/* Override any GCC internal prototype to avoid an error. 17002 Use char because int might match the return type of a GCC 17003 builtin and then its argument prototype would still apply. */ 17004char nanosleep (); 17005int 17006main (void) 17007{ 17008return nanosleep (); 17009 ; 17010 return 0; 17011} 17012_ACEOF 17013for ac_lib in '' rt posix4 17014do 17015 if test -z "$ac_lib"; then 17016 ac_res="none required" 17017 else 17018 ac_res=-l$ac_lib 17019 LIBS="-l$ac_lib $ac_func_search_save_LIBS" 17020 fi 17021 if ac_fn_c_try_link "$LINENO" 17022then : 17023 ac_cv_search_nanosleep=$ac_res 17024fi 17025rm -f core conftest.err conftest.$ac_objext conftest.beam \ 17026 conftest$ac_exeext 17027 if test ${ac_cv_search_nanosleep+y} 17028then : 17029 break 17030fi 17031done 17032if test ${ac_cv_search_nanosleep+y} 17033then : 17034 17035else $as_nop 17036 ac_cv_search_nanosleep=no 17037fi 17038rm conftest.$ac_ext 17039LIBS=$ac_func_search_save_LIBS 17040fi 17041{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_nanosleep" >&5 17042printf "%s\n" "$ac_cv_search_nanosleep" >&6; } 17043ac_res=$ac_cv_search_nanosleep 17044if test "$ac_res" != no 17045then : 17046 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" 17047 17048printf "%s\n" "#define HAVE_NANOSLEEP 1" >>confdefs.h 17049 17050fi 17051 17052 17053{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5 17054printf %s "checking for library containing clock_gettime... " >&6; } 17055if test ${ac_cv_search_clock_gettime+y} 17056then : 17057 printf %s "(cached) " >&6 17058else $as_nop 17059 ac_func_search_save_LIBS=$LIBS 17060cat confdefs.h - <<_ACEOF >conftest.$ac_ext 17061/* end confdefs.h. */ 17062 17063/* Override any GCC internal prototype to avoid an error. 17064 Use char because int might match the return type of a GCC 17065 builtin and then its argument prototype would still apply. */ 17066char clock_gettime (); 17067int 17068main (void) 17069{ 17070return clock_gettime (); 17071 ; 17072 return 0; 17073} 17074_ACEOF 17075for ac_lib in '' rt 17076do 17077 if test -z "$ac_lib"; then 17078 ac_res="none required" 17079 else 17080 ac_res=-l$ac_lib 17081 LIBS="-l$ac_lib $ac_func_search_save_LIBS" 17082 fi 17083 if ac_fn_c_try_link "$LINENO" 17084then : 17085 ac_cv_search_clock_gettime=$ac_res 17086fi 17087rm -f core conftest.err conftest.$ac_objext conftest.beam \ 17088 conftest$ac_exeext 17089 if test ${ac_cv_search_clock_gettime+y} 17090then : 17091 break 17092fi 17093done 17094if test ${ac_cv_search_clock_gettime+y} 17095then : 17096 17097else $as_nop 17098 ac_cv_search_clock_gettime=no 17099fi 17100rm conftest.$ac_ext 17101LIBS=$ac_func_search_save_LIBS 17102fi 17103{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5 17104printf "%s\n" "$ac_cv_search_clock_gettime" >&6; } 17105ac_res=$ac_cv_search_clock_gettime 17106if test "$ac_res" != no 17107then : 17108 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" 17109 17110printf "%s\n" "#define HAVE_CLOCK_GETTIME 1" >>confdefs.h 17111 17112fi 17113 17114 17115ac_fn_check_decl "$LINENO" "localtime_r" "ac_cv_have_decl_localtime_r" " #include <time.h> 17116 17117" "$ac_c_undeclared_builtin_options" "CFLAGS" 17118if test "x$ac_cv_have_decl_localtime_r" = xyes 17119then : 17120 17121else $as_nop 17122 saved_CPPFLAGS="$CPPFLAGS" 17123 CPPFLAGS="$CPPFLAGS -D_REENTRANT" 17124 unset ac_cv_have_decl_localtime_r 17125 ac_fn_check_decl "$LINENO" "localtime_r" "ac_cv_have_decl_localtime_r" " #include <time.h> 17126 17127" "$ac_c_undeclared_builtin_options" "CFLAGS" 17128if test "x$ac_cv_have_decl_localtime_r" = xyes 17129then : 17130 17131else $as_nop 17132 CPPFLAGS="$saved_CPPFLAGS" 17133fi 17134 17135fi 17136 17137ac_fn_check_decl "$LINENO" "strsep" "ac_cv_have_decl_strsep" " 17138#ifdef HAVE_STRING_H 17139# include <string.h> 17140#endif 17141 17142" "$ac_c_undeclared_builtin_options" "CFLAGS" 17143if test "x$ac_cv_have_decl_strsep" = xyes 17144then : 17145 ac_fn_c_check_func "$LINENO" "strsep" "ac_cv_func_strsep" 17146if test "x$ac_cv_func_strsep" = xyes 17147then : 17148 printf "%s\n" "#define HAVE_STRSEP 1" >>confdefs.h 17149 17150fi 17151 17152fi 17153 17154ac_fn_check_decl "$LINENO" "tcsendbreak" "ac_cv_have_decl_tcsendbreak" "#include <termios.h> 17155 17156" "$ac_c_undeclared_builtin_options" "CFLAGS" 17157if test "x$ac_cv_have_decl_tcsendbreak" = xyes 17158then : 17159 printf "%s\n" "#define HAVE_TCSENDBREAK 1" >>confdefs.h 17160 17161else $as_nop 17162 ac_fn_c_check_func "$LINENO" "tcsendbreak" "ac_cv_func_tcsendbreak" 17163if test "x$ac_cv_func_tcsendbreak" = xyes 17164then : 17165 printf "%s\n" "#define HAVE_TCSENDBREAK 1" >>confdefs.h 17166 17167fi 17168 17169fi 17170 17171ac_fn_check_decl "$LINENO" "h_errno" "ac_cv_have_decl_h_errno" "#include <netdb.h> 17172" "$ac_c_undeclared_builtin_options" "CFLAGS" 17173if test "x$ac_cv_have_decl_h_errno" = xyes 17174then : 17175 ac_have_decl=1 17176else $as_nop 17177 ac_have_decl=0 17178fi 17179printf "%s\n" "#define HAVE_DECL_H_ERRNO $ac_have_decl" >>confdefs.h 17180 17181 17182ac_fn_check_decl "$LINENO" "SHUT_RD" "ac_cv_have_decl_SHUT_RD" " 17183#include <sys/types.h> 17184#include <sys/socket.h> 17185#include <unistd.h> 17186 17187" "$ac_c_undeclared_builtin_options" "CFLAGS" 17188if test "x$ac_cv_have_decl_SHUT_RD" = xyes 17189then : 17190 ac_have_decl=1 17191else $as_nop 17192 ac_have_decl=0 17193fi 17194printf "%s\n" "#define HAVE_DECL_SHUT_RD $ac_have_decl" >>confdefs.h 17195ac_fn_check_decl "$LINENO" "getpeereid" "ac_cv_have_decl_getpeereid" " 17196#include <sys/types.h> 17197#include <sys/socket.h> 17198#include <unistd.h> 17199 17200" "$ac_c_undeclared_builtin_options" "CFLAGS" 17201if test "x$ac_cv_have_decl_getpeereid" = xyes 17202then : 17203 ac_have_decl=1 17204else $as_nop 17205 ac_have_decl=0 17206fi 17207printf "%s\n" "#define HAVE_DECL_GETPEEREID $ac_have_decl" >>confdefs.h 17208 17209 17210ac_fn_check_decl "$LINENO" "O_NONBLOCK" "ac_cv_have_decl_O_NONBLOCK" " 17211#include <sys/types.h> 17212#ifdef HAVE_SYS_STAT_H 17213# include <sys/stat.h> 17214#endif 17215#ifdef HAVE_FCNTL_H 17216# include <fcntl.h> 17217#endif 17218 17219" "$ac_c_undeclared_builtin_options" "CFLAGS" 17220if test "x$ac_cv_have_decl_O_NONBLOCK" = xyes 17221then : 17222 ac_have_decl=1 17223else $as_nop 17224 ac_have_decl=0 17225fi 17226printf "%s\n" "#define HAVE_DECL_O_NONBLOCK $ac_have_decl" >>confdefs.h 17227 17228 17229ac_fn_check_decl "$LINENO" "ftruncate" "ac_cv_have_decl_ftruncate" " 17230#include <sys/types.h> 17231#include <unistd.h> 17232 17233" "$ac_c_undeclared_builtin_options" "CFLAGS" 17234if test "x$ac_cv_have_decl_ftruncate" = xyes 17235then : 17236 ac_have_decl=1 17237else $as_nop 17238 ac_have_decl=0 17239fi 17240printf "%s\n" "#define HAVE_DECL_FTRUNCATE $ac_have_decl" >>confdefs.h 17241ac_fn_check_decl "$LINENO" "getentropy" "ac_cv_have_decl_getentropy" " 17242#include <sys/types.h> 17243#include <unistd.h> 17244 17245" "$ac_c_undeclared_builtin_options" "CFLAGS" 17246if test "x$ac_cv_have_decl_getentropy" = xyes 17247then : 17248 ac_have_decl=1 17249else $as_nop 17250 ac_have_decl=0 17251fi 17252printf "%s\n" "#define HAVE_DECL_GETENTROPY $ac_have_decl" >>confdefs.h 17253 17254 17255ac_fn_check_decl "$LINENO" "readv" "ac_cv_have_decl_readv" " 17256#include <sys/types.h> 17257#include <sys/uio.h> 17258#include <unistd.h> 17259 17260" "$ac_c_undeclared_builtin_options" "CFLAGS" 17261if test "x$ac_cv_have_decl_readv" = xyes 17262then : 17263 ac_have_decl=1 17264else $as_nop 17265 ac_have_decl=0 17266fi 17267printf "%s\n" "#define HAVE_DECL_READV $ac_have_decl" >>confdefs.h 17268ac_fn_check_decl "$LINENO" "writev" "ac_cv_have_decl_writev" " 17269#include <sys/types.h> 17270#include <sys/uio.h> 17271#include <unistd.h> 17272 17273" "$ac_c_undeclared_builtin_options" "CFLAGS" 17274if test "x$ac_cv_have_decl_writev" = xyes 17275then : 17276 ac_have_decl=1 17277else $as_nop 17278 ac_have_decl=0 17279fi 17280printf "%s\n" "#define HAVE_DECL_WRITEV $ac_have_decl" >>confdefs.h 17281 17282 17283ac_fn_check_decl "$LINENO" "MAXSYMLINKS" "ac_cv_have_decl_MAXSYMLINKS" " 17284#include <sys/param.h> 17285 17286" "$ac_c_undeclared_builtin_options" "CFLAGS" 17287if test "x$ac_cv_have_decl_MAXSYMLINKS" = xyes 17288then : 17289 ac_have_decl=1 17290else $as_nop 17291 ac_have_decl=0 17292fi 17293printf "%s\n" "#define HAVE_DECL_MAXSYMLINKS $ac_have_decl" >>confdefs.h 17294 17295 17296ac_fn_check_decl "$LINENO" "offsetof" "ac_cv_have_decl_offsetof" " 17297#include <stddef.h> 17298 17299" "$ac_c_undeclared_builtin_options" "CFLAGS" 17300if test "x$ac_cv_have_decl_offsetof" = xyes 17301then : 17302 ac_have_decl=1 17303else $as_nop 17304 ac_have_decl=0 17305fi 17306printf "%s\n" "#define HAVE_DECL_OFFSETOF $ac_have_decl" >>confdefs.h 17307 17308 17309# extra bits for select(2) 17310ac_fn_check_decl "$LINENO" "howmany" "ac_cv_have_decl_howmany" " 17311#include <sys/param.h> 17312#include <sys/types.h> 17313#ifdef HAVE_SYS_SYSMACROS_H 17314#include <sys/sysmacros.h> 17315#endif 17316#ifdef HAVE_SYS_SELECT_H 17317#include <sys/select.h> 17318#endif 17319#ifdef HAVE_SYS_TIME_H 17320#include <sys/time.h> 17321#endif 17322#ifdef HAVE_UNISTD_H 17323#include <unistd.h> 17324#endif 17325 17326" "$ac_c_undeclared_builtin_options" "CFLAGS" 17327if test "x$ac_cv_have_decl_howmany" = xyes 17328then : 17329 ac_have_decl=1 17330else $as_nop 17331 ac_have_decl=0 17332fi 17333printf "%s\n" "#define HAVE_DECL_HOWMANY $ac_have_decl" >>confdefs.h 17334ac_fn_check_decl "$LINENO" "NFDBITS" "ac_cv_have_decl_NFDBITS" " 17335#include <sys/param.h> 17336#include <sys/types.h> 17337#ifdef HAVE_SYS_SYSMACROS_H 17338#include <sys/sysmacros.h> 17339#endif 17340#ifdef HAVE_SYS_SELECT_H 17341#include <sys/select.h> 17342#endif 17343#ifdef HAVE_SYS_TIME_H 17344#include <sys/time.h> 17345#endif 17346#ifdef HAVE_UNISTD_H 17347#include <unistd.h> 17348#endif 17349 17350" "$ac_c_undeclared_builtin_options" "CFLAGS" 17351if test "x$ac_cv_have_decl_NFDBITS" = xyes 17352then : 17353 ac_have_decl=1 17354else $as_nop 17355 ac_have_decl=0 17356fi 17357printf "%s\n" "#define HAVE_DECL_NFDBITS $ac_have_decl" >>confdefs.h 17358 17359ac_fn_c_check_type "$LINENO" "fd_mask" "ac_cv_type_fd_mask" " 17360#include <sys/param.h> 17361#include <sys/types.h> 17362#ifdef HAVE_SYS_SELECT_H 17363#include <sys/select.h> 17364#endif 17365#ifdef HAVE_SYS_TIME_H 17366#include <sys/time.h> 17367#endif 17368#ifdef HAVE_UNISTD_H 17369#include <unistd.h> 17370#endif 17371 17372" 17373if test "x$ac_cv_type_fd_mask" = xyes 17374then : 17375 17376printf "%s\n" "#define HAVE_FD_MASK 1" >>confdefs.h 17377 17378 17379fi 17380 17381 17382 17383 for ac_func in setresuid 17384do : 17385 ac_fn_c_check_func "$LINENO" "setresuid" "ac_cv_func_setresuid" 17386if test "x$ac_cv_func_setresuid" = xyes 17387then : 17388 printf "%s\n" "#define HAVE_SETRESUID 1" >>confdefs.h 17389 17390 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if setresuid seems to work" >&5 17391printf %s "checking if setresuid seems to work... " >&6; } 17392 if test "$cross_compiling" = yes 17393then : 17394 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: not checking setresuid" >&5 17395printf "%s\n" "$as_me: WARNING: cross compiling: not checking setresuid" >&2;} 17396 17397else $as_nop 17398 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 17399/* end confdefs.h. */ 17400 17401#include <errno.h> 17402#include <stdlib.h> 17403#include <unistd.h> 17404 17405int 17406main (void) 17407{ 17408 17409 errno=0; 17410 setresuid(0,0,0); 17411 if (errno==ENOSYS) 17412 exit(1); 17413 else 17414 exit(0); 17415 17416 ; 17417 return 0; 17418} 17419_ACEOF 17420if ac_fn_c_try_run "$LINENO" 17421then : 17422 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 17423printf "%s\n" "yes" >&6; } 17424else $as_nop 17425 17426printf "%s\n" "#define BROKEN_SETRESUID 1" >>confdefs.h 17427 17428 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not implemented" >&5 17429printf "%s\n" "not implemented" >&6; } 17430fi 17431rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 17432 conftest.$ac_objext conftest.beam conftest.$ac_ext 17433fi 17434 17435 17436fi 17437 17438done 17439 17440 17441 for ac_func in setresgid 17442do : 17443 ac_fn_c_check_func "$LINENO" "setresgid" "ac_cv_func_setresgid" 17444if test "x$ac_cv_func_setresgid" = xyes 17445then : 17446 printf "%s\n" "#define HAVE_SETRESGID 1" >>confdefs.h 17447 17448 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if setresgid seems to work" >&5 17449printf %s "checking if setresgid seems to work... " >&6; } 17450 if test "$cross_compiling" = yes 17451then : 17452 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: not checking setresuid" >&5 17453printf "%s\n" "$as_me: WARNING: cross compiling: not checking setresuid" >&2;} 17454 17455else $as_nop 17456 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 17457/* end confdefs.h. */ 17458 17459#include <errno.h> 17460#include <stdlib.h> 17461#include <unistd.h> 17462 17463int 17464main (void) 17465{ 17466 17467 errno=0; 17468 setresgid(0,0,0); 17469 if (errno==ENOSYS) 17470 exit(1); 17471 else 17472 exit(0); 17473 17474 ; 17475 return 0; 17476} 17477_ACEOF 17478if ac_fn_c_try_run "$LINENO" 17479then : 17480 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 17481printf "%s\n" "yes" >&6; } 17482else $as_nop 17483 17484printf "%s\n" "#define BROKEN_SETRESGID 1" >>confdefs.h 17485 17486 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not implemented" >&5 17487printf "%s\n" "not implemented" >&6; } 17488fi 17489rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 17490 conftest.$ac_objext conftest.beam conftest.$ac_ext 17491fi 17492 17493 17494fi 17495 17496done 17497 17498{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working fflush(NULL)" >&5 17499printf %s "checking for working fflush(NULL)... " >&6; } 17500if test "$cross_compiling" = yes 17501then : 17502 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: assuming working" >&5 17503printf "%s\n" "$as_me: WARNING: cross compiling: assuming working" >&2;} 17504 17505else $as_nop 17506 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 17507/* end confdefs.h. */ 17508 17509#include <stdio.h> 17510#include <stdlib.h> 17511 17512int 17513main (void) 17514{ 17515fflush(NULL); exit(0); 17516 ; 17517 return 0; 17518} 17519_ACEOF 17520if ac_fn_c_try_run "$LINENO" 17521then : 17522 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 17523printf "%s\n" "yes" >&6; } 17524else $as_nop 17525 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 17526printf "%s\n" "no" >&6; } 17527 17528printf "%s\n" "#define FFLUSH_NULL_BUG 1" >>confdefs.h 17529 17530fi 17531rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 17532 conftest.$ac_objext conftest.beam conftest.$ac_ext 17533fi 17534 17535 17536ac_fn_c_check_func "$LINENO" "gettimeofday" "ac_cv_func_gettimeofday" 17537if test "x$ac_cv_func_gettimeofday" = xyes 17538then : 17539 printf "%s\n" "#define HAVE_GETTIMEOFDAY 1" >>confdefs.h 17540 17541fi 17542ac_fn_c_check_func "$LINENO" "time" "ac_cv_func_time" 17543if test "x$ac_cv_func_time" = xyes 17544then : 17545 printf "%s\n" "#define HAVE_TIME 1" >>confdefs.h 17546 17547fi 17548 17549ac_fn_c_check_func "$LINENO" "endutent" "ac_cv_func_endutent" 17550if test "x$ac_cv_func_endutent" = xyes 17551then : 17552 printf "%s\n" "#define HAVE_ENDUTENT 1" >>confdefs.h 17553 17554fi 17555ac_fn_c_check_func "$LINENO" "getutent" "ac_cv_func_getutent" 17556if test "x$ac_cv_func_getutent" = xyes 17557then : 17558 printf "%s\n" "#define HAVE_GETUTENT 1" >>confdefs.h 17559 17560fi 17561ac_fn_c_check_func "$LINENO" "getutid" "ac_cv_func_getutid" 17562if test "x$ac_cv_func_getutid" = xyes 17563then : 17564 printf "%s\n" "#define HAVE_GETUTID 1" >>confdefs.h 17565 17566fi 17567ac_fn_c_check_func "$LINENO" "getutline" "ac_cv_func_getutline" 17568if test "x$ac_cv_func_getutline" = xyes 17569then : 17570 printf "%s\n" "#define HAVE_GETUTLINE 1" >>confdefs.h 17571 17572fi 17573ac_fn_c_check_func "$LINENO" "pututline" "ac_cv_func_pututline" 17574if test "x$ac_cv_func_pututline" = xyes 17575then : 17576 printf "%s\n" "#define HAVE_PUTUTLINE 1" >>confdefs.h 17577 17578fi 17579ac_fn_c_check_func "$LINENO" "setutent" "ac_cv_func_setutent" 17580if test "x$ac_cv_func_setutent" = xyes 17581then : 17582 printf "%s\n" "#define HAVE_SETUTENT 1" >>confdefs.h 17583 17584fi 17585 17586ac_fn_c_check_func "$LINENO" "utmpname" "ac_cv_func_utmpname" 17587if test "x$ac_cv_func_utmpname" = xyes 17588then : 17589 printf "%s\n" "#define HAVE_UTMPNAME 1" >>confdefs.h 17590 17591fi 17592 17593ac_fn_c_check_func "$LINENO" "endutxent" "ac_cv_func_endutxent" 17594if test "x$ac_cv_func_endutxent" = xyes 17595then : 17596 printf "%s\n" "#define HAVE_ENDUTXENT 1" >>confdefs.h 17597 17598fi 17599ac_fn_c_check_func "$LINENO" "getutxent" "ac_cv_func_getutxent" 17600if test "x$ac_cv_func_getutxent" = xyes 17601then : 17602 printf "%s\n" "#define HAVE_GETUTXENT 1" >>confdefs.h 17603 17604fi 17605ac_fn_c_check_func "$LINENO" "getutxid" "ac_cv_func_getutxid" 17606if test "x$ac_cv_func_getutxid" = xyes 17607then : 17608 printf "%s\n" "#define HAVE_GETUTXID 1" >>confdefs.h 17609 17610fi 17611ac_fn_c_check_func "$LINENO" "getutxline" "ac_cv_func_getutxline" 17612if test "x$ac_cv_func_getutxline" = xyes 17613then : 17614 printf "%s\n" "#define HAVE_GETUTXLINE 1" >>confdefs.h 17615 17616fi 17617ac_fn_c_check_func "$LINENO" "getutxuser" "ac_cv_func_getutxuser" 17618if test "x$ac_cv_func_getutxuser" = xyes 17619then : 17620 printf "%s\n" "#define HAVE_GETUTXUSER 1" >>confdefs.h 17621 17622fi 17623ac_fn_c_check_func "$LINENO" "pututxline" "ac_cv_func_pututxline" 17624if test "x$ac_cv_func_pututxline" = xyes 17625then : 17626 printf "%s\n" "#define HAVE_PUTUTXLINE 1" >>confdefs.h 17627 17628fi 17629 17630ac_fn_c_check_func "$LINENO" "setutxdb" "ac_cv_func_setutxdb" 17631if test "x$ac_cv_func_setutxdb" = xyes 17632then : 17633 printf "%s\n" "#define HAVE_SETUTXDB 1" >>confdefs.h 17634 17635fi 17636ac_fn_c_check_func "$LINENO" "setutxent" "ac_cv_func_setutxent" 17637if test "x$ac_cv_func_setutxent" = xyes 17638then : 17639 printf "%s\n" "#define HAVE_SETUTXENT 1" >>confdefs.h 17640 17641fi 17642ac_fn_c_check_func "$LINENO" "utmpxname" "ac_cv_func_utmpxname" 17643if test "x$ac_cv_func_utmpxname" = xyes 17644then : 17645 printf "%s\n" "#define HAVE_UTMPXNAME 1" >>confdefs.h 17646 17647fi 17648 17649ac_fn_c_check_func "$LINENO" "getlastlogxbyname" "ac_cv_func_getlastlogxbyname" 17650if test "x$ac_cv_func_getlastlogxbyname" = xyes 17651then : 17652 printf "%s\n" "#define HAVE_GETLASTLOGXBYNAME 1" >>confdefs.h 17653 17654fi 17655 17656 17657ac_fn_c_check_func "$LINENO" "daemon" "ac_cv_func_daemon" 17658if test "x$ac_cv_func_daemon" = xyes 17659then : 17660 17661printf "%s\n" "#define HAVE_DAEMON 1" >>confdefs.h 17662 17663else $as_nop 17664 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for daemon in -lbsd" >&5 17665printf %s "checking for daemon in -lbsd... " >&6; } 17666if test ${ac_cv_lib_bsd_daemon+y} 17667then : 17668 printf %s "(cached) " >&6 17669else $as_nop 17670 ac_check_lib_save_LIBS=$LIBS 17671LIBS="-lbsd $LIBS" 17672cat confdefs.h - <<_ACEOF >conftest.$ac_ext 17673/* end confdefs.h. */ 17674 17675/* Override any GCC internal prototype to avoid an error. 17676 Use char because int might match the return type of a GCC 17677 builtin and then its argument prototype would still apply. */ 17678char daemon (); 17679int 17680main (void) 17681{ 17682return daemon (); 17683 ; 17684 return 0; 17685} 17686_ACEOF 17687if ac_fn_c_try_link "$LINENO" 17688then : 17689 ac_cv_lib_bsd_daemon=yes 17690else $as_nop 17691 ac_cv_lib_bsd_daemon=no 17692fi 17693rm -f core conftest.err conftest.$ac_objext conftest.beam \ 17694 conftest$ac_exeext conftest.$ac_ext 17695LIBS=$ac_check_lib_save_LIBS 17696fi 17697{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_daemon" >&5 17698printf "%s\n" "$ac_cv_lib_bsd_daemon" >&6; } 17699if test "x$ac_cv_lib_bsd_daemon" = xyes 17700then : 17701 LIBS="$LIBS -lbsd"; printf "%s\n" "#define HAVE_DAEMON 1" >>confdefs.h 17702 17703fi 17704 17705 17706fi 17707 17708 17709ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize" 17710if test "x$ac_cv_func_getpagesize" = xyes 17711then : 17712 17713printf "%s\n" "#define HAVE_GETPAGESIZE 1" >>confdefs.h 17714 17715else $as_nop 17716 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for getpagesize in -lucb" >&5 17717printf %s "checking for getpagesize in -lucb... " >&6; } 17718if test ${ac_cv_lib_ucb_getpagesize+y} 17719then : 17720 printf %s "(cached) " >&6 17721else $as_nop 17722 ac_check_lib_save_LIBS=$LIBS 17723LIBS="-lucb $LIBS" 17724cat confdefs.h - <<_ACEOF >conftest.$ac_ext 17725/* end confdefs.h. */ 17726 17727/* Override any GCC internal prototype to avoid an error. 17728 Use char because int might match the return type of a GCC 17729 builtin and then its argument prototype would still apply. */ 17730char getpagesize (); 17731int 17732main (void) 17733{ 17734return getpagesize (); 17735 ; 17736 return 0; 17737} 17738_ACEOF 17739if ac_fn_c_try_link "$LINENO" 17740then : 17741 ac_cv_lib_ucb_getpagesize=yes 17742else $as_nop 17743 ac_cv_lib_ucb_getpagesize=no 17744fi 17745rm -f core conftest.err conftest.$ac_objext conftest.beam \ 17746 conftest$ac_exeext conftest.$ac_ext 17747LIBS=$ac_check_lib_save_LIBS 17748fi 17749{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ucb_getpagesize" >&5 17750printf "%s\n" "$ac_cv_lib_ucb_getpagesize" >&6; } 17751if test "x$ac_cv_lib_ucb_getpagesize" = xyes 17752then : 17753 LIBS="$LIBS -lucb"; printf "%s\n" "#define HAVE_GETPAGESIZE 1" >>confdefs.h 17754 17755fi 17756 17757 17758fi 17759 17760 17761# Check for broken snprintf 17762if test "x$ac_cv_func_snprintf" = "xyes" ; then 17763 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether snprintf correctly terminates long strings" >&5 17764printf %s "checking whether snprintf correctly terminates long strings... " >&6; } 17765 if test "$cross_compiling" = yes 17766then : 17767 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: Assuming working snprintf()" >&5 17768printf "%s\n" "$as_me: WARNING: cross compiling: Assuming working snprintf()" >&2;} 17769 17770else $as_nop 17771 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 17772/* end confdefs.h. */ 17773 17774#include <stdio.h> 17775#include <stdlib.h> 17776 17777int 17778main (void) 17779{ 17780 17781 char b[5]; 17782 snprintf(b,5,"123456789"); 17783 exit(b[4]!='\0'); 17784 17785 ; 17786 return 0; 17787} 17788_ACEOF 17789if ac_fn_c_try_run "$LINENO" 17790then : 17791 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 17792printf "%s\n" "yes" >&6; } 17793else $as_nop 17794 17795 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 17796printf "%s\n" "no" >&6; } 17797 17798printf "%s\n" "#define BROKEN_SNPRINTF 1" >>confdefs.h 17799 17800 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: ****** Your snprintf() function is broken, complain to your vendor" >&5 17801printf "%s\n" "$as_me: WARNING: ****** Your snprintf() function is broken, complain to your vendor" >&2;} 17802 17803fi 17804rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 17805 conftest.$ac_objext conftest.beam conftest.$ac_ext 17806fi 17807 17808fi 17809 17810if test "x$ac_cv_func_snprintf" = "xyes" ; then 17811 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether snprintf understands %zu" >&5 17812printf %s "checking whether snprintf understands %zu... " >&6; } 17813 if test "$cross_compiling" = yes 17814then : 17815 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: Assuming working snprintf()" >&5 17816printf "%s\n" "$as_me: WARNING: cross compiling: Assuming working snprintf()" >&2;} 17817 17818else $as_nop 17819 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 17820/* end confdefs.h. */ 17821 17822#include <sys/types.h> 17823#include <stdio.h> 17824#include <stdlib.h> 17825#include <string.h> 17826 17827int 17828main (void) 17829{ 17830 17831 size_t a = 1, b = 2; 17832 char z[128]; 17833 snprintf(z, sizeof z, "%zu%zu", a, b); 17834 exit(strcmp(z, "12")); 17835 17836 ; 17837 return 0; 17838} 17839_ACEOF 17840if ac_fn_c_try_run "$LINENO" 17841then : 17842 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 17843printf "%s\n" "yes" >&6; } 17844else $as_nop 17845 17846 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 17847printf "%s\n" "no" >&6; } 17848 17849printf "%s\n" "#define BROKEN_SNPRINTF 1" >>confdefs.h 17850 17851 17852fi 17853rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 17854 conftest.$ac_objext conftest.beam conftest.$ac_ext 17855fi 17856 17857fi 17858 17859# We depend on vsnprintf returning the right thing on overflow: the 17860# number of characters it tried to create (as per SUSv3) 17861if test "x$ac_cv_func_vsnprintf" = "xyes" ; then 17862 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether vsnprintf returns correct values on overflow" >&5 17863printf %s "checking whether vsnprintf returns correct values on overflow... " >&6; } 17864 if test "$cross_compiling" = yes 17865then : 17866 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: Assuming working vsnprintf()" >&5 17867printf "%s\n" "$as_me: WARNING: cross compiling: Assuming working vsnprintf()" >&2;} 17868 17869else $as_nop 17870 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 17871/* end confdefs.h. */ 17872 17873#include <sys/types.h> 17874#include <stdio.h> 17875#include <stdarg.h> 17876 17877int x_snprintf(char *str, size_t count, const char *fmt, ...) 17878{ 17879 size_t ret; 17880 va_list ap; 17881 17882 va_start(ap, fmt); 17883 ret = vsnprintf(str, count, fmt, ap); 17884 va_end(ap); 17885 return ret; 17886} 17887 17888int 17889main (void) 17890{ 17891 17892char x[1]; 17893if (x_snprintf(x, 1, "%s %d", "hello", 12345) != 11) 17894 return 1; 17895if (x_snprintf(NULL, 0, "%s %d", "hello", 12345) != 11) 17896 return 1; 17897return 0; 17898 17899 ; 17900 return 0; 17901} 17902_ACEOF 17903if ac_fn_c_try_run "$LINENO" 17904then : 17905 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 17906printf "%s\n" "yes" >&6; } 17907else $as_nop 17908 17909 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 17910printf "%s\n" "no" >&6; } 17911 17912printf "%s\n" "#define BROKEN_SNPRINTF 1" >>confdefs.h 17913 17914 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: ****** Your vsnprintf() function is broken, complain to your vendor" >&5 17915printf "%s\n" "$as_me: WARNING: ****** Your vsnprintf() function is broken, complain to your vendor" >&2;} 17916 17917fi 17918rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 17919 conftest.$ac_objext conftest.beam conftest.$ac_ext 17920fi 17921 17922fi 17923 17924# On systems where [v]snprintf is broken, but is declared in stdio, 17925# check that the fmt argument is const char * or just char *. 17926# This is only useful for when BROKEN_SNPRINTF 17927{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether snprintf can declare const char *fmt" >&5 17928printf %s "checking whether snprintf can declare const char *fmt... " >&6; } 17929cat confdefs.h - <<_ACEOF >conftest.$ac_ext 17930/* end confdefs.h. */ 17931 17932#include <stdio.h> 17933int snprintf(char *a, size_t b, const char *c, ...) { return 0; } 17934 17935int 17936main (void) 17937{ 17938 17939 snprintf(0, 0, 0); 17940 17941 ; 17942 return 0; 17943} 17944_ACEOF 17945if ac_fn_c_try_compile "$LINENO" 17946then : 17947 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 17948printf "%s\n" "yes" >&6; } 17949 17950printf "%s\n" "#define SNPRINTF_CONST const" >>confdefs.h 17951 17952else $as_nop 17953 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 17954printf "%s\n" "no" >&6; } 17955 printf "%s\n" "#define SNPRINTF_CONST /* not const */" >>confdefs.h 17956 17957fi 17958rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 17959 17960# Check for missing getpeereid (or equiv) support 17961NO_PEERCHECK="" 17962if test "x$ac_cv_func_getpeereid" != "xyes" -a "x$ac_cv_func_getpeerucred" != "xyes"; then 17963 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether system supports SO_PEERCRED getsockopt" >&5 17964printf %s "checking whether system supports SO_PEERCRED getsockopt... " >&6; } 17965 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 17966/* end confdefs.h. */ 17967 17968#include <sys/types.h> 17969#include <sys/socket.h> 17970int 17971main (void) 17972{ 17973int i = SO_PEERCRED; 17974 ; 17975 return 0; 17976} 17977_ACEOF 17978if ac_fn_c_try_compile "$LINENO" 17979then : 17980 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 17981printf "%s\n" "yes" >&6; } 17982 17983printf "%s\n" "#define HAVE_SO_PEERCRED 1" >>confdefs.h 17984 17985 17986else $as_nop 17987 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 17988printf "%s\n" "no" >&6; } 17989 NO_PEERCHECK=1 17990 17991fi 17992rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 17993fi 17994 17995if test ! -z "$check_for_openpty_ctty_bug"; then 17996 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if openpty correctly handles controlling tty" >&5 17997printf %s "checking if openpty correctly handles controlling tty... " >&6; } 17998 if test "$cross_compiling" = yes 17999then : 18000 18001 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: cross-compiling, assuming yes" >&5 18002printf "%s\n" "cross-compiling, assuming yes" >&6; } 18003 18004 18005else $as_nop 18006 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 18007/* end confdefs.h. */ 18008 18009#include <stdio.h> 18010#include <stdlib.h> 18011#include <unistd.h> 18012#ifdef HAVE_PTY_H 18013# include <pty.h> 18014#endif 18015#include <sys/fcntl.h> 18016#include <sys/types.h> 18017#include <sys/wait.h> 18018 18019int 18020main (void) 18021{ 18022 18023 pid_t pid; 18024 int fd, ptyfd, ttyfd, status; 18025 18026 pid = fork(); 18027 if (pid < 0) { /* failed */ 18028 exit(1); 18029 } else if (pid > 0) { /* parent */ 18030 waitpid(pid, &status, 0); 18031 if (WIFEXITED(status)) 18032 exit(WEXITSTATUS(status)); 18033 else 18034 exit(2); 18035 } else { /* child */ 18036 close(0); close(1); close(2); 18037 setsid(); 18038 openpty(&ptyfd, &ttyfd, NULL, NULL, NULL); 18039 fd = open("/dev/tty", O_RDWR | O_NOCTTY); 18040 if (fd >= 0) 18041 exit(3); /* Acquired ctty: broken */ 18042 else 18043 exit(0); /* Did not acquire ctty: OK */ 18044 } 18045 18046 ; 18047 return 0; 18048} 18049_ACEOF 18050if ac_fn_c_try_run "$LINENO" 18051then : 18052 18053 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 18054printf "%s\n" "yes" >&6; } 18055 18056else $as_nop 18057 18058 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 18059printf "%s\n" "no" >&6; } 18060 printf "%s\n" "#define SSHD_ACQUIRES_CTTY 1" >>confdefs.h 18061 18062 18063fi 18064rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 18065 conftest.$ac_objext conftest.beam conftest.$ac_ext 18066fi 18067 18068fi 18069 18070if test "x$ac_cv_func_getaddrinfo" = "xyes" && \ 18071 test "x$check_for_hpux_broken_getaddrinfo" = "x1"; then 18072 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if getaddrinfo seems to work" >&5 18073printf %s "checking if getaddrinfo seems to work... " >&6; } 18074 if test "$cross_compiling" = yes 18075then : 18076 18077 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: cross-compiling, assuming yes" >&5 18078printf "%s\n" "cross-compiling, assuming yes" >&6; } 18079 18080 18081else $as_nop 18082 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 18083/* end confdefs.h. */ 18084 18085#include <stdio.h> 18086#include <stdlib.h> 18087#include <sys/socket.h> 18088#include <netdb.h> 18089#include <errno.h> 18090#include <netinet/in.h> 18091 18092#define TEST_PORT "2222" 18093 18094int 18095main (void) 18096{ 18097 18098 int err, sock; 18099 struct addrinfo *gai_ai, *ai, hints; 18100 char ntop[NI_MAXHOST], strport[NI_MAXSERV], *name = NULL; 18101 18102 memset(&hints, 0, sizeof(hints)); 18103 hints.ai_family = PF_UNSPEC; 18104 hints.ai_socktype = SOCK_STREAM; 18105 hints.ai_flags = AI_PASSIVE; 18106 18107 err = getaddrinfo(name, TEST_PORT, &hints, &gai_ai); 18108 if (err != 0) { 18109 fprintf(stderr, "getaddrinfo failed (%s)", gai_strerror(err)); 18110 exit(1); 18111 } 18112 18113 for (ai = gai_ai; ai != NULL; ai = ai->ai_next) { 18114 if (ai->ai_family != AF_INET6) 18115 continue; 18116 18117 err = getnameinfo(ai->ai_addr, ai->ai_addrlen, ntop, 18118 sizeof(ntop), strport, sizeof(strport), 18119 NI_NUMERICHOST|NI_NUMERICSERV); 18120 18121 if (err != 0) { 18122 if (err == EAI_SYSTEM) 18123 perror("getnameinfo EAI_SYSTEM"); 18124 else 18125 fprintf(stderr, "getnameinfo failed: %s\n", 18126 gai_strerror(err)); 18127 exit(2); 18128 } 18129 18130 sock = socket(ai->ai_family, ai->ai_socktype, ai->ai_protocol); 18131 if (sock < 0) 18132 perror("socket"); 18133 if (bind(sock, ai->ai_addr, ai->ai_addrlen) < 0) { 18134 if (errno == EBADF) 18135 exit(3); 18136 } 18137 } 18138 exit(0); 18139 18140 ; 18141 return 0; 18142} 18143_ACEOF 18144if ac_fn_c_try_run "$LINENO" 18145then : 18146 18147 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 18148printf "%s\n" "yes" >&6; } 18149 18150else $as_nop 18151 18152 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 18153printf "%s\n" "no" >&6; } 18154 printf "%s\n" "#define BROKEN_GETADDRINFO 1" >>confdefs.h 18155 18156 18157fi 18158rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 18159 conftest.$ac_objext conftest.beam conftest.$ac_ext 18160fi 18161 18162fi 18163 18164if test "x$ac_cv_func_getaddrinfo" = "xyes" && \ 18165 test "x$check_for_aix_broken_getaddrinfo" = "x1"; then 18166 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if getaddrinfo seems to work" >&5 18167printf %s "checking if getaddrinfo seems to work... " >&6; } 18168 if test "$cross_compiling" = yes 18169then : 18170 18171 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: cross-compiling, assuming no" >&5 18172printf "%s\n" "cross-compiling, assuming no" >&6; } 18173 18174 18175else $as_nop 18176 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 18177/* end confdefs.h. */ 18178 18179#include <stdio.h> 18180#include <stdlib.h> 18181#include <sys/socket.h> 18182#include <netdb.h> 18183#include <errno.h> 18184#include <netinet/in.h> 18185 18186#define TEST_PORT "2222" 18187 18188int 18189main (void) 18190{ 18191 18192 int err, sock; 18193 struct addrinfo *gai_ai, *ai, hints; 18194 char ntop[NI_MAXHOST], strport[NI_MAXSERV], *name = NULL; 18195 18196 memset(&hints, 0, sizeof(hints)); 18197 hints.ai_family = PF_UNSPEC; 18198 hints.ai_socktype = SOCK_STREAM; 18199 hints.ai_flags = AI_PASSIVE; 18200 18201 err = getaddrinfo(name, TEST_PORT, &hints, &gai_ai); 18202 if (err != 0) { 18203 fprintf(stderr, "getaddrinfo failed (%s)", gai_strerror(err)); 18204 exit(1); 18205 } 18206 18207 for (ai = gai_ai; ai != NULL; ai = ai->ai_next) { 18208 if (ai->ai_family != AF_INET && ai->ai_family != AF_INET6) 18209 continue; 18210 18211 err = getnameinfo(ai->ai_addr, ai->ai_addrlen, ntop, 18212 sizeof(ntop), strport, sizeof(strport), 18213 NI_NUMERICHOST|NI_NUMERICSERV); 18214 18215 if (ai->ai_family == AF_INET && err != 0) { 18216 perror("getnameinfo"); 18217 exit(2); 18218 } 18219 } 18220 exit(0); 18221 18222 ; 18223 return 0; 18224} 18225_ACEOF 18226if ac_fn_c_try_run "$LINENO" 18227then : 18228 18229 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 18230printf "%s\n" "yes" >&6; } 18231 18232printf "%s\n" "#define AIX_GETNAMEINFO_HACK 1" >>confdefs.h 18233 18234 18235else $as_nop 18236 18237 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 18238printf "%s\n" "no" >&6; } 18239 printf "%s\n" "#define BROKEN_GETADDRINFO 1" >>confdefs.h 18240 18241 18242fi 18243rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 18244 conftest.$ac_objext conftest.beam conftest.$ac_ext 18245fi 18246 18247fi 18248 18249if test "x$ac_cv_func_getaddrinfo" = "xyes"; then 18250 ac_fn_check_decl "$LINENO" "AI_NUMERICSERV" "ac_cv_have_decl_AI_NUMERICSERV" "#include <sys/types.h> 18251 #include <sys/socket.h> 18252 #include <netdb.h> 18253" "$ac_c_undeclared_builtin_options" "CFLAGS" 18254if test "x$ac_cv_have_decl_AI_NUMERICSERV" = xyes 18255then : 18256 ac_have_decl=1 18257else $as_nop 18258 ac_have_decl=0 18259fi 18260printf "%s\n" "#define HAVE_DECL_AI_NUMERICSERV $ac_have_decl" >>confdefs.h 18261 18262fi 18263 18264if test "x$check_for_conflicting_getspnam" = "x1"; then 18265 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for conflicting getspnam in shadow.h" >&5 18266printf %s "checking for conflicting getspnam in shadow.h... " >&6; } 18267 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 18268/* end confdefs.h. */ 18269 18270#include <shadow.h> 18271#include <stdlib.h> 18272 18273int 18274main (void) 18275{ 18276 exit(0); 18277 ; 18278 return 0; 18279} 18280_ACEOF 18281if ac_fn_c_try_compile "$LINENO" 18282then : 18283 18284 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 18285printf "%s\n" "no" >&6; } 18286 18287else $as_nop 18288 18289 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 18290printf "%s\n" "yes" >&6; } 18291 18292printf "%s\n" "#define GETSPNAM_CONFLICTING_DEFS 1" >>confdefs.h 18293 18294 18295 18296fi 18297rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 18298fi 18299 18300if test "x$ac_cv_func_strnvis" = "xyes"; then 18301 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working strnvis" >&5 18302printf %s "checking for working strnvis... " >&6; } 18303 if test "$cross_compiling" = yes 18304then : 18305 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: assuming broken" >&5 18306printf "%s\n" "$as_me: WARNING: cross compiling: assuming broken" >&2;} 18307 18308printf "%s\n" "#define BROKEN_STRNVIS 1" >>confdefs.h 18309 18310 18311else $as_nop 18312 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 18313/* end confdefs.h. */ 18314 18315#include <signal.h> 18316#include <stdlib.h> 18317#include <string.h> 18318#include <unistd.h> 18319#include <vis.h> 18320static void sighandler(int sig) { _exit(1); } 18321 18322int 18323main (void) 18324{ 18325 18326 char dst[16]; 18327 18328 signal(SIGSEGV, sighandler); 18329 if (strnvis(dst, "src", 4, 0) && strcmp(dst, "src") == 0) 18330 exit(0); 18331 exit(1) 18332 18333 ; 18334 return 0; 18335} 18336_ACEOF 18337if ac_fn_c_try_run "$LINENO" 18338then : 18339 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 18340printf "%s\n" "yes" >&6; } 18341else $as_nop 18342 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 18343printf "%s\n" "no" >&6; } 18344 18345printf "%s\n" "#define BROKEN_STRNVIS 1" >>confdefs.h 18346 18347fi 18348rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 18349 conftest.$ac_objext conftest.beam conftest.$ac_ext 18350fi 18351 18352fi 18353 18354{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if SA_RESTARTed signals interrupt select()" >&5 18355printf %s "checking if SA_RESTARTed signals interrupt select()... " >&6; } 18356if test "$cross_compiling" = yes 18357then : 18358 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: assuming yes" >&5 18359printf "%s\n" "$as_me: WARNING: cross compiling: assuming yes" >&2;} 18360 18361else $as_nop 18362 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 18363/* end confdefs.h. */ 18364 18365#ifdef HAVE_SYS_SELECT 18366# include <sys/select.h> 18367#endif 18368#include <sys/types.h> 18369#include <sys/time.h> 18370#include <stdlib.h> 18371#include <signal.h> 18372#include <unistd.h> 18373static void sighandler(int sig) { } 18374 18375int 18376main (void) 18377{ 18378 18379 int r; 18380 pid_t pid; 18381 struct sigaction sa; 18382 18383 sa.sa_handler = sighandler; 18384 sa.sa_flags = SA_RESTART; 18385 (void)sigaction(SIGTERM, &sa, NULL); 18386 if ((pid = fork()) == 0) { /* child */ 18387 pid = getppid(); 18388 sleep(1); 18389 kill(pid, SIGTERM); 18390 sleep(1); 18391 if (getppid() == pid) /* if parent did not exit, shoot it */ 18392 kill(pid, SIGKILL); 18393 exit(0); 18394 } else { /* parent */ 18395 r = select(0, NULL, NULL, NULL, NULL); 18396 } 18397 exit(r == -1 ? 0 : 1); 18398 18399 ; 18400 return 0; 18401} 18402_ACEOF 18403if ac_fn_c_try_run "$LINENO" 18404then : 18405 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 18406printf "%s\n" "yes" >&6; } 18407else $as_nop 18408 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 18409printf "%s\n" "no" >&6; } 18410 18411printf "%s\n" "#define NO_SA_RESTART 1" >>confdefs.h 18412 18413fi 18414rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 18415 conftest.$ac_objext conftest.beam conftest.$ac_ext 18416fi 18417 18418 18419 18420 for ac_func in getpgrp 18421do : 18422 ac_fn_c_check_func "$LINENO" "getpgrp" "ac_cv_func_getpgrp" 18423if test "x$ac_cv_func_getpgrp" = xyes 18424then : 18425 printf "%s\n" "#define HAVE_GETPGRP 1" >>confdefs.h 18426 18427 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if getpgrp accepts zero args" >&5 18428printf %s "checking if getpgrp accepts zero args... " >&6; } 18429 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 18430/* end confdefs.h. */ 18431$ac_includes_default 18432int 18433main (void) 18434{ 18435 getpgrp(); 18436 ; 18437 return 0; 18438} 18439_ACEOF 18440if ac_fn_c_try_compile "$LINENO" 18441then : 18442 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 18443printf "%s\n" "yes" >&6; } 18444 18445printf "%s\n" "#define GETPGRP_VOID 1" >>confdefs.h 18446 18447else $as_nop 18448 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 18449printf "%s\n" "no" >&6; } 18450 18451printf "%s\n" "#define GETPGRP_VOID 0" >>confdefs.h 18452 18453 18454fi 18455rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 18456 18457fi 18458 18459done 18460 18461# Search for OpenSSL 18462saved_CPPFLAGS="$CPPFLAGS" 18463saved_LDFLAGS="$LDFLAGS" 18464openssl_bin_PATH="$PATH" 18465 18466# Check whether --with-ssl-dir was given. 18467if test ${with_ssl_dir+y} 18468then : 18469 withval=$with_ssl_dir; 18470 if test "x$openssl" = "xno" ; then 18471 as_fn_error $? "cannot use --with-ssl-dir when OpenSSL disabled" "$LINENO" 5 18472 fi 18473 if test "x$withval" != "xno" ; then 18474 case "$withval" in 18475 # Relative paths 18476 ./*|../*) withval="`pwd`/$withval" 18477 esac 18478 if test -d "$withval/lib"; then 18479 libcrypto_path="${withval}/lib" 18480 elif test -d "$withval/lib64"; then 18481 libcrypto_path="$withval/lib64" 18482 else 18483 # Built but not installed 18484 libcrypto_path="${withval}" 18485 fi 18486 if test -n "${rpath_opt}"; then 18487 LDFLAGS="-L${libcrypto_path} ${rpath_opt}${libcrypto_path} ${LDFLAGS}" 18488 else 18489 LDFLAGS="-L${libcrypto_path} ${LDFLAGS}" 18490 fi 18491 if test -d "$withval/include"; then 18492 CPPFLAGS="-I${withval}/include ${CPPFLAGS}" 18493 else 18494 CPPFLAGS="-I${withval} ${CPPFLAGS}" 18495 fi 18496 if test -x "${withval}/bin/openssl" && \ 18497 "${withval}/bin/openssl" version >/dev/null 2>&1; then 18498 openssl_bin_PATH="${withval}/bin${PATH_SEPARATOR}${PATH}" 18499 elif test -x "${withval}/apps/openssl" && \ 18500 "${withval}/apps/openssl" version >/dev/null 2>&1; then 18501 openssl_bin_PATH="${withval}/apps${PATH_SEPARATOR}${PATH}" 18502 fi 18503 fi 18504 18505 18506fi 18507 18508for ac_prog in openssl 18509do 18510 # Extract the first word of "$ac_prog", so it can be a program name with args. 18511set dummy $ac_prog; ac_word=$2 18512{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 18513printf %s "checking for $ac_word... " >&6; } 18514if test ${ac_cv_path_openssl_bin+y} 18515then : 18516 printf %s "(cached) " >&6 18517else $as_nop 18518 case $openssl_bin in 18519 [\\/]* | ?:[\\/]*) 18520 ac_cv_path_openssl_bin="$openssl_bin" # Let the user override the test with a path. 18521 ;; 18522 *) 18523 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 18524for as_dir in $openssl_bin_PATH 18525do 18526 IFS=$as_save_IFS 18527 case $as_dir in #((( 18528 '') as_dir=./ ;; 18529 */) ;; 18530 *) as_dir=$as_dir/ ;; 18531 esac 18532 for ac_exec_ext in '' $ac_executable_extensions; do 18533 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 18534 ac_cv_path_openssl_bin="$as_dir$ac_word$ac_exec_ext" 18535 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 18536 break 2 18537 fi 18538done 18539 done 18540IFS=$as_save_IFS 18541 18542 ;; 18543esac 18544fi 18545openssl_bin=$ac_cv_path_openssl_bin 18546if test -n "$openssl_bin"; then 18547 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $openssl_bin" >&5 18548printf "%s\n" "$openssl_bin" >&6; } 18549else 18550 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 18551printf "%s\n" "no" >&6; } 18552fi 18553 18554 18555 test -n "$openssl_bin" && break 18556done 18557 18558OPENSSL_BIN=${openssl_bin} 18559 18560 18561 18562# Check whether --with-openssl-header-check was given. 18563if test ${with_openssl_header_check+y} 18564then : 18565 withval=$with_openssl_header_check; 18566 if test "x$withval" = "xno" ; then 18567 openssl_check_nonfatal=1 18568 fi 18569 18570 18571fi 18572 18573 18574openssl_engine=no 18575 18576# Check whether --with-ssl-engine was given. 18577if test ${with_ssl_engine+y} 18578then : 18579 withval=$with_ssl_engine; 18580 if test "x$withval" != "xno" ; then 18581 if test "x$openssl" = "xno" ; then 18582 as_fn_error $? "cannot use --with-ssl-engine when OpenSSL disabled" "$LINENO" 5 18583 fi 18584 openssl_engine=yes 18585 fi 18586 18587 18588fi 18589 18590 18591nocrypto_saved_LIBS="$LIBS" 18592if test "x$openssl" = "xyes" ; then 18593 LIBS="-L/usr/lib/priv -lprivate_crypto $LIBS" 18594 CHANNELLIBS="-L/usr/lib/priv -lprivate_crypto $CHANNELLIBS" 18595 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 18596/* end confdefs.h. */ 18597 18598/* Override any GCC internal prototype to avoid an error. 18599 Use char because int might match the return type of a GCC 18600 builtin and then its argument prototype would still apply. */ 18601char RAND_add (); 18602int 18603main (void) 18604{ 18605return RAND_add (); 18606 ; 18607 return 0; 18608} 18609_ACEOF 18610if ac_fn_c_try_link "$LINENO" 18611then : 18612 18613else $as_nop 18614 as_fn_error $? "*** working libcrypto not found, check config.log" "$LINENO" 5 18615fi 18616rm -f core conftest.err conftest.$ac_objext conftest.beam \ 18617 conftest$ac_exeext conftest.$ac_ext 18618 ac_fn_c_check_header_compile "$LINENO" "openssl/opensslv.h" "ac_cv_header_openssl_opensslv_h" "$ac_includes_default" 18619if test "x$ac_cv_header_openssl_opensslv_h" = xyes 18620then : 18621 18622else $as_nop 18623 as_fn_error $? "*** OpenSSL headers missing - please install first or check config.log ***" "$LINENO" 5 18624fi 18625 18626 18627 # Determine OpenSSL header version 18628 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking OpenSSL header version" >&5 18629printf %s "checking OpenSSL header version... " >&6; } 18630 if test "$cross_compiling" = yes 18631then : 18632 18633 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: not checking" >&5 18634printf "%s\n" "$as_me: WARNING: cross compiling: not checking" >&2;} 18635 18636 18637else $as_nop 18638 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 18639/* end confdefs.h. */ 18640 18641 #include <stdlib.h> 18642 #include <stdio.h> 18643 #include <string.h> 18644 #include <openssl/opensslv.h> 18645 #define DATA "conftest.sslincver" 18646 18647int 18648main (void) 18649{ 18650 18651 FILE *fd; 18652 int rc; 18653 18654 fd = fopen(DATA,"w"); 18655 if(fd == NULL) 18656 exit(1); 18657 18658 if ((rc = fprintf(fd, "%08lx (%s)\n", 18659 (unsigned long)OPENSSL_VERSION_NUMBER, 18660 OPENSSL_VERSION_TEXT)) < 0) 18661 exit(1); 18662 18663 exit(0); 18664 18665 ; 18666 return 0; 18667} 18668_ACEOF 18669if ac_fn_c_try_run "$LINENO" 18670then : 18671 18672 ssl_header_ver=`cat conftest.sslincver` 18673 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ssl_header_ver" >&5 18674printf "%s\n" "$ssl_header_ver" >&6; } 18675 18676else $as_nop 18677 18678 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: failed" >&5 18679printf "%s\n" "failed" >&6; } 18680 as_fn_error $? "OpenSSL version test program failed." "$LINENO" 5 18681 18682fi 18683rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 18684 conftest.$ac_objext conftest.beam conftest.$ac_ext 18685fi 18686 18687 18688 # Determining OpenSSL library version is version dependent. 18689 ac_fn_c_check_func "$LINENO" "OpenSSL_version" "ac_cv_func_OpenSSL_version" 18690if test "x$ac_cv_func_OpenSSL_version" = xyes 18691then : 18692 printf "%s\n" "#define HAVE_OPENSSL_VERSION 1" >>confdefs.h 18693 18694fi 18695ac_fn_c_check_func "$LINENO" "OpenSSL_version_num" "ac_cv_func_OpenSSL_version_num" 18696if test "x$ac_cv_func_OpenSSL_version_num" = xyes 18697then : 18698 printf "%s\n" "#define HAVE_OPENSSL_VERSION_NUM 1" >>confdefs.h 18699 18700fi 18701 18702 18703 # Determine OpenSSL library version 18704 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking OpenSSL library version" >&5 18705printf %s "checking OpenSSL library version... " >&6; } 18706 if test "$cross_compiling" = yes 18707then : 18708 18709 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: not checking" >&5 18710printf "%s\n" "$as_me: WARNING: cross compiling: not checking" >&2;} 18711 18712 18713else $as_nop 18714 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 18715/* end confdefs.h. */ 18716 18717 #include <stdio.h> 18718 #include <stdlib.h> 18719 #include <string.h> 18720 #include <openssl/opensslv.h> 18721 #include <openssl/crypto.h> 18722 #define DATA "conftest.ssllibver" 18723 18724int 18725main (void) 18726{ 18727 18728 FILE *f; 18729 /* We need these legacy bits to warn for old libcrypto */ 18730 #ifndef OPENSSL_VERSION 18731 # define OPENSSL_VERSION SSLEAY_VERSION 18732 #endif 18733 #ifndef HAVE_OPENSSL_VERSION 18734 # define OpenSSL_version SSLeay_version 18735 #endif 18736 #ifndef HAVE_OPENSSL_VERSION_NUM 18737 # define OpenSSL_version_num SSLeay 18738 #endif 18739 if ((f = fopen(DATA, "w")) == NULL) 18740 exit(1); 18741 if (fprintf(f, "%08lx (%s)", 18742 (unsigned long)OpenSSL_version_num(), 18743 OpenSSL_version(OPENSSL_VERSION)) < 0) 18744 exit(1); 18745#ifdef LIBRESSL_VERSION_NUMBER 18746 if (fprintf(f, " libressl-%08lx", LIBRESSL_VERSION_NUMBER) < 0) 18747 exit(1); 18748#endif 18749 if (fputc('\n', f) == EOF || fclose(f) == EOF) 18750 exit(1); 18751 exit(0); 18752 18753 ; 18754 return 0; 18755} 18756_ACEOF 18757if ac_fn_c_try_run "$LINENO" 18758then : 18759 18760 sslver=`cat conftest.ssllibver` 18761 ssl_showver=`echo "$sslver" | sed 's/ libressl-.*//'` 18762 # Check version is supported. 18763 case "$sslver" in 18764 100*|10100*) # 1.0.x, 1.1.0x 18765 as_fn_error $? "OpenSSL >= 1.1.1 required (have \"$ssl_showver\")" "$LINENO" 5 18766 ;; 18767 101*) ;; # 1.1.x 18768 200*) # LibreSSL 18769 lver=`echo "$sslver" | sed 's/.*libressl-//'` 18770 case "$lver" in 18771 2*|300*) # 2.x, 3.0.0 18772 as_fn_error $? "LibreSSL >= 3.1.0 required (have \"$ssl_showver\")" "$LINENO" 5 18773 ;; 18774 *) ;; # Assume all other versions are good. 18775 esac 18776 ;; 18777 30*) 18778 # OpenSSL 3; we use the 1.1x API 18779 # https://openssl.org/policies/general/versioning-policy.html 18780 CPPFLAGS="$CPPFLAGS -DOPENSSL_API_COMPAT=0x10100000L" 18781 ;; 18782 *) 18783 as_fn_error $? "Unknown/unsupported OpenSSL version (\"$ssl_showver\")" "$LINENO" 5 18784 ;; 18785 esac 18786 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ssl_showver" >&5 18787printf "%s\n" "$ssl_showver" >&6; } 18788 18789else $as_nop 18790 18791 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not found" >&5 18792printf "%s\n" "not found" >&6; } 18793 as_fn_error $? "OpenSSL library not found." "$LINENO" 5 18794 18795fi 18796rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 18797 conftest.$ac_objext conftest.beam conftest.$ac_ext 18798fi 18799 18800 18801 case "$host" in 18802 x86_64-*) 18803 case "$sslver" in 18804 3000004*) 18805 as_fn_error $? "OpenSSL 3.0.4 has a potential RCE in its RSA implementation (CVE-2022-2274)" "$LINENO" 5 18806 ;; 18807 esac 18808 esac 18809 18810 # Sanity check OpenSSL headers 18811 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether OpenSSL's headers match the library" >&5 18812printf %s "checking whether OpenSSL's headers match the library... " >&6; } 18813 if test "$cross_compiling" = yes 18814then : 18815 18816 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: not checking" >&5 18817printf "%s\n" "$as_me: WARNING: cross compiling: not checking" >&2;} 18818 18819 18820else $as_nop 18821 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 18822/* end confdefs.h. */ 18823 18824 #include <stdlib.h> 18825 #include <string.h> 18826 #include <openssl/opensslv.h> 18827 #include <openssl/crypto.h> 18828 18829int 18830main (void) 18831{ 18832 18833 exit(OpenSSL_version_num() == OPENSSL_VERSION_NUMBER ? 0 : 1); 18834 18835 ; 18836 return 0; 18837} 18838_ACEOF 18839if ac_fn_c_try_run "$LINENO" 18840then : 18841 18842 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 18843printf "%s\n" "yes" >&6; } 18844 18845else $as_nop 18846 18847 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 18848printf "%s\n" "no" >&6; } 18849 if test "x$openssl_check_nonfatal" = "x"; then 18850 as_fn_error $? "Your OpenSSL headers do not match your 18851 library. Check config.log for details. 18852 If you are sure your installation is consistent, you can disable the check 18853 by running \"./configure --without-openssl-header-check\". 18854 Also see contrib/findssl.sh for help identifying header/library mismatches. 18855 " "$LINENO" 5 18856 else 18857 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Your OpenSSL headers do not match your 18858 library. Check config.log for details. 18859 Also see contrib/findssl.sh for help identifying header/library mismatches." >&5 18860printf "%s\n" "$as_me: WARNING: Your OpenSSL headers do not match your 18861 library. Check config.log for details. 18862 Also see contrib/findssl.sh for help identifying header/library mismatches." >&2;} 18863 fi 18864 18865fi 18866rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 18867 conftest.$ac_objext conftest.beam conftest.$ac_ext 18868fi 18869 18870 18871 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if programs using OpenSSL functions will link" >&5 18872printf %s "checking if programs using OpenSSL functions will link... " >&6; } 18873 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 18874/* end confdefs.h. */ 18875 #include <openssl/err.h> 18876int 18877main (void) 18878{ 18879 ERR_load_crypto_strings(); 18880 ; 18881 return 0; 18882} 18883_ACEOF 18884if ac_fn_c_try_link "$LINENO" 18885then : 18886 18887 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 18888printf "%s\n" "yes" >&6; } 18889 18890else $as_nop 18891 18892 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 18893printf "%s\n" "no" >&6; } 18894 LIBS="$LIBS -ldl" 18895 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if programs using OpenSSL need -ldl" >&5 18896printf %s "checking if programs using OpenSSL need -ldl... " >&6; } 18897 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 18898/* end confdefs.h. */ 18899 #include <openssl/err.h> 18900int 18901main (void) 18902{ 18903 ERR_load_crypto_strings(); 18904 ; 18905 return 0; 18906} 18907_ACEOF 18908if ac_fn_c_try_link "$LINENO" 18909then : 18910 18911 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 18912printf "%s\n" "yes" >&6; } 18913 CHANNELLIBS="$CHANNELLIBS -ldl" 18914 18915else $as_nop 18916 18917 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 18918printf "%s\n" "no" >&6; } 18919 18920 18921fi 18922rm -f core conftest.err conftest.$ac_objext conftest.beam \ 18923 conftest$ac_exeext conftest.$ac_ext 18924 18925 18926fi 18927rm -f core conftest.err conftest.$ac_objext conftest.beam \ 18928 conftest$ac_exeext conftest.$ac_ext 18929 18930 ac_fn_c_check_func "$LINENO" "BN_is_prime_ex" "ac_cv_func_BN_is_prime_ex" 18931if test "x$ac_cv_func_BN_is_prime_ex" = xyes 18932then : 18933 printf "%s\n" "#define HAVE_BN_IS_PRIME_EX 1" >>confdefs.h 18934 18935fi 18936ac_fn_c_check_func "$LINENO" "DES_crypt" "ac_cv_func_DES_crypt" 18937if test "x$ac_cv_func_DES_crypt" = xyes 18938then : 18939 printf "%s\n" "#define HAVE_DES_CRYPT 1" >>confdefs.h 18940 18941fi 18942ac_fn_c_check_func "$LINENO" "DSA_generate_parameters_ex" "ac_cv_func_DSA_generate_parameters_ex" 18943if test "x$ac_cv_func_DSA_generate_parameters_ex" = xyes 18944then : 18945 printf "%s\n" "#define HAVE_DSA_GENERATE_PARAMETERS_EX 1" >>confdefs.h 18946 18947fi 18948ac_fn_c_check_func "$LINENO" "EVP_DigestFinal_ex" "ac_cv_func_EVP_DigestFinal_ex" 18949if test "x$ac_cv_func_EVP_DigestFinal_ex" = xyes 18950then : 18951 printf "%s\n" "#define HAVE_EVP_DIGESTFINAL_EX 1" >>confdefs.h 18952 18953fi 18954ac_fn_c_check_func "$LINENO" "EVP_DigestInit_ex" "ac_cv_func_EVP_DigestInit_ex" 18955if test "x$ac_cv_func_EVP_DigestInit_ex" = xyes 18956then : 18957 printf "%s\n" "#define HAVE_EVP_DIGESTINIT_EX 1" >>confdefs.h 18958 18959fi 18960ac_fn_c_check_func "$LINENO" "EVP_MD_CTX_cleanup" "ac_cv_func_EVP_MD_CTX_cleanup" 18961if test "x$ac_cv_func_EVP_MD_CTX_cleanup" = xyes 18962then : 18963 printf "%s\n" "#define HAVE_EVP_MD_CTX_CLEANUP 1" >>confdefs.h 18964 18965fi 18966ac_fn_c_check_func "$LINENO" "EVP_MD_CTX_copy_ex" "ac_cv_func_EVP_MD_CTX_copy_ex" 18967if test "x$ac_cv_func_EVP_MD_CTX_copy_ex" = xyes 18968then : 18969 printf "%s\n" "#define HAVE_EVP_MD_CTX_COPY_EX 1" >>confdefs.h 18970 18971fi 18972ac_fn_c_check_func "$LINENO" "EVP_MD_CTX_init" "ac_cv_func_EVP_MD_CTX_init" 18973if test "x$ac_cv_func_EVP_MD_CTX_init" = xyes 18974then : 18975 printf "%s\n" "#define HAVE_EVP_MD_CTX_INIT 1" >>confdefs.h 18976 18977fi 18978ac_fn_c_check_func "$LINENO" "HMAC_CTX_init" "ac_cv_func_HMAC_CTX_init" 18979if test "x$ac_cv_func_HMAC_CTX_init" = xyes 18980then : 18981 printf "%s\n" "#define HAVE_HMAC_CTX_INIT 1" >>confdefs.h 18982 18983fi 18984ac_fn_c_check_func "$LINENO" "RSA_generate_key_ex" "ac_cv_func_RSA_generate_key_ex" 18985if test "x$ac_cv_func_RSA_generate_key_ex" = xyes 18986then : 18987 printf "%s\n" "#define HAVE_RSA_GENERATE_KEY_EX 1" >>confdefs.h 18988 18989fi 18990ac_fn_c_check_func "$LINENO" "RSA_get_default_method" "ac_cv_func_RSA_get_default_method" 18991if test "x$ac_cv_func_RSA_get_default_method" = xyes 18992then : 18993 printf "%s\n" "#define HAVE_RSA_GET_DEFAULT_METHOD 1" >>confdefs.h 18994 18995fi 18996 18997 18998 # OpenSSL_add_all_algorithms may be a macro. 18999 ac_fn_c_check_func "$LINENO" "OpenSSL_add_all_algorithms" "ac_cv_func_OpenSSL_add_all_algorithms" 19000if test "x$ac_cv_func_OpenSSL_add_all_algorithms" = xyes 19001then : 19002 19003printf "%s\n" "#define HAVE_OPENSSL_ADD_ALL_ALGORITHMS 1" >>confdefs.h 19004 19005else $as_nop 19006 ac_fn_check_decl "$LINENO" "OpenSSL_add_all_algorithms" "ac_cv_have_decl_OpenSSL_add_all_algorithms" "#include <openssl/evp.h> 19007 19008" "$ac_c_undeclared_builtin_options" "CFLAGS" 19009if test "x$ac_cv_have_decl_OpenSSL_add_all_algorithms" = xyes 19010then : 19011 19012printf "%s\n" "#define HAVE_OPENSSL_ADD_ALL_ALGORITHMS 1" >>confdefs.h 19013 19014fi 19015 19016fi 19017 19018 19019 # LibreSSL/OpenSSL API differences 19020 ac_fn_c_check_func "$LINENO" "EVP_CIPHER_CTX_iv" "ac_cv_func_EVP_CIPHER_CTX_iv" 19021if test "x$ac_cv_func_EVP_CIPHER_CTX_iv" = xyes 19022then : 19023 printf "%s\n" "#define HAVE_EVP_CIPHER_CTX_IV 1" >>confdefs.h 19024 19025fi 19026ac_fn_c_check_func "$LINENO" "EVP_CIPHER_CTX_iv_noconst" "ac_cv_func_EVP_CIPHER_CTX_iv_noconst" 19027if test "x$ac_cv_func_EVP_CIPHER_CTX_iv_noconst" = xyes 19028then : 19029 printf "%s\n" "#define HAVE_EVP_CIPHER_CTX_IV_NOCONST 1" >>confdefs.h 19030 19031fi 19032ac_fn_c_check_func "$LINENO" "EVP_CIPHER_CTX_get_iv" "ac_cv_func_EVP_CIPHER_CTX_get_iv" 19033if test "x$ac_cv_func_EVP_CIPHER_CTX_get_iv" = xyes 19034then : 19035 printf "%s\n" "#define HAVE_EVP_CIPHER_CTX_GET_IV 1" >>confdefs.h 19036 19037fi 19038ac_fn_c_check_func "$LINENO" "EVP_CIPHER_CTX_get_updated_iv" "ac_cv_func_EVP_CIPHER_CTX_get_updated_iv" 19039if test "x$ac_cv_func_EVP_CIPHER_CTX_get_updated_iv" = xyes 19040then : 19041 printf "%s\n" "#define HAVE_EVP_CIPHER_CTX_GET_UPDATED_IV 1" >>confdefs.h 19042 19043fi 19044ac_fn_c_check_func "$LINENO" "EVP_CIPHER_CTX_set_iv" "ac_cv_func_EVP_CIPHER_CTX_set_iv" 19045if test "x$ac_cv_func_EVP_CIPHER_CTX_set_iv" = xyes 19046then : 19047 printf "%s\n" "#define HAVE_EVP_CIPHER_CTX_SET_IV 1" >>confdefs.h 19048 19049fi 19050 19051 19052 if test "x$openssl_engine" = "xyes" ; then 19053 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for OpenSSL ENGINE support" >&5 19054printf %s "checking for OpenSSL ENGINE support... " >&6; } 19055 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 19056/* end confdefs.h. */ 19057 19058 #include <openssl/engine.h> 19059 19060int 19061main (void) 19062{ 19063 19064 ENGINE_load_builtin_engines(); 19065 ENGINE_register_all_complete(); 19066 19067 ; 19068 return 0; 19069} 19070_ACEOF 19071if ac_fn_c_try_compile "$LINENO" 19072then : 19073 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 19074printf "%s\n" "yes" >&6; } 19075 19076printf "%s\n" "#define USE_OPENSSL_ENGINE 1" >>confdefs.h 19077 19078 19079else $as_nop 19080 as_fn_error $? "OpenSSL ENGINE support not found" "$LINENO" 5 19081 19082fi 19083rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 19084 fi 19085 19086 # Check for OpenSSL without EVP_aes_{192,256}_cbc 19087 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether OpenSSL lacks support for AES 192/256" >&5 19088printf %s "checking whether OpenSSL lacks support for AES 192/256... " >&6; } 19089 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 19090/* end confdefs.h. */ 19091 19092 #include <stdlib.h> 19093 #include <string.h> 19094 #include <openssl/evp.h> 19095 19096int 19097main (void) 19098{ 19099 19100 exit(EVP_aes_192_cbc() == NULL || EVP_aes_256_cbc() == NULL); 19101 19102 ; 19103 return 0; 19104} 19105_ACEOF 19106if ac_fn_c_try_link "$LINENO" 19107then : 19108 19109 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 19110printf "%s\n" "no" >&6; } 19111 19112else $as_nop 19113 19114 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 19115printf "%s\n" "yes" >&6; } 19116 19117printf "%s\n" "#define OPENSSL_LOBOTOMISED_AES 1" >>confdefs.h 19118 19119 19120 19121fi 19122rm -f core conftest.err conftest.$ac_objext conftest.beam \ 19123 conftest$ac_exeext conftest.$ac_ext 19124 19125 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if EVP_DigestUpdate returns an int" >&5 19126printf %s "checking if EVP_DigestUpdate returns an int... " >&6; } 19127 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 19128/* end confdefs.h. */ 19129 19130 #include <stdlib.h> 19131 #include <string.h> 19132 #include <openssl/evp.h> 19133 19134int 19135main (void) 19136{ 19137 19138 if(EVP_DigestUpdate(NULL, NULL,0)) 19139 exit(0); 19140 19141 ; 19142 return 0; 19143} 19144_ACEOF 19145if ac_fn_c_try_link "$LINENO" 19146then : 19147 19148 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 19149printf "%s\n" "yes" >&6; } 19150 19151else $as_nop 19152 19153 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 19154printf "%s\n" "no" >&6; } 19155 19156printf "%s\n" "#define OPENSSL_EVP_DIGESTUPDATE_VOID 1" >>confdefs.h 19157 19158 19159 19160fi 19161rm -f core conftest.err conftest.$ac_objext conftest.beam \ 19162 conftest$ac_exeext conftest.$ac_ext 19163 19164 # Check for various EVP support in OpenSSL 19165 ac_fn_c_check_func "$LINENO" "EVP_sha256" "ac_cv_func_EVP_sha256" 19166if test "x$ac_cv_func_EVP_sha256" = xyes 19167then : 19168 printf "%s\n" "#define HAVE_EVP_SHA256 1" >>confdefs.h 19169 19170fi 19171ac_fn_c_check_func "$LINENO" "EVP_sha384" "ac_cv_func_EVP_sha384" 19172if test "x$ac_cv_func_EVP_sha384" = xyes 19173then : 19174 printf "%s\n" "#define HAVE_EVP_SHA384 1" >>confdefs.h 19175 19176fi 19177ac_fn_c_check_func "$LINENO" "EVP_sha512" "ac_cv_func_EVP_sha512" 19178if test "x$ac_cv_func_EVP_sha512" = xyes 19179then : 19180 printf "%s\n" "#define HAVE_EVP_SHA512 1" >>confdefs.h 19181 19182fi 19183ac_fn_c_check_func "$LINENO" "EVP_chacha20" "ac_cv_func_EVP_chacha20" 19184if test "x$ac_cv_func_EVP_chacha20" = xyes 19185then : 19186 printf "%s\n" "#define HAVE_EVP_CHACHA20 1" >>confdefs.h 19187 19188fi 19189 19190 19191 # Check complete ECC support in OpenSSL 19192 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether OpenSSL has NID_X9_62_prime256v1" >&5 19193printf %s "checking whether OpenSSL has NID_X9_62_prime256v1... " >&6; } 19194 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 19195/* end confdefs.h. */ 19196 19197 #include <openssl/ec.h> 19198 #include <openssl/ecdh.h> 19199 #include <openssl/ecdsa.h> 19200 #include <openssl/evp.h> 19201 #include <openssl/objects.h> 19202 #include <openssl/opensslv.h> 19203 19204int 19205main (void) 19206{ 19207 19208 EC_KEY *e = EC_KEY_new_by_curve_name(NID_X9_62_prime256v1); 19209 const EVP_MD *m = EVP_sha256(); /* We need this too */ 19210 19211 ; 19212 return 0; 19213} 19214_ACEOF 19215if ac_fn_c_try_link "$LINENO" 19216then : 19217 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 19218printf "%s\n" "yes" >&6; } 19219 enable_nistp256=1 19220else $as_nop 19221 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 19222printf "%s\n" "no" >&6; } 19223 19224fi 19225rm -f core conftest.err conftest.$ac_objext conftest.beam \ 19226 conftest$ac_exeext conftest.$ac_ext 19227 19228 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether OpenSSL has NID_secp384r1" >&5 19229printf %s "checking whether OpenSSL has NID_secp384r1... " >&6; } 19230 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 19231/* end confdefs.h. */ 19232 19233 #include <openssl/ec.h> 19234 #include <openssl/ecdh.h> 19235 #include <openssl/ecdsa.h> 19236 #include <openssl/evp.h> 19237 #include <openssl/objects.h> 19238 #include <openssl/opensslv.h> 19239 19240int 19241main (void) 19242{ 19243 19244 EC_KEY *e = EC_KEY_new_by_curve_name(NID_secp384r1); 19245 const EVP_MD *m = EVP_sha384(); /* We need this too */ 19246 19247 ; 19248 return 0; 19249} 19250_ACEOF 19251if ac_fn_c_try_link "$LINENO" 19252then : 19253 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 19254printf "%s\n" "yes" >&6; } 19255 enable_nistp384=1 19256else $as_nop 19257 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 19258printf "%s\n" "no" >&6; } 19259 19260fi 19261rm -f core conftest.err conftest.$ac_objext conftest.beam \ 19262 conftest$ac_exeext conftest.$ac_ext 19263 19264 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether OpenSSL has NID_secp521r1" >&5 19265printf %s "checking whether OpenSSL has NID_secp521r1... " >&6; } 19266 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 19267/* end confdefs.h. */ 19268 19269 #include <openssl/ec.h> 19270 #include <openssl/ecdh.h> 19271 #include <openssl/ecdsa.h> 19272 #include <openssl/evp.h> 19273 #include <openssl/objects.h> 19274 #include <openssl/opensslv.h> 19275 19276int 19277main (void) 19278{ 19279 19280 EC_KEY *e = EC_KEY_new_by_curve_name(NID_secp521r1); 19281 const EVP_MD *m = EVP_sha512(); /* We need this too */ 19282 19283 ; 19284 return 0; 19285} 19286_ACEOF 19287if ac_fn_c_try_link "$LINENO" 19288then : 19289 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 19290printf "%s\n" "yes" >&6; } 19291 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if OpenSSL's NID_secp521r1 is functional" >&5 19292printf %s "checking if OpenSSL's NID_secp521r1 is functional... " >&6; } 19293 if test "$cross_compiling" = yes 19294then : 19295 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cross-compiling: assuming yes" >&5 19296printf "%s\n" "$as_me: WARNING: cross-compiling: assuming yes" >&2;} 19297 enable_nistp521=1 19298 19299else $as_nop 19300 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 19301/* end confdefs.h. */ 19302 19303 #include <stdlib.h> 19304 #include <openssl/ec.h> 19305 #include <openssl/ecdh.h> 19306 #include <openssl/ecdsa.h> 19307 #include <openssl/evp.h> 19308 #include <openssl/objects.h> 19309 #include <openssl/opensslv.h> 19310 19311int 19312main (void) 19313{ 19314 19315 EC_KEY *e = EC_KEY_new_by_curve_name(NID_secp521r1); 19316 const EVP_MD *m = EVP_sha512(); /* We need this too */ 19317 exit(e == NULL || m == NULL); 19318 19319 ; 19320 return 0; 19321} 19322_ACEOF 19323if ac_fn_c_try_run "$LINENO" 19324then : 19325 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 19326printf "%s\n" "yes" >&6; } 19327 enable_nistp521=1 19328else $as_nop 19329 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 19330printf "%s\n" "no" >&6; } 19331fi 19332rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 19333 conftest.$ac_objext conftest.beam conftest.$ac_ext 19334fi 19335 19336else $as_nop 19337 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 19338printf "%s\n" "no" >&6; } 19339 19340fi 19341rm -f core conftest.err conftest.$ac_objext conftest.beam \ 19342 conftest$ac_exeext conftest.$ac_ext 19343 19344 if test x$enable_nistp256 = x1 || test x$enable_nistp384 = x1 || \ 19345 test x$enable_nistp521 = x1; then 19346 19347printf "%s\n" "#define OPENSSL_HAS_ECC 1" >>confdefs.h 19348 19349 ac_fn_c_check_func "$LINENO" "EC_KEY_METHOD_new" "ac_cv_func_EC_KEY_METHOD_new" 19350if test "x$ac_cv_func_EC_KEY_METHOD_new" = xyes 19351then : 19352 printf "%s\n" "#define HAVE_EC_KEY_METHOD_NEW 1" >>confdefs.h 19353 19354fi 19355 19356 openssl_ecc=yes 19357 else 19358 openssl_ecc=no 19359 fi 19360 if test x$enable_nistp256 = x1; then 19361 19362printf "%s\n" "#define OPENSSL_HAS_NISTP256 1" >>confdefs.h 19363 19364 else 19365 unsupported_algorithms="$unsupported_algorithms \ 19366 ecdsa-sha2-nistp256 \ 19367 ecdh-sha2-nistp256 \ 19368 ecdsa-sha2-nistp256-cert-v01@openssh.com" 19369 fi 19370 if test x$enable_nistp384 = x1; then 19371 19372printf "%s\n" "#define OPENSSL_HAS_NISTP384 1" >>confdefs.h 19373 19374 else 19375 unsupported_algorithms="$unsupported_algorithms \ 19376 ecdsa-sha2-nistp384 \ 19377 ecdh-sha2-nistp384 \ 19378 ecdsa-sha2-nistp384-cert-v01@openssh.com" 19379 fi 19380 if test x$enable_nistp521 = x1; then 19381 19382printf "%s\n" "#define OPENSSL_HAS_NISTP521 1" >>confdefs.h 19383 19384 else 19385 unsupported_algorithms="$unsupported_algorithms \ 19386 ecdh-sha2-nistp521 \ 19387 ecdsa-sha2-nistp521 \ 19388 ecdsa-sha2-nistp521-cert-v01@openssh.com" 19389 fi 19390 19391 # Check libcrypto ED25519 support 19392 ac_fn_c_check_func "$LINENO" "EVP_PKEY_get_raw_public_key" "ac_cv_func_EVP_PKEY_get_raw_public_key" 19393if test "x$ac_cv_func_EVP_PKEY_get_raw_public_key" = xyes 19394then : 19395 printf "%s\n" "#define HAVE_EVP_PKEY_GET_RAW_PUBLIC_KEY 1" >>confdefs.h 19396 19397fi 19398 19399 ac_fn_c_check_func "$LINENO" "EVP_PKEY_get_raw_private_key" "ac_cv_func_EVP_PKEY_get_raw_private_key" 19400if test "x$ac_cv_func_EVP_PKEY_get_raw_private_key" = xyes 19401then : 19402 printf "%s\n" "#define HAVE_EVP_PKEY_GET_RAW_PRIVATE_KEY 1" >>confdefs.h 19403 19404fi 19405 19406 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether OpenSSL has ED25519 support" >&5 19407printf %s "checking whether OpenSSL has ED25519 support... " >&6; } 19408 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 19409/* end confdefs.h. */ 19410 19411 #include <string.h> 19412 #include <openssl/evp.h> 19413 19414int 19415main (void) 19416{ 19417 19418 unsigned char buf[64]; 19419 memset(buf, 0, sizeof(buf)); 19420 exit(EVP_PKEY_new_raw_private_key(EVP_PKEY_ED25519, NULL, 19421 buf, sizeof(buf)) == NULL); 19422 19423 ; 19424 return 0; 19425} 19426_ACEOF 19427if ac_fn_c_try_link "$LINENO" 19428then : 19429 19430 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 19431printf "%s\n" "yes" >&6; } 19432 19433printf "%s\n" "#define OPENSSL_HAS_ED25519 1" >>confdefs.h 19434 19435 19436else $as_nop 19437 19438 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 19439printf "%s\n" "no" >&6; } 19440 19441 19442fi 19443rm -f core conftest.err conftest.$ac_objext conftest.beam \ 19444 conftest$ac_exeext conftest.$ac_ext 19445 19446 openssl_dsa=no 19447 if test ! -z "$enable_dsa" ; then 19448 ac_fn_check_decl "$LINENO" "OPENSSL_NO_DSA" "ac_cv_have_decl_OPENSSL_NO_DSA" " #include <openssl/opensslconf.h> 19449 19450" "$ac_c_undeclared_builtin_options" "CFLAGS" 19451if test "x$ac_cv_have_decl_OPENSSL_NO_DSA" = xyes 19452then : 19453 ac_have_decl=1 19454else $as_nop 19455 ac_have_decl=0 19456fi 19457printf "%s\n" "#define HAVE_DECL_OPENSSL_NO_DSA $ac_have_decl" >>confdefs.h 19458if test $ac_have_decl = 1 19459then : 19460 19461else $as_nop 19462 19463 ac_fn_check_decl "$LINENO" "OPENSSL_IS_BORINGSSL" "ac_cv_have_decl_OPENSSL_IS_BORINGSSL" " #include <openssl/opensslconf.h> 19464 19465" "$ac_c_undeclared_builtin_options" "CFLAGS" 19466if test "x$ac_cv_have_decl_OPENSSL_IS_BORINGSSL" = xyes 19467then : 19468 ac_have_decl=1 19469else $as_nop 19470 ac_have_decl=0 19471fi 19472printf "%s\n" "#define HAVE_DECL_OPENSSL_IS_BORINGSSL $ac_have_decl" >>confdefs.h 19473if test $ac_have_decl = 1 19474then : 19475 19476else $as_nop 19477 openssl_dsa=yes 19478fi 19479 19480 19481fi 19482 19483 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable DSA key support" >&5 19484printf %s "checking whether to enable DSA key support... " >&6; } 19485 if test "x$openssl_dsa" = "xno"; then 19486 as_fn_error $? "DSA requested but not supported by OpenSSL" "$LINENO" 5 19487 else 19488 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 19489printf "%s\n" "yes" >&6; } 19490 19491printf "%s\n" "#define WITH_DSA 1" >>confdefs.h 19492 19493 fi 19494 fi 19495fi 19496 19497# PKCS11/U2F depend on OpenSSL and dlopen(). 19498enable_pkcs11=yes 19499enable_sk=yes 19500if test "x$openssl" != "xyes" ; then 19501 enable_pkcs11="disabled; missing libcrypto" 19502fi 19503if test "x$ac_cv_func_dlopen" != "xyes" ; then 19504 enable_pkcs11="disabled; missing dlopen(3)" 19505 enable_sk="disabled; missing dlopen(3)" 19506fi 19507if test "x$ac_cv_have_decl_RTLD_NOW" != "xyes" ; then 19508 enable_pkcs11="disabled; missing RTLD_NOW" 19509 enable_sk="disabled; missing RTLD_NOW" 19510fi 19511if test ! -z "$disable_pkcs11" ; then 19512 enable_pkcs11="disabled by user" 19513fi 19514if test ! -z "$disable_sk" ; then 19515 enable_sk="disabled by user" 19516fi 19517 19518{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable PKCS11" >&5 19519printf %s "checking whether to enable PKCS11... " >&6; } 19520if test "x$enable_pkcs11" = "xyes" ; then 19521 19522printf "%s\n" "#define ENABLE_PKCS11 /**/" >>confdefs.h 19523 19524fi 19525{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $enable_pkcs11" >&5 19526printf "%s\n" "$enable_pkcs11" >&6; } 19527 19528{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to enable U2F" >&5 19529printf %s "checking whether to enable U2F... " >&6; } 19530if test "x$enable_sk" = "xyes" ; then 19531 19532printf "%s\n" "#define ENABLE_SK /**/" >>confdefs.h 19533 19534 SK_DUMMY_LIBRARY=regress/misc/sk-dummy/sk-dummy.so 19535 19536else 19537 # Do not try to build sk-dummy library. 19538 SK_DUMMY_LIBRARY="" 19539 19540fi 19541{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $enable_sk" >&5 19542printf "%s\n" "$enable_sk" >&6; } 19543 19544# Now check for built-in security key support. 19545if test "x$enable_sk" = "xyes" -a "x$enable_sk_internal" != "xno" ; then 19546 use_pkgconfig_for_libfido2= 19547 if test "x$PKGCONFIG" != "xno"; then 19548 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $PKGCONFIG knows about libfido2" >&5 19549printf %s "checking if $PKGCONFIG knows about libfido2... " >&6; } 19550 if "$PKGCONFIG" libfido2; then 19551 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 19552printf "%s\n" "yes" >&6; } 19553 use_pkgconfig_for_libfido2=yes 19554 else 19555 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 19556printf "%s\n" "no" >&6; } 19557 fi 19558 fi 19559 if test "x$use_pkgconfig_for_libfido2" = "xyes"; then 19560 LIBFIDO2=`$PKGCONFIG --libs libfido2` 19561 CPPFLAGS="$CPPFLAGS `$PKGCONFIG --cflags libfido2`" 19562 else 19563 LIBFIDO2="-lfido2 -lcbor" 19564 fi 19565 OTHERLIBS=`echo $LIBFIDO2 | sed 's/-lfido2//'` 19566 fido2_error= 19567 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for fido_init in -lfido2" >&5 19568printf %s "checking for fido_init in -lfido2... " >&6; } 19569if test ${ac_cv_lib_fido2_fido_init+y} 19570then : 19571 printf %s "(cached) " >&6 19572else $as_nop 19573 ac_check_lib_save_LIBS=$LIBS 19574LIBS="-lfido2 $OTHERLIBS 19575 $LIBS" 19576cat confdefs.h - <<_ACEOF >conftest.$ac_ext 19577/* end confdefs.h. */ 19578 19579/* Override any GCC internal prototype to avoid an error. 19580 Use char because int might match the return type of a GCC 19581 builtin and then its argument prototype would still apply. */ 19582char fido_init (); 19583int 19584main (void) 19585{ 19586return fido_init (); 19587 ; 19588 return 0; 19589} 19590_ACEOF 19591if ac_fn_c_try_link "$LINENO" 19592then : 19593 ac_cv_lib_fido2_fido_init=yes 19594else $as_nop 19595 ac_cv_lib_fido2_fido_init=no 19596fi 19597rm -f core conftest.err conftest.$ac_objext conftest.beam \ 19598 conftest$ac_exeext conftest.$ac_ext 19599LIBS=$ac_check_lib_save_LIBS 19600fi 19601{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_fido2_fido_init" >&5 19602printf "%s\n" "$ac_cv_lib_fido2_fido_init" >&6; } 19603if test "x$ac_cv_lib_fido2_fido_init" = xyes 19604then : 19605 19606else $as_nop 19607 fido2_error="missing/unusable libfido2" 19608fi 19609 19610 ac_fn_c_check_header_compile "$LINENO" "fido.h" "ac_cv_header_fido_h" "$ac_includes_default" 19611if test "x$ac_cv_header_fido_h" = xyes 19612then : 19613 19614else $as_nop 19615 fido2_error="missing fido.h from libfido2" 19616fi 19617 19618 ac_fn_c_check_header_compile "$LINENO" "fido/credman.h" "ac_cv_header_fido_credman_h" " #include <fido.h> 19619 19620" 19621if test "x$ac_cv_header_fido_credman_h" = xyes 19622then : 19623 19624else $as_nop 19625 fido2_error="missing fido/credman.h from libfido2" 19626fi 19627 19628 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for usable libfido2 installation" >&5 19629printf %s "checking for usable libfido2 installation... " >&6; } 19630 if test ! -z "$fido2_error" ; then 19631 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $fido2_error" >&5 19632printf "%s\n" "$fido2_error" >&6; } 19633 if test "x$enable_sk_internal" = "xyes" ; then 19634 as_fn_error $? "No usable libfido2 library/headers found" "$LINENO" 5 19635 fi 19636 LIBFIDO2="" 19637 else 19638 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 19639printf "%s\n" "yes" >&6; } 19640 19641 19642printf "%s\n" "#define ENABLE_SK_INTERNAL /**/" >>confdefs.h 19643 19644 enable_sk="built-in" 19645 saved_LIBS="$LIBS" 19646 LIBS="$LIBFIDO2 $LIBS" 19647 ac_fn_c_check_func "$LINENO" "fido_assert_set_clientdata" "ac_cv_func_fido_assert_set_clientdata" 19648if test "x$ac_cv_func_fido_assert_set_clientdata" = xyes 19649then : 19650 printf "%s\n" "#define HAVE_FIDO_ASSERT_SET_CLIENTDATA 1" >>confdefs.h 19651 19652fi 19653ac_fn_c_check_func "$LINENO" "fido_cred_prot" "ac_cv_func_fido_cred_prot" 19654if test "x$ac_cv_func_fido_cred_prot" = xyes 19655then : 19656 printf "%s\n" "#define HAVE_FIDO_CRED_PROT 1" >>confdefs.h 19657 19658fi 19659ac_fn_c_check_func "$LINENO" "fido_cred_set_prot" "ac_cv_func_fido_cred_set_prot" 19660if test "x$ac_cv_func_fido_cred_set_prot" = xyes 19661then : 19662 printf "%s\n" "#define HAVE_FIDO_CRED_SET_PROT 1" >>confdefs.h 19663 19664fi 19665ac_fn_c_check_func "$LINENO" "fido_cred_set_clientdata" "ac_cv_func_fido_cred_set_clientdata" 19666if test "x$ac_cv_func_fido_cred_set_clientdata" = xyes 19667then : 19668 printf "%s\n" "#define HAVE_FIDO_CRED_SET_CLIENTDATA 1" >>confdefs.h 19669 19670fi 19671ac_fn_c_check_func "$LINENO" "fido_dev_get_touch_begin" "ac_cv_func_fido_dev_get_touch_begin" 19672if test "x$ac_cv_func_fido_dev_get_touch_begin" = xyes 19673then : 19674 printf "%s\n" "#define HAVE_FIDO_DEV_GET_TOUCH_BEGIN 1" >>confdefs.h 19675 19676fi 19677ac_fn_c_check_func "$LINENO" "fido_dev_get_touch_status" "ac_cv_func_fido_dev_get_touch_status" 19678if test "x$ac_cv_func_fido_dev_get_touch_status" = xyes 19679then : 19680 printf "%s\n" "#define HAVE_FIDO_DEV_GET_TOUCH_STATUS 1" >>confdefs.h 19681 19682fi 19683ac_fn_c_check_func "$LINENO" "fido_dev_supports_cred_prot" "ac_cv_func_fido_dev_supports_cred_prot" 19684if test "x$ac_cv_func_fido_dev_supports_cred_prot" = xyes 19685then : 19686 printf "%s\n" "#define HAVE_FIDO_DEV_SUPPORTS_CRED_PROT 1" >>confdefs.h 19687 19688fi 19689ac_fn_c_check_func "$LINENO" "fido_dev_is_winhello" "ac_cv_func_fido_dev_is_winhello" 19690if test "x$ac_cv_func_fido_dev_is_winhello" = xyes 19691then : 19692 printf "%s\n" "#define HAVE_FIDO_DEV_IS_WINHELLO 1" >>confdefs.h 19693 19694fi 19695 19696 LIBS="$saved_LIBS" 19697 fi 19698fi 19699 19700ac_fn_c_check_func "$LINENO" "arc4random" "ac_cv_func_arc4random" 19701if test "x$ac_cv_func_arc4random" = xyes 19702then : 19703 printf "%s\n" "#define HAVE_ARC4RANDOM 1" >>confdefs.h 19704 19705fi 19706ac_fn_c_check_func "$LINENO" "arc4random_buf" "ac_cv_func_arc4random_buf" 19707if test "x$ac_cv_func_arc4random_buf" = xyes 19708then : 19709 printf "%s\n" "#define HAVE_ARC4RANDOM_BUF 1" >>confdefs.h 19710 19711fi 19712ac_fn_c_check_func "$LINENO" "arc4random_stir" "ac_cv_func_arc4random_stir" 19713if test "x$ac_cv_func_arc4random_stir" = xyes 19714then : 19715 printf "%s\n" "#define HAVE_ARC4RANDOM_STIR 1" >>confdefs.h 19716 19717fi 19718ac_fn_c_check_func "$LINENO" "arc4random_uniform" "ac_cv_func_arc4random_uniform" 19719if test "x$ac_cv_func_arc4random_uniform" = xyes 19720then : 19721 printf "%s\n" "#define HAVE_ARC4RANDOM_UNIFORM 1" >>confdefs.h 19722 19723fi 19724 19725### Configure cryptographic random number support 19726 19727# Check whether OpenSSL seeds itself 19728if test "x$openssl" = "xyes" ; then 19729 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether OpenSSL's PRNG is internally seeded" >&5 19730printf %s "checking whether OpenSSL's PRNG is internally seeded... " >&6; } 19731 if test "$cross_compiling" = yes 19732then : 19733 19734 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: assuming yes" >&5 19735printf "%s\n" "$as_me: WARNING: cross compiling: assuming yes" >&2;} 19736 # This is safe, since we will fatal() at runtime if 19737 # OpenSSL is not seeded correctly. 19738 OPENSSL_SEEDS_ITSELF=yes 19739 19740 19741else $as_nop 19742 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 19743/* end confdefs.h. */ 19744 19745 #include <stdlib.h> 19746 #include <string.h> 19747 #include <openssl/rand.h> 19748 19749int 19750main (void) 19751{ 19752 19753 exit(RAND_status() == 1 ? 0 : 1); 19754 19755 ; 19756 return 0; 19757} 19758_ACEOF 19759if ac_fn_c_try_run "$LINENO" 19760then : 19761 19762 OPENSSL_SEEDS_ITSELF=yes 19763 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 19764printf "%s\n" "yes" >&6; } 19765 19766else $as_nop 19767 19768 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 19769printf "%s\n" "no" >&6; } 19770 19771fi 19772rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 19773 conftest.$ac_objext conftest.beam conftest.$ac_ext 19774fi 19775 19776fi 19777 19778# PRNGD TCP socket 19779 19780# Check whether --with-prngd-port was given. 19781if test ${with_prngd_port+y} 19782then : 19783 withval=$with_prngd_port; 19784 case "$withval" in 19785 no) 19786 withval="" 19787 ;; 19788 [0-9]*) 19789 ;; 19790 *) 19791 as_fn_error $? "You must specify a numeric port number for --with-prngd-port" "$LINENO" 5 19792 ;; 19793 esac 19794 if test ! -z "$withval" ; then 19795 PRNGD_PORT="$withval" 19796 19797printf "%s\n" "#define PRNGD_PORT $PRNGD_PORT" >>confdefs.h 19798 19799 fi 19800 19801 19802fi 19803 19804 19805# PRNGD Unix domain socket 19806 19807# Check whether --with-prngd-socket was given. 19808if test ${with_prngd_socket+y} 19809then : 19810 withval=$with_prngd_socket; 19811 case "$withval" in 19812 yes) 19813 withval="/var/run/egd-pool" 19814 ;; 19815 no) 19816 withval="" 19817 ;; 19818 /*) 19819 ;; 19820 *) 19821 as_fn_error $? "You must specify an absolute path to the entropy socket" "$LINENO" 5 19822 ;; 19823 esac 19824 19825 if test ! -z "$withval" ; then 19826 if test ! -z "$PRNGD_PORT" ; then 19827 as_fn_error $? "You may not specify both a PRNGD/EGD port and socket" "$LINENO" 5 19828 fi 19829 if test ! -r "$withval" ; then 19830 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Entropy socket is not readable" >&5 19831printf "%s\n" "$as_me: WARNING: Entropy socket is not readable" >&2;} 19832 fi 19833 PRNGD_SOCKET="$withval" 19834 19835printf "%s\n" "#define PRNGD_SOCKET \"$PRNGD_SOCKET\"" >>confdefs.h 19836 19837 fi 19838 19839else $as_nop 19840 19841 # Check for existing socket only if we don't have a random device already 19842 if test "x$OPENSSL_SEEDS_ITSELF" != "xyes" ; then 19843 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for PRNGD/EGD socket" >&5 19844printf %s "checking for PRNGD/EGD socket... " >&6; } 19845 # Insert other locations here 19846 for sock in /var/run/egd-pool /dev/egd-pool /etc/entropy; do 19847 if test -r $sock && $TEST_MINUS_S_SH -c "test -S $sock -o -p $sock" ; then 19848 PRNGD_SOCKET="$sock" 19849 printf "%s\n" "#define PRNGD_SOCKET \"$PRNGD_SOCKET\"" >>confdefs.h 19850 19851 break; 19852 fi 19853 done 19854 if test ! -z "$PRNGD_SOCKET" ; then 19855 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PRNGD_SOCKET" >&5 19856printf "%s\n" "$PRNGD_SOCKET" >&6; } 19857 else 19858 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not found" >&5 19859printf "%s\n" "not found" >&6; } 19860 fi 19861 fi 19862 19863 19864fi 19865 19866 19867# Which randomness source do we use? 19868if test ! -z "$PRNGD_PORT" ; then 19869 RAND_MSG="PRNGd port $PRNGD_PORT" 19870elif test ! -z "$PRNGD_SOCKET" ; then 19871 RAND_MSG="PRNGd socket $PRNGD_SOCKET" 19872elif test ! -z "$OPENSSL_SEEDS_ITSELF" ; then 19873 19874printf "%s\n" "#define OPENSSL_PRNG_ONLY 1" >>confdefs.h 19875 19876 RAND_MSG="OpenSSL internal ONLY" 19877elif test "x$openssl" = "xno" ; then 19878 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: OpenSSH will use /dev/urandom as a source of random numbers. It will fail if this device is not supported or accessible" >&5 19879printf "%s\n" "$as_me: WARNING: OpenSSH will use /dev/urandom as a source of random numbers. It will fail if this device is not supported or accessible" >&2;} 19880else 19881 as_fn_error $? "OpenSSH has no source of random numbers. Please configure OpenSSL with an entropy source or re-run configure using one of the --with-prngd-port or --with-prngd-socket options" "$LINENO" 5 19882fi 19883LIBS="$nocrypto_saved_LIBS" 19884 19885saved_LIBS="$LIBS" 19886{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ia_openinfo in -liaf" >&5 19887printf %s "checking for ia_openinfo in -liaf... " >&6; } 19888if test ${ac_cv_lib_iaf_ia_openinfo+y} 19889then : 19890 printf %s "(cached) " >&6 19891else $as_nop 19892 ac_check_lib_save_LIBS=$LIBS 19893LIBS="-liaf $LIBS" 19894cat confdefs.h - <<_ACEOF >conftest.$ac_ext 19895/* end confdefs.h. */ 19896 19897/* Override any GCC internal prototype to avoid an error. 19898 Use char because int might match the return type of a GCC 19899 builtin and then its argument prototype would still apply. */ 19900char ia_openinfo (); 19901int 19902main (void) 19903{ 19904return ia_openinfo (); 19905 ; 19906 return 0; 19907} 19908_ACEOF 19909if ac_fn_c_try_link "$LINENO" 19910then : 19911 ac_cv_lib_iaf_ia_openinfo=yes 19912else $as_nop 19913 ac_cv_lib_iaf_ia_openinfo=no 19914fi 19915rm -f core conftest.err conftest.$ac_objext conftest.beam \ 19916 conftest$ac_exeext conftest.$ac_ext 19917LIBS=$ac_check_lib_save_LIBS 19918fi 19919{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_iaf_ia_openinfo" >&5 19920printf "%s\n" "$ac_cv_lib_iaf_ia_openinfo" >&6; } 19921if test "x$ac_cv_lib_iaf_ia_openinfo" = xyes 19922then : 19923 19924 LIBS="$LIBS -liaf" 19925 19926 for ac_func in set_id 19927do : 19928 ac_fn_c_check_func "$LINENO" "set_id" "ac_cv_func_set_id" 19929if test "x$ac_cv_func_set_id" = xyes 19930then : 19931 printf "%s\n" "#define HAVE_SET_ID 1" >>confdefs.h 19932 SSHDLIBS="$SSHDLIBS -liaf" 19933 19934printf "%s\n" "#define HAVE_LIBIAF 1" >>confdefs.h 19935 19936 19937fi 19938 19939done 19940 19941fi 19942 19943LIBS="$saved_LIBS" 19944 19945# Check for crypt() in libcrypt. If we have it, we only need it for sshd. 19946saved_LIBS="$LIBS" 19947{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for crypt in -lcrypt" >&5 19948printf %s "checking for crypt in -lcrypt... " >&6; } 19949if test ${ac_cv_lib_crypt_crypt+y} 19950then : 19951 printf %s "(cached) " >&6 19952else $as_nop 19953 ac_check_lib_save_LIBS=$LIBS 19954LIBS="-lcrypt $LIBS" 19955cat confdefs.h - <<_ACEOF >conftest.$ac_ext 19956/* end confdefs.h. */ 19957 19958/* Override any GCC internal prototype to avoid an error. 19959 Use char because int might match the return type of a GCC 19960 builtin and then its argument prototype would still apply. */ 19961char crypt (); 19962int 19963main (void) 19964{ 19965return crypt (); 19966 ; 19967 return 0; 19968} 19969_ACEOF 19970if ac_fn_c_try_link "$LINENO" 19971then : 19972 ac_cv_lib_crypt_crypt=yes 19973else $as_nop 19974 ac_cv_lib_crypt_crypt=no 19975fi 19976rm -f core conftest.err conftest.$ac_objext conftest.beam \ 19977 conftest$ac_exeext conftest.$ac_ext 19978LIBS=$ac_check_lib_save_LIBS 19979fi 19980{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypt_crypt" >&5 19981printf "%s\n" "$ac_cv_lib_crypt_crypt" >&6; } 19982if test "x$ac_cv_lib_crypt_crypt" = xyes 19983then : 19984 19985 LIBS="-lcrypt $LIBS" 19986 SSHDLIBS="-lcrypt $SSHDLIBS" 19987 19988fi 19989 19990ac_fn_c_check_func "$LINENO" "crypt" "ac_cv_func_crypt" 19991if test "x$ac_cv_func_crypt" = xyes 19992then : 19993 printf "%s\n" "#define HAVE_CRYPT 1" >>confdefs.h 19994 19995fi 19996 19997LIBS="$saved_LIBS" 19998 19999# Check for PAM libs 20000PAM_MSG="no" 20001 20002# Check whether --with-pam was given. 20003if test ${with_pam+y} 20004then : 20005 withval=$with_pam; 20006 if test "x$withval" != "xno" ; then 20007 if test "x$ac_cv_header_security_pam_appl_h" != "xyes" && \ 20008 test "x$ac_cv_header_pam_pam_appl_h" != "xyes" ; then 20009 as_fn_error $? "PAM headers not found" "$LINENO" 5 20010 fi 20011 20012 saved_LIBS="$LIBS" 20013 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 20014printf %s "checking for dlopen in -ldl... " >&6; } 20015if test ${ac_cv_lib_dl_dlopen+y} 20016then : 20017 printf %s "(cached) " >&6 20018else $as_nop 20019 ac_check_lib_save_LIBS=$LIBS 20020LIBS="-ldl $LIBS" 20021cat confdefs.h - <<_ACEOF >conftest.$ac_ext 20022/* end confdefs.h. */ 20023 20024/* Override any GCC internal prototype to avoid an error. 20025 Use char because int might match the return type of a GCC 20026 builtin and then its argument prototype would still apply. */ 20027char dlopen (); 20028int 20029main (void) 20030{ 20031return dlopen (); 20032 ; 20033 return 0; 20034} 20035_ACEOF 20036if ac_fn_c_try_link "$LINENO" 20037then : 20038 ac_cv_lib_dl_dlopen=yes 20039else $as_nop 20040 ac_cv_lib_dl_dlopen=no 20041fi 20042rm -f core conftest.err conftest.$ac_objext conftest.beam \ 20043 conftest$ac_exeext conftest.$ac_ext 20044LIBS=$ac_check_lib_save_LIBS 20045fi 20046{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 20047printf "%s\n" "$ac_cv_lib_dl_dlopen" >&6; } 20048if test "x$ac_cv_lib_dl_dlopen" = xyes 20049then : 20050 printf "%s\n" "#define HAVE_LIBDL 1" >>confdefs.h 20051 20052 LIBS="-ldl $LIBS" 20053 20054fi 20055 20056 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pam_set_item in -lpam" >&5 20057printf %s "checking for pam_set_item in -lpam... " >&6; } 20058if test ${ac_cv_lib_pam_pam_set_item+y} 20059then : 20060 printf %s "(cached) " >&6 20061else $as_nop 20062 ac_check_lib_save_LIBS=$LIBS 20063LIBS="-lpam $LIBS" 20064cat confdefs.h - <<_ACEOF >conftest.$ac_ext 20065/* end confdefs.h. */ 20066 20067/* Override any GCC internal prototype to avoid an error. 20068 Use char because int might match the return type of a GCC 20069 builtin and then its argument prototype would still apply. */ 20070char pam_set_item (); 20071int 20072main (void) 20073{ 20074return pam_set_item (); 20075 ; 20076 return 0; 20077} 20078_ACEOF 20079if ac_fn_c_try_link "$LINENO" 20080then : 20081 ac_cv_lib_pam_pam_set_item=yes 20082else $as_nop 20083 ac_cv_lib_pam_pam_set_item=no 20084fi 20085rm -f core conftest.err conftest.$ac_objext conftest.beam \ 20086 conftest$ac_exeext conftest.$ac_ext 20087LIBS=$ac_check_lib_save_LIBS 20088fi 20089{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pam_pam_set_item" >&5 20090printf "%s\n" "$ac_cv_lib_pam_pam_set_item" >&6; } 20091if test "x$ac_cv_lib_pam_pam_set_item" = xyes 20092then : 20093 printf "%s\n" "#define HAVE_LIBPAM 1" >>confdefs.h 20094 20095 LIBS="-lpam $LIBS" 20096 20097else $as_nop 20098 as_fn_error $? "*** libpam missing" "$LINENO" 5 20099fi 20100 20101 ac_fn_c_check_func "$LINENO" "pam_getenvlist" "ac_cv_func_pam_getenvlist" 20102if test "x$ac_cv_func_pam_getenvlist" = xyes 20103then : 20104 printf "%s\n" "#define HAVE_PAM_GETENVLIST 1" >>confdefs.h 20105 20106fi 20107 20108 ac_fn_c_check_func "$LINENO" "pam_putenv" "ac_cv_func_pam_putenv" 20109if test "x$ac_cv_func_pam_putenv" = xyes 20110then : 20111 printf "%s\n" "#define HAVE_PAM_PUTENV 1" >>confdefs.h 20112 20113fi 20114 20115 LIBS="$saved_LIBS" 20116 20117 PAM_MSG="yes" 20118 20119 SSHDLIBS="$SSHDLIBS -lpam" 20120 20121printf "%s\n" "#define USE_PAM 1" >>confdefs.h 20122 20123 20124 if test $ac_cv_lib_dl_dlopen = yes; then 20125 case "$LIBS" in 20126 *-ldl*) 20127 # libdl already in LIBS 20128 ;; 20129 *) 20130 SSHDLIBS="$SSHDLIBS -ldl" 20131 ;; 20132 esac 20133 fi 20134 fi 20135 20136 20137fi 20138 20139 20140 20141# Check whether --with-pam-service was given. 20142if test ${with_pam_service+y} 20143then : 20144 withval=$with_pam_service; 20145 if test "x$withval" != "xno" && \ 20146 test "x$withval" != "xyes" ; then 20147 20148printf "%s\n" "#define SSHD_PAM_SERVICE \"$withval\"" >>confdefs.h 20149 20150 fi 20151 20152 20153fi 20154 20155 20156# Check for older PAM 20157if test "x$PAM_MSG" = "xyes" ; then 20158 # Check PAM strerror arguments (old PAM) 20159 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether pam_strerror takes only one argument" >&5 20160printf %s "checking whether pam_strerror takes only one argument... " >&6; } 20161 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 20162/* end confdefs.h. */ 20163 20164#include <stdlib.h> 20165#if defined(HAVE_SECURITY_PAM_APPL_H) 20166#include <security/pam_appl.h> 20167#elif defined (HAVE_PAM_PAM_APPL_H) 20168#include <pam/pam_appl.h> 20169#endif 20170 20171int 20172main (void) 20173{ 20174 20175(void)pam_strerror((pam_handle_t *)NULL, -1); 20176 20177 ; 20178 return 0; 20179} 20180_ACEOF 20181if ac_fn_c_try_compile "$LINENO" 20182then : 20183 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 20184printf "%s\n" "no" >&6; } 20185else $as_nop 20186 20187 20188printf "%s\n" "#define HAVE_OLD_PAM 1" >>confdefs.h 20189 20190 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 20191printf "%s\n" "yes" >&6; } 20192 PAM_MSG="yes (old library)" 20193 20194 20195fi 20196rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 20197fi 20198 20199case "$host" in 20200*-*-cygwin*) 20201 SSH_PRIVSEP_USER=CYGWIN_SSH_PRIVSEP_USER 20202 ;; 20203*) 20204 SSH_PRIVSEP_USER=sshd 20205 ;; 20206esac 20207 20208# Check whether --with-privsep-user was given. 20209if test ${with_privsep_user+y} 20210then : 20211 withval=$with_privsep_user; 20212 if test -n "$withval" && test "x$withval" != "xno" && \ 20213 test "x${withval}" != "xyes"; then 20214 SSH_PRIVSEP_USER=$withval 20215 fi 20216 20217 20218fi 20219 20220if test "x$SSH_PRIVSEP_USER" = "xCYGWIN_SSH_PRIVSEP_USER" ; then 20221 20222printf "%s\n" "#define SSH_PRIVSEP_USER CYGWIN_SSH_PRIVSEP_USER" >>confdefs.h 20223 20224else 20225 20226printf "%s\n" "#define SSH_PRIVSEP_USER \"$SSH_PRIVSEP_USER\"" >>confdefs.h 20227 20228fi 20229 20230 20231if test "x$have_linux_no_new_privs" = "x1" ; then 20232ac_fn_check_decl "$LINENO" "SECCOMP_MODE_FILTER" "ac_cv_have_decl_SECCOMP_MODE_FILTER" " 20233 #include <sys/types.h> 20234 #include <linux/seccomp.h> 20235 20236" "$ac_c_undeclared_builtin_options" "CFLAGS" 20237if test "x$ac_cv_have_decl_SECCOMP_MODE_FILTER" = xyes 20238then : 20239 have_seccomp_filter=1 20240fi 20241fi 20242if test "x$have_seccomp_filter" = "x1" ; then 20243{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking kernel for seccomp_filter support" >&5 20244printf %s "checking kernel for seccomp_filter support... " >&6; } 20245cat confdefs.h - <<_ACEOF >conftest.$ac_ext 20246/* end confdefs.h. */ 20247 20248 #include <errno.h> 20249 #include <elf.h> 20250 #include <linux/audit.h> 20251 #include <linux/seccomp.h> 20252 #include <stdlib.h> 20253 #include <sys/prctl.h> 20254 20255int 20256main (void) 20257{ 20258 int i = $seccomp_audit_arch; 20259 errno = 0; 20260 prctl(PR_SET_SECCOMP, SECCOMP_MODE_FILTER, NULL, 0, 0); 20261 exit(errno == EFAULT ? 0 : 1); 20262 ; 20263 return 0; 20264} 20265_ACEOF 20266if ac_fn_c_try_link "$LINENO" 20267then : 20268 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 20269printf "%s\n" "yes" >&6; } 20270else $as_nop 20271 20272 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 20273printf "%s\n" "no" >&6; } 20274 # Disable seccomp filter as a target 20275 have_seccomp_filter=0 20276 20277 20278fi 20279rm -f core conftest.err conftest.$ac_objext conftest.beam \ 20280 conftest$ac_exeext conftest.$ac_ext 20281fi 20282 20283ac_fn_c_check_member "$LINENO" "struct pollfd" "fd" "ac_cv_member_struct_pollfd_fd" " 20284#include <sys/types.h> 20285#ifdef HAVE_POLL_H 20286#include <poll.h> 20287#endif 20288#ifdef HAVE_SYS_POLL_H 20289#include <sys/poll.h> 20290#endif 20291 20292" 20293if test "x$ac_cv_member_struct_pollfd_fd" = xyes 20294then : 20295 20296printf "%s\n" "#define HAVE_STRUCT_POLLFD_FD 1" >>confdefs.h 20297 20298 20299fi 20300 20301 20302ac_fn_c_check_type "$LINENO" "nfds_t" "ac_cv_type_nfds_t" " 20303#include <sys/types.h> 20304#ifdef HAVE_POLL_H 20305#include <poll.h> 20306#endif 20307#ifdef HAVE_SYS_POLL_H 20308#include <sys/poll.h> 20309#endif 20310 20311" 20312if test "x$ac_cv_type_nfds_t" = xyes 20313then : 20314 20315printf "%s\n" "#define HAVE_NFDS_T 1" >>confdefs.h 20316 20317 20318fi 20319 20320 20321# Decide which sandbox style to use 20322sandbox_arg="" 20323 20324# Check whether --with-sandbox was given. 20325if test ${with_sandbox+y} 20326then : 20327 withval=$with_sandbox; 20328 if test "x$withval" = "xyes" ; then 20329 sandbox_arg="" 20330 else 20331 sandbox_arg="$withval" 20332 fi 20333 20334 20335fi 20336 20337 20338if test "x$sandbox_arg" != "xno"; then 20339# POSIX specifies that poll() "shall fail with EINVAL if the nfds argument 20340# is greater than OPEN_MAX". On some platforms that includes implementions 20341# of select in userspace on top of poll() so check both work with rlimit 20342# NOFILES so check that both work before enabling the rlimit sandbox. 20343 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if select and/or poll works with descriptor rlimit" >&5 20344printf %s "checking if select and/or poll works with descriptor rlimit... " >&6; } 20345 if test "$cross_compiling" = yes 20346then : 20347 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: assuming no" >&5 20348printf "%s\n" "$as_me: WARNING: cross compiling: assuming no" >&2;} 20349 select_works_with_rlimit=no 20350 20351else $as_nop 20352 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 20353/* end confdefs.h. */ 20354 20355#include <sys/types.h> 20356#ifdef HAVE_SYS_TIME_H 20357# include <sys/time.h> 20358#endif 20359#include <sys/resource.h> 20360#ifdef HAVE_SYS_SELECT_H 20361# include <sys/select.h> 20362#endif 20363#ifdef HAVE_POLL_H 20364# include <poll.h> 20365#elif HAVE_SYS_POLL_H 20366# include <sys/poll.h> 20367#endif 20368#include <errno.h> 20369#include <fcntl.h> 20370#include <stdlib.h> 20371 20372int 20373main (void) 20374{ 20375 20376 struct rlimit rl_zero; 20377 int fd, r; 20378 fd_set fds; 20379 struct timeval tv; 20380#ifdef HAVE_POLL 20381 struct pollfd pfd; 20382#endif 20383 20384 fd = open("/dev/null", O_RDONLY); 20385 FD_ZERO(&fds); 20386 FD_SET(fd, &fds); 20387 rl_zero.rlim_cur = rl_zero.rlim_max = 0; 20388 setrlimit(RLIMIT_FSIZE, &rl_zero); 20389 setrlimit(RLIMIT_NOFILE, &rl_zero); 20390 tv.tv_sec = 1; 20391 tv.tv_usec = 0; 20392 r = select(fd+1, &fds, NULL, NULL, &tv); 20393 if (r == -1) 20394 exit(1); 20395#ifdef HAVE_POLL 20396 pfd.fd = fd; 20397 pfd.events = POLLIN; 20398 r = poll(&pfd, 1, 1); 20399 if (r == -1) 20400 exit(2); 20401#endif 20402 exit(0); 20403 20404 ; 20405 return 0; 20406} 20407_ACEOF 20408if ac_fn_c_try_run "$LINENO" 20409then : 20410 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 20411printf "%s\n" "yes" >&6; } 20412 select_works_with_rlimit=yes 20413else $as_nop 20414 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 20415printf "%s\n" "no" >&6; } 20416 select_works_with_rlimit=no 20417fi 20418rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 20419 conftest.$ac_objext conftest.beam conftest.$ac_ext 20420fi 20421 20422 20423 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if setrlimit(RLIMIT_NOFILE,{0,0}) works" >&5 20424printf %s "checking if setrlimit(RLIMIT_NOFILE,{0,0}) works... " >&6; } 20425 if test "$cross_compiling" = yes 20426then : 20427 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: assuming yes" >&5 20428printf "%s\n" "$as_me: WARNING: cross compiling: assuming yes" >&2;} 20429 rlimit_nofile_zero_works=yes 20430 20431else $as_nop 20432 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 20433/* end confdefs.h. */ 20434 20435#include <sys/types.h> 20436#ifdef HAVE_SYS_TIME_H 20437# include <sys/time.h> 20438#endif 20439#include <sys/resource.h> 20440#include <errno.h> 20441#include <stdlib.h> 20442 20443int 20444main (void) 20445{ 20446 20447 struct rlimit rl_zero; 20448 int r; 20449 20450 rl_zero.rlim_cur = rl_zero.rlim_max = 0; 20451 r = setrlimit(RLIMIT_NOFILE, &rl_zero); 20452 exit (r == -1 ? 1 : 0); 20453 20454 ; 20455 return 0; 20456} 20457_ACEOF 20458if ac_fn_c_try_run "$LINENO" 20459then : 20460 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 20461printf "%s\n" "yes" >&6; } 20462 rlimit_nofile_zero_works=yes 20463else $as_nop 20464 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 20465printf "%s\n" "no" >&6; } 20466 rlimit_nofile_zero_works=no 20467fi 20468rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 20469 conftest.$ac_objext conftest.beam conftest.$ac_ext 20470fi 20471 20472 20473 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if setrlimit RLIMIT_FSIZE works" >&5 20474printf %s "checking if setrlimit RLIMIT_FSIZE works... " >&6; } 20475 if test "$cross_compiling" = yes 20476then : 20477 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: assuming yes" >&5 20478printf "%s\n" "$as_me: WARNING: cross compiling: assuming yes" >&2;} 20479 20480else $as_nop 20481 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 20482/* end confdefs.h. */ 20483 20484#include <sys/types.h> 20485#include <sys/resource.h> 20486#include <stdlib.h> 20487 20488int 20489main (void) 20490{ 20491 20492 struct rlimit rl_zero; 20493 20494 rl_zero.rlim_cur = rl_zero.rlim_max = 0; 20495 exit(setrlimit(RLIMIT_FSIZE, &rl_zero) != 0); 20496 20497 ; 20498 return 0; 20499} 20500_ACEOF 20501if ac_fn_c_try_run "$LINENO" 20502then : 20503 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 20504printf "%s\n" "yes" >&6; } 20505else $as_nop 20506 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 20507printf "%s\n" "no" >&6; } 20508 20509printf "%s\n" "#define SANDBOX_SKIP_RLIMIT_FSIZE 1" >>confdefs.h 20510 20511fi 20512rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 20513 conftest.$ac_objext conftest.beam conftest.$ac_ext 20514fi 20515 20516fi 20517 20518if test "x$sandbox_arg" = "xpledge" || \ 20519 ( test -z "$sandbox_arg" && test "x$ac_cv_func_pledge" = "xyes" ) ; then 20520 test "x$ac_cv_func_pledge" != "xyes" && \ 20521 as_fn_error $? "pledge sandbox requires pledge(2) support" "$LINENO" 5 20522 SANDBOX_STYLE="pledge" 20523 20524printf "%s\n" "#define SANDBOX_PLEDGE 1" >>confdefs.h 20525 20526elif test "x$sandbox_arg" = "xsystrace" || \ 20527 ( test -z "$sandbox_arg" && test "x$have_systr_policy_kill" = "x1" ) ; then 20528 test "x$have_systr_policy_kill" != "x1" && \ 20529 as_fn_error $? "systrace sandbox requires systrace headers and SYSTR_POLICY_KILL support" "$LINENO" 5 20530 SANDBOX_STYLE="systrace" 20531 20532printf "%s\n" "#define SANDBOX_SYSTRACE 1" >>confdefs.h 20533 20534elif test "x$sandbox_arg" = "xdarwin" || \ 20535 ( test -z "$sandbox_arg" && test "x$ac_cv_func_sandbox_init" = "xyes" && \ 20536 test "x$ac_cv_header_sandbox_h" = "xyes") ; then 20537 test "x$ac_cv_func_sandbox_init" != "xyes" -o \ 20538 "x$ac_cv_header_sandbox_h" != "xyes" && \ 20539 as_fn_error $? "Darwin seatbelt sandbox requires sandbox.h and sandbox_init function" "$LINENO" 5 20540 SANDBOX_STYLE="darwin" 20541 20542printf "%s\n" "#define SANDBOX_DARWIN 1" >>confdefs.h 20543 20544elif test "x$sandbox_arg" = "xseccomp_filter" || \ 20545 ( test -z "$sandbox_arg" && \ 20546 test "x$have_seccomp_filter" = "x1" && \ 20547 test "x$ac_cv_header_elf_h" = "xyes" && \ 20548 test "x$ac_cv_header_linux_audit_h" = "xyes" && \ 20549 test "x$ac_cv_header_linux_filter_h" = "xyes" && \ 20550 test "x$seccomp_audit_arch" != "x" && \ 20551 test "x$have_linux_no_new_privs" = "x1" && \ 20552 test "x$ac_cv_func_prctl" = "xyes" ) ; then 20553 test "x$seccomp_audit_arch" = "x" && \ 20554 as_fn_error $? "seccomp_filter sandbox not supported on $host" "$LINENO" 5 20555 test "x$have_linux_no_new_privs" != "x1" && \ 20556 as_fn_error $? "seccomp_filter sandbox requires PR_SET_NO_NEW_PRIVS" "$LINENO" 5 20557 test "x$have_seccomp_filter" != "x1" && \ 20558 as_fn_error $? "seccomp_filter sandbox requires seccomp headers" "$LINENO" 5 20559 test "x$ac_cv_func_prctl" != "xyes" && \ 20560 as_fn_error $? "seccomp_filter sandbox requires prctl function" "$LINENO" 5 20561 SANDBOX_STYLE="seccomp_filter" 20562 20563printf "%s\n" "#define SANDBOX_SECCOMP_FILTER 1" >>confdefs.h 20564 20565elif test "x$sandbox_arg" = "xcapsicum" || \ 20566 ( test -z "$sandbox_arg" && \ 20567 test "x$disable_capsicum" != "xyes" && \ 20568 test "x$ac_cv_header_sys_capsicum_h" = "xyes" && \ 20569 test "x$ac_cv_func_cap_rights_limit" = "xyes") ; then 20570 test "x$ac_cv_header_sys_capsicum_h" != "xyes" && \ 20571 as_fn_error $? "capsicum sandbox requires sys/capsicum.h header" "$LINENO" 5 20572 test "x$ac_cv_func_cap_rights_limit" != "xyes" && \ 20573 as_fn_error $? "capsicum sandbox requires cap_rights_limit function" "$LINENO" 5 20574 SANDBOX_STYLE="capsicum" 20575 20576printf "%s\n" "#define SANDBOX_CAPSICUM 1" >>confdefs.h 20577 20578elif test "x$sandbox_arg" = "xrlimit" || \ 20579 ( test -z "$sandbox_arg" && test "x$ac_cv_func_setrlimit" = "xyes" && \ 20580 test "x$select_works_with_rlimit" = "xyes" && \ 20581 test "x$rlimit_nofile_zero_works" = "xyes" ) ; then 20582 test "x$ac_cv_func_setrlimit" != "xyes" && \ 20583 as_fn_error $? "rlimit sandbox requires setrlimit function" "$LINENO" 5 20584 test "x$select_works_with_rlimit" != "xyes" && \ 20585 as_fn_error $? "rlimit sandbox requires select to work with rlimit" "$LINENO" 5 20586 SANDBOX_STYLE="rlimit" 20587 20588printf "%s\n" "#define SANDBOX_RLIMIT 1" >>confdefs.h 20589 20590elif test "x$sandbox_arg" = "xsolaris" || \ 20591 ( test -z "$sandbox_arg" && test "x$SOLARIS_PRIVS" = "xyes" ) ; then 20592 SANDBOX_STYLE="solaris" 20593 20594printf "%s\n" "#define SANDBOX_SOLARIS 1" >>confdefs.h 20595 20596elif test -z "$sandbox_arg" || test "x$sandbox_arg" = "xno" || \ 20597 test "x$sandbox_arg" = "xnone" || test "x$sandbox_arg" = "xnull" ; then 20598 SANDBOX_STYLE="none" 20599 20600printf "%s\n" "#define SANDBOX_NULL 1" >>confdefs.h 20601 20602else 20603 as_fn_error $? "unsupported --with-sandbox" "$LINENO" 5 20604fi 20605 20606# Cheap hack to ensure NEWS-OS libraries are arranged right. 20607if test ! -z "$SONY" ; then 20608 LIBS="$LIBS -liberty"; 20609fi 20610 20611# Check for long long datatypes 20612ac_fn_c_check_type "$LINENO" "long long" "ac_cv_type_long_long" "$ac_includes_default" 20613if test "x$ac_cv_type_long_long" = xyes 20614then : 20615 20616printf "%s\n" "#define HAVE_LONG_LONG 1" >>confdefs.h 20617 20618 20619fi 20620ac_fn_c_check_type "$LINENO" "unsigned long long" "ac_cv_type_unsigned_long_long" "$ac_includes_default" 20621if test "x$ac_cv_type_unsigned_long_long" = xyes 20622then : 20623 20624printf "%s\n" "#define HAVE_UNSIGNED_LONG_LONG 1" >>confdefs.h 20625 20626 20627fi 20628ac_fn_c_check_type "$LINENO" "long double" "ac_cv_type_long_double" "$ac_includes_default" 20629if test "x$ac_cv_type_long_double" = xyes 20630then : 20631 20632printf "%s\n" "#define HAVE_LONG_DOUBLE 1" >>confdefs.h 20633 20634 20635fi 20636 20637 20638# Check datatype sizes 20639# The cast to long int works around a bug in the HP C Compiler 20640# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects 20641# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. 20642# This bug is HP SR number 8606223364. 20643{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of short int" >&5 20644printf %s "checking size of short int... " >&6; } 20645if test ${ac_cv_sizeof_short_int+y} 20646then : 20647 printf %s "(cached) " >&6 20648else $as_nop 20649 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short int))" "ac_cv_sizeof_short_int" "$ac_includes_default" 20650then : 20651 20652else $as_nop 20653 if test "$ac_cv_type_short_int" = yes; then 20654 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 20655printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} 20656as_fn_error 77 "cannot compute sizeof (short int) 20657See \`config.log' for more details" "$LINENO" 5; } 20658 else 20659 ac_cv_sizeof_short_int=0 20660 fi 20661fi 20662 20663fi 20664{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short_int" >&5 20665printf "%s\n" "$ac_cv_sizeof_short_int" >&6; } 20666 20667 20668 20669printf "%s\n" "#define SIZEOF_SHORT_INT $ac_cv_sizeof_short_int" >>confdefs.h 20670 20671 20672# The cast to long int works around a bug in the HP C Compiler 20673# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects 20674# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. 20675# This bug is HP SR number 8606223364. 20676{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of int" >&5 20677printf %s "checking size of int... " >&6; } 20678if test ${ac_cv_sizeof_int+y} 20679then : 20680 printf %s "(cached) " >&6 20681else $as_nop 20682 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default" 20683then : 20684 20685else $as_nop 20686 if test "$ac_cv_type_int" = yes; then 20687 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 20688printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} 20689as_fn_error 77 "cannot compute sizeof (int) 20690See \`config.log' for more details" "$LINENO" 5; } 20691 else 20692 ac_cv_sizeof_int=0 20693 fi 20694fi 20695 20696fi 20697{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5 20698printf "%s\n" "$ac_cv_sizeof_int" >&6; } 20699 20700 20701 20702printf "%s\n" "#define SIZEOF_INT $ac_cv_sizeof_int" >>confdefs.h 20703 20704 20705# The cast to long int works around a bug in the HP C Compiler 20706# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects 20707# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. 20708# This bug is HP SR number 8606223364. 20709{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of long int" >&5 20710printf %s "checking size of long int... " >&6; } 20711if test ${ac_cv_sizeof_long_int+y} 20712then : 20713 printf %s "(cached) " >&6 20714else $as_nop 20715 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long int))" "ac_cv_sizeof_long_int" "$ac_includes_default" 20716then : 20717 20718else $as_nop 20719 if test "$ac_cv_type_long_int" = yes; then 20720 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 20721printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} 20722as_fn_error 77 "cannot compute sizeof (long int) 20723See \`config.log' for more details" "$LINENO" 5; } 20724 else 20725 ac_cv_sizeof_long_int=0 20726 fi 20727fi 20728 20729fi 20730{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_int" >&5 20731printf "%s\n" "$ac_cv_sizeof_long_int" >&6; } 20732 20733 20734 20735printf "%s\n" "#define SIZEOF_LONG_INT $ac_cv_sizeof_long_int" >>confdefs.h 20736 20737 20738# The cast to long int works around a bug in the HP C Compiler 20739# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects 20740# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. 20741# This bug is HP SR number 8606223364. 20742{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of long long int" >&5 20743printf %s "checking size of long long int... " >&6; } 20744if test ${ac_cv_sizeof_long_long_int+y} 20745then : 20746 printf %s "(cached) " >&6 20747else $as_nop 20748 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long int))" "ac_cv_sizeof_long_long_int" "$ac_includes_default" 20749then : 20750 20751else $as_nop 20752 if test "$ac_cv_type_long_long_int" = yes; then 20753 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 20754printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} 20755as_fn_error 77 "cannot compute sizeof (long long int) 20756See \`config.log' for more details" "$LINENO" 5; } 20757 else 20758 ac_cv_sizeof_long_long_int=0 20759 fi 20760fi 20761 20762fi 20763{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long_int" >&5 20764printf "%s\n" "$ac_cv_sizeof_long_long_int" >&6; } 20765 20766 20767 20768printf "%s\n" "#define SIZEOF_LONG_LONG_INT $ac_cv_sizeof_long_long_int" >>confdefs.h 20769 20770 20771# The cast to long int works around a bug in the HP C Compiler 20772# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects 20773# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. 20774# This bug is HP SR number 8606223364. 20775{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of time_t" >&5 20776printf %s "checking size of time_t... " >&6; } 20777if test ${ac_cv_sizeof_time_t+y} 20778then : 20779 printf %s "(cached) " >&6 20780else $as_nop 20781 if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (time_t))" "ac_cv_sizeof_time_t" " 20782 #include <sys/types.h> 20783 #ifdef HAVE_SYS_TIME_H 20784 # include <sys/time.h> 20785 #endif 20786 #ifdef HAVE_TIME_H 20787 # include <time.h> 20788 #endif 20789 20790 20791" 20792then : 20793 20794else $as_nop 20795 if test "$ac_cv_type_time_t" = yes; then 20796 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 20797printf "%s\n" "$as_me: error: in \`$ac_pwd':" >&2;} 20798as_fn_error 77 "cannot compute sizeof (time_t) 20799See \`config.log' for more details" "$LINENO" 5; } 20800 else 20801 ac_cv_sizeof_time_t=0 20802 fi 20803fi 20804 20805fi 20806{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_time_t" >&5 20807printf "%s\n" "$ac_cv_sizeof_time_t" >&6; } 20808 20809 20810 20811printf "%s\n" "#define SIZEOF_TIME_T $ac_cv_sizeof_time_t" >>confdefs.h 20812 20813 20814 20815# Sanity check long long for some platforms (AIX) 20816if test "x$ac_cv_sizeof_long_long_int" = "x4" ; then 20817 ac_cv_sizeof_long_long_int=0 20818fi 20819 20820# compute LLONG_MIN and LLONG_MAX if we don't know them. 20821if test -z "$have_llong_max" && test -z "$have_long_long_max"; then 20822 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for max value of long long" >&5 20823printf %s "checking for max value of long long... " >&6; } 20824 if test "$cross_compiling" = yes 20825then : 20826 20827 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: not checking" >&5 20828printf "%s\n" "$as_me: WARNING: cross compiling: not checking" >&2;} 20829 20830 20831else $as_nop 20832 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 20833/* end confdefs.h. */ 20834 20835#include <stdio.h> 20836#include <stdlib.h> 20837/* Why is this so damn hard? */ 20838#ifdef __GNUC__ 20839# undef __GNUC__ 20840#endif 20841#define __USE_ISOC99 20842#include <limits.h> 20843#define DATA "conftest.llminmax" 20844#define my_abs(a) ((a) < 0 ? ((a) * -1) : (a)) 20845 20846/* 20847 * printf in libc on some platforms (eg old Tru64) does not understand %lld so 20848 * we do this the hard way. 20849 */ 20850static int 20851fprint_ll(FILE *f, long long n) 20852{ 20853 unsigned int i; 20854 int l[sizeof(long long) * 8]; 20855 20856 if (n < 0) 20857 if (fprintf(f, "-") < 0) 20858 return -1; 20859 for (i = 0; n != 0; i++) { 20860 l[i] = my_abs(n % 10); 20861 n /= 10; 20862 } 20863 do { 20864 if (fprintf(f, "%d", l[--i]) < 0) 20865 return -1; 20866 } while (i != 0); 20867 if (fprintf(f, " ") < 0) 20868 return -1; 20869 return 0; 20870} 20871 20872int 20873main (void) 20874{ 20875 20876 FILE *f; 20877 long long i, llmin, llmax = 0; 20878 20879 if((f = fopen(DATA,"w")) == NULL) 20880 exit(1); 20881 20882#if defined(LLONG_MIN) && defined(LLONG_MAX) 20883 fprintf(stderr, "Using system header for LLONG_MIN and LLONG_MAX\n"); 20884 llmin = LLONG_MIN; 20885 llmax = LLONG_MAX; 20886#else 20887 fprintf(stderr, "Calculating LLONG_MIN and LLONG_MAX\n"); 20888 /* This will work on one's complement and two's complement */ 20889 for (i = 1; i > llmax; i <<= 1, i++) 20890 llmax = i; 20891 llmin = llmax + 1LL; /* wrap */ 20892#endif 20893 20894 /* Sanity check */ 20895 if (llmin + 1 < llmin || llmin - 1 < llmin || llmax + 1 > llmax 20896 || llmax - 1 > llmax || llmin == llmax || llmin == 0 20897 || llmax == 0 || llmax < LONG_MAX || llmin > LONG_MIN) { 20898 fprintf(f, "unknown unknown\n"); 20899 exit(2); 20900 } 20901 20902 if (fprint_ll(f, llmin) < 0) 20903 exit(3); 20904 if (fprint_ll(f, llmax) < 0) 20905 exit(4); 20906 if (fclose(f) < 0) 20907 exit(5); 20908 exit(0); 20909 20910 ; 20911 return 0; 20912} 20913_ACEOF 20914if ac_fn_c_try_run "$LINENO" 20915then : 20916 20917 llong_min=`$AWK '{print $1}' conftest.llminmax` 20918 llong_max=`$AWK '{print $2}' conftest.llminmax` 20919 20920 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $llong_max" >&5 20921printf "%s\n" "$llong_max" >&6; } 20922 20923printf "%s\n" "#define LLONG_MAX ${llong_max}LL" >>confdefs.h 20924 20925 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for min value of long long" >&5 20926printf %s "checking for min value of long long... " >&6; } 20927 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $llong_min" >&5 20928printf "%s\n" "$llong_min" >&6; } 20929 20930printf "%s\n" "#define LLONG_MIN ${llong_min}LL" >>confdefs.h 20931 20932 20933else $as_nop 20934 20935 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not found" >&5 20936printf "%s\n" "not found" >&6; } 20937 20938fi 20939rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 20940 conftest.$ac_objext conftest.beam conftest.$ac_ext 20941fi 20942 20943fi 20944 20945ac_fn_check_decl "$LINENO" "UINT32_MAX" "ac_cv_have_decl_UINT32_MAX" " 20946#ifdef HAVE_SYS_LIMITS_H 20947# include <sys/limits.h> 20948#endif 20949#ifdef HAVE_LIMITS_H 20950# include <limits.h> 20951#endif 20952#ifdef HAVE_STDINT_H 20953# include <stdint.h> 20954#endif 20955 20956" "$ac_c_undeclared_builtin_options" "CFLAGS" 20957if test "x$ac_cv_have_decl_UINT32_MAX" = xyes 20958then : 20959 ac_have_decl=1 20960else $as_nop 20961 ac_have_decl=0 20962fi 20963printf "%s\n" "#define HAVE_DECL_UINT32_MAX $ac_have_decl" >>confdefs.h 20964 20965 20966# More checks for data types 20967{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for u_int type" >&5 20968printf %s "checking for u_int type... " >&6; } 20969if test ${ac_cv_have_u_int+y} 20970then : 20971 printf %s "(cached) " >&6 20972else $as_nop 20973 20974 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 20975/* end confdefs.h. */ 20976 #include <sys/types.h> 20977int 20978main (void) 20979{ 20980 u_int a; a = 1; 20981 ; 20982 return 0; 20983} 20984_ACEOF 20985if ac_fn_c_try_compile "$LINENO" 20986then : 20987 ac_cv_have_u_int="yes" 20988else $as_nop 20989 ac_cv_have_u_int="no" 20990 20991fi 20992rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 20993 20994fi 20995{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_u_int" >&5 20996printf "%s\n" "$ac_cv_have_u_int" >&6; } 20997if test "x$ac_cv_have_u_int" = "xyes" ; then 20998 20999printf "%s\n" "#define HAVE_U_INT 1" >>confdefs.h 21000 21001 have_u_int=1 21002fi 21003 21004{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for intXX_t types" >&5 21005printf %s "checking for intXX_t types... " >&6; } 21006if test ${ac_cv_have_intxx_t+y} 21007then : 21008 printf %s "(cached) " >&6 21009else $as_nop 21010 21011 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 21012/* end confdefs.h. */ 21013 #include <sys/types.h> 21014int 21015main (void) 21016{ 21017 int8_t a; int16_t b; int32_t c; a = b = c = 1; 21018 ; 21019 return 0; 21020} 21021_ACEOF 21022if ac_fn_c_try_compile "$LINENO" 21023then : 21024 ac_cv_have_intxx_t="yes" 21025else $as_nop 21026 ac_cv_have_intxx_t="no" 21027 21028fi 21029rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 21030 21031fi 21032{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_intxx_t" >&5 21033printf "%s\n" "$ac_cv_have_intxx_t" >&6; } 21034if test "x$ac_cv_have_intxx_t" = "xyes" ; then 21035 21036printf "%s\n" "#define HAVE_INTXX_T 1" >>confdefs.h 21037 21038 have_intxx_t=1 21039fi 21040 21041if (test -z "$have_intxx_t" && \ 21042 test "x$ac_cv_header_stdint_h" = "xyes") 21043then 21044 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for intXX_t types in stdint.h" >&5 21045printf %s "checking for intXX_t types in stdint.h... " >&6; } 21046 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 21047/* end confdefs.h. */ 21048 #include <stdint.h> 21049int 21050main (void) 21051{ 21052 int8_t a; int16_t b; int32_t c; a = b = c = 1; 21053 ; 21054 return 0; 21055} 21056_ACEOF 21057if ac_fn_c_try_compile "$LINENO" 21058then : 21059 21060 printf "%s\n" "#define HAVE_INTXX_T 1" >>confdefs.h 21061 21062 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 21063printf "%s\n" "yes" >&6; } 21064 21065else $as_nop 21066 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 21067printf "%s\n" "no" >&6; } 21068 21069fi 21070rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 21071fi 21072 21073{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for int64_t type" >&5 21074printf %s "checking for int64_t type... " >&6; } 21075if test ${ac_cv_have_int64_t+y} 21076then : 21077 printf %s "(cached) " >&6 21078else $as_nop 21079 21080 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 21081/* end confdefs.h. */ 21082 21083#include <sys/types.h> 21084#ifdef HAVE_STDINT_H 21085# include <stdint.h> 21086#endif 21087#include <sys/socket.h> 21088#ifdef HAVE_SYS_BITYPES_H 21089# include <sys/bitypes.h> 21090#endif 21091 21092int 21093main (void) 21094{ 21095 21096int64_t a; a = 1; 21097 21098 ; 21099 return 0; 21100} 21101_ACEOF 21102if ac_fn_c_try_compile "$LINENO" 21103then : 21104 ac_cv_have_int64_t="yes" 21105else $as_nop 21106 ac_cv_have_int64_t="no" 21107 21108fi 21109rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 21110 21111fi 21112{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_int64_t" >&5 21113printf "%s\n" "$ac_cv_have_int64_t" >&6; } 21114if test "x$ac_cv_have_int64_t" = "xyes" ; then 21115 21116printf "%s\n" "#define HAVE_INT64_T 1" >>confdefs.h 21117 21118fi 21119 21120{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for u_intXX_t types" >&5 21121printf %s "checking for u_intXX_t types... " >&6; } 21122if test ${ac_cv_have_u_intxx_t+y} 21123then : 21124 printf %s "(cached) " >&6 21125else $as_nop 21126 21127 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 21128/* end confdefs.h. */ 21129 #include <sys/types.h> 21130int 21131main (void) 21132{ 21133 u_int8_t a; u_int16_t b; u_int32_t c; a = b = c = 1; 21134 ; 21135 return 0; 21136} 21137_ACEOF 21138if ac_fn_c_try_compile "$LINENO" 21139then : 21140 ac_cv_have_u_intxx_t="yes" 21141else $as_nop 21142 ac_cv_have_u_intxx_t="no" 21143 21144fi 21145rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 21146 21147fi 21148{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_u_intxx_t" >&5 21149printf "%s\n" "$ac_cv_have_u_intxx_t" >&6; } 21150if test "x$ac_cv_have_u_intxx_t" = "xyes" ; then 21151 21152printf "%s\n" "#define HAVE_U_INTXX_T 1" >>confdefs.h 21153 21154 have_u_intxx_t=1 21155fi 21156 21157if test -z "$have_u_intxx_t" ; then 21158 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for u_intXX_t types in sys/socket.h" >&5 21159printf %s "checking for u_intXX_t types in sys/socket.h... " >&6; } 21160 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 21161/* end confdefs.h. */ 21162 #include <sys/socket.h> 21163int 21164main (void) 21165{ 21166 u_int8_t a; u_int16_t b; u_int32_t c; a = b = c = 1; 21167 ; 21168 return 0; 21169} 21170_ACEOF 21171if ac_fn_c_try_compile "$LINENO" 21172then : 21173 21174 printf "%s\n" "#define HAVE_U_INTXX_T 1" >>confdefs.h 21175 21176 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 21177printf "%s\n" "yes" >&6; } 21178 21179else $as_nop 21180 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 21181printf "%s\n" "no" >&6; } 21182 21183fi 21184rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 21185fi 21186 21187{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for u_int64_t types" >&5 21188printf %s "checking for u_int64_t types... " >&6; } 21189if test ${ac_cv_have_u_int64_t+y} 21190then : 21191 printf %s "(cached) " >&6 21192else $as_nop 21193 21194 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 21195/* end confdefs.h. */ 21196 #include <sys/types.h> 21197int 21198main (void) 21199{ 21200 u_int64_t a; a = 1; 21201 ; 21202 return 0; 21203} 21204_ACEOF 21205if ac_fn_c_try_compile "$LINENO" 21206then : 21207 ac_cv_have_u_int64_t="yes" 21208else $as_nop 21209 ac_cv_have_u_int64_t="no" 21210 21211fi 21212rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 21213 21214fi 21215{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_u_int64_t" >&5 21216printf "%s\n" "$ac_cv_have_u_int64_t" >&6; } 21217if test "x$ac_cv_have_u_int64_t" = "xyes" ; then 21218 21219printf "%s\n" "#define HAVE_U_INT64_T 1" >>confdefs.h 21220 21221 have_u_int64_t=1 21222fi 21223 21224if (test -z "$have_u_int64_t" && \ 21225 test "x$ac_cv_header_sys_bitypes_h" = "xyes") 21226then 21227 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for u_int64_t type in sys/bitypes.h" >&5 21228printf %s "checking for u_int64_t type in sys/bitypes.h... " >&6; } 21229 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 21230/* end confdefs.h. */ 21231 #include <sys/bitypes.h> 21232int 21233main (void) 21234{ 21235 u_int64_t a; a = 1 21236 ; 21237 return 0; 21238} 21239_ACEOF 21240if ac_fn_c_try_compile "$LINENO" 21241then : 21242 21243 printf "%s\n" "#define HAVE_U_INT64_T 1" >>confdefs.h 21244 21245 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 21246printf "%s\n" "yes" >&6; } 21247 21248else $as_nop 21249 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 21250printf "%s\n" "no" >&6; } 21251 21252fi 21253rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 21254fi 21255 21256if test -z "$have_u_intxx_t" ; then 21257 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for uintXX_t types" >&5 21258printf %s "checking for uintXX_t types... " >&6; } 21259if test ${ac_cv_have_uintxx_t+y} 21260then : 21261 printf %s "(cached) " >&6 21262else $as_nop 21263 21264 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 21265/* end confdefs.h. */ 21266 21267#include <sys/types.h> 21268 21269int 21270main (void) 21271{ 21272 21273 uint8_t a; 21274 uint16_t b; 21275 uint32_t c; 21276 a = b = c = 1; 21277 21278 ; 21279 return 0; 21280} 21281_ACEOF 21282if ac_fn_c_try_compile "$LINENO" 21283then : 21284 ac_cv_have_uintxx_t="yes" 21285else $as_nop 21286 ac_cv_have_uintxx_t="no" 21287 21288fi 21289rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 21290 21291fi 21292{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_uintxx_t" >&5 21293printf "%s\n" "$ac_cv_have_uintxx_t" >&6; } 21294 if test "x$ac_cv_have_uintxx_t" = "xyes" ; then 21295 21296printf "%s\n" "#define HAVE_UINTXX_T 1" >>confdefs.h 21297 21298 fi 21299fi 21300 21301if (test -z "$have_uintxx_t" && \ 21302 test "x$ac_cv_header_stdint_h" = "xyes") 21303then 21304 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for uintXX_t types in stdint.h" >&5 21305printf %s "checking for uintXX_t types in stdint.h... " >&6; } 21306 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 21307/* end confdefs.h. */ 21308 #include <stdint.h> 21309int 21310main (void) 21311{ 21312 uint8_t a; uint16_t b; uint32_t c; a = b = c = 1; 21313 ; 21314 return 0; 21315} 21316_ACEOF 21317if ac_fn_c_try_compile "$LINENO" 21318then : 21319 21320 printf "%s\n" "#define HAVE_UINTXX_T 1" >>confdefs.h 21321 21322 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 21323printf "%s\n" "yes" >&6; } 21324 21325else $as_nop 21326 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 21327printf "%s\n" "no" >&6; } 21328 21329fi 21330rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 21331fi 21332 21333if (test -z "$have_uintxx_t" && \ 21334 test "x$ac_cv_header_inttypes_h" = "xyes") 21335then 21336 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for uintXX_t types in inttypes.h" >&5 21337printf %s "checking for uintXX_t types in inttypes.h... " >&6; } 21338 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 21339/* end confdefs.h. */ 21340 #include <inttypes.h> 21341int 21342main (void) 21343{ 21344 uint8_t a; uint16_t b; uint32_t c; a = b = c = 1; 21345 ; 21346 return 0; 21347} 21348_ACEOF 21349if ac_fn_c_try_compile "$LINENO" 21350then : 21351 21352 printf "%s\n" "#define HAVE_UINTXX_T 1" >>confdefs.h 21353 21354 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 21355printf "%s\n" "yes" >&6; } 21356 21357else $as_nop 21358 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 21359printf "%s\n" "no" >&6; } 21360 21361fi 21362rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 21363fi 21364 21365if (test -z "$have_u_intxx_t" || test -z "$have_intxx_t" && \ 21366 test "x$ac_cv_header_sys_bitypes_h" = "xyes") 21367then 21368 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for intXX_t and u_intXX_t types in sys/bitypes.h" >&5 21369printf %s "checking for intXX_t and u_intXX_t types in sys/bitypes.h... " >&6; } 21370 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 21371/* end confdefs.h. */ 21372 21373#include <sys/bitypes.h> 21374 21375int 21376main (void) 21377{ 21378 21379 int8_t a; int16_t b; int32_t c; 21380 u_int8_t e; u_int16_t f; u_int32_t g; 21381 a = b = c = e = f = g = 1; 21382 21383 ; 21384 return 0; 21385} 21386_ACEOF 21387if ac_fn_c_try_compile "$LINENO" 21388then : 21389 21390 printf "%s\n" "#define HAVE_U_INTXX_T 1" >>confdefs.h 21391 21392 printf "%s\n" "#define HAVE_INTXX_T 1" >>confdefs.h 21393 21394 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 21395printf "%s\n" "yes" >&6; } 21396 21397else $as_nop 21398 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 21399printf "%s\n" "no" >&6; } 21400 21401fi 21402rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 21403fi 21404 21405 21406{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for u_char" >&5 21407printf %s "checking for u_char... " >&6; } 21408if test ${ac_cv_have_u_char+y} 21409then : 21410 printf %s "(cached) " >&6 21411else $as_nop 21412 21413 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 21414/* end confdefs.h. */ 21415 #include <sys/types.h> 21416int 21417main (void) 21418{ 21419 u_char foo; foo = 125; 21420 ; 21421 return 0; 21422} 21423_ACEOF 21424if ac_fn_c_try_compile "$LINENO" 21425then : 21426 ac_cv_have_u_char="yes" 21427else $as_nop 21428 ac_cv_have_u_char="no" 21429 21430fi 21431rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 21432 21433fi 21434{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_u_char" >&5 21435printf "%s\n" "$ac_cv_have_u_char" >&6; } 21436if test "x$ac_cv_have_u_char" = "xyes" ; then 21437 21438printf "%s\n" "#define HAVE_U_CHAR 1" >>confdefs.h 21439 21440fi 21441 21442ac_fn_c_check_type "$LINENO" "intmax_t" "ac_cv_type_intmax_t" " 21443#include <sys/types.h> 21444#ifdef HAVE_STDINT_H 21445# include <stdint.h> 21446#endif 21447 21448" 21449if test "x$ac_cv_type_intmax_t" = xyes 21450then : 21451 21452printf "%s\n" "#define HAVE_INTMAX_T 1" >>confdefs.h 21453 21454 21455fi 21456ac_fn_c_check_type "$LINENO" "uintmax_t" "ac_cv_type_uintmax_t" " 21457#include <sys/types.h> 21458#ifdef HAVE_STDINT_H 21459# include <stdint.h> 21460#endif 21461 21462" 21463if test "x$ac_cv_type_uintmax_t" = xyes 21464then : 21465 21466printf "%s\n" "#define HAVE_UINTMAX_T 1" >>confdefs.h 21467 21468 21469fi 21470 21471 21472 21473 ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "#include <sys/types.h> 21474#include <sys/socket.h> 21475" 21476if test "x$ac_cv_type_socklen_t" = xyes 21477then : 21478 21479else $as_nop 21480 21481 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for socklen_t equivalent" >&5 21482printf %s "checking for socklen_t equivalent... " >&6; } 21483 if test ${curl_cv_socklen_t_equiv+y} 21484then : 21485 printf %s "(cached) " >&6 21486else $as_nop 21487 21488 # Systems have either "struct sockaddr *" or 21489 # "void *" as the second argument to getpeername 21490 curl_cv_socklen_t_equiv= 21491 for arg2 in "struct sockaddr" void; do 21492 for t in int size_t unsigned long "unsigned long"; do 21493 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 21494/* end confdefs.h. */ 21495 21496 21497 #include <sys/types.h> 21498 #include <sys/socket.h> 21499 int getpeername (int, $arg2 *, $t *); 21500 21501int 21502main (void) 21503{ 21504 21505 $t len; 21506 getpeername(0,0,&len); 21507 21508 ; 21509 return 0; 21510} 21511 21512_ACEOF 21513if ac_fn_c_try_compile "$LINENO" 21514then : 21515 21516 curl_cv_socklen_t_equiv="$t" 21517 break 21518 21519fi 21520rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 21521 done 21522 done 21523 21524 if test "x$curl_cv_socklen_t_equiv" = x; then 21525 as_fn_error $? "Cannot find a type to use in place of socklen_t" "$LINENO" 5 21526 fi 21527 21528fi 21529 21530 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $curl_cv_socklen_t_equiv" >&5 21531printf "%s\n" "$curl_cv_socklen_t_equiv" >&6; } 21532 21533printf "%s\n" "#define socklen_t $curl_cv_socklen_t_equiv" >>confdefs.h 21534 21535fi 21536 21537 21538 21539ac_fn_c_check_type "$LINENO" "sig_atomic_t" "ac_cv_type_sig_atomic_t" "#include <signal.h> 21540" 21541if test "x$ac_cv_type_sig_atomic_t" = xyes 21542then : 21543 21544printf "%s\n" "#define HAVE_SIG_ATOMIC_T 1" >>confdefs.h 21545 21546 21547fi 21548ac_fn_c_check_type "$LINENO" "sighandler_t" "ac_cv_type_sighandler_t" "#include <signal.h> 21549" 21550if test "x$ac_cv_type_sighandler_t" = xyes 21551then : 21552 21553printf "%s\n" "#define HAVE_SIGHANDLER_T 1" >>confdefs.h 21554 21555 21556fi 21557 21558ac_fn_c_check_type "$LINENO" "fsblkcnt_t" "ac_cv_type_fsblkcnt_t" " 21559#include <sys/types.h> 21560#ifdef HAVE_SYS_BITYPES_H 21561#include <sys/bitypes.h> 21562#endif 21563#ifdef HAVE_SYS_STATFS_H 21564#include <sys/statfs.h> 21565#endif 21566#ifdef HAVE_SYS_STATVFS_H 21567#include <sys/statvfs.h> 21568#endif 21569 21570" 21571if test "x$ac_cv_type_fsblkcnt_t" = xyes 21572then : 21573 21574printf "%s\n" "#define HAVE_FSBLKCNT_T 1" >>confdefs.h 21575 21576 21577fi 21578ac_fn_c_check_type "$LINENO" "fsfilcnt_t" "ac_cv_type_fsfilcnt_t" " 21579#include <sys/types.h> 21580#ifdef HAVE_SYS_BITYPES_H 21581#include <sys/bitypes.h> 21582#endif 21583#ifdef HAVE_SYS_STATFS_H 21584#include <sys/statfs.h> 21585#endif 21586#ifdef HAVE_SYS_STATVFS_H 21587#include <sys/statvfs.h> 21588#endif 21589 21590" 21591if test "x$ac_cv_type_fsfilcnt_t" = xyes 21592then : 21593 21594printf "%s\n" "#define HAVE_FSFILCNT_T 1" >>confdefs.h 21595 21596 21597fi 21598 21599 21600ac_fn_c_check_member "$LINENO" "struct statfs" "f_files" "ac_cv_member_struct_statfs_f_files" " 21601#include <sys/param.h> 21602#include <sys/types.h> 21603#ifdef HAVE_SYS_BITYPES_H 21604#include <sys/bitypes.h> 21605#endif 21606#ifdef HAVE_SYS_STATFS_H 21607#include <sys/statfs.h> 21608#endif 21609#ifdef HAVE_SYS_STATVFS_H 21610#include <sys/statvfs.h> 21611#endif 21612#ifdef HAVE_SYS_VFS_H 21613#include <sys/vfs.h> 21614#endif 21615#ifdef HAVE_SYS_MOUNT_H 21616#include <sys/mount.h> 21617#endif 21618 21619" 21620if test "x$ac_cv_member_struct_statfs_f_files" = xyes 21621then : 21622 21623printf "%s\n" "#define HAVE_STRUCT_STATFS_F_FILES 1" >>confdefs.h 21624 21625 21626fi 21627ac_fn_c_check_member "$LINENO" "struct statfs" "f_flags" "ac_cv_member_struct_statfs_f_flags" " 21628#include <sys/param.h> 21629#include <sys/types.h> 21630#ifdef HAVE_SYS_BITYPES_H 21631#include <sys/bitypes.h> 21632#endif 21633#ifdef HAVE_SYS_STATFS_H 21634#include <sys/statfs.h> 21635#endif 21636#ifdef HAVE_SYS_STATVFS_H 21637#include <sys/statvfs.h> 21638#endif 21639#ifdef HAVE_SYS_VFS_H 21640#include <sys/vfs.h> 21641#endif 21642#ifdef HAVE_SYS_MOUNT_H 21643#include <sys/mount.h> 21644#endif 21645 21646" 21647if test "x$ac_cv_member_struct_statfs_f_flags" = xyes 21648then : 21649 21650printf "%s\n" "#define HAVE_STRUCT_STATFS_F_FLAGS 1" >>confdefs.h 21651 21652 21653fi 21654 21655 21656 21657ac_fn_c_check_type "$LINENO" "in_addr_t" "ac_cv_type_in_addr_t" "#include <sys/types.h> 21658#include <netinet/in.h> 21659" 21660if test "x$ac_cv_type_in_addr_t" = xyes 21661then : 21662 21663printf "%s\n" "#define HAVE_IN_ADDR_T 1" >>confdefs.h 21664 21665 21666fi 21667ac_fn_c_check_type "$LINENO" "in_port_t" "ac_cv_type_in_port_t" "#include <sys/types.h> 21668#include <netinet/in.h> 21669" 21670if test "x$ac_cv_type_in_port_t" = xyes 21671then : 21672 21673printf "%s\n" "#define HAVE_IN_PORT_T 1" >>confdefs.h 21674 21675 21676fi 21677 21678 21679{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for size_t" >&5 21680printf %s "checking for size_t... " >&6; } 21681if test ${ac_cv_have_size_t+y} 21682then : 21683 printf %s "(cached) " >&6 21684else $as_nop 21685 21686 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 21687/* end confdefs.h. */ 21688 #include <sys/types.h> 21689int 21690main (void) 21691{ 21692 size_t foo; foo = 1235; 21693 ; 21694 return 0; 21695} 21696_ACEOF 21697if ac_fn_c_try_compile "$LINENO" 21698then : 21699 ac_cv_have_size_t="yes" 21700else $as_nop 21701 ac_cv_have_size_t="no" 21702 21703fi 21704rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 21705 21706fi 21707{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_size_t" >&5 21708printf "%s\n" "$ac_cv_have_size_t" >&6; } 21709if test "x$ac_cv_have_size_t" = "xyes" ; then 21710 21711printf "%s\n" "#define HAVE_SIZE_T 1" >>confdefs.h 21712 21713fi 21714 21715{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5 21716printf %s "checking for ssize_t... " >&6; } 21717if test ${ac_cv_have_ssize_t+y} 21718then : 21719 printf %s "(cached) " >&6 21720else $as_nop 21721 21722 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 21723/* end confdefs.h. */ 21724 #include <sys/types.h> 21725int 21726main (void) 21727{ 21728 ssize_t foo; foo = 1235; 21729 ; 21730 return 0; 21731} 21732_ACEOF 21733if ac_fn_c_try_compile "$LINENO" 21734then : 21735 ac_cv_have_ssize_t="yes" 21736else $as_nop 21737 ac_cv_have_ssize_t="no" 21738 21739fi 21740rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 21741 21742fi 21743{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_ssize_t" >&5 21744printf "%s\n" "$ac_cv_have_ssize_t" >&6; } 21745if test "x$ac_cv_have_ssize_t" = "xyes" ; then 21746 21747printf "%s\n" "#define HAVE_SSIZE_T 1" >>confdefs.h 21748 21749fi 21750 21751{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for clock_t" >&5 21752printf %s "checking for clock_t... " >&6; } 21753if test ${ac_cv_have_clock_t+y} 21754then : 21755 printf %s "(cached) " >&6 21756else $as_nop 21757 21758 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 21759/* end confdefs.h. */ 21760 #include <time.h> 21761int 21762main (void) 21763{ 21764 clock_t foo; foo = 1235; 21765 ; 21766 return 0; 21767} 21768_ACEOF 21769if ac_fn_c_try_compile "$LINENO" 21770then : 21771 ac_cv_have_clock_t="yes" 21772else $as_nop 21773 ac_cv_have_clock_t="no" 21774 21775fi 21776rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 21777 21778fi 21779{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_clock_t" >&5 21780printf "%s\n" "$ac_cv_have_clock_t" >&6; } 21781if test "x$ac_cv_have_clock_t" = "xyes" ; then 21782 21783printf "%s\n" "#define HAVE_CLOCK_T 1" >>confdefs.h 21784 21785fi 21786 21787{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sa_family_t" >&5 21788printf %s "checking for sa_family_t... " >&6; } 21789if test ${ac_cv_have_sa_family_t+y} 21790then : 21791 printf %s "(cached) " >&6 21792else $as_nop 21793 21794 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 21795/* end confdefs.h. */ 21796 21797#include <sys/types.h> 21798#include <sys/socket.h> 21799 21800int 21801main (void) 21802{ 21803 sa_family_t foo; foo = 1235; 21804 ; 21805 return 0; 21806} 21807_ACEOF 21808if ac_fn_c_try_compile "$LINENO" 21809then : 21810 ac_cv_have_sa_family_t="yes" 21811else $as_nop 21812 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 21813/* end confdefs.h. */ 21814 21815#include <sys/types.h> 21816#include <sys/socket.h> 21817#include <netinet/in.h> 21818 21819int 21820main (void) 21821{ 21822 sa_family_t foo; foo = 1235; 21823 ; 21824 return 0; 21825} 21826_ACEOF 21827if ac_fn_c_try_compile "$LINENO" 21828then : 21829 ac_cv_have_sa_family_t="yes" 21830else $as_nop 21831 ac_cv_have_sa_family_t="no" 21832 21833fi 21834rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 21835 21836fi 21837rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 21838 21839fi 21840{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_sa_family_t" >&5 21841printf "%s\n" "$ac_cv_have_sa_family_t" >&6; } 21842if test "x$ac_cv_have_sa_family_t" = "xyes" ; then 21843 21844printf "%s\n" "#define HAVE_SA_FAMILY_T 1" >>confdefs.h 21845 21846fi 21847 21848{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pid_t" >&5 21849printf %s "checking for pid_t... " >&6; } 21850if test ${ac_cv_have_pid_t+y} 21851then : 21852 printf %s "(cached) " >&6 21853else $as_nop 21854 21855 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 21856/* end confdefs.h. */ 21857 #include <sys/types.h> 21858int 21859main (void) 21860{ 21861 pid_t foo; foo = 1235; 21862 ; 21863 return 0; 21864} 21865_ACEOF 21866if ac_fn_c_try_compile "$LINENO" 21867then : 21868 ac_cv_have_pid_t="yes" 21869else $as_nop 21870 ac_cv_have_pid_t="no" 21871 21872fi 21873rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 21874 21875fi 21876{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_pid_t" >&5 21877printf "%s\n" "$ac_cv_have_pid_t" >&6; } 21878if test "x$ac_cv_have_pid_t" = "xyes" ; then 21879 21880printf "%s\n" "#define HAVE_PID_T 1" >>confdefs.h 21881 21882fi 21883 21884{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for mode_t" >&5 21885printf %s "checking for mode_t... " >&6; } 21886if test ${ac_cv_have_mode_t+y} 21887then : 21888 printf %s "(cached) " >&6 21889else $as_nop 21890 21891 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 21892/* end confdefs.h. */ 21893 #include <sys/types.h> 21894int 21895main (void) 21896{ 21897 mode_t foo; foo = 1235; 21898 ; 21899 return 0; 21900} 21901_ACEOF 21902if ac_fn_c_try_compile "$LINENO" 21903then : 21904 ac_cv_have_mode_t="yes" 21905else $as_nop 21906 ac_cv_have_mode_t="no" 21907 21908fi 21909rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 21910 21911fi 21912{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_mode_t" >&5 21913printf "%s\n" "$ac_cv_have_mode_t" >&6; } 21914if test "x$ac_cv_have_mode_t" = "xyes" ; then 21915 21916printf "%s\n" "#define HAVE_MODE_T 1" >>confdefs.h 21917 21918fi 21919 21920 21921{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for struct sockaddr_storage" >&5 21922printf %s "checking for struct sockaddr_storage... " >&6; } 21923if test ${ac_cv_have_struct_sockaddr_storage+y} 21924then : 21925 printf %s "(cached) " >&6 21926else $as_nop 21927 21928 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 21929/* end confdefs.h. */ 21930 21931#include <sys/types.h> 21932#include <sys/socket.h> 21933 21934int 21935main (void) 21936{ 21937 struct sockaddr_storage s; 21938 ; 21939 return 0; 21940} 21941_ACEOF 21942if ac_fn_c_try_compile "$LINENO" 21943then : 21944 ac_cv_have_struct_sockaddr_storage="yes" 21945else $as_nop 21946 ac_cv_have_struct_sockaddr_storage="no" 21947 21948fi 21949rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 21950 21951fi 21952{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_struct_sockaddr_storage" >&5 21953printf "%s\n" "$ac_cv_have_struct_sockaddr_storage" >&6; } 21954if test "x$ac_cv_have_struct_sockaddr_storage" = "xyes" ; then 21955 21956printf "%s\n" "#define HAVE_STRUCT_SOCKADDR_STORAGE 1" >>confdefs.h 21957 21958fi 21959 21960{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for struct sockaddr_in6" >&5 21961printf %s "checking for struct sockaddr_in6... " >&6; } 21962if test ${ac_cv_have_struct_sockaddr_in6+y} 21963then : 21964 printf %s "(cached) " >&6 21965else $as_nop 21966 21967 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 21968/* end confdefs.h. */ 21969 21970#include <sys/types.h> 21971#include <netinet/in.h> 21972 21973int 21974main (void) 21975{ 21976 struct sockaddr_in6 s; s.sin6_family = 0; 21977 ; 21978 return 0; 21979} 21980_ACEOF 21981if ac_fn_c_try_compile "$LINENO" 21982then : 21983 ac_cv_have_struct_sockaddr_in6="yes" 21984else $as_nop 21985 ac_cv_have_struct_sockaddr_in6="no" 21986 21987fi 21988rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 21989 21990fi 21991{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_struct_sockaddr_in6" >&5 21992printf "%s\n" "$ac_cv_have_struct_sockaddr_in6" >&6; } 21993if test "x$ac_cv_have_struct_sockaddr_in6" = "xyes" ; then 21994 21995printf "%s\n" "#define HAVE_STRUCT_SOCKADDR_IN6 1" >>confdefs.h 21996 21997fi 21998 21999{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for struct in6_addr" >&5 22000printf %s "checking for struct in6_addr... " >&6; } 22001if test ${ac_cv_have_struct_in6_addr+y} 22002then : 22003 printf %s "(cached) " >&6 22004else $as_nop 22005 22006 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22007/* end confdefs.h. */ 22008 22009#include <sys/types.h> 22010#include <netinet/in.h> 22011 22012int 22013main (void) 22014{ 22015 struct in6_addr s; s.s6_addr[0] = 0; 22016 ; 22017 return 0; 22018} 22019_ACEOF 22020if ac_fn_c_try_compile "$LINENO" 22021then : 22022 ac_cv_have_struct_in6_addr="yes" 22023else $as_nop 22024 ac_cv_have_struct_in6_addr="no" 22025 22026fi 22027rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 22028 22029fi 22030{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_struct_in6_addr" >&5 22031printf "%s\n" "$ac_cv_have_struct_in6_addr" >&6; } 22032if test "x$ac_cv_have_struct_in6_addr" = "xyes" ; then 22033 22034printf "%s\n" "#define HAVE_STRUCT_IN6_ADDR 1" >>confdefs.h 22035 22036 22037 ac_fn_c_check_member "$LINENO" "struct sockaddr_in6" "sin6_scope_id" "ac_cv_member_struct_sockaddr_in6_sin6_scope_id" " 22038#ifdef HAVE_SYS_TYPES_H 22039#include <sys/types.h> 22040#endif 22041#include <netinet/in.h> 22042 22043" 22044if test "x$ac_cv_member_struct_sockaddr_in6_sin6_scope_id" = xyes 22045then : 22046 22047printf "%s\n" "#define HAVE_STRUCT_SOCKADDR_IN6_SIN6_SCOPE_ID 1" >>confdefs.h 22048 22049 22050fi 22051 22052fi 22053 22054{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for struct addrinfo" >&5 22055printf %s "checking for struct addrinfo... " >&6; } 22056if test ${ac_cv_have_struct_addrinfo+y} 22057then : 22058 printf %s "(cached) " >&6 22059else $as_nop 22060 22061 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22062/* end confdefs.h. */ 22063 22064#include <sys/types.h> 22065#include <sys/socket.h> 22066#include <netdb.h> 22067 22068int 22069main (void) 22070{ 22071 struct addrinfo s; s.ai_flags = AI_PASSIVE; 22072 ; 22073 return 0; 22074} 22075_ACEOF 22076if ac_fn_c_try_compile "$LINENO" 22077then : 22078 ac_cv_have_struct_addrinfo="yes" 22079else $as_nop 22080 ac_cv_have_struct_addrinfo="no" 22081 22082fi 22083rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 22084 22085fi 22086{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_struct_addrinfo" >&5 22087printf "%s\n" "$ac_cv_have_struct_addrinfo" >&6; } 22088if test "x$ac_cv_have_struct_addrinfo" = "xyes" ; then 22089 22090printf "%s\n" "#define HAVE_STRUCT_ADDRINFO 1" >>confdefs.h 22091 22092fi 22093 22094{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5 22095printf %s "checking for struct timeval... " >&6; } 22096if test ${ac_cv_have_struct_timeval+y} 22097then : 22098 printf %s "(cached) " >&6 22099else $as_nop 22100 22101 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22102/* end confdefs.h. */ 22103 #include <sys/time.h> 22104int 22105main (void) 22106{ 22107 struct timeval tv; tv.tv_sec = 1; 22108 ; 22109 return 0; 22110} 22111_ACEOF 22112if ac_fn_c_try_compile "$LINENO" 22113then : 22114 ac_cv_have_struct_timeval="yes" 22115else $as_nop 22116 ac_cv_have_struct_timeval="no" 22117 22118fi 22119rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 22120 22121fi 22122{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_struct_timeval" >&5 22123printf "%s\n" "$ac_cv_have_struct_timeval" >&6; } 22124if test "x$ac_cv_have_struct_timeval" = "xyes" ; then 22125 22126printf "%s\n" "#define HAVE_STRUCT_TIMEVAL 1" >>confdefs.h 22127 22128 have_struct_timeval=1 22129fi 22130 22131{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for struct timespec" >&5 22132printf %s "checking for struct timespec... " >&6; } 22133if test ${ac_cv_have_struct_timespec+y} 22134then : 22135 printf %s "(cached) " >&6 22136else $as_nop 22137 22138 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22139/* end confdefs.h. */ 22140 22141 #ifdef HAVE_SYS_TIME_H 22142 # include <sys/time.h> 22143 #endif 22144 #ifdef HAVE_TIME_H 22145 # include <time.h> 22146 #endif 22147 22148int 22149main (void) 22150{ 22151 struct timespec ts; ts.tv_sec = 1; 22152 ; 22153 return 0; 22154} 22155_ACEOF 22156if ac_fn_c_try_compile "$LINENO" 22157then : 22158 ac_cv_have_struct_timespec="yes" 22159else $as_nop 22160 ac_cv_have_struct_timespec="no" 22161 22162fi 22163rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 22164 22165fi 22166{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_struct_timespec" >&5 22167printf "%s\n" "$ac_cv_have_struct_timespec" >&6; } 22168if test "x$ac_cv_have_struct_timespec" = "xyes" ; then 22169 22170printf "%s\n" "#define HAVE_STRUCT_TIMESPEC 1" >>confdefs.h 22171 22172 have_struct_timespec=1 22173fi 22174 22175# We need int64_t or else certain parts of the compile will fail. 22176if test "x$ac_cv_have_int64_t" = "xno" && \ 22177 test "x$ac_cv_sizeof_long_int" != "x8" && \ 22178 test "x$ac_cv_sizeof_long_long_int" = "x0" ; then 22179 echo "OpenSSH requires int64_t support. Contact your vendor or install" 22180 echo "an alternative compiler (I.E., GCC) before continuing." 22181 echo "" 22182 exit 1; 22183else 22184 if test "$cross_compiling" = yes 22185then : 22186 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: Assuming working snprintf()" >&5 22187printf "%s\n" "$as_me: WARNING: cross compiling: Assuming working snprintf()" >&2;} 22188 22189else $as_nop 22190 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22191/* end confdefs.h. */ 22192 22193#include <stdio.h> 22194#include <stdlib.h> 22195#include <string.h> 22196#ifdef HAVE_SNPRINTF 22197int main(void) 22198{ 22199 char buf[50]; 22200 char expected_out[50]; 22201 int mazsize = 50 ; 22202#if (SIZEOF_LONG_INT == 8) 22203 long int num = 0x7fffffffffffffff; 22204#else 22205 long long num = 0x7fffffffffffffffll; 22206#endif 22207 strcpy(expected_out, "9223372036854775807"); 22208 snprintf(buf, mazsize, "%lld", num); 22209 if(strcmp(buf, expected_out) != 0) 22210 exit(1); 22211 exit(0); 22212} 22213#else 22214int main(void) { exit(0); } 22215#endif 22216 22217_ACEOF 22218if ac_fn_c_try_run "$LINENO" 22219then : 22220 true 22221else $as_nop 22222 printf "%s\n" "#define BROKEN_SNPRINTF 1" >>confdefs.h 22223 22224fi 22225rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 22226 conftest.$ac_objext conftest.beam conftest.$ac_ext 22227fi 22228 22229fi 22230 22231 22232# look for field 'ut_host' in header 'utmp.h' 22233 ossh_safe=`echo "utmp.h" | sed 'y%./+-%__p_%'` 22234 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_host 22235 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ut_host field in utmp.h" >&5 22236printf %s "checking for ut_host field in utmp.h... " >&6; } 22237 if eval test \${$ossh_varname+y} 22238then : 22239 printf %s "(cached) " >&6 22240else $as_nop 22241 22242 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22243/* end confdefs.h. */ 22244#include <utmp.h> 22245 22246_ACEOF 22247if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 22248 $EGREP "ut_host" >/dev/null 2>&1 22249then : 22250 eval "$ossh_varname=yes" 22251else $as_nop 22252 eval "$ossh_varname=no" 22253fi 22254rm -rf conftest* 22255 22256fi 22257 22258 ossh_result=`eval 'echo $'"$ossh_varname"` 22259 if test -n "`echo $ossh_varname`"; then 22260 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5 22261printf "%s\n" "$ossh_result" >&6; } 22262 if test "x$ossh_result" = "xyes"; then 22263 22264printf "%s\n" "#define HAVE_HOST_IN_UTMP 1" >>confdefs.h 22265 22266 fi 22267 else 22268 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 22269printf "%s\n" "no" >&6; } 22270 fi 22271 22272 22273# look for field 'ut_host' in header 'utmpx.h' 22274 ossh_safe=`echo "utmpx.h" | sed 'y%./+-%__p_%'` 22275 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_host 22276 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ut_host field in utmpx.h" >&5 22277printf %s "checking for ut_host field in utmpx.h... " >&6; } 22278 if eval test \${$ossh_varname+y} 22279then : 22280 printf %s "(cached) " >&6 22281else $as_nop 22282 22283 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22284/* end confdefs.h. */ 22285#include <utmpx.h> 22286 22287_ACEOF 22288if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 22289 $EGREP "ut_host" >/dev/null 2>&1 22290then : 22291 eval "$ossh_varname=yes" 22292else $as_nop 22293 eval "$ossh_varname=no" 22294fi 22295rm -rf conftest* 22296 22297fi 22298 22299 ossh_result=`eval 'echo $'"$ossh_varname"` 22300 if test -n "`echo $ossh_varname`"; then 22301 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5 22302printf "%s\n" "$ossh_result" >&6; } 22303 if test "x$ossh_result" = "xyes"; then 22304 22305printf "%s\n" "#define HAVE_HOST_IN_UTMPX 1" >>confdefs.h 22306 22307 fi 22308 else 22309 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 22310printf "%s\n" "no" >&6; } 22311 fi 22312 22313 22314# look for field 'syslen' in header 'utmpx.h' 22315 ossh_safe=`echo "utmpx.h" | sed 'y%./+-%__p_%'` 22316 ossh_varname="ossh_cv_$ossh_safe""_has_"syslen 22317 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for syslen field in utmpx.h" >&5 22318printf %s "checking for syslen field in utmpx.h... " >&6; } 22319 if eval test \${$ossh_varname+y} 22320then : 22321 printf %s "(cached) " >&6 22322else $as_nop 22323 22324 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22325/* end confdefs.h. */ 22326#include <utmpx.h> 22327 22328_ACEOF 22329if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 22330 $EGREP "syslen" >/dev/null 2>&1 22331then : 22332 eval "$ossh_varname=yes" 22333else $as_nop 22334 eval "$ossh_varname=no" 22335fi 22336rm -rf conftest* 22337 22338fi 22339 22340 ossh_result=`eval 'echo $'"$ossh_varname"` 22341 if test -n "`echo $ossh_varname`"; then 22342 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5 22343printf "%s\n" "$ossh_result" >&6; } 22344 if test "x$ossh_result" = "xyes"; then 22345 22346printf "%s\n" "#define HAVE_SYSLEN_IN_UTMPX 1" >>confdefs.h 22347 22348 fi 22349 else 22350 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 22351printf "%s\n" "no" >&6; } 22352 fi 22353 22354 22355# look for field 'ut_pid' in header 'utmp.h' 22356 ossh_safe=`echo "utmp.h" | sed 'y%./+-%__p_%'` 22357 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_pid 22358 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ut_pid field in utmp.h" >&5 22359printf %s "checking for ut_pid field in utmp.h... " >&6; } 22360 if eval test \${$ossh_varname+y} 22361then : 22362 printf %s "(cached) " >&6 22363else $as_nop 22364 22365 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22366/* end confdefs.h. */ 22367#include <utmp.h> 22368 22369_ACEOF 22370if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 22371 $EGREP "ut_pid" >/dev/null 2>&1 22372then : 22373 eval "$ossh_varname=yes" 22374else $as_nop 22375 eval "$ossh_varname=no" 22376fi 22377rm -rf conftest* 22378 22379fi 22380 22381 ossh_result=`eval 'echo $'"$ossh_varname"` 22382 if test -n "`echo $ossh_varname`"; then 22383 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5 22384printf "%s\n" "$ossh_result" >&6; } 22385 if test "x$ossh_result" = "xyes"; then 22386 22387printf "%s\n" "#define HAVE_PID_IN_UTMP 1" >>confdefs.h 22388 22389 fi 22390 else 22391 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 22392printf "%s\n" "no" >&6; } 22393 fi 22394 22395 22396# look for field 'ut_type' in header 'utmp.h' 22397 ossh_safe=`echo "utmp.h" | sed 'y%./+-%__p_%'` 22398 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_type 22399 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ut_type field in utmp.h" >&5 22400printf %s "checking for ut_type field in utmp.h... " >&6; } 22401 if eval test \${$ossh_varname+y} 22402then : 22403 printf %s "(cached) " >&6 22404else $as_nop 22405 22406 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22407/* end confdefs.h. */ 22408#include <utmp.h> 22409 22410_ACEOF 22411if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 22412 $EGREP "ut_type" >/dev/null 2>&1 22413then : 22414 eval "$ossh_varname=yes" 22415else $as_nop 22416 eval "$ossh_varname=no" 22417fi 22418rm -rf conftest* 22419 22420fi 22421 22422 ossh_result=`eval 'echo $'"$ossh_varname"` 22423 if test -n "`echo $ossh_varname`"; then 22424 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5 22425printf "%s\n" "$ossh_result" >&6; } 22426 if test "x$ossh_result" = "xyes"; then 22427 22428printf "%s\n" "#define HAVE_TYPE_IN_UTMP 1" >>confdefs.h 22429 22430 fi 22431 else 22432 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 22433printf "%s\n" "no" >&6; } 22434 fi 22435 22436 22437# look for field 'ut_type' in header 'utmpx.h' 22438 ossh_safe=`echo "utmpx.h" | sed 'y%./+-%__p_%'` 22439 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_type 22440 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ut_type field in utmpx.h" >&5 22441printf %s "checking for ut_type field in utmpx.h... " >&6; } 22442 if eval test \${$ossh_varname+y} 22443then : 22444 printf %s "(cached) " >&6 22445else $as_nop 22446 22447 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22448/* end confdefs.h. */ 22449#include <utmpx.h> 22450 22451_ACEOF 22452if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 22453 $EGREP "ut_type" >/dev/null 2>&1 22454then : 22455 eval "$ossh_varname=yes" 22456else $as_nop 22457 eval "$ossh_varname=no" 22458fi 22459rm -rf conftest* 22460 22461fi 22462 22463 ossh_result=`eval 'echo $'"$ossh_varname"` 22464 if test -n "`echo $ossh_varname`"; then 22465 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5 22466printf "%s\n" "$ossh_result" >&6; } 22467 if test "x$ossh_result" = "xyes"; then 22468 22469printf "%s\n" "#define HAVE_TYPE_IN_UTMPX 1" >>confdefs.h 22470 22471 fi 22472 else 22473 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 22474printf "%s\n" "no" >&6; } 22475 fi 22476 22477 22478# look for field 'ut_tv' in header 'utmp.h' 22479 ossh_safe=`echo "utmp.h" | sed 'y%./+-%__p_%'` 22480 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_tv 22481 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ut_tv field in utmp.h" >&5 22482printf %s "checking for ut_tv field in utmp.h... " >&6; } 22483 if eval test \${$ossh_varname+y} 22484then : 22485 printf %s "(cached) " >&6 22486else $as_nop 22487 22488 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22489/* end confdefs.h. */ 22490#include <utmp.h> 22491 22492_ACEOF 22493if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 22494 $EGREP "ut_tv" >/dev/null 2>&1 22495then : 22496 eval "$ossh_varname=yes" 22497else $as_nop 22498 eval "$ossh_varname=no" 22499fi 22500rm -rf conftest* 22501 22502fi 22503 22504 ossh_result=`eval 'echo $'"$ossh_varname"` 22505 if test -n "`echo $ossh_varname`"; then 22506 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5 22507printf "%s\n" "$ossh_result" >&6; } 22508 if test "x$ossh_result" = "xyes"; then 22509 22510printf "%s\n" "#define HAVE_TV_IN_UTMP 1" >>confdefs.h 22511 22512 fi 22513 else 22514 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 22515printf "%s\n" "no" >&6; } 22516 fi 22517 22518 22519# look for field 'ut_id' in header 'utmp.h' 22520 ossh_safe=`echo "utmp.h" | sed 'y%./+-%__p_%'` 22521 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_id 22522 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ut_id field in utmp.h" >&5 22523printf %s "checking for ut_id field in utmp.h... " >&6; } 22524 if eval test \${$ossh_varname+y} 22525then : 22526 printf %s "(cached) " >&6 22527else $as_nop 22528 22529 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22530/* end confdefs.h. */ 22531#include <utmp.h> 22532 22533_ACEOF 22534if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 22535 $EGREP "ut_id" >/dev/null 2>&1 22536then : 22537 eval "$ossh_varname=yes" 22538else $as_nop 22539 eval "$ossh_varname=no" 22540fi 22541rm -rf conftest* 22542 22543fi 22544 22545 ossh_result=`eval 'echo $'"$ossh_varname"` 22546 if test -n "`echo $ossh_varname`"; then 22547 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5 22548printf "%s\n" "$ossh_result" >&6; } 22549 if test "x$ossh_result" = "xyes"; then 22550 22551printf "%s\n" "#define HAVE_ID_IN_UTMP 1" >>confdefs.h 22552 22553 fi 22554 else 22555 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 22556printf "%s\n" "no" >&6; } 22557 fi 22558 22559 22560# look for field 'ut_id' in header 'utmpx.h' 22561 ossh_safe=`echo "utmpx.h" | sed 'y%./+-%__p_%'` 22562 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_id 22563 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ut_id field in utmpx.h" >&5 22564printf %s "checking for ut_id field in utmpx.h... " >&6; } 22565 if eval test \${$ossh_varname+y} 22566then : 22567 printf %s "(cached) " >&6 22568else $as_nop 22569 22570 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22571/* end confdefs.h. */ 22572#include <utmpx.h> 22573 22574_ACEOF 22575if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 22576 $EGREP "ut_id" >/dev/null 2>&1 22577then : 22578 eval "$ossh_varname=yes" 22579else $as_nop 22580 eval "$ossh_varname=no" 22581fi 22582rm -rf conftest* 22583 22584fi 22585 22586 ossh_result=`eval 'echo $'"$ossh_varname"` 22587 if test -n "`echo $ossh_varname`"; then 22588 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5 22589printf "%s\n" "$ossh_result" >&6; } 22590 if test "x$ossh_result" = "xyes"; then 22591 22592printf "%s\n" "#define HAVE_ID_IN_UTMPX 1" >>confdefs.h 22593 22594 fi 22595 else 22596 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 22597printf "%s\n" "no" >&6; } 22598 fi 22599 22600 22601# look for field 'ut_addr' in header 'utmp.h' 22602 ossh_safe=`echo "utmp.h" | sed 'y%./+-%__p_%'` 22603 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_addr 22604 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ut_addr field in utmp.h" >&5 22605printf %s "checking for ut_addr field in utmp.h... " >&6; } 22606 if eval test \${$ossh_varname+y} 22607then : 22608 printf %s "(cached) " >&6 22609else $as_nop 22610 22611 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22612/* end confdefs.h. */ 22613#include <utmp.h> 22614 22615_ACEOF 22616if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 22617 $EGREP "ut_addr" >/dev/null 2>&1 22618then : 22619 eval "$ossh_varname=yes" 22620else $as_nop 22621 eval "$ossh_varname=no" 22622fi 22623rm -rf conftest* 22624 22625fi 22626 22627 ossh_result=`eval 'echo $'"$ossh_varname"` 22628 if test -n "`echo $ossh_varname`"; then 22629 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5 22630printf "%s\n" "$ossh_result" >&6; } 22631 if test "x$ossh_result" = "xyes"; then 22632 22633printf "%s\n" "#define HAVE_ADDR_IN_UTMP 1" >>confdefs.h 22634 22635 fi 22636 else 22637 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 22638printf "%s\n" "no" >&6; } 22639 fi 22640 22641 22642# look for field 'ut_addr' in header 'utmpx.h' 22643 ossh_safe=`echo "utmpx.h" | sed 'y%./+-%__p_%'` 22644 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_addr 22645 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ut_addr field in utmpx.h" >&5 22646printf %s "checking for ut_addr field in utmpx.h... " >&6; } 22647 if eval test \${$ossh_varname+y} 22648then : 22649 printf %s "(cached) " >&6 22650else $as_nop 22651 22652 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22653/* end confdefs.h. */ 22654#include <utmpx.h> 22655 22656_ACEOF 22657if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 22658 $EGREP "ut_addr" >/dev/null 2>&1 22659then : 22660 eval "$ossh_varname=yes" 22661else $as_nop 22662 eval "$ossh_varname=no" 22663fi 22664rm -rf conftest* 22665 22666fi 22667 22668 ossh_result=`eval 'echo $'"$ossh_varname"` 22669 if test -n "`echo $ossh_varname`"; then 22670 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5 22671printf "%s\n" "$ossh_result" >&6; } 22672 if test "x$ossh_result" = "xyes"; then 22673 22674printf "%s\n" "#define HAVE_ADDR_IN_UTMPX 1" >>confdefs.h 22675 22676 fi 22677 else 22678 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 22679printf "%s\n" "no" >&6; } 22680 fi 22681 22682 22683# look for field 'ut_addr_v6' in header 'utmp.h' 22684 ossh_safe=`echo "utmp.h" | sed 'y%./+-%__p_%'` 22685 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_addr_v6 22686 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ut_addr_v6 field in utmp.h" >&5 22687printf %s "checking for ut_addr_v6 field in utmp.h... " >&6; } 22688 if eval test \${$ossh_varname+y} 22689then : 22690 printf %s "(cached) " >&6 22691else $as_nop 22692 22693 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22694/* end confdefs.h. */ 22695#include <utmp.h> 22696 22697_ACEOF 22698if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 22699 $EGREP "ut_addr_v6" >/dev/null 2>&1 22700then : 22701 eval "$ossh_varname=yes" 22702else $as_nop 22703 eval "$ossh_varname=no" 22704fi 22705rm -rf conftest* 22706 22707fi 22708 22709 ossh_result=`eval 'echo $'"$ossh_varname"` 22710 if test -n "`echo $ossh_varname`"; then 22711 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5 22712printf "%s\n" "$ossh_result" >&6; } 22713 if test "x$ossh_result" = "xyes"; then 22714 22715printf "%s\n" "#define HAVE_ADDR_V6_IN_UTMP 1" >>confdefs.h 22716 22717 fi 22718 else 22719 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 22720printf "%s\n" "no" >&6; } 22721 fi 22722 22723 22724# look for field 'ut_addr_v6' in header 'utmpx.h' 22725 ossh_safe=`echo "utmpx.h" | sed 'y%./+-%__p_%'` 22726 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_addr_v6 22727 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ut_addr_v6 field in utmpx.h" >&5 22728printf %s "checking for ut_addr_v6 field in utmpx.h... " >&6; } 22729 if eval test \${$ossh_varname+y} 22730then : 22731 printf %s "(cached) " >&6 22732else $as_nop 22733 22734 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22735/* end confdefs.h. */ 22736#include <utmpx.h> 22737 22738_ACEOF 22739if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 22740 $EGREP "ut_addr_v6" >/dev/null 2>&1 22741then : 22742 eval "$ossh_varname=yes" 22743else $as_nop 22744 eval "$ossh_varname=no" 22745fi 22746rm -rf conftest* 22747 22748fi 22749 22750 ossh_result=`eval 'echo $'"$ossh_varname"` 22751 if test -n "`echo $ossh_varname`"; then 22752 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5 22753printf "%s\n" "$ossh_result" >&6; } 22754 if test "x$ossh_result" = "xyes"; then 22755 22756printf "%s\n" "#define HAVE_ADDR_V6_IN_UTMPX 1" >>confdefs.h 22757 22758 fi 22759 else 22760 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 22761printf "%s\n" "no" >&6; } 22762 fi 22763 22764 22765# look for field 'ut_exit' in header 'utmp.h' 22766 ossh_safe=`echo "utmp.h" | sed 'y%./+-%__p_%'` 22767 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_exit 22768 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ut_exit field in utmp.h" >&5 22769printf %s "checking for ut_exit field in utmp.h... " >&6; } 22770 if eval test \${$ossh_varname+y} 22771then : 22772 printf %s "(cached) " >&6 22773else $as_nop 22774 22775 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22776/* end confdefs.h. */ 22777#include <utmp.h> 22778 22779_ACEOF 22780if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 22781 $EGREP "ut_exit" >/dev/null 2>&1 22782then : 22783 eval "$ossh_varname=yes" 22784else $as_nop 22785 eval "$ossh_varname=no" 22786fi 22787rm -rf conftest* 22788 22789fi 22790 22791 ossh_result=`eval 'echo $'"$ossh_varname"` 22792 if test -n "`echo $ossh_varname`"; then 22793 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5 22794printf "%s\n" "$ossh_result" >&6; } 22795 if test "x$ossh_result" = "xyes"; then 22796 22797printf "%s\n" "#define HAVE_EXIT_IN_UTMP 1" >>confdefs.h 22798 22799 fi 22800 else 22801 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 22802printf "%s\n" "no" >&6; } 22803 fi 22804 22805 22806# look for field 'ut_time' in header 'utmp.h' 22807 ossh_safe=`echo "utmp.h" | sed 'y%./+-%__p_%'` 22808 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_time 22809 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ut_time field in utmp.h" >&5 22810printf %s "checking for ut_time field in utmp.h... " >&6; } 22811 if eval test \${$ossh_varname+y} 22812then : 22813 printf %s "(cached) " >&6 22814else $as_nop 22815 22816 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22817/* end confdefs.h. */ 22818#include <utmp.h> 22819 22820_ACEOF 22821if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 22822 $EGREP "ut_time" >/dev/null 2>&1 22823then : 22824 eval "$ossh_varname=yes" 22825else $as_nop 22826 eval "$ossh_varname=no" 22827fi 22828rm -rf conftest* 22829 22830fi 22831 22832 ossh_result=`eval 'echo $'"$ossh_varname"` 22833 if test -n "`echo $ossh_varname`"; then 22834 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5 22835printf "%s\n" "$ossh_result" >&6; } 22836 if test "x$ossh_result" = "xyes"; then 22837 22838printf "%s\n" "#define HAVE_TIME_IN_UTMP 1" >>confdefs.h 22839 22840 fi 22841 else 22842 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 22843printf "%s\n" "no" >&6; } 22844 fi 22845 22846 22847# look for field 'ut_time' in header 'utmpx.h' 22848 ossh_safe=`echo "utmpx.h" | sed 'y%./+-%__p_%'` 22849 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_time 22850 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ut_time field in utmpx.h" >&5 22851printf %s "checking for ut_time field in utmpx.h... " >&6; } 22852 if eval test \${$ossh_varname+y} 22853then : 22854 printf %s "(cached) " >&6 22855else $as_nop 22856 22857 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22858/* end confdefs.h. */ 22859#include <utmpx.h> 22860 22861_ACEOF 22862if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 22863 $EGREP "ut_time" >/dev/null 2>&1 22864then : 22865 eval "$ossh_varname=yes" 22866else $as_nop 22867 eval "$ossh_varname=no" 22868fi 22869rm -rf conftest* 22870 22871fi 22872 22873 ossh_result=`eval 'echo $'"$ossh_varname"` 22874 if test -n "`echo $ossh_varname`"; then 22875 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5 22876printf "%s\n" "$ossh_result" >&6; } 22877 if test "x$ossh_result" = "xyes"; then 22878 22879printf "%s\n" "#define HAVE_TIME_IN_UTMPX 1" >>confdefs.h 22880 22881 fi 22882 else 22883 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 22884printf "%s\n" "no" >&6; } 22885 fi 22886 22887 22888# look for field 'ut_tv' in header 'utmpx.h' 22889 ossh_safe=`echo "utmpx.h" | sed 'y%./+-%__p_%'` 22890 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_tv 22891 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ut_tv field in utmpx.h" >&5 22892printf %s "checking for ut_tv field in utmpx.h... " >&6; } 22893 if eval test \${$ossh_varname+y} 22894then : 22895 printf %s "(cached) " >&6 22896else $as_nop 22897 22898 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22899/* end confdefs.h. */ 22900#include <utmpx.h> 22901 22902_ACEOF 22903if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 22904 $EGREP "ut_tv" >/dev/null 2>&1 22905then : 22906 eval "$ossh_varname=yes" 22907else $as_nop 22908 eval "$ossh_varname=no" 22909fi 22910rm -rf conftest* 22911 22912fi 22913 22914 ossh_result=`eval 'echo $'"$ossh_varname"` 22915 if test -n "`echo $ossh_varname`"; then 22916 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5 22917printf "%s\n" "$ossh_result" >&6; } 22918 if test "x$ossh_result" = "xyes"; then 22919 22920printf "%s\n" "#define HAVE_TV_IN_UTMPX 1" >>confdefs.h 22921 22922 fi 22923 else 22924 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 22925printf "%s\n" "no" >&6; } 22926 fi 22927 22928 22929# look for field 'ut_ss' in header 'utmpx.h' 22930 ossh_safe=`echo "utmpx.h" | sed 'y%./+-%__p_%'` 22931 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_ss 22932 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ut_ss field in utmpx.h" >&5 22933printf %s "checking for ut_ss field in utmpx.h... " >&6; } 22934 if eval test \${$ossh_varname+y} 22935then : 22936 printf %s "(cached) " >&6 22937else $as_nop 22938 22939 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 22940/* end confdefs.h. */ 22941#include <utmpx.h> 22942 22943_ACEOF 22944if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 22945 $EGREP "ut_ss" >/dev/null 2>&1 22946then : 22947 eval "$ossh_varname=yes" 22948else $as_nop 22949 eval "$ossh_varname=no" 22950fi 22951rm -rf conftest* 22952 22953fi 22954 22955 ossh_result=`eval 'echo $'"$ossh_varname"` 22956 if test -n "`echo $ossh_varname`"; then 22957 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5 22958printf "%s\n" "$ossh_result" >&6; } 22959 if test "x$ossh_result" = "xyes"; then 22960 22961printf "%s\n" "#define HAVE_SS_IN_UTMPX 1" >>confdefs.h 22962 22963 fi 22964 else 22965 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 22966printf "%s\n" "no" >&6; } 22967 fi 22968 22969 22970ac_fn_c_check_member "$LINENO" "struct stat" "st_blksize" "ac_cv_member_struct_stat_st_blksize" "$ac_includes_default" 22971if test "x$ac_cv_member_struct_stat_st_blksize" = xyes 22972then : 22973 22974printf "%s\n" "#define HAVE_STRUCT_STAT_ST_BLKSIZE 1" >>confdefs.h 22975 22976 22977fi 22978 22979ac_fn_c_check_member "$LINENO" "struct stat" "st_mtim" "ac_cv_member_struct_stat_st_mtim" "$ac_includes_default" 22980if test "x$ac_cv_member_struct_stat_st_mtim" = xyes 22981then : 22982 22983printf "%s\n" "#define HAVE_STRUCT_STAT_ST_MTIM 1" >>confdefs.h 22984 22985 22986fi 22987 22988ac_fn_c_check_member "$LINENO" "struct stat" "st_mtime" "ac_cv_member_struct_stat_st_mtime" "$ac_includes_default" 22989if test "x$ac_cv_member_struct_stat_st_mtime" = xyes 22990then : 22991 22992printf "%s\n" "#define HAVE_STRUCT_STAT_ST_MTIME 1" >>confdefs.h 22993 22994 22995fi 22996 22997ac_fn_c_check_member "$LINENO" "struct passwd" "pw_gecos" "ac_cv_member_struct_passwd_pw_gecos" " 22998#include <sys/types.h> 22999#include <pwd.h> 23000 23001" 23002if test "x$ac_cv_member_struct_passwd_pw_gecos" = xyes 23003then : 23004 23005printf "%s\n" "#define HAVE_STRUCT_PASSWD_PW_GECOS 1" >>confdefs.h 23006 23007 23008fi 23009ac_fn_c_check_member "$LINENO" "struct passwd" "pw_class" "ac_cv_member_struct_passwd_pw_class" " 23010#include <sys/types.h> 23011#include <pwd.h> 23012 23013" 23014if test "x$ac_cv_member_struct_passwd_pw_class" = xyes 23015then : 23016 23017printf "%s\n" "#define HAVE_STRUCT_PASSWD_PW_CLASS 1" >>confdefs.h 23018 23019 23020fi 23021ac_fn_c_check_member "$LINENO" "struct passwd" "pw_change" "ac_cv_member_struct_passwd_pw_change" " 23022#include <sys/types.h> 23023#include <pwd.h> 23024 23025" 23026if test "x$ac_cv_member_struct_passwd_pw_change" = xyes 23027then : 23028 23029printf "%s\n" "#define HAVE_STRUCT_PASSWD_PW_CHANGE 1" >>confdefs.h 23030 23031 23032fi 23033ac_fn_c_check_member "$LINENO" "struct passwd" "pw_expire" "ac_cv_member_struct_passwd_pw_expire" " 23034#include <sys/types.h> 23035#include <pwd.h> 23036 23037" 23038if test "x$ac_cv_member_struct_passwd_pw_expire" = xyes 23039then : 23040 23041printf "%s\n" "#define HAVE_STRUCT_PASSWD_PW_EXPIRE 1" >>confdefs.h 23042 23043 23044fi 23045 23046 23047ac_fn_c_check_member "$LINENO" "struct __res_state" "retrans" "ac_cv_member_struct___res_state_retrans" " 23048#include <stdio.h> 23049#if HAVE_SYS_TYPES_H 23050# include <sys/types.h> 23051#endif 23052#include <netinet/in.h> 23053#include <arpa/nameser.h> 23054#include <resolv.h> 23055 23056" 23057if test "x$ac_cv_member_struct___res_state_retrans" = xyes 23058then : 23059 23060else $as_nop 23061 23062printf "%s\n" "#define __res_state state" >>confdefs.h 23063 23064fi 23065 23066 23067ac_fn_c_check_member "$LINENO" "struct sockaddr_in" "sin_len" "ac_cv_member_struct_sockaddr_in_sin_len" " 23068#include <sys/types.h> 23069#include <sys/socket.h> 23070#include <netinet/in.h> 23071 23072 23073" 23074if test "x$ac_cv_member_struct_sockaddr_in_sin_len" = xyes 23075then : 23076 23077printf "%s\n" "#define SOCK_HAS_LEN 1" >>confdefs.h 23078 23079fi 23080 23081 23082{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ss_family field in struct sockaddr_storage" >&5 23083printf %s "checking for ss_family field in struct sockaddr_storage... " >&6; } 23084if test ${ac_cv_have_ss_family_in_struct_ss+y} 23085then : 23086 printf %s "(cached) " >&6 23087else $as_nop 23088 23089 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 23090/* end confdefs.h. */ 23091 23092#include <sys/types.h> 23093#include <sys/socket.h> 23094 23095int 23096main (void) 23097{ 23098 struct sockaddr_storage s; s.ss_family = 1; 23099 ; 23100 return 0; 23101} 23102_ACEOF 23103if ac_fn_c_try_compile "$LINENO" 23104then : 23105 ac_cv_have_ss_family_in_struct_ss="yes" 23106else $as_nop 23107 ac_cv_have_ss_family_in_struct_ss="no" 23108fi 23109rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 23110 23111fi 23112{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_ss_family_in_struct_ss" >&5 23113printf "%s\n" "$ac_cv_have_ss_family_in_struct_ss" >&6; } 23114if test "x$ac_cv_have_ss_family_in_struct_ss" = "xyes" ; then 23115 23116printf "%s\n" "#define HAVE_SS_FAMILY_IN_SS 1" >>confdefs.h 23117 23118fi 23119 23120{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for __ss_family field in struct sockaddr_storage" >&5 23121printf %s "checking for __ss_family field in struct sockaddr_storage... " >&6; } 23122if test ${ac_cv_have___ss_family_in_struct_ss+y} 23123then : 23124 printf %s "(cached) " >&6 23125else $as_nop 23126 23127 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 23128/* end confdefs.h. */ 23129 23130#include <sys/types.h> 23131#include <sys/socket.h> 23132 23133int 23134main (void) 23135{ 23136 struct sockaddr_storage s; s.__ss_family = 1; 23137 ; 23138 return 0; 23139} 23140_ACEOF 23141if ac_fn_c_try_compile "$LINENO" 23142then : 23143 ac_cv_have___ss_family_in_struct_ss="yes" 23144else $as_nop 23145 ac_cv_have___ss_family_in_struct_ss="no" 23146 23147fi 23148rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 23149 23150fi 23151{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have___ss_family_in_struct_ss" >&5 23152printf "%s\n" "$ac_cv_have___ss_family_in_struct_ss" >&6; } 23153if test "x$ac_cv_have___ss_family_in_struct_ss" = "xyes" ; then 23154 23155printf "%s\n" "#define HAVE___SS_FAMILY_IN_SS 1" >>confdefs.h 23156 23157fi 23158 23159{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for msg_accrights field in struct msghdr" >&5 23160printf %s "checking for msg_accrights field in struct msghdr... " >&6; } 23161if test ${ac_cv_have_accrights_in_msghdr+y} 23162then : 23163 printf %s "(cached) " >&6 23164else $as_nop 23165 23166 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 23167/* end confdefs.h. */ 23168 23169#include <sys/types.h> 23170#include <sys/socket.h> 23171#include <sys/uio.h> 23172#include <stdlib.h> 23173 23174int 23175main (void) 23176{ 23177 23178#ifdef msg_accrights 23179#error "msg_accrights is a macro" 23180exit(1); 23181#endif 23182struct msghdr m; 23183m.msg_accrights = 0; 23184exit(0); 23185 23186 ; 23187 return 0; 23188} 23189_ACEOF 23190if ac_fn_c_try_compile "$LINENO" 23191then : 23192 ac_cv_have_accrights_in_msghdr="yes" 23193else $as_nop 23194 ac_cv_have_accrights_in_msghdr="no" 23195 23196fi 23197rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 23198 23199fi 23200{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_accrights_in_msghdr" >&5 23201printf "%s\n" "$ac_cv_have_accrights_in_msghdr" >&6; } 23202if test "x$ac_cv_have_accrights_in_msghdr" = "xyes" ; then 23203 23204printf "%s\n" "#define HAVE_ACCRIGHTS_IN_MSGHDR 1" >>confdefs.h 23205 23206fi 23207 23208{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if struct statvfs.f_fsid is integral type" >&5 23209printf %s "checking if struct statvfs.f_fsid is integral type... " >&6; } 23210cat confdefs.h - <<_ACEOF >conftest.$ac_ext 23211/* end confdefs.h. */ 23212 23213#include <sys/param.h> 23214#include <sys/stat.h> 23215#ifdef HAVE_SYS_TIME_H 23216# include <sys/time.h> 23217#endif 23218#ifdef HAVE_SYS_MOUNT_H 23219#include <sys/mount.h> 23220#endif 23221#ifdef HAVE_SYS_STATVFS_H 23222#include <sys/statvfs.h> 23223#endif 23224 23225int 23226main (void) 23227{ 23228 struct statvfs s; s.f_fsid = 0; 23229 ; 23230 return 0; 23231} 23232_ACEOF 23233if ac_fn_c_try_compile "$LINENO" 23234then : 23235 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 23236printf "%s\n" "yes" >&6; } 23237else $as_nop 23238 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 23239printf "%s\n" "no" >&6; } 23240 23241 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if fsid_t has member val" >&5 23242printf %s "checking if fsid_t has member val... " >&6; } 23243 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 23244/* end confdefs.h. */ 23245 23246#include <sys/types.h> 23247#include <sys/statvfs.h> 23248 23249int 23250main (void) 23251{ 23252 fsid_t t; t.val[0] = 0; 23253 ; 23254 return 0; 23255} 23256_ACEOF 23257if ac_fn_c_try_compile "$LINENO" 23258then : 23259 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 23260printf "%s\n" "yes" >&6; } 23261 23262printf "%s\n" "#define FSID_HAS_VAL 1" >>confdefs.h 23263 23264else $as_nop 23265 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 23266printf "%s\n" "no" >&6; } 23267fi 23268rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 23269 23270 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if f_fsid has member __val" >&5 23271printf %s "checking if f_fsid has member __val... " >&6; } 23272 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 23273/* end confdefs.h. */ 23274 23275#include <sys/types.h> 23276#include <sys/statvfs.h> 23277 23278int 23279main (void) 23280{ 23281 fsid_t t; t.__val[0] = 0; 23282 ; 23283 return 0; 23284} 23285_ACEOF 23286if ac_fn_c_try_compile "$LINENO" 23287then : 23288 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 23289printf "%s\n" "yes" >&6; } 23290 23291printf "%s\n" "#define FSID_HAS___VAL 1" >>confdefs.h 23292 23293else $as_nop 23294 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 23295printf "%s\n" "no" >&6; } 23296fi 23297rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 23298 23299fi 23300rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 23301 23302{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for msg_control field in struct msghdr" >&5 23303printf %s "checking for msg_control field in struct msghdr... " >&6; } 23304if test ${ac_cv_have_control_in_msghdr+y} 23305then : 23306 printf %s "(cached) " >&6 23307else $as_nop 23308 23309 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 23310/* end confdefs.h. */ 23311 23312#include <sys/types.h> 23313#include <sys/socket.h> 23314#include <sys/uio.h> 23315#include <stdlib.h> 23316 23317int 23318main (void) 23319{ 23320 23321#ifdef msg_control 23322#error "msg_control is a macro" 23323exit(1); 23324#endif 23325struct msghdr m; 23326m.msg_control = 0; 23327exit(0); 23328 23329 ; 23330 return 0; 23331} 23332_ACEOF 23333if ac_fn_c_try_compile "$LINENO" 23334then : 23335 ac_cv_have_control_in_msghdr="yes" 23336else $as_nop 23337 ac_cv_have_control_in_msghdr="no" 23338 23339fi 23340rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 23341 23342fi 23343{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_control_in_msghdr" >&5 23344printf "%s\n" "$ac_cv_have_control_in_msghdr" >&6; } 23345if test "x$ac_cv_have_control_in_msghdr" = "xyes" ; then 23346 23347printf "%s\n" "#define HAVE_CONTROL_IN_MSGHDR 1" >>confdefs.h 23348 23349fi 23350 23351{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if libc defines __progname" >&5 23352printf %s "checking if libc defines __progname... " >&6; } 23353if test ${ac_cv_libc_defines___progname+y} 23354then : 23355 printf %s "(cached) " >&6 23356else $as_nop 23357 23358 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 23359/* end confdefs.h. */ 23360 #include <stdio.h> 23361int 23362main (void) 23363{ 23364 extern char *__progname; printf("%s", __progname); 23365 ; 23366 return 0; 23367} 23368_ACEOF 23369if ac_fn_c_try_link "$LINENO" 23370then : 23371 ac_cv_libc_defines___progname="yes" 23372else $as_nop 23373 ac_cv_libc_defines___progname="no" 23374 23375fi 23376rm -f core conftest.err conftest.$ac_objext conftest.beam \ 23377 conftest$ac_exeext conftest.$ac_ext 23378 23379fi 23380{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libc_defines___progname" >&5 23381printf "%s\n" "$ac_cv_libc_defines___progname" >&6; } 23382if test "x$ac_cv_libc_defines___progname" = "xyes" ; then 23383 23384printf "%s\n" "#define HAVE___PROGNAME 1" >>confdefs.h 23385 23386fi 23387 23388{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC implements __FUNCTION__" >&5 23389printf %s "checking whether $CC implements __FUNCTION__... " >&6; } 23390if test ${ac_cv_cc_implements___FUNCTION__+y} 23391then : 23392 printf %s "(cached) " >&6 23393else $as_nop 23394 23395 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 23396/* end confdefs.h. */ 23397 #include <stdio.h> 23398int 23399main (void) 23400{ 23401 printf("%s", __FUNCTION__); 23402 ; 23403 return 0; 23404} 23405_ACEOF 23406if ac_fn_c_try_link "$LINENO" 23407then : 23408 ac_cv_cc_implements___FUNCTION__="yes" 23409else $as_nop 23410 ac_cv_cc_implements___FUNCTION__="no" 23411 23412fi 23413rm -f core conftest.err conftest.$ac_objext conftest.beam \ 23414 conftest$ac_exeext conftest.$ac_ext 23415 23416fi 23417{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cc_implements___FUNCTION__" >&5 23418printf "%s\n" "$ac_cv_cc_implements___FUNCTION__" >&6; } 23419if test "x$ac_cv_cc_implements___FUNCTION__" = "xyes" ; then 23420 23421printf "%s\n" "#define HAVE___FUNCTION__ 1" >>confdefs.h 23422 23423fi 23424 23425{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC implements __func__" >&5 23426printf %s "checking whether $CC implements __func__... " >&6; } 23427if test ${ac_cv_cc_implements___func__+y} 23428then : 23429 printf %s "(cached) " >&6 23430else $as_nop 23431 23432 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 23433/* end confdefs.h. */ 23434 #include <stdio.h> 23435int 23436main (void) 23437{ 23438 printf("%s", __func__); 23439 ; 23440 return 0; 23441} 23442_ACEOF 23443if ac_fn_c_try_link "$LINENO" 23444then : 23445 ac_cv_cc_implements___func__="yes" 23446else $as_nop 23447 ac_cv_cc_implements___func__="no" 23448 23449fi 23450rm -f core conftest.err conftest.$ac_objext conftest.beam \ 23451 conftest$ac_exeext conftest.$ac_ext 23452 23453fi 23454{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cc_implements___func__" >&5 23455printf "%s\n" "$ac_cv_cc_implements___func__" >&6; } 23456if test "x$ac_cv_cc_implements___func__" = "xyes" ; then 23457 23458printf "%s\n" "#define HAVE___func__ 1" >>confdefs.h 23459 23460fi 23461 23462{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether va_copy exists" >&5 23463printf %s "checking whether va_copy exists... " >&6; } 23464if test ${ac_cv_have_va_copy+y} 23465then : 23466 printf %s "(cached) " >&6 23467else $as_nop 23468 23469 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 23470/* end confdefs.h. */ 23471 23472#include <stdarg.h> 23473va_list x,y; 23474 23475int 23476main (void) 23477{ 23478 va_copy(x,y); 23479 ; 23480 return 0; 23481} 23482_ACEOF 23483if ac_fn_c_try_link "$LINENO" 23484then : 23485 ac_cv_have_va_copy="yes" 23486else $as_nop 23487 ac_cv_have_va_copy="no" 23488 23489fi 23490rm -f core conftest.err conftest.$ac_objext conftest.beam \ 23491 conftest$ac_exeext conftest.$ac_ext 23492 23493fi 23494{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_va_copy" >&5 23495printf "%s\n" "$ac_cv_have_va_copy" >&6; } 23496if test "x$ac_cv_have_va_copy" = "xyes" ; then 23497 23498printf "%s\n" "#define HAVE_VA_COPY 1" >>confdefs.h 23499 23500fi 23501 23502{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether __va_copy exists" >&5 23503printf %s "checking whether __va_copy exists... " >&6; } 23504if test ${ac_cv_have___va_copy+y} 23505then : 23506 printf %s "(cached) " >&6 23507else $as_nop 23508 23509 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 23510/* end confdefs.h. */ 23511 23512#include <stdarg.h> 23513va_list x,y; 23514 23515int 23516main (void) 23517{ 23518 __va_copy(x,y); 23519 ; 23520 return 0; 23521} 23522_ACEOF 23523if ac_fn_c_try_link "$LINENO" 23524then : 23525 ac_cv_have___va_copy="yes" 23526else $as_nop 23527 ac_cv_have___va_copy="no" 23528 23529fi 23530rm -f core conftest.err conftest.$ac_objext conftest.beam \ 23531 conftest$ac_exeext conftest.$ac_ext 23532 23533fi 23534{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have___va_copy" >&5 23535printf "%s\n" "$ac_cv_have___va_copy" >&6; } 23536if test "x$ac_cv_have___va_copy" = "xyes" ; then 23537 23538printf "%s\n" "#define HAVE___VA_COPY 1" >>confdefs.h 23539 23540fi 23541 23542{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether getopt has optreset support" >&5 23543printf %s "checking whether getopt has optreset support... " >&6; } 23544if test ${ac_cv_have_getopt_optreset+y} 23545then : 23546 printf %s "(cached) " >&6 23547else $as_nop 23548 23549 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 23550/* end confdefs.h. */ 23551 #include <getopt.h> 23552int 23553main (void) 23554{ 23555 extern int optreset; optreset = 0; 23556 ; 23557 return 0; 23558} 23559_ACEOF 23560if ac_fn_c_try_link "$LINENO" 23561then : 23562 ac_cv_have_getopt_optreset="yes" 23563else $as_nop 23564 ac_cv_have_getopt_optreset="no" 23565 23566fi 23567rm -f core conftest.err conftest.$ac_objext conftest.beam \ 23568 conftest$ac_exeext conftest.$ac_ext 23569 23570fi 23571{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_getopt_optreset" >&5 23572printf "%s\n" "$ac_cv_have_getopt_optreset" >&6; } 23573if test "x$ac_cv_have_getopt_optreset" = "xyes" ; then 23574 23575printf "%s\n" "#define HAVE_GETOPT_OPTRESET 1" >>confdefs.h 23576 23577fi 23578 23579{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if libc defines sys_errlist" >&5 23580printf %s "checking if libc defines sys_errlist... " >&6; } 23581if test ${ac_cv_libc_defines_sys_errlist+y} 23582then : 23583 printf %s "(cached) " >&6 23584else $as_nop 23585 23586 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 23587/* end confdefs.h. */ 23588 #include <stdio.h> 23589int 23590main (void) 23591{ 23592 extern const char *const sys_errlist[]; printf("%s", sys_errlist[0]); 23593 ; 23594 return 0; 23595} 23596_ACEOF 23597if ac_fn_c_try_link "$LINENO" 23598then : 23599 ac_cv_libc_defines_sys_errlist="yes" 23600else $as_nop 23601 ac_cv_libc_defines_sys_errlist="no" 23602 23603fi 23604rm -f core conftest.err conftest.$ac_objext conftest.beam \ 23605 conftest$ac_exeext conftest.$ac_ext 23606 23607fi 23608{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libc_defines_sys_errlist" >&5 23609printf "%s\n" "$ac_cv_libc_defines_sys_errlist" >&6; } 23610if test "x$ac_cv_libc_defines_sys_errlist" = "xyes" ; then 23611 23612printf "%s\n" "#define HAVE_SYS_ERRLIST 1" >>confdefs.h 23613 23614fi 23615 23616 23617{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if libc defines sys_nerr" >&5 23618printf %s "checking if libc defines sys_nerr... " >&6; } 23619if test ${ac_cv_libc_defines_sys_nerr+y} 23620then : 23621 printf %s "(cached) " >&6 23622else $as_nop 23623 23624 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 23625/* end confdefs.h. */ 23626 #include <stdio.h> 23627int 23628main (void) 23629{ 23630 extern int sys_nerr; printf("%i", sys_nerr); 23631 ; 23632 return 0; 23633} 23634_ACEOF 23635if ac_fn_c_try_link "$LINENO" 23636then : 23637 ac_cv_libc_defines_sys_nerr="yes" 23638else $as_nop 23639 ac_cv_libc_defines_sys_nerr="no" 23640 23641fi 23642rm -f core conftest.err conftest.$ac_objext conftest.beam \ 23643 conftest$ac_exeext conftest.$ac_ext 23644 23645fi 23646{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libc_defines_sys_nerr" >&5 23647printf "%s\n" "$ac_cv_libc_defines_sys_nerr" >&6; } 23648if test "x$ac_cv_libc_defines_sys_nerr" = "xyes" ; then 23649 23650printf "%s\n" "#define HAVE_SYS_NERR 1" >>confdefs.h 23651 23652fi 23653 23654# Check libraries needed by DNS fingerprint support 23655{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing getrrsetbyname" >&5 23656printf %s "checking for library containing getrrsetbyname... " >&6; } 23657if test ${ac_cv_search_getrrsetbyname+y} 23658then : 23659 printf %s "(cached) " >&6 23660else $as_nop 23661 ac_func_search_save_LIBS=$LIBS 23662cat confdefs.h - <<_ACEOF >conftest.$ac_ext 23663/* end confdefs.h. */ 23664 23665/* Override any GCC internal prototype to avoid an error. 23666 Use char because int might match the return type of a GCC 23667 builtin and then its argument prototype would still apply. */ 23668char getrrsetbyname (); 23669int 23670main (void) 23671{ 23672return getrrsetbyname (); 23673 ; 23674 return 0; 23675} 23676_ACEOF 23677for ac_lib in '' resolv 23678do 23679 if test -z "$ac_lib"; then 23680 ac_res="none required" 23681 else 23682 ac_res=-l$ac_lib 23683 LIBS="-l$ac_lib $ac_func_search_save_LIBS" 23684 fi 23685 if ac_fn_c_try_link "$LINENO" 23686then : 23687 ac_cv_search_getrrsetbyname=$ac_res 23688fi 23689rm -f core conftest.err conftest.$ac_objext conftest.beam \ 23690 conftest$ac_exeext 23691 if test ${ac_cv_search_getrrsetbyname+y} 23692then : 23693 break 23694fi 23695done 23696if test ${ac_cv_search_getrrsetbyname+y} 23697then : 23698 23699else $as_nop 23700 ac_cv_search_getrrsetbyname=no 23701fi 23702rm conftest.$ac_ext 23703LIBS=$ac_func_search_save_LIBS 23704fi 23705{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_getrrsetbyname" >&5 23706printf "%s\n" "$ac_cv_search_getrrsetbyname" >&6; } 23707ac_res=$ac_cv_search_getrrsetbyname 23708if test "$ac_res" != no 23709then : 23710 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" 23711 23712printf "%s\n" "#define HAVE_GETRRSETBYNAME 1" >>confdefs.h 23713 23714else $as_nop 23715 23716 # Needed by our getrrsetbyname() 23717 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing res_query" >&5 23718printf %s "checking for library containing res_query... " >&6; } 23719if test ${ac_cv_search_res_query+y} 23720then : 23721 printf %s "(cached) " >&6 23722else $as_nop 23723 ac_func_search_save_LIBS=$LIBS 23724cat confdefs.h - <<_ACEOF >conftest.$ac_ext 23725/* end confdefs.h. */ 23726 23727/* Override any GCC internal prototype to avoid an error. 23728 Use char because int might match the return type of a GCC 23729 builtin and then its argument prototype would still apply. */ 23730char res_query (); 23731int 23732main (void) 23733{ 23734return res_query (); 23735 ; 23736 return 0; 23737} 23738_ACEOF 23739for ac_lib in '' resolv 23740do 23741 if test -z "$ac_lib"; then 23742 ac_res="none required" 23743 else 23744 ac_res=-l$ac_lib 23745 LIBS="-l$ac_lib $ac_func_search_save_LIBS" 23746 fi 23747 if ac_fn_c_try_link "$LINENO" 23748then : 23749 ac_cv_search_res_query=$ac_res 23750fi 23751rm -f core conftest.err conftest.$ac_objext conftest.beam \ 23752 conftest$ac_exeext 23753 if test ${ac_cv_search_res_query+y} 23754then : 23755 break 23756fi 23757done 23758if test ${ac_cv_search_res_query+y} 23759then : 23760 23761else $as_nop 23762 ac_cv_search_res_query=no 23763fi 23764rm conftest.$ac_ext 23765LIBS=$ac_func_search_save_LIBS 23766fi 23767{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_res_query" >&5 23768printf "%s\n" "$ac_cv_search_res_query" >&6; } 23769ac_res=$ac_cv_search_res_query 23770if test "$ac_res" != no 23771then : 23772 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" 23773 23774fi 23775 23776 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing dn_expand" >&5 23777printf %s "checking for library containing dn_expand... " >&6; } 23778if test ${ac_cv_search_dn_expand+y} 23779then : 23780 printf %s "(cached) " >&6 23781else $as_nop 23782 ac_func_search_save_LIBS=$LIBS 23783cat confdefs.h - <<_ACEOF >conftest.$ac_ext 23784/* end confdefs.h. */ 23785 23786/* Override any GCC internal prototype to avoid an error. 23787 Use char because int might match the return type of a GCC 23788 builtin and then its argument prototype would still apply. */ 23789char dn_expand (); 23790int 23791main (void) 23792{ 23793return dn_expand (); 23794 ; 23795 return 0; 23796} 23797_ACEOF 23798for ac_lib in '' resolv 23799do 23800 if test -z "$ac_lib"; then 23801 ac_res="none required" 23802 else 23803 ac_res=-l$ac_lib 23804 LIBS="-l$ac_lib $ac_func_search_save_LIBS" 23805 fi 23806 if ac_fn_c_try_link "$LINENO" 23807then : 23808 ac_cv_search_dn_expand=$ac_res 23809fi 23810rm -f core conftest.err conftest.$ac_objext conftest.beam \ 23811 conftest$ac_exeext 23812 if test ${ac_cv_search_dn_expand+y} 23813then : 23814 break 23815fi 23816done 23817if test ${ac_cv_search_dn_expand+y} 23818then : 23819 23820else $as_nop 23821 ac_cv_search_dn_expand=no 23822fi 23823rm conftest.$ac_ext 23824LIBS=$ac_func_search_save_LIBS 23825fi 23826{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dn_expand" >&5 23827printf "%s\n" "$ac_cv_search_dn_expand" >&6; } 23828ac_res=$ac_cv_search_dn_expand 23829if test "$ac_res" != no 23830then : 23831 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" 23832 23833fi 23834 23835 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if res_query will link" >&5 23836printf %s "checking if res_query will link... " >&6; } 23837 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 23838/* end confdefs.h. */ 23839 23840#include <sys/types.h> 23841#include <netinet/in.h> 23842#include <arpa/nameser.h> 23843#include <netdb.h> 23844#include <resolv.h> 23845 23846int 23847main (void) 23848{ 23849 23850 res_query (0, 0, 0, 0, 0); 23851 23852 ; 23853 return 0; 23854} 23855_ACEOF 23856if ac_fn_c_try_link "$LINENO" 23857then : 23858 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 23859printf "%s\n" "yes" >&6; } 23860else $as_nop 23861 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 23862printf "%s\n" "no" >&6; } 23863 saved_LIBS="$LIBS" 23864 LIBS="$LIBS -lresolv" 23865 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for res_query in -lresolv" >&5 23866printf %s "checking for res_query in -lresolv... " >&6; } 23867 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 23868/* end confdefs.h. */ 23869 23870#include <sys/types.h> 23871#include <netinet/in.h> 23872#include <arpa/nameser.h> 23873#include <netdb.h> 23874#include <resolv.h> 23875 23876int 23877main (void) 23878{ 23879 23880 res_query (0, 0, 0, 0, 0); 23881 23882 ; 23883 return 0; 23884} 23885_ACEOF 23886if ac_fn_c_try_link "$LINENO" 23887then : 23888 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 23889printf "%s\n" "yes" >&6; } 23890else $as_nop 23891 LIBS="$saved_LIBS" 23892 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 23893printf "%s\n" "no" >&6; } 23894fi 23895rm -f core conftest.err conftest.$ac_objext conftest.beam \ 23896 conftest$ac_exeext conftest.$ac_ext 23897 23898fi 23899rm -f core conftest.err conftest.$ac_objext conftest.beam \ 23900 conftest$ac_exeext conftest.$ac_ext 23901 ac_fn_c_check_func "$LINENO" "_getshort" "ac_cv_func__getshort" 23902if test "x$ac_cv_func__getshort" = xyes 23903then : 23904 printf "%s\n" "#define HAVE__GETSHORT 1" >>confdefs.h 23905 23906fi 23907ac_fn_c_check_func "$LINENO" "_getlong" "ac_cv_func__getlong" 23908if test "x$ac_cv_func__getlong" = xyes 23909then : 23910 printf "%s\n" "#define HAVE__GETLONG 1" >>confdefs.h 23911 23912fi 23913 23914 ac_fn_check_decl "$LINENO" "_getshort" "ac_cv_have_decl__getshort" "#include <sys/types.h> 23915 #include <arpa/nameser.h> 23916" "$ac_c_undeclared_builtin_options" "CFLAGS" 23917if test "x$ac_cv_have_decl__getshort" = xyes 23918then : 23919 ac_have_decl=1 23920else $as_nop 23921 ac_have_decl=0 23922fi 23923printf "%s\n" "#define HAVE_DECL__GETSHORT $ac_have_decl" >>confdefs.h 23924ac_fn_check_decl "$LINENO" "_getlong" "ac_cv_have_decl__getlong" "#include <sys/types.h> 23925 #include <arpa/nameser.h> 23926" "$ac_c_undeclared_builtin_options" "CFLAGS" 23927if test "x$ac_cv_have_decl__getlong" = xyes 23928then : 23929 ac_have_decl=1 23930else $as_nop 23931 ac_have_decl=0 23932fi 23933printf "%s\n" "#define HAVE_DECL__GETLONG $ac_have_decl" >>confdefs.h 23934 23935 ac_fn_c_check_member "$LINENO" "HEADER" "ad" "ac_cv_member_HEADER_ad" "#include <arpa/nameser.h> 23936" 23937if test "x$ac_cv_member_HEADER_ad" = xyes 23938then : 23939 23940printf "%s\n" "#define HAVE_HEADER_AD 1" >>confdefs.h 23941 23942fi 23943 23944 23945fi 23946 23947 23948{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if struct __res_state _res is an extern" >&5 23949printf %s "checking if struct __res_state _res is an extern... " >&6; } 23950cat confdefs.h - <<_ACEOF >conftest.$ac_ext 23951/* end confdefs.h. */ 23952 23953#include <stdio.h> 23954#if HAVE_SYS_TYPES_H 23955# include <sys/types.h> 23956#endif 23957#include <netinet/in.h> 23958#include <arpa/nameser.h> 23959#include <resolv.h> 23960extern struct __res_state _res; 23961 23962int 23963main (void) 23964{ 23965 23966struct __res_state *volatile p = &_res; /* force resolution of _res */ 23967return 0; 23968 23969 ; 23970 return 0; 23971} 23972_ACEOF 23973if ac_fn_c_try_link "$LINENO" 23974then : 23975 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 23976printf "%s\n" "yes" >&6; } 23977 23978printf "%s\n" "#define HAVE__RES_EXTERN 1" >>confdefs.h 23979 23980 23981else $as_nop 23982 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 23983printf "%s\n" "no" >&6; } 23984 23985fi 23986rm -f core conftest.err conftest.$ac_objext conftest.beam \ 23987 conftest$ac_exeext conftest.$ac_ext 23988 23989# Check whether user wants SELinux support 23990SELINUX_MSG="no" 23991LIBSELINUX="" 23992 23993# Check whether --with-selinux was given. 23994if test ${with_selinux+y} 23995then : 23996 withval=$with_selinux; if test "x$withval" != "xno" ; then 23997 save_LIBS="$LIBS" 23998 23999printf "%s\n" "#define WITH_SELINUX 1" >>confdefs.h 24000 24001 SELINUX_MSG="yes" 24002 ac_fn_c_check_header_compile "$LINENO" "selinux/selinux.h" "ac_cv_header_selinux_selinux_h" "$ac_includes_default" 24003if test "x$ac_cv_header_selinux_selinux_h" = xyes 24004then : 24005 24006else $as_nop 24007 as_fn_error $? "SELinux support requires selinux.h header" "$LINENO" 5 24008fi 24009 24010 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for setexeccon in -lselinux" >&5 24011printf %s "checking for setexeccon in -lselinux... " >&6; } 24012if test ${ac_cv_lib_selinux_setexeccon+y} 24013then : 24014 printf %s "(cached) " >&6 24015else $as_nop 24016 ac_check_lib_save_LIBS=$LIBS 24017LIBS="-lselinux $LIBS" 24018cat confdefs.h - <<_ACEOF >conftest.$ac_ext 24019/* end confdefs.h. */ 24020 24021/* Override any GCC internal prototype to avoid an error. 24022 Use char because int might match the return type of a GCC 24023 builtin and then its argument prototype would still apply. */ 24024char setexeccon (); 24025int 24026main (void) 24027{ 24028return setexeccon (); 24029 ; 24030 return 0; 24031} 24032_ACEOF 24033if ac_fn_c_try_link "$LINENO" 24034then : 24035 ac_cv_lib_selinux_setexeccon=yes 24036else $as_nop 24037 ac_cv_lib_selinux_setexeccon=no 24038fi 24039rm -f core conftest.err conftest.$ac_objext conftest.beam \ 24040 conftest$ac_exeext conftest.$ac_ext 24041LIBS=$ac_check_lib_save_LIBS 24042fi 24043{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_selinux_setexeccon" >&5 24044printf "%s\n" "$ac_cv_lib_selinux_setexeccon" >&6; } 24045if test "x$ac_cv_lib_selinux_setexeccon" = xyes 24046then : 24047 LIBSELINUX="-lselinux" 24048 LIBS="$LIBS -lselinux" 24049 24050else $as_nop 24051 as_fn_error $? "SELinux support requires libselinux library" "$LINENO" 5 24052fi 24053 24054 ac_fn_c_check_func "$LINENO" "getseuserbyname" "ac_cv_func_getseuserbyname" 24055if test "x$ac_cv_func_getseuserbyname" = xyes 24056then : 24057 printf "%s\n" "#define HAVE_GETSEUSERBYNAME 1" >>confdefs.h 24058 24059fi 24060ac_fn_c_check_func "$LINENO" "get_default_context_with_level" "ac_cv_func_get_default_context_with_level" 24061if test "x$ac_cv_func_get_default_context_with_level" = xyes 24062then : 24063 printf "%s\n" "#define HAVE_GET_DEFAULT_CONTEXT_WITH_LEVEL 1" >>confdefs.h 24064 24065fi 24066 24067 LIBS="$save_LIBS $LIBSELINUX" 24068 fi 24069 24070fi 24071 24072 24073 24074# Check whether user wants Kerberos 5 support 24075KRB5_MSG="no" 24076 24077# Check whether --with-kerberos5 was given. 24078if test ${with_kerberos5+y} 24079then : 24080 withval=$with_kerberos5; if test "x$withval" != "xno" ; then 24081 if test "x$withval" = "xyes" ; then 24082 KRB5ROOT="/usr/local" 24083 else 24084 KRB5ROOT=${withval} 24085 fi 24086 24087 24088printf "%s\n" "#define KRB5 1" >>confdefs.h 24089 24090 KRB5_MSG="yes" 24091 24092 use_pkgconfig_for_krb5= 24093 if test "x$PKGCONFIG" != "xno"; then 24094 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if $PKGCONFIG knows about kerberos5" >&5 24095printf %s "checking if $PKGCONFIG knows about kerberos5... " >&6; } 24096 if "$PKGCONFIG" krb5; then 24097 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24098printf "%s\n" "yes" >&6; } 24099 use_pkgconfig_for_krb5=yes 24100 else 24101 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 24102printf "%s\n" "no" >&6; } 24103 fi 24104 fi 24105 if test "x$use_pkgconfig_for_krb5" = "xyes"; then 24106 K5CFLAGS=`$PKGCONFIG --cflags krb5` 24107 K5LIBS=`$PKGCONFIG --libs krb5` 24108 CPPFLAGS="$CPPFLAGS $K5CFLAGS" 24109 24110 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gssapi support" >&5 24111printf %s "checking for gssapi support... " >&6; } 24112 if "$PKGCONFIG" krb5-gssapi; then 24113 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24114printf "%s\n" "yes" >&6; } 24115 24116printf "%s\n" "#define GSSAPI 1" >>confdefs.h 24117 24118 GSSCFLAGS="`$PKGCONFIG --cflags krb5-gssapi`" 24119 GSSLIBS="`$PKGCONFIG --libs krb5-gssapi`" 24120 CPPFLAGS="$CPPFLAGS $GSSCFLAGS" 24121 else 24122 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 24123printf "%s\n" "no" >&6; } 24124 fi 24125 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether we are using Heimdal" >&5 24126printf %s "checking whether we are using Heimdal... " >&6; } 24127 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 24128/* end confdefs.h. */ 24129 #include <krb5.h> 24130 24131int 24132main (void) 24133{ 24134 char *tmp = heimdal_version; 24135 ; 24136 return 0; 24137} 24138_ACEOF 24139if ac_fn_c_try_compile "$LINENO" 24140then : 24141 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24142printf "%s\n" "yes" >&6; } 24143 24144printf "%s\n" "#define HEIMDAL 1" >>confdefs.h 24145 24146else $as_nop 24147 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 24148printf "%s\n" "no" >&6; } 24149 24150fi 24151rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 24152 else 24153 if test -n "$ac_tool_prefix"; then 24154 # Extract the first word of "${ac_tool_prefix}krb5-config", so it can be a program name with args. 24155set dummy ${ac_tool_prefix}krb5-config; ac_word=$2 24156{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24157printf %s "checking for $ac_word... " >&6; } 24158if test ${ac_cv_path_KRB5CONF+y} 24159then : 24160 printf %s "(cached) " >&6 24161else $as_nop 24162 case $KRB5CONF in 24163 [\\/]* | ?:[\\/]*) 24164 ac_cv_path_KRB5CONF="$KRB5CONF" # Let the user override the test with a path. 24165 ;; 24166 *) 24167 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24168as_dummy="$KRB5ROOT/bin:$PATH" 24169for as_dir in $as_dummy 24170do 24171 IFS=$as_save_IFS 24172 case $as_dir in #((( 24173 '') as_dir=./ ;; 24174 */) ;; 24175 *) as_dir=$as_dir/ ;; 24176 esac 24177 for ac_exec_ext in '' $ac_executable_extensions; do 24178 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 24179 ac_cv_path_KRB5CONF="$as_dir$ac_word$ac_exec_ext" 24180 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 24181 break 2 24182 fi 24183done 24184 done 24185IFS=$as_save_IFS 24186 24187 ;; 24188esac 24189fi 24190KRB5CONF=$ac_cv_path_KRB5CONF 24191if test -n "$KRB5CONF"; then 24192 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $KRB5CONF" >&5 24193printf "%s\n" "$KRB5CONF" >&6; } 24194else 24195 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 24196printf "%s\n" "no" >&6; } 24197fi 24198 24199 24200fi 24201if test -z "$ac_cv_path_KRB5CONF"; then 24202 ac_pt_KRB5CONF=$KRB5CONF 24203 # Extract the first word of "krb5-config", so it can be a program name with args. 24204set dummy krb5-config; ac_word=$2 24205{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24206printf %s "checking for $ac_word... " >&6; } 24207if test ${ac_cv_path_ac_pt_KRB5CONF+y} 24208then : 24209 printf %s "(cached) " >&6 24210else $as_nop 24211 case $ac_pt_KRB5CONF in 24212 [\\/]* | ?:[\\/]*) 24213 ac_cv_path_ac_pt_KRB5CONF="$ac_pt_KRB5CONF" # Let the user override the test with a path. 24214 ;; 24215 *) 24216 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24217as_dummy="$KRB5ROOT/bin:$PATH" 24218for as_dir in $as_dummy 24219do 24220 IFS=$as_save_IFS 24221 case $as_dir in #((( 24222 '') as_dir=./ ;; 24223 */) ;; 24224 *) as_dir=$as_dir/ ;; 24225 esac 24226 for ac_exec_ext in '' $ac_executable_extensions; do 24227 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 24228 ac_cv_path_ac_pt_KRB5CONF="$as_dir$ac_word$ac_exec_ext" 24229 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 24230 break 2 24231 fi 24232done 24233 done 24234IFS=$as_save_IFS 24235 24236 ;; 24237esac 24238fi 24239ac_pt_KRB5CONF=$ac_cv_path_ac_pt_KRB5CONF 24240if test -n "$ac_pt_KRB5CONF"; then 24241 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_pt_KRB5CONF" >&5 24242printf "%s\n" "$ac_pt_KRB5CONF" >&6; } 24243else 24244 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 24245printf "%s\n" "no" >&6; } 24246fi 24247 24248 if test "x$ac_pt_KRB5CONF" = x; then 24249 KRB5CONF="$KRB5ROOT/bin/krb5-config" 24250 else 24251 case $cross_compiling:$ac_tool_warned in 24252yes:) 24253{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 24254printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 24255ac_tool_warned=yes ;; 24256esac 24257 KRB5CONF=$ac_pt_KRB5CONF 24258 fi 24259else 24260 KRB5CONF="$ac_cv_path_KRB5CONF" 24261fi 24262 24263 if test -x $KRB5CONF ; then 24264 K5CFLAGS="`$KRB5CONF --cflags`" 24265 K5LIBS="`$KRB5CONF --libs`" 24266 CPPFLAGS="$CPPFLAGS $K5CFLAGS" 24267 24268 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gssapi support" >&5 24269printf %s "checking for gssapi support... " >&6; } 24270 if $KRB5CONF | grep gssapi >/dev/null ; then 24271 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24272printf "%s\n" "yes" >&6; } 24273 24274printf "%s\n" "#define GSSAPI 1" >>confdefs.h 24275 24276 GSSCFLAGS="`$KRB5CONF --cflags gssapi`" 24277 GSSLIBS="`$KRB5CONF --libs gssapi`" 24278 CPPFLAGS="$CPPFLAGS $GSSCFLAGS" 24279 else 24280 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 24281printf "%s\n" "no" >&6; } 24282 fi 24283 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether we are using Heimdal" >&5 24284printf %s "checking whether we are using Heimdal... " >&6; } 24285 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 24286/* end confdefs.h. */ 24287 #include <krb5.h> 24288 24289int 24290main (void) 24291{ 24292 char *tmp = heimdal_version; 24293 ; 24294 return 0; 24295} 24296_ACEOF 24297if ac_fn_c_try_compile "$LINENO" 24298then : 24299 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24300printf "%s\n" "yes" >&6; } 24301 24302printf "%s\n" "#define HEIMDAL 1" >>confdefs.h 24303 24304else $as_nop 24305 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 24306printf "%s\n" "no" >&6; } 24307 24308fi 24309rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 24310 else 24311 CPPFLAGS="$CPPFLAGS -I${KRB5ROOT}/include" 24312 LDFLAGS="$LDFLAGS -L${KRB5ROOT}/lib" 24313 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether we are using Heimdal" >&5 24314printf %s "checking whether we are using Heimdal... " >&6; } 24315 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 24316/* end confdefs.h. */ 24317 #include <krb5.h> 24318 24319int 24320main (void) 24321{ 24322 char *tmp = heimdal_version; 24323 ; 24324 return 0; 24325} 24326_ACEOF 24327if ac_fn_c_try_compile "$LINENO" 24328then : 24329 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24330printf "%s\n" "yes" >&6; } 24331 printf "%s\n" "#define HEIMDAL 1" >>confdefs.h 24332 24333 K5LIBS="-lkrb5" 24334 K5LIBS="$K5LIBS -lcom_err -lasn1" 24335 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for net_write in -lroken" >&5 24336printf %s "checking for net_write in -lroken... " >&6; } 24337if test ${ac_cv_lib_roken_net_write+y} 24338then : 24339 printf %s "(cached) " >&6 24340else $as_nop 24341 ac_check_lib_save_LIBS=$LIBS 24342LIBS="-lroken $LIBS" 24343cat confdefs.h - <<_ACEOF >conftest.$ac_ext 24344/* end confdefs.h. */ 24345 24346/* Override any GCC internal prototype to avoid an error. 24347 Use char because int might match the return type of a GCC 24348 builtin and then its argument prototype would still apply. */ 24349char net_write (); 24350int 24351main (void) 24352{ 24353return net_write (); 24354 ; 24355 return 0; 24356} 24357_ACEOF 24358if ac_fn_c_try_link "$LINENO" 24359then : 24360 ac_cv_lib_roken_net_write=yes 24361else $as_nop 24362 ac_cv_lib_roken_net_write=no 24363fi 24364rm -f core conftest.err conftest.$ac_objext conftest.beam \ 24365 conftest$ac_exeext conftest.$ac_ext 24366LIBS=$ac_check_lib_save_LIBS 24367fi 24368{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_roken_net_write" >&5 24369printf "%s\n" "$ac_cv_lib_roken_net_write" >&6; } 24370if test "x$ac_cv_lib_roken_net_write" = xyes 24371then : 24372 K5LIBS="$K5LIBS -lroken" 24373fi 24374 24375 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes" >&5 24376printf %s "checking for des_cbc_encrypt in -ldes... " >&6; } 24377if test ${ac_cv_lib_des_des_cbc_encrypt+y} 24378then : 24379 printf %s "(cached) " >&6 24380else $as_nop 24381 ac_check_lib_save_LIBS=$LIBS 24382LIBS="-ldes $LIBS" 24383cat confdefs.h - <<_ACEOF >conftest.$ac_ext 24384/* end confdefs.h. */ 24385 24386/* Override any GCC internal prototype to avoid an error. 24387 Use char because int might match the return type of a GCC 24388 builtin and then its argument prototype would still apply. */ 24389char des_cbc_encrypt (); 24390int 24391main (void) 24392{ 24393return des_cbc_encrypt (); 24394 ; 24395 return 0; 24396} 24397_ACEOF 24398if ac_fn_c_try_link "$LINENO" 24399then : 24400 ac_cv_lib_des_des_cbc_encrypt=yes 24401else $as_nop 24402 ac_cv_lib_des_des_cbc_encrypt=no 24403fi 24404rm -f core conftest.err conftest.$ac_objext conftest.beam \ 24405 conftest$ac_exeext conftest.$ac_ext 24406LIBS=$ac_check_lib_save_LIBS 24407fi 24408{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des_des_cbc_encrypt" >&5 24409printf "%s\n" "$ac_cv_lib_des_des_cbc_encrypt" >&6; } 24410if test "x$ac_cv_lib_des_des_cbc_encrypt" = xyes 24411then : 24412 K5LIBS="$K5LIBS -ldes" 24413fi 24414 24415 24416else $as_nop 24417 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 24418printf "%s\n" "no" >&6; } 24419 K5LIBS="-lkrb5 -lk5crypto -lcom_err" 24420 24421fi 24422rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 24423 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing dn_expand" >&5 24424printf %s "checking for library containing dn_expand... " >&6; } 24425if test ${ac_cv_search_dn_expand+y} 24426then : 24427 printf %s "(cached) " >&6 24428else $as_nop 24429 ac_func_search_save_LIBS=$LIBS 24430cat confdefs.h - <<_ACEOF >conftest.$ac_ext 24431/* end confdefs.h. */ 24432 24433/* Override any GCC internal prototype to avoid an error. 24434 Use char because int might match the return type of a GCC 24435 builtin and then its argument prototype would still apply. */ 24436char dn_expand (); 24437int 24438main (void) 24439{ 24440return dn_expand (); 24441 ; 24442 return 0; 24443} 24444_ACEOF 24445for ac_lib in '' resolv 24446do 24447 if test -z "$ac_lib"; then 24448 ac_res="none required" 24449 else 24450 ac_res=-l$ac_lib 24451 LIBS="-l$ac_lib $ac_func_search_save_LIBS" 24452 fi 24453 if ac_fn_c_try_link "$LINENO" 24454then : 24455 ac_cv_search_dn_expand=$ac_res 24456fi 24457rm -f core conftest.err conftest.$ac_objext conftest.beam \ 24458 conftest$ac_exeext 24459 if test ${ac_cv_search_dn_expand+y} 24460then : 24461 break 24462fi 24463done 24464if test ${ac_cv_search_dn_expand+y} 24465then : 24466 24467else $as_nop 24468 ac_cv_search_dn_expand=no 24469fi 24470rm conftest.$ac_ext 24471LIBS=$ac_func_search_save_LIBS 24472fi 24473{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dn_expand" >&5 24474printf "%s\n" "$ac_cv_search_dn_expand" >&6; } 24475ac_res=$ac_cv_search_dn_expand 24476if test "$ac_res" != no 24477then : 24478 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" 24479 24480fi 24481 24482 24483 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gss_init_sec_context in -lgssapi_krb5" >&5 24484printf %s "checking for gss_init_sec_context in -lgssapi_krb5... " >&6; } 24485if test ${ac_cv_lib_gssapi_krb5_gss_init_sec_context+y} 24486then : 24487 printf %s "(cached) " >&6 24488else $as_nop 24489 ac_check_lib_save_LIBS=$LIBS 24490LIBS="-lgssapi_krb5 $LIBS" 24491cat confdefs.h - <<_ACEOF >conftest.$ac_ext 24492/* end confdefs.h. */ 24493 24494/* Override any GCC internal prototype to avoid an error. 24495 Use char because int might match the return type of a GCC 24496 builtin and then its argument prototype would still apply. */ 24497char gss_init_sec_context (); 24498int 24499main (void) 24500{ 24501return gss_init_sec_context (); 24502 ; 24503 return 0; 24504} 24505_ACEOF 24506if ac_fn_c_try_link "$LINENO" 24507then : 24508 ac_cv_lib_gssapi_krb5_gss_init_sec_context=yes 24509else $as_nop 24510 ac_cv_lib_gssapi_krb5_gss_init_sec_context=no 24511fi 24512rm -f core conftest.err conftest.$ac_objext conftest.beam \ 24513 conftest$ac_exeext conftest.$ac_ext 24514LIBS=$ac_check_lib_save_LIBS 24515fi 24516{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gssapi_krb5_gss_init_sec_context" >&5 24517printf "%s\n" "$ac_cv_lib_gssapi_krb5_gss_init_sec_context" >&6; } 24518if test "x$ac_cv_lib_gssapi_krb5_gss_init_sec_context" = xyes 24519then : 24520 printf "%s\n" "#define GSSAPI 1" >>confdefs.h 24521 24522 GSSLIBS="-lgssapi_krb5" 24523else $as_nop 24524 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gss_init_sec_context in -lgssapi" >&5 24525printf %s "checking for gss_init_sec_context in -lgssapi... " >&6; } 24526if test ${ac_cv_lib_gssapi_gss_init_sec_context+y} 24527then : 24528 printf %s "(cached) " >&6 24529else $as_nop 24530 ac_check_lib_save_LIBS=$LIBS 24531LIBS="-lgssapi $LIBS" 24532cat confdefs.h - <<_ACEOF >conftest.$ac_ext 24533/* end confdefs.h. */ 24534 24535/* Override any GCC internal prototype to avoid an error. 24536 Use char because int might match the return type of a GCC 24537 builtin and then its argument prototype would still apply. */ 24538char gss_init_sec_context (); 24539int 24540main (void) 24541{ 24542return gss_init_sec_context (); 24543 ; 24544 return 0; 24545} 24546_ACEOF 24547if ac_fn_c_try_link "$LINENO" 24548then : 24549 ac_cv_lib_gssapi_gss_init_sec_context=yes 24550else $as_nop 24551 ac_cv_lib_gssapi_gss_init_sec_context=no 24552fi 24553rm -f core conftest.err conftest.$ac_objext conftest.beam \ 24554 conftest$ac_exeext conftest.$ac_ext 24555LIBS=$ac_check_lib_save_LIBS 24556fi 24557{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gssapi_gss_init_sec_context" >&5 24558printf "%s\n" "$ac_cv_lib_gssapi_gss_init_sec_context" >&6; } 24559if test "x$ac_cv_lib_gssapi_gss_init_sec_context" = xyes 24560then : 24561 printf "%s\n" "#define GSSAPI 1" >>confdefs.h 24562 24563 GSSLIBS="-lgssapi" 24564else $as_nop 24565 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gss_init_sec_context in -lgss" >&5 24566printf %s "checking for gss_init_sec_context in -lgss... " >&6; } 24567if test ${ac_cv_lib_gss_gss_init_sec_context+y} 24568then : 24569 printf %s "(cached) " >&6 24570else $as_nop 24571 ac_check_lib_save_LIBS=$LIBS 24572LIBS="-lgss $LIBS" 24573cat confdefs.h - <<_ACEOF >conftest.$ac_ext 24574/* end confdefs.h. */ 24575 24576/* Override any GCC internal prototype to avoid an error. 24577 Use char because int might match the return type of a GCC 24578 builtin and then its argument prototype would still apply. */ 24579char gss_init_sec_context (); 24580int 24581main (void) 24582{ 24583return gss_init_sec_context (); 24584 ; 24585 return 0; 24586} 24587_ACEOF 24588if ac_fn_c_try_link "$LINENO" 24589then : 24590 ac_cv_lib_gss_gss_init_sec_context=yes 24591else $as_nop 24592 ac_cv_lib_gss_gss_init_sec_context=no 24593fi 24594rm -f core conftest.err conftest.$ac_objext conftest.beam \ 24595 conftest$ac_exeext conftest.$ac_ext 24596LIBS=$ac_check_lib_save_LIBS 24597fi 24598{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gss_gss_init_sec_context" >&5 24599printf "%s\n" "$ac_cv_lib_gss_gss_init_sec_context" >&6; } 24600if test "x$ac_cv_lib_gss_gss_init_sec_context" = xyes 24601then : 24602 printf "%s\n" "#define GSSAPI 1" >>confdefs.h 24603 24604 GSSLIBS="-lgss" 24605else $as_nop 24606 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Cannot find any suitable gss-api library - build may fail" >&5 24607printf "%s\n" "$as_me: WARNING: Cannot find any suitable gss-api library - build may fail" >&2;} 24608fi 24609 24610 24611fi 24612 24613 24614fi 24615 24616 24617 ac_fn_c_check_header_compile "$LINENO" "gssapi.h" "ac_cv_header_gssapi_h" "$ac_includes_default" 24618if test "x$ac_cv_header_gssapi_h" = xyes 24619then : 24620 24621else $as_nop 24622 unset ac_cv_header_gssapi_h 24623 CPPFLAGS="$CPPFLAGS -I${KRB5ROOT}/include/gssapi" 24624 for ac_header in gssapi.h 24625do : 24626 ac_fn_c_check_header_compile "$LINENO" "gssapi.h" "ac_cv_header_gssapi_h" "$ac_includes_default" 24627if test "x$ac_cv_header_gssapi_h" = xyes 24628then : 24629 printf "%s\n" "#define HAVE_GSSAPI_H 1" >>confdefs.h 24630 24631else $as_nop 24632 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Cannot find any suitable gss-api header - build may fail" >&5 24633printf "%s\n" "$as_me: WARNING: Cannot find any suitable gss-api header - build may fail" >&2;} 24634 24635fi 24636 24637done 24638 24639 24640fi 24641 24642 24643 oldCPP="$CPPFLAGS" 24644 CPPFLAGS="$CPPFLAGS -I${KRB5ROOT}/include/gssapi" 24645 ac_fn_c_check_header_compile "$LINENO" "gssapi_krb5.h" "ac_cv_header_gssapi_krb5_h" "$ac_includes_default" 24646if test "x$ac_cv_header_gssapi_krb5_h" = xyes 24647then : 24648 24649else $as_nop 24650 CPPFLAGS="$oldCPP" 24651fi 24652 24653 24654 fi 24655 fi 24656 if test -n "${rpath_opt}" ; then 24657 LDFLAGS="$LDFLAGS ${rpath_opt}${KRB5ROOT}/lib" 24658 fi 24659 if test ! -z "$blibpath" ; then 24660 blibpath="$blibpath:${KRB5ROOT}/lib" 24661 fi 24662 24663 ac_fn_c_check_header_compile "$LINENO" "gssapi.h" "ac_cv_header_gssapi_h" "$ac_includes_default" 24664if test "x$ac_cv_header_gssapi_h" = xyes 24665then : 24666 printf "%s\n" "#define HAVE_GSSAPI_H 1" >>confdefs.h 24667 24668fi 24669ac_fn_c_check_header_compile "$LINENO" "gssapi/gssapi.h" "ac_cv_header_gssapi_gssapi_h" "$ac_includes_default" 24670if test "x$ac_cv_header_gssapi_gssapi_h" = xyes 24671then : 24672 printf "%s\n" "#define HAVE_GSSAPI_GSSAPI_H 1" >>confdefs.h 24673 24674fi 24675 24676 ac_fn_c_check_header_compile "$LINENO" "gssapi_krb5.h" "ac_cv_header_gssapi_krb5_h" "$ac_includes_default" 24677if test "x$ac_cv_header_gssapi_krb5_h" = xyes 24678then : 24679 printf "%s\n" "#define HAVE_GSSAPI_KRB5_H 1" >>confdefs.h 24680 24681fi 24682ac_fn_c_check_header_compile "$LINENO" "gssapi/gssapi_krb5.h" "ac_cv_header_gssapi_gssapi_krb5_h" "$ac_includes_default" 24683if test "x$ac_cv_header_gssapi_gssapi_krb5_h" = xyes 24684then : 24685 printf "%s\n" "#define HAVE_GSSAPI_GSSAPI_KRB5_H 1" >>confdefs.h 24686 24687fi 24688 24689 ac_fn_c_check_header_compile "$LINENO" "gssapi_generic.h" "ac_cv_header_gssapi_generic_h" "$ac_includes_default" 24690if test "x$ac_cv_header_gssapi_generic_h" = xyes 24691then : 24692 printf "%s\n" "#define HAVE_GSSAPI_GENERIC_H 1" >>confdefs.h 24693 24694fi 24695ac_fn_c_check_header_compile "$LINENO" "gssapi/gssapi_generic.h" "ac_cv_header_gssapi_gssapi_generic_h" "$ac_includes_default" 24696if test "x$ac_cv_header_gssapi_gssapi_generic_h" = xyes 24697then : 24698 printf "%s\n" "#define HAVE_GSSAPI_GSSAPI_GENERIC_H 1" >>confdefs.h 24699 24700fi 24701 24702 24703 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing k_hasafs" >&5 24704printf %s "checking for library containing k_hasafs... " >&6; } 24705if test ${ac_cv_search_k_hasafs+y} 24706then : 24707 printf %s "(cached) " >&6 24708else $as_nop 24709 ac_func_search_save_LIBS=$LIBS 24710cat confdefs.h - <<_ACEOF >conftest.$ac_ext 24711/* end confdefs.h. */ 24712 24713/* Override any GCC internal prototype to avoid an error. 24714 Use char because int might match the return type of a GCC 24715 builtin and then its argument prototype would still apply. */ 24716char k_hasafs (); 24717int 24718main (void) 24719{ 24720return k_hasafs (); 24721 ; 24722 return 0; 24723} 24724_ACEOF 24725for ac_lib in '' kafs 24726do 24727 if test -z "$ac_lib"; then 24728 ac_res="none required" 24729 else 24730 ac_res=-l$ac_lib 24731 LIBS="-l$ac_lib $ac_func_search_save_LIBS" 24732 fi 24733 if ac_fn_c_try_link "$LINENO" 24734then : 24735 ac_cv_search_k_hasafs=$ac_res 24736fi 24737rm -f core conftest.err conftest.$ac_objext conftest.beam \ 24738 conftest$ac_exeext 24739 if test ${ac_cv_search_k_hasafs+y} 24740then : 24741 break 24742fi 24743done 24744if test ${ac_cv_search_k_hasafs+y} 24745then : 24746 24747else $as_nop 24748 ac_cv_search_k_hasafs=no 24749fi 24750rm conftest.$ac_ext 24751LIBS=$ac_func_search_save_LIBS 24752fi 24753{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_k_hasafs" >&5 24754printf "%s\n" "$ac_cv_search_k_hasafs" >&6; } 24755ac_res=$ac_cv_search_k_hasafs 24756if test "$ac_res" != no 24757then : 24758 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" 24759 24760printf "%s\n" "#define USE_AFS 1" >>confdefs.h 24761 24762fi 24763 24764 24765 ac_fn_check_decl "$LINENO" "GSS_C_NT_HOSTBASED_SERVICE" "ac_cv_have_decl_GSS_C_NT_HOSTBASED_SERVICE" " 24766#ifdef HAVE_GSSAPI_H 24767# include <gssapi.h> 24768#elif defined(HAVE_GSSAPI_GSSAPI_H) 24769# include <gssapi/gssapi.h> 24770#endif 24771 24772#ifdef HAVE_GSSAPI_GENERIC_H 24773# include <gssapi_generic.h> 24774#elif defined(HAVE_GSSAPI_GSSAPI_GENERIC_H) 24775# include <gssapi/gssapi_generic.h> 24776#endif 24777 24778" "$ac_c_undeclared_builtin_options" "CFLAGS" 24779if test "x$ac_cv_have_decl_GSS_C_NT_HOSTBASED_SERVICE" = xyes 24780then : 24781 ac_have_decl=1 24782else $as_nop 24783 ac_have_decl=0 24784fi 24785printf "%s\n" "#define HAVE_DECL_GSS_C_NT_HOSTBASED_SERVICE $ac_have_decl" >>confdefs.h 24786 24787 saved_LIBS="$LIBS" 24788 LIBS="$LIBS $K5LIBS" 24789 ac_fn_c_check_func "$LINENO" "krb5_cc_new_unique" "ac_cv_func_krb5_cc_new_unique" 24790if test "x$ac_cv_func_krb5_cc_new_unique" = xyes 24791then : 24792 printf "%s\n" "#define HAVE_KRB5_CC_NEW_UNIQUE 1" >>confdefs.h 24793 24794fi 24795ac_fn_c_check_func "$LINENO" "krb5_get_error_message" "ac_cv_func_krb5_get_error_message" 24796if test "x$ac_cv_func_krb5_get_error_message" = xyes 24797then : 24798 printf "%s\n" "#define HAVE_KRB5_GET_ERROR_MESSAGE 1" >>confdefs.h 24799 24800fi 24801ac_fn_c_check_func "$LINENO" "krb5_free_error_message" "ac_cv_func_krb5_free_error_message" 24802if test "x$ac_cv_func_krb5_free_error_message" = xyes 24803then : 24804 printf "%s\n" "#define HAVE_KRB5_FREE_ERROR_MESSAGE 1" >>confdefs.h 24805 24806fi 24807 24808 LIBS="$saved_LIBS" 24809 24810 fi 24811 24812 24813fi 24814 24815 24816 24817 24818 24819# Looking for programs, paths and files 24820 24821PRIVSEP_PATH=/var/empty 24822 24823# Check whether --with-privsep-path was given. 24824if test ${with_privsep_path+y} 24825then : 24826 withval=$with_privsep_path; 24827 if test -n "$withval" && test "x$withval" != "xno" && \ 24828 test "x${withval}" != "xyes"; then 24829 PRIVSEP_PATH=$withval 24830 fi 24831 24832 24833fi 24834 24835 24836 24837 24838# Check whether --with-xauth was given. 24839if test ${with_xauth+y} 24840then : 24841 withval=$with_xauth; 24842 if test -n "$withval" && test "x$withval" != "xno" && \ 24843 test "x${withval}" != "xyes"; then 24844 xauth_path=$withval 24845 fi 24846 24847else $as_nop 24848 24849 TestPath="$PATH" 24850 TestPath="${TestPath}${PATH_SEPARATOR}/usr/X/bin" 24851 TestPath="${TestPath}${PATH_SEPARATOR}/usr/bin/X11" 24852 TestPath="${TestPath}${PATH_SEPARATOR}/usr/X11R6/bin" 24853 TestPath="${TestPath}${PATH_SEPARATOR}/usr/openwin/bin" 24854 # Extract the first word of "xauth", so it can be a program name with args. 24855set dummy xauth; ac_word=$2 24856{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24857printf %s "checking for $ac_word... " >&6; } 24858if test ${ac_cv_path_xauth_path+y} 24859then : 24860 printf %s "(cached) " >&6 24861else $as_nop 24862 case $xauth_path in 24863 [\\/]* | ?:[\\/]*) 24864 ac_cv_path_xauth_path="$xauth_path" # Let the user override the test with a path. 24865 ;; 24866 *) 24867 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24868for as_dir in $TestPath 24869do 24870 IFS=$as_save_IFS 24871 case $as_dir in #((( 24872 '') as_dir=./ ;; 24873 */) ;; 24874 *) as_dir=$as_dir/ ;; 24875 esac 24876 for ac_exec_ext in '' $ac_executable_extensions; do 24877 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 24878 ac_cv_path_xauth_path="$as_dir$ac_word$ac_exec_ext" 24879 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 24880 break 2 24881 fi 24882done 24883 done 24884IFS=$as_save_IFS 24885 24886 ;; 24887esac 24888fi 24889xauth_path=$ac_cv_path_xauth_path 24890if test -n "$xauth_path"; then 24891 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $xauth_path" >&5 24892printf "%s\n" "$xauth_path" >&6; } 24893else 24894 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 24895printf "%s\n" "no" >&6; } 24896fi 24897 24898 24899 if (test ! -z "$xauth_path" && test -x "/usr/openwin/bin/xauth") ; then 24900 xauth_path="/usr/openwin/bin/xauth" 24901 fi 24902 24903 24904fi 24905 24906 24907STRIP_OPT=-s 24908# Check whether --enable-strip was given. 24909if test ${enable_strip+y} 24910then : 24911 enableval=$enable_strip; 24912 if test "x$enableval" = "xno" ; then 24913 STRIP_OPT= 24914 fi 24915 24916 24917fi 24918 24919 24920 24921if test -z "$xauth_path" ; then 24922 XAUTH_PATH="undefined" 24923 24924else 24925 24926printf "%s\n" "#define XAUTH_PATH \"$xauth_path\"" >>confdefs.h 24927 24928 XAUTH_PATH=$xauth_path 24929 24930fi 24931 24932# Check for mail directory 24933 24934# Check whether --with-maildir was given. 24935if test ${with_maildir+y} 24936then : 24937 withval=$with_maildir; 24938 if test "X$withval" != X && test "x$withval" != xno && \ 24939 test "x${withval}" != xyes; then 24940 24941printf "%s\n" "#define MAIL_DIRECTORY \"$withval\"" >>confdefs.h 24942 24943 fi 24944 24945else $as_nop 24946 24947 if test "X$maildir" != "X"; then 24948 printf "%s\n" "#define MAIL_DIRECTORY \"$maildir\"" >>confdefs.h 24949 24950 else 24951 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking Discovering system mail directory" >&5 24952printf %s "checking Discovering system mail directory... " >&6; } 24953 if test "$cross_compiling" = yes 24954then : 24955 24956 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: use --with-maildir=/path/to/mail" >&5 24957printf "%s\n" "$as_me: WARNING: cross compiling: use --with-maildir=/path/to/mail" >&2;} 24958 24959 24960else $as_nop 24961 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 24962/* end confdefs.h. */ 24963 24964#include <stdio.h> 24965#include <stdlib.h> 24966#include <string.h> 24967#ifdef HAVE_PATHS_H 24968#include <paths.h> 24969#endif 24970#ifdef HAVE_MAILLOCK_H 24971#include <maillock.h> 24972#endif 24973#define DATA "conftest.maildir" 24974 24975int 24976main (void) 24977{ 24978 24979 FILE *fd; 24980 int rc; 24981 24982 fd = fopen(DATA,"w"); 24983 if(fd == NULL) 24984 exit(1); 24985 24986#if defined (_PATH_MAILDIR) 24987 if ((rc = fprintf(fd ,"_PATH_MAILDIR:%s\n", _PATH_MAILDIR)) <0) 24988 exit(1); 24989#elif defined (MAILDIR) 24990 if ((rc = fprintf(fd ,"MAILDIR:%s\n", MAILDIR)) <0) 24991 exit(1); 24992#elif defined (_PATH_MAIL) 24993 if ((rc = fprintf(fd ,"_PATH_MAIL:%s\n", _PATH_MAIL)) <0) 24994 exit(1); 24995#else 24996 exit (2); 24997#endif 24998 24999 exit(0); 25000 25001 ; 25002 return 0; 25003} 25004_ACEOF 25005if ac_fn_c_try_run "$LINENO" 25006then : 25007 25008 maildir_what=`awk -F: '{print $1}' conftest.maildir` 25009 maildir=`awk -F: '{print $2}' conftest.maildir \ 25010 | sed 's|/$||'` 25011 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Using: $maildir from $maildir_what" >&5 25012printf "%s\n" "Using: $maildir from $maildir_what" >&6; } 25013 if test "x$maildir_what" != "x_PATH_MAILDIR"; then 25014 printf "%s\n" "#define MAIL_DIRECTORY \"$maildir\"" >>confdefs.h 25015 25016 fi 25017 25018else $as_nop 25019 25020 if test "X$ac_status" = "X2";then 25021# our test program didn't find it. Default to /var/spool/mail 25022 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Using: default value of /var/spool/mail" >&5 25023printf "%s\n" "Using: default value of /var/spool/mail" >&6; } 25024 printf "%s\n" "#define MAIL_DIRECTORY \"/var/spool/mail\"" >>confdefs.h 25025 25026 else 25027 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: *** not found ***" >&5 25028printf "%s\n" "*** not found ***" >&6; } 25029 fi 25030 25031fi 25032rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 25033 conftest.$ac_objext conftest.beam conftest.$ac_ext 25034fi 25035 25036 fi 25037 25038 25039fi 25040 # maildir 25041 25042if test ! -z "$cross_compiling" && test "x$cross_compiling" = "xyes"; then 25043 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: Disabling /dev/ptmx test" >&5 25044printf "%s\n" "$as_me: WARNING: cross compiling: Disabling /dev/ptmx test" >&2;} 25045 disable_ptmx_check=yes 25046fi 25047if test -z "$no_dev_ptmx" ; then 25048 if test "x$disable_ptmx_check" != "xyes" ; then 25049 as_ac_File=`printf "%s\n" "ac_cv_file_"/dev/ptmx"" | $as_tr_sh` 25050{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for \"/dev/ptmx\"" >&5 25051printf %s "checking for \"/dev/ptmx\"... " >&6; } 25052if eval test \${$as_ac_File+y} 25053then : 25054 printf %s "(cached) " >&6 25055else $as_nop 25056 test "$cross_compiling" = yes && 25057 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5 25058if test -r ""/dev/ptmx""; then 25059 eval "$as_ac_File=yes" 25060else 25061 eval "$as_ac_File=no" 25062fi 25063fi 25064eval ac_res=\$$as_ac_File 25065 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 25066printf "%s\n" "$ac_res" >&6; } 25067if eval test \"x\$"$as_ac_File"\" = x"yes" 25068then : 25069 25070 25071printf "%s\n" "#define HAVE_DEV_PTMX 1" >>confdefs.h 25072 25073 have_dev_ptmx=1 25074 25075 25076fi 25077 25078 fi 25079fi 25080 25081if test ! -z "$cross_compiling" && test "x$cross_compiling" != "xyes"; then 25082 as_ac_File=`printf "%s\n" "ac_cv_file_"/dev/ptc"" | $as_tr_sh` 25083{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for \"/dev/ptc\"" >&5 25084printf %s "checking for \"/dev/ptc\"... " >&6; } 25085if eval test \${$as_ac_File+y} 25086then : 25087 printf %s "(cached) " >&6 25088else $as_nop 25089 test "$cross_compiling" = yes && 25090 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5 25091if test -r ""/dev/ptc""; then 25092 eval "$as_ac_File=yes" 25093else 25094 eval "$as_ac_File=no" 25095fi 25096fi 25097eval ac_res=\$$as_ac_File 25098 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 25099printf "%s\n" "$ac_res" >&6; } 25100if eval test \"x\$"$as_ac_File"\" = x"yes" 25101then : 25102 25103 25104printf "%s\n" "#define HAVE_DEV_PTS_AND_PTC 1" >>confdefs.h 25105 25106 have_dev_ptc=1 25107 25108 25109fi 25110 25111else 25112 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: Disabling /dev/ptc test" >&5 25113printf "%s\n" "$as_me: WARNING: cross compiling: Disabling /dev/ptc test" >&2;} 25114fi 25115 25116# Options from here on. Some of these are preset by platform above 25117 25118# Check whether --with-mantype was given. 25119if test ${with_mantype+y} 25120then : 25121 withval=$with_mantype; 25122 case "$withval" in 25123 man|cat|doc) 25124 MANTYPE=$withval 25125 ;; 25126 *) 25127 as_fn_error $? "invalid man type: $withval" "$LINENO" 5 25128 ;; 25129 esac 25130 25131 25132fi 25133 25134if test -z "$MANTYPE"; then 25135 if ${MANDOC} ${srcdir}/ssh.1 >/dev/null 2>&1; then 25136 MANTYPE=doc 25137 elif ${NROFF} -mdoc ${srcdir}/ssh.1 >/dev/null 2>&1; then 25138 MANTYPE=doc 25139 elif ${NROFF} -man ${srcdir}/ssh.1 >/dev/null 2>&1; then 25140 MANTYPE=man 25141 else 25142 MANTYPE=cat 25143 fi 25144fi 25145 25146if test "$MANTYPE" = "doc"; then 25147 mansubdir=man; 25148else 25149 mansubdir=$MANTYPE; 25150fi 25151 25152 25153# Whether to disable shadow password support 25154 25155# Check whether --with-shadow was given. 25156if test ${with_shadow+y} 25157then : 25158 withval=$with_shadow; 25159 if test "x$withval" = "xno" ; then 25160 printf "%s\n" "#define DISABLE_SHADOW 1" >>confdefs.h 25161 25162 disable_shadow=yes 25163 fi 25164 25165 25166fi 25167 25168 25169if test -z "$disable_shadow" ; then 25170 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if the systems has expire shadow information" >&5 25171printf %s "checking if the systems has expire shadow information... " >&6; } 25172 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 25173/* end confdefs.h. */ 25174 25175#include <sys/types.h> 25176#include <shadow.h> 25177struct spwd sp; 25178 25179int 25180main (void) 25181{ 25182 sp.sp_expire = sp.sp_lstchg = sp.sp_inact = 0; 25183 ; 25184 return 0; 25185} 25186_ACEOF 25187if ac_fn_c_try_compile "$LINENO" 25188then : 25189 sp_expire_available=yes 25190fi 25191rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 25192 25193 if test "x$sp_expire_available" = "xyes" ; then 25194 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 25195printf "%s\n" "yes" >&6; } 25196 25197printf "%s\n" "#define HAS_SHADOW_EXPIRE 1" >>confdefs.h 25198 25199 else 25200 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 25201printf "%s\n" "no" >&6; } 25202 fi 25203fi 25204 25205# Use ip address instead of hostname in $DISPLAY 25206if test ! -z "$IPADDR_IN_DISPLAY" ; then 25207 DISPLAY_HACK_MSG="yes" 25208 25209printf "%s\n" "#define IPADDR_IN_DISPLAY 1" >>confdefs.h 25210 25211else 25212 DISPLAY_HACK_MSG="no" 25213 25214# Check whether --with-ipaddr-display was given. 25215if test ${with_ipaddr_display+y} 25216then : 25217 withval=$with_ipaddr_display; 25218 if test "x$withval" != "xno" ; then 25219 printf "%s\n" "#define IPADDR_IN_DISPLAY 1" >>confdefs.h 25220 25221 DISPLAY_HACK_MSG="yes" 25222 fi 25223 25224 25225fi 25226 25227fi 25228 25229# check for /etc/default/login and use it if present. 25230# Check whether --enable-etc-default-login was given. 25231if test ${enable_etc_default_login+y} 25232then : 25233 enableval=$enable_etc_default_login; if test "x$enableval" = "xno"; then 25234 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: /etc/default/login handling disabled" >&5 25235printf "%s\n" "$as_me: /etc/default/login handling disabled" >&6;} 25236 etc_default_login=no 25237 else 25238 etc_default_login=yes 25239 fi 25240else $as_nop 25241 if test ! -z "$cross_compiling" && test "x$cross_compiling" = "xyes"; 25242 then 25243 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: not checking /etc/default/login" >&5 25244printf "%s\n" "$as_me: WARNING: cross compiling: not checking /etc/default/login" >&2;} 25245 etc_default_login=no 25246 else 25247 etc_default_login=yes 25248 fi 25249 25250fi 25251 25252 25253if test "x$etc_default_login" != "xno"; then 25254 as_ac_File=`printf "%s\n" "ac_cv_file_"/etc/default/login"" | $as_tr_sh` 25255{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for \"/etc/default/login\"" >&5 25256printf %s "checking for \"/etc/default/login\"... " >&6; } 25257if eval test \${$as_ac_File+y} 25258then : 25259 printf %s "(cached) " >&6 25260else $as_nop 25261 test "$cross_compiling" = yes && 25262 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5 25263if test -r ""/etc/default/login""; then 25264 eval "$as_ac_File=yes" 25265else 25266 eval "$as_ac_File=no" 25267fi 25268fi 25269eval ac_res=\$$as_ac_File 25270 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 25271printf "%s\n" "$ac_res" >&6; } 25272if eval test \"x\$"$as_ac_File"\" = x"yes" 25273then : 25274 external_path_file=/etc/default/login 25275fi 25276 25277 if test "x$external_path_file" = "x/etc/default/login"; then 25278 25279printf "%s\n" "#define HAVE_ETC_DEFAULT_LOGIN 1" >>confdefs.h 25280 25281 fi 25282fi 25283 25284if test $ac_cv_func_login_getcapbool = "yes" && \ 25285 test $ac_cv_header_login_cap_h = "yes" ; then 25286 external_path_file=/etc/login.conf 25287fi 25288 25289# Whether to mess with the default path 25290SERVER_PATH_MSG="(default)" 25291 25292# Check whether --with-default-path was given. 25293if test ${with_default_path+y} 25294then : 25295 withval=$with_default_path; 25296 if test "x$external_path_file" = "x/etc/login.conf" ; then 25297 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: 25298--with-default-path=PATH has no effect on this system. 25299Edit /etc/login.conf instead." >&5 25300printf "%s\n" "$as_me: WARNING: 25301--with-default-path=PATH has no effect on this system. 25302Edit /etc/login.conf instead." >&2;} 25303 elif test "x$withval" != "xno" ; then 25304 if test ! -z "$external_path_file" ; then 25305 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: 25306--with-default-path=PATH will only be used if PATH is not defined in 25307$external_path_file ." >&5 25308printf "%s\n" "$as_me: WARNING: 25309--with-default-path=PATH will only be used if PATH is not defined in 25310$external_path_file ." >&2;} 25311 fi 25312 user_path="$withval" 25313 SERVER_PATH_MSG="$withval" 25314 fi 25315 25316else $as_nop 25317 if test "x$external_path_file" = "x/etc/login.conf" ; then 25318 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Make sure the path to scp is in /etc/login.conf" >&5 25319printf "%s\n" "$as_me: WARNING: Make sure the path to scp is in /etc/login.conf" >&2;} 25320 else 25321 if test ! -z "$external_path_file" ; then 25322 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: 25323If PATH is defined in $external_path_file, ensure the path to scp is included, 25324otherwise scp will not work." >&5 25325printf "%s\n" "$as_me: WARNING: 25326If PATH is defined in $external_path_file, ensure the path to scp is included, 25327otherwise scp will not work." >&2;} 25328 fi 25329 if test "$cross_compiling" = yes 25330then : 25331 user_path="/usr/bin:/bin:/usr/sbin:/sbin" 25332 25333else $as_nop 25334 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 25335/* end confdefs.h. */ 25336 25337/* find out what STDPATH is */ 25338#include <stdio.h> 25339#include <stdlib.h> 25340#ifdef HAVE_PATHS_H 25341# include <paths.h> 25342#endif 25343#ifndef _PATH_STDPATH 25344# ifdef _PATH_USERPATH /* Irix */ 25345# define _PATH_STDPATH _PATH_USERPATH 25346# else 25347# define _PATH_STDPATH "/usr/bin:/bin:/usr/sbin:/sbin" 25348# endif 25349#endif 25350#include <sys/types.h> 25351#include <sys/stat.h> 25352#include <fcntl.h> 25353#define DATA "conftest.stdpath" 25354 25355int 25356main (void) 25357{ 25358 25359 FILE *fd; 25360 int rc; 25361 25362 fd = fopen(DATA,"w"); 25363 if(fd == NULL) 25364 exit(1); 25365 25366 if ((rc = fprintf(fd,"%s", _PATH_STDPATH)) < 0) 25367 exit(1); 25368 25369 exit(0); 25370 25371 ; 25372 return 0; 25373} 25374_ACEOF 25375if ac_fn_c_try_run "$LINENO" 25376then : 25377 user_path=`cat conftest.stdpath` 25378else $as_nop 25379 user_path="/usr/bin:/bin:/usr/sbin:/sbin" 25380fi 25381rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 25382 conftest.$ac_objext conftest.beam conftest.$ac_ext 25383fi 25384 25385# make sure $bindir is in USER_PATH so scp will work 25386 t_bindir="${bindir}" 25387 while echo "${t_bindir}" | egrep '\$\{|NONE/' >/dev/null 2>&1; do 25388 t_bindir=`eval echo ${t_bindir}` 25389 case $t_bindir in 25390 NONE/*) t_bindir=`echo $t_bindir | sed "s~NONE~$prefix~"` ;; 25391 esac 25392 case $t_bindir in 25393 NONE/*) t_bindir=`echo $t_bindir | sed "s~NONE~$ac_default_prefix~"` ;; 25394 esac 25395 done 25396 echo $user_path | grep ":$t_bindir" > /dev/null 2>&1 25397 if test $? -ne 0 ; then 25398 echo $user_path | grep "^$t_bindir" > /dev/null 2>&1 25399 if test $? -ne 0 ; then 25400 user_path=$user_path:$t_bindir 25401 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: Adding $t_bindir to USER_PATH so scp will work" >&5 25402printf "%s\n" "Adding $t_bindir to USER_PATH so scp will work" >&6; } 25403 fi 25404 fi 25405 fi 25406 25407fi 25408 25409if test "x$external_path_file" != "x/etc/login.conf" ; then 25410 25411printf "%s\n" "#define USER_PATH \"$user_path\"" >>confdefs.h 25412 25413 25414fi 25415 25416# Set superuser path separately to user path 25417 25418# Check whether --with-superuser-path was given. 25419if test ${with_superuser_path+y} 25420then : 25421 withval=$with_superuser_path; 25422 if test -n "$withval" && test "x$withval" != "xno" && \ 25423 test "x${withval}" != "xyes"; then 25424 25425printf "%s\n" "#define SUPERUSER_PATH \"$withval\"" >>confdefs.h 25426 25427 superuser_path=$withval 25428 fi 25429 25430 25431fi 25432 25433 25434 25435{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if we need to convert IPv4 in IPv6-mapped addresses" >&5 25436printf %s "checking if we need to convert IPv4 in IPv6-mapped addresses... " >&6; } 25437IPV4_IN6_HACK_MSG="no" 25438 25439# Check whether --with-4in6 was given. 25440if test ${with_4in6+y} 25441then : 25442 withval=$with_4in6; 25443 if test "x$withval" != "xno" ; then 25444 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 25445printf "%s\n" "yes" >&6; } 25446 25447printf "%s\n" "#define IPV4_IN_IPV6 1" >>confdefs.h 25448 25449 IPV4_IN6_HACK_MSG="yes" 25450 else 25451 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 25452printf "%s\n" "no" >&6; } 25453 fi 25454 25455else $as_nop 25456 25457 if test "x$inet6_default_4in6" = "xyes"; then 25458 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes (default)" >&5 25459printf "%s\n" "yes (default)" >&6; } 25460 printf "%s\n" "#define IPV4_IN_IPV6 1" >>confdefs.h 25461 25462 IPV4_IN6_HACK_MSG="yes" 25463 else 25464 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no (default)" >&5 25465printf "%s\n" "no (default)" >&6; } 25466 fi 25467 25468 25469fi 25470 25471 25472# Whether to enable BSD auth support 25473BSD_AUTH_MSG=no 25474 25475# Check whether --with-bsd-auth was given. 25476if test ${with_bsd_auth+y} 25477then : 25478 withval=$with_bsd_auth; 25479 if test "x$withval" != "xno" ; then 25480 25481printf "%s\n" "#define BSD_AUTH 1" >>confdefs.h 25482 25483 BSD_AUTH_MSG=yes 25484 fi 25485 25486 25487fi 25488 25489 25490# Where to place sshd.pid 25491piddir=/var/run 25492# make sure the directory exists 25493if test ! -d $piddir ; then 25494 piddir=`eval echo ${sysconfdir}` 25495 case $piddir in 25496 NONE/*) piddir=`echo $piddir | sed "s~NONE~$ac_default_prefix~"` ;; 25497 esac 25498fi 25499 25500 25501# Check whether --with-pid-dir was given. 25502if test ${with_pid_dir+y} 25503then : 25504 withval=$with_pid_dir; 25505 if test -n "$withval" && test "x$withval" != "xno" && \ 25506 test "x${withval}" != "xyes"; then 25507 piddir=$withval 25508 if test ! -d $piddir ; then 25509 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: ** no $piddir directory on this system **" >&5 25510printf "%s\n" "$as_me: WARNING: ** no $piddir directory on this system **" >&2;} 25511 fi 25512 fi 25513 25514 25515fi 25516 25517 25518 25519printf "%s\n" "#define _PATH_SSH_PIDDIR \"$piddir\"" >>confdefs.h 25520 25521 25522 25523 25524# Check whether --enable-fd-passing was given. 25525if test ${enable_fd_passing+y} 25526then : 25527 enableval=$enable_fd_passing; 25528 if test "x$enableval" = "xno" ; then 25529 printf "%s\n" "#define DISABLE_FD_PASSING 1" >>confdefs.h 25530 25531 fi 25532 25533 25534fi 25535 25536 25537# Check whether --enable-lastlog was given. 25538if test ${enable_lastlog+y} 25539then : 25540 enableval=$enable_lastlog; 25541 if test "x$enableval" = "xno" ; then 25542 printf "%s\n" "#define DISABLE_LASTLOG 1" >>confdefs.h 25543 25544 fi 25545 25546 25547fi 25548 25549# Check whether --enable-utmp was given. 25550if test ${enable_utmp+y} 25551then : 25552 enableval=$enable_utmp; 25553 if test "x$enableval" = "xno" ; then 25554 printf "%s\n" "#define DISABLE_UTMP 1" >>confdefs.h 25555 25556 fi 25557 25558 25559fi 25560 25561# Check whether --enable-utmpx was given. 25562if test ${enable_utmpx+y} 25563then : 25564 enableval=$enable_utmpx; 25565 if test "x$enableval" = "xno" ; then 25566 25567printf "%s\n" "#define DISABLE_UTMPX 1" >>confdefs.h 25568 25569 fi 25570 25571 25572fi 25573 25574# Check whether --enable-wtmp was given. 25575if test ${enable_wtmp+y} 25576then : 25577 enableval=$enable_wtmp; 25578 if test "x$enableval" = "xno" ; then 25579 printf "%s\n" "#define DISABLE_WTMP 1" >>confdefs.h 25580 25581 fi 25582 25583 25584fi 25585 25586# Check whether --enable-wtmpx was given. 25587if test ${enable_wtmpx+y} 25588then : 25589 enableval=$enable_wtmpx; 25590 if test "x$enableval" = "xno" ; then 25591 25592printf "%s\n" "#define DISABLE_WTMPX 1" >>confdefs.h 25593 25594 fi 25595 25596 25597fi 25598 25599# Check whether --enable-libutil was given. 25600if test ${enable_libutil+y} 25601then : 25602 enableval=$enable_libutil; 25603 if test "x$enableval" = "xno" ; then 25604 printf "%s\n" "#define DISABLE_LOGIN 1" >>confdefs.h 25605 25606 fi 25607 25608 25609fi 25610 25611# Check whether --enable-pututline was given. 25612if test ${enable_pututline+y} 25613then : 25614 enableval=$enable_pututline; 25615 if test "x$enableval" = "xno" ; then 25616 25617printf "%s\n" "#define DISABLE_PUTUTLINE 1" >>confdefs.h 25618 25619 fi 25620 25621 25622fi 25623 25624# Check whether --enable-pututxline was given. 25625if test ${enable_pututxline+y} 25626then : 25627 enableval=$enable_pututxline; 25628 if test "x$enableval" = "xno" ; then 25629 25630printf "%s\n" "#define DISABLE_PUTUTXLINE 1" >>confdefs.h 25631 25632 fi 25633 25634 25635fi 25636 25637 25638# Check whether --with-lastlog was given. 25639if test ${with_lastlog+y} 25640then : 25641 withval=$with_lastlog; 25642 if test "x$withval" = "xno" ; then 25643 printf "%s\n" "#define DISABLE_LASTLOG 1" >>confdefs.h 25644 25645 elif test -n "$withval" && test "x${withval}" != "xyes"; then 25646 conf_lastlog_location=$withval 25647 fi 25648 25649 25650fi 25651 25652 25653 25654{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if your system defines LASTLOG_FILE" >&5 25655printf %s "checking if your system defines LASTLOG_FILE... " >&6; } 25656cat confdefs.h - <<_ACEOF >conftest.$ac_ext 25657/* end confdefs.h. */ 25658 25659#include <sys/types.h> 25660#include <utmp.h> 25661#ifdef HAVE_LASTLOG_H 25662# include <lastlog.h> 25663#endif 25664#ifdef HAVE_PATHS_H 25665# include <paths.h> 25666#endif 25667#ifdef HAVE_LOGIN_H 25668# include <login.h> 25669#endif 25670 25671int 25672main (void) 25673{ 25674 char *lastlog = LASTLOG_FILE; 25675 ; 25676 return 0; 25677} 25678_ACEOF 25679if ac_fn_c_try_compile "$LINENO" 25680then : 25681 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 25682printf "%s\n" "yes" >&6; } 25683else $as_nop 25684 25685 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 25686printf "%s\n" "no" >&6; } 25687 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if your system defines _PATH_LASTLOG" >&5 25688printf %s "checking if your system defines _PATH_LASTLOG... " >&6; } 25689 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 25690/* end confdefs.h. */ 25691 25692#include <sys/types.h> 25693#include <utmp.h> 25694#ifdef HAVE_LASTLOG_H 25695# include <lastlog.h> 25696#endif 25697#ifdef HAVE_PATHS_H 25698# include <paths.h> 25699#endif 25700 25701int 25702main (void) 25703{ 25704 char *lastlog = _PATH_LASTLOG; 25705 ; 25706 return 0; 25707} 25708_ACEOF 25709if ac_fn_c_try_compile "$LINENO" 25710then : 25711 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 25712printf "%s\n" "yes" >&6; } 25713else $as_nop 25714 25715 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 25716printf "%s\n" "no" >&6; } 25717 system_lastlog_path=no 25718 25719fi 25720rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 25721 25722fi 25723rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 25724 25725if test -z "$conf_lastlog_location"; then 25726 if test x"$system_lastlog_path" = x"no" ; then 25727 for f in /var/log/lastlog /usr/adm/lastlog /var/adm/lastlog /etc/security/lastlog ; do 25728 if (test -d "$f" || test -f "$f") ; then 25729 conf_lastlog_location=$f 25730 fi 25731 done 25732 if test -z "$conf_lastlog_location"; then 25733 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: ** Cannot find lastlog **" >&5 25734printf "%s\n" "$as_me: WARNING: ** Cannot find lastlog **" >&2;} 25735 fi 25736 fi 25737fi 25738 25739if test -n "$conf_lastlog_location"; then 25740 25741printf "%s\n" "#define CONF_LASTLOG_FILE \"$conf_lastlog_location\"" >>confdefs.h 25742 25743fi 25744 25745{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if your system defines UTMP_FILE" >&5 25746printf %s "checking if your system defines UTMP_FILE... " >&6; } 25747cat confdefs.h - <<_ACEOF >conftest.$ac_ext 25748/* end confdefs.h. */ 25749 25750#include <sys/types.h> 25751#include <utmp.h> 25752#ifdef HAVE_PATHS_H 25753# include <paths.h> 25754#endif 25755 25756int 25757main (void) 25758{ 25759 char *utmp = UTMP_FILE; 25760 ; 25761 return 0; 25762} 25763_ACEOF 25764if ac_fn_c_try_compile "$LINENO" 25765then : 25766 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 25767printf "%s\n" "yes" >&6; } 25768else $as_nop 25769 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 25770printf "%s\n" "no" >&6; } 25771 system_utmp_path=no 25772 25773fi 25774rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 25775if test -z "$conf_utmp_location"; then 25776 if test x"$system_utmp_path" = x"no" ; then 25777 for f in /etc/utmp /usr/adm/utmp /var/run/utmp; do 25778 if test -f $f ; then 25779 conf_utmp_location=$f 25780 fi 25781 done 25782 if test -z "$conf_utmp_location"; then 25783 printf "%s\n" "#define DISABLE_UTMP 1" >>confdefs.h 25784 25785 fi 25786 fi 25787fi 25788if test -n "$conf_utmp_location"; then 25789 25790printf "%s\n" "#define CONF_UTMP_FILE \"$conf_utmp_location\"" >>confdefs.h 25791 25792fi 25793 25794{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if your system defines WTMP_FILE" >&5 25795printf %s "checking if your system defines WTMP_FILE... " >&6; } 25796cat confdefs.h - <<_ACEOF >conftest.$ac_ext 25797/* end confdefs.h. */ 25798 25799#include <sys/types.h> 25800#include <utmp.h> 25801#ifdef HAVE_PATHS_H 25802# include <paths.h> 25803#endif 25804 25805int 25806main (void) 25807{ 25808 char *wtmp = WTMP_FILE; 25809 ; 25810 return 0; 25811} 25812_ACEOF 25813if ac_fn_c_try_compile "$LINENO" 25814then : 25815 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 25816printf "%s\n" "yes" >&6; } 25817else $as_nop 25818 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 25819printf "%s\n" "no" >&6; } 25820 system_wtmp_path=no 25821 25822fi 25823rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 25824if test -z "$conf_wtmp_location"; then 25825 if test x"$system_wtmp_path" = x"no" ; then 25826 for f in /usr/adm/wtmp /var/log/wtmp; do 25827 if test -f $f ; then 25828 conf_wtmp_location=$f 25829 fi 25830 done 25831 if test -z "$conf_wtmp_location"; then 25832 printf "%s\n" "#define DISABLE_WTMP 1" >>confdefs.h 25833 25834 fi 25835 fi 25836fi 25837if test -n "$conf_wtmp_location"; then 25838 25839printf "%s\n" "#define CONF_WTMP_FILE \"$conf_wtmp_location\"" >>confdefs.h 25840 25841fi 25842 25843{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if your system defines WTMPX_FILE" >&5 25844printf %s "checking if your system defines WTMPX_FILE... " >&6; } 25845cat confdefs.h - <<_ACEOF >conftest.$ac_ext 25846/* end confdefs.h. */ 25847 25848#include <sys/types.h> 25849#include <utmp.h> 25850#ifdef HAVE_UTMPX_H 25851#include <utmpx.h> 25852#endif 25853#ifdef HAVE_PATHS_H 25854# include <paths.h> 25855#endif 25856 25857int 25858main (void) 25859{ 25860 char *wtmpx = WTMPX_FILE; 25861 ; 25862 return 0; 25863} 25864_ACEOF 25865if ac_fn_c_try_compile "$LINENO" 25866then : 25867 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5 25868printf "%s\n" "yes" >&6; } 25869else $as_nop 25870 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 25871printf "%s\n" "no" >&6; } 25872 system_wtmpx_path=no 25873 25874fi 25875rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext 25876if test -z "$conf_wtmpx_location"; then 25877 if test x"$system_wtmpx_path" = x"no" ; then 25878 printf "%s\n" "#define DISABLE_WTMPX 1" >>confdefs.h 25879 25880 fi 25881else 25882 25883printf "%s\n" "#define CONF_WTMPX_FILE \"$conf_wtmpx_location\"" >>confdefs.h 25884 25885fi 25886 25887 25888if test ! -z "$blibpath" ; then 25889 LDFLAGS="$LDFLAGS $blibflags$blibpath" 25890 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Please check and edit blibpath in LDFLAGS in Makefile" >&5 25891printf "%s\n" "$as_me: WARNING: Please check and edit blibpath in LDFLAGS in Makefile" >&2;} 25892fi 25893 25894ac_fn_c_check_member "$LINENO" "struct lastlog" "ll_line" "ac_cv_member_struct_lastlog_ll_line" " 25895#ifdef HAVE_SYS_TYPES_H 25896#include <sys/types.h> 25897#endif 25898#ifdef HAVE_UTMP_H 25899#include <utmp.h> 25900#endif 25901#ifdef HAVE_UTMPX_H 25902#include <utmpx.h> 25903#endif 25904#ifdef HAVE_LASTLOG_H 25905#include <lastlog.h> 25906#endif 25907 25908" 25909if test "x$ac_cv_member_struct_lastlog_ll_line" = xyes 25910then : 25911 25912else $as_nop 25913 25914 if test x$SKIP_DISABLE_LASTLOG_DEFINE != "xyes" ; then 25915 printf "%s\n" "#define DISABLE_LASTLOG 1" >>confdefs.h 25916 25917 fi 25918 25919fi 25920 25921 25922ac_fn_c_check_member "$LINENO" "struct utmp" "ut_line" "ac_cv_member_struct_utmp_ut_line" " 25923#ifdef HAVE_SYS_TYPES_H 25924#include <sys/types.h> 25925#endif 25926#ifdef HAVE_UTMP_H 25927#include <utmp.h> 25928#endif 25929#ifdef HAVE_UTMPX_H 25930#include <utmpx.h> 25931#endif 25932#ifdef HAVE_LASTLOG_H 25933#include <lastlog.h> 25934#endif 25935 25936" 25937if test "x$ac_cv_member_struct_utmp_ut_line" = xyes 25938then : 25939 25940else $as_nop 25941 25942 printf "%s\n" "#define DISABLE_UTMP 1" >>confdefs.h 25943 25944 printf "%s\n" "#define DISABLE_WTMP 1" >>confdefs.h 25945 25946 25947fi 25948 25949 25950CFLAGS="$CFLAGS $werror_flags" 25951 25952if test "x$ac_cv_func_getaddrinfo" != "xyes" ; then 25953 TEST_SSH_IPV6=no 25954else 25955 TEST_SSH_IPV6=yes 25956fi 25957ac_fn_check_decl "$LINENO" "BROKEN_GETADDRINFO" "ac_cv_have_decl_BROKEN_GETADDRINFO" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS" 25958if test "x$ac_cv_have_decl_BROKEN_GETADDRINFO" = xyes 25959then : 25960 TEST_SSH_IPV6=no 25961fi 25962TEST_SSH_IPV6=$TEST_SSH_IPV6 25963 25964TEST_SSH_UTF8=$TEST_SSH_UTF8 25965 25966TEST_MALLOC_OPTIONS=$TEST_MALLOC_OPTIONS 25967 25968UNSUPPORTED_ALGORITHMS=$unsupported_algorithms 25969 25970DEPEND=$(cat $srcdir/.depend) 25971 25972 25973# Binaries for interop tests. 25974# Extract the first word of "plink", so it can be a program name with args. 25975set dummy plink; ac_word=$2 25976{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 25977printf %s "checking for $ac_word... " >&6; } 25978if test ${ac_cv_path_PLINK+y} 25979then : 25980 printf %s "(cached) " >&6 25981else $as_nop 25982 case $PLINK in 25983 [\\/]* | ?:[\\/]*) 25984 ac_cv_path_PLINK="$PLINK" # Let the user override the test with a path. 25985 ;; 25986 *) 25987 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 25988for as_dir in $PATH 25989do 25990 IFS=$as_save_IFS 25991 case $as_dir in #((( 25992 '') as_dir=./ ;; 25993 */) ;; 25994 *) as_dir=$as_dir/ ;; 25995 esac 25996 for ac_exec_ext in '' $ac_executable_extensions; do 25997 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 25998 ac_cv_path_PLINK="$as_dir$ac_word$ac_exec_ext" 25999 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 26000 break 2 26001 fi 26002done 26003 done 26004IFS=$as_save_IFS 26005 26006 ;; 26007esac 26008fi 26009PLINK=$ac_cv_path_PLINK 26010if test -n "$PLINK"; then 26011 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PLINK" >&5 26012printf "%s\n" "$PLINK" >&6; } 26013else 26014 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 26015printf "%s\n" "no" >&6; } 26016fi 26017 26018 26019# Extract the first word of "puttygen", so it can be a program name with args. 26020set dummy puttygen; ac_word=$2 26021{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 26022printf %s "checking for $ac_word... " >&6; } 26023if test ${ac_cv_path_PUTTYGEN+y} 26024then : 26025 printf %s "(cached) " >&6 26026else $as_nop 26027 case $PUTTYGEN in 26028 [\\/]* | ?:[\\/]*) 26029 ac_cv_path_PUTTYGEN="$PUTTYGEN" # Let the user override the test with a path. 26030 ;; 26031 *) 26032 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 26033for as_dir in $PATH 26034do 26035 IFS=$as_save_IFS 26036 case $as_dir in #((( 26037 '') as_dir=./ ;; 26038 */) ;; 26039 *) as_dir=$as_dir/ ;; 26040 esac 26041 for ac_exec_ext in '' $ac_executable_extensions; do 26042 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 26043 ac_cv_path_PUTTYGEN="$as_dir$ac_word$ac_exec_ext" 26044 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 26045 break 2 26046 fi 26047done 26048 done 26049IFS=$as_save_IFS 26050 26051 ;; 26052esac 26053fi 26054PUTTYGEN=$ac_cv_path_PUTTYGEN 26055if test -n "$PUTTYGEN"; then 26056 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PUTTYGEN" >&5 26057printf "%s\n" "$PUTTYGEN" >&6; } 26058else 26059 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 26060printf "%s\n" "no" >&6; } 26061fi 26062 26063 26064# Extract the first word of "conch", so it can be a program name with args. 26065set dummy conch; ac_word=$2 26066{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 26067printf %s "checking for $ac_word... " >&6; } 26068if test ${ac_cv_path_CONCH+y} 26069then : 26070 printf %s "(cached) " >&6 26071else $as_nop 26072 case $CONCH in 26073 [\\/]* | ?:[\\/]*) 26074 ac_cv_path_CONCH="$CONCH" # Let the user override the test with a path. 26075 ;; 26076 *) 26077 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 26078for as_dir in $PATH 26079do 26080 IFS=$as_save_IFS 26081 case $as_dir in #((( 26082 '') as_dir=./ ;; 26083 */) ;; 26084 *) as_dir=$as_dir/ ;; 26085 esac 26086 for ac_exec_ext in '' $ac_executable_extensions; do 26087 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 26088 ac_cv_path_CONCH="$as_dir$ac_word$ac_exec_ext" 26089 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 26090 break 2 26091 fi 26092done 26093 done 26094IFS=$as_save_IFS 26095 26096 ;; 26097esac 26098fi 26099CONCH=$ac_cv_path_CONCH 26100if test -n "$CONCH"; then 26101 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CONCH" >&5 26102printf "%s\n" "$CONCH" >&6; } 26103else 26104 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 26105printf "%s\n" "no" >&6; } 26106fi 26107 26108 26109# Extract the first word of "dropbear", so it can be a program name with args. 26110set dummy dropbear; ac_word=$2 26111{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 26112printf %s "checking for $ac_word... " >&6; } 26113if test ${ac_cv_path_DROPBEAR+y} 26114then : 26115 printf %s "(cached) " >&6 26116else $as_nop 26117 case $DROPBEAR in 26118 [\\/]* | ?:[\\/]*) 26119 ac_cv_path_DROPBEAR="$DROPBEAR" # Let the user override the test with a path. 26120 ;; 26121 *) 26122 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 26123for as_dir in $PATH 26124do 26125 IFS=$as_save_IFS 26126 case $as_dir in #((( 26127 '') as_dir=./ ;; 26128 */) ;; 26129 *) as_dir=$as_dir/ ;; 26130 esac 26131 for ac_exec_ext in '' $ac_executable_extensions; do 26132 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 26133 ac_cv_path_DROPBEAR="$as_dir$ac_word$ac_exec_ext" 26134 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 26135 break 2 26136 fi 26137done 26138 done 26139IFS=$as_save_IFS 26140 26141 ;; 26142esac 26143fi 26144DROPBEAR=$ac_cv_path_DROPBEAR 26145if test -n "$DROPBEAR"; then 26146 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $DROPBEAR" >&5 26147printf "%s\n" "$DROPBEAR" >&6; } 26148else 26149 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 26150printf "%s\n" "no" >&6; } 26151fi 26152 26153 26154# Extract the first word of "dbclient", so it can be a program name with args. 26155set dummy dbclient; ac_word=$2 26156{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 26157printf %s "checking for $ac_word... " >&6; } 26158if test ${ac_cv_path_DBCLIENT+y} 26159then : 26160 printf %s "(cached) " >&6 26161else $as_nop 26162 case $DBCLIENT in 26163 [\\/]* | ?:[\\/]*) 26164 ac_cv_path_DBCLIENT="$DBCLIENT" # Let the user override the test with a path. 26165 ;; 26166 *) 26167 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 26168for as_dir in $PATH 26169do 26170 IFS=$as_save_IFS 26171 case $as_dir in #((( 26172 '') as_dir=./ ;; 26173 */) ;; 26174 *) as_dir=$as_dir/ ;; 26175 esac 26176 for ac_exec_ext in '' $ac_executable_extensions; do 26177 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 26178 ac_cv_path_DBCLIENT="$as_dir$ac_word$ac_exec_ext" 26179 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 26180 break 2 26181 fi 26182done 26183 done 26184IFS=$as_save_IFS 26185 26186 ;; 26187esac 26188fi 26189DBCLIENT=$ac_cv_path_DBCLIENT 26190if test -n "$DBCLIENT"; then 26191 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $DBCLIENT" >&5 26192printf "%s\n" "$DBCLIENT" >&6; } 26193else 26194 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 26195printf "%s\n" "no" >&6; } 26196fi 26197 26198 26199# Extract the first word of "dropbearkey", so it can be a program name with args. 26200set dummy dropbearkey; ac_word=$2 26201{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 26202printf %s "checking for $ac_word... " >&6; } 26203if test ${ac_cv_path_DROPBEARKEY+y} 26204then : 26205 printf %s "(cached) " >&6 26206else $as_nop 26207 case $DROPBEARKEY in 26208 [\\/]* | ?:[\\/]*) 26209 ac_cv_path_DROPBEARKEY="$DROPBEARKEY" # Let the user override the test with a path. 26210 ;; 26211 *) 26212 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 26213for as_dir in $PATH 26214do 26215 IFS=$as_save_IFS 26216 case $as_dir in #((( 26217 '') as_dir=./ ;; 26218 */) ;; 26219 *) as_dir=$as_dir/ ;; 26220 esac 26221 for ac_exec_ext in '' $ac_executable_extensions; do 26222 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 26223 ac_cv_path_DROPBEARKEY="$as_dir$ac_word$ac_exec_ext" 26224 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 26225 break 2 26226 fi 26227done 26228 done 26229IFS=$as_save_IFS 26230 26231 ;; 26232esac 26233fi 26234DROPBEARKEY=$ac_cv_path_DROPBEARKEY 26235if test -n "$DROPBEARKEY"; then 26236 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $DROPBEARKEY" >&5 26237printf "%s\n" "$DROPBEARKEY" >&6; } 26238else 26239 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 26240printf "%s\n" "no" >&6; } 26241fi 26242 26243 26244# Extract the first word of "dropbearconvert", so it can be a program name with args. 26245set dummy dropbearconvert; ac_word=$2 26246{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 26247printf %s "checking for $ac_word... " >&6; } 26248if test ${ac_cv_path_DROPBEARCONVERT+y} 26249then : 26250 printf %s "(cached) " >&6 26251else $as_nop 26252 case $DROPBEARCONVERT in 26253 [\\/]* | ?:[\\/]*) 26254 ac_cv_path_DROPBEARCONVERT="$DROPBEARCONVERT" # Let the user override the test with a path. 26255 ;; 26256 *) 26257 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 26258for as_dir in $PATH 26259do 26260 IFS=$as_save_IFS 26261 case $as_dir in #((( 26262 '') as_dir=./ ;; 26263 */) ;; 26264 *) as_dir=$as_dir/ ;; 26265 esac 26266 for ac_exec_ext in '' $ac_executable_extensions; do 26267 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then 26268 ac_cv_path_DROPBEARCONVERT="$as_dir$ac_word$ac_exec_ext" 26269 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5 26270 break 2 26271 fi 26272done 26273 done 26274IFS=$as_save_IFS 26275 26276 ;; 26277esac 26278fi 26279DROPBEARCONVERT=$ac_cv_path_DROPBEARCONVERT 26280if test -n "$DROPBEARCONVERT"; then 26281 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $DROPBEARCONVERT" >&5 26282printf "%s\n" "$DROPBEARCONVERT" >&6; } 26283else 26284 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5 26285printf "%s\n" "no" >&6; } 26286fi 26287 26288 26289 26290CFLAGS="${CFLAGS} ${CFLAGS_AFTER}" 26291LDFLAGS="${LDFLAGS} ${LDFLAGS_AFTER}" 26292 26293# Make a copy of CFLAGS/LDFLAGS without PIE options. 26294LDFLAGS_NOPIE=`echo "$LDFLAGS" | sed 's/ -pie//'` 26295CFLAGS_NOPIE=`echo "$CFLAGS" | sed 's/ -fPIE//'` 26296 26297 26298 26299 26300ac_config_files="$ac_config_files Makefile buildpkg.sh opensshd.init openssh.xml openbsd-compat/Makefile openbsd-compat/regress/Makefile survey.sh" 26301 26302cat >confcache <<\_ACEOF 26303# This file is a shell script that caches the results of configure 26304# tests run on this system so they can be shared between configure 26305# scripts and configure runs, see configure's option --config-cache. 26306# It is not useful on other systems. If it contains results you don't 26307# want to keep, you may remove or edit it. 26308# 26309# config.status only pays attention to the cache file if you give it 26310# the --recheck option to rerun configure. 26311# 26312# `ac_cv_env_foo' variables (set or unset) will be overridden when 26313# loading this file, other *unset* `ac_cv_foo' will be assigned the 26314# following values. 26315 26316_ACEOF 26317 26318# The following way of writing the cache mishandles newlines in values, 26319# but we know of no workaround that is simple, portable, and efficient. 26320# So, we kill variables containing newlines. 26321# Ultrix sh set writes to stderr and can't be redirected directly, 26322# and sets the high bit in the cache file unless we assign to the vars. 26323( 26324 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do 26325 eval ac_val=\$$ac_var 26326 case $ac_val in #( 26327 *${as_nl}*) 26328 case $ac_var in #( 26329 *_cv_*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 26330printf "%s\n" "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; 26331 esac 26332 case $ac_var in #( 26333 _ | IFS | as_nl) ;; #( 26334 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( 26335 *) { eval $ac_var=; unset $ac_var;} ;; 26336 esac ;; 26337 esac 26338 done 26339 26340 (set) 2>&1 | 26341 case $as_nl`(ac_space=' '; set) 2>&1` in #( 26342 *${as_nl}ac_space=\ *) 26343 # `set' does not quote correctly, so add quotes: double-quote 26344 # substitution turns \\\\ into \\, and sed turns \\ into \. 26345 sed -n \ 26346 "s/'/'\\\\''/g; 26347 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" 26348 ;; #( 26349 *) 26350 # `set' quotes correctly as required by POSIX, so do not add quotes. 26351 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" 26352 ;; 26353 esac | 26354 sort 26355) | 26356 sed ' 26357 /^ac_cv_env_/b end 26358 t clear 26359 :clear 26360 s/^\([^=]*\)=\(.*[{}].*\)$/test ${\1+y} || &/ 26361 t end 26362 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ 26363 :end' >>confcache 26364if diff "$cache_file" confcache >/dev/null 2>&1; then :; else 26365 if test -w "$cache_file"; then 26366 if test "x$cache_file" != "x/dev/null"; then 26367 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 26368printf "%s\n" "$as_me: updating cache $cache_file" >&6;} 26369 if test ! -f "$cache_file" || test -h "$cache_file"; then 26370 cat confcache >"$cache_file" 26371 else 26372 case $cache_file in #( 26373 */* | ?:*) 26374 mv -f confcache "$cache_file"$$ && 26375 mv -f "$cache_file"$$ "$cache_file" ;; #( 26376 *) 26377 mv -f confcache "$cache_file" ;; 26378 esac 26379 fi 26380 fi 26381 else 26382 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 26383printf "%s\n" "$as_me: not updating unwritable cache $cache_file" >&6;} 26384 fi 26385fi 26386rm -f confcache 26387 26388test "x$prefix" = xNONE && prefix=$ac_default_prefix 26389# Let make expand exec_prefix. 26390test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' 26391 26392DEFS=-DHAVE_CONFIG_H 26393 26394ac_libobjs= 26395ac_ltlibobjs= 26396U= 26397for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue 26398 # 1. Remove the extension, and $U if already installed. 26399 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' 26400 ac_i=`printf "%s\n" "$ac_i" | sed "$ac_script"` 26401 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR 26402 # will be set to the directory where LIBOBJS objects are built. 26403 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" 26404 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' 26405done 26406LIBOBJS=$ac_libobjs 26407 26408LTLIBOBJS=$ac_ltlibobjs 26409 26410 26411 26412 26413: "${CONFIG_STATUS=./config.status}" 26414ac_write_fail=0 26415ac_clean_files_save=$ac_clean_files 26416ac_clean_files="$ac_clean_files $CONFIG_STATUS" 26417{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 26418printf "%s\n" "$as_me: creating $CONFIG_STATUS" >&6;} 26419as_write_fail=0 26420cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 26421#! $SHELL 26422# Generated by $as_me. 26423# Run this file to recreate the current configuration. 26424# Compiler output produced by configure, useful for debugging 26425# configure, is in config.log if it exists. 26426 26427debug=false 26428ac_cs_recheck=false 26429ac_cs_silent=false 26430 26431SHELL=\${CONFIG_SHELL-$SHELL} 26432export SHELL 26433_ASEOF 26434cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 26435## -------------------- ## 26436## M4sh Initialization. ## 26437## -------------------- ## 26438 26439# Be more Bourne compatible 26440DUALCASE=1; export DUALCASE # for MKS sh 26441as_nop=: 26442if test ${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1 26443then : 26444 emulate sh 26445 NULLCMD=: 26446 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which 26447 # is contrary to our usage. Disable this feature. 26448 alias -g '${1+"$@"}'='"$@"' 26449 setopt NO_GLOB_SUBST 26450else $as_nop 26451 case `(set -o) 2>/dev/null` in #( 26452 *posix*) : 26453 set -o posix ;; #( 26454 *) : 26455 ;; 26456esac 26457fi 26458 26459 26460 26461# Reset variables that may have inherited troublesome values from 26462# the environment. 26463 26464# IFS needs to be set, to space, tab, and newline, in precisely that order. 26465# (If _AS_PATH_WALK were called with IFS unset, it would have the 26466# side effect of setting IFS to empty, thus disabling word splitting.) 26467# Quoting is to prevent editors from complaining about space-tab. 26468as_nl=' 26469' 26470export as_nl 26471IFS=" "" $as_nl" 26472 26473PS1='$ ' 26474PS2='> ' 26475PS4='+ ' 26476 26477# Ensure predictable behavior from utilities with locale-dependent output. 26478LC_ALL=C 26479export LC_ALL 26480LANGUAGE=C 26481export LANGUAGE 26482 26483# We cannot yet rely on "unset" to work, but we need these variables 26484# to be unset--not just set to an empty or harmless value--now, to 26485# avoid bugs in old shells (e.g. pre-3.0 UWIN ksh). This construct 26486# also avoids known problems related to "unset" and subshell syntax 26487# in other old shells (e.g. bash 2.01 and pdksh 5.2.14). 26488for as_var in BASH_ENV ENV MAIL MAILPATH CDPATH 26489do eval test \${$as_var+y} \ 26490 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : 26491done 26492 26493# Ensure that fds 0, 1, and 2 are open. 26494if (exec 3>&0) 2>/dev/null; then :; else exec 0</dev/null; fi 26495if (exec 3>&1) 2>/dev/null; then :; else exec 1>/dev/null; fi 26496if (exec 3>&2) ; then :; else exec 2>/dev/null; fi 26497 26498# The user is always right. 26499if ${PATH_SEPARATOR+false} :; then 26500 PATH_SEPARATOR=: 26501 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { 26502 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || 26503 PATH_SEPARATOR=';' 26504 } 26505fi 26506 26507 26508# Find who we are. Look in the path if we contain no directory separator. 26509as_myself= 26510case $0 in #(( 26511 *[\\/]* ) as_myself=$0 ;; 26512 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 26513for as_dir in $PATH 26514do 26515 IFS=$as_save_IFS 26516 case $as_dir in #((( 26517 '') as_dir=./ ;; 26518 */) ;; 26519 *) as_dir=$as_dir/ ;; 26520 esac 26521 test -r "$as_dir$0" && as_myself=$as_dir$0 && break 26522 done 26523IFS=$as_save_IFS 26524 26525 ;; 26526esac 26527# We did not find ourselves, most probably we were run as `sh COMMAND' 26528# in which case we are not to be found in the path. 26529if test "x$as_myself" = x; then 26530 as_myself=$0 26531fi 26532if test ! -f "$as_myself"; then 26533 printf "%s\n" "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 26534 exit 1 26535fi 26536 26537 26538 26539# as_fn_error STATUS ERROR [LINENO LOG_FD] 26540# ---------------------------------------- 26541# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are 26542# provided, also output the error to LOG_FD, referencing LINENO. Then exit the 26543# script with STATUS, using 1 if that was 0. 26544as_fn_error () 26545{ 26546 as_status=$1; test $as_status -eq 0 && as_status=1 26547 if test "$4"; then 26548 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 26549 printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 26550 fi 26551 printf "%s\n" "$as_me: error: $2" >&2 26552 as_fn_exit $as_status 26553} # as_fn_error 26554 26555 26556 26557# as_fn_set_status STATUS 26558# ----------------------- 26559# Set $? to STATUS, without forking. 26560as_fn_set_status () 26561{ 26562 return $1 26563} # as_fn_set_status 26564 26565# as_fn_exit STATUS 26566# ----------------- 26567# Exit the shell with STATUS, even in a "trap 0" or "set -e" context. 26568as_fn_exit () 26569{ 26570 set +e 26571 as_fn_set_status $1 26572 exit $1 26573} # as_fn_exit 26574 26575# as_fn_unset VAR 26576# --------------- 26577# Portably unset VAR. 26578as_fn_unset () 26579{ 26580 { eval $1=; unset $1;} 26581} 26582as_unset=as_fn_unset 26583 26584# as_fn_append VAR VALUE 26585# ---------------------- 26586# Append the text in VALUE to the end of the definition contained in VAR. Take 26587# advantage of any shell optimizations that allow amortized linear growth over 26588# repeated appends, instead of the typical quadratic growth present in naive 26589# implementations. 26590if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null 26591then : 26592 eval 'as_fn_append () 26593 { 26594 eval $1+=\$2 26595 }' 26596else $as_nop 26597 as_fn_append () 26598 { 26599 eval $1=\$$1\$2 26600 } 26601fi # as_fn_append 26602 26603# as_fn_arith ARG... 26604# ------------------ 26605# Perform arithmetic evaluation on the ARGs, and store the result in the 26606# global $as_val. Take advantage of shells that can avoid forks. The arguments 26607# must be portable across $(()) and expr. 26608if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null 26609then : 26610 eval 'as_fn_arith () 26611 { 26612 as_val=$(( $* )) 26613 }' 26614else $as_nop 26615 as_fn_arith () 26616 { 26617 as_val=`expr "$@" || test $? -eq 1` 26618 } 26619fi # as_fn_arith 26620 26621 26622if expr a : '\(a\)' >/dev/null 2>&1 && 26623 test "X`expr 00001 : '.*\(...\)'`" = X001; then 26624 as_expr=expr 26625else 26626 as_expr=false 26627fi 26628 26629if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then 26630 as_basename=basename 26631else 26632 as_basename=false 26633fi 26634 26635if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then 26636 as_dirname=dirname 26637else 26638 as_dirname=false 26639fi 26640 26641as_me=`$as_basename -- "$0" || 26642$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ 26643 X"$0" : 'X\(//\)$' \| \ 26644 X"$0" : 'X\(/\)' \| . 2>/dev/null || 26645printf "%s\n" X/"$0" | 26646 sed '/^.*\/\([^/][^/]*\)\/*$/{ 26647 s//\1/ 26648 q 26649 } 26650 /^X\/\(\/\/\)$/{ 26651 s//\1/ 26652 q 26653 } 26654 /^X\/\(\/\).*/{ 26655 s//\1/ 26656 q 26657 } 26658 s/.*/./; q'` 26659 26660# Avoid depending upon Character Ranges. 26661as_cr_letters='abcdefghijklmnopqrstuvwxyz' 26662as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' 26663as_cr_Letters=$as_cr_letters$as_cr_LETTERS 26664as_cr_digits='0123456789' 26665as_cr_alnum=$as_cr_Letters$as_cr_digits 26666 26667 26668# Determine whether it's possible to make 'echo' print without a newline. 26669# These variables are no longer used directly by Autoconf, but are AC_SUBSTed 26670# for compatibility with existing Makefiles. 26671ECHO_C= ECHO_N= ECHO_T= 26672case `echo -n x` in #((((( 26673-n*) 26674 case `echo 'xy\c'` in 26675 *c*) ECHO_T=' ';; # ECHO_T is single tab character. 26676 xy) ECHO_C='\c';; 26677 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null 26678 ECHO_T=' ';; 26679 esac;; 26680*) 26681 ECHO_N='-n';; 26682esac 26683 26684# For backward compatibility with old third-party macros, we provide 26685# the shell variables $as_echo and $as_echo_n. New code should use 26686# AS_ECHO(["message"]) and AS_ECHO_N(["message"]), respectively. 26687as_echo='printf %s\n' 26688as_echo_n='printf %s' 26689 26690rm -f conf$$ conf$$.exe conf$$.file 26691if test -d conf$$.dir; then 26692 rm -f conf$$.dir/conf$$.file 26693else 26694 rm -f conf$$.dir 26695 mkdir conf$$.dir 2>/dev/null 26696fi 26697if (echo >conf$$.file) 2>/dev/null; then 26698 if ln -s conf$$.file conf$$ 2>/dev/null; then 26699 as_ln_s='ln -s' 26700 # ... but there are two gotchas: 26701 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. 26702 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. 26703 # In both cases, we have to default to `cp -pR'. 26704 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || 26705 as_ln_s='cp -pR' 26706 elif ln conf$$.file conf$$ 2>/dev/null; then 26707 as_ln_s=ln 26708 else 26709 as_ln_s='cp -pR' 26710 fi 26711else 26712 as_ln_s='cp -pR' 26713fi 26714rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file 26715rmdir conf$$.dir 2>/dev/null 26716 26717 26718# as_fn_mkdir_p 26719# ------------- 26720# Create "$as_dir" as a directory, including parents if necessary. 26721as_fn_mkdir_p () 26722{ 26723 26724 case $as_dir in #( 26725 -*) as_dir=./$as_dir;; 26726 esac 26727 test -d "$as_dir" || eval $as_mkdir_p || { 26728 as_dirs= 26729 while :; do 26730 case $as_dir in #( 26731 *\'*) as_qdir=`printf "%s\n" "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( 26732 *) as_qdir=$as_dir;; 26733 esac 26734 as_dirs="'$as_qdir' $as_dirs" 26735 as_dir=`$as_dirname -- "$as_dir" || 26736$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 26737 X"$as_dir" : 'X\(//\)[^/]' \| \ 26738 X"$as_dir" : 'X\(//\)$' \| \ 26739 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || 26740printf "%s\n" X"$as_dir" | 26741 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 26742 s//\1/ 26743 q 26744 } 26745 /^X\(\/\/\)[^/].*/{ 26746 s//\1/ 26747 q 26748 } 26749 /^X\(\/\/\)$/{ 26750 s//\1/ 26751 q 26752 } 26753 /^X\(\/\).*/{ 26754 s//\1/ 26755 q 26756 } 26757 s/.*/./; q'` 26758 test -d "$as_dir" && break 26759 done 26760 test -z "$as_dirs" || eval "mkdir $as_dirs" 26761 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" 26762 26763 26764} # as_fn_mkdir_p 26765if mkdir -p . 2>/dev/null; then 26766 as_mkdir_p='mkdir -p "$as_dir"' 26767else 26768 test -d ./-p && rmdir ./-p 26769 as_mkdir_p=false 26770fi 26771 26772 26773# as_fn_executable_p FILE 26774# ----------------------- 26775# Test if FILE is an executable regular file. 26776as_fn_executable_p () 26777{ 26778 test -f "$1" && test -x "$1" 26779} # as_fn_executable_p 26780as_test_x='test -x' 26781as_executable_p=as_fn_executable_p 26782 26783# Sed expression to map a string onto a valid CPP name. 26784as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" 26785 26786# Sed expression to map a string onto a valid variable name. 26787as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" 26788 26789 26790exec 6>&1 26791## ----------------------------------- ## 26792## Main body of $CONFIG_STATUS script. ## 26793## ----------------------------------- ## 26794_ASEOF 26795test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 26796 26797cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 26798# Save the log message, to keep $0 and so on meaningful, and to 26799# report actual input values of CONFIG_FILES etc. instead of their 26800# values after options handling. 26801ac_log=" 26802This file was extended by OpenSSH $as_me Portable, which was 26803generated by GNU Autoconf 2.71. Invocation command line was 26804 26805 CONFIG_FILES = $CONFIG_FILES 26806 CONFIG_HEADERS = $CONFIG_HEADERS 26807 CONFIG_LINKS = $CONFIG_LINKS 26808 CONFIG_COMMANDS = $CONFIG_COMMANDS 26809 $ $0 $@ 26810 26811on `(hostname || uname -n) 2>/dev/null | sed 1q` 26812" 26813 26814_ACEOF 26815 26816case $ac_config_files in *" 26817"*) set x $ac_config_files; shift; ac_config_files=$*;; 26818esac 26819 26820case $ac_config_headers in *" 26821"*) set x $ac_config_headers; shift; ac_config_headers=$*;; 26822esac 26823 26824 26825cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 26826# Files that config.status was made for. 26827config_files="$ac_config_files" 26828config_headers="$ac_config_headers" 26829 26830_ACEOF 26831 26832cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 26833ac_cs_usage="\ 26834\`$as_me' instantiates files and other configuration actions 26835from templates according to the current configuration. Unless the files 26836and actions are specified as TAGs, all are instantiated by default. 26837 26838Usage: $0 [OPTION]... [TAG]... 26839 26840 -h, --help print this help, then exit 26841 -V, --version print version number and configuration settings, then exit 26842 --config print configuration, then exit 26843 -q, --quiet, --silent 26844 do not print progress messages 26845 -d, --debug don't remove temporary files 26846 --recheck update $as_me by reconfiguring in the same conditions 26847 --file=FILE[:TEMPLATE] 26848 instantiate the configuration file FILE 26849 --header=FILE[:TEMPLATE] 26850 instantiate the configuration header FILE 26851 26852Configuration files: 26853$config_files 26854 26855Configuration headers: 26856$config_headers 26857 26858Report bugs to <openssh-unix-dev@mindrot.org>." 26859 26860_ACEOF 26861ac_cs_config=`printf "%s\n" "$ac_configure_args" | sed "$ac_safe_unquote"` 26862ac_cs_config_escaped=`printf "%s\n" "$ac_cs_config" | sed "s/^ //; s/'/'\\\\\\\\''/g"` 26863cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 26864ac_cs_config='$ac_cs_config_escaped' 26865ac_cs_version="\\ 26866OpenSSH config.status Portable 26867configured by $0, generated by GNU Autoconf 2.71, 26868 with options \\"\$ac_cs_config\\" 26869 26870Copyright (C) 2021 Free Software Foundation, Inc. 26871This config.status script is free software; the Free Software Foundation 26872gives unlimited permission to copy, distribute and modify it." 26873 26874ac_pwd='$ac_pwd' 26875srcdir='$srcdir' 26876INSTALL='$INSTALL' 26877MKDIR_P='$MKDIR_P' 26878AWK='$AWK' 26879test -n "\$AWK" || AWK=awk 26880_ACEOF 26881 26882cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 26883# The default lists apply if the user does not specify any file. 26884ac_need_defaults=: 26885while test $# != 0 26886do 26887 case $1 in 26888 --*=?*) 26889 ac_option=`expr "X$1" : 'X\([^=]*\)='` 26890 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` 26891 ac_shift=: 26892 ;; 26893 --*=) 26894 ac_option=`expr "X$1" : 'X\([^=]*\)='` 26895 ac_optarg= 26896 ac_shift=: 26897 ;; 26898 *) 26899 ac_option=$1 26900 ac_optarg=$2 26901 ac_shift=shift 26902 ;; 26903 esac 26904 26905 case $ac_option in 26906 # Handling of the options. 26907 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) 26908 ac_cs_recheck=: ;; 26909 --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) 26910 printf "%s\n" "$ac_cs_version"; exit ;; 26911 --config | --confi | --conf | --con | --co | --c ) 26912 printf "%s\n" "$ac_cs_config"; exit ;; 26913 --debug | --debu | --deb | --de | --d | -d ) 26914 debug=: ;; 26915 --file | --fil | --fi | --f ) 26916 $ac_shift 26917 case $ac_optarg in 26918 *\'*) ac_optarg=`printf "%s\n" "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; 26919 '') as_fn_error $? "missing file argument" ;; 26920 esac 26921 as_fn_append CONFIG_FILES " '$ac_optarg'" 26922 ac_need_defaults=false;; 26923 --header | --heade | --head | --hea ) 26924 $ac_shift 26925 case $ac_optarg in 26926 *\'*) ac_optarg=`printf "%s\n" "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; 26927 esac 26928 as_fn_append CONFIG_HEADERS " '$ac_optarg'" 26929 ac_need_defaults=false;; 26930 --he | --h) 26931 # Conflict between --help and --header 26932 as_fn_error $? "ambiguous option: \`$1' 26933Try \`$0 --help' for more information.";; 26934 --help | --hel | -h ) 26935 printf "%s\n" "$ac_cs_usage"; exit ;; 26936 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 26937 | -silent | --silent | --silen | --sile | --sil | --si | --s) 26938 ac_cs_silent=: ;; 26939 26940 # This is an error. 26941 -*) as_fn_error $? "unrecognized option: \`$1' 26942Try \`$0 --help' for more information." ;; 26943 26944 *) as_fn_append ac_config_targets " $1" 26945 ac_need_defaults=false ;; 26946 26947 esac 26948 shift 26949done 26950 26951ac_configure_extra_args= 26952 26953if $ac_cs_silent; then 26954 exec 6>/dev/null 26955 ac_configure_extra_args="$ac_configure_extra_args --silent" 26956fi 26957 26958_ACEOF 26959cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 26960if \$ac_cs_recheck; then 26961 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion 26962 shift 26963 \printf "%s\n" "running CONFIG_SHELL=$SHELL \$*" >&6 26964 CONFIG_SHELL='$SHELL' 26965 export CONFIG_SHELL 26966 exec "\$@" 26967fi 26968 26969_ACEOF 26970cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 26971exec 5>>config.log 26972{ 26973 echo 26974 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX 26975## Running $as_me. ## 26976_ASBOX 26977 printf "%s\n" "$ac_log" 26978} >&5 26979 26980_ACEOF 26981cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 26982_ACEOF 26983 26984cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 26985 26986# Handling of arguments. 26987for ac_config_target in $ac_config_targets 26988do 26989 case $ac_config_target in 26990 "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;; 26991 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; 26992 "buildpkg.sh") CONFIG_FILES="$CONFIG_FILES buildpkg.sh" ;; 26993 "opensshd.init") CONFIG_FILES="$CONFIG_FILES opensshd.init" ;; 26994 "openssh.xml") CONFIG_FILES="$CONFIG_FILES openssh.xml" ;; 26995 "openbsd-compat/Makefile") CONFIG_FILES="$CONFIG_FILES openbsd-compat/Makefile" ;; 26996 "openbsd-compat/regress/Makefile") CONFIG_FILES="$CONFIG_FILES openbsd-compat/regress/Makefile" ;; 26997 "survey.sh") CONFIG_FILES="$CONFIG_FILES survey.sh" ;; 26998 26999 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; 27000 esac 27001done 27002 27003 27004# If the user did not use the arguments to specify the items to instantiate, 27005# then the envvar interface is used. Set only those that are not. 27006# We use the long form for the default assignment because of an extremely 27007# bizarre bug on SunOS 4.1.3. 27008if $ac_need_defaults; then 27009 test ${CONFIG_FILES+y} || CONFIG_FILES=$config_files 27010 test ${CONFIG_HEADERS+y} || CONFIG_HEADERS=$config_headers 27011fi 27012 27013# Have a temporary directory for convenience. Make it in the build tree 27014# simply because there is no reason against having it here, and in addition, 27015# creating and moving files from /tmp can sometimes cause problems. 27016# Hook for its removal unless debugging. 27017# Note that there is a small window in which the directory will not be cleaned: 27018# after its creation but before its name has been assigned to `$tmp'. 27019$debug || 27020{ 27021 tmp= ac_tmp= 27022 trap 'exit_status=$? 27023 : "${ac_tmp:=$tmp}" 27024 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status 27025' 0 27026 trap 'as_fn_exit 1' 1 2 13 15 27027} 27028# Create a (secure) tmp directory for tmp files. 27029 27030{ 27031 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && 27032 test -d "$tmp" 27033} || 27034{ 27035 tmp=./conf$$-$RANDOM 27036 (umask 077 && mkdir "$tmp") 27037} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 27038ac_tmp=$tmp 27039 27040# Set up the scripts for CONFIG_FILES section. 27041# No need to generate them if there are no CONFIG_FILES. 27042# This happens for instance with `./config.status config.h'. 27043if test -n "$CONFIG_FILES"; then 27044 27045 27046ac_cr=`echo X | tr X '\015'` 27047# On cygwin, bash can eat \r inside `` if the user requested igncr. 27048# But we know of no other shell where ac_cr would be empty at this 27049# point, so we can use a bashism as a fallback. 27050if test "x$ac_cr" = x; then 27051 eval ac_cr=\$\'\\r\' 27052fi 27053ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` 27054if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then 27055 ac_cs_awk_cr='\\r' 27056else 27057 ac_cs_awk_cr=$ac_cr 27058fi 27059 27060echo 'BEGIN {' >"$ac_tmp/subs1.awk" && 27061_ACEOF 27062 27063 27064{ 27065 echo "cat >conf$$subs.awk <<_ACEOF" && 27066 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && 27067 echo "_ACEOF" 27068} >conf$$subs.sh || 27069 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 27070ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` 27071ac_delim='%!_!# ' 27072for ac_last_try in false false false false false :; do 27073 . ./conf$$subs.sh || 27074 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 27075 27076 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` 27077 if test $ac_delim_n = $ac_delim_num; then 27078 break 27079 elif $ac_last_try; then 27080 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 27081 else 27082 ac_delim="$ac_delim!$ac_delim _$ac_delim!! " 27083 fi 27084done 27085rm -f conf$$subs.sh 27086 27087cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 27088cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && 27089_ACEOF 27090sed -n ' 27091h 27092s/^/S["/; s/!.*/"]=/ 27093p 27094g 27095s/^[^!]*!// 27096:repl 27097t repl 27098s/'"$ac_delim"'$// 27099t delim 27100:nl 27101h 27102s/\(.\{148\}\)..*/\1/ 27103t more1 27104s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ 27105p 27106n 27107b repl 27108:more1 27109s/["\\]/\\&/g; s/^/"/; s/$/"\\/ 27110p 27111g 27112s/.\{148\}// 27113t nl 27114:delim 27115h 27116s/\(.\{148\}\)..*/\1/ 27117t more2 27118s/["\\]/\\&/g; s/^/"/; s/$/"/ 27119p 27120b 27121:more2 27122s/["\\]/\\&/g; s/^/"/; s/$/"\\/ 27123p 27124g 27125s/.\{148\}// 27126t delim 27127' <conf$$subs.awk | sed ' 27128/^[^""]/{ 27129 N 27130 s/\n// 27131} 27132' >>$CONFIG_STATUS || ac_write_fail=1 27133rm -f conf$$subs.awk 27134cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 27135_ACAWK 27136cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && 27137 for (key in S) S_is_set[key] = 1 27138 FS = "" 27139 27140} 27141{ 27142 line = $ 0 27143 nfields = split(line, field, "@") 27144 substed = 0 27145 len = length(field[1]) 27146 for (i = 2; i < nfields; i++) { 27147 key = field[i] 27148 keylen = length(key) 27149 if (S_is_set[key]) { 27150 value = S[key] 27151 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) 27152 len += length(value) + length(field[++i]) 27153 substed = 1 27154 } else 27155 len += 1 + keylen 27156 } 27157 27158 print line 27159} 27160 27161_ACAWK 27162_ACEOF 27163cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 27164if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then 27165 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" 27166else 27167 cat 27168fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ 27169 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 27170_ACEOF 27171 27172# VPATH may cause trouble with some makes, so we remove sole $(srcdir), 27173# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and 27174# trailing colons and then remove the whole line if VPATH becomes empty 27175# (actually we leave an empty line to preserve line numbers). 27176if test "x$srcdir" = x.; then 27177 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ 27178h 27179s/// 27180s/^/:/ 27181s/[ ]*$/:/ 27182s/:\$(srcdir):/:/g 27183s/:\${srcdir}:/:/g 27184s/:@srcdir@:/:/g 27185s/^:*// 27186s/:*$// 27187x 27188s/\(=[ ]*\).*/\1/ 27189G 27190s/\n// 27191s/^[^=]*=[ ]*$// 27192}' 27193fi 27194 27195cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 27196fi # test -n "$CONFIG_FILES" 27197 27198# Set up the scripts for CONFIG_HEADERS section. 27199# No need to generate them if there are no CONFIG_HEADERS. 27200# This happens for instance with `./config.status Makefile'. 27201if test -n "$CONFIG_HEADERS"; then 27202cat >"$ac_tmp/defines.awk" <<\_ACAWK || 27203BEGIN { 27204_ACEOF 27205 27206# Transform confdefs.h into an awk script `defines.awk', embedded as 27207# here-document in config.status, that substitutes the proper values into 27208# config.h.in to produce config.h. 27209 27210# Create a delimiter string that does not exist in confdefs.h, to ease 27211# handling of long lines. 27212ac_delim='%!_!# ' 27213for ac_last_try in false false :; do 27214 ac_tt=`sed -n "/$ac_delim/p" confdefs.h` 27215 if test -z "$ac_tt"; then 27216 break 27217 elif $ac_last_try; then 27218 as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 27219 else 27220 ac_delim="$ac_delim!$ac_delim _$ac_delim!! " 27221 fi 27222done 27223 27224# For the awk script, D is an array of macro values keyed by name, 27225# likewise P contains macro parameters if any. Preserve backslash 27226# newline sequences. 27227 27228ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* 27229sed -n ' 27230s/.\{148\}/&'"$ac_delim"'/g 27231t rset 27232:rset 27233s/^[ ]*#[ ]*define[ ][ ]*/ / 27234t def 27235d 27236:def 27237s/\\$// 27238t bsnl 27239s/["\\]/\\&/g 27240s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ 27241D["\1"]=" \3"/p 27242s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p 27243d 27244:bsnl 27245s/["\\]/\\&/g 27246s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ 27247D["\1"]=" \3\\\\\\n"\\/p 27248t cont 27249s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p 27250t cont 27251d 27252:cont 27253n 27254s/.\{148\}/&'"$ac_delim"'/g 27255t clear 27256:clear 27257s/\\$// 27258t bsnlc 27259s/["\\]/\\&/g; s/^/"/; s/$/"/p 27260d 27261:bsnlc 27262s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p 27263b cont 27264' <confdefs.h | sed ' 27265s/'"$ac_delim"'/"\\\ 27266"/g' >>$CONFIG_STATUS || ac_write_fail=1 27267 27268cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 27269 for (key in D) D_is_set[key] = 1 27270 FS = "" 27271} 27272/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { 27273 line = \$ 0 27274 split(line, arg, " ") 27275 if (arg[1] == "#") { 27276 defundef = arg[2] 27277 mac1 = arg[3] 27278 } else { 27279 defundef = substr(arg[1], 2) 27280 mac1 = arg[2] 27281 } 27282 split(mac1, mac2, "(") #) 27283 macro = mac2[1] 27284 prefix = substr(line, 1, index(line, defundef) - 1) 27285 if (D_is_set[macro]) { 27286 # Preserve the white space surrounding the "#". 27287 print prefix "define", macro P[macro] D[macro] 27288 next 27289 } else { 27290 # Replace #undef with comments. This is necessary, for example, 27291 # in the case of _POSIX_SOURCE, which is predefined and required 27292 # on some systems where configure will not decide to define it. 27293 if (defundef == "undef") { 27294 print "/*", prefix defundef, macro, "*/" 27295 next 27296 } 27297 } 27298} 27299{ print } 27300_ACAWK 27301_ACEOF 27302cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 27303 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 27304fi # test -n "$CONFIG_HEADERS" 27305 27306 27307eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS " 27308shift 27309for ac_tag 27310do 27311 case $ac_tag in 27312 :[FHLC]) ac_mode=$ac_tag; continue;; 27313 esac 27314 case $ac_mode$ac_tag in 27315 :[FHL]*:*);; 27316 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; 27317 :[FH]-) ac_tag=-:-;; 27318 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; 27319 esac 27320 ac_save_IFS=$IFS 27321 IFS=: 27322 set x $ac_tag 27323 IFS=$ac_save_IFS 27324 shift 27325 ac_file=$1 27326 shift 27327 27328 case $ac_mode in 27329 :L) ac_source=$1;; 27330 :[FH]) 27331 ac_file_inputs= 27332 for ac_f 27333 do 27334 case $ac_f in 27335 -) ac_f="$ac_tmp/stdin";; 27336 *) # Look for the file first in the build tree, then in the source tree 27337 # (if the path is not absolute). The absolute path cannot be DOS-style, 27338 # because $ac_f cannot contain `:'. 27339 test -f "$ac_f" || 27340 case $ac_f in 27341 [\\/$]*) false;; 27342 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; 27343 esac || 27344 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; 27345 esac 27346 case $ac_f in *\'*) ac_f=`printf "%s\n" "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac 27347 as_fn_append ac_file_inputs " '$ac_f'" 27348 done 27349 27350 # Let's still pretend it is `configure' which instantiates (i.e., don't 27351 # use $as_me), people would be surprised to read: 27352 # /* config.h. Generated by config.status. */ 27353 configure_input='Generated from '` 27354 printf "%s\n" "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' 27355 `' by configure.' 27356 if test x"$ac_file" != x-; then 27357 configure_input="$ac_file. $configure_input" 27358 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 27359printf "%s\n" "$as_me: creating $ac_file" >&6;} 27360 fi 27361 # Neutralize special characters interpreted by sed in replacement strings. 27362 case $configure_input in #( 27363 *\&* | *\|* | *\\* ) 27364 ac_sed_conf_input=`printf "%s\n" "$configure_input" | 27365 sed 's/[\\\\&|]/\\\\&/g'`;; #( 27366 *) ac_sed_conf_input=$configure_input;; 27367 esac 27368 27369 case $ac_tag in 27370 *:-:* | *:-) cat >"$ac_tmp/stdin" \ 27371 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; 27372 esac 27373 ;; 27374 esac 27375 27376 ac_dir=`$as_dirname -- "$ac_file" || 27377$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 27378 X"$ac_file" : 'X\(//\)[^/]' \| \ 27379 X"$ac_file" : 'X\(//\)$' \| \ 27380 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || 27381printf "%s\n" X"$ac_file" | 27382 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 27383 s//\1/ 27384 q 27385 } 27386 /^X\(\/\/\)[^/].*/{ 27387 s//\1/ 27388 q 27389 } 27390 /^X\(\/\/\)$/{ 27391 s//\1/ 27392 q 27393 } 27394 /^X\(\/\).*/{ 27395 s//\1/ 27396 q 27397 } 27398 s/.*/./; q'` 27399 as_dir="$ac_dir"; as_fn_mkdir_p 27400 ac_builddir=. 27401 27402case "$ac_dir" in 27403.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; 27404*) 27405 ac_dir_suffix=/`printf "%s\n" "$ac_dir" | sed 's|^\.[\\/]||'` 27406 # A ".." for each directory in $ac_dir_suffix. 27407 ac_top_builddir_sub=`printf "%s\n" "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` 27408 case $ac_top_builddir_sub in 27409 "") ac_top_builddir_sub=. ac_top_build_prefix= ;; 27410 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; 27411 esac ;; 27412esac 27413ac_abs_top_builddir=$ac_pwd 27414ac_abs_builddir=$ac_pwd$ac_dir_suffix 27415# for backward compatibility: 27416ac_top_builddir=$ac_top_build_prefix 27417 27418case $srcdir in 27419 .) # We are building in place. 27420 ac_srcdir=. 27421 ac_top_srcdir=$ac_top_builddir_sub 27422 ac_abs_top_srcdir=$ac_pwd ;; 27423 [\\/]* | ?:[\\/]* ) # Absolute name. 27424 ac_srcdir=$srcdir$ac_dir_suffix; 27425 ac_top_srcdir=$srcdir 27426 ac_abs_top_srcdir=$srcdir ;; 27427 *) # Relative name. 27428 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix 27429 ac_top_srcdir=$ac_top_build_prefix$srcdir 27430 ac_abs_top_srcdir=$ac_pwd/$srcdir ;; 27431esac 27432ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix 27433 27434 27435 case $ac_mode in 27436 :F) 27437 # 27438 # CONFIG_FILE 27439 # 27440 27441 case $INSTALL in 27442 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; 27443 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; 27444 esac 27445 ac_MKDIR_P=$MKDIR_P 27446 case $MKDIR_P in 27447 [\\/$]* | ?:[\\/]* ) ;; 27448 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;; 27449 esac 27450_ACEOF 27451 27452cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 27453# If the template does not know about datarootdir, expand it. 27454# FIXME: This hack should be removed a few years after 2.60. 27455ac_datarootdir_hack=; ac_datarootdir_seen= 27456ac_sed_dataroot=' 27457/datarootdir/ { 27458 p 27459 q 27460} 27461/@datadir@/p 27462/@docdir@/p 27463/@infodir@/p 27464/@localedir@/p 27465/@mandir@/p' 27466case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in 27467*datarootdir*) ac_datarootdir_seen=yes;; 27468*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) 27469 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 27470printf "%s\n" "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} 27471_ACEOF 27472cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 27473 ac_datarootdir_hack=' 27474 s&@datadir@&$datadir&g 27475 s&@docdir@&$docdir&g 27476 s&@infodir@&$infodir&g 27477 s&@localedir@&$localedir&g 27478 s&@mandir@&$mandir&g 27479 s&\\\${datarootdir}&$datarootdir&g' ;; 27480esac 27481_ACEOF 27482 27483# Neutralize VPATH when `$srcdir' = `.'. 27484# Shell code in configure.ac might set extrasub. 27485# FIXME: do we really want to maintain this feature? 27486cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 27487ac_sed_extra="$ac_vpsub 27488$extrasub 27489_ACEOF 27490cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 27491:t 27492/@[a-zA-Z_][a-zA-Z_0-9]*@/!b 27493s|@configure_input@|$ac_sed_conf_input|;t t 27494s&@top_builddir@&$ac_top_builddir_sub&;t t 27495s&@top_build_prefix@&$ac_top_build_prefix&;t t 27496s&@srcdir@&$ac_srcdir&;t t 27497s&@abs_srcdir@&$ac_abs_srcdir&;t t 27498s&@top_srcdir@&$ac_top_srcdir&;t t 27499s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t 27500s&@builddir@&$ac_builddir&;t t 27501s&@abs_builddir@&$ac_abs_builddir&;t t 27502s&@abs_top_builddir@&$ac_abs_top_builddir&;t t 27503s&@INSTALL@&$ac_INSTALL&;t t 27504s&@MKDIR_P@&$ac_MKDIR_P&;t t 27505$ac_datarootdir_hack 27506" 27507eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ 27508 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 27509 27510test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && 27511 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && 27512 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ 27513 "$ac_tmp/out"`; test -z "$ac_out"; } && 27514 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' 27515which seems to be undefined. Please make sure it is defined" >&5 27516printf "%s\n" "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' 27517which seems to be undefined. Please make sure it is defined" >&2;} 27518 27519 rm -f "$ac_tmp/stdin" 27520 case $ac_file in 27521 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; 27522 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; 27523 esac \ 27524 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 27525 ;; 27526 :H) 27527 # 27528 # CONFIG_HEADER 27529 # 27530 if test x"$ac_file" != x-; then 27531 { 27532 printf "%s\n" "/* $configure_input */" >&1 \ 27533 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" 27534 } >"$ac_tmp/config.h" \ 27535 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 27536 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then 27537 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 27538printf "%s\n" "$as_me: $ac_file is unchanged" >&6;} 27539 else 27540 rm -f "$ac_file" 27541 mv "$ac_tmp/config.h" "$ac_file" \ 27542 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 27543 fi 27544 else 27545 printf "%s\n" "/* $configure_input */" >&1 \ 27546 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ 27547 || as_fn_error $? "could not create -" "$LINENO" 5 27548 fi 27549 ;; 27550 27551 27552 esac 27553 27554done # for ac_tag 27555 27556 27557as_fn_exit 0 27558_ACEOF 27559ac_clean_files=$ac_clean_files_save 27560 27561test $ac_write_fail = 0 || 27562 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 27563 27564 27565# configure is writing to config.log, and then calls config.status. 27566# config.status does its own redirection, appending to config.log. 27567# Unfortunately, on DOS this fails, as config.log is still kept open 27568# by configure, so config.status won't be able to write to it; its 27569# output is simply discarded. So we exec the FD to /dev/null, 27570# effectively closing config.log, so it can be properly (re)opened and 27571# appended to by config.status. When coming back to configure, we 27572# need to make the FD available again. 27573if test "$no_create" != yes; then 27574 ac_cs_success=: 27575 ac_config_status_args= 27576 test "$silent" = yes && 27577 ac_config_status_args="$ac_config_status_args --quiet" 27578 exec 5>/dev/null 27579 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false 27580 exec 5>>config.log 27581 # Use ||, not &&, to avoid exiting from the if with $? = 1, which 27582 # would make configure fail if this is the last instruction. 27583 $ac_cs_success || as_fn_exit 1 27584fi 27585if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then 27586 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 27587printf "%s\n" "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} 27588fi 27589 27590 27591# Print summary of options 27592 27593# Someone please show me a better way :) 27594A=`eval echo ${prefix}` ; A=`eval echo ${A}` 27595B=`eval echo ${bindir}` ; B=`eval echo ${B}` 27596C=`eval echo ${sbindir}` ; C=`eval echo ${C}` 27597D=`eval echo ${sysconfdir}` ; D=`eval echo ${D}` 27598E=`eval echo ${libexecdir}/ssh-askpass` ; E=`eval echo ${E}` 27599F=`eval echo ${mandir}/${mansubdir}X` ; F=`eval echo ${F}` 27600G=`eval echo ${piddir}` ; G=`eval echo ${G}` 27601H=`eval echo ${PRIVSEP_PATH}` ; H=`eval echo ${H}` 27602I=`eval echo ${user_path}` ; I=`eval echo ${I}` 27603J=`eval echo ${superuser_path}` ; J=`eval echo ${J}` 27604 27605echo "" 27606echo "OpenSSH has been configured with the following options:" 27607echo " User binaries: $B" 27608echo " System binaries: $C" 27609echo " Configuration files: $D" 27610echo " Askpass program: $E" 27611echo " Manual pages: $F" 27612echo " PID file: $G" 27613echo " Privilege separation chroot path: $H" 27614if test "x$external_path_file" = "x/etc/login.conf" ; then 27615echo " At runtime, sshd will use the path defined in $external_path_file" 27616echo " Make sure the path to scp is present, otherwise scp will not work" 27617else 27618echo " sshd default user PATH: $I" 27619 if test ! -z "$external_path_file"; then 27620echo " (If PATH is set in $external_path_file it will be used instead. If" 27621echo " used, ensure the path to scp is present, otherwise scp will not work.)" 27622 fi 27623fi 27624if test ! -z "$superuser_path" ; then 27625echo " sshd superuser user PATH: $J" 27626fi 27627echo " Manpage format: $MANTYPE" 27628echo " PAM support: $PAM_MSG" 27629echo " OSF SIA support: $SIA_MSG" 27630echo " KerberosV support: $KRB5_MSG" 27631echo " SELinux support: $SELINUX_MSG" 27632echo " libedit support: $LIBEDIT_MSG" 27633echo " libldns support: $LDNS_MSG" 27634echo " Solaris process contract support: $SPC_MSG" 27635echo " Solaris project support: $SP_MSG" 27636echo " Solaris privilege support: $SPP_MSG" 27637echo " IP address in \$DISPLAY hack: $DISPLAY_HACK_MSG" 27638echo " Translate v4 in v6 hack: $IPV4_IN6_HACK_MSG" 27639echo " BSD Auth support: $BSD_AUTH_MSG" 27640echo " Random number source: $RAND_MSG" 27641echo " Privsep sandbox style: $SANDBOX_STYLE" 27642echo " PKCS#11 support: $enable_pkcs11" 27643echo " U2F/FIDO support: $enable_sk" 27644 27645echo "" 27646 27647echo " Host: ${host}" 27648echo " Compiler: ${CC}" 27649echo " Compiler flags: ${CFLAGS}" 27650echo "Preprocessor flags: ${CPPFLAGS}" 27651echo " Linker flags: ${LDFLAGS}" 27652echo " Libraries: ${LIBS}" 27653if test ! -z "${CHANNELLIBS}"; then 27654echo " +for channels: ${CHANNELLIBS}" 27655fi 27656if test ! -z "${LIBFIDO2}"; then 27657echo " +for FIDO2: ${LIBFIDO2}" 27658fi 27659if test ! -z "${SSHDLIBS}"; then 27660echo " +for sshd: ${SSHDLIBS}" 27661fi 27662 27663echo "" 27664 27665if test "x$MAKE_PACKAGE_SUPPORTED" = "xyes" ; then 27666 echo "SVR4 style packages are supported with \"make package\"" 27667 echo "" 27668fi 27669 27670if test "x$PAM_MSG" = "xyes" ; then 27671 echo "PAM is enabled. You may need to install a PAM control file " 27672 echo "for sshd, otherwise password authentication may fail. " 27673 echo "Example PAM control files can be found in the contrib/ " 27674 echo "subdirectory" 27675 echo "" 27676fi 27677 27678if test ! -z "$NO_PEERCHECK" ; then 27679 echo "WARNING: the operating system that you are using does not" 27680 echo "appear to support getpeereid(), getpeerucred() or the" 27681 echo "SO_PEERCRED getsockopt() option. These facilities are used to" 27682 echo "enforce security checks to prevent unauthorised connections to" 27683 echo "ssh-agent. Their absence increases the risk that a malicious" 27684 echo "user can connect to your agent." 27685 echo "" 27686fi 27687 27688if test "$AUDIT_MODULE" = "bsm" ; then 27689 echo "WARNING: BSM audit support is currently considered EXPERIMENTAL." 27690 echo "See the Solaris section in README.platform for details." 27691fi 27692