blob: 45c2bd730ab486a44bb6170f1270d0a2324bc84c [file] [log] [blame]
Elliott Hughes82be86d2017-09-20 17:00:17 -07001#! /bin/sh
2# Guess values for system-dependent variables and create Makefiles.
3# Generated by GNU Autoconf 2.69 for curl -.
4#
5# Report bugs to <a suitable curl mailing list: https://curl.haxx.se/mail/>.
6#
7#
8# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
9#
10#
11# This configure script is free software; the Free Software Foundation
12# gives unlimited permission to copy, distribute and modify it.
13#
Haibo Huang51d9d882019-02-06 01:36:06 -080014# Copyright (c) 1998 - 2019 Daniel Stenberg, <daniel@haxx.se>
Elliott Hughes82be86d2017-09-20 17:00:17 -070015# This configure script may be copied, distributed and modified under the
16# terms of the curl license; see COPYING for more details
17
18## -------------------------------- ##
19## XC_CONFIGURE_PREAMBLE ver: 1.0 ##
20## -------------------------------- ##
21
22xc_configure_preamble_ver_major='1'
23xc_configure_preamble_ver_minor='0'
24
25#
26# Set IFS to space, tab and newline.
27#
28
29xc_space=' '
30xc_tab=' '
31xc_newline='
32'
33IFS="$xc_space$xc_tab$xc_newline"
34
35#
36# Set internationalization behavior variables.
37#
38
39LANG='C'
40LC_ALL='C'
41LANGUAGE='C'
42export LANG
43export LC_ALL
44export LANGUAGE
45
46#
47# Some useful variables.
48#
49
50xc_msg_warn='configure: WARNING:'
51xc_msg_abrt='Can not continue.'
52xc_msg_err='configure: error:'
53
54#
55# Verify that 'echo' command is available, otherwise abort.
56#
57
58xc_tst_str='unknown'
59(`echo "$xc_tst_str" >/dev/null 2>&1`) && xc_tst_str='success'
60case "x$xc_tst_str" in # ((
61 xsuccess)
62 :
63 ;;
64 *)
65 # Try built-in echo, and fail.
66 echo "$xc_msg_err 'echo' command not found. $xc_msg_abrt" >&2
67 exit 1
68 ;;
69esac
70
71#
72# Verify that 'test' command is available, otherwise abort.
73#
74
75xc_tst_str='unknown'
76(`test -n "$xc_tst_str" >/dev/null 2>&1`) && xc_tst_str='success'
77case "x$xc_tst_str" in # ((
78 xsuccess)
79 :
80 ;;
81 *)
82 echo "$xc_msg_err 'test' command not found. $xc_msg_abrt" >&2
83 exit 1
84 ;;
85esac
86
87#
88# Verify that 'PATH' variable is set, otherwise abort.
89#
90
91xc_tst_str='unknown'
92(`test -n "$PATH" >/dev/null 2>&1`) && xc_tst_str='success'
93case "x$xc_tst_str" in # ((
94 xsuccess)
95 :
96 ;;
97 *)
98 echo "$xc_msg_err 'PATH' variable not set. $xc_msg_abrt" >&2
99 exit 1
100 ;;
101esac
102
103#
104# Verify that 'expr' command is available, otherwise abort.
105#
106
107xc_tst_str='unknown'
108xc_tst_str=`expr "$xc_tst_str" : '.*' 2>/dev/null`
109case "x$xc_tst_str" in # ((
110 x7)
111 :
112 ;;
113 *)
114 echo "$xc_msg_err 'expr' command not found. $xc_msg_abrt" >&2
115 exit 1
116 ;;
117esac
118
119#
120# Verify that 'sed' utility is found within 'PATH', otherwise abort.
121#
122
123xc_tst_str='unknown'
124xc_tst_str=`echo "$xc_tst_str" 2>/dev/null \
125 | sed -e 's:unknown:success:' 2>/dev/null`
126case "x$xc_tst_str" in # ((
127 xsuccess)
128 :
129 ;;
130 *)
131 echo "$xc_msg_err 'sed' utility not found in 'PATH'. $xc_msg_abrt" >&2
132 exit 1
133 ;;
134esac
135
136#
137# Verify that 'grep' utility is found within 'PATH', otherwise abort.
138#
139
140xc_tst_str='unknown'
141(`echo "$xc_tst_str" 2>/dev/null \
142 | grep 'unknown' >/dev/null 2>&1`) && xc_tst_str='success'
143case "x$xc_tst_str" in # ((
144 xsuccess)
145 :
146 ;;
147 *)
148 echo "$xc_msg_err 'grep' utility not found in 'PATH'. $xc_msg_abrt" >&2
149 exit 1
150 ;;
151esac
152
153#
154# Verify that 'tr' utility is found within 'PATH', otherwise abort.
155#
156
157xc_tst_str="${xc_tab}98s7u6c5c4e3s2s10"
158xc_tst_str=`echo "$xc_tst_str" 2>/dev/null \
159 | tr -d "0123456789$xc_tab" 2>/dev/null`
160case "x$xc_tst_str" in # ((
161 xsuccess)
162 :
163 ;;
164 *)
165 echo "$xc_msg_err 'tr' utility not found in 'PATH'. $xc_msg_abrt" >&2
166 exit 1
167 ;;
168esac
169
170#
171# Verify that 'wc' utility is found within 'PATH', otherwise abort.
172#
173
174xc_tst_str='unknown unknown unknown unknown'
175xc_tst_str=`echo "$xc_tst_str" 2>/dev/null \
176 | wc -w 2>/dev/null | tr -d "$xc_space$xc_tab" 2>/dev/null`
177case "x$xc_tst_str" in # ((
178 x4)
179 :
180 ;;
181 *)
182 echo "$xc_msg_err 'wc' utility not found in 'PATH'. $xc_msg_abrt" >&2
183 exit 1
184 ;;
185esac
186
187#
188# Verify that 'cat' utility is found within 'PATH', otherwise abort.
189#
190
191xc_tst_str='unknown'
192xc_tst_str=`cat <<_EOT 2>/dev/null \
193 | wc -l 2>/dev/null | tr -d "$xc_space$xc_tab" 2>/dev/null
194unknown
195unknown
196unknown
197_EOT`
198case "x$xc_tst_str" in # ((
199 x3)
200 :
201 ;;
202 *)
203 echo "$xc_msg_err 'cat' utility not found in 'PATH'. $xc_msg_abrt" >&2
204 exit 1
205 ;;
206esac
207
208#
209# Auto-detect and set 'PATH_SEPARATOR', unless it is already non-empty set.
210#
211
212# Directory count in 'PATH' when using a colon separator.
213xc_tst_dirs_col='x'
214xc_tst_prev_IFS=$IFS; IFS=':'
215for xc_tst_dir in $PATH; do
216 IFS=$xc_tst_prev_IFS
217 xc_tst_dirs_col="x$xc_tst_dirs_col"
218done
219IFS=$xc_tst_prev_IFS
220xc_tst_dirs_col=`expr "$xc_tst_dirs_col" : '.*'`
221
222# Directory count in 'PATH' when using a semicolon separator.
223xc_tst_dirs_sem='x'
224xc_tst_prev_IFS=$IFS; IFS=';'
225for xc_tst_dir in $PATH; do
226 IFS=$xc_tst_prev_IFS
227 xc_tst_dirs_sem="x$xc_tst_dirs_sem"
228done
229IFS=$xc_tst_prev_IFS
230xc_tst_dirs_sem=`expr "$xc_tst_dirs_sem" : '.*'`
231
232if test $xc_tst_dirs_sem -eq $xc_tst_dirs_col; then
233 # When both counting methods give the same result we do not want to
234 # chose one over the other, and consider auto-detection not possible.
235 if test -z "$PATH_SEPARATOR"; then
Elliott Hughescac39802018-04-27 16:19:43 -0700236 # User should provide the correct 'PATH_SEPARATOR' definition.
237 # Until then, guess that it is colon!
238 echo "$xc_msg_warn path separator not determined, guessing colon" >&2
239 PATH_SEPARATOR=':'
Elliott Hughes82be86d2017-09-20 17:00:17 -0700240 fi
241else
242 # Separator with the greater directory count is the auto-detected one.
243 if test $xc_tst_dirs_sem -gt $xc_tst_dirs_col; then
244 xc_tst_auto_separator=';'
245 else
246 xc_tst_auto_separator=':'
247 fi
248 if test -z "$PATH_SEPARATOR"; then
249 # Simply use the auto-detected one when not already set.
250 PATH_SEPARATOR=$xc_tst_auto_separator
251 elif test "x$PATH_SEPARATOR" != "x$xc_tst_auto_separator"; then
252 echo "$xc_msg_warn 'PATH_SEPARATOR' does not match auto-detected one." >&2
253 fi
254fi
255xc_PATH_SEPARATOR=$PATH_SEPARATOR
256
257xc_configure_preamble_result='yes'
258
259
260## -------------------- ##
261## M4sh Initialization. ##
262## -------------------- ##
263
264# Be more Bourne compatible
265DUALCASE=1; export DUALCASE # for MKS sh
266if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
267 emulate sh
268 NULLCMD=:
269 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
270 # is contrary to our usage. Disable this feature.
271 alias -g '${1+"$@"}'='"$@"'
272 setopt NO_GLOB_SUBST
273else
274 case `(set -o) 2>/dev/null` in #(
275 *posix*) :
276 set -o posix ;; #(
277 *) :
278 ;;
279esac
280fi
281
282
283as_nl='
284'
285export as_nl
286# Printing a long string crashes Solaris 7 /usr/bin/printf.
287as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
288as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
289as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
290# Prefer a ksh shell builtin over an external printf program on Solaris,
291# but without wasting forks for bash or zsh.
292if test -z "$BASH_VERSION$ZSH_VERSION" \
293 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
294 as_echo='print -r --'
295 as_echo_n='print -rn --'
296elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
297 as_echo='printf %s\n'
298 as_echo_n='printf %s'
299else
300 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
301 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
302 as_echo_n='/usr/ucb/echo -n'
303 else
304 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
305 as_echo_n_body='eval
306 arg=$1;
307 case $arg in #(
308 *"$as_nl"*)
309 expr "X$arg" : "X\\(.*\\)$as_nl";
310 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
311 esac;
312 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
313 '
314 export as_echo_n_body
315 as_echo_n='sh -c $as_echo_n_body as_echo'
316 fi
317 export as_echo_body
318 as_echo='sh -c $as_echo_body as_echo'
319fi
320
321
322
323# IFS
324# We need space, tab and new line, in precisely that order. Quoting is
325# there to prevent editors from complaining about space-tab.
326# (If _AS_PATH_WALK were called with IFS unset, it would disable word
327# splitting by setting IFS to empty value.)
328IFS=" "" $as_nl"
329
330# Find who we are. Look in the path if we contain no directory separator.
331as_myself=
332case $0 in #((
333 *[\\/]* ) as_myself=$0 ;;
334 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
335for as_dir in $PATH
336do
337 IFS=$as_save_IFS
338 test -z "$as_dir" && as_dir=.
339 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
340 done
341IFS=$as_save_IFS
342
343 ;;
344esac
345# We did not find ourselves, most probably we were run as `sh COMMAND'
346# in which case we are not to be found in the path.
347if test "x$as_myself" = x; then
348 as_myself=$0
349fi
350if test ! -f "$as_myself"; then
351 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
352 exit 1
353fi
354
355# Unset variables that we do not need and which cause bugs (e.g. in
356# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
357# suppresses any "Segmentation fault" message there. '((' could
358# trigger a bug in pdksh 5.2.14.
359for as_var in BASH_ENV ENV MAIL MAILPATH
360do eval test x\${$as_var+set} = xset \
361 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
362done
363PS1='$ '
364PS2='> '
365PS4='+ '
366
367# NLS nuisances.
368LC_ALL=C
369export LC_ALL
370LANGUAGE=C
371export LANGUAGE
372
373# CDPATH.
374(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
375
376# Use a proper internal environment variable to ensure we don't fall
377 # into an infinite loop, continuously re-executing ourselves.
378 if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
379 _as_can_reexec=no; export _as_can_reexec;
380 # We cannot yet assume a decent shell, so we have to provide a
381# neutralization value for shells without unset; and this also
382# works around shells that cannot unset nonexistent variables.
383# Preserve -v and -x to the replacement shell.
384BASH_ENV=/dev/null
385ENV=/dev/null
386(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
387case $- in # ((((
388 *v*x* | *x*v* ) as_opts=-vx ;;
389 *v* ) as_opts=-v ;;
390 *x* ) as_opts=-x ;;
391 * ) as_opts= ;;
392esac
393exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
394# Admittedly, this is quite paranoid, since all the known shells bail
395# out after a failed `exec'.
396$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
397as_fn_exit 255
398 fi
399 # We don't want this to propagate to other subprocesses.
400 { _as_can_reexec=; unset _as_can_reexec;}
401if test "x$CONFIG_SHELL" = x; then
402 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
403 emulate sh
404 NULLCMD=:
405 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
406 # is contrary to our usage. Disable this feature.
407 alias -g '\${1+\"\$@\"}'='\"\$@\"'
408 setopt NO_GLOB_SUBST
409else
410 case \`(set -o) 2>/dev/null\` in #(
411 *posix*) :
412 set -o posix ;; #(
413 *) :
414 ;;
415esac
416fi
417"
418 as_required="as_fn_return () { (exit \$1); }
419as_fn_success () { as_fn_return 0; }
420as_fn_failure () { as_fn_return 1; }
421as_fn_ret_success () { return 0; }
422as_fn_ret_failure () { return 1; }
423
424exitcode=0
425as_fn_success || { exitcode=1; echo as_fn_success failed.; }
426as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
427as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
428as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
429if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
430
431else
432 exitcode=1; echo positional parameters were not saved.
433fi
434test x\$exitcode = x0 || exit 1
435test -x / || exit 1"
436 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
437 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
438 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
439 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
440test \$(( 1 + 1 )) = 2 || exit 1
441
442 test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || (
443 ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
444 ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
445 ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
446 PATH=/empty FPATH=/empty; export PATH FPATH
447 test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\
448 || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1"
449 if (eval "$as_required") 2>/dev/null; then :
450 as_have_required=yes
451else
452 as_have_required=no
453fi
454 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
455
456else
457 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
458as_found=false
459for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
460do
461 IFS=$as_save_IFS
462 test -z "$as_dir" && as_dir=.
463 as_found=:
464 case $as_dir in #(
465 /*)
466 for as_base in sh bash ksh sh5; do
467 # Try only shells that exist, to save several forks.
468 as_shell=$as_dir/$as_base
469 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
470 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
471 CONFIG_SHELL=$as_shell as_have_required=yes
472 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
473 break 2
474fi
475fi
476 done;;
477 esac
478 as_found=false
479done
480$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
481 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
482 CONFIG_SHELL=$SHELL as_have_required=yes
483fi; }
484IFS=$as_save_IFS
485
486
487 if test "x$CONFIG_SHELL" != x; then :
488 export CONFIG_SHELL
489 # We cannot yet assume a decent shell, so we have to provide a
490# neutralization value for shells without unset; and this also
491# works around shells that cannot unset nonexistent variables.
492# Preserve -v and -x to the replacement shell.
493BASH_ENV=/dev/null
494ENV=/dev/null
495(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
496case $- in # ((((
497 *v*x* | *x*v* ) as_opts=-vx ;;
498 *v* ) as_opts=-v ;;
499 *x* ) as_opts=-x ;;
500 * ) as_opts= ;;
501esac
502exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
503# Admittedly, this is quite paranoid, since all the known shells bail
504# out after a failed `exec'.
505$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
506exit 255
507fi
508
509 if test x$as_have_required = xno; then :
510 $as_echo "$0: This script requires a shell more modern than all"
511 $as_echo "$0: the shells that I found on your system."
512 if test x${ZSH_VERSION+set} = xset ; then
513 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
514 $as_echo "$0: be upgraded to zsh 4.3.4 or later."
515 else
516 $as_echo "$0: Please tell bug-autoconf@gnu.org and a suitable curl
517$0: mailing list: https://curl.haxx.se/mail/ about your
518$0: system, including any error possibly output before this
519$0: message. Then install a modern shell, or manually run
520$0: the script under such a shell if you do have one."
521 fi
522 exit 1
523fi
524fi
525fi
526SHELL=${CONFIG_SHELL-/bin/sh}
527export SHELL
528# Unset more variables known to interfere with behavior of common tools.
529CLICOLOR_FORCE= GREP_OPTIONS=
530unset CLICOLOR_FORCE GREP_OPTIONS
531
532## --------------------- ##
533## M4sh Shell Functions. ##
534## --------------------- ##
535# as_fn_unset VAR
536# ---------------
537# Portably unset VAR.
538as_fn_unset ()
539{
540 { eval $1=; unset $1;}
541}
542as_unset=as_fn_unset
543
544# as_fn_set_status STATUS
545# -----------------------
546# Set $? to STATUS, without forking.
547as_fn_set_status ()
548{
549 return $1
550} # as_fn_set_status
551
552# as_fn_exit STATUS
553# -----------------
554# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
555as_fn_exit ()
556{
557 set +e
558 as_fn_set_status $1
559 exit $1
560} # as_fn_exit
561
562# as_fn_mkdir_p
563# -------------
564# Create "$as_dir" as a directory, including parents if necessary.
565as_fn_mkdir_p ()
566{
567
568 case $as_dir in #(
569 -*) as_dir=./$as_dir;;
570 esac
571 test -d "$as_dir" || eval $as_mkdir_p || {
572 as_dirs=
573 while :; do
574 case $as_dir in #(
575 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
576 *) as_qdir=$as_dir;;
577 esac
578 as_dirs="'$as_qdir' $as_dirs"
579 as_dir=`$as_dirname -- "$as_dir" ||
580$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
581 X"$as_dir" : 'X\(//\)[^/]' \| \
582 X"$as_dir" : 'X\(//\)$' \| \
583 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
584$as_echo X"$as_dir" |
585 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
586 s//\1/
587 q
588 }
589 /^X\(\/\/\)[^/].*/{
590 s//\1/
591 q
592 }
593 /^X\(\/\/\)$/{
594 s//\1/
595 q
596 }
597 /^X\(\/\).*/{
598 s//\1/
599 q
600 }
601 s/.*/./; q'`
602 test -d "$as_dir" && break
603 done
604 test -z "$as_dirs" || eval "mkdir $as_dirs"
605 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
606
607
608} # as_fn_mkdir_p
609
610# as_fn_executable_p FILE
611# -----------------------
612# Test if FILE is an executable regular file.
613as_fn_executable_p ()
614{
615 test -f "$1" && test -x "$1"
616} # as_fn_executable_p
617# as_fn_append VAR VALUE
618# ----------------------
619# Append the text in VALUE to the end of the definition contained in VAR. Take
620# advantage of any shell optimizations that allow amortized linear growth over
621# repeated appends, instead of the typical quadratic growth present in naive
622# implementations.
623if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
624 eval 'as_fn_append ()
625 {
626 eval $1+=\$2
627 }'
628else
629 as_fn_append ()
630 {
631 eval $1=\$$1\$2
632 }
633fi # as_fn_append
634
635# as_fn_arith ARG...
636# ------------------
637# Perform arithmetic evaluation on the ARGs, and store the result in the
638# global $as_val. Take advantage of shells that can avoid forks. The arguments
639# must be portable across $(()) and expr.
640if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
641 eval 'as_fn_arith ()
642 {
643 as_val=$(( $* ))
644 }'
645else
646 as_fn_arith ()
647 {
648 as_val=`expr "$@" || test $? -eq 1`
649 }
650fi # as_fn_arith
651
652
653# as_fn_error STATUS ERROR [LINENO LOG_FD]
654# ----------------------------------------
655# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
656# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
657# script with STATUS, using 1 if that was 0.
658as_fn_error ()
659{
660 as_status=$1; test $as_status -eq 0 && as_status=1
661 if test "$4"; then
662 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
663 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
664 fi
665 $as_echo "$as_me: error: $2" >&2
666 as_fn_exit $as_status
667} # as_fn_error
668
669if expr a : '\(a\)' >/dev/null 2>&1 &&
670 test "X`expr 00001 : '.*\(...\)'`" = X001; then
671 as_expr=expr
672else
673 as_expr=false
674fi
675
676if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
677 as_basename=basename
678else
679 as_basename=false
680fi
681
682if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
683 as_dirname=dirname
684else
685 as_dirname=false
686fi
687
688as_me=`$as_basename -- "$0" ||
689$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
690 X"$0" : 'X\(//\)$' \| \
691 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
692$as_echo X/"$0" |
693 sed '/^.*\/\([^/][^/]*\)\/*$/{
694 s//\1/
695 q
696 }
697 /^X\/\(\/\/\)$/{
698 s//\1/
699 q
700 }
701 /^X\/\(\/\).*/{
702 s//\1/
703 q
704 }
705 s/.*/./; q'`
706
707# Avoid depending upon Character Ranges.
708as_cr_letters='abcdefghijklmnopqrstuvwxyz'
709as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
710as_cr_Letters=$as_cr_letters$as_cr_LETTERS
711as_cr_digits='0123456789'
712as_cr_alnum=$as_cr_Letters$as_cr_digits
713
714
715 as_lineno_1=$LINENO as_lineno_1a=$LINENO
716 as_lineno_2=$LINENO as_lineno_2a=$LINENO
717 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
718 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
719 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
720 sed -n '
721 p
722 /[$]LINENO/=
723 ' <$as_myself |
724 sed '
725 s/[$]LINENO.*/&-/
726 t lineno
727 b
728 :lineno
729 N
730 :loop
731 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
732 t loop
733 s/-\n.*//
734 ' >$as_me.lineno &&
735 chmod +x "$as_me.lineno" ||
736 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
737
738 # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
739 # already done that, so ensure we don't try to do so again and fall
740 # in an infinite loop. This has already happened in practice.
741 _as_can_reexec=no; export _as_can_reexec
742 # Don't try to exec as it changes $[0], causing all sort of problems
743 # (the dirname of $[0] is not the place where we might find the
744 # original and so on. Autoconf is especially sensitive to this).
745 . "./$as_me.lineno"
746 # Exit status is that of the last command.
747 exit
748}
749
750ECHO_C= ECHO_N= ECHO_T=
751case `echo -n x` in #(((((
752-n*)
753 case `echo 'xy\c'` in
754 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
755 xy) ECHO_C='\c';;
756 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
757 ECHO_T=' ';;
758 esac;;
759*)
760 ECHO_N='-n';;
761esac
762
763rm -f conf$$ conf$$.exe conf$$.file
764if test -d conf$$.dir; then
765 rm -f conf$$.dir/conf$$.file
766else
767 rm -f conf$$.dir
768 mkdir conf$$.dir 2>/dev/null
769fi
770if (echo >conf$$.file) 2>/dev/null; then
771 if ln -s conf$$.file conf$$ 2>/dev/null; then
772 as_ln_s='ln -s'
773 # ... but there are two gotchas:
774 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
775 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
776 # In both cases, we have to default to `cp -pR'.
777 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
778 as_ln_s='cp -pR'
779 elif ln conf$$.file conf$$ 2>/dev/null; then
780 as_ln_s=ln
781 else
782 as_ln_s='cp -pR'
783 fi
784else
785 as_ln_s='cp -pR'
786fi
787rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
788rmdir conf$$.dir 2>/dev/null
789
790if mkdir -p . 2>/dev/null; then
791 as_mkdir_p='mkdir -p "$as_dir"'
792else
793 test -d ./-p && rmdir ./-p
794 as_mkdir_p=false
795fi
796
797as_test_x='test -x'
798as_executable_p=as_fn_executable_p
799
800# Sed expression to map a string onto a valid CPP name.
801as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
802
803# Sed expression to map a string onto a valid variable name.
804as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
805
806SHELL=${CONFIG_SHELL-/bin/sh}
807
808
809test -n "$DJDIR" || exec 7<&0 </dev/null
810exec 6>&1
811
812# Name of the host.
813# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
814# so uname gets run too.
815ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
816
817#
818# Initializations.
819#
820ac_default_prefix=/usr/local
821ac_clean_files=
822ac_config_libobj_dir=.
823LIBOBJS=
824cross_compiling=no
825subdirs=
826MFLAGS=
827MAKEFLAGS=
828
829# Identity of this package.
830PACKAGE_NAME='curl'
831PACKAGE_TARNAME='curl'
832PACKAGE_VERSION='-'
833PACKAGE_STRING='curl -'
834PACKAGE_BUGREPORT='a suitable curl mailing list: https://curl.haxx.se/mail/'
835PACKAGE_URL=''
836
837ac_unique_file="lib/urldata.h"
838# Factoring default headers for most tests.
839ac_includes_default="\
840#include <stdio.h>
841#ifdef HAVE_SYS_TYPES_H
842# include <sys/types.h>
843#endif
844#ifdef HAVE_SYS_STAT_H
845# include <sys/stat.h>
846#endif
847#ifdef STDC_HEADERS
848# include <stdlib.h>
849# include <stddef.h>
850#else
851# ifdef HAVE_STDLIB_H
852# include <stdlib.h>
853# endif
854#endif
855#ifdef HAVE_STRING_H
856# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
857# include <memory.h>
858# endif
859# include <string.h>
860#endif
861#ifdef HAVE_STRINGS_H
862# include <strings.h>
863#endif
864#ifdef HAVE_INTTYPES_H
865# include <inttypes.h>
866#endif
867#ifdef HAVE_STDINT_H
868# include <stdint.h>
869#endif
870#ifdef HAVE_UNISTD_H
871# include <unistd.h>
872#endif"
873
874enable_option_checking=no
875ac_subst_vars='am__EXEEXT_FALSE
876am__EXEEXT_TRUE
877LTLIBOBJS
878LIBOBJS
Elliott Hughes0128fe42018-02-27 14:57:55 -0800879SSL_BACKENDS
Elliott Hughes82be86d2017-09-20 17:00:17 -0700880SUPPORT_PROTOCOLS
881SUPPORT_FEATURES
882ENABLE_STATIC
883ENABLE_SHARED
884CROSSCOMPILING_FALSE
885CROSSCOMPILING_TRUE
886BLANK_AT_MAKETIME
887CURL_NETWORK_AND_TIME_LIBS
888CURL_NETWORK_LIBS
889LIBCURL_LIBS
Elliott Hughes82be86d2017-09-20 17:00:17 -0700890CFLAG_CURL_SYMBOL_HIDING
891DOING_CURL_SYMBOL_HIDING_FALSE
892DOING_CURL_SYMBOL_HIDING_TRUE
893USE_UNIX_SOCKETS
894BUILD_LIBHOSTNAME_FALSE
895BUILD_LIBHOSTNAME_TRUE
896USE_EMBEDDED_ARES_FALSE
897USE_EMBEDDED_ARES_TRUE
898USE_ARES
899subdirs
900USE_MANUAL_FALSE
901USE_MANUAL_TRUE
902MANOPT
903NROFF
904PERL
905IPV6_ENABLED
Haibo Huang65021c72019-03-27 15:37:23 -0700906FISH_FUNCTIONS_DIR
Elliott Hughes82be86d2017-09-20 17:00:17 -0700907ZSH_FUNCTIONS_DIR
Haibo Huang445085a2019-09-11 13:33:50 -0700908USE_QUICHE
909USE_NGHTTP3
910USE_NGTCP2_CRYPTO_OPENSSL
911USE_NGTCP2
Elliott Hughes82be86d2017-09-20 17:00:17 -0700912USE_NGHTTP2
913IDN_ENABLED
914CURL_LT_SHLIB_USE_VERSIONED_SYMBOLS_FALSE
915CURL_LT_SHLIB_USE_VERSIONED_SYMBOLS_TRUE
916CURL_LT_SHLIB_VERSIONED_FLAVOUR
917USE_LIBRTMP
Elliott Hughes0128fe42018-02-27 14:57:55 -0800918USE_LIBSSH
Elliott Hughes82be86d2017-09-20 17:00:17 -0700919USE_LIBSSH2
920LIBMETALINK_CPPFLAGS
921LIBMETALINK_LDFLAGS
922LIBMETALINK_LIBS
923USE_LIBPSL_FALSE
924USE_LIBPSL_TRUE
925CURL_CA_BUNDLE
Alex Deymo486467e2017-12-19 19:04:07 +0100926CURL_WITH_MULTI_SSL
Elliott Hughes82be86d2017-09-20 17:00:17 -0700927SSL_ENABLED
Elliott Hughes82be86d2017-09-20 17:00:17 -0700928NSS_LIBS
929USE_NSS
Elliott Hughesa93fb052018-12-12 14:22:48 -0800930USE_MESALINK
Haibo Huang001784b2019-07-19 05:27:28 -0700931USE_WOLFSSL
Elliott Hughes82be86d2017-09-20 17:00:17 -0700932USE_MBEDTLS
Elliott Hughes82be86d2017-09-20 17:00:17 -0700933HAVE_GNUTLS_SRP
934USE_GNUTLS_NETTLE
935USE_GNUTLS
936HAVE_OPENSSL_SRP
937RANDOM_FILE
938SSL_LIBS
Haibo Huang65021c72019-03-27 15:37:23 -0700939USE_SECTRANSP
Elliott Hughes82be86d2017-09-20 17:00:17 -0700940USE_WINDOWS_SSPI
941USE_SCHANNEL
Alex Deymo486467e2017-12-19 19:04:07 +0100942DEFAULT_SSL_BACKEND
943BUILD_STUB_GSS_FALSE
944BUILD_STUB_GSS_TRUE
Elliott Hughes82be86d2017-09-20 17:00:17 -0700945USE_OPENLDAP
Alex Deymo486467e2017-12-19 19:04:07 +0100946HAVE_BROTLI
Elliott Hughes82be86d2017-09-20 17:00:17 -0700947ZLIB_LIBS
948HAVE_LIBZ_FALSE
949HAVE_LIBZ_TRUE
950HAVE_LIBZ
951PKGCONFIG
Haibo Huang65021c72019-03-27 15:37:23 -0700952HAVE_PROTO_BSDSOCKET_H
Elliott Hughes82be86d2017-09-20 17:00:17 -0700953CURL_DISABLE_GOPHER
954CURL_DISABLE_SMTP
955CURL_DISABLE_SMB
956CURL_DISABLE_IMAP
957CURL_DISABLE_POP3
958CURL_DISABLE_TFTP
959CURL_DISABLE_TELNET
960CURL_DISABLE_DICT
961CURL_DISABLE_PROXY
962HAVE_LDAP_SSL
963CURL_DISABLE_LDAPS
964CURL_DISABLE_LDAP
965CURL_DISABLE_FILE
966CURL_DISABLE_FTP
967CURL_DISABLE_RTSP
968CURL_DISABLE_HTTP
969DOING_NATIVE_WINDOWS_FALSE
970DOING_NATIVE_WINDOWS_TRUE
971BUILD_UNITTESTS_FALSE
972BUILD_UNITTESTS_TRUE
973CURLDEBUG_FALSE
974CURLDEBUG_TRUE
975USE_EXPLICIT_LIB_DEPS_FALSE
976USE_EXPLICIT_LIB_DEPS_TRUE
977REQUIRE_LIB_DEPS
978CPPFLAG_CURL_STATICLIB
979USE_CPPFLAG_CURL_STATICLIB_FALSE
980USE_CPPFLAG_CURL_STATICLIB_TRUE
981CURL_LT_SHLIB_USE_MIMPURE_TEXT_FALSE
982CURL_LT_SHLIB_USE_MIMPURE_TEXT_TRUE
983CURL_LT_SHLIB_USE_NO_UNDEFINED_FALSE
984CURL_LT_SHLIB_USE_NO_UNDEFINED_TRUE
985CURL_LT_SHLIB_USE_VERSION_INFO_FALSE
986CURL_LT_SHLIB_USE_VERSION_INFO_TRUE
987LT_SYS_LIBRARY_PATH
988OTOOL64
989OTOOL
990LIPO
991NMEDIT
992DSYMUTIL
993MANIFEST_TOOL
994RANLIB
995ac_ct_AR
996LN_S
997NM
998ac_ct_DUMPBIN
999DUMPBIN
1000LD
1001FGREP
1002LIBTOOL
1003OBJDUMP
1004DLLTOOL
1005AS
Elliott Hughes72d948d2018-08-03 14:37:21 -07001006AR_FLAGS
Elliott Hughes82be86d2017-09-20 17:00:17 -07001007host_os
1008host_vendor
1009host_cpu
1010host
1011build_os
1012build_vendor
1013build_cpu
1014build
1015PKGADD_VENDOR
1016PKGADD_NAME
1017PKGADD_PKG
1018VERSIONNUM
1019CURLVERSION
1020am__fastdepCC_FALSE
1021am__fastdepCC_TRUE
1022CCDEPMODE
1023am__nodep
1024AMDEPBACKSLASH
1025AMDEP_FALSE
1026AMDEP_TRUE
Elliott Hughes82be86d2017-09-20 17:00:17 -07001027am__include
1028DEPDIR
1029am__untar
1030am__tar
1031AMTAR
1032am__leading_dot
1033SET_MAKE
1034AWK
1035mkdir_p
1036MKDIR_P
1037INSTALL_STRIP_PROGRAM
1038STRIP
1039install_sh
1040MAKEINFO
1041AUTOHEADER
1042AUTOMAKE
1043AUTOCONF
1044ACLOCAL
1045VERSION
1046PACKAGE
1047CYGPATH_W
1048am__isrc
Elliott Hughes0128fe42018-02-27 14:57:55 -08001049LCOV
1050GCOV
Elliott Hughes82be86d2017-09-20 17:00:17 -07001051CPP
1052OBJEXT
1053EXEEXT
1054ac_ct_CC
1055CPPFLAGS
1056LDFLAGS
1057CFLAGS
1058CC
1059INSTALL_DATA
1060INSTALL_SCRIPT
1061INSTALL_PROGRAM
1062libext
1063AR
1064EGREP
1065GREP
Elliott Hughes0128fe42018-02-27 14:57:55 -08001066SED
Elliott Hughes82be86d2017-09-20 17:00:17 -07001067CURL_CFLAG_EXTRAS
1068CONFIGURE_OPTIONS
Elliott Hughes82be86d2017-09-20 17:00:17 -07001069AM_BACKSLASH
1070AM_DEFAULT_VERBOSITY
1071AM_DEFAULT_V
1072AM_V
1073MAINT
1074MAINTAINER_MODE_FALSE
1075MAINTAINER_MODE_TRUE
1076target_alias
1077host_alias
1078build_alias
1079LIBS
1080ECHO_T
1081ECHO_N
1082ECHO_C
1083DEFS
1084mandir
1085localedir
1086libdir
1087psdir
1088pdfdir
1089dvidir
1090htmldir
1091infodir
1092docdir
1093oldincludedir
1094includedir
1095runstatedir
1096localstatedir
1097sharedstatedir
1098sysconfdir
1099datadir
1100datarootdir
1101libexecdir
1102sbindir
1103bindir
1104program_transform_name
1105prefix
1106exec_prefix
1107PACKAGE_URL
1108PACKAGE_BUGREPORT
1109PACKAGE_STRING
1110PACKAGE_VERSION
1111PACKAGE_TARNAME
1112PACKAGE_NAME
1113SHELL
Haibo Huang001784b2019-07-19 05:27:28 -07001114PATH_SEPARATOR
1115am__quote'
Elliott Hughes82be86d2017-09-20 17:00:17 -07001116ac_subst_files=''
1117ac_user_opts='
1118enable_option_checking
1119enable_maintainer_mode
1120enable_silent_rules
1121enable_debug
1122enable_optimize
1123enable_warnings
1124enable_werror
1125enable_curldebug
1126enable_symbol_hiding
1127enable_hidden_symbols
1128enable_ares
1129enable_rt
Haibo Huang31944072019-11-06 02:28:57 -08001130enable_esni
Elliott Hughes82be86d2017-09-20 17:00:17 -07001131enable_code_coverage
1132enable_dependency_tracking
1133enable_largefile
1134enable_shared
1135enable_static
1136with_pic
1137enable_fast_install
1138with_aix_soname
1139with_gnu_ld
1140with_sysroot
1141enable_libtool_lock
1142enable_http
1143enable_ftp
1144enable_file
1145enable_ldap
1146enable_ldaps
1147enable_rtsp
1148enable_proxy
1149enable_dict
1150enable_telnet
1151enable_tftp
1152enable_pop3
1153enable_imap
1154enable_smb
1155enable_smtp
1156enable_gopher
1157enable_manual
1158enable_libcurl_option
1159enable_libgcc
1160with_zlib
Alex Deymo486467e2017-12-19 19:04:07 +01001161with_brotli
Elliott Hughes82be86d2017-09-20 17:00:17 -07001162with_ldap_lib
1163with_lber_lib
1164enable_ipv6
1165with_gssapi_includes
1166with_gssapi_libs
1167with_gssapi
Alex Deymo486467e2017-12-19 19:04:07 +01001168with_default_ssl_backend
Elliott Hughes82be86d2017-09-20 17:00:17 -07001169with_winssl
Haibo Huang51d9d882019-02-06 01:36:06 -08001170with_schannel
Elliott Hughes82be86d2017-09-20 17:00:17 -07001171with_darwinssl
Haibo Huang65021c72019-03-27 15:37:23 -07001172with_secure_transport
1173with_amissl
Elliott Hughes82be86d2017-09-20 17:00:17 -07001174with_ssl
1175with_egd_socket
1176with_random
Elliott Hughesa93fb052018-12-12 14:22:48 -08001177enable_openssl_auto_load_config
Elliott Hughes82be86d2017-09-20 17:00:17 -07001178with_gnutls
Elliott Hughes82be86d2017-09-20 17:00:17 -07001179with_mbedtls
Elliott Hughes1ef06ba2018-05-30 15:43:58 -07001180with_wolfssl
Elliott Hughesa93fb052018-12-12 14:22:48 -08001181with_mesalink
Elliott Hughes82be86d2017-09-20 17:00:17 -07001182with_nss
Elliott Hughes82be86d2017-09-20 17:00:17 -07001183with_ca_bundle
1184with_ca_path
1185with_ca_fallback
1186with_libpsl
1187with_libmetalink
1188with_libssh2
Elliott Hughes0128fe42018-02-27 14:57:55 -08001189with_libssh
Elliott Hughes82be86d2017-09-20 17:00:17 -07001190with_librtmp
1191enable_versioned_symbols
1192with_winidn
1193with_libidn2
1194with_nghttp2
Haibo Huang445085a2019-09-11 13:33:50 -07001195with_ngtcp2
1196with_nghttp3
1197with_quiche
Elliott Hughes82be86d2017-09-20 17:00:17 -07001198with_zsh_functions_dir
Haibo Huang65021c72019-03-27 15:37:23 -07001199with_fish_functions_dir
Elliott Hughes82be86d2017-09-20 17:00:17 -07001200enable_threaded_resolver
1201enable_pthreads
1202enable_verbose
1203enable_sspi
1204enable_crypto_auth
1205enable_ntlm_wb
1206enable_tls_srp
1207enable_unix_sockets
1208enable_cookies
Haibo Huang001784b2019-07-19 05:27:28 -07001209enable_http_auth
1210enable_doh
1211enable_mime
1212enable_dateparse
1213enable_netrc
1214enable_progress_meter
1215enable_dnsshuffle
Haibo Huang65021c72019-03-27 15:37:23 -07001216enable_alt_svc
Elliott Hughes82be86d2017-09-20 17:00:17 -07001217'
1218 ac_precious_vars='build_alias
1219host_alias
1220target_alias
1221CC
1222CFLAGS
1223LDFLAGS
1224LIBS
1225CPPFLAGS
1226CPP
1227LT_SYS_LIBRARY_PATH'
1228ac_subdirs_all='ares'
1229
1230# Initialize some variables set by options.
1231ac_init_help=
1232ac_init_version=false
1233ac_unrecognized_opts=
1234ac_unrecognized_sep=
1235# The variables have the same names as the options, with
1236# dashes changed to underlines.
1237cache_file=/dev/null
1238exec_prefix=NONE
1239no_create=
1240no_recursion=
1241prefix=NONE
1242program_prefix=NONE
1243program_suffix=NONE
1244program_transform_name=s,x,x,
1245silent=
1246site=
1247srcdir=
1248verbose=
1249x_includes=NONE
1250x_libraries=NONE
1251
1252# Installation directory options.
1253# These are left unexpanded so users can "make install exec_prefix=/foo"
1254# and all the variables that are supposed to be based on exec_prefix
1255# by default will actually change.
1256# Use braces instead of parens because sh, perl, etc. also accept them.
1257# (The list follows the same order as the GNU Coding Standards.)
1258bindir='${exec_prefix}/bin'
1259sbindir='${exec_prefix}/sbin'
1260libexecdir='${exec_prefix}/libexec'
1261datarootdir='${prefix}/share'
1262datadir='${datarootdir}'
1263sysconfdir='${prefix}/etc'
1264sharedstatedir='${prefix}/com'
1265localstatedir='${prefix}/var'
1266runstatedir='${localstatedir}/run'
1267includedir='${prefix}/include'
1268oldincludedir='/usr/include'
1269docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
1270infodir='${datarootdir}/info'
1271htmldir='${docdir}'
1272dvidir='${docdir}'
1273pdfdir='${docdir}'
1274psdir='${docdir}'
1275libdir='${exec_prefix}/lib'
1276localedir='${datarootdir}/locale'
1277mandir='${datarootdir}/man'
1278
1279ac_prev=
1280ac_dashdash=
1281for ac_option
1282do
1283 # If the previous option needs an argument, assign it.
1284 if test -n "$ac_prev"; then
1285 eval $ac_prev=\$ac_option
1286 ac_prev=
1287 continue
1288 fi
1289
1290 case $ac_option in
1291 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1292 *=) ac_optarg= ;;
1293 *) ac_optarg=yes ;;
1294 esac
1295
1296 # Accept the important Cygnus configure options, so we can diagnose typos.
1297
1298 case $ac_dashdash$ac_option in
1299 --)
1300 ac_dashdash=yes ;;
1301
1302 -bindir | --bindir | --bindi | --bind | --bin | --bi)
1303 ac_prev=bindir ;;
1304 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1305 bindir=$ac_optarg ;;
1306
1307 -build | --build | --buil | --bui | --bu)
1308 ac_prev=build_alias ;;
1309 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1310 build_alias=$ac_optarg ;;
1311
1312 -cache-file | --cache-file | --cache-fil | --cache-fi \
1313 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1314 ac_prev=cache_file ;;
1315 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1316 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1317 cache_file=$ac_optarg ;;
1318
1319 --config-cache | -C)
1320 cache_file=config.cache ;;
1321
1322 -datadir | --datadir | --datadi | --datad)
1323 ac_prev=datadir ;;
1324 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1325 datadir=$ac_optarg ;;
1326
1327 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1328 | --dataroo | --dataro | --datar)
1329 ac_prev=datarootdir ;;
1330 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1331 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1332 datarootdir=$ac_optarg ;;
1333
1334 -disable-* | --disable-*)
1335 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1336 # Reject names that are not valid shell variable names.
1337 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1338 as_fn_error $? "invalid feature name: $ac_useropt"
1339 ac_useropt_orig=$ac_useropt
1340 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1341 case $ac_user_opts in
1342 *"
1343"enable_$ac_useropt"
1344"*) ;;
1345 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1346 ac_unrecognized_sep=', ';;
1347 esac
1348 eval enable_$ac_useropt=no ;;
1349
1350 -docdir | --docdir | --docdi | --doc | --do)
1351 ac_prev=docdir ;;
1352 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1353 docdir=$ac_optarg ;;
1354
1355 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1356 ac_prev=dvidir ;;
1357 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1358 dvidir=$ac_optarg ;;
1359
1360 -enable-* | --enable-*)
1361 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1362 # Reject names that are not valid shell variable names.
1363 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1364 as_fn_error $? "invalid feature name: $ac_useropt"
1365 ac_useropt_orig=$ac_useropt
1366 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1367 case $ac_user_opts in
1368 *"
1369"enable_$ac_useropt"
1370"*) ;;
1371 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1372 ac_unrecognized_sep=', ';;
1373 esac
1374 eval enable_$ac_useropt=\$ac_optarg ;;
1375
1376 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1377 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1378 | --exec | --exe | --ex)
1379 ac_prev=exec_prefix ;;
1380 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1381 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1382 | --exec=* | --exe=* | --ex=*)
1383 exec_prefix=$ac_optarg ;;
1384
1385 -gas | --gas | --ga | --g)
1386 # Obsolete; use --with-gas.
1387 with_gas=yes ;;
1388
1389 -help | --help | --hel | --he | -h)
1390 ac_init_help=long ;;
1391 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1392 ac_init_help=recursive ;;
1393 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1394 ac_init_help=short ;;
1395
1396 -host | --host | --hos | --ho)
1397 ac_prev=host_alias ;;
1398 -host=* | --host=* | --hos=* | --ho=*)
1399 host_alias=$ac_optarg ;;
1400
1401 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1402 ac_prev=htmldir ;;
1403 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1404 | --ht=*)
1405 htmldir=$ac_optarg ;;
1406
1407 -includedir | --includedir | --includedi | --included | --include \
1408 | --includ | --inclu | --incl | --inc)
1409 ac_prev=includedir ;;
1410 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1411 | --includ=* | --inclu=* | --incl=* | --inc=*)
1412 includedir=$ac_optarg ;;
1413
1414 -infodir | --infodir | --infodi | --infod | --info | --inf)
1415 ac_prev=infodir ;;
1416 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1417 infodir=$ac_optarg ;;
1418
1419 -libdir | --libdir | --libdi | --libd)
1420 ac_prev=libdir ;;
1421 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1422 libdir=$ac_optarg ;;
1423
1424 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1425 | --libexe | --libex | --libe)
1426 ac_prev=libexecdir ;;
1427 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1428 | --libexe=* | --libex=* | --libe=*)
1429 libexecdir=$ac_optarg ;;
1430
1431 -localedir | --localedir | --localedi | --localed | --locale)
1432 ac_prev=localedir ;;
1433 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1434 localedir=$ac_optarg ;;
1435
1436 -localstatedir | --localstatedir | --localstatedi | --localstated \
1437 | --localstate | --localstat | --localsta | --localst | --locals)
1438 ac_prev=localstatedir ;;
1439 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1440 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1441 localstatedir=$ac_optarg ;;
1442
1443 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1444 ac_prev=mandir ;;
1445 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1446 mandir=$ac_optarg ;;
1447
1448 -nfp | --nfp | --nf)
1449 # Obsolete; use --without-fp.
1450 with_fp=no ;;
1451
1452 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1453 | --no-cr | --no-c | -n)
1454 no_create=yes ;;
1455
1456 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1457 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1458 no_recursion=yes ;;
1459
1460 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1461 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1462 | --oldin | --oldi | --old | --ol | --o)
1463 ac_prev=oldincludedir ;;
1464 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1465 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1466 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1467 oldincludedir=$ac_optarg ;;
1468
1469 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1470 ac_prev=prefix ;;
1471 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1472 prefix=$ac_optarg ;;
1473
1474 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1475 | --program-pre | --program-pr | --program-p)
1476 ac_prev=program_prefix ;;
1477 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1478 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1479 program_prefix=$ac_optarg ;;
1480
1481 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1482 | --program-suf | --program-su | --program-s)
1483 ac_prev=program_suffix ;;
1484 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1485 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1486 program_suffix=$ac_optarg ;;
1487
1488 -program-transform-name | --program-transform-name \
1489 | --program-transform-nam | --program-transform-na \
1490 | --program-transform-n | --program-transform- \
1491 | --program-transform | --program-transfor \
1492 | --program-transfo | --program-transf \
1493 | --program-trans | --program-tran \
1494 | --progr-tra | --program-tr | --program-t)
1495 ac_prev=program_transform_name ;;
1496 -program-transform-name=* | --program-transform-name=* \
1497 | --program-transform-nam=* | --program-transform-na=* \
1498 | --program-transform-n=* | --program-transform-=* \
1499 | --program-transform=* | --program-transfor=* \
1500 | --program-transfo=* | --program-transf=* \
1501 | --program-trans=* | --program-tran=* \
1502 | --progr-tra=* | --program-tr=* | --program-t=*)
1503 program_transform_name=$ac_optarg ;;
1504
1505 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1506 ac_prev=pdfdir ;;
1507 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1508 pdfdir=$ac_optarg ;;
1509
1510 -psdir | --psdir | --psdi | --psd | --ps)
1511 ac_prev=psdir ;;
1512 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1513 psdir=$ac_optarg ;;
1514
1515 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1516 | -silent | --silent | --silen | --sile | --sil)
1517 silent=yes ;;
1518
1519 -runstatedir | --runstatedir | --runstatedi | --runstated \
1520 | --runstate | --runstat | --runsta | --runst | --runs \
1521 | --run | --ru | --r)
1522 ac_prev=runstatedir ;;
1523 -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
1524 | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \
1525 | --run=* | --ru=* | --r=*)
1526 runstatedir=$ac_optarg ;;
1527
1528 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1529 ac_prev=sbindir ;;
1530 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1531 | --sbi=* | --sb=*)
1532 sbindir=$ac_optarg ;;
1533
1534 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1535 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1536 | --sharedst | --shareds | --shared | --share | --shar \
1537 | --sha | --sh)
1538 ac_prev=sharedstatedir ;;
1539 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1540 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1541 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1542 | --sha=* | --sh=*)
1543 sharedstatedir=$ac_optarg ;;
1544
1545 -site | --site | --sit)
1546 ac_prev=site ;;
1547 -site=* | --site=* | --sit=*)
1548 site=$ac_optarg ;;
1549
1550 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1551 ac_prev=srcdir ;;
1552 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1553 srcdir=$ac_optarg ;;
1554
1555 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1556 | --syscon | --sysco | --sysc | --sys | --sy)
1557 ac_prev=sysconfdir ;;
1558 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1559 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1560 sysconfdir=$ac_optarg ;;
1561
1562 -target | --target | --targe | --targ | --tar | --ta | --t)
1563 ac_prev=target_alias ;;
1564 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1565 target_alias=$ac_optarg ;;
1566
1567 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1568 verbose=yes ;;
1569
1570 -version | --version | --versio | --versi | --vers | -V)
1571 ac_init_version=: ;;
1572
1573 -with-* | --with-*)
1574 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1575 # Reject names that are not valid shell variable names.
1576 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1577 as_fn_error $? "invalid package name: $ac_useropt"
1578 ac_useropt_orig=$ac_useropt
1579 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1580 case $ac_user_opts in
1581 *"
1582"with_$ac_useropt"
1583"*) ;;
1584 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1585 ac_unrecognized_sep=', ';;
1586 esac
1587 eval with_$ac_useropt=\$ac_optarg ;;
1588
1589 -without-* | --without-*)
1590 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1591 # Reject names that are not valid shell variable names.
1592 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1593 as_fn_error $? "invalid package name: $ac_useropt"
1594 ac_useropt_orig=$ac_useropt
1595 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1596 case $ac_user_opts in
1597 *"
1598"with_$ac_useropt"
1599"*) ;;
1600 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1601 ac_unrecognized_sep=', ';;
1602 esac
1603 eval with_$ac_useropt=no ;;
1604
1605 --x)
1606 # Obsolete; use --with-x.
1607 with_x=yes ;;
1608
1609 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1610 | --x-incl | --x-inc | --x-in | --x-i)
1611 ac_prev=x_includes ;;
1612 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1613 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1614 x_includes=$ac_optarg ;;
1615
1616 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1617 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1618 ac_prev=x_libraries ;;
1619 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1620 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1621 x_libraries=$ac_optarg ;;
1622
1623 -*) as_fn_error $? "unrecognized option: \`$ac_option'
1624Try \`$0 --help' for more information"
1625 ;;
1626
1627 *=*)
1628 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1629 # Reject names that are not valid shell variable names.
1630 case $ac_envvar in #(
1631 '' | [0-9]* | *[!_$as_cr_alnum]* )
1632 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1633 esac
1634 eval $ac_envvar=\$ac_optarg
1635 export $ac_envvar ;;
1636
1637 *)
1638 # FIXME: should be removed in autoconf 3.0.
1639 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1640 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1641 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1642 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1643 ;;
1644
1645 esac
1646done
1647
1648if test -n "$ac_prev"; then
1649 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1650 as_fn_error $? "missing argument to $ac_option"
1651fi
1652
1653if test -n "$ac_unrecognized_opts"; then
1654 case $enable_option_checking in
1655 no) ;;
1656 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1657 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1658 esac
1659fi
1660
1661# Check all directory arguments for consistency.
1662for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1663 datadir sysconfdir sharedstatedir localstatedir includedir \
1664 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1665 libdir localedir mandir runstatedir
1666do
1667 eval ac_val=\$$ac_var
1668 # Remove trailing slashes.
1669 case $ac_val in
1670 */ )
1671 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1672 eval $ac_var=\$ac_val;;
1673 esac
1674 # Be sure to have absolute directory names.
1675 case $ac_val in
1676 [\\/$]* | ?:[\\/]* ) continue;;
1677 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1678 esac
1679 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1680done
1681
1682# There might be people who depend on the old broken behavior: `$host'
1683# used to hold the argument of --host etc.
1684# FIXME: To remove some day.
1685build=$build_alias
1686host=$host_alias
1687target=$target_alias
1688
1689# FIXME: To remove some day.
1690if test "x$host_alias" != x; then
1691 if test "x$build_alias" = x; then
1692 cross_compiling=maybe
1693 elif test "x$build_alias" != "x$host_alias"; then
1694 cross_compiling=yes
1695 fi
1696fi
1697
1698ac_tool_prefix=
1699test -n "$host_alias" && ac_tool_prefix=$host_alias-
1700
1701test "$silent" = yes && exec 6>/dev/null
1702
1703
1704ac_pwd=`pwd` && test -n "$ac_pwd" &&
1705ac_ls_di=`ls -di .` &&
1706ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1707 as_fn_error $? "working directory cannot be determined"
1708test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1709 as_fn_error $? "pwd does not report name of working directory"
1710
1711
1712# Find the source files, if location was not specified.
1713if test -z "$srcdir"; then
1714 ac_srcdir_defaulted=yes
1715 # Try the directory containing this script, then the parent directory.
1716 ac_confdir=`$as_dirname -- "$as_myself" ||
1717$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1718 X"$as_myself" : 'X\(//\)[^/]' \| \
1719 X"$as_myself" : 'X\(//\)$' \| \
1720 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1721$as_echo X"$as_myself" |
1722 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1723 s//\1/
1724 q
1725 }
1726 /^X\(\/\/\)[^/].*/{
1727 s//\1/
1728 q
1729 }
1730 /^X\(\/\/\)$/{
1731 s//\1/
1732 q
1733 }
1734 /^X\(\/\).*/{
1735 s//\1/
1736 q
1737 }
1738 s/.*/./; q'`
1739 srcdir=$ac_confdir
1740 if test ! -r "$srcdir/$ac_unique_file"; then
1741 srcdir=..
1742 fi
1743else
1744 ac_srcdir_defaulted=no
1745fi
1746if test ! -r "$srcdir/$ac_unique_file"; then
1747 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1748 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1749fi
1750ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1751ac_abs_confdir=`(
1752 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1753 pwd)`
1754# When building in place, set srcdir=.
1755if test "$ac_abs_confdir" = "$ac_pwd"; then
1756 srcdir=.
1757fi
1758# Remove unnecessary trailing slashes from srcdir.
1759# Double slashes in file names in object file debugging info
1760# mess up M-x gdb in Emacs.
1761case $srcdir in
1762*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1763esac
1764for ac_var in $ac_precious_vars; do
1765 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1766 eval ac_env_${ac_var}_value=\$${ac_var}
1767 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1768 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1769done
1770
1771#
1772# Report the --help message.
1773#
1774if test "$ac_init_help" = "long"; then
1775 # Omit some internal or obsolete options to make the list less imposing.
1776 # This message is too long to be a string in the A/UX 3.1 sh.
1777 cat <<_ACEOF
1778\`configure' configures curl - to adapt to many kinds of systems.
1779
1780Usage: $0 [OPTION]... [VAR=VALUE]...
1781
1782To assign environment variables (e.g., CC, CFLAGS...), specify them as
1783VAR=VALUE. See below for descriptions of some of the useful variables.
1784
1785Defaults for the options are specified in brackets.
1786
1787Configuration:
1788 -h, --help display this help and exit
1789 --help=short display options specific to this package
1790 --help=recursive display the short help of all the included packages
1791 -V, --version display version information and exit
1792 -q, --quiet, --silent do not print \`checking ...' messages
1793 --cache-file=FILE cache test results in FILE [disabled]
1794 -C, --config-cache alias for \`--cache-file=config.cache'
1795 -n, --no-create do not create output files
1796 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1797
1798Installation directories:
1799 --prefix=PREFIX install architecture-independent files in PREFIX
1800 [$ac_default_prefix]
1801 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1802 [PREFIX]
1803
1804By default, \`make install' will install all the files in
1805\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1806an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1807for instance \`--prefix=\$HOME'.
1808
1809For better control, use the options below.
1810
1811Fine tuning of the installation directories:
1812 --bindir=DIR user executables [EPREFIX/bin]
1813 --sbindir=DIR system admin executables [EPREFIX/sbin]
1814 --libexecdir=DIR program executables [EPREFIX/libexec]
1815 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1816 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1817 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1818 --runstatedir=DIR modifiable per-process data [LOCALSTATEDIR/run]
1819 --libdir=DIR object code libraries [EPREFIX/lib]
1820 --includedir=DIR C header files [PREFIX/include]
1821 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1822 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1823 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1824 --infodir=DIR info documentation [DATAROOTDIR/info]
1825 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1826 --mandir=DIR man documentation [DATAROOTDIR/man]
1827 --docdir=DIR documentation root [DATAROOTDIR/doc/curl]
1828 --htmldir=DIR html documentation [DOCDIR]
1829 --dvidir=DIR dvi documentation [DOCDIR]
1830 --pdfdir=DIR pdf documentation [DOCDIR]
1831 --psdir=DIR ps documentation [DOCDIR]
1832_ACEOF
1833
1834 cat <<\_ACEOF
1835
1836Program names:
1837 --program-prefix=PREFIX prepend PREFIX to installed program names
1838 --program-suffix=SUFFIX append SUFFIX to installed program names
1839 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
1840
1841System types:
1842 --build=BUILD configure for building on BUILD [guessed]
1843 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1844_ACEOF
1845fi
1846
1847if test -n "$ac_init_help"; then
1848 case $ac_init_help in
1849 short | recursive ) echo "Configuration of curl -:";;
1850 esac
1851 cat <<\_ACEOF
1852
1853Optional Features:
1854 --disable-option-checking ignore unrecognized --enable/--with options
1855 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1856 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
1857 --enable-maintainer-mode
1858 enable make rules and dependencies not useful (and
1859 sometimes confusing) to the casual installer
1860 --enable-silent-rules less verbose build output (undo: "make V=1")
1861 --disable-silent-rules verbose build output (undo: "make V=0")
1862 --enable-debug Enable debug build options
1863 --disable-debug Disable debug build options
1864 --enable-optimize Enable compiler optimizations
1865 --disable-optimize Disable compiler optimizations
1866 --enable-warnings Enable strict compiler warnings
1867 --disable-warnings Disable strict compiler warnings
1868 --enable-werror Enable compiler warnings as errors
1869 --disable-werror Disable compiler warnings as errors
1870 --enable-curldebug Enable curl debug memory tracking
1871 --disable-curldebug Disable curl debug memory tracking
1872 --enable-symbol-hiding Enable hiding of library internal symbols
1873 --disable-symbol-hiding Disable hiding of library internal symbols
1874 --enable-hidden-symbols To be deprecated, use --enable-symbol-hiding
1875 --disable-hidden-symbols
1876 To be deprecated, use --disable-symbol-hiding
1877 --enable-ares[=PATH] Enable c-ares for DNS lookups
1878 --disable-ares Disable c-ares for DNS lookups
1879 --disable-rt disable dependency on -lrt
Haibo Huang31944072019-11-06 02:28:57 -08001880 --enable-esni Enable ESNI support
1881 --disable-esni Disable ESNI support
Haibo Huang51d9d882019-02-06 01:36:06 -08001882 --enable-code-coverage Provide code coverage
Elliott Hughes82be86d2017-09-20 17:00:17 -07001883 --enable-dependency-tracking
1884 do not reject slow dependency extractors
1885 --disable-dependency-tracking
1886 speeds up one-time build
1887 --disable-largefile omit support for large files
1888 --enable-shared[=PKGS] build shared libraries [default=yes]
1889 --enable-static[=PKGS] build static libraries [default=yes]
1890 --enable-fast-install[=PKGS]
1891 optimize for fast installation [default=yes]
1892 --disable-libtool-lock avoid locking (might break parallel builds)
1893 --enable-http Enable HTTP support
1894 --disable-http Disable HTTP support
1895 --enable-ftp Enable FTP support
1896 --disable-ftp Disable FTP support
1897 --enable-file Enable FILE support
1898 --disable-file Disable FILE support
1899 --enable-ldap Enable LDAP support
1900 --disable-ldap Disable LDAP support
1901 --enable-ldaps Enable LDAPS support
1902 --disable-ldaps Disable LDAPS support
1903 --enable-rtsp Enable RTSP support
1904 --disable-rtsp Disable RTSP support
1905 --enable-proxy Enable proxy support
1906 --disable-proxy Disable proxy support
1907 --enable-dict Enable DICT support
1908 --disable-dict Disable DICT support
1909 --enable-telnet Enable TELNET support
1910 --disable-telnet Disable TELNET support
1911 --enable-tftp Enable TFTP support
1912 --disable-tftp Disable TFTP support
1913 --enable-pop3 Enable POP3 support
1914 --disable-pop3 Disable POP3 support
1915 --enable-imap Enable IMAP support
1916 --disable-imap Disable IMAP support
1917 --enable-smb Enable SMB/CIFS support
1918 --disable-smb Disable SMB/CIFS support
1919 --enable-smtp Enable SMTP support
1920 --disable-smtp Disable SMTP support
1921 --enable-gopher Enable Gopher support
1922 --disable-gopher Disable Gopher support
1923 --enable-manual Enable built-in manual
1924 --disable-manual Disable built-in manual
1925 --enable-libcurl-option Enable --libcurl C code generation support
1926 --disable-libcurl-option
1927 Disable --libcurl C code generation support
1928 --enable-libgcc use libgcc when linking
1929 --enable-ipv6 Enable IPv6 (with IPv4) support
1930 --disable-ipv6 Disable IPv6 support
Elliott Hughesa93fb052018-12-12 14:22:48 -08001931 --enable-openssl-auto-load-config
1932 Enable automatic loading of OpenSSL configuration
1933 --disable-openssl-auto-load-config
1934 Disable automatic loading of OpenSSL configuration
Elliott Hughes82be86d2017-09-20 17:00:17 -07001935 --enable-versioned-symbols
1936 Enable versioned symbols in shared library
1937 --disable-versioned-symbols
1938 Disable versioned symbols in shared library
1939 --enable-threaded-resolver
1940 Enable threaded resolver
1941 --disable-threaded-resolver
1942 Disable threaded resolver
1943 --enable-pthreads Enable POSIX threads (default for threaded resolver)
1944 --disable-pthreads Disable POSIX threads
1945 --enable-verbose Enable verbose strings
1946 --disable-verbose Disable verbose strings
1947 --enable-sspi Enable SSPI
1948 --disable-sspi Disable SSPI
1949 --enable-crypto-auth Enable cryptographic authentication
1950 --disable-crypto-auth Disable cryptographic authentication
1951 --enable-ntlm-wb[=FILE] Enable NTLM delegation to winbind's ntlm_auth
1952 helper, where FILE is ntlm_auth's absolute filename
1953 (default: /usr/bin/ntlm_auth)
1954 --disable-ntlm-wb Disable NTLM delegation to winbind's ntlm_auth
1955 helper
1956 --enable-tls-srp Enable TLS-SRP authentication
1957 --disable-tls-srp Disable TLS-SRP authentication
1958 --enable-unix-sockets Enable Unix domain sockets
1959 --disable-unix-sockets Disable Unix domain sockets
1960 --enable-cookies Enable cookies support
1961 --disable-cookies Disable cookies support
Haibo Huang001784b2019-07-19 05:27:28 -07001962 --enable-http-auth Enable HTTP authentication support
1963 --disable-http-auth Disable HTTP authentication support
1964 --enable-doh Enable DoH support
1965 --disable-doh Disable DoH support
1966 --enable-mime Enable mime API support
1967 --disable-mime Disable mime API support
1968 --enable-dateparse Enable date parsing
1969 --disable-dateparse Disable date parsing
1970 --enable-netrc Enable netrc parsing
1971 --disable-netrc Disable netrc parsing
1972 --enable-progress-meter Enable progress-meter
1973 --disable-progress-meter
1974 Disable progress-meter
1975 --enable-dnsshuffle Enable DNS shuffling
1976 --disable-dnsshuffle Disable DNS shufflinf
Haibo Huang65021c72019-03-27 15:37:23 -07001977 --enable-alt-svc Enable alt-svc support
1978 --disable-alt-svc Disable alt-svc support
Elliott Hughes82be86d2017-09-20 17:00:17 -07001979
1980Optional Packages:
1981 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1982 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
Elliott Hughes82be86d2017-09-20 17:00:17 -07001983 --with-pic[=PKGS] try to use only PIC/non-PIC objects [default=use
1984 both]
1985 --with-aix-soname=aix|svr4|both
1986 shared library versioning (aka "SONAME") variant to
1987 provide on AIX, [default=aix].
1988 --with-gnu-ld assume the C compiler uses GNU ld [default=no]
1989 --with-sysroot[=DIR] Search for dependent libraries within DIR (or the
1990 compiler's sysroot if not specified).
1991 --with-zlib=PATH search for zlib in PATH
1992 --without-zlib disable use of zlib
Alex Deymo486467e2017-12-19 19:04:07 +01001993 --with-brotli=PATH Where to look for brotli, PATH points to the BROTLI
1994 installation; when possible, set the PKG_CONFIG_PATH
1995 environment variable instead of using this option
1996 --without-brotli disable BROTLI
Elliott Hughes82be86d2017-09-20 17:00:17 -07001997 --with-ldap-lib=libname Specify name of ldap lib file
1998 --with-lber-lib=libname Specify name of lber lib file
1999 --with-gssapi-includes=DIR
2000 Specify location of GSS-API headers
2001 --with-gssapi-libs=DIR Specify location of GSS-API libs
2002 --with-gssapi=DIR Where to look for GSS-API
Alex Deymo486467e2017-12-19 19:04:07 +01002003 --with-default-ssl-backend=NAME
2004 Use NAME as default SSL backend
2005 --without-default-ssl-backend
2006 Use implicit default SSL backend
Elliott Hughes82be86d2017-09-20 17:00:17 -07002007 --with-winssl enable Windows native SSL/TLS
2008 --without-winssl disable Windows native SSL/TLS
Haibo Huang51d9d882019-02-06 01:36:06 -08002009 --with-schannel enable Windows native SSL/TLS
2010 --without-schannel disable Windows native SSL/TLS
Elliott Hughes82be86d2017-09-20 17:00:17 -07002011 --with-darwinssl enable Apple OS native SSL/TLS
2012 --without-darwinssl disable Apple OS native SSL/TLS
Haibo Huang65021c72019-03-27 15:37:23 -07002013 --with-secure-transport enable Apple OS native SSL/TLS
2014 --without-secure-transport
2015 disable Apple OS native SSL/TLS
2016 --with-amissl enable Amiga native SSL/TLS (AmiSSL)
2017 --without-amissl disable Amiga native SSL/TLS (AmiSSL)
Elliott Hughes82be86d2017-09-20 17:00:17 -07002018 --with-ssl=PATH Where to look for OpenSSL, PATH points to the SSL
2019 installation (default: /usr/local/ssl); when
2020 possible, set the PKG_CONFIG_PATH environment
2021 variable instead of using this option
2022 --without-ssl disable OpenSSL
2023 --with-egd-socket=FILE Entropy Gathering Daemon socket pathname
2024 --with-random=FILE read randomness from FILE (default=/dev/urandom)
2025 --with-gnutls=PATH where to look for GnuTLS, PATH points to the
2026 installation root
2027 --without-gnutls disable GnuTLS detection
Elliott Hughes82be86d2017-09-20 17:00:17 -07002028 --with-mbedtls=PATH where to look for mbedTLS, PATH points to the
2029 installation root
2030 --without-mbedtls disable mbedTLS detection
Elliott Hughes1ef06ba2018-05-30 15:43:58 -07002031 --with-wolfssl=PATH where to look for WolfSSL, PATH points to the
2032 installation root (default: system lib default)
2033 --without-wolfssl disable WolfSSL detection
Elliott Hughesa93fb052018-12-12 14:22:48 -08002034 --with-mesalink=PATH where to look for MesaLink, PATH points to the
2035 installation root
2036 --without-mesalink disable MesaLink detection
Elliott Hughes82be86d2017-09-20 17:00:17 -07002037 --with-nss=PATH where to look for NSS, PATH points to the
2038 installation root
2039 --without-nss disable NSS detection
Elliott Hughes82be86d2017-09-20 17:00:17 -07002040 --with-ca-bundle=FILE Path to a file containing CA certificates (example:
2041 /etc/ca-bundle.crt)
2042 --without-ca-bundle Don't use a default CA bundle
2043 --with-ca-path=DIRECTORY
2044 Path to a directory containing CA certificates
2045 stored individually, with their filenames in a hash
2046 format. This option can be used with OpenSSL, GnuTLS
2047 and PolarSSL backends. Refer to OpenSSL c_rehash for
2048 details. (example: /etc/certificates)
2049 --without-ca-path Don't use a default CA path
2050 --with-ca-fallback Use the built in CA store of the SSL library
2051 --without-ca-fallback Don't use the built in CA store of the SSL library
2052 --without-libpsl disable support for libpsl cookie checking
2053 --with-libmetalink=PATH where to look for libmetalink, PATH points to the
2054 installation root
2055 --without-libmetalink disable libmetalink detection
2056 --with-libssh2=PATH Where to look for libssh2, PATH points to the
2057 LIBSSH2 installation; when possible, set the
2058 PKG_CONFIG_PATH environment variable instead of
2059 using this option
Elliott Hughes0128fe42018-02-27 14:57:55 -08002060 --with-libssh2 enable LIBSSH2
2061 --with-libssh=PATH Where to look for libssh, PATH points to the LIBSSH
2062 installation; when possible, set the PKG_CONFIG_PATH
2063 environment variable instead of using this option
2064 --with-libssh enable LIBSSH
Elliott Hughes82be86d2017-09-20 17:00:17 -07002065 --with-librtmp=PATH Where to look for librtmp, PATH points to the
2066 LIBRTMP installation; when possible, set the
2067 PKG_CONFIG_PATH environment variable instead of
2068 using this option
2069 --without-librtmp disable LIBRTMP
2070 --with-winidn=PATH enable Windows native IDN
2071 --without-winidn disable Windows native IDN
2072 --with-libidn2=PATH Enable libidn2 usage
2073 --without-libidn2 Disable libidn2 usage
2074 --with-nghttp2=PATH Enable nghttp2 usage
2075 --without-nghttp2 Disable nghttp2 usage
Haibo Huang445085a2019-09-11 13:33:50 -07002076 --with-ngtcp2=PATH Enable ngtcp2 usage
2077 --without-ngtcp2 Disable ngtcp2 usage
2078 --with-nghttp3=PATH Enable nghttp3 usage
2079 --without-nghttp3 Disable nghttp3 usage
2080 --with-quiche=PATH Enable quiche usage
2081 --without-quiche Disable quiche usage
Elliott Hughes82be86d2017-09-20 17:00:17 -07002082 --with-zsh-functions-dir=PATH
2083 Install zsh completions to PATH
2084 --without-zsh-functions-dir
2085 Do not install zsh completions
Haibo Huang65021c72019-03-27 15:37:23 -07002086 --with-fish-functions-dir=PATH
2087 Install fish completions to PATH
2088 --without-fish-functions-dir
2089 Do not install fish completions
Elliott Hughes82be86d2017-09-20 17:00:17 -07002090
2091Some influential environment variables:
2092 CC C compiler command
2093 CFLAGS C compiler flags
2094 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
2095 nonstandard directory <lib dir>
2096 LIBS libraries to pass to the linker, e.g. -l<library>
2097 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
2098 you have headers in a nonstandard directory <include dir>
2099 CPP C preprocessor
2100 LT_SYS_LIBRARY_PATH
2101 User-defined run-time library search path.
2102
2103Use these variables to override the choices made by `configure' or to help
2104it to find libraries and programs with nonstandard names/locations.
2105
2106Report bugs to <a suitable curl mailing list: https://curl.haxx.se/mail/>.
2107_ACEOF
2108ac_status=$?
2109fi
2110
2111if test "$ac_init_help" = "recursive"; then
2112 # If there are subdirs, report their specific --help.
2113 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2114 test -d "$ac_dir" ||
2115 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2116 continue
2117 ac_builddir=.
2118
2119case "$ac_dir" in
2120.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2121*)
2122 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
2123 # A ".." for each directory in $ac_dir_suffix.
2124 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
2125 case $ac_top_builddir_sub in
2126 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2127 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2128 esac ;;
2129esac
2130ac_abs_top_builddir=$ac_pwd
2131ac_abs_builddir=$ac_pwd$ac_dir_suffix
2132# for backward compatibility:
2133ac_top_builddir=$ac_top_build_prefix
2134
2135case $srcdir in
2136 .) # We are building in place.
2137 ac_srcdir=.
2138 ac_top_srcdir=$ac_top_builddir_sub
2139 ac_abs_top_srcdir=$ac_pwd ;;
2140 [\\/]* | ?:[\\/]* ) # Absolute name.
2141 ac_srcdir=$srcdir$ac_dir_suffix;
2142 ac_top_srcdir=$srcdir
2143 ac_abs_top_srcdir=$srcdir ;;
2144 *) # Relative name.
2145 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2146 ac_top_srcdir=$ac_top_build_prefix$srcdir
2147 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2148esac
2149ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2150
2151 cd "$ac_dir" || { ac_status=$?; continue; }
2152 # Check for guested configure.
2153 if test -f "$ac_srcdir/configure.gnu"; then
2154 echo &&
2155 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2156 elif test -f "$ac_srcdir/configure"; then
2157 echo &&
2158 $SHELL "$ac_srcdir/configure" --help=recursive
2159 else
2160 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2161 fi || ac_status=$?
2162 cd "$ac_pwd" || { ac_status=$?; break; }
2163 done
2164fi
2165
2166test -n "$ac_init_help" && exit $ac_status
2167if $ac_init_version; then
2168 cat <<\_ACEOF
2169curl configure -
2170generated by GNU Autoconf 2.69
2171
2172Copyright (C) 2012 Free Software Foundation, Inc.
2173This configure script is free software; the Free Software Foundation
2174gives unlimited permission to copy, distribute and modify it.
2175
Haibo Huang51d9d882019-02-06 01:36:06 -08002176Copyright (c) 1998 - 2019 Daniel Stenberg, <daniel@haxx.se>
Elliott Hughes82be86d2017-09-20 17:00:17 -07002177This configure script may be copied, distributed and modified under the
2178terms of the curl license; see COPYING for more details
2179_ACEOF
2180 exit
2181fi
2182
2183## ------------------------ ##
2184## Autoconf initialization. ##
2185## ------------------------ ##
2186
2187# ac_fn_c_try_compile LINENO
2188# --------------------------
2189# Try to compile conftest.$ac_ext, and return whether this succeeded.
2190ac_fn_c_try_compile ()
2191{
2192 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2193 rm -f conftest.$ac_objext
2194 if { { ac_try="$ac_compile"
2195case "(($ac_try" in
2196 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2197 *) ac_try_echo=$ac_try;;
2198esac
2199eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2200$as_echo "$ac_try_echo"; } >&5
2201 (eval "$ac_compile") 2>conftest.err
2202 ac_status=$?
2203 if test -s conftest.err; then
2204 grep -v '^ *+' conftest.err >conftest.er1
2205 cat conftest.er1 >&5
2206 mv -f conftest.er1 conftest.err
2207 fi
2208 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2209 test $ac_status = 0; } && {
2210 test -z "$ac_c_werror_flag" ||
2211 test ! -s conftest.err
2212 } && test -s conftest.$ac_objext; then :
2213 ac_retval=0
2214else
2215 $as_echo "$as_me: failed program was:" >&5
2216sed 's/^/| /' conftest.$ac_ext >&5
2217
2218 ac_retval=1
2219fi
2220 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2221 as_fn_set_status $ac_retval
2222
2223} # ac_fn_c_try_compile
2224
2225# ac_fn_c_try_cpp LINENO
2226# ----------------------
2227# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2228ac_fn_c_try_cpp ()
2229{
2230 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2231 if { { ac_try="$ac_cpp conftest.$ac_ext"
2232case "(($ac_try" in
2233 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2234 *) ac_try_echo=$ac_try;;
2235esac
2236eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2237$as_echo "$ac_try_echo"; } >&5
2238 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2239 ac_status=$?
2240 if test -s conftest.err; then
2241 grep -v '^ *+' conftest.err >conftest.er1
2242 cat conftest.er1 >&5
2243 mv -f conftest.er1 conftest.err
2244 fi
2245 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2246 test $ac_status = 0; } > conftest.i && {
2247 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2248 test ! -s conftest.err
2249 }; then :
2250 ac_retval=0
2251else
2252 $as_echo "$as_me: failed program was:" >&5
2253sed 's/^/| /' conftest.$ac_ext >&5
2254
2255 ac_retval=1
2256fi
2257 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2258 as_fn_set_status $ac_retval
2259
2260} # ac_fn_c_try_cpp
2261
Alex Deymo486467e2017-12-19 19:04:07 +01002262# ac_fn_c_try_link LINENO
2263# -----------------------
2264# Try to link conftest.$ac_ext, and return whether this succeeded.
2265ac_fn_c_try_link ()
2266{
2267 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2268 rm -f conftest.$ac_objext conftest$ac_exeext
2269 if { { ac_try="$ac_link"
2270case "(($ac_try" in
2271 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2272 *) ac_try_echo=$ac_try;;
2273esac
2274eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2275$as_echo "$ac_try_echo"; } >&5
2276 (eval "$ac_link") 2>conftest.err
2277 ac_status=$?
2278 if test -s conftest.err; then
2279 grep -v '^ *+' conftest.err >conftest.er1
2280 cat conftest.er1 >&5
2281 mv -f conftest.er1 conftest.err
2282 fi
2283 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2284 test $ac_status = 0; } && {
2285 test -z "$ac_c_werror_flag" ||
2286 test ! -s conftest.err
2287 } && test -s conftest$ac_exeext && {
2288 test "$cross_compiling" = yes ||
2289 test -x conftest$ac_exeext
2290 }; then :
2291 ac_retval=0
2292else
2293 $as_echo "$as_me: failed program was:" >&5
2294sed 's/^/| /' conftest.$ac_ext >&5
2295
2296 ac_retval=1
2297fi
2298 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2299 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2300 # interfere with the next link command; also delete a directory that is
2301 # left behind by Apple's compiler. We do this before executing the actions.
2302 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2303 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2304 as_fn_set_status $ac_retval
2305
2306} # ac_fn_c_try_link
2307
Elliott Hughes82be86d2017-09-20 17:00:17 -07002308# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2309# -------------------------------------------------------
2310# Tests whether HEADER exists and can be compiled using the include files in
2311# INCLUDES, setting the cache variable VAR accordingly.
2312ac_fn_c_check_header_compile ()
2313{
2314 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2315 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2316$as_echo_n "checking for $2... " >&6; }
2317if eval \${$3+:} false; then :
2318 $as_echo_n "(cached) " >&6
2319else
2320 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2321/* end confdefs.h. */
2322$4
2323#include <$2>
2324_ACEOF
2325if ac_fn_c_try_compile "$LINENO"; then :
2326 eval "$3=yes"
2327else
2328 eval "$3=no"
2329fi
2330rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2331fi
2332eval ac_res=\$$3
2333 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2334$as_echo "$ac_res" >&6; }
2335 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2336
2337} # ac_fn_c_check_header_compile
2338
2339# ac_fn_c_try_run LINENO
2340# ----------------------
2341# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2342# that executables *can* be run.
2343ac_fn_c_try_run ()
2344{
2345 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2346 if { { ac_try="$ac_link"
2347case "(($ac_try" in
2348 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2349 *) ac_try_echo=$ac_try;;
2350esac
2351eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2352$as_echo "$ac_try_echo"; } >&5
2353 (eval "$ac_link") 2>&5
2354 ac_status=$?
2355 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2356 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2357 { { case "(($ac_try" in
2358 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2359 *) ac_try_echo=$ac_try;;
2360esac
2361eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2362$as_echo "$ac_try_echo"; } >&5
2363 (eval "$ac_try") 2>&5
2364 ac_status=$?
2365 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2366 test $ac_status = 0; }; }; then :
2367 ac_retval=0
2368else
2369 $as_echo "$as_me: program exited with status $ac_status" >&5
2370 $as_echo "$as_me: failed program was:" >&5
2371sed 's/^/| /' conftest.$ac_ext >&5
2372
2373 ac_retval=$ac_status
2374fi
2375 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2376 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2377 as_fn_set_status $ac_retval
2378
2379} # ac_fn_c_try_run
2380
Alex Deymo486467e2017-12-19 19:04:07 +01002381# ac_fn_c_check_func LINENO FUNC VAR
2382# ----------------------------------
2383# Tests whether FUNC exists, setting the cache variable VAR accordingly
2384ac_fn_c_check_func ()
2385{
2386 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2387 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2388$as_echo_n "checking for $2... " >&6; }
2389if eval \${$3+:} false; then :
2390 $as_echo_n "(cached) " >&6
2391else
2392 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2393/* end confdefs.h. */
2394
2395#define $2 innocuous_$2
2396#ifdef __STDC__
2397# include <limits.h>
2398#else
2399# include <assert.h>
2400#endif
2401#undef $2
2402#ifdef __cplusplus
2403extern "C"
2404#endif
2405char $2 ();
2406#if defined __stub_$2 || defined __stub___$2
2407choke me
2408#endif
2409
2410int main (void)
2411{
2412return $2 ();
2413 ;
2414 return 0;
2415}
2416_ACEOF
2417if ac_fn_c_try_link "$LINENO"; then :
2418 eval "$3=yes"
2419else
2420 eval "$3=no"
2421fi
2422rm -f core conftest.err conftest.$ac_objext \
2423 conftest$ac_exeext conftest.$ac_ext
2424fi
2425eval ac_res=\$$3
2426 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2427$as_echo "$ac_res" >&6; }
2428 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2429
2430} # ac_fn_c_check_func
2431
2432# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
2433# -------------------------------------------------------
2434# Tests whether HEADER exists, giving a warning if it cannot be compiled using
2435# the include files in INCLUDES and setting the cache variable VAR
2436# accordingly.
2437ac_fn_c_check_header_mongrel ()
2438{
2439 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2440 if eval \${$3+:} false; then :
2441 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2442$as_echo_n "checking for $2... " >&6; }
2443if eval \${$3+:} false; then :
2444 $as_echo_n "(cached) " >&6
2445fi
2446eval ac_res=\$$3
2447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2448$as_echo "$ac_res" >&6; }
2449else
2450 # Is the header compilable?
2451{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2452$as_echo_n "checking $2 usability... " >&6; }
2453cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2454/* end confdefs.h. */
2455$4
2456#include <$2>
2457_ACEOF
2458if ac_fn_c_try_compile "$LINENO"; then :
2459 ac_header_compiler=yes
2460else
2461 ac_header_compiler=no
2462fi
2463rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2464{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2465$as_echo "$ac_header_compiler" >&6; }
2466
2467# Is the header present?
2468{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2469$as_echo_n "checking $2 presence... " >&6; }
2470cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2471/* end confdefs.h. */
2472#include <$2>
2473_ACEOF
2474if ac_fn_c_try_cpp "$LINENO"; then :
2475 ac_header_preproc=yes
2476else
2477 ac_header_preproc=no
2478fi
2479rm -f conftest.err conftest.i conftest.$ac_ext
2480{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2481$as_echo "$ac_header_preproc" >&6; }
2482
2483# So? What about this header?
2484case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
2485 yes:no: )
2486 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2487$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2488 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2489$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2490 ;;
2491 no:yes:* )
2492 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2493$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2494 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
2495$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
2496 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2497$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2498 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
2499$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
2500 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2501$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2502( $as_echo "## ----------------------------------------------------------------------- ##
2503## Report this to a suitable curl mailing list: https://curl.haxx.se/mail/ ##
2504## ----------------------------------------------------------------------- ##"
2505 ) | sed "s/^/$as_me: WARNING: /" >&2
2506 ;;
2507esac
2508 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2509$as_echo_n "checking for $2... " >&6; }
2510if eval \${$3+:} false; then :
2511 $as_echo_n "(cached) " >&6
2512else
2513 eval "$3=\$ac_header_compiler"
2514fi
2515eval ac_res=\$$3
2516 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2517$as_echo "$ac_res" >&6; }
2518fi
2519 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2520
2521} # ac_fn_c_check_header_mongrel
2522
Elliott Hughes82be86d2017-09-20 17:00:17 -07002523# ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2524# -------------------------------------------
2525# Tests whether TYPE exists after having included INCLUDES, setting cache
2526# variable VAR accordingly.
2527ac_fn_c_check_type ()
2528{
2529 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2530 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2531$as_echo_n "checking for $2... " >&6; }
2532if eval \${$3+:} false; then :
2533 $as_echo_n "(cached) " >&6
2534else
2535 eval "$3=no"
2536 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2537/* end confdefs.h. */
2538$4
2539int main (void)
2540{
2541if (sizeof ($2))
2542 return 0;
2543 ;
2544 return 0;
2545}
2546_ACEOF
2547if ac_fn_c_try_compile "$LINENO"; then :
2548 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2549/* end confdefs.h. */
2550$4
2551int main (void)
2552{
2553if (sizeof (($2)))
2554 return 0;
2555 ;
2556 return 0;
2557}
2558_ACEOF
2559if ac_fn_c_try_compile "$LINENO"; then :
2560
2561else
2562 eval "$3=yes"
2563fi
2564rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2565fi
2566rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2567fi
2568eval ac_res=\$$3
2569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2570$as_echo "$ac_res" >&6; }
2571 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2572
2573} # ac_fn_c_check_type
2574
Elliott Hughes72d948d2018-08-03 14:37:21 -07002575# ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
2576# ---------------------------------------------
2577# Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
2578# accordingly.
2579ac_fn_c_check_decl ()
2580{
2581 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2582 as_decl_name=`echo $2|sed 's/ *(.*//'`
2583 as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
2584 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2585$as_echo_n "checking whether $as_decl_name is declared... " >&6; }
2586if eval \${$3+:} false; then :
2587 $as_echo_n "(cached) " >&6
2588else
2589 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2590/* end confdefs.h. */
2591$4
2592int main (void)
2593{
2594#ifndef $as_decl_name
2595#ifdef __cplusplus
2596 (void) $as_decl_use;
2597#else
2598 (void) $as_decl_name;
2599#endif
2600#endif
2601
2602 ;
2603 return 0;
2604}
2605_ACEOF
2606if ac_fn_c_try_compile "$LINENO"; then :
2607 eval "$3=yes"
2608else
2609 eval "$3=no"
2610fi
2611rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2612fi
2613eval ac_res=\$$3
2614 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2615$as_echo "$ac_res" >&6; }
2616 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2617
2618} # ac_fn_c_check_decl
2619
Elliott Hughes82be86d2017-09-20 17:00:17 -07002620# ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2621# ----------------------------------------------------
2622# Tries to find if the field MEMBER exists in type AGGR, after including
2623# INCLUDES, setting cache variable VAR accordingly.
2624ac_fn_c_check_member ()
2625{
2626 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2627 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2628$as_echo_n "checking for $2.$3... " >&6; }
2629if eval \${$4+:} false; then :
2630 $as_echo_n "(cached) " >&6
2631else
2632 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2633/* end confdefs.h. */
2634$5
2635int main (void)
2636{
2637static $2 ac_aggr;
2638if (ac_aggr.$3)
2639return 0;
2640 ;
2641 return 0;
2642}
2643_ACEOF
2644if ac_fn_c_try_compile "$LINENO"; then :
2645 eval "$4=yes"
2646else
2647 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2648/* end confdefs.h. */
2649$5
2650int main (void)
2651{
2652static $2 ac_aggr;
2653if (sizeof ac_aggr.$3)
2654return 0;
2655 ;
2656 return 0;
2657}
2658_ACEOF
2659if ac_fn_c_try_compile "$LINENO"; then :
2660 eval "$4=yes"
2661else
2662 eval "$4=no"
2663fi
2664rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2665fi
2666rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2667fi
2668eval ac_res=\$$4
2669 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2670$as_echo "$ac_res" >&6; }
2671 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2672
2673} # ac_fn_c_check_member
2674cat >config.log <<_ACEOF
2675This file contains any messages produced by compilers while
2676running configure, to aid debugging if configure makes a mistake.
2677
2678It was created by curl $as_me -, which was
2679generated by GNU Autoconf 2.69. Invocation command line was
2680
2681 $ $0 $@
2682
2683_ACEOF
2684exec 5>>config.log
2685{
2686cat <<_ASUNAME
2687## --------- ##
2688## Platform. ##
2689## --------- ##
2690
2691hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2692uname -m = `(uname -m) 2>/dev/null || echo unknown`
2693uname -r = `(uname -r) 2>/dev/null || echo unknown`
2694uname -s = `(uname -s) 2>/dev/null || echo unknown`
2695uname -v = `(uname -v) 2>/dev/null || echo unknown`
2696
2697/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2698/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2699
2700/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2701/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2702/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2703/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2704/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2705/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2706/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2707
2708_ASUNAME
2709
2710as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2711for as_dir in $PATH
2712do
2713 IFS=$as_save_IFS
2714 test -z "$as_dir" && as_dir=.
2715 $as_echo "PATH: $as_dir"
2716 done
2717IFS=$as_save_IFS
2718
2719} >&5
2720
2721cat >&5 <<_ACEOF
2722
2723
2724## ----------- ##
2725## Core tests. ##
2726## ----------- ##
2727
2728_ACEOF
2729
2730
2731# Keep a trace of the command line.
2732# Strip out --no-create and --no-recursion so they do not pile up.
2733# Strip out --silent because we don't want to record it for future runs.
2734# Also quote any args containing shell meta-characters.
2735# Make two passes to allow for proper duplicate-argument suppression.
2736ac_configure_args=
2737ac_configure_args0=
2738ac_configure_args1=
2739ac_must_keep_next=false
2740for ac_pass in 1 2
2741do
2742 for ac_arg
2743 do
2744 case $ac_arg in
2745 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2746 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2747 | -silent | --silent | --silen | --sile | --sil)
2748 continue ;;
2749 *\'*)
2750 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2751 esac
2752 case $ac_pass in
2753 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2754 2)
2755 as_fn_append ac_configure_args1 " '$ac_arg'"
2756 if test $ac_must_keep_next = true; then
2757 ac_must_keep_next=false # Got value, back to normal.
2758 else
2759 case $ac_arg in
2760 *=* | --config-cache | -C | -disable-* | --disable-* \
2761 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2762 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2763 | -with-* | --with-* | -without-* | --without-* | --x)
2764 case "$ac_configure_args0 " in
2765 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2766 esac
2767 ;;
2768 -* ) ac_must_keep_next=true ;;
2769 esac
2770 fi
2771 as_fn_append ac_configure_args " '$ac_arg'"
2772 ;;
2773 esac
2774 done
2775done
2776{ ac_configure_args0=; unset ac_configure_args0;}
2777{ ac_configure_args1=; unset ac_configure_args1;}
2778
2779# When interrupted or exit'd, cleanup temporary files, and complete
2780# config.log. We remove comments because anyway the quotes in there
2781# would cause problems or look ugly.
2782# WARNING: Use '\'' to represent an apostrophe within the trap.
2783# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2784trap 'exit_status=$?
2785 # Save into config.log some information that might help in debugging.
2786 {
2787 echo
2788
2789 $as_echo "## ---------------- ##
2790## Cache variables. ##
2791## ---------------- ##"
2792 echo
2793 # The following way of writing the cache mishandles newlines in values,
2794(
2795 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2796 eval ac_val=\$$ac_var
2797 case $ac_val in #(
2798 *${as_nl}*)
2799 case $ac_var in #(
2800 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2801$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2802 esac
2803 case $ac_var in #(
2804 _ | IFS | as_nl) ;; #(
2805 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2806 *) { eval $ac_var=; unset $ac_var;} ;;
2807 esac ;;
2808 esac
2809 done
2810 (set) 2>&1 |
2811 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2812 *${as_nl}ac_space=\ *)
2813 sed -n \
2814 "s/'\''/'\''\\\\'\'''\''/g;
2815 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2816 ;; #(
2817 *)
2818 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2819 ;;
2820 esac |
2821 sort
2822)
2823 echo
2824
2825 $as_echo "## ----------------- ##
2826## Output variables. ##
2827## ----------------- ##"
2828 echo
2829 for ac_var in $ac_subst_vars
2830 do
2831 eval ac_val=\$$ac_var
2832 case $ac_val in
2833 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2834 esac
2835 $as_echo "$ac_var='\''$ac_val'\''"
2836 done | sort
2837 echo
2838
2839 if test -n "$ac_subst_files"; then
2840 $as_echo "## ------------------- ##
2841## File substitutions. ##
2842## ------------------- ##"
2843 echo
2844 for ac_var in $ac_subst_files
2845 do
2846 eval ac_val=\$$ac_var
2847 case $ac_val in
2848 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2849 esac
2850 $as_echo "$ac_var='\''$ac_val'\''"
2851 done | sort
2852 echo
2853 fi
2854
2855 if test -s confdefs.h; then
2856 $as_echo "## ----------- ##
2857## confdefs.h. ##
2858## ----------- ##"
2859 echo
2860 cat confdefs.h
2861 echo
2862 fi
2863 test "$ac_signal" != 0 &&
2864 $as_echo "$as_me: caught signal $ac_signal"
2865 $as_echo "$as_me: exit $exit_status"
2866 } >&5
2867 rm -f core *.core core.conftest.* &&
2868 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2869 exit $exit_status
2870' 0
2871for ac_signal in 1 2 13 15; do
2872 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2873done
2874ac_signal=0
2875
2876# confdefs.h avoids OS command line length limits that DEFS can exceed.
2877rm -f -r conftest* confdefs.h
2878
2879$as_echo "/* confdefs.h */" > confdefs.h
2880
2881# Predefined preprocessor variables.
2882
2883cat >>confdefs.h <<_ACEOF
2884#define PACKAGE_NAME "$PACKAGE_NAME"
2885_ACEOF
2886
2887cat >>confdefs.h <<_ACEOF
2888#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2889_ACEOF
2890
2891cat >>confdefs.h <<_ACEOF
2892#define PACKAGE_VERSION "$PACKAGE_VERSION"
2893_ACEOF
2894
2895cat >>confdefs.h <<_ACEOF
2896#define PACKAGE_STRING "$PACKAGE_STRING"
2897_ACEOF
2898
2899cat >>confdefs.h <<_ACEOF
2900#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2901_ACEOF
2902
2903cat >>confdefs.h <<_ACEOF
2904#define PACKAGE_URL "$PACKAGE_URL"
2905_ACEOF
2906
2907
2908# Let the site file select an alternate cache file if it wants to.
2909# Prefer an explicitly selected file to automatically selected ones.
2910ac_site_file1=NONE
2911ac_site_file2=NONE
2912if test -n "$CONFIG_SITE"; then
2913 # We do not want a PATH search for config.site.
2914 case $CONFIG_SITE in #((
2915 -*) ac_site_file1=./$CONFIG_SITE;;
2916 */*) ac_site_file1=$CONFIG_SITE;;
2917 *) ac_site_file1=./$CONFIG_SITE;;
2918 esac
2919elif test "x$prefix" != xNONE; then
2920 ac_site_file1=$prefix/share/config.site
2921 ac_site_file2=$prefix/etc/config.site
2922else
2923 ac_site_file1=$ac_default_prefix/share/config.site
2924 ac_site_file2=$ac_default_prefix/etc/config.site
2925fi
2926for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2927do
2928 test "x$ac_site_file" = xNONE && continue
2929 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
2930 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2931$as_echo "$as_me: loading site script $ac_site_file" >&6;}
2932 sed 's/^/| /' "$ac_site_file" >&5
2933 . "$ac_site_file" \
2934 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2935$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2936as_fn_error $? "failed to load site script $ac_site_file
2937See \`config.log' for more details" "$LINENO" 5; }
2938 fi
2939done
2940
2941if test -r "$cache_file"; then
2942 # Some versions of bash will fail to source /dev/null (special files
2943 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
2944 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2945 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2946$as_echo "$as_me: loading cache $cache_file" >&6;}
2947 case $cache_file in
2948 [\\/]* | ?:[\\/]* ) . "$cache_file";;
2949 *) . "./$cache_file";;
2950 esac
2951 fi
2952else
2953 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2954$as_echo "$as_me: creating cache $cache_file" >&6;}
2955 >$cache_file
2956fi
2957
2958# Check that the precious variables saved in the cache have kept the same
2959# value.
2960ac_cache_corrupted=false
2961for ac_var in $ac_precious_vars; do
2962 eval ac_old_set=\$ac_cv_env_${ac_var}_set
2963 eval ac_new_set=\$ac_env_${ac_var}_set
2964 eval ac_old_val=\$ac_cv_env_${ac_var}_value
2965 eval ac_new_val=\$ac_env_${ac_var}_value
2966 case $ac_old_set,$ac_new_set in
2967 set,)
2968 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2969$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2970 ac_cache_corrupted=: ;;
2971 ,set)
2972 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2973$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2974 ac_cache_corrupted=: ;;
2975 ,);;
2976 *)
2977 if test "x$ac_old_val" != "x$ac_new_val"; then
2978 # differences in whitespace do not lead to failure.
2979 ac_old_val_w=`echo x $ac_old_val`
2980 ac_new_val_w=`echo x $ac_new_val`
2981 if test "$ac_old_val_w" != "$ac_new_val_w"; then
2982 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2983$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2984 ac_cache_corrupted=:
2985 else
2986 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2987$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2988 eval $ac_var=\$ac_old_val
2989 fi
2990 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
2991$as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
2992 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
2993$as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
2994 fi;;
2995 esac
2996 # Pass precious variables to config.status.
2997 if test "$ac_new_set" = set; then
2998 case $ac_new_val in
2999 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3000 *) ac_arg=$ac_var=$ac_new_val ;;
3001 esac
3002 case " $ac_configure_args " in
3003 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
3004 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3005 esac
3006 fi
3007done
3008if $ac_cache_corrupted; then
3009 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3010$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3011 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3012$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
3013 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3014fi
3015## -------------------- ##
3016## Main body of script. ##
3017## -------------------- ##
3018
3019ac_ext=c
3020ac_cpp='$CPP $CPPFLAGS'
3021ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3022ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3023ac_compiler_gnu=$ac_cv_c_compiler_gnu
3024
3025
3026
3027
3028
3029
3030
3031# using curl-override.m4
3032
3033
3034
3035
3036
3037ac_config_headers="$ac_config_headers lib/curl_config.h"
3038
3039
3040
3041{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
3042$as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
3043 # Check whether --enable-maintainer-mode was given.
3044if test "${enable_maintainer_mode+set}" = set; then :
3045 enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
3046else
3047 USE_MAINTAINER_MODE=no
3048fi
3049
3050 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5
3051$as_echo "$USE_MAINTAINER_MODE" >&6; }
3052 if test $USE_MAINTAINER_MODE = yes; then
3053 MAINTAINER_MODE_TRUE=
3054 MAINTAINER_MODE_FALSE='#'
3055else
3056 MAINTAINER_MODE_TRUE='#'
3057 MAINTAINER_MODE_FALSE=
3058fi
3059
3060 MAINT=$MAINTAINER_MODE_TRUE
3061
3062
3063# Check whether --enable-silent-rules was given.
3064if test "${enable_silent_rules+set}" = set; then :
3065 enableval=$enable_silent_rules;
3066fi
3067
3068case $enable_silent_rules in # (((
3069 yes) AM_DEFAULT_VERBOSITY=0;;
3070 no) AM_DEFAULT_VERBOSITY=1;;
3071 *) AM_DEFAULT_VERBOSITY=0;;
3072esac
3073am_make=${MAKE-make}
3074{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
3075$as_echo_n "checking whether $am_make supports nested variables... " >&6; }
3076if ${am_cv_make_support_nested_variables+:} false; then :
3077 $as_echo_n "(cached) " >&6
3078else
3079 if $as_echo 'TRUE=$(BAR$(V))
3080BAR0=false
3081BAR1=true
3082V=1
3083am__doit:
3084 @$(TRUE)
3085.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
3086 am_cv_make_support_nested_variables=yes
3087else
3088 am_cv_make_support_nested_variables=no
3089fi
3090fi
3091{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
3092$as_echo "$am_cv_make_support_nested_variables" >&6; }
3093if test $am_cv_make_support_nested_variables = yes; then
3094 AM_V='$(V)'
3095 AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
3096else
3097 AM_V=$AM_DEFAULT_VERBOSITY
3098 AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
3099fi
3100AM_BACKSLASH='\'
3101
3102
3103
3104 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable debug build options" >&5
3105$as_echo_n "checking whether to enable debug build options... " >&6; }
3106 OPT_DEBUG_BUILD="default"
3107 # Check whether --enable-debug was given.
3108if test "${enable_debug+set}" = set; then :
3109 enableval=$enable_debug; OPT_DEBUG_BUILD=$enableval
3110fi
3111
3112 case "$OPT_DEBUG_BUILD" in
3113 no)
3114 want_debug="no"
3115 ;;
3116 default)
3117 want_debug="no"
3118 ;;
3119 *)
3120 want_debug="yes"
Elliott Hughes1ef06ba2018-05-30 15:43:58 -07003121
3122$as_echo "#define DEBUGBUILD 1" >>confdefs.h
3123
Elliott Hughes82be86d2017-09-20 17:00:17 -07003124 ;;
3125 esac
3126 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $want_debug" >&5
3127$as_echo "$want_debug" >&6; }
3128
3129
3130 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable compiler optimizer" >&5
3131$as_echo_n "checking whether to enable compiler optimizer... " >&6; }
3132 OPT_COMPILER_OPTIMIZE="default"
3133 # Check whether --enable-optimize was given.
3134if test "${enable_optimize+set}" = set; then :
3135 enableval=$enable_optimize; OPT_COMPILER_OPTIMIZE=$enableval
3136fi
3137
3138 case "$OPT_COMPILER_OPTIMIZE" in
3139 no)
3140 want_optimize="no"
3141 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3142$as_echo "no" >&6; }
3143 ;;
3144 default)
3145 if test "$want_debug" = "yes"; then
3146 want_optimize="assume_no"
3147 { $as_echo "$as_me:${as_lineno-$LINENO}: result: (assumed) no" >&5
3148$as_echo "(assumed) no" >&6; }
3149 else
3150 want_optimize="assume_yes"
3151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: (assumed) yes" >&5
3152$as_echo "(assumed) yes" >&6; }
3153 fi
3154 ;;
3155 *)
3156 want_optimize="yes"
3157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3158$as_echo "yes" >&6; }
3159 ;;
3160 esac
3161
3162
3163 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable strict compiler warnings" >&5
3164$as_echo_n "checking whether to enable strict compiler warnings... " >&6; }
3165 OPT_COMPILER_WARNINGS="default"
3166 # Check whether --enable-warnings was given.
3167if test "${enable_warnings+set}" = set; then :
3168 enableval=$enable_warnings; OPT_COMPILER_WARNINGS=$enableval
3169fi
3170
3171 case "$OPT_COMPILER_WARNINGS" in
3172 no)
3173 want_warnings="no"
3174 ;;
3175 default)
3176 want_warnings="$want_debug"
3177 ;;
3178 *)
3179 want_warnings="yes"
3180 ;;
3181 esac
3182 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $want_warnings" >&5
3183$as_echo "$want_warnings" >&6; }
3184
3185
3186 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable compiler warnings as errors" >&5
3187$as_echo_n "checking whether to enable compiler warnings as errors... " >&6; }
3188 OPT_COMPILER_WERROR="default"
3189 # Check whether --enable-werror was given.
3190if test "${enable_werror+set}" = set; then :
3191 enableval=$enable_werror; OPT_COMPILER_WERROR=$enableval
3192fi
3193
3194 case "$OPT_COMPILER_WERROR" in
3195 no)
3196 want_werror="no"
3197 ;;
3198 default)
3199 want_werror="no"
3200 ;;
3201 *)
3202 want_werror="yes"
3203 ;;
3204 esac
3205 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $want_werror" >&5
3206$as_echo "$want_werror" >&6; }
3207
3208
3209 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable curl debug memory tracking" >&5
3210$as_echo_n "checking whether to enable curl debug memory tracking... " >&6; }
3211 OPT_CURLDEBUG_BUILD="default"
3212 # Check whether --enable-curldebug was given.
3213if test "${enable_curldebug+set}" = set; then :
3214 enableval=$enable_curldebug; OPT_CURLDEBUG_BUILD=$enableval
3215fi
3216
3217 case "$OPT_CURLDEBUG_BUILD" in
3218 no)
3219 want_curldebug="no"
3220 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3221$as_echo "no" >&6; }
3222 ;;
3223 default)
3224 if test "$want_debug" = "yes"; then
3225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: (assumed) yes" >&5
3226$as_echo "(assumed) yes" >&6; }
Elliott Hughes1ef06ba2018-05-30 15:43:58 -07003227
3228$as_echo "#define CURLDEBUG 1" >>confdefs.h
3229
Elliott Hughes82be86d2017-09-20 17:00:17 -07003230 else
3231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3232$as_echo "no" >&6; }
3233 fi
3234 want_curldebug_assumed="yes"
3235 want_curldebug="$want_debug"
3236 ;;
3237 *)
3238 want_curldebug="yes"
Elliott Hughes1ef06ba2018-05-30 15:43:58 -07003239
3240$as_echo "#define CURLDEBUG 1" >>confdefs.h
3241
Elliott Hughes82be86d2017-09-20 17:00:17 -07003242 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3243$as_echo "yes" >&6; }
3244 ;;
3245 esac
3246
3247
3248 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable hiding of library internal symbols" >&5
3249$as_echo_n "checking whether to enable hiding of library internal symbols... " >&6; }
3250 OPT_SYMBOL_HIDING="default"
3251 # Check whether --enable-symbol-hiding was given.
3252if test "${enable_symbol_hiding+set}" = set; then :
3253 enableval=$enable_symbol_hiding; OPT_SYMBOL_HIDING=$enableval
3254fi
3255
3256 # Check whether --enable-hidden-symbols was given.
3257if test "${enable_hidden_symbols+set}" = set; then :
3258 enableval=$enable_hidden_symbols; OPT_SYMBOL_HIDING=$enableval
3259fi
3260
3261 case "$OPT_SYMBOL_HIDING" in
3262 no)
3263 want_symbol_hiding="no"
3264 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3265$as_echo "no" >&6; }
3266 ;;
3267 default)
3268 want_symbol_hiding="yes"
3269 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3270$as_echo "yes" >&6; }
3271 ;;
3272 *)
3273 want_symbol_hiding="yes"
3274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3275$as_echo "yes" >&6; }
3276 ;;
3277 esac
3278
3279
3280 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable c-ares for DNS lookups" >&5
3281$as_echo_n "checking whether to enable c-ares for DNS lookups... " >&6; }
3282 OPT_ARES="default"
3283 # Check whether --enable-ares was given.
3284if test "${enable_ares+set}" = set; then :
3285 enableval=$enable_ares; OPT_ARES=$enableval
3286fi
3287
3288 case "$OPT_ARES" in
3289 no)
3290 want_ares="no"
3291 ;;
3292 default)
3293 want_ares="no"
3294 ;;
3295 *)
3296 want_ares="yes"
3297 if test -n "$enableval" && test "$enableval" != "yes"; then
3298 want_ares_path="$enableval"
3299 fi
3300 ;;
3301 esac
3302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $want_ares" >&5
3303$as_echo "$want_ares" >&6; }
3304
3305
3306 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to disable dependency on -lrt" >&5
3307$as_echo_n "checking whether to disable dependency on -lrt... " >&6; }
3308 OPT_RT="default"
3309 # Check whether --enable-rt was given.
3310if test "${enable_rt+set}" = set; then :
3311 enableval=$enable_rt; OPT_RT=$enableval
3312fi
3313
3314 case "$OPT_RT" in
3315 no)
3316 dontwant_rt="yes"
3317 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3318$as_echo "yes" >&6; }
3319 ;;
3320 default)
3321 dontwant_rt="no"
3322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: (assumed no)" >&5
3323$as_echo "(assumed no)" >&6; }
3324 ;;
3325 *)
3326 dontwant_rt="no"
3327 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3328$as_echo "no" >&6; }
3329 ;;
3330 esac
3331
3332
Haibo Huang31944072019-11-06 02:28:57 -08003333 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable ESNI support" >&5
3334$as_echo_n "checking whether to enable ESNI support... " >&6; }
3335 OPT_ESNI="default"
3336 # Check whether --enable-esni was given.
3337if test "${enable_esni+set}" = set; then :
3338 enableval=$enable_esni; OPT_ESNI=$enableval
3339fi
3340
3341 case "$OPT_ESNI" in
3342 no)
3343 want_esni="no"
3344 curl_esni_msg="no (--enable-esni)"
3345 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3346$as_echo "no" >&6; }
3347 ;;
3348 default)
3349 want_esni="no"
3350 curl_esni_msg="no (--enable-esni)"
3351 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3352$as_echo "no" >&6; }
3353 ;;
3354 *)
3355 want_esni="yes"
3356 curl_esni_msg="enabled (--disable-esni)"
3357 experimental="esni"
3358 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3359$as_echo "yes" >&6; }
3360 ;;
3361 esac
3362
3363
Elliott Hughes82be86d2017-09-20 17:00:17 -07003364#
3365# Check that 'XC_CONFIGURE_PREAMBLE' has already run.
3366#
3367
3368if test -z "$xc_configure_preamble_result"; then
3369 as_fn_error $? "xc_configure_preamble_result not set (internal problem)" "$LINENO" 5
3370fi
3371
3372#
3373# Check that 'PATH_SEPARATOR' has already been set.
3374#
3375
3376if test -z "$xc_PATH_SEPARATOR"; then
3377 as_fn_error $? "xc_PATH_SEPARATOR not set (internal problem)" "$LINENO" 5
3378fi
3379if test -z "$PATH_SEPARATOR"; then
3380 as_fn_error $? "PATH_SEPARATOR not set (internal or config.site problem)" "$LINENO" 5
3381fi
3382{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for path separator" >&5
3383$as_echo_n "checking for path separator... " >&6; }
3384{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATH_SEPARATOR" >&5
3385$as_echo "$PATH_SEPARATOR" >&6; }
3386if test "x$PATH_SEPARATOR" != "x$xc_PATH_SEPARATOR"; then
3387 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for initial path separator" >&5
3388$as_echo_n "checking for initial path separator... " >&6; }
3389 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $xc_PATH_SEPARATOR" >&5
3390$as_echo "$xc_PATH_SEPARATOR" >&6; }
3391 as_fn_error $? "path separator mismatch (internal or config.site problem)" "$LINENO" 5
3392fi
3393
Elliott Hughes82be86d2017-09-20 17:00:17 -07003394
3395#
3396# save the configure arguments
3397#
3398CONFIGURE_OPTIONS="\"$ac_configure_args\""
3399
3400
3401CURL_CFLAG_EXTRAS=""
3402if test X"$want_werror" = Xyes; then
3403 CURL_CFLAG_EXTRAS="-Werror"
Elliott Hughesb1ef70f2018-10-30 11:28:38 -07003404 if test "$compiler_id" = "GNU_C"; then
3405 if test "$compiler_num" -ge "500"; then
3406 CURL_CFLAG_EXTRAS="$CURL_CFLAG_EXTRAS -pedantic-errors"
3407 fi
3408 fi
Elliott Hughes82be86d2017-09-20 17:00:17 -07003409fi
3410
3411
3412if test -z "$SED"; then
3413 # Extract the first word of "sed", so it can be a program name with args.
3414set dummy sed; ac_word=$2
3415{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3416$as_echo_n "checking for $ac_word... " >&6; }
3417if ${ac_cv_path_SED+:} false; then :
3418 $as_echo_n "(cached) " >&6
3419else
3420 case $SED in
3421 [\\/]* | ?:[\\/]*)
3422 ac_cv_path_SED="$SED" # Let the user override the test with a path.
3423 ;;
3424 *)
3425 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3426as_dummy="$PATH:/usr/bin:/usr/local/bin"
3427for as_dir in $as_dummy
3428do
3429 IFS=$as_save_IFS
3430 test -z "$as_dir" && as_dir=.
3431 for ac_exec_ext in '' $ac_executable_extensions; do
3432 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3433 ac_cv_path_SED="$as_dir/$ac_word$ac_exec_ext"
3434 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3435 break 2
3436 fi
3437done
3438 done
3439IFS=$as_save_IFS
3440
3441 test -z "$ac_cv_path_SED" && ac_cv_path_SED="not_found"
3442 ;;
3443esac
3444fi
3445SED=$ac_cv_path_SED
3446if test -n "$SED"; then
3447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SED" >&5
3448$as_echo "$SED" >&6; }
3449else
3450 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3451$as_echo "no" >&6; }
3452fi
3453
3454
3455 if test -z "$SED" || test "$SED" = "not_found"; then
3456 as_fn_error $? "sed not found in PATH. Cannot continue without sed." "$LINENO" 5
3457 fi
3458fi
3459
3460
3461if test -z "$GREP"; then
3462 # Extract the first word of "grep", so it can be a program name with args.
3463set dummy grep; ac_word=$2
3464{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3465$as_echo_n "checking for $ac_word... " >&6; }
3466if ${ac_cv_path_GREP+:} false; then :
3467 $as_echo_n "(cached) " >&6
3468else
3469 case $GREP in
3470 [\\/]* | ?:[\\/]*)
3471 ac_cv_path_GREP="$GREP" # Let the user override the test with a path.
3472 ;;
3473 *)
3474 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3475as_dummy="$PATH:/usr/bin:/usr/local/bin"
3476for as_dir in $as_dummy
3477do
3478 IFS=$as_save_IFS
3479 test -z "$as_dir" && as_dir=.
3480 for ac_exec_ext in '' $ac_executable_extensions; do
3481 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3482 ac_cv_path_GREP="$as_dir/$ac_word$ac_exec_ext"
3483 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3484 break 2
3485 fi
3486done
3487 done
3488IFS=$as_save_IFS
3489
3490 test -z "$ac_cv_path_GREP" && ac_cv_path_GREP="not_found"
3491 ;;
3492esac
3493fi
3494GREP=$ac_cv_path_GREP
3495if test -n "$GREP"; then
3496 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GREP" >&5
3497$as_echo "$GREP" >&6; }
3498else
3499 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3500$as_echo "no" >&6; }
3501fi
3502
3503
3504 if test -z "$GREP" || test "$GREP" = "not_found"; then
3505 as_fn_error $? "grep not found in PATH. Cannot continue without grep." "$LINENO" 5
3506 fi
3507fi
3508
3509
3510if test -z "$EGREP"; then
3511 if echo a | ($GREP -E '(a|b)') >/dev/null 2>&1; then
3512 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
3513$as_echo_n "checking for egrep... " >&6; }
3514 EGREP="$GREP -E"
3515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EGREP" >&5
3516$as_echo "$EGREP" >&6; }
3517 else
3518 # Extract the first word of "egrep", so it can be a program name with args.
3519set dummy egrep; ac_word=$2
3520{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3521$as_echo_n "checking for $ac_word... " >&6; }
3522if ${ac_cv_path_EGREP+:} false; then :
3523 $as_echo_n "(cached) " >&6
3524else
3525 case $EGREP in
3526 [\\/]* | ?:[\\/]*)
3527 ac_cv_path_EGREP="$EGREP" # Let the user override the test with a path.
3528 ;;
3529 *)
3530 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3531as_dummy="$PATH:/usr/bin:/usr/local/bin"
3532for as_dir in $as_dummy
3533do
3534 IFS=$as_save_IFS
3535 test -z "$as_dir" && as_dir=.
3536 for ac_exec_ext in '' $ac_executable_extensions; do
3537 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3538 ac_cv_path_EGREP="$as_dir/$ac_word$ac_exec_ext"
3539 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3540 break 2
3541 fi
3542done
3543 done
3544IFS=$as_save_IFS
3545
3546 test -z "$ac_cv_path_EGREP" && ac_cv_path_EGREP="not_found"
3547 ;;
3548esac
3549fi
3550EGREP=$ac_cv_path_EGREP
3551if test -n "$EGREP"; then
3552 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EGREP" >&5
3553$as_echo "$EGREP" >&6; }
3554else
3555 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3556$as_echo "no" >&6; }
3557fi
3558
3559
3560 fi
3561fi
3562if test -z "$EGREP" || test "$EGREP" = "not_found"; then
3563 as_fn_error $? "egrep not found in PATH. Cannot continue without egrep." "$LINENO" 5
3564fi
3565
3566
3567if test -z "$AR"; then
3568 if test -n "$ac_tool_prefix"; then
3569 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
3570set dummy ${ac_tool_prefix}ar; ac_word=$2
3571{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3572$as_echo_n "checking for $ac_word... " >&6; }
3573if ${ac_cv_path_AR+:} false; then :
3574 $as_echo_n "(cached) " >&6
3575else
3576 case $AR in
3577 [\\/]* | ?:[\\/]*)
3578 ac_cv_path_AR="$AR" # Let the user override the test with a path.
3579 ;;
3580 *)
3581 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3582as_dummy="$PATH:/usr/bin:/usr/local/bin"
3583for as_dir in $as_dummy
3584do
3585 IFS=$as_save_IFS
3586 test -z "$as_dir" && as_dir=.
3587 for ac_exec_ext in '' $ac_executable_extensions; do
3588 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3589 ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext"
3590 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3591 break 2
3592 fi
3593done
3594 done
3595IFS=$as_save_IFS
3596
3597 ;;
3598esac
3599fi
3600AR=$ac_cv_path_AR
3601if test -n "$AR"; then
3602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
3603$as_echo "$AR" >&6; }
3604else
3605 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3606$as_echo "no" >&6; }
3607fi
3608
3609
3610fi
3611if test -z "$ac_cv_path_AR"; then
3612 ac_pt_AR=$AR
3613 # Extract the first word of "ar", so it can be a program name with args.
3614set dummy ar; ac_word=$2
3615{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3616$as_echo_n "checking for $ac_word... " >&6; }
3617if ${ac_cv_path_ac_pt_AR+:} false; then :
3618 $as_echo_n "(cached) " >&6
3619else
3620 case $ac_pt_AR in
3621 [\\/]* | ?:[\\/]*)
3622 ac_cv_path_ac_pt_AR="$ac_pt_AR" # Let the user override the test with a path.
3623 ;;
3624 *)
3625 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3626as_dummy="$PATH:/usr/bin:/usr/local/bin"
3627for as_dir in $as_dummy
3628do
3629 IFS=$as_save_IFS
3630 test -z "$as_dir" && as_dir=.
3631 for ac_exec_ext in '' $ac_executable_extensions; do
3632 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3633 ac_cv_path_ac_pt_AR="$as_dir/$ac_word$ac_exec_ext"
3634 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3635 break 2
3636 fi
3637done
3638 done
3639IFS=$as_save_IFS
3640
3641 ;;
3642esac
3643fi
3644ac_pt_AR=$ac_cv_path_ac_pt_AR
3645if test -n "$ac_pt_AR"; then
3646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_AR" >&5
3647$as_echo "$ac_pt_AR" >&6; }
3648else
3649 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3650$as_echo "no" >&6; }
3651fi
3652
3653 if test "x$ac_pt_AR" = x; then
3654 AR="not_found"
3655 else
3656 case $cross_compiling:$ac_tool_warned in
3657yes:)
3658{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3659$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3660ac_tool_warned=yes ;;
3661esac
3662 AR=$ac_pt_AR
3663 fi
3664else
3665 AR="$ac_cv_path_AR"
3666fi
3667
3668 if test -z "$AR" || test "$AR" = "not_found"; then
3669 as_fn_error $? "ar not found in PATH. Cannot continue without ar." "$LINENO" 5
3670 fi
3671fi
3672
3673
3674
3675
3676CURLVERSION=`$SED -ne 's/^#define LIBCURL_VERSION "\(.*\)".*/\1/p' ${srcdir}/include/curl/curlver.h`
3677
3678 xc_prog_cc_prev_IFS=$IFS
3679 xc_prog_cc_prev_LIBS=$LIBS
3680 xc_prog_cc_prev_CFLAGS=$CFLAGS
3681 xc_prog_cc_prev_LDFLAGS=$LDFLAGS
3682 xc_prog_cc_prev_CPPFLAGS=$CPPFLAGS
3683
3684
3685
3686 xc_bad_var_libs=no
3687 for xc_word in $LIBS; do
3688 case "$xc_word" in
3689 -l* | --library=*)
3690 :
3691 ;;
3692 *)
3693 xc_bad_var_libs=yes
3694 ;;
3695 esac
3696 done
3697 if test $xc_bad_var_libs = yes; then
3698 { $as_echo "$as_me:${as_lineno-$LINENO}: using LIBS: $LIBS" >&5
3699$as_echo "$as_me: using LIBS: $LIBS" >&6;}
3700 { $as_echo "$as_me:${as_lineno-$LINENO}: LIBS note: LIBS should only be used to specify libraries (-lname)." >&5
3701$as_echo "$as_me: LIBS note: LIBS should only be used to specify libraries (-lname)." >&6;}
3702 fi
3703
3704
3705 xc_bad_var_ldflags=no
3706 for xc_word in $LDFLAGS; do
3707 case "$xc_word" in
3708 -D*)
3709 xc_bad_var_ldflags=yes
3710 ;;
3711 -U*)
3712 xc_bad_var_ldflags=yes
3713 ;;
3714 -I*)
3715 xc_bad_var_ldflags=yes
3716 ;;
3717 -l* | --library=*)
3718 xc_bad_var_ldflags=yes
3719 ;;
3720 esac
3721 done
3722 if test $xc_bad_var_ldflags = yes; then
3723 { $as_echo "$as_me:${as_lineno-$LINENO}: using LDFLAGS: $LDFLAGS" >&5
3724$as_echo "$as_me: using LDFLAGS: $LDFLAGS" >&6;}
3725 xc_bad_var_msg="LDFLAGS note: LDFLAGS should only be used to specify linker flags, not"
3726 for xc_word in $LDFLAGS; do
3727 case "$xc_word" in
3728 -D*)
3729 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg macro definitions. Use CPPFLAGS for: $xc_word" >&5
3730$as_echo "$as_me: $xc_bad_var_msg macro definitions. Use CPPFLAGS for: $xc_word" >&6;}
3731 ;;
3732 -U*)
3733 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg macro suppressions. Use CPPFLAGS for: $xc_word" >&5
3734$as_echo "$as_me: $xc_bad_var_msg macro suppressions. Use CPPFLAGS for: $xc_word" >&6;}
3735 ;;
3736 -I*)
3737 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg include directories. Use CPPFLAGS for: $xc_word" >&5
3738$as_echo "$as_me: $xc_bad_var_msg include directories. Use CPPFLAGS for: $xc_word" >&6;}
3739 ;;
3740 -l* | --library=*)
3741 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg libraries. Use LIBS for: $xc_word" >&5
3742$as_echo "$as_me: $xc_bad_var_msg libraries. Use LIBS for: $xc_word" >&6;}
3743 ;;
3744 esac
3745 done
3746 fi
3747
3748
3749 xc_bad_var_cppflags=no
3750 for xc_word in $CPPFLAGS; do
3751 case "$xc_word" in
3752 -rpath*)
3753 xc_bad_var_cppflags=yes
3754 ;;
3755 -L* | --library-path=*)
3756 xc_bad_var_cppflags=yes
3757 ;;
3758 -l* | --library=*)
3759 xc_bad_var_cppflags=yes
3760 ;;
3761 esac
3762 done
3763 if test $xc_bad_var_cppflags = yes; then
3764 { $as_echo "$as_me:${as_lineno-$LINENO}: using CPPFLAGS: $CPPFLAGS" >&5
3765$as_echo "$as_me: using CPPFLAGS: $CPPFLAGS" >&6;}
3766 xc_bad_var_msg="CPPFLAGS note: CPPFLAGS should only be used to specify C preprocessor flags, not"
3767 for xc_word in $CPPFLAGS; do
3768 case "$xc_word" in
3769 -rpath*)
3770 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg library runtime directories. Use LDFLAGS for: $xc_word" >&5
3771$as_echo "$as_me: $xc_bad_var_msg library runtime directories. Use LDFLAGS for: $xc_word" >&6;}
3772 ;;
3773 -L* | --library-path=*)
3774 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg library directories. Use LDFLAGS for: $xc_word" >&5
3775$as_echo "$as_me: $xc_bad_var_msg library directories. Use LDFLAGS for: $xc_word" >&6;}
3776 ;;
3777 -l* | --library=*)
3778 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg libraries. Use LIBS for: $xc_word" >&5
3779$as_echo "$as_me: $xc_bad_var_msg libraries. Use LIBS for: $xc_word" >&6;}
3780 ;;
3781 esac
3782 done
3783 fi
3784
3785
3786 xc_bad_var_cflags=no
3787 for xc_word in $CFLAGS; do
3788 case "$xc_word" in
3789 -D*)
3790 xc_bad_var_cflags=yes
3791 ;;
3792 -U*)
3793 xc_bad_var_cflags=yes
3794 ;;
3795 -I*)
3796 xc_bad_var_cflags=yes
3797 ;;
3798 -rpath*)
3799 xc_bad_var_cflags=yes
3800 ;;
3801 -L* | --library-path=*)
3802 xc_bad_var_cflags=yes
3803 ;;
3804 -l* | --library=*)
3805 xc_bad_var_cflags=yes
3806 ;;
3807 esac
3808 done
3809 if test $xc_bad_var_cflags = yes; then
3810 { $as_echo "$as_me:${as_lineno-$LINENO}: using CFLAGS: $CFLAGS" >&5
3811$as_echo "$as_me: using CFLAGS: $CFLAGS" >&6;}
3812 xc_bad_var_msg="CFLAGS note: CFLAGS should only be used to specify C compiler flags, not"
3813 for xc_word in $CFLAGS; do
3814 case "$xc_word" in
3815 -D*)
3816 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg macro definitions. Use CPPFLAGS for: $xc_word" >&5
3817$as_echo "$as_me: $xc_bad_var_msg macro definitions. Use CPPFLAGS for: $xc_word" >&6;}
3818 ;;
3819 -U*)
3820 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg macro suppressions. Use CPPFLAGS for: $xc_word" >&5
3821$as_echo "$as_me: $xc_bad_var_msg macro suppressions. Use CPPFLAGS for: $xc_word" >&6;}
3822 ;;
3823 -I*)
3824 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg include directories. Use CPPFLAGS for: $xc_word" >&5
3825$as_echo "$as_me: $xc_bad_var_msg include directories. Use CPPFLAGS for: $xc_word" >&6;}
3826 ;;
3827 -rpath*)
3828 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg library runtime directories. Use LDFLAGS for: $xc_word" >&5
3829$as_echo "$as_me: $xc_bad_var_msg library runtime directories. Use LDFLAGS for: $xc_word" >&6;}
3830 ;;
3831 -L* | --library-path=*)
3832 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg library directories. Use LDFLAGS for: $xc_word" >&5
3833$as_echo "$as_me: $xc_bad_var_msg library directories. Use LDFLAGS for: $xc_word" >&6;}
3834 ;;
3835 -l* | --library=*)
3836 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg libraries. Use LIBS for: $xc_word" >&5
3837$as_echo "$as_me: $xc_bad_var_msg libraries. Use LIBS for: $xc_word" >&6;}
3838 ;;
3839 esac
3840 done
3841 fi
3842
3843 if test $xc_bad_var_libs = yes ||
3844 test $xc_bad_var_cflags = yes ||
3845 test $xc_bad_var_ldflags = yes ||
3846 test $xc_bad_var_cppflags = yes; then
3847 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Continuing even with errors mentioned immediately above this line." >&5
3848$as_echo "$as_me: WARNING: Continuing even with errors mentioned immediately above this line." >&2;}
3849 fi
3850
3851ac_aux_dir=
3852for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
3853 if test -f "$ac_dir/install-sh"; then
3854 ac_aux_dir=$ac_dir
3855 ac_install_sh="$ac_aux_dir/install-sh -c"
3856 break
3857 elif test -f "$ac_dir/install.sh"; then
3858 ac_aux_dir=$ac_dir
3859 ac_install_sh="$ac_aux_dir/install.sh -c"
3860 break
3861 elif test -f "$ac_dir/shtool"; then
3862 ac_aux_dir=$ac_dir
3863 ac_install_sh="$ac_aux_dir/shtool install -c"
3864 break
3865 fi
3866done
3867if test -z "$ac_aux_dir"; then
3868 as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
3869fi
3870
3871# These three variables are undocumented and unsupported,
3872# and are intended to be withdrawn in a future Autoconf release.
3873# They can cause serious problems if a builder's source tree is in a directory
3874# whose full name contains unusual characters.
3875ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
3876ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
3877ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
3878
3879
3880# Find a good install program. We prefer a C program (faster),
3881# so one script is as good as another. But avoid the broken or
3882# incompatible versions:
3883# SysV /etc/install, /usr/sbin/install
3884# SunOS /usr/etc/install
3885# IRIX /sbin/install
3886# AIX /bin/install
3887# AmigaOS /C/install, which installs bootblocks on floppy discs
3888# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3889# AFS /usr/afsws/bin/install, which mishandles nonexistent args
3890# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3891# OS/2's system install, which has a completely different semantic
3892# ./install, which can be erroneously created by make from ./install.sh.
3893# Reject install programs that cannot install multiple files.
3894{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
3895$as_echo_n "checking for a BSD-compatible install... " >&6; }
3896if test -z "$INSTALL"; then
3897if ${ac_cv_path_install+:} false; then :
3898 $as_echo_n "(cached) " >&6
3899else
3900 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3901for as_dir in $PATH
3902do
3903 IFS=$as_save_IFS
3904 test -z "$as_dir" && as_dir=.
3905 # Account for people who put trailing slashes in PATH elements.
3906case $as_dir/ in #((
3907 ./ | .// | /[cC]/* | \
3908 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3909 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
3910 /usr/ucb/* ) ;;
3911 *)
3912 # OSF1 and SCO ODT 3.0 have their own names for install.
3913 # Don't use installbsd from OSF since it installs stuff as root
3914 # by default.
3915 for ac_prog in ginstall scoinst install; do
3916 for ac_exec_ext in '' $ac_executable_extensions; do
3917 if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
3918 if test $ac_prog = install &&
3919 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3920 # AIX install. It has an incompatible calling convention.
3921 :
3922 elif test $ac_prog = install &&
3923 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3924 # program-specific install script used by HP pwplus--don't use.
3925 :
3926 else
3927 rm -rf conftest.one conftest.two conftest.dir
3928 echo one > conftest.one
3929 echo two > conftest.two
3930 mkdir conftest.dir
3931 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
3932 test -s conftest.one && test -s conftest.two &&
3933 test -s conftest.dir/conftest.one &&
3934 test -s conftest.dir/conftest.two
3935 then
3936 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3937 break 3
3938 fi
3939 fi
3940 fi
3941 done
3942 done
3943 ;;
3944esac
3945
3946 done
3947IFS=$as_save_IFS
3948
3949rm -rf conftest.one conftest.two conftest.dir
3950
3951fi
3952 if test "${ac_cv_path_install+set}" = set; then
3953 INSTALL=$ac_cv_path_install
3954 else
3955 # As a last resort, use the slow shell script. Don't cache a
3956 # value for INSTALL within a source directory, because that will
3957 # break other packages using the cache if that directory is
3958 # removed, or if the value is a relative name.
3959 INSTALL=$ac_install_sh
3960 fi
3961fi
3962{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
3963$as_echo "$INSTALL" >&6; }
3964
3965# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3966# It thinks the first close brace ends the variable substitution.
3967test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3968
3969test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3970
3971test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3972
3973# Expand $ac_aux_dir to an absolute path.
3974am_aux_dir=`cd "$ac_aux_dir" && pwd`
3975
3976ac_ext=c
3977ac_cpp='$CPP $CPPFLAGS'
3978ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3979ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3980ac_compiler_gnu=$ac_cv_c_compiler_gnu
3981if test -n "$ac_tool_prefix"; then
3982 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
3983set dummy ${ac_tool_prefix}gcc; ac_word=$2
3984{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3985$as_echo_n "checking for $ac_word... " >&6; }
3986if ${ac_cv_prog_CC+:} false; then :
3987 $as_echo_n "(cached) " >&6
3988else
3989 if test -n "$CC"; then
3990 ac_cv_prog_CC="$CC" # Let the user override the test.
3991else
3992as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3993for as_dir in $PATH
3994do
3995 IFS=$as_save_IFS
3996 test -z "$as_dir" && as_dir=.
3997 for ac_exec_ext in '' $ac_executable_extensions; do
3998 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3999 ac_cv_prog_CC="${ac_tool_prefix}gcc"
4000 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4001 break 2
4002 fi
4003done
4004 done
4005IFS=$as_save_IFS
4006
4007fi
4008fi
4009CC=$ac_cv_prog_CC
4010if test -n "$CC"; then
4011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4012$as_echo "$CC" >&6; }
4013else
4014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4015$as_echo "no" >&6; }
4016fi
4017
4018
4019fi
4020if test -z "$ac_cv_prog_CC"; then
4021 ac_ct_CC=$CC
4022 # Extract the first word of "gcc", so it can be a program name with args.
4023set dummy gcc; ac_word=$2
4024{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4025$as_echo_n "checking for $ac_word... " >&6; }
4026if ${ac_cv_prog_ac_ct_CC+:} false; then :
4027 $as_echo_n "(cached) " >&6
4028else
4029 if test -n "$ac_ct_CC"; then
4030 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4031else
4032as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4033for as_dir in $PATH
4034do
4035 IFS=$as_save_IFS
4036 test -z "$as_dir" && as_dir=.
4037 for ac_exec_ext in '' $ac_executable_extensions; do
4038 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4039 ac_cv_prog_ac_ct_CC="gcc"
4040 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4041 break 2
4042 fi
4043done
4044 done
4045IFS=$as_save_IFS
4046
4047fi
4048fi
4049ac_ct_CC=$ac_cv_prog_ac_ct_CC
4050if test -n "$ac_ct_CC"; then
4051 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4052$as_echo "$ac_ct_CC" >&6; }
4053else
4054 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4055$as_echo "no" >&6; }
4056fi
4057
4058 if test "x$ac_ct_CC" = x; then
4059 CC=""
4060 else
4061 case $cross_compiling:$ac_tool_warned in
4062yes:)
4063{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4064$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4065ac_tool_warned=yes ;;
4066esac
4067 CC=$ac_ct_CC
4068 fi
4069else
4070 CC="$ac_cv_prog_CC"
4071fi
4072
4073if test -z "$CC"; then
4074 if test -n "$ac_tool_prefix"; then
4075 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4076set dummy ${ac_tool_prefix}cc; ac_word=$2
4077{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4078$as_echo_n "checking for $ac_word... " >&6; }
4079if ${ac_cv_prog_CC+:} false; then :
4080 $as_echo_n "(cached) " >&6
4081else
4082 if test -n "$CC"; then
4083 ac_cv_prog_CC="$CC" # Let the user override the test.
4084else
4085as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4086for as_dir in $PATH
4087do
4088 IFS=$as_save_IFS
4089 test -z "$as_dir" && as_dir=.
4090 for ac_exec_ext in '' $ac_executable_extensions; do
4091 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4092 ac_cv_prog_CC="${ac_tool_prefix}cc"
4093 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4094 break 2
4095 fi
4096done
4097 done
4098IFS=$as_save_IFS
4099
4100fi
4101fi
4102CC=$ac_cv_prog_CC
4103if test -n "$CC"; then
4104 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4105$as_echo "$CC" >&6; }
4106else
4107 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4108$as_echo "no" >&6; }
4109fi
4110
4111
4112 fi
4113fi
4114if test -z "$CC"; then
4115 # Extract the first word of "cc", so it can be a program name with args.
4116set dummy cc; ac_word=$2
4117{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4118$as_echo_n "checking for $ac_word... " >&6; }
4119if ${ac_cv_prog_CC+:} false; then :
4120 $as_echo_n "(cached) " >&6
4121else
4122 if test -n "$CC"; then
4123 ac_cv_prog_CC="$CC" # Let the user override the test.
4124else
4125 ac_prog_rejected=no
4126as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4127for as_dir in $PATH
4128do
4129 IFS=$as_save_IFS
4130 test -z "$as_dir" && as_dir=.
4131 for ac_exec_ext in '' $ac_executable_extensions; do
4132 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4133 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
4134 ac_prog_rejected=yes
4135 continue
4136 fi
4137 ac_cv_prog_CC="cc"
4138 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4139 break 2
4140 fi
4141done
4142 done
4143IFS=$as_save_IFS
4144
4145if test $ac_prog_rejected = yes; then
4146 # We found a bogon in the path, so make sure we never use it.
4147 set dummy $ac_cv_prog_CC
4148 shift
4149 if test $# != 0; then
4150 # We chose a different compiler from the bogus one.
4151 # However, it has the same basename, so the bogon will be chosen
4152 # first if we set CC to just the basename; use the full file name.
4153 shift
4154 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
4155 fi
4156fi
4157fi
4158fi
4159CC=$ac_cv_prog_CC
4160if test -n "$CC"; then
4161 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4162$as_echo "$CC" >&6; }
4163else
4164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4165$as_echo "no" >&6; }
4166fi
4167
4168
4169fi
4170if test -z "$CC"; then
4171 if test -n "$ac_tool_prefix"; then
4172 for ac_prog in cl.exe
4173 do
4174 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4175set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4176{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4177$as_echo_n "checking for $ac_word... " >&6; }
4178if ${ac_cv_prog_CC+:} false; then :
4179 $as_echo_n "(cached) " >&6
4180else
4181 if test -n "$CC"; then
4182 ac_cv_prog_CC="$CC" # Let the user override the test.
4183else
4184as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4185for as_dir in $PATH
4186do
4187 IFS=$as_save_IFS
4188 test -z "$as_dir" && as_dir=.
4189 for ac_exec_ext in '' $ac_executable_extensions; do
4190 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4191 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
4192 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4193 break 2
4194 fi
4195done
4196 done
4197IFS=$as_save_IFS
4198
4199fi
4200fi
4201CC=$ac_cv_prog_CC
4202if test -n "$CC"; then
4203 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4204$as_echo "$CC" >&6; }
4205else
4206 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4207$as_echo "no" >&6; }
4208fi
4209
4210
4211 test -n "$CC" && break
4212 done
4213fi
4214if test -z "$CC"; then
4215 ac_ct_CC=$CC
4216 for ac_prog in cl.exe
4217do
4218 # Extract the first word of "$ac_prog", so it can be a program name with args.
4219set dummy $ac_prog; ac_word=$2
4220{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4221$as_echo_n "checking for $ac_word... " >&6; }
4222if ${ac_cv_prog_ac_ct_CC+:} false; then :
4223 $as_echo_n "(cached) " >&6
4224else
4225 if test -n "$ac_ct_CC"; then
4226 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4227else
4228as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4229for as_dir in $PATH
4230do
4231 IFS=$as_save_IFS
4232 test -z "$as_dir" && as_dir=.
4233 for ac_exec_ext in '' $ac_executable_extensions; do
4234 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4235 ac_cv_prog_ac_ct_CC="$ac_prog"
4236 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4237 break 2
4238 fi
4239done
4240 done
4241IFS=$as_save_IFS
4242
4243fi
4244fi
4245ac_ct_CC=$ac_cv_prog_ac_ct_CC
4246if test -n "$ac_ct_CC"; then
4247 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4248$as_echo "$ac_ct_CC" >&6; }
4249else
4250 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4251$as_echo "no" >&6; }
4252fi
4253
4254
4255 test -n "$ac_ct_CC" && break
4256done
4257
4258 if test "x$ac_ct_CC" = x; then
4259 CC=""
4260 else
4261 case $cross_compiling:$ac_tool_warned in
4262yes:)
4263{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4264$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4265ac_tool_warned=yes ;;
4266esac
4267 CC=$ac_ct_CC
4268 fi
4269fi
4270
4271fi
4272
4273
4274test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4275$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4276as_fn_error $? "no acceptable C compiler found in \$PATH
4277See \`config.log' for more details" "$LINENO" 5; }
4278
4279# Provide some information about the compiler.
4280$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
4281set X $ac_compile
4282ac_compiler=$2
4283for ac_option in --version -v -V -qversion; do
4284 { { ac_try="$ac_compiler $ac_option >&5"
4285case "(($ac_try" in
4286 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4287 *) ac_try_echo=$ac_try;;
4288esac
4289eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4290$as_echo "$ac_try_echo"; } >&5
4291 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
4292 ac_status=$?
4293 if test -s conftest.err; then
4294 sed '10a\
4295... rest of stderr output deleted ...
4296 10q' conftest.err >conftest.er1
4297 cat conftest.er1 >&5
4298 fi
4299 rm -f conftest.er1 conftest.err
4300 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4301 test $ac_status = 0; }
4302done
4303
4304cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4305/* end confdefs.h. */
4306
4307int main (void)
4308{
4309
4310 ;
4311 return 0;
4312}
4313_ACEOF
4314ac_clean_files_save=$ac_clean_files
4315ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
4316# Try to create an executable without -o first, disregard a.out.
4317# It will help us diagnose broken compilers, and finding out an intuition
4318# of exeext.
4319{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
4320$as_echo_n "checking whether the C compiler works... " >&6; }
4321ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
4322
4323# The possible output files:
4324ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
4325
4326ac_rmfiles=
4327for ac_file in $ac_files
4328do
4329 case $ac_file in
4330 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4331 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
4332 esac
4333done
4334rm -f $ac_rmfiles
4335
4336if { { ac_try="$ac_link_default"
4337case "(($ac_try" in
4338 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4339 *) ac_try_echo=$ac_try;;
4340esac
4341eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4342$as_echo "$ac_try_echo"; } >&5
4343 (eval "$ac_link_default") 2>&5
4344 ac_status=$?
4345 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4346 test $ac_status = 0; }; then :
4347 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
4348# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
4349# in a Makefile. We should not override ac_cv_exeext if it was cached,
4350# so that the user can short-circuit this test for compilers unknown to
4351# Autoconf.
4352for ac_file in $ac_files ''
4353do
4354 test -f "$ac_file" || continue
4355 case $ac_file in
4356 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
4357 ;;
4358 [ab].out )
4359 # We found the default executable, but exeext='' is most
4360 # certainly right.
4361 break;;
4362 *.* )
4363 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
4364 then :; else
4365 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4366 fi
4367 # We set ac_cv_exeext here because the later test for it is not
4368 # safe: cross compilers may not add the suffix if given an `-o'
4369 # argument, so we may need to know it at that point already.
4370 # Even if this section looks crufty: it has the advantage of
4371 # actually working.
4372 break;;
4373 * )
4374 break;;
4375 esac
4376done
4377test "$ac_cv_exeext" = no && ac_cv_exeext=
4378
4379else
4380 ac_file=''
4381fi
4382if test -z "$ac_file"; then :
4383 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4384$as_echo "no" >&6; }
4385$as_echo "$as_me: failed program was:" >&5
4386sed 's/^/| /' conftest.$ac_ext >&5
4387
4388{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4389$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4390as_fn_error 77 "C compiler cannot create executables
4391See \`config.log' for more details" "$LINENO" 5; }
4392else
4393 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4394$as_echo "yes" >&6; }
4395fi
4396{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
4397$as_echo_n "checking for C compiler default output file name... " >&6; }
4398{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
4399$as_echo "$ac_file" >&6; }
4400ac_exeext=$ac_cv_exeext
4401
4402rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
4403ac_clean_files=$ac_clean_files_save
4404{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
4405$as_echo_n "checking for suffix of executables... " >&6; }
4406if { { ac_try="$ac_link"
4407case "(($ac_try" in
4408 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4409 *) ac_try_echo=$ac_try;;
4410esac
4411eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4412$as_echo "$ac_try_echo"; } >&5
4413 (eval "$ac_link") 2>&5
4414 ac_status=$?
4415 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4416 test $ac_status = 0; }; then :
4417 # If both `conftest.exe' and `conftest' are `present' (well, observable)
4418# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
4419# work properly (i.e., refer to `conftest.exe'), while it won't with
4420# `rm'.
4421for ac_file in conftest.exe conftest conftest.*; do
4422 test -f "$ac_file" || continue
4423 case $ac_file in
4424 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4425 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4426 break;;
4427 * ) break;;
4428 esac
4429done
4430else
4431 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4432$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4433as_fn_error $? "cannot compute suffix of executables: cannot compile and link
4434See \`config.log' for more details" "$LINENO" 5; }
4435fi
4436rm -f conftest conftest$ac_cv_exeext
4437{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
4438$as_echo "$ac_cv_exeext" >&6; }
4439
4440rm -f conftest.$ac_ext
4441EXEEXT=$ac_cv_exeext
4442ac_exeext=$EXEEXT
4443cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4444/* end confdefs.h. */
4445#include <stdio.h>
4446int main (void)
4447{
4448FILE *f = fopen ("conftest.out", "w");
4449 return ferror (f) || fclose (f) != 0;
4450
4451 ;
4452 return 0;
4453}
4454_ACEOF
4455ac_clean_files="$ac_clean_files conftest.out"
4456# Check that the compiler produces executables we can run. If not, either
4457# the compiler is broken, or we cross compile.
4458{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
4459$as_echo_n "checking whether we are cross compiling... " >&6; }
4460if test "$cross_compiling" != yes; then
4461 { { ac_try="$ac_link"
4462case "(($ac_try" in
4463 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4464 *) ac_try_echo=$ac_try;;
4465esac
4466eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4467$as_echo "$ac_try_echo"; } >&5
4468 (eval "$ac_link") 2>&5
4469 ac_status=$?
4470 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4471 test $ac_status = 0; }
4472 if { ac_try='./conftest$ac_cv_exeext'
4473 { { case "(($ac_try" in
4474 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4475 *) ac_try_echo=$ac_try;;
4476esac
4477eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4478$as_echo "$ac_try_echo"; } >&5
4479 (eval "$ac_try") 2>&5
4480 ac_status=$?
4481 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4482 test $ac_status = 0; }; }; then
4483 cross_compiling=no
4484 else
4485 if test "$cross_compiling" = maybe; then
4486 cross_compiling=yes
4487 else
4488 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4489$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4490as_fn_error $? "cannot run C compiled programs.
4491If you meant to cross compile, use \`--host'.
4492See \`config.log' for more details" "$LINENO" 5; }
4493 fi
4494 fi
4495fi
4496{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
4497$as_echo "$cross_compiling" >&6; }
4498
4499rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
4500ac_clean_files=$ac_clean_files_save
4501{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
4502$as_echo_n "checking for suffix of object files... " >&6; }
4503if ${ac_cv_objext+:} false; then :
4504 $as_echo_n "(cached) " >&6
4505else
4506 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4507/* end confdefs.h. */
4508
4509int main (void)
4510{
4511
4512 ;
4513 return 0;
4514}
4515_ACEOF
4516rm -f conftest.o conftest.obj
4517if { { ac_try="$ac_compile"
4518case "(($ac_try" in
4519 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4520 *) ac_try_echo=$ac_try;;
4521esac
4522eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4523$as_echo "$ac_try_echo"; } >&5
4524 (eval "$ac_compile") 2>&5
4525 ac_status=$?
4526 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4527 test $ac_status = 0; }; then :
4528 for ac_file in conftest.o conftest.obj conftest.*; do
4529 test -f "$ac_file" || continue;
4530 case $ac_file in
4531 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
4532 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
4533 break;;
4534 esac
4535done
4536else
4537 $as_echo "$as_me: failed program was:" >&5
4538sed 's/^/| /' conftest.$ac_ext >&5
4539
4540{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4541$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4542as_fn_error $? "cannot compute suffix of object files: cannot compile
4543See \`config.log' for more details" "$LINENO" 5; }
4544fi
4545rm -f conftest.$ac_cv_objext conftest.$ac_ext
4546fi
4547{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
4548$as_echo "$ac_cv_objext" >&6; }
4549OBJEXT=$ac_cv_objext
4550ac_objext=$OBJEXT
4551{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
4552$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
4553if ${ac_cv_c_compiler_gnu+:} false; then :
4554 $as_echo_n "(cached) " >&6
4555else
4556 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4557/* end confdefs.h. */
4558
4559int main (void)
4560{
4561#ifndef __GNUC__
4562 choke me
4563#endif
4564
4565 ;
4566 return 0;
4567}
4568_ACEOF
4569if ac_fn_c_try_compile "$LINENO"; then :
4570 ac_compiler_gnu=yes
4571else
4572 ac_compiler_gnu=no
4573fi
4574rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4575ac_cv_c_compiler_gnu=$ac_compiler_gnu
4576
4577fi
4578{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
4579$as_echo "$ac_cv_c_compiler_gnu" >&6; }
4580if test $ac_compiler_gnu = yes; then
4581 GCC=yes
4582else
4583 GCC=
4584fi
4585ac_test_CFLAGS=${CFLAGS+set}
4586ac_save_CFLAGS=$CFLAGS
4587{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
4588$as_echo_n "checking whether $CC accepts -g... " >&6; }
4589if ${ac_cv_prog_cc_g+:} false; then :
4590 $as_echo_n "(cached) " >&6
4591else
4592 ac_save_c_werror_flag=$ac_c_werror_flag
4593 ac_c_werror_flag=yes
4594 ac_cv_prog_cc_g=no
4595 CFLAGS="-g"
4596 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4597/* end confdefs.h. */
4598
4599int main (void)
4600{
4601
4602 ;
4603 return 0;
4604}
4605_ACEOF
4606if ac_fn_c_try_compile "$LINENO"; then :
4607 ac_cv_prog_cc_g=yes
4608else
4609 CFLAGS=""
4610 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4611/* end confdefs.h. */
4612
4613int main (void)
4614{
4615
4616 ;
4617 return 0;
4618}
4619_ACEOF
4620if ac_fn_c_try_compile "$LINENO"; then :
4621
4622else
4623 ac_c_werror_flag=$ac_save_c_werror_flag
4624 CFLAGS="-g"
4625 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4626/* end confdefs.h. */
4627
4628int main (void)
4629{
4630
4631 ;
4632 return 0;
4633}
4634_ACEOF
4635if ac_fn_c_try_compile "$LINENO"; then :
4636 ac_cv_prog_cc_g=yes
4637fi
4638rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4639fi
4640rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4641fi
4642rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4643 ac_c_werror_flag=$ac_save_c_werror_flag
4644fi
4645{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
4646$as_echo "$ac_cv_prog_cc_g" >&6; }
4647if test "$ac_test_CFLAGS" = set; then
4648 CFLAGS=$ac_save_CFLAGS
4649elif test $ac_cv_prog_cc_g = yes; then
4650 if test "$GCC" = yes; then
4651 CFLAGS="-g -O2"
4652 else
4653 CFLAGS="-g"
4654 fi
4655else
4656 if test "$GCC" = yes; then
4657 CFLAGS="-O2"
4658 else
4659 CFLAGS=
4660 fi
4661fi
4662{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
4663$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
4664if ${ac_cv_prog_cc_c89+:} false; then :
4665 $as_echo_n "(cached) " >&6
4666else
4667 ac_cv_prog_cc_c89=no
4668ac_save_CC=$CC
4669cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4670/* end confdefs.h. */
4671#include <stdarg.h>
4672#include <stdio.h>
4673struct stat;
4674/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
4675struct buf { int x; };
4676FILE * (*rcsopen) (struct buf *, struct stat *, int);
4677static char *e (p, i)
4678 char **p;
4679 int i;
4680{
4681 return p[i];
4682}
4683static char *f (char * (*g) (char **, int), char **p, ...)
4684{
4685 char *s;
4686 va_list v;
4687 va_start (v,p);
4688 s = g (p, va_arg (v,int));
4689 va_end (v);
4690 return s;
4691}
4692
4693/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
4694 function prototypes and stuff, but not '\xHH' hex character constants.
4695 These don't provoke an error unfortunately, instead are silently treated
4696 as 'x'. The following induces an error, until -std is added to get
4697 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
4698 array size at least. It's necessary to write '\x00'==0 to get something
4699 that's true only with -std. */
4700int osf4_cc_array ['\x00' == 0 ? 1 : -1];
4701
4702/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
4703 inside strings and character constants. */
4704#define FOO(x) 'x'
4705int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
4706
4707int test (int i, double x);
4708struct s1 {int (*f) (int a);};
4709struct s2 {int (*f) (double a);};
4710int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4711int argc;
4712char **argv;
4713int main (void)
4714{
4715return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
4716 ;
4717 return 0;
4718}
4719_ACEOF
4720for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
4721 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4722do
4723 CC="$ac_save_CC $ac_arg"
4724 if ac_fn_c_try_compile "$LINENO"; then :
4725 ac_cv_prog_cc_c89=$ac_arg
4726fi
4727rm -f core conftest.err conftest.$ac_objext
4728 test "x$ac_cv_prog_cc_c89" != "xno" && break
4729done
4730rm -f conftest.$ac_ext
4731CC=$ac_save_CC
4732
4733fi
4734# AC_CACHE_VAL
4735case "x$ac_cv_prog_cc_c89" in
4736 x)
4737 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4738$as_echo "none needed" >&6; } ;;
4739 xno)
4740 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4741$as_echo "unsupported" >&6; } ;;
4742 *)
4743 CC="$CC $ac_cv_prog_cc_c89"
4744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
4745$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
4746esac
4747if test "x$ac_cv_prog_cc_c89" != xno; then :
4748
4749fi
4750
4751ac_ext=c
4752ac_cpp='$CPP $CPPFLAGS'
4753ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4754ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4755ac_compiler_gnu=$ac_cv_c_compiler_gnu
4756
4757ac_ext=c
4758ac_cpp='$CPP $CPPFLAGS'
4759ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4760ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4761ac_compiler_gnu=$ac_cv_c_compiler_gnu
4762{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5
4763$as_echo_n "checking whether $CC understands -c and -o together... " >&6; }
4764if ${am_cv_prog_cc_c_o+:} false; then :
4765 $as_echo_n "(cached) " >&6
4766else
4767 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4768/* end confdefs.h. */
4769
4770int main (void)
4771{
4772
4773 ;
4774 return 0;
4775}
4776_ACEOF
4777 # Make sure it works both with $CC and with simple cc.
4778 # Following AC_PROG_CC_C_O, we do the test twice because some
4779 # compilers refuse to overwrite an existing .o file with -o,
4780 # though they will create one.
4781 am_cv_prog_cc_c_o=yes
4782 for am_i in 1 2; do
4783 if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5
4784 ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5
4785 ac_status=$?
4786 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4787 (exit $ac_status); } \
4788 && test -f conftest2.$ac_objext; then
4789 : OK
4790 else
4791 am_cv_prog_cc_c_o=no
4792 break
4793 fi
4794 done
4795 rm -f core conftest*
4796 unset am_i
4797fi
4798{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5
4799$as_echo "$am_cv_prog_cc_c_o" >&6; }
4800if test "$am_cv_prog_cc_c_o" != yes; then
4801 # Losing compiler, so override with the script.
4802 # FIXME: It is wrong to rewrite CC.
4803 # But if we don't then we get into trouble of one sort or another.
4804 # A longer-term fix would be to have automake use am__CC in this case,
4805 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
4806 CC="$am_aux_dir/compile $CC"
4807fi
4808ac_ext=c
4809ac_cpp='$CPP $CPPFLAGS'
4810ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4811ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4812ac_compiler_gnu=$ac_cv_c_compiler_gnu
4813
4814
4815
4816ac_ext=c
4817ac_cpp='$CPP $CPPFLAGS'
4818ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4819ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4820ac_compiler_gnu=$ac_cv_c_compiler_gnu
4821{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
4822$as_echo_n "checking how to run the C preprocessor... " >&6; }
4823# On Suns, sometimes $CPP names a directory.
4824if test -n "$CPP" && test -d "$CPP"; then
4825 CPP=
4826fi
4827if test -z "$CPP"; then
4828 if ${ac_cv_prog_CPP+:} false; then :
4829 $as_echo_n "(cached) " >&6
4830else
4831 # Double quotes because CPP needs to be expanded
4832 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
4833 do
4834 ac_preproc_ok=false
4835for ac_c_preproc_warn_flag in '' yes
4836do
4837 # Use a header file that comes with gcc, so configuring glibc
4838 # with a fresh cross-compiler works.
4839 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4840 # <limits.h> exists even on freestanding compilers.
4841 # On the NeXT, cc -E runs the code through the compiler's parser,
4842 # not just through cpp. "Syntax error" is here to catch this case.
4843 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4844/* end confdefs.h. */
4845#ifdef __STDC__
4846# include <limits.h>
4847#else
4848# include <assert.h>
4849#endif
4850 Syntax error
4851_ACEOF
4852if ac_fn_c_try_cpp "$LINENO"; then :
4853
4854else
4855 # Broken: fails on valid input.
4856continue
4857fi
4858rm -f conftest.err conftest.i conftest.$ac_ext
4859
4860 # OK, works on sane cases. Now check whether nonexistent headers
4861 # can be detected and how.
4862 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4863/* end confdefs.h. */
4864#include <ac_nonexistent.h>
4865_ACEOF
4866if ac_fn_c_try_cpp "$LINENO"; then :
4867 # Broken: success on invalid input.
4868continue
4869else
4870 # Passes both tests.
4871ac_preproc_ok=:
4872break
4873fi
4874rm -f conftest.err conftest.i conftest.$ac_ext
4875
4876done
4877# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4878rm -f conftest.i conftest.err conftest.$ac_ext
4879if $ac_preproc_ok; then :
4880 break
4881fi
4882
4883 done
4884 ac_cv_prog_CPP=$CPP
4885
4886fi
4887 CPP=$ac_cv_prog_CPP
4888else
4889 ac_cv_prog_CPP=$CPP
4890fi
4891{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
4892$as_echo "$CPP" >&6; }
4893ac_preproc_ok=false
4894for ac_c_preproc_warn_flag in '' yes
4895do
4896 # Use a header file that comes with gcc, so configuring glibc
4897 # with a fresh cross-compiler works.
4898 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4899 # <limits.h> exists even on freestanding compilers.
4900 # On the NeXT, cc -E runs the code through the compiler's parser,
4901 # not just through cpp. "Syntax error" is here to catch this case.
4902 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4903/* end confdefs.h. */
4904#ifdef __STDC__
4905# include <limits.h>
4906#else
4907# include <assert.h>
4908#endif
4909 Syntax error
4910_ACEOF
4911if ac_fn_c_try_cpp "$LINENO"; then :
4912
4913else
4914 # Broken: fails on valid input.
4915continue
4916fi
4917rm -f conftest.err conftest.i conftest.$ac_ext
4918
4919 # OK, works on sane cases. Now check whether nonexistent headers
4920 # can be detected and how.
4921 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4922/* end confdefs.h. */
4923#include <ac_nonexistent.h>
4924_ACEOF
4925if ac_fn_c_try_cpp "$LINENO"; then :
4926 # Broken: success on invalid input.
4927continue
4928else
4929 # Passes both tests.
4930ac_preproc_ok=:
4931break
4932fi
4933rm -f conftest.err conftest.i conftest.$ac_ext
4934
4935done
4936# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4937rm -f conftest.i conftest.err conftest.$ac_ext
4938if $ac_preproc_ok; then :
4939
4940else
4941 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4942$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4943as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
4944See \`config.log' for more details" "$LINENO" 5; }
4945fi
4946
4947ac_ext=c
4948ac_cpp='$CPP $CPPFLAGS'
4949ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4950ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4951ac_compiler_gnu=$ac_cv_c_compiler_gnu
4952
4953
4954 IFS=$xc_prog_cc_prev_IFS
4955 LIBS=$xc_prog_cc_prev_LIBS
4956 CFLAGS=$xc_prog_cc_prev_CFLAGS
4957 LDFLAGS=$xc_prog_cc_prev_LDFLAGS
4958 CPPFLAGS=$xc_prog_cc_prev_CPPFLAGS
4959
4960
4961
4962
4963
Elliott Hughes0128fe42018-02-27 14:57:55 -08004964
4965{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
4966$as_echo_n "checking for a sed that does not truncate output... " >&6; }
4967if ${ac_cv_path_SED+:} false; then :
4968 $as_echo_n "(cached) " >&6
4969else
4970 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
4971 for ac_i in 1 2 3 4 5 6 7; do
4972 ac_script="$ac_script$as_nl$ac_script"
4973 done
4974 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
4975 { ac_script=; unset ac_script;}
4976 if test -z "$SED"; then
4977 ac_path_SED_found=false
4978 # Loop through the user's path and test for each of PROGNAME-LIST
4979 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4980for as_dir in $PATH
4981do
4982 IFS=$as_save_IFS
4983 test -z "$as_dir" && as_dir=.
4984 for ac_prog in sed gsed; do
4985 for ac_exec_ext in '' $ac_executable_extensions; do
4986 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
4987 as_fn_executable_p "$ac_path_SED" || continue
4988# Check for GNU ac_path_SED and select it if it is found.
4989 # Check for GNU $ac_path_SED
4990case `"$ac_path_SED" --version 2>&1` in
4991*GNU*)
4992 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
4993*)
4994 ac_count=0
4995 $as_echo_n 0123456789 >"conftest.in"
4996 while :
4997 do
4998 cat "conftest.in" "conftest.in" >"conftest.tmp"
4999 mv "conftest.tmp" "conftest.in"
5000 cp "conftest.in" "conftest.nl"
5001 $as_echo '' >> "conftest.nl"
5002 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
5003 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5004 as_fn_arith $ac_count + 1 && ac_count=$as_val
5005 if test $ac_count -gt ${ac_path_SED_max-0}; then
5006 # Best one so far, save it but keep looking for a better one
5007 ac_cv_path_SED="$ac_path_SED"
5008 ac_path_SED_max=$ac_count
5009 fi
5010 # 10*(2^10) chars as input seems more than enough
5011 test $ac_count -gt 10 && break
5012 done
5013 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5014esac
5015
5016 $ac_path_SED_found && break 3
5017 done
5018 done
5019 done
5020IFS=$as_save_IFS
5021 if test -z "$ac_cv_path_SED"; then
5022 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
5023 fi
5024else
5025 ac_cv_path_SED=$SED
5026fi
5027
5028fi
5029{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
5030$as_echo "$ac_cv_path_SED" >&6; }
5031 SED="$ac_cv_path_SED"
5032 rm -f conftest.sed
5033
Elliott Hughes0128fe42018-02-27 14:57:55 -08005034
5035
5036
Haibo Huang51d9d882019-02-06 01:36:06 -08005037 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for code coverage support" >&5
5038$as_echo_n "checking for code coverage support... " >&6; }
5039 coverage="no"
5040 curl_coverage_msg="disabled"
Elliott Hughes0128fe42018-02-27 14:57:55 -08005041
Haibo Huang51d9d882019-02-06 01:36:06 -08005042 # Check whether --enable-code-coverage was given.
Elliott Hughes0128fe42018-02-27 14:57:55 -08005043if test "${enable_code_coverage+set}" = set; then :
Haibo Huang001784b2019-07-19 05:27:28 -07005044 enableval=$enable_code_coverage; coverage="$enableval"
Elliott Hughes0128fe42018-02-27 14:57:55 -08005045fi
5046
5047
Haibo Huang51d9d882019-02-06 01:36:06 -08005048 if test "$GCC" != "yes" ; then :
5049 coverage="no"
Elliott Hughes0128fe42018-02-27 14:57:55 -08005050fi
Haibo Huang51d9d882019-02-06 01:36:06 -08005051 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $coverage" >&5
5052$as_echo "$coverage" >&6; }
Elliott Hughes0128fe42018-02-27 14:57:55 -08005053
Haibo Huang51d9d882019-02-06 01:36:06 -08005054 if test "x$coverage" = "xyes"; then
5055 curl_coverage_msg="enabled"
Elliott Hughes0128fe42018-02-27 14:57:55 -08005056
Haibo Huang51d9d882019-02-06 01:36:06 -08005057 if test -n "$ac_tool_prefix"; then
5058 # Extract the first word of "${ac_tool_prefix}gcov", so it can be a program name with args.
5059set dummy ${ac_tool_prefix}gcov; ac_word=$2
Elliott Hughes0128fe42018-02-27 14:57:55 -08005060{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5061$as_echo_n "checking for $ac_word... " >&6; }
5062if ${ac_cv_prog_GCOV+:} false; then :
5063 $as_echo_n "(cached) " >&6
5064else
5065 if test -n "$GCOV"; then
5066 ac_cv_prog_GCOV="$GCOV" # Let the user override the test.
5067else
5068as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5069for as_dir in $PATH
5070do
5071 IFS=$as_save_IFS
5072 test -z "$as_dir" && as_dir=.
5073 for ac_exec_ext in '' $ac_executable_extensions; do
5074 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
Haibo Huang51d9d882019-02-06 01:36:06 -08005075 ac_cv_prog_GCOV="${ac_tool_prefix}gcov"
Elliott Hughes0128fe42018-02-27 14:57:55 -08005076 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5077 break 2
5078 fi
5079done
5080 done
5081IFS=$as_save_IFS
5082
5083fi
5084fi
5085GCOV=$ac_cv_prog_GCOV
5086if test -n "$GCOV"; then
5087 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCOV" >&5
5088$as_echo "$GCOV" >&6; }
5089else
5090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5091$as_echo "no" >&6; }
5092fi
5093
5094
5095fi
5096if test -z "$ac_cv_prog_GCOV"; then
5097 ac_ct_GCOV=$GCOV
Haibo Huang51d9d882019-02-06 01:36:06 -08005098 # Extract the first word of "gcov", so it can be a program name with args.
5099set dummy gcov; ac_word=$2
Elliott Hughes0128fe42018-02-27 14:57:55 -08005100{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5101$as_echo_n "checking for $ac_word... " >&6; }
5102if ${ac_cv_prog_ac_ct_GCOV+:} false; then :
5103 $as_echo_n "(cached) " >&6
5104else
5105 if test -n "$ac_ct_GCOV"; then
5106 ac_cv_prog_ac_ct_GCOV="$ac_ct_GCOV" # Let the user override the test.
5107else
5108as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5109for as_dir in $PATH
5110do
5111 IFS=$as_save_IFS
5112 test -z "$as_dir" && as_dir=.
5113 for ac_exec_ext in '' $ac_executable_extensions; do
5114 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
Haibo Huang51d9d882019-02-06 01:36:06 -08005115 ac_cv_prog_ac_ct_GCOV="gcov"
Elliott Hughes0128fe42018-02-27 14:57:55 -08005116 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5117 break 2
5118 fi
5119done
5120 done
5121IFS=$as_save_IFS
5122
5123fi
5124fi
5125ac_ct_GCOV=$ac_cv_prog_ac_ct_GCOV
5126if test -n "$ac_ct_GCOV"; then
5127 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_GCOV" >&5
5128$as_echo "$ac_ct_GCOV" >&6; }
5129else
5130 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5131$as_echo "no" >&6; }
5132fi
5133
5134 if test "x$ac_ct_GCOV" = x; then
Haibo Huang51d9d882019-02-06 01:36:06 -08005135 GCOV="gcov"
Elliott Hughes0128fe42018-02-27 14:57:55 -08005136 else
5137 case $cross_compiling:$ac_tool_warned in
5138yes:)
5139{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5140$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5141ac_tool_warned=yes ;;
5142esac
5143 GCOV=$ac_ct_GCOV
5144 fi
5145else
5146 GCOV="$ac_cv_prog_GCOV"
5147fi
5148
Haibo Huang51d9d882019-02-06 01:36:06 -08005149 if test -z "$GCOV"; then
5150 as_fn_error $? "needs gcov for code coverage" "$LINENO" 5
5151 fi
5152 # Extract the first word of "lcov", so it can be a program name with args.
Elliott Hughes0128fe42018-02-27 14:57:55 -08005153set dummy lcov; ac_word=$2
5154{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5155$as_echo_n "checking for $ac_word... " >&6; }
5156if ${ac_cv_prog_LCOV+:} false; then :
5157 $as_echo_n "(cached) " >&6
5158else
5159 if test -n "$LCOV"; then
5160 ac_cv_prog_LCOV="$LCOV" # Let the user override the test.
5161else
5162as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5163for as_dir in $PATH
5164do
5165 IFS=$as_save_IFS
5166 test -z "$as_dir" && as_dir=.
5167 for ac_exec_ext in '' $ac_executable_extensions; do
5168 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5169 ac_cv_prog_LCOV="lcov"
5170 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5171 break 2
5172 fi
5173done
5174 done
5175IFS=$as_save_IFS
5176
5177fi
5178fi
5179LCOV=$ac_cv_prog_LCOV
5180if test -n "$LCOV"; then
5181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LCOV" >&5
5182$as_echo "$LCOV" >&6; }
5183else
5184 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5185$as_echo "no" >&6; }
5186fi
5187
5188
Haibo Huang51d9d882019-02-06 01:36:06 -08005189 if test -z "$LCOV"; then
5190 as_fn_error $? "needs lcov for code coverage" "$LINENO" 5
5191 fi
5192
5193 CPPFLAGS="$CPPFLAGS -DNDEBUG"
5194 CFLAGS="$CLAGS -O0 -g -fprofile-arcs -ftest-coverage"
5195 LIBS="$LIBS -lgcov"
Elliott Hughes0128fe42018-02-27 14:57:55 -08005196 fi
Elliott Hughes0128fe42018-02-27 14:57:55 -08005197
Elliott Hughes0128fe42018-02-27 14:57:55 -08005198
Haibo Huang001784b2019-07-19 05:27:28 -07005199am__api_version='1.16'
Elliott Hughes82be86d2017-09-20 17:00:17 -07005200
5201{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
5202$as_echo_n "checking whether build environment is sane... " >&6; }
5203# Reject unsafe characters in $srcdir or the absolute working directory
5204# name. Accept space and tab only in the latter.
5205am_lf='
5206'
5207case `pwd` in
5208 *[\\\"\#\$\&\'\`$am_lf]*)
5209 as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;;
5210esac
5211case $srcdir in
5212 *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
5213 as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;;
5214esac
5215
5216# Do 'set' in a subshell so we don't clobber the current shell's
5217# arguments. Must try -L first in case configure is actually a
5218# symlink; some systems play weird games with the mod time of symlinks
5219# (eg FreeBSD returns the mod time of the symlink's containing
5220# directory).
5221if (
5222 am_has_slept=no
5223 for am_try in 1 2; do
5224 echo "timestamp, slept: $am_has_slept" > conftest.file
5225 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
5226 if test "$*" = "X"; then
5227 # -L didn't work.
5228 set X `ls -t "$srcdir/configure" conftest.file`
5229 fi
5230 if test "$*" != "X $srcdir/configure conftest.file" \
5231 && test "$*" != "X conftest.file $srcdir/configure"; then
5232
5233 # If neither matched, then we have a broken ls. This can happen
5234 # if, for instance, CONFIG_SHELL is bash and it inherits a
5235 # broken ls alias from the environment. This has actually
5236 # happened. Such a system could not be considered "sane".
5237 as_fn_error $? "ls -t appears to fail. Make sure there is not a broken
5238 alias in your environment" "$LINENO" 5
5239 fi
5240 if test "$2" = conftest.file || test $am_try -eq 2; then
5241 break
5242 fi
5243 # Just in case.
5244 sleep 1
5245 am_has_slept=yes
5246 done
5247 test "$2" = conftest.file
5248 )
5249then
5250 # Ok.
5251 :
5252else
5253 as_fn_error $? "newly created file is older than distributed files!
5254Check your system clock" "$LINENO" 5
5255fi
5256{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5257$as_echo "yes" >&6; }
5258# If we didn't sleep, we still need to ensure time stamps of config.status and
5259# generated files are strictly newer.
5260am_sleep_pid=
5261if grep 'slept: no' conftest.file >/dev/null 2>&1; then
5262 ( sleep 1 ) &
5263 am_sleep_pid=$!
5264fi
5265
5266rm -f conftest.file
5267
5268test "$program_prefix" != NONE &&
5269 program_transform_name="s&^&$program_prefix&;$program_transform_name"
5270# Use a double $ so make ignores it.
5271test "$program_suffix" != NONE &&
5272 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
5273# Double any \ or $.
5274# By default was `s,x,x', remove it if useless.
5275ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
5276program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
5277
5278if test x"${MISSING+set}" != xset; then
5279 case $am_aux_dir in
5280 *\ * | *\ *)
5281 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
5282 *)
5283 MISSING="\${SHELL} $am_aux_dir/missing" ;;
5284 esac
5285fi
5286# Use eval to expand $SHELL
5287if eval "$MISSING --is-lightweight"; then
5288 am_missing_run="$MISSING "
5289else
5290 am_missing_run=
5291 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5
5292$as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;}
5293fi
5294
5295if test x"${install_sh+set}" != xset; then
5296 case $am_aux_dir in
5297 *\ * | *\ *)
5298 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
5299 *)
5300 install_sh="\${SHELL} $am_aux_dir/install-sh"
5301 esac
5302fi
5303
5304# Installed binaries are usually stripped using 'strip' when the user
5305# run "make install-strip". However 'strip' might not be the right
5306# tool to use in cross-compilation environments, therefore Automake
5307# will honor the 'STRIP' environment variable to overrule this program.
5308if test "$cross_compiling" != no; then
5309 if test -n "$ac_tool_prefix"; then
5310 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
5311set dummy ${ac_tool_prefix}strip; ac_word=$2
5312{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5313$as_echo_n "checking for $ac_word... " >&6; }
5314if ${ac_cv_prog_STRIP+:} false; then :
5315 $as_echo_n "(cached) " >&6
5316else
5317 if test -n "$STRIP"; then
5318 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
5319else
5320as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5321for as_dir in $PATH
5322do
5323 IFS=$as_save_IFS
5324 test -z "$as_dir" && as_dir=.
5325 for ac_exec_ext in '' $ac_executable_extensions; do
5326 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5327 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
5328 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5329 break 2
5330 fi
5331done
5332 done
5333IFS=$as_save_IFS
5334
5335fi
5336fi
5337STRIP=$ac_cv_prog_STRIP
5338if test -n "$STRIP"; then
5339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
5340$as_echo "$STRIP" >&6; }
5341else
5342 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5343$as_echo "no" >&6; }
5344fi
5345
5346
5347fi
5348if test -z "$ac_cv_prog_STRIP"; then
5349 ac_ct_STRIP=$STRIP
5350 # Extract the first word of "strip", so it can be a program name with args.
5351set dummy strip; ac_word=$2
5352{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5353$as_echo_n "checking for $ac_word... " >&6; }
5354if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
5355 $as_echo_n "(cached) " >&6
5356else
5357 if test -n "$ac_ct_STRIP"; then
5358 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
5359else
5360as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5361for as_dir in $PATH
5362do
5363 IFS=$as_save_IFS
5364 test -z "$as_dir" && as_dir=.
5365 for ac_exec_ext in '' $ac_executable_extensions; do
5366 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5367 ac_cv_prog_ac_ct_STRIP="strip"
5368 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5369 break 2
5370 fi
5371done
5372 done
5373IFS=$as_save_IFS
5374
5375fi
5376fi
5377ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
5378if test -n "$ac_ct_STRIP"; then
5379 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
5380$as_echo "$ac_ct_STRIP" >&6; }
5381else
5382 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5383$as_echo "no" >&6; }
5384fi
5385
5386 if test "x$ac_ct_STRIP" = x; then
5387 STRIP=":"
5388 else
5389 case $cross_compiling:$ac_tool_warned in
5390yes:)
5391{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5392$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5393ac_tool_warned=yes ;;
5394esac
5395 STRIP=$ac_ct_STRIP
5396 fi
5397else
5398 STRIP="$ac_cv_prog_STRIP"
5399fi
5400
5401fi
5402INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
5403
5404{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
5405$as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
5406if test -z "$MKDIR_P"; then
5407 if ${ac_cv_path_mkdir+:} false; then :
5408 $as_echo_n "(cached) " >&6
5409else
5410 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5411for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
5412do
5413 IFS=$as_save_IFS
5414 test -z "$as_dir" && as_dir=.
5415 for ac_prog in mkdir gmkdir; do
5416 for ac_exec_ext in '' $ac_executable_extensions; do
5417 as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue
5418 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
5419 'mkdir (GNU coreutils) '* | \
5420 'mkdir (coreutils) '* | \
5421 'mkdir (fileutils) '4.1*)
5422 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
5423 break 3;;
5424 esac
5425 done
5426 done
5427 done
5428IFS=$as_save_IFS
5429
5430fi
5431
5432 test -d ./--version && rmdir ./--version
5433 if test "${ac_cv_path_mkdir+set}" = set; then
5434 MKDIR_P="$ac_cv_path_mkdir -p"
5435 else
5436 # As a last resort, use the slow shell script. Don't cache a
5437 # value for MKDIR_P within a source directory, because that will
5438 # break other packages using the cache if that directory is
5439 # removed, or if the value is a relative name.
5440 MKDIR_P="$ac_install_sh -d"
5441 fi
5442fi
5443{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
5444$as_echo "$MKDIR_P" >&6; }
5445
5446for ac_prog in gawk mawk nawk awk
5447do
5448 # Extract the first word of "$ac_prog", so it can be a program name with args.
5449set dummy $ac_prog; ac_word=$2
5450{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5451$as_echo_n "checking for $ac_word... " >&6; }
5452if ${ac_cv_prog_AWK+:} false; then :
5453 $as_echo_n "(cached) " >&6
5454else
5455 if test -n "$AWK"; then
5456 ac_cv_prog_AWK="$AWK" # Let the user override the test.
5457else
5458as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5459for as_dir in $PATH
5460do
5461 IFS=$as_save_IFS
5462 test -z "$as_dir" && as_dir=.
5463 for ac_exec_ext in '' $ac_executable_extensions; do
5464 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5465 ac_cv_prog_AWK="$ac_prog"
5466 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5467 break 2
5468 fi
5469done
5470 done
5471IFS=$as_save_IFS
5472
5473fi
5474fi
5475AWK=$ac_cv_prog_AWK
5476if test -n "$AWK"; then
5477 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
5478$as_echo "$AWK" >&6; }
5479else
5480 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5481$as_echo "no" >&6; }
5482fi
5483
5484
5485 test -n "$AWK" && break
5486done
5487
5488{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
5489$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
5490set x ${MAKE-make}
5491ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
5492if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then :
5493 $as_echo_n "(cached) " >&6
5494else
5495 cat >conftest.make <<\_ACEOF
5496SHELL = /bin/sh
5497all:
5498 @echo '@@@%%%=$(MAKE)=@@@%%%'
5499_ACEOF
5500# GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
5501case `${MAKE-make} -f conftest.make 2>/dev/null` in
5502 *@@@%%%=?*=@@@%%%*)
5503 eval ac_cv_prog_make_${ac_make}_set=yes;;
5504 *)
5505 eval ac_cv_prog_make_${ac_make}_set=no;;
5506esac
5507rm -f conftest.make
5508fi
5509if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
5510 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5511$as_echo "yes" >&6; }
5512 SET_MAKE=
5513else
5514 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5515$as_echo "no" >&6; }
5516 SET_MAKE="MAKE=${MAKE-make}"
5517fi
5518
5519rm -rf .tst 2>/dev/null
5520mkdir .tst 2>/dev/null
5521if test -d .tst; then
5522 am__leading_dot=.
5523else
5524 am__leading_dot=_
5525fi
5526rmdir .tst 2>/dev/null
5527
5528DEPDIR="${am__leading_dot}deps"
5529
5530ac_config_commands="$ac_config_commands depfiles"
5531
Haibo Huang001784b2019-07-19 05:27:28 -07005532{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} supports the include directive" >&5
5533$as_echo_n "checking whether ${MAKE-make} supports the include directive... " >&6; }
5534cat > confinc.mk << 'END'
Elliott Hughes82be86d2017-09-20 17:00:17 -07005535am__doit:
Haibo Huang001784b2019-07-19 05:27:28 -07005536 @echo this is the am__doit target >confinc.out
Elliott Hughes82be86d2017-09-20 17:00:17 -07005537.PHONY: am__doit
5538END
Elliott Hughes82be86d2017-09-20 17:00:17 -07005539am__include="#"
5540am__quote=
Haibo Huang001784b2019-07-19 05:27:28 -07005541# BSD make does it like this.
5542echo '.include "confinc.mk" # ignored' > confmf.BSD
5543# Other make implementations (GNU, Solaris 10, AIX) do it like this.
5544echo 'include confinc.mk # ignored' > confmf.GNU
5545_am_result=no
5546for s in GNU BSD; do
5547 { echo "$as_me:$LINENO: ${MAKE-make} -f confmf.$s && cat confinc.out" >&5
5548 (${MAKE-make} -f confmf.$s && cat confinc.out) >&5 2>&5
5549 ac_status=$?
5550 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5551 (exit $ac_status); }
5552 case $?:`cat confinc.out 2>/dev/null` in #(
5553 '0:this is the am__doit target') :
5554 case $s in #(
5555 BSD) :
5556 am__include='.include' am__quote='"' ;; #(
5557 *) :
5558 am__include='include' am__quote='' ;;
5559esac ;; #(
5560 *) :
Elliott Hughes82be86d2017-09-20 17:00:17 -07005561 ;;
Haibo Huang001784b2019-07-19 05:27:28 -07005562esac
5563 if test "$am__include" != "#"; then
5564 _am_result="yes ($s style)"
5565 break
5566 fi
5567done
5568rm -f confinc.* confmf.*
5569{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${_am_result}" >&5
5570$as_echo "${_am_result}" >&6; }
Elliott Hughes82be86d2017-09-20 17:00:17 -07005571
5572# Check whether --enable-dependency-tracking was given.
5573if test "${enable_dependency_tracking+set}" = set; then :
5574 enableval=$enable_dependency_tracking;
5575fi
5576
5577if test "x$enable_dependency_tracking" != xno; then
5578 am_depcomp="$ac_aux_dir/depcomp"
5579 AMDEPBACKSLASH='\'
5580 am__nodep='_no'
5581fi
5582 if test "x$enable_dependency_tracking" != xno; then
5583 AMDEP_TRUE=
5584 AMDEP_FALSE='#'
5585else
5586 AMDEP_TRUE='#'
5587 AMDEP_FALSE=
5588fi
5589
5590
5591## --------------------------------------- ##
5592## Start of automake initialization code ##
5593## --------------------------------------- ##
5594
5595if test "`cd $srcdir && pwd`" != "`pwd`"; then
5596 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
5597 # is not polluted with repeated "-I."
5598 am__isrc=' -I$(srcdir)'
5599 # test to see if srcdir already configured
5600 if test -f $srcdir/config.status; then
5601 as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
5602 fi
5603fi
5604
5605# test whether we have cygpath
5606if test -z "$CYGPATH_W"; then
5607 if (cygpath --version) >/dev/null 2>/dev/null; then
5608 CYGPATH_W='cygpath -w'
5609 else
5610 CYGPATH_W=echo
5611 fi
5612fi
5613
5614
5615# Define the identity of the package.
5616 PACKAGE='curl'
5617 VERSION='-'
5618
5619
5620cat >>confdefs.h <<_ACEOF
5621#define PACKAGE "$PACKAGE"
5622_ACEOF
5623
5624
5625cat >>confdefs.h <<_ACEOF
5626#define VERSION "$VERSION"
5627_ACEOF
5628
5629# Some tools Automake needs.
5630
5631ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
5632
5633
5634AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
5635
5636
5637AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
5638
5639
5640AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
5641
5642
5643MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
5644
5645# For better backward compatibility. To be removed once Automake 1.9.x
5646# dies out for good. For more background, see:
Haibo Huang001784b2019-07-19 05:27:28 -07005647# <https://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
5648# <https://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
Elliott Hughes82be86d2017-09-20 17:00:17 -07005649mkdir_p='$(MKDIR_P)'
5650
5651# We need awk for the "check" target (and possibly the TAP driver). The
5652# system "awk" is bad on some platforms.
5653# Always define AMTAR for backward compatibility. Yes, it's still used
5654# in the wild :-( We should find a proper way to deprecate it ...
5655AMTAR='$${TAR-tar}'
5656
5657
5658# We'll loop over all known methods to create a tar archive until one works.
5659_am_tools='gnutar pax cpio none'
5660
5661am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'
5662
5663
5664
5665
5666
5667depcc="$CC" am_compiler_list=
5668
5669{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
5670$as_echo_n "checking dependency style of $depcc... " >&6; }
5671if ${am_cv_CC_dependencies_compiler_type+:} false; then :
5672 $as_echo_n "(cached) " >&6
5673else
5674 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
5675 # We make a subdir and do the tests there. Otherwise we can end up
5676 # making bogus files that we don't know about and never remove. For
5677 # instance it was reported that on HP-UX the gcc test will end up
5678 # making a dummy file named 'D' -- because '-MD' means "put the output
5679 # in D".
5680 rm -rf conftest.dir
5681 mkdir conftest.dir
5682 # Copy depcomp to subdir because otherwise we won't find it if we're
5683 # using a relative directory.
5684 cp "$am_depcomp" conftest.dir
5685 cd conftest.dir
5686 # We will build objects and dependencies in a subdirectory because
5687 # it helps to detect inapplicable dependency modes. For instance
5688 # both Tru64's cc and ICC support -MD to output dependencies as a
5689 # side effect of compilation, but ICC will put the dependencies in
5690 # the current directory while Tru64 will put them in the object
5691 # directory.
5692 mkdir sub
5693
5694 am_cv_CC_dependencies_compiler_type=none
5695 if test "$am_compiler_list" = ""; then
5696 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
5697 fi
5698 am__universal=false
5699 case " $depcc " in #(
5700 *\ -arch\ *\ -arch\ *) am__universal=true ;;
5701 esac
5702
5703 for depmode in $am_compiler_list; do
5704 # Setup a source with many dependencies, because some compilers
5705 # like to wrap large dependency lists on column 80 (with \), and
5706 # we should not choose a depcomp mode which is confused by this.
5707 #
5708 # We need to recreate these files for each test, as the compiler may
5709 # overwrite some of them when testing with obscure command lines.
5710 # This happens at least with the AIX C compiler.
5711 : > sub/conftest.c
5712 for i in 1 2 3 4 5 6; do
5713 echo '#include "conftst'$i'.h"' >> sub/conftest.c
5714 # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
5715 # Solaris 10 /bin/sh.
5716 echo '/* dummy */' > sub/conftst$i.h
5717 done
5718 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
5719
5720 # We check with '-c' and '-o' for the sake of the "dashmstdout"
5721 # mode. It turns out that the SunPro C++ compiler does not properly
5722 # handle '-M -o', and we need to detect this. Also, some Intel
5723 # versions had trouble with output in subdirs.
5724 am__obj=sub/conftest.${OBJEXT-o}
5725 am__minus_obj="-o $am__obj"
5726 case $depmode in
5727 gcc)
5728 # This depmode causes a compiler race in universal mode.
5729 test "$am__universal" = false || continue
5730 ;;
5731 nosideeffect)
5732 # After this tag, mechanisms are not by side-effect, so they'll
5733 # only be used when explicitly requested.
5734 if test "x$enable_dependency_tracking" = xyes; then
5735 continue
5736 else
5737 break
5738 fi
5739 ;;
5740 msvc7 | msvc7msys | msvisualcpp | msvcmsys)
5741 # This compiler won't grok '-c -o', but also, the minuso test has
5742 # not run yet. These depmodes are late enough in the game, and
5743 # so weak that their functioning should not be impacted.
5744 am__obj=conftest.${OBJEXT-o}
5745 am__minus_obj=
5746 ;;
5747 none) break ;;
5748 esac
5749 if depmode=$depmode \
5750 source=sub/conftest.c object=$am__obj \
5751 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
5752 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
5753 >/dev/null 2>conftest.err &&
5754 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
5755 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
5756 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
5757 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
5758 # icc doesn't choke on unknown options, it will just issue warnings
5759 # or remarks (even with -Werror). So we grep stderr for any message
5760 # that says an option was ignored or not supported.
5761 # When given -MP, icc 7.0 and 7.1 complain thusly:
5762 # icc: Command line warning: ignoring option '-M'; no argument required
5763 # The diagnosis changed in icc 8.0:
5764 # icc: Command line remark: option '-MP' not supported
5765 if (grep 'ignoring option' conftest.err ||
5766 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
5767 am_cv_CC_dependencies_compiler_type=$depmode
5768 break
5769 fi
5770 fi
5771 done
5772
5773 cd ..
5774 rm -rf conftest.dir
5775else
5776 am_cv_CC_dependencies_compiler_type=none
5777fi
5778
5779fi
5780{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
5781$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
5782CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
5783
5784 if
5785 test "x$enable_dependency_tracking" != xno \
5786 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
5787 am__fastdepCC_TRUE=
5788 am__fastdepCC_FALSE='#'
5789else
5790 am__fastdepCC_TRUE='#'
5791 am__fastdepCC_FALSE=
5792fi
5793
5794
5795
5796# POSIX will say in a future version that running "rm -f" with no argument
5797# is OK; and we want to be able to make that assumption in our Makefile
5798# recipes. So use an aggressive probe to check that the usage we want is
5799# actually supported "in the wild" to an acceptable degree.
5800# See automake bug#10828.
5801# To make any issue more visible, cause the running configure to be aborted
5802# by default if the 'rm' program in use doesn't match our expectations; the
5803# user can still override this though.
5804if rm -f && rm -fr && rm -rf; then : OK; else
5805 cat >&2 <<'END'
5806Oops!
5807
5808Your 'rm' program seems unable to run without file operands specified
5809on the command line, even when the '-f' option is present. This is contrary
5810to the behaviour of most rm programs out there, and not conforming with
5811the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
5812
5813Please tell bug-automake@gnu.org about your system, including the value
5814of your $PATH and any error possibly output before this message. This
5815can help us improve future automake versions.
5816
5817END
5818 if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then
5819 echo 'Configuration will proceed anyway, since you have set the' >&2
5820 echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
5821 echo >&2
5822 else
5823 cat >&2 <<'END'
5824Aborting the configuration process, to ensure you take notice of the issue.
5825
5826You can download and install GNU coreutils to get an 'rm' implementation
Haibo Huang001784b2019-07-19 05:27:28 -07005827that behaves properly: <https://www.gnu.org/software/coreutils/>.
Elliott Hughes82be86d2017-09-20 17:00:17 -07005828
5829If you want to complete the configuration process using your problematic
5830'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
5831to "yes", and re-run configure.
5832
5833END
5834 as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5
5835 fi
5836fi
5837
5838## ------------------------------------- ##
5839## End of automake initialization code ##
5840## ------------------------------------- ##
5841
5842
5843{ $as_echo "$as_me:${as_lineno-$LINENO}: checking curl version" >&5
5844$as_echo_n "checking curl version... " >&6; }
5845{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CURLVERSION" >&5
5846$as_echo "$CURLVERSION" >&6; }
5847
5848
5849
5850VERSIONNUM=`$SED -ne 's/^#define LIBCURL_VERSION_NUM 0x\([0-9A-Fa-f]*\).*/\1/p' ${srcdir}/include/curl/curlver.h`
5851
5852
5853PKGADD_PKG="HAXXcurl"
5854PKGADD_NAME="curl - a client that groks URLs"
5855PKGADD_VENDOR="curl.haxx.se"
5856
5857
5858
5859
Haibo Huang001784b2019-07-19 05:27:28 -07005860 curl_ssl_msg="no (--with-{ssl,gnutls,nss,mbedtls,wolfssl,schannel,secure-transport,mesalink,amissl} )"
Elliott Hughes82be86d2017-09-20 17:00:17 -07005861 curl_ssh_msg="no (--with-libssh2)"
5862 curl_zlib_msg="no (--with-zlib)"
Alex Deymo486467e2017-12-19 19:04:07 +01005863 curl_brotli_msg="no (--with-brotli)"
Elliott Hughes82be86d2017-09-20 17:00:17 -07005864 curl_gss_msg="no (--with-gssapi)"
5865curl_tls_srp_msg="no (--enable-tls-srp)"
5866 curl_res_msg="default (--enable-ares / --enable-threaded-resolver)"
5867 curl_ipv6_msg="no (--enable-ipv6)"
5868curl_unix_sockets_msg="no (--enable-unix-sockets)"
5869 curl_idn_msg="no (--with-{libidn2,winidn})"
5870 curl_manual_msg="no (--enable-manual)"
5871curl_libcurl_msg="enabled (--disable-libcurl-option)"
5872curl_verbose_msg="enabled (--disable-verbose)"
5873 curl_sspi_msg="no (--enable-sspi)"
5874 curl_ldap_msg="no (--enable-ldap / --with-ldap-lib / --with-lber-lib)"
5875 curl_ldaps_msg="no (--enable-ldaps)"
5876 curl_rtsp_msg="no (--enable-rtsp)"
5877 curl_rtmp_msg="no (--with-librtmp)"
5878 curl_mtlnk_msg="no (--with-libmetalink)"
5879 curl_psl_msg="no (--with-libpsl)"
5880
Alex Deymo486467e2017-12-19 19:04:07 +01005881 ssl_backends=
Elliott Hughes82be86d2017-09-20 17:00:17 -07005882
5883INITIAL_LDFLAGS=$LDFLAGS
5884INITIAL_LIBS=$LIBS
5885
5886
5887# Make sure we can run config.sub.
5888$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
5889 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
5890
5891{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
5892$as_echo_n "checking build system type... " >&6; }
5893if ${ac_cv_build+:} false; then :
5894 $as_echo_n "(cached) " >&6
5895else
5896 ac_build_alias=$build_alias
5897test "x$ac_build_alias" = x &&
5898 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
5899test "x$ac_build_alias" = x &&
5900 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
5901ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
5902 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
5903
5904fi
5905{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
5906$as_echo "$ac_cv_build" >&6; }
5907case $ac_cv_build in
5908*-*-*) ;;
5909*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
5910esac
5911build=$ac_cv_build
5912ac_save_IFS=$IFS; IFS='-'
5913set x $ac_cv_build
5914shift
5915build_cpu=$1
5916build_vendor=$2
5917shift; shift
5918# Remember, the first character of IFS is used to create $*,
5919# except with old shells:
5920build_os=$*
5921IFS=$ac_save_IFS
5922case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
5923
5924
5925{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
5926$as_echo_n "checking host system type... " >&6; }
5927if ${ac_cv_host+:} false; then :
5928 $as_echo_n "(cached) " >&6
5929else
5930 if test "x$host_alias" = x; then
5931 ac_cv_host=$ac_cv_build
5932else
5933 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
5934 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
5935fi
5936
5937fi
5938{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
5939$as_echo "$ac_cv_host" >&6; }
5940case $ac_cv_host in
5941*-*-*) ;;
5942*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
5943esac
5944host=$ac_cv_host
5945ac_save_IFS=$IFS; IFS='-'
5946set x $ac_cv_host
5947shift
5948host_cpu=$1
5949host_vendor=$2
5950shift; shift
5951# Remember, the first character of IFS is used to create $*,
5952# except with old shells:
5953host_os=$*
5954IFS=$ac_save_IFS
5955case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
5956
5957
5958
5959cat >>confdefs.h <<_ACEOF
5960#define OS "${host}"
5961_ACEOF
5962
5963
Elliott Hughes72d948d2018-08-03 14:37:21 -07005964# Silence warning: ar: 'u' modifier ignored since 'D' is the default
5965AR_FLAGS=cr
5966
Elliott Hughes82be86d2017-09-20 17:00:17 -07005967
5968
5969
Elliott Hughes82be86d2017-09-20 17:00:17 -07005970{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
5971$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
5972if ${ac_cv_path_GREP+:} false; then :
5973 $as_echo_n "(cached) " >&6
5974else
5975 if test -z "$GREP"; then
5976 ac_path_GREP_found=false
5977 # Loop through the user's path and test for each of PROGNAME-LIST
5978 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5979for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5980do
5981 IFS=$as_save_IFS
5982 test -z "$as_dir" && as_dir=.
5983 for ac_prog in grep ggrep; do
5984 for ac_exec_ext in '' $ac_executable_extensions; do
5985 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
5986 as_fn_executable_p "$ac_path_GREP" || continue
5987# Check for GNU ac_path_GREP and select it if it is found.
5988 # Check for GNU $ac_path_GREP
5989case `"$ac_path_GREP" --version 2>&1` in
5990*GNU*)
5991 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
5992*)
5993 ac_count=0
5994 $as_echo_n 0123456789 >"conftest.in"
5995 while :
5996 do
5997 cat "conftest.in" "conftest.in" >"conftest.tmp"
5998 mv "conftest.tmp" "conftest.in"
5999 cp "conftest.in" "conftest.nl"
6000 $as_echo 'GREP' >> "conftest.nl"
6001 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
6002 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
6003 as_fn_arith $ac_count + 1 && ac_count=$as_val
6004 if test $ac_count -gt ${ac_path_GREP_max-0}; then
6005 # Best one so far, save it but keep looking for a better one
6006 ac_cv_path_GREP="$ac_path_GREP"
6007 ac_path_GREP_max=$ac_count
6008 fi
6009 # 10*(2^10) chars as input seems more than enough
6010 test $ac_count -gt 10 && break
6011 done
6012 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
6013esac
6014
6015 $ac_path_GREP_found && break 3
6016 done
6017 done
6018 done
6019IFS=$as_save_IFS
6020 if test -z "$ac_cv_path_GREP"; then
6021 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
6022 fi
6023else
6024 ac_cv_path_GREP=$GREP
6025fi
6026
6027fi
6028{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
6029$as_echo "$ac_cv_path_GREP" >&6; }
6030 GREP="$ac_cv_path_GREP"
6031
6032
6033{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
6034$as_echo_n "checking for egrep... " >&6; }
6035if ${ac_cv_path_EGREP+:} false; then :
6036 $as_echo_n "(cached) " >&6
6037else
6038 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
6039 then ac_cv_path_EGREP="$GREP -E"
6040 else
6041 if test -z "$EGREP"; then
6042 ac_path_EGREP_found=false
6043 # Loop through the user's path and test for each of PROGNAME-LIST
6044 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6045for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
6046do
6047 IFS=$as_save_IFS
6048 test -z "$as_dir" && as_dir=.
6049 for ac_prog in egrep; do
6050 for ac_exec_ext in '' $ac_executable_extensions; do
6051 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
6052 as_fn_executable_p "$ac_path_EGREP" || continue
6053# Check for GNU ac_path_EGREP and select it if it is found.
6054 # Check for GNU $ac_path_EGREP
6055case `"$ac_path_EGREP" --version 2>&1` in
6056*GNU*)
6057 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
6058*)
6059 ac_count=0
6060 $as_echo_n 0123456789 >"conftest.in"
6061 while :
6062 do
6063 cat "conftest.in" "conftest.in" >"conftest.tmp"
6064 mv "conftest.tmp" "conftest.in"
6065 cp "conftest.in" "conftest.nl"
6066 $as_echo 'EGREP' >> "conftest.nl"
6067 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
6068 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
6069 as_fn_arith $ac_count + 1 && ac_count=$as_val
6070 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
6071 # Best one so far, save it but keep looking for a better one
6072 ac_cv_path_EGREP="$ac_path_EGREP"
6073 ac_path_EGREP_max=$ac_count
6074 fi
6075 # 10*(2^10) chars as input seems more than enough
6076 test $ac_count -gt 10 && break
6077 done
6078 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
6079esac
6080
6081 $ac_path_EGREP_found && break 3
6082 done
6083 done
6084 done
6085IFS=$as_save_IFS
6086 if test -z "$ac_cv_path_EGREP"; then
6087 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
6088 fi
6089else
6090 ac_cv_path_EGREP=$EGREP
6091fi
6092
6093 fi
6094fi
6095{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
6096$as_echo "$ac_cv_path_EGREP" >&6; }
6097 EGREP="$ac_cv_path_EGREP"
6098
6099
Elliott Hughes82be86d2017-09-20 17:00:17 -07006100
6101
6102 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if OS is AIX (to define _ALL_SOURCE)" >&5
6103$as_echo_n "checking if OS is AIX (to define _ALL_SOURCE)... " >&6; }
6104 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6105/* end confdefs.h. */
6106
6107#ifdef _AIX
6108 yes_this_is_aix
6109#endif
6110
6111_ACEOF
6112if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6113 $EGREP "yes_this_is_aix" >/dev/null 2>&1; then :
6114
6115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6116$as_echo "yes" >&6; }
6117 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
6118
6119
6120else
6121
6122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6123$as_echo "no" >&6; }
6124
6125fi
6126rm -f conftest*
6127
6128
6129
6130
6131 #
6132 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if _THREAD_SAFE is already defined" >&5
6133$as_echo_n "checking if _THREAD_SAFE is already defined... " >&6; }
6134 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6135/* end confdefs.h. */
6136
6137
6138
6139int main (void)
6140{
6141
6142#ifdef _THREAD_SAFE
6143 int dummy=1;
6144#else
6145 force compilation error
6146#endif
6147
6148 ;
6149 return 0;
6150}
6151
6152_ACEOF
6153if ac_fn_c_try_compile "$LINENO"; then :
6154
6155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6156$as_echo "yes" >&6; }
6157 tmp_thread_safe_initially_defined="yes"
6158
6159else
6160
6161 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6162$as_echo "no" >&6; }
6163 tmp_thread_safe_initially_defined="no"
6164
6165fi
6166rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6167 #
6168 if test "$tmp_thread_safe_initially_defined" = "no"; then
6169 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if _THREAD_SAFE is actually needed" >&5
6170$as_echo_n "checking if _THREAD_SAFE is actually needed... " >&6; }
6171
6172 case $host_os in
6173 aix[123].* | aix4.[012].*)
6174 tmp_need_thread_safe="no"
6175 ;;
6176 aix*)
6177 tmp_need_thread_safe="yes"
6178 ;;
6179 *)
6180 tmp_need_thread_safe="no"
6181 ;;
6182 esac
6183
6184 if test "$tmp_need_thread_safe" = "yes"; then
6185 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6186$as_echo "yes" >&6; }
6187 else
6188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6189$as_echo "no" >&6; }
6190 fi
6191 fi
6192 #
6193 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if _THREAD_SAFE is onwards defined" >&5
6194$as_echo_n "checking if _THREAD_SAFE is onwards defined... " >&6; }
6195 if test "$tmp_thread_safe_initially_defined" = "yes" ||
6196 test "$tmp_need_thread_safe" = "yes"; then
6197
6198
6199$as_echo "#define NEED_THREAD_SAFE 1" >>confdefs.h
6200
6201cat >>confdefs.h <<_EOF
6202#ifndef _THREAD_SAFE
6203# define _THREAD_SAFE
6204#endif
6205_EOF
6206
6207 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6208$as_echo "yes" >&6; }
6209 else
6210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6211$as_echo "no" >&6; }
6212 fi
6213 #
6214
6215
6216 #
6217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if _REENTRANT is already defined" >&5
6218$as_echo_n "checking if _REENTRANT is already defined... " >&6; }
6219 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6220/* end confdefs.h. */
6221
6222
6223
6224int main (void)
6225{
6226
6227#ifdef _REENTRANT
6228 int dummy=1;
6229#else
6230 force compilation error
6231#endif
6232
6233 ;
6234 return 0;
6235}
6236
6237_ACEOF
6238if ac_fn_c_try_compile "$LINENO"; then :
6239
6240 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6241$as_echo "yes" >&6; }
6242 tmp_reentrant_initially_defined="yes"
6243
6244else
6245
6246 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6247$as_echo "no" >&6; }
6248 tmp_reentrant_initially_defined="no"
6249
6250fi
6251rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6252 #
6253 if test "$tmp_reentrant_initially_defined" = "no"; then
6254 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if _REENTRANT is actually needed" >&5
6255$as_echo_n "checking if _REENTRANT is actually needed... " >&6; }
6256
6257 case $host_os in
6258 solaris*)
6259 tmp_need_reentrant="yes"
6260 ;;
6261 *)
6262 tmp_need_reentrant="no"
6263 ;;
6264 esac
6265
6266 if test "$tmp_need_reentrant" = "no"; then
6267
6268 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6269/* end confdefs.h. */
6270
6271
6272#include <errno.h>
6273
6274int main (void)
6275{
6276
6277 if(0 != errno)
6278 return 1;
6279
6280 ;
6281 return 0;
6282}
6283
6284_ACEOF
6285if ac_fn_c_try_compile "$LINENO"; then :
6286
6287 tmp_errno="yes"
6288
6289else
6290
6291 tmp_errno="no"
6292
6293fi
6294rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6295 if test "$tmp_errno" = "yes"; then
6296 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6297/* end confdefs.h. */
6298
6299
6300#include <errno.h>
6301
6302int main (void)
6303{
6304
6305#ifdef errno
6306 int dummy=1;
6307#else
6308 force compilation error
6309#endif
6310
6311 ;
6312 return 0;
6313}
6314
6315_ACEOF
6316if ac_fn_c_try_compile "$LINENO"; then :
6317
6318 tmp_errno="errno_macro_defined"
6319
6320else
6321
6322 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6323/* end confdefs.h. */
6324
6325
6326#define _REENTRANT
6327#include <errno.h>
6328
6329int main (void)
6330{
6331
6332#ifdef errno
6333 int dummy=1;
6334#else
6335 force compilation error
6336#endif
6337
6338 ;
6339 return 0;
6340}
6341
6342_ACEOF
6343if ac_fn_c_try_compile "$LINENO"; then :
6344
6345 tmp_errno="errno_macro_needs_reentrant"
6346 tmp_need_reentrant="yes"
6347
6348fi
6349rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6350
6351fi
6352rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6353 fi
6354
6355 fi
6356 if test "$tmp_need_reentrant" = "no"; then
6357
6358 if test "$tmp_need_reentrant" = "no"; then
6359
6360 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6361/* end confdefs.h. */
6362
6363
6364#define gmtime_r innocuous_gmtime_r
6365#ifdef __STDC__
6366# include <limits.h>
6367#else
6368# include <assert.h>
6369#endif
6370#undef gmtime_r
6371#ifdef __cplusplus
6372extern "C"
6373#endif
6374char gmtime_r ();
6375#if defined __stub_gmtime_r || defined __stub___gmtime_r
6376choke me
6377#endif
6378
6379int main (void)
6380{
6381return gmtime_r ();
6382 ;
6383 return 0;
6384}
6385
6386_ACEOF
6387if ac_fn_c_try_link "$LINENO"; then :
6388
6389 tmp_gmtime_r="yes"
6390
6391else
6392
6393 tmp_gmtime_r="no"
6394
6395fi
6396rm -f core conftest.err conftest.$ac_objext \
6397 conftest$ac_exeext conftest.$ac_ext
6398 if test "$tmp_gmtime_r" = "yes"; then
6399 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6400/* end confdefs.h. */
6401
6402#include <sys/types.h>
6403#include <time.h>
6404
6405_ACEOF
6406if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6407 $EGREP "gmtime_r" >/dev/null 2>&1; then :
6408
6409 tmp_gmtime_r="proto_declared"
6410
6411else
6412
6413 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6414/* end confdefs.h. */
6415
6416#define _REENTRANT
6417#include <sys/types.h>
6418#include <time.h>
6419
6420_ACEOF
6421if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6422 $EGREP "gmtime_r" >/dev/null 2>&1; then :
6423
6424 tmp_gmtime_r="proto_needs_reentrant"
6425 tmp_need_reentrant="yes"
6426
6427fi
6428rm -f conftest*
6429
6430
6431fi
6432rm -f conftest*
6433
6434 fi
6435
6436 fi
6437 if test "$tmp_need_reentrant" = "no"; then
6438
6439 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6440/* end confdefs.h. */
6441
6442
6443#define localtime_r innocuous_localtime_r
6444#ifdef __STDC__
6445# include <limits.h>
6446#else
6447# include <assert.h>
6448#endif
6449#undef localtime_r
6450#ifdef __cplusplus
6451extern "C"
6452#endif
6453char localtime_r ();
6454#if defined __stub_localtime_r || defined __stub___localtime_r
6455choke me
6456#endif
6457
6458int main (void)
6459{
6460return localtime_r ();
6461 ;
6462 return 0;
6463}
6464
6465_ACEOF
6466if ac_fn_c_try_link "$LINENO"; then :
6467
6468 tmp_localtime_r="yes"
6469
6470else
6471
6472 tmp_localtime_r="no"
6473
6474fi
6475rm -f core conftest.err conftest.$ac_objext \
6476 conftest$ac_exeext conftest.$ac_ext
6477 if test "$tmp_localtime_r" = "yes"; then
6478 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6479/* end confdefs.h. */
6480
6481#include <sys/types.h>
6482#include <time.h>
6483
6484_ACEOF
6485if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6486 $EGREP "localtime_r" >/dev/null 2>&1; then :
6487
6488 tmp_localtime_r="proto_declared"
6489
6490else
6491
6492 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6493/* end confdefs.h. */
6494
6495#define _REENTRANT
6496#include <sys/types.h>
6497#include <time.h>
6498
6499_ACEOF
6500if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6501 $EGREP "localtime_r" >/dev/null 2>&1; then :
6502
6503 tmp_localtime_r="proto_needs_reentrant"
6504 tmp_need_reentrant="yes"
6505
6506fi
6507rm -f conftest*
6508
6509
6510fi
6511rm -f conftest*
6512
6513 fi
6514
6515 fi
6516 if test "$tmp_need_reentrant" = "no"; then
6517
6518 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6519/* end confdefs.h. */
6520
6521
6522#define strerror_r innocuous_strerror_r
6523#ifdef __STDC__
6524# include <limits.h>
6525#else
6526# include <assert.h>
6527#endif
6528#undef strerror_r
6529#ifdef __cplusplus
6530extern "C"
6531#endif
6532char strerror_r ();
6533#if defined __stub_strerror_r || defined __stub___strerror_r
6534choke me
6535#endif
6536
6537int main (void)
6538{
6539return strerror_r ();
6540 ;
6541 return 0;
6542}
6543
6544_ACEOF
6545if ac_fn_c_try_link "$LINENO"; then :
6546
6547 tmp_strerror_r="yes"
6548
6549else
6550
6551 tmp_strerror_r="no"
6552
6553fi
6554rm -f core conftest.err conftest.$ac_objext \
6555 conftest$ac_exeext conftest.$ac_ext
6556 if test "$tmp_strerror_r" = "yes"; then
6557 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6558/* end confdefs.h. */
6559
6560#include <sys/types.h>
6561#include <string.h>
6562
6563_ACEOF
6564if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6565 $EGREP "strerror_r" >/dev/null 2>&1; then :
6566
6567 tmp_strerror_r="proto_declared"
6568
6569else
6570
6571 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6572/* end confdefs.h. */
6573
6574#define _REENTRANT
6575#include <sys/types.h>
6576#include <string.h>
6577
6578_ACEOF
6579if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6580 $EGREP "strerror_r" >/dev/null 2>&1; then :
6581
6582 tmp_strerror_r="proto_needs_reentrant"
6583 tmp_need_reentrant="yes"
6584
6585fi
6586rm -f conftest*
6587
6588
6589fi
6590rm -f conftest*
6591
6592 fi
6593
6594 fi
6595 if test "$tmp_need_reentrant" = "no"; then
6596
6597 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6598/* end confdefs.h. */
6599
6600
6601#define strtok_r innocuous_strtok_r
6602#ifdef __STDC__
6603# include <limits.h>
6604#else
6605# include <assert.h>
6606#endif
6607#undef strtok_r
6608#ifdef __cplusplus
6609extern "C"
6610#endif
6611char strtok_r ();
6612#if defined __stub_strtok_r || defined __stub___strtok_r
6613choke me
6614#endif
6615
6616int main (void)
6617{
6618return strtok_r ();
6619 ;
6620 return 0;
6621}
6622
6623_ACEOF
6624if ac_fn_c_try_link "$LINENO"; then :
6625
6626 tmp_strtok_r="yes"
6627
6628else
6629
6630 tmp_strtok_r="no"
6631
6632fi
6633rm -f core conftest.err conftest.$ac_objext \
6634 conftest$ac_exeext conftest.$ac_ext
6635 if test "$tmp_strtok_r" = "yes"; then
6636 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6637/* end confdefs.h. */
6638
6639#include <sys/types.h>
6640#include <string.h>
6641
6642_ACEOF
6643if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6644 $EGREP "strtok_r" >/dev/null 2>&1; then :
6645
6646 tmp_strtok_r="proto_declared"
6647
6648else
6649
6650 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6651/* end confdefs.h. */
6652
6653#define _REENTRANT
6654#include <sys/types.h>
6655#include <string.h>
6656
6657_ACEOF
6658if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6659 $EGREP "strtok_r" >/dev/null 2>&1; then :
6660
6661 tmp_strtok_r="proto_needs_reentrant"
6662 tmp_need_reentrant="yes"
6663
6664fi
6665rm -f conftest*
6666
6667
6668fi
6669rm -f conftest*
6670
6671 fi
6672
6673 fi
6674 if test "$tmp_need_reentrant" = "no"; then
6675
6676 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6677/* end confdefs.h. */
6678
6679
6680#define inet_ntoa_r innocuous_inet_ntoa_r
6681#ifdef __STDC__
6682# include <limits.h>
6683#else
6684# include <assert.h>
6685#endif
6686#undef inet_ntoa_r
6687#ifdef __cplusplus
6688extern "C"
6689#endif
6690char inet_ntoa_r ();
6691#if defined __stub_inet_ntoa_r || defined __stub___inet_ntoa_r
6692choke me
6693#endif
6694
6695int main (void)
6696{
6697return inet_ntoa_r ();
6698 ;
6699 return 0;
6700}
6701
6702_ACEOF
6703if ac_fn_c_try_link "$LINENO"; then :
6704
6705 tmp_inet_ntoa_r="yes"
6706
6707else
6708
6709 tmp_inet_ntoa_r="no"
6710
6711fi
6712rm -f core conftest.err conftest.$ac_objext \
6713 conftest$ac_exeext conftest.$ac_ext
6714 if test "$tmp_inet_ntoa_r" = "yes"; then
6715 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6716/* end confdefs.h. */
6717
6718#include <sys/types.h>
6719#include <sys/socket.h>
6720#include <netinet/in.h>
6721#include <arpa/inet.h>
6722
6723_ACEOF
6724if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6725 $EGREP "inet_ntoa_r" >/dev/null 2>&1; then :
6726
6727 tmp_inet_ntoa_r="proto_declared"
6728
6729else
6730
6731 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6732/* end confdefs.h. */
6733
6734#define _REENTRANT
6735#include <sys/types.h>
6736#include <sys/socket.h>
6737#include <netinet/in.h>
6738#include <arpa/inet.h>
6739
6740_ACEOF
6741if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6742 $EGREP "inet_ntoa_r" >/dev/null 2>&1; then :
6743
6744 tmp_inet_ntoa_r="proto_needs_reentrant"
6745 tmp_need_reentrant="yes"
6746
6747fi
6748rm -f conftest*
6749
6750
6751fi
6752rm -f conftest*
6753
6754 fi
6755
6756 fi
6757 if test "$tmp_need_reentrant" = "no"; then
6758
6759 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6760/* end confdefs.h. */
6761
6762
6763#define gethostbyaddr_r innocuous_gethostbyaddr_r
6764#ifdef __STDC__
6765# include <limits.h>
6766#else
6767# include <assert.h>
6768#endif
6769#undef gethostbyaddr_r
6770#ifdef __cplusplus
6771extern "C"
6772#endif
6773char gethostbyaddr_r ();
6774#if defined __stub_gethostbyaddr_r || defined __stub___gethostbyaddr_r
6775choke me
6776#endif
6777
6778int main (void)
6779{
6780return gethostbyaddr_r ();
6781 ;
6782 return 0;
6783}
6784
6785_ACEOF
6786if ac_fn_c_try_link "$LINENO"; then :
6787
6788 tmp_gethostbyaddr_r="yes"
6789
6790else
6791
6792 tmp_gethostbyaddr_r="no"
6793
6794fi
6795rm -f core conftest.err conftest.$ac_objext \
6796 conftest$ac_exeext conftest.$ac_ext
6797 if test "$tmp_gethostbyaddr_r" = "yes"; then
6798 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6799/* end confdefs.h. */
6800
6801#include <sys/types.h>
6802#include <netdb.h>
6803
6804_ACEOF
6805if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6806 $EGREP "gethostbyaddr_r" >/dev/null 2>&1; then :
6807
6808 tmp_gethostbyaddr_r="proto_declared"
6809
6810else
6811
6812 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6813/* end confdefs.h. */
6814
6815#define _REENTRANT
6816#include <sys/types.h>
6817#include <netdb.h>
6818
6819_ACEOF
6820if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6821 $EGREP "gethostbyaddr_r" >/dev/null 2>&1; then :
6822
6823 tmp_gethostbyaddr_r="proto_needs_reentrant"
6824 tmp_need_reentrant="yes"
6825
6826fi
6827rm -f conftest*
6828
6829
6830fi
6831rm -f conftest*
6832
6833 fi
6834
6835 fi
6836 if test "$tmp_need_reentrant" = "no"; then
6837
6838 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6839/* end confdefs.h. */
6840
6841
6842#define gethostbyname_r innocuous_gethostbyname_r
6843#ifdef __STDC__
6844# include <limits.h>
6845#else
6846# include <assert.h>
6847#endif
6848#undef gethostbyname_r
6849#ifdef __cplusplus
6850extern "C"
6851#endif
6852char gethostbyname_r ();
6853#if defined __stub_gethostbyname_r || defined __stub___gethostbyname_r
6854choke me
6855#endif
6856
6857int main (void)
6858{
6859return gethostbyname_r ();
6860 ;
6861 return 0;
6862}
6863
6864_ACEOF
6865if ac_fn_c_try_link "$LINENO"; then :
6866
6867 tmp_gethostbyname_r="yes"
6868
6869else
6870
6871 tmp_gethostbyname_r="no"
6872
6873fi
6874rm -f core conftest.err conftest.$ac_objext \
6875 conftest$ac_exeext conftest.$ac_ext
6876 if test "$tmp_gethostbyname_r" = "yes"; then
6877 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6878/* end confdefs.h. */
6879
6880#include <sys/types.h>
6881#include <netdb.h>
6882
6883_ACEOF
6884if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6885 $EGREP "gethostbyname_r" >/dev/null 2>&1; then :
6886
6887 tmp_gethostbyname_r="proto_declared"
6888
6889else
6890
6891 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6892/* end confdefs.h. */
6893
6894#define _REENTRANT
6895#include <sys/types.h>
6896#include <netdb.h>
6897
6898_ACEOF
6899if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6900 $EGREP "gethostbyname_r" >/dev/null 2>&1; then :
6901
6902 tmp_gethostbyname_r="proto_needs_reentrant"
6903 tmp_need_reentrant="yes"
6904
6905fi
6906rm -f conftest*
6907
6908
6909fi
6910rm -f conftest*
6911
6912 fi
6913
6914 fi
6915 if test "$tmp_need_reentrant" = "no"; then
6916
6917 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6918/* end confdefs.h. */
6919
6920
6921#define getprotobyname_r innocuous_getprotobyname_r
6922#ifdef __STDC__
6923# include <limits.h>
6924#else
6925# include <assert.h>
6926#endif
6927#undef getprotobyname_r
6928#ifdef __cplusplus
6929extern "C"
6930#endif
6931char getprotobyname_r ();
6932#if defined __stub_getprotobyname_r || defined __stub___getprotobyname_r
6933choke me
6934#endif
6935
6936int main (void)
6937{
6938return getprotobyname_r ();
6939 ;
6940 return 0;
6941}
6942
6943_ACEOF
6944if ac_fn_c_try_link "$LINENO"; then :
6945
6946 tmp_getprotobyname_r="yes"
6947
6948else
6949
6950 tmp_getprotobyname_r="no"
6951
6952fi
6953rm -f core conftest.err conftest.$ac_objext \
6954 conftest$ac_exeext conftest.$ac_ext
6955 if test "$tmp_getprotobyname_r" = "yes"; then
6956 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6957/* end confdefs.h. */
6958
6959#include <sys/types.h>
6960#include <netdb.h>
6961
6962_ACEOF
6963if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6964 $EGREP "getprotobyname_r" >/dev/null 2>&1; then :
6965
6966 tmp_getprotobyname_r="proto_declared"
6967
6968else
6969
6970 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6971/* end confdefs.h. */
6972
6973#define _REENTRANT
6974#include <sys/types.h>
6975#include <netdb.h>
6976
6977_ACEOF
6978if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6979 $EGREP "getprotobyname_r" >/dev/null 2>&1; then :
6980
6981 tmp_getprotobyname_r="proto_needs_reentrant"
6982 tmp_need_reentrant="yes"
6983
6984fi
6985rm -f conftest*
6986
6987
6988fi
6989rm -f conftest*
6990
6991 fi
6992
6993 fi
6994 if test "$tmp_need_reentrant" = "no"; then
6995
6996 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6997/* end confdefs.h. */
6998
6999
7000#define getservbyport_r innocuous_getservbyport_r
7001#ifdef __STDC__
7002# include <limits.h>
7003#else
7004# include <assert.h>
7005#endif
7006#undef getservbyport_r
7007#ifdef __cplusplus
7008extern "C"
7009#endif
7010char getservbyport_r ();
7011#if defined __stub_getservbyport_r || defined __stub___getservbyport_r
7012choke me
7013#endif
7014
7015int main (void)
7016{
7017return getservbyport_r ();
7018 ;
7019 return 0;
7020}
7021
7022_ACEOF
7023if ac_fn_c_try_link "$LINENO"; then :
7024
7025 tmp_getservbyport_r="yes"
7026
7027else
7028
7029 tmp_getservbyport_r="no"
7030
7031fi
7032rm -f core conftest.err conftest.$ac_objext \
7033 conftest$ac_exeext conftest.$ac_ext
7034 if test "$tmp_getservbyport_r" = "yes"; then
7035 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7036/* end confdefs.h. */
7037
7038#include <sys/types.h>
7039#include <netdb.h>
7040
7041_ACEOF
7042if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7043 $EGREP "getservbyport_r" >/dev/null 2>&1; then :
7044
7045 tmp_getservbyport_r="proto_declared"
7046
7047else
7048
7049 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7050/* end confdefs.h. */
7051
7052#define _REENTRANT
7053#include <sys/types.h>
7054#include <netdb.h>
7055
7056_ACEOF
7057if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7058 $EGREP "getservbyport_r" >/dev/null 2>&1; then :
7059
7060 tmp_getservbyport_r="proto_needs_reentrant"
7061 tmp_need_reentrant="yes"
7062
7063fi
7064rm -f conftest*
7065
7066
7067fi
7068rm -f conftest*
7069
7070 fi
7071
7072 fi
7073
7074 fi
7075 if test "$tmp_need_reentrant" = "yes"; then
7076 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7077$as_echo "yes" >&6; }
7078 else
7079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7080$as_echo "no" >&6; }
7081 fi
7082 fi
7083 #
7084 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if _REENTRANT is onwards defined" >&5
7085$as_echo_n "checking if _REENTRANT is onwards defined... " >&6; }
7086 if test "$tmp_reentrant_initially_defined" = "yes" ||
7087 test "$tmp_need_reentrant" = "yes"; then
7088
7089
7090$as_echo "#define NEED_REENTRANT 1" >>confdefs.h
7091
7092cat >>confdefs.h <<_EOF
7093#ifndef _REENTRANT
7094# define _REENTRANT
7095#endif
7096_EOF
7097
7098 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7099$as_echo "yes" >&6; }
7100 else
7101 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7102$as_echo "no" >&6; }
7103 fi
7104 #
7105
7106
7107# Check whether --enable-largefile was given.
7108if test "${enable_largefile+set}" = set; then :
7109 enableval=$enable_largefile;
7110fi
7111
7112if test "$enable_largefile" != no; then
7113
7114 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
7115$as_echo_n "checking for special C compiler options needed for large files... " >&6; }
7116if ${ac_cv_sys_largefile_CC+:} false; then :
7117 $as_echo_n "(cached) " >&6
7118else
7119 ac_cv_sys_largefile_CC=no
7120 if test "$GCC" != yes; then
7121 ac_save_CC=$CC
7122 while :; do
7123 # IRIX 6.2 and later do not support large files by default,
7124 # so use the C compiler's -n32 option if that helps.
7125 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7126/* end confdefs.h. */
7127#include <sys/types.h>
7128 /* Check that off_t can represent 2**63 - 1 correctly.
7129 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7130 since some C++ compilers masquerading as C compilers
7131 incorrectly reject 9223372036854775807. */
7132#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
7133 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7134 && LARGE_OFF_T % 2147483647 == 1)
7135 ? 1 : -1];
7136int main (void)
7137{
7138
7139 ;
7140 return 0;
7141}
7142_ACEOF
7143 if ac_fn_c_try_compile "$LINENO"; then :
7144 break
7145fi
7146rm -f core conftest.err conftest.$ac_objext
7147 CC="$CC -n32"
7148 if ac_fn_c_try_compile "$LINENO"; then :
7149 ac_cv_sys_largefile_CC=' -n32'; break
7150fi
7151rm -f core conftest.err conftest.$ac_objext
7152 break
7153 done
7154 CC=$ac_save_CC
7155 rm -f conftest.$ac_ext
7156 fi
7157fi
7158{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
7159$as_echo "$ac_cv_sys_largefile_CC" >&6; }
7160 if test "$ac_cv_sys_largefile_CC" != no; then
7161 CC=$CC$ac_cv_sys_largefile_CC
7162 fi
7163
7164 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
7165$as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
7166if ${ac_cv_sys_file_offset_bits+:} false; then :
7167 $as_echo_n "(cached) " >&6
7168else
7169 while :; do
7170 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7171/* end confdefs.h. */
7172#include <sys/types.h>
7173 /* Check that off_t can represent 2**63 - 1 correctly.
7174 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7175 since some C++ compilers masquerading as C compilers
7176 incorrectly reject 9223372036854775807. */
7177#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
7178 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7179 && LARGE_OFF_T % 2147483647 == 1)
7180 ? 1 : -1];
7181int main (void)
7182{
7183
7184 ;
7185 return 0;
7186}
7187_ACEOF
7188if ac_fn_c_try_compile "$LINENO"; then :
7189 ac_cv_sys_file_offset_bits=no; break
7190fi
7191rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7192 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7193/* end confdefs.h. */
7194#define _FILE_OFFSET_BITS 64
7195#include <sys/types.h>
7196 /* Check that off_t can represent 2**63 - 1 correctly.
7197 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7198 since some C++ compilers masquerading as C compilers
7199 incorrectly reject 9223372036854775807. */
7200#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
7201 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7202 && LARGE_OFF_T % 2147483647 == 1)
7203 ? 1 : -1];
7204int main (void)
7205{
7206
7207 ;
7208 return 0;
7209}
7210_ACEOF
7211if ac_fn_c_try_compile "$LINENO"; then :
7212 ac_cv_sys_file_offset_bits=64; break
7213fi
7214rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7215 ac_cv_sys_file_offset_bits=unknown
7216 break
7217done
7218fi
7219{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
7220$as_echo "$ac_cv_sys_file_offset_bits" >&6; }
7221case $ac_cv_sys_file_offset_bits in #(
7222 no | unknown) ;;
7223 *)
7224cat >>confdefs.h <<_ACEOF
7225#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
7226_ACEOF
7227;;
7228esac
7229rm -rf conftest*
7230 if test $ac_cv_sys_file_offset_bits = unknown; then
7231 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
7232$as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
7233if ${ac_cv_sys_large_files+:} false; then :
7234 $as_echo_n "(cached) " >&6
7235else
7236 while :; do
7237 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7238/* end confdefs.h. */
7239#include <sys/types.h>
7240 /* Check that off_t can represent 2**63 - 1 correctly.
7241 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7242 since some C++ compilers masquerading as C compilers
7243 incorrectly reject 9223372036854775807. */
7244#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
7245 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7246 && LARGE_OFF_T % 2147483647 == 1)
7247 ? 1 : -1];
7248int main (void)
7249{
7250
7251 ;
7252 return 0;
7253}
7254_ACEOF
7255if ac_fn_c_try_compile "$LINENO"; then :
7256 ac_cv_sys_large_files=no; break
7257fi
7258rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7259 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7260/* end confdefs.h. */
7261#define _LARGE_FILES 1
7262#include <sys/types.h>
7263 /* Check that off_t can represent 2**63 - 1 correctly.
7264 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7265 since some C++ compilers masquerading as C compilers
7266 incorrectly reject 9223372036854775807. */
7267#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
7268 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7269 && LARGE_OFF_T % 2147483647 == 1)
7270 ? 1 : -1];
7271int main (void)
7272{
7273
7274 ;
7275 return 0;
7276}
7277_ACEOF
7278if ac_fn_c_try_compile "$LINENO"; then :
7279 ac_cv_sys_large_files=1; break
7280fi
7281rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7282 ac_cv_sys_large_files=unknown
7283 break
7284done
7285fi
7286{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
7287$as_echo "$ac_cv_sys_large_files" >&6; }
7288case $ac_cv_sys_large_files in #(
7289 no | unknown) ;;
7290 *)
7291cat >>confdefs.h <<_ACEOF
7292#define _LARGE_FILES $ac_cv_sys_large_files
7293_ACEOF
7294;;
7295esac
7296rm -rf conftest*
7297 fi
7298
7299
7300fi
7301
7302
7303case `pwd` in
7304 *\ * | *\ *)
7305 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5
7306$as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;;
7307esac
7308
7309
7310
7311macro_version='2.4.6'
7312macro_revision='2.4.6'
7313
7314
7315
7316
7317
7318
7319
7320
7321
7322
7323
7324
7325
7326ltmain=$ac_aux_dir/ltmain.sh
7327
7328# Backslashify metacharacters that are still active within
7329# double-quoted strings.
7330sed_quote_subst='s/\(["`$\\]\)/\\\1/g'
7331
7332# Same as above, but do not quote variable references.
7333double_quote_subst='s/\(["`\\]\)/\\\1/g'
7334
7335# Sed substitution to delay expansion of an escaped shell variable in a
7336# double_quote_subst'ed string.
7337delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
7338
7339# Sed substitution to delay expansion of an escaped single quote.
7340delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
7341
7342# Sed substitution to avoid accidental globbing in evaled expressions
7343no_glob_subst='s/\*/\\\*/g'
7344
7345ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
7346ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
7347ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
7348
7349{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
7350$as_echo_n "checking how to print strings... " >&6; }
7351# Test print first, because it will be a builtin if present.
7352if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
7353 test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
7354 ECHO='print -r --'
7355elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
7356 ECHO='printf %s\n'
7357else
7358 # Use this function as a fallback that always works.
7359 func_fallback_echo ()
7360 {
7361 eval 'cat <<_LTECHO_EOF
7362$1
7363_LTECHO_EOF'
7364 }
7365 ECHO='func_fallback_echo'
7366fi
7367
7368# func_echo_all arg...
7369# Invoke $ECHO with all args, space-separated.
7370func_echo_all ()
7371{
7372 $ECHO ""
7373}
7374
7375case $ECHO in
7376 printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5
7377$as_echo "printf" >&6; } ;;
7378 print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5
7379$as_echo "print -r" >&6; } ;;
7380 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5
7381$as_echo "cat" >&6; } ;;
7382esac
7383
7384
7385
7386
7387
7388
7389
7390
7391
7392
7393
7394
7395
7396
7397{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
7398$as_echo_n "checking for a sed that does not truncate output... " >&6; }
7399if ${ac_cv_path_SED+:} false; then :
7400 $as_echo_n "(cached) " >&6
7401else
7402 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
7403 for ac_i in 1 2 3 4 5 6 7; do
7404 ac_script="$ac_script$as_nl$ac_script"
7405 done
7406 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
7407 { ac_script=; unset ac_script;}
7408 if test -z "$SED"; then
7409 ac_path_SED_found=false
7410 # Loop through the user's path and test for each of PROGNAME-LIST
7411 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7412for as_dir in $PATH
7413do
7414 IFS=$as_save_IFS
7415 test -z "$as_dir" && as_dir=.
7416 for ac_prog in sed gsed; do
7417 for ac_exec_ext in '' $ac_executable_extensions; do
7418 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
7419 as_fn_executable_p "$ac_path_SED" || continue
7420# Check for GNU ac_path_SED and select it if it is found.
7421 # Check for GNU $ac_path_SED
7422case `"$ac_path_SED" --version 2>&1` in
7423*GNU*)
7424 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
7425*)
7426 ac_count=0
7427 $as_echo_n 0123456789 >"conftest.in"
7428 while :
7429 do
7430 cat "conftest.in" "conftest.in" >"conftest.tmp"
7431 mv "conftest.tmp" "conftest.in"
7432 cp "conftest.in" "conftest.nl"
7433 $as_echo '' >> "conftest.nl"
7434 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
7435 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
7436 as_fn_arith $ac_count + 1 && ac_count=$as_val
7437 if test $ac_count -gt ${ac_path_SED_max-0}; then
7438 # Best one so far, save it but keep looking for a better one
7439 ac_cv_path_SED="$ac_path_SED"
7440 ac_path_SED_max=$ac_count
7441 fi
7442 # 10*(2^10) chars as input seems more than enough
7443 test $ac_count -gt 10 && break
7444 done
7445 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
7446esac
7447
7448 $ac_path_SED_found && break 3
7449 done
7450 done
7451 done
7452IFS=$as_save_IFS
7453 if test -z "$ac_cv_path_SED"; then
7454 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
7455 fi
7456else
7457 ac_cv_path_SED=$SED
7458fi
7459
7460fi
7461{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
7462$as_echo "$ac_cv_path_SED" >&6; }
7463 SED="$ac_cv_path_SED"
7464 rm -f conftest.sed
7465
7466test -z "$SED" && SED=sed
7467Xsed="$SED -e 1s/^X//"
7468
7469
7470
7471
7472
7473
7474
7475
7476
7477
7478
7479{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
7480$as_echo_n "checking for fgrep... " >&6; }
7481if ${ac_cv_path_FGREP+:} false; then :
7482 $as_echo_n "(cached) " >&6
7483else
7484 if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
7485 then ac_cv_path_FGREP="$GREP -F"
7486 else
7487 if test -z "$FGREP"; then
7488 ac_path_FGREP_found=false
7489 # Loop through the user's path and test for each of PROGNAME-LIST
7490 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7491for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
7492do
7493 IFS=$as_save_IFS
7494 test -z "$as_dir" && as_dir=.
7495 for ac_prog in fgrep; do
7496 for ac_exec_ext in '' $ac_executable_extensions; do
7497 ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
7498 as_fn_executable_p "$ac_path_FGREP" || continue
7499# Check for GNU ac_path_FGREP and select it if it is found.
7500 # Check for GNU $ac_path_FGREP
7501case `"$ac_path_FGREP" --version 2>&1` in
7502*GNU*)
7503 ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
7504*)
7505 ac_count=0
7506 $as_echo_n 0123456789 >"conftest.in"
7507 while :
7508 do
7509 cat "conftest.in" "conftest.in" >"conftest.tmp"
7510 mv "conftest.tmp" "conftest.in"
7511 cp "conftest.in" "conftest.nl"
7512 $as_echo 'FGREP' >> "conftest.nl"
7513 "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
7514 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
7515 as_fn_arith $ac_count + 1 && ac_count=$as_val
7516 if test $ac_count -gt ${ac_path_FGREP_max-0}; then
7517 # Best one so far, save it but keep looking for a better one
7518 ac_cv_path_FGREP="$ac_path_FGREP"
7519 ac_path_FGREP_max=$ac_count
7520 fi
7521 # 10*(2^10) chars as input seems more than enough
7522 test $ac_count -gt 10 && break
7523 done
7524 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
7525esac
7526
7527 $ac_path_FGREP_found && break 3
7528 done
7529 done
7530 done
7531IFS=$as_save_IFS
7532 if test -z "$ac_cv_path_FGREP"; then
7533 as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
7534 fi
7535else
7536 ac_cv_path_FGREP=$FGREP
7537fi
7538
7539 fi
7540fi
7541{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
7542$as_echo "$ac_cv_path_FGREP" >&6; }
7543 FGREP="$ac_cv_path_FGREP"
7544
7545
7546test -z "$GREP" && GREP=grep
7547
7548
7549
7550
7551
7552
7553
7554
7555
7556
7557
7558
7559
7560
7561
7562
7563
7564
7565
7566# Check whether --with-gnu-ld was given.
7567if test "${with_gnu_ld+set}" = set; then :
7568 withval=$with_gnu_ld; test no = "$withval" || with_gnu_ld=yes
7569else
7570 with_gnu_ld=no
7571fi
7572
7573ac_prog=ld
7574if test yes = "$GCC"; then
7575 # Check if gcc -print-prog-name=ld gives a path.
7576 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
7577$as_echo_n "checking for ld used by $CC... " >&6; }
7578 case $host in
7579 *-*-mingw*)
7580 # gcc leaves a trailing carriage return, which upsets mingw
7581 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
7582 *)
7583 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
7584 esac
7585 case $ac_prog in
7586 # Accept absolute paths.
7587 [\\/]* | ?:[\\/]*)
7588 re_direlt='/[^/][^/]*/\.\./'
7589 # Canonicalize the pathname of ld
7590 ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
7591 while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
7592 ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
7593 done
7594 test -z "$LD" && LD=$ac_prog
7595 ;;
7596 "")
7597 # If it fails, then pretend we aren't using GCC.
7598 ac_prog=ld
7599 ;;
7600 *)
7601 # If it is relative, then search for the first ld in PATH.
7602 with_gnu_ld=unknown
7603 ;;
7604 esac
7605elif test yes = "$with_gnu_ld"; then
7606 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
7607$as_echo_n "checking for GNU ld... " >&6; }
7608else
7609 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
7610$as_echo_n "checking for non-GNU ld... " >&6; }
7611fi
7612if ${lt_cv_path_LD+:} false; then :
7613 $as_echo_n "(cached) " >&6
7614else
7615 if test -z "$LD"; then
7616 lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
7617 for ac_dir in $PATH; do
7618 IFS=$lt_save_ifs
7619 test -z "$ac_dir" && ac_dir=.
7620 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
7621 lt_cv_path_LD=$ac_dir/$ac_prog
7622 # Check to see if the program is GNU ld. I'd rather use --version,
7623 # but apparently some variants of GNU ld only accept -v.
7624 # Break only if it was the GNU/non-GNU ld that we prefer.
7625 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
7626 *GNU* | *'with BFD'*)
7627 test no != "$with_gnu_ld" && break
7628 ;;
7629 *)
7630 test yes != "$with_gnu_ld" && break
7631 ;;
7632 esac
7633 fi
7634 done
7635 IFS=$lt_save_ifs
7636else
7637 lt_cv_path_LD=$LD # Let the user override the test with a path.
7638fi
7639fi
7640
7641LD=$lt_cv_path_LD
7642if test -n "$LD"; then
7643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
7644$as_echo "$LD" >&6; }
7645else
7646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7647$as_echo "no" >&6; }
7648fi
7649test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
7650{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
7651$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
7652if ${lt_cv_prog_gnu_ld+:} false; then :
7653 $as_echo_n "(cached) " >&6
7654else
7655 # I'd rather use --version here, but apparently some GNU lds only accept -v.
7656case `$LD -v 2>&1 </dev/null` in
7657*GNU* | *'with BFD'*)
7658 lt_cv_prog_gnu_ld=yes
7659 ;;
7660*)
7661 lt_cv_prog_gnu_ld=no
7662 ;;
7663esac
7664fi
7665{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
7666$as_echo "$lt_cv_prog_gnu_ld" >&6; }
7667with_gnu_ld=$lt_cv_prog_gnu_ld
7668
7669
7670
7671
7672
7673
7674
7675
7676
7677{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5
7678$as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; }
7679if ${lt_cv_path_NM+:} false; then :
7680 $as_echo_n "(cached) " >&6
7681else
7682 if test -n "$NM"; then
7683 # Let the user override the test.
7684 lt_cv_path_NM=$NM
7685else
7686 lt_nm_to_check=${ac_tool_prefix}nm
7687 if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
7688 lt_nm_to_check="$lt_nm_to_check nm"
7689 fi
7690 for lt_tmp_nm in $lt_nm_to_check; do
7691 lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
7692 for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
7693 IFS=$lt_save_ifs
7694 test -z "$ac_dir" && ac_dir=.
7695 tmp_nm=$ac_dir/$lt_tmp_nm
7696 if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then
7697 # Check to see if the nm accepts a BSD-compat flag.
7698 # Adding the 'sed 1q' prevents false positives on HP-UX, which says:
7699 # nm: unknown option "B" ignored
7700 # Tru64's nm complains that /dev/null is an invalid object file
7701 # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty
7702 case $build_os in
7703 mingw*) lt_bad_file=conftest.nm/nofile ;;
7704 *) lt_bad_file=/dev/null ;;
7705 esac
7706 case `"$tmp_nm" -B $lt_bad_file 2>&1 | sed '1q'` in
7707 *$lt_bad_file* | *'Invalid file or object type'*)
7708 lt_cv_path_NM="$tmp_nm -B"
7709 break 2
7710 ;;
7711 *)
7712 case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
7713 */dev/null*)
7714 lt_cv_path_NM="$tmp_nm -p"
7715 break 2
7716 ;;
7717 *)
7718 lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
7719 continue # so that we can try to find one that supports BSD flags
7720 ;;
7721 esac
7722 ;;
7723 esac
7724 fi
7725 done
7726 IFS=$lt_save_ifs
7727 done
7728 : ${lt_cv_path_NM=no}
7729fi
7730fi
7731{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5
7732$as_echo "$lt_cv_path_NM" >&6; }
7733if test no != "$lt_cv_path_NM"; then
7734 NM=$lt_cv_path_NM
7735else
7736 # Didn't find any BSD compatible name lister, look for dumpbin.
7737 if test -n "$DUMPBIN"; then :
7738 # Let the user override the test.
7739 else
7740 if test -n "$ac_tool_prefix"; then
7741 for ac_prog in dumpbin "link -dump"
7742 do
7743 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
7744set dummy $ac_tool_prefix$ac_prog; ac_word=$2
7745{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7746$as_echo_n "checking for $ac_word... " >&6; }
7747if ${ac_cv_prog_DUMPBIN+:} false; then :
7748 $as_echo_n "(cached) " >&6
7749else
7750 if test -n "$DUMPBIN"; then
7751 ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test.
7752else
7753as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7754for as_dir in $PATH
7755do
7756 IFS=$as_save_IFS
7757 test -z "$as_dir" && as_dir=.
7758 for ac_exec_ext in '' $ac_executable_extensions; do
7759 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7760 ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog"
7761 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7762 break 2
7763 fi
7764done
7765 done
7766IFS=$as_save_IFS
7767
7768fi
7769fi
7770DUMPBIN=$ac_cv_prog_DUMPBIN
7771if test -n "$DUMPBIN"; then
7772 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5
7773$as_echo "$DUMPBIN" >&6; }
7774else
7775 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7776$as_echo "no" >&6; }
7777fi
7778
7779
7780 test -n "$DUMPBIN" && break
7781 done
7782fi
7783if test -z "$DUMPBIN"; then
7784 ac_ct_DUMPBIN=$DUMPBIN
7785 for ac_prog in dumpbin "link -dump"
7786do
7787 # Extract the first word of "$ac_prog", so it can be a program name with args.
7788set dummy $ac_prog; ac_word=$2
7789{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7790$as_echo_n "checking for $ac_word... " >&6; }
7791if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then :
7792 $as_echo_n "(cached) " >&6
7793else
7794 if test -n "$ac_ct_DUMPBIN"; then
7795 ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test.
7796else
7797as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7798for as_dir in $PATH
7799do
7800 IFS=$as_save_IFS
7801 test -z "$as_dir" && as_dir=.
7802 for ac_exec_ext in '' $ac_executable_extensions; do
7803 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7804 ac_cv_prog_ac_ct_DUMPBIN="$ac_prog"
7805 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7806 break 2
7807 fi
7808done
7809 done
7810IFS=$as_save_IFS
7811
7812fi
7813fi
7814ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN
7815if test -n "$ac_ct_DUMPBIN"; then
7816 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5
7817$as_echo "$ac_ct_DUMPBIN" >&6; }
7818else
7819 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7820$as_echo "no" >&6; }
7821fi
7822
7823
7824 test -n "$ac_ct_DUMPBIN" && break
7825done
7826
7827 if test "x$ac_ct_DUMPBIN" = x; then
7828 DUMPBIN=":"
7829 else
7830 case $cross_compiling:$ac_tool_warned in
7831yes:)
7832{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7833$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7834ac_tool_warned=yes ;;
7835esac
7836 DUMPBIN=$ac_ct_DUMPBIN
7837 fi
7838fi
7839
7840 case `$DUMPBIN -symbols -headers /dev/null 2>&1 | sed '1q'` in
7841 *COFF*)
7842 DUMPBIN="$DUMPBIN -symbols -headers"
7843 ;;
7844 *)
7845 DUMPBIN=:
7846 ;;
7847 esac
7848 fi
7849
7850 if test : != "$DUMPBIN"; then
7851 NM=$DUMPBIN
7852 fi
7853fi
7854test -z "$NM" && NM=nm
7855
7856
7857
7858
7859
7860
7861{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5
7862$as_echo_n "checking the name lister ($NM) interface... " >&6; }
7863if ${lt_cv_nm_interface+:} false; then :
7864 $as_echo_n "(cached) " >&6
7865else
7866 lt_cv_nm_interface="BSD nm"
7867 echo "int some_variable = 0;" > conftest.$ac_ext
7868 (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5)
7869 (eval "$ac_compile" 2>conftest.err)
7870 cat conftest.err >&5
7871 (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
7872 (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
7873 cat conftest.err >&5
7874 (eval echo "\"\$as_me:$LINENO: output\"" >&5)
7875 cat conftest.out >&5
7876 if $GREP 'External.*some_variable' conftest.out > /dev/null; then
7877 lt_cv_nm_interface="MS dumpbin"
7878 fi
7879 rm -f conftest*
7880fi
7881{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5
7882$as_echo "$lt_cv_nm_interface" >&6; }
7883
7884{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
7885$as_echo_n "checking whether ln -s works... " >&6; }
7886LN_S=$as_ln_s
7887if test "$LN_S" = "ln -s"; then
7888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7889$as_echo "yes" >&6; }
7890else
7891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
7892$as_echo "no, using $LN_S" >&6; }
7893fi
7894
7895# find the maximum length of command line arguments
7896{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5
7897$as_echo_n "checking the maximum length of command line arguments... " >&6; }
7898if ${lt_cv_sys_max_cmd_len+:} false; then :
7899 $as_echo_n "(cached) " >&6
7900else
7901 i=0
7902 teststring=ABCD
7903
7904 case $build_os in
7905 msdosdjgpp*)
7906 # On DJGPP, this test can blow up pretty badly due to problems in libc
7907 # (any single argument exceeding 2000 bytes causes a buffer overrun
7908 # during glob expansion). Even if it were fixed, the result of this
7909 # check would be larger than it should be.
7910 lt_cv_sys_max_cmd_len=12288; # 12K is about right
7911 ;;
7912
7913 gnu*)
7914 # Under GNU Hurd, this test is not required because there is
7915 # no limit to the length of command line arguments.
7916 # Libtool will interpret -1 as no limit whatsoever
7917 lt_cv_sys_max_cmd_len=-1;
7918 ;;
7919
7920 cygwin* | mingw* | cegcc*)
7921 # On Win9x/ME, this test blows up -- it succeeds, but takes
7922 # about 5 minutes as the teststring grows exponentially.
7923 # Worse, since 9x/ME are not pre-emptively multitasking,
7924 # you end up with a "frozen" computer, even though with patience
7925 # the test eventually succeeds (with a max line length of 256k).
7926 # Instead, let's just punt: use the minimum linelength reported by
7927 # all of the supported platforms: 8192 (on NT/2K/XP).
7928 lt_cv_sys_max_cmd_len=8192;
7929 ;;
7930
7931 mint*)
7932 # On MiNT this can take a long time and run out of memory.
7933 lt_cv_sys_max_cmd_len=8192;
7934 ;;
7935
7936 amigaos*)
7937 # On AmigaOS with pdksh, this test takes hours, literally.
7938 # So we just punt and use a minimum line length of 8192.
7939 lt_cv_sys_max_cmd_len=8192;
7940 ;;
7941
7942 bitrig* | darwin* | dragonfly* | freebsd* | netbsd* | openbsd*)
7943 # This has been around since 386BSD, at least. Likely further.
7944 if test -x /sbin/sysctl; then
7945 lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
7946 elif test -x /usr/sbin/sysctl; then
7947 lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
7948 else
7949 lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
7950 fi
7951 # And add a safety zone
7952 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
7953 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
7954 ;;
7955
7956 interix*)
7957 # We know the value 262144 and hardcode it with a safety zone (like BSD)
7958 lt_cv_sys_max_cmd_len=196608
7959 ;;
7960
7961 os2*)
7962 # The test takes a long time on OS/2.
7963 lt_cv_sys_max_cmd_len=8192
7964 ;;
7965
7966 osf*)
7967 # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
7968 # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
7969 # nice to cause kernel panics so lets avoid the loop below.
7970 # First set a reasonable default.
7971 lt_cv_sys_max_cmd_len=16384
7972 #
7973 if test -x /sbin/sysconfig; then
7974 case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
7975 *1*) lt_cv_sys_max_cmd_len=-1 ;;
7976 esac
7977 fi
7978 ;;
7979 sco3.2v5*)
7980 lt_cv_sys_max_cmd_len=102400
7981 ;;
7982 sysv5* | sco5v6* | sysv4.2uw2*)
7983 kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
7984 if test -n "$kargmax"; then
7985 lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'`
7986 else
7987 lt_cv_sys_max_cmd_len=32768
7988 fi
7989 ;;
7990 *)
7991 lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
7992 if test -n "$lt_cv_sys_max_cmd_len" && \
7993 test undefined != "$lt_cv_sys_max_cmd_len"; then
7994 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
7995 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
7996 else
7997 # Make teststring a little bigger before we do anything with it.
7998 # a 1K string should be a reasonable start.
7999 for i in 1 2 3 4 5 6 7 8; do
8000 teststring=$teststring$teststring
8001 done
8002 SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
8003 # If test is not a shell built-in, we'll probably end up computing a
8004 # maximum length that is only half of the actual maximum length, but
8005 # we can't tell.
8006 while { test X`env echo "$teststring$teststring" 2>/dev/null` \
8007 = "X$teststring$teststring"; } >/dev/null 2>&1 &&
8008 test 17 != "$i" # 1/2 MB should be enough
8009 do
8010 i=`expr $i + 1`
8011 teststring=$teststring$teststring
8012 done
8013 # Only check the string length outside the loop.
8014 lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
8015 teststring=
8016 # Add a significant safety factor because C++ compilers can tack on
8017 # massive amounts of additional arguments before passing them to the
8018 # linker. It appears as though 1/2 is a usable value.
8019 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
8020 fi
8021 ;;
8022 esac
8023
8024fi
8025
8026if test -n "$lt_cv_sys_max_cmd_len"; then
8027 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5
8028$as_echo "$lt_cv_sys_max_cmd_len" >&6; }
8029else
8030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5
8031$as_echo "none" >&6; }
8032fi
8033max_cmd_len=$lt_cv_sys_max_cmd_len
8034
8035
8036
8037
8038
8039
8040: ${CP="cp -f"}
8041: ${MV="mv -f"}
8042: ${RM="rm -f"}
8043
8044if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
8045 lt_unset=unset
8046else
8047 lt_unset=false
8048fi
8049
8050
8051
8052
8053
8054# test EBCDIC or ASCII
8055case `echo X|tr X '\101'` in
8056 A) # ASCII based system
8057 # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
8058 lt_SP2NL='tr \040 \012'
8059 lt_NL2SP='tr \015\012 \040\040'
8060 ;;
8061 *) # EBCDIC based system
8062 lt_SP2NL='tr \100 \n'
8063 lt_NL2SP='tr \r\n \100\100'
8064 ;;
8065esac
8066
8067
8068
8069
8070
8071
8072
8073
8074
8075{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5
8076$as_echo_n "checking how to convert $build file names to $host format... " >&6; }
8077if ${lt_cv_to_host_file_cmd+:} false; then :
8078 $as_echo_n "(cached) " >&6
8079else
8080 case $host in
8081 *-*-mingw* )
8082 case $build in
8083 *-*-mingw* ) # actually msys
8084 lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
8085 ;;
8086 *-*-cygwin* )
8087 lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
8088 ;;
8089 * ) # otherwise, assume *nix
8090 lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
8091 ;;
8092 esac
8093 ;;
8094 *-*-cygwin* )
8095 case $build in
8096 *-*-mingw* ) # actually msys
8097 lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
8098 ;;
8099 *-*-cygwin* )
8100 lt_cv_to_host_file_cmd=func_convert_file_noop
8101 ;;
8102 * ) # otherwise, assume *nix
8103 lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
8104 ;;
8105 esac
8106 ;;
8107 * ) # unhandled hosts (and "normal" native builds)
8108 lt_cv_to_host_file_cmd=func_convert_file_noop
8109 ;;
8110esac
8111
8112fi
8113
8114to_host_file_cmd=$lt_cv_to_host_file_cmd
8115{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5
8116$as_echo "$lt_cv_to_host_file_cmd" >&6; }
8117
8118
8119
8120
8121
8122{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5
8123$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; }
8124if ${lt_cv_to_tool_file_cmd+:} false; then :
8125 $as_echo_n "(cached) " >&6
8126else
8127 #assume ordinary cross tools, or native build.
8128lt_cv_to_tool_file_cmd=func_convert_file_noop
8129case $host in
8130 *-*-mingw* )
8131 case $build in
8132 *-*-mingw* ) # actually msys
8133 lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
8134 ;;
8135 esac
8136 ;;
8137esac
8138
8139fi
8140
8141to_tool_file_cmd=$lt_cv_to_tool_file_cmd
8142{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5
8143$as_echo "$lt_cv_to_tool_file_cmd" >&6; }
8144
8145
8146
8147
8148
8149{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
8150$as_echo_n "checking for $LD option to reload object files... " >&6; }
8151if ${lt_cv_ld_reload_flag+:} false; then :
8152 $as_echo_n "(cached) " >&6
8153else
8154 lt_cv_ld_reload_flag='-r'
8155fi
8156{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5
8157$as_echo "$lt_cv_ld_reload_flag" >&6; }
8158reload_flag=$lt_cv_ld_reload_flag
8159case $reload_flag in
8160"" | " "*) ;;
8161*) reload_flag=" $reload_flag" ;;
8162esac
8163reload_cmds='$LD$reload_flag -o $output$reload_objs'
8164case $host_os in
8165 cygwin* | mingw* | pw32* | cegcc*)
8166 if test yes != "$GCC"; then
8167 reload_cmds=false
8168 fi
8169 ;;
8170 darwin*)
8171 if test yes = "$GCC"; then
8172 reload_cmds='$LTCC $LTCFLAGS -nostdlib $wl-r -o $output$reload_objs'
8173 else
8174 reload_cmds='$LD$reload_flag -o $output$reload_objs'
8175 fi
8176 ;;
8177esac
8178
8179
8180
8181
8182
8183
8184
8185
8186
8187if test -n "$ac_tool_prefix"; then
8188 # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
8189set dummy ${ac_tool_prefix}objdump; ac_word=$2
8190{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8191$as_echo_n "checking for $ac_word... " >&6; }
8192if ${ac_cv_prog_OBJDUMP+:} false; then :
8193 $as_echo_n "(cached) " >&6
8194else
8195 if test -n "$OBJDUMP"; then
8196 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
8197else
8198as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8199for as_dir in $PATH
8200do
8201 IFS=$as_save_IFS
8202 test -z "$as_dir" && as_dir=.
8203 for ac_exec_ext in '' $ac_executable_extensions; do
8204 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8205 ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
8206 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8207 break 2
8208 fi
8209done
8210 done
8211IFS=$as_save_IFS
8212
8213fi
8214fi
8215OBJDUMP=$ac_cv_prog_OBJDUMP
8216if test -n "$OBJDUMP"; then
8217 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
8218$as_echo "$OBJDUMP" >&6; }
8219else
8220 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8221$as_echo "no" >&6; }
8222fi
8223
8224
8225fi
8226if test -z "$ac_cv_prog_OBJDUMP"; then
8227 ac_ct_OBJDUMP=$OBJDUMP
8228 # Extract the first word of "objdump", so it can be a program name with args.
8229set dummy objdump; ac_word=$2
8230{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8231$as_echo_n "checking for $ac_word... " >&6; }
8232if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
8233 $as_echo_n "(cached) " >&6
8234else
8235 if test -n "$ac_ct_OBJDUMP"; then
8236 ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
8237else
8238as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8239for as_dir in $PATH
8240do
8241 IFS=$as_save_IFS
8242 test -z "$as_dir" && as_dir=.
8243 for ac_exec_ext in '' $ac_executable_extensions; do
8244 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8245 ac_cv_prog_ac_ct_OBJDUMP="objdump"
8246 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8247 break 2
8248 fi
8249done
8250 done
8251IFS=$as_save_IFS
8252
8253fi
8254fi
8255ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
8256if test -n "$ac_ct_OBJDUMP"; then
8257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
8258$as_echo "$ac_ct_OBJDUMP" >&6; }
8259else
8260 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8261$as_echo "no" >&6; }
8262fi
8263
8264 if test "x$ac_ct_OBJDUMP" = x; then
8265 OBJDUMP="false"
8266 else
8267 case $cross_compiling:$ac_tool_warned in
8268yes:)
8269{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8270$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8271ac_tool_warned=yes ;;
8272esac
8273 OBJDUMP=$ac_ct_OBJDUMP
8274 fi
8275else
8276 OBJDUMP="$ac_cv_prog_OBJDUMP"
8277fi
8278
8279test -z "$OBJDUMP" && OBJDUMP=objdump
8280
8281
8282
8283
8284
8285
8286{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5
8287$as_echo_n "checking how to recognize dependent libraries... " >&6; }
8288if ${lt_cv_deplibs_check_method+:} false; then :
8289 $as_echo_n "(cached) " >&6
8290else
8291 lt_cv_file_magic_cmd='$MAGIC_CMD'
8292lt_cv_file_magic_test_file=
8293lt_cv_deplibs_check_method='unknown'
8294# Need to set the preceding variable on all platforms that support
8295# interlibrary dependencies.
8296# 'none' -- dependencies not supported.
8297# 'unknown' -- same as none, but documents that we really don't know.
8298# 'pass_all' -- all dependencies passed with no checks.
8299# 'test_compile' -- check by making test program.
8300# 'file_magic [[regex]]' -- check by looking for files in library path
8301# that responds to the $file_magic_cmd with a given extended regex.
8302# If you have 'file' or equivalent on your system and you're not sure
8303# whether 'pass_all' will *always* work, you probably want this one.
8304
8305case $host_os in
8306aix[4-9]*)
8307 lt_cv_deplibs_check_method=pass_all
8308 ;;
8309
8310beos*)
8311 lt_cv_deplibs_check_method=pass_all
8312 ;;
8313
8314bsdi[45]*)
8315 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
8316 lt_cv_file_magic_cmd='/usr/bin/file -L'
8317 lt_cv_file_magic_test_file=/shlib/libc.so
8318 ;;
8319
8320cygwin*)
8321 # func_win32_libid is a shell function defined in ltmain.sh
8322 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
8323 lt_cv_file_magic_cmd='func_win32_libid'
8324 ;;
8325
8326mingw* | pw32*)
8327 # Base MSYS/MinGW do not provide the 'file' command needed by
8328 # func_win32_libid shell function, so use a weaker test based on 'objdump',
8329 # unless we find 'file', for example because we are cross-compiling.
8330 if ( file / ) >/dev/null 2>&1; then
8331 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
8332 lt_cv_file_magic_cmd='func_win32_libid'
8333 else
8334 # Keep this pattern in sync with the one in func_win32_libid.
8335 lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
8336 lt_cv_file_magic_cmd='$OBJDUMP -f'
8337 fi
8338 ;;
8339
8340cegcc*)
8341 # use the weaker test based on 'objdump'. See mingw*.
8342 lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
8343 lt_cv_file_magic_cmd='$OBJDUMP -f'
8344 ;;
8345
8346darwin* | rhapsody*)
8347 lt_cv_deplibs_check_method=pass_all
8348 ;;
8349
8350freebsd* | dragonfly*)
8351 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
8352 case $host_cpu in
8353 i*86 )
8354 # Not sure whether the presence of OpenBSD here was a mistake.
8355 # Let's accept both of them until this is cleared up.
8356 lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library'
8357 lt_cv_file_magic_cmd=/usr/bin/file
8358 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
8359 ;;
8360 esac
8361 else
8362 lt_cv_deplibs_check_method=pass_all
8363 fi
8364 ;;
8365
8366haiku*)
8367 lt_cv_deplibs_check_method=pass_all
8368 ;;
8369
8370hpux10.20* | hpux11*)
8371 lt_cv_file_magic_cmd=/usr/bin/file
8372 case $host_cpu in
8373 ia64*)
8374 lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
8375 lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
8376 ;;
8377 hppa*64*)
8378 lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]'
8379 lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
8380 ;;
8381 *)
8382 lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library'
8383 lt_cv_file_magic_test_file=/usr/lib/libc.sl
8384 ;;
8385 esac
8386 ;;
8387
8388interix[3-9]*)
8389 # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
8390 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$'
8391 ;;
8392
8393irix5* | irix6* | nonstopux*)
8394 case $LD in
8395 *-32|*"-32 ") libmagic=32-bit;;
8396 *-n32|*"-n32 ") libmagic=N32;;
8397 *-64|*"-64 ") libmagic=64-bit;;
8398 *) libmagic=never-match;;
8399 esac
8400 lt_cv_deplibs_check_method=pass_all
8401 ;;
8402
8403# This must be glibc/ELF.
8404linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
8405 lt_cv_deplibs_check_method=pass_all
8406 ;;
8407
8408netbsd* | netbsdelf*-gnu)
8409 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
8410 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
8411 else
8412 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$'
8413 fi
8414 ;;
8415
8416newos6*)
8417 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
8418 lt_cv_file_magic_cmd=/usr/bin/file
8419 lt_cv_file_magic_test_file=/usr/lib/libnls.so
8420 ;;
8421
8422*nto* | *qnx*)
8423 lt_cv_deplibs_check_method=pass_all
8424 ;;
8425
8426openbsd* | bitrig*)
8427 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
8428 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$'
8429 else
8430 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
8431 fi
8432 ;;
8433
8434osf3* | osf4* | osf5*)
8435 lt_cv_deplibs_check_method=pass_all
8436 ;;
8437
8438rdos*)
8439 lt_cv_deplibs_check_method=pass_all
8440 ;;
8441
8442solaris*)
8443 lt_cv_deplibs_check_method=pass_all
8444 ;;
8445
8446sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
8447 lt_cv_deplibs_check_method=pass_all
8448 ;;
8449
8450sysv4 | sysv4.3*)
8451 case $host_vendor in
8452 motorola)
8453 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]'
8454 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
8455 ;;
8456 ncr)
8457 lt_cv_deplibs_check_method=pass_all
8458 ;;
8459 sequent)
8460 lt_cv_file_magic_cmd='/bin/file'
8461 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
8462 ;;
8463 sni)
8464 lt_cv_file_magic_cmd='/bin/file'
8465 lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
8466 lt_cv_file_magic_test_file=/lib/libc.so
8467 ;;
8468 siemens)
8469 lt_cv_deplibs_check_method=pass_all
8470 ;;
8471 pc)
8472 lt_cv_deplibs_check_method=pass_all
8473 ;;
8474 esac
8475 ;;
8476
8477tpf*)
8478 lt_cv_deplibs_check_method=pass_all
8479 ;;
8480os2*)
8481 lt_cv_deplibs_check_method=pass_all
8482 ;;
8483esac
8484
8485fi
8486{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
8487$as_echo "$lt_cv_deplibs_check_method" >&6; }
8488
8489file_magic_glob=
8490want_nocaseglob=no
8491if test "$build" = "$host"; then
8492 case $host_os in
8493 mingw* | pw32*)
8494 if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
8495 want_nocaseglob=yes
8496 else
8497 file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"`
8498 fi
8499 ;;
8500 esac
8501fi
8502
8503file_magic_cmd=$lt_cv_file_magic_cmd
8504deplibs_check_method=$lt_cv_deplibs_check_method
8505test -z "$deplibs_check_method" && deplibs_check_method=unknown
8506
8507
8508
8509
8510
8511
8512
8513
8514
8515
8516
8517
8518
8519
8520
8521
8522
8523
8524
8525
8526
8527
8528if test -n "$ac_tool_prefix"; then
8529 # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
8530set dummy ${ac_tool_prefix}dlltool; ac_word=$2
8531{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8532$as_echo_n "checking for $ac_word... " >&6; }
8533if ${ac_cv_prog_DLLTOOL+:} false; then :
8534 $as_echo_n "(cached) " >&6
8535else
8536 if test -n "$DLLTOOL"; then
8537 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
8538else
8539as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8540for as_dir in $PATH
8541do
8542 IFS=$as_save_IFS
8543 test -z "$as_dir" && as_dir=.
8544 for ac_exec_ext in '' $ac_executable_extensions; do
8545 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8546 ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
8547 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8548 break 2
8549 fi
8550done
8551 done
8552IFS=$as_save_IFS
8553
8554fi
8555fi
8556DLLTOOL=$ac_cv_prog_DLLTOOL
8557if test -n "$DLLTOOL"; then
8558 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
8559$as_echo "$DLLTOOL" >&6; }
8560else
8561 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8562$as_echo "no" >&6; }
8563fi
8564
8565
8566fi
8567if test -z "$ac_cv_prog_DLLTOOL"; then
8568 ac_ct_DLLTOOL=$DLLTOOL
8569 # Extract the first word of "dlltool", so it can be a program name with args.
8570set dummy dlltool; ac_word=$2
8571{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8572$as_echo_n "checking for $ac_word... " >&6; }
8573if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
8574 $as_echo_n "(cached) " >&6
8575else
8576 if test -n "$ac_ct_DLLTOOL"; then
8577 ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
8578else
8579as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8580for as_dir in $PATH
8581do
8582 IFS=$as_save_IFS
8583 test -z "$as_dir" && as_dir=.
8584 for ac_exec_ext in '' $ac_executable_extensions; do
8585 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8586 ac_cv_prog_ac_ct_DLLTOOL="dlltool"
8587 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8588 break 2
8589 fi
8590done
8591 done
8592IFS=$as_save_IFS
8593
8594fi
8595fi
8596ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
8597if test -n "$ac_ct_DLLTOOL"; then
8598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
8599$as_echo "$ac_ct_DLLTOOL" >&6; }
8600else
8601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8602$as_echo "no" >&6; }
8603fi
8604
8605 if test "x$ac_ct_DLLTOOL" = x; then
8606 DLLTOOL="false"
8607 else
8608 case $cross_compiling:$ac_tool_warned in
8609yes:)
8610{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8611$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8612ac_tool_warned=yes ;;
8613esac
8614 DLLTOOL=$ac_ct_DLLTOOL
8615 fi
8616else
8617 DLLTOOL="$ac_cv_prog_DLLTOOL"
8618fi
8619
8620test -z "$DLLTOOL" && DLLTOOL=dlltool
8621
8622
8623
8624
8625
8626
8627
8628{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5
8629$as_echo_n "checking how to associate runtime and link libraries... " >&6; }
8630if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then :
8631 $as_echo_n "(cached) " >&6
8632else
8633 lt_cv_sharedlib_from_linklib_cmd='unknown'
8634
8635case $host_os in
8636cygwin* | mingw* | pw32* | cegcc*)
8637 # two different shell functions defined in ltmain.sh;
8638 # decide which one to use based on capabilities of $DLLTOOL
8639 case `$DLLTOOL --help 2>&1` in
8640 *--identify-strict*)
8641 lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
8642 ;;
8643 *)
8644 lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
8645 ;;
8646 esac
8647 ;;
8648*)
8649 # fallback: assume linklib IS sharedlib
8650 lt_cv_sharedlib_from_linklib_cmd=$ECHO
8651 ;;
8652esac
8653
8654fi
8655{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5
8656$as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; }
8657sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
8658test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
8659
8660
8661
8662
8663
8664
8665
8666if test -n "$ac_tool_prefix"; then
8667 for ac_prog in ar
8668 do
8669 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
8670set dummy $ac_tool_prefix$ac_prog; ac_word=$2
8671{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8672$as_echo_n "checking for $ac_word... " >&6; }
8673if ${ac_cv_prog_AR+:} false; then :
8674 $as_echo_n "(cached) " >&6
8675else
8676 if test -n "$AR"; then
8677 ac_cv_prog_AR="$AR" # Let the user override the test.
8678else
8679as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8680for as_dir in $PATH
8681do
8682 IFS=$as_save_IFS
8683 test -z "$as_dir" && as_dir=.
8684 for ac_exec_ext in '' $ac_executable_extensions; do
8685 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8686 ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
8687 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8688 break 2
8689 fi
8690done
8691 done
8692IFS=$as_save_IFS
8693
8694fi
8695fi
8696AR=$ac_cv_prog_AR
8697if test -n "$AR"; then
8698 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
8699$as_echo "$AR" >&6; }
8700else
8701 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8702$as_echo "no" >&6; }
8703fi
8704
8705
8706 test -n "$AR" && break
8707 done
8708fi
8709if test -z "$AR"; then
8710 ac_ct_AR=$AR
8711 for ac_prog in ar
8712do
8713 # Extract the first word of "$ac_prog", so it can be a program name with args.
8714set dummy $ac_prog; ac_word=$2
8715{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8716$as_echo_n "checking for $ac_word... " >&6; }
8717if ${ac_cv_prog_ac_ct_AR+:} false; then :
8718 $as_echo_n "(cached) " >&6
8719else
8720 if test -n "$ac_ct_AR"; then
8721 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
8722else
8723as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8724for as_dir in $PATH
8725do
8726 IFS=$as_save_IFS
8727 test -z "$as_dir" && as_dir=.
8728 for ac_exec_ext in '' $ac_executable_extensions; do
8729 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8730 ac_cv_prog_ac_ct_AR="$ac_prog"
8731 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8732 break 2
8733 fi
8734done
8735 done
8736IFS=$as_save_IFS
8737
8738fi
8739fi
8740ac_ct_AR=$ac_cv_prog_ac_ct_AR
8741if test -n "$ac_ct_AR"; then
8742 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
8743$as_echo "$ac_ct_AR" >&6; }
8744else
8745 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8746$as_echo "no" >&6; }
8747fi
8748
8749
8750 test -n "$ac_ct_AR" && break
8751done
8752
8753 if test "x$ac_ct_AR" = x; then
8754 AR="false"
8755 else
8756 case $cross_compiling:$ac_tool_warned in
8757yes:)
8758{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8759$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8760ac_tool_warned=yes ;;
8761esac
8762 AR=$ac_ct_AR
8763 fi
8764fi
8765
8766: ${AR=ar}
8767: ${AR_FLAGS=cru}
8768
8769
8770
8771
8772
8773
8774
8775
8776
8777
8778
8779{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
8780$as_echo_n "checking for archiver @FILE support... " >&6; }
8781if ${lt_cv_ar_at_file+:} false; then :
8782 $as_echo_n "(cached) " >&6
8783else
8784 lt_cv_ar_at_file=no
8785 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8786/* end confdefs.h. */
8787
8788int main (void)
8789{
8790
8791 ;
8792 return 0;
8793}
8794_ACEOF
8795if ac_fn_c_try_compile "$LINENO"; then :
8796 echo conftest.$ac_objext > conftest.lst
8797 lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5'
8798 { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
8799 (eval $lt_ar_try) 2>&5
8800 ac_status=$?
8801 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8802 test $ac_status = 0; }
8803 if test 0 -eq "$ac_status"; then
8804 # Ensure the archiver fails upon bogus file names.
8805 rm -f conftest.$ac_objext libconftest.a
8806 { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
8807 (eval $lt_ar_try) 2>&5
8808 ac_status=$?
8809 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8810 test $ac_status = 0; }
8811 if test 0 -ne "$ac_status"; then
8812 lt_cv_ar_at_file=@
8813 fi
8814 fi
8815 rm -f conftest.* libconftest.a
8816
8817fi
8818rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8819
8820fi
8821{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5
8822$as_echo "$lt_cv_ar_at_file" >&6; }
8823
8824if test no = "$lt_cv_ar_at_file"; then
8825 archiver_list_spec=
8826else
8827 archiver_list_spec=$lt_cv_ar_at_file
8828fi
8829
8830
8831
8832
8833
8834
8835
8836if test -n "$ac_tool_prefix"; then
8837 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
8838set dummy ${ac_tool_prefix}strip; ac_word=$2
8839{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8840$as_echo_n "checking for $ac_word... " >&6; }
8841if ${ac_cv_prog_STRIP+:} false; then :
8842 $as_echo_n "(cached) " >&6
8843else
8844 if test -n "$STRIP"; then
8845 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
8846else
8847as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8848for as_dir in $PATH
8849do
8850 IFS=$as_save_IFS
8851 test -z "$as_dir" && as_dir=.
8852 for ac_exec_ext in '' $ac_executable_extensions; do
8853 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8854 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
8855 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8856 break 2
8857 fi
8858done
8859 done
8860IFS=$as_save_IFS
8861
8862fi
8863fi
8864STRIP=$ac_cv_prog_STRIP
8865if test -n "$STRIP"; then
8866 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
8867$as_echo "$STRIP" >&6; }
8868else
8869 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8870$as_echo "no" >&6; }
8871fi
8872
8873
8874fi
8875if test -z "$ac_cv_prog_STRIP"; then
8876 ac_ct_STRIP=$STRIP
8877 # Extract the first word of "strip", so it can be a program name with args.
8878set dummy strip; ac_word=$2
8879{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8880$as_echo_n "checking for $ac_word... " >&6; }
8881if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
8882 $as_echo_n "(cached) " >&6
8883else
8884 if test -n "$ac_ct_STRIP"; then
8885 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
8886else
8887as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8888for as_dir in $PATH
8889do
8890 IFS=$as_save_IFS
8891 test -z "$as_dir" && as_dir=.
8892 for ac_exec_ext in '' $ac_executable_extensions; do
8893 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8894 ac_cv_prog_ac_ct_STRIP="strip"
8895 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8896 break 2
8897 fi
8898done
8899 done
8900IFS=$as_save_IFS
8901
8902fi
8903fi
8904ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
8905if test -n "$ac_ct_STRIP"; then
8906 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
8907$as_echo "$ac_ct_STRIP" >&6; }
8908else
8909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8910$as_echo "no" >&6; }
8911fi
8912
8913 if test "x$ac_ct_STRIP" = x; then
8914 STRIP=":"
8915 else
8916 case $cross_compiling:$ac_tool_warned in
8917yes:)
8918{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8919$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8920ac_tool_warned=yes ;;
8921esac
8922 STRIP=$ac_ct_STRIP
8923 fi
8924else
8925 STRIP="$ac_cv_prog_STRIP"
8926fi
8927
8928test -z "$STRIP" && STRIP=:
8929
8930
8931
8932
8933
8934
8935if test -n "$ac_tool_prefix"; then
8936 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
8937set dummy ${ac_tool_prefix}ranlib; ac_word=$2
8938{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8939$as_echo_n "checking for $ac_word... " >&6; }
8940if ${ac_cv_prog_RANLIB+:} false; then :
8941 $as_echo_n "(cached) " >&6
8942else
8943 if test -n "$RANLIB"; then
8944 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
8945else
8946as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8947for as_dir in $PATH
8948do
8949 IFS=$as_save_IFS
8950 test -z "$as_dir" && as_dir=.
8951 for ac_exec_ext in '' $ac_executable_extensions; do
8952 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8953 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
8954 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8955 break 2
8956 fi
8957done
8958 done
8959IFS=$as_save_IFS
8960
8961fi
8962fi
8963RANLIB=$ac_cv_prog_RANLIB
8964if test -n "$RANLIB"; then
8965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
8966$as_echo "$RANLIB" >&6; }
8967else
8968 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8969$as_echo "no" >&6; }
8970fi
8971
8972
8973fi
8974if test -z "$ac_cv_prog_RANLIB"; then
8975 ac_ct_RANLIB=$RANLIB
8976 # Extract the first word of "ranlib", so it can be a program name with args.
8977set dummy ranlib; ac_word=$2
8978{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8979$as_echo_n "checking for $ac_word... " >&6; }
8980if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
8981 $as_echo_n "(cached) " >&6
8982else
8983 if test -n "$ac_ct_RANLIB"; then
8984 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
8985else
8986as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8987for as_dir in $PATH
8988do
8989 IFS=$as_save_IFS
8990 test -z "$as_dir" && as_dir=.
8991 for ac_exec_ext in '' $ac_executable_extensions; do
8992 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8993 ac_cv_prog_ac_ct_RANLIB="ranlib"
8994 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8995 break 2
8996 fi
8997done
8998 done
8999IFS=$as_save_IFS
9000
9001fi
9002fi
9003ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
9004if test -n "$ac_ct_RANLIB"; then
9005 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
9006$as_echo "$ac_ct_RANLIB" >&6; }
9007else
9008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9009$as_echo "no" >&6; }
9010fi
9011
9012 if test "x$ac_ct_RANLIB" = x; then
9013 RANLIB=":"
9014 else
9015 case $cross_compiling:$ac_tool_warned in
9016yes:)
9017{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9018$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9019ac_tool_warned=yes ;;
9020esac
9021 RANLIB=$ac_ct_RANLIB
9022 fi
9023else
9024 RANLIB="$ac_cv_prog_RANLIB"
9025fi
9026
9027test -z "$RANLIB" && RANLIB=:
9028
9029
9030
9031
9032
9033
9034# Determine commands to create old-style static archives.
9035old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
9036old_postinstall_cmds='chmod 644 $oldlib'
9037old_postuninstall_cmds=
9038
9039if test -n "$RANLIB"; then
9040 case $host_os in
9041 bitrig* | openbsd*)
9042 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib"
9043 ;;
9044 *)
9045 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib"
9046 ;;
9047 esac
9048 old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib"
9049fi
9050
9051case $host_os in
9052 darwin*)
9053 lock_old_archive_extraction=yes ;;
9054 *)
9055 lock_old_archive_extraction=no ;;
9056esac
9057
9058
9059
9060
9061
9062
9063
9064
9065
9066
9067
9068
9069
9070
9071
9072
9073
9074
9075
9076
9077
9078
9079
9080
9081
9082
9083
9084
9085
9086
9087
9088
9089
9090
9091
9092
9093
9094
9095
9096# If no C compiler was specified, use CC.
9097LTCC=${LTCC-"$CC"}
9098
9099# If no C compiler flags were specified, use CFLAGS.
9100LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
9101
9102# Allow CC to be a program name with arguments.
9103compiler=$CC
9104
9105
9106# Check for command to grab the raw symbol name followed by C symbol from nm.
9107{ $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5
9108$as_echo_n "checking command to parse $NM output from $compiler object... " >&6; }
9109if ${lt_cv_sys_global_symbol_pipe+:} false; then :
9110 $as_echo_n "(cached) " >&6
9111else
9112
9113# These are sane defaults that work on at least a few old systems.
9114# [They come from Ultrix. What could be older than Ultrix?!! ;)]
9115
9116# Character class describing NM global symbol codes.
9117symcode='[BCDEGRST]'
9118
9119# Regexp to match symbols that can be accessed directly from C.
9120sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
9121
9122# Define system-specific variables.
9123case $host_os in
9124aix*)
9125 symcode='[BCDT]'
9126 ;;
9127cygwin* | mingw* | pw32* | cegcc*)
9128 symcode='[ABCDGISTW]'
9129 ;;
9130hpux*)
9131 if test ia64 = "$host_cpu"; then
9132 symcode='[ABCDEGRST]'
9133 fi
9134 ;;
9135irix* | nonstopux*)
9136 symcode='[BCDEGRST]'
9137 ;;
9138osf*)
9139 symcode='[BCDEGQRST]'
9140 ;;
9141solaris*)
9142 symcode='[BDRT]'
9143 ;;
9144sco3.2v5*)
9145 symcode='[DT]'
9146 ;;
9147sysv4.2uw2*)
9148 symcode='[DT]'
9149 ;;
9150sysv5* | sco5v6* | unixware* | OpenUNIX*)
9151 symcode='[ABDT]'
9152 ;;
9153sysv4)
9154 symcode='[DFNSTU]'
9155 ;;
9156esac
9157
9158# If we're using GNU nm, then use its standard symbol codes.
9159case `$NM -V 2>&1` in
9160*GNU* | *'with BFD'*)
9161 symcode='[ABCDGIRSTW]' ;;
9162esac
9163
9164if test "$lt_cv_nm_interface" = "MS dumpbin"; then
9165 # Gets list of data symbols to import.
9166 lt_cv_sys_global_symbol_to_import="sed -n -e 's/^I .* \(.*\)$/\1/p'"
9167 # Adjust the below global symbol transforms to fixup imported variables.
9168 lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'"
9169 lt_c_name_hook=" -e 's/^I .* \(.*\)$/ {\"\1\", (void *) 0},/p'"
9170 lt_c_name_lib_hook="\
9171 -e 's/^I .* \(lib.*\)$/ {\"\1\", (void *) 0},/p'\
9172 -e 's/^I .* \(.*\)$/ {\"lib\1\", (void *) 0},/p'"
9173else
9174 # Disable hooks by default.
9175 lt_cv_sys_global_symbol_to_import=
9176 lt_cdecl_hook=
9177 lt_c_name_hook=
9178 lt_c_name_lib_hook=
9179fi
9180
9181# Transform an extracted symbol line into a proper C declaration.
9182# Some systems (esp. on ia64) link data and code symbols differently,
9183# so use this general approach.
9184lt_cv_sys_global_symbol_to_cdecl="sed -n"\
9185$lt_cdecl_hook\
9186" -e 's/^T .* \(.*\)$/extern int \1();/p'"\
9187" -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'"
9188
9189# Transform an extracted symbol line into symbol name and symbol address
9190lt_cv_sys_global_symbol_to_c_name_address="sed -n"\
9191$lt_c_name_hook\
9192" -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\
9193" -e 's/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/p'"
9194
9195# Transform an extracted symbol line into symbol name with lib prefix and
9196# symbol address.
9197lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n"\
9198$lt_c_name_lib_hook\
9199" -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\
9200" -e 's/^$symcode$symcode* .* \(lib.*\)$/ {\"\1\", (void *) \&\1},/p'"\
9201" -e 's/^$symcode$symcode* .* \(.*\)$/ {\"lib\1\", (void *) \&\1},/p'"
9202
9203# Handle CRLF in mingw tool chain
9204opt_cr=
9205case $build_os in
9206mingw*)
9207 opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
9208 ;;
9209esac
9210
9211# Try without a prefix underscore, then with it.
9212for ac_symprfx in "" "_"; do
9213
9214 # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
9215 symxfrm="\\1 $ac_symprfx\\2 \\2"
9216
9217 # Write the raw and C identifiers.
9218 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
9219 # Fake it for dumpbin and say T for any non-static function,
9220 # D for any global variable and I for any imported variable.
9221 # Also find C++ and __fastcall symbols from MSVC++,
9222 # which start with @ or ?.
9223 lt_cv_sys_global_symbol_pipe="$AWK '"\
9224" {last_section=section; section=\$ 3};"\
9225" /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\
9226" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
9227" /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\
9228" /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\
9229" /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\
9230" \$ 0!~/External *\|/{next};"\
9231" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
9232" {if(hide[section]) next};"\
9233" {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\
9234" {split(\$ 0,a,/\||\r/); split(a[2],s)};"\
9235" s[1]~/^[@?]/{print f,s[1],s[1]; next};"\
9236" s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\
9237" ' prfx=^$ac_symprfx"
9238 else
9239 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
9240 fi
9241 lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
9242
9243 # Check to see that the pipe works correctly.
9244 pipe_works=no
9245
9246 rm -f conftest*
9247 cat > conftest.$ac_ext <<_LT_EOF
9248#ifdef __cplusplus
9249extern "C" {
9250#endif
9251char nm_test_var;
9252void nm_test_func(void);
9253void nm_test_func(void){}
9254#ifdef __cplusplus
9255}
9256#endif
9257int main(){nm_test_var='a';nm_test_func();return(0);}
9258_LT_EOF
9259
9260 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9261 (eval $ac_compile) 2>&5
9262 ac_status=$?
9263 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9264 test $ac_status = 0; }; then
9265 # Now try to grab the symbols.
9266 nlist=conftest.nm
Haibo Huang001784b2019-07-19 05:27:28 -07009267 $ECHO "$as_me:$LINENO: $NM conftest.$ac_objext | $lt_cv_sys_global_symbol_pipe > $nlist" >&5
9268 if eval "$NM" conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist 2>&5 && test -s "$nlist"; then
Elliott Hughes82be86d2017-09-20 17:00:17 -07009269 # Try sorting and uniquifying the output.
9270 if sort "$nlist" | uniq > "$nlist"T; then
9271 mv -f "$nlist"T "$nlist"
9272 else
9273 rm -f "$nlist"T
9274 fi
9275
9276 # Make sure that we snagged all the symbols we need.
9277 if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
9278 if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
9279 cat <<_LT_EOF > conftest.$ac_ext
9280/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */
9281#if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE
9282/* DATA imports from DLLs on WIN32 can't be const, because runtime
9283 relocations are performed -- see ld's documentation on pseudo-relocs. */
9284# define LT_DLSYM_CONST
9285#elif defined __osf__
9286/* This system does not cope well with relocations in const data. */
9287# define LT_DLSYM_CONST
9288#else
9289# define LT_DLSYM_CONST const
9290#endif
9291
9292#ifdef __cplusplus
9293extern "C" {
9294#endif
9295
9296_LT_EOF
9297 # Now generate the symbol file.
9298 eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
9299
9300 cat <<_LT_EOF >> conftest.$ac_ext
9301
9302/* The mapping between symbol names and symbols. */
9303LT_DLSYM_CONST struct {
9304 const char *name;
9305 void *address;
9306}
9307lt__PROGRAM__LTX_preloaded_symbols[] =
9308{
9309 { "@PROGRAM@", (void *) 0 },
9310_LT_EOF
9311 $SED "s/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
9312 cat <<\_LT_EOF >> conftest.$ac_ext
9313 {0, (void *) 0}
9314};
9315
9316/* This works around a problem in FreeBSD linker */
9317#ifdef FREEBSD_WORKAROUND
9318static const void *lt_preloaded_setup() {
9319 return lt__PROGRAM__LTX_preloaded_symbols;
9320}
9321#endif
9322
9323#ifdef __cplusplus
9324}
9325#endif
9326_LT_EOF
9327 # Now try linking the two files.
9328 mv -f conftest.$ac_objext conftstm.$ac_objext
9329 lt_globsym_save_LIBS=$LIBS
9330 lt_globsym_save_CFLAGS=$CFLAGS
9331 LIBS=conftstm.$ac_objext
9332 CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
9333 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
9334 (eval $ac_link) 2>&5
9335 ac_status=$?
9336 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9337 test $ac_status = 0; } && test -s conftest$ac_exeext; then
9338 pipe_works=yes
9339 fi
9340 LIBS=$lt_globsym_save_LIBS
9341 CFLAGS=$lt_globsym_save_CFLAGS
9342 else
9343 echo "cannot find nm_test_func in $nlist" >&5
9344 fi
9345 else
9346 echo "cannot find nm_test_var in $nlist" >&5
9347 fi
9348 else
9349 echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
9350 fi
9351 else
9352 echo "$progname: failed program was:" >&5
9353 cat conftest.$ac_ext >&5
9354 fi
9355 rm -rf conftest* conftst*
9356
9357 # Do not use the global_symbol_pipe unless it works.
9358 if test yes = "$pipe_works"; then
9359 break
9360 else
9361 lt_cv_sys_global_symbol_pipe=
9362 fi
9363done
9364
9365fi
9366
9367if test -z "$lt_cv_sys_global_symbol_pipe"; then
9368 lt_cv_sys_global_symbol_to_cdecl=
9369fi
9370if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
9371 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
9372$as_echo "failed" >&6; }
9373else
9374 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
9375$as_echo "ok" >&6; }
9376fi
9377
9378# Response file support.
9379if test "$lt_cv_nm_interface" = "MS dumpbin"; then
9380 nm_file_list_spec='@'
9381elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then
9382 nm_file_list_spec='@'
9383fi
9384
9385
9386
9387
9388
9389
9390
9391
9392
9393
9394
9395
9396
9397
9398
9399
9400
9401
9402
9403
9404
9405
9406
9407
9408
9409
9410
9411
9412
9413
9414
9415
9416
9417
9418
9419
9420
9421{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
9422$as_echo_n "checking for sysroot... " >&6; }
9423
9424# Check whether --with-sysroot was given.
9425if test "${with_sysroot+set}" = set; then :
9426 withval=$with_sysroot;
9427else
9428 with_sysroot=no
9429fi
9430
9431
9432lt_sysroot=
9433case $with_sysroot in #(
9434 yes)
9435 if test yes = "$GCC"; then
9436 lt_sysroot=`$CC --print-sysroot 2>/dev/null`
9437 fi
9438 ;; #(
9439 /*)
9440 lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"`
9441 ;; #(
9442 no|'')
9443 ;; #(
9444 *)
9445 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_sysroot" >&5
9446$as_echo "$with_sysroot" >&6; }
9447 as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5
9448 ;;
9449esac
9450
9451 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5
9452$as_echo "${lt_sysroot:-no}" >&6; }
9453
9454
9455
9456
9457
9458{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a working dd" >&5
9459$as_echo_n "checking for a working dd... " >&6; }
9460if ${ac_cv_path_lt_DD+:} false; then :
9461 $as_echo_n "(cached) " >&6
9462else
9463 printf 0123456789abcdef0123456789abcdef >conftest.i
9464cat conftest.i conftest.i >conftest2.i
9465: ${lt_DD:=$DD}
9466if test -z "$lt_DD"; then
9467 ac_path_lt_DD_found=false
9468 # Loop through the user's path and test for each of PROGNAME-LIST
9469 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9470for as_dir in $PATH
9471do
9472 IFS=$as_save_IFS
9473 test -z "$as_dir" && as_dir=.
9474 for ac_prog in dd; do
9475 for ac_exec_ext in '' $ac_executable_extensions; do
9476 ac_path_lt_DD="$as_dir/$ac_prog$ac_exec_ext"
9477 as_fn_executable_p "$ac_path_lt_DD" || continue
9478if "$ac_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then
9479 cmp -s conftest.i conftest.out \
9480 && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=:
9481fi
9482 $ac_path_lt_DD_found && break 3
9483 done
9484 done
9485 done
9486IFS=$as_save_IFS
9487 if test -z "$ac_cv_path_lt_DD"; then
9488 :
9489 fi
9490else
9491 ac_cv_path_lt_DD=$lt_DD
9492fi
9493
9494rm -f conftest.i conftest2.i conftest.out
9495fi
9496{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_lt_DD" >&5
9497$as_echo "$ac_cv_path_lt_DD" >&6; }
9498
9499
9500{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to truncate binary pipes" >&5
9501$as_echo_n "checking how to truncate binary pipes... " >&6; }
9502if ${lt_cv_truncate_bin+:} false; then :
9503 $as_echo_n "(cached) " >&6
9504else
9505 printf 0123456789abcdef0123456789abcdef >conftest.i
9506cat conftest.i conftest.i >conftest2.i
9507lt_cv_truncate_bin=
9508if "$ac_cv_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then
9509 cmp -s conftest.i conftest.out \
9510 && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1"
9511fi
9512rm -f conftest.i conftest2.i conftest.out
9513test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q"
9514fi
9515{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_truncate_bin" >&5
9516$as_echo "$lt_cv_truncate_bin" >&6; }
9517
9518
9519
9520
9521
9522
9523
9524# Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
9525func_cc_basename ()
9526{
9527 for cc_temp in $*""; do
9528 case $cc_temp in
9529 compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
9530 distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
9531 \-*) ;;
9532 *) break;;
9533 esac
9534 done
9535 func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
9536}
9537
9538# Check whether --enable-libtool-lock was given.
9539if test "${enable_libtool_lock+set}" = set; then :
9540 enableval=$enable_libtool_lock;
9541fi
9542
9543test no = "$enable_libtool_lock" || enable_libtool_lock=yes
9544
9545# Some flags need to be propagated to the compiler or linker for good
9546# libtool support.
9547case $host in
9548ia64-*-hpux*)
9549 # Find out what ABI is being produced by ac_compile, and set mode
9550 # options accordingly.
9551 echo 'int i;' > conftest.$ac_ext
9552 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9553 (eval $ac_compile) 2>&5
9554 ac_status=$?
9555 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9556 test $ac_status = 0; }; then
9557 case `/usr/bin/file conftest.$ac_objext` in
9558 *ELF-32*)
9559 HPUX_IA64_MODE=32
9560 ;;
9561 *ELF-64*)
9562 HPUX_IA64_MODE=64
9563 ;;
9564 esac
9565 fi
9566 rm -rf conftest*
9567 ;;
9568*-*-irix6*)
9569 # Find out what ABI is being produced by ac_compile, and set linker
9570 # options accordingly.
9571 echo '#line '$LINENO' "configure"' > conftest.$ac_ext
9572 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9573 (eval $ac_compile) 2>&5
9574 ac_status=$?
9575 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9576 test $ac_status = 0; }; then
9577 if test yes = "$lt_cv_prog_gnu_ld"; then
9578 case `/usr/bin/file conftest.$ac_objext` in
9579 *32-bit*)
9580 LD="${LD-ld} -melf32bsmip"
9581 ;;
9582 *N32*)
9583 LD="${LD-ld} -melf32bmipn32"
9584 ;;
9585 *64-bit*)
9586 LD="${LD-ld} -melf64bmip"
9587 ;;
9588 esac
9589 else
9590 case `/usr/bin/file conftest.$ac_objext` in
9591 *32-bit*)
9592 LD="${LD-ld} -32"
9593 ;;
9594 *N32*)
9595 LD="${LD-ld} -n32"
9596 ;;
9597 *64-bit*)
9598 LD="${LD-ld} -64"
9599 ;;
9600 esac
9601 fi
9602 fi
9603 rm -rf conftest*
9604 ;;
9605
9606mips64*-*linux*)
9607 # Find out what ABI is being produced by ac_compile, and set linker
9608 # options accordingly.
9609 echo '#line '$LINENO' "configure"' > conftest.$ac_ext
9610 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9611 (eval $ac_compile) 2>&5
9612 ac_status=$?
9613 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9614 test $ac_status = 0; }; then
9615 emul=elf
9616 case `/usr/bin/file conftest.$ac_objext` in
9617 *32-bit*)
9618 emul="${emul}32"
9619 ;;
9620 *64-bit*)
9621 emul="${emul}64"
9622 ;;
9623 esac
9624 case `/usr/bin/file conftest.$ac_objext` in
9625 *MSB*)
9626 emul="${emul}btsmip"
9627 ;;
9628 *LSB*)
9629 emul="${emul}ltsmip"
9630 ;;
9631 esac
9632 case `/usr/bin/file conftest.$ac_objext` in
9633 *N32*)
9634 emul="${emul}n32"
9635 ;;
9636 esac
9637 LD="${LD-ld} -m $emul"
9638 fi
9639 rm -rf conftest*
9640 ;;
9641
9642x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \
9643s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
9644 # Find out what ABI is being produced by ac_compile, and set linker
9645 # options accordingly. Note that the listed cases only cover the
9646 # situations where additional linker options are needed (such as when
9647 # doing 32-bit compilation for a host where ld defaults to 64-bit, or
9648 # vice versa); the common cases where no linker options are needed do
9649 # not appear in the list.
9650 echo 'int i;' > conftest.$ac_ext
9651 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9652 (eval $ac_compile) 2>&5
9653 ac_status=$?
9654 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9655 test $ac_status = 0; }; then
9656 case `/usr/bin/file conftest.o` in
9657 *32-bit*)
9658 case $host in
9659 x86_64-*kfreebsd*-gnu)
9660 LD="${LD-ld} -m elf_i386_fbsd"
9661 ;;
9662 x86_64-*linux*)
9663 case `/usr/bin/file conftest.o` in
9664 *x86-64*)
9665 LD="${LD-ld} -m elf32_x86_64"
9666 ;;
9667 *)
9668 LD="${LD-ld} -m elf_i386"
9669 ;;
9670 esac
9671 ;;
9672 powerpc64le-*linux*)
9673 LD="${LD-ld} -m elf32lppclinux"
9674 ;;
9675 powerpc64-*linux*)
9676 LD="${LD-ld} -m elf32ppclinux"
9677 ;;
9678 s390x-*linux*)
9679 LD="${LD-ld} -m elf_s390"
9680 ;;
9681 sparc64-*linux*)
9682 LD="${LD-ld} -m elf32_sparc"
9683 ;;
9684 esac
9685 ;;
9686 *64-bit*)
9687 case $host in
9688 x86_64-*kfreebsd*-gnu)
9689 LD="${LD-ld} -m elf_x86_64_fbsd"
9690 ;;
9691 x86_64-*linux*)
9692 LD="${LD-ld} -m elf_x86_64"
9693 ;;
9694 powerpcle-*linux*)
9695 LD="${LD-ld} -m elf64lppc"
9696 ;;
9697 powerpc-*linux*)
9698 LD="${LD-ld} -m elf64ppc"
9699 ;;
9700 s390*-*linux*|s390*-*tpf*)
9701 LD="${LD-ld} -m elf64_s390"
9702 ;;
9703 sparc*-*linux*)
9704 LD="${LD-ld} -m elf64_sparc"
9705 ;;
9706 esac
9707 ;;
9708 esac
9709 fi
9710 rm -rf conftest*
9711 ;;
9712
9713*-*-sco3.2v5*)
9714 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
9715 SAVE_CFLAGS=$CFLAGS
9716 CFLAGS="$CFLAGS -belf"
9717 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5
9718$as_echo_n "checking whether the C compiler needs -belf... " >&6; }
9719if ${lt_cv_cc_needs_belf+:} false; then :
9720 $as_echo_n "(cached) " >&6
9721else
9722 ac_ext=c
9723ac_cpp='$CPP $CPPFLAGS'
9724ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
9725ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
9726ac_compiler_gnu=$ac_cv_c_compiler_gnu
9727
9728 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9729/* end confdefs.h. */
9730
9731int main (void)
9732{
9733
9734 ;
9735 return 0;
9736}
9737_ACEOF
9738if ac_fn_c_try_link "$LINENO"; then :
9739 lt_cv_cc_needs_belf=yes
9740else
9741 lt_cv_cc_needs_belf=no
9742fi
9743rm -f core conftest.err conftest.$ac_objext \
9744 conftest$ac_exeext conftest.$ac_ext
9745 ac_ext=c
9746ac_cpp='$CPP $CPPFLAGS'
9747ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
9748ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
9749ac_compiler_gnu=$ac_cv_c_compiler_gnu
9750
9751fi
9752{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5
9753$as_echo "$lt_cv_cc_needs_belf" >&6; }
9754 if test yes != "$lt_cv_cc_needs_belf"; then
9755 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
9756 CFLAGS=$SAVE_CFLAGS
9757 fi
9758 ;;
9759*-*solaris*)
9760 # Find out what ABI is being produced by ac_compile, and set linker
9761 # options accordingly.
9762 echo 'int i;' > conftest.$ac_ext
9763 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9764 (eval $ac_compile) 2>&5
9765 ac_status=$?
9766 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9767 test $ac_status = 0; }; then
9768 case `/usr/bin/file conftest.o` in
9769 *64-bit*)
9770 case $lt_cv_prog_gnu_ld in
9771 yes*)
9772 case $host in
9773 i?86-*-solaris*|x86_64-*-solaris*)
9774 LD="${LD-ld} -m elf_x86_64"
9775 ;;
9776 sparc*-*-solaris*)
9777 LD="${LD-ld} -m elf64_sparc"
9778 ;;
9779 esac
9780 # GNU ld 2.21 introduced _sol2 emulations. Use them if available.
9781 if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then
9782 LD=${LD-ld}_sol2
9783 fi
9784 ;;
9785 *)
9786 if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
9787 LD="${LD-ld} -64"
9788 fi
9789 ;;
9790 esac
9791 ;;
9792 esac
9793 fi
9794 rm -rf conftest*
9795 ;;
9796esac
9797
9798need_locks=$enable_libtool_lock
9799
9800if test -n "$ac_tool_prefix"; then
9801 # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args.
9802set dummy ${ac_tool_prefix}mt; ac_word=$2
9803{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9804$as_echo_n "checking for $ac_word... " >&6; }
9805if ${ac_cv_prog_MANIFEST_TOOL+:} false; then :
9806 $as_echo_n "(cached) " >&6
9807else
9808 if test -n "$MANIFEST_TOOL"; then
9809 ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test.
9810else
9811as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9812for as_dir in $PATH
9813do
9814 IFS=$as_save_IFS
9815 test -z "$as_dir" && as_dir=.
9816 for ac_exec_ext in '' $ac_executable_extensions; do
9817 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9818 ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt"
9819 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9820 break 2
9821 fi
9822done
9823 done
9824IFS=$as_save_IFS
9825
9826fi
9827fi
9828MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL
9829if test -n "$MANIFEST_TOOL"; then
9830 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5
9831$as_echo "$MANIFEST_TOOL" >&6; }
9832else
9833 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9834$as_echo "no" >&6; }
9835fi
9836
9837
9838fi
9839if test -z "$ac_cv_prog_MANIFEST_TOOL"; then
9840 ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL
9841 # Extract the first word of "mt", so it can be a program name with args.
9842set dummy mt; ac_word=$2
9843{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9844$as_echo_n "checking for $ac_word... " >&6; }
9845if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then :
9846 $as_echo_n "(cached) " >&6
9847else
9848 if test -n "$ac_ct_MANIFEST_TOOL"; then
9849 ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test.
9850else
9851as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9852for as_dir in $PATH
9853do
9854 IFS=$as_save_IFS
9855 test -z "$as_dir" && as_dir=.
9856 for ac_exec_ext in '' $ac_executable_extensions; do
9857 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9858 ac_cv_prog_ac_ct_MANIFEST_TOOL="mt"
9859 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9860 break 2
9861 fi
9862done
9863 done
9864IFS=$as_save_IFS
9865
9866fi
9867fi
9868ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL
9869if test -n "$ac_ct_MANIFEST_TOOL"; then
9870 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5
9871$as_echo "$ac_ct_MANIFEST_TOOL" >&6; }
9872else
9873 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9874$as_echo "no" >&6; }
9875fi
9876
9877 if test "x$ac_ct_MANIFEST_TOOL" = x; then
9878 MANIFEST_TOOL=":"
9879 else
9880 case $cross_compiling:$ac_tool_warned in
9881yes:)
9882{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9883$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9884ac_tool_warned=yes ;;
9885esac
9886 MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL
9887 fi
9888else
9889 MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL"
9890fi
9891
9892test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
9893{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5
9894$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; }
9895if ${lt_cv_path_mainfest_tool+:} false; then :
9896 $as_echo_n "(cached) " >&6
9897else
9898 lt_cv_path_mainfest_tool=no
9899 echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5
9900 $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
9901 cat conftest.err >&5
9902 if $GREP 'Manifest Tool' conftest.out > /dev/null; then
9903 lt_cv_path_mainfest_tool=yes
9904 fi
9905 rm -f conftest*
9906fi
9907{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5
9908$as_echo "$lt_cv_path_mainfest_tool" >&6; }
9909if test yes != "$lt_cv_path_mainfest_tool"; then
9910 MANIFEST_TOOL=:
9911fi
9912
9913
9914
9915
9916
9917
9918 case $host_os in
9919 rhapsody* | darwin*)
9920 if test -n "$ac_tool_prefix"; then
9921 # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args.
9922set dummy ${ac_tool_prefix}dsymutil; ac_word=$2
9923{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9924$as_echo_n "checking for $ac_word... " >&6; }
9925if ${ac_cv_prog_DSYMUTIL+:} false; then :
9926 $as_echo_n "(cached) " >&6
9927else
9928 if test -n "$DSYMUTIL"; then
9929 ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
9930else
9931as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9932for as_dir in $PATH
9933do
9934 IFS=$as_save_IFS
9935 test -z "$as_dir" && as_dir=.
9936 for ac_exec_ext in '' $ac_executable_extensions; do
9937 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9938 ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil"
9939 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9940 break 2
9941 fi
9942done
9943 done
9944IFS=$as_save_IFS
9945
9946fi
9947fi
9948DSYMUTIL=$ac_cv_prog_DSYMUTIL
9949if test -n "$DSYMUTIL"; then
9950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
9951$as_echo "$DSYMUTIL" >&6; }
9952else
9953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9954$as_echo "no" >&6; }
9955fi
9956
9957
9958fi
9959if test -z "$ac_cv_prog_DSYMUTIL"; then
9960 ac_ct_DSYMUTIL=$DSYMUTIL
9961 # Extract the first word of "dsymutil", so it can be a program name with args.
9962set dummy dsymutil; ac_word=$2
9963{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9964$as_echo_n "checking for $ac_word... " >&6; }
9965if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then :
9966 $as_echo_n "(cached) " >&6
9967else
9968 if test -n "$ac_ct_DSYMUTIL"; then
9969 ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test.
9970else
9971as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9972for as_dir in $PATH
9973do
9974 IFS=$as_save_IFS
9975 test -z "$as_dir" && as_dir=.
9976 for ac_exec_ext in '' $ac_executable_extensions; do
9977 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9978 ac_cv_prog_ac_ct_DSYMUTIL="dsymutil"
9979 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9980 break 2
9981 fi
9982done
9983 done
9984IFS=$as_save_IFS
9985
9986fi
9987fi
9988ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL
9989if test -n "$ac_ct_DSYMUTIL"; then
9990 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5
9991$as_echo "$ac_ct_DSYMUTIL" >&6; }
9992else
9993 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9994$as_echo "no" >&6; }
9995fi
9996
9997 if test "x$ac_ct_DSYMUTIL" = x; then
9998 DSYMUTIL=":"
9999 else
10000 case $cross_compiling:$ac_tool_warned in
10001yes:)
10002{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
10003$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
10004ac_tool_warned=yes ;;
10005esac
10006 DSYMUTIL=$ac_ct_DSYMUTIL
10007 fi
10008else
10009 DSYMUTIL="$ac_cv_prog_DSYMUTIL"
10010fi
10011
10012 if test -n "$ac_tool_prefix"; then
10013 # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args.
10014set dummy ${ac_tool_prefix}nmedit; ac_word=$2
10015{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10016$as_echo_n "checking for $ac_word... " >&6; }
10017if ${ac_cv_prog_NMEDIT+:} false; then :
10018 $as_echo_n "(cached) " >&6
10019else
10020 if test -n "$NMEDIT"; then
10021 ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test.
10022else
10023as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10024for as_dir in $PATH
10025do
10026 IFS=$as_save_IFS
10027 test -z "$as_dir" && as_dir=.
10028 for ac_exec_ext in '' $ac_executable_extensions; do
10029 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10030 ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit"
10031 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10032 break 2
10033 fi
10034done
10035 done
10036IFS=$as_save_IFS
10037
10038fi
10039fi
10040NMEDIT=$ac_cv_prog_NMEDIT
10041if test -n "$NMEDIT"; then
10042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5
10043$as_echo "$NMEDIT" >&6; }
10044else
10045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10046$as_echo "no" >&6; }
10047fi
10048
10049
10050fi
10051if test -z "$ac_cv_prog_NMEDIT"; then
10052 ac_ct_NMEDIT=$NMEDIT
10053 # Extract the first word of "nmedit", so it can be a program name with args.
10054set dummy nmedit; ac_word=$2
10055{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10056$as_echo_n "checking for $ac_word... " >&6; }
10057if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then :
10058 $as_echo_n "(cached) " >&6
10059else
10060 if test -n "$ac_ct_NMEDIT"; then
10061 ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test.
10062else
10063as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10064for as_dir in $PATH
10065do
10066 IFS=$as_save_IFS
10067 test -z "$as_dir" && as_dir=.
10068 for ac_exec_ext in '' $ac_executable_extensions; do
10069 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10070 ac_cv_prog_ac_ct_NMEDIT="nmedit"
10071 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10072 break 2
10073 fi
10074done
10075 done
10076IFS=$as_save_IFS
10077
10078fi
10079fi
10080ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT
10081if test -n "$ac_ct_NMEDIT"; then
10082 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5
10083$as_echo "$ac_ct_NMEDIT" >&6; }
10084else
10085 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10086$as_echo "no" >&6; }
10087fi
10088
10089 if test "x$ac_ct_NMEDIT" = x; then
10090 NMEDIT=":"
10091 else
10092 case $cross_compiling:$ac_tool_warned in
10093yes:)
10094{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
10095$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
10096ac_tool_warned=yes ;;
10097esac
10098 NMEDIT=$ac_ct_NMEDIT
10099 fi
10100else
10101 NMEDIT="$ac_cv_prog_NMEDIT"
10102fi
10103
10104 if test -n "$ac_tool_prefix"; then
10105 # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args.
10106set dummy ${ac_tool_prefix}lipo; ac_word=$2
10107{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10108$as_echo_n "checking for $ac_word... " >&6; }
10109if ${ac_cv_prog_LIPO+:} false; then :
10110 $as_echo_n "(cached) " >&6
10111else
10112 if test -n "$LIPO"; then
10113 ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
10114else
10115as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10116for as_dir in $PATH
10117do
10118 IFS=$as_save_IFS
10119 test -z "$as_dir" && as_dir=.
10120 for ac_exec_ext in '' $ac_executable_extensions; do
10121 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10122 ac_cv_prog_LIPO="${ac_tool_prefix}lipo"
10123 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10124 break 2
10125 fi
10126done
10127 done
10128IFS=$as_save_IFS
10129
10130fi
10131fi
10132LIPO=$ac_cv_prog_LIPO
10133if test -n "$LIPO"; then
10134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
10135$as_echo "$LIPO" >&6; }
10136else
10137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10138$as_echo "no" >&6; }
10139fi
10140
10141
10142fi
10143if test -z "$ac_cv_prog_LIPO"; then
10144 ac_ct_LIPO=$LIPO
10145 # Extract the first word of "lipo", so it can be a program name with args.
10146set dummy lipo; ac_word=$2
10147{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10148$as_echo_n "checking for $ac_word... " >&6; }
10149if ${ac_cv_prog_ac_ct_LIPO+:} false; then :
10150 $as_echo_n "(cached) " >&6
10151else
10152 if test -n "$ac_ct_LIPO"; then
10153 ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test.
10154else
10155as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10156for as_dir in $PATH
10157do
10158 IFS=$as_save_IFS
10159 test -z "$as_dir" && as_dir=.
10160 for ac_exec_ext in '' $ac_executable_extensions; do
10161 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10162 ac_cv_prog_ac_ct_LIPO="lipo"
10163 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10164 break 2
10165 fi
10166done
10167 done
10168IFS=$as_save_IFS
10169
10170fi
10171fi
10172ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO
10173if test -n "$ac_ct_LIPO"; then
10174 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5
10175$as_echo "$ac_ct_LIPO" >&6; }
10176else
10177 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10178$as_echo "no" >&6; }
10179fi
10180
10181 if test "x$ac_ct_LIPO" = x; then
10182 LIPO=":"
10183 else
10184 case $cross_compiling:$ac_tool_warned in
10185yes:)
10186{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
10187$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
10188ac_tool_warned=yes ;;
10189esac
10190 LIPO=$ac_ct_LIPO
10191 fi
10192else
10193 LIPO="$ac_cv_prog_LIPO"
10194fi
10195
10196 if test -n "$ac_tool_prefix"; then
10197 # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args.
10198set dummy ${ac_tool_prefix}otool; ac_word=$2
10199{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10200$as_echo_n "checking for $ac_word... " >&6; }
10201if ${ac_cv_prog_OTOOL+:} false; then :
10202 $as_echo_n "(cached) " >&6
10203else
10204 if test -n "$OTOOL"; then
10205 ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
10206else
10207as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10208for as_dir in $PATH
10209do
10210 IFS=$as_save_IFS
10211 test -z "$as_dir" && as_dir=.
10212 for ac_exec_ext in '' $ac_executable_extensions; do
10213 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10214 ac_cv_prog_OTOOL="${ac_tool_prefix}otool"
10215 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10216 break 2
10217 fi
10218done
10219 done
10220IFS=$as_save_IFS
10221
10222fi
10223fi
10224OTOOL=$ac_cv_prog_OTOOL
10225if test -n "$OTOOL"; then
10226 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
10227$as_echo "$OTOOL" >&6; }
10228else
10229 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10230$as_echo "no" >&6; }
10231fi
10232
10233
10234fi
10235if test -z "$ac_cv_prog_OTOOL"; then
10236 ac_ct_OTOOL=$OTOOL
10237 # Extract the first word of "otool", so it can be a program name with args.
10238set dummy otool; ac_word=$2
10239{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10240$as_echo_n "checking for $ac_word... " >&6; }
10241if ${ac_cv_prog_ac_ct_OTOOL+:} false; then :
10242 $as_echo_n "(cached) " >&6
10243else
10244 if test -n "$ac_ct_OTOOL"; then
10245 ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test.
10246else
10247as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10248for as_dir in $PATH
10249do
10250 IFS=$as_save_IFS
10251 test -z "$as_dir" && as_dir=.
10252 for ac_exec_ext in '' $ac_executable_extensions; do
10253 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10254 ac_cv_prog_ac_ct_OTOOL="otool"
10255 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10256 break 2
10257 fi
10258done
10259 done
10260IFS=$as_save_IFS
10261
10262fi
10263fi
10264ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL
10265if test -n "$ac_ct_OTOOL"; then
10266 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5
10267$as_echo "$ac_ct_OTOOL" >&6; }
10268else
10269 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10270$as_echo "no" >&6; }
10271fi
10272
10273 if test "x$ac_ct_OTOOL" = x; then
10274 OTOOL=":"
10275 else
10276 case $cross_compiling:$ac_tool_warned in
10277yes:)
10278{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
10279$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
10280ac_tool_warned=yes ;;
10281esac
10282 OTOOL=$ac_ct_OTOOL
10283 fi
10284else
10285 OTOOL="$ac_cv_prog_OTOOL"
10286fi
10287
10288 if test -n "$ac_tool_prefix"; then
10289 # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args.
10290set dummy ${ac_tool_prefix}otool64; ac_word=$2
10291{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10292$as_echo_n "checking for $ac_word... " >&6; }
10293if ${ac_cv_prog_OTOOL64+:} false; then :
10294 $as_echo_n "(cached) " >&6
10295else
10296 if test -n "$OTOOL64"; then
10297 ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test.
10298else
10299as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10300for as_dir in $PATH
10301do
10302 IFS=$as_save_IFS
10303 test -z "$as_dir" && as_dir=.
10304 for ac_exec_ext in '' $ac_executable_extensions; do
10305 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10306 ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64"
10307 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10308 break 2
10309 fi
10310done
10311 done
10312IFS=$as_save_IFS
10313
10314fi
10315fi
10316OTOOL64=$ac_cv_prog_OTOOL64
10317if test -n "$OTOOL64"; then
10318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5
10319$as_echo "$OTOOL64" >&6; }
10320else
10321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10322$as_echo "no" >&6; }
10323fi
10324
10325
10326fi
10327if test -z "$ac_cv_prog_OTOOL64"; then
10328 ac_ct_OTOOL64=$OTOOL64
10329 # Extract the first word of "otool64", so it can be a program name with args.
10330set dummy otool64; ac_word=$2
10331{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10332$as_echo_n "checking for $ac_word... " >&6; }
10333if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then :
10334 $as_echo_n "(cached) " >&6
10335else
10336 if test -n "$ac_ct_OTOOL64"; then
10337 ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test.
10338else
10339as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10340for as_dir in $PATH
10341do
10342 IFS=$as_save_IFS
10343 test -z "$as_dir" && as_dir=.
10344 for ac_exec_ext in '' $ac_executable_extensions; do
10345 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10346 ac_cv_prog_ac_ct_OTOOL64="otool64"
10347 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10348 break 2
10349 fi
10350done
10351 done
10352IFS=$as_save_IFS
10353
10354fi
10355fi
10356ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64
10357if test -n "$ac_ct_OTOOL64"; then
10358 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5
10359$as_echo "$ac_ct_OTOOL64" >&6; }
10360else
10361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10362$as_echo "no" >&6; }
10363fi
10364
10365 if test "x$ac_ct_OTOOL64" = x; then
10366 OTOOL64=":"
10367 else
10368 case $cross_compiling:$ac_tool_warned in
10369yes:)
10370{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
10371$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
10372ac_tool_warned=yes ;;
10373esac
10374 OTOOL64=$ac_ct_OTOOL64
10375 fi
10376else
10377 OTOOL64="$ac_cv_prog_OTOOL64"
10378fi
10379
10380
10381
10382
10383
10384
10385
10386
10387
10388
10389
10390
10391
10392
10393
10394
10395
10396
10397
10398
10399
10400
10401
10402
10403
10404
10405
10406 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5
10407$as_echo_n "checking for -single_module linker flag... " >&6; }
10408if ${lt_cv_apple_cc_single_mod+:} false; then :
10409 $as_echo_n "(cached) " >&6
10410else
10411 lt_cv_apple_cc_single_mod=no
10412 if test -z "$LT_MULTI_MODULE"; then
10413 # By default we will add the -single_module flag. You can override
10414 # by either setting the environment variable LT_MULTI_MODULE
10415 # non-empty at configure time, or by adding -multi_module to the
10416 # link flags.
10417 rm -rf libconftest.dylib*
10418 echo "int foo(void){return 1;}" > conftest.c
10419 echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
10420-dynamiclib -Wl,-single_module conftest.c" >&5
10421 $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
10422 -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
10423 _lt_result=$?
10424 # If there is a non-empty error log, and "single_module"
10425 # appears in it, assume the flag caused a linker warning
10426 if test -s conftest.err && $GREP single_module conftest.err; then
10427 cat conftest.err >&5
10428 # Otherwise, if the output was created with a 0 exit code from
10429 # the compiler, it worked.
10430 elif test -f libconftest.dylib && test 0 = "$_lt_result"; then
10431 lt_cv_apple_cc_single_mod=yes
10432 else
10433 cat conftest.err >&5
10434 fi
10435 rm -rf libconftest.dylib*
10436 rm -f conftest.*
10437 fi
10438fi
10439{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5
10440$as_echo "$lt_cv_apple_cc_single_mod" >&6; }
10441
10442 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5
10443$as_echo_n "checking for -exported_symbols_list linker flag... " >&6; }
10444if ${lt_cv_ld_exported_symbols_list+:} false; then :
10445 $as_echo_n "(cached) " >&6
10446else
10447 lt_cv_ld_exported_symbols_list=no
10448 save_LDFLAGS=$LDFLAGS
10449 echo "_main" > conftest.sym
10450 LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
10451 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10452/* end confdefs.h. */
10453
10454int main (void)
10455{
10456
10457 ;
10458 return 0;
10459}
10460_ACEOF
10461if ac_fn_c_try_link "$LINENO"; then :
10462 lt_cv_ld_exported_symbols_list=yes
10463else
10464 lt_cv_ld_exported_symbols_list=no
10465fi
10466rm -f core conftest.err conftest.$ac_objext \
10467 conftest$ac_exeext conftest.$ac_ext
10468 LDFLAGS=$save_LDFLAGS
10469
10470fi
10471{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5
10472$as_echo "$lt_cv_ld_exported_symbols_list" >&6; }
10473
10474 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5
10475$as_echo_n "checking for -force_load linker flag... " >&6; }
10476if ${lt_cv_ld_force_load+:} false; then :
10477 $as_echo_n "(cached) " >&6
10478else
10479 lt_cv_ld_force_load=no
10480 cat > conftest.c << _LT_EOF
10481int forced_loaded() { return 2;}
10482_LT_EOF
10483 echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5
10484 $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
10485 echo "$AR cru libconftest.a conftest.o" >&5
10486 $AR cru libconftest.a conftest.o 2>&5
10487 echo "$RANLIB libconftest.a" >&5
10488 $RANLIB libconftest.a 2>&5
10489 cat > conftest.c << _LT_EOF
10490int main() { return 0;}
10491_LT_EOF
10492 echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5
10493 $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
10494 _lt_result=$?
10495 if test -s conftest.err && $GREP force_load conftest.err; then
10496 cat conftest.err >&5
10497 elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then
10498 lt_cv_ld_force_load=yes
10499 else
10500 cat conftest.err >&5
10501 fi
10502 rm -f conftest.err libconftest.a conftest conftest.c
10503 rm -rf conftest.dSYM
10504
10505fi
10506{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5
10507$as_echo "$lt_cv_ld_force_load" >&6; }
10508 case $host_os in
10509 rhapsody* | darwin1.[012])
10510 _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;;
10511 darwin1.*)
10512 _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
10513 darwin*) # darwin 5.x on
10514 # if running on 10.5 or later, the deployment target defaults
10515 # to the OS version, if on x86, and 10.4, the deployment
10516 # target defaults to 10.4. Don't you love it?
10517 case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
10518 10.0,*86*-darwin8*|10.0,*-darwin[91]*)
10519 _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;;
10520 10.[012][,.]*)
10521 _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
10522 10.*)
10523 _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;;
10524 esac
10525 ;;
10526 esac
10527 if test yes = "$lt_cv_apple_cc_single_mod"; then
10528 _lt_dar_single_mod='$single_module'
10529 fi
10530 if test yes = "$lt_cv_ld_exported_symbols_list"; then
10531 _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym'
10532 else
10533 _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib'
10534 fi
10535 if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then
10536 _lt_dsymutil='~$DSYMUTIL $lib || :'
10537 else
10538 _lt_dsymutil=
10539 fi
10540 ;;
10541 esac
10542
10543# func_munge_path_list VARIABLE PATH
10544# -----------------------------------
10545# VARIABLE is name of variable containing _space_ separated list of
10546# directories to be munged by the contents of PATH, which is string
10547# having a format:
10548# "DIR[:DIR]:"
10549# string "DIR[ DIR]" will be prepended to VARIABLE
10550# ":DIR[:DIR]"
10551# string "DIR[ DIR]" will be appended to VARIABLE
10552# "DIRP[:DIRP]::[DIRA:]DIRA"
10553# string "DIRP[ DIRP]" will be prepended to VARIABLE and string
10554# "DIRA[ DIRA]" will be appended to VARIABLE
10555# "DIR[:DIR]"
10556# VARIABLE will be replaced by "DIR[ DIR]"
10557func_munge_path_list ()
10558{
10559 case x$2 in
10560 x)
10561 ;;
10562 *:)
10563 eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\"
10564 ;;
10565 x:*)
10566 eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\"
10567 ;;
10568 *::*)
10569 eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\"
10570 eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\"
10571 ;;
10572 *)
10573 eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\"
10574 ;;
10575 esac
10576}
10577
Alex Deymo486467e2017-12-19 19:04:07 +010010578{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
10579$as_echo_n "checking for ANSI C header files... " >&6; }
10580if ${ac_cv_header_stdc+:} false; then :
10581 $as_echo_n "(cached) " >&6
10582else
10583 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10584/* end confdefs.h. */
10585#include <stdlib.h>
10586#include <stdarg.h>
10587#include <string.h>
10588#include <float.h>
10589
10590int main (void)
10591{
10592
10593 ;
10594 return 0;
10595}
10596_ACEOF
10597if ac_fn_c_try_compile "$LINENO"; then :
10598 ac_cv_header_stdc=yes
10599else
10600 ac_cv_header_stdc=no
10601fi
10602rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10603
10604if test $ac_cv_header_stdc = yes; then
10605 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
10606 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10607/* end confdefs.h. */
10608#include <string.h>
10609
10610_ACEOF
10611if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10612 $EGREP "memchr" >/dev/null 2>&1; then :
10613
10614else
10615 ac_cv_header_stdc=no
10616fi
10617rm -f conftest*
10618
10619fi
10620
10621if test $ac_cv_header_stdc = yes; then
10622 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
10623 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10624/* end confdefs.h. */
10625#include <stdlib.h>
10626
10627_ACEOF
10628if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10629 $EGREP "free" >/dev/null 2>&1; then :
10630
10631else
10632 ac_cv_header_stdc=no
10633fi
10634rm -f conftest*
10635
10636fi
10637
10638if test $ac_cv_header_stdc = yes; then
10639 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
10640 if test "$cross_compiling" = yes; then :
10641 :
10642else
10643 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10644/* end confdefs.h. */
10645#include <ctype.h>
10646#include <stdlib.h>
10647#if ((' ' & 0x0FF) == 0x020)
10648# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
10649# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
10650#else
10651# define ISLOWER(c) \
10652 (('a' <= (c) && (c) <= 'i') \
10653 || ('j' <= (c) && (c) <= 'r') \
10654 || ('s' <= (c) && (c) <= 'z'))
10655# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
10656#endif
10657
10658#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
10659int
10660main ()
10661{
10662 int i;
10663 for (i = 0; i < 256; i++)
10664 if (XOR (islower (i), ISLOWER (i))
10665 || toupper (i) != TOUPPER (i))
10666 return 2;
10667 return 0;
10668}
10669_ACEOF
10670if ac_fn_c_try_run "$LINENO"; then :
10671
10672else
10673 ac_cv_header_stdc=no
10674fi
10675rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10676 conftest.$ac_objext conftest.beam conftest.$ac_ext
10677fi
10678
10679fi
10680fi
10681{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
10682$as_echo "$ac_cv_header_stdc" >&6; }
10683if test $ac_cv_header_stdc = yes; then
10684
10685$as_echo "#define STDC_HEADERS 1" >>confdefs.h
10686
10687fi
10688
10689# On IRIX 5.3, sys/types and inttypes.h are conflicting.
10690for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
10691 inttypes.h stdint.h unistd.h
10692do :
10693 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10694ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
10695"
10696if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
10697 cat >>confdefs.h <<_ACEOF
10698#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10699_ACEOF
10700
10701fi
10702
10703done
10704
10705
Elliott Hughes82be86d2017-09-20 17:00:17 -070010706for ac_header in dlfcn.h
10707do :
10708 ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
10709"
10710if test "x$ac_cv_header_dlfcn_h" = xyes; then :
10711 cat >>confdefs.h <<_ACEOF
10712#define HAVE_DLFCN_H 1
10713_ACEOF
10714
10715fi
10716
10717done
10718
10719# ------------------------------------ #
10720# Determine libtool default behavior #
10721# ------------------------------------ #
10722
10723#
10724# Default behavior is to enable shared and static libraries on systems
10725# where libtool knows how to build both library versions, and does not
10726# require separate configuration and build runs for each flavor.
10727#
10728
10729xc_lt_want_enable_shared='yes'
10730xc_lt_want_enable_static='yes'
10731
10732#
10733# User may have disabled shared or static libraries.
10734#
10735case "x$enable_shared" in # (
10736 xno)
10737 xc_lt_want_enable_shared='no'
10738 ;;
10739esac
10740case "x$enable_static" in # (
10741 xno)
10742 xc_lt_want_enable_static='no'
10743 ;;
10744esac
10745if test "x$xc_lt_want_enable_shared" = 'xno' &&
10746 test "x$xc_lt_want_enable_static" = 'xno'; then
10747 as_fn_error $? "can not disable shared and static libraries simultaneously" "$LINENO" 5
10748fi
10749
10750#
10751# Default behavior on systems that require independent configuration
10752# and build runs for shared and static is to enable shared libraries
10753# and disable static ones. On these systems option '--disable-shared'
10754# must be used in order to build a proper static library.
10755#
10756
10757if test "x$xc_lt_want_enable_shared" = 'xyes' &&
10758 test "x$xc_lt_want_enable_static" = 'xyes'; then
10759 case $host_os in # (
10760 pw32* | cegcc* | os2* | aix*)
10761 xc_lt_want_enable_static='no'
10762 ;;
10763 esac
10764fi
10765
10766#
10767# Make libtool aware of current shared and static library preferences
10768# taking in account that, depending on host characteristics, libtool
10769# may modify these option preferences later in this configure script.
10770#
10771
10772enable_shared=$xc_lt_want_enable_shared
10773enable_static=$xc_lt_want_enable_static
10774
10775#
10776# Default behavior is to build PIC objects for shared libraries and
10777# non-PIC objects for static libraries.
10778#
10779
10780xc_lt_want_with_pic='default'
10781
10782#
10783# User may have specified PIC preference.
10784#
10785
10786case "x$with_pic" in # ((
10787 xno)
10788 xc_lt_want_with_pic='no'
10789 ;;
10790 xyes)
10791 xc_lt_want_with_pic='yes'
10792 ;;
10793esac
10794
10795#
10796# Default behavior on some systems where building a shared library out
10797# of non-PIC compiled objects will fail with following linker error
10798# "relocation R_X86_64_32 can not be used when making a shared object"
10799# is to build PIC objects even for static libraries. This behavior may
10800# be overridden using 'configure --disable-shared --without-pic'.
10801#
10802
10803if test "x$xc_lt_want_with_pic" = 'xdefault'; then
10804 case $host_cpu in # (
10805 x86_64 | amd64 | ia64)
10806 case $host_os in # (
10807 linux* | freebsd*)
10808 xc_lt_want_with_pic='yes'
10809 ;;
10810 esac
10811 ;;
10812 esac
10813fi
10814
10815#
10816# Make libtool aware of current PIC preference taking in account that,
10817# depending on host characteristics, libtool may modify PIC default
10818# behavior to fit host system idiosyncrasies later in this script.
10819#
10820
10821with_pic=$xc_lt_want_with_pic
10822
10823## ----------------------- ##
10824## Start of libtool code ##
10825## ----------------------- ##
10826
10827
10828
10829
10830# Set options
10831enable_win32_dll=yes
10832
10833case $host in
10834*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*)
10835 if test -n "$ac_tool_prefix"; then
10836 # Extract the first word of "${ac_tool_prefix}as", so it can be a program name with args.
10837set dummy ${ac_tool_prefix}as; ac_word=$2
10838{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10839$as_echo_n "checking for $ac_word... " >&6; }
10840if ${ac_cv_prog_AS+:} false; then :
10841 $as_echo_n "(cached) " >&6
10842else
10843 if test -n "$AS"; then
10844 ac_cv_prog_AS="$AS" # Let the user override the test.
10845else
10846as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10847for as_dir in $PATH
10848do
10849 IFS=$as_save_IFS
10850 test -z "$as_dir" && as_dir=.
10851 for ac_exec_ext in '' $ac_executable_extensions; do
10852 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10853 ac_cv_prog_AS="${ac_tool_prefix}as"
10854 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10855 break 2
10856 fi
10857done
10858 done
10859IFS=$as_save_IFS
10860
10861fi
10862fi
10863AS=$ac_cv_prog_AS
10864if test -n "$AS"; then
10865 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
10866$as_echo "$AS" >&6; }
10867else
10868 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10869$as_echo "no" >&6; }
10870fi
10871
10872
10873fi
10874if test -z "$ac_cv_prog_AS"; then
10875 ac_ct_AS=$AS
10876 # Extract the first word of "as", so it can be a program name with args.
10877set dummy as; ac_word=$2
10878{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10879$as_echo_n "checking for $ac_word... " >&6; }
10880if ${ac_cv_prog_ac_ct_AS+:} false; then :
10881 $as_echo_n "(cached) " >&6
10882else
10883 if test -n "$ac_ct_AS"; then
10884 ac_cv_prog_ac_ct_AS="$ac_ct_AS" # Let the user override the test.
10885else
10886as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10887for as_dir in $PATH
10888do
10889 IFS=$as_save_IFS
10890 test -z "$as_dir" && as_dir=.
10891 for ac_exec_ext in '' $ac_executable_extensions; do
10892 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10893 ac_cv_prog_ac_ct_AS="as"
10894 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10895 break 2
10896 fi
10897done
10898 done
10899IFS=$as_save_IFS
10900
10901fi
10902fi
10903ac_ct_AS=$ac_cv_prog_ac_ct_AS
10904if test -n "$ac_ct_AS"; then
10905 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AS" >&5
10906$as_echo "$ac_ct_AS" >&6; }
10907else
10908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10909$as_echo "no" >&6; }
10910fi
10911
10912 if test "x$ac_ct_AS" = x; then
10913 AS="false"
10914 else
10915 case $cross_compiling:$ac_tool_warned in
10916yes:)
10917{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
10918$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
10919ac_tool_warned=yes ;;
10920esac
10921 AS=$ac_ct_AS
10922 fi
10923else
10924 AS="$ac_cv_prog_AS"
10925fi
10926
10927 if test -n "$ac_tool_prefix"; then
10928 # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
10929set dummy ${ac_tool_prefix}dlltool; ac_word=$2
10930{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10931$as_echo_n "checking for $ac_word... " >&6; }
10932if ${ac_cv_prog_DLLTOOL+:} false; then :
10933 $as_echo_n "(cached) " >&6
10934else
10935 if test -n "$DLLTOOL"; then
10936 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
10937else
10938as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10939for as_dir in $PATH
10940do
10941 IFS=$as_save_IFS
10942 test -z "$as_dir" && as_dir=.
10943 for ac_exec_ext in '' $ac_executable_extensions; do
10944 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10945 ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
10946 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10947 break 2
10948 fi
10949done
10950 done
10951IFS=$as_save_IFS
10952
10953fi
10954fi
10955DLLTOOL=$ac_cv_prog_DLLTOOL
10956if test -n "$DLLTOOL"; then
10957 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
10958$as_echo "$DLLTOOL" >&6; }
10959else
10960 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10961$as_echo "no" >&6; }
10962fi
10963
10964
10965fi
10966if test -z "$ac_cv_prog_DLLTOOL"; then
10967 ac_ct_DLLTOOL=$DLLTOOL
10968 # Extract the first word of "dlltool", so it can be a program name with args.
10969set dummy dlltool; ac_word=$2
10970{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10971$as_echo_n "checking for $ac_word... " >&6; }
10972if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
10973 $as_echo_n "(cached) " >&6
10974else
10975 if test -n "$ac_ct_DLLTOOL"; then
10976 ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
10977else
10978as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10979for as_dir in $PATH
10980do
10981 IFS=$as_save_IFS
10982 test -z "$as_dir" && as_dir=.
10983 for ac_exec_ext in '' $ac_executable_extensions; do
10984 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10985 ac_cv_prog_ac_ct_DLLTOOL="dlltool"
10986 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10987 break 2
10988 fi
10989done
10990 done
10991IFS=$as_save_IFS
10992
10993fi
10994fi
10995ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
10996if test -n "$ac_ct_DLLTOOL"; then
10997 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
10998$as_echo "$ac_ct_DLLTOOL" >&6; }
10999else
11000 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11001$as_echo "no" >&6; }
11002fi
11003
11004 if test "x$ac_ct_DLLTOOL" = x; then
11005 DLLTOOL="false"
11006 else
11007 case $cross_compiling:$ac_tool_warned in
11008yes:)
11009{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
11010$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
11011ac_tool_warned=yes ;;
11012esac
11013 DLLTOOL=$ac_ct_DLLTOOL
11014 fi
11015else
11016 DLLTOOL="$ac_cv_prog_DLLTOOL"
11017fi
11018
11019 if test -n "$ac_tool_prefix"; then
11020 # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
11021set dummy ${ac_tool_prefix}objdump; ac_word=$2
11022{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11023$as_echo_n "checking for $ac_word... " >&6; }
11024if ${ac_cv_prog_OBJDUMP+:} false; then :
11025 $as_echo_n "(cached) " >&6
11026else
11027 if test -n "$OBJDUMP"; then
11028 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
11029else
11030as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11031for as_dir in $PATH
11032do
11033 IFS=$as_save_IFS
11034 test -z "$as_dir" && as_dir=.
11035 for ac_exec_ext in '' $ac_executable_extensions; do
11036 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11037 ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
11038 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11039 break 2
11040 fi
11041done
11042 done
11043IFS=$as_save_IFS
11044
11045fi
11046fi
11047OBJDUMP=$ac_cv_prog_OBJDUMP
11048if test -n "$OBJDUMP"; then
11049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
11050$as_echo "$OBJDUMP" >&6; }
11051else
11052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11053$as_echo "no" >&6; }
11054fi
11055
11056
11057fi
11058if test -z "$ac_cv_prog_OBJDUMP"; then
11059 ac_ct_OBJDUMP=$OBJDUMP
11060 # Extract the first word of "objdump", so it can be a program name with args.
11061set dummy objdump; ac_word=$2
11062{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11063$as_echo_n "checking for $ac_word... " >&6; }
11064if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
11065 $as_echo_n "(cached) " >&6
11066else
11067 if test -n "$ac_ct_OBJDUMP"; then
11068 ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
11069else
11070as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11071for as_dir in $PATH
11072do
11073 IFS=$as_save_IFS
11074 test -z "$as_dir" && as_dir=.
11075 for ac_exec_ext in '' $ac_executable_extensions; do
11076 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11077 ac_cv_prog_ac_ct_OBJDUMP="objdump"
11078 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11079 break 2
11080 fi
11081done
11082 done
11083IFS=$as_save_IFS
11084
11085fi
11086fi
11087ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
11088if test -n "$ac_ct_OBJDUMP"; then
11089 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
11090$as_echo "$ac_ct_OBJDUMP" >&6; }
11091else
11092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11093$as_echo "no" >&6; }
11094fi
11095
11096 if test "x$ac_ct_OBJDUMP" = x; then
11097 OBJDUMP="false"
11098 else
11099 case $cross_compiling:$ac_tool_warned in
11100yes:)
11101{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
11102$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
11103ac_tool_warned=yes ;;
11104esac
11105 OBJDUMP=$ac_ct_OBJDUMP
11106 fi
11107else
11108 OBJDUMP="$ac_cv_prog_OBJDUMP"
11109fi
11110
11111 ;;
11112esac
11113
11114test -z "$AS" && AS=as
11115
11116
11117
11118
11119
11120test -z "$DLLTOOL" && DLLTOOL=dlltool
11121
11122
11123
11124
11125
11126test -z "$OBJDUMP" && OBJDUMP=objdump
11127
11128
11129
11130
11131
11132
11133
11134 enable_dlopen=no
11135
11136
11137
11138 # Check whether --enable-shared was given.
11139if test "${enable_shared+set}" = set; then :
11140 enableval=$enable_shared; p=${PACKAGE-default}
11141 case $enableval in
11142 yes) enable_shared=yes ;;
11143 no) enable_shared=no ;;
11144 *)
11145 enable_shared=no
11146 # Look at the argument we got. We use all the common list separators.
11147 lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
11148 for pkg in $enableval; do
11149 IFS=$lt_save_ifs
11150 if test "X$pkg" = "X$p"; then
11151 enable_shared=yes
11152 fi
11153 done
11154 IFS=$lt_save_ifs
11155 ;;
11156 esac
11157else
11158 enable_shared=yes
11159fi
11160
11161
11162
11163
11164
11165
11166
11167
11168
11169 # Check whether --enable-static was given.
11170if test "${enable_static+set}" = set; then :
11171 enableval=$enable_static; p=${PACKAGE-default}
11172 case $enableval in
11173 yes) enable_static=yes ;;
11174 no) enable_static=no ;;
11175 *)
11176 enable_static=no
11177 # Look at the argument we got. We use all the common list separators.
11178 lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
11179 for pkg in $enableval; do
11180 IFS=$lt_save_ifs
11181 if test "X$pkg" = "X$p"; then
11182 enable_static=yes
11183 fi
11184 done
11185 IFS=$lt_save_ifs
11186 ;;
11187 esac
11188else
11189 enable_static=yes
11190fi
11191
11192
11193
11194
11195
11196
11197
11198
11199
11200
11201# Check whether --with-pic was given.
11202if test "${with_pic+set}" = set; then :
11203 withval=$with_pic; lt_p=${PACKAGE-default}
11204 case $withval in
11205 yes|no) pic_mode=$withval ;;
11206 *)
11207 pic_mode=default
11208 # Look at the argument we got. We use all the common list separators.
11209 lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
11210 for lt_pkg in $withval; do
11211 IFS=$lt_save_ifs
11212 if test "X$lt_pkg" = "X$lt_p"; then
11213 pic_mode=yes
11214 fi
11215 done
11216 IFS=$lt_save_ifs
11217 ;;
11218 esac
11219else
11220 pic_mode=default
11221fi
11222
11223
11224
11225
11226
11227
11228
11229
11230 # Check whether --enable-fast-install was given.
11231if test "${enable_fast_install+set}" = set; then :
11232 enableval=$enable_fast_install; p=${PACKAGE-default}
11233 case $enableval in
11234 yes) enable_fast_install=yes ;;
11235 no) enable_fast_install=no ;;
11236 *)
11237 enable_fast_install=no
11238 # Look at the argument we got. We use all the common list separators.
11239 lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
11240 for pkg in $enableval; do
11241 IFS=$lt_save_ifs
11242 if test "X$pkg" = "X$p"; then
11243 enable_fast_install=yes
11244 fi
11245 done
11246 IFS=$lt_save_ifs
11247 ;;
11248 esac
11249else
11250 enable_fast_install=yes
11251fi
11252
11253
11254
11255
11256
11257
11258
11259
11260 shared_archive_member_spec=
11261case $host,$enable_shared in
11262power*-*-aix[5-9]*,yes)
11263 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of shared library versioning to provide" >&5
11264$as_echo_n "checking which variant of shared library versioning to provide... " >&6; }
11265
11266# Check whether --with-aix-soname was given.
11267if test "${with_aix_soname+set}" = set; then :
11268 withval=$with_aix_soname; case $withval in
11269 aix|svr4|both)
11270 ;;
11271 *)
11272 as_fn_error $? "Unknown argument to --with-aix-soname" "$LINENO" 5
11273 ;;
11274 esac
11275 lt_cv_with_aix_soname=$with_aix_soname
11276else
11277 if ${lt_cv_with_aix_soname+:} false; then :
11278 $as_echo_n "(cached) " >&6
11279else
11280 lt_cv_with_aix_soname=aix
11281fi
11282
11283 with_aix_soname=$lt_cv_with_aix_soname
11284fi
11285
11286 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_aix_soname" >&5
11287$as_echo "$with_aix_soname" >&6; }
11288 if test aix != "$with_aix_soname"; then
11289 # For the AIX way of multilib, we name the shared archive member
11290 # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o',
11291 # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File.
11292 # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag,
11293 # the AIX toolchain works better with OBJECT_MODE set (default 32).
11294 if test 64 = "${OBJECT_MODE-32}"; then
11295 shared_archive_member_spec=shr_64
11296 else
11297 shared_archive_member_spec=shr
11298 fi
11299 fi
11300 ;;
11301*)
11302 with_aix_soname=aix
11303 ;;
11304esac
11305
11306
11307
11308
11309
11310
11311
11312
11313
11314
11315# This can be used to rebuild libtool when needed
11316LIBTOOL_DEPS=$ltmain
11317
11318# Always use our own libtool.
11319LIBTOOL='$(SHELL) $(top_builddir)/libtool'
11320
11321
11322
11323
11324
11325
11326
11327
11328
11329
11330
11331
11332
11333
11334
11335
11336
11337
11338
11339
11340
11341
11342
11343
11344
11345
11346
11347
11348
11349
11350test -z "$LN_S" && LN_S="ln -s"
11351
11352
11353
11354
11355
11356
11357
11358
11359
11360
11361
11362
11363
11364
11365if test -n "${ZSH_VERSION+set}"; then
11366 setopt NO_GLOB_SUBST
11367fi
11368
11369{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5
11370$as_echo_n "checking for objdir... " >&6; }
11371if ${lt_cv_objdir+:} false; then :
11372 $as_echo_n "(cached) " >&6
11373else
11374 rm -f .libs 2>/dev/null
11375mkdir .libs 2>/dev/null
11376if test -d .libs; then
11377 lt_cv_objdir=.libs
11378else
11379 # MS-DOS does not allow filenames that begin with a dot.
11380 lt_cv_objdir=_libs
11381fi
11382rmdir .libs 2>/dev/null
11383fi
11384{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5
11385$as_echo "$lt_cv_objdir" >&6; }
11386objdir=$lt_cv_objdir
11387
11388
11389
11390
11391
11392cat >>confdefs.h <<_ACEOF
11393#define LT_OBJDIR "$lt_cv_objdir/"
11394_ACEOF
11395
11396
11397
11398
11399case $host_os in
11400aix3*)
11401 # AIX sometimes has problems with the GCC collect2 program. For some
11402 # reason, if we set the COLLECT_NAMES environment variable, the problems
11403 # vanish in a puff of smoke.
11404 if test set != "${COLLECT_NAMES+set}"; then
11405 COLLECT_NAMES=
11406 export COLLECT_NAMES
11407 fi
11408 ;;
11409esac
11410
11411# Global variables:
11412ofile=libtool
11413can_build_shared=yes
11414
11415# All known linkers require a '.a' archive for static linking (except MSVC,
11416# which needs '.lib').
11417libext=a
11418
11419with_gnu_ld=$lt_cv_prog_gnu_ld
11420
11421old_CC=$CC
11422old_CFLAGS=$CFLAGS
11423
11424# Set sane defaults for various variables
11425test -z "$CC" && CC=cc
11426test -z "$LTCC" && LTCC=$CC
11427test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
11428test -z "$LD" && LD=ld
11429test -z "$ac_objext" && ac_objext=o
11430
11431func_cc_basename $compiler
11432cc_basename=$func_cc_basename_result
11433
11434
11435# Only perform the check for file, if the check method requires it
11436test -z "$MAGIC_CMD" && MAGIC_CMD=file
11437case $deplibs_check_method in
11438file_magic*)
11439 if test "$file_magic_cmd" = '$MAGIC_CMD'; then
11440 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5
11441$as_echo_n "checking for ${ac_tool_prefix}file... " >&6; }
11442if ${lt_cv_path_MAGIC_CMD+:} false; then :
11443 $as_echo_n "(cached) " >&6
11444else
11445 case $MAGIC_CMD in
11446[\\/*] | ?:[\\/]*)
11447 lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path.
11448 ;;
11449*)
11450 lt_save_MAGIC_CMD=$MAGIC_CMD
11451 lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
11452 ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
11453 for ac_dir in $ac_dummy; do
11454 IFS=$lt_save_ifs
11455 test -z "$ac_dir" && ac_dir=.
11456 if test -f "$ac_dir/${ac_tool_prefix}file"; then
11457 lt_cv_path_MAGIC_CMD=$ac_dir/"${ac_tool_prefix}file"
11458 if test -n "$file_magic_test_file"; then
11459 case $deplibs_check_method in
11460 "file_magic "*)
11461 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
11462 MAGIC_CMD=$lt_cv_path_MAGIC_CMD
11463 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
11464 $EGREP "$file_magic_regex" > /dev/null; then
11465 :
11466 else
11467 cat <<_LT_EOF 1>&2
11468
11469*** Warning: the command libtool uses to detect shared libraries,
11470*** $file_magic_cmd, produces output that libtool cannot recognize.
11471*** The result is that libtool may fail to recognize shared libraries
11472*** as such. This will affect the creation of libtool libraries that
11473*** depend on shared libraries, but programs linked with such libtool
11474*** libraries will work regardless of this problem. Nevertheless, you
11475*** may want to report the problem to your system manager and/or to
11476*** bug-libtool@gnu.org
11477
11478_LT_EOF
11479 fi ;;
11480 esac
11481 fi
11482 break
11483 fi
11484 done
11485 IFS=$lt_save_ifs
11486 MAGIC_CMD=$lt_save_MAGIC_CMD
11487 ;;
11488esac
11489fi
11490
11491MAGIC_CMD=$lt_cv_path_MAGIC_CMD
11492if test -n "$MAGIC_CMD"; then
11493 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
11494$as_echo "$MAGIC_CMD" >&6; }
11495else
11496 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11497$as_echo "no" >&6; }
11498fi
11499
11500
11501
11502
11503
11504if test -z "$lt_cv_path_MAGIC_CMD"; then
11505 if test -n "$ac_tool_prefix"; then
11506 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5
11507$as_echo_n "checking for file... " >&6; }
11508if ${lt_cv_path_MAGIC_CMD+:} false; then :
11509 $as_echo_n "(cached) " >&6
11510else
11511 case $MAGIC_CMD in
11512[\\/*] | ?:[\\/]*)
11513 lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path.
11514 ;;
11515*)
11516 lt_save_MAGIC_CMD=$MAGIC_CMD
11517 lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
11518 ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
11519 for ac_dir in $ac_dummy; do
11520 IFS=$lt_save_ifs
11521 test -z "$ac_dir" && ac_dir=.
11522 if test -f "$ac_dir/file"; then
11523 lt_cv_path_MAGIC_CMD=$ac_dir/"file"
11524 if test -n "$file_magic_test_file"; then
11525 case $deplibs_check_method in
11526 "file_magic "*)
11527 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
11528 MAGIC_CMD=$lt_cv_path_MAGIC_CMD
11529 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
11530 $EGREP "$file_magic_regex" > /dev/null; then
11531 :
11532 else
11533 cat <<_LT_EOF 1>&2
11534
11535*** Warning: the command libtool uses to detect shared libraries,
11536*** $file_magic_cmd, produces output that libtool cannot recognize.
11537*** The result is that libtool may fail to recognize shared libraries
11538*** as such. This will affect the creation of libtool libraries that
11539*** depend on shared libraries, but programs linked with such libtool
11540*** libraries will work regardless of this problem. Nevertheless, you
11541*** may want to report the problem to your system manager and/or to
11542*** bug-libtool@gnu.org
11543
11544_LT_EOF
11545 fi ;;
11546 esac
11547 fi
11548 break
11549 fi
11550 done
11551 IFS=$lt_save_ifs
11552 MAGIC_CMD=$lt_save_MAGIC_CMD
11553 ;;
11554esac
11555fi
11556
11557MAGIC_CMD=$lt_cv_path_MAGIC_CMD
11558if test -n "$MAGIC_CMD"; then
11559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
11560$as_echo "$MAGIC_CMD" >&6; }
11561else
11562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11563$as_echo "no" >&6; }
11564fi
11565
11566
11567 else
11568 MAGIC_CMD=:
11569 fi
11570fi
11571
11572 fi
11573 ;;
11574esac
11575
11576# Use C for the default configuration in the libtool script
11577
11578lt_save_CC=$CC
11579ac_ext=c
11580ac_cpp='$CPP $CPPFLAGS'
11581ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
11582ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
11583ac_compiler_gnu=$ac_cv_c_compiler_gnu
11584
11585
11586# Source file extension for C test sources.
11587ac_ext=c
11588
11589# Object file extension for compiled C test sources.
11590objext=o
11591objext=$objext
11592
11593# Code to be used in simple compile tests
11594lt_simple_compile_test_code="int some_variable = 0;"
11595
11596# Code to be used in simple link tests
11597lt_simple_link_test_code='int main(){return(0);}'
11598
11599
11600
11601
11602
11603
11604
11605# If no C compiler was specified, use CC.
11606LTCC=${LTCC-"$CC"}
11607
11608# If no C compiler flags were specified, use CFLAGS.
11609LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
11610
11611# Allow CC to be a program name with arguments.
11612compiler=$CC
11613
11614# Save the default compiler, since it gets overwritten when the other
11615# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
11616compiler_DEFAULT=$CC
11617
11618# save warnings/boilerplate of simple test code
11619ac_outfile=conftest.$ac_objext
11620echo "$lt_simple_compile_test_code" >conftest.$ac_ext
11621eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
11622_lt_compiler_boilerplate=`cat conftest.err`
11623$RM conftest*
11624
11625ac_outfile=conftest.$ac_objext
11626echo "$lt_simple_link_test_code" >conftest.$ac_ext
11627eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
11628_lt_linker_boilerplate=`cat conftest.err`
11629$RM -r conftest*
11630
11631
11632## CAVEAT EMPTOR:
11633## There is no encapsulation within the following macros, do not change
11634## the running order or otherwise move them around unless you know exactly
11635## what you are doing...
11636if test -n "$compiler"; then
11637
11638lt_prog_compiler_no_builtin_flag=
11639
11640if test yes = "$GCC"; then
11641 case $cc_basename in
11642 nvcc*)
11643 lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;;
11644 *)
11645 lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;;
11646 esac
11647
11648 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
11649$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; }
11650if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then :
11651 $as_echo_n "(cached) " >&6
11652else
11653 lt_cv_prog_compiler_rtti_exceptions=no
11654 ac_outfile=conftest.$ac_objext
11655 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
11656 lt_compiler_flag="-fno-rtti -fno-exceptions" ## exclude from sc_useless_quotes_in_assignment
11657 # Insert the option either (1) after the last *FLAGS variable, or
11658 # (2) before a word containing "conftest.", or (3) at the end.
11659 # Note that $ac_compile itself does not contain backslashes and begins
11660 # with a dollar sign (not a hyphen), so the echo should work correctly.
11661 # The option is referenced via a variable to avoid confusing sed.
11662 lt_compile=`echo "$ac_compile" | $SED \
11663 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
11664 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
11665 -e 's:$: $lt_compiler_flag:'`
11666 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
11667 (eval "$lt_compile" 2>conftest.err)
11668 ac_status=$?
11669 cat conftest.err >&5
11670 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11671 if (exit $ac_status) && test -s "$ac_outfile"; then
11672 # The compiler can only warn and ignore the option if not recognized
11673 # So say no if there are warnings other than the usual output.
11674 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
11675 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
11676 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
11677 lt_cv_prog_compiler_rtti_exceptions=yes
11678 fi
11679 fi
11680 $RM conftest*
11681
11682fi
11683{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
11684$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; }
11685
11686if test yes = "$lt_cv_prog_compiler_rtti_exceptions"; then
11687 lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
11688else
11689 :
11690fi
11691
11692fi
11693
11694
11695
11696
11697
11698
11699 lt_prog_compiler_wl=
11700lt_prog_compiler_pic=
11701lt_prog_compiler_static=
11702
11703
11704 if test yes = "$GCC"; then
11705 lt_prog_compiler_wl='-Wl,'
11706 lt_prog_compiler_static='-static'
11707
11708 case $host_os in
11709 aix*)
11710 # All AIX code is PIC.
11711 if test ia64 = "$host_cpu"; then
11712 # AIX 5 now supports IA64 processor
11713 lt_prog_compiler_static='-Bstatic'
11714 fi
11715 lt_prog_compiler_pic='-fPIC'
11716 ;;
11717
11718 amigaos*)
11719 case $host_cpu in
11720 powerpc)
11721 # see comment about AmigaOS4 .so support
11722 lt_prog_compiler_pic='-fPIC'
11723 ;;
11724 m68k)
11725 # FIXME: we need at least 68020 code to build shared libraries, but
11726 # adding the '-m68020' flag to GCC prevents building anything better,
11727 # like '-m68040'.
11728 lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
11729 ;;
11730 esac
11731 ;;
11732
11733 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
11734 # PIC is the default for these OSes.
11735 ;;
11736
11737 mingw* | cygwin* | pw32* | os2* | cegcc*)
11738 # This hack is so that the source file can tell whether it is being
11739 # built for inclusion in a dll (and should export symbols for example).
11740 # Although the cygwin gcc ignores -fPIC, still need this for old-style
11741 # (--disable-auto-import) libraries
11742 lt_prog_compiler_pic='-DDLL_EXPORT'
11743 case $host_os in
11744 os2*)
11745 lt_prog_compiler_static='$wl-static'
11746 ;;
11747 esac
11748 ;;
11749
11750 darwin* | rhapsody*)
11751 # PIC is the default on this platform
11752 # Common symbols not allowed in MH_DYLIB files
11753 lt_prog_compiler_pic='-fno-common'
11754 ;;
11755
11756 haiku*)
11757 # PIC is the default for Haiku.
11758 # The "-static" flag exists, but is broken.
11759 lt_prog_compiler_static=
11760 ;;
11761
11762 hpux*)
11763 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
11764 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
11765 # sets the default TLS model and affects inlining.
11766 case $host_cpu in
11767 hppa*64*)
11768 # +Z the default
11769 ;;
11770 *)
11771 lt_prog_compiler_pic='-fPIC'
11772 ;;
11773 esac
11774 ;;
11775
11776 interix[3-9]*)
11777 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
11778 # Instead, we relocate shared libraries at runtime.
11779 ;;
11780
11781 msdosdjgpp*)
11782 # Just because we use GCC doesn't mean we suddenly get shared libraries
11783 # on systems that don't support them.
11784 lt_prog_compiler_can_build_shared=no
11785 enable_shared=no
11786 ;;
11787
11788 *nto* | *qnx*)
11789 # QNX uses GNU C++, but need to define -shared option too, otherwise
11790 # it will coredump.
11791 lt_prog_compiler_pic='-fPIC -shared'
11792 ;;
11793
11794 sysv4*MP*)
11795 if test -d /usr/nec; then
11796 lt_prog_compiler_pic=-Kconform_pic
11797 fi
11798 ;;
11799
11800 *)
11801 lt_prog_compiler_pic='-fPIC'
11802 ;;
11803 esac
11804
11805 case $cc_basename in
11806 nvcc*) # Cuda Compiler Driver 2.2
11807 lt_prog_compiler_wl='-Xlinker '
11808 if test -n "$lt_prog_compiler_pic"; then
11809 lt_prog_compiler_pic="-Xcompiler $lt_prog_compiler_pic"
11810 fi
11811 ;;
11812 esac
11813 else
11814 # PORTME Check for flag to pass linker flags through the system compiler.
11815 case $host_os in
11816 aix*)
11817 lt_prog_compiler_wl='-Wl,'
11818 if test ia64 = "$host_cpu"; then
11819 # AIX 5 now supports IA64 processor
11820 lt_prog_compiler_static='-Bstatic'
11821 else
11822 lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp'
11823 fi
11824 ;;
11825
11826 darwin* | rhapsody*)
11827 # PIC is the default on this platform
11828 # Common symbols not allowed in MH_DYLIB files
11829 lt_prog_compiler_pic='-fno-common'
11830 case $cc_basename in
11831 nagfor*)
11832 # NAG Fortran compiler
11833 lt_prog_compiler_wl='-Wl,-Wl,,'
11834 lt_prog_compiler_pic='-PIC'
11835 lt_prog_compiler_static='-Bstatic'
11836 ;;
11837 esac
11838 ;;
11839
11840 mingw* | cygwin* | pw32* | os2* | cegcc*)
11841 # This hack is so that the source file can tell whether it is being
11842 # built for inclusion in a dll (and should export symbols for example).
11843 lt_prog_compiler_pic='-DDLL_EXPORT'
11844 case $host_os in
11845 os2*)
11846 lt_prog_compiler_static='$wl-static'
11847 ;;
11848 esac
11849 ;;
11850
11851 hpux9* | hpux10* | hpux11*)
11852 lt_prog_compiler_wl='-Wl,'
11853 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
11854 # not for PA HP-UX.
11855 case $host_cpu in
11856 hppa*64*|ia64*)
11857 # +Z the default
11858 ;;
11859 *)
11860 lt_prog_compiler_pic='+Z'
11861 ;;
11862 esac
11863 # Is there a better lt_prog_compiler_static that works with the bundled CC?
11864 lt_prog_compiler_static='$wl-a ${wl}archive'
11865 ;;
11866
11867 irix5* | irix6* | nonstopux*)
11868 lt_prog_compiler_wl='-Wl,'
11869 # PIC (with -KPIC) is the default.
11870 lt_prog_compiler_static='-non_shared'
11871 ;;
11872
11873 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
11874 case $cc_basename in
11875 # old Intel for x86_64, which still supported -KPIC.
11876 ecc*)
11877 lt_prog_compiler_wl='-Wl,'
11878 lt_prog_compiler_pic='-KPIC'
11879 lt_prog_compiler_static='-static'
11880 ;;
11881 # icc used to be incompatible with GCC.
11882 # ICC 10 doesn't accept -KPIC any more.
11883 icc* | ifort*)
11884 lt_prog_compiler_wl='-Wl,'
11885 lt_prog_compiler_pic='-fPIC'
11886 lt_prog_compiler_static='-static'
11887 ;;
11888 # Lahey Fortran 8.1.
11889 lf95*)
11890 lt_prog_compiler_wl='-Wl,'
11891 lt_prog_compiler_pic='--shared'
11892 lt_prog_compiler_static='--static'
11893 ;;
11894 nagfor*)
11895 # NAG Fortran compiler
11896 lt_prog_compiler_wl='-Wl,-Wl,,'
11897 lt_prog_compiler_pic='-PIC'
11898 lt_prog_compiler_static='-Bstatic'
11899 ;;
11900 tcc*)
11901 # Fabrice Bellard et al's Tiny C Compiler
11902 lt_prog_compiler_wl='-Wl,'
11903 lt_prog_compiler_pic='-fPIC'
11904 lt_prog_compiler_static='-static'
11905 ;;
11906 pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
11907 # Portland Group compilers (*not* the Pentium gcc compiler,
11908 # which looks to be a dead project)
11909 lt_prog_compiler_wl='-Wl,'
11910 lt_prog_compiler_pic='-fpic'
11911 lt_prog_compiler_static='-Bstatic'
11912 ;;
11913 ccc*)
11914 lt_prog_compiler_wl='-Wl,'
11915 # All Alpha code is PIC.
11916 lt_prog_compiler_static='-non_shared'
11917 ;;
11918 xl* | bgxl* | bgf* | mpixl*)
11919 # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
11920 lt_prog_compiler_wl='-Wl,'
11921 lt_prog_compiler_pic='-qpic'
11922 lt_prog_compiler_static='-qstaticlink'
11923 ;;
11924 *)
11925 case `$CC -V 2>&1 | sed 5q` in
11926 *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [1-7].* | *Sun*Fortran*\ 8.[0-3]*)
11927 # Sun Fortran 8.3 passes all unrecognized flags to the linker
11928 lt_prog_compiler_pic='-KPIC'
11929 lt_prog_compiler_static='-Bstatic'
11930 lt_prog_compiler_wl=''
11931 ;;
11932 *Sun\ F* | *Sun*Fortran*)
11933 lt_prog_compiler_pic='-KPIC'
11934 lt_prog_compiler_static='-Bstatic'
11935 lt_prog_compiler_wl='-Qoption ld '
11936 ;;
11937 *Sun\ C*)
11938 # Sun C 5.9
11939 lt_prog_compiler_pic='-KPIC'
11940 lt_prog_compiler_static='-Bstatic'
11941 lt_prog_compiler_wl='-Wl,'
11942 ;;
11943 *Intel*\ [CF]*Compiler*)
11944 lt_prog_compiler_wl='-Wl,'
11945 lt_prog_compiler_pic='-fPIC'
11946 lt_prog_compiler_static='-static'
11947 ;;
11948 *Portland\ Group*)
11949 lt_prog_compiler_wl='-Wl,'
11950 lt_prog_compiler_pic='-fpic'
11951 lt_prog_compiler_static='-Bstatic'
11952 ;;
11953 esac
11954 ;;
11955 esac
11956 ;;
11957
11958 newsos6)
11959 lt_prog_compiler_pic='-KPIC'
11960 lt_prog_compiler_static='-Bstatic'
11961 ;;
11962
11963 *nto* | *qnx*)
11964 # QNX uses GNU C++, but need to define -shared option too, otherwise
11965 # it will coredump.
11966 lt_prog_compiler_pic='-fPIC -shared'
11967 ;;
11968
11969 osf3* | osf4* | osf5*)
11970 lt_prog_compiler_wl='-Wl,'
11971 # All OSF/1 code is PIC.
11972 lt_prog_compiler_static='-non_shared'
11973 ;;
11974
11975 rdos*)
11976 lt_prog_compiler_static='-non_shared'
11977 ;;
11978
11979 solaris*)
11980 lt_prog_compiler_pic='-KPIC'
11981 lt_prog_compiler_static='-Bstatic'
11982 case $cc_basename in
11983 f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
11984 lt_prog_compiler_wl='-Qoption ld ';;
11985 *)
11986 lt_prog_compiler_wl='-Wl,';;
11987 esac
11988 ;;
11989
11990 sunos4*)
11991 lt_prog_compiler_wl='-Qoption ld '
11992 lt_prog_compiler_pic='-PIC'
11993 lt_prog_compiler_static='-Bstatic'
11994 ;;
11995
11996 sysv4 | sysv4.2uw2* | sysv4.3*)
11997 lt_prog_compiler_wl='-Wl,'
11998 lt_prog_compiler_pic='-KPIC'
11999 lt_prog_compiler_static='-Bstatic'
12000 ;;
12001
12002 sysv4*MP*)
12003 if test -d /usr/nec; then
12004 lt_prog_compiler_pic='-Kconform_pic'
12005 lt_prog_compiler_static='-Bstatic'
12006 fi
12007 ;;
12008
12009 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
12010 lt_prog_compiler_wl='-Wl,'
12011 lt_prog_compiler_pic='-KPIC'
12012 lt_prog_compiler_static='-Bstatic'
12013 ;;
12014
12015 unicos*)
12016 lt_prog_compiler_wl='-Wl,'
12017 lt_prog_compiler_can_build_shared=no
12018 ;;
12019
12020 uts4*)
12021 lt_prog_compiler_pic='-pic'
12022 lt_prog_compiler_static='-Bstatic'
12023 ;;
12024
12025 *)
12026 lt_prog_compiler_can_build_shared=no
12027 ;;
12028 esac
12029 fi
12030
12031case $host_os in
12032 # For platforms that do not support PIC, -DPIC is meaningless:
12033 *djgpp*)
12034 lt_prog_compiler_pic=
12035 ;;
12036 *)
12037 lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
12038 ;;
12039esac
12040
12041{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
12042$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
12043if ${lt_cv_prog_compiler_pic+:} false; then :
12044 $as_echo_n "(cached) " >&6
12045else
12046 lt_cv_prog_compiler_pic=$lt_prog_compiler_pic
12047fi
12048{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5
12049$as_echo "$lt_cv_prog_compiler_pic" >&6; }
12050lt_prog_compiler_pic=$lt_cv_prog_compiler_pic
12051
12052#
12053# Check to make sure the PIC flag actually works.
12054#
12055if test -n "$lt_prog_compiler_pic"; then
12056 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
12057$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; }
12058if ${lt_cv_prog_compiler_pic_works+:} false; then :
12059 $as_echo_n "(cached) " >&6
12060else
12061 lt_cv_prog_compiler_pic_works=no
12062 ac_outfile=conftest.$ac_objext
12063 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
12064 lt_compiler_flag="$lt_prog_compiler_pic -DPIC" ## exclude from sc_useless_quotes_in_assignment
12065 # Insert the option either (1) after the last *FLAGS variable, or
12066 # (2) before a word containing "conftest.", or (3) at the end.
12067 # Note that $ac_compile itself does not contain backslashes and begins
12068 # with a dollar sign (not a hyphen), so the echo should work correctly.
12069 # The option is referenced via a variable to avoid confusing sed.
12070 lt_compile=`echo "$ac_compile" | $SED \
12071 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
12072 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
12073 -e 's:$: $lt_compiler_flag:'`
12074 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
12075 (eval "$lt_compile" 2>conftest.err)
12076 ac_status=$?
12077 cat conftest.err >&5
12078 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12079 if (exit $ac_status) && test -s "$ac_outfile"; then
12080 # The compiler can only warn and ignore the option if not recognized
12081 # So say no if there are warnings other than the usual output.
12082 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
12083 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
12084 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
12085 lt_cv_prog_compiler_pic_works=yes
12086 fi
12087 fi
12088 $RM conftest*
12089
12090fi
12091{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5
12092$as_echo "$lt_cv_prog_compiler_pic_works" >&6; }
12093
12094if test yes = "$lt_cv_prog_compiler_pic_works"; then
12095 case $lt_prog_compiler_pic in
12096 "" | " "*) ;;
12097 *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
12098 esac
12099else
12100 lt_prog_compiler_pic=
12101 lt_prog_compiler_can_build_shared=no
12102fi
12103
12104fi
12105
12106
12107
12108
12109
12110
12111
12112
12113
12114
12115
12116#
12117# Check to make sure the static flag actually works.
12118#
12119wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\"
12120{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
12121$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
12122if ${lt_cv_prog_compiler_static_works+:} false; then :
12123 $as_echo_n "(cached) " >&6
12124else
12125 lt_cv_prog_compiler_static_works=no
12126 save_LDFLAGS=$LDFLAGS
12127 LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
12128 echo "$lt_simple_link_test_code" > conftest.$ac_ext
12129 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
12130 # The linker can only warn and ignore the option if not recognized
12131 # So say no if there are warnings
12132 if test -s conftest.err; then
12133 # Append any errors to the config.log.
12134 cat conftest.err 1>&5
12135 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
12136 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
12137 if diff conftest.exp conftest.er2 >/dev/null; then
12138 lt_cv_prog_compiler_static_works=yes
12139 fi
12140 else
12141 lt_cv_prog_compiler_static_works=yes
12142 fi
12143 fi
12144 $RM -r conftest*
12145 LDFLAGS=$save_LDFLAGS
12146
12147fi
12148{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5
12149$as_echo "$lt_cv_prog_compiler_static_works" >&6; }
12150
12151if test yes = "$lt_cv_prog_compiler_static_works"; then
12152 :
12153else
12154 lt_prog_compiler_static=
12155fi
12156
12157
12158
12159
12160
12161
12162
12163 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
12164$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
12165if ${lt_cv_prog_compiler_c_o+:} false; then :
12166 $as_echo_n "(cached) " >&6
12167else
12168 lt_cv_prog_compiler_c_o=no
12169 $RM -r conftest 2>/dev/null
12170 mkdir conftest
12171 cd conftest
12172 mkdir out
12173 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
12174
12175 lt_compiler_flag="-o out/conftest2.$ac_objext"
12176 # Insert the option either (1) after the last *FLAGS variable, or
12177 # (2) before a word containing "conftest.", or (3) at the end.
12178 # Note that $ac_compile itself does not contain backslashes and begins
12179 # with a dollar sign (not a hyphen), so the echo should work correctly.
12180 lt_compile=`echo "$ac_compile" | $SED \
12181 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
12182 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
12183 -e 's:$: $lt_compiler_flag:'`
12184 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
12185 (eval "$lt_compile" 2>out/conftest.err)
12186 ac_status=$?
12187 cat out/conftest.err >&5
12188 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12189 if (exit $ac_status) && test -s out/conftest2.$ac_objext
12190 then
12191 # The compiler can only warn and ignore the option if not recognized
12192 # So say no if there are warnings
12193 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
12194 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
12195 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
12196 lt_cv_prog_compiler_c_o=yes
12197 fi
12198 fi
12199 chmod u+w . 2>&5
12200 $RM conftest*
12201 # SGI C++ compiler will create directory out/ii_files/ for
12202 # template instantiation
12203 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
12204 $RM out/* && rmdir out
12205 cd ..
12206 $RM -r conftest
12207 $RM conftest*
12208
12209fi
12210{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
12211$as_echo "$lt_cv_prog_compiler_c_o" >&6; }
12212
12213
12214
12215
12216
12217
12218 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
12219$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
12220if ${lt_cv_prog_compiler_c_o+:} false; then :
12221 $as_echo_n "(cached) " >&6
12222else
12223 lt_cv_prog_compiler_c_o=no
12224 $RM -r conftest 2>/dev/null
12225 mkdir conftest
12226 cd conftest
12227 mkdir out
12228 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
12229
12230 lt_compiler_flag="-o out/conftest2.$ac_objext"
12231 # Insert the option either (1) after the last *FLAGS variable, or
12232 # (2) before a word containing "conftest.", or (3) at the end.
12233 # Note that $ac_compile itself does not contain backslashes and begins
12234 # with a dollar sign (not a hyphen), so the echo should work correctly.
12235 lt_compile=`echo "$ac_compile" | $SED \
12236 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
12237 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
12238 -e 's:$: $lt_compiler_flag:'`
12239 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
12240 (eval "$lt_compile" 2>out/conftest.err)
12241 ac_status=$?
12242 cat out/conftest.err >&5
12243 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12244 if (exit $ac_status) && test -s out/conftest2.$ac_objext
12245 then
12246 # The compiler can only warn and ignore the option if not recognized
12247 # So say no if there are warnings
12248 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
12249 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
12250 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
12251 lt_cv_prog_compiler_c_o=yes
12252 fi
12253 fi
12254 chmod u+w . 2>&5
12255 $RM conftest*
12256 # SGI C++ compiler will create directory out/ii_files/ for
12257 # template instantiation
12258 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
12259 $RM out/* && rmdir out
12260 cd ..
12261 $RM -r conftest
12262 $RM conftest*
12263
12264fi
12265{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
12266$as_echo "$lt_cv_prog_compiler_c_o" >&6; }
12267
12268
12269
12270
12271hard_links=nottested
12272if test no = "$lt_cv_prog_compiler_c_o" && test no != "$need_locks"; then
12273 # do not overwrite the value of need_locks provided by the user
12274 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
12275$as_echo_n "checking if we can lock with hard links... " >&6; }
12276 hard_links=yes
12277 $RM conftest*
12278 ln conftest.a conftest.b 2>/dev/null && hard_links=no
12279 touch conftest.a
12280 ln conftest.a conftest.b 2>&5 || hard_links=no
12281 ln conftest.a conftest.b 2>/dev/null && hard_links=no
12282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
12283$as_echo "$hard_links" >&6; }
12284 if test no = "$hard_links"; then
12285 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&5
12286$as_echo "$as_me: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&2;}
12287 need_locks=warn
12288 fi
12289else
12290 need_locks=no
12291fi
12292
12293
12294
12295
12296
12297
12298 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
12299$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
12300
12301 runpath_var=
12302 allow_undefined_flag=
12303 always_export_symbols=no
12304 archive_cmds=
12305 archive_expsym_cmds=
12306 compiler_needs_object=no
12307 enable_shared_with_static_runtimes=no
12308 export_dynamic_flag_spec=
12309 export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
12310 hardcode_automatic=no
12311 hardcode_direct=no
12312 hardcode_direct_absolute=no
12313 hardcode_libdir_flag_spec=
12314 hardcode_libdir_separator=
12315 hardcode_minus_L=no
12316 hardcode_shlibpath_var=unsupported
12317 inherit_rpath=no
12318 link_all_deplibs=unknown
12319 module_cmds=
12320 module_expsym_cmds=
12321 old_archive_from_new_cmds=
12322 old_archive_from_expsyms_cmds=
12323 thread_safe_flag_spec=
12324 whole_archive_flag_spec=
12325 # include_expsyms should be a list of space-separated symbols to be *always*
12326 # included in the symbol list
12327 include_expsyms=
12328 # exclude_expsyms can be an extended regexp of symbols to exclude
12329 # it will be wrapped by ' (' and ')$', so one must not match beginning or
12330 # end of line. Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc',
12331 # as well as any symbol that contains 'd'.
12332 exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
12333 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
12334 # platforms (ab)use it in PIC code, but their linkers get confused if
12335 # the symbol is explicitly referenced. Since portable code cannot
12336 # rely on this symbol name, it's probably fine to never include it in
12337 # preloaded symbol tables.
12338 # Exclude shared library initialization/finalization symbols.
12339 extract_expsyms_cmds=
12340
12341 case $host_os in
12342 cygwin* | mingw* | pw32* | cegcc*)
12343 # FIXME: the MSVC++ port hasn't been tested in a loooong time
12344 # When not using gcc, we currently assume that we are using
12345 # Microsoft Visual C++.
12346 if test yes != "$GCC"; then
12347 with_gnu_ld=no
12348 fi
12349 ;;
12350 interix*)
12351 # we just hope/assume this is gcc and not c89 (= MSVC++)
12352 with_gnu_ld=yes
12353 ;;
12354 openbsd* | bitrig*)
12355 with_gnu_ld=no
12356 ;;
12357 linux* | k*bsd*-gnu | gnu*)
12358 link_all_deplibs=no
12359 ;;
12360 esac
12361
12362 ld_shlibs=yes
12363
12364 # On some targets, GNU ld is compatible enough with the native linker
12365 # that we're better off using the native interface for both.
12366 lt_use_gnu_ld_interface=no
12367 if test yes = "$with_gnu_ld"; then
12368 case $host_os in
12369 aix*)
12370 # The AIX port of GNU ld has always aspired to compatibility
12371 # with the native linker. However, as the warning in the GNU ld
12372 # block says, versions before 2.19.5* couldn't really create working
12373 # shared libraries, regardless of the interface used.
12374 case `$LD -v 2>&1` in
12375 *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
12376 *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;;
12377 *\ \(GNU\ Binutils\)\ [3-9]*) ;;
12378 *)
12379 lt_use_gnu_ld_interface=yes
12380 ;;
12381 esac
12382 ;;
12383 *)
12384 lt_use_gnu_ld_interface=yes
12385 ;;
12386 esac
12387 fi
12388
12389 if test yes = "$lt_use_gnu_ld_interface"; then
12390 # If archive_cmds runs LD, not CC, wlarc should be empty
12391 wlarc='$wl'
12392
12393 # Set some defaults for GNU ld with shared library support. These
12394 # are reset later if shared libraries are not supported. Putting them
12395 # here allows them to be overridden if necessary.
12396 runpath_var=LD_RUN_PATH
12397 hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
12398 export_dynamic_flag_spec='$wl--export-dynamic'
12399 # ancient GNU ld didn't support --whole-archive et. al.
12400 if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
12401 whole_archive_flag_spec=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive'
12402 else
12403 whole_archive_flag_spec=
12404 fi
12405 supports_anon_versioning=no
12406 case `$LD -v | $SED -e 's/(^)\+)\s\+//' 2>&1` in
12407 *GNU\ gold*) supports_anon_versioning=yes ;;
12408 *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
12409 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
12410 *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
12411 *\ 2.11.*) ;; # other 2.11 versions
12412 *) supports_anon_versioning=yes ;;
12413 esac
12414
12415 # See if GNU ld supports shared libraries.
12416 case $host_os in
12417 aix[3-9]*)
12418 # On AIX/PPC, the GNU linker is very broken
12419 if test ia64 != "$host_cpu"; then
12420 ld_shlibs=no
12421 cat <<_LT_EOF 1>&2
12422
12423*** Warning: the GNU linker, at least up to release 2.19, is reported
12424*** to be unable to reliably create shared libraries on AIX.
12425*** Therefore, libtool is disabling shared libraries support. If you
12426*** really care for shared libraries, you may want to install binutils
12427*** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
12428*** You will then need to restart the configuration process.
12429
12430_LT_EOF
12431 fi
12432 ;;
12433
12434 amigaos*)
12435 case $host_cpu in
12436 powerpc)
12437 # see comment about AmigaOS4 .so support
12438 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
12439 archive_expsym_cmds=''
12440 ;;
12441 m68k)
12442 archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
12443 hardcode_libdir_flag_spec='-L$libdir'
12444 hardcode_minus_L=yes
12445 ;;
12446 esac
12447 ;;
12448
12449 beos*)
12450 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
12451 allow_undefined_flag=unsupported
12452 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
12453 # support --undefined. This deserves some investigation. FIXME
12454 archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
12455 else
12456 ld_shlibs=no
12457 fi
12458 ;;
12459
12460 cygwin* | mingw* | pw32* | cegcc*)
12461 # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
12462 # as there is no search path for DLLs.
12463 hardcode_libdir_flag_spec='-L$libdir'
12464 export_dynamic_flag_spec='$wl--export-all-symbols'
12465 allow_undefined_flag=unsupported
12466 always_export_symbols=no
12467 enable_shared_with_static_runtimes=yes
12468 export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols'
12469 exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'
12470
12471 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
12472 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
12473 # If the export-symbols file already is a .def file, use it as
12474 # is; otherwise, prepend EXPORTS...
12475 archive_expsym_cmds='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then
12476 cp $export_symbols $output_objdir/$soname.def;
12477 else
12478 echo EXPORTS > $output_objdir/$soname.def;
12479 cat $export_symbols >> $output_objdir/$soname.def;
12480 fi~
12481 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
12482 else
12483 ld_shlibs=no
12484 fi
12485 ;;
12486
12487 haiku*)
12488 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
12489 link_all_deplibs=yes
12490 ;;
12491
12492 os2*)
12493 hardcode_libdir_flag_spec='-L$libdir'
12494 hardcode_minus_L=yes
12495 allow_undefined_flag=unsupported
12496 shrext_cmds=.dll
12497 archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
12498 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
12499 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
12500 $ECHO EXPORTS >> $output_objdir/$libname.def~
12501 emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
12502 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
12503 emximp -o $lib $output_objdir/$libname.def'
12504 archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
12505 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
12506 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
12507 $ECHO EXPORTS >> $output_objdir/$libname.def~
12508 prefix_cmds="$SED"~
12509 if test EXPORTS = "`$SED 1q $export_symbols`"; then
12510 prefix_cmds="$prefix_cmds -e 1d";
12511 fi~
12512 prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
12513 cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
12514 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
12515 emximp -o $lib $output_objdir/$libname.def'
12516 old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
12517 enable_shared_with_static_runtimes=yes
12518 ;;
12519
12520 interix[3-9]*)
12521 hardcode_direct=no
12522 hardcode_shlibpath_var=no
12523 hardcode_libdir_flag_spec='$wl-rpath,$libdir'
12524 export_dynamic_flag_spec='$wl-E'
12525 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
12526 # Instead, shared libraries are loaded at an image base (0x10000000 by
12527 # default) and relocated if they conflict, which is a slow very memory
12528 # consuming and fragmenting process. To avoid this, we pick a random,
12529 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
12530 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
12531 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
12532 archive_expsym_cmds='sed "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
12533 ;;
12534
12535 gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
12536 tmp_diet=no
12537 if test linux-dietlibc = "$host_os"; then
12538 case $cc_basename in
12539 diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
12540 esac
12541 fi
12542 if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
12543 && test no = "$tmp_diet"
12544 then
12545 tmp_addflag=' $pic_flag'
12546 tmp_sharedflag='-shared'
12547 case $cc_basename,$host_cpu in
12548 pgcc*) # Portland Group C compiler
12549 whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
12550 tmp_addflag=' $pic_flag'
12551 ;;
12552 pgf77* | pgf90* | pgf95* | pgfortran*)
12553 # Portland Group f77 and f90 compilers
12554 whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
12555 tmp_addflag=' $pic_flag -Mnomain' ;;
12556 ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
12557 tmp_addflag=' -i_dynamic' ;;
12558 efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
12559 tmp_addflag=' -i_dynamic -nofor_main' ;;
12560 ifc* | ifort*) # Intel Fortran compiler
12561 tmp_addflag=' -nofor_main' ;;
12562 lf95*) # Lahey Fortran 8.1
12563 whole_archive_flag_spec=
12564 tmp_sharedflag='--shared' ;;
12565 nagfor*) # NAGFOR 5.3
12566 tmp_sharedflag='-Wl,-shared' ;;
12567 xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below)
12568 tmp_sharedflag='-qmkshrobj'
12569 tmp_addflag= ;;
12570 nvcc*) # Cuda Compiler Driver 2.2
12571 whole_archive_flag_spec='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
12572 compiler_needs_object=yes
12573 ;;
12574 esac
12575 case `$CC -V 2>&1 | sed 5q` in
12576 *Sun\ C*) # Sun C 5.9
12577 whole_archive_flag_spec='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive'
12578 compiler_needs_object=yes
12579 tmp_sharedflag='-G' ;;
12580 *Sun\ F*) # Sun Fortran 8.3
12581 tmp_sharedflag='-G' ;;
12582 esac
12583 archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
12584
12585 if test yes = "$supports_anon_versioning"; then
12586 archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
12587 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
12588 echo "local: *; };" >> $output_objdir/$libname.ver~
12589 $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib'
12590 fi
12591
12592 case $cc_basename in
12593 tcc*)
12594 export_dynamic_flag_spec='-rdynamic'
12595 ;;
12596 xlf* | bgf* | bgxlf* | mpixlf*)
12597 # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
12598 whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
12599 hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
12600 archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
12601 if test yes = "$supports_anon_versioning"; then
12602 archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
12603 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
12604 echo "local: *; };" >> $output_objdir/$libname.ver~
12605 $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
12606 fi
12607 ;;
12608 esac
12609 else
12610 ld_shlibs=no
12611 fi
12612 ;;
12613
12614 netbsd* | netbsdelf*-gnu)
12615 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
12616 archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
12617 wlarc=
12618 else
12619 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
12620 archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
12621 fi
12622 ;;
12623
12624 solaris*)
12625 if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
12626 ld_shlibs=no
12627 cat <<_LT_EOF 1>&2
12628
12629*** Warning: The releases 2.8.* of the GNU linker cannot reliably
12630*** create shared libraries on Solaris systems. Therefore, libtool
12631*** is disabling shared libraries support. We urge you to upgrade GNU
12632*** binutils to release 2.9.1 or newer. Another option is to modify
12633*** your PATH or compiler configuration so that the native linker is
12634*** used, and then restart.
12635
12636_LT_EOF
12637 elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
12638 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
12639 archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
12640 else
12641 ld_shlibs=no
12642 fi
12643 ;;
12644
12645 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
12646 case `$LD -v 2>&1` in
12647 *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*)
12648 ld_shlibs=no
12649 cat <<_LT_EOF 1>&2
12650
12651*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot
12652*** reliably create shared libraries on SCO systems. Therefore, libtool
12653*** is disabling shared libraries support. We urge you to upgrade GNU
12654*** binutils to release 2.16.91.0.3 or newer. Another option is to modify
12655*** your PATH or compiler configuration so that the native linker is
12656*** used, and then restart.
12657
12658_LT_EOF
12659 ;;
12660 *)
12661 # For security reasons, it is highly recommended that you always
12662 # use absolute paths for naming shared libraries, and exclude the
12663 # DT_RUNPATH tag from executables and libraries. But doing so
12664 # requires that you compile everything twice, which is a pain.
12665 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
12666 hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
12667 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
12668 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
12669 else
12670 ld_shlibs=no
12671 fi
12672 ;;
12673 esac
12674 ;;
12675
12676 sunos4*)
12677 archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
12678 wlarc=
12679 hardcode_direct=yes
12680 hardcode_shlibpath_var=no
12681 ;;
12682
12683 *)
12684 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
12685 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
12686 archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
12687 else
12688 ld_shlibs=no
12689 fi
12690 ;;
12691 esac
12692
12693 if test no = "$ld_shlibs"; then
12694 runpath_var=
12695 hardcode_libdir_flag_spec=
12696 export_dynamic_flag_spec=
12697 whole_archive_flag_spec=
12698 fi
12699 else
12700 # PORTME fill in a description of your system's linker (not GNU ld)
12701 case $host_os in
12702 aix3*)
12703 allow_undefined_flag=unsupported
12704 always_export_symbols=yes
12705 archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname'
12706 # Note: this linker hardcodes the directories in LIBPATH if there
12707 # are no directories specified by -L.
12708 hardcode_minus_L=yes
12709 if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then
12710 # Neither direct hardcoding nor static linking is supported with a
12711 # broken collect2.
12712 hardcode_direct=unsupported
12713 fi
12714 ;;
12715
12716 aix[4-9]*)
12717 if test ia64 = "$host_cpu"; then
12718 # On IA64, the linker does run time linking by default, so we don't
12719 # have to do anything special.
12720 aix_use_runtimelinking=no
12721 exp_sym_flag='-Bexport'
12722 no_entry_flag=
12723 else
12724 # If we're using GNU nm, then we don't want the "-C" option.
12725 # -C means demangle to GNU nm, but means don't demangle to AIX nm.
12726 # Without the "-l" option, or with the "-B" option, AIX nm treats
12727 # weak defined symbols like other global defined symbols, whereas
12728 # GNU nm marks them as "W".
12729 # While the 'weak' keyword is ignored in the Export File, we need
12730 # it in the Import File for the 'aix-soname' feature, so we have
12731 # to replace the "-B" option with "-P" for AIX nm.
12732 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
12733 export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols'
12734 else
12735 export_symbols_cmds='`func_echo_all $NM | $SED -e '\''s/B\([^B]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && (substr(\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols'
12736 fi
12737 aix_use_runtimelinking=no
12738
12739 # Test if we are trying to use run time linking or normal
12740 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
12741 # have runtime linking enabled, and use it for executables.
12742 # For shared libraries, we enable/disable runtime linking
12743 # depending on the kind of the shared library created -
12744 # when "with_aix_soname,aix_use_runtimelinking" is:
12745 # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables
12746 # "aix,yes" lib.so shared, rtl:yes, for executables
12747 # lib.a static archive
12748 # "both,no" lib.so.V(shr.o) shared, rtl:yes
12749 # lib.a(lib.so.V) shared, rtl:no, for executables
12750 # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables
12751 # lib.a(lib.so.V) shared, rtl:no
12752 # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables
12753 # lib.a static archive
12754 case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
12755 for ld_flag in $LDFLAGS; do
12756 if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then
12757 aix_use_runtimelinking=yes
12758 break
12759 fi
12760 done
12761 if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then
12762 # With aix-soname=svr4, we create the lib.so.V shared archives only,
12763 # so we don't have lib.a shared libs to link our executables.
12764 # We have to force runtime linking in this case.
12765 aix_use_runtimelinking=yes
12766 LDFLAGS="$LDFLAGS -Wl,-brtl"
12767 fi
12768 ;;
12769 esac
12770
12771 exp_sym_flag='-bexport'
12772 no_entry_flag='-bnoentry'
12773 fi
12774
12775 # When large executables or shared objects are built, AIX ld can
12776 # have problems creating the table of contents. If linking a library
12777 # or program results in "error TOC overflow" add -mminimal-toc to
12778 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
12779 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
12780
12781 archive_cmds=''
12782 hardcode_direct=yes
12783 hardcode_direct_absolute=yes
12784 hardcode_libdir_separator=':'
12785 link_all_deplibs=yes
12786 file_list_spec='$wl-f,'
12787 case $with_aix_soname,$aix_use_runtimelinking in
12788 aix,*) ;; # traditional, no import file
12789 svr4,* | *,yes) # use import file
12790 # The Import File defines what to hardcode.
12791 hardcode_direct=no
12792 hardcode_direct_absolute=no
12793 ;;
12794 esac
12795
12796 if test yes = "$GCC"; then
12797 case $host_os in aix4.[012]|aix4.[012].*)
12798 # We only want to do this on AIX 4.2 and lower, the check
12799 # below for broken collect2 doesn't work under 4.3+
12800 collect2name=`$CC -print-prog-name=collect2`
12801 if test -f "$collect2name" &&
12802 strings "$collect2name" | $GREP resolve_lib_name >/dev/null
12803 then
12804 # We have reworked collect2
12805 :
12806 else
12807 # We have old collect2
12808 hardcode_direct=unsupported
12809 # It fails to find uninstalled libraries when the uninstalled
12810 # path is not listed in the libpath. Setting hardcode_minus_L
12811 # to unsupported forces relinking
12812 hardcode_minus_L=yes
12813 hardcode_libdir_flag_spec='-L$libdir'
12814 hardcode_libdir_separator=
12815 fi
12816 ;;
12817 esac
12818 shared_flag='-shared'
12819 if test yes = "$aix_use_runtimelinking"; then
12820 shared_flag="$shared_flag "'$wl-G'
12821 fi
12822 # Need to ensure runtime linking is disabled for the traditional
12823 # shared library, or the linker may eventually find shared libraries
12824 # /with/ Import File - we do not want to mix them.
12825 shared_flag_aix='-shared'
12826 shared_flag_svr4='-shared $wl-G'
12827 else
12828 # not using gcc
12829 if test ia64 = "$host_cpu"; then
12830 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
12831 # chokes on -Wl,-G. The following line is correct:
12832 shared_flag='-G'
12833 else
12834 if test yes = "$aix_use_runtimelinking"; then
12835 shared_flag='$wl-G'
12836 else
12837 shared_flag='$wl-bM:SRE'
12838 fi
12839 shared_flag_aix='$wl-bM:SRE'
12840 shared_flag_svr4='$wl-G'
12841 fi
12842 fi
12843
12844 export_dynamic_flag_spec='$wl-bexpall'
12845 # It seems that -bexpall does not export symbols beginning with
12846 # underscore (_), so it is better to generate a list of symbols to export.
12847 always_export_symbols=yes
12848 if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then
12849 # Warning - without using the other runtime loading flags (-brtl),
12850 # -berok will link without error, but may produce a broken library.
12851 allow_undefined_flag='-berok'
12852 # Determine the default libpath from the value encoded in an
12853 # empty executable.
12854 if test set = "${lt_cv_aix_libpath+set}"; then
12855 aix_libpath=$lt_cv_aix_libpath
12856else
12857 if ${lt_cv_aix_libpath_+:} false; then :
12858 $as_echo_n "(cached) " >&6
12859else
12860 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12861/* end confdefs.h. */
12862
12863int main (void)
12864{
12865
12866 ;
12867 return 0;
12868}
12869_ACEOF
12870if ac_fn_c_try_link "$LINENO"; then :
12871
12872 lt_aix_libpath_sed='
12873 /Import File Strings/,/^$/ {
12874 /^0/ {
12875 s/^0 *\([^ ]*\) *$/\1/
12876 p
12877 }
12878 }'
12879 lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12880 # Check for a 64-bit object if we didn't find anything.
12881 if test -z "$lt_cv_aix_libpath_"; then
12882 lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12883 fi
12884fi
12885rm -f core conftest.err conftest.$ac_objext \
12886 conftest$ac_exeext conftest.$ac_ext
12887 if test -z "$lt_cv_aix_libpath_"; then
12888 lt_cv_aix_libpath_=/usr/lib:/lib
12889 fi
12890
12891fi
12892
12893 aix_libpath=$lt_cv_aix_libpath_
12894fi
12895
12896 hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath"
12897 archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag
12898 else
12899 if test ia64 = "$host_cpu"; then
12900 hardcode_libdir_flag_spec='$wl-R $libdir:/usr/lib:/lib'
12901 allow_undefined_flag="-z nodefs"
12902 archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols"
12903 else
12904 # Determine the default libpath from the value encoded in an
12905 # empty executable.
12906 if test set = "${lt_cv_aix_libpath+set}"; then
12907 aix_libpath=$lt_cv_aix_libpath
12908else
12909 if ${lt_cv_aix_libpath_+:} false; then :
12910 $as_echo_n "(cached) " >&6
12911else
12912 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12913/* end confdefs.h. */
12914
12915int main (void)
12916{
12917
12918 ;
12919 return 0;
12920}
12921_ACEOF
12922if ac_fn_c_try_link "$LINENO"; then :
12923
12924 lt_aix_libpath_sed='
12925 /Import File Strings/,/^$/ {
12926 /^0/ {
12927 s/^0 *\([^ ]*\) *$/\1/
12928 p
12929 }
12930 }'
12931 lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12932 # Check for a 64-bit object if we didn't find anything.
12933 if test -z "$lt_cv_aix_libpath_"; then
12934 lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12935 fi
12936fi
12937rm -f core conftest.err conftest.$ac_objext \
12938 conftest$ac_exeext conftest.$ac_ext
12939 if test -z "$lt_cv_aix_libpath_"; then
12940 lt_cv_aix_libpath_=/usr/lib:/lib
12941 fi
12942
12943fi
12944
12945 aix_libpath=$lt_cv_aix_libpath_
12946fi
12947
12948 hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath"
12949 # Warning - without using the other run time loading flags,
12950 # -berok will link without error, but may produce a broken library.
12951 no_undefined_flag=' $wl-bernotok'
12952 allow_undefined_flag=' $wl-berok'
12953 if test yes = "$with_gnu_ld"; then
12954 # We only use this code for GNU lds that support --whole-archive.
12955 whole_archive_flag_spec='$wl--whole-archive$convenience $wl--no-whole-archive'
12956 else
12957 # Exported symbols can be pulled into shared objects from archives
12958 whole_archive_flag_spec='$convenience'
12959 fi
12960 archive_cmds_need_lc=yes
12961 archive_expsym_cmds='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d'
12962 # -brtl affects multiple linker settings, -berok does not and is overridden later
12963 compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([, ]\\)%-berok\\1%g"`'
12964 if test svr4 != "$with_aix_soname"; then
12965 # This is similar to how AIX traditionally builds its shared libraries.
12966 archive_expsym_cmds="$archive_expsym_cmds"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname'
12967 fi
12968 if test aix != "$with_aix_soname"; then
12969 archive_expsym_cmds="$archive_expsym_cmds"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp'
12970 else
12971 # used by -dlpreopen to get the symbols
12972 archive_expsym_cmds="$archive_expsym_cmds"'~$MV $output_objdir/$realname.d/$soname $output_objdir'
12973 fi
12974 archive_expsym_cmds="$archive_expsym_cmds"'~$RM -r $output_objdir/$realname.d'
12975 fi
12976 fi
12977 ;;
12978
12979 amigaos*)
12980 case $host_cpu in
12981 powerpc)
12982 # see comment about AmigaOS4 .so support
12983 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
12984 archive_expsym_cmds=''
12985 ;;
12986 m68k)
12987 archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
12988 hardcode_libdir_flag_spec='-L$libdir'
12989 hardcode_minus_L=yes
12990 ;;
12991 esac
12992 ;;
12993
12994 bsdi[45]*)
12995 export_dynamic_flag_spec=-rdynamic
12996 ;;
12997
12998 cygwin* | mingw* | pw32* | cegcc*)
12999 # When not using gcc, we currently assume that we are using
13000 # Microsoft Visual C++.
13001 # hardcode_libdir_flag_spec is actually meaningless, as there is
13002 # no search path for DLLs.
13003 case $cc_basename in
13004 cl*)
13005 # Native MSVC
13006 hardcode_libdir_flag_spec=' '
13007 allow_undefined_flag=unsupported
13008 always_export_symbols=yes
13009 file_list_spec='@'
13010 # Tell ltmain to make .lib files, not .a files.
13011 libext=lib
13012 # Tell ltmain to make .dll files, not .so files.
13013 shrext_cmds=.dll
13014 # FIXME: Setting linknames here is a bad hack.
13015 archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames='
13016 archive_expsym_cmds='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then
13017 cp "$export_symbols" "$output_objdir/$soname.def";
13018 echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp";
13019 else
13020 $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp;
13021 fi~
13022 $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
13023 linknames='
13024 # The linker will not automatically build a static lib if we build a DLL.
13025 # _LT_TAGVAR(old_archive_from_new_cmds, )='true'
13026 enable_shared_with_static_runtimes=yes
13027 exclude_expsyms='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
13028 export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
13029 # Don't use ranlib
13030 old_postinstall_cmds='chmod 644 $oldlib'
13031 postlink_cmds='lt_outputfile="@OUTPUT@"~
13032 lt_tool_outputfile="@TOOL_OUTPUT@"~
13033 case $lt_outputfile in
13034 *.exe|*.EXE) ;;
13035 *)
13036 lt_outputfile=$lt_outputfile.exe
13037 lt_tool_outputfile=$lt_tool_outputfile.exe
13038 ;;
13039 esac~
13040 if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then
13041 $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
13042 $RM "$lt_outputfile.manifest";
13043 fi'
13044 ;;
13045 *)
13046 # Assume MSVC wrapper
13047 hardcode_libdir_flag_spec=' '
13048 allow_undefined_flag=unsupported
13049 # Tell ltmain to make .lib files, not .a files.
13050 libext=lib
13051 # Tell ltmain to make .dll files, not .so files.
13052 shrext_cmds=.dll
13053 # FIXME: Setting linknames here is a bad hack.
13054 archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
13055 # The linker will automatically build a .lib file if we build a DLL.
13056 old_archive_from_new_cmds='true'
13057 # FIXME: Should let the user specify the lib program.
13058 old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
13059 enable_shared_with_static_runtimes=yes
13060 ;;
13061 esac
13062 ;;
13063
13064 darwin* | rhapsody*)
13065
13066
13067 archive_cmds_need_lc=no
13068 hardcode_direct=no
13069 hardcode_automatic=yes
13070 hardcode_shlibpath_var=unsupported
13071 if test yes = "$lt_cv_ld_force_load"; then
13072 whole_archive_flag_spec='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience $wl-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
13073
13074 else
13075 whole_archive_flag_spec=''
13076 fi
13077 link_all_deplibs=yes
13078 allow_undefined_flag=$_lt_dar_allow_undefined
13079 case $cc_basename in
13080 ifort*|nagfor*) _lt_dar_can_shared=yes ;;
13081 *) _lt_dar_can_shared=$GCC ;;
13082 esac
13083 if test yes = "$_lt_dar_can_shared"; then
13084 output_verbose_link_cmd=func_echo_all
13085 archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil"
13086 module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil"
13087 archive_expsym_cmds="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil"
13088 module_expsym_cmds="sed -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil"
13089
13090 else
13091 ld_shlibs=no
13092 fi
13093
13094 ;;
13095
13096 dgux*)
13097 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
13098 hardcode_libdir_flag_spec='-L$libdir'
13099 hardcode_shlibpath_var=no
13100 ;;
13101
13102 # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
13103 # support. Future versions do this automatically, but an explicit c++rt0.o
13104 # does not break anything, and helps significantly (at the cost of a little
13105 # extra space).
13106 freebsd2.2*)
13107 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
13108 hardcode_libdir_flag_spec='-R$libdir'
13109 hardcode_direct=yes
13110 hardcode_shlibpath_var=no
13111 ;;
13112
13113 # Unfortunately, older versions of FreeBSD 2 do not have this feature.
13114 freebsd2.*)
13115 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
13116 hardcode_direct=yes
13117 hardcode_minus_L=yes
13118 hardcode_shlibpath_var=no
13119 ;;
13120
13121 # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
13122 freebsd* | dragonfly*)
13123 archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
13124 hardcode_libdir_flag_spec='-R$libdir'
13125 hardcode_direct=yes
13126 hardcode_shlibpath_var=no
13127 ;;
13128
13129 hpux9*)
13130 if test yes = "$GCC"; then
13131 archive_cmds='$RM $output_objdir/$soname~$CC -shared $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv -f $output_objdir/$soname $lib'
13132 else
13133 archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test "x$output_objdir/$soname" = "x$lib" || mv -f $output_objdir/$soname $lib'
13134 fi
13135 hardcode_libdir_flag_spec='$wl+b $wl$libdir'
13136 hardcode_libdir_separator=:
13137 hardcode_direct=yes
13138
13139 # hardcode_minus_L: Not really in the search PATH,
13140 # but as the default location of the library.
13141 hardcode_minus_L=yes
13142 export_dynamic_flag_spec='$wl-E'
13143 ;;
13144
13145 hpux10*)
13146 if test yes,no = "$GCC,$with_gnu_ld"; then
13147 archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
13148 else
13149 archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
13150 fi
13151 if test no = "$with_gnu_ld"; then
13152 hardcode_libdir_flag_spec='$wl+b $wl$libdir'
13153 hardcode_libdir_separator=:
13154 hardcode_direct=yes
13155 hardcode_direct_absolute=yes
13156 export_dynamic_flag_spec='$wl-E'
13157 # hardcode_minus_L: Not really in the search PATH,
13158 # but as the default location of the library.
13159 hardcode_minus_L=yes
13160 fi
13161 ;;
13162
13163 hpux11*)
13164 if test yes,no = "$GCC,$with_gnu_ld"; then
13165 case $host_cpu in
13166 hppa*64*)
13167 archive_cmds='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
13168 ;;
13169 ia64*)
13170 archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
13171 ;;
13172 *)
13173 archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
13174 ;;
13175 esac
13176 else
13177 case $host_cpu in
13178 hppa*64*)
13179 archive_cmds='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
13180 ;;
13181 ia64*)
13182 archive_cmds='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
13183 ;;
13184 *)
13185
13186 # Older versions of the 11.00 compiler do not understand -b yet
13187 # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
13188 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5
13189$as_echo_n "checking if $CC understands -b... " >&6; }
13190if ${lt_cv_prog_compiler__b+:} false; then :
13191 $as_echo_n "(cached) " >&6
13192else
13193 lt_cv_prog_compiler__b=no
13194 save_LDFLAGS=$LDFLAGS
13195 LDFLAGS="$LDFLAGS -b"
13196 echo "$lt_simple_link_test_code" > conftest.$ac_ext
13197 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
13198 # The linker can only warn and ignore the option if not recognized
13199 # So say no if there are warnings
13200 if test -s conftest.err; then
13201 # Append any errors to the config.log.
13202 cat conftest.err 1>&5
13203 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
13204 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
13205 if diff conftest.exp conftest.er2 >/dev/null; then
13206 lt_cv_prog_compiler__b=yes
13207 fi
13208 else
13209 lt_cv_prog_compiler__b=yes
13210 fi
13211 fi
13212 $RM -r conftest*
13213 LDFLAGS=$save_LDFLAGS
13214
13215fi
13216{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5
13217$as_echo "$lt_cv_prog_compiler__b" >&6; }
13218
13219if test yes = "$lt_cv_prog_compiler__b"; then
13220 archive_cmds='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
13221else
13222 archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
13223fi
13224
13225 ;;
13226 esac
13227 fi
13228 if test no = "$with_gnu_ld"; then
13229 hardcode_libdir_flag_spec='$wl+b $wl$libdir'
13230 hardcode_libdir_separator=:
13231
13232 case $host_cpu in
13233 hppa*64*|ia64*)
13234 hardcode_direct=no
13235 hardcode_shlibpath_var=no
13236 ;;
13237 *)
13238 hardcode_direct=yes
13239 hardcode_direct_absolute=yes
13240 export_dynamic_flag_spec='$wl-E'
13241
13242 # hardcode_minus_L: Not really in the search PATH,
13243 # but as the default location of the library.
13244 hardcode_minus_L=yes
13245 ;;
13246 esac
13247 fi
13248 ;;
13249
13250 irix5* | irix6* | nonstopux*)
13251 if test yes = "$GCC"; then
13252 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
13253 # Try to use the -exported_symbol ld option, if it does not
13254 # work, assume that -exports_file does not work either and
13255 # implicitly export all symbols.
13256 # This should be the same for all languages, so no per-tag cache variable.
13257 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
13258$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
13259if ${lt_cv_irix_exported_symbol+:} false; then :
13260 $as_echo_n "(cached) " >&6
13261else
13262 save_LDFLAGS=$LDFLAGS
13263 LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null"
13264 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13265/* end confdefs.h. */
13266int foo (void) { return 0; }
13267_ACEOF
13268if ac_fn_c_try_link "$LINENO"; then :
13269 lt_cv_irix_exported_symbol=yes
13270else
13271 lt_cv_irix_exported_symbol=no
13272fi
13273rm -f core conftest.err conftest.$ac_objext \
13274 conftest$ac_exeext conftest.$ac_ext
13275 LDFLAGS=$save_LDFLAGS
13276fi
13277{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5
13278$as_echo "$lt_cv_irix_exported_symbol" >&6; }
13279 if test yes = "$lt_cv_irix_exported_symbol"; then
13280 archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib'
13281 fi
13282 link_all_deplibs=no
13283 else
13284 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
13285 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -exports_file $export_symbols -o $lib'
13286 fi
13287 archive_cmds_need_lc='no'
13288 hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
13289 hardcode_libdir_separator=:
13290 inherit_rpath=yes
13291 link_all_deplibs=yes
13292 ;;
13293
13294 linux*)
13295 case $cc_basename in
13296 tcc*)
13297 # Fabrice Bellard et al's Tiny C Compiler
13298 ld_shlibs=yes
13299 archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
13300 ;;
13301 esac
13302 ;;
13303
13304 netbsd* | netbsdelf*-gnu)
13305 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
13306 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
13307 else
13308 archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
13309 fi
13310 hardcode_libdir_flag_spec='-R$libdir'
13311 hardcode_direct=yes
13312 hardcode_shlibpath_var=no
13313 ;;
13314
13315 newsos6)
13316 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
13317 hardcode_direct=yes
13318 hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
13319 hardcode_libdir_separator=:
13320 hardcode_shlibpath_var=no
13321 ;;
13322
13323 *nto* | *qnx*)
13324 ;;
13325
13326 openbsd* | bitrig*)
13327 if test -f /usr/libexec/ld.so; then
13328 hardcode_direct=yes
13329 hardcode_shlibpath_var=no
13330 hardcode_direct_absolute=yes
13331 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
13332 archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
13333 archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols'
13334 hardcode_libdir_flag_spec='$wl-rpath,$libdir'
13335 export_dynamic_flag_spec='$wl-E'
13336 else
13337 archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
13338 hardcode_libdir_flag_spec='$wl-rpath,$libdir'
13339 fi
13340 else
13341 ld_shlibs=no
13342 fi
13343 ;;
13344
13345 os2*)
13346 hardcode_libdir_flag_spec='-L$libdir'
13347 hardcode_minus_L=yes
13348 allow_undefined_flag=unsupported
13349 shrext_cmds=.dll
13350 archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
13351 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
13352 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
13353 $ECHO EXPORTS >> $output_objdir/$libname.def~
13354 emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
13355 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
13356 emximp -o $lib $output_objdir/$libname.def'
13357 archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
13358 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
13359 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
13360 $ECHO EXPORTS >> $output_objdir/$libname.def~
13361 prefix_cmds="$SED"~
13362 if test EXPORTS = "`$SED 1q $export_symbols`"; then
13363 prefix_cmds="$prefix_cmds -e 1d";
13364 fi~
13365 prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
13366 cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
13367 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
13368 emximp -o $lib $output_objdir/$libname.def'
13369 old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
13370 enable_shared_with_static_runtimes=yes
13371 ;;
13372
13373 osf3*)
13374 if test yes = "$GCC"; then
13375 allow_undefined_flag=' $wl-expect_unresolved $wl\*'
13376 archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
13377 else
13378 allow_undefined_flag=' -expect_unresolved \*'
13379 archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
13380 fi
13381 archive_cmds_need_lc='no'
13382 hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
13383 hardcode_libdir_separator=:
13384 ;;
13385
13386 osf4* | osf5*) # as osf3* with the addition of -msym flag
13387 if test yes = "$GCC"; then
13388 allow_undefined_flag=' $wl-expect_unresolved $wl\*'
13389 archive_cmds='$CC -shared$allow_undefined_flag $pic_flag $libobjs $deplibs $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib'
13390 hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
13391 else
13392 allow_undefined_flag=' -expect_unresolved \*'
13393 archive_cmds='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib'
13394 archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~
13395 $CC -shared$allow_undefined_flag $wl-input $wl$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~$RM $lib.exp'
13396
13397 # Both c and cxx compiler support -rpath directly
13398 hardcode_libdir_flag_spec='-rpath $libdir'
13399 fi
13400 archive_cmds_need_lc='no'
13401 hardcode_libdir_separator=:
13402 ;;
13403
13404 solaris*)
13405 no_undefined_flag=' -z defs'
13406 if test yes = "$GCC"; then
13407 wlarc='$wl'
13408 archive_cmds='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
13409 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
13410 $CC -shared $pic_flag $wl-z ${wl}text $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
13411 else
13412 case `$CC -V 2>&1` in
13413 *"Compilers 5.0"*)
13414 wlarc=''
13415 archive_cmds='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags'
13416 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
13417 $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
13418 ;;
13419 *)
13420 wlarc='$wl'
13421 archive_cmds='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags'
13422 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
13423 $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
13424 ;;
13425 esac
13426 fi
13427 hardcode_libdir_flag_spec='-R$libdir'
13428 hardcode_shlibpath_var=no
13429 case $host_os in
13430 solaris2.[0-5] | solaris2.[0-5].*) ;;
13431 *)
13432 # The compiler driver will combine and reorder linker options,
13433 # but understands '-z linker_flag'. GCC discards it without '$wl',
13434 # but is careful enough not to reorder.
13435 # Supported since Solaris 2.6 (maybe 2.5.1?)
13436 if test yes = "$GCC"; then
13437 whole_archive_flag_spec='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract'
13438 else
13439 whole_archive_flag_spec='-z allextract$convenience -z defaultextract'
13440 fi
13441 ;;
13442 esac
13443 link_all_deplibs=yes
13444 ;;
13445
13446 sunos4*)
13447 if test sequent = "$host_vendor"; then
13448 # Use $CC to link under sequent, because it throws in some extra .o
13449 # files that make .init and .fini sections work.
13450 archive_cmds='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags'
13451 else
13452 archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
13453 fi
13454 hardcode_libdir_flag_spec='-L$libdir'
13455 hardcode_direct=yes
13456 hardcode_minus_L=yes
13457 hardcode_shlibpath_var=no
13458 ;;
13459
13460 sysv4)
13461 case $host_vendor in
13462 sni)
13463 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
13464 hardcode_direct=yes # is this really true???
13465 ;;
13466 siemens)
13467 ## LD is ld it makes a PLAMLIB
13468 ## CC just makes a GrossModule.
13469 archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
13470 reload_cmds='$CC -r -o $output$reload_objs'
13471 hardcode_direct=no
13472 ;;
13473 motorola)
13474 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
13475 hardcode_direct=no #Motorola manual says yes, but my tests say they lie
13476 ;;
13477 esac
13478 runpath_var='LD_RUN_PATH'
13479 hardcode_shlibpath_var=no
13480 ;;
13481
13482 sysv4.3*)
13483 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
13484 hardcode_shlibpath_var=no
13485 export_dynamic_flag_spec='-Bexport'
13486 ;;
13487
13488 sysv4*MP*)
13489 if test -d /usr/nec; then
13490 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
13491 hardcode_shlibpath_var=no
13492 runpath_var=LD_RUN_PATH
13493 hardcode_runpath_var=yes
13494 ld_shlibs=yes
13495 fi
13496 ;;
13497
13498 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
13499 no_undefined_flag='$wl-z,text'
13500 archive_cmds_need_lc=no
13501 hardcode_shlibpath_var=no
13502 runpath_var='LD_RUN_PATH'
13503
13504 if test yes = "$GCC"; then
13505 archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13506 archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13507 else
13508 archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13509 archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13510 fi
13511 ;;
13512
13513 sysv5* | sco3.2v5* | sco5v6*)
13514 # Note: We CANNOT use -z defs as we might desire, because we do not
13515 # link with -lc, and that would cause any symbols used from libc to
13516 # always be unresolved, which means just about no library would
13517 # ever link correctly. If we're not using GNU ld we use -z text
13518 # though, which does catch some bad symbols but isn't as heavy-handed
13519 # as -z defs.
13520 no_undefined_flag='$wl-z,text'
13521 allow_undefined_flag='$wl-z,nodefs'
13522 archive_cmds_need_lc=no
13523 hardcode_shlibpath_var=no
13524 hardcode_libdir_flag_spec='$wl-R,$libdir'
13525 hardcode_libdir_separator=':'
13526 link_all_deplibs=yes
13527 export_dynamic_flag_spec='$wl-Bexport'
13528 runpath_var='LD_RUN_PATH'
13529
13530 if test yes = "$GCC"; then
13531 archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13532 archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13533 else
13534 archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13535 archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13536 fi
13537 ;;
13538
13539 uts4*)
13540 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
13541 hardcode_libdir_flag_spec='-L$libdir'
13542 hardcode_shlibpath_var=no
13543 ;;
13544
13545 *)
13546 ld_shlibs=no
13547 ;;
13548 esac
13549
13550 if test sni = "$host_vendor"; then
13551 case $host in
13552 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
13553 export_dynamic_flag_spec='$wl-Blargedynsym'
13554 ;;
13555 esac
13556 fi
13557 fi
13558
13559{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5
13560$as_echo "$ld_shlibs" >&6; }
13561test no = "$ld_shlibs" && can_build_shared=no
13562
13563with_gnu_ld=$with_gnu_ld
13564
13565
13566
13567
13568
13569
13570
13571
13572
13573
13574
13575
13576
13577
13578
13579#
13580# Do we need to explicitly link libc?
13581#
13582case "x$archive_cmds_need_lc" in
13583x|xyes)
13584 # Assume -lc should be added
13585 archive_cmds_need_lc=yes
13586
13587 if test yes,yes = "$GCC,$enable_shared"; then
13588 case $archive_cmds in
13589 *'~'*)
13590 # FIXME: we may have to deal with multi-command sequences.
13591 ;;
13592 '$CC '*)
13593 # Test whether the compiler implicitly links with -lc since on some
13594 # systems, -lgcc has to come before -lc. If gcc already passes -lc
13595 # to ld, don't add -lc before -lgcc.
13596 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
13597$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
13598if ${lt_cv_archive_cmds_need_lc+:} false; then :
13599 $as_echo_n "(cached) " >&6
13600else
13601 $RM conftest*
13602 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
13603
13604 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
13605 (eval $ac_compile) 2>&5
13606 ac_status=$?
13607 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
13608 test $ac_status = 0; } 2>conftest.err; then
13609 soname=conftest
13610 lib=conftest
13611 libobjs=conftest.$ac_objext
13612 deplibs=
13613 wl=$lt_prog_compiler_wl
13614 pic_flag=$lt_prog_compiler_pic
13615 compiler_flags=-v
13616 linker_flags=-v
13617 verstring=
13618 output_objdir=.
13619 libname=conftest
13620 lt_save_allow_undefined_flag=$allow_undefined_flag
13621 allow_undefined_flag=
13622 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
13623 (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
13624 ac_status=$?
13625 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
13626 test $ac_status = 0; }
13627 then
13628 lt_cv_archive_cmds_need_lc=no
13629 else
13630 lt_cv_archive_cmds_need_lc=yes
13631 fi
13632 allow_undefined_flag=$lt_save_allow_undefined_flag
13633 else
13634 cat conftest.err 1>&5
13635 fi
13636 $RM conftest*
13637
13638fi
13639{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5
13640$as_echo "$lt_cv_archive_cmds_need_lc" >&6; }
13641 archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc
13642 ;;
13643 esac
13644 fi
13645 ;;
13646esac
13647
13648
13649
13650
13651
13652
13653
13654
13655
13656
13657
13658
13659
13660
13661
13662
13663
13664
13665
13666
13667
13668
13669
13670
13671
13672
13673
13674
13675
13676
13677
13678
13679
13680
13681
13682
13683
13684
13685
13686
13687
13688
13689
13690
13691
13692
13693
13694
13695
13696
13697
13698
13699
13700
13701
13702
13703
13704
13705
13706
13707
13708
13709
13710
13711
13712
13713
13714
13715
13716
13717
13718
13719
13720
13721
13722
13723
13724
13725
13726
13727
13728
13729
13730
13731
13732
13733
13734
13735
13736
13737
13738
13739
13740
13741
13742
13743
13744
13745
13746
13747
13748
13749
13750
13751
13752
13753
13754
13755
13756
13757
13758
13759
13760
13761
13762
13763
13764
13765
13766
13767
13768
13769
13770
13771
13772
13773
13774
13775
13776
13777
13778
13779
13780
13781
13782
13783
13784
13785
13786
13787
13788
13789
13790
13791
13792
13793
13794
13795
13796
13797
13798
13799 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
13800$as_echo_n "checking dynamic linker characteristics... " >&6; }
13801
13802if test yes = "$GCC"; then
13803 case $host_os in
13804 darwin*) lt_awk_arg='/^libraries:/,/LR/' ;;
13805 *) lt_awk_arg='/^libraries:/' ;;
13806 esac
13807 case $host_os in
13808 mingw* | cegcc*) lt_sed_strip_eq='s|=\([A-Za-z]:\)|\1|g' ;;
13809 *) lt_sed_strip_eq='s|=/|/|g' ;;
13810 esac
13811 lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
13812 case $lt_search_path_spec in
13813 *\;*)
13814 # if the path contains ";" then we assume it to be the separator
13815 # otherwise default to the standard path separator (i.e. ":") - it is
13816 # assumed that no part of a normal pathname contains ";" but that should
13817 # okay in the real world where ";" in dirpaths is itself problematic.
13818 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
13819 ;;
13820 *)
13821 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
13822 ;;
13823 esac
13824 # Ok, now we have the path, separated by spaces, we can step through it
13825 # and add multilib dir if necessary...
13826 lt_tmp_lt_search_path_spec=
13827 lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
13828 # ...but if some path component already ends with the multilib dir we assume
13829 # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer).
13830 case "$lt_multi_os_dir; $lt_search_path_spec " in
13831 "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*)
13832 lt_multi_os_dir=
13833 ;;
13834 esac
13835 for lt_sys_path in $lt_search_path_spec; do
13836 if test -d "$lt_sys_path$lt_multi_os_dir"; then
13837 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir"
13838 elif test -n "$lt_multi_os_dir"; then
13839 test -d "$lt_sys_path" && \
13840 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
13841 fi
13842 done
13843 lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
13844BEGIN {RS = " "; FS = "/|\n";} {
13845 lt_foo = "";
13846 lt_count = 0;
13847 for (lt_i = NF; lt_i > 0; lt_i--) {
13848 if ($lt_i != "" && $lt_i != ".") {
13849 if ($lt_i == "..") {
13850 lt_count++;
13851 } else {
13852 if (lt_count == 0) {
13853 lt_foo = "/" $lt_i lt_foo;
13854 } else {
13855 lt_count--;
13856 }
13857 }
13858 }
13859 }
13860 if (lt_foo != "") { lt_freq[lt_foo]++; }
13861 if (lt_freq[lt_foo] == 1) { print lt_foo; }
13862}'`
13863 # AWK program above erroneously prepends '/' to C:/dos/paths
13864 # for these hosts.
13865 case $host_os in
13866 mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
13867 $SED 's|/\([A-Za-z]:\)|\1|g'` ;;
13868 esac
13869 sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
13870else
13871 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
13872fi
13873library_names_spec=
13874libname_spec='lib$name'
13875soname_spec=
13876shrext_cmds=.so
13877postinstall_cmds=
13878postuninstall_cmds=
13879finish_cmds=
13880finish_eval=
13881shlibpath_var=
13882shlibpath_overrides_runpath=unknown
13883version_type=none
13884dynamic_linker="$host_os ld.so"
13885sys_lib_dlsearch_path_spec="/lib /usr/lib"
13886need_lib_prefix=unknown
13887hardcode_into_libs=no
13888
13889# when you set need_version to no, make sure it does not cause -set_version
13890# flags to be left without arguments
13891need_version=unknown
13892
13893
13894
13895case $host_os in
13896aix3*)
13897 version_type=linux # correct to gnu/linux during the next big refactor
13898 library_names_spec='$libname$release$shared_ext$versuffix $libname.a'
13899 shlibpath_var=LIBPATH
13900
13901 # AIX 3 has no versioning support, so we append a major version to the name.
13902 soname_spec='$libname$release$shared_ext$major'
13903 ;;
13904
13905aix[4-9]*)
13906 version_type=linux # correct to gnu/linux during the next big refactor
13907 need_lib_prefix=no
13908 need_version=no
13909 hardcode_into_libs=yes
13910 if test ia64 = "$host_cpu"; then
13911 # AIX 5 supports IA64
13912 library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext'
13913 shlibpath_var=LD_LIBRARY_PATH
13914 else
13915 # With GCC up to 2.95.x, collect2 would create an import file
13916 # for dependence libraries. The import file would start with
13917 # the line '#! .'. This would cause the generated library to
13918 # depend on '.', always an invalid library. This was fixed in
13919 # development snapshots of GCC prior to 3.0.
13920 case $host_os in
13921 aix4 | aix4.[01] | aix4.[01].*)
13922 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
13923 echo ' yes '
13924 echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then
13925 :
13926 else
13927 can_build_shared=no
13928 fi
13929 ;;
13930 esac
13931 # Using Import Files as archive members, it is possible to support
13932 # filename-based versioning of shared library archives on AIX. While
13933 # this would work for both with and without runtime linking, it will
13934 # prevent static linking of such archives. So we do filename-based
13935 # shared library versioning with .so extension only, which is used
13936 # when both runtime linking and shared linking is enabled.
13937 # Unfortunately, runtime linking may impact performance, so we do
13938 # not want this to be the default eventually. Also, we use the
13939 # versioned .so libs for executables only if there is the -brtl
13940 # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only.
13941 # To allow for filename-based versioning support, we need to create
13942 # libNAME.so.V as an archive file, containing:
13943 # *) an Import File, referring to the versioned filename of the
13944 # archive as well as the shared archive member, telling the
13945 # bitwidth (32 or 64) of that shared object, and providing the
13946 # list of exported symbols of that shared object, eventually
13947 # decorated with the 'weak' keyword
13948 # *) the shared object with the F_LOADONLY flag set, to really avoid
13949 # it being seen by the linker.
13950 # At run time we better use the real file rather than another symlink,
13951 # but for link time we create the symlink libNAME.so -> libNAME.so.V
13952
13953 case $with_aix_soname,$aix_use_runtimelinking in
13954 # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct
13955 # soname into executable. Probably we can add versioning support to
13956 # collect2, so additional links can be useful in future.
13957 aix,yes) # traditional libtool
13958 dynamic_linker='AIX unversionable lib.so'
13959 # If using run time linking (on AIX 4.2 or later) use lib<name>.so
13960 # instead of lib<name>.a to let people know that these are not
13961 # typical AIX shared libraries.
13962 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13963 ;;
13964 aix,no) # traditional AIX only
13965 dynamic_linker='AIX lib.a(lib.so.V)'
13966 # We preserve .a as extension for shared libraries through AIX4.2
13967 # and later when we are not doing run time linking.
13968 library_names_spec='$libname$release.a $libname.a'
13969 soname_spec='$libname$release$shared_ext$major'
13970 ;;
13971 svr4,*) # full svr4 only
13972 dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o)"
13973 library_names_spec='$libname$release$shared_ext$major $libname$shared_ext'
13974 # We do not specify a path in Import Files, so LIBPATH fires.
13975 shlibpath_overrides_runpath=yes
13976 ;;
13977 *,yes) # both, prefer svr4
13978 dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o), lib.a(lib.so.V)"
13979 library_names_spec='$libname$release$shared_ext$major $libname$shared_ext'
13980 # unpreferred sharedlib libNAME.a needs extra handling
13981 postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"'
13982 postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"'
13983 # We do not specify a path in Import Files, so LIBPATH fires.
13984 shlibpath_overrides_runpath=yes
13985 ;;
13986 *,no) # both, prefer aix
13987 dynamic_linker="AIX lib.a(lib.so.V), lib.so.V($shared_archive_member_spec.o)"
13988 library_names_spec='$libname$release.a $libname.a'
13989 soname_spec='$libname$release$shared_ext$major'
13990 # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling
13991 postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)'
13992 postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"'
13993 ;;
13994 esac
13995 shlibpath_var=LIBPATH
13996 fi
13997 ;;
13998
13999amigaos*)
14000 case $host_cpu in
14001 powerpc)
14002 # Since July 2007 AmigaOS4 officially supports .so libraries.
14003 # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
14004 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14005 ;;
14006 m68k)
14007 library_names_spec='$libname.ixlibrary $libname.a'
14008 # Create ${libname}_ixlibrary.a entries in /sys/libs.
14009 finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
14010 ;;
14011 esac
14012 ;;
14013
14014beos*)
14015 library_names_spec='$libname$shared_ext'
14016 dynamic_linker="$host_os ld.so"
14017 shlibpath_var=LIBRARY_PATH
14018 ;;
14019
14020bsdi[45]*)
14021 version_type=linux # correct to gnu/linux during the next big refactor
14022 need_version=no
14023 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14024 soname_spec='$libname$release$shared_ext$major'
14025 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
14026 shlibpath_var=LD_LIBRARY_PATH
14027 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
14028 sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
14029 # the default ld.so.conf also contains /usr/contrib/lib and
14030 # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
14031 # libtool to hard-code these into programs
14032 ;;
14033
14034cygwin* | mingw* | pw32* | cegcc*)
14035 version_type=windows
14036 shrext_cmds=.dll
14037 need_version=no
14038 need_lib_prefix=no
14039
14040 case $GCC,$cc_basename in
14041 yes,*)
14042 # gcc
14043 library_names_spec='$libname.dll.a'
14044 # DLL is installed to $(libdir)/../bin by postinstall_cmds
14045 postinstall_cmds='base_file=`basename \$file`~
14046 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
14047 dldir=$destdir/`dirname \$dlpath`~
14048 test -d \$dldir || mkdir -p \$dldir~
14049 $install_prog $dir/$dlname \$dldir/$dlname~
14050 chmod a+x \$dldir/$dlname~
14051 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
14052 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
14053 fi'
14054 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
14055 dlpath=$dir/\$dldll~
14056 $RM \$dlpath'
14057 shlibpath_overrides_runpath=yes
14058
14059 case $host_os in
14060 cygwin*)
14061 # Cygwin DLLs use 'cyg' prefix rather than 'lib'
14062 soname_spec='`echo $libname | sed -e 's/^lib/cyg/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
14063
14064 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"
14065 ;;
14066 mingw* | cegcc*)
14067 # MinGW DLLs use traditional 'lib' prefix
14068 soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
14069 ;;
14070 pw32*)
14071 # pw32 DLLs use 'pw' prefix rather than 'lib'
14072 library_names_spec='`echo $libname | sed -e 's/^lib/pw/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
14073 ;;
14074 esac
14075 dynamic_linker='Win32 ld.exe'
14076 ;;
14077
14078 *,cl*)
14079 # Native MSVC
14080 libname_spec='$name'
14081 soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
14082 library_names_spec='$libname.dll.lib'
14083
14084 case $build_os in
14085 mingw*)
14086 sys_lib_search_path_spec=
14087 lt_save_ifs=$IFS
14088 IFS=';'
14089 for lt_path in $LIB
14090 do
14091 IFS=$lt_save_ifs
14092 # Let DOS variable expansion print the short 8.3 style file name.
14093 lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
14094 sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
14095 done
14096 IFS=$lt_save_ifs
14097 # Convert to MSYS style.
14098 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'`
14099 ;;
14100 cygwin*)
14101 # Convert to unix form, then to dos form, then back to unix form
14102 # but this time dos style (no spaces!) so that the unix form looks
14103 # like /cygdrive/c/PROGRA~1:/cygdr...
14104 sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
14105 sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
14106 sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
14107 ;;
14108 *)
14109 sys_lib_search_path_spec=$LIB
14110 if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
14111 # It is most probably a Windows format PATH.
14112 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
14113 else
14114 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
14115 fi
14116 # FIXME: find the short name or the path components, as spaces are
14117 # common. (e.g. "Program Files" -> "PROGRA~1")
14118 ;;
14119 esac
14120
14121 # DLL is installed to $(libdir)/../bin by postinstall_cmds
14122 postinstall_cmds='base_file=`basename \$file`~
14123 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
14124 dldir=$destdir/`dirname \$dlpath`~
14125 test -d \$dldir || mkdir -p \$dldir~
14126 $install_prog $dir/$dlname \$dldir/$dlname'
14127 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
14128 dlpath=$dir/\$dldll~
14129 $RM \$dlpath'
14130 shlibpath_overrides_runpath=yes
14131 dynamic_linker='Win32 link.exe'
14132 ;;
14133
14134 *)
14135 # Assume MSVC wrapper
14136 library_names_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext $libname.lib'
14137 dynamic_linker='Win32 ld.exe'
14138 ;;
14139 esac
14140 # FIXME: first we should search . and the directory the executable is in
14141 shlibpath_var=PATH
14142 ;;
14143
14144darwin* | rhapsody*)
14145 dynamic_linker="$host_os dyld"
14146 version_type=darwin
14147 need_lib_prefix=no
14148 need_version=no
14149 library_names_spec='$libname$release$major$shared_ext $libname$shared_ext'
14150 soname_spec='$libname$release$major$shared_ext'
14151 shlibpath_overrides_runpath=yes
14152 shlibpath_var=DYLD_LIBRARY_PATH
14153 shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
14154
14155 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"
14156 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
14157 ;;
14158
14159dgux*)
14160 version_type=linux # correct to gnu/linux during the next big refactor
14161 need_lib_prefix=no
14162 need_version=no
14163 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14164 soname_spec='$libname$release$shared_ext$major'
14165 shlibpath_var=LD_LIBRARY_PATH
14166 ;;
14167
14168freebsd* | dragonfly*)
14169 # DragonFly does not have aout. When/if they implement a new
14170 # versioning mechanism, adjust this.
14171 if test -x /usr/bin/objformat; then
14172 objformat=`/usr/bin/objformat`
14173 else
14174 case $host_os in
14175 freebsd[23].*) objformat=aout ;;
14176 *) objformat=elf ;;
14177 esac
14178 fi
14179 version_type=freebsd-$objformat
14180 case $version_type in
14181 freebsd-elf*)
14182 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14183 soname_spec='$libname$release$shared_ext$major'
14184 need_version=no
14185 need_lib_prefix=no
14186 ;;
14187 freebsd-*)
14188 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
14189 need_version=yes
14190 ;;
14191 esac
14192 shlibpath_var=LD_LIBRARY_PATH
14193 case $host_os in
14194 freebsd2.*)
14195 shlibpath_overrides_runpath=yes
14196 ;;
14197 freebsd3.[01]* | freebsdelf3.[01]*)
14198 shlibpath_overrides_runpath=yes
14199 hardcode_into_libs=yes
14200 ;;
14201 freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
14202 freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
14203 shlibpath_overrides_runpath=no
14204 hardcode_into_libs=yes
14205 ;;
14206 *) # from 4.6 on, and DragonFly
14207 shlibpath_overrides_runpath=yes
14208 hardcode_into_libs=yes
14209 ;;
14210 esac
14211 ;;
14212
14213haiku*)
14214 version_type=linux # correct to gnu/linux during the next big refactor
14215 need_lib_prefix=no
14216 need_version=no
14217 dynamic_linker="$host_os runtime_loader"
14218 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14219 soname_spec='$libname$release$shared_ext$major'
14220 shlibpath_var=LIBRARY_PATH
14221 shlibpath_overrides_runpath=no
14222 sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
14223 hardcode_into_libs=yes
14224 ;;
14225
14226hpux9* | hpux10* | hpux11*)
14227 # Give a soname corresponding to the major version so that dld.sl refuses to
14228 # link against other versions.
14229 version_type=sunos
14230 need_lib_prefix=no
14231 need_version=no
14232 case $host_cpu in
14233 ia64*)
14234 shrext_cmds='.so'
14235 hardcode_into_libs=yes
14236 dynamic_linker="$host_os dld.so"
14237 shlibpath_var=LD_LIBRARY_PATH
14238 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
14239 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14240 soname_spec='$libname$release$shared_ext$major'
14241 if test 32 = "$HPUX_IA64_MODE"; then
14242 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
14243 sys_lib_dlsearch_path_spec=/usr/lib/hpux32
14244 else
14245 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
14246 sys_lib_dlsearch_path_spec=/usr/lib/hpux64
14247 fi
14248 ;;
14249 hppa*64*)
14250 shrext_cmds='.sl'
14251 hardcode_into_libs=yes
14252 dynamic_linker="$host_os dld.sl"
14253 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
14254 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
14255 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14256 soname_spec='$libname$release$shared_ext$major'
14257 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
14258 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
14259 ;;
14260 *)
14261 shrext_cmds='.sl'
14262 dynamic_linker="$host_os dld.sl"
14263 shlibpath_var=SHLIB_PATH
14264 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
14265 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14266 soname_spec='$libname$release$shared_ext$major'
14267 ;;
14268 esac
14269 # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
14270 postinstall_cmds='chmod 555 $lib'
14271 # or fails outright, so override atomically:
14272 install_override_mode=555
14273 ;;
14274
14275interix[3-9]*)
14276 version_type=linux # correct to gnu/linux during the next big refactor
14277 need_lib_prefix=no
14278 need_version=no
14279 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14280 soname_spec='$libname$release$shared_ext$major'
14281 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
14282 shlibpath_var=LD_LIBRARY_PATH
14283 shlibpath_overrides_runpath=no
14284 hardcode_into_libs=yes
14285 ;;
14286
14287irix5* | irix6* | nonstopux*)
14288 case $host_os in
14289 nonstopux*) version_type=nonstopux ;;
14290 *)
14291 if test yes = "$lt_cv_prog_gnu_ld"; then
14292 version_type=linux # correct to gnu/linux during the next big refactor
14293 else
14294 version_type=irix
14295 fi ;;
14296 esac
14297 need_lib_prefix=no
14298 need_version=no
14299 soname_spec='$libname$release$shared_ext$major'
14300 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext'
14301 case $host_os in
14302 irix5* | nonstopux*)
14303 libsuff= shlibsuff=
14304 ;;
14305 *)
14306 case $LD in # libtool.m4 will add one of these switches to LD
14307 *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
14308 libsuff= shlibsuff= libmagic=32-bit;;
14309 *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
14310 libsuff=32 shlibsuff=N32 libmagic=N32;;
14311 *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
14312 libsuff=64 shlibsuff=64 libmagic=64-bit;;
14313 *) libsuff= shlibsuff= libmagic=never-match;;
14314 esac
14315 ;;
14316 esac
14317 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
14318 shlibpath_overrides_runpath=no
14319 sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff"
14320 sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff"
14321 hardcode_into_libs=yes
14322 ;;
14323
14324# No shared lib support for Linux oldld, aout, or coff.
14325linux*oldld* | linux*aout* | linux*coff*)
14326 dynamic_linker=no
14327 ;;
14328
14329linux*android*)
14330 version_type=none # Android doesn't support versioned libraries.
14331 need_lib_prefix=no
14332 need_version=no
14333 library_names_spec='$libname$release$shared_ext'
14334 soname_spec='$libname$release$shared_ext'
14335 finish_cmds=
14336 shlibpath_var=LD_LIBRARY_PATH
14337 shlibpath_overrides_runpath=yes
14338
14339 # This implies no fast_install, which is unacceptable.
14340 # Some rework will be needed to allow for fast_install
14341 # before this can be enabled.
14342 hardcode_into_libs=yes
14343
14344 dynamic_linker='Android linker'
14345 # Don't embed -rpath directories since the linker doesn't support them.
14346 hardcode_libdir_flag_spec='-L$libdir'
14347 ;;
14348
14349# This must be glibc/ELF.
14350linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
14351 version_type=linux # correct to gnu/linux during the next big refactor
14352 need_lib_prefix=no
14353 need_version=no
14354 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14355 soname_spec='$libname$release$shared_ext$major'
14356 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
14357 shlibpath_var=LD_LIBRARY_PATH
14358 shlibpath_overrides_runpath=no
14359
14360 # Some binutils ld are patched to set DT_RUNPATH
14361 if ${lt_cv_shlibpath_overrides_runpath+:} false; then :
14362 $as_echo_n "(cached) " >&6
14363else
14364 lt_cv_shlibpath_overrides_runpath=no
14365 save_LDFLAGS=$LDFLAGS
14366 save_libdir=$libdir
14367 eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \
14368 LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\""
14369 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14370/* end confdefs.h. */
14371
14372int main (void)
14373{
14374
14375 ;
14376 return 0;
14377}
14378_ACEOF
14379if ac_fn_c_try_link "$LINENO"; then :
14380 if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then :
14381 lt_cv_shlibpath_overrides_runpath=yes
14382fi
14383fi
14384rm -f core conftest.err conftest.$ac_objext \
14385 conftest$ac_exeext conftest.$ac_ext
14386 LDFLAGS=$save_LDFLAGS
14387 libdir=$save_libdir
14388
14389fi
14390
14391 shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
14392
14393 # This implies no fast_install, which is unacceptable.
14394 # Some rework will be needed to allow for fast_install
14395 # before this can be enabled.
14396 hardcode_into_libs=yes
14397
14398 # Ideally, we could use ldconfig to report *all* directores which are
14399 # searched for libraries, however this is still not possible. Aside from not
14400 # being certain /sbin/ldconfig is available, command
14401 # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64,
14402 # even though it is searched at run-time. Try to do the best guess by
14403 # appending ld.so.conf contents (and includes) to the search path.
14404 if test -f /etc/ld.so.conf; then
14405 lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
14406 sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
14407 fi
14408
14409 # We used to test for /lib/ld.so.1 and disable shared libraries on
14410 # powerpc, because MkLinux only supported shared libraries with the
14411 # GNU dynamic linker. Since this was broken with cross compilers,
14412 # most powerpc-linux boxes support dynamic linking these days and
14413 # people can always --disable-shared, the test was removed, and we
14414 # assume the GNU/Linux dynamic linker is in use.
14415 dynamic_linker='GNU/Linux ld.so'
14416 ;;
14417
14418netbsdelf*-gnu)
14419 version_type=linux
14420 need_lib_prefix=no
14421 need_version=no
14422 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
14423 soname_spec='${libname}${release}${shared_ext}$major'
14424 shlibpath_var=LD_LIBRARY_PATH
14425 shlibpath_overrides_runpath=no
14426 hardcode_into_libs=yes
14427 dynamic_linker='NetBSD ld.elf_so'
14428 ;;
14429
14430netbsd*)
14431 version_type=sunos
14432 need_lib_prefix=no
14433 need_version=no
14434 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
14435 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
14436 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
14437 dynamic_linker='NetBSD (a.out) ld.so'
14438 else
14439 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14440 soname_spec='$libname$release$shared_ext$major'
14441 dynamic_linker='NetBSD ld.elf_so'
14442 fi
14443 shlibpath_var=LD_LIBRARY_PATH
14444 shlibpath_overrides_runpath=yes
14445 hardcode_into_libs=yes
14446 ;;
14447
14448newsos6)
14449 version_type=linux # correct to gnu/linux during the next big refactor
14450 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14451 shlibpath_var=LD_LIBRARY_PATH
14452 shlibpath_overrides_runpath=yes
14453 ;;
14454
14455*nto* | *qnx*)
14456 version_type=qnx
14457 need_lib_prefix=no
14458 need_version=no
14459 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14460 soname_spec='$libname$release$shared_ext$major'
14461 shlibpath_var=LD_LIBRARY_PATH
14462 shlibpath_overrides_runpath=no
14463 hardcode_into_libs=yes
14464 dynamic_linker='ldqnx.so'
14465 ;;
14466
14467openbsd* | bitrig*)
14468 version_type=sunos
14469 sys_lib_dlsearch_path_spec=/usr/lib
14470 need_lib_prefix=no
14471 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
14472 need_version=no
14473 else
14474 need_version=yes
14475 fi
14476 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
14477 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
14478 shlibpath_var=LD_LIBRARY_PATH
14479 shlibpath_overrides_runpath=yes
14480 ;;
14481
14482os2*)
14483 libname_spec='$name'
14484 version_type=windows
14485 shrext_cmds=.dll
14486 need_version=no
14487 need_lib_prefix=no
14488 # OS/2 can only load a DLL with a base name of 8 characters or less.
14489 soname_spec='`test -n "$os2dllname" && libname="$os2dllname";
14490 v=$($ECHO $release$versuffix | tr -d .-);
14491 n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _);
14492 $ECHO $n$v`$shared_ext'
14493 library_names_spec='${libname}_dll.$libext'
14494 dynamic_linker='OS/2 ld.exe'
14495 shlibpath_var=BEGINLIBPATH
14496 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
14497 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
14498 postinstall_cmds='base_file=`basename \$file`~
14499 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~
14500 dldir=$destdir/`dirname \$dlpath`~
14501 test -d \$dldir || mkdir -p \$dldir~
14502 $install_prog $dir/$dlname \$dldir/$dlname~
14503 chmod a+x \$dldir/$dlname~
14504 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
14505 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
14506 fi'
14507 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~
14508 dlpath=$dir/\$dldll~
14509 $RM \$dlpath'
14510 ;;
14511
14512osf3* | osf4* | osf5*)
14513 version_type=osf
14514 need_lib_prefix=no
14515 need_version=no
14516 soname_spec='$libname$release$shared_ext$major'
14517 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14518 shlibpath_var=LD_LIBRARY_PATH
14519 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
14520 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
14521 ;;
14522
14523rdos*)
14524 dynamic_linker=no
14525 ;;
14526
14527solaris*)
14528 version_type=linux # correct to gnu/linux during the next big refactor
14529 need_lib_prefix=no
14530 need_version=no
14531 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14532 soname_spec='$libname$release$shared_ext$major'
14533 shlibpath_var=LD_LIBRARY_PATH
14534 shlibpath_overrides_runpath=yes
14535 hardcode_into_libs=yes
14536 # ldd complains unless libraries are executable
14537 postinstall_cmds='chmod +x $lib'
14538 ;;
14539
14540sunos4*)
14541 version_type=sunos
14542 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
14543 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
14544 shlibpath_var=LD_LIBRARY_PATH
14545 shlibpath_overrides_runpath=yes
14546 if test yes = "$with_gnu_ld"; then
14547 need_lib_prefix=no
14548 fi
14549 need_version=yes
14550 ;;
14551
14552sysv4 | sysv4.3*)
14553 version_type=linux # correct to gnu/linux during the next big refactor
14554 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14555 soname_spec='$libname$release$shared_ext$major'
14556 shlibpath_var=LD_LIBRARY_PATH
14557 case $host_vendor in
14558 sni)
14559 shlibpath_overrides_runpath=no
14560 need_lib_prefix=no
14561 runpath_var=LD_RUN_PATH
14562 ;;
14563 siemens)
14564 need_lib_prefix=no
14565 ;;
14566 motorola)
14567 need_lib_prefix=no
14568 need_version=no
14569 shlibpath_overrides_runpath=no
14570 sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
14571 ;;
14572 esac
14573 ;;
14574
14575sysv4*MP*)
14576 if test -d /usr/nec; then
14577 version_type=linux # correct to gnu/linux during the next big refactor
14578 library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext'
14579 soname_spec='$libname$shared_ext.$major'
14580 shlibpath_var=LD_LIBRARY_PATH
14581 fi
14582 ;;
14583
14584sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
14585 version_type=sco
14586 need_lib_prefix=no
14587 need_version=no
14588 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext'
14589 soname_spec='$libname$release$shared_ext$major'
14590 shlibpath_var=LD_LIBRARY_PATH
14591 shlibpath_overrides_runpath=yes
14592 hardcode_into_libs=yes
14593 if test yes = "$with_gnu_ld"; then
14594 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
14595 else
14596 sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
14597 case $host_os in
14598 sco3.2v5*)
14599 sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
14600 ;;
14601 esac
14602 fi
14603 sys_lib_dlsearch_path_spec='/usr/lib'
14604 ;;
14605
14606tpf*)
14607 # TPF is a cross-target only. Preferred cross-host = GNU/Linux.
14608 version_type=linux # correct to gnu/linux during the next big refactor
14609 need_lib_prefix=no
14610 need_version=no
14611 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14612 shlibpath_var=LD_LIBRARY_PATH
14613 shlibpath_overrides_runpath=no
14614 hardcode_into_libs=yes
14615 ;;
14616
14617uts4*)
14618 version_type=linux # correct to gnu/linux during the next big refactor
14619 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14620 soname_spec='$libname$release$shared_ext$major'
14621 shlibpath_var=LD_LIBRARY_PATH
14622 ;;
14623
14624*)
14625 dynamic_linker=no
14626 ;;
14627esac
14628{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
14629$as_echo "$dynamic_linker" >&6; }
14630test no = "$dynamic_linker" && can_build_shared=no
14631
14632variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
14633if test yes = "$GCC"; then
14634 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
14635fi
14636
14637if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then
14638 sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec
14639fi
14640
14641if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then
14642 sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec
14643fi
14644
14645# remember unaugmented sys_lib_dlsearch_path content for libtool script decls...
14646configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec
14647
14648# ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code
14649func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH"
14650
14651# to be used as default LT_SYS_LIBRARY_PATH value in generated libtool
14652configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH
14653
14654
14655
14656
14657
14658
14659
14660
14661
14662
14663
14664
14665
14666
14667
14668
14669
14670
14671
14672
14673
14674
14675
14676
14677
14678
14679
14680
14681
14682
14683
14684
14685
14686
14687
14688
14689
14690
14691
14692
14693
14694
14695
14696
14697
14698
14699
14700
14701
14702
14703
14704
14705
14706
14707
14708
14709
14710
14711
14712
14713
14714
14715
14716
14717
14718
14719
14720
14721
14722
14723
14724
14725
14726
14727
14728
14729
14730
14731
14732
14733
14734
14735
14736
14737
14738
14739
14740
14741
14742
14743
14744
14745
14746
14747
14748
14749
14750 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
14751$as_echo_n "checking how to hardcode library paths into programs... " >&6; }
14752hardcode_action=
14753if test -n "$hardcode_libdir_flag_spec" ||
14754 test -n "$runpath_var" ||
14755 test yes = "$hardcode_automatic"; then
14756
14757 # We can hardcode non-existent directories.
14758 if test no != "$hardcode_direct" &&
14759 # If the only mechanism to avoid hardcoding is shlibpath_var, we
14760 # have to relink, otherwise we might link with an installed library
14761 # when we should be linking with a yet-to-be-installed one
14762 ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, )" &&
14763 test no != "$hardcode_minus_L"; then
14764 # Linking always hardcodes the temporary library directory.
14765 hardcode_action=relink
14766 else
14767 # We can link without hardcoding, and we can hardcode nonexisting dirs.
14768 hardcode_action=immediate
14769 fi
14770else
14771 # We cannot hardcode anything, or else we can only hardcode existing
14772 # directories.
14773 hardcode_action=unsupported
14774fi
14775{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5
14776$as_echo "$hardcode_action" >&6; }
14777
14778if test relink = "$hardcode_action" ||
14779 test yes = "$inherit_rpath"; then
14780 # Fast installation is not supported
14781 enable_fast_install=no
14782elif test yes = "$shlibpath_overrides_runpath" ||
14783 test no = "$enable_shared"; then
14784 # Fast installation is not necessary
14785 enable_fast_install=needless
14786fi
14787
14788
14789
14790
14791
14792
14793 if test yes != "$enable_dlopen"; then
14794 enable_dlopen=unknown
14795 enable_dlopen_self=unknown
14796 enable_dlopen_self_static=unknown
14797else
14798 lt_cv_dlopen=no
14799 lt_cv_dlopen_libs=
14800
14801 case $host_os in
14802 beos*)
14803 lt_cv_dlopen=load_add_on
14804 lt_cv_dlopen_libs=
14805 lt_cv_dlopen_self=yes
14806 ;;
14807
14808 mingw* | pw32* | cegcc*)
14809 lt_cv_dlopen=LoadLibrary
14810 lt_cv_dlopen_libs=
14811 ;;
14812
14813 cygwin*)
14814 lt_cv_dlopen=dlopen
14815 lt_cv_dlopen_libs=
14816 ;;
14817
14818 darwin*)
14819 # if libdl is installed we need to link against it
14820 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
14821$as_echo_n "checking for dlopen in -ldl... " >&6; }
14822if ${ac_cv_lib_dl_dlopen+:} false; then :
14823 $as_echo_n "(cached) " >&6
14824else
14825 ac_check_lib_save_LIBS=$LIBS
14826LIBS="-ldl $LIBS"
14827cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14828/* end confdefs.h. */
14829
14830
14831#ifdef __cplusplus
14832extern "C"
14833#endif
14834char dlopen ();
14835int main (void)
14836{
14837return dlopen ();
14838 ;
14839 return 0;
14840}
14841_ACEOF
14842if ac_fn_c_try_link "$LINENO"; then :
14843 ac_cv_lib_dl_dlopen=yes
14844else
14845 ac_cv_lib_dl_dlopen=no
14846fi
14847rm -f core conftest.err conftest.$ac_objext \
14848 conftest$ac_exeext conftest.$ac_ext
14849LIBS=$ac_check_lib_save_LIBS
14850fi
14851{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
14852$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
14853if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
14854 lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl
14855else
14856
14857 lt_cv_dlopen=dyld
14858 lt_cv_dlopen_libs=
14859 lt_cv_dlopen_self=yes
14860
14861fi
14862
14863 ;;
14864
14865 tpf*)
14866 # Don't try to run any link tests for TPF. We know it's impossible
14867 # because TPF is a cross-compiler, and we know how we open DSOs.
14868 lt_cv_dlopen=dlopen
14869 lt_cv_dlopen_libs=
14870 lt_cv_dlopen_self=no
14871 ;;
14872
14873 *)
14874 ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load"
14875if test "x$ac_cv_func_shl_load" = xyes; then :
14876 lt_cv_dlopen=shl_load
14877else
14878 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
14879$as_echo_n "checking for shl_load in -ldld... " >&6; }
14880if ${ac_cv_lib_dld_shl_load+:} false; then :
14881 $as_echo_n "(cached) " >&6
14882else
14883 ac_check_lib_save_LIBS=$LIBS
14884LIBS="-ldld $LIBS"
14885cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14886/* end confdefs.h. */
14887
14888
14889#ifdef __cplusplus
14890extern "C"
14891#endif
14892char shl_load ();
14893int main (void)
14894{
14895return shl_load ();
14896 ;
14897 return 0;
14898}
14899_ACEOF
14900if ac_fn_c_try_link "$LINENO"; then :
14901 ac_cv_lib_dld_shl_load=yes
14902else
14903 ac_cv_lib_dld_shl_load=no
14904fi
14905rm -f core conftest.err conftest.$ac_objext \
14906 conftest$ac_exeext conftest.$ac_ext
14907LIBS=$ac_check_lib_save_LIBS
14908fi
14909{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
14910$as_echo "$ac_cv_lib_dld_shl_load" >&6; }
14911if test "x$ac_cv_lib_dld_shl_load" = xyes; then :
14912 lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld
14913else
14914 ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
14915if test "x$ac_cv_func_dlopen" = xyes; then :
14916 lt_cv_dlopen=dlopen
14917else
14918 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
14919$as_echo_n "checking for dlopen in -ldl... " >&6; }
14920if ${ac_cv_lib_dl_dlopen+:} false; then :
14921 $as_echo_n "(cached) " >&6
14922else
14923 ac_check_lib_save_LIBS=$LIBS
14924LIBS="-ldl $LIBS"
14925cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14926/* end confdefs.h. */
14927
14928
14929#ifdef __cplusplus
14930extern "C"
14931#endif
14932char dlopen ();
14933int main (void)
14934{
14935return dlopen ();
14936 ;
14937 return 0;
14938}
14939_ACEOF
14940if ac_fn_c_try_link "$LINENO"; then :
14941 ac_cv_lib_dl_dlopen=yes
14942else
14943 ac_cv_lib_dl_dlopen=no
14944fi
14945rm -f core conftest.err conftest.$ac_objext \
14946 conftest$ac_exeext conftest.$ac_ext
14947LIBS=$ac_check_lib_save_LIBS
14948fi
14949{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
14950$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
14951if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
14952 lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl
14953else
14954 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5
14955$as_echo_n "checking for dlopen in -lsvld... " >&6; }
14956if ${ac_cv_lib_svld_dlopen+:} false; then :
14957 $as_echo_n "(cached) " >&6
14958else
14959 ac_check_lib_save_LIBS=$LIBS
14960LIBS="-lsvld $LIBS"
14961cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14962/* end confdefs.h. */
14963
14964
14965#ifdef __cplusplus
14966extern "C"
14967#endif
14968char dlopen ();
14969int main (void)
14970{
14971return dlopen ();
14972 ;
14973 return 0;
14974}
14975_ACEOF
14976if ac_fn_c_try_link "$LINENO"; then :
14977 ac_cv_lib_svld_dlopen=yes
14978else
14979 ac_cv_lib_svld_dlopen=no
14980fi
14981rm -f core conftest.err conftest.$ac_objext \
14982 conftest$ac_exeext conftest.$ac_ext
14983LIBS=$ac_check_lib_save_LIBS
14984fi
14985{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5
14986$as_echo "$ac_cv_lib_svld_dlopen" >&6; }
14987if test "x$ac_cv_lib_svld_dlopen" = xyes; then :
14988 lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld
14989else
14990 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5
14991$as_echo_n "checking for dld_link in -ldld... " >&6; }
14992if ${ac_cv_lib_dld_dld_link+:} false; then :
14993 $as_echo_n "(cached) " >&6
14994else
14995 ac_check_lib_save_LIBS=$LIBS
14996LIBS="-ldld $LIBS"
14997cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14998/* end confdefs.h. */
14999
15000
15001#ifdef __cplusplus
15002extern "C"
15003#endif
15004char dld_link ();
15005int main (void)
15006{
15007return dld_link ();
15008 ;
15009 return 0;
15010}
15011_ACEOF
15012if ac_fn_c_try_link "$LINENO"; then :
15013 ac_cv_lib_dld_dld_link=yes
15014else
15015 ac_cv_lib_dld_dld_link=no
15016fi
15017rm -f core conftest.err conftest.$ac_objext \
15018 conftest$ac_exeext conftest.$ac_ext
15019LIBS=$ac_check_lib_save_LIBS
15020fi
15021{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5
15022$as_echo "$ac_cv_lib_dld_dld_link" >&6; }
15023if test "x$ac_cv_lib_dld_dld_link" = xyes; then :
15024 lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld
15025fi
15026
15027
15028fi
15029
15030
15031fi
15032
15033
15034fi
15035
15036
15037fi
15038
15039
15040fi
15041
15042 ;;
15043 esac
15044
15045 if test no = "$lt_cv_dlopen"; then
15046 enable_dlopen=no
15047 else
15048 enable_dlopen=yes
15049 fi
15050
15051 case $lt_cv_dlopen in
15052 dlopen)
15053 save_CPPFLAGS=$CPPFLAGS
15054 test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
15055
15056 save_LDFLAGS=$LDFLAGS
15057 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
15058
15059 save_LIBS=$LIBS
15060 LIBS="$lt_cv_dlopen_libs $LIBS"
15061
15062 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5
15063$as_echo_n "checking whether a program can dlopen itself... " >&6; }
15064if ${lt_cv_dlopen_self+:} false; then :
15065 $as_echo_n "(cached) " >&6
15066else
15067 if test yes = "$cross_compiling"; then :
15068 lt_cv_dlopen_self=cross
15069else
15070 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
15071 lt_status=$lt_dlunknown
15072 cat > conftest.$ac_ext <<_LT_EOF
15073#line $LINENO "configure"
15074#include "confdefs.h"
15075
15076#if HAVE_DLFCN_H
15077#include <dlfcn.h>
15078#endif
15079
15080#include <stdio.h>
15081
15082#ifdef RTLD_GLOBAL
15083# define LT_DLGLOBAL RTLD_GLOBAL
15084#else
15085# ifdef DL_GLOBAL
15086# define LT_DLGLOBAL DL_GLOBAL
15087# else
15088# define LT_DLGLOBAL 0
15089# endif
15090#endif
15091
15092/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
15093 find out it does not work in some platform. */
15094#ifndef LT_DLLAZY_OR_NOW
15095# ifdef RTLD_LAZY
15096# define LT_DLLAZY_OR_NOW RTLD_LAZY
15097# else
15098# ifdef DL_LAZY
15099# define LT_DLLAZY_OR_NOW DL_LAZY
15100# else
15101# ifdef RTLD_NOW
15102# define LT_DLLAZY_OR_NOW RTLD_NOW
15103# else
15104# ifdef DL_NOW
15105# define LT_DLLAZY_OR_NOW DL_NOW
15106# else
15107# define LT_DLLAZY_OR_NOW 0
15108# endif
15109# endif
15110# endif
15111# endif
15112#endif
15113
15114/* When -fvisibility=hidden is used, assume the code has been annotated
15115 correspondingly for the symbols needed. */
15116#if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
15117int fnord () __attribute__((visibility("default")));
15118#endif
15119
15120int fnord () { return 42; }
15121int main ()
15122{
15123 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
15124 int status = $lt_dlunknown;
15125
15126 if (self)
15127 {
15128 if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
15129 else
15130 {
15131 if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
15132 else puts (dlerror ());
15133 }
15134 /* dlclose (self); */
15135 }
15136 else
15137 puts (dlerror ());
15138
15139 return status;
15140}
15141_LT_EOF
15142 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
15143 (eval $ac_link) 2>&5
15144 ac_status=$?
15145 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
15146 test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then
15147 (./conftest; exit; ) >&5 2>/dev/null
15148 lt_status=$?
15149 case x$lt_status in
15150 x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
15151 x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
15152 x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;;
15153 esac
15154 else :
15155 # compilation failed
15156 lt_cv_dlopen_self=no
15157 fi
15158fi
15159rm -fr conftest*
15160
15161
15162fi
15163{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5
15164$as_echo "$lt_cv_dlopen_self" >&6; }
15165
15166 if test yes = "$lt_cv_dlopen_self"; then
15167 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
15168 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5
15169$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; }
15170if ${lt_cv_dlopen_self_static+:} false; then :
15171 $as_echo_n "(cached) " >&6
15172else
15173 if test yes = "$cross_compiling"; then :
15174 lt_cv_dlopen_self_static=cross
15175else
15176 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
15177 lt_status=$lt_dlunknown
15178 cat > conftest.$ac_ext <<_LT_EOF
15179#line $LINENO "configure"
15180#include "confdefs.h"
15181
15182#if HAVE_DLFCN_H
15183#include <dlfcn.h>
15184#endif
15185
15186#include <stdio.h>
15187
15188#ifdef RTLD_GLOBAL
15189# define LT_DLGLOBAL RTLD_GLOBAL
15190#else
15191# ifdef DL_GLOBAL
15192# define LT_DLGLOBAL DL_GLOBAL
15193# else
15194# define LT_DLGLOBAL 0
15195# endif
15196#endif
15197
15198/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
15199 find out it does not work in some platform. */
15200#ifndef LT_DLLAZY_OR_NOW
15201# ifdef RTLD_LAZY
15202# define LT_DLLAZY_OR_NOW RTLD_LAZY
15203# else
15204# ifdef DL_LAZY
15205# define LT_DLLAZY_OR_NOW DL_LAZY
15206# else
15207# ifdef RTLD_NOW
15208# define LT_DLLAZY_OR_NOW RTLD_NOW
15209# else
15210# ifdef DL_NOW
15211# define LT_DLLAZY_OR_NOW DL_NOW
15212# else
15213# define LT_DLLAZY_OR_NOW 0
15214# endif
15215# endif
15216# endif
15217# endif
15218#endif
15219
15220/* When -fvisibility=hidden is used, assume the code has been annotated
15221 correspondingly for the symbols needed. */
15222#if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
15223int fnord () __attribute__((visibility("default")));
15224#endif
15225
15226int fnord () { return 42; }
15227int main ()
15228{
15229 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
15230 int status = $lt_dlunknown;
15231
15232 if (self)
15233 {
15234 if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
15235 else
15236 {
15237 if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
15238 else puts (dlerror ());
15239 }
15240 /* dlclose (self); */
15241 }
15242 else
15243 puts (dlerror ());
15244
15245 return status;
15246}
15247_LT_EOF
15248 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
15249 (eval $ac_link) 2>&5
15250 ac_status=$?
15251 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
15252 test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then
15253 (./conftest; exit; ) >&5 2>/dev/null
15254 lt_status=$?
15255 case x$lt_status in
15256 x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
15257 x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
15258 x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;;
15259 esac
15260 else :
15261 # compilation failed
15262 lt_cv_dlopen_self_static=no
15263 fi
15264fi
15265rm -fr conftest*
15266
15267
15268fi
15269{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5
15270$as_echo "$lt_cv_dlopen_self_static" >&6; }
15271 fi
15272
15273 CPPFLAGS=$save_CPPFLAGS
15274 LDFLAGS=$save_LDFLAGS
15275 LIBS=$save_LIBS
15276 ;;
15277 esac
15278
15279 case $lt_cv_dlopen_self in
15280 yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
15281 *) enable_dlopen_self=unknown ;;
15282 esac
15283
15284 case $lt_cv_dlopen_self_static in
15285 yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
15286 *) enable_dlopen_self_static=unknown ;;
15287 esac
15288fi
15289
15290
15291
15292
15293
15294
15295
15296
15297
15298
15299
15300
15301
15302
15303
15304
15305
15306striplib=
15307old_striplib=
15308{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5
15309$as_echo_n "checking whether stripping libraries is possible... " >&6; }
15310if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
15311 test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
15312 test -z "$striplib" && striplib="$STRIP --strip-unneeded"
15313 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15314$as_echo "yes" >&6; }
15315else
15316# FIXME - insert some real tests, host_os isn't really good enough
15317 case $host_os in
15318 darwin*)
15319 if test -n "$STRIP"; then
15320 striplib="$STRIP -x"
15321 old_striplib="$STRIP -S"
15322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15323$as_echo "yes" >&6; }
15324 else
15325 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15326$as_echo "no" >&6; }
15327 fi
15328 ;;
15329 *)
15330 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15331$as_echo "no" >&6; }
15332 ;;
15333 esac
15334fi
15335
15336
15337
15338
15339
15340
15341
15342
15343
15344
15345
15346
15347 # Report what library types will actually be built
15348 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5
15349$as_echo_n "checking if libtool supports shared libraries... " >&6; }
15350 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5
15351$as_echo "$can_build_shared" >&6; }
15352
15353 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5
15354$as_echo_n "checking whether to build shared libraries... " >&6; }
15355 test no = "$can_build_shared" && enable_shared=no
15356
15357 # On AIX, shared libraries and static libraries use the same namespace, and
15358 # are all built from PIC.
15359 case $host_os in
15360 aix3*)
15361 test yes = "$enable_shared" && enable_static=no
15362 if test -n "$RANLIB"; then
15363 archive_cmds="$archive_cmds~\$RANLIB \$lib"
15364 postinstall_cmds='$RANLIB $lib'
15365 fi
15366 ;;
15367
15368 aix[4-9]*)
15369 if test ia64 != "$host_cpu"; then
15370 case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in
15371 yes,aix,yes) ;; # shared object as lib.so file only
15372 yes,svr4,*) ;; # shared object as lib.so archive member only
15373 yes,*) enable_static=no ;; # shared object in lib.a archive as well
15374 esac
15375 fi
15376 ;;
15377 esac
15378 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5
15379$as_echo "$enable_shared" >&6; }
15380
15381 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5
15382$as_echo_n "checking whether to build static libraries... " >&6; }
15383 # Make sure either enable_shared or enable_static is yes.
15384 test yes = "$enable_shared" || enable_static=yes
15385 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5
15386$as_echo "$enable_static" >&6; }
15387
15388
15389
15390
15391fi
15392ac_ext=c
15393ac_cpp='$CPP $CPPFLAGS'
15394ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
15395ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
15396ac_compiler_gnu=$ac_cv_c_compiler_gnu
15397
15398CC=$lt_save_CC
15399
15400
15401
15402
15403
15404
15405
15406
15407
15408
15409
15410
15411
15412
15413
15414 ac_config_commands="$ac_config_commands libtool"
15415
15416
15417
15418
15419# Only expand once:
15420
15421
15422## --------------------- ##
15423## End of libtool code ##
15424## --------------------- ##
15425
15426#
15427# Verify if finally libtool shared libraries will be built
15428#
15429
15430case "x$enable_shared" in # ((
15431 xyes | xno)
15432 xc_lt_build_shared=$enable_shared
15433 ;;
15434 *)
15435 as_fn_error $? "unexpected libtool enable_shared value: $enable_shared" "$LINENO" 5
15436 ;;
15437esac
15438
15439#
15440# Verify if finally libtool static libraries will be built
15441#
15442
15443case "x$enable_static" in # ((
15444 xyes | xno)
15445 xc_lt_build_static=$enable_static
15446 ;;
15447 *)
15448 as_fn_error $? "unexpected libtool enable_static value: $enable_static" "$LINENO" 5
15449 ;;
15450esac
15451
15452#
15453# Verify if libtool shared libraries should be linked using flag -version-info
15454#
15455
15456{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries with -version-info" >&5
15457$as_echo_n "checking whether to build shared libraries with -version-info... " >&6; }
15458xc_lt_shlib_use_version_info='yes'
15459if test "x$version_type" = 'xnone'; then
15460 xc_lt_shlib_use_version_info='no'
15461fi
15462case $host_os in # (
15463 amigaos*)
15464 xc_lt_shlib_use_version_info='yes'
15465 ;;
15466esac
15467{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $xc_lt_shlib_use_version_info" >&5
15468$as_echo "$xc_lt_shlib_use_version_info" >&6; }
15469
15470#
15471# Verify if libtool shared libraries should be linked using flag -no-undefined
15472#
15473
15474{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries with -no-undefined" >&5
15475$as_echo_n "checking whether to build shared libraries with -no-undefined... " >&6; }
15476xc_lt_shlib_use_no_undefined='no'
15477if test "x$allow_undefined" = 'xno'; then
15478 xc_lt_shlib_use_no_undefined='yes'
15479elif test "x$allow_undefined_flag" = 'xunsupported'; then
15480 xc_lt_shlib_use_no_undefined='yes'
15481fi
15482case $host_os in # (
15483 cygwin* | mingw* | pw32* | cegcc* | os2* | aix*)
15484 xc_lt_shlib_use_no_undefined='yes'
15485 ;;
15486esac
15487{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $xc_lt_shlib_use_no_undefined" >&5
15488$as_echo "$xc_lt_shlib_use_no_undefined" >&6; }
15489
15490#
15491# Verify if libtool shared libraries should be linked using flag -mimpure-text
15492#
15493
15494{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries with -mimpure-text" >&5
15495$as_echo_n "checking whether to build shared libraries with -mimpure-text... " >&6; }
15496xc_lt_shlib_use_mimpure_text='no'
15497case $host_os in # (
15498 solaris2*)
15499 if test "x$GCC" = 'xyes'; then
15500 xc_lt_shlib_use_mimpure_text='yes'
15501 fi
15502 ;;
15503esac
15504{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $xc_lt_shlib_use_mimpure_text" >&5
15505$as_echo "$xc_lt_shlib_use_mimpure_text" >&6; }
15506
15507#
15508# Find out whether libtool libraries would be built wit PIC
15509#
15510
15511case "x$pic_mode" in # ((((
15512 xdefault)
15513 xc_lt_build_shared_with_pic='yes'
15514 xc_lt_build_static_with_pic='no'
15515 ;;
15516 xyes)
15517 xc_lt_build_shared_with_pic='yes'
15518 xc_lt_build_static_with_pic='yes'
15519 ;;
15520 xno)
15521 xc_lt_build_shared_with_pic='no'
15522 xc_lt_build_static_with_pic='no'
15523 ;;
15524 *)
15525 xc_lt_build_shared_with_pic='unknown'
15526 xc_lt_build_static_with_pic='unknown'
15527 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unexpected libtool pic_mode value: $pic_mode" >&5
15528$as_echo "$as_me: WARNING: unexpected libtool pic_mode value: $pic_mode" >&2;}
15529 ;;
15530esac
15531{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries with PIC" >&5
15532$as_echo_n "checking whether to build shared libraries with PIC... " >&6; }
15533{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $xc_lt_build_shared_with_pic" >&5
15534$as_echo "$xc_lt_build_shared_with_pic" >&6; }
15535{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries with PIC" >&5
15536$as_echo_n "checking whether to build static libraries with PIC... " >&6; }
15537{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $xc_lt_build_static_with_pic" >&5
15538$as_echo "$xc_lt_build_static_with_pic" >&6; }
15539
15540#
15541# Verify if libtool shared libraries will be built while static not built
15542#
15543
15544{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries only" >&5
15545$as_echo_n "checking whether to build shared libraries only... " >&6; }
15546if test "$xc_lt_build_shared" = 'yes' &&
15547 test "$xc_lt_build_static" = 'no'; then
15548 xc_lt_build_shared_only='yes'
15549else
15550 xc_lt_build_shared_only='no'
15551fi
15552{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $xc_lt_build_shared_only" >&5
15553$as_echo "$xc_lt_build_shared_only" >&6; }
15554
15555#
15556# Verify if libtool static libraries will be built while shared not built
15557#
15558
15559{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries only" >&5
15560$as_echo_n "checking whether to build static libraries only... " >&6; }
15561if test "$xc_lt_build_static" = 'yes' &&
15562 test "$xc_lt_build_shared" = 'no'; then
15563 xc_lt_build_static_only='yes'
15564else
15565 xc_lt_build_static_only='no'
15566fi
15567{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $xc_lt_build_static_only" >&5
15568$as_echo "$xc_lt_build_static_only" >&6; }
15569
15570
15571
15572
15573#
15574# Automake conditionals based on libtool related checks
15575#
15576
15577 if test "x$xc_lt_shlib_use_version_info" = 'xyes'; then
15578 CURL_LT_SHLIB_USE_VERSION_INFO_TRUE=
15579 CURL_LT_SHLIB_USE_VERSION_INFO_FALSE='#'
15580else
15581 CURL_LT_SHLIB_USE_VERSION_INFO_TRUE='#'
15582 CURL_LT_SHLIB_USE_VERSION_INFO_FALSE=
15583fi
15584
15585 if test "x$xc_lt_shlib_use_no_undefined" = 'xyes'; then
15586 CURL_LT_SHLIB_USE_NO_UNDEFINED_TRUE=
15587 CURL_LT_SHLIB_USE_NO_UNDEFINED_FALSE='#'
15588else
15589 CURL_LT_SHLIB_USE_NO_UNDEFINED_TRUE='#'
15590 CURL_LT_SHLIB_USE_NO_UNDEFINED_FALSE=
15591fi
15592
15593 if test "x$xc_lt_shlib_use_mimpure_text" = 'xyes'; then
15594 CURL_LT_SHLIB_USE_MIMPURE_TEXT_TRUE=
15595 CURL_LT_SHLIB_USE_MIMPURE_TEXT_FALSE='#'
15596else
15597 CURL_LT_SHLIB_USE_MIMPURE_TEXT_TRUE='#'
15598 CURL_LT_SHLIB_USE_MIMPURE_TEXT_FALSE=
15599fi
15600
15601
15602#
15603# Due to libtool and automake machinery limitations of not allowing
15604# specifying separate CPPFLAGS or CFLAGS when compiling objects for
15605# inclusion of these in shared or static libraries, we are forced to
15606# build using separate configure runs for shared and static libraries
15607# on systems where different CPPFLAGS or CFLAGS are mandatory in order
15608# to compile objects for each kind of library. Notice that relying on
15609# the '-DPIC' CFLAG that libtool provides is not valid given that the
15610# user might for example choose to build static libraries with PIC.
15611#
15612
15613#
15614# Make our Makefile.am files use the staticlib CPPFLAG only when strictly
15615# targeting a static library and not building its shared counterpart.
15616#
15617
15618 if test "x$xc_lt_build_static_only" = 'xyes'; then
15619 USE_CPPFLAG_CURL_STATICLIB_TRUE=
15620 USE_CPPFLAG_CURL_STATICLIB_FALSE='#'
15621else
15622 USE_CPPFLAG_CURL_STATICLIB_TRUE='#'
15623 USE_CPPFLAG_CURL_STATICLIB_FALSE=
15624fi
15625
15626
15627#
15628# Make staticlib CPPFLAG variable and its definition visible in output
15629# files unconditionally, providing an empty definition unless strictly
15630# targeting a static library and not building its shared counterpart.
15631#
15632
15633CPPFLAG_CURL_STATICLIB=
15634if test "x$xc_lt_build_static_only" = 'xyes'; then
15635 CPPFLAG_CURL_STATICLIB='-DCURL_STATICLIB'
15636fi
15637
15638
15639
15640# Determine whether all dependent libraries must be specified when linking
15641if test "X$enable_shared" = "Xyes" -a "X$link_all_deplibs" = "Xno"
15642then
15643 REQUIRE_LIB_DEPS=no
15644else
15645 REQUIRE_LIB_DEPS=yes
15646fi
15647
15648 if test x$REQUIRE_LIB_DEPS = xyes; then
15649 USE_EXPLICIT_LIB_DEPS_TRUE=
15650 USE_EXPLICIT_LIB_DEPS_FALSE='#'
15651else
15652 USE_EXPLICIT_LIB_DEPS_TRUE='#'
15653 USE_EXPLICIT_LIB_DEPS_FALSE=
15654fi
15655
15656
15657{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
15658$as_echo_n "checking for inline... " >&6; }
15659if ${ac_cv_c_inline+:} false; then :
15660 $as_echo_n "(cached) " >&6
15661else
15662 ac_cv_c_inline=no
15663for ac_kw in inline __inline__ __inline; do
15664 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15665/* end confdefs.h. */
15666#ifndef __cplusplus
15667typedef int foo_t;
15668static $ac_kw foo_t static_foo () {return 0; }
15669$ac_kw foo_t foo () {return 0; }
15670#endif
15671
15672_ACEOF
15673if ac_fn_c_try_compile "$LINENO"; then :
15674 ac_cv_c_inline=$ac_kw
15675fi
15676rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15677 test "$ac_cv_c_inline" != no && break
15678done
15679
15680fi
15681{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
15682$as_echo "$ac_cv_c_inline" >&6; }
15683
15684case $ac_cv_c_inline in
15685 inline | yes) ;;
15686 *)
15687 case $ac_cv_c_inline in
15688 no) ac_val=;;
15689 *) ac_val=$ac_cv_c_inline;;
15690 esac
15691 cat >>confdefs.h <<_ACEOF
15692#ifndef __cplusplus
15693#define inline $ac_val
15694#endif
15695_ACEOF
15696 ;;
15697esac
15698
15699
15700
15701
Alex Deymo486467e2017-12-19 19:04:07 +010015702 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if cpp -P is needed" >&5
15703$as_echo_n "checking if cpp -P is needed... " >&6; }
15704 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15705/* end confdefs.h. */
15706
15707 #include <errno.h>
15708TEST EINVAL TEST
15709
15710_ACEOF
15711if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15712 $EGREP "TEST.*TEST" >/dev/null 2>&1; then :
15713 cpp=no
15714else
15715 cpp=yes
15716fi
15717rm -f conftest*
15718
15719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cpp" >&5
15720$as_echo "$cpp" >&6; }
15721
15722 if test "x$cpp" = "xyes"; then
15723 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if cpp -P works" >&5
15724$as_echo_n "checking if cpp -P works... " >&6; }
15725 OLDCPPFLAGS=$CPPFLAGS
15726 CPPFLAGS="$CPPFLAGS -P"
15727 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15728/* end confdefs.h. */
15729
15730 #include <errno.h>
15731TEST EINVAL TEST
15732
15733_ACEOF
15734if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15735 $EGREP "TEST.*TEST" >/dev/null 2>&1; then :
15736 cpp_p=yes
15737else
15738 cpp_p=no
15739fi
15740rm -f conftest*
15741
15742 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cpp_p" >&5
15743$as_echo "$cpp_p" >&6; }
15744
15745 if test "x$cpp_p" = "xno"; then
15746 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: failed to figure out cpp -P alternative" >&5
15747$as_echo "$as_me: WARNING: failed to figure out cpp -P alternative" >&2;}
15748 # without -P
15749 CPPPFLAG=""
15750 else
15751 # with -P
15752 CPPPFLAG="-P"
15753 fi
15754 CPPFLAGS=$OLDCPPFLAGS
15755 else
15756 # without -P
15757 CPPPFLAG=""
15758 fi
15759
15760
Elliott Hughes82be86d2017-09-20 17:00:17 -070015761 #
15762 compiler_id="unknown"
15763 compiler_num="0"
15764 #
15765 flags_dbg_all="unknown"
15766 flags_dbg_yes="unknown"
15767 flags_dbg_off="unknown"
15768 flags_opt_all="unknown"
15769 flags_opt_yes="unknown"
15770 flags_opt_off="unknown"
15771 #
15772 flags_prefer_cppflags="no"
15773 #
15774
15775 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler is DEC/Compaq/HP C" >&5
15776$as_echo_n "checking if compiler is DEC/Compaq/HP C... " >&6; }
15777
15778 OLDCPPFLAGS=$CPPFLAGS
15779 # CPPPFLAG comes from CURL_CPP_P
15780 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
15781 if test -z "$SED"; then
15782 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
15783 fi
15784 if test -z "$GREP"; then
15785 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
15786 fi
15787
15788 tmp_exp=""
15789 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15790/* end confdefs.h. */
15791
15792
15793#ifdef __DECC
15794CURL_DEF_TOKEN __DECC
15795#endif
15796
15797
15798_ACEOF
15799if ac_fn_c_try_cpp "$LINENO"; then :
15800
15801 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
15802 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
15803 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
15804 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
15805 if test -z "$tmp_exp" || test "$tmp_exp" = "__DECC"; then
15806 tmp_exp=""
15807 fi
15808
15809fi
15810rm -f conftest.err conftest.i conftest.$ac_ext
15811 if test -z "$tmp_exp"; then
15812 curl_cv_have_def___DECC=no
15813
15814 else
15815 curl_cv_have_def___DECC=yes
15816 curl_cv_def___DECC=$tmp_exp
15817
15818 fi
15819 CPPFLAGS=$OLDCPPFLAGS
15820
15821
15822 OLDCPPFLAGS=$CPPFLAGS
15823 # CPPPFLAG comes from CURL_CPP_P
15824 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
15825 if test -z "$SED"; then
15826 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
15827 fi
15828 if test -z "$GREP"; then
15829 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
15830 fi
15831
15832 tmp_exp=""
15833 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15834/* end confdefs.h. */
15835
15836
15837#ifdef __DECC_VER
15838CURL_DEF_TOKEN __DECC_VER
15839#endif
15840
15841
15842_ACEOF
15843if ac_fn_c_try_cpp "$LINENO"; then :
15844
15845 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
15846 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
15847 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
15848 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
15849 if test -z "$tmp_exp" || test "$tmp_exp" = "__DECC_VER"; then
15850 tmp_exp=""
15851 fi
15852
15853fi
15854rm -f conftest.err conftest.i conftest.$ac_ext
15855 if test -z "$tmp_exp"; then
15856 curl_cv_have_def___DECC_VER=no
15857
15858 else
15859 curl_cv_have_def___DECC_VER=yes
15860 curl_cv_def___DECC_VER=$tmp_exp
15861
15862 fi
15863 CPPFLAGS=$OLDCPPFLAGS
15864
15865 if test "$curl_cv_have_def___DECC" = "yes" &&
15866 test "$curl_cv_have_def___DECC_VER" = "yes"; then
15867 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15868$as_echo "yes" >&6; }
15869 compiler_id="DEC_C"
15870 flags_dbg_all="-g -g0 -g1 -g2 -g3"
15871 flags_dbg_yes="-g2"
15872 flags_dbg_off=""
15873 flags_opt_all="-O -O0 -O1 -O2 -O3 -O4"
15874 flags_opt_yes="-O1"
15875 flags_opt_off="-O0"
15876 else
15877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15878$as_echo "no" >&6; }
15879 fi
15880
15881
15882 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler is HP-UX C" >&5
15883$as_echo_n "checking if compiler is HP-UX C... " >&6; }
15884
15885 OLDCPPFLAGS=$CPPFLAGS
15886 # CPPPFLAG comes from CURL_CPP_P
15887 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
15888 if test -z "$SED"; then
15889 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
15890 fi
15891 if test -z "$GREP"; then
15892 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
15893 fi
15894
15895 tmp_exp=""
15896 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15897/* end confdefs.h. */
15898
15899
15900#ifdef __HP_cc
15901CURL_DEF_TOKEN __HP_cc
15902#endif
15903
15904
15905_ACEOF
15906if ac_fn_c_try_cpp "$LINENO"; then :
15907
15908 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
15909 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
15910 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
15911 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
15912 if test -z "$tmp_exp" || test "$tmp_exp" = "__HP_cc"; then
15913 tmp_exp=""
15914 fi
15915
15916fi
15917rm -f conftest.err conftest.i conftest.$ac_ext
15918 if test -z "$tmp_exp"; then
15919 curl_cv_have_def___HP_cc=no
15920
15921 else
15922 curl_cv_have_def___HP_cc=yes
15923 curl_cv_def___HP_cc=$tmp_exp
15924
15925 fi
15926 CPPFLAGS=$OLDCPPFLAGS
15927
15928 if test "$curl_cv_have_def___HP_cc" = "yes"; then
15929 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15930$as_echo "yes" >&6; }
15931 compiler_id="HP_UX_C"
15932 flags_dbg_all="-g -s"
15933 flags_dbg_yes="-g"
15934 flags_dbg_off="-s"
15935 flags_opt_all="-O +O0 +O1 +O2 +O3 +O4"
15936 flags_opt_yes="+O2"
15937 flags_opt_off="+O0"
15938 else
15939 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15940$as_echo "no" >&6; }
15941 fi
15942
15943
15944 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler is IBM C" >&5
15945$as_echo_n "checking if compiler is IBM C... " >&6; }
15946
15947 OLDCPPFLAGS=$CPPFLAGS
15948 # CPPPFLAG comes from CURL_CPP_P
15949 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
15950 if test -z "$SED"; then
15951 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
15952 fi
15953 if test -z "$GREP"; then
15954 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
15955 fi
15956
15957 tmp_exp=""
15958 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15959/* end confdefs.h. */
15960
15961
15962#ifdef __IBMC__
15963CURL_DEF_TOKEN __IBMC__
15964#endif
15965
15966
15967_ACEOF
15968if ac_fn_c_try_cpp "$LINENO"; then :
15969
15970 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
15971 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
15972 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
15973 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
15974 if test -z "$tmp_exp" || test "$tmp_exp" = "__IBMC__"; then
15975 tmp_exp=""
15976 fi
15977
15978fi
15979rm -f conftest.err conftest.i conftest.$ac_ext
15980 if test -z "$tmp_exp"; then
15981 curl_cv_have_def___IBMC__=no
15982
15983 else
15984 curl_cv_have_def___IBMC__=yes
15985 curl_cv_def___IBMC__=$tmp_exp
15986
15987 fi
15988 CPPFLAGS=$OLDCPPFLAGS
15989
15990 if test "$curl_cv_have_def___IBMC__" = "yes"; then
15991 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15992$as_echo "yes" >&6; }
15993 compiler_id="IBM_C"
15994 flags_dbg_all="-g -g0 -g1 -g2 -g3"
15995 flags_dbg_yes="-g"
15996 flags_dbg_off=""
15997 flags_opt_all="-O -O0 -O1 -O2 -O3 -O4 -O5"
15998 flags_opt_all="$flags_opt_all -qnooptimize"
15999 flags_opt_all="$flags_opt_all -qoptimize=0"
16000 flags_opt_all="$flags_opt_all -qoptimize=1"
16001 flags_opt_all="$flags_opt_all -qoptimize=2"
16002 flags_opt_all="$flags_opt_all -qoptimize=3"
16003 flags_opt_all="$flags_opt_all -qoptimize=4"
16004 flags_opt_all="$flags_opt_all -qoptimize=5"
16005 flags_opt_yes="-O2"
16006 flags_opt_off="-qnooptimize"
16007 flags_prefer_cppflags="yes"
16008 else
16009 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16010$as_echo "no" >&6; }
16011 fi
16012
16013
16014 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler is Intel C" >&5
16015$as_echo_n "checking if compiler is Intel C... " >&6; }
16016
16017 OLDCPPFLAGS=$CPPFLAGS
16018 # CPPPFLAG comes from CURL_CPP_P
16019 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16020 if test -z "$SED"; then
16021 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16022 fi
16023 if test -z "$GREP"; then
16024 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16025 fi
16026
16027 tmp_exp=""
16028 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16029/* end confdefs.h. */
16030
16031
16032#ifdef __INTEL_COMPILER
16033CURL_DEF_TOKEN __INTEL_COMPILER
16034#endif
16035
16036
16037_ACEOF
16038if ac_fn_c_try_cpp "$LINENO"; then :
16039
16040 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16041 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16042 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16043 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16044 if test -z "$tmp_exp" || test "$tmp_exp" = "__INTEL_COMPILER"; then
16045 tmp_exp=""
16046 fi
16047
16048fi
16049rm -f conftest.err conftest.i conftest.$ac_ext
16050 if test -z "$tmp_exp"; then
16051 curl_cv_have_def___INTEL_COMPILER=no
16052
16053 else
16054 curl_cv_have_def___INTEL_COMPILER=yes
16055 curl_cv_def___INTEL_COMPILER=$tmp_exp
16056
16057 fi
16058 CPPFLAGS=$OLDCPPFLAGS
16059
16060 if test "$curl_cv_have_def___INTEL_COMPILER" = "yes"; then
16061 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16062$as_echo "yes" >&6; }
16063 compiler_num="$curl_cv_def___INTEL_COMPILER"
16064
16065 OLDCPPFLAGS=$CPPFLAGS
16066 # CPPPFLAG comes from CURL_CPP_P
16067 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16068 if test -z "$SED"; then
16069 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16070 fi
16071 if test -z "$GREP"; then
16072 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16073 fi
16074
16075 tmp_exp=""
16076 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16077/* end confdefs.h. */
16078
16079
16080#ifdef __unix__
16081CURL_DEF_TOKEN __unix__
16082#endif
16083
16084
16085_ACEOF
16086if ac_fn_c_try_cpp "$LINENO"; then :
16087
16088 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16089 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16090 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16091 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16092 if test -z "$tmp_exp" || test "$tmp_exp" = ""; then
16093 tmp_exp=""
16094 fi
16095
16096fi
16097rm -f conftest.err conftest.i conftest.$ac_ext
16098 if test -z "$tmp_exp"; then
16099 curl_cv_have_def___unix__=no
16100
16101 else
16102 curl_cv_have_def___unix__=yes
16103 curl_cv_def___unix__=$tmp_exp
16104
16105 fi
16106 CPPFLAGS=$OLDCPPFLAGS
16107
16108 if test "$curl_cv_have_def___unix__" = "yes"; then
16109 compiler_id="INTEL_UNIX_C"
16110 flags_dbg_all="-g -g0"
16111 flags_dbg_yes="-g"
16112 flags_dbg_off=""
16113 flags_opt_all="-O -O0 -O1 -O2 -O3 -Os"
16114 flags_opt_yes="-O2"
16115 flags_opt_off="-O0"
16116 else
16117 compiler_id="INTEL_WINDOWS_C"
16118 flags_dbg_all="/ZI /Zi /zI /zi /ZD /Zd /zD /zd /Z7 /z7 /Oy /Oy-"
16119 flags_dbg_all="$flags_dbg_all /debug"
16120 flags_dbg_all="$flags_dbg_all /debug:none"
16121 flags_dbg_all="$flags_dbg_all /debug:minimal"
16122 flags_dbg_all="$flags_dbg_all /debug:partial"
16123 flags_dbg_all="$flags_dbg_all /debug:full"
16124 flags_dbg_all="$flags_dbg_all /debug:semantic_stepping"
16125 flags_dbg_all="$flags_dbg_all /debug:extended"
16126 flags_dbg_yes="/Zi /Oy-"
16127 flags_dbg_off="/debug:none /Oy-"
16128 flags_opt_all="/O /O0 /O1 /O2 /O3 /Od /Og /Og- /Oi /Oi-"
16129 flags_opt_yes="/O2"
16130 flags_opt_off="/Od"
16131 fi
16132 else
16133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16134$as_echo "no" >&6; }
16135 fi
16136
16137
16138 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler is clang" >&5
16139$as_echo_n "checking if compiler is clang... " >&6; }
16140
16141 OLDCPPFLAGS=$CPPFLAGS
16142 # CPPPFLAG comes from CURL_CPP_P
16143 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16144 if test -z "$SED"; then
16145 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16146 fi
16147 if test -z "$GREP"; then
16148 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16149 fi
16150
16151 tmp_exp=""
16152 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16153/* end confdefs.h. */
16154
16155
16156#ifdef __clang__
16157CURL_DEF_TOKEN __clang__
16158#endif
16159
16160
16161_ACEOF
16162if ac_fn_c_try_cpp "$LINENO"; then :
16163
16164 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16165 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16166 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16167 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16168 if test -z "$tmp_exp" || test "$tmp_exp" = "__clang__"; then
16169 tmp_exp=""
16170 fi
16171
16172fi
16173rm -f conftest.err conftest.i conftest.$ac_ext
16174 if test -z "$tmp_exp"; then
16175 curl_cv_have_def___clang__=no
16176
16177 else
16178 curl_cv_have_def___clang__=yes
16179 curl_cv_def___clang__=$tmp_exp
16180
16181 fi
16182 CPPFLAGS=$OLDCPPFLAGS
16183
16184 if test "$curl_cv_have_def___clang__" = "yes"; then
16185 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16186$as_echo "yes" >&6; }
Haibo Huang51d9d882019-02-06 01:36:06 -080016187 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler is xlclang" >&5
16188$as_echo_n "checking if compiler is xlclang... " >&6; }
16189
16190 OLDCPPFLAGS=$CPPFLAGS
16191 # CPPPFLAG comes from CURL_CPP_P
16192 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16193 if test -z "$SED"; then
16194 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16195 fi
16196 if test -z "$GREP"; then
16197 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16198 fi
16199
16200 tmp_exp=""
16201 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16202/* end confdefs.h. */
16203
16204
16205#ifdef __ibmxl__
16206CURL_DEF_TOKEN __ibmxl__
16207#endif
16208
16209
16210_ACEOF
16211if ac_fn_c_try_cpp "$LINENO"; then :
16212
16213 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16214 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16215 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16216 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16217 if test -z "$tmp_exp" || test "$tmp_exp" = "__ibmxl__"; then
16218 tmp_exp=""
16219 fi
16220
16221fi
16222rm -f conftest.err conftest.i conftest.$ac_ext
16223 if test -z "$tmp_exp"; then
16224 curl_cv_have_def___ibmxl__=no
16225
16226 else
16227 curl_cv_have_def___ibmxl__=yes
16228 curl_cv_def___ibmxl__=$tmp_exp
16229
16230 fi
16231 CPPFLAGS=$OLDCPPFLAGS
16232
16233 if test "$curl_cv_have_def___ibmxl__" = "yes" ; then
16234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16235$as_echo "yes" >&6; }
16236 compiler_id="XLCLANG"
16237 else
16238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16239$as_echo "no" >&6; }
16240 compiler_id="CLANG"
16241 fi
Elliott Hughes82be86d2017-09-20 17:00:17 -070016242 fullclangver=`$CC -v 2>&1 | grep version`
16243 clangver=`echo $fullclangver | grep "based on LLVM " | "$SED" 's/.*(based on LLVM \([0-9]*\.[0-9]*\).*)/\1/'`
16244 if test -z "$clangver"; then
16245 if echo $fullclangver | grep "Apple LLVM version " >/dev/null; then
Alex Deymo486467e2017-12-19 19:04:07 +010016246 clangver="3.7"
Elliott Hughes82be86d2017-09-20 17:00:17 -070016247 else
16248 clangver=`echo $fullclangver | "$SED" 's/.*version \([0-9]*\.[0-9]*\).*/\1/'`
16249 fi
16250 fi
16251 clangvhi=`echo $clangver | cut -d . -f1`
16252 clangvlo=`echo $clangver | cut -d . -f2`
16253 compiler_num=`(expr $clangvhi "*" 100 + $clangvlo) 2>/dev/null`
16254 flags_dbg_all="-g -g0 -g1 -g2 -g3"
16255 flags_dbg_all="$flags_dbg_all -ggdb"
16256 flags_dbg_all="$flags_dbg_all -gstabs"
16257 flags_dbg_all="$flags_dbg_all -gstabs+"
16258 flags_dbg_all="$flags_dbg_all -gcoff"
16259 flags_dbg_all="$flags_dbg_all -gxcoff"
16260 flags_dbg_all="$flags_dbg_all -gdwarf-2"
16261 flags_dbg_all="$flags_dbg_all -gvms"
16262 flags_dbg_yes="-g"
16263 flags_dbg_off=""
16264 flags_opt_all="-O -O0 -O1 -O2 -Os -O3 -O4"
16265 flags_opt_yes="-Os"
16266 flags_opt_off="-O0"
16267 else
16268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16269$as_echo "no" >&6; }
16270 fi
16271
16272
16273 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler is GNU C" >&5
16274$as_echo_n "checking if compiler is GNU C... " >&6; }
16275
16276 OLDCPPFLAGS=$CPPFLAGS
16277 # CPPPFLAG comes from CURL_CPP_P
16278 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16279 if test -z "$SED"; then
16280 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16281 fi
16282 if test -z "$GREP"; then
16283 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16284 fi
16285
16286 tmp_exp=""
16287 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16288/* end confdefs.h. */
16289
16290
16291#ifdef __GNUC__
16292CURL_DEF_TOKEN __GNUC__
16293#endif
16294
16295
16296_ACEOF
16297if ac_fn_c_try_cpp "$LINENO"; then :
16298
16299 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16300 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16301 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16302 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16303 if test -z "$tmp_exp" || test "$tmp_exp" = "__GNUC__"; then
16304 tmp_exp=""
16305 fi
16306
16307fi
16308rm -f conftest.err conftest.i conftest.$ac_ext
16309 if test -z "$tmp_exp"; then
16310 curl_cv_have_def___GNUC__=no
16311
16312 else
16313 curl_cv_have_def___GNUC__=yes
16314 curl_cv_def___GNUC__=$tmp_exp
16315
16316 fi
16317 CPPFLAGS=$OLDCPPFLAGS
16318
16319 if test "$curl_cv_have_def___GNUC__" = "yes" &&
16320 test "$compiler_id" = "unknown"; then
16321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16322$as_echo "yes" >&6; }
16323 compiler_id="GNU_C"
16324 gccver=`$CC -dumpversion`
16325 gccvhi=`echo $gccver | cut -d . -f1`
16326 gccvlo=`echo $gccver | cut -d . -f2`
16327 compiler_num=`(expr $gccvhi "*" 100 + $gccvlo) 2>/dev/null`
16328 flags_dbg_all="-g -g0 -g1 -g2 -g3"
16329 flags_dbg_all="$flags_dbg_all -ggdb"
16330 flags_dbg_all="$flags_dbg_all -gstabs"
16331 flags_dbg_all="$flags_dbg_all -gstabs+"
16332 flags_dbg_all="$flags_dbg_all -gcoff"
16333 flags_dbg_all="$flags_dbg_all -gxcoff"
16334 flags_dbg_all="$flags_dbg_all -gdwarf-2"
16335 flags_dbg_all="$flags_dbg_all -gvms"
16336 flags_dbg_yes="-g"
16337 flags_dbg_off=""
16338 flags_opt_all="-O -O0 -O1 -O2 -O3 -Os -Og -Ofast"
16339 flags_opt_yes="-O2"
16340 flags_opt_off="-O0"
16341
16342 OLDCPPFLAGS=$CPPFLAGS
16343 # CPPPFLAG comes from CURL_CPP_P
16344 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16345 if test -z "$SED"; then
16346 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16347 fi
16348 if test -z "$GREP"; then
16349 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16350 fi
16351
16352 tmp_exp=""
16353 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16354/* end confdefs.h. */
16355
16356
16357#ifdef _WIN32
16358CURL_DEF_TOKEN _WIN32
16359#endif
16360
16361
16362_ACEOF
16363if ac_fn_c_try_cpp "$LINENO"; then :
16364
16365 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16366 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16367 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16368 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16369 if test -z "$tmp_exp" || test "$tmp_exp" = "_WIN32"; then
16370 tmp_exp=""
16371 fi
16372
16373fi
16374rm -f conftest.err conftest.i conftest.$ac_ext
16375 if test -z "$tmp_exp"; then
16376 curl_cv_have_def__WIN32=no
16377
16378 else
16379 curl_cv_have_def__WIN32=yes
16380 curl_cv_def__WIN32=$tmp_exp
16381
16382 fi
16383 CPPFLAGS=$OLDCPPFLAGS
16384
16385 else
16386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16387$as_echo "no" >&6; }
16388 fi
16389
16390
16391 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler is LCC" >&5
16392$as_echo_n "checking if compiler is LCC... " >&6; }
16393
16394 OLDCPPFLAGS=$CPPFLAGS
16395 # CPPPFLAG comes from CURL_CPP_P
16396 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16397 if test -z "$SED"; then
16398 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16399 fi
16400 if test -z "$GREP"; then
16401 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16402 fi
16403
16404 tmp_exp=""
16405 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16406/* end confdefs.h. */
16407
16408
16409#ifdef __LCC__
16410CURL_DEF_TOKEN __LCC__
16411#endif
16412
16413
16414_ACEOF
16415if ac_fn_c_try_cpp "$LINENO"; then :
16416
16417 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16418 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16419 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16420 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16421 if test -z "$tmp_exp" || test "$tmp_exp" = "__LCC__"; then
16422 tmp_exp=""
16423 fi
16424
16425fi
16426rm -f conftest.err conftest.i conftest.$ac_ext
16427 if test -z "$tmp_exp"; then
16428 curl_cv_have_def___LCC__=no
16429
16430 else
16431 curl_cv_have_def___LCC__=yes
16432 curl_cv_def___LCC__=$tmp_exp
16433
16434 fi
16435 CPPFLAGS=$OLDCPPFLAGS
16436
16437 if test "$curl_cv_have_def___LCC__" = "yes"; then
16438 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16439$as_echo "yes" >&6; }
16440 compiler_id="LCC"
16441 flags_dbg_all="-g"
16442 flags_dbg_yes="-g"
16443 flags_dbg_off=""
16444 flags_opt_all=""
16445 flags_opt_yes=""
16446 flags_opt_off=""
16447 else
16448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16449$as_echo "no" >&6; }
16450 fi
16451
16452
16453 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler is SGI MIPSpro C" >&5
16454$as_echo_n "checking if compiler is SGI MIPSpro C... " >&6; }
16455
16456 OLDCPPFLAGS=$CPPFLAGS
16457 # CPPPFLAG comes from CURL_CPP_P
16458 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16459 if test -z "$SED"; then
16460 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16461 fi
16462 if test -z "$GREP"; then
16463 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16464 fi
16465
16466 tmp_exp=""
16467 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16468/* end confdefs.h. */
16469
16470
16471#ifdef __GNUC__
16472CURL_DEF_TOKEN __GNUC__
16473#endif
16474
16475
16476_ACEOF
16477if ac_fn_c_try_cpp "$LINENO"; then :
16478
16479 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16480 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16481 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16482 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16483 if test -z "$tmp_exp" || test "$tmp_exp" = "__GNUC__"; then
16484 tmp_exp=""
16485 fi
16486
16487fi
16488rm -f conftest.err conftest.i conftest.$ac_ext
16489 if test -z "$tmp_exp"; then
16490 curl_cv_have_def___GNUC__=no
16491
16492 else
16493 curl_cv_have_def___GNUC__=yes
16494 curl_cv_def___GNUC__=$tmp_exp
16495
16496 fi
16497 CPPFLAGS=$OLDCPPFLAGS
16498
16499
16500 OLDCPPFLAGS=$CPPFLAGS
16501 # CPPPFLAG comes from CURL_CPP_P
16502 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16503 if test -z "$SED"; then
16504 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16505 fi
16506 if test -z "$GREP"; then
16507 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16508 fi
16509
16510 tmp_exp=""
16511 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16512/* end confdefs.h. */
16513
16514
16515#ifdef _COMPILER_VERSION
16516CURL_DEF_TOKEN _COMPILER_VERSION
16517#endif
16518
16519
16520_ACEOF
16521if ac_fn_c_try_cpp "$LINENO"; then :
16522
16523 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16524 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16525 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16526 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16527 if test -z "$tmp_exp" || test "$tmp_exp" = "_COMPILER_VERSION"; then
16528 tmp_exp=""
16529 fi
16530
16531fi
16532rm -f conftest.err conftest.i conftest.$ac_ext
16533 if test -z "$tmp_exp"; then
16534 curl_cv_have_def__COMPILER_VERSION=no
16535
16536 else
16537 curl_cv_have_def__COMPILER_VERSION=yes
16538 curl_cv_def__COMPILER_VERSION=$tmp_exp
16539
16540 fi
16541 CPPFLAGS=$OLDCPPFLAGS
16542
16543
16544 OLDCPPFLAGS=$CPPFLAGS
16545 # CPPPFLAG comes from CURL_CPP_P
16546 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16547 if test -z "$SED"; then
16548 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16549 fi
16550 if test -z "$GREP"; then
16551 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16552 fi
16553
16554 tmp_exp=""
16555 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16556/* end confdefs.h. */
16557
16558
16559#ifdef _SGI_COMPILER_VERSION
16560CURL_DEF_TOKEN _SGI_COMPILER_VERSION
16561#endif
16562
16563
16564_ACEOF
16565if ac_fn_c_try_cpp "$LINENO"; then :
16566
16567 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16568 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16569 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16570 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16571 if test -z "$tmp_exp" || test "$tmp_exp" = "_SGI_COMPILER_VERSION"; then
16572 tmp_exp=""
16573 fi
16574
16575fi
16576rm -f conftest.err conftest.i conftest.$ac_ext
16577 if test -z "$tmp_exp"; then
16578 curl_cv_have_def__SGI_COMPILER_VERSION=no
16579
16580 else
16581 curl_cv_have_def__SGI_COMPILER_VERSION=yes
16582 curl_cv_def__SGI_COMPILER_VERSION=$tmp_exp
16583
16584 fi
16585 CPPFLAGS=$OLDCPPFLAGS
16586
16587 if test "$curl_cv_have_def___GNUC__" = "no" &&
16588 (test "$curl_cv_have_def__SGI_COMPILER_VERSION" = "yes" ||
16589 test "$curl_cv_have_def__COMPILER_VERSION" = "yes"); then
16590 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16591$as_echo "yes" >&6; }
16592 compiler_id="SGI_MIPSPRO_C"
16593 flags_dbg_all="-g -g0 -g1 -g2 -g3"
16594 flags_dbg_yes="-g"
16595 flags_dbg_off=""
16596 flags_opt_all="-O -O0 -O1 -O2 -O3 -Ofast"
16597 flags_opt_yes="-O2"
16598 flags_opt_off="-O0"
16599 else
16600 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16601$as_echo "no" >&6; }
16602 fi
16603
16604
16605 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler is SGI MIPS C" >&5
16606$as_echo_n "checking if compiler is SGI MIPS C... " >&6; }
16607
16608 OLDCPPFLAGS=$CPPFLAGS
16609 # CPPPFLAG comes from CURL_CPP_P
16610 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16611 if test -z "$SED"; then
16612 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16613 fi
16614 if test -z "$GREP"; then
16615 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16616 fi
16617
16618 tmp_exp=""
16619 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16620/* end confdefs.h. */
16621
16622
16623#ifdef __GNUC__
16624CURL_DEF_TOKEN __GNUC__
16625#endif
16626
16627
16628_ACEOF
16629if ac_fn_c_try_cpp "$LINENO"; then :
16630
16631 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16632 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16633 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16634 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16635 if test -z "$tmp_exp" || test "$tmp_exp" = "__GNUC__"; then
16636 tmp_exp=""
16637 fi
16638
16639fi
16640rm -f conftest.err conftest.i conftest.$ac_ext
16641 if test -z "$tmp_exp"; then
16642 curl_cv_have_def___GNUC__=no
16643
16644 else
16645 curl_cv_have_def___GNUC__=yes
16646 curl_cv_def___GNUC__=$tmp_exp
16647
16648 fi
16649 CPPFLAGS=$OLDCPPFLAGS
16650
16651
16652 OLDCPPFLAGS=$CPPFLAGS
16653 # CPPPFLAG comes from CURL_CPP_P
16654 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16655 if test -z "$SED"; then
16656 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16657 fi
16658 if test -z "$GREP"; then
16659 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16660 fi
16661
16662 tmp_exp=""
16663 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16664/* end confdefs.h. */
16665
16666
16667#ifdef __sgi
16668CURL_DEF_TOKEN __sgi
16669#endif
16670
16671
16672_ACEOF
16673if ac_fn_c_try_cpp "$LINENO"; then :
16674
16675 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16676 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16677 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16678 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16679 if test -z "$tmp_exp" || test "$tmp_exp" = "__sgi"; then
16680 tmp_exp=""
16681 fi
16682
16683fi
16684rm -f conftest.err conftest.i conftest.$ac_ext
16685 if test -z "$tmp_exp"; then
16686 curl_cv_have_def___sgi=no
16687
16688 else
16689 curl_cv_have_def___sgi=yes
16690 curl_cv_def___sgi=$tmp_exp
16691
16692 fi
16693 CPPFLAGS=$OLDCPPFLAGS
16694
16695 if test "$curl_cv_have_def___GNUC__" = "no" &&
16696 test "$curl_cv_have_def___sgi" = "yes" &&
16697 test "$compiler_id" = "unknown"; then
16698 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16699$as_echo "yes" >&6; }
16700 compiler_id="SGI_MIPS_C"
16701 flags_dbg_all="-g -g0 -g1 -g2 -g3"
16702 flags_dbg_yes="-g"
16703 flags_dbg_off=""
16704 flags_opt_all="-O -O0 -O1 -O2 -O3 -Ofast"
16705 flags_opt_yes="-O2"
16706 flags_opt_off="-O0"
16707 else
16708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16709$as_echo "no" >&6; }
16710 fi
16711
16712
16713 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler is SunPro C" >&5
16714$as_echo_n "checking if compiler is SunPro C... " >&6; }
16715
16716 OLDCPPFLAGS=$CPPFLAGS
16717 # CPPPFLAG comes from CURL_CPP_P
16718 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16719 if test -z "$SED"; then
16720 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16721 fi
16722 if test -z "$GREP"; then
16723 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16724 fi
16725
16726 tmp_exp=""
16727 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16728/* end confdefs.h. */
16729
16730
16731#ifdef __SUNPRO_C
16732CURL_DEF_TOKEN __SUNPRO_C
16733#endif
16734
16735
16736_ACEOF
16737if ac_fn_c_try_cpp "$LINENO"; then :
16738
16739 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16740 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16741 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16742 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16743 if test -z "$tmp_exp" || test "$tmp_exp" = "__SUNPRO_C"; then
16744 tmp_exp=""
16745 fi
16746
16747fi
16748rm -f conftest.err conftest.i conftest.$ac_ext
16749 if test -z "$tmp_exp"; then
16750 curl_cv_have_def___SUNPRO_C=no
16751
16752 else
16753 curl_cv_have_def___SUNPRO_C=yes
16754 curl_cv_def___SUNPRO_C=$tmp_exp
16755
16756 fi
16757 CPPFLAGS=$OLDCPPFLAGS
16758
16759 if test "$curl_cv_have_def___SUNPRO_C" = "yes"; then
16760 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16761$as_echo "yes" >&6; }
16762 compiler_id="SUNPRO_C"
16763 flags_dbg_all="-g -s"
16764 flags_dbg_yes="-g"
16765 flags_dbg_off="-s"
16766 flags_opt_all="-O -xO -xO1 -xO2 -xO3 -xO4 -xO5"
16767 flags_opt_yes="-xO2"
16768 flags_opt_off=""
16769 else
16770 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16771$as_echo "no" >&6; }
16772 fi
16773
16774
16775 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler is Tiny C" >&5
16776$as_echo_n "checking if compiler is Tiny C... " >&6; }
16777
16778 OLDCPPFLAGS=$CPPFLAGS
16779 # CPPPFLAG comes from CURL_CPP_P
16780 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16781 if test -z "$SED"; then
16782 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16783 fi
16784 if test -z "$GREP"; then
16785 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16786 fi
16787
16788 tmp_exp=""
16789 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16790/* end confdefs.h. */
16791
16792
16793#ifdef __TINYC__
16794CURL_DEF_TOKEN __TINYC__
16795#endif
16796
16797
16798_ACEOF
16799if ac_fn_c_try_cpp "$LINENO"; then :
16800
16801 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16802 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16803 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16804 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16805 if test -z "$tmp_exp" || test "$tmp_exp" = "__TINYC__"; then
16806 tmp_exp=""
16807 fi
16808
16809fi
16810rm -f conftest.err conftest.i conftest.$ac_ext
16811 if test -z "$tmp_exp"; then
16812 curl_cv_have_def___TINYC__=no
16813
16814 else
16815 curl_cv_have_def___TINYC__=yes
16816 curl_cv_def___TINYC__=$tmp_exp
16817
16818 fi
16819 CPPFLAGS=$OLDCPPFLAGS
16820
16821 if test "$curl_cv_have_def___TINYC__" = "yes"; then
16822 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16823$as_echo "yes" >&6; }
16824 compiler_id="TINY_C"
16825 flags_dbg_all="-g -b"
16826 flags_dbg_yes="-g"
16827 flags_dbg_off=""
16828 flags_opt_all=""
16829 flags_opt_yes=""
16830 flags_opt_off=""
16831 else
16832 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16833$as_echo "no" >&6; }
16834 fi
16835
16836
16837 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler is Watcom C" >&5
16838$as_echo_n "checking if compiler is Watcom C... " >&6; }
16839
16840 OLDCPPFLAGS=$CPPFLAGS
16841 # CPPPFLAG comes from CURL_CPP_P
16842 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16843 if test -z "$SED"; then
16844 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16845 fi
16846 if test -z "$GREP"; then
16847 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16848 fi
16849
16850 tmp_exp=""
16851 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16852/* end confdefs.h. */
16853
16854
16855#ifdef __WATCOMC__
16856CURL_DEF_TOKEN __WATCOMC__
16857#endif
16858
16859
16860_ACEOF
16861if ac_fn_c_try_cpp "$LINENO"; then :
16862
16863 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16864 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16865 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16866 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16867 if test -z "$tmp_exp" || test "$tmp_exp" = "__WATCOMC__"; then
16868 tmp_exp=""
16869 fi
16870
16871fi
16872rm -f conftest.err conftest.i conftest.$ac_ext
16873 if test -z "$tmp_exp"; then
16874 curl_cv_have_def___WATCOMC__=no
16875
16876 else
16877 curl_cv_have_def___WATCOMC__=yes
16878 curl_cv_def___WATCOMC__=$tmp_exp
16879
16880 fi
16881 CPPFLAGS=$OLDCPPFLAGS
16882
16883 if test "$curl_cv_have_def___WATCOMC__" = "yes"; then
16884 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16885$as_echo "yes" >&6; }
16886
16887 OLDCPPFLAGS=$CPPFLAGS
16888 # CPPPFLAG comes from CURL_CPP_P
16889 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16890 if test -z "$SED"; then
16891 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16892 fi
16893 if test -z "$GREP"; then
16894 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16895 fi
16896
16897 tmp_exp=""
16898 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16899/* end confdefs.h. */
16900
16901
16902#ifdef __UNIX__
16903CURL_DEF_TOKEN __UNIX__
16904#endif
16905
16906
16907_ACEOF
16908if ac_fn_c_try_cpp "$LINENO"; then :
16909
16910 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16911 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16912 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16913 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16914 if test -z "$tmp_exp" || test "$tmp_exp" = "__UNIX__"; then
16915 tmp_exp=""
16916 fi
16917
16918fi
16919rm -f conftest.err conftest.i conftest.$ac_ext
16920 if test -z "$tmp_exp"; then
16921 curl_cv_have_def___UNIX__=no
16922
16923 else
16924 curl_cv_have_def___UNIX__=yes
16925 curl_cv_def___UNIX__=$tmp_exp
16926
16927 fi
16928 CPPFLAGS=$OLDCPPFLAGS
16929
16930 if test "$curl_cv_have_def___UNIX__" = "yes"; then
16931 compiler_id="WATCOM_UNIX_C"
16932 flags_dbg_all="-g1 -g1+ -g2 -g3"
16933 flags_dbg_yes="-g2"
16934 flags_dbg_off=""
16935 flags_opt_all="-O0 -O1 -O2 -O3"
16936 flags_opt_yes="-O2"
16937 flags_opt_off="-O0"
16938 else
16939 compiler_id="WATCOM_WINDOWS_C"
16940 flags_dbg_all=""
16941 flags_dbg_yes=""
16942 flags_dbg_off=""
16943 flags_opt_all=""
16944 flags_opt_yes=""
16945 flags_opt_off=""
16946 fi
16947 else
16948 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16949$as_echo "no" >&6; }
16950 fi
16951
16952 #
16953 if test "$compiler_id" = "unknown"; then
16954 cat <<_EOF 1>&2
16955***
16956*** Warning: This configure script does not have information about the
16957*** compiler you are using, relative to the flags required to enable or
16958*** disable generation of debug info, optimization options or warnings.
16959***
16960*** Whatever settings are present in CFLAGS will be used for this run.
16961***
16962*** If you wish to help the curl project to better support your compiler
16963*** you can report this and the required info on the libcurl development
16964*** mailing list: https://cool.haxx.se/mailman/listinfo/curl-library/
16965***
16966_EOF
16967 fi
16968
16969
16970squeeze() {
16971 _sqz_result=""
16972 eval _sqz_input=\$$1
16973 for _sqz_token in $_sqz_input; do
16974 if test -z "$_sqz_result"; then
16975 _sqz_result="$_sqz_token"
16976 else
16977 _sqz_result="$_sqz_result $_sqz_token"
16978 fi
16979 done
16980 eval $1=\$_sqz_result
16981 return 0
16982}
16983
16984
16985 #
16986 if test "$compiler_id" != "unknown"; then
16987 #
16988 if test "$compiler_id" = "GNU_C" ||
16989 test "$compiler_id" = "CLANG"; then
16990
16991 if test "$compiler_id" = "GNU_C" ||
16992 test "$compiler_id" = "CLANG"; then
16993 tmp_has_include="no"
16994 tmp_chg_FLAGS="$CFLAGS"
16995 for word1 in $tmp_chg_FLAGS; do
16996 case "$word1" in
16997 -I*)
16998 tmp_has_include="yes"
16999 ;;
17000 esac
17001 done
17002 if test "$tmp_has_include" = "yes"; then
17003 tmp_chg_FLAGS=`echo "$tmp_chg_FLAGS" | "$SED" 's/^-I/ -isystem /g'`
17004 tmp_chg_FLAGS=`echo "$tmp_chg_FLAGS" | "$SED" 's/ -I/ -isystem /g'`
17005 CFLAGS="$tmp_chg_FLAGS"
17006 squeeze CFLAGS
17007 fi
17008 tmp_has_include="no"
17009 tmp_chg_FLAGS="$CPPFLAGS"
17010 for word1 in $tmp_chg_FLAGS; do
17011 case "$word1" in
17012 -I*)
17013 tmp_has_include="yes"
17014 ;;
17015 esac
17016 done
17017 if test "$tmp_has_include" = "yes"; then
17018 tmp_chg_FLAGS=`echo "$tmp_chg_FLAGS" | "$SED" 's/^-I/ -isystem /g'`
17019 tmp_chg_FLAGS=`echo "$tmp_chg_FLAGS" | "$SED" 's/ -I/ -isystem /g'`
17020 CPPFLAGS="$tmp_chg_FLAGS"
17021 squeeze CPPFLAGS
17022 fi
17023 fi
17024
17025 fi
17026 #
17027 tmp_save_CPPFLAGS="$CPPFLAGS"
17028 tmp_save_CFLAGS="$CFLAGS"
17029 tmp_CPPFLAGS=""
17030 tmp_CFLAGS=""
17031 #
17032 case "$compiler_id" in
17033 #
17034 CLANG)
17035 #
17036 tmp_CFLAGS="$tmp_CFLAGS -Qunused-arguments"
17037 ;;
17038 #
17039 DEC_C)
17040 #
17041 tmp_CFLAGS="$tmp_CFLAGS -std1"
17042 tmp_CFLAGS="$tmp_CFLAGS -noansi_alias"
17043 tmp_CFLAGS="$tmp_CFLAGS -warnprotos"
17044 tmp_CFLAGS="$tmp_CFLAGS -msg_fatal toofewargs,toomanyargs"
17045 ;;
17046 #
17047 GNU_C)
17048 #
17049 if test "$compiler_num" -ge "295"; then
17050 tmp_CFLAGS="$tmp_CFLAGS -Werror-implicit-function-declaration"
17051 fi
17052 ;;
17053 #
17054 HP_UX_C)
17055 #
17056 tmp_CFLAGS="$tmp_CFLAGS -z"
17057 tmp_CFLAGS="$tmp_CFLAGS +W 4227,4255"
17058 ;;
17059 #
17060 IBM_C)
17061 #
17062 tmp_CPPFLAGS="$tmp_CPPFLAGS -qthreaded"
17063 tmp_CPPFLAGS="$tmp_CPPFLAGS -qnoansialias"
17064 tmp_CPPFLAGS="$tmp_CPPFLAGS -qhalt=e"
17065 ;;
17066 #
17067 INTEL_UNIX_C)
17068 #
17069 tmp_CFLAGS="$tmp_CFLAGS -std=gnu89"
17070 tmp_CPPFLAGS="$tmp_CPPFLAGS -we140,147,165,266"
17071 tmp_CPPFLAGS="$tmp_CPPFLAGS -wd279,981,1469"
17072 ;;
17073 #
17074 INTEL_WINDOWS_C)
17075 #
17076 tmp_CFLAGS="$tmp_CFLAGS"
17077 ;;
17078 #
17079 LCC)
17080 #
17081 tmp_CFLAGS="$tmp_CFLAGS -n"
17082 ;;
17083 #
17084 SGI_MIPS_C)
17085 #
17086 tmp_CFLAGS="$tmp_CFLAGS"
17087 ;;
17088 #
17089 SGI_MIPSPRO_C)
17090 #
17091 tmp_CFLAGS="$tmp_CFLAGS"
17092 ;;
17093 #
17094 SUNPRO_C)
17095 #
17096 tmp_CFLAGS="$tmp_CFLAGS"
17097 ;;
17098 #
17099 TINY_C)
17100 #
17101 tmp_CFLAGS="$tmp_CFLAGS"
17102 ;;
17103 #
17104 WATCOM_UNIX_C)
17105 #
17106 tmp_CFLAGS="$tmp_CFLAGS"
17107 ;;
17108 #
17109 WATCOM_WINDOWS_C)
17110 #
17111 tmp_CFLAGS="$tmp_CFLAGS"
17112 ;;
17113 #
17114 esac
17115 #
17116 squeeze tmp_CPPFLAGS
17117 squeeze tmp_CFLAGS
17118 #
17119 if test ! -z "$tmp_CFLAGS" || test ! -z "$tmp_CPPFLAGS"; then
17120 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler accepts some basic options" >&5
17121$as_echo_n "checking if compiler accepts some basic options... " >&6; }
17122 CPPFLAGS="$tmp_save_CPPFLAGS $tmp_CPPFLAGS"
17123 CFLAGS="$tmp_save_CFLAGS $tmp_CFLAGS"
17124 squeeze CPPFLAGS
17125 squeeze CFLAGS
17126
17127 tmp_compiler_works="unknown"
17128 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17129/* end confdefs.h. */
17130
17131
17132
17133int main (void)
17134{
17135
17136 int i = 1;
17137 return i;
17138
17139 ;
17140 return 0;
17141}
17142
17143_ACEOF
17144if ac_fn_c_try_compile "$LINENO"; then :
17145
17146 tmp_compiler_works="yes"
17147
17148else
17149
17150 tmp_compiler_works="no"
17151 echo " " >&6
17152 sed 's/^/cc-fail: /' conftest.err >&6
17153 echo " " >&6
17154
17155fi
17156rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17157 if test "$tmp_compiler_works" = "yes"; then
17158 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17159/* end confdefs.h. */
17160
17161
17162
17163int main (void)
17164{
17165
17166 int i = 1;
17167 return i;
17168
17169 ;
17170 return 0;
17171}
17172
17173_ACEOF
17174if ac_fn_c_try_link "$LINENO"; then :
17175
17176 tmp_compiler_works="yes"
17177
17178else
17179
17180 tmp_compiler_works="no"
17181 echo " " >&6
17182 sed 's/^/link-fail: /' conftest.err >&6
17183 echo " " >&6
17184
17185fi
17186rm -f core conftest.err conftest.$ac_objext \
17187 conftest$ac_exeext conftest.$ac_ext
17188 fi
17189 if test "x$cross_compiling" != "xyes" &&
17190 test "$tmp_compiler_works" = "yes"; then
Elliott Hughesa93fb052018-12-12 14:22:48 -080017191
17192
17193 old=$LD_LIBRARY_PATH
17194 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
17195 export LD_LIBRARY_PATH
17196 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070017197 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17198$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17199as_fn_error $? "cannot run test program while cross compiling
17200See \`config.log' for more details" "$LINENO" 5; }
17201else
17202 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17203/* end confdefs.h. */
17204
17205
17206# ifdef __STDC__
17207# include <stdlib.h>
17208# endif
17209
17210int main (void)
17211{
17212
17213 int i = 0;
17214 exit(i);
17215
17216 ;
17217 return 0;
17218}
17219
17220_ACEOF
17221if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughesa93fb052018-12-12 14:22:48 -080017222 tmp_compiler_works="yes"
Elliott Hughes82be86d2017-09-20 17:00:17 -070017223
17224else
Elliott Hughesa93fb052018-12-12 14:22:48 -080017225 tmp_compiler_works="no"
Elliott Hughes82be86d2017-09-20 17:00:17 -070017226 echo " " >&6
17227 echo "run-fail: test program exited with status $ac_status" >&6
17228 echo " " >&6
17229
17230fi
17231rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17232 conftest.$ac_objext conftest.beam conftest.$ac_ext
17233fi
17234
Elliott Hughesa93fb052018-12-12 14:22:48 -080017235 LD_LIBRARY_PATH=$old # restore
17236
Elliott Hughes82be86d2017-09-20 17:00:17 -070017237 fi
17238 if test "$tmp_compiler_works" = "yes"; then
17239
17240 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17241$as_echo "yes" >&6; }
17242 { $as_echo "$as_me:${as_lineno-$LINENO}: compiler options added: $tmp_CFLAGS $tmp_CPPFLAGS" >&5
17243$as_echo "$as_me: compiler options added: $tmp_CFLAGS $tmp_CPPFLAGS" >&6;}
17244
17245 else
17246
17247 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17248$as_echo "no" >&6; }
17249 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: compiler options rejected: $tmp_CFLAGS $tmp_CPPFLAGS" >&5
17250$as_echo "$as_me: WARNING: compiler options rejected: $tmp_CFLAGS $tmp_CPPFLAGS" >&2;}
17251 CPPFLAGS="$tmp_save_CPPFLAGS"
17252 CFLAGS="$tmp_save_CFLAGS"
17253
17254 fi
17255
17256 fi
17257 #
17258 fi
17259
17260
17261 #
17262 if test "$compiler_id" != "unknown"; then
17263 #
17264 tmp_save_CFLAGS="$CFLAGS"
17265 tmp_save_CPPFLAGS="$CPPFLAGS"
17266 #
17267 tmp_options=""
17268 tmp_CFLAGS="$CFLAGS"
17269 tmp_CPPFLAGS="$CPPFLAGS"
17270
17271 ac_var_stripped=""
17272 for word1 in $tmp_CFLAGS; do
17273 ac_var_strip_word="no"
17274 for word2 in $flags_dbg_all; do
17275 if test "$word1" = "$word2"; then
17276 ac_var_strip_word="yes"
17277 fi
17278 done
17279 if test "$ac_var_strip_word" = "no"; then
17280 ac_var_stripped="$ac_var_stripped $word1"
17281 fi
17282 done
17283 tmp_CFLAGS="$ac_var_stripped"
17284 squeeze tmp_CFLAGS
17285
17286
17287 ac_var_stripped=""
17288 for word1 in $tmp_CPPFLAGS; do
17289 ac_var_strip_word="no"
17290 for word2 in $flags_dbg_all; do
17291 if test "$word1" = "$word2"; then
17292 ac_var_strip_word="yes"
17293 fi
17294 done
17295 if test "$ac_var_strip_word" = "no"; then
17296 ac_var_stripped="$ac_var_stripped $word1"
17297 fi
17298 done
17299 tmp_CPPFLAGS="$ac_var_stripped"
17300 squeeze tmp_CPPFLAGS
17301
17302 #
17303 if test "$want_debug" = "yes"; then
17304 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler accepts debug enabling options" >&5
17305$as_echo_n "checking if compiler accepts debug enabling options... " >&6; }
17306 tmp_options="$flags_dbg_yes"
17307 fi
17308 if test "$want_debug" = "no"; then
17309 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler accepts debug disabling options" >&5
17310$as_echo_n "checking if compiler accepts debug disabling options... " >&6; }
17311 tmp_options="$flags_dbg_off"
17312 fi
17313 #
17314 if test "$flags_prefer_cppflags" = "yes"; then
17315 CPPFLAGS="$tmp_CPPFLAGS $tmp_options"
17316 CFLAGS="$tmp_CFLAGS"
17317 else
17318 CPPFLAGS="$tmp_CPPFLAGS"
17319 CFLAGS="$tmp_CFLAGS $tmp_options"
17320 fi
17321 squeeze CPPFLAGS
17322 squeeze CFLAGS
17323
17324 tmp_compiler_works="unknown"
17325 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17326/* end confdefs.h. */
17327
17328
17329
17330int main (void)
17331{
17332
17333 int i = 1;
17334 return i;
17335
17336 ;
17337 return 0;
17338}
17339
17340_ACEOF
17341if ac_fn_c_try_compile "$LINENO"; then :
17342
17343 tmp_compiler_works="yes"
17344
17345else
17346
17347 tmp_compiler_works="no"
17348 echo " " >&6
17349 sed 's/^/cc-fail: /' conftest.err >&6
17350 echo " " >&6
17351
17352fi
17353rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17354 if test "$tmp_compiler_works" = "yes"; then
17355 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17356/* end confdefs.h. */
17357
17358
17359
17360int main (void)
17361{
17362
17363 int i = 1;
17364 return i;
17365
17366 ;
17367 return 0;
17368}
17369
17370_ACEOF
17371if ac_fn_c_try_link "$LINENO"; then :
17372
17373 tmp_compiler_works="yes"
17374
17375else
17376
17377 tmp_compiler_works="no"
17378 echo " " >&6
17379 sed 's/^/link-fail: /' conftest.err >&6
17380 echo " " >&6
17381
17382fi
17383rm -f core conftest.err conftest.$ac_objext \
17384 conftest$ac_exeext conftest.$ac_ext
17385 fi
17386 if test "x$cross_compiling" != "xyes" &&
17387 test "$tmp_compiler_works" = "yes"; then
Elliott Hughesa93fb052018-12-12 14:22:48 -080017388
17389
17390 old=$LD_LIBRARY_PATH
17391 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
17392 export LD_LIBRARY_PATH
17393 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070017394 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17395$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17396as_fn_error $? "cannot run test program while cross compiling
17397See \`config.log' for more details" "$LINENO" 5; }
17398else
17399 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17400/* end confdefs.h. */
17401
17402
17403# ifdef __STDC__
17404# include <stdlib.h>
17405# endif
17406
17407int main (void)
17408{
17409
17410 int i = 0;
17411 exit(i);
17412
17413 ;
17414 return 0;
17415}
17416
17417_ACEOF
17418if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughesa93fb052018-12-12 14:22:48 -080017419 tmp_compiler_works="yes"
Elliott Hughes82be86d2017-09-20 17:00:17 -070017420
17421else
Elliott Hughesa93fb052018-12-12 14:22:48 -080017422 tmp_compiler_works="no"
Elliott Hughes82be86d2017-09-20 17:00:17 -070017423 echo " " >&6
17424 echo "run-fail: test program exited with status $ac_status" >&6
17425 echo " " >&6
17426
17427fi
17428rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17429 conftest.$ac_objext conftest.beam conftest.$ac_ext
17430fi
17431
Elliott Hughesa93fb052018-12-12 14:22:48 -080017432 LD_LIBRARY_PATH=$old # restore
17433
Elliott Hughes82be86d2017-09-20 17:00:17 -070017434 fi
17435 if test "$tmp_compiler_works" = "yes"; then
17436
17437 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17438$as_echo "yes" >&6; }
17439 { $as_echo "$as_me:${as_lineno-$LINENO}: compiler options added: $tmp_options" >&5
17440$as_echo "$as_me: compiler options added: $tmp_options" >&6;}
17441
17442 else
17443
17444 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17445$as_echo "no" >&6; }
17446 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: compiler options rejected: $tmp_options" >&5
17447$as_echo "$as_me: WARNING: compiler options rejected: $tmp_options" >&2;}
17448 CPPFLAGS="$tmp_save_CPPFLAGS"
17449 CFLAGS="$tmp_save_CFLAGS"
17450
17451 fi
17452
17453 #
17454 fi
17455
17456
17457 #
17458 if test "$compiler_id" != "unknown"; then
17459 #
17460 tmp_save_CFLAGS="$CFLAGS"
17461 tmp_save_CPPFLAGS="$CPPFLAGS"
17462 #
17463 tmp_options=""
17464 tmp_CFLAGS="$CFLAGS"
17465 tmp_CPPFLAGS="$CPPFLAGS"
17466 honor_optimize_option="yes"
17467 #
17468 #
17469 if test "$want_optimize" = "assume_no" ||
17470 test "$want_optimize" = "assume_yes"; then
17471 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler optimizer assumed setting might be used" >&5
17472$as_echo_n "checking if compiler optimizer assumed setting might be used... " >&6; }
17473
17474
17475 ac_var_match_word="no"
17476 for word1 in $tmp_CFLAGS; do
17477 for word2 in $flags_opt_all; do
17478 if test "$word1" = "$word2"; then
17479 ac_var_match_word="yes"
17480 fi
17481 done
17482 done
17483
17484 if test "$ac_var_match_word" = "yes"; then
17485
17486 honor_optimize_option="no"
17487
17488
17489 fi
17490
17491
17492
17493 ac_var_match_word="no"
17494 for word1 in $tmp_CPPFLAGS; do
17495 for word2 in $flags_opt_all; do
17496 if test "$word1" = "$word2"; then
17497 ac_var_match_word="yes"
17498 fi
17499 done
17500 done
17501
17502 if test "$ac_var_match_word" = "yes"; then
17503
17504 honor_optimize_option="no"
17505
17506
17507 fi
17508
17509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $honor_optimize_option" >&5
17510$as_echo "$honor_optimize_option" >&6; }
17511 if test "$honor_optimize_option" = "yes"; then
17512 if test "$want_optimize" = "assume_yes"; then
17513 want_optimize="yes"
17514 fi
17515 if test "$want_optimize" = "assume_no"; then
17516 want_optimize="no"
17517 fi
17518 fi
17519 fi
17520 #
17521 if test "$honor_optimize_option" = "yes"; then
17522
17523 ac_var_stripped=""
17524 for word1 in $tmp_CFLAGS; do
17525 ac_var_strip_word="no"
17526 for word2 in $flags_opt_all; do
17527 if test "$word1" = "$word2"; then
17528 ac_var_strip_word="yes"
17529 fi
17530 done
17531 if test "$ac_var_strip_word" = "no"; then
17532 ac_var_stripped="$ac_var_stripped $word1"
17533 fi
17534 done
17535 tmp_CFLAGS="$ac_var_stripped"
17536 squeeze tmp_CFLAGS
17537
17538
17539 ac_var_stripped=""
17540 for word1 in $tmp_CPPFLAGS; do
17541 ac_var_strip_word="no"
17542 for word2 in $flags_opt_all; do
17543 if test "$word1" = "$word2"; then
17544 ac_var_strip_word="yes"
17545 fi
17546 done
17547 if test "$ac_var_strip_word" = "no"; then
17548 ac_var_stripped="$ac_var_stripped $word1"
17549 fi
17550 done
17551 tmp_CPPFLAGS="$ac_var_stripped"
17552 squeeze tmp_CPPFLAGS
17553
17554 if test "$want_optimize" = "yes"; then
17555 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler accepts optimizer enabling options" >&5
17556$as_echo_n "checking if compiler accepts optimizer enabling options... " >&6; }
17557 tmp_options="$flags_opt_yes"
17558 fi
17559 if test "$want_optimize" = "no"; then
17560 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler accepts optimizer disabling options" >&5
17561$as_echo_n "checking if compiler accepts optimizer disabling options... " >&6; }
17562 tmp_options="$flags_opt_off"
17563 fi
17564 if test "$flags_prefer_cppflags" = "yes"; then
17565 CPPFLAGS="$tmp_CPPFLAGS $tmp_options"
17566 CFLAGS="$tmp_CFLAGS"
17567 else
17568 CPPFLAGS="$tmp_CPPFLAGS"
17569 CFLAGS="$tmp_CFLAGS $tmp_options"
17570 fi
17571 squeeze CPPFLAGS
17572 squeeze CFLAGS
17573
17574 tmp_compiler_works="unknown"
17575 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17576/* end confdefs.h. */
17577
17578
17579
17580int main (void)
17581{
17582
17583 int i = 1;
17584 return i;
17585
17586 ;
17587 return 0;
17588}
17589
17590_ACEOF
17591if ac_fn_c_try_compile "$LINENO"; then :
17592
17593 tmp_compiler_works="yes"
17594
17595else
17596
17597 tmp_compiler_works="no"
17598 echo " " >&6
17599 sed 's/^/cc-fail: /' conftest.err >&6
17600 echo " " >&6
17601
17602fi
17603rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17604 if test "$tmp_compiler_works" = "yes"; then
17605 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17606/* end confdefs.h. */
17607
17608
17609
17610int main (void)
17611{
17612
17613 int i = 1;
17614 return i;
17615
17616 ;
17617 return 0;
17618}
17619
17620_ACEOF
17621if ac_fn_c_try_link "$LINENO"; then :
17622
17623 tmp_compiler_works="yes"
17624
17625else
17626
17627 tmp_compiler_works="no"
17628 echo " " >&6
17629 sed 's/^/link-fail: /' conftest.err >&6
17630 echo " " >&6
17631
17632fi
17633rm -f core conftest.err conftest.$ac_objext \
17634 conftest$ac_exeext conftest.$ac_ext
17635 fi
17636 if test "x$cross_compiling" != "xyes" &&
17637 test "$tmp_compiler_works" = "yes"; then
Elliott Hughesa93fb052018-12-12 14:22:48 -080017638
17639
17640 old=$LD_LIBRARY_PATH
17641 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
17642 export LD_LIBRARY_PATH
17643 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070017644 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17645$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17646as_fn_error $? "cannot run test program while cross compiling
17647See \`config.log' for more details" "$LINENO" 5; }
17648else
17649 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17650/* end confdefs.h. */
17651
17652
17653# ifdef __STDC__
17654# include <stdlib.h>
17655# endif
17656
17657int main (void)
17658{
17659
17660 int i = 0;
17661 exit(i);
17662
17663 ;
17664 return 0;
17665}
17666
17667_ACEOF
17668if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughesa93fb052018-12-12 14:22:48 -080017669 tmp_compiler_works="yes"
Elliott Hughes82be86d2017-09-20 17:00:17 -070017670
17671else
Elliott Hughesa93fb052018-12-12 14:22:48 -080017672 tmp_compiler_works="no"
Elliott Hughes82be86d2017-09-20 17:00:17 -070017673 echo " " >&6
17674 echo "run-fail: test program exited with status $ac_status" >&6
17675 echo " " >&6
17676
17677fi
17678rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17679 conftest.$ac_objext conftest.beam conftest.$ac_ext
17680fi
17681
Elliott Hughesa93fb052018-12-12 14:22:48 -080017682 LD_LIBRARY_PATH=$old # restore
17683
Elliott Hughes82be86d2017-09-20 17:00:17 -070017684 fi
17685 if test "$tmp_compiler_works" = "yes"; then
17686
17687 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17688$as_echo "yes" >&6; }
17689 { $as_echo "$as_me:${as_lineno-$LINENO}: compiler options added: $tmp_options" >&5
17690$as_echo "$as_me: compiler options added: $tmp_options" >&6;}
17691
17692 else
17693
17694 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17695$as_echo "no" >&6; }
17696 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: compiler options rejected: $tmp_options" >&5
17697$as_echo "$as_me: WARNING: compiler options rejected: $tmp_options" >&2;}
17698 CPPFLAGS="$tmp_save_CPPFLAGS"
17699 CFLAGS="$tmp_save_CFLAGS"
17700
17701 fi
17702
17703 fi
17704 #
17705 fi
17706
17707
17708 #
17709 if test "$compiler_id" != "unknown"; then
17710 #
17711 tmp_save_CPPFLAGS="$CPPFLAGS"
17712 tmp_save_CFLAGS="$CFLAGS"
17713 tmp_CPPFLAGS=""
17714 tmp_CFLAGS=""
17715 #
17716 case "$compiler_id" in
17717 #
17718 CLANG)
17719 #
17720 if test "$want_warnings" = "yes"; then
17721 tmp_CFLAGS="$tmp_CFLAGS -pedantic"
17722 tmp_CFLAGS="$tmp_CFLAGS -Wall -Wextra"
17723 tmp_CFLAGS="$tmp_CFLAGS -Wpointer-arith -Wwrite-strings"
17724 tmp_CFLAGS="$tmp_CFLAGS -Wshadow"
17725 tmp_CFLAGS="$tmp_CFLAGS -Winline -Wnested-externs"
17726 tmp_CFLAGS="$tmp_CFLAGS -Wmissing-declarations"
17727 tmp_CFLAGS="$tmp_CFLAGS -Wmissing-prototypes"
17728 tmp_CFLAGS="$tmp_CFLAGS -Wno-long-long"
17729 tmp_CFLAGS="$tmp_CFLAGS -Wfloat-equal"
17730 tmp_CFLAGS="$tmp_CFLAGS -Wno-multichar -Wsign-compare"
17731 tmp_CFLAGS="$tmp_CFLAGS -Wundef"
17732 tmp_CFLAGS="$tmp_CFLAGS -Wno-format-nonliteral"
17733 tmp_CFLAGS="$tmp_CFLAGS -Wendif-labels -Wstrict-prototypes"
17734 tmp_CFLAGS="$tmp_CFLAGS -Wdeclaration-after-statement"
17735 tmp_CFLAGS="$tmp_CFLAGS -Wcast-align"
17736 tmp_CFLAGS="$tmp_CFLAGS -Wno-system-headers"
17737 tmp_CFLAGS="$tmp_CFLAGS -Wshorten-64-to-32"
17738 #
17739 if test "$compiler_num" -ge "101"; then
17740 tmp_CFLAGS="$tmp_CFLAGS -Wunused"
17741 fi
17742 #
17743 if test "$compiler_num" -ge "208"; then
17744 tmp_CFLAGS="$tmp_CFLAGS -Wvla"
17745 fi
17746 #
17747 if test "$compiler_num" -ge "209"; then
17748 tmp_CFLAGS="$tmp_CFLAGS -Wshift-sign-overflow"
17749 fi
17750 #
17751 if test "$compiler_num" -ge "302"; then
17752 case $host_os in
17753 cygwin* | mingw*)
17754 ;;
17755 *)
17756 tmp_CFLAGS="$tmp_CFLAGS -Wmissing-variable-declarations"
17757 ;;
17758 esac
17759 fi
17760 #
17761 if test "$compiler_num" -ge "306"; then
17762 tmp_CFLAGS="$tmp_CFLAGS -Wdouble-promotion"
17763 fi
17764 #
17765 if test "$compiler_num" -ge "309"; then
17766 tmp_CFLAGS="$tmp_CFLAGS -Wcomma"
Alex Deymo486467e2017-12-19 19:04:07 +010017767 # avoid the varargs warning, fixed in 4.0
17768 # https://bugs.llvm.org/show_bug.cgi?id=29140
17769 if test "$compiler_num" -lt "400"; then
17770 tmp_CFLAGS="$tmp_CFLAGS -Wno-varargs"
17771 fi
Elliott Hughes82be86d2017-09-20 17:00:17 -070017772 fi
17773 fi
17774 ;;
17775 #
17776 DEC_C)
17777 #
17778 if test "$want_warnings" = "yes"; then
17779 tmp_CFLAGS="$tmp_CFLAGS -msg_enable level3"
17780 fi
17781 ;;
17782 #
17783 GNU_C)
17784 #
17785 if test "$want_warnings" = "yes"; then
17786 #
17787 if test "x$cross_compiling" != "xyes" ||
17788 test "$compiler_num" -ge "300"; then
17789 tmp_CFLAGS="$tmp_CFLAGS -pedantic"
17790 fi
17791 #
17792 tmp_CFLAGS="$tmp_CFLAGS -Wall -W"
17793 #
17794 if test "$compiler_num" -ge "104"; then
17795 tmp_CFLAGS="$tmp_CFLAGS -Wpointer-arith -Wwrite-strings"
17796 if test "x$cross_compiling" != "xyes" ||
17797 test "$compiler_num" -ge "300"; then
17798 tmp_CFLAGS="$tmp_CFLAGS -Wunused -Wshadow"
17799 fi
17800 fi
17801 #
17802 if test "$compiler_num" -ge "207"; then
17803 tmp_CFLAGS="$tmp_CFLAGS -Winline -Wnested-externs"
17804 if test "x$cross_compiling" != "xyes" ||
17805 test "$compiler_num" -ge "300"; then
17806 tmp_CFLAGS="$tmp_CFLAGS -Wmissing-declarations"
17807 tmp_CFLAGS="$tmp_CFLAGS -Wmissing-prototypes"
17808 fi
17809 fi
17810 #
17811 if test "$compiler_num" -ge "295"; then
17812 tmp_CFLAGS="$tmp_CFLAGS -Wno-long-long"
Elliott Hughesb1ef70f2018-10-30 11:28:38 -070017813 tmp_CFLAGS="$tmp_CFLAGS -Wbad-function-cast"
Elliott Hughes82be86d2017-09-20 17:00:17 -070017814 fi
17815 #
17816 if test "$compiler_num" -ge "296"; then
17817 tmp_CFLAGS="$tmp_CFLAGS -Wfloat-equal"
17818 tmp_CFLAGS="$tmp_CFLAGS -Wno-multichar -Wsign-compare"
17819 tmp_CFLAGS="$tmp_CFLAGS -Wundef"
17820 fi
17821 #
17822 if test "$compiler_num" -ge "297"; then
17823 tmp_CFLAGS="$tmp_CFLAGS -Wno-format-nonliteral"
17824 fi
17825 #
17826 if test "$compiler_num" -ge "300"; then
17827 tmp_CFLAGS="$tmp_CFLAGS"
17828 fi
17829 #
17830 if test "$compiler_num" -ge "303"; then
17831 tmp_CFLAGS="$tmp_CFLAGS -Wendif-labels -Wstrict-prototypes"
17832 fi
17833 #
17834 if test "$compiler_num" -ge "304"; then
17835 tmp_CFLAGS="$tmp_CFLAGS -Wdeclaration-after-statement"
Elliott Hughesb1ef70f2018-10-30 11:28:38 -070017836 tmp_CFLAGS="$tmp_CFLAGS -Wold-style-definition"
Elliott Hughes82be86d2017-09-20 17:00:17 -070017837 fi
17838 #
17839 if test "$compiler_num" -ge "400"; then
17840 tmp_CFLAGS="$tmp_CFLAGS -Wstrict-aliasing=3"
17841 fi
17842 #
17843 if test "$compiler_num" -ge "402"; then
17844 tmp_CFLAGS="$tmp_CFLAGS -Wcast-align"
17845 fi
17846 #
17847 if test "$compiler_num" -ge "403"; then
17848 tmp_CFLAGS="$tmp_CFLAGS -Wtype-limits -Wold-style-declaration"
17849 tmp_CFLAGS="$tmp_CFLAGS -Wmissing-parameter-type -Wempty-body"
17850 tmp_CFLAGS="$tmp_CFLAGS -Wclobbered -Wignored-qualifiers"
17851 tmp_CFLAGS="$tmp_CFLAGS -Wconversion -Wno-sign-conversion -Wvla"
Elliott Hughesb1ef70f2018-10-30 11:28:38 -070017852 tmp_CFLAGS="$tmp_CFLAGS -ftree-vrp"
Elliott Hughes82be86d2017-09-20 17:00:17 -070017853 fi
17854 #
17855 if test "$compiler_num" -ge "405"; then
17856 if test "$curl_cv_have_def__WIN32" = "yes"; then
17857 tmp_CFLAGS="$tmp_CFLAGS -Wno-pedantic-ms-format"
17858 fi
17859 fi
17860 #
17861 if test "$compiler_num" -ge "406"; then
17862 tmp_CFLAGS="$tmp_CFLAGS -Wdouble-promotion"
17863 fi
17864 #
Elliott Hughesb1ef70f2018-10-30 11:28:38 -070017865 if test "$compiler_num" -ge "408"; then
17866 tmp_CFLAGS="$tmp_CFLAGS -Wformat=2"
17867 fi
17868 #
17869 if test "$compiler_num" -ge "500"; then
17870 tmp_CFLAGS="$tmp_CFLAGS -Warray-bounds=2"
17871 fi
17872 #
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070017873 if test "$compiler_num" -ge "600"; then
17874 tmp_CFLAGS="$tmp_CFLAGS -Wshift-negative-value"
17875 tmp_CFLAGS="$tmp_CFLAGS -Wshift-overflow=2"
Elliott Hughesb1ef70f2018-10-30 11:28:38 -070017876 tmp_CFLAGS="$tmp_CFLAGS -Wnull-dereference -fdelete-null-pointer-checks"
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070017877 tmp_CFLAGS="$tmp_CFLAGS -Wduplicated-cond"
Elliott Hughesb1ef70f2018-10-30 11:28:38 -070017878 tmp_CFLAGS="$tmp_CFLAGS -Wunused-const-variable"
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070017879 fi
17880 #
17881 if test "$compiler_num" -ge "700"; then
17882 tmp_CFLAGS="$tmp_CFLAGS -Wduplicated-branches"
17883 tmp_CFLAGS="$tmp_CFLAGS -Wrestrict"
17884 tmp_CFLAGS="$tmp_CFLAGS -Walloc-zero"
17885 tmp_CFLAGS="$tmp_CFLAGS -Wformat-overflow=2"
17886 tmp_CFLAGS="$tmp_CFLAGS -Wformat-truncation=2"
Elliott Hughesb1ef70f2018-10-30 11:28:38 -070017887 tmp_CFLAGS="$tmp_CFLAGS -Wimplicit-fallthrough=4"
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070017888 fi
17889 #
Elliott Hughes82be86d2017-09-20 17:00:17 -070017890 fi
17891 #
17892 if test "$compiler_num" -ge "300"; then
17893 tmp_CFLAGS="$tmp_CFLAGS -Wno-system-headers"
17894 else
17895 if test "x$cross_compiling" = "xyes"; then
17896 if test "$compiler_num" -ge "104"; then
17897 tmp_CFLAGS="$tmp_CFLAGS -Wno-unused -Wno-shadow"
17898 fi
17899 if test "$compiler_num" -ge "207"; then
17900 tmp_CFLAGS="$tmp_CFLAGS -Wno-missing-declarations"
17901 tmp_CFLAGS="$tmp_CFLAGS -Wno-missing-prototypes"
17902 fi
17903 fi
17904 fi
17905 ;;
17906 #
17907 HP_UX_C)
17908 #
17909 if test "$want_warnings" = "yes"; then
17910 tmp_CFLAGS="$tmp_CFLAGS +w1"
17911 fi
17912 ;;
17913 #
17914 IBM_C)
17915 #
17916 tmp_CFLAGS="$tmp_CFLAGS"
17917 ;;
17918 #
17919 INTEL_UNIX_C)
17920 #
17921 if test "$want_warnings" = "yes"; then
17922 if test "$compiler_num" -gt "600"; then
17923 tmp_CPPFLAGS="$tmp_CPPFLAGS -Wall -w2"
17924 tmp_CPPFLAGS="$tmp_CPPFLAGS -Wcheck"
17925 tmp_CPPFLAGS="$tmp_CPPFLAGS -Wcomment"
17926 tmp_CPPFLAGS="$tmp_CPPFLAGS -Wdeprecated"
17927 tmp_CPPFLAGS="$tmp_CPPFLAGS -Wmissing-prototypes"
17928 tmp_CPPFLAGS="$tmp_CPPFLAGS -Wp64"
17929 tmp_CPPFLAGS="$tmp_CPPFLAGS -Wpointer-arith"
17930 tmp_CPPFLAGS="$tmp_CPPFLAGS -Wreturn-type"
17931 tmp_CPPFLAGS="$tmp_CPPFLAGS -Wshadow"
17932 tmp_CPPFLAGS="$tmp_CPPFLAGS -Wuninitialized"
17933 tmp_CPPFLAGS="$tmp_CPPFLAGS -Wunused-function"
17934 fi
17935 fi
17936 tmp_CFLAGS="$tmp_CFLAGS -fno-omit-frame-pointer"
17937 tmp_CFLAGS="$tmp_CFLAGS -fno-strict-aliasing"
17938 tmp_CFLAGS="$tmp_CFLAGS -fp-model precise"
17939 if test "$compiler_num" -ge "1000"; then
17940 tmp_CFLAGS="$tmp_CFLAGS -vec-report0"
17941 fi
17942 ;;
17943 #
17944 INTEL_WINDOWS_C)
17945 #
17946 tmp_CFLAGS="$tmp_CFLAGS"
17947 ;;
17948 #
17949 LCC)
17950 #
17951 if test "$want_warnings" = "yes"; then
17952 tmp_CFLAGS="$tmp_CFLAGS"
17953 fi
17954 ;;
17955 #
17956 SGI_MIPS_C)
17957 #
17958 if test "$want_warnings" = "yes"; then
17959 tmp_CFLAGS="$tmp_CFLAGS -fullwarn"
17960 fi
17961 ;;
17962 #
17963 SGI_MIPSPRO_C)
17964 #
17965 if test "$want_warnings" = "yes"; then
17966 tmp_CFLAGS="$tmp_CFLAGS -fullwarn"
17967 tmp_CFLAGS="$tmp_CFLAGS -woff 1209"
17968 fi
17969 ;;
17970 #
17971 SUNPRO_C)
17972 #
17973 if test "$want_warnings" = "yes"; then
17974 tmp_CFLAGS="$tmp_CFLAGS -v"
17975 fi
17976 ;;
17977 #
17978 TINY_C)
17979 #
17980 if test "$want_warnings" = "yes"; then
17981 tmp_CFLAGS="$tmp_CFLAGS -Wall"
17982 tmp_CFLAGS="$tmp_CFLAGS -Wwrite-strings"
17983 tmp_CFLAGS="$tmp_CFLAGS -Wunsupported"
17984 fi
17985 ;;
17986 #
17987 WATCOM_UNIX_C)
17988 #
17989 if test "$want_warnings" = "yes"; then
17990 tmp_CFLAGS="$tmp_CFLAGS -Wall -Wextra"
17991 fi
17992 ;;
17993 #
17994 WATCOM_WINDOWS_C)
17995 #
17996 tmp_CFLAGS="$tmp_CFLAGS"
17997 ;;
17998 #
17999 esac
18000 #
18001 squeeze tmp_CPPFLAGS
18002 squeeze tmp_CFLAGS
18003 #
18004 if test ! -z "$tmp_CFLAGS" || test ! -z "$tmp_CPPFLAGS"; then
18005 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler accepts strict warning options" >&5
18006$as_echo_n "checking if compiler accepts strict warning options... " >&6; }
18007 CPPFLAGS="$tmp_save_CPPFLAGS $tmp_CPPFLAGS"
18008 CFLAGS="$tmp_save_CFLAGS $tmp_CFLAGS"
18009 squeeze CPPFLAGS
18010 squeeze CFLAGS
18011
18012 tmp_compiler_works="unknown"
18013 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18014/* end confdefs.h. */
18015
18016
18017
18018int main (void)
18019{
18020
18021 int i = 1;
18022 return i;
18023
18024 ;
18025 return 0;
18026}
18027
18028_ACEOF
18029if ac_fn_c_try_compile "$LINENO"; then :
18030
18031 tmp_compiler_works="yes"
18032
18033else
18034
18035 tmp_compiler_works="no"
18036 echo " " >&6
18037 sed 's/^/cc-fail: /' conftest.err >&6
18038 echo " " >&6
18039
18040fi
18041rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18042 if test "$tmp_compiler_works" = "yes"; then
18043 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18044/* end confdefs.h. */
18045
18046
18047
18048int main (void)
18049{
18050
18051 int i = 1;
18052 return i;
18053
18054 ;
18055 return 0;
18056}
18057
18058_ACEOF
18059if ac_fn_c_try_link "$LINENO"; then :
18060
18061 tmp_compiler_works="yes"
18062
18063else
18064
18065 tmp_compiler_works="no"
18066 echo " " >&6
18067 sed 's/^/link-fail: /' conftest.err >&6
18068 echo " " >&6
18069
18070fi
18071rm -f core conftest.err conftest.$ac_objext \
18072 conftest$ac_exeext conftest.$ac_ext
18073 fi
18074 if test "x$cross_compiling" != "xyes" &&
18075 test "$tmp_compiler_works" = "yes"; then
Elliott Hughesa93fb052018-12-12 14:22:48 -080018076
18077
18078 old=$LD_LIBRARY_PATH
18079 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
18080 export LD_LIBRARY_PATH
18081 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070018082 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
18083$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18084as_fn_error $? "cannot run test program while cross compiling
18085See \`config.log' for more details" "$LINENO" 5; }
18086else
18087 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18088/* end confdefs.h. */
18089
18090
18091# ifdef __STDC__
18092# include <stdlib.h>
18093# endif
18094
18095int main (void)
18096{
18097
18098 int i = 0;
18099 exit(i);
18100
18101 ;
18102 return 0;
18103}
18104
18105_ACEOF
18106if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughesa93fb052018-12-12 14:22:48 -080018107 tmp_compiler_works="yes"
Elliott Hughes82be86d2017-09-20 17:00:17 -070018108
18109else
Elliott Hughesa93fb052018-12-12 14:22:48 -080018110 tmp_compiler_works="no"
Elliott Hughes82be86d2017-09-20 17:00:17 -070018111 echo " " >&6
18112 echo "run-fail: test program exited with status $ac_status" >&6
18113 echo " " >&6
18114
18115fi
18116rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18117 conftest.$ac_objext conftest.beam conftest.$ac_ext
18118fi
18119
Elliott Hughesa93fb052018-12-12 14:22:48 -080018120 LD_LIBRARY_PATH=$old # restore
18121
Elliott Hughes82be86d2017-09-20 17:00:17 -070018122 fi
18123 if test "$tmp_compiler_works" = "yes"; then
18124
18125 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18126$as_echo "yes" >&6; }
18127 { $as_echo "$as_me:${as_lineno-$LINENO}: compiler options added: $tmp_CFLAGS $tmp_CPPFLAGS" >&5
18128$as_echo "$as_me: compiler options added: $tmp_CFLAGS $tmp_CPPFLAGS" >&6;}
18129
18130 else
18131
18132 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18133$as_echo "no" >&6; }
18134 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: compiler options rejected: $tmp_CFLAGS $tmp_CPPFLAGS" >&5
18135$as_echo "$as_me: WARNING: compiler options rejected: $tmp_CFLAGS $tmp_CPPFLAGS" >&2;}
18136 CPPFLAGS="$tmp_save_CPPFLAGS"
18137 CFLAGS="$tmp_save_CFLAGS"
18138
18139 fi
18140
18141 fi
18142 #
18143 fi
18144
18145
18146if test "$compiler_id" = "INTEL_UNIX_C"; then
18147 #
18148 if test "$compiler_num" -ge "1000"; then
18149 CFLAGS="$CFLAGS -shared-intel"
18150 elif test "$compiler_num" -ge "900"; then
18151 CFLAGS="$CFLAGS -i-dynamic"
18152 fi
18153 #
18154fi
18155
18156
18157 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler halts on compilation errors" >&5
18158$as_echo_n "checking if compiler halts on compilation errors... " >&6; }
18159 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18160/* end confdefs.h. */
18161
18162
18163
18164int main (void)
18165{
18166
18167 force compilation error
18168
18169 ;
18170 return 0;
18171}
18172
18173_ACEOF
18174if ac_fn_c_try_compile "$LINENO"; then :
18175
18176 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18177$as_echo "no" >&6; }
18178 as_fn_error $? "compiler does not halt on compilation errors." "$LINENO" 5
18179
18180else
18181
18182 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18183$as_echo "yes" >&6; }
18184
18185fi
18186rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18187
18188
18189 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler halts on negative sized arrays" >&5
18190$as_echo_n "checking if compiler halts on negative sized arrays... " >&6; }
18191 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18192/* end confdefs.h. */
18193
18194
18195 typedef char bad_t[sizeof(char) == sizeof(int) ? -1 : -1 ];
18196
18197int main (void)
18198{
18199
18200 bad_t dummy;
18201
18202 ;
18203 return 0;
18204}
18205
18206_ACEOF
18207if ac_fn_c_try_compile "$LINENO"; then :
18208
18209 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18210$as_echo "no" >&6; }
18211 as_fn_error $? "compiler does not halt on negative sized arrays." "$LINENO" 5
18212
18213else
18214
18215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18216$as_echo "yes" >&6; }
18217
18218fi
18219rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18220
18221
18222 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler halts on function prototype mismatch" >&5
18223$as_echo_n "checking if compiler halts on function prototype mismatch... " >&6; }
18224 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18225/* end confdefs.h. */
18226
18227
18228# include <stdlib.h>
18229 int rand(int n);
18230 int rand(int n)
18231 {
18232 if(n)
18233 return ++n;
18234 else
18235 return n;
18236 }
18237
18238int main (void)
18239{
18240
18241 int i[2]={0,0};
18242 int j = rand(i[0]);
18243 if(j)
18244 return j;
18245
18246 ;
18247 return 0;
18248}
18249
18250_ACEOF
18251if ac_fn_c_try_compile "$LINENO"; then :
18252
18253 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18254$as_echo "no" >&6; }
18255 as_fn_error $? "compiler does not halt on function prototype mismatch." "$LINENO" 5
18256
18257else
18258
18259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18260$as_echo "yes" >&6; }
18261
18262fi
18263rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18264
18265
18266 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler supports hiding library internal symbols" >&5
18267$as_echo_n "checking if compiler supports hiding library internal symbols... " >&6; }
18268 supports_symbol_hiding="no"
18269 symbol_hiding_CFLAGS=""
18270 symbol_hiding_EXTERN=""
18271 tmp_CFLAGS=""
18272 tmp_EXTERN=""
18273 case "$compiler_id" in
18274 CLANG)
18275 tmp_EXTERN="__attribute__ ((__visibility__ (\"default\")))"
18276 tmp_CFLAGS="-fvisibility=hidden"
18277 supports_symbol_hiding="yes"
18278 ;;
18279 GNU_C)
18280 if test "$compiler_num" -ge "304"; then
18281 if $CC --help --verbose 2>/dev/null | grep fvisibility= >/dev/null ; then
18282 tmp_EXTERN="__attribute__ ((__visibility__ (\"default\")))"
18283 tmp_CFLAGS="-fvisibility=hidden"
18284 supports_symbol_hiding="yes"
18285 fi
18286 fi
18287 ;;
18288 INTEL_UNIX_C)
18289 if test "$compiler_num" -ge "900"; then
18290 if $CC --help --verbose 2>&1 | grep fvisibility= > /dev/null ; then
18291 tmp_save_CFLAGS="$CFLAGS"
18292 CFLAGS="$CFLAGS -fvisibility=hidden"
18293 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18294/* end confdefs.h. */
18295
18296
18297# include <stdio.h>
18298
18299int main (void)
18300{
18301
18302 printf("icc fvisibility bug test");
18303
18304 ;
18305 return 0;
18306}
18307
18308_ACEOF
18309if ac_fn_c_try_link "$LINENO"; then :
18310
18311 tmp_EXTERN="__attribute__ ((__visibility__ (\"default\")))"
18312 tmp_CFLAGS="-fvisibility=hidden"
18313 supports_symbol_hiding="yes"
18314
18315fi
18316rm -f core conftest.err conftest.$ac_objext \
18317 conftest$ac_exeext conftest.$ac_ext
18318 CFLAGS="$tmp_save_CFLAGS"
18319 fi
18320 fi
18321 ;;
18322 SUNPRO_C)
18323 if $CC 2>&1 | grep flags >/dev/null && $CC -flags | grep xldscope= >/dev/null ; then
18324 tmp_EXTERN="__global"
18325 tmp_CFLAGS="-xldscope=hidden"
18326 supports_symbol_hiding="yes"
18327 fi
18328 ;;
18329 esac
18330 if test "$supports_symbol_hiding" = "yes"; then
18331 tmp_save_CFLAGS="$CFLAGS"
18332 CFLAGS="$tmp_save_CFLAGS $tmp_CFLAGS"
18333 squeeze CFLAGS
18334 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18335/* end confdefs.h. */
18336
18337
18338 $tmp_EXTERN char *dummy(char *buff);
18339 char *dummy(char *buff)
18340 {
18341 if(buff)
18342 return ++buff;
18343 else
18344 return buff;
18345 }
18346
18347int main (void)
18348{
18349
18350 char b[16];
18351 char *r = dummy(&b[0]);
18352 if(r)
18353 return (int)*r;
18354
18355 ;
18356 return 0;
18357}
18358
18359_ACEOF
18360if ac_fn_c_try_compile "$LINENO"; then :
18361
18362 supports_symbol_hiding="yes"
18363 if test -f conftest.err; then
18364 grep 'visibility' conftest.err >/dev/null
18365 if test "$?" -eq "0"; then
18366 supports_symbol_hiding="no"
18367 fi
18368 fi
18369
18370else
18371
18372 supports_symbol_hiding="no"
18373 echo " " >&6
18374 sed 's/^/cc-src: /' conftest.$ac_ext >&6
18375 sed 's/^/cc-err: /' conftest.err >&6
18376 echo " " >&6
18377
18378fi
18379rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18380 CFLAGS="$tmp_save_CFLAGS"
18381 fi
18382 if test "$supports_symbol_hiding" = "yes"; then
18383 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18384$as_echo "yes" >&6; }
18385 symbol_hiding_CFLAGS="$tmp_CFLAGS"
18386 symbol_hiding_EXTERN="$tmp_EXTERN"
18387 else
18388 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18389$as_echo "no" >&6; }
18390 fi
18391
18392
18393
18394 supports_curldebug="unknown"
18395 if test "$want_curldebug" = "yes"; then
18396 if test "x$enable_shared" != "xno" &&
18397 test "x$enable_shared" != "xyes"; then
18398 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unknown enable_shared setting." >&5
18399$as_echo "$as_me: WARNING: unknown enable_shared setting." >&2;}
18400 supports_curldebug="no"
18401 fi
18402 if test "x$enable_static" != "xno" &&
18403 test "x$enable_static" != "xyes"; then
18404 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unknown enable_static setting." >&5
18405$as_echo "$as_me: WARNING: unknown enable_static setting." >&2;}
18406 supports_curldebug="no"
18407 fi
18408 if test "$supports_curldebug" != "no"; then
18409 if test "$enable_shared" = "yes" &&
18410 test "x$xc_lt_shlib_use_no_undefined" = 'xyes'; then
18411 supports_curldebug="no"
18412 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: shared library does not support undefined symbols." >&5
18413$as_echo "$as_me: WARNING: shared library does not support undefined symbols." >&2;}
18414 fi
18415 fi
18416 fi
18417 #
18418 if test "$want_curldebug" = "yes"; then
18419 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if curl debug memory tracking can be enabled" >&5
18420$as_echo_n "checking if curl debug memory tracking can be enabled... " >&6; }
18421 test "$supports_curldebug" = "no" || supports_curldebug="yes"
18422 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports_curldebug" >&5
18423$as_echo "$supports_curldebug" >&6; }
18424 if test "$supports_curldebug" = "no"; then
18425 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot enable curl debug memory tracking." >&5
18426$as_echo "$as_me: WARNING: cannot enable curl debug memory tracking." >&2;}
18427 want_curldebug="no"
18428 fi
18429 fi
Elliott Hughes82be86d2017-09-20 17:00:17 -070018430
18431 if test x$want_curldebug = xyes; then
18432 CURLDEBUG_TRUE=
18433 CURLDEBUG_FALSE='#'
18434else
18435 CURLDEBUG_TRUE='#'
18436 CURLDEBUG_FALSE=
18437fi
18438
18439
18440supports_unittests=yes
18441# cross-compilation of unit tests static library/programs fails when
18442# libcurl shared library is built. This might be due to a libtool or
18443# automake issue. In this case we disable unit tests.
18444if test "x$cross_compiling" != "xno" &&
18445 test "x$enable_shared" != "xno"; then
18446 supports_unittests=no
18447fi
18448
18449# IRIX 6.5.24 gcc 3.3 autobuilds fail unittests library compilation due to
18450# a problem related with OpenSSL headers and library versions not matching.
18451# Disable unit tests while time to further investigate this is found.
18452case $host in
18453 mips-sgi-irix6.5)
18454 if test "$compiler_id" = "GNU_C"; then
18455 supports_unittests=no
18456 fi
18457 ;;
18458esac
18459
18460# All AIX autobuilds fails unit tests linking against unittests library
18461# due to unittests library being built with no symbols or members. Libtool ?
18462# Disable unit tests while time to further investigate this is found.
18463case $host_os in
18464 aix*)
18465 supports_unittests=no
18466 ;;
18467esac
18468
18469if test "x$want_debug" = "xyes" &&
18470 test "x$supports_unittests" = "xyes"; then
18471 want_unittests=yes
18472else
18473 want_unittests=no
18474fi
18475 if test x$want_unittests = xyes; then
18476 BUILD_UNITTESTS_TRUE=
18477 BUILD_UNITTESTS_FALSE='#'
18478else
18479 BUILD_UNITTESTS_TRUE='#'
18480 BUILD_UNITTESTS_FALSE=
18481fi
18482
18483
18484
18485
18486
18487 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for windows.h" >&5
18488$as_echo_n "checking for windows.h... " >&6; }
18489if ${curl_cv_header_windows_h+:} false; then :
18490 $as_echo_n "(cached) " >&6
18491else
18492
18493 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18494/* end confdefs.h. */
18495
18496
18497#undef inline
18498#ifndef WIN32_LEAN_AND_MEAN
18499#define WIN32_LEAN_AND_MEAN
18500#endif
18501#include <windows.h>
18502
18503int main (void)
18504{
18505
18506#if defined(__CYGWIN__) || defined(__CEGCC__)
18507 HAVE_WINDOWS_H shall not be defined.
18508#else
18509 int dummy=2*WINVER;
18510#endif
18511
18512 ;
18513 return 0;
18514}
18515
18516_ACEOF
18517if ac_fn_c_try_compile "$LINENO"; then :
18518
18519 curl_cv_header_windows_h="yes"
18520
18521else
18522
18523 curl_cv_header_windows_h="no"
18524
18525fi
18526rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18527
18528fi
18529{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_windows_h" >&5
18530$as_echo "$curl_cv_header_windows_h" >&6; }
18531 case "$curl_cv_header_windows_h" in
18532 yes)
18533
18534cat >>confdefs.h <<_ACEOF
18535#define HAVE_WINDOWS_H 1
18536_ACEOF
18537
18538 ;;
18539 esac
18540
18541
18542 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build target is a native Windows one" >&5
18543$as_echo_n "checking whether build target is a native Windows one... " >&6; }
18544if ${curl_cv_native_windows+:} false; then :
18545 $as_echo_n "(cached) " >&6
18546else
18547
18548 if test "$curl_cv_header_windows_h" = "no"; then
18549 curl_cv_native_windows="no"
18550 else
18551 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18552/* end confdefs.h. */
18553
18554
18555
18556int main (void)
18557{
18558
18559#if defined(__MINGW32__) || defined(__MINGW32CE__) || \
18560 (defined(_MSC_VER) && (defined(_WIN32) || defined(_WIN64)))
18561 int dummy=1;
18562#else
18563 Not a native Windows build target.
18564#endif
18565
18566 ;
18567 return 0;
18568}
18569
18570_ACEOF
18571if ac_fn_c_try_compile "$LINENO"; then :
18572
18573 curl_cv_native_windows="yes"
18574
18575else
18576
18577 curl_cv_native_windows="no"
18578
18579fi
18580rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18581 fi
18582
18583fi
18584{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_native_windows" >&5
18585$as_echo "$curl_cv_native_windows" >&6; }
18586 if test "x$curl_cv_native_windows" = xyes; then
18587 DOING_NATIVE_WINDOWS_TRUE=
18588 DOING_NATIVE_WINDOWS_FALSE='#'
18589else
18590 DOING_NATIVE_WINDOWS_TRUE='#'
18591 DOING_NATIVE_WINDOWS_FALSE=
18592fi
18593
18594
18595case X-"$curl_cv_native_windows" in
18596 X-yes)
18597
18598 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for winsock.h" >&5
18599$as_echo_n "checking for winsock.h... " >&6; }
18600if ${curl_cv_header_winsock_h+:} false; then :
18601 $as_echo_n "(cached) " >&6
18602else
18603
18604 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18605/* end confdefs.h. */
18606
18607
18608#undef inline
18609#ifndef WIN32_LEAN_AND_MEAN
18610#define WIN32_LEAN_AND_MEAN
18611#endif
18612#include <windows.h>
18613#include <winsock.h>
18614
18615int main (void)
18616{
18617
18618#if defined(__CYGWIN__) || defined(__CEGCC__)
18619 HAVE_WINSOCK_H shall not be defined.
18620#else
18621 int dummy=WSACleanup();
18622#endif
18623
18624 ;
18625 return 0;
18626}
18627
18628_ACEOF
18629if ac_fn_c_try_compile "$LINENO"; then :
18630
18631 curl_cv_header_winsock_h="yes"
18632
18633else
18634
18635 curl_cv_header_winsock_h="no"
18636
18637fi
18638rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18639
18640fi
18641{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_winsock_h" >&5
18642$as_echo "$curl_cv_header_winsock_h" >&6; }
18643 case "$curl_cv_header_winsock_h" in
18644 yes)
18645
18646cat >>confdefs.h <<_ACEOF
18647#define HAVE_WINSOCK_H 1
18648_ACEOF
18649
18650 ;;
18651 esac
18652
18653
18654 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for winsock2.h" >&5
18655$as_echo_n "checking for winsock2.h... " >&6; }
18656if ${curl_cv_header_winsock2_h+:} false; then :
18657 $as_echo_n "(cached) " >&6
18658else
18659
18660 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18661/* end confdefs.h. */
18662
18663
18664#undef inline
18665#ifndef WIN32_LEAN_AND_MEAN
18666#define WIN32_LEAN_AND_MEAN
18667#endif
18668#include <windows.h>
18669#include <winsock2.h>
18670
18671int main (void)
18672{
18673
18674#if defined(__CYGWIN__) || defined(__CEGCC__) || defined(__MINGW32CE__)
18675 HAVE_WINSOCK2_H shall not be defined.
18676#else
18677 int dummy=2*IPPROTO_ESP;
18678#endif
18679
18680 ;
18681 return 0;
18682}
18683
18684_ACEOF
18685if ac_fn_c_try_compile "$LINENO"; then :
18686
18687 curl_cv_header_winsock2_h="yes"
18688
18689else
18690
18691 curl_cv_header_winsock2_h="no"
18692
18693fi
18694rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18695
18696fi
18697{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_winsock2_h" >&5
18698$as_echo "$curl_cv_header_winsock2_h" >&6; }
18699 case "$curl_cv_header_winsock2_h" in
18700 yes)
18701
18702cat >>confdefs.h <<_ACEOF
18703#define HAVE_WINSOCK2_H 1
18704_ACEOF
18705
18706 ;;
18707 esac
18708
18709
18710 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ws2tcpip.h" >&5
18711$as_echo_n "checking for ws2tcpip.h... " >&6; }
18712if ${curl_cv_header_ws2tcpip_h+:} false; then :
18713 $as_echo_n "(cached) " >&6
18714else
18715
18716 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18717/* end confdefs.h. */
18718
18719
18720#undef inline
18721#ifndef WIN32_LEAN_AND_MEAN
18722#define WIN32_LEAN_AND_MEAN
18723#endif
18724#include <windows.h>
18725#include <winsock2.h>
18726#include <ws2tcpip.h>
18727
18728int main (void)
18729{
18730
18731#if defined(__CYGWIN__) || defined(__CEGCC__) || defined(__MINGW32CE__)
18732 HAVE_WS2TCPIP_H shall not be defined.
18733#else
18734 int dummy=2*IP_PKTINFO;
18735#endif
18736
18737 ;
18738 return 0;
18739}
18740
18741_ACEOF
18742if ac_fn_c_try_compile "$LINENO"; then :
18743
18744 curl_cv_header_ws2tcpip_h="yes"
18745
18746else
18747
18748 curl_cv_header_ws2tcpip_h="no"
18749
18750fi
18751rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18752
18753fi
18754{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_ws2tcpip_h" >&5
18755$as_echo "$curl_cv_header_ws2tcpip_h" >&6; }
18756 case "$curl_cv_header_ws2tcpip_h" in
18757 yes)
18758
18759cat >>confdefs.h <<_ACEOF
18760#define HAVE_WS2TCPIP_H 1
18761_ACEOF
18762
18763 ;;
18764 esac
18765
18766
18767 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for winldap.h" >&5
18768$as_echo_n "checking for winldap.h... " >&6; }
18769if ${curl_cv_header_winldap_h+:} false; then :
18770 $as_echo_n "(cached) " >&6
18771else
18772
18773 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18774/* end confdefs.h. */
18775
18776
18777#undef inline
18778#ifdef HAVE_WINDOWS_H
18779#ifndef WIN32_LEAN_AND_MEAN
18780#define WIN32_LEAN_AND_MEAN
18781#endif
18782#include <windows.h>
18783#endif
18784#include <winldap.h>
18785
18786int main (void)
18787{
18788
18789#if defined(__CYGWIN__) || defined(__CEGCC__)
18790 HAVE_WINLDAP_H shall not be defined.
18791#else
18792 LDAP *ldp = ldap_init("dummy", LDAP_PORT);
18793 ULONG res = ldap_unbind(ldp);
18794#endif
18795
18796 ;
18797 return 0;
18798}
18799
18800_ACEOF
18801if ac_fn_c_try_compile "$LINENO"; then :
18802
18803 curl_cv_header_winldap_h="yes"
18804
18805else
18806
18807 curl_cv_header_winldap_h="no"
18808
18809fi
18810rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18811
18812fi
18813{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_winldap_h" >&5
18814$as_echo "$curl_cv_header_winldap_h" >&6; }
18815 case "$curl_cv_header_winldap_h" in
18816 yes)
18817
18818cat >>confdefs.h <<_ACEOF
18819#define HAVE_WINLDAP_H 1
18820_ACEOF
18821
18822 ;;
18823 esac
18824
18825
18826 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for winber.h" >&5
18827$as_echo_n "checking for winber.h... " >&6; }
18828if ${curl_cv_header_winber_h+:} false; then :
18829 $as_echo_n "(cached) " >&6
18830else
18831
18832 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18833/* end confdefs.h. */
18834
18835
18836#undef inline
18837#ifdef HAVE_WINDOWS_H
18838#ifndef WIN32_LEAN_AND_MEAN
18839#define WIN32_LEAN_AND_MEAN
18840#endif
18841#include <windows.h>
18842#endif
18843#include <winldap.h>
18844#include <winber.h>
18845
18846int main (void)
18847{
18848
18849#if defined(__CYGWIN__) || defined(__CEGCC__)
18850 HAVE_WINBER_H shall not be defined.
18851#else
18852 BERVAL *bvp = NULL;
18853 BerElement *bep = ber_init(bvp);
18854 ber_free(bep, 1);
18855#endif
18856
18857 ;
18858 return 0;
18859}
18860
18861_ACEOF
18862if ac_fn_c_try_compile "$LINENO"; then :
18863
18864 curl_cv_header_winber_h="yes"
18865
18866else
18867
18868 curl_cv_header_winber_h="no"
18869
18870fi
18871rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18872
18873fi
18874{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_winber_h" >&5
18875$as_echo "$curl_cv_header_winber_h" >&6; }
18876 case "$curl_cv_header_winber_h" in
18877 yes)
18878
18879cat >>confdefs.h <<_ACEOF
18880#define HAVE_WINBER_H 1
18881_ACEOF
18882
18883 ;;
18884 esac
18885
18886 ;;
18887 *)
18888 curl_cv_header_winsock_h="no"
18889 curl_cv_header_winsock2_h="no"
18890 curl_cv_header_ws2tcpip_h="no"
18891 curl_cv_header_winldap_h="no"
18892 curl_cv_header_winber_h="no"
18893 ;;
18894esac
18895
18896 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build target supports WIN32 file API" >&5
18897$as_echo_n "checking whether build target supports WIN32 file API... " >&6; }
18898 curl_win32_file_api="no"
18899 if test "$curl_cv_header_windows_h" = "yes"; then
18900 if test x"$enable_largefile" != "xno"; then
18901 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18902/* end confdefs.h. */
18903
18904
18905
18906int main (void)
18907{
18908
18909#if !defined(_WIN32_WCE) && \
18910 (defined(__MINGW32__) || \
18911 (defined(_MSC_VER) && (defined(_WIN32) || defined(_WIN64))))
18912 int dummy=1;
18913#else
18914 WIN32 large file API not supported.
18915#endif
18916
18917 ;
18918 return 0;
18919}
18920
18921_ACEOF
18922if ac_fn_c_try_compile "$LINENO"; then :
18923
18924 curl_win32_file_api="win32_large_files"
18925
18926fi
18927rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18928 fi
18929 if test "$curl_win32_file_api" = "no"; then
18930 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18931/* end confdefs.h. */
18932
18933
18934
18935int main (void)
18936{
18937
18938#if defined(_WIN32_WCE) || defined(__MINGW32__) || defined(_MSC_VER)
18939 int dummy=1;
18940#else
18941 WIN32 small file API not supported.
18942#endif
18943
18944 ;
18945 return 0;
18946}
18947
18948_ACEOF
18949if ac_fn_c_try_compile "$LINENO"; then :
18950
18951 curl_win32_file_api="win32_small_files"
18952
18953fi
18954rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18955 fi
18956 fi
18957 case "$curl_win32_file_api" in
18958 win32_large_files)
18959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (large file enabled)" >&5
18960$as_echo "yes (large file enabled)" >&6; }
18961
18962cat >>confdefs.h <<_ACEOF
18963#define USE_WIN32_LARGE_FILES 1
18964_ACEOF
18965
18966 ;;
18967 win32_small_files)
18968 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (large file disabled)" >&5
18969$as_echo "yes (large file disabled)" >&6; }
18970
18971cat >>confdefs.h <<_ACEOF
18972#define USE_WIN32_SMALL_FILES 1
18973_ACEOF
18974
18975 ;;
18976 *)
18977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18978$as_echo "no" >&6; }
18979 ;;
18980 esac
18981
18982
18983
18984
18985 tst_cflags="no"
18986 case $host_os in
18987 darwin*)
18988 tst_cflags="yes"
18989 ;;
18990 esac
18991
18992 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for good-to-use Mac CFLAGS" >&5
18993$as_echo_n "checking for good-to-use Mac CFLAGS... " >&6; }
18994 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tst_cflags" >&5
18995$as_echo "$tst_cflags" >&6; };
18996
18997 if test "$tst_cflags" = "yes"; then
18998 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for *version-min in CFLAGS" >&5
18999$as_echo_n "checking for *version-min in CFLAGS... " >&6; }
19000 min=""
19001 if test -z "$(echo $CFLAGS | grep m.*os.*-version-min)"; then
19002 min="-mmacosx-version-min=10.8"
19003 CFLAGS="$CFLAGS $min"
19004 fi
19005 if test -z "$min"; then
19006 { $as_echo "$as_me:${as_lineno-$LINENO}: result: set by user" >&5
19007$as_echo "set by user" >&6; }
19008 else
19009 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $min set" >&5
19010$as_echo "$min set" >&6; }
19011 fi
19012
19013 old_CFLAGS=$CFLAGS
19014 CFLAGS="$CFLAGS -Werror=partial-availability"
19015 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -Werror=partial-availability" >&5
19016$as_echo_n "checking whether $CC accepts -Werror=partial-availability... " >&6; }
19017 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19018/* end confdefs.h. */
19019
19020int main (void)
19021{
19022
19023 ;
19024 return 0;
19025}
19026_ACEOF
19027if ac_fn_c_try_compile "$LINENO"; then :
19028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19029$as_echo "yes" >&6; }
19030else
19031 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19032$as_echo "no" >&6; }
19033 CFLAGS=$old_CFLAGS
19034fi
19035rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19036 fi
19037
19038
19039
Alex Deymo486467e2017-12-19 19:04:07 +010019040 { $as_echo "$as_me:${as_lineno-$LINENO}: checking to see if the compiler supports __builtin_available()" >&5
19041$as_echo_n "checking to see if the compiler supports __builtin_available()... " >&6; }
19042 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19043/* end confdefs.h. */
19044
19045
19046#include <stdlib.h>
19047
19048int main (void)
19049{
19050
19051 if (__builtin_available(macOS 10.8, iOS 5.0, *)) {}
19052
19053 ;
19054 return 0;
19055}
19056
19057_ACEOF
19058if ac_fn_c_try_compile "$LINENO"; then :
19059
19060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19061$as_echo "yes" >&6; }
19062
19063cat >>confdefs.h <<_ACEOF
19064#define HAVE_BUILTIN_AVAILABLE 1
19065_ACEOF
19066
19067
19068else
19069
19070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19071$as_echo "no" >&6; }
19072
19073fi
19074rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19075
19076
Haibo Huang65021c72019-03-27 15:37:23 -070019077
Elliott Hughes82be86d2017-09-20 17:00:17 -070019078{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support http" >&5
19079$as_echo_n "checking whether to support http... " >&6; }
19080# Check whether --enable-http was given.
19081if test "${enable_http+set}" = set; then :
19082 enableval=$enable_http; case "$enableval" in
19083 no)
19084 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19085$as_echo "no" >&6; }
19086
19087$as_echo "#define CURL_DISABLE_HTTP 1" >>confdefs.h
19088
19089 disable_http="yes"
19090 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: disable HTTP disables FTP over proxy and RTSP" >&5
19091$as_echo "$as_me: WARNING: disable HTTP disables FTP over proxy and RTSP" >&2;}
19092 CURL_DISABLE_HTTP=1
19093
19094
19095$as_echo "#define CURL_DISABLE_RTSP 1" >>confdefs.h
19096
19097 CURL_DISABLE_RTSP=1
19098
19099 ;;
19100 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19101$as_echo "yes" >&6; }
19102 ;;
19103 esac
19104else
19105 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19106$as_echo "yes" >&6; }
19107
19108fi
19109
19110{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support ftp" >&5
19111$as_echo_n "checking whether to support ftp... " >&6; }
19112# Check whether --enable-ftp was given.
19113if test "${enable_ftp+set}" = set; then :
19114 enableval=$enable_ftp; case "$enableval" in
19115 no)
19116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19117$as_echo "no" >&6; }
19118
19119$as_echo "#define CURL_DISABLE_FTP 1" >>confdefs.h
19120
19121 CURL_DISABLE_FTP=1
19122
19123 ;;
19124 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19125$as_echo "yes" >&6; }
19126 ;;
19127 esac
19128else
19129 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19130$as_echo "yes" >&6; }
19131
19132fi
19133
19134{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support file" >&5
19135$as_echo_n "checking whether to support file... " >&6; }
19136# Check whether --enable-file was given.
19137if test "${enable_file+set}" = set; then :
19138 enableval=$enable_file; case "$enableval" in
19139 no)
19140 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19141$as_echo "no" >&6; }
19142
19143$as_echo "#define CURL_DISABLE_FILE 1" >>confdefs.h
19144
19145 CURL_DISABLE_FILE=1
19146
19147 ;;
19148 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19149$as_echo "yes" >&6; }
19150 ;;
19151 esac
19152else
19153 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19154$as_echo "yes" >&6; }
19155
19156fi
19157
19158{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support ldap" >&5
19159$as_echo_n "checking whether to support ldap... " >&6; }
19160# Check whether --enable-ldap was given.
19161if test "${enable_ldap+set}" = set; then :
19162 enableval=$enable_ldap; case "$enableval" in
19163 no)
19164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19165$as_echo "no" >&6; }
19166
19167$as_echo "#define CURL_DISABLE_LDAP 1" >>confdefs.h
19168
19169 CURL_DISABLE_LDAP=1
19170
19171 ;;
19172 *)
19173 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19174$as_echo "yes" >&6; }
19175 ;;
19176 esac
19177else
19178
19179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19180$as_echo "yes" >&6; }
19181
19182fi
19183
19184{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support ldaps" >&5
19185$as_echo_n "checking whether to support ldaps... " >&6; }
19186# Check whether --enable-ldaps was given.
19187if test "${enable_ldaps+set}" = set; then :
19188 enableval=$enable_ldaps; case "$enableval" in
19189 no)
19190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19191$as_echo "no" >&6; }
19192
19193$as_echo "#define CURL_DISABLE_LDAPS 1" >>confdefs.h
19194
19195 CURL_DISABLE_LDAPS=1
19196
19197 ;;
19198 *) if test "x$CURL_DISABLE_LDAP" = "x1" ; then
19199 { $as_echo "$as_me:${as_lineno-$LINENO}: result: LDAP needs to be enabled to support LDAPS" >&5
19200$as_echo "LDAP needs to be enabled to support LDAPS" >&6; }
19201
19202$as_echo "#define CURL_DISABLE_LDAPS 1" >>confdefs.h
19203
19204 CURL_DISABLE_LDAPS=1
19205
19206 else
19207 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19208$as_echo "yes" >&6; }
19209
19210$as_echo "#define HAVE_LDAP_SSL 1" >>confdefs.h
19211
19212 HAVE_LDAP_SSL=1
19213
19214 fi
19215 ;;
19216 esac
19217else
19218
19219 if test "x$CURL_DISABLE_LDAP" = "x1" ; then
19220 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19221$as_echo "no" >&6; }
19222
19223$as_echo "#define CURL_DISABLE_LDAPS 1" >>confdefs.h
19224
19225 CURL_DISABLE_LDAPS=1
19226
19227 else
19228 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19229$as_echo "yes" >&6; }
19230
19231$as_echo "#define HAVE_LDAP_SSL 1" >>confdefs.h
19232
19233 HAVE_LDAP_SSL=1
19234
19235 fi
19236
19237fi
19238
19239
19240{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support rtsp" >&5
19241$as_echo_n "checking whether to support rtsp... " >&6; }
19242# Check whether --enable-rtsp was given.
19243if test "${enable_rtsp+set}" = set; then :
19244 enableval=$enable_rtsp; case "$enableval" in
19245 no)
19246 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19247$as_echo "no" >&6; }
19248
19249$as_echo "#define CURL_DISABLE_RTSP 1" >>confdefs.h
19250
19251 CURL_DISABLE_RTSP=1
19252
19253 ;;
19254 *) if test x$CURL_DISABLE_HTTP = x1 ; then
19255 as_fn_error $? "HTTP support needs to be enabled in order to enable RTSP support!" "$LINENO" 5
19256 else
19257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19258$as_echo "yes" >&6; }
19259 curl_rtsp_msg="enabled"
19260 fi
19261 ;;
19262 esac
19263else
19264 if test "x$CURL_DISABLE_HTTP" != "x1"; then
19265 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19266$as_echo "yes" >&6; }
19267 curl_rtsp_msg="enabled"
19268 else
19269 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19270$as_echo "no" >&6; }
19271 fi
19272
19273fi
19274
19275
19276{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support proxies" >&5
19277$as_echo_n "checking whether to support proxies... " >&6; }
19278# Check whether --enable-proxy was given.
19279if test "${enable_proxy+set}" = set; then :
19280 enableval=$enable_proxy; case "$enableval" in
19281 no)
19282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19283$as_echo "no" >&6; }
19284
19285$as_echo "#define CURL_DISABLE_PROXY 1" >>confdefs.h
19286
19287 CURL_DISABLE_PROXY=1
19288
19289 ;;
19290 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19291$as_echo "yes" >&6; }
19292 ;;
19293 esac
19294else
19295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19296$as_echo "yes" >&6; }
19297
19298fi
19299
19300
19301{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support dict" >&5
19302$as_echo_n "checking whether to support dict... " >&6; }
19303# Check whether --enable-dict was given.
19304if test "${enable_dict+set}" = set; then :
19305 enableval=$enable_dict; case "$enableval" in
19306 no)
19307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19308$as_echo "no" >&6; }
19309
19310$as_echo "#define CURL_DISABLE_DICT 1" >>confdefs.h
19311
19312 CURL_DISABLE_DICT=1
19313
19314 ;;
19315 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19316$as_echo "yes" >&6; }
19317 ;;
19318 esac
19319else
19320 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19321$as_echo "yes" >&6; }
19322
19323fi
19324
19325{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support telnet" >&5
19326$as_echo_n "checking whether to support telnet... " >&6; }
19327# Check whether --enable-telnet was given.
19328if test "${enable_telnet+set}" = set; then :
19329 enableval=$enable_telnet; case "$enableval" in
19330 no)
19331 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19332$as_echo "no" >&6; }
19333
19334$as_echo "#define CURL_DISABLE_TELNET 1" >>confdefs.h
19335
19336 CURL_DISABLE_TELNET=1
19337
19338 ;;
19339 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19340$as_echo "yes" >&6; }
19341 ;;
19342 esac
19343else
19344 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19345$as_echo "yes" >&6; }
19346
19347fi
19348
19349{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support tftp" >&5
19350$as_echo_n "checking whether to support tftp... " >&6; }
19351# Check whether --enable-tftp was given.
19352if test "${enable_tftp+set}" = set; then :
19353 enableval=$enable_tftp; case "$enableval" in
19354 no)
19355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19356$as_echo "no" >&6; }
19357
19358$as_echo "#define CURL_DISABLE_TFTP 1" >>confdefs.h
19359
19360 CURL_DISABLE_TFTP=1
19361
19362 ;;
19363 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19364$as_echo "yes" >&6; }
19365 ;;
19366 esac
19367else
19368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19369$as_echo "yes" >&6; }
19370
19371fi
19372
19373
19374{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support pop3" >&5
19375$as_echo_n "checking whether to support pop3... " >&6; }
19376# Check whether --enable-pop3 was given.
19377if test "${enable_pop3+set}" = set; then :
19378 enableval=$enable_pop3; case "$enableval" in
19379 no)
19380 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19381$as_echo "no" >&6; }
19382
19383$as_echo "#define CURL_DISABLE_POP3 1" >>confdefs.h
19384
19385 CURL_DISABLE_POP3=1
19386
19387 ;;
19388 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19389$as_echo "yes" >&6; }
19390 ;;
19391 esac
19392else
19393 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19394$as_echo "yes" >&6; }
19395
19396fi
19397
19398
19399
19400{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support imap" >&5
19401$as_echo_n "checking whether to support imap... " >&6; }
19402# Check whether --enable-imap was given.
19403if test "${enable_imap+set}" = set; then :
19404 enableval=$enable_imap; case "$enableval" in
19405 no)
19406 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19407$as_echo "no" >&6; }
19408
19409$as_echo "#define CURL_DISABLE_IMAP 1" >>confdefs.h
19410
19411 CURL_DISABLE_IMAP=1
19412
19413 ;;
19414 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19415$as_echo "yes" >&6; }
19416 ;;
19417 esac
19418else
19419 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19420$as_echo "yes" >&6; }
19421
19422fi
19423
19424
19425
19426{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support smb" >&5
19427$as_echo_n "checking whether to support smb... " >&6; }
19428# Check whether --enable-smb was given.
19429if test "${enable_smb+set}" = set; then :
19430 enableval=$enable_smb; case "$enableval" in
19431 no)
19432 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19433$as_echo "no" >&6; }
19434
19435$as_echo "#define CURL_DISABLE_SMB 1" >>confdefs.h
19436
19437 CURL_DISABLE_SMB=1
19438
19439 ;;
19440 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19441$as_echo "yes" >&6; }
19442 ;;
19443 esac
19444else
19445 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19446$as_echo "yes" >&6; }
19447
19448fi
19449
19450
19451{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support smtp" >&5
19452$as_echo_n "checking whether to support smtp... " >&6; }
19453# Check whether --enable-smtp was given.
19454if test "${enable_smtp+set}" = set; then :
19455 enableval=$enable_smtp; case "$enableval" in
19456 no)
19457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19458$as_echo "no" >&6; }
19459
19460$as_echo "#define CURL_DISABLE_SMTP 1" >>confdefs.h
19461
19462 CURL_DISABLE_SMTP=1
19463
19464 ;;
19465 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19466$as_echo "yes" >&6; }
19467 ;;
19468 esac
19469else
19470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19471$as_echo "yes" >&6; }
19472
19473fi
19474
19475
19476{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support gopher" >&5
19477$as_echo_n "checking whether to support gopher... " >&6; }
19478# Check whether --enable-gopher was given.
19479if test "${enable_gopher+set}" = set; then :
19480 enableval=$enable_gopher; case "$enableval" in
19481 no)
19482 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19483$as_echo "no" >&6; }
19484
19485$as_echo "#define CURL_DISABLE_GOPHER 1" >>confdefs.h
19486
19487 CURL_DISABLE_GOPHER=1
19488
19489 ;;
19490 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19491$as_echo "yes" >&6; }
19492 ;;
19493 esac
19494else
19495 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19496$as_echo "yes" >&6; }
19497
19498fi
19499
19500
19501
19502
19503{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to provide built-in manual" >&5
19504$as_echo_n "checking whether to provide built-in manual... " >&6; }
19505# Check whether --enable-manual was given.
19506if test "${enable_manual+set}" = set; then :
19507 enableval=$enable_manual; case "$enableval" in
19508 no)
19509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19510$as_echo "no" >&6; }
19511 ;;
19512 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19513$as_echo "yes" >&6; }
19514 USE_MANUAL="1"
19515 ;;
19516 esac
19517else
19518 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19519$as_echo "yes" >&6; }
19520 USE_MANUAL="1"
19521
19522fi
19523
19524
19525{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable generation of C code" >&5
19526$as_echo_n "checking whether to enable generation of C code... " >&6; }
19527# Check whether --enable-libcurl_option was given.
19528if test "${enable_libcurl_option+set}" = set; then :
19529 enableval=$enable_libcurl_option; case "$enableval" in
19530 no)
19531 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19532$as_echo "no" >&6; }
19533
19534$as_echo "#define CURL_DISABLE_LIBCURL_OPTION 1" >>confdefs.h
19535
19536 curl_libcurl_msg="no"
19537 ;;
19538 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19539$as_echo "yes" >&6; }
19540 ;;
19541 esac
19542else
19543 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19544$as_echo "yes" >&6; }
19545
19546fi
19547
19548
19549
19550{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use libgcc" >&5
19551$as_echo_n "checking whether to use libgcc... " >&6; }
19552# Check whether --enable-libgcc was given.
19553if test "${enable_libgcc+set}" = set; then :
19554 enableval=$enable_libgcc; case "$enableval" in
19555 yes)
19556 LIBS="-lgcc $LIBS"
19557 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19558$as_echo "yes" >&6; }
19559 ;;
19560 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19561$as_echo "no" >&6; }
19562 ;;
19563 esac
19564else
19565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19566$as_echo "no" >&6; }
19567
19568fi
19569
19570
19571
19572 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if X/Open network library is required" >&5
19573$as_echo_n "checking if X/Open network library is required... " >&6; }
19574 tst_lib_xnet_required="no"
19575 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19576/* end confdefs.h. */
19577
19578
19579int main (void)
19580{
19581#if defined(__hpux) && defined(_XOPEN_SOURCE) && (_XOPEN_SOURCE >= 600)
19582 return 0;
19583#elif defined(__hpux) && defined(_XOPEN_SOURCE_EXTENDED)
19584 return 0;
19585#else
19586 force compilation error
19587#endif
19588}
19589
19590
19591_ACEOF
19592if ac_fn_c_try_compile "$LINENO"; then :
19593
19594 tst_lib_xnet_required="yes"
19595 LIBS="-lxnet $LIBS"
19596
19597fi
19598rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tst_lib_xnet_required" >&5
19600$as_echo "$tst_lib_xnet_required" >&6; }
19601
19602
19603ac_fn_c_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname"
19604if test "x$ac_cv_func_gethostbyname" = xyes; then :
19605 HAVE_GETHOSTBYNAME="1"
19606
19607else
19608 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lnsl" >&5
19609$as_echo_n "checking for gethostbyname in -lnsl... " >&6; }
19610if ${ac_cv_lib_nsl_gethostbyname+:} false; then :
19611 $as_echo_n "(cached) " >&6
19612else
19613 ac_check_lib_save_LIBS=$LIBS
19614LIBS="-lnsl $LIBS"
19615cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19616/* end confdefs.h. */
19617
19618
19619#ifdef __cplusplus
19620extern "C"
19621#endif
19622char gethostbyname ();
19623int main (void)
19624{
19625return gethostbyname ();
19626 ;
19627 return 0;
19628}
19629_ACEOF
19630if ac_fn_c_try_link "$LINENO"; then :
19631 ac_cv_lib_nsl_gethostbyname=yes
19632else
19633 ac_cv_lib_nsl_gethostbyname=no
19634fi
19635rm -f core conftest.err conftest.$ac_objext \
19636 conftest$ac_exeext conftest.$ac_ext
19637LIBS=$ac_check_lib_save_LIBS
19638fi
19639{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_gethostbyname" >&5
19640$as_echo "$ac_cv_lib_nsl_gethostbyname" >&6; }
19641if test "x$ac_cv_lib_nsl_gethostbyname" = xyes; then :
19642 HAVE_GETHOSTBYNAME="1"
19643 LIBS="-lnsl $LIBS"
19644
19645fi
19646
19647
19648fi
19649
19650
19651if test "$HAVE_GETHOSTBYNAME" != "1"
19652then
19653 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lsocket" >&5
19654$as_echo_n "checking for gethostbyname in -lsocket... " >&6; }
19655if ${ac_cv_lib_socket_gethostbyname+:} false; then :
19656 $as_echo_n "(cached) " >&6
19657else
19658 ac_check_lib_save_LIBS=$LIBS
19659LIBS="-lsocket $LIBS"
19660cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19661/* end confdefs.h. */
19662
19663
19664#ifdef __cplusplus
19665extern "C"
19666#endif
19667char gethostbyname ();
19668int main (void)
19669{
19670return gethostbyname ();
19671 ;
19672 return 0;
19673}
19674_ACEOF
19675if ac_fn_c_try_link "$LINENO"; then :
19676 ac_cv_lib_socket_gethostbyname=yes
19677else
19678 ac_cv_lib_socket_gethostbyname=no
19679fi
19680rm -f core conftest.err conftest.$ac_objext \
19681 conftest$ac_exeext conftest.$ac_ext
19682LIBS=$ac_check_lib_save_LIBS
19683fi
19684{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_gethostbyname" >&5
19685$as_echo "$ac_cv_lib_socket_gethostbyname" >&6; }
19686if test "x$ac_cv_lib_socket_gethostbyname" = xyes; then :
19687 HAVE_GETHOSTBYNAME="1"
19688 LIBS="-lsocket $LIBS"
19689
19690fi
19691
19692fi
19693
19694if test "$HAVE_GETHOSTBYNAME" != "1"
19695then
19696 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lwatt" >&5
19697$as_echo_n "checking for gethostbyname in -lwatt... " >&6; }
19698if ${ac_cv_lib_watt_gethostbyname+:} false; then :
19699 $as_echo_n "(cached) " >&6
19700else
19701 ac_check_lib_save_LIBS=$LIBS
19702LIBS="-lwatt $LIBS"
19703cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19704/* end confdefs.h. */
19705
19706
19707#ifdef __cplusplus
19708extern "C"
19709#endif
19710char gethostbyname ();
19711int main (void)
19712{
19713return gethostbyname ();
19714 ;
19715 return 0;
19716}
19717_ACEOF
19718if ac_fn_c_try_link "$LINENO"; then :
19719 ac_cv_lib_watt_gethostbyname=yes
19720else
19721 ac_cv_lib_watt_gethostbyname=no
19722fi
19723rm -f core conftest.err conftest.$ac_objext \
19724 conftest$ac_exeext conftest.$ac_ext
19725LIBS=$ac_check_lib_save_LIBS
19726fi
19727{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_watt_gethostbyname" >&5
19728$as_echo "$ac_cv_lib_watt_gethostbyname" >&6; }
19729if test "x$ac_cv_lib_watt_gethostbyname" = xyes; then :
19730 HAVE_GETHOSTBYNAME="1"
19731 CPPFLAGS="-I/dev/env/WATT_ROOT/inc"
19732 LDFLAGS="-L/dev/env/WATT_ROOT/lib"
19733 LIBS="-lwatt $LIBS"
19734
19735fi
19736
19737fi
19738
19739if test "$HAVE_GETHOSTBYNAME" != "1"
19740then
19741 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname with both nsl and socket libs" >&5
19742$as_echo_n "checking for gethostbyname with both nsl and socket libs... " >&6; }
19743 my_ac_save_LIBS=$LIBS
19744 LIBS="-lnsl -lsocket $LIBS"
19745 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19746/* end confdefs.h. */
19747
19748
19749
19750int main (void)
19751{
19752
19753 gethostbyname();
19754
19755 ;
19756 return 0;
19757}
19758
19759_ACEOF
19760if ac_fn_c_try_link "$LINENO"; then :
19761
19762 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19763$as_echo "yes" >&6; }
19764 HAVE_GETHOSTBYNAME="1"
19765
19766else
19767
19768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19769$as_echo "no" >&6; }
19770 LIBS=$my_ac_save_LIBS
19771
19772fi
19773rm -f core conftest.err conftest.$ac_objext \
19774 conftest$ac_exeext conftest.$ac_ext
19775fi
19776
19777if test "$HAVE_GETHOSTBYNAME" != "1"
19778then
19779 if test "$curl_cv_header_windows_h" = "yes"; then
19780 if test "$curl_cv_header_winsock_h" = "yes"; then
19781 case $host in
19782 *-*-mingw32ce*)
19783 winsock_LIB="-lwinsock"
19784 ;;
19785 *)
19786 winsock_LIB="-lwsock32"
19787 ;;
19788 esac
19789 fi
19790 if test "$curl_cv_header_winsock2_h" = "yes"; then
19791 winsock_LIB="-lws2_32"
19792 fi
19793 if test ! -z "$winsock_LIB"; then
19794 my_ac_save_LIBS=$LIBS
19795 LIBS="$winsock_LIB $LIBS"
19796 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in $winsock_LIB" >&5
19797$as_echo_n "checking for gethostbyname in $winsock_LIB... " >&6; }
19798 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19799/* end confdefs.h. */
19800
19801
19802#ifdef HAVE_WINDOWS_H
19803#ifndef WIN32_LEAN_AND_MEAN
19804#define WIN32_LEAN_AND_MEAN
19805#endif
19806#include <windows.h>
19807#ifdef HAVE_WINSOCK2_H
19808#include <winsock2.h>
19809#else
19810#ifdef HAVE_WINSOCK_H
19811#include <winsock.h>
19812#endif
19813#endif
19814#endif
19815
19816int main (void)
19817{
19818
19819 gethostbyname("www.dummysite.com");
19820
19821 ;
19822 return 0;
19823}
19824
19825_ACEOF
19826if ac_fn_c_try_link "$LINENO"; then :
19827
19828 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19829$as_echo "yes" >&6; }
19830 HAVE_GETHOSTBYNAME="1"
19831
19832else
19833
19834 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19835$as_echo "no" >&6; }
19836 winsock_LIB=""
19837 LIBS=$my_ac_save_LIBS
19838
19839fi
19840rm -f core conftest.err conftest.$ac_objext \
19841 conftest$ac_exeext conftest.$ac_ext
19842 fi
19843 fi
19844fi
19845
19846if test "$HAVE_GETHOSTBYNAME" != "1"
19847then
19848 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname for Minix 3" >&5
19849$as_echo_n "checking for gethostbyname for Minix 3... " >&6; }
19850 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19851/* end confdefs.h. */
19852
19853
19854/* Older Minix versions may need <net/gen/netdb.h> here instead */
19855#include <netdb.h>
19856
19857int main (void)
19858{
19859
19860 gethostbyname("www.dummysite.com");
19861
19862 ;
19863 return 0;
19864}
19865
19866_ACEOF
19867if ac_fn_c_try_link "$LINENO"; then :
19868
19869 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19870$as_echo "yes" >&6; }
19871 HAVE_GETHOSTBYNAME="1"
19872
19873else
19874
19875 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19876$as_echo "no" >&6; }
19877
19878fi
19879rm -f core conftest.err conftest.$ac_objext \
19880 conftest$ac_exeext conftest.$ac_ext
19881fi
19882
19883if test "$HAVE_GETHOSTBYNAME" != "1"
19884then
19885 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname for eCos" >&5
19886$as_echo_n "checking for gethostbyname for eCos... " >&6; }
19887 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19888/* end confdefs.h. */
19889
19890
19891#include <stdio.h>
19892#include <netdb.h>
19893
19894int main (void)
19895{
19896
19897 gethostbyname("www.dummysite.com");
19898
19899 ;
19900 return 0;
19901}
19902
19903_ACEOF
19904if ac_fn_c_try_link "$LINENO"; then :
19905
19906 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19907$as_echo "yes" >&6; }
19908 HAVE_GETHOSTBYNAME="1"
19909
19910else
19911
19912 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19913$as_echo "no" >&6; }
19914
19915fi
19916rm -f core conftest.err conftest.$ac_objext \
19917 conftest$ac_exeext conftest.$ac_ext
19918fi
19919
19920if test "$HAVE_GETHOSTBYNAME" != "1"
19921then
Haibo Huang65021c72019-03-27 15:37:23 -070019922 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname for AmigaOS bsdsocket.library" >&5
19923$as_echo_n "checking for gethostbyname for AmigaOS bsdsocket.library... " >&6; }
19924 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19925/* end confdefs.h. */
19926
19927
19928#include <proto/bsdsocket.h>
19929struct Library *SocketBase = NULL;
19930
19931int main (void)
19932{
19933
19934 gethostbyname("www.dummysite.com");
19935
19936 ;
19937 return 0;
19938}
19939
19940_ACEOF
19941if ac_fn_c_try_link "$LINENO"; then :
19942
19943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19944$as_echo "yes" >&6; }
19945 HAVE_GETHOSTBYNAME="1"
19946 HAVE_PROTO_BSDSOCKET_H="1"
19947
19948$as_echo "#define HAVE_PROTO_BSDSOCKET_H 1" >>confdefs.h
19949
19950 HAVE_PROTO_BSDSOCKET_H=1
19951
19952
19953else
19954
19955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19956$as_echo "no" >&6; }
19957
19958fi
19959rm -f core conftest.err conftest.$ac_objext \
19960 conftest$ac_exeext conftest.$ac_ext
19961fi
19962
19963if test "$HAVE_GETHOSTBYNAME" != "1"
19964then
Elliott Hughes82be86d2017-09-20 17:00:17 -070019965 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lnetwork" >&5
19966$as_echo_n "checking for gethostbyname in -lnetwork... " >&6; }
19967if ${ac_cv_lib_network_gethostbyname+:} false; then :
19968 $as_echo_n "(cached) " >&6
19969else
19970 ac_check_lib_save_LIBS=$LIBS
19971LIBS="-lnetwork $LIBS"
19972cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19973/* end confdefs.h. */
19974
19975
19976#ifdef __cplusplus
19977extern "C"
19978#endif
19979char gethostbyname ();
19980int main (void)
19981{
19982return gethostbyname ();
19983 ;
19984 return 0;
19985}
19986_ACEOF
19987if ac_fn_c_try_link "$LINENO"; then :
19988 ac_cv_lib_network_gethostbyname=yes
19989else
19990 ac_cv_lib_network_gethostbyname=no
19991fi
19992rm -f core conftest.err conftest.$ac_objext \
19993 conftest$ac_exeext conftest.$ac_ext
19994LIBS=$ac_check_lib_save_LIBS
19995fi
19996{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_network_gethostbyname" >&5
19997$as_echo "$ac_cv_lib_network_gethostbyname" >&6; }
19998if test "x$ac_cv_lib_network_gethostbyname" = xyes; then :
19999 HAVE_GETHOSTBYNAME="1"
20000 LIBS="-lnetwork $LIBS"
20001
20002fi
20003
20004fi
20005
20006if test "$HAVE_GETHOSTBYNAME" != "1"
20007then
20008 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lnet" >&5
20009$as_echo_n "checking for gethostbyname in -lnet... " >&6; }
20010if ${ac_cv_lib_net_gethostbyname+:} false; then :
20011 $as_echo_n "(cached) " >&6
20012else
20013 ac_check_lib_save_LIBS=$LIBS
20014LIBS="-lnet $LIBS"
20015cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20016/* end confdefs.h. */
20017
20018
20019#ifdef __cplusplus
20020extern "C"
20021#endif
20022char gethostbyname ();
20023int main (void)
20024{
20025return gethostbyname ();
20026 ;
20027 return 0;
20028}
20029_ACEOF
20030if ac_fn_c_try_link "$LINENO"; then :
20031 ac_cv_lib_net_gethostbyname=yes
20032else
20033 ac_cv_lib_net_gethostbyname=no
20034fi
20035rm -f core conftest.err conftest.$ac_objext \
20036 conftest$ac_exeext conftest.$ac_ext
20037LIBS=$ac_check_lib_save_LIBS
20038fi
20039{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_net_gethostbyname" >&5
20040$as_echo "$ac_cv_lib_net_gethostbyname" >&6; }
20041if test "x$ac_cv_lib_net_gethostbyname" = xyes; then :
20042 HAVE_GETHOSTBYNAME="1"
20043 LIBS="-lnet $LIBS"
20044
20045fi
20046
20047fi
20048
20049
20050if test "$HAVE_GETHOSTBYNAME" != "1"; then
20051 as_fn_error $? "couldn't find libraries for gethostbyname()" "$LINENO" 5
20052fi
20053
20054
20055curl_includes_winsock2="\
20056/* includes start */
20057#ifdef HAVE_WINDOWS_H
20058# ifndef WIN32_LEAN_AND_MEAN
20059# define WIN32_LEAN_AND_MEAN
20060# endif
20061# include <windows.h>
20062# ifdef HAVE_WINSOCK2_H
20063# include <winsock2.h>
20064# else
20065# ifdef HAVE_WINSOCK_H
20066# include <winsock.h>
20067# endif
20068# endif
20069#endif
20070/* includes end */"
20071
20072 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for windows.h" >&5
20073$as_echo_n "checking for windows.h... " >&6; }
20074if ${curl_cv_header_windows_h+:} false; then :
20075 $as_echo_n "(cached) " >&6
20076else
20077
20078 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20079/* end confdefs.h. */
20080
20081
20082#undef inline
20083#ifndef WIN32_LEAN_AND_MEAN
20084#define WIN32_LEAN_AND_MEAN
20085#endif
20086#include <windows.h>
20087
20088int main (void)
20089{
20090
20091#if defined(__CYGWIN__) || defined(__CEGCC__)
20092 HAVE_WINDOWS_H shall not be defined.
20093#else
20094 int dummy=2*WINVER;
20095#endif
20096
20097 ;
20098 return 0;
20099}
20100
20101_ACEOF
20102if ac_fn_c_try_compile "$LINENO"; then :
20103
20104 curl_cv_header_windows_h="yes"
20105
20106else
20107
20108 curl_cv_header_windows_h="no"
20109
20110fi
20111rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20112
20113fi
20114{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_windows_h" >&5
20115$as_echo "$curl_cv_header_windows_h" >&6; }
20116 case "$curl_cv_header_windows_h" in
20117 yes)
20118
20119cat >>confdefs.h <<_ACEOF
20120#define HAVE_WINDOWS_H 1
20121_ACEOF
20122
20123 ;;
20124 esac
20125
20126
20127 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for winsock.h" >&5
20128$as_echo_n "checking for winsock.h... " >&6; }
20129if ${curl_cv_header_winsock_h+:} false; then :
20130 $as_echo_n "(cached) " >&6
20131else
20132
20133 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20134/* end confdefs.h. */
20135
20136
20137#undef inline
20138#ifndef WIN32_LEAN_AND_MEAN
20139#define WIN32_LEAN_AND_MEAN
20140#endif
20141#include <windows.h>
20142#include <winsock.h>
20143
20144int main (void)
20145{
20146
20147#if defined(__CYGWIN__) || defined(__CEGCC__)
20148 HAVE_WINSOCK_H shall not be defined.
20149#else
20150 int dummy=WSACleanup();
20151#endif
20152
20153 ;
20154 return 0;
20155}
20156
20157_ACEOF
20158if ac_fn_c_try_compile "$LINENO"; then :
20159
20160 curl_cv_header_winsock_h="yes"
20161
20162else
20163
20164 curl_cv_header_winsock_h="no"
20165
20166fi
20167rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20168
20169fi
20170{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_winsock_h" >&5
20171$as_echo "$curl_cv_header_winsock_h" >&6; }
20172 case "$curl_cv_header_winsock_h" in
20173 yes)
20174
20175cat >>confdefs.h <<_ACEOF
20176#define HAVE_WINSOCK_H 1
20177_ACEOF
20178
20179 ;;
20180 esac
20181
20182
20183 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for winsock2.h" >&5
20184$as_echo_n "checking for winsock2.h... " >&6; }
20185if ${curl_cv_header_winsock2_h+:} false; then :
20186 $as_echo_n "(cached) " >&6
20187else
20188
20189 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20190/* end confdefs.h. */
20191
20192
20193#undef inline
20194#ifndef WIN32_LEAN_AND_MEAN
20195#define WIN32_LEAN_AND_MEAN
20196#endif
20197#include <windows.h>
20198#include <winsock2.h>
20199
20200int main (void)
20201{
20202
20203#if defined(__CYGWIN__) || defined(__CEGCC__) || defined(__MINGW32CE__)
20204 HAVE_WINSOCK2_H shall not be defined.
20205#else
20206 int dummy=2*IPPROTO_ESP;
20207#endif
20208
20209 ;
20210 return 0;
20211}
20212
20213_ACEOF
20214if ac_fn_c_try_compile "$LINENO"; then :
20215
20216 curl_cv_header_winsock2_h="yes"
20217
20218else
20219
20220 curl_cv_header_winsock2_h="no"
20221
20222fi
20223rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20224
20225fi
20226{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_winsock2_h" >&5
20227$as_echo "$curl_cv_header_winsock2_h" >&6; }
20228 case "$curl_cv_header_winsock2_h" in
20229 yes)
20230
20231cat >>confdefs.h <<_ACEOF
20232#define HAVE_WINSOCK2_H 1
20233_ACEOF
20234
20235 ;;
20236 esac
20237
20238
20239
Haibo Huang65021c72019-03-27 15:37:23 -070020240curl_includes_bsdsocket="\
20241/* includes start */
20242#ifdef HAVE_PROTO_BSDSOCKET_H
20243# include <proto/bsdsocket.h>
20244 struct Library *SocketBase = NULL;
20245#endif
20246/* includes end */"
20247 for ac_header in proto/bsdsocket.h
20248do :
20249 ac_fn_c_check_header_compile "$LINENO" "proto/bsdsocket.h" "ac_cv_header_proto_bsdsocket_h" " $curl_includes_bsdsocket
20250"
20251if test "x$ac_cv_header_proto_bsdsocket_h" = xyes; then :
20252 cat >>confdefs.h <<_ACEOF
20253#define HAVE_PROTO_BSDSOCKET_H 1
20254_ACEOF
20255
20256fi
20257
20258done
20259
20260
20261
20262 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for connect in libraries" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070020263$as_echo_n "checking for connect in libraries... " >&6; }
20264 tst_connect_save_LIBS="$LIBS"
20265 tst_connect_need_LIBS="unknown"
20266 for tst_lib in '' '-lsocket' ; do
20267 if test "$tst_connect_need_LIBS" = "unknown"; then
20268 LIBS="$tst_lib $tst_connect_save_LIBS"
20269 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20270/* end confdefs.h. */
20271
20272
20273 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070020274 $curl_includes_bsdsocket
20275 #if !defined(HAVE_WINDOWS_H) && !defined(HAVE_PROTO_BSDSOCKET_H)
Elliott Hughes82be86d2017-09-20 17:00:17 -070020276 int connect(int, void*, int);
20277 #endif
20278
20279int main (void)
20280{
20281
20282 if(0 != connect(0, 0, 0))
20283 return 1;
20284
20285 ;
20286 return 0;
20287}
20288
20289_ACEOF
20290if ac_fn_c_try_link "$LINENO"; then :
20291
20292 tst_connect_need_LIBS="$tst_lib"
20293
20294fi
20295rm -f core conftest.err conftest.$ac_objext \
20296 conftest$ac_exeext conftest.$ac_ext
20297 fi
20298 done
20299 LIBS="$tst_connect_save_LIBS"
20300 #
20301 case X-"$tst_connect_need_LIBS" in
20302 X-unknown)
20303 { $as_echo "$as_me:${as_lineno-$LINENO}: result: cannot find connect" >&5
20304$as_echo "cannot find connect" >&6; }
20305 as_fn_error $? "cannot find connect function in libraries." "$LINENO" 5
20306 ;;
20307 X-)
20308 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
20309$as_echo "yes" >&6; }
20310 ;;
20311 *)
20312 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tst_connect_need_LIBS" >&5
20313$as_echo "$tst_connect_need_LIBS" >&6; }
20314 LIBS="$tst_connect_need_LIBS $tst_connect_save_LIBS"
20315 ;;
20316 esac
20317
20318
20319CURL_NETWORK_LIBS=$LIBS
20320
20321{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
20322$as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
20323if ${ac_cv_header_time+:} false; then :
20324 $as_echo_n "(cached) " >&6
20325else
20326 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20327/* end confdefs.h. */
20328#include <sys/types.h>
20329#include <sys/time.h>
20330#include <time.h>
20331
20332int main (void)
20333{
20334if ((struct tm *) 0)
20335return 0;
20336 ;
20337 return 0;
20338}
20339_ACEOF
20340if ac_fn_c_try_compile "$LINENO"; then :
20341 ac_cv_header_time=yes
20342else
20343 ac_cv_header_time=no
20344fi
20345rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20346fi
20347{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
20348$as_echo "$ac_cv_header_time" >&6; }
20349if test $ac_cv_header_time = yes; then
20350
20351$as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
20352
20353fi
20354
20355
20356 for ac_header in sys/types.h sys/time.h time.h
20357do :
20358 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
20359ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
20360if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
20361 cat >>confdefs.h <<_ACEOF
20362#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
20363_ACEOF
20364
20365fi
20366
20367done
20368
20369 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for monotonic clock_gettime" >&5
20370$as_echo_n "checking for monotonic clock_gettime... " >&6; }
20371 #
20372 if test "x$dontwant_rt" = "xno" ; then
20373 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20374/* end confdefs.h. */
20375
20376
20377#ifdef HAVE_SYS_TYPES_H
20378#include <sys/types.h>
20379#endif
20380#ifdef HAVE_SYS_TIME_H
20381#include <sys/time.h>
20382#ifdef TIME_WITH_SYS_TIME
20383#include <time.h>
20384#endif
20385#else
20386#ifdef HAVE_TIME_H
20387#include <time.h>
20388#endif
20389#endif
20390
20391int main (void)
20392{
20393
20394 struct timespec ts;
20395 (void)clock_gettime(CLOCK_MONOTONIC, &ts);
20396
20397 ;
20398 return 0;
20399}
20400
20401_ACEOF
20402if ac_fn_c_try_compile "$LINENO"; then :
20403
20404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
20405$as_echo "yes" >&6; }
20406 curl_func_clock_gettime="yes"
20407
20408else
20409
20410 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20411$as_echo "no" >&6; }
20412 curl_func_clock_gettime="no"
20413
20414fi
20415rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20416 fi
20417
20418
20419 #
20420 if test "$curl_func_clock_gettime" = "yes"; then
20421 #
20422 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clock_gettime in libraries" >&5
20423$as_echo_n "checking for clock_gettime in libraries... " >&6; }
20424 #
20425 curl_cv_save_LIBS="$LIBS"
20426 curl_cv_gclk_LIBS="unknown"
20427 #
20428 for x_xlibs in '' '-lrt' '-lposix4' ; do
20429 if test "$curl_cv_gclk_LIBS" = "unknown"; then
20430 if test -z "$x_xlibs"; then
20431 LIBS="$curl_cv_save_LIBS"
20432 else
20433 LIBS="$x_xlibs $curl_cv_save_LIBS"
20434 fi
20435 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20436/* end confdefs.h. */
20437
20438
20439#ifdef HAVE_SYS_TYPES_H
20440#include <sys/types.h>
20441#endif
20442#ifdef HAVE_SYS_TIME_H
20443#include <sys/time.h>
20444#ifdef TIME_WITH_SYS_TIME
20445#include <time.h>
20446#endif
20447#else
20448#ifdef HAVE_TIME_H
20449#include <time.h>
20450#endif
20451#endif
20452
20453int main (void)
20454{
20455
20456 struct timespec ts;
20457 (void)clock_gettime(CLOCK_MONOTONIC, &ts);
20458
20459 ;
20460 return 0;
20461}
20462
20463_ACEOF
20464if ac_fn_c_try_link "$LINENO"; then :
20465
20466 curl_cv_gclk_LIBS="$x_xlibs"
20467
20468fi
20469rm -f core conftest.err conftest.$ac_objext \
20470 conftest$ac_exeext conftest.$ac_ext
20471 fi
20472 done
20473 #
20474 LIBS="$curl_cv_save_LIBS"
20475 #
20476 case X-"$curl_cv_gclk_LIBS" in
20477 X-unknown)
20478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: cannot find clock_gettime" >&5
20479$as_echo "cannot find clock_gettime" >&6; }
20480 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: HAVE_CLOCK_GETTIME_MONOTONIC will not be defined" >&5
20481$as_echo "$as_me: WARNING: HAVE_CLOCK_GETTIME_MONOTONIC will not be defined" >&2;}
20482 curl_func_clock_gettime="no"
20483 ;;
20484 X-)
20485 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no additional lib required" >&5
20486$as_echo "no additional lib required" >&6; }
20487 curl_func_clock_gettime="yes"
20488 ;;
20489 *)
20490 if test -z "$curl_cv_save_LIBS"; then
20491 LIBS="$curl_cv_gclk_LIBS"
20492 else
20493 LIBS="$curl_cv_gclk_LIBS $curl_cv_save_LIBS"
20494 fi
20495 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_gclk_LIBS" >&5
20496$as_echo "$curl_cv_gclk_LIBS" >&6; }
20497 curl_func_clock_gettime="yes"
20498 ;;
20499 esac
20500 #
20501 if test "x$cross_compiling" != "xyes" &&
20502 test "$curl_func_clock_gettime" = "yes"; then
20503 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if monotonic clock_gettime works" >&5
20504$as_echo_n "checking if monotonic clock_gettime works... " >&6; }
Elliott Hughesa93fb052018-12-12 14:22:48 -080020505
20506
20507 old=$LD_LIBRARY_PATH
20508 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
20509 export LD_LIBRARY_PATH
20510 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070020511 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
20512$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
20513as_fn_error $? "cannot run test program while cross compiling
20514See \`config.log' for more details" "$LINENO" 5; }
20515else
20516 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20517/* end confdefs.h. */
20518
20519
20520#ifdef HAVE_STDLIB_H
20521#include <stdlib.h>
20522#endif
20523#ifdef HAVE_SYS_TYPES_H
20524#include <sys/types.h>
20525#endif
20526#ifdef HAVE_SYS_TIME_H
20527#include <sys/time.h>
20528#ifdef TIME_WITH_SYS_TIME
20529#include <time.h>
20530#endif
20531#else
20532#ifdef HAVE_TIME_H
20533#include <time.h>
20534#endif
20535#endif
20536
20537int main (void)
20538{
20539
20540 struct timespec ts;
20541 if (0 == clock_gettime(CLOCK_MONOTONIC, &ts))
20542 exit(0);
20543 else
20544 exit(1);
20545
20546 ;
20547 return 0;
20548}
20549
20550_ACEOF
20551if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughesa93fb052018-12-12 14:22:48 -080020552 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070020553$as_echo "yes" >&6; }
20554
20555else
Elliott Hughesa93fb052018-12-12 14:22:48 -080020556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070020557$as_echo "no" >&6; }
20558 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: HAVE_CLOCK_GETTIME_MONOTONIC will not be defined" >&5
20559$as_echo "$as_me: WARNING: HAVE_CLOCK_GETTIME_MONOTONIC will not be defined" >&2;}
20560 curl_func_clock_gettime="no"
20561 LIBS="$curl_cv_save_LIBS"
20562
20563fi
20564rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20565 conftest.$ac_objext conftest.beam conftest.$ac_ext
20566fi
20567
Elliott Hughesa93fb052018-12-12 14:22:48 -080020568 LD_LIBRARY_PATH=$old # restore
20569
Elliott Hughes82be86d2017-09-20 17:00:17 -070020570 fi
20571 #
20572 case "$curl_func_clock_gettime" in
20573 yes)
20574
20575cat >>confdefs.h <<_ACEOF
20576#define HAVE_CLOCK_GETTIME_MONOTONIC 1
20577_ACEOF
20578
20579 ;;
20580 esac
20581 #
20582 fi
20583 #
20584
20585
20586CURL_NETWORK_AND_TIME_LIBS=$LIBS
20587
20588
20589
20590clean_CPPFLAGS=$CPPFLAGS
20591clean_LDFLAGS=$LDFLAGS
20592clean_LIBS=$LIBS
20593ZLIB_LIBS=""
20594
20595# Check whether --with-zlib was given.
20596if test "${with_zlib+set}" = set; then :
20597 withval=$with_zlib; OPT_ZLIB="$withval"
20598fi
20599
20600
20601if test "$OPT_ZLIB" = "no" ; then
20602 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: zlib disabled" >&5
20603$as_echo "$as_me: WARNING: zlib disabled" >&2;}
20604else
20605 if test "$OPT_ZLIB" = "yes" ; then
20606 OPT_ZLIB=""
20607 fi
20608
20609 if test -z "$OPT_ZLIB" ; then
20610
20611 if test -n "$PKG_CONFIG"; then
20612 PKGCONFIG="$PKG_CONFIG"
20613 else
20614 if test -n "$ac_tool_prefix"; then
20615 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
20616set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
20617{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
20618$as_echo_n "checking for $ac_word... " >&6; }
20619if ${ac_cv_path_PKGCONFIG+:} false; then :
20620 $as_echo_n "(cached) " >&6
20621else
20622 case $PKGCONFIG in
20623 [\\/]* | ?:[\\/]*)
20624 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
20625 ;;
20626 *)
20627 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
20628as_dummy="$PATH:/usr/bin:/usr/local/bin"
20629for as_dir in $as_dummy
20630do
20631 IFS=$as_save_IFS
20632 test -z "$as_dir" && as_dir=.
20633 for ac_exec_ext in '' $ac_executable_extensions; do
20634 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
20635 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
20636 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
20637 break 2
20638 fi
20639done
20640 done
20641IFS=$as_save_IFS
20642
20643 ;;
20644esac
20645fi
20646PKGCONFIG=$ac_cv_path_PKGCONFIG
20647if test -n "$PKGCONFIG"; then
20648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
20649$as_echo "$PKGCONFIG" >&6; }
20650else
20651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20652$as_echo "no" >&6; }
20653fi
20654
20655
20656fi
20657if test -z "$ac_cv_path_PKGCONFIG"; then
20658 ac_pt_PKGCONFIG=$PKGCONFIG
20659 # Extract the first word of "pkg-config", so it can be a program name with args.
20660set dummy pkg-config; ac_word=$2
20661{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
20662$as_echo_n "checking for $ac_word... " >&6; }
20663if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
20664 $as_echo_n "(cached) " >&6
20665else
20666 case $ac_pt_PKGCONFIG in
20667 [\\/]* | ?:[\\/]*)
20668 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
20669 ;;
20670 *)
20671 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
20672as_dummy="$PATH:/usr/bin:/usr/local/bin"
20673for as_dir in $as_dummy
20674do
20675 IFS=$as_save_IFS
20676 test -z "$as_dir" && as_dir=.
20677 for ac_exec_ext in '' $ac_executable_extensions; do
20678 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
20679 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
20680 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
20681 break 2
20682 fi
20683done
20684 done
20685IFS=$as_save_IFS
20686
20687 ;;
20688esac
20689fi
20690ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
20691if test -n "$ac_pt_PKGCONFIG"; then
20692 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
20693$as_echo "$ac_pt_PKGCONFIG" >&6; }
20694else
20695 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20696$as_echo "no" >&6; }
20697fi
20698
20699 if test "x$ac_pt_PKGCONFIG" = x; then
20700 PKGCONFIG="no"
20701 else
20702 case $cross_compiling:$ac_tool_warned in
20703yes:)
20704{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
20705$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
20706ac_tool_warned=yes ;;
20707esac
20708 PKGCONFIG=$ac_pt_PKGCONFIG
20709 fi
20710else
20711 PKGCONFIG="$ac_cv_path_PKGCONFIG"
20712fi
20713
20714 fi
20715
20716 if test "x$PKGCONFIG" != "xno"; then
20717 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for zlib options with pkg-config" >&5
20718$as_echo_n "checking for zlib options with pkg-config... " >&6; }
20719 itexists=`
20720 if test -n ""; then
20721 PKG_CONFIG_LIBDIR=""
20722 export PKG_CONFIG_LIBDIR
20723 fi
20724 $PKGCONFIG --exists zlib >/dev/null 2>&1 && echo 1`
20725
20726 if test -z "$itexists"; then
20727 PKGCONFIG="no"
20728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20729$as_echo "no" >&6; }
20730 else
20731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
20732$as_echo "found" >&6; }
20733 fi
20734 fi
20735
20736
20737 if test "$PKGCONFIG" != "no" ; then
20738 LIBS="`$PKGCONFIG --libs-only-l zlib` $LIBS"
20739 LDFLAGS="$LDFLAGS `$PKGCONFIG --libs-only-L zlib`"
20740 CPPFLAGS="$CPPFLAGS `$PKGCONFIG --cflags-only-I zlib`"
20741 OPT_ZLIB=""
20742 HAVE_LIBZ="1"
20743 fi
20744
20745 if test -z "$HAVE_LIBZ"; then
20746
20747
20748 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inflateEnd in -lz" >&5
20749$as_echo_n "checking for inflateEnd in -lz... " >&6; }
20750if ${ac_cv_lib_z_inflateEnd+:} false; then :
20751 $as_echo_n "(cached) " >&6
20752else
20753 ac_check_lib_save_LIBS=$LIBS
20754LIBS="-lz $LIBS"
20755cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20756/* end confdefs.h. */
20757
20758
20759#ifdef __cplusplus
20760extern "C"
20761#endif
20762char inflateEnd ();
20763int main (void)
20764{
20765return inflateEnd ();
20766 ;
20767 return 0;
20768}
20769_ACEOF
20770if ac_fn_c_try_link "$LINENO"; then :
20771 ac_cv_lib_z_inflateEnd=yes
20772else
20773 ac_cv_lib_z_inflateEnd=no
20774fi
20775rm -f core conftest.err conftest.$ac_objext \
20776 conftest$ac_exeext conftest.$ac_ext
20777LIBS=$ac_check_lib_save_LIBS
20778fi
20779{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_inflateEnd" >&5
20780$as_echo "$ac_cv_lib_z_inflateEnd" >&6; }
20781if test "x$ac_cv_lib_z_inflateEnd" = xyes; then :
20782 HAVE_LIBZ="1"
20783 LIBS="-lz $LIBS"
20784else
20785 OPT_ZLIB="/usr/local"
20786fi
20787
20788 fi
20789 fi
20790
20791 if test -n "$OPT_ZLIB"; then
20792 CPPFLAGS="$CPPFLAGS -I$OPT_ZLIB/include"
20793 LDFLAGS="$LDFLAGS -L$OPT_ZLIB/lib$libsuff"
20794 fi
20795
20796 ac_fn_c_check_header_mongrel "$LINENO" "zlib.h" "ac_cv_header_zlib_h" "$ac_includes_default"
20797if test "x$ac_cv_header_zlib_h" = xyes; then :
20798
20799 HAVE_ZLIB_H="1"
20800 if test "$HAVE_LIBZ" != "1"; then
20801 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gzread in -lz" >&5
20802$as_echo_n "checking for gzread in -lz... " >&6; }
20803if ${ac_cv_lib_z_gzread+:} false; then :
20804 $as_echo_n "(cached) " >&6
20805else
20806 ac_check_lib_save_LIBS=$LIBS
20807LIBS="-lz $LIBS"
20808cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20809/* end confdefs.h. */
20810
20811
20812#ifdef __cplusplus
20813extern "C"
20814#endif
20815char gzread ();
20816int main (void)
20817{
20818return gzread ();
20819 ;
20820 return 0;
20821}
20822_ACEOF
20823if ac_fn_c_try_link "$LINENO"; then :
20824 ac_cv_lib_z_gzread=yes
20825else
20826 ac_cv_lib_z_gzread=no
20827fi
20828rm -f core conftest.err conftest.$ac_objext \
20829 conftest$ac_exeext conftest.$ac_ext
20830LIBS=$ac_check_lib_save_LIBS
20831fi
20832{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_gzread" >&5
20833$as_echo "$ac_cv_lib_z_gzread" >&6; }
20834if test "x$ac_cv_lib_z_gzread" = xyes; then :
20835
20836 HAVE_LIBZ="1"
20837 LIBS="-lz $LIBS"
20838
20839else
20840 CPPFLAGS=$clean_CPPFLAGS
20841 LDFLAGS=$clean_LDFLAGS
20842fi
20843
20844 fi
20845
20846else
20847
20848 CPPFLAGS=$clean_CPPFLAGS
20849 LDFLAGS=$clean_LDFLAGS
20850
20851fi
20852
20853
20854
20855 if test "$HAVE_LIBZ" = "1" && test "$HAVE_ZLIB_H" != "1"
20856 then
20857 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: configure found only the libz lib, not the header file!" >&5
20858$as_echo "$as_me: WARNING: configure found only the libz lib, not the header file!" >&2;}
20859 HAVE_LIBZ=""
20860 CPPFLAGS=$clean_CPPFLAGS
20861 LDFLAGS=$clean_LDFLAGS
20862 LIBS=$clean_LIBS
20863 elif test "$HAVE_LIBZ" != "1" && test "$HAVE_ZLIB_H" = "1"
20864 then
20865 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: configure found only the libz header file, not the lib!" >&5
20866$as_echo "$as_me: WARNING: configure found only the libz header file, not the lib!" >&2;}
20867 CPPFLAGS=$clean_CPPFLAGS
20868 LDFLAGS=$clean_LDFLAGS
20869 LIBS=$clean_LIBS
20870 elif test "$HAVE_LIBZ" = "1" && test "$HAVE_ZLIB_H" = "1"
20871 then
20872
20873
20874$as_echo "#define HAVE_ZLIB_H 1" >>confdefs.h
20875
20876
20877$as_echo "#define HAVE_LIBZ 1" >>confdefs.h
20878
20879
20880 ZLIB_LIBS="-lz"
20881 LIBS="-lz $clean_LIBS"
20882
20883 AMFIXLIB="1"
20884 { $as_echo "$as_me:${as_lineno-$LINENO}: found both libz and libz.h header" >&5
20885$as_echo "$as_me: found both libz and libz.h header" >&6;}
20886 curl_zlib_msg="enabled"
20887 fi
20888fi
20889
20890 if test x"$AMFIXLIB" = x1; then
20891 HAVE_LIBZ_TRUE=
20892 HAVE_LIBZ_FALSE='#'
20893else
20894 HAVE_LIBZ_TRUE='#'
20895 HAVE_LIBZ_FALSE=
20896fi
20897
20898
20899
20900
Alex Deymo486467e2017-12-19 19:04:07 +010020901
20902OPT_BROTLI=off
20903
20904# Check whether --with-brotli was given.
20905if test "${with_brotli+set}" = set; then :
20906 withval=$with_brotli; OPT_BROTLI=$withval
20907fi
20908
20909
20910if test X"$OPT_BROTLI" != Xno; then
20911 CLEANLDFLAGS="$LDFLAGS"
20912 CLEANCPPFLAGS="$CPPFLAGS"
20913 CLEANLIBS="$LIBS"
20914
20915 case "$OPT_BROTLI" in
20916 yes)
20917
20918 if test -n "$PKG_CONFIG"; then
20919 PKGCONFIG="$PKG_CONFIG"
20920 else
20921 if test -n "$ac_tool_prefix"; then
20922 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
20923set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
20924{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
20925$as_echo_n "checking for $ac_word... " >&6; }
20926if ${ac_cv_path_PKGCONFIG+:} false; then :
20927 $as_echo_n "(cached) " >&6
20928else
20929 case $PKGCONFIG in
20930 [\\/]* | ?:[\\/]*)
20931 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
20932 ;;
20933 *)
20934 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
20935as_dummy="$PATH:/usr/bin:/usr/local/bin"
20936for as_dir in $as_dummy
20937do
20938 IFS=$as_save_IFS
20939 test -z "$as_dir" && as_dir=.
20940 for ac_exec_ext in '' $ac_executable_extensions; do
20941 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
20942 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
20943 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
20944 break 2
20945 fi
20946done
20947 done
20948IFS=$as_save_IFS
20949
20950 ;;
20951esac
20952fi
20953PKGCONFIG=$ac_cv_path_PKGCONFIG
20954if test -n "$PKGCONFIG"; then
20955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
20956$as_echo "$PKGCONFIG" >&6; }
20957else
20958 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20959$as_echo "no" >&6; }
20960fi
20961
20962
20963fi
20964if test -z "$ac_cv_path_PKGCONFIG"; then
20965 ac_pt_PKGCONFIG=$PKGCONFIG
20966 # Extract the first word of "pkg-config", so it can be a program name with args.
20967set dummy pkg-config; ac_word=$2
20968{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
20969$as_echo_n "checking for $ac_word... " >&6; }
20970if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
20971 $as_echo_n "(cached) " >&6
20972else
20973 case $ac_pt_PKGCONFIG in
20974 [\\/]* | ?:[\\/]*)
20975 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
20976 ;;
20977 *)
20978 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
20979as_dummy="$PATH:/usr/bin:/usr/local/bin"
20980for as_dir in $as_dummy
20981do
20982 IFS=$as_save_IFS
20983 test -z "$as_dir" && as_dir=.
20984 for ac_exec_ext in '' $ac_executable_extensions; do
20985 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
20986 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
20987 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
20988 break 2
20989 fi
20990done
20991 done
20992IFS=$as_save_IFS
20993
20994 ;;
20995esac
20996fi
20997ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
20998if test -n "$ac_pt_PKGCONFIG"; then
20999 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
21000$as_echo "$ac_pt_PKGCONFIG" >&6; }
21001else
21002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21003$as_echo "no" >&6; }
21004fi
21005
21006 if test "x$ac_pt_PKGCONFIG" = x; then
21007 PKGCONFIG="no"
21008 else
21009 case $cross_compiling:$ac_tool_warned in
21010yes:)
21011{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
21012$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
21013ac_tool_warned=yes ;;
21014esac
21015 PKGCONFIG=$ac_pt_PKGCONFIG
21016 fi
21017else
21018 PKGCONFIG="$ac_cv_path_PKGCONFIG"
21019fi
21020
21021 fi
21022
21023 if test "x$PKGCONFIG" != "xno"; then
21024 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libbrotlidec options with pkg-config" >&5
21025$as_echo_n "checking for libbrotlidec options with pkg-config... " >&6; }
21026 itexists=`
21027 if test -n ""; then
21028 PKG_CONFIG_LIBDIR=""
21029 export PKG_CONFIG_LIBDIR
21030 fi
21031 $PKGCONFIG --exists libbrotlidec >/dev/null 2>&1 && echo 1`
21032
21033 if test -z "$itexists"; then
21034 PKGCONFIG="no"
21035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21036$as_echo "no" >&6; }
21037 else
21038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
21039$as_echo "found" >&6; }
21040 fi
21041 fi
21042
21043
21044 if test "$PKGCONFIG" != "no" ; then
21045 LIB_BROTLI=`$PKGCONFIG --libs-only-l libbrotlidec`
21046 LD_BROTLI=`$PKGCONFIG --libs-only-L libbrotlidec`
21047 CPP_BROTLI=`$PKGCONFIG --cflags-only-I libbrotlidec`
21048 version=`$PKGCONFIG --modversion libbrotlidec`
21049 DIR_BROTLI=`echo $LD_BROTLI | $SED -e 's/-L//'`
21050 fi
21051
21052 ;;
21053 off)
21054 ;;
21055 *)
21056 PREFIX_BROTLI=$OPT_BROTLI
21057 ;;
21058 esac
21059
21060 if test -n "$PREFIX_BROTLI"; then
21061 LIB_BROTLI="-lbrotlidec"
21062 LD_BROTLI=-L${PREFIX_BROTLI}/lib$libsuff
21063 CPP_BROTLI=-I${PREFIX_BROTLI}/include
21064 DIR_BROTLI=${PREFIX_BROTLI}/lib$libsuff
21065 fi
21066
21067 LDFLAGS="$LDFLAGS $LD_BROTLI"
21068 CPPFLAGS="$CPPFLAGS $CPP_BROTLI"
21069 LIBS="$LIB_BROTLI $LIBS"
21070
21071 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BrotliDecoderDecompress in -lbrotlidec" >&5
21072$as_echo_n "checking for BrotliDecoderDecompress in -lbrotlidec... " >&6; }
21073if ${ac_cv_lib_brotlidec_BrotliDecoderDecompress+:} false; then :
21074 $as_echo_n "(cached) " >&6
21075else
21076 ac_check_lib_save_LIBS=$LIBS
21077LIBS="-lbrotlidec $LIBS"
21078cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21079/* end confdefs.h. */
21080
21081
21082#ifdef __cplusplus
21083extern "C"
21084#endif
21085char BrotliDecoderDecompress ();
21086int main (void)
21087{
21088return BrotliDecoderDecompress ();
21089 ;
21090 return 0;
21091}
21092_ACEOF
21093if ac_fn_c_try_link "$LINENO"; then :
21094 ac_cv_lib_brotlidec_BrotliDecoderDecompress=yes
21095else
21096 ac_cv_lib_brotlidec_BrotliDecoderDecompress=no
21097fi
21098rm -f core conftest.err conftest.$ac_objext \
21099 conftest$ac_exeext conftest.$ac_ext
21100LIBS=$ac_check_lib_save_LIBS
21101fi
21102{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_brotlidec_BrotliDecoderDecompress" >&5
21103$as_echo "$ac_cv_lib_brotlidec_BrotliDecoderDecompress" >&6; }
21104if test "x$ac_cv_lib_brotlidec_BrotliDecoderDecompress" = xyes; then :
21105 cat >>confdefs.h <<_ACEOF
21106#define HAVE_LIBBROTLIDEC 1
21107_ACEOF
21108
21109 LIBS="-lbrotlidec $LIBS"
21110
21111fi
21112
21113
21114 for ac_header in brotli/decode.h
21115do :
21116 ac_fn_c_check_header_mongrel "$LINENO" "brotli/decode.h" "ac_cv_header_brotli_decode_h" "$ac_includes_default"
21117if test "x$ac_cv_header_brotli_decode_h" = xyes; then :
21118 cat >>confdefs.h <<_ACEOF
21119#define HAVE_BROTLI_DECODE_H 1
21120_ACEOF
21121 curl_brotli_msg="enabled (libbrotlidec)"
21122 HAVE_BROTLI=1
21123
21124$as_echo "#define HAVE_BROTLI 1" >>confdefs.h
21125
21126 HAVE_BROTLI=1
21127
21128
21129fi
21130
21131done
21132
21133
21134 if test X"$OPT_BROTLI" != Xoff &&
21135 test "$HAVE_BROTLI" != "1"; then
21136 as_fn_error $? "BROTLI libs and/or directories were not found where specified!" "$LINENO" 5
21137 fi
21138
21139 if test "$HAVE_BROTLI" = "1"; then
21140 if test -n "$DIR_BROTLI"; then
21141
21142 if test "x$cross_compiling" != "xyes"; then
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070021143 CURL_LIBRARY_PATH="$CURL_LIBRARY_PATH:$DIR_BROTLI"
21144 export CURL_LIBRARY_PATH
21145 { $as_echo "$as_me:${as_lineno-$LINENO}: Added $DIR_BROTLI to CURL_LIBRARY_PATH" >&5
21146$as_echo "$as_me: Added $DIR_BROTLI to CURL_LIBRARY_PATH" >&6;}
Alex Deymo486467e2017-12-19 19:04:07 +010021147 fi
21148 fi
21149 else
21150 LDFLAGS=$CLEANLDFLAGS
21151 CPPFLAGS=$CLEANCPPFLAGS
21152 LIBS=$CLEANLIBS
21153 fi
21154fi
21155
21156
Elliott Hughes82be86d2017-09-20 17:00:17 -070021157LDAPLIBNAME=""
21158
21159# Check whether --with-ldap-lib was given.
21160if test "${with_ldap_lib+set}" = set; then :
21161 withval=$with_ldap_lib; LDAPLIBNAME="$withval"
21162fi
21163
21164
21165LBERLIBNAME=""
21166
21167# Check whether --with-lber-lib was given.
21168if test "${with_lber_lib+set}" = set; then :
21169 withval=$with_lber_lib; LBERLIBNAME="$withval"
21170fi
21171
21172
21173if test x$CURL_DISABLE_LDAP != x1 ; then
21174
21175
21176 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lber.h" >&5
21177$as_echo_n "checking for lber.h... " >&6; }
21178if ${curl_cv_header_lber_h+:} false; then :
21179 $as_echo_n "(cached) " >&6
21180else
21181
21182 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21183/* end confdefs.h. */
21184
21185
21186#undef inline
21187#ifdef HAVE_WINDOWS_H
21188#ifndef WIN32_LEAN_AND_MEAN
21189#define WIN32_LEAN_AND_MEAN
21190#endif
21191#include <windows.h>
21192#else
21193#ifdef HAVE_SYS_TYPES_H
21194#include <sys/types.h>
21195#endif
21196#endif
21197#ifndef NULL
21198#define NULL (void *)0
21199#endif
21200#include <lber.h>
21201
21202int main (void)
21203{
21204
21205 BerValue *bvp = NULL;
21206 BerElement *bep = ber_init(bvp);
21207 ber_free(bep, 1);
21208
21209 ;
21210 return 0;
21211}
21212
21213_ACEOF
21214if ac_fn_c_try_compile "$LINENO"; then :
21215
21216 curl_cv_header_lber_h="yes"
21217
21218else
21219
21220 curl_cv_header_lber_h="no"
21221
21222fi
21223rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21224
21225fi
21226{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_lber_h" >&5
21227$as_echo "$curl_cv_header_lber_h" >&6; }
21228 if test "$curl_cv_header_lber_h" = "yes"; then
21229
21230cat >>confdefs.h <<_ACEOF
21231#define HAVE_LBER_H 1
21232_ACEOF
21233
21234 #
21235 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21236/* end confdefs.h. */
21237
21238
21239#undef inline
21240#ifdef HAVE_WINDOWS_H
21241#ifndef WIN32_LEAN_AND_MEAN
21242#define WIN32_LEAN_AND_MEAN
21243#endif
21244#include <windows.h>
21245#else
21246#ifdef HAVE_SYS_TYPES_H
21247#include <sys/types.h>
21248#endif
21249#endif
21250#ifndef NULL
21251#define NULL (void *)0
21252#endif
21253#ifndef LDAP_DEPRECATED
21254#define LDAP_DEPRECATED 1
21255#endif
21256#include <ldap.h>
21257
21258int main (void)
21259{
21260
21261 BerValue *bvp = NULL;
21262 BerElement *bep = ber_init(bvp);
21263 ber_free(bep, 1);
21264
21265 ;
21266 return 0;
21267}
21268
21269_ACEOF
21270if ac_fn_c_try_compile "$LINENO"; then :
21271
21272 curl_cv_need_header_lber_h="no"
21273
21274else
21275
21276 curl_cv_need_header_lber_h="yes"
21277
21278fi
21279rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21280 #
21281 case "$curl_cv_need_header_lber_h" in
21282 yes)
21283
21284cat >>confdefs.h <<_ACEOF
21285#define NEED_LBER_H 1
21286_ACEOF
21287
21288 ;;
21289 esac
21290 fi
21291
21292
21293 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ldap.h" >&5
21294$as_echo_n "checking for ldap.h... " >&6; }
21295if ${curl_cv_header_ldap_h+:} false; then :
21296 $as_echo_n "(cached) " >&6
21297else
21298
21299 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21300/* end confdefs.h. */
21301
21302
21303#undef inline
21304#ifdef HAVE_WINDOWS_H
21305#ifndef WIN32_LEAN_AND_MEAN
21306#define WIN32_LEAN_AND_MEAN
21307#endif
21308#include <windows.h>
21309#else
21310#ifdef HAVE_SYS_TYPES_H
21311#include <sys/types.h>
21312#endif
21313#endif
21314#ifndef LDAP_DEPRECATED
21315#define LDAP_DEPRECATED 1
21316#endif
21317#ifdef NEED_LBER_H
21318#include <lber.h>
21319#endif
21320#include <ldap.h>
21321
21322int main (void)
21323{
21324
21325 LDAP *ldp = ldap_init("dummy", LDAP_PORT);
21326 int res = ldap_unbind(ldp);
21327
21328 ;
21329 return 0;
21330}
21331
21332_ACEOF
21333if ac_fn_c_try_compile "$LINENO"; then :
21334
21335 curl_cv_header_ldap_h="yes"
21336
21337else
21338
21339 curl_cv_header_ldap_h="no"
21340
21341fi
21342rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21343
21344fi
21345{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_ldap_h" >&5
21346$as_echo "$curl_cv_header_ldap_h" >&6; }
21347 case "$curl_cv_header_ldap_h" in
21348 yes)
21349
21350cat >>confdefs.h <<_ACEOF
21351#define HAVE_LDAP_H 1
21352_ACEOF
21353
21354 ;;
21355 esac
21356
21357
21358 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ldapssl.h" >&5
21359$as_echo_n "checking for ldapssl.h... " >&6; }
21360if ${curl_cv_header_ldapssl_h+:} false; then :
21361 $as_echo_n "(cached) " >&6
21362else
21363
21364 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21365/* end confdefs.h. */
21366
21367
21368#undef inline
21369#ifdef HAVE_WINDOWS_H
21370#ifndef WIN32_LEAN_AND_MEAN
21371#define WIN32_LEAN_AND_MEAN
21372#endif
21373#include <windows.h>
21374#else
21375#ifdef HAVE_SYS_TYPES_H
21376#include <sys/types.h>
21377#endif
21378#endif
21379#ifndef NULL
21380#define NULL (void *)0
21381#endif
21382#ifndef LDAP_DEPRECATED
21383#define LDAP_DEPRECATED 1
21384#endif
21385#ifdef NEED_LBER_H
21386#include <lber.h>
21387#endif
21388#ifdef HAVE_LDAP_H
21389#include <ldap.h>
21390#endif
21391#include <ldapssl.h>
21392
21393int main (void)
21394{
21395
21396 char *cert_label = NULL;
21397 LDAP *ldp = ldap_ssl_init("dummy", LDAPS_PORT, cert_label);
21398
21399 ;
21400 return 0;
21401}
21402
21403_ACEOF
21404if ac_fn_c_try_compile "$LINENO"; then :
21405
21406 curl_cv_header_ldapssl_h="yes"
21407
21408else
21409
21410 curl_cv_header_ldapssl_h="no"
21411
21412fi
21413rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21414
21415fi
21416{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_ldapssl_h" >&5
21417$as_echo "$curl_cv_header_ldapssl_h" >&6; }
21418 case "$curl_cv_header_ldapssl_h" in
21419 yes)
21420
21421cat >>confdefs.h <<_ACEOF
21422#define HAVE_LDAPSSL_H 1
21423_ACEOF
21424
21425 ;;
21426 esac
21427
21428
21429 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ldap_ssl.h" >&5
21430$as_echo_n "checking for ldap_ssl.h... " >&6; }
21431if ${curl_cv_header_ldap_ssl_h+:} false; then :
21432 $as_echo_n "(cached) " >&6
21433else
21434
21435 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21436/* end confdefs.h. */
21437
21438
21439#undef inline
21440#ifdef HAVE_WINDOWS_H
21441#ifndef WIN32_LEAN_AND_MEAN
21442#define WIN32_LEAN_AND_MEAN
21443#endif
21444#include <windows.h>
21445#else
21446#ifdef HAVE_SYS_TYPES_H
21447#include <sys/types.h>
21448#endif
21449#endif
21450#ifndef LDAP_DEPRECATED
21451#define LDAP_DEPRECATED 1
21452#endif
21453#ifdef NEED_LBER_H
21454#include <lber.h>
21455#endif
21456#ifdef HAVE_LDAP_H
21457#include <ldap.h>
21458#endif
21459#include <ldap_ssl.h>
21460
21461int main (void)
21462{
21463
21464 LDAP *ldp = ldapssl_init("dummy", LDAPS_PORT, 1);
21465
21466 ;
21467 return 0;
21468}
21469
21470_ACEOF
21471if ac_fn_c_try_compile "$LINENO"; then :
21472
21473 curl_cv_header_ldap_ssl_h="yes"
21474
21475else
21476
21477 curl_cv_header_ldap_ssl_h="no"
21478
21479fi
21480rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21481
21482fi
21483{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_ldap_ssl_h" >&5
21484$as_echo "$curl_cv_header_ldap_ssl_h" >&6; }
21485 case "$curl_cv_header_ldap_ssl_h" in
21486 yes)
21487
21488cat >>confdefs.h <<_ACEOF
21489#define HAVE_LDAP_SSL_H 1
21490_ACEOF
21491
21492 ;;
21493 esac
21494
21495
21496 if test -z "$LDAPLIBNAME" ; then
21497 if test "$curl_cv_native_windows" = "yes"; then
21498 LDAPLIBNAME="wldap32"
21499 LBERLIBNAME="no"
21500 fi
21501 fi
21502
21503 if test "$LDAPLIBNAME" ; then
21504 as_ac_Lib=`$as_echo "ac_cv_lib_"$LDAPLIBNAME"''_ldap_init" | $as_tr_sh`
21505{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ldap_init in -l\"$LDAPLIBNAME\"" >&5
21506$as_echo_n "checking for ldap_init in -l\"$LDAPLIBNAME\"... " >&6; }
21507if eval \${$as_ac_Lib+:} false; then :
21508 $as_echo_n "(cached) " >&6
21509else
21510 ac_check_lib_save_LIBS=$LIBS
21511LIBS="-l"$LDAPLIBNAME" $LIBS"
21512cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21513/* end confdefs.h. */
21514
21515
21516#ifdef __cplusplus
21517extern "C"
21518#endif
21519char ldap_init ();
21520int main (void)
21521{
21522return ldap_init ();
21523 ;
21524 return 0;
21525}
21526_ACEOF
21527if ac_fn_c_try_link "$LINENO"; then :
21528 eval "$as_ac_Lib=yes"
21529else
21530 eval "$as_ac_Lib=no"
21531fi
21532rm -f core conftest.err conftest.$ac_objext \
21533 conftest$ac_exeext conftest.$ac_ext
21534LIBS=$ac_check_lib_save_LIBS
21535fi
21536eval ac_res=\$$as_ac_Lib
21537 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
21538$as_echo "$ac_res" >&6; }
21539if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
21540 cat >>confdefs.h <<_ACEOF
21541#define `$as_echo "HAVE_LIB"$LDAPLIBNAME"" | $as_tr_cpp` 1
21542_ACEOF
21543
21544 LIBS="-l"$LDAPLIBNAME" $LIBS"
21545
21546else
21547
21548 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \"$LDAPLIBNAME\" is not an LDAP library: LDAP disabled" >&5
21549$as_echo "$as_me: WARNING: \"$LDAPLIBNAME\" is not an LDAP library: LDAP disabled" >&2;}
21550
21551$as_echo "#define CURL_DISABLE_LDAP 1" >>confdefs.h
21552
21553 CURL_DISABLE_LDAP=1
21554
21555
21556$as_echo "#define CURL_DISABLE_LDAPS 1" >>confdefs.h
21557
21558 CURL_DISABLE_LDAPS=1
21559
21560fi
21561
21562 else
21563
21564 #
21565 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LDAP libraries" >&5
21566$as_echo_n "checking for LDAP libraries... " >&6; }
21567 #
21568 u_libs=""
21569 #
21570
21571 #
21572 curl_cv_save_LIBS="$LIBS"
21573 curl_cv_ldap_LIBS="unknown"
21574 #
21575 for x_nlibs in '' "$u_libs" \
21576 '-lldap' \
21577 '-lldap -llber' \
21578 '-llber -lldap' \
21579 '-lldapssl -lldapx -lldapsdk' \
Haibo Huang65021c72019-03-27 15:37:23 -070021580 '-lldapsdk -lldapx -lldapssl' \
21581 '-lldap -llber -lssl -lcrypto' ; do
21582
Elliott Hughes82be86d2017-09-20 17:00:17 -070021583 if test "$curl_cv_ldap_LIBS" = "unknown"; then
21584 if test -z "$x_nlibs"; then
21585 LIBS="$curl_cv_save_LIBS"
21586 else
21587 LIBS="$x_nlibs $curl_cv_save_LIBS"
21588 fi
21589 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21590/* end confdefs.h. */
21591
21592
21593#undef inline
21594#ifdef HAVE_WINDOWS_H
21595#ifndef WIN32_LEAN_AND_MEAN
21596#define WIN32_LEAN_AND_MEAN
21597#endif
21598#include <windows.h>
21599#else
21600#ifdef HAVE_SYS_TYPES_H
21601#include <sys/types.h>
21602#endif
21603#endif
21604#ifndef NULL
21605#define NULL (void *)0
21606#endif
21607#ifndef LDAP_DEPRECATED
21608#define LDAP_DEPRECATED 1
21609#endif
21610#ifdef NEED_LBER_H
21611#include <lber.h>
21612#endif
21613#ifdef HAVE_LDAP_H
21614#include <ldap.h>
21615#endif
21616
21617int main (void)
21618{
21619
21620 BerValue *bvp = NULL;
21621 BerElement *bep = ber_init(bvp);
21622 LDAP *ldp = ldap_init("dummy", LDAP_PORT);
21623 int res = ldap_unbind(ldp);
21624 ber_free(bep, 1);
21625
21626 ;
21627 return 0;
21628}
21629
21630_ACEOF
21631if ac_fn_c_try_link "$LINENO"; then :
21632
21633 curl_cv_ldap_LIBS="$x_nlibs"
21634
21635fi
21636rm -f core conftest.err conftest.$ac_objext \
21637 conftest$ac_exeext conftest.$ac_ext
21638 fi
21639 done
21640 #
21641 LIBS="$curl_cv_save_LIBS"
21642 #
21643 case X-"$curl_cv_ldap_LIBS" in
21644 X-unknown)
21645 { $as_echo "$as_me:${as_lineno-$LINENO}: result: cannot find LDAP libraries" >&5
21646$as_echo "cannot find LDAP libraries" >&6; }
21647 ;;
21648 X-)
21649 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no additional lib required" >&5
21650$as_echo "no additional lib required" >&6; }
21651 ;;
21652 *)
21653 if test -z "$curl_cv_save_LIBS"; then
21654 LIBS="$curl_cv_ldap_LIBS"
21655 else
21656 LIBS="$curl_cv_ldap_LIBS $curl_cv_save_LIBS"
21657 fi
21658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_ldap_LIBS" >&5
21659$as_echo "$curl_cv_ldap_LIBS" >&6; }
21660 ;;
21661 esac
21662 #
21663
21664 case X-"$curl_cv_ldap_LIBS" in
21665 X-unknown)
21666 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Cannot find libraries for LDAP support: LDAP disabled" >&5
21667$as_echo "$as_me: WARNING: Cannot find libraries for LDAP support: LDAP disabled" >&2;}
21668
21669$as_echo "#define CURL_DISABLE_LDAP 1" >>confdefs.h
21670
21671 CURL_DISABLE_LDAP=1
21672
21673
21674$as_echo "#define CURL_DISABLE_LDAPS 1" >>confdefs.h
21675
21676 CURL_DISABLE_LDAPS=1
21677
21678 ;;
21679 esac
21680 fi
21681fi
21682
21683if test x$CURL_DISABLE_LDAP != x1 ; then
21684
21685 if test "$LBERLIBNAME" ; then
21686 if test "$LBERLIBNAME" != "no" ; then
21687 as_ac_Lib=`$as_echo "ac_cv_lib_"$LBERLIBNAME"''_ber_free" | $as_tr_sh`
21688{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ber_free in -l\"$LBERLIBNAME\"" >&5
21689$as_echo_n "checking for ber_free in -l\"$LBERLIBNAME\"... " >&6; }
21690if eval \${$as_ac_Lib+:} false; then :
21691 $as_echo_n "(cached) " >&6
21692else
21693 ac_check_lib_save_LIBS=$LIBS
21694LIBS="-l"$LBERLIBNAME" $LIBS"
21695cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21696/* end confdefs.h. */
21697
21698
21699#ifdef __cplusplus
21700extern "C"
21701#endif
21702char ber_free ();
21703int main (void)
21704{
21705return ber_free ();
21706 ;
21707 return 0;
21708}
21709_ACEOF
21710if ac_fn_c_try_link "$LINENO"; then :
21711 eval "$as_ac_Lib=yes"
21712else
21713 eval "$as_ac_Lib=no"
21714fi
21715rm -f core conftest.err conftest.$ac_objext \
21716 conftest$ac_exeext conftest.$ac_ext
21717LIBS=$ac_check_lib_save_LIBS
21718fi
21719eval ac_res=\$$as_ac_Lib
21720 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
21721$as_echo "$ac_res" >&6; }
21722if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
21723 cat >>confdefs.h <<_ACEOF
21724#define `$as_echo "HAVE_LIB"$LBERLIBNAME"" | $as_tr_cpp` 1
21725_ACEOF
21726
21727 LIBS="-l"$LBERLIBNAME" $LIBS"
21728
21729else
21730
21731 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \"$LBERLIBNAME\" is not an LBER library: LDAP disabled" >&5
21732$as_echo "$as_me: WARNING: \"$LBERLIBNAME\" is not an LBER library: LDAP disabled" >&2;}
21733
21734$as_echo "#define CURL_DISABLE_LDAP 1" >>confdefs.h
21735
21736 CURL_DISABLE_LDAP=1
21737
21738
21739$as_echo "#define CURL_DISABLE_LDAPS 1" >>confdefs.h
21740
21741 CURL_DISABLE_LDAPS=1
21742
21743fi
21744
21745 fi
21746 fi
21747fi
21748
21749if test x$CURL_DISABLE_LDAP != x1 ; then
21750 for ac_func in ldap_url_parse ldap_init_fd
21751do :
21752 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21753ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
21754if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
21755 cat >>confdefs.h <<_ACEOF
21756#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21757_ACEOF
21758
21759fi
21760done
21761
21762
21763 if test "$LDAPLIBNAME" = "wldap32"; then
21764 curl_ldap_msg="enabled (winldap)"
21765
21766$as_echo "#define USE_WIN32_LDAP 1" >>confdefs.h
21767
21768 else
21769 curl_ldap_msg="enabled (OpenLDAP)"
21770 if test "x$ac_cv_func_ldap_init_fd" = "xyes"; then
21771
21772$as_echo "#define USE_OPENLDAP 1" >>confdefs.h
21773
21774 USE_OPENLDAP=1
21775
21776 fi
21777 fi
21778fi
21779
21780if test x$CURL_DISABLE_LDAPS != x1 ; then
21781 curl_ldaps_msg="enabled"
21782fi
21783
21784
21785{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable IPv6" >&5
21786$as_echo_n "checking whether to enable IPv6... " >&6; }
21787# Check whether --enable-ipv6 was given.
21788if test "${enable_ipv6+set}" = set; then :
21789 enableval=$enable_ipv6; case "$enableval" in
21790 no)
21791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21792$as_echo "no" >&6; }
21793 ipv6=no
21794 ;;
21795 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
21796$as_echo "yes" >&6; }
21797 ipv6=yes
21798 ;;
21799 esac
21800else
21801 if test "$cross_compiling" = yes; then :
21802 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
21803$as_echo "yes" >&6; }
21804 ipv6=yes
21805
21806else
21807 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21808/* end confdefs.h. */
21809 /* is AF_INET6 available? */
21810#include <sys/types.h>
21811#ifdef HAVE_WINSOCK2_H
21812#include <winsock2.h>
21813#else
21814#include <sys/socket.h>
21815#endif
21816#include <stdlib.h> /* for exit() */
21817main()
21818{
21819 if (socket(AF_INET6, SOCK_STREAM, 0) < 0)
21820 exit(1);
21821 else
21822 exit(0);
21823}
21824
21825_ACEOF
21826if ac_fn_c_try_run "$LINENO"; then :
21827 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
21828$as_echo "yes" >&6; }
21829 ipv6=yes
21830else
21831 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21832$as_echo "no" >&6; }
21833 ipv6=no
21834fi
21835rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21836 conftest.$ac_objext conftest.beam conftest.$ac_ext
21837fi
21838
21839fi
21840
21841
Elliott Hughes82be86d2017-09-20 17:00:17 -070021842# Check if struct sockaddr_in6 have sin6_scope_id member
21843if test "$ipv6" = yes; then
21844 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if struct sockaddr_in6 has sin6_scope_id member" >&5
21845$as_echo_n "checking if struct sockaddr_in6 has sin6_scope_id member... " >&6; }
21846 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21847/* end confdefs.h. */
21848
21849#include <sys/types.h>
21850#ifdef HAVE_WINSOCK2_H
21851#include <winsock2.h>
21852#include <ws2tcpip.h>
21853#else
21854#include <netinet/in.h>
Elliott Hughes0128fe42018-02-27 14:57:55 -080021855#if defined (__TANDEM)
21856# include <netinet/in6.h>
21857#endif
Elliott Hughes82be86d2017-09-20 17:00:17 -070021858#endif
21859int main (void)
21860{
21861struct sockaddr_in6 s; s.sin6_scope_id = 0;
21862 ;
21863 return 0;
21864}
21865_ACEOF
21866if ac_fn_c_try_compile "$LINENO"; then :
21867 have_sin6_scope_id=yes
21868fi
21869rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21870 if test "$have_sin6_scope_id" = yes; then
21871 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
21872$as_echo "yes" >&6; }
21873
21874$as_echo "#define HAVE_SOCKADDR_IN6_SIN6_SCOPE_ID 1" >>confdefs.h
21875
21876 else
21877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21878$as_echo "no" >&6; }
21879 fi
21880fi
21881
21882
21883{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if argv can be written to" >&5
21884$as_echo_n "checking if argv can be written to... " >&6; }
Elliott Hughes82be86d2017-09-20 17:00:17 -070021885
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070021886
21887 old=$LD_LIBRARY_PATH
Elliott Hughes72d948d2018-08-03 14:37:21 -070021888 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
21889 export LD_LIBRARY_PATH
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070021890 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070021891 curl_cv_writable_argv=cross
21892
21893else
21894 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21895/* end confdefs.h. */
21896
Elliott Hughes82be86d2017-09-20 17:00:17 -070021897int main(int argc, char ** argv) {
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070021898 argv00 = ' ';
21899 return (argv00 == ' ')?0:1;
Elliott Hughes82be86d2017-09-20 17:00:17 -070021900}
21901
Elliott Hughes82be86d2017-09-20 17:00:17 -070021902_ACEOF
21903if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070021904 curl_cv_writable_argv=yes
21905
21906else
Elliott Hughes82be86d2017-09-20 17:00:17 -070021907 curl_cv_writable_argv=no
21908
21909fi
21910rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21911 conftest.$ac_objext conftest.beam conftest.$ac_ext
21912fi
21913
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070021914 LD_LIBRARY_PATH=$old # restore
21915
Elliott Hughes82be86d2017-09-20 17:00:17 -070021916case $curl_cv_writable_argv in
21917yes)
21918
21919$as_echo "#define HAVE_WRITABLE_ARGV 1" >>confdefs.h
21920
21921 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
21922$as_echo "yes" >&6; }
21923 ;;
21924no)
21925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21926$as_echo "no" >&6; }
21927 ;;
21928*)
21929 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21930$as_echo "no" >&6; }
21931 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: the previous check could not be made default was used" >&5
21932$as_echo "$as_me: WARNING: the previous check could not be made default was used" >&2;}
21933 ;;
21934esac
21935
21936
21937
21938GSSAPI_ROOT="/usr"
21939
21940# Check whether --with-gssapi-includes was given.
21941if test "${with_gssapi_includes+set}" = set; then :
21942 withval=$with_gssapi_includes; GSSAPI_INCS="-I$withval"
21943 want_gss="yes"
21944
21945fi
21946
21947
21948
21949# Check whether --with-gssapi-libs was given.
21950if test "${with_gssapi_libs+set}" = set; then :
21951 withval=$with_gssapi_libs; GSSAPI_LIB_DIR="-L$withval"
21952 want_gss="yes"
21953
21954fi
21955
21956
21957
21958# Check whether --with-gssapi was given.
21959if test "${with_gssapi+set}" = set; then :
21960 withval=$with_gssapi;
21961 GSSAPI_ROOT="$withval"
21962 if test x"$GSSAPI_ROOT" != xno; then
21963 want_gss="yes"
21964 if test x"$GSSAPI_ROOT" = xyes; then
21965 GSSAPI_ROOT="/usr"
21966 fi
21967 fi
21968
21969fi
21970
21971
21972: ${KRB5CONFIG:="$GSSAPI_ROOT/bin/krb5-config"}
21973
21974save_CPPFLAGS="$CPPFLAGS"
21975{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if GSS-API support is requested" >&5
21976$as_echo_n "checking if GSS-API support is requested... " >&6; }
21977if test x"$want_gss" = xyes; then
21978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
21979$as_echo "yes" >&6; }
21980
21981 if test -z "$GSSAPI_INCS"; then
21982 if test -n "$host_alias" -a -f "$GSSAPI_ROOT/bin/$host_alias-krb5-config"; then
21983 GSSAPI_INCS=`$GSSAPI_ROOT/bin/$host_alias-krb5-config --cflags gssapi`
21984 elif test -f "$KRB5CONFIG"; then
21985 GSSAPI_INCS=`$KRB5CONFIG --cflags gssapi`
21986 elif test "$GSSAPI_ROOT" != "yes"; then
21987 GSSAPI_INCS="-I$GSSAPI_ROOT/include"
21988 fi
21989 fi
21990
21991 CPPFLAGS="$CPPFLAGS $GSSAPI_INCS"
21992
21993 ac_fn_c_check_header_mongrel "$LINENO" "gss.h" "ac_cv_header_gss_h" "$ac_includes_default"
21994if test "x$ac_cv_header_gss_h" = xyes; then :
21995
21996
21997$as_echo "#define HAVE_GSSGNU 1" >>confdefs.h
21998
21999 gnu_gss=yes
22000
22001else
22002
22003 for ac_header in gssapi/gssapi.h
22004do :
22005 ac_fn_c_check_header_mongrel "$LINENO" "gssapi/gssapi.h" "ac_cv_header_gssapi_gssapi_h" "$ac_includes_default"
22006if test "x$ac_cv_header_gssapi_gssapi_h" = xyes; then :
22007 cat >>confdefs.h <<_ACEOF
22008#define HAVE_GSSAPI_GSSAPI_H 1
22009_ACEOF
22010
22011else
22012 not_mit=1
22013fi
22014
22015done
22016
22017 for ac_header in gssapi/gssapi_generic.h gssapi/gssapi_krb5.h
22018do :
22019 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
22020ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "
22021$ac_includes_default
22022#ifdef HAVE_GSSAPI_GSSAPI_H
22023#include <gssapi/gssapi.h>
22024#endif
22025
22026"
22027if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
22028 cat >>confdefs.h <<_ACEOF
22029#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
22030_ACEOF
22031
22032else
22033 not_mit=1
22034fi
22035
22036done
22037
22038 if test "x$not_mit" = "x1"; then
22039 ac_fn_c_check_header_mongrel "$LINENO" "gssapi.h" "ac_cv_header_gssapi_h" "$ac_includes_default"
22040if test "x$ac_cv_header_gssapi_h" = xyes; then :
22041
22042
22043$as_echo "#define HAVE_GSSHEIMDAL 1" >>confdefs.h
22044
22045
22046else
22047
22048 want_gss=no
22049 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: disabling GSS-API support since no header files were found" >&5
22050$as_echo "$as_me: WARNING: disabling GSS-API support since no header files were found" >&2;}
22051
22052
22053fi
22054
22055
22056 else
22057
22058$as_echo "#define HAVE_GSSMIT 1" >>confdefs.h
22059
22060 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if GSS-API headers declare GSS_C_NT_HOSTBASED_SERVICE" >&5
22061$as_echo_n "checking if GSS-API headers declare GSS_C_NT_HOSTBASED_SERVICE... " >&6; }
22062 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22063/* end confdefs.h. */
22064
22065
22066#include <gssapi/gssapi.h>
22067#include <gssapi/gssapi_generic.h>
22068#include <gssapi/gssapi_krb5.h>
22069
22070int main (void)
22071{
22072
22073 gss_import_name(
22074 (OM_uint32 *)0,
22075 (gss_buffer_t)0,
22076 GSS_C_NT_HOSTBASED_SERVICE,
22077 (gss_name_t *)0);
22078
22079 ;
22080 return 0;
22081}
22082
22083_ACEOF
22084if ac_fn_c_try_compile "$LINENO"; then :
22085
22086 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22087$as_echo "yes" >&6; }
22088
22089else
22090
22091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22092$as_echo "no" >&6; }
22093
22094$as_echo "#define HAVE_OLD_GSSMIT 1" >>confdefs.h
22095
22096
22097fi
22098rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22099 fi
22100
22101
22102fi
22103
22104
22105else
22106 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22107$as_echo "no" >&6; }
22108fi
22109if test x"$want_gss" = xyes; then
22110
22111$as_echo "#define HAVE_GSSAPI 1" >>confdefs.h
22112
22113 HAVE_GSSAPI=1
22114 curl_gss_msg="enabled (MIT Kerberos/Heimdal)"
22115
22116 if test -n "$gnu_gss"; then
22117 curl_gss_msg="enabled (GNU GSS)"
22118 LDFLAGS="$LDFLAGS $GSSAPI_LIB_DIR"
22119 LIBS="-lgss $LIBS"
22120 elif test -z "$GSSAPI_LIB_DIR"; then
22121 case $host in
22122 *-*-darwin*)
22123 LIBS="-lgssapi_krb5 -lresolv $LIBS"
22124 ;;
22125 *)
22126 if test -n "$host_alias" -a -f "$GSSAPI_ROOT/bin/$host_alias-krb5-config"; then
22127 gss_libs=`$GSSAPI_ROOT/bin/$host_alias-krb5-config --libs gssapi`
22128 LIBS="$gss_libs $LIBS"
22129 elif test -f "$KRB5CONFIG"; then
22130 gss_libs=`$KRB5CONFIG --libs gssapi`
22131 LIBS="$gss_libs $LIBS"
22132 else
22133 case $host in
22134 *-hp-hpux*)
22135 gss_libname="gss"
22136 ;;
22137 *)
22138 gss_libname="gssapi"
22139 ;;
22140 esac
22141
22142 if test "$GSSAPI_ROOT" != "yes"; then
22143 LDFLAGS="$LDFLAGS -L$GSSAPI_ROOT/lib$libsuff"
22144 LIBS="-l$gss_libname $LIBS"
22145 else
22146 LIBS="-l$gss_libname $LIBS"
22147 fi
22148 fi
22149 ;;
22150 esac
22151 else
22152 LDFLAGS="$LDFLAGS $GSSAPI_LIB_DIR"
22153 case $host in
22154 *-hp-hpux*)
22155 LIBS="-lgss $LIBS"
22156 ;;
22157 *)
22158 LIBS="-lgssapi $LIBS"
22159 ;;
22160 esac
22161 fi
22162else
22163 CPPFLAGS="$save_CPPFLAGS"
22164fi
22165
Alex Deymo486467e2017-12-19 19:04:07 +010022166build_libstubgss=no
22167if test x"$want_gss" = "xyes"; then
22168 build_libstubgss=yes
22169fi
22170
22171 if test "x$build_libstubgss" = "xyes"; then
22172 BUILD_STUB_GSS_TRUE=
22173 BUILD_STUB_GSS_FALSE='#'
22174else
22175 BUILD_STUB_GSS_TRUE='#'
22176 BUILD_STUB_GSS_FALSE=
22177fi
22178
22179
22180
22181DEFAULT_SSL_BACKEND=no
22182VALID_DEFAULT_SSL_BACKEND=
22183
22184# Check whether --with-default-ssl-backend was given.
22185if test "${with_default_ssl_backend+set}" = set; then :
22186 withval=$with_default_ssl_backend; DEFAULT_SSL_BACKEND=$withval
22187fi
22188
22189case "$DEFAULT_SSL_BACKEND" in
22190 no)
22191 ;;
22192 default|yes)
22193 as_fn_error $? "The name of the default SSL backend is required." "$LINENO" 5
22194 ;;
22195 *)
22196
22197 VALID_DEFAULT_SSL_BACKEND=no
22198 ;;
22199esac
22200
22201
Elliott Hughes82be86d2017-09-20 17:00:17 -070022202
22203OPT_WINSSL=no
22204
22205# Check whether --with-winssl was given.
22206if test "${with_winssl+set}" = set; then :
22207 withval=$with_winssl; OPT_WINSSL=$withval
22208fi
22209
22210
Haibo Huang51d9d882019-02-06 01:36:06 -080022211
22212# Check whether --with-schannel was given.
22213if test "${with_schannel+set}" = set; then :
22214 withval=$with_schannel; OPT_WINSSL=$withval
22215fi
22216
22217
Elliott Hughes82be86d2017-09-20 17:00:17 -070022218{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable Windows native SSL/TLS (Windows native builds only)" >&5
22219$as_echo_n "checking whether to enable Windows native SSL/TLS (Windows native builds only)... " >&6; }
Alex Deymo486467e2017-12-19 19:04:07 +010022220if test -z "$ssl_backends" -o "x$OPT_WINSSL" != xno; then
22221 ssl_msg=
Elliott Hughes82be86d2017-09-20 17:00:17 -070022222 if test "x$OPT_WINSSL" != "xno" &&
22223 test "x$curl_cv_native_windows" = "xyes"; then
22224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22225$as_echo "yes" >&6; }
22226
22227$as_echo "#define USE_SCHANNEL 1" >>confdefs.h
22228
22229 USE_SCHANNEL=1
22230
Alex Deymo486467e2017-12-19 19:04:07 +010022231 ssl_msg="Windows-native"
22232 test schannel != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
Elliott Hughes82be86d2017-09-20 17:00:17 -070022233 WINSSL_ENABLED=1
22234 # --with-winssl implies --enable-sspi
22235
22236$as_echo "#define USE_WINDOWS_SSPI 1" >>confdefs.h
22237
22238 USE_WINDOWS_SSPI=1
22239
22240 curl_sspi_msg="enabled"
22241 LIBS="-lcrypt32 $LIBS"
22242 else
22243 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22244$as_echo "no" >&6; }
22245 fi
Alex Deymo486467e2017-12-19 19:04:07 +010022246 test -z "$ssl_msg" || ssl_backends="${ssl_backends:+$ssl_backends, }$ssl_msg"
Elliott Hughes82be86d2017-09-20 17:00:17 -070022247else
22248 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22249$as_echo "no" >&6; }
22250fi
22251
Haibo Huang65021c72019-03-27 15:37:23 -070022252OPT_SECURETRANSPORT=no
Elliott Hughes82be86d2017-09-20 17:00:17 -070022253
22254# Check whether --with-darwinssl was given.
22255if test "${with_darwinssl+set}" = set; then :
Haibo Huang65021c72019-03-27 15:37:23 -070022256 withval=$with_darwinssl; OPT_SECURETRANSPORT=$withval
Elliott Hughes82be86d2017-09-20 17:00:17 -070022257fi
22258
22259
Haibo Huang65021c72019-03-27 15:37:23 -070022260
22261# Check whether --with-secure-transport was given.
22262if test "${with_secure_transport+set}" = set; then :
22263 withval=$with_secure_transport; OPT_SECURETRANSPORT=$withval
22264fi
22265
22266
22267{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable Secure Transport" >&5
22268$as_echo_n "checking whether to enable Secure Transport... " >&6; }
22269if test -z "$ssl_backends" -o "x$OPT_SECURETRANSPORT" != xno; then
22270 if test "x$OPT_SECURETRANSPORT" != "xno" &&
Elliott Hughes82be86d2017-09-20 17:00:17 -070022271 test -d "/System/Library/Frameworks/Security.framework"; then
22272 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22273$as_echo "yes" >&6; }
22274
Haibo Huang65021c72019-03-27 15:37:23 -070022275$as_echo "#define USE_SECTRANSP 1" >>confdefs.h
Elliott Hughes82be86d2017-09-20 17:00:17 -070022276
Haibo Huang65021c72019-03-27 15:37:23 -070022277 USE_SECTRANSP=1
Elliott Hughes82be86d2017-09-20 17:00:17 -070022278
Haibo Huang65021c72019-03-27 15:37:23 -070022279 ssl_msg="Secure Transport"
22280 test secure-transport != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
22281 SECURETRANSPORT_ENABLED=1
Elliott Hughes82be86d2017-09-20 17:00:17 -070022282 LDFLAGS="$LDFLAGS -framework CoreFoundation -framework Security"
22283 else
22284 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22285$as_echo "no" >&6; }
22286 fi
Alex Deymo486467e2017-12-19 19:04:07 +010022287 test -z "$ssl_msg" || ssl_backends="${ssl_backends:+$ssl_backends, }$ssl_msg"
Elliott Hughes82be86d2017-09-20 17:00:17 -070022288else
22289 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22290$as_echo "no" >&6; }
22291fi
22292
Haibo Huang65021c72019-03-27 15:37:23 -070022293OPT_AMISSL=no
22294
22295# Check whether --with-amissl was given.
22296if test "${with_amissl+set}" = set; then :
22297 withval=$with_amissl; OPT_AMISSL=$withval
22298fi
22299
22300
22301{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable Amiga native SSL/TLS (AmiSSL)" >&5
22302$as_echo_n "checking whether to enable Amiga native SSL/TLS (AmiSSL)... " >&6; }
Haibo Huang34ab3462019-05-22 00:50:27 -070022303if test "$HAVE_PROTO_BSDSOCKET_H" = "1"; then
Haibo Huang65021c72019-03-27 15:37:23 -070022304 if test -z "$ssl_backends" -o "x$OPT_AMISSL" != xno; then
22305 ssl_msg=
22306 if test "x$OPT_AMISSL" != "xno"; then
22307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22308$as_echo "yes" >&6; }
22309 ssl_msg="AmiSSL"
22310 test amissl != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
22311 AMISSL_ENABLED=1
22312 LIBS="-lamisslauto $LIBS"
22313
22314$as_echo "#define USE_AMISSL 1" >>confdefs.h
22315
22316
22317$as_echo "#define USE_OPENSSL 1" >>confdefs.h
22318
22319 else
22320 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22321$as_echo "no" >&6; }
22322 fi
22323 test -z "$ssl_msg" || ssl_backends="${ssl_backends:+$ssl_backends, }$ssl_msg"
22324 else
22325 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22326$as_echo "no" >&6; }
22327 fi
22328else
22329 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22330$as_echo "no" >&6; }
22331fi
22332
Elliott Hughes82be86d2017-09-20 17:00:17 -070022333
22334OPT_SSL=off
22335ca="no"
22336
22337# Check whether --with-ssl was given.
22338if test "${with_ssl+set}" = set; then :
22339 withval=$with_ssl; OPT_SSL=$withval
22340fi
22341
22342
Alex Deymo486467e2017-12-19 19:04:07 +010022343if test -z "$ssl_backends" -o "x$OPT_SSL" != xno &&
22344 test X"$OPT_SSL" != Xno; then
22345 ssl_msg=
22346
Elliott Hughes82be86d2017-09-20 17:00:17 -070022347 CLEANLDFLAGS="$LDFLAGS"
22348 CLEANCPPFLAGS="$CPPFLAGS"
22349 CLEANLIBS="$LIBS"
22350
22351 case $host in
22352 *-*-msys* | *-*-mingw*)
22353 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gdi32" >&5
22354$as_echo_n "checking for gdi32... " >&6; }
22355 my_ac_save_LIBS=$LIBS
22356 LIBS="-lgdi32 $LIBS"
22357 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22358/* end confdefs.h. */
22359#include <windef.h>
22360 #include <wingdi.h>
22361int main (void)
22362{
22363GdiFlush();
22364 ;
22365 return 0;
22366}
22367_ACEOF
22368if ac_fn_c_try_link "$LINENO"; then :
22369 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22370$as_echo "yes" >&6; }
22371else
22372 LIBS=$my_ac_save_LIBS
22373 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22374$as_echo "no" >&6; }
22375
22376fi
22377rm -f core conftest.err conftest.$ac_objext \
22378 conftest$ac_exeext conftest.$ac_ext
22379 ;;
22380 esac
22381
22382 case "$OPT_SSL" in
22383 yes)
22384 if test x$cross_compiling != xyes; then
22385 PKGTEST="yes"
22386 fi
22387 PREFIX_OPENSSL=/usr/local/ssl
22388 LIB_OPENSSL="$PREFIX_OPENSSL/lib$libsuff"
22389 ;;
22390 off)
22391 if test x$cross_compiling != xyes; then
22392 PKGTEST="yes"
22393 fi
22394 PREFIX_OPENSSL=
22395 ;;
22396 *)
22397 PKGTEST="no"
22398 PREFIX_OPENSSL=$OPT_SSL
22399
22400 OPENSSL_PCDIR="$OPT_SSL/lib/pkgconfig"
Elliott Hughes82be86d2017-09-20 17:00:17 -070022401 if test -f "$OPENSSL_PCDIR/openssl.pc"; then
Elliott Hughes72d948d2018-08-03 14:37:21 -070022402 { $as_echo "$as_me:${as_lineno-$LINENO}: PKG_CONFIG_LIBDIR will be set to \"$OPENSSL_PCDIR\"" >&5
22403$as_echo "$as_me: PKG_CONFIG_LIBDIR will be set to \"$OPENSSL_PCDIR\"" >&6;}
Elliott Hughes82be86d2017-09-20 17:00:17 -070022404 PKGTEST="yes"
Elliott Hughes72d948d2018-08-03 14:37:21 -070022405 elif test ! -f "$PREFIX_OPENSSL/include/openssl/ssl.h"; then
22406 as_fn_error $? "$PREFIX_OPENSSL is a bad --with-ssl prefix!" "$LINENO" 5
Elliott Hughes82be86d2017-09-20 17:00:17 -070022407 fi
22408
22409 LIB_OPENSSL="$PREFIX_OPENSSL/lib$libsuff"
22410 if test "$PREFIX_OPENSSL" != "/usr" ; then
22411 SSL_LDFLAGS="-L$LIB_OPENSSL"
22412 SSL_CPPFLAGS="-I$PREFIX_OPENSSL/include"
22413 fi
22414 SSL_CPPFLAGS="$SSL_CPPFLAGS -I$PREFIX_OPENSSL/include/openssl"
22415 ;;
22416 esac
22417
22418 if test "$PKGTEST" = "yes"; then
22419
22420
22421 if test -n "$PKG_CONFIG"; then
22422 PKGCONFIG="$PKG_CONFIG"
22423 else
22424 if test -n "$ac_tool_prefix"; then
22425 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
22426set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
22427{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
22428$as_echo_n "checking for $ac_word... " >&6; }
22429if ${ac_cv_path_PKGCONFIG+:} false; then :
22430 $as_echo_n "(cached) " >&6
22431else
22432 case $PKGCONFIG in
22433 [\\/]* | ?:[\\/]*)
22434 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
22435 ;;
22436 *)
22437 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22438as_dummy="$PATH:/usr/bin:/usr/local/bin"
22439for as_dir in $as_dummy
22440do
22441 IFS=$as_save_IFS
22442 test -z "$as_dir" && as_dir=.
22443 for ac_exec_ext in '' $ac_executable_extensions; do
22444 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
22445 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
22446 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
22447 break 2
22448 fi
22449done
22450 done
22451IFS=$as_save_IFS
22452
22453 ;;
22454esac
22455fi
22456PKGCONFIG=$ac_cv_path_PKGCONFIG
22457if test -n "$PKGCONFIG"; then
22458 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
22459$as_echo "$PKGCONFIG" >&6; }
22460else
22461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22462$as_echo "no" >&6; }
22463fi
22464
22465
22466fi
22467if test -z "$ac_cv_path_PKGCONFIG"; then
22468 ac_pt_PKGCONFIG=$PKGCONFIG
22469 # Extract the first word of "pkg-config", so it can be a program name with args.
22470set dummy pkg-config; ac_word=$2
22471{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
22472$as_echo_n "checking for $ac_word... " >&6; }
22473if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
22474 $as_echo_n "(cached) " >&6
22475else
22476 case $ac_pt_PKGCONFIG in
22477 [\\/]* | ?:[\\/]*)
22478 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
22479 ;;
22480 *)
22481 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22482as_dummy="$PATH:/usr/bin:/usr/local/bin"
22483for as_dir in $as_dummy
22484do
22485 IFS=$as_save_IFS
22486 test -z "$as_dir" && as_dir=.
22487 for ac_exec_ext in '' $ac_executable_extensions; do
22488 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
22489 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
22490 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
22491 break 2
22492 fi
22493done
22494 done
22495IFS=$as_save_IFS
22496
22497 ;;
22498esac
22499fi
22500ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
22501if test -n "$ac_pt_PKGCONFIG"; then
22502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
22503$as_echo "$ac_pt_PKGCONFIG" >&6; }
22504else
22505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22506$as_echo "no" >&6; }
22507fi
22508
22509 if test "x$ac_pt_PKGCONFIG" = x; then
22510 PKGCONFIG="no"
22511 else
22512 case $cross_compiling:$ac_tool_warned in
22513yes:)
22514{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
22515$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
22516ac_tool_warned=yes ;;
22517esac
22518 PKGCONFIG=$ac_pt_PKGCONFIG
22519 fi
22520else
22521 PKGCONFIG="$ac_cv_path_PKGCONFIG"
22522fi
22523
22524 fi
22525
22526 if test "x$PKGCONFIG" != "xno"; then
22527 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openssl options with pkg-config" >&5
22528$as_echo_n "checking for openssl options with pkg-config... " >&6; }
22529 itexists=`
22530 if test -n "$OPENSSL_PCDIR"; then
22531 PKG_CONFIG_LIBDIR="$OPENSSL_PCDIR"
22532 export PKG_CONFIG_LIBDIR
22533 fi
22534 $PKGCONFIG --exists openssl >/dev/null 2>&1 && echo 1`
22535
22536 if test -z "$itexists"; then
22537 PKGCONFIG="no"
22538 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22539$as_echo "no" >&6; }
22540 else
22541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
22542$as_echo "found" >&6; }
22543 fi
22544 fi
22545
22546
22547 if test "$PKGCONFIG" != "no" ; then
22548 SSL_LIBS=`
22549 if test -n "$OPENSSL_PCDIR"; then
22550 PKG_CONFIG_LIBDIR="$OPENSSL_PCDIR"
22551 export PKG_CONFIG_LIBDIR
22552 fi
Haibo Huang21926d52019-01-08 14:27:10 -080022553 $PKGCONFIG --libs-only-l --libs-only-other openssl 2>/dev/null`
Elliott Hughes82be86d2017-09-20 17:00:17 -070022554
22555 SSL_LDFLAGS=`
22556 if test -n "$OPENSSL_PCDIR"; then
22557 PKG_CONFIG_LIBDIR="$OPENSSL_PCDIR"
22558 export PKG_CONFIG_LIBDIR
22559 fi
22560 $PKGCONFIG --libs-only-L openssl 2>/dev/null`
22561
22562 SSL_CPPFLAGS=`
22563 if test -n "$OPENSSL_PCDIR"; then
22564 PKG_CONFIG_LIBDIR="$OPENSSL_PCDIR"
22565 export PKG_CONFIG_LIBDIR
22566 fi
22567 $PKGCONFIG --cflags-only-I openssl 2>/dev/null`
22568
22569
22570 { $as_echo "$as_me:${as_lineno-$LINENO}: pkg-config: SSL_LIBS: \"$SSL_LIBS\"" >&5
22571$as_echo "$as_me: pkg-config: SSL_LIBS: \"$SSL_LIBS\"" >&6;}
22572 { $as_echo "$as_me:${as_lineno-$LINENO}: pkg-config: SSL_LDFLAGS: \"$SSL_LDFLAGS\"" >&5
22573$as_echo "$as_me: pkg-config: SSL_LDFLAGS: \"$SSL_LDFLAGS\"" >&6;}
22574 { $as_echo "$as_me:${as_lineno-$LINENO}: pkg-config: SSL_CPPFLAGS: \"$SSL_CPPFLAGS\"" >&5
22575$as_echo "$as_me: pkg-config: SSL_CPPFLAGS: \"$SSL_CPPFLAGS\"" >&6;}
22576
22577 LIB_OPENSSL=`echo $SSL_LDFLAGS | sed -e 's/-L//g'`
22578
22579 LIBS="$SSL_LIBS $LIBS"
22580 fi
22581 fi
22582
22583 CPPFLAGS="$CPPFLAGS $SSL_CPPFLAGS"
22584 LDFLAGS="$LDFLAGS $SSL_LDFLAGS"
22585
22586 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HMAC_Update in -lcrypto" >&5
22587$as_echo_n "checking for HMAC_Update in -lcrypto... " >&6; }
22588if ${ac_cv_lib_crypto_HMAC_Update+:} false; then :
22589 $as_echo_n "(cached) " >&6
22590else
22591 ac_check_lib_save_LIBS=$LIBS
22592LIBS="-lcrypto $LIBS"
22593cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22594/* end confdefs.h. */
22595
22596
22597#ifdef __cplusplus
22598extern "C"
22599#endif
22600char HMAC_Update ();
22601int main (void)
22602{
22603return HMAC_Update ();
22604 ;
22605 return 0;
22606}
22607_ACEOF
22608if ac_fn_c_try_link "$LINENO"; then :
22609 ac_cv_lib_crypto_HMAC_Update=yes
22610else
22611 ac_cv_lib_crypto_HMAC_Update=no
22612fi
22613rm -f core conftest.err conftest.$ac_objext \
22614 conftest$ac_exeext conftest.$ac_ext
22615LIBS=$ac_check_lib_save_LIBS
22616fi
22617{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_HMAC_Update" >&5
22618$as_echo "$ac_cv_lib_crypto_HMAC_Update" >&6; }
22619if test "x$ac_cv_lib_crypto_HMAC_Update" = xyes; then :
22620
22621 HAVECRYPTO="yes"
22622 LIBS="-lcrypto $LIBS"
22623
22624else
22625
22626 LDFLAGS="$CLEANLDFLAGS -L$LIB_OPENSSL"
Elliott Hughesb1ef70f2018-10-30 11:28:38 -070022627 if test "$PKGCONFIG" = "no" ; then
22628 # only set this if pkg-config wasn't used
22629 CPPFLAGS="$CLEANCPPFLAGS -I$PREFIX_OPENSSL/include/openssl -I$PREFIX_OPENSSL/include"
22630 fi
Elliott Hughes82be86d2017-09-20 17:00:17 -070022631 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HMAC_Init_ex in -lcrypto" >&5
22632$as_echo_n "checking for HMAC_Init_ex in -lcrypto... " >&6; }
22633if ${ac_cv_lib_crypto_HMAC_Init_ex+:} false; then :
22634 $as_echo_n "(cached) " >&6
22635else
22636 ac_check_lib_save_LIBS=$LIBS
22637LIBS="-lcrypto $LIBS"
22638cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22639/* end confdefs.h. */
22640
22641
22642#ifdef __cplusplus
22643extern "C"
22644#endif
22645char HMAC_Init_ex ();
22646int main (void)
22647{
22648return HMAC_Init_ex ();
22649 ;
22650 return 0;
22651}
22652_ACEOF
22653if ac_fn_c_try_link "$LINENO"; then :
22654 ac_cv_lib_crypto_HMAC_Init_ex=yes
22655else
22656 ac_cv_lib_crypto_HMAC_Init_ex=no
22657fi
22658rm -f core conftest.err conftest.$ac_objext \
22659 conftest$ac_exeext conftest.$ac_ext
22660LIBS=$ac_check_lib_save_LIBS
22661fi
22662{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_HMAC_Init_ex" >&5
22663$as_echo "$ac_cv_lib_crypto_HMAC_Init_ex" >&6; }
22664if test "x$ac_cv_lib_crypto_HMAC_Init_ex" = xyes; then :
22665
22666 HAVECRYPTO="yes"
22667 LIBS="-lcrypto $LIBS"
22668else
22669
22670
22671 { $as_echo "$as_me:${as_lineno-$LINENO}: checking OpenSSL linking with -ldl" >&5
22672$as_echo_n "checking OpenSSL linking with -ldl... " >&6; }
Elliott Hughes72d948d2018-08-03 14:37:21 -070022673 LIBS="$CLEANLIBS -lcrypto -ldl"
Elliott Hughes82be86d2017-09-20 17:00:17 -070022674 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22675/* end confdefs.h. */
22676
22677 #include <openssl/err.h>
22678
22679int main (void)
22680{
22681
22682 ERR_clear_error();
22683
22684 ;
22685 return 0;
22686}
22687_ACEOF
22688if ac_fn_c_try_link "$LINENO"; then :
22689
22690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22691$as_echo "yes" >&6; }
22692 HAVECRYPTO="yes"
22693
22694else
22695
22696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22697$as_echo "no" >&6; }
22698
22699 { $as_echo "$as_me:${as_lineno-$LINENO}: checking OpenSSL linking with -ldl and -lpthread" >&5
22700$as_echo_n "checking OpenSSL linking with -ldl and -lpthread... " >&6; }
Elliott Hughes72d948d2018-08-03 14:37:21 -070022701 LIBS="$CLEANLIBS -lcrypto -ldl -lpthread"
Elliott Hughes82be86d2017-09-20 17:00:17 -070022702 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22703/* end confdefs.h. */
22704
22705 #include <openssl/err.h>
22706
22707int main (void)
22708{
22709
22710 ERR_clear_error();
22711
22712 ;
22713 return 0;
22714}
22715_ACEOF
22716if ac_fn_c_try_link "$LINENO"; then :
22717
22718 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22719$as_echo "yes" >&6; }
22720 HAVECRYPTO="yes"
22721
22722else
22723
22724 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22725$as_echo "no" >&6; }
22726 LDFLAGS="$CLEANLDFLAGS"
22727 CPPFLAGS="$CLEANCPPFLAGS"
22728 LIBS="$CLEANLIBS"
22729
22730
22731fi
22732rm -f core conftest.err conftest.$ac_objext \
22733 conftest$ac_exeext conftest.$ac_ext
22734
22735
22736fi
22737rm -f core conftest.err conftest.$ac_objext \
22738 conftest$ac_exeext conftest.$ac_ext
22739
22740
22741fi
22742
22743
22744fi
22745
22746
22747 if test X"$HAVECRYPTO" = X"yes"; then
22748
22749 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SSL_connect in -lssl" >&5
22750$as_echo_n "checking for SSL_connect in -lssl... " >&6; }
22751if ${ac_cv_lib_ssl_SSL_connect+:} false; then :
22752 $as_echo_n "(cached) " >&6
22753else
22754 ac_check_lib_save_LIBS=$LIBS
22755LIBS="-lssl $LIBS"
22756cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22757/* end confdefs.h. */
22758
22759
22760#ifdef __cplusplus
22761extern "C"
22762#endif
22763char SSL_connect ();
22764int main (void)
22765{
22766return SSL_connect ();
22767 ;
22768 return 0;
22769}
22770_ACEOF
22771if ac_fn_c_try_link "$LINENO"; then :
22772 ac_cv_lib_ssl_SSL_connect=yes
22773else
22774 ac_cv_lib_ssl_SSL_connect=no
22775fi
22776rm -f core conftest.err conftest.$ac_objext \
22777 conftest$ac_exeext conftest.$ac_ext
22778LIBS=$ac_check_lib_save_LIBS
22779fi
22780{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ssl_SSL_connect" >&5
22781$as_echo "$ac_cv_lib_ssl_SSL_connect" >&6; }
22782if test "x$ac_cv_lib_ssl_SSL_connect" = xyes; then :
22783 cat >>confdefs.h <<_ACEOF
22784#define HAVE_LIBSSL 1
22785_ACEOF
22786
22787 LIBS="-lssl $LIBS"
22788
22789fi
22790
22791
22792 if test "$ac_cv_lib_ssl_SSL_connect" != yes; then
22793 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssl with RSAglue/rsaref libs in use" >&5
22794$as_echo_n "checking for ssl with RSAglue/rsaref libs in use... " >&6; };
22795 OLIBS=$LIBS
22796 LIBS="-lRSAglue -lrsaref $LIBS"
22797 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SSL_connect in -lssl" >&5
22798$as_echo_n "checking for SSL_connect in -lssl... " >&6; }
22799if ${ac_cv_lib_ssl_SSL_connect+:} false; then :
22800 $as_echo_n "(cached) " >&6
22801else
22802 ac_check_lib_save_LIBS=$LIBS
22803LIBS="-lssl $LIBS"
22804cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22805/* end confdefs.h. */
22806
22807
22808#ifdef __cplusplus
22809extern "C"
22810#endif
22811char SSL_connect ();
22812int main (void)
22813{
22814return SSL_connect ();
22815 ;
22816 return 0;
22817}
22818_ACEOF
22819if ac_fn_c_try_link "$LINENO"; then :
22820 ac_cv_lib_ssl_SSL_connect=yes
22821else
22822 ac_cv_lib_ssl_SSL_connect=no
22823fi
22824rm -f core conftest.err conftest.$ac_objext \
22825 conftest$ac_exeext conftest.$ac_ext
22826LIBS=$ac_check_lib_save_LIBS
22827fi
22828{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ssl_SSL_connect" >&5
22829$as_echo "$ac_cv_lib_ssl_SSL_connect" >&6; }
22830if test "x$ac_cv_lib_ssl_SSL_connect" = xyes; then :
22831 cat >>confdefs.h <<_ACEOF
22832#define HAVE_LIBSSL 1
22833_ACEOF
22834
22835 LIBS="-lssl $LIBS"
22836
22837fi
22838
22839 if test "$ac_cv_lib_ssl_SSL_connect" != yes; then
22840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22841$as_echo "no" >&6; }
22842 LIBS=$OLIBS
22843 else
22844 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22845$as_echo "yes" >&6; }
22846 fi
22847
22848 else
22849
22850 for ac_header in openssl/x509.h openssl/rsa.h openssl/crypto.h \
22851 openssl/pem.h openssl/ssl.h openssl/err.h
22852do :
22853 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
22854ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
22855if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
22856 cat >>confdefs.h <<_ACEOF
22857#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
22858_ACEOF
Alex Deymo486467e2017-12-19 19:04:07 +010022859 ssl_msg="OpenSSL"
22860 test openssl != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
Elliott Hughes82be86d2017-09-20 17:00:17 -070022861 OPENSSL_ENABLED=1
22862
22863$as_echo "#define USE_OPENSSL 1" >>confdefs.h
22864
22865fi
22866
22867done
22868
22869
22870 if test $ac_cv_header_openssl_x509_h = no; then
22871 for ac_header in x509.h rsa.h crypto.h pem.h ssl.h err.h
22872do :
22873 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
22874ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
22875if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
22876 cat >>confdefs.h <<_ACEOF
22877#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
22878_ACEOF
22879
22880fi
22881
22882done
22883
22884
22885 if test $ac_cv_header_x509_h = yes &&
22886 test $ac_cv_header_crypto_h = yes &&
22887 test $ac_cv_header_ssl_h = yes; then
Alex Deymo486467e2017-12-19 19:04:07 +010022888 ssl_msg="OpenSSL"
Elliott Hughes82be86d2017-09-20 17:00:17 -070022889 OPENSSL_ENABLED=1
22890 fi
22891 fi
22892 fi
22893
Alex Deymo486467e2017-12-19 19:04:07 +010022894 if test X"$OPENSSL_ENABLED" != X"1"; then
Elliott Hughes82be86d2017-09-20 17:00:17 -070022895 LIBS="$CLEANLIBS"
22896 fi
22897
22898 if test X"$OPT_SSL" != Xoff &&
22899 test "$OPENSSL_ENABLED" != "1"; then
22900 as_fn_error $? "OpenSSL libs and/or directories were not found where specified!" "$LINENO" 5
22901 fi
22902 fi
22903
22904 if test X"$OPENSSL_ENABLED" = X"1"; then
Elliott Hughes82be86d2017-09-20 17:00:17 -070022905
22906 for ac_func in RAND_egd \
Haibo Huang51d9d882019-02-06 01:36:06 -080022907 SSLv2_client_method \
22908 OpenSSL_version
Elliott Hughes82be86d2017-09-20 17:00:17 -070022909do :
22910 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
22911ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
22912if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
22913 cat >>confdefs.h <<_ACEOF
22914#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
22915_ACEOF
22916
22917fi
22918done
22919
22920
22921 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BoringSSL" >&5
22922$as_echo_n "checking for BoringSSL... " >&6; }
22923 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22924/* end confdefs.h. */
22925
22926
22927 #include <openssl/base.h>
22928
22929int main (void)
22930{
22931
22932 #ifndef OPENSSL_IS_BORINGSSL
22933 #error not boringssl
22934 #endif
22935
22936 ;
22937 return 0;
22938}
22939
22940_ACEOF
22941if ac_fn_c_try_compile "$LINENO"; then :
22942
22943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22944$as_echo "yes" >&6; }
22945
22946cat >>confdefs.h <<_ACEOF
22947#define HAVE_BORINGSSL 1
22948_ACEOF
22949
Alex Deymo486467e2017-12-19 19:04:07 +010022950 ssl_msg="BoringSSL"
Elliott Hughes82be86d2017-09-20 17:00:17 -070022951
22952else
22953
22954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22955$as_echo "no" >&6; }
22956
22957fi
22958rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22959
22960 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libressl" >&5
22961$as_echo_n "checking for libressl... " >&6; }
22962 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22963/* end confdefs.h. */
22964
22965
22966#include <openssl/opensslv.h>
22967
22968int main (void)
22969{
22970
22971 int dummy = LIBRESSL_VERSION_NUMBER;
22972
22973 ;
22974 return 0;
22975}
22976
22977_ACEOF
22978if ac_fn_c_try_compile "$LINENO"; then :
22979
22980 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22981$as_echo "yes" >&6; }
22982
22983cat >>confdefs.h <<_ACEOF
22984#define HAVE_LIBRESSL 1
22985_ACEOF
22986
Alex Deymo486467e2017-12-19 19:04:07 +010022987 ssl_msg="libressl"
Elliott Hughes82be86d2017-09-20 17:00:17 -070022988
22989else
22990
22991 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22992$as_echo "no" >&6; }
22993
22994fi
22995rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22996 fi
22997
22998 if test "$OPENSSL_ENABLED" = "1"; then
22999 if test -n "$LIB_OPENSSL"; then
23000 if test "x$cross_compiling" != "xyes"; then
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070023001 CURL_LIBRARY_PATH="$CURL_LIBRARY_PATH:$LIB_OPENSSL"
23002 export CURL_LIBRARY_PATH
23003 { $as_echo "$as_me:${as_lineno-$LINENO}: Added $LIB_OPENSSL to CURL_LIBRARY_PATH" >&5
23004$as_echo "$as_me: Added $LIB_OPENSSL to CURL_LIBRARY_PATH" >&6;}
Elliott Hughes82be86d2017-09-20 17:00:17 -070023005 fi
23006 fi
23007
23008 #
23009
23010 #
23011 tst_api="unknown"
23012 #
23013 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OpenSSL headers version" >&5
23014$as_echo_n "checking for OpenSSL headers version... " >&6; }
23015
23016 OLDCPPFLAGS=$CPPFLAGS
23017 # CPPPFLAG comes from CURL_CPP_P
23018 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
23019 if test -z "$SED"; then
23020 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
23021 fi
23022 if test -z "$GREP"; then
23023 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
23024 fi
23025
23026 tmp_exp=""
23027 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23028/* end confdefs.h. */
23029
23030
23031# ifdef USE_OPENSSL
23032# include <openssl/crypto.h>
23033# else
23034# include <crypto.h>
23035# endif
23036
23037#ifdef OPENSSL_VERSION_NUMBER
23038CURL_DEF_TOKEN OPENSSL_VERSION_NUMBER
23039#endif
23040
23041
23042_ACEOF
23043if ac_fn_c_try_cpp "$LINENO"; then :
23044
23045 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
23046 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
23047 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
23048 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
23049 if test -z "$tmp_exp" || test "$tmp_exp" = "OPENSSL_VERSION_NUMBER"; then
23050 tmp_exp=""
23051 fi
23052
23053fi
23054rm -f conftest.err conftest.i conftest.$ac_ext
23055 if test -z "$tmp_exp"; then
23056 curl_cv_have_def_OPENSSL_VERSION_NUMBER=no
23057
23058 else
23059 curl_cv_have_def_OPENSSL_VERSION_NUMBER=yes
23060 curl_cv_def_OPENSSL_VERSION_NUMBER=$tmp_exp
23061
23062 fi
23063 CPPFLAGS=$OLDCPPFLAGS
23064
23065 if test "$curl_cv_have_def_OPENSSL_VERSION_NUMBER" = "yes"; then
23066 tst_verlen=`expr "$curl_cv_def_OPENSSL_VERSION_NUMBER" : '.*'`
23067 case "x$tst_verlen" in
23068 x6)
23069 tst_vermaj=`echo $curl_cv_def_OPENSSL_VERSION_NUMBER | cut -c 3`
23070 tst_vermin=`echo $curl_cv_def_OPENSSL_VERSION_NUMBER | cut -c 4`
23071 tst_verfix=`echo $curl_cv_def_OPENSSL_VERSION_NUMBER | cut -c 5`
23072 tst_api=0x$tst_vermaj$tst_vermin$tst_verfix
23073 ;;
23074 x11|x10)
23075 tst_vermaj=`echo $curl_cv_def_OPENSSL_VERSION_NUMBER | cut -c 3`
23076 tst_vermin=`echo $curl_cv_def_OPENSSL_VERSION_NUMBER | cut -c 5`
23077 tst_verfix=`echo $curl_cv_def_OPENSSL_VERSION_NUMBER | cut -c 7`
23078 tst_api=0x$tst_vermaj$tst_vermin$tst_verfix
23079 ;;
23080 *)
23081 tst_api="unknown"
23082 ;;
23083 esac
23084 case $tst_api in
Elliott Hughescac39802018-04-27 16:19:43 -070023085 0x111) tst_show="1.1.1" ;;
Elliott Hughes82be86d2017-09-20 17:00:17 -070023086 0x110) tst_show="1.1.0" ;;
23087 0x102) tst_show="1.0.2" ;;
23088 0x101) tst_show="1.0.1" ;;
23089 0x100) tst_show="1.0.0" ;;
23090 0x099) tst_show="0.9.9" ;;
23091 0x098) tst_show="0.9.8" ;;
23092 0x097) tst_show="0.9.7" ;;
23093 0x096) tst_show="0.9.6" ;;
23094 0x095) tst_show="0.9.5" ;;
23095 0x094) tst_show="0.9.4" ;;
23096 0x093) tst_show="0.9.3" ;;
23097 0x092) tst_show="0.9.2" ;;
23098 0x091) tst_show="0.9.1" ;;
23099 *) tst_show="unknown" ;;
23100 esac
23101 tst_show="$tst_show - $curl_cv_def_OPENSSL_VERSION_NUMBER"
23102 else
23103 tst_show="unknown"
23104 fi
23105 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tst_show" >&5
23106$as_echo "$tst_show" >&6; }
23107 #
23108 curl_openssl_api_headers=$tst_api
23109
23110
23111 #
23112 tst_api="unknown"
23113 #
23114 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OpenSSL library version" >&5
23115$as_echo_n "checking for OpenSSL library version... " >&6; }
23116 if test "$tst_api" = "unknown"; then
Elliott Hughescac39802018-04-27 16:19:43 -070023117 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23118/* end confdefs.h. */
23119
23120
23121#define ERR_clear_last_mark innocuous_ERR_clear_last_mark
23122#ifdef __STDC__
23123# include <limits.h>
23124#else
23125# include <assert.h>
23126#endif
23127#undef ERR_clear_last_mark
23128#ifdef __cplusplus
23129extern "C"
23130#endif
23131char ERR_clear_last_mark ();
23132#if defined __stub_ERR_clear_last_mark || defined __stub___ERR_clear_last_mark
23133choke me
23134#endif
23135
23136int main (void)
23137{
23138return ERR_clear_last_mark ();
23139 ;
23140 return 0;
23141}
23142
23143_ACEOF
23144if ac_fn_c_try_link "$LINENO"; then :
23145
23146 tst_api="0x111"
23147
23148fi
23149rm -f core conftest.err conftest.$ac_objext \
23150 conftest$ac_exeext conftest.$ac_ext
23151 fi
23152 if test "$tst_api" = "unknown"; then
Elliott Hughes82be86d2017-09-20 17:00:17 -070023153 case $host in
23154 *-*-vms*)
23155 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23156/* end confdefs.h. */
23157
23158
23159#define SSL_CTX_set_not_resumbl_sess_cb innocuous_SSL_CTX_set_not_resumbl_sess_cb
23160#ifdef __STDC__
23161# include <limits.h>
23162#else
23163# include <assert.h>
23164#endif
23165#undef SSL_CTX_set_not_resumbl_sess_cb
23166#ifdef __cplusplus
23167extern "C"
23168#endif
23169char SSL_CTX_set_not_resumbl_sess_cb ();
23170#if defined __stub_SSL_CTX_set_not_resumbl_sess_cb || defined __stub___SSL_CTX_set_not_resumbl_sess_cb
23171choke me
23172#endif
23173
23174int main (void)
23175{
23176return SSL_CTX_set_not_resumbl_sess_cb ();
23177 ;
23178 return 0;
23179}
23180
23181_ACEOF
23182if ac_fn_c_try_link "$LINENO"; then :
23183
23184 tst_api="0x110"
23185
23186fi
23187rm -f core conftest.err conftest.$ac_objext \
23188 conftest$ac_exeext conftest.$ac_ext
23189 ;;
23190 *)
23191 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23192/* end confdefs.h. */
23193
23194
23195#define SSL_CTX_set_not_resumable_session_callback innocuous_SSL_CTX_set_not_resumable_session_callback
23196#ifdef __STDC__
23197# include <limits.h>
23198#else
23199# include <assert.h>
23200#endif
23201#undef SSL_CTX_set_not_resumable_session_callback
23202#ifdef __cplusplus
23203extern "C"
23204#endif
23205char SSL_CTX_set_not_resumable_session_callback ();
23206#if defined __stub_SSL_CTX_set_not_resumable_session_callback || defined __stub___SSL_CTX_set_not_resumable_session_callback
23207choke me
23208#endif
23209
23210int main (void)
23211{
23212return SSL_CTX_set_not_resumable_session_callback ();
23213 ;
23214 return 0;
23215}
23216
23217_ACEOF
23218if ac_fn_c_try_link "$LINENO"; then :
23219
23220 tst_api="0x110"
23221
23222fi
23223rm -f core conftest.err conftest.$ac_objext \
23224 conftest$ac_exeext conftest.$ac_ext
23225 ;;
23226 esac
23227 fi
23228 if test "$tst_api" = "unknown"; then
23229 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23230/* end confdefs.h. */
23231
23232
23233#define SSL_CONF_CTX_new innocuous_SSL_CONF_CTX_new
23234#ifdef __STDC__
23235# include <limits.h>
23236#else
23237# include <assert.h>
23238#endif
23239#undef SSL_CONF_CTX_new
23240#ifdef __cplusplus
23241extern "C"
23242#endif
23243char SSL_CONF_CTX_new ();
23244#if defined __stub_SSL_CONF_CTX_new || defined __stub___SSL_CONF_CTX_new
23245choke me
23246#endif
23247
23248int main (void)
23249{
23250return SSL_CONF_CTX_new ();
23251 ;
23252 return 0;
23253}
23254
23255_ACEOF
23256if ac_fn_c_try_link "$LINENO"; then :
23257
23258 tst_api="0x102"
23259
23260fi
23261rm -f core conftest.err conftest.$ac_objext \
23262 conftest$ac_exeext conftest.$ac_ext
23263 fi
23264 if test "$tst_api" = "unknown"; then
23265 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23266/* end confdefs.h. */
23267
23268
23269#define SSL_renegotiate_abbreviated innocuous_SSL_renegotiate_abbreviated
23270#ifdef __STDC__
23271# include <limits.h>
23272#else
23273# include <assert.h>
23274#endif
23275#undef SSL_renegotiate_abbreviated
23276#ifdef __cplusplus
23277extern "C"
23278#endif
23279char SSL_renegotiate_abbreviated ();
23280#if defined __stub_SSL_renegotiate_abbreviated || defined __stub___SSL_renegotiate_abbreviated
23281choke me
23282#endif
23283
23284int main (void)
23285{
23286return SSL_renegotiate_abbreviated ();
23287 ;
23288 return 0;
23289}
23290
23291_ACEOF
23292if ac_fn_c_try_link "$LINENO"; then :
23293
23294 tst_api="0x101"
23295
23296fi
23297rm -f core conftest.err conftest.$ac_objext \
23298 conftest$ac_exeext conftest.$ac_ext
23299 fi
23300 if test "$tst_api" = "unknown"; then
23301 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23302/* end confdefs.h. */
23303
23304
23305#define OBJ_add_sigid innocuous_OBJ_add_sigid
23306#ifdef __STDC__
23307# include <limits.h>
23308#else
23309# include <assert.h>
23310#endif
23311#undef OBJ_add_sigid
23312#ifdef __cplusplus
23313extern "C"
23314#endif
23315char OBJ_add_sigid ();
23316#if defined __stub_OBJ_add_sigid || defined __stub___OBJ_add_sigid
23317choke me
23318#endif
23319
23320int main (void)
23321{
23322return OBJ_add_sigid ();
23323 ;
23324 return 0;
23325}
23326
23327_ACEOF
23328if ac_fn_c_try_link "$LINENO"; then :
23329
23330 tst_api="0x100"
23331
23332fi
23333rm -f core conftest.err conftest.$ac_objext \
23334 conftest$ac_exeext conftest.$ac_ext
23335 fi
23336 if test "$tst_api" = "unknown"; then
23337 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23338/* end confdefs.h. */
23339
23340
23341#define ERR_set_mark innocuous_ERR_set_mark
23342#ifdef __STDC__
23343# include <limits.h>
23344#else
23345# include <assert.h>
23346#endif
23347#undef ERR_set_mark
23348#ifdef __cplusplus
23349extern "C"
23350#endif
23351char ERR_set_mark ();
23352#if defined __stub_ERR_set_mark || defined __stub___ERR_set_mark
23353choke me
23354#endif
23355
23356int main (void)
23357{
23358return ERR_set_mark ();
23359 ;
23360 return 0;
23361}
23362
23363_ACEOF
23364if ac_fn_c_try_link "$LINENO"; then :
23365
23366 tst_api="0x098"
23367
23368fi
23369rm -f core conftest.err conftest.$ac_objext \
23370 conftest$ac_exeext conftest.$ac_ext
23371 fi
23372 if test "$tst_api" = "unknown"; then
23373 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23374/* end confdefs.h. */
23375
23376
23377#define ERR_peek_last_error innocuous_ERR_peek_last_error
23378#ifdef __STDC__
23379# include <limits.h>
23380#else
23381# include <assert.h>
23382#endif
23383#undef ERR_peek_last_error
23384#ifdef __cplusplus
23385extern "C"
23386#endif
23387char ERR_peek_last_error ();
23388#if defined __stub_ERR_peek_last_error || defined __stub___ERR_peek_last_error
23389choke me
23390#endif
23391
23392int main (void)
23393{
23394return ERR_peek_last_error ();
23395 ;
23396 return 0;
23397}
23398
23399_ACEOF
23400if ac_fn_c_try_link "$LINENO"; then :
23401
23402 tst_api="0x097"
23403
23404fi
23405rm -f core conftest.err conftest.$ac_objext \
23406 conftest$ac_exeext conftest.$ac_ext
23407 fi
23408 if test "$tst_api" = "unknown"; then
23409 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23410/* end confdefs.h. */
23411
23412
23413#define c2i_ASN1_OBJECT innocuous_c2i_ASN1_OBJECT
23414#ifdef __STDC__
23415# include <limits.h>
23416#else
23417# include <assert.h>
23418#endif
23419#undef c2i_ASN1_OBJECT
23420#ifdef __cplusplus
23421extern "C"
23422#endif
23423char c2i_ASN1_OBJECT ();
23424#if defined __stub_c2i_ASN1_OBJECT || defined __stub___c2i_ASN1_OBJECT
23425choke me
23426#endif
23427
23428int main (void)
23429{
23430return c2i_ASN1_OBJECT ();
23431 ;
23432 return 0;
23433}
23434
23435_ACEOF
23436if ac_fn_c_try_link "$LINENO"; then :
23437
23438 tst_api="0x096"
23439
23440fi
23441rm -f core conftest.err conftest.$ac_objext \
23442 conftest$ac_exeext conftest.$ac_ext
23443 fi
23444 if test "$tst_api" = "unknown"; then
23445 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23446/* end confdefs.h. */
23447
23448
23449#define SSL_CTX_set_purpose innocuous_SSL_CTX_set_purpose
23450#ifdef __STDC__
23451# include <limits.h>
23452#else
23453# include <assert.h>
23454#endif
23455#undef SSL_CTX_set_purpose
23456#ifdef __cplusplus
23457extern "C"
23458#endif
23459char SSL_CTX_set_purpose ();
23460#if defined __stub_SSL_CTX_set_purpose || defined __stub___SSL_CTX_set_purpose
23461choke me
23462#endif
23463
23464int main (void)
23465{
23466return SSL_CTX_set_purpose ();
23467 ;
23468 return 0;
23469}
23470
23471_ACEOF
23472if ac_fn_c_try_link "$LINENO"; then :
23473
23474 tst_api="0x095"
23475
23476fi
23477rm -f core conftest.err conftest.$ac_objext \
23478 conftest$ac_exeext conftest.$ac_ext
23479 fi
23480 if test "$tst_api" = "unknown"; then
23481 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23482/* end confdefs.h. */
23483
23484
23485#define OBJ_obj2txt innocuous_OBJ_obj2txt
23486#ifdef __STDC__
23487# include <limits.h>
23488#else
23489# include <assert.h>
23490#endif
23491#undef OBJ_obj2txt
23492#ifdef __cplusplus
23493extern "C"
23494#endif
23495char OBJ_obj2txt ();
23496#if defined __stub_OBJ_obj2txt || defined __stub___OBJ_obj2txt
23497choke me
23498#endif
23499
23500int main (void)
23501{
23502return OBJ_obj2txt ();
23503 ;
23504 return 0;
23505}
23506
23507_ACEOF
23508if ac_fn_c_try_link "$LINENO"; then :
23509
23510 tst_api="0x094"
23511
23512fi
23513rm -f core conftest.err conftest.$ac_objext \
23514 conftest$ac_exeext conftest.$ac_ext
23515 fi
23516 if test "$tst_api" = "unknown"; then
23517 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23518/* end confdefs.h. */
23519
23520
23521#define SSL_get_verify_depth innocuous_SSL_get_verify_depth
23522#ifdef __STDC__
23523# include <limits.h>
23524#else
23525# include <assert.h>
23526#endif
23527#undef SSL_get_verify_depth
23528#ifdef __cplusplus
23529extern "C"
23530#endif
23531char SSL_get_verify_depth ();
23532#if defined __stub_SSL_get_verify_depth || defined __stub___SSL_get_verify_depth
23533choke me
23534#endif
23535
23536int main (void)
23537{
23538return SSL_get_verify_depth ();
23539 ;
23540 return 0;
23541}
23542
23543_ACEOF
23544if ac_fn_c_try_link "$LINENO"; then :
23545
23546 tst_api="0x093"
23547
23548fi
23549rm -f core conftest.err conftest.$ac_objext \
23550 conftest$ac_exeext conftest.$ac_ext
23551 fi
23552 if test "$tst_api" = "unknown"; then
23553 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23554/* end confdefs.h. */
23555
23556
23557#define SSL_library_init innocuous_SSL_library_init
23558#ifdef __STDC__
23559# include <limits.h>
23560#else
23561# include <assert.h>
23562#endif
23563#undef SSL_library_init
23564#ifdef __cplusplus
23565extern "C"
23566#endif
23567char SSL_library_init ();
23568#if defined __stub_SSL_library_init || defined __stub___SSL_library_init
23569choke me
23570#endif
23571
23572int main (void)
23573{
23574return SSL_library_init ();
23575 ;
23576 return 0;
23577}
23578
23579_ACEOF
23580if ac_fn_c_try_link "$LINENO"; then :
23581
23582 tst_api="0x092"
23583
23584fi
23585rm -f core conftest.err conftest.$ac_objext \
23586 conftest$ac_exeext conftest.$ac_ext
23587 fi
23588 if test "$tst_api" = "unknown"; then
23589 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23590/* end confdefs.h. */
23591
23592
23593#define SSL_CTX_set_cipher_list innocuous_SSL_CTX_set_cipher_list
23594#ifdef __STDC__
23595# include <limits.h>
23596#else
23597# include <assert.h>
23598#endif
23599#undef SSL_CTX_set_cipher_list
23600#ifdef __cplusplus
23601extern "C"
23602#endif
23603char SSL_CTX_set_cipher_list ();
23604#if defined __stub_SSL_CTX_set_cipher_list || defined __stub___SSL_CTX_set_cipher_list
23605choke me
23606#endif
23607
23608int main (void)
23609{
23610return SSL_CTX_set_cipher_list ();
23611 ;
23612 return 0;
23613}
23614
23615_ACEOF
23616if ac_fn_c_try_link "$LINENO"; then :
23617
23618 tst_api="0x091"
23619
23620fi
23621rm -f core conftest.err conftest.$ac_objext \
23622 conftest$ac_exeext conftest.$ac_ext
23623 fi
23624 case $tst_api in
Elliott Hughescac39802018-04-27 16:19:43 -070023625 0x111) tst_show="1.1.1" ;;
Elliott Hughes82be86d2017-09-20 17:00:17 -070023626 0x110) tst_show="1.1.0" ;;
23627 0x102) tst_show="1.0.2" ;;
23628 0x101) tst_show="1.0.1" ;;
23629 0x100) tst_show="1.0.0" ;;
23630 0x099) tst_show="0.9.9" ;;
23631 0x098) tst_show="0.9.8" ;;
23632 0x097) tst_show="0.9.7" ;;
23633 0x096) tst_show="0.9.6" ;;
23634 0x095) tst_show="0.9.5" ;;
23635 0x094) tst_show="0.9.4" ;;
23636 0x093) tst_show="0.9.3" ;;
23637 0x092) tst_show="0.9.2" ;;
23638 0x091) tst_show="0.9.1" ;;
23639 *) tst_show="unknown" ;;
23640 esac
23641 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tst_show" >&5
23642$as_echo "$tst_show" >&6; }
23643 #
23644 curl_openssl_api_library=$tst_api
23645
23646 #
23647 tst_match="yes"
23648 #
23649 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OpenSSL headers and library versions matching" >&5
23650$as_echo_n "checking for OpenSSL headers and library versions matching... " >&6; }
23651 if test "$curl_openssl_api_headers" = "unknown" ||
23652 test "$curl_openssl_api_library" = "unknown"; then
23653 tst_match="fail"
23654 tst_warns="Can not compare OpenSSL headers and library versions."
23655 elif test "$curl_openssl_api_headers" != "$curl_openssl_api_library"; then
23656 tst_match="no"
23657 tst_warns="OpenSSL headers and library versions do not match."
23658 fi
23659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tst_match" >&5
23660$as_echo "$tst_match" >&6; }
23661 if test "$tst_match" != "yes"; then
23662 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $tst_warns" >&5
23663$as_echo "$as_me: WARNING: $tst_warns" >&2;}
23664 fi
23665
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070023666 check_for_ca_bundle=1
Elliott Hughes82be86d2017-09-20 17:00:17 -070023667 fi
23668
Alex Deymo486467e2017-12-19 19:04:07 +010023669 test -z "$ssl_msg" || ssl_backends="${ssl_backends:+$ssl_backends, }$ssl_msg"
Elliott Hughes82be86d2017-09-20 17:00:17 -070023670fi
23671
Haibo Huang34ab3462019-05-22 00:50:27 -070023672if test X"$OPT_SSL" != Xoff &&
23673 test X"$OPT_SSL" != Xno &&
23674 test "$OPENSSL_ENABLED" != "1"; then
23675 { $as_echo "$as_me:${as_lineno-$LINENO}: OPT_SSL: $OPT_SSL" >&5
23676$as_echo "$as_me: OPT_SSL: $OPT_SSL" >&6;}
23677 { $as_echo "$as_me:${as_lineno-$LINENO}: OPENSSL_ENABLED: $OPENSSL_ENABLED" >&5
23678$as_echo "$as_me: OPENSSL_ENABLED: $OPENSSL_ENABLED" >&6;}
23679 as_fn_error $? "--with-ssl was given but OpenSSL could not be detected" "$LINENO" 5
23680fi
23681
Elliott Hughes82be86d2017-09-20 17:00:17 -070023682
23683if test X"$OPENSSL_ENABLED" = X"1"; then
23684
23685# Check whether --with-egd-socket was given.
23686if test "${with_egd_socket+set}" = set; then :
23687 withval=$with_egd_socket; EGD_SOCKET="$withval"
23688
23689fi
23690
23691 if test -n "$EGD_SOCKET" ; then
23692
23693cat >>confdefs.h <<_ACEOF
23694#define EGD_SOCKET "$EGD_SOCKET"
23695_ACEOF
23696
23697 fi
23698
23699
23700# Check whether --with-random was given.
23701if test "${with_random+set}" = set; then :
23702 withval=$with_random; RANDOM_FILE="$withval"
23703else
23704
23705 if test x$cross_compiling != xyes; then
23706 as_ac_File=`$as_echo "ac_cv_file_"/dev/urandom"" | $as_tr_sh`
23707{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for \"/dev/urandom\"" >&5
23708$as_echo_n "checking for \"/dev/urandom\"... " >&6; }
23709if eval \${$as_ac_File+:} false; then :
23710 $as_echo_n "(cached) " >&6
23711else
23712 test "$cross_compiling" = yes &&
23713 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
23714if test -r ""/dev/urandom""; then
23715 eval "$as_ac_File=yes"
23716else
23717 eval "$as_ac_File=no"
23718fi
23719fi
23720eval ac_res=\$$as_ac_File
23721 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
23722$as_echo "$ac_res" >&6; }
23723if eval test \"x\$"$as_ac_File"\" = x"yes"; then :
23724 RANDOM_FILE="/dev/urandom"
23725fi
23726
23727 else
23728 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: skipped the /dev/urandom detection when cross-compiling" >&5
23729$as_echo "$as_me: WARNING: skipped the /dev/urandom detection when cross-compiling" >&2;}
23730 fi
23731
23732
23733fi
23734
23735 if test -n "$RANDOM_FILE" && test X"$RANDOM_FILE" != Xno ; then
23736
23737
23738cat >>confdefs.h <<_ACEOF
23739#define RANDOM_FILE "$RANDOM_FILE"
23740_ACEOF
23741
23742 fi
23743fi
23744
23745if test "$OPENSSL_ENABLED" = "1"; then
23746 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SRP_Calc_client_key in -lcrypto" >&5
23747$as_echo_n "checking for SRP_Calc_client_key in -lcrypto... " >&6; }
23748if ${ac_cv_lib_crypto_SRP_Calc_client_key+:} false; then :
23749 $as_echo_n "(cached) " >&6
23750else
23751 ac_check_lib_save_LIBS=$LIBS
23752LIBS="-lcrypto $LIBS"
23753cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23754/* end confdefs.h. */
23755
23756
23757#ifdef __cplusplus
23758extern "C"
23759#endif
23760char SRP_Calc_client_key ();
23761int main (void)
23762{
23763return SRP_Calc_client_key ();
23764 ;
23765 return 0;
23766}
23767_ACEOF
23768if ac_fn_c_try_link "$LINENO"; then :
23769 ac_cv_lib_crypto_SRP_Calc_client_key=yes
23770else
23771 ac_cv_lib_crypto_SRP_Calc_client_key=no
23772fi
23773rm -f core conftest.err conftest.$ac_objext \
23774 conftest$ac_exeext conftest.$ac_ext
23775LIBS=$ac_check_lib_save_LIBS
23776fi
23777{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_SRP_Calc_client_key" >&5
23778$as_echo "$ac_cv_lib_crypto_SRP_Calc_client_key" >&6; }
23779if test "x$ac_cv_lib_crypto_SRP_Calc_client_key" = xyes; then :
23780
23781
23782$as_echo "#define HAVE_OPENSSL_SRP 1" >>confdefs.h
23783
23784 HAVE_OPENSSL_SRP=1
23785
23786
23787fi
23788
23789fi
23790
Elliott Hughesa93fb052018-12-12 14:22:48 -080023791if test X"$OPENSSL_ENABLED" = X"1"; then
23792# Check whether --enable-openssl-auto-load-config was given.
23793if test "${enable_openssl_auto_load_config+set}" = set; then :
23794 enableval=$enable_openssl_auto_load_config; if test X"$enableval" = X"no"; then
23795 { $as_echo "$as_me:${as_lineno-$LINENO}: automatic loading of OpenSSL configuration disabled" >&5
23796$as_echo "$as_me: automatic loading of OpenSSL configuration disabled" >&6;}
23797
23798$as_echo "#define CURL_DISABLE_OPENSSL_AUTO_LOAD_CONFIG 1" >>confdefs.h
23799
23800 fi
23801
23802fi
23803
23804fi
23805
Elliott Hughes82be86d2017-09-20 17:00:17 -070023806
23807OPT_GNUTLS=no
23808
23809
23810# Check whether --with-gnutls was given.
23811if test "${with_gnutls+set}" = set; then :
23812 withval=$with_gnutls; OPT_GNUTLS=$withval
23813fi
23814
23815
Alex Deymo486467e2017-12-19 19:04:07 +010023816if test -z "$ssl_backends" -o "x$OPT_GNUTLS" != xno; then
23817 ssl_msg=
Elliott Hughes82be86d2017-09-20 17:00:17 -070023818
23819 if test X"$OPT_GNUTLS" != Xno; then
23820
23821 addld=""
23822 addlib=""
23823 gtlslib=""
23824 version=""
23825 addcflags=""
23826
23827 if test "x$OPT_GNUTLS" = "xyes"; then
23828
23829 if test -n "$PKG_CONFIG"; then
23830 PKGCONFIG="$PKG_CONFIG"
23831 else
23832 if test -n "$ac_tool_prefix"; then
23833 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
23834set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
23835{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
23836$as_echo_n "checking for $ac_word... " >&6; }
23837if ${ac_cv_path_PKGCONFIG+:} false; then :
23838 $as_echo_n "(cached) " >&6
23839else
23840 case $PKGCONFIG in
23841 [\\/]* | ?:[\\/]*)
23842 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
23843 ;;
23844 *)
23845 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
23846as_dummy="$PATH:/usr/bin:/usr/local/bin"
23847for as_dir in $as_dummy
23848do
23849 IFS=$as_save_IFS
23850 test -z "$as_dir" && as_dir=.
23851 for ac_exec_ext in '' $ac_executable_extensions; do
23852 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
23853 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
23854 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
23855 break 2
23856 fi
23857done
23858 done
23859IFS=$as_save_IFS
23860
23861 ;;
23862esac
23863fi
23864PKGCONFIG=$ac_cv_path_PKGCONFIG
23865if test -n "$PKGCONFIG"; then
23866 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
23867$as_echo "$PKGCONFIG" >&6; }
23868else
23869 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
23870$as_echo "no" >&6; }
23871fi
23872
23873
23874fi
23875if test -z "$ac_cv_path_PKGCONFIG"; then
23876 ac_pt_PKGCONFIG=$PKGCONFIG
23877 # Extract the first word of "pkg-config", so it can be a program name with args.
23878set dummy pkg-config; ac_word=$2
23879{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
23880$as_echo_n "checking for $ac_word... " >&6; }
23881if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
23882 $as_echo_n "(cached) " >&6
23883else
23884 case $ac_pt_PKGCONFIG in
23885 [\\/]* | ?:[\\/]*)
23886 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
23887 ;;
23888 *)
23889 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
23890as_dummy="$PATH:/usr/bin:/usr/local/bin"
23891for as_dir in $as_dummy
23892do
23893 IFS=$as_save_IFS
23894 test -z "$as_dir" && as_dir=.
23895 for ac_exec_ext in '' $ac_executable_extensions; do
23896 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
23897 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
23898 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
23899 break 2
23900 fi
23901done
23902 done
23903IFS=$as_save_IFS
23904
23905 ;;
23906esac
23907fi
23908ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
23909if test -n "$ac_pt_PKGCONFIG"; then
23910 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
23911$as_echo "$ac_pt_PKGCONFIG" >&6; }
23912else
23913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
23914$as_echo "no" >&6; }
23915fi
23916
23917 if test "x$ac_pt_PKGCONFIG" = x; then
23918 PKGCONFIG="no"
23919 else
23920 case $cross_compiling:$ac_tool_warned in
23921yes:)
23922{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
23923$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
23924ac_tool_warned=yes ;;
23925esac
23926 PKGCONFIG=$ac_pt_PKGCONFIG
23927 fi
23928else
23929 PKGCONFIG="$ac_cv_path_PKGCONFIG"
23930fi
23931
23932 fi
23933
23934 if test "x$PKGCONFIG" != "xno"; then
23935 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gnutls options with pkg-config" >&5
23936$as_echo_n "checking for gnutls options with pkg-config... " >&6; }
23937 itexists=`
23938 if test -n ""; then
23939 PKG_CONFIG_LIBDIR=""
23940 export PKG_CONFIG_LIBDIR
23941 fi
23942 $PKGCONFIG --exists gnutls >/dev/null 2>&1 && echo 1`
23943
23944 if test -z "$itexists"; then
23945 PKGCONFIG="no"
23946 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
23947$as_echo "no" >&6; }
23948 else
23949 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
23950$as_echo "found" >&6; }
23951 fi
23952 fi
23953
23954
23955 if test "$PKGCONFIG" != "no" ; then
23956 addlib=`$PKGCONFIG --libs-only-l gnutls`
23957 addld=`$PKGCONFIG --libs-only-L gnutls`
23958 addcflags=`$PKGCONFIG --cflags-only-I gnutls`
23959 version=`$PKGCONFIG --modversion gnutls`
23960 gtlslib=`echo $addld | $SED -e 's/-L//'`
23961 else
23962 check=`libgnutls-config --version 2>/dev/null`
23963 if test -n "$check"; then
23964 addlib=`libgnutls-config --libs`
23965 addcflags=`libgnutls-config --cflags`
23966 version=`libgnutls-config --version`
23967 gtlslib=`libgnutls-config --prefix`/lib$libsuff
23968 fi
23969 fi
23970 else
23971 cfg=$OPT_GNUTLS/bin/libgnutls-config
23972 check=`$cfg --version 2>/dev/null`
23973 if test -n "$check"; then
23974 addlib=`$cfg --libs`
23975 addcflags=`$cfg --cflags`
23976 version=`$cfg --version`
23977 gtlslib=`$cfg --prefix`/lib$libsuff
23978 else
23979 addlib=-lgnutls
23980 addld=-L$OPT_GNUTLS/lib$libsuff
23981 addcflags=-I$OPT_GNUTLS/include
23982 version="" # we just don't know
23983 gtlslib=$OPT_GNUTLS/lib$libsuff
23984 fi
23985 fi
23986
23987 if test -z "$version"; then
23988 version="unknown"
23989 fi
23990
23991 if test -n "$addlib"; then
23992
23993 CLEANLIBS="$LIBS"
23994 CLEANCPPFLAGS="$CPPFLAGS"
23995 CLEANLDFLAGS="$LDFLAGS"
23996
23997 LIBS="$addlib $LIBS"
23998 LDFLAGS="$LDFLAGS $addld"
23999 if test "$addcflags" != "-I/usr/include"; then
24000 CPPFLAGS="$CPPFLAGS $addcflags"
24001 fi
24002
24003 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gnutls_check_version in -lgnutls" >&5
24004$as_echo_n "checking for gnutls_check_version in -lgnutls... " >&6; }
24005if ${ac_cv_lib_gnutls_gnutls_check_version+:} false; then :
24006 $as_echo_n "(cached) " >&6
24007else
24008 ac_check_lib_save_LIBS=$LIBS
24009LIBS="-lgnutls $LIBS"
24010cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24011/* end confdefs.h. */
24012
24013
24014#ifdef __cplusplus
24015extern "C"
24016#endif
24017char gnutls_check_version ();
24018int main (void)
24019{
24020return gnutls_check_version ();
24021 ;
24022 return 0;
24023}
24024_ACEOF
24025if ac_fn_c_try_link "$LINENO"; then :
24026 ac_cv_lib_gnutls_gnutls_check_version=yes
24027else
24028 ac_cv_lib_gnutls_gnutls_check_version=no
24029fi
24030rm -f core conftest.err conftest.$ac_objext \
24031 conftest$ac_exeext conftest.$ac_ext
24032LIBS=$ac_check_lib_save_LIBS
24033fi
24034{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gnutls_gnutls_check_version" >&5
24035$as_echo "$ac_cv_lib_gnutls_gnutls_check_version" >&6; }
24036if test "x$ac_cv_lib_gnutls_gnutls_check_version" = xyes; then :
24037
24038
24039$as_echo "#define USE_GNUTLS 1" >>confdefs.h
24040
24041 USE_GNUTLS=1
24042
24043 GNUTLS_ENABLED=1
24044 USE_GNUTLS="yes"
Alex Deymo486467e2017-12-19 19:04:07 +010024045 ssl_msg="GnuTLS"
24046 test gnutls != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
Elliott Hughes82be86d2017-09-20 17:00:17 -070024047
24048else
24049
24050 LIBS="$CLEANLIBS"
24051 CPPFLAGS="$CLEANCPPFLAGS"
24052
24053fi
24054
24055
24056 if test "x$USE_GNUTLS" = "xyes"; then
24057 { $as_echo "$as_me:${as_lineno-$LINENO}: detected GnuTLS version $version" >&5
24058$as_echo "$as_me: detected GnuTLS version $version" >&6;}
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070024059 check_for_ca_bundle=1
Elliott Hughes82be86d2017-09-20 17:00:17 -070024060 if test -n "$gtlslib"; then
24061 if test "x$cross_compiling" != "xyes"; then
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070024062 CURL_LIBRARY_PATH="$CURL_LIBRARY_PATH:$gtlslib"
24063 export CURL_LIBRARY_PATH
24064 { $as_echo "$as_me:${as_lineno-$LINENO}: Added $gtlslib to CURL_LIBRARY_PATH" >&5
24065$as_echo "$as_me: Added $gtlslib to CURL_LIBRARY_PATH" >&6;}
Elliott Hughes82be86d2017-09-20 17:00:17 -070024066 fi
24067 fi
24068 for ac_func in gnutls_certificate_set_x509_key_file2 gnutls_alpn_set_protocols gnutls_ocsp_req_init
24069do :
24070 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
24071ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
24072if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
24073 cat >>confdefs.h <<_ACEOF
24074#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
24075_ACEOF
24076
24077fi
24078done
24079
24080 fi
24081
24082 fi
24083
24084 fi
Alex Deymo486467e2017-12-19 19:04:07 +010024085 test -z "$ssl_msg" || ssl_backends="${ssl_backends:+$ssl_backends, }$ssl_msg"
Elliott Hughes82be86d2017-09-20 17:00:17 -070024086fi
24087
24088
24089if test "$GNUTLS_ENABLED" = "1"; then
24090 USE_GNUTLS_NETTLE=
24091 # First check if we can detect either crypto library via transitive linking
24092 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nettle_MD5Init in -lgnutls" >&5
24093$as_echo_n "checking for nettle_MD5Init in -lgnutls... " >&6; }
24094if ${ac_cv_lib_gnutls_nettle_MD5Init+:} false; then :
24095 $as_echo_n "(cached) " >&6
24096else
24097 ac_check_lib_save_LIBS=$LIBS
24098LIBS="-lgnutls $LIBS"
24099cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24100/* end confdefs.h. */
24101
24102
24103#ifdef __cplusplus
24104extern "C"
24105#endif
24106char nettle_MD5Init ();
24107int main (void)
24108{
24109return nettle_MD5Init ();
24110 ;
24111 return 0;
24112}
24113_ACEOF
24114if ac_fn_c_try_link "$LINENO"; then :
24115 ac_cv_lib_gnutls_nettle_MD5Init=yes
24116else
24117 ac_cv_lib_gnutls_nettle_MD5Init=no
24118fi
24119rm -f core conftest.err conftest.$ac_objext \
24120 conftest$ac_exeext conftest.$ac_ext
24121LIBS=$ac_check_lib_save_LIBS
24122fi
24123{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gnutls_nettle_MD5Init" >&5
24124$as_echo "$ac_cv_lib_gnutls_nettle_MD5Init" >&6; }
24125if test "x$ac_cv_lib_gnutls_nettle_MD5Init" = xyes; then :
24126 USE_GNUTLS_NETTLE=1
24127fi
24128
24129 if test "$USE_GNUTLS_NETTLE" = ""; then
24130 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gcry_control in -lgnutls" >&5
24131$as_echo_n "checking for gcry_control in -lgnutls... " >&6; }
24132if ${ac_cv_lib_gnutls_gcry_control+:} false; then :
24133 $as_echo_n "(cached) " >&6
24134else
24135 ac_check_lib_save_LIBS=$LIBS
24136LIBS="-lgnutls $LIBS"
24137cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24138/* end confdefs.h. */
24139
24140
24141#ifdef __cplusplus
24142extern "C"
24143#endif
24144char gcry_control ();
24145int main (void)
24146{
24147return gcry_control ();
24148 ;
24149 return 0;
24150}
24151_ACEOF
24152if ac_fn_c_try_link "$LINENO"; then :
24153 ac_cv_lib_gnutls_gcry_control=yes
24154else
24155 ac_cv_lib_gnutls_gcry_control=no
24156fi
24157rm -f core conftest.err conftest.$ac_objext \
24158 conftest$ac_exeext conftest.$ac_ext
24159LIBS=$ac_check_lib_save_LIBS
24160fi
24161{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gnutls_gcry_control" >&5
24162$as_echo "$ac_cv_lib_gnutls_gcry_control" >&6; }
24163if test "x$ac_cv_lib_gnutls_gcry_control" = xyes; then :
24164 USE_GNUTLS_NETTLE=0
24165fi
24166
24167 fi
24168 # If not, try linking directly to both of them to see if they are available
24169 if test "$USE_GNUTLS_NETTLE" = ""; then
24170 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nettle_MD5Init in -lnettle" >&5
24171$as_echo_n "checking for nettle_MD5Init in -lnettle... " >&6; }
24172if ${ac_cv_lib_nettle_nettle_MD5Init+:} false; then :
24173 $as_echo_n "(cached) " >&6
24174else
24175 ac_check_lib_save_LIBS=$LIBS
24176LIBS="-lnettle $LIBS"
24177cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24178/* end confdefs.h. */
24179
24180
24181#ifdef __cplusplus
24182extern "C"
24183#endif
24184char nettle_MD5Init ();
24185int main (void)
24186{
24187return nettle_MD5Init ();
24188 ;
24189 return 0;
24190}
24191_ACEOF
24192if ac_fn_c_try_link "$LINENO"; then :
24193 ac_cv_lib_nettle_nettle_MD5Init=yes
24194else
24195 ac_cv_lib_nettle_nettle_MD5Init=no
24196fi
24197rm -f core conftest.err conftest.$ac_objext \
24198 conftest$ac_exeext conftest.$ac_ext
24199LIBS=$ac_check_lib_save_LIBS
24200fi
24201{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nettle_nettle_MD5Init" >&5
24202$as_echo "$ac_cv_lib_nettle_nettle_MD5Init" >&6; }
24203if test "x$ac_cv_lib_nettle_nettle_MD5Init" = xyes; then :
24204 USE_GNUTLS_NETTLE=1
24205fi
24206
24207 fi
24208 if test "$USE_GNUTLS_NETTLE" = ""; then
24209 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gcry_control in -lgcrypt" >&5
24210$as_echo_n "checking for gcry_control in -lgcrypt... " >&6; }
24211if ${ac_cv_lib_gcrypt_gcry_control+:} false; then :
24212 $as_echo_n "(cached) " >&6
24213else
24214 ac_check_lib_save_LIBS=$LIBS
24215LIBS="-lgcrypt $LIBS"
24216cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24217/* end confdefs.h. */
24218
24219
24220#ifdef __cplusplus
24221extern "C"
24222#endif
24223char gcry_control ();
24224int main (void)
24225{
24226return gcry_control ();
24227 ;
24228 return 0;
24229}
24230_ACEOF
24231if ac_fn_c_try_link "$LINENO"; then :
24232 ac_cv_lib_gcrypt_gcry_control=yes
24233else
24234 ac_cv_lib_gcrypt_gcry_control=no
24235fi
24236rm -f core conftest.err conftest.$ac_objext \
24237 conftest$ac_exeext conftest.$ac_ext
24238LIBS=$ac_check_lib_save_LIBS
24239fi
24240{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gcrypt_gcry_control" >&5
24241$as_echo "$ac_cv_lib_gcrypt_gcry_control" >&6; }
24242if test "x$ac_cv_lib_gcrypt_gcry_control" = xyes; then :
24243 USE_GNUTLS_NETTLE=0
24244fi
24245
24246 fi
24247 if test "$USE_GNUTLS_NETTLE" = ""; then
24248 as_fn_error $? "GnuTLS found, but neither gcrypt nor nettle found" "$LINENO" 5
24249 fi
24250 if test "$USE_GNUTLS_NETTLE" = "1"; then
24251
24252$as_echo "#define USE_GNUTLS_NETTLE 1" >>confdefs.h
24253
24254 USE_GNUTLS_NETTLE=1
24255
24256 LIBS="-lnettle $LIBS"
24257 else
24258 LIBS="-lgcrypt $LIBS"
24259 fi
24260fi
24261
24262if test "$GNUTLS_ENABLED" = "1"; then
24263 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gnutls_srp_verifier in -lgnutls" >&5
24264$as_echo_n "checking for gnutls_srp_verifier in -lgnutls... " >&6; }
24265if ${ac_cv_lib_gnutls_gnutls_srp_verifier+:} false; then :
24266 $as_echo_n "(cached) " >&6
24267else
24268 ac_check_lib_save_LIBS=$LIBS
24269LIBS="-lgnutls $LIBS"
24270cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24271/* end confdefs.h. */
24272
24273
24274#ifdef __cplusplus
24275extern "C"
24276#endif
24277char gnutls_srp_verifier ();
24278int main (void)
24279{
24280return gnutls_srp_verifier ();
24281 ;
24282 return 0;
24283}
24284_ACEOF
24285if ac_fn_c_try_link "$LINENO"; then :
24286 ac_cv_lib_gnutls_gnutls_srp_verifier=yes
24287else
24288 ac_cv_lib_gnutls_gnutls_srp_verifier=no
24289fi
24290rm -f core conftest.err conftest.$ac_objext \
24291 conftest$ac_exeext conftest.$ac_ext
24292LIBS=$ac_check_lib_save_LIBS
24293fi
24294{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gnutls_gnutls_srp_verifier" >&5
24295$as_echo "$ac_cv_lib_gnutls_gnutls_srp_verifier" >&6; }
24296if test "x$ac_cv_lib_gnutls_gnutls_srp_verifier" = xyes; then :
24297
24298
24299$as_echo "#define HAVE_GNUTLS_SRP 1" >>confdefs.h
24300
24301 HAVE_GNUTLS_SRP=1
24302
24303
24304fi
24305
24306fi
24307
24308
Elliott Hughes82be86d2017-09-20 17:00:17 -070024309OPT_MBEDTLS=no
24310
24311_cppflags=$CPPFLAGS
24312_ldflags=$LDFLAGS
24313
24314# Check whether --with-mbedtls was given.
24315if test "${with_mbedtls+set}" = set; then :
24316 withval=$with_mbedtls; OPT_MBEDTLS=$withval
24317fi
24318
24319
Alex Deymo486467e2017-12-19 19:04:07 +010024320if test -z "$ssl_backends" -o "x$OPT_MBEDTLS" != xno; then
24321 ssl_msg=
Elliott Hughes82be86d2017-09-20 17:00:17 -070024322
24323 if test X"$OPT_MBEDTLS" != Xno; then
24324
24325 if test "$OPT_MBEDTLS" = "yes"; then
24326 OPT_MBEDTLS=""
24327 fi
24328
24329 if test -z "$OPT_MBEDTLS" ; then
24330
24331 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbedtls_havege_init in -lmbedtls" >&5
24332$as_echo_n "checking for mbedtls_havege_init in -lmbedtls... " >&6; }
24333if ${ac_cv_lib_mbedtls_mbedtls_havege_init+:} false; then :
24334 $as_echo_n "(cached) " >&6
24335else
24336 ac_check_lib_save_LIBS=$LIBS
24337LIBS="-lmbedtls -lmbedx509 -lmbedcrypto $LIBS"
24338cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24339/* end confdefs.h. */
24340
24341
24342#ifdef __cplusplus
24343extern "C"
24344#endif
24345char mbedtls_havege_init ();
24346int main (void)
24347{
24348return mbedtls_havege_init ();
24349 ;
24350 return 0;
24351}
24352_ACEOF
24353if ac_fn_c_try_link "$LINENO"; then :
24354 ac_cv_lib_mbedtls_mbedtls_havege_init=yes
24355else
24356 ac_cv_lib_mbedtls_mbedtls_havege_init=no
24357fi
24358rm -f core conftest.err conftest.$ac_objext \
24359 conftest$ac_exeext conftest.$ac_ext
24360LIBS=$ac_check_lib_save_LIBS
24361fi
24362{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mbedtls_mbedtls_havege_init" >&5
24363$as_echo "$ac_cv_lib_mbedtls_mbedtls_havege_init" >&6; }
24364if test "x$ac_cv_lib_mbedtls_mbedtls_havege_init" = xyes; then :
24365
24366
24367$as_echo "#define USE_MBEDTLS 1" >>confdefs.h
24368
24369 USE_MBEDTLS=1
24370
24371 MBEDTLS_ENABLED=1
24372 USE_MBEDTLS="yes"
Alex Deymo486467e2017-12-19 19:04:07 +010024373 ssl_msg="mbedTLS"
24374 test mbedtls != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
Elliott Hughes82be86d2017-09-20 17:00:17 -070024375
24376fi
24377
24378 fi
24379
24380 addld=""
24381 addlib=""
24382 addcflags=""
24383 mbedtlslib=""
24384
24385 if test "x$USE_MBEDTLS" != "xyes"; then
24386 addld=-L$OPT_MBEDTLS/lib$libsuff
24387 addcflags=-I$OPT_MBEDTLS/include
24388 mbedtlslib=$OPT_MBEDTLS/lib$libsuff
24389
24390 LDFLAGS="$LDFLAGS $addld"
24391 if test "$addcflags" != "-I/usr/include"; then
24392 CPPFLAGS="$CPPFLAGS $addcflags"
24393 fi
24394
24395 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbedtls_ssl_init in -lmbedtls" >&5
24396$as_echo_n "checking for mbedtls_ssl_init in -lmbedtls... " >&6; }
24397if ${ac_cv_lib_mbedtls_mbedtls_ssl_init+:} false; then :
24398 $as_echo_n "(cached) " >&6
24399else
24400 ac_check_lib_save_LIBS=$LIBS
24401LIBS="-lmbedtls -lmbedx509 -lmbedcrypto $LIBS"
24402cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24403/* end confdefs.h. */
24404
24405
24406#ifdef __cplusplus
24407extern "C"
24408#endif
24409char mbedtls_ssl_init ();
24410int main (void)
24411{
24412return mbedtls_ssl_init ();
24413 ;
24414 return 0;
24415}
24416_ACEOF
24417if ac_fn_c_try_link "$LINENO"; then :
24418 ac_cv_lib_mbedtls_mbedtls_ssl_init=yes
24419else
24420 ac_cv_lib_mbedtls_mbedtls_ssl_init=no
24421fi
24422rm -f core conftest.err conftest.$ac_objext \
24423 conftest$ac_exeext conftest.$ac_ext
24424LIBS=$ac_check_lib_save_LIBS
24425fi
24426{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mbedtls_mbedtls_ssl_init" >&5
24427$as_echo "$ac_cv_lib_mbedtls_mbedtls_ssl_init" >&6; }
24428if test "x$ac_cv_lib_mbedtls_mbedtls_ssl_init" = xyes; then :
24429
24430
24431$as_echo "#define USE_MBEDTLS 1" >>confdefs.h
24432
24433 USE_MBEDTLS=1
24434
24435 MBEDTLS_ENABLED=1
24436 USE_MBEDTLS="yes"
Alex Deymo486467e2017-12-19 19:04:07 +010024437 ssl_msg="mbedTLS"
24438 test mbedtls != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
Elliott Hughes82be86d2017-09-20 17:00:17 -070024439
24440else
24441
24442 CPPFLAGS=$_cppflags
24443 LDFLAGS=$_ldflags
24444
24445fi
24446
24447 fi
24448
24449 if test "x$USE_MBEDTLS" = "xyes"; then
24450 { $as_echo "$as_me:${as_lineno-$LINENO}: detected mbedTLS" >&5
24451$as_echo "$as_me: detected mbedTLS" >&6;}
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070024452 check_for_ca_bundle=1
Elliott Hughes82be86d2017-09-20 17:00:17 -070024453
24454 LIBS="-lmbedtls -lmbedx509 -lmbedcrypto $LIBS"
24455
24456 if test -n "$mbedtlslib"; then
24457 if test "x$cross_compiling" != "xyes"; then
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070024458 CURL_LIBRARY_PATH="$CURL_LIBRARY_PATH:$mbedtlslib"
24459 export CURL_LIBRARY_PATH
24460 { $as_echo "$as_me:${as_lineno-$LINENO}: Added $mbedtlslib to CURL_LIBRARY_PATH" >&5
24461$as_echo "$as_me: Added $mbedtlslib to CURL_LIBRARY_PATH" >&6;}
Elliott Hughes82be86d2017-09-20 17:00:17 -070024462 fi
24463 fi
24464 fi
24465
24466 fi
Alex Deymo486467e2017-12-19 19:04:07 +010024467 test -z "$ssl_msg" || ssl_backends="${ssl_backends:+$ssl_backends, }$ssl_msg"
Elliott Hughes82be86d2017-09-20 17:00:17 -070024468fi
24469
24470
Haibo Huang001784b2019-07-19 05:27:28 -070024471OPT_WOLFSSL=no
Elliott Hughes82be86d2017-09-20 17:00:17 -070024472
24473_cppflags=$CPPFLAGS
24474_ldflags=$LDFLAGS
24475
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070024476
24477# Check whether --with-wolfssl was given.
24478if test "${with_wolfssl+set}" = set; then :
Haibo Huang001784b2019-07-19 05:27:28 -070024479 withval=$with_wolfssl; OPT_WOLFSSL=$withval
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070024480fi
24481
24482
Haibo Huang001784b2019-07-19 05:27:28 -070024483if test -z "$ssl_backends" -o "x$OPT_WOLFSSL" != xno; then
Alex Deymo486467e2017-12-19 19:04:07 +010024484 ssl_msg=
Elliott Hughes82be86d2017-09-20 17:00:17 -070024485
Haibo Huang001784b2019-07-19 05:27:28 -070024486 if test X"$OPT_WOLFSSL" != Xno; then
Elliott Hughes82be86d2017-09-20 17:00:17 -070024487
Haibo Huang001784b2019-07-19 05:27:28 -070024488 if test "$OPT_WOLFSSL" = "yes"; then
24489 OPT_WOLFSSL=""
Elliott Hughes82be86d2017-09-20 17:00:17 -070024490 fi
24491
Elliott Hughes82be86d2017-09-20 17:00:17 -070024492 addld=""
24493 addlib=""
24494 addcflags=""
Elliott Hughes82be86d2017-09-20 17:00:17 -070024495
Haibo Huang001784b2019-07-19 05:27:28 -070024496 if test "x$USE_WOLFSSL" != "xyes"; then
Haibo Huang31944072019-11-06 02:28:57 -080024497 addld=-L$OPT_WOLFSSL/lib$libsuff
Haibo Huang001784b2019-07-19 05:27:28 -070024498 addcflags=-I$OPT_WOLFSSL/include
Haibo Huang31944072019-11-06 02:28:57 -080024499 wolfssllibpath=$OPT_WOLFSSL/lib$libsuff
Elliott Hughes82be86d2017-09-20 17:00:17 -070024500
24501 LDFLAGS="$LDFLAGS $addld"
24502 if test "$addcflags" != "-I/usr/include"; then
24503 CPPFLAGS="$CPPFLAGS $addcflags"
24504 fi
24505
Elliott Hughes82be86d2017-09-20 17:00:17 -070024506 my_ac_save_LIBS="$LIBS"
Haibo Huang31944072019-11-06 02:28:57 -080024507 LIBS="-lwolfssl -lm $LIBS"
Elliott Hughes82be86d2017-09-20 17:00:17 -070024508
Haibo Huang31944072019-11-06 02:28:57 -080024509 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wolfSSL_Init in -lwolfssl" >&5
24510$as_echo_n "checking for wolfSSL_Init in -lwolfssl... " >&6; }
Elliott Hughes82be86d2017-09-20 17:00:17 -070024511 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24512/* end confdefs.h. */
24513
24514
24515/* These aren't needed for detection and confuse WolfSSL.
24516 They are set up properly later if it is detected. */
24517#undef SIZEOF_LONG
24518#undef SIZEOF_LONG_LONG
Haibo Huang31944072019-11-06 02:28:57 -080024519#include <wolfssl/ssl.h>
Elliott Hughes82be86d2017-09-20 17:00:17 -070024520
24521int main (void)
24522{
24523
Haibo Huang31944072019-11-06 02:28:57 -080024524 return wolfSSL_Init();
Elliott Hughes82be86d2017-09-20 17:00:17 -070024525
24526 ;
24527 return 0;
24528}
24529
24530_ACEOF
24531if ac_fn_c_try_link "$LINENO"; then :
24532
24533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
24534$as_echo "yes" >&6; }
24535
Haibo Huang001784b2019-07-19 05:27:28 -070024536$as_echo "#define USE_WOLFSSL 1" >>confdefs.h
Elliott Hughes82be86d2017-09-20 17:00:17 -070024537
Haibo Huang001784b2019-07-19 05:27:28 -070024538 USE_WOLFSSL=1
Elliott Hughes82be86d2017-09-20 17:00:17 -070024539
Haibo Huang001784b2019-07-19 05:27:28 -070024540 WOLFSSL_ENABLED=1
24541 USE_WOLFSSL="yes"
Alex Deymo486467e2017-12-19 19:04:07 +010024542 ssl_msg="WolfSSL"
Haibo Huang31944072019-11-06 02:28:57 -080024543 test wolfssl != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
Elliott Hughes82be86d2017-09-20 17:00:17 -070024544
24545else
24546
24547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24548$as_echo "no" >&6; }
24549 CPPFLAGS=$_cppflags
24550 LDFLAGS=$_ldflags
Haibo Huang31944072019-11-06 02:28:57 -080024551 wolfssllibpath=""
Elliott Hughes82be86d2017-09-20 17:00:17 -070024552
24553fi
24554rm -f core conftest.err conftest.$ac_objext \
24555 conftest$ac_exeext conftest.$ac_ext
24556 LIBS="$my_ac_save_LIBS"
24557 fi
24558
Haibo Huang001784b2019-07-19 05:27:28 -070024559 if test "x$USE_WOLFSSL" = "xyes"; then
Haibo Huang31944072019-11-06 02:28:57 -080024560 { $as_echo "$as_me:${as_lineno-$LINENO}: detected wolfSSL" >&5
24561$as_echo "$as_me: detected wolfSSL" >&6;}
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070024562 check_for_ca_bundle=1
Elliott Hughes82be86d2017-09-20 17:00:17 -070024563
Elliott Hughes72d948d2018-08-03 14:37:21 -070024564 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070024565$as_echo_n "checking size of long long... " >&6; }
24566if ${ac_cv_sizeof_long_long+:} false; then :
24567 $as_echo_n "(cached) " >&6
24568else
Elliott Hughes72d948d2018-08-03 14:37:21 -070024569 for ac_size in 4 8 1 2 16 ; do # List sizes in rough order of prevalence.
24570 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24571/* end confdefs.h. */
Elliott Hughes82be86d2017-09-20 17:00:17 -070024572
Elliott Hughes72d948d2018-08-03 14:37:21 -070024573#include <sys/types.h>
24574
24575
24576int main (void)
24577{
24578switch (0) case 0: case (sizeof (long long) == $ac_size):;
24579 ;
24580 return 0;
24581}
24582_ACEOF
24583if ac_fn_c_try_compile "$LINENO"; then :
24584 ac_cv_sizeof_long_long=$ac_size
24585fi
24586rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24587 if test x$ac_cv_sizeof_long_long != x ; then break; fi
24588done
24589
Elliott Hughes82be86d2017-09-20 17:00:17 -070024590fi
24591
Elliott Hughes72d948d2018-08-03 14:37:21 -070024592if test x$ac_cv_sizeof_long_long = x ; then
24593 as_fn_error $? "cannot determine a size for long long" "$LINENO" 5
Elliott Hughes82be86d2017-09-20 17:00:17 -070024594fi
24595{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5
24596$as_echo "$ac_cv_sizeof_long_long" >&6; }
24597
Elliott Hughes82be86d2017-09-20 17:00:17 -070024598cat >>confdefs.h <<_ACEOF
24599#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
24600_ACEOF
24601
24602
24603
Haibo Huang31944072019-11-06 02:28:57 -080024604 LIBS="-lwolfssl -lm $LIBS"
Elliott Hughes82be86d2017-09-20 17:00:17 -070024605
Haibo Huang001784b2019-07-19 05:27:28 -070024606 for ac_func in wolfSSLv3_client_method \
24607 wolfSSL_get_peer_certificate \
24608 wolfSSL_UseALPN
Elliott Hughes82be86d2017-09-20 17:00:17 -070024609do :
24610 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
24611ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
24612if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
24613 cat >>confdefs.h <<_ACEOF
24614#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
24615_ACEOF
24616
24617fi
24618done
24619
Elliott Hughes82be86d2017-09-20 17:00:17 -070024620
Haibo Huang31944072019-11-06 02:28:57 -080024621 if test -n "$wolfssllibpath"; then
Elliott Hughes82be86d2017-09-20 17:00:17 -070024622 if test "x$cross_compiling" != "xyes"; then
Haibo Huang31944072019-11-06 02:28:57 -080024623 CURL_LIBRARY_PATH="$CURL_LIBRARY_PATH:$wolfssllibpath"
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070024624 export CURL_LIBRARY_PATH
Haibo Huang31944072019-11-06 02:28:57 -080024625 { $as_echo "$as_me:${as_lineno-$LINENO}: Added $wolfssllibpath to CURL_LIBRARY_PATH" >&5
24626$as_echo "$as_me: Added $wolfssllibpath to CURL_LIBRARY_PATH" >&6;}
Elliott Hughes82be86d2017-09-20 17:00:17 -070024627 fi
24628 fi
24629
24630 fi
24631
24632 fi
Alex Deymo486467e2017-12-19 19:04:07 +010024633 test -z "$ssl_msg" || ssl_backends="${ssl_backends:+$ssl_backends, }$ssl_msg"
Elliott Hughes82be86d2017-09-20 17:00:17 -070024634fi
24635
24636
Elliott Hughesa93fb052018-12-12 14:22:48 -080024637OPT_MESALINK=no
24638
24639_cppflags=$CPPFLAGS
24640_ldflags=$LDFLAGS
24641
24642# Check whether --with-mesalink was given.
24643if test "${with_mesalink+set}" = set; then :
24644 withval=$with_mesalink; OPT_MESALINK=$withval
24645fi
24646
24647
24648if test -z "$ssl_backends" -o "x$OPT_MESALINK" != xno; then
24649 ssl_msg=
24650
24651 if test X"$OPT_MESALINK" != Xno; then
24652
24653 if test "$OPT_MESALINK" = "yes"; then
24654 OPT_MESALINK=""
24655 fi
24656
24657 if test -z "$OPT_MESALINK" ; then
24658
24659 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mesalink_library_init in -lmesalink" >&5
24660$as_echo_n "checking for mesalink_library_init in -lmesalink... " >&6; }
24661if ${ac_cv_lib_mesalink_mesalink_library_init+:} false; then :
24662 $as_echo_n "(cached) " >&6
24663else
24664 ac_check_lib_save_LIBS=$LIBS
24665LIBS="-lmesalink $LIBS"
24666cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24667/* end confdefs.h. */
24668
24669
24670#ifdef __cplusplus
24671extern "C"
24672#endif
24673char mesalink_library_init ();
24674int main (void)
24675{
24676return mesalink_library_init ();
24677 ;
24678 return 0;
24679}
24680_ACEOF
24681if ac_fn_c_try_link "$LINENO"; then :
24682 ac_cv_lib_mesalink_mesalink_library_init=yes
24683else
24684 ac_cv_lib_mesalink_mesalink_library_init=no
24685fi
24686rm -f core conftest.err conftest.$ac_objext \
24687 conftest$ac_exeext conftest.$ac_ext
24688LIBS=$ac_check_lib_save_LIBS
24689fi
24690{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mesalink_mesalink_library_init" >&5
24691$as_echo "$ac_cv_lib_mesalink_mesalink_library_init" >&6; }
24692if test "x$ac_cv_lib_mesalink_mesalink_library_init" = xyes; then :
24693
24694
24695$as_echo "#define USE_MESALINK 1" >>confdefs.h
24696
24697 USE_MESALINK=1
24698
24699 MESALINK_ENABLED=1
24700 USE_MESALINK="yes"
24701 ssl_msg="MesaLink"
24702 test mesalink != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
24703
24704fi
24705
24706 fi
24707
24708 addld=""
24709 addlib=""
24710 addcflags=""
24711 mesalinklib=""
24712
24713 if test "x$USE_MESALINK" != "xyes"; then
24714 addld=-L$OPT_MESALINK/lib$libsuff
24715 addcflags=-I$OPT_MESALINK/include
24716 mesalinklib=$OPT_MESALINK/lib$libsuff
24717
24718 LDFLAGS="$LDFLAGS $addld"
24719 if test "$addcflags" != "-I/usr/include"; then
24720 CPPFLAGS="$CPPFLAGS $addcflags"
24721 fi
24722
24723 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mesalink_library_init in -lmesalink" >&5
24724$as_echo_n "checking for mesalink_library_init in -lmesalink... " >&6; }
24725if ${ac_cv_lib_mesalink_mesalink_library_init+:} false; then :
24726 $as_echo_n "(cached) " >&6
24727else
24728 ac_check_lib_save_LIBS=$LIBS
24729LIBS="-lmesalink $LIBS"
24730cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24731/* end confdefs.h. */
24732
24733
24734#ifdef __cplusplus
24735extern "C"
24736#endif
24737char mesalink_library_init ();
24738int main (void)
24739{
24740return mesalink_library_init ();
24741 ;
24742 return 0;
24743}
24744_ACEOF
24745if ac_fn_c_try_link "$LINENO"; then :
24746 ac_cv_lib_mesalink_mesalink_library_init=yes
24747else
24748 ac_cv_lib_mesalink_mesalink_library_init=no
24749fi
24750rm -f core conftest.err conftest.$ac_objext \
24751 conftest$ac_exeext conftest.$ac_ext
24752LIBS=$ac_check_lib_save_LIBS
24753fi
24754{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mesalink_mesalink_library_init" >&5
24755$as_echo "$ac_cv_lib_mesalink_mesalink_library_init" >&6; }
24756if test "x$ac_cv_lib_mesalink_mesalink_library_init" = xyes; then :
24757
24758
24759$as_echo "#define USE_MESALINK 1" >>confdefs.h
24760
24761 USE_MESALINK=1
24762
24763 MESALINK_ENABLED=1
24764 USE_MESALINK="yes"
24765 ssl_msg="MesaLink"
24766 test mesalink != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
24767
24768else
24769
24770 CPPFLAGS=$_cppflags
24771 LDFLAGS=$_ldflags
24772
24773fi
24774
24775 fi
24776
24777 if test "x$USE_MESALINK" = "xyes"; then
24778 { $as_echo "$as_me:${as_lineno-$LINENO}: detected MesaLink" >&5
24779$as_echo "$as_me: detected MesaLink" >&6;}
24780
24781 LIBS="-lmesalink $LIBS"
24782
24783 if test -n "$mesalinklib"; then
24784 if test "x$cross_compiling" != "xyes"; then
24785 LD_LIBRARY_PATH="$LD_LIBRARY_PATH:$mesalinklib"
24786 export LD_LIBRARY_PATH
24787 { $as_echo "$as_me:${as_lineno-$LINENO}: Added $mesalinklib to LD_LIBRARY_PATH" >&5
24788$as_echo "$as_me: Added $mesalinklib to LD_LIBRARY_PATH" >&6;}
24789 fi
24790 fi
24791 fi
24792
24793 fi
24794 test -z "$ssl_msg" || ssl_backends="${ssl_backends:+$ssl_backends, }$ssl_msg"
24795fi
24796
24797
Elliott Hughes82be86d2017-09-20 17:00:17 -070024798OPT_NSS=no
24799
24800
24801# Check whether --with-nss was given.
24802if test "${with_nss+set}" = set; then :
24803 withval=$with_nss; OPT_NSS=$withval
24804fi
24805
24806
Alex Deymo486467e2017-12-19 19:04:07 +010024807if test -z "$ssl_backends" -o "x$OPT_NSS" != xno; then
24808 ssl_msg=
Elliott Hughes82be86d2017-09-20 17:00:17 -070024809
24810 if test X"$OPT_NSS" != Xno; then
24811
24812 addld=""
24813 addlib=""
24814 addcflags=""
24815 nssprefix=""
24816 version=""
24817
24818 if test "x$OPT_NSS" = "xyes"; then
24819
24820
24821 if test -n "$PKG_CONFIG"; then
24822 PKGCONFIG="$PKG_CONFIG"
24823 else
24824 if test -n "$ac_tool_prefix"; then
24825 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
24826set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
24827{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24828$as_echo_n "checking for $ac_word... " >&6; }
24829if ${ac_cv_path_PKGCONFIG+:} false; then :
24830 $as_echo_n "(cached) " >&6
24831else
24832 case $PKGCONFIG in
24833 [\\/]* | ?:[\\/]*)
24834 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
24835 ;;
24836 *)
24837 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24838as_dummy="$PATH:/usr/bin:/usr/local/bin"
24839for as_dir in $as_dummy
24840do
24841 IFS=$as_save_IFS
24842 test -z "$as_dir" && as_dir=.
24843 for ac_exec_ext in '' $ac_executable_extensions; do
24844 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
24845 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
24846 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
24847 break 2
24848 fi
24849done
24850 done
24851IFS=$as_save_IFS
24852
24853 ;;
24854esac
24855fi
24856PKGCONFIG=$ac_cv_path_PKGCONFIG
24857if test -n "$PKGCONFIG"; then
24858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
24859$as_echo "$PKGCONFIG" >&6; }
24860else
24861 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24862$as_echo "no" >&6; }
24863fi
24864
24865
24866fi
24867if test -z "$ac_cv_path_PKGCONFIG"; then
24868 ac_pt_PKGCONFIG=$PKGCONFIG
24869 # Extract the first word of "pkg-config", so it can be a program name with args.
24870set dummy pkg-config; ac_word=$2
24871{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24872$as_echo_n "checking for $ac_word... " >&6; }
24873if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
24874 $as_echo_n "(cached) " >&6
24875else
24876 case $ac_pt_PKGCONFIG in
24877 [\\/]* | ?:[\\/]*)
24878 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
24879 ;;
24880 *)
24881 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24882as_dummy="$PATH:/usr/bin:/usr/local/bin"
24883for as_dir in $as_dummy
24884do
24885 IFS=$as_save_IFS
24886 test -z "$as_dir" && as_dir=.
24887 for ac_exec_ext in '' $ac_executable_extensions; do
24888 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
24889 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
24890 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
24891 break 2
24892 fi
24893done
24894 done
24895IFS=$as_save_IFS
24896
24897 ;;
24898esac
24899fi
24900ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
24901if test -n "$ac_pt_PKGCONFIG"; then
24902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
24903$as_echo "$ac_pt_PKGCONFIG" >&6; }
24904else
24905 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24906$as_echo "no" >&6; }
24907fi
24908
24909 if test "x$ac_pt_PKGCONFIG" = x; then
24910 PKGCONFIG="no"
24911 else
24912 case $cross_compiling:$ac_tool_warned in
24913yes:)
24914{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
24915$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
24916ac_tool_warned=yes ;;
24917esac
24918 PKGCONFIG=$ac_pt_PKGCONFIG
24919 fi
24920else
24921 PKGCONFIG="$ac_cv_path_PKGCONFIG"
24922fi
24923
24924 fi
24925
24926 if test "x$PKGCONFIG" != "xno"; then
24927 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nss options with pkg-config" >&5
24928$as_echo_n "checking for nss options with pkg-config... " >&6; }
24929 itexists=`
24930 if test -n ""; then
24931 PKG_CONFIG_LIBDIR=""
24932 export PKG_CONFIG_LIBDIR
24933 fi
24934 $PKGCONFIG --exists nss >/dev/null 2>&1 && echo 1`
24935
24936 if test -z "$itexists"; then
24937 PKGCONFIG="no"
24938 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24939$as_echo "no" >&6; }
24940 else
24941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
24942$as_echo "found" >&6; }
24943 fi
24944 fi
24945
24946
24947 if test "$PKGCONFIG" != "no" ; then
24948 addlib=`$PKGCONFIG --libs nss`
24949 addcflags=`$PKGCONFIG --cflags nss`
24950 version=`$PKGCONFIG --modversion nss`
24951 nssprefix=`$PKGCONFIG --variable=prefix nss`
24952 else
24953
24954 check=`nss-config --version 2>/dev/null`
24955 if test -n "$check"; then
24956 addlib=`nss-config --libs`
24957 addcflags=`nss-config --cflags`
24958 version=`nss-config --version`
24959 nssprefix=`nss-config --prefix`
24960 else
24961 addlib="-lnss3"
24962 addcflags=""
24963 version="unknown"
24964 fi
24965 fi
24966 else
24967 NSS_PCDIR="$OPT_NSS/lib/pkgconfig"
24968 if test -f "$NSS_PCDIR/nss.pc"; then
24969
24970 if test -n "$PKG_CONFIG"; then
24971 PKGCONFIG="$PKG_CONFIG"
24972 else
24973 if test -n "$ac_tool_prefix"; then
24974 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
24975set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
24976{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24977$as_echo_n "checking for $ac_word... " >&6; }
24978if ${ac_cv_path_PKGCONFIG+:} false; then :
24979 $as_echo_n "(cached) " >&6
24980else
24981 case $PKGCONFIG in
24982 [\\/]* | ?:[\\/]*)
24983 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
24984 ;;
24985 *)
24986 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24987as_dummy="$PATH:/usr/bin:/usr/local/bin"
24988for as_dir in $as_dummy
24989do
24990 IFS=$as_save_IFS
24991 test -z "$as_dir" && as_dir=.
24992 for ac_exec_ext in '' $ac_executable_extensions; do
24993 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
24994 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
24995 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
24996 break 2
24997 fi
24998done
24999 done
25000IFS=$as_save_IFS
25001
25002 ;;
25003esac
25004fi
25005PKGCONFIG=$ac_cv_path_PKGCONFIG
25006if test -n "$PKGCONFIG"; then
25007 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
25008$as_echo "$PKGCONFIG" >&6; }
25009else
25010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25011$as_echo "no" >&6; }
25012fi
25013
25014
25015fi
25016if test -z "$ac_cv_path_PKGCONFIG"; then
25017 ac_pt_PKGCONFIG=$PKGCONFIG
25018 # Extract the first word of "pkg-config", so it can be a program name with args.
25019set dummy pkg-config; ac_word=$2
25020{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25021$as_echo_n "checking for $ac_word... " >&6; }
25022if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
25023 $as_echo_n "(cached) " >&6
25024else
25025 case $ac_pt_PKGCONFIG in
25026 [\\/]* | ?:[\\/]*)
25027 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
25028 ;;
25029 *)
25030 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25031as_dummy="$PATH:/usr/bin:/usr/local/bin"
25032for as_dir in $as_dummy
25033do
25034 IFS=$as_save_IFS
25035 test -z "$as_dir" && as_dir=.
25036 for ac_exec_ext in '' $ac_executable_extensions; do
25037 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25038 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
25039 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25040 break 2
25041 fi
25042done
25043 done
25044IFS=$as_save_IFS
25045
25046 ;;
25047esac
25048fi
25049ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
25050if test -n "$ac_pt_PKGCONFIG"; then
25051 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
25052$as_echo "$ac_pt_PKGCONFIG" >&6; }
25053else
25054 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25055$as_echo "no" >&6; }
25056fi
25057
25058 if test "x$ac_pt_PKGCONFIG" = x; then
25059 PKGCONFIG="no"
25060 else
25061 case $cross_compiling:$ac_tool_warned in
25062yes:)
25063{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
25064$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
25065ac_tool_warned=yes ;;
25066esac
25067 PKGCONFIG=$ac_pt_PKGCONFIG
25068 fi
25069else
25070 PKGCONFIG="$ac_cv_path_PKGCONFIG"
25071fi
25072
25073 fi
25074
25075 if test "x$PKGCONFIG" != "xno"; then
25076 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nss options with pkg-config" >&5
25077$as_echo_n "checking for nss options with pkg-config... " >&6; }
25078 itexists=`
25079 if test -n "$NSS_PCDIR"; then
25080 PKG_CONFIG_LIBDIR="$NSS_PCDIR"
25081 export PKG_CONFIG_LIBDIR
25082 fi
25083 $PKGCONFIG --exists nss >/dev/null 2>&1 && echo 1`
25084
25085 if test -z "$itexists"; then
25086 PKGCONFIG="no"
25087 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25088$as_echo "no" >&6; }
25089 else
25090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
25091$as_echo "found" >&6; }
25092 fi
25093 fi
25094
25095 if test "$PKGCONFIG" != "no" ; then
25096 addld=`
25097 if test -n "$NSS_PCDIR"; then
25098 PKG_CONFIG_LIBDIR="$NSS_PCDIR"
25099 export PKG_CONFIG_LIBDIR
25100 fi
25101 $PKGCONFIG --libs-only-L nss`
25102 addlib=`
25103 if test -n "$NSS_PCDIR"; then
25104 PKG_CONFIG_LIBDIR="$NSS_PCDIR"
25105 export PKG_CONFIG_LIBDIR
25106 fi
25107 $PKGCONFIG --libs-only-l nss`
25108 addcflags=`
25109 if test -n "$NSS_PCDIR"; then
25110 PKG_CONFIG_LIBDIR="$NSS_PCDIR"
25111 export PKG_CONFIG_LIBDIR
25112 fi
25113 $PKGCONFIG --cflags nss`
25114 version=`
25115 if test -n "$NSS_PCDIR"; then
25116 PKG_CONFIG_LIBDIR="$NSS_PCDIR"
25117 export PKG_CONFIG_LIBDIR
25118 fi
25119 $PKGCONFIG --modversion nss`
25120 nssprefix=`
25121 if test -n "$NSS_PCDIR"; then
25122 PKG_CONFIG_LIBDIR="$NSS_PCDIR"
25123 export PKG_CONFIG_LIBDIR
25124 fi
25125 $PKGCONFIG --variable=prefix nss`
25126 fi
25127 fi
25128 fi
25129
25130 if test -z "$addlib"; then
25131 # Without pkg-config, we'll kludge in some defaults
25132 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Using hard-wired libraries and compilation flags for NSS." >&5
25133$as_echo "$as_me: WARNING: Using hard-wired libraries and compilation flags for NSS." >&2;}
25134 addld="-L$OPT_NSS/lib"
25135 addlib="-lssl3 -lsmime3 -lnss3 -lplds4 -lplc4 -lnspr4"
25136 addcflags="-I$OPT_NSS/include"
25137 version="unknown"
25138 nssprefix=$OPT_NSS
25139 fi
25140
25141 CLEANLDFLAGS="$LDFLAGS"
25142 CLEANLIBS="$LIBS"
25143 CLEANCPPFLAGS="$CPPFLAGS"
25144
25145 LDFLAGS="$addld $LDFLAGS"
25146 LIBS="$addlib $LIBS"
25147 if test "$addcflags" != "-I/usr/include"; then
25148 CPPFLAGS="$CPPFLAGS $addcflags"
25149 fi
25150
25151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SSL_VersionRangeSet in -lnss3" >&5
25152$as_echo_n "checking for SSL_VersionRangeSet in -lnss3... " >&6; }
25153if ${ac_cv_lib_nss3_SSL_VersionRangeSet+:} false; then :
25154 $as_echo_n "(cached) " >&6
25155else
25156 ac_check_lib_save_LIBS=$LIBS
25157LIBS="-lnss3 $LIBS"
25158cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25159/* end confdefs.h. */
25160
25161
25162#ifdef __cplusplus
25163extern "C"
25164#endif
25165char SSL_VersionRangeSet ();
25166int main (void)
25167{
25168return SSL_VersionRangeSet ();
25169 ;
25170 return 0;
25171}
25172_ACEOF
25173if ac_fn_c_try_link "$LINENO"; then :
25174 ac_cv_lib_nss3_SSL_VersionRangeSet=yes
25175else
25176 ac_cv_lib_nss3_SSL_VersionRangeSet=no
25177fi
25178rm -f core conftest.err conftest.$ac_objext \
25179 conftest$ac_exeext conftest.$ac_ext
25180LIBS=$ac_check_lib_save_LIBS
25181fi
25182{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nss3_SSL_VersionRangeSet" >&5
25183$as_echo "$ac_cv_lib_nss3_SSL_VersionRangeSet" >&6; }
25184if test "x$ac_cv_lib_nss3_SSL_VersionRangeSet" = xyes; then :
25185
25186
25187$as_echo "#define USE_NSS 1" >>confdefs.h
25188
25189 USE_NSS=1
25190
25191 USE_NSS="yes"
25192 NSS_ENABLED=1
Alex Deymo486467e2017-12-19 19:04:07 +010025193 ssl_msg="NSS"
25194 test nss != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
Elliott Hughes82be86d2017-09-20 17:00:17 -070025195
25196else
25197
25198 LDFLAGS="$CLEANLDFLAGS"
25199 LIBS="$CLEANLIBS"
25200 CPPFLAGS="$CLEANCPPFLAGS"
25201
25202fi
25203
25204
25205 if test "x$USE_NSS" = "xyes"; then
25206 { $as_echo "$as_me:${as_lineno-$LINENO}: detected NSS version $version" >&5
25207$as_echo "$as_me: detected NSS version $version" >&6;}
25208
Elliott Hughescac39802018-04-27 16:19:43 -070025209 ac_fn_c_check_func "$LINENO" "PK11_CreateManagedGenericObject" "ac_cv_func_PK11_CreateManagedGenericObject"
25210if test "x$ac_cv_func_PK11_CreateManagedGenericObject" = xyes; then :
25211
25212
25213$as_echo "#define HAVE_PK11_CREATEMANAGEDGENERICOBJECT 1" >>confdefs.h
25214
25215
25216fi
25217
25218
Elliott Hughes82be86d2017-09-20 17:00:17 -070025219 NSS_LIBS=$addlib
25220
25221
25222 if test "x$cross_compiling" != "xyes"; then
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070025223 CURL_LIBRARY_PATH="$CURL_LIBRARY_PATH:$nssprefix/lib$libsuff"
25224 export CURL_LIBRARY_PATH
25225 { $as_echo "$as_me:${as_lineno-$LINENO}: Added $nssprefix/lib$libsuff to CURL_LIBRARY_PATH" >&5
25226$as_echo "$as_me: Added $nssprefix/lib$libsuff to CURL_LIBRARY_PATH" >&6;}
Elliott Hughes82be86d2017-09-20 17:00:17 -070025227 fi
25228
25229 fi
25230 fi
Alex Deymo486467e2017-12-19 19:04:07 +010025231 test -z "$ssl_msg" || ssl_backends="${ssl_backends:+$ssl_backends, }$ssl_msg"
Elliott Hughes82be86d2017-09-20 17:00:17 -070025232fi
Alex Deymo486467e2017-12-19 19:04:07 +010025233
Haibo Huang001784b2019-07-19 05:27:28 -070025234case "x$OPENSSL_ENABLED$GNUTLS_ENABLED$NSS_ENABLED$MBEDTLS_ENABLED$WOLFSSL_ENABLED$WINSSL_ENABLED$SECURETRANSPORT_ENABLED$MESALINK_ENABLED$AMISSL_ENABLED" in
Alex Deymo486467e2017-12-19 19:04:07 +010025235x)
Elliott Hughes82be86d2017-09-20 17:00:17 -070025236 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: SSL disabled, you will not be able to use HTTPS, FTPS, NTLM and more." >&5
25237$as_echo "$as_me: WARNING: SSL disabled, you will not be able to use HTTPS, FTPS, NTLM and more." >&2;}
Haibo Huang001784b2019-07-19 05:27:28 -070025238 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Use --with-ssl, --with-gnutls, --with-wolfssl, --with-mbedtls, --with-nss, --with-schannel, --with-secure-transport, --with-mesalink or --with-amissl to address this." >&5
25239$as_echo "$as_me: WARNING: Use --with-ssl, --with-gnutls, --with-wolfssl, --with-mbedtls, --with-nss, --with-schannel, --with-secure-transport, --with-mesalink or --with-amissl to address this." >&2;}
Alex Deymo486467e2017-12-19 19:04:07 +010025240 ;;
25241x1)
25242 # one SSL backend is enabled
Elliott Hughes82be86d2017-09-20 17:00:17 -070025243
25244 SSL_ENABLED="1"
Alex Deymo486467e2017-12-19 19:04:07 +010025245 { $as_echo "$as_me:${as_lineno-$LINENO}: built with one SSL backend" >&5
25246$as_echo "$as_me: built with one SSL backend" >&6;}
25247 ;;
25248*)
25249 # more than one SSL backend is enabled
25250
25251 SSL_ENABLED="1"
25252
25253 CURL_WITH_MULTI_SSL="1"
25254
25255$as_echo "#define CURL_WITH_MULTI_SSL 1" >>confdefs.h
25256
25257 { $as_echo "$as_me:${as_lineno-$LINENO}: built with multiple SSL backends" >&5
25258$as_echo "$as_me: built with multiple SSL backends" >&6;}
25259 ;;
25260esac
25261
25262if test -n "$ssl_backends"; then
25263 curl_ssl_msg="enabled ($ssl_backends)"
25264fi
25265
25266if test no = "$VALID_DEFAULT_SSL_BACKEND"
25267then
25268 if test -n "$SSL_ENABLED"
25269 then
25270 as_fn_error $? "Default SSL backend $DEFAULT_SSL_BACKEND not enabled!" "$LINENO" 5
25271 else
25272 as_fn_error $? "Default SSL backend requires SSL!" "$LINENO" 5
25273 fi
25274elif test yes = "$VALID_DEFAULT_SSL_BACKEND"
25275then
25276
25277cat >>confdefs.h <<_ACEOF
25278#define CURL_DEFAULT_SSL_BACKEND "$DEFAULT_SSL_BACKEND"
25279_ACEOF
25280
Elliott Hughes82be86d2017-09-20 17:00:17 -070025281fi
25282
25283
Haibo Huang445085a2019-09-11 13:33:50 -070025284if test -n "$check_for_ca_bundle"; then
Elliott Hughes82be86d2017-09-20 17:00:17 -070025285
25286
25287 { $as_echo "$as_me:${as_lineno-$LINENO}: checking default CA cert bundle/path" >&5
25288$as_echo_n "checking default CA cert bundle/path... " >&6; }
25289
25290
25291# Check whether --with-ca-bundle was given.
25292if test "${with_ca_bundle+set}" = set; then :
25293 withval=$with_ca_bundle;
25294 want_ca="$withval"
25295 if test "x$want_ca" = "xyes"; then
25296 as_fn_error $? "--with-ca-bundle=FILE requires a path to the CA bundle" "$LINENO" 5
25297 fi
25298
25299else
25300 want_ca="unset"
25301fi
25302
25303
25304# Check whether --with-ca-path was given.
25305if test "${with_ca_path+set}" = set; then :
25306 withval=$with_ca_path;
25307 want_capath="$withval"
25308 if test "x$want_capath" = "xyes"; then
25309 as_fn_error $? "--with-ca-path=DIRECTORY requires a path to the CA path directory" "$LINENO" 5
25310 fi
25311
25312else
25313 want_capath="unset"
25314fi
25315
25316
25317 ca_warning=" (warning: certs not found)"
25318 capath_warning=" (warning: certs not found)"
25319 check_capath=""
25320
25321 if test "x$want_ca" != "xno" -a "x$want_ca" != "xunset" -a \
25322 "x$want_capath" != "xno" -a "x$want_capath" != "xunset"; then
25323 ca="$want_ca"
25324 capath="$want_capath"
25325 elif test "x$want_ca" != "xno" -a "x$want_ca" != "xunset"; then
25326 ca="$want_ca"
25327 capath="no"
25328 elif test "x$want_capath" != "xno" -a "x$want_capath" != "xunset"; then
25329 if test "x$OPENSSL_ENABLED" != "x1" -a "x$GNUTLS_ENABLED" != "x1" -a "x$POLARSSL_ENABLED" != "x1"; then
25330 as_fn_error $? "--with-ca-path only works with OpenSSL, GnuTLS or PolarSSL" "$LINENO" 5
25331 fi
25332 capath="$want_capath"
25333 ca="no"
25334 else
25335 ca="no"
25336 capath="no"
25337 if test "x$cross_compiling" != "xyes"; then
25338 if test "x$want_ca" = "xunset"; then
25339 if test "x$prefix" != xNONE; then
25340 cac="${prefix}/share/curl/curl-ca-bundle.crt"
25341 else
25342 cac="$ac_default_prefix/share/curl/curl-ca-bundle.crt"
25343 fi
25344
25345 for a in /etc/ssl/certs/ca-certificates.crt \
25346 /etc/pki/tls/certs/ca-bundle.crt \
25347 /usr/share/ssl/certs/ca-bundle.crt \
25348 /usr/local/share/certs/ca-root-nss.crt \
25349 /etc/ssl/cert.pem \
25350 "$cac"; do
25351 if test -f "$a"; then
25352 ca="$a"
25353 break
25354 fi
25355 done
25356 fi
25357 if test "x$want_capath" = "xunset" -a "x$ca" = "xno" -a \
25358 "x$OPENSSL_ENABLED" = "x1"; then
25359 check_capath="/etc/ssl/certs/"
25360 fi
25361 else
25362 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: skipped the ca-cert path detection when cross-compiling" >&5
25363$as_echo "$as_me: WARNING: skipped the ca-cert path detection when cross-compiling" >&2;}
25364 fi
25365 fi
25366
25367 if test "x$ca" = "xno" || test -f "$ca"; then
25368 ca_warning=""
25369 fi
25370
25371 if test "x$capath" != "xno"; then
25372 check_capath="$capath"
25373 fi
25374
25375 if test ! -z "$check_capath"; then
25376 for a in "$check_capath"; do
25377 if test -d "$a" && ls "$a"/[0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f][0-9a-f].0 >/dev/null 2>/dev/null; then
25378 if test "x$capath" = "xno"; then
25379 capath="$a"
25380 fi
25381 capath_warning=""
25382 break
25383 fi
25384 done
25385 fi
25386
25387 if test "x$capath" = "xno"; then
25388 capath_warning=""
25389 fi
25390
25391 if test "x$ca" != "xno"; then
25392 CURL_CA_BUNDLE='"'$ca'"'
25393
25394cat >>confdefs.h <<_ACEOF
25395#define CURL_CA_BUNDLE "$ca"
25396_ACEOF
25397
25398
25399 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ca" >&5
25400$as_echo "$ca" >&6; }
25401 fi
25402 if test "x$capath" != "xno"; then
25403 CURL_CA_PATH="\"$capath\""
25404
25405cat >>confdefs.h <<_ACEOF
25406#define CURL_CA_PATH "$capath"
25407_ACEOF
25408
25409 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $capath (capath)" >&5
25410$as_echo "$capath (capath)" >&6; }
25411 fi
25412 if test "x$ca" = "xno" && test "x$capath" = "xno"; then
25413 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25414$as_echo "no" >&6; }
25415 fi
25416
25417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use builtin CA store of SSL library" >&5
25418$as_echo_n "checking whether to use builtin CA store of SSL library... " >&6; }
25419
25420# Check whether --with-ca-fallback was given.
25421if test "${with_ca_fallback+set}" = set; then :
25422 withval=$with_ca_fallback;
25423 if test "x$with_ca_fallback" != "xyes" -a "x$with_ca_fallback" != "xno"; then
25424 as_fn_error $? "--with-ca-fallback only allows yes or no as parameter" "$LINENO" 5
25425 fi
25426
25427else
25428 with_ca_fallback="no"
25429fi
25430
25431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_ca_fallback" >&5
25432$as_echo "$with_ca_fallback" >&6; }
25433 if test "x$with_ca_fallback" = "xyes"; then
25434 if test "x$OPENSSL_ENABLED" != "x1" -a "x$GNUTLS_ENABLED" != "x1"; then
25435 as_fn_error $? "--with-ca-fallback only works with OpenSSL or GnuTLS" "$LINENO" 5
25436 fi
25437
25438cat >>confdefs.h <<_ACEOF
25439#define CURL_CA_FALLBACK 1
25440_ACEOF
25441
25442 fi
25443
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070025444fi
Elliott Hughes82be86d2017-09-20 17:00:17 -070025445
25446
25447
25448# Check whether --with-libpsl was given.
25449if test "${with_libpsl+set}" = set; then :
25450 withval=$with_libpsl; with_libpsl=$withval
25451else
25452 with_libpsl=yes
25453fi
25454
25455if test $with_libpsl != "no"; then
25456 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing psl_builtin" >&5
25457$as_echo_n "checking for library containing psl_builtin... " >&6; }
25458if ${ac_cv_search_psl_builtin+:} false; then :
25459 $as_echo_n "(cached) " >&6
25460else
25461 ac_func_search_save_LIBS=$LIBS
25462cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25463/* end confdefs.h. */
25464
25465
25466#ifdef __cplusplus
25467extern "C"
25468#endif
25469char psl_builtin ();
25470int main (void)
25471{
25472return psl_builtin ();
25473 ;
25474 return 0;
25475}
25476_ACEOF
25477for ac_lib in '' psl; do
25478 if test -z "$ac_lib"; then
25479 ac_res="none required"
25480 else
25481 ac_res=-l$ac_lib
25482 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
25483 fi
25484 if ac_fn_c_try_link "$LINENO"; then :
25485 ac_cv_search_psl_builtin=$ac_res
25486fi
25487rm -f core conftest.err conftest.$ac_objext \
25488 conftest$ac_exeext
25489 if ${ac_cv_search_psl_builtin+:} false; then :
25490 break
25491fi
25492done
25493if ${ac_cv_search_psl_builtin+:} false; then :
25494
25495else
25496 ac_cv_search_psl_builtin=no
25497fi
25498rm conftest.$ac_ext
25499LIBS=$ac_func_search_save_LIBS
25500fi
25501{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_psl_builtin" >&5
25502$as_echo "$ac_cv_search_psl_builtin" >&6; }
25503ac_res=$ac_cv_search_psl_builtin
25504if test "$ac_res" != no; then :
25505 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
Haibo Huang65021c72019-03-27 15:37:23 -070025506 curl_psl_msg="enabled";
Elliott Hughes82be86d2017-09-20 17:00:17 -070025507
25508$as_echo "#define USE_LIBPSL 1" >>confdefs.h
25509
25510
25511else
25512 curl_psl_msg="no (libpsl not found)";
25513 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libpsl was not found" >&5
25514$as_echo "$as_me: WARNING: libpsl was not found" >&2;}
25515
25516
25517fi
25518
25519fi
Haibo Huang65021c72019-03-27 15:37:23 -070025520 if test "$curl_psl_msg" = "enabled"; then
Elliott Hughes82be86d2017-09-20 17:00:17 -070025521 USE_LIBPSL_TRUE=
25522 USE_LIBPSL_FALSE='#'
25523else
25524 USE_LIBPSL_TRUE='#'
25525 USE_LIBPSL_FALSE=
25526fi
25527
25528
25529
25530OPT_LIBMETALINK=no
25531
25532
25533# Check whether --with-libmetalink was given.
25534if test "${with_libmetalink+set}" = set; then :
25535 withval=$with_libmetalink; OPT_LIBMETALINK=$withval
25536fi
25537
25538
25539if test X"$OPT_LIBMETALINK" != Xno; then
25540
25541 addld=""
25542 addlib=""
25543 addcflags=""
25544 version=""
25545 libmetalinklib=""
25546
25547 PKGTEST="no"
25548 if test "x$OPT_LIBMETALINK" = "xyes"; then
25549 PKGTEST="yes"
25550
25551 if test -n "$PKG_CONFIG"; then
25552 PKGCONFIG="$PKG_CONFIG"
25553 else
25554 if test -n "$ac_tool_prefix"; then
25555 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
25556set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
25557{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25558$as_echo_n "checking for $ac_word... " >&6; }
25559if ${ac_cv_path_PKGCONFIG+:} false; then :
25560 $as_echo_n "(cached) " >&6
25561else
25562 case $PKGCONFIG in
25563 [\\/]* | ?:[\\/]*)
25564 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
25565 ;;
25566 *)
25567 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25568as_dummy="$PATH:/usr/bin:/usr/local/bin"
25569for as_dir in $as_dummy
25570do
25571 IFS=$as_save_IFS
25572 test -z "$as_dir" && as_dir=.
25573 for ac_exec_ext in '' $ac_executable_extensions; do
25574 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25575 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
25576 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25577 break 2
25578 fi
25579done
25580 done
25581IFS=$as_save_IFS
25582
25583 ;;
25584esac
25585fi
25586PKGCONFIG=$ac_cv_path_PKGCONFIG
25587if test -n "$PKGCONFIG"; then
25588 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
25589$as_echo "$PKGCONFIG" >&6; }
25590else
25591 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25592$as_echo "no" >&6; }
25593fi
25594
25595
25596fi
25597if test -z "$ac_cv_path_PKGCONFIG"; then
25598 ac_pt_PKGCONFIG=$PKGCONFIG
25599 # Extract the first word of "pkg-config", so it can be a program name with args.
25600set dummy pkg-config; ac_word=$2
25601{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25602$as_echo_n "checking for $ac_word... " >&6; }
25603if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
25604 $as_echo_n "(cached) " >&6
25605else
25606 case $ac_pt_PKGCONFIG in
25607 [\\/]* | ?:[\\/]*)
25608 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
25609 ;;
25610 *)
25611 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25612as_dummy="$PATH:/usr/bin:/usr/local/bin"
25613for as_dir in $as_dummy
25614do
25615 IFS=$as_save_IFS
25616 test -z "$as_dir" && as_dir=.
25617 for ac_exec_ext in '' $ac_executable_extensions; do
25618 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25619 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
25620 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25621 break 2
25622 fi
25623done
25624 done
25625IFS=$as_save_IFS
25626
25627 ;;
25628esac
25629fi
25630ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
25631if test -n "$ac_pt_PKGCONFIG"; then
25632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
25633$as_echo "$ac_pt_PKGCONFIG" >&6; }
25634else
25635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25636$as_echo "no" >&6; }
25637fi
25638
25639 if test "x$ac_pt_PKGCONFIG" = x; then
25640 PKGCONFIG="no"
25641 else
25642 case $cross_compiling:$ac_tool_warned in
25643yes:)
25644{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
25645$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
25646ac_tool_warned=yes ;;
25647esac
25648 PKGCONFIG=$ac_pt_PKGCONFIG
25649 fi
25650else
25651 PKGCONFIG="$ac_cv_path_PKGCONFIG"
25652fi
25653
25654 fi
25655
25656 if test "x$PKGCONFIG" != "xno"; then
25657 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libmetalink options with pkg-config" >&5
25658$as_echo_n "checking for libmetalink options with pkg-config... " >&6; }
25659 itexists=`
25660 if test -n ""; then
25661 PKG_CONFIG_LIBDIR=""
25662 export PKG_CONFIG_LIBDIR
25663 fi
25664 $PKGCONFIG --exists libmetalink >/dev/null 2>&1 && echo 1`
25665
25666 if test -z "$itexists"; then
25667 PKGCONFIG="no"
25668 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25669$as_echo "no" >&6; }
25670 else
25671 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
25672$as_echo "found" >&6; }
25673 fi
25674 fi
25675
25676 else
25677 LIBMETALINK_PCDIR="$OPT_LIBMETALINK/lib/pkgconfig"
25678 { $as_echo "$as_me:${as_lineno-$LINENO}: PKG_CONFIG_LIBDIR will be set to \"$LIBMETALINK_PCDIR\"" >&5
25679$as_echo "$as_me: PKG_CONFIG_LIBDIR will be set to \"$LIBMETALINK_PCDIR\"" >&6;}
25680 if test -f "$LIBMETALINK_PCDIR/libmetalink.pc"; then
25681 PKGTEST="yes"
25682 fi
25683 if test "$PKGTEST" = "yes"; then
25684
25685 if test -n "$PKG_CONFIG"; then
25686 PKGCONFIG="$PKG_CONFIG"
25687 else
25688 if test -n "$ac_tool_prefix"; then
25689 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
25690set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
25691{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25692$as_echo_n "checking for $ac_word... " >&6; }
25693if ${ac_cv_path_PKGCONFIG+:} false; then :
25694 $as_echo_n "(cached) " >&6
25695else
25696 case $PKGCONFIG in
25697 [\\/]* | ?:[\\/]*)
25698 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
25699 ;;
25700 *)
25701 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25702as_dummy="$PATH:/usr/bin:/usr/local/bin"
25703for as_dir in $as_dummy
25704do
25705 IFS=$as_save_IFS
25706 test -z "$as_dir" && as_dir=.
25707 for ac_exec_ext in '' $ac_executable_extensions; do
25708 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25709 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
25710 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25711 break 2
25712 fi
25713done
25714 done
25715IFS=$as_save_IFS
25716
25717 ;;
25718esac
25719fi
25720PKGCONFIG=$ac_cv_path_PKGCONFIG
25721if test -n "$PKGCONFIG"; then
25722 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
25723$as_echo "$PKGCONFIG" >&6; }
25724else
25725 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25726$as_echo "no" >&6; }
25727fi
25728
25729
25730fi
25731if test -z "$ac_cv_path_PKGCONFIG"; then
25732 ac_pt_PKGCONFIG=$PKGCONFIG
25733 # Extract the first word of "pkg-config", so it can be a program name with args.
25734set dummy pkg-config; ac_word=$2
25735{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25736$as_echo_n "checking for $ac_word... " >&6; }
25737if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
25738 $as_echo_n "(cached) " >&6
25739else
25740 case $ac_pt_PKGCONFIG in
25741 [\\/]* | ?:[\\/]*)
25742 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
25743 ;;
25744 *)
25745 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25746as_dummy="$PATH:/usr/bin:/usr/local/bin"
25747for as_dir in $as_dummy
25748do
25749 IFS=$as_save_IFS
25750 test -z "$as_dir" && as_dir=.
25751 for ac_exec_ext in '' $ac_executable_extensions; do
25752 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25753 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
25754 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25755 break 2
25756 fi
25757done
25758 done
25759IFS=$as_save_IFS
25760
25761 ;;
25762esac
25763fi
25764ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
25765if test -n "$ac_pt_PKGCONFIG"; then
25766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
25767$as_echo "$ac_pt_PKGCONFIG" >&6; }
25768else
25769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25770$as_echo "no" >&6; }
25771fi
25772
25773 if test "x$ac_pt_PKGCONFIG" = x; then
25774 PKGCONFIG="no"
25775 else
25776 case $cross_compiling:$ac_tool_warned in
25777yes:)
25778{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
25779$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
25780ac_tool_warned=yes ;;
25781esac
25782 PKGCONFIG=$ac_pt_PKGCONFIG
25783 fi
25784else
25785 PKGCONFIG="$ac_cv_path_PKGCONFIG"
25786fi
25787
25788 fi
25789
25790 if test "x$PKGCONFIG" != "xno"; then
25791 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libmetalink options with pkg-config" >&5
25792$as_echo_n "checking for libmetalink options with pkg-config... " >&6; }
25793 itexists=`
25794 if test -n "$LIBMETALINK_PCDIR"; then
25795 PKG_CONFIG_LIBDIR="$LIBMETALINK_PCDIR"
25796 export PKG_CONFIG_LIBDIR
25797 fi
25798 $PKGCONFIG --exists libmetalink >/dev/null 2>&1 && echo 1`
25799
25800 if test -z "$itexists"; then
25801 PKGCONFIG="no"
25802 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25803$as_echo "no" >&6; }
25804 else
25805 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
25806$as_echo "found" >&6; }
25807 fi
25808 fi
25809
25810 fi
25811 fi
25812 if test "$PKGTEST" = "yes" && test "$PKGCONFIG" != "no"; then
25813 addlib=`
25814 if test -n "$LIBMETALINK_PCDIR"; then
25815 PKG_CONFIG_LIBDIR="$LIBMETALINK_PCDIR"
25816 export PKG_CONFIG_LIBDIR
25817 fi
25818 $PKGCONFIG --libs-only-l libmetalink`
25819 addld=`
25820 if test -n "$LIBMETALINK_PCDIR"; then
25821 PKG_CONFIG_LIBDIR="$LIBMETALINK_PCDIR"
25822 export PKG_CONFIG_LIBDIR
25823 fi
25824 $PKGCONFIG --libs-only-L libmetalink`
25825 addcflags=`
25826 if test -n "$LIBMETALINK_PCDIR"; then
25827 PKG_CONFIG_LIBDIR="$LIBMETALINK_PCDIR"
25828 export PKG_CONFIG_LIBDIR
25829 fi
25830 $PKGCONFIG --cflags-only-I libmetalink`
25831 version=`
25832 if test -n "$LIBMETALINK_PCDIR"; then
25833 PKG_CONFIG_LIBDIR="$LIBMETALINK_PCDIR"
25834 export PKG_CONFIG_LIBDIR
25835 fi
25836 $PKGCONFIG --modversion libmetalink`
25837 libmetalinklib=`echo $addld | $SED -e 's/-L//'`
25838 fi
25839 if test -n "$addlib"; then
25840
25841 clean_CPPFLAGS="$CPPFLAGS"
25842 clean_LDFLAGS="$LDFLAGS"
25843 clean_LIBS="$LIBS"
25844 CPPFLAGS="$clean_CPPFLAGS $addcflags"
25845 LDFLAGS="$clean_LDFLAGS $addld"
25846 LIBS="$addlib $clean_LIBS"
25847 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libmetalink is recent enough" >&5
25848$as_echo_n "checking if libmetalink is recent enough... " >&6; }
25849 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25850/* end confdefs.h. */
25851
25852
25853# include <metalink/metalink.h>
25854
25855int main (void)
25856{
25857
25858 if(0 != metalink_strerror(0)) /* added in 0.1.0 */
25859 return 1;
25860
25861 ;
25862 return 0;
25863}
25864
25865_ACEOF
25866if ac_fn_c_try_link "$LINENO"; then :
25867
25868 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes ($version)" >&5
25869$as_echo "yes ($version)" >&6; }
25870 want_metalink="yes"
25871
25872else
25873
25874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no ($version)" >&5
25875$as_echo "no ($version)" >&6; }
25876 { $as_echo "$as_me:${as_lineno-$LINENO}: libmetalink library defective or too old" >&5
25877$as_echo "$as_me: libmetalink library defective or too old" >&6;}
25878 want_metalink="no"
25879
25880fi
25881rm -f core conftest.err conftest.$ac_objext \
25882 conftest$ac_exeext conftest.$ac_ext
25883 CPPFLAGS="$clean_CPPFLAGS"
25884 LDFLAGS="$clean_LDFLAGS"
25885 LIBS="$clean_LIBS"
25886 if test "$want_metalink" = "yes"; then
25887
25888$as_echo "#define USE_METALINK 1" >>confdefs.h
25889
25890 LIBMETALINK_LIBS=$addlib
25891 LIBMETALINK_LDFLAGS=$addld
25892 LIBMETALINK_CPPFLAGS=$addcflags
25893
25894
25895
25896 curl_mtlnk_msg="enabled"
25897 fi
25898
25899 fi
25900fi
25901
25902
25903OPT_LIBSSH2=off
25904
25905# Check whether --with-libssh2 was given.
25906if test "${with_libssh2+set}" = set; then :
25907 withval=$with_libssh2; OPT_LIBSSH2=$withval
Elliott Hughes0128fe42018-02-27 14:57:55 -080025908else
25909 OPT_LIBSSH2=no
25910fi
25911
25912
25913
25914OPT_LIBSSH=off
25915
25916# Check whether --with-libssh was given.
25917if test "${with_libssh+set}" = set; then :
25918 withval=$with_libssh; OPT_LIBSSH=$withval
25919else
25920 OPT_LIBSSH=no
Elliott Hughes82be86d2017-09-20 17:00:17 -070025921fi
25922
25923
25924if test X"$OPT_LIBSSH2" != Xno; then
25925 CLEANLDFLAGS="$LDFLAGS"
25926 CLEANCPPFLAGS="$CPPFLAGS"
25927 CLEANLIBS="$LIBS"
25928
25929 case "$OPT_LIBSSH2" in
25930 yes)
25931
25932 if test -n "$PKG_CONFIG"; then
25933 PKGCONFIG="$PKG_CONFIG"
25934 else
25935 if test -n "$ac_tool_prefix"; then
25936 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
25937set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
25938{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25939$as_echo_n "checking for $ac_word... " >&6; }
25940if ${ac_cv_path_PKGCONFIG+:} false; then :
25941 $as_echo_n "(cached) " >&6
25942else
25943 case $PKGCONFIG in
25944 [\\/]* | ?:[\\/]*)
25945 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
25946 ;;
25947 *)
25948 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25949as_dummy="$PATH:/usr/bin:/usr/local/bin"
25950for as_dir in $as_dummy
25951do
25952 IFS=$as_save_IFS
25953 test -z "$as_dir" && as_dir=.
25954 for ac_exec_ext in '' $ac_executable_extensions; do
25955 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25956 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
25957 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25958 break 2
25959 fi
25960done
25961 done
25962IFS=$as_save_IFS
25963
25964 ;;
25965esac
25966fi
25967PKGCONFIG=$ac_cv_path_PKGCONFIG
25968if test -n "$PKGCONFIG"; then
25969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
25970$as_echo "$PKGCONFIG" >&6; }
25971else
25972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25973$as_echo "no" >&6; }
25974fi
25975
25976
25977fi
25978if test -z "$ac_cv_path_PKGCONFIG"; then
25979 ac_pt_PKGCONFIG=$PKGCONFIG
25980 # Extract the first word of "pkg-config", so it can be a program name with args.
25981set dummy pkg-config; ac_word=$2
25982{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25983$as_echo_n "checking for $ac_word... " >&6; }
25984if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
25985 $as_echo_n "(cached) " >&6
25986else
25987 case $ac_pt_PKGCONFIG in
25988 [\\/]* | ?:[\\/]*)
25989 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
25990 ;;
25991 *)
25992 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25993as_dummy="$PATH:/usr/bin:/usr/local/bin"
25994for as_dir in $as_dummy
25995do
25996 IFS=$as_save_IFS
25997 test -z "$as_dir" && as_dir=.
25998 for ac_exec_ext in '' $ac_executable_extensions; do
25999 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
26000 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
26001 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
26002 break 2
26003 fi
26004done
26005 done
26006IFS=$as_save_IFS
26007
26008 ;;
26009esac
26010fi
26011ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
26012if test -n "$ac_pt_PKGCONFIG"; then
26013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
26014$as_echo "$ac_pt_PKGCONFIG" >&6; }
26015else
26016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26017$as_echo "no" >&6; }
26018fi
26019
26020 if test "x$ac_pt_PKGCONFIG" = x; then
26021 PKGCONFIG="no"
26022 else
26023 case $cross_compiling:$ac_tool_warned in
26024yes:)
26025{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
26026$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
26027ac_tool_warned=yes ;;
26028esac
26029 PKGCONFIG=$ac_pt_PKGCONFIG
26030 fi
26031else
26032 PKGCONFIG="$ac_cv_path_PKGCONFIG"
26033fi
26034
26035 fi
26036
26037 if test "x$PKGCONFIG" != "xno"; then
26038 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libssh2 options with pkg-config" >&5
26039$as_echo_n "checking for libssh2 options with pkg-config... " >&6; }
26040 itexists=`
26041 if test -n ""; then
26042 PKG_CONFIG_LIBDIR=""
26043 export PKG_CONFIG_LIBDIR
26044 fi
26045 $PKGCONFIG --exists libssh2 >/dev/null 2>&1 && echo 1`
26046
26047 if test -z "$itexists"; then
26048 PKGCONFIG="no"
26049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26050$as_echo "no" >&6; }
26051 else
26052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
26053$as_echo "found" >&6; }
26054 fi
26055 fi
26056
26057
26058 if test "$PKGCONFIG" != "no" ; then
Elliott Hughes72d948d2018-08-03 14:37:21 -070026059 LIB_SSH2=`$PKGCONFIG --libs libssh2`
Elliott Hughes82be86d2017-09-20 17:00:17 -070026060 LD_SSH2=`$PKGCONFIG --libs-only-L libssh2`
26061 CPP_SSH2=`$PKGCONFIG --cflags-only-I libssh2`
26062 version=`$PKGCONFIG --modversion libssh2`
26063 DIR_SSH2=`echo $LD_SSH2 | $SED -e 's/-L//'`
26064 fi
26065
26066 ;;
26067 off)
26068 ;;
26069 *)
26070 PREFIX_SSH2=$OPT_LIBSSH2
26071 ;;
26072 esac
26073
26074 if test -n "$PREFIX_SSH2"; then
26075 LIB_SSH2="-lssh2"
26076 LD_SSH2=-L${PREFIX_SSH2}/lib$libsuff
26077 CPP_SSH2=-I${PREFIX_SSH2}/include
26078 DIR_SSH2=${PREFIX_SSH2}/lib$libsuff
26079 fi
26080
26081 LDFLAGS="$LDFLAGS $LD_SSH2"
26082 CPPFLAGS="$CPPFLAGS $CPP_SSH2"
26083 LIBS="$LIB_SSH2 $LIBS"
26084
26085 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libssh2_channel_open_ex in -lssh2" >&5
26086$as_echo_n "checking for libssh2_channel_open_ex in -lssh2... " >&6; }
26087if ${ac_cv_lib_ssh2_libssh2_channel_open_ex+:} false; then :
26088 $as_echo_n "(cached) " >&6
26089else
26090 ac_check_lib_save_LIBS=$LIBS
26091LIBS="-lssh2 $LIBS"
26092cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26093/* end confdefs.h. */
26094
26095
26096#ifdef __cplusplus
26097extern "C"
26098#endif
26099char libssh2_channel_open_ex ();
26100int main (void)
26101{
26102return libssh2_channel_open_ex ();
26103 ;
26104 return 0;
26105}
26106_ACEOF
26107if ac_fn_c_try_link "$LINENO"; then :
26108 ac_cv_lib_ssh2_libssh2_channel_open_ex=yes
26109else
26110 ac_cv_lib_ssh2_libssh2_channel_open_ex=no
26111fi
26112rm -f core conftest.err conftest.$ac_objext \
26113 conftest$ac_exeext conftest.$ac_ext
26114LIBS=$ac_check_lib_save_LIBS
26115fi
26116{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ssh2_libssh2_channel_open_ex" >&5
26117$as_echo "$ac_cv_lib_ssh2_libssh2_channel_open_ex" >&6; }
26118if test "x$ac_cv_lib_ssh2_libssh2_channel_open_ex" = xyes; then :
26119 cat >>confdefs.h <<_ACEOF
26120#define HAVE_LIBSSH2 1
26121_ACEOF
26122
26123 LIBS="-lssh2 $LIBS"
26124
26125fi
26126
26127
26128 for ac_header in libssh2.h
26129do :
26130 ac_fn_c_check_header_mongrel "$LINENO" "libssh2.h" "ac_cv_header_libssh2_h" "$ac_includes_default"
26131if test "x$ac_cv_header_libssh2_h" = xyes; then :
26132 cat >>confdefs.h <<_ACEOF
26133#define HAVE_LIBSSH2_H 1
26134_ACEOF
26135 curl_ssh_msg="enabled (libSSH2)"
26136 LIBSSH2_ENABLED=1
26137
26138$as_echo "#define USE_LIBSSH2 1" >>confdefs.h
26139
26140 USE_LIBSSH2=1
26141
26142
26143fi
26144
26145done
26146
26147
26148 if test X"$OPT_LIBSSH2" != Xoff &&
26149 test "$LIBSSH2_ENABLED" != "1"; then
26150 as_fn_error $? "libSSH2 libs and/or directories were not found where specified!" "$LINENO" 5
26151 fi
26152
26153 if test "$LIBSSH2_ENABLED" = "1"; then
26154 if test -n "$DIR_SSH2"; then
26155
26156 if test "x$cross_compiling" != "xyes"; then
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070026157 CURL_LIBRARY_PATH="$CURL_LIBRARY_PATH:$DIR_SSH2"
26158 export CURL_LIBRARY_PATH
26159 { $as_echo "$as_me:${as_lineno-$LINENO}: Added $DIR_SSH2 to CURL_LIBRARY_PATH" >&5
26160$as_echo "$as_me: Added $DIR_SSH2 to CURL_LIBRARY_PATH" >&6;}
Elliott Hughes82be86d2017-09-20 17:00:17 -070026161 fi
26162 fi
26163 else
26164 LDFLAGS=$CLEANLDFLAGS
26165 CPPFLAGS=$CLEANCPPFLAGS
26166 LIBS=$CLEANLIBS
26167 fi
Elliott Hughes0128fe42018-02-27 14:57:55 -080026168elif test X"$OPT_LIBSSH" != Xno; then
26169 CLEANLDFLAGS="$LDFLAGS"
26170 CLEANCPPFLAGS="$CPPFLAGS"
26171 CLEANLIBS="$LIBS"
26172
26173 case "$OPT_LIBSSH" in
26174 yes)
26175
26176 if test -n "$PKG_CONFIG"; then
26177 PKGCONFIG="$PKG_CONFIG"
26178 else
26179 if test -n "$ac_tool_prefix"; then
26180 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
26181set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
26182{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
26183$as_echo_n "checking for $ac_word... " >&6; }
26184if ${ac_cv_path_PKGCONFIG+:} false; then :
26185 $as_echo_n "(cached) " >&6
26186else
26187 case $PKGCONFIG in
26188 [\\/]* | ?:[\\/]*)
26189 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
26190 ;;
26191 *)
26192 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26193as_dummy="$PATH:/usr/bin:/usr/local/bin"
26194for as_dir in $as_dummy
26195do
26196 IFS=$as_save_IFS
26197 test -z "$as_dir" && as_dir=.
26198 for ac_exec_ext in '' $ac_executable_extensions; do
26199 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
26200 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
26201 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
26202 break 2
26203 fi
26204done
26205 done
26206IFS=$as_save_IFS
26207
26208 ;;
26209esac
26210fi
26211PKGCONFIG=$ac_cv_path_PKGCONFIG
26212if test -n "$PKGCONFIG"; then
26213 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
26214$as_echo "$PKGCONFIG" >&6; }
26215else
26216 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26217$as_echo "no" >&6; }
26218fi
26219
26220
26221fi
26222if test -z "$ac_cv_path_PKGCONFIG"; then
26223 ac_pt_PKGCONFIG=$PKGCONFIG
26224 # Extract the first word of "pkg-config", so it can be a program name with args.
26225set dummy pkg-config; ac_word=$2
26226{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
26227$as_echo_n "checking for $ac_word... " >&6; }
26228if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
26229 $as_echo_n "(cached) " >&6
26230else
26231 case $ac_pt_PKGCONFIG in
26232 [\\/]* | ?:[\\/]*)
26233 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
26234 ;;
26235 *)
26236 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26237as_dummy="$PATH:/usr/bin:/usr/local/bin"
26238for as_dir in $as_dummy
26239do
26240 IFS=$as_save_IFS
26241 test -z "$as_dir" && as_dir=.
26242 for ac_exec_ext in '' $ac_executable_extensions; do
26243 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
26244 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
26245 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
26246 break 2
26247 fi
26248done
26249 done
26250IFS=$as_save_IFS
26251
26252 ;;
26253esac
26254fi
26255ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
26256if test -n "$ac_pt_PKGCONFIG"; then
26257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
26258$as_echo "$ac_pt_PKGCONFIG" >&6; }
26259else
26260 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26261$as_echo "no" >&6; }
26262fi
26263
26264 if test "x$ac_pt_PKGCONFIG" = x; then
26265 PKGCONFIG="no"
26266 else
26267 case $cross_compiling:$ac_tool_warned in
26268yes:)
26269{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
26270$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
26271ac_tool_warned=yes ;;
26272esac
26273 PKGCONFIG=$ac_pt_PKGCONFIG
26274 fi
26275else
26276 PKGCONFIG="$ac_cv_path_PKGCONFIG"
26277fi
26278
26279 fi
26280
26281 if test "x$PKGCONFIG" != "xno"; then
26282 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libssh options with pkg-config" >&5
26283$as_echo_n "checking for libssh options with pkg-config... " >&6; }
26284 itexists=`
26285 if test -n ""; then
26286 PKG_CONFIG_LIBDIR=""
26287 export PKG_CONFIG_LIBDIR
26288 fi
26289 $PKGCONFIG --exists libssh >/dev/null 2>&1 && echo 1`
26290
26291 if test -z "$itexists"; then
26292 PKGCONFIG="no"
26293 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26294$as_echo "no" >&6; }
26295 else
26296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
26297$as_echo "found" >&6; }
26298 fi
26299 fi
26300
26301
26302 if test "$PKGCONFIG" != "no" ; then
26303 LIB_SSH=`$PKGCONFIG --libs-only-l libssh`
26304 LD_SSH=`$PKGCONFIG --libs-only-L libssh`
26305 CPP_SSH=`$PKGCONFIG --cflags-only-I libssh`
26306 version=`$PKGCONFIG --modversion libssh`
26307 DIR_SSH=`echo $LD_SSH | $SED -e 's/-L//'`
26308 fi
26309
26310 ;;
26311 off)
26312 ;;
26313 *)
26314 PREFIX_SSH=$OPT_LIBSSH
26315 ;;
26316 esac
26317
26318 if test -n "$PREFIX_SSH"; then
26319 LIB_SSH="-lssh"
26320 LD_SSH=-L${PREFIX_SSH}/lib$libsuff
26321 CPP_SSH=-I${PREFIX_SSH}/include
26322 DIR_SSH=${PREFIX_SSH}/lib$libsuff
26323 fi
26324
26325 LDFLAGS="$LDFLAGS $LD_SSH"
26326 CPPFLAGS="$CPPFLAGS $CPP_SSH"
26327 LIBS="$LIB_SSH $LIBS"
26328
26329 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssh_new in -lssh" >&5
26330$as_echo_n "checking for ssh_new in -lssh... " >&6; }
26331if ${ac_cv_lib_ssh_ssh_new+:} false; then :
26332 $as_echo_n "(cached) " >&6
26333else
26334 ac_check_lib_save_LIBS=$LIBS
26335LIBS="-lssh $LIBS"
26336cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26337/* end confdefs.h. */
26338
26339
26340#ifdef __cplusplus
26341extern "C"
26342#endif
26343char ssh_new ();
26344int main (void)
26345{
26346return ssh_new ();
26347 ;
26348 return 0;
26349}
26350_ACEOF
26351if ac_fn_c_try_link "$LINENO"; then :
26352 ac_cv_lib_ssh_ssh_new=yes
26353else
26354 ac_cv_lib_ssh_ssh_new=no
26355fi
26356rm -f core conftest.err conftest.$ac_objext \
26357 conftest$ac_exeext conftest.$ac_ext
26358LIBS=$ac_check_lib_save_LIBS
26359fi
26360{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ssh_ssh_new" >&5
26361$as_echo "$ac_cv_lib_ssh_ssh_new" >&6; }
26362if test "x$ac_cv_lib_ssh_ssh_new" = xyes; then :
26363 cat >>confdefs.h <<_ACEOF
26364#define HAVE_LIBSSH 1
26365_ACEOF
26366
26367 LIBS="-lssh $LIBS"
26368
26369fi
26370
26371
26372 for ac_header in libssh/libssh.h
26373do :
26374 ac_fn_c_check_header_mongrel "$LINENO" "libssh/libssh.h" "ac_cv_header_libssh_libssh_h" "$ac_includes_default"
26375if test "x$ac_cv_header_libssh_libssh_h" = xyes; then :
26376 cat >>confdefs.h <<_ACEOF
26377#define HAVE_LIBSSH_LIBSSH_H 1
26378_ACEOF
26379 curl_ssh_msg="enabled (libSSH)"
26380 LIBSSH_ENABLED=1
26381
26382$as_echo "#define USE_LIBSSH 1" >>confdefs.h
26383
26384 USE_LIBSSH=1
26385
26386
26387fi
26388
26389done
26390
26391
26392 if test X"$OPT_LIBSSH" != Xoff &&
26393 test "$LIBSSH_ENABLED" != "1"; then
26394 as_fn_error $? "libSSH libs and/or directories were not found where specified!" "$LINENO" 5
26395 fi
26396
26397 if test "$LIBSSH_ENABLED" = "1"; then
26398 if test -n "$DIR_SSH"; then
26399
26400 if test "x$cross_compiling" != "xyes"; then
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070026401 CURL_LIBRARY_PATH="$CURL_LIBRARY_PATH:$DIR_SSH"
26402 export CURL_LIBRARY_PATH
26403 { $as_echo "$as_me:${as_lineno-$LINENO}: Added $DIR_SSH to CURL_LIBRARY_PATH" >&5
26404$as_echo "$as_me: Added $DIR_SSH to CURL_LIBRARY_PATH" >&6;}
Elliott Hughes0128fe42018-02-27 14:57:55 -080026405 fi
26406 fi
26407 else
26408 LDFLAGS=$CLEANLDFLAGS
26409 CPPFLAGS=$CLEANCPPFLAGS
26410 LIBS=$CLEANLIBS
26411 fi
Elliott Hughes82be86d2017-09-20 17:00:17 -070026412fi
26413
26414
26415OPT_LIBRTMP=off
26416
26417# Check whether --with-librtmp was given.
26418if test "${with_librtmp+set}" = set; then :
26419 withval=$with_librtmp; OPT_LIBRTMP=$withval
26420fi
26421
26422
26423if test X"$OPT_LIBRTMP" != Xno; then
26424 CLEANLDFLAGS="$LDFLAGS"
26425 CLEANCPPFLAGS="$CPPFLAGS"
26426 CLEANLIBS="$LIBS"
26427
26428 case "$OPT_LIBRTMP" in
26429 yes)
26430
26431 if test -n "$PKG_CONFIG"; then
26432 PKGCONFIG="$PKG_CONFIG"
26433 else
26434 if test -n "$ac_tool_prefix"; then
26435 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
26436set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
26437{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
26438$as_echo_n "checking for $ac_word... " >&6; }
26439if ${ac_cv_path_PKGCONFIG+:} false; then :
26440 $as_echo_n "(cached) " >&6
26441else
26442 case $PKGCONFIG in
26443 [\\/]* | ?:[\\/]*)
26444 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
26445 ;;
26446 *)
26447 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26448as_dummy="$PATH:/usr/bin:/usr/local/bin"
26449for as_dir in $as_dummy
26450do
26451 IFS=$as_save_IFS
26452 test -z "$as_dir" && as_dir=.
26453 for ac_exec_ext in '' $ac_executable_extensions; do
26454 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
26455 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
26456 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
26457 break 2
26458 fi
26459done
26460 done
26461IFS=$as_save_IFS
26462
26463 ;;
26464esac
26465fi
26466PKGCONFIG=$ac_cv_path_PKGCONFIG
26467if test -n "$PKGCONFIG"; then
26468 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
26469$as_echo "$PKGCONFIG" >&6; }
26470else
26471 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26472$as_echo "no" >&6; }
26473fi
26474
26475
26476fi
26477if test -z "$ac_cv_path_PKGCONFIG"; then
26478 ac_pt_PKGCONFIG=$PKGCONFIG
26479 # Extract the first word of "pkg-config", so it can be a program name with args.
26480set dummy pkg-config; ac_word=$2
26481{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
26482$as_echo_n "checking for $ac_word... " >&6; }
26483if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
26484 $as_echo_n "(cached) " >&6
26485else
26486 case $ac_pt_PKGCONFIG in
26487 [\\/]* | ?:[\\/]*)
26488 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
26489 ;;
26490 *)
26491 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26492as_dummy="$PATH:/usr/bin:/usr/local/bin"
26493for as_dir in $as_dummy
26494do
26495 IFS=$as_save_IFS
26496 test -z "$as_dir" && as_dir=.
26497 for ac_exec_ext in '' $ac_executable_extensions; do
26498 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
26499 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
26500 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
26501 break 2
26502 fi
26503done
26504 done
26505IFS=$as_save_IFS
26506
26507 ;;
26508esac
26509fi
26510ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
26511if test -n "$ac_pt_PKGCONFIG"; then
26512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
26513$as_echo "$ac_pt_PKGCONFIG" >&6; }
26514else
26515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26516$as_echo "no" >&6; }
26517fi
26518
26519 if test "x$ac_pt_PKGCONFIG" = x; then
26520 PKGCONFIG="no"
26521 else
26522 case $cross_compiling:$ac_tool_warned in
26523yes:)
26524{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
26525$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
26526ac_tool_warned=yes ;;
26527esac
26528 PKGCONFIG=$ac_pt_PKGCONFIG
26529 fi
26530else
26531 PKGCONFIG="$ac_cv_path_PKGCONFIG"
26532fi
26533
26534 fi
26535
26536 if test "x$PKGCONFIG" != "xno"; then
26537 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for librtmp options with pkg-config" >&5
26538$as_echo_n "checking for librtmp options with pkg-config... " >&6; }
26539 itexists=`
26540 if test -n ""; then
26541 PKG_CONFIG_LIBDIR=""
26542 export PKG_CONFIG_LIBDIR
26543 fi
26544 $PKGCONFIG --exists librtmp >/dev/null 2>&1 && echo 1`
26545
26546 if test -z "$itexists"; then
26547 PKGCONFIG="no"
26548 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26549$as_echo "no" >&6; }
26550 else
26551 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
26552$as_echo "found" >&6; }
26553 fi
26554 fi
26555
26556
26557 if test "$PKGCONFIG" != "no" ; then
26558 LIB_RTMP=`$PKGCONFIG --libs-only-l librtmp`
26559 LD_RTMP=`$PKGCONFIG --libs-only-L librtmp`
26560 CPP_RTMP=`$PKGCONFIG --cflags-only-I librtmp`
26561 version=`$PKGCONFIG --modversion librtmp`
26562 DIR_RTMP=`echo $LD_RTMP | $SED -e 's/-L//'`
26563 else
26564 as_fn_error $? "--librtmp was specified but could not find librtmp pkgconfig file." "$LINENO" 5
26565 fi
26566
26567 ;;
26568 off)
26569 LIB_RTMP="-lrtmp"
26570 ;;
26571 *)
26572 LIB_RTMP="-lrtmp"
26573 PREFIX_RTMP=$OPT_LIBRTMP
26574 ;;
26575 esac
26576
26577 if test -n "$PREFIX_RTMP"; then
26578 LD_RTMP=-L${PREFIX_RTMP}/lib$libsuff
26579 CPP_RTMP=-I${PREFIX_RTMP}/include
26580 DIR_RTMP=${PREFIX_RTMP}/lib$libsuff
26581 fi
26582
26583 LDFLAGS="$LDFLAGS $LD_RTMP"
26584 CPPFLAGS="$CPPFLAGS $CPP_RTMP"
26585 LIBS="$LIB_RTMP $LIBS"
26586
26587 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RTMP_Init in -lrtmp" >&5
26588$as_echo_n "checking for RTMP_Init in -lrtmp... " >&6; }
26589if ${ac_cv_lib_rtmp_RTMP_Init+:} false; then :
26590 $as_echo_n "(cached) " >&6
26591else
26592 ac_check_lib_save_LIBS=$LIBS
26593LIBS="-lrtmp $LIBS"
26594cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26595/* end confdefs.h. */
26596
26597
26598#ifdef __cplusplus
26599extern "C"
26600#endif
26601char RTMP_Init ();
26602int main (void)
26603{
26604return RTMP_Init ();
26605 ;
26606 return 0;
26607}
26608_ACEOF
26609if ac_fn_c_try_link "$LINENO"; then :
26610 ac_cv_lib_rtmp_RTMP_Init=yes
26611else
26612 ac_cv_lib_rtmp_RTMP_Init=no
26613fi
26614rm -f core conftest.err conftest.$ac_objext \
26615 conftest$ac_exeext conftest.$ac_ext
26616LIBS=$ac_check_lib_save_LIBS
26617fi
26618{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rtmp_RTMP_Init" >&5
26619$as_echo "$ac_cv_lib_rtmp_RTMP_Init" >&6; }
26620if test "x$ac_cv_lib_rtmp_RTMP_Init" = xyes; then :
26621
26622 for ac_header in librtmp/rtmp.h
26623do :
26624 ac_fn_c_check_header_mongrel "$LINENO" "librtmp/rtmp.h" "ac_cv_header_librtmp_rtmp_h" "$ac_includes_default"
26625if test "x$ac_cv_header_librtmp_rtmp_h" = xyes; then :
26626 cat >>confdefs.h <<_ACEOF
26627#define HAVE_LIBRTMP_RTMP_H 1
26628_ACEOF
26629 curl_rtmp_msg="enabled (librtmp)"
26630 LIBRTMP_ENABLED=1
26631
26632$as_echo "#define USE_LIBRTMP 1" >>confdefs.h
26633
26634 USE_LIBRTMP=1
26635
26636
26637fi
26638
26639done
26640
26641
26642else
26643 LDFLAGS=$CLEANLDFLAGS
26644 CPPFLAGS=$CLEANCPPFLAGS
26645 LIBS=$CLEANLIBS
26646
26647fi
26648
26649
26650 if test X"$OPT_LIBRTMP" != Xoff &&
26651 test "$LIBRTMP_ENABLED" != "1"; then
26652 as_fn_error $? "librtmp libs and/or directories were not found where specified!" "$LINENO" 5
26653 fi
26654
26655fi
26656
26657
26658versioned_symbols_flavour=
26659{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether versioned symbols are wanted" >&5
26660$as_echo_n "checking whether versioned symbols are wanted... " >&6; }
26661# Check whether --enable-versioned-symbols was given.
26662if test "${enable_versioned_symbols+set}" = set; then :
26663 enableval=$enable_versioned_symbols; case "$enableval" in
26664 yes) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
26665$as_echo "yes" >&6; }
26666 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libraries can be versioned" >&5
26667$as_echo_n "checking if libraries can be versioned... " >&6; }
26668 GLD=`$LD --help < /dev/null 2>/dev/null | grep version-script`
26669 if test -z "$GLD"; then
26670 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26671$as_echo "no" >&6; }
26672 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: You need an ld version supporting the --version-script option" >&5
26673$as_echo "$as_me: WARNING: You need an ld version supporting the --version-script option" >&2;}
26674 else
26675 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
26676$as_echo "yes" >&6; }
Alex Deymo486467e2017-12-19 19:04:07 +010026677 if test "x$CURL_WITH_MULTI_SSL" = "x1"; then
26678 versioned_symbols_flavour="MULTISSL_"
26679 elif test "x$OPENSSL_ENABLED" = "x1"; then
Elliott Hughes82be86d2017-09-20 17:00:17 -070026680 versioned_symbols_flavour="OPENSSL_"
26681 elif test "x$GNUTLS_ENABLED" = "x1"; then
26682 versioned_symbols_flavour="GNUTLS_"
26683 elif test "x$NSS_ENABLED" = "x1"; then
26684 versioned_symbols_flavour="NSS_"
Haibo Huang001784b2019-07-19 05:27:28 -070026685 elif test "x$WOLFSSL_ENABLED" = "x1"; then
26686 versioned_symbols_flavour="WOLFSSL_"
Elliott Hughes82be86d2017-09-20 17:00:17 -070026687 elif test "x$WINSSL_ENABLED" = "x1"; then
Haibo Huang65021c72019-03-27 15:37:23 -070026688 versioned_symbols_flavour="SCHANNEL_"
26689 elif test "x$SECURETRANSPORT_ENABLED" = "x1"; then
26690 versioned_symbols_flavour="SECURE_TRANSPORT_"
Elliott Hughes82be86d2017-09-20 17:00:17 -070026691 else
26692 versioned_symbols_flavour=""
26693 fi
26694 versioned_symbols="yes"
26695 fi
26696 ;;
26697
26698 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26699$as_echo "no" >&6; }
26700 ;;
26701 esac
26702
26703else
26704
26705{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26706$as_echo "no" >&6; }
26707
26708
26709fi
26710
26711
26712CURL_LT_SHLIB_VERSIONED_FLAVOUR="$versioned_symbols_flavour"
26713
26714 if test "x$versioned_symbols" = 'xyes'; then
26715 CURL_LT_SHLIB_USE_VERSIONED_SYMBOLS_TRUE=
26716 CURL_LT_SHLIB_USE_VERSIONED_SYMBOLS_FALSE='#'
26717else
26718 CURL_LT_SHLIB_USE_VERSIONED_SYMBOLS_TRUE='#'
26719 CURL_LT_SHLIB_USE_VERSIONED_SYMBOLS_FALSE=
26720fi
26721
26722
26723
26724{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable Windows native IDN (Windows native builds only)" >&5
26725$as_echo_n "checking whether to enable Windows native IDN (Windows native builds only)... " >&6; }
26726OPT_WINIDN="default"
26727
26728# Check whether --with-winidn was given.
26729if test "${with_winidn+set}" = set; then :
26730 withval=$with_winidn; OPT_WINIDN=$withval
26731fi
26732
26733case "$OPT_WINIDN" in
26734 no|default)
26735 want_winidn="no"
26736 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26737$as_echo "no" >&6; }
26738 ;;
26739 yes)
26740 want_winidn="yes"
26741 want_winidn_path="default"
26742 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
26743$as_echo "yes" >&6; }
26744 ;;
26745 *)
26746 want_winidn="yes"
26747 want_winidn_path="$withval"
26748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes ($withval)" >&5
26749$as_echo "yes ($withval)" >&6; }
26750 ;;
26751esac
26752
26753if test "$want_winidn" = "yes"; then
26754 clean_CPPFLAGS="$CPPFLAGS"
26755 clean_LDFLAGS="$LDFLAGS"
26756 clean_LIBS="$LIBS"
26757 WINIDN_LIBS="-lnormaliz"
26758 WINIDN_CPPFLAGS="-DWINVER=0x0600"
26759 #
26760 if test "$want_winidn_path" != "default"; then
26761 WINIDN_LDFLAGS="-L$want_winidn_path/lib$libsuff"
26762 WINIDN_CPPFLAGS="-I$want_winidn_path/include"
26763 WINIDN_DIR="$want_winidn_path/lib$libsuff"
26764 fi
26765 #
26766 CPPFLAGS="$CPPFLAGS $WINIDN_CPPFLAGS"
26767 LDFLAGS="$LDFLAGS $WINIDN_LDFLAGS"
26768 LIBS="$WINIDN_LIBS $LIBS"
26769 #
26770 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if IdnToUnicode can be linked" >&5
26771$as_echo_n "checking if IdnToUnicode can be linked... " >&6; }
26772 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26773/* end confdefs.h. */
26774
26775
26776 #include <windows.h>
26777
26778int main (void)
26779{
26780
26781 IdnToUnicode(0, NULL, 0, NULL, 0);
26782
26783 ;
26784 return 0;
26785}
26786
26787_ACEOF
26788if ac_fn_c_try_link "$LINENO"; then :
26789
26790 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
26791$as_echo "yes" >&6; }
26792 tst_links_winidn="yes"
26793
26794else
26795
26796 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26797$as_echo "no" >&6; }
26798 tst_links_winidn="no"
26799
26800fi
26801rm -f core conftest.err conftest.$ac_objext \
26802 conftest$ac_exeext conftest.$ac_ext
26803 #
26804 if test "$tst_links_winidn" = "yes"; then
26805
26806$as_echo "#define USE_WIN32_IDN 1" >>confdefs.h
26807
26808
26809$as_echo "#define WANT_IDN_PROTOTYPES 1" >>confdefs.h
26810
26811 IDN_ENABLED=1
26812
26813 curl_idn_msg="enabled (Windows-native)"
26814 else
26815 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Cannot find libraries for IDN support: IDN disabled" >&5
26816$as_echo "$as_me: WARNING: Cannot find libraries for IDN support: IDN disabled" >&2;}
26817 CPPFLAGS="$clean_CPPFLAGS"
26818 LDFLAGS="$clean_LDFLAGS"
26819 LIBS="$clean_LIBS"
26820 fi
26821fi
26822
26823
26824{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with libidn2" >&5
26825$as_echo_n "checking whether to build with libidn2... " >&6; }
26826OPT_IDN="default"
26827
26828# Check whether --with-libidn2 was given.
26829if test "${with_libidn2+set}" = set; then :
26830 withval=$with_libidn2; OPT_IDN=$withval
26831fi
26832
26833case "$OPT_IDN" in
26834 no)
26835 want_idn="no"
26836 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26837$as_echo "no" >&6; }
26838 ;;
26839 default)
26840 want_idn="yes"
26841 want_idn_path="default"
26842 { $as_echo "$as_me:${as_lineno-$LINENO}: result: (assumed) yes" >&5
26843$as_echo "(assumed) yes" >&6; }
26844 ;;
26845 yes)
26846 want_idn="yes"
26847 want_idn_path="default"
26848 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
26849$as_echo "yes" >&6; }
26850 ;;
26851 *)
26852 want_idn="yes"
26853 want_idn_path="$withval"
26854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes ($withval)" >&5
26855$as_echo "yes ($withval)" >&6; }
26856 ;;
26857esac
26858
26859if test "$want_idn" = "yes"; then
26860 clean_CPPFLAGS="$CPPFLAGS"
26861 clean_LDFLAGS="$LDFLAGS"
26862 clean_LIBS="$LIBS"
26863 PKGCONFIG="no"
26864 #
26865 if test "$want_idn_path" != "default"; then
26866 IDN_PCDIR="$want_idn_path/lib$libsuff/pkgconfig"
26867
26868 if test -n "$PKG_CONFIG"; then
26869 PKGCONFIG="$PKG_CONFIG"
26870 else
26871 if test -n "$ac_tool_prefix"; then
26872 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
26873set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
26874{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
26875$as_echo_n "checking for $ac_word... " >&6; }
26876if ${ac_cv_path_PKGCONFIG+:} false; then :
26877 $as_echo_n "(cached) " >&6
26878else
26879 case $PKGCONFIG in
26880 [\\/]* | ?:[\\/]*)
26881 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
26882 ;;
26883 *)
26884 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26885as_dummy="$PATH:/usr/bin:/usr/local/bin"
26886for as_dir in $as_dummy
26887do
26888 IFS=$as_save_IFS
26889 test -z "$as_dir" && as_dir=.
26890 for ac_exec_ext in '' $ac_executable_extensions; do
26891 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
26892 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
26893 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
26894 break 2
26895 fi
26896done
26897 done
26898IFS=$as_save_IFS
26899
26900 ;;
26901esac
26902fi
26903PKGCONFIG=$ac_cv_path_PKGCONFIG
26904if test -n "$PKGCONFIG"; then
26905 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
26906$as_echo "$PKGCONFIG" >&6; }
26907else
26908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26909$as_echo "no" >&6; }
26910fi
26911
26912
26913fi
26914if test -z "$ac_cv_path_PKGCONFIG"; then
26915 ac_pt_PKGCONFIG=$PKGCONFIG
26916 # Extract the first word of "pkg-config", so it can be a program name with args.
26917set dummy pkg-config; ac_word=$2
26918{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
26919$as_echo_n "checking for $ac_word... " >&6; }
26920if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
26921 $as_echo_n "(cached) " >&6
26922else
26923 case $ac_pt_PKGCONFIG in
26924 [\\/]* | ?:[\\/]*)
26925 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
26926 ;;
26927 *)
26928 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26929as_dummy="$PATH:/usr/bin:/usr/local/bin"
26930for as_dir in $as_dummy
26931do
26932 IFS=$as_save_IFS
26933 test -z "$as_dir" && as_dir=.
26934 for ac_exec_ext in '' $ac_executable_extensions; do
26935 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
26936 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
26937 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
26938 break 2
26939 fi
26940done
26941 done
26942IFS=$as_save_IFS
26943
26944 ;;
26945esac
26946fi
26947ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
26948if test -n "$ac_pt_PKGCONFIG"; then
26949 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
26950$as_echo "$ac_pt_PKGCONFIG" >&6; }
26951else
26952 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26953$as_echo "no" >&6; }
26954fi
26955
26956 if test "x$ac_pt_PKGCONFIG" = x; then
26957 PKGCONFIG="no"
26958 else
26959 case $cross_compiling:$ac_tool_warned in
26960yes:)
26961{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
26962$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
26963ac_tool_warned=yes ;;
26964esac
26965 PKGCONFIG=$ac_pt_PKGCONFIG
26966 fi
26967else
26968 PKGCONFIG="$ac_cv_path_PKGCONFIG"
26969fi
26970
26971 fi
26972
26973 if test "x$PKGCONFIG" != "xno"; then
26974 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libidn2 options with pkg-config" >&5
26975$as_echo_n "checking for libidn2 options with pkg-config... " >&6; }
26976 itexists=`
26977 if test -n "$IDN_PCDIR"; then
26978 PKG_CONFIG_LIBDIR="$IDN_PCDIR"
26979 export PKG_CONFIG_LIBDIR
26980 fi
26981 $PKGCONFIG --exists libidn2 >/dev/null 2>&1 && echo 1`
26982
26983 if test -z "$itexists"; then
26984 PKGCONFIG="no"
26985 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26986$as_echo "no" >&6; }
26987 else
26988 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
26989$as_echo "found" >&6; }
26990 fi
26991 fi
26992
26993 if test "$PKGCONFIG" != "no"; then
26994 IDN_LIBS=`
26995 if test -n "$IDN_PCDIR"; then
26996 PKG_CONFIG_LIBDIR="$IDN_PCDIR"
26997 export PKG_CONFIG_LIBDIR
26998 fi
26999 $PKGCONFIG --libs-only-l libidn2 2>/dev/null`
27000 IDN_LDFLAGS=`
27001 if test -n "$IDN_PCDIR"; then
27002 PKG_CONFIG_LIBDIR="$IDN_PCDIR"
27003 export PKG_CONFIG_LIBDIR
27004 fi
27005 $PKGCONFIG --libs-only-L libidn2 2>/dev/null`
27006 IDN_CPPFLAGS=`
27007 if test -n "$IDN_PCDIR"; then
27008 PKG_CONFIG_LIBDIR="$IDN_PCDIR"
27009 export PKG_CONFIG_LIBDIR
27010 fi
27011 $PKGCONFIG --cflags-only-I libidn2 2>/dev/null`
27012 IDN_DIR=`echo $IDN_LDFLAGS | $SED -e 's/-L//'`
27013 else
27014 IDN_LIBS="-lidn2"
27015 IDN_LDFLAGS="-L$want_idn_path/lib$libsuff"
27016 IDN_CPPFLAGS="-I$want_idn_path/include"
27017 IDN_DIR="$want_idn_path/lib$libsuff"
27018 fi
27019 else
27020
27021 if test -n "$PKG_CONFIG"; then
27022 PKGCONFIG="$PKG_CONFIG"
27023 else
27024 if test -n "$ac_tool_prefix"; then
27025 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
27026set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
27027{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27028$as_echo_n "checking for $ac_word... " >&6; }
27029if ${ac_cv_path_PKGCONFIG+:} false; then :
27030 $as_echo_n "(cached) " >&6
27031else
27032 case $PKGCONFIG in
27033 [\\/]* | ?:[\\/]*)
27034 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
27035 ;;
27036 *)
27037 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27038as_dummy="$PATH:/usr/bin:/usr/local/bin"
27039for as_dir in $as_dummy
27040do
27041 IFS=$as_save_IFS
27042 test -z "$as_dir" && as_dir=.
27043 for ac_exec_ext in '' $ac_executable_extensions; do
27044 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27045 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
27046 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27047 break 2
27048 fi
27049done
27050 done
27051IFS=$as_save_IFS
27052
27053 ;;
27054esac
27055fi
27056PKGCONFIG=$ac_cv_path_PKGCONFIG
27057if test -n "$PKGCONFIG"; then
27058 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
27059$as_echo "$PKGCONFIG" >&6; }
27060else
27061 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27062$as_echo "no" >&6; }
27063fi
27064
27065
27066fi
27067if test -z "$ac_cv_path_PKGCONFIG"; then
27068 ac_pt_PKGCONFIG=$PKGCONFIG
27069 # Extract the first word of "pkg-config", so it can be a program name with args.
27070set dummy pkg-config; ac_word=$2
27071{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27072$as_echo_n "checking for $ac_word... " >&6; }
27073if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
27074 $as_echo_n "(cached) " >&6
27075else
27076 case $ac_pt_PKGCONFIG in
27077 [\\/]* | ?:[\\/]*)
27078 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
27079 ;;
27080 *)
27081 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27082as_dummy="$PATH:/usr/bin:/usr/local/bin"
27083for as_dir in $as_dummy
27084do
27085 IFS=$as_save_IFS
27086 test -z "$as_dir" && as_dir=.
27087 for ac_exec_ext in '' $ac_executable_extensions; do
27088 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27089 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
27090 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27091 break 2
27092 fi
27093done
27094 done
27095IFS=$as_save_IFS
27096
27097 ;;
27098esac
27099fi
27100ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
27101if test -n "$ac_pt_PKGCONFIG"; then
27102 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
27103$as_echo "$ac_pt_PKGCONFIG" >&6; }
27104else
27105 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27106$as_echo "no" >&6; }
27107fi
27108
27109 if test "x$ac_pt_PKGCONFIG" = x; then
27110 PKGCONFIG="no"
27111 else
27112 case $cross_compiling:$ac_tool_warned in
27113yes:)
27114{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
27115$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
27116ac_tool_warned=yes ;;
27117esac
27118 PKGCONFIG=$ac_pt_PKGCONFIG
27119 fi
27120else
27121 PKGCONFIG="$ac_cv_path_PKGCONFIG"
27122fi
27123
27124 fi
27125
27126 if test "x$PKGCONFIG" != "xno"; then
27127 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libidn2 options with pkg-config" >&5
27128$as_echo_n "checking for libidn2 options with pkg-config... " >&6; }
27129 itexists=`
27130 if test -n ""; then
27131 PKG_CONFIG_LIBDIR=""
27132 export PKG_CONFIG_LIBDIR
27133 fi
27134 $PKGCONFIG --exists libidn2 >/dev/null 2>&1 && echo 1`
27135
27136 if test -z "$itexists"; then
27137 PKGCONFIG="no"
27138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27139$as_echo "no" >&6; }
27140 else
27141 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
27142$as_echo "found" >&6; }
27143 fi
27144 fi
27145
27146 if test "$PKGCONFIG" != "no"; then
27147 IDN_LIBS=`$PKGCONFIG --libs-only-l libidn2 2>/dev/null`
27148 IDN_LDFLAGS=`$PKGCONFIG --libs-only-L libidn2 2>/dev/null`
27149 IDN_CPPFLAGS=`$PKGCONFIG --cflags-only-I libidn2 2>/dev/null`
27150 IDN_DIR=`echo $IDN_LDFLAGS | $SED -e 's/-L//'`
27151 else
27152 IDN_LIBS="-lidn2"
27153 fi
27154 fi
27155 #
27156 if test "$PKGCONFIG" != "no"; then
27157 { $as_echo "$as_me:${as_lineno-$LINENO}: pkg-config: IDN_LIBS: \"$IDN_LIBS\"" >&5
27158$as_echo "$as_me: pkg-config: IDN_LIBS: \"$IDN_LIBS\"" >&6;}
27159 { $as_echo "$as_me:${as_lineno-$LINENO}: pkg-config: IDN_LDFLAGS: \"$IDN_LDFLAGS\"" >&5
27160$as_echo "$as_me: pkg-config: IDN_LDFLAGS: \"$IDN_LDFLAGS\"" >&6;}
27161 { $as_echo "$as_me:${as_lineno-$LINENO}: pkg-config: IDN_CPPFLAGS: \"$IDN_CPPFLAGS\"" >&5
27162$as_echo "$as_me: pkg-config: IDN_CPPFLAGS: \"$IDN_CPPFLAGS\"" >&6;}
27163 { $as_echo "$as_me:${as_lineno-$LINENO}: pkg-config: IDN_DIR: \"$IDN_DIR\"" >&5
27164$as_echo "$as_me: pkg-config: IDN_DIR: \"$IDN_DIR\"" >&6;}
27165 else
27166 { $as_echo "$as_me:${as_lineno-$LINENO}: IDN_LIBS: \"$IDN_LIBS\"" >&5
27167$as_echo "$as_me: IDN_LIBS: \"$IDN_LIBS\"" >&6;}
27168 { $as_echo "$as_me:${as_lineno-$LINENO}: IDN_LDFLAGS: \"$IDN_LDFLAGS\"" >&5
27169$as_echo "$as_me: IDN_LDFLAGS: \"$IDN_LDFLAGS\"" >&6;}
27170 { $as_echo "$as_me:${as_lineno-$LINENO}: IDN_CPPFLAGS: \"$IDN_CPPFLAGS\"" >&5
27171$as_echo "$as_me: IDN_CPPFLAGS: \"$IDN_CPPFLAGS\"" >&6;}
27172 { $as_echo "$as_me:${as_lineno-$LINENO}: IDN_DIR: \"$IDN_DIR\"" >&5
27173$as_echo "$as_me: IDN_DIR: \"$IDN_DIR\"" >&6;}
27174 fi
27175 #
27176 CPPFLAGS="$CPPFLAGS $IDN_CPPFLAGS"
27177 LDFLAGS="$LDFLAGS $IDN_LDFLAGS"
27178 LIBS="$IDN_LIBS $LIBS"
27179 #
27180 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if idn2_lookup_ul can be linked" >&5
27181$as_echo_n "checking if idn2_lookup_ul can be linked... " >&6; }
27182 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27183/* end confdefs.h. */
27184
27185
27186#define idn2_lookup_ul innocuous_idn2_lookup_ul
27187#ifdef __STDC__
27188# include <limits.h>
27189#else
27190# include <assert.h>
27191#endif
27192#undef idn2_lookup_ul
27193#ifdef __cplusplus
27194extern "C"
27195#endif
27196char idn2_lookup_ul ();
27197#if defined __stub_idn2_lookup_ul || defined __stub___idn2_lookup_ul
27198choke me
27199#endif
27200
27201int main (void)
27202{
27203return idn2_lookup_ul ();
27204 ;
27205 return 0;
27206}
27207
27208_ACEOF
27209if ac_fn_c_try_link "$LINENO"; then :
27210
27211 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
27212$as_echo "yes" >&6; }
27213 tst_links_libidn="yes"
27214
27215else
27216
27217 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27218$as_echo "no" >&6; }
27219 tst_links_libidn="no"
27220
27221fi
27222rm -f core conftest.err conftest.$ac_objext \
27223 conftest$ac_exeext conftest.$ac_ext
27224 #
27225 for ac_header in idn2.h
27226do :
27227 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
27228ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
27229if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
27230 cat >>confdefs.h <<_ACEOF
27231#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
27232_ACEOF
27233
27234fi
27235
27236done
27237
27238
27239 if test "$tst_links_libidn" = "yes"; then
27240
27241$as_echo "#define HAVE_LIBIDN2 1" >>confdefs.h
27242
27243
27244 IDN_ENABLED=1
27245
27246 curl_idn_msg="enabled (libidn2)"
27247 if test -n "$IDN_DIR" -a "x$cross_compiling" != "xyes"; then
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070027248 CURL_LIBRARY_PATH="$CURL_LIBRARY_PATH:$IDN_DIR"
27249 export CURL_LIBRARY_PATH
27250 { $as_echo "$as_me:${as_lineno-$LINENO}: Added $IDN_DIR to CURL_LIBRARY_PATH" >&5
27251$as_echo "$as_me: Added $IDN_DIR to CURL_LIBRARY_PATH" >&6;}
Elliott Hughes82be86d2017-09-20 17:00:17 -070027252 fi
27253 else
27254 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Cannot find libraries for IDN support: IDN disabled" >&5
27255$as_echo "$as_me: WARNING: Cannot find libraries for IDN support: IDN disabled" >&2;}
27256 CPPFLAGS="$clean_CPPFLAGS"
27257 LDFLAGS="$clean_LDFLAGS"
27258 LIBS="$clean_LIBS"
27259 fi
27260fi
27261
27262
27263
27264
27265
27266OPT_H2="yes"
27267
27268if test "x$disable_http" = "xyes"; then
27269 # without HTTP, nghttp2 is no use
27270 OPT_H2="no"
27271fi
27272
27273
27274# Check whether --with-nghttp2 was given.
27275if test "${with_nghttp2+set}" = set; then :
27276 withval=$with_nghttp2; OPT_H2=$withval
27277fi
27278
27279case "$OPT_H2" in
27280 no)
27281 want_h2="no"
27282 ;;
27283 yes)
27284 want_h2="default"
27285 want_h2_path=""
27286 ;;
27287 *)
27288 want_h2="yes"
27289 want_h2_path="$withval/lib/pkgconfig"
27290 ;;
27291esac
27292
27293curl_h2_msg="disabled (--with-nghttp2)"
27294if test X"$want_h2" != Xno; then
27295 CLEANLDFLAGS="$LDFLAGS"
27296 CLEANCPPFLAGS="$CPPFLAGS"
27297 CLEANLIBS="$LIBS"
27298
27299
27300 if test -n "$PKG_CONFIG"; then
27301 PKGCONFIG="$PKG_CONFIG"
27302 else
27303 if test -n "$ac_tool_prefix"; then
27304 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
27305set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
27306{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27307$as_echo_n "checking for $ac_word... " >&6; }
27308if ${ac_cv_path_PKGCONFIG+:} false; then :
27309 $as_echo_n "(cached) " >&6
27310else
27311 case $PKGCONFIG in
27312 [\\/]* | ?:[\\/]*)
27313 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
27314 ;;
27315 *)
27316 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27317as_dummy="$PATH:/usr/bin:/usr/local/bin"
27318for as_dir in $as_dummy
27319do
27320 IFS=$as_save_IFS
27321 test -z "$as_dir" && as_dir=.
27322 for ac_exec_ext in '' $ac_executable_extensions; do
27323 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27324 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
27325 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27326 break 2
27327 fi
27328done
27329 done
27330IFS=$as_save_IFS
27331
27332 ;;
27333esac
27334fi
27335PKGCONFIG=$ac_cv_path_PKGCONFIG
27336if test -n "$PKGCONFIG"; then
27337 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
27338$as_echo "$PKGCONFIG" >&6; }
27339else
27340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27341$as_echo "no" >&6; }
27342fi
27343
27344
27345fi
27346if test -z "$ac_cv_path_PKGCONFIG"; then
27347 ac_pt_PKGCONFIG=$PKGCONFIG
27348 # Extract the first word of "pkg-config", so it can be a program name with args.
27349set dummy pkg-config; ac_word=$2
27350{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27351$as_echo_n "checking for $ac_word... " >&6; }
27352if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
27353 $as_echo_n "(cached) " >&6
27354else
27355 case $ac_pt_PKGCONFIG in
27356 [\\/]* | ?:[\\/]*)
27357 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
27358 ;;
27359 *)
27360 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27361as_dummy="$PATH:/usr/bin:/usr/local/bin"
27362for as_dir in $as_dummy
27363do
27364 IFS=$as_save_IFS
27365 test -z "$as_dir" && as_dir=.
27366 for ac_exec_ext in '' $ac_executable_extensions; do
27367 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27368 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
27369 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27370 break 2
27371 fi
27372done
27373 done
27374IFS=$as_save_IFS
27375
27376 ;;
27377esac
27378fi
27379ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
27380if test -n "$ac_pt_PKGCONFIG"; then
27381 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
27382$as_echo "$ac_pt_PKGCONFIG" >&6; }
27383else
27384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27385$as_echo "no" >&6; }
27386fi
27387
27388 if test "x$ac_pt_PKGCONFIG" = x; then
27389 PKGCONFIG="no"
27390 else
27391 case $cross_compiling:$ac_tool_warned in
27392yes:)
27393{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
27394$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
27395ac_tool_warned=yes ;;
27396esac
27397 PKGCONFIG=$ac_pt_PKGCONFIG
27398 fi
27399else
27400 PKGCONFIG="$ac_cv_path_PKGCONFIG"
27401fi
27402
27403 fi
27404
27405 if test "x$PKGCONFIG" != "xno"; then
27406 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libnghttp2 options with pkg-config" >&5
27407$as_echo_n "checking for libnghttp2 options with pkg-config... " >&6; }
27408 itexists=`
27409 if test -n "$want_h2_path"; then
27410 PKG_CONFIG_LIBDIR="$want_h2_path"
27411 export PKG_CONFIG_LIBDIR
27412 fi
27413 $PKGCONFIG --exists libnghttp2 >/dev/null 2>&1 && echo 1`
27414
27415 if test -z "$itexists"; then
27416 PKGCONFIG="no"
27417 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27418$as_echo "no" >&6; }
27419 else
27420 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
27421$as_echo "found" >&6; }
27422 fi
27423 fi
27424
27425
27426 if test "$PKGCONFIG" != "no" ; then
27427 LIB_H2=`
27428 if test -n "$want_h2_path"; then
27429 PKG_CONFIG_LIBDIR="$want_h2_path"
27430 export PKG_CONFIG_LIBDIR
27431 fi
27432
27433 $PKGCONFIG --libs-only-l libnghttp2`
27434 { $as_echo "$as_me:${as_lineno-$LINENO}: -l is $LIB_H2" >&5
27435$as_echo "$as_me: -l is $LIB_H2" >&6;}
27436
27437 CPP_H2=`
27438 if test -n "$want_h2_path"; then
27439 PKG_CONFIG_LIBDIR="$want_h2_path"
27440 export PKG_CONFIG_LIBDIR
27441 fi
27442 $PKGCONFIG --cflags-only-I libnghttp2`
27443 { $as_echo "$as_me:${as_lineno-$LINENO}: -I is $CPP_H2" >&5
27444$as_echo "$as_me: -I is $CPP_H2" >&6;}
27445
27446 LD_H2=`
27447 if test -n "$want_h2_path"; then
27448 PKG_CONFIG_LIBDIR="$want_h2_path"
27449 export PKG_CONFIG_LIBDIR
27450 fi
27451
27452 $PKGCONFIG --libs-only-L libnghttp2`
27453 { $as_echo "$as_me:${as_lineno-$LINENO}: -L is $LD_H2" >&5
27454$as_echo "$as_me: -L is $LD_H2" >&6;}
27455
27456 LDFLAGS="$LDFLAGS $LD_H2"
27457 CPPFLAGS="$CPPFLAGS $CPP_H2"
27458 LIBS="$LIB_H2 $LIBS"
27459
27460 # use nghttp2_option_set_no_recv_client_magic to require nghttp2
27461 # >= 1.0.0
27462 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nghttp2_option_set_no_recv_client_magic in -lnghttp2" >&5
27463$as_echo_n "checking for nghttp2_option_set_no_recv_client_magic in -lnghttp2... " >&6; }
27464if ${ac_cv_lib_nghttp2_nghttp2_option_set_no_recv_client_magic+:} false; then :
27465 $as_echo_n "(cached) " >&6
27466else
27467 ac_check_lib_save_LIBS=$LIBS
27468LIBS="-lnghttp2 $LIBS"
27469cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27470/* end confdefs.h. */
27471
27472
27473#ifdef __cplusplus
27474extern "C"
27475#endif
27476char nghttp2_option_set_no_recv_client_magic ();
27477int main (void)
27478{
27479return nghttp2_option_set_no_recv_client_magic ();
27480 ;
27481 return 0;
27482}
27483_ACEOF
27484if ac_fn_c_try_link "$LINENO"; then :
27485 ac_cv_lib_nghttp2_nghttp2_option_set_no_recv_client_magic=yes
27486else
27487 ac_cv_lib_nghttp2_nghttp2_option_set_no_recv_client_magic=no
27488fi
27489rm -f core conftest.err conftest.$ac_objext \
27490 conftest$ac_exeext conftest.$ac_ext
27491LIBS=$ac_check_lib_save_LIBS
27492fi
27493{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nghttp2_nghttp2_option_set_no_recv_client_magic" >&5
27494$as_echo "$ac_cv_lib_nghttp2_nghttp2_option_set_no_recv_client_magic" >&6; }
27495if test "x$ac_cv_lib_nghttp2_nghttp2_option_set_no_recv_client_magic" = xyes; then :
27496
27497 for ac_header in nghttp2/nghttp2.h
27498do :
27499 ac_fn_c_check_header_mongrel "$LINENO" "nghttp2/nghttp2.h" "ac_cv_header_nghttp2_nghttp2_h" "$ac_includes_default"
27500if test "x$ac_cv_header_nghttp2_nghttp2_h" = xyes; then :
27501 cat >>confdefs.h <<_ACEOF
27502#define HAVE_NGHTTP2_NGHTTP2_H 1
27503_ACEOF
27504 curl_h2_msg="enabled (nghttp2)"
27505 NGHTTP2_ENABLED=1
27506
27507$as_echo "#define USE_NGHTTP2 1" >>confdefs.h
27508
27509 USE_NGHTTP2=1
27510
27511
27512fi
27513
27514done
27515
27516
27517else
27518 LDFLAGS=$CLEANLDFLAGS
27519 CPPFLAGS=$CLEANCPPFLAGS
27520 LIBS=$CLEANLIBS
27521
27522fi
27523
27524
27525 else
27526 if test X"$want_h2" != Xdefault; then
27527 as_fn_error $? "--with-nghttp2 was specified but could not find libnghttp2 pkg-config file." "$LINENO" 5
27528 fi
27529 fi
27530
27531fi
27532
27533
Haibo Huang445085a2019-09-11 13:33:50 -070027534OPT_TCP2="yes"
27535curl_h3_msg="disabled (--with-ngtcp2, --with-quiche)"
27536
27537if test "x$disable_http" = "xyes"; then
27538 # without HTTP, ngtcp2 is no use
27539 OPT_TCP2="no"
27540fi
27541
27542
27543# Check whether --with-ngtcp2 was given.
27544if test "${with_ngtcp2+set}" = set; then :
27545 withval=$with_ngtcp2; OPT_TCP2=$withval
27546fi
27547
27548case "$OPT_TCP2" in
27549 no)
27550 want_tcp2="no"
27551 ;;
27552 yes)
27553 want_tcp2="default"
27554 want_tcp2_path=""
27555 ;;
27556 *)
27557 want_tcp2="yes"
27558 want_tcp2_path="$withval/lib/pkgconfig"
27559 ;;
27560esac
27561
27562curl_tcp2_msg="disabled (--with-ngtcp2)"
27563if test X"$want_tcp2" != Xno; then
27564 CLEANLDFLAGS="$LDFLAGS"
27565 CLEANCPPFLAGS="$CPPFLAGS"
27566 CLEANLIBS="$LIBS"
27567
27568
27569 if test -n "$PKG_CONFIG"; then
27570 PKGCONFIG="$PKG_CONFIG"
27571 else
27572 if test -n "$ac_tool_prefix"; then
27573 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
27574set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
27575{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27576$as_echo_n "checking for $ac_word... " >&6; }
27577if ${ac_cv_path_PKGCONFIG+:} false; then :
27578 $as_echo_n "(cached) " >&6
27579else
27580 case $PKGCONFIG in
27581 [\\/]* | ?:[\\/]*)
27582 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
27583 ;;
27584 *)
27585 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27586as_dummy="$PATH:/usr/bin:/usr/local/bin"
27587for as_dir in $as_dummy
27588do
27589 IFS=$as_save_IFS
27590 test -z "$as_dir" && as_dir=.
27591 for ac_exec_ext in '' $ac_executable_extensions; do
27592 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27593 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
27594 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27595 break 2
27596 fi
27597done
27598 done
27599IFS=$as_save_IFS
27600
27601 ;;
27602esac
27603fi
27604PKGCONFIG=$ac_cv_path_PKGCONFIG
27605if test -n "$PKGCONFIG"; then
27606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
27607$as_echo "$PKGCONFIG" >&6; }
27608else
27609 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27610$as_echo "no" >&6; }
27611fi
27612
27613
27614fi
27615if test -z "$ac_cv_path_PKGCONFIG"; then
27616 ac_pt_PKGCONFIG=$PKGCONFIG
27617 # Extract the first word of "pkg-config", so it can be a program name with args.
27618set dummy pkg-config; ac_word=$2
27619{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27620$as_echo_n "checking for $ac_word... " >&6; }
27621if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
27622 $as_echo_n "(cached) " >&6
27623else
27624 case $ac_pt_PKGCONFIG in
27625 [\\/]* | ?:[\\/]*)
27626 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
27627 ;;
27628 *)
27629 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27630as_dummy="$PATH:/usr/bin:/usr/local/bin"
27631for as_dir in $as_dummy
27632do
27633 IFS=$as_save_IFS
27634 test -z "$as_dir" && as_dir=.
27635 for ac_exec_ext in '' $ac_executable_extensions; do
27636 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27637 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
27638 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27639 break 2
27640 fi
27641done
27642 done
27643IFS=$as_save_IFS
27644
27645 ;;
27646esac
27647fi
27648ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
27649if test -n "$ac_pt_PKGCONFIG"; then
27650 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
27651$as_echo "$ac_pt_PKGCONFIG" >&6; }
27652else
27653 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27654$as_echo "no" >&6; }
27655fi
27656
27657 if test "x$ac_pt_PKGCONFIG" = x; then
27658 PKGCONFIG="no"
27659 else
27660 case $cross_compiling:$ac_tool_warned in
27661yes:)
27662{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
27663$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
27664ac_tool_warned=yes ;;
27665esac
27666 PKGCONFIG=$ac_pt_PKGCONFIG
27667 fi
27668else
27669 PKGCONFIG="$ac_cv_path_PKGCONFIG"
27670fi
27671
27672 fi
27673
27674 if test "x$PKGCONFIG" != "xno"; then
27675 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libngtcp2 options with pkg-config" >&5
27676$as_echo_n "checking for libngtcp2 options with pkg-config... " >&6; }
27677 itexists=`
27678 if test -n "$want_tcp2_path"; then
27679 PKG_CONFIG_LIBDIR="$want_tcp2_path"
27680 export PKG_CONFIG_LIBDIR
27681 fi
27682 $PKGCONFIG --exists libngtcp2 >/dev/null 2>&1 && echo 1`
27683
27684 if test -z "$itexists"; then
27685 PKGCONFIG="no"
27686 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27687$as_echo "no" >&6; }
27688 else
27689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
27690$as_echo "found" >&6; }
27691 fi
27692 fi
27693
27694
27695 if test "$PKGCONFIG" != "no" ; then
27696 LIB_TCP2=`
27697 if test -n "$want_tcp2_path"; then
27698 PKG_CONFIG_LIBDIR="$want_tcp2_path"
27699 export PKG_CONFIG_LIBDIR
27700 fi
27701
27702 $PKGCONFIG --libs-only-l libngtcp2`
27703 { $as_echo "$as_me:${as_lineno-$LINENO}: -l is $LIB_TCP2" >&5
27704$as_echo "$as_me: -l is $LIB_TCP2" >&6;}
27705
27706 CPP_TCP2=`
27707 if test -n "$want_tcp2_path"; then
27708 PKG_CONFIG_LIBDIR="$want_tcp2_path"
27709 export PKG_CONFIG_LIBDIR
27710 fi
27711 $PKGCONFIG --cflags-only-I libngtcp2`
27712 { $as_echo "$as_me:${as_lineno-$LINENO}: -I is $CPP_TCP2" >&5
27713$as_echo "$as_me: -I is $CPP_TCP2" >&6;}
27714
27715 LD_TCP2=`
27716 if test -n "$want_tcp2_path"; then
27717 PKG_CONFIG_LIBDIR="$want_tcp2_path"
27718 export PKG_CONFIG_LIBDIR
27719 fi
27720
27721 $PKGCONFIG --libs-only-L libngtcp2`
27722 { $as_echo "$as_me:${as_lineno-$LINENO}: -L is $LD_TCP2" >&5
27723$as_echo "$as_me: -L is $LD_TCP2" >&6;}
27724
27725 LDFLAGS="$LDFLAGS $LD_TCP2"
27726 CPPFLAGS="$CPPFLAGS $CPP_TCP2"
27727 LIBS="$LIB_TCP2 $LIBS"
27728
27729 if test "x$cross_compiling" != "xyes"; then
27730 DIR_TCP2=`echo $LD_TCP2 | $SED -e 's/-L//'`
27731 fi
27732 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ngtcp2_conn_client_new in -lngtcp2" >&5
27733$as_echo_n "checking for ngtcp2_conn_client_new in -lngtcp2... " >&6; }
27734if ${ac_cv_lib_ngtcp2_ngtcp2_conn_client_new+:} false; then :
27735 $as_echo_n "(cached) " >&6
27736else
27737 ac_check_lib_save_LIBS=$LIBS
27738LIBS="-lngtcp2 $LIBS"
27739cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27740/* end confdefs.h. */
27741
27742
27743#ifdef __cplusplus
27744extern "C"
27745#endif
27746char ngtcp2_conn_client_new ();
27747int main (void)
27748{
27749return ngtcp2_conn_client_new ();
27750 ;
27751 return 0;
27752}
27753_ACEOF
27754if ac_fn_c_try_link "$LINENO"; then :
27755 ac_cv_lib_ngtcp2_ngtcp2_conn_client_new=yes
27756else
27757 ac_cv_lib_ngtcp2_ngtcp2_conn_client_new=no
27758fi
27759rm -f core conftest.err conftest.$ac_objext \
27760 conftest$ac_exeext conftest.$ac_ext
27761LIBS=$ac_check_lib_save_LIBS
27762fi
27763{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ngtcp2_ngtcp2_conn_client_new" >&5
27764$as_echo "$ac_cv_lib_ngtcp2_ngtcp2_conn_client_new" >&6; }
27765if test "x$ac_cv_lib_ngtcp2_ngtcp2_conn_client_new" = xyes; then :
27766
27767 for ac_header in ngtcp2/ngtcp2.h
27768do :
27769 ac_fn_c_check_header_mongrel "$LINENO" "ngtcp2/ngtcp2.h" "ac_cv_header_ngtcp2_ngtcp2_h" "$ac_includes_default"
27770if test "x$ac_cv_header_ngtcp2_ngtcp2_h" = xyes; then :
27771 cat >>confdefs.h <<_ACEOF
27772#define HAVE_NGTCP2_NGTCP2_H 1
27773_ACEOF
27774 NGTCP2_ENABLED=1
27775
27776$as_echo "#define USE_NGTCP2 1" >>confdefs.h
27777
27778 USE_NGTCP2=1
27779
27780 CURL_LIBRARY_PATH="$CURL_LIBRARY_PATH:$DIR_TCP2"
27781 export CURL_LIBRARY_PATH
27782 { $as_echo "$as_me:${as_lineno-$LINENO}: Added $DIR_TCP2 to CURL_LIBRARY_PATH" >&5
27783$as_echo "$as_me: Added $DIR_TCP2 to CURL_LIBRARY_PATH" >&6;}
27784
27785fi
27786
27787done
27788
27789
27790else
27791 LDFLAGS=$CLEANLDFLAGS
27792 CPPFLAGS=$CLEANCPPFLAGS
27793 LIBS=$CLEANLIBS
27794
27795fi
27796
27797
27798 else
27799 if test X"$want_tcp2" != Xdefault; then
27800 as_fn_error $? "--with-ngtcp2 was specified but could not find ngtcp2 pkg-config file." "$LINENO" 5
27801 fi
27802 fi
27803
27804fi
27805
27806if test "x$NGTCP2_ENABLED" = "x1"; then
27807 CLEANLDFLAGS="$LDFLAGS"
27808 CLEANCPPFLAGS="$CPPFLAGS"
27809 CLEANLIBS="$LIBS"
27810
27811
27812 if test -n "$PKG_CONFIG"; then
27813 PKGCONFIG="$PKG_CONFIG"
27814 else
27815 if test -n "$ac_tool_prefix"; then
27816 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
27817set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
27818{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27819$as_echo_n "checking for $ac_word... " >&6; }
27820if ${ac_cv_path_PKGCONFIG+:} false; then :
27821 $as_echo_n "(cached) " >&6
27822else
27823 case $PKGCONFIG in
27824 [\\/]* | ?:[\\/]*)
27825 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
27826 ;;
27827 *)
27828 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27829as_dummy="$PATH:/usr/bin:/usr/local/bin"
27830for as_dir in $as_dummy
27831do
27832 IFS=$as_save_IFS
27833 test -z "$as_dir" && as_dir=.
27834 for ac_exec_ext in '' $ac_executable_extensions; do
27835 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27836 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
27837 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27838 break 2
27839 fi
27840done
27841 done
27842IFS=$as_save_IFS
27843
27844 ;;
27845esac
27846fi
27847PKGCONFIG=$ac_cv_path_PKGCONFIG
27848if test -n "$PKGCONFIG"; then
27849 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
27850$as_echo "$PKGCONFIG" >&6; }
27851else
27852 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27853$as_echo "no" >&6; }
27854fi
27855
27856
27857fi
27858if test -z "$ac_cv_path_PKGCONFIG"; then
27859 ac_pt_PKGCONFIG=$PKGCONFIG
27860 # Extract the first word of "pkg-config", so it can be a program name with args.
27861set dummy pkg-config; ac_word=$2
27862{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27863$as_echo_n "checking for $ac_word... " >&6; }
27864if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
27865 $as_echo_n "(cached) " >&6
27866else
27867 case $ac_pt_PKGCONFIG in
27868 [\\/]* | ?:[\\/]*)
27869 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
27870 ;;
27871 *)
27872 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27873as_dummy="$PATH:/usr/bin:/usr/local/bin"
27874for as_dir in $as_dummy
27875do
27876 IFS=$as_save_IFS
27877 test -z "$as_dir" && as_dir=.
27878 for ac_exec_ext in '' $ac_executable_extensions; do
27879 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27880 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
27881 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27882 break 2
27883 fi
27884done
27885 done
27886IFS=$as_save_IFS
27887
27888 ;;
27889esac
27890fi
27891ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
27892if test -n "$ac_pt_PKGCONFIG"; then
27893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
27894$as_echo "$ac_pt_PKGCONFIG" >&6; }
27895else
27896 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27897$as_echo "no" >&6; }
27898fi
27899
27900 if test "x$ac_pt_PKGCONFIG" = x; then
27901 PKGCONFIG="no"
27902 else
27903 case $cross_compiling:$ac_tool_warned in
27904yes:)
27905{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
27906$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
27907ac_tool_warned=yes ;;
27908esac
27909 PKGCONFIG=$ac_pt_PKGCONFIG
27910 fi
27911else
27912 PKGCONFIG="$ac_cv_path_PKGCONFIG"
27913fi
27914
27915 fi
27916
27917 if test "x$PKGCONFIG" != "xno"; then
27918 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libngtcp2_crypto_openssl options with pkg-config" >&5
27919$as_echo_n "checking for libngtcp2_crypto_openssl options with pkg-config... " >&6; }
27920 itexists=`
27921 if test -n "$want_tcp2_path"; then
27922 PKG_CONFIG_LIBDIR="$want_tcp2_path"
27923 export PKG_CONFIG_LIBDIR
27924 fi
27925 $PKGCONFIG --exists libngtcp2_crypto_openssl >/dev/null 2>&1 && echo 1`
27926
27927 if test -z "$itexists"; then
27928 PKGCONFIG="no"
27929 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27930$as_echo "no" >&6; }
27931 else
27932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
27933$as_echo "found" >&6; }
27934 fi
27935 fi
27936
27937
27938 if test "$PKGCONFIG" != "no" ; then
27939 LIB_NGTCP2_CRYPTO_OPENSSL=`
27940 if test -n "$want_tcp2_path"; then
27941 PKG_CONFIG_LIBDIR="$want_tcp2_path"
27942 export PKG_CONFIG_LIBDIR
27943 fi
27944
27945 $PKGCONFIG --libs-only-l libngtcp2_crypto_openssl`
27946 { $as_echo "$as_me:${as_lineno-$LINENO}: -l is $LIB_NGTCP2_CRYPTO_OPENSSL" >&5
27947$as_echo "$as_me: -l is $LIB_NGTCP2_CRYPTO_OPENSSL" >&6;}
27948
27949 CPP_NGTCP2_CRYPTO_OPENSSL=`
27950 if test -n "$want_tcp2_path"; then
27951 PKG_CONFIG_LIBDIR="$want_tcp2_path"
27952 export PKG_CONFIG_LIBDIR
27953 fi
27954 $PKGCONFIG --cflags-only-I libngtcp2_crypto_openssl`
27955 { $as_echo "$as_me:${as_lineno-$LINENO}: -I is $CPP_NGTCP2_CRYPTO_OPENSSL" >&5
27956$as_echo "$as_me: -I is $CPP_NGTCP2_CRYPTO_OPENSSL" >&6;}
27957
27958 LD_NGTCP2_CRYPTO_OPENSSL=`
27959 if test -n "$want_tcp2_path"; then
27960 PKG_CONFIG_LIBDIR="$want_tcp2_path"
27961 export PKG_CONFIG_LIBDIR
27962 fi
27963
27964 $PKGCONFIG --libs-only-L libngtcp2_crypto_openssl`
27965 { $as_echo "$as_me:${as_lineno-$LINENO}: -L is $LD_NGTCP2_CRYPTO_OPENSSL" >&5
27966$as_echo "$as_me: -L is $LD_NGTCP2_CRYPTO_OPENSSL" >&6;}
27967
27968 LDFLAGS="$LDFLAGS $LD_NGTCP2_CRYPTO_OPENSSL"
27969 CPPFLAGS="$CPPFLAGS $CPP_NGTCP2_CRYPTO_OPENSSL"
27970 LIBS="$LIB_NGTCP2_CRYPTO_OPENSSL $LIBS"
27971
27972 if test "x$cross_compiling" != "xyes"; then
27973 DIR_NGTCP2_CRYPTO_OPENSSL=`echo $LD_NGTCP2_CRYPTO_OPENSSL | $SED -e 's/-L//'`
27974 fi
27975 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ngtcp2_crypto_ctx_initial in -lngtcp2_crypto_openssl" >&5
27976$as_echo_n "checking for ngtcp2_crypto_ctx_initial in -lngtcp2_crypto_openssl... " >&6; }
27977if ${ac_cv_lib_ngtcp2_crypto_openssl_ngtcp2_crypto_ctx_initial+:} false; then :
27978 $as_echo_n "(cached) " >&6
27979else
27980 ac_check_lib_save_LIBS=$LIBS
27981LIBS="-lngtcp2_crypto_openssl $LIBS"
27982cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27983/* end confdefs.h. */
27984
27985
27986#ifdef __cplusplus
27987extern "C"
27988#endif
27989char ngtcp2_crypto_ctx_initial ();
27990int main (void)
27991{
27992return ngtcp2_crypto_ctx_initial ();
27993 ;
27994 return 0;
27995}
27996_ACEOF
27997if ac_fn_c_try_link "$LINENO"; then :
27998 ac_cv_lib_ngtcp2_crypto_openssl_ngtcp2_crypto_ctx_initial=yes
27999else
28000 ac_cv_lib_ngtcp2_crypto_openssl_ngtcp2_crypto_ctx_initial=no
28001fi
28002rm -f core conftest.err conftest.$ac_objext \
28003 conftest$ac_exeext conftest.$ac_ext
28004LIBS=$ac_check_lib_save_LIBS
28005fi
28006{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ngtcp2_crypto_openssl_ngtcp2_crypto_ctx_initial" >&5
28007$as_echo "$ac_cv_lib_ngtcp2_crypto_openssl_ngtcp2_crypto_ctx_initial" >&6; }
28008if test "x$ac_cv_lib_ngtcp2_crypto_openssl_ngtcp2_crypto_ctx_initial" = xyes; then :
28009
28010 for ac_header in ngtcp2/ngtcp2_crypto.h
28011do :
28012 ac_fn_c_check_header_mongrel "$LINENO" "ngtcp2/ngtcp2_crypto.h" "ac_cv_header_ngtcp2_ngtcp2_crypto_h" "$ac_includes_default"
28013if test "x$ac_cv_header_ngtcp2_ngtcp2_crypto_h" = xyes; then :
28014 cat >>confdefs.h <<_ACEOF
28015#define HAVE_NGTCP2_NGTCP2_CRYPTO_H 1
28016_ACEOF
28017 NGTCP2_ENABLED=1
28018
28019$as_echo "#define USE_NGTCP2_CRYPTO_OPENSSL 1" >>confdefs.h
28020
28021 USE_NGTCP2_CRYPTO_OPENSSL=1
28022
28023 CURL_LIBRARY_PATH="$CURL_LIBRARY_PATH:$DIR_NGTCP2_CRYPTO_OPENSSL"
28024 export CURL_LIBRARY_PATH
28025 { $as_echo "$as_me:${as_lineno-$LINENO}: Added $DIR_NGTCP2_CRYPTO_OPENSSL to CURL_LIBRARY_PATH" >&5
28026$as_echo "$as_me: Added $DIR_NGTCP2_CRYPTO_OPENSSL to CURL_LIBRARY_PATH" >&6;}
28027
28028fi
28029
28030done
28031
28032
28033else
28034 LDFLAGS=$CLEANLDFLAGS
28035 CPPFLAGS=$CLEANCPPFLAGS
28036 LIBS=$CLEANLIBS
28037
28038fi
28039
28040
28041 else
28042 if test X"$want_tcp2" != Xdefault; then
28043 as_fn_error $? "--with-ngtcp2 was specified but could not find ngtcp2_crypto_openssl pkg-config file." "$LINENO" 5
28044 fi
28045 fi
28046fi
28047
28048
28049OPT_NGHTTP3="yes"
28050
28051if test "x$NGTCP2_ENABLED" = "x"; then
28052 # without ngtcp2, nghttp3 is of no use for us
28053 OPT_NGHTTP3="no"
28054fi
28055
28056
28057# Check whether --with-nghttp3 was given.
28058if test "${with_nghttp3+set}" = set; then :
28059 withval=$with_nghttp3; OPT_NGHTTP3=$withval
28060fi
28061
28062case "$OPT_NGHTTP3" in
28063 no)
28064 want_nghttp3="no"
28065 ;;
28066 yes)
28067 want_nghttp3="default"
28068 want_nghttp3_path=""
28069 ;;
28070 *)
28071 want_nghttp3="yes"
28072 want_nghttp3_path="$withval/lib/pkgconfig"
28073 ;;
28074esac
28075
28076curl_http3_msg="disabled (--with-nghttp3)"
28077if test X"$want_nghttp3" != Xno; then
28078 CLEANLDFLAGS="$LDFLAGS"
28079 CLEANCPPFLAGS="$CPPFLAGS"
28080 CLEANLIBS="$LIBS"
28081
28082
28083 if test -n "$PKG_CONFIG"; then
28084 PKGCONFIG="$PKG_CONFIG"
28085 else
28086 if test -n "$ac_tool_prefix"; then
28087 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
28088set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
28089{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
28090$as_echo_n "checking for $ac_word... " >&6; }
28091if ${ac_cv_path_PKGCONFIG+:} false; then :
28092 $as_echo_n "(cached) " >&6
28093else
28094 case $PKGCONFIG in
28095 [\\/]* | ?:[\\/]*)
28096 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
28097 ;;
28098 *)
28099 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28100as_dummy="$PATH:/usr/bin:/usr/local/bin"
28101for as_dir in $as_dummy
28102do
28103 IFS=$as_save_IFS
28104 test -z "$as_dir" && as_dir=.
28105 for ac_exec_ext in '' $ac_executable_extensions; do
28106 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
28107 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
28108 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
28109 break 2
28110 fi
28111done
28112 done
28113IFS=$as_save_IFS
28114
28115 ;;
28116esac
28117fi
28118PKGCONFIG=$ac_cv_path_PKGCONFIG
28119if test -n "$PKGCONFIG"; then
28120 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
28121$as_echo "$PKGCONFIG" >&6; }
28122else
28123 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28124$as_echo "no" >&6; }
28125fi
28126
28127
28128fi
28129if test -z "$ac_cv_path_PKGCONFIG"; then
28130 ac_pt_PKGCONFIG=$PKGCONFIG
28131 # Extract the first word of "pkg-config", so it can be a program name with args.
28132set dummy pkg-config; ac_word=$2
28133{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
28134$as_echo_n "checking for $ac_word... " >&6; }
28135if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
28136 $as_echo_n "(cached) " >&6
28137else
28138 case $ac_pt_PKGCONFIG in
28139 [\\/]* | ?:[\\/]*)
28140 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
28141 ;;
28142 *)
28143 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28144as_dummy="$PATH:/usr/bin:/usr/local/bin"
28145for as_dir in $as_dummy
28146do
28147 IFS=$as_save_IFS
28148 test -z "$as_dir" && as_dir=.
28149 for ac_exec_ext in '' $ac_executable_extensions; do
28150 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
28151 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
28152 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
28153 break 2
28154 fi
28155done
28156 done
28157IFS=$as_save_IFS
28158
28159 ;;
28160esac
28161fi
28162ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
28163if test -n "$ac_pt_PKGCONFIG"; then
28164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
28165$as_echo "$ac_pt_PKGCONFIG" >&6; }
28166else
28167 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28168$as_echo "no" >&6; }
28169fi
28170
28171 if test "x$ac_pt_PKGCONFIG" = x; then
28172 PKGCONFIG="no"
28173 else
28174 case $cross_compiling:$ac_tool_warned in
28175yes:)
28176{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
28177$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
28178ac_tool_warned=yes ;;
28179esac
28180 PKGCONFIG=$ac_pt_PKGCONFIG
28181 fi
28182else
28183 PKGCONFIG="$ac_cv_path_PKGCONFIG"
28184fi
28185
28186 fi
28187
28188 if test "x$PKGCONFIG" != "xno"; then
28189 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libnghttp3 options with pkg-config" >&5
28190$as_echo_n "checking for libnghttp3 options with pkg-config... " >&6; }
28191 itexists=`
28192 if test -n "$want_nghttp3_path"; then
28193 PKG_CONFIG_LIBDIR="$want_nghttp3_path"
28194 export PKG_CONFIG_LIBDIR
28195 fi
28196 $PKGCONFIG --exists libnghttp3 >/dev/null 2>&1 && echo 1`
28197
28198 if test -z "$itexists"; then
28199 PKGCONFIG="no"
28200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28201$as_echo "no" >&6; }
28202 else
28203 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
28204$as_echo "found" >&6; }
28205 fi
28206 fi
28207
28208
28209 if test "$PKGCONFIG" != "no" ; then
28210 LIB_NGHTTP3=`
28211 if test -n "$want_nghttp3_path"; then
28212 PKG_CONFIG_LIBDIR="$want_nghttp3_path"
28213 export PKG_CONFIG_LIBDIR
28214 fi
28215
28216 $PKGCONFIG --libs-only-l libnghttp3`
28217 { $as_echo "$as_me:${as_lineno-$LINENO}: -l is $LIB_NGHTTP3" >&5
28218$as_echo "$as_me: -l is $LIB_NGHTTP3" >&6;}
28219
28220 CPP_NGHTTP3=`
28221 if test -n "$want_nghttp3_path"; then
28222 PKG_CONFIG_LIBDIR="$want_nghttp3_path"
28223 export PKG_CONFIG_LIBDIR
28224 fi
28225 $PKGCONFIG --cflags-only-I libnghttp3`
28226 { $as_echo "$as_me:${as_lineno-$LINENO}: -I is $CPP_NGHTTP3" >&5
28227$as_echo "$as_me: -I is $CPP_NGHTTP3" >&6;}
28228
28229 LD_NGHTTP3=`
28230 if test -n "$want_nghttp3_path"; then
28231 PKG_CONFIG_LIBDIR="$want_nghttp3_path"
28232 export PKG_CONFIG_LIBDIR
28233 fi
28234
28235 $PKGCONFIG --libs-only-L libnghttp3`
28236 { $as_echo "$as_me:${as_lineno-$LINENO}: -L is $LD_NGHTTP3" >&5
28237$as_echo "$as_me: -L is $LD_NGHTTP3" >&6;}
28238
28239 LDFLAGS="$LDFLAGS $LD_NGHTTP3"
28240 CPPFLAGS="$CPPFLAGS $CPP_NGHTTP3"
28241 LIBS="$LIB_NGHTTP3 $LIBS"
28242
28243 if test "x$cross_compiling" != "xyes"; then
28244 DIR_NGHTTP3=`echo $LD_NGHTTP3 | $SED -e 's/-L//'`
28245 fi
28246 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nghttp3_conn_client_new in -lnghttp3" >&5
28247$as_echo_n "checking for nghttp3_conn_client_new in -lnghttp3... " >&6; }
28248if ${ac_cv_lib_nghttp3_nghttp3_conn_client_new+:} false; then :
28249 $as_echo_n "(cached) " >&6
28250else
28251 ac_check_lib_save_LIBS=$LIBS
28252LIBS="-lnghttp3 $LIBS"
28253cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28254/* end confdefs.h. */
28255
28256
28257#ifdef __cplusplus
28258extern "C"
28259#endif
28260char nghttp3_conn_client_new ();
28261int main (void)
28262{
28263return nghttp3_conn_client_new ();
28264 ;
28265 return 0;
28266}
28267_ACEOF
28268if ac_fn_c_try_link "$LINENO"; then :
28269 ac_cv_lib_nghttp3_nghttp3_conn_client_new=yes
28270else
28271 ac_cv_lib_nghttp3_nghttp3_conn_client_new=no
28272fi
28273rm -f core conftest.err conftest.$ac_objext \
28274 conftest$ac_exeext conftest.$ac_ext
28275LIBS=$ac_check_lib_save_LIBS
28276fi
28277{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nghttp3_nghttp3_conn_client_new" >&5
28278$as_echo "$ac_cv_lib_nghttp3_nghttp3_conn_client_new" >&6; }
28279if test "x$ac_cv_lib_nghttp3_nghttp3_conn_client_new" = xyes; then :
28280
28281 for ac_header in nghttp3/nghttp3.h
28282do :
28283 ac_fn_c_check_header_mongrel "$LINENO" "nghttp3/nghttp3.h" "ac_cv_header_nghttp3_nghttp3_h" "$ac_includes_default"
28284if test "x$ac_cv_header_nghttp3_nghttp3_h" = xyes; then :
28285 cat >>confdefs.h <<_ACEOF
28286#define HAVE_NGHTTP3_NGHTTP3_H 1
28287_ACEOF
28288 curl_h3_msg="enabled (ngtcp2 + nghttp3)"
28289 NGHTTP3_ENABLED=1
28290
28291$as_echo "#define USE_NGHTTP3 1" >>confdefs.h
28292
28293 USE_NGHTTP3=1
28294
28295 CURL_LIBRARY_PATH="$CURL_LIBRARY_PATH:$DIR_NGHTTP3"
28296 export CURL_LIBRARY_PATH
28297 { $as_echo "$as_me:${as_lineno-$LINENO}: Added $DIR_NGHTTP3 to CURL_LIBRARY_PATH" >&5
28298$as_echo "$as_me: Added $DIR_NGHTTP3 to CURL_LIBRARY_PATH" >&6;}
28299 experimental="$experimental HTTP3"
28300
28301fi
28302
28303done
28304
28305
28306else
28307 LDFLAGS=$CLEANLDFLAGS
28308 CPPFLAGS=$CLEANCPPFLAGS
28309 LIBS=$CLEANLIBS
28310
28311fi
28312
28313
28314 else
28315 if test X"$want_nghttp3" != Xdefault; then
28316 as_fn_error $? "--with-nghttp3 was specified but could not find nghttp3 pkg-config file." "$LINENO" 5
28317 fi
28318 fi
28319
28320fi
28321
28322
28323OPT_QUICHE="yes"
28324
28325if test "x$disable_http" = "xyes" -o "x$USE_NGTCP" = "x1"; then
28326 # without HTTP or with ngtcp2, quiche is no use
28327 OPT_QUICHE="no"
28328fi
28329
28330
28331# Check whether --with-quiche was given.
28332if test "${with_quiche+set}" = set; then :
28333 withval=$with_quiche; OPT_QUICHE=$withval
28334fi
28335
28336case "$OPT_QUICHE" in
28337 no)
28338 want_quiche="no"
28339 ;;
28340 yes)
28341 want_quiche="default"
28342 want_quiche_path=""
28343 ;;
28344 *)
28345 want_quiche="yes"
28346 want_quiche_path="$withval"
28347 ;;
28348esac
28349
28350if test X"$want_quiche" != Xno; then
28351 CLEANLDFLAGS="$LDFLAGS"
28352 CLEANCPPFLAGS="$CPPFLAGS"
28353 CLEANLIBS="$LIBS"
28354
28355
28356 if test -n "$PKG_CONFIG"; then
28357 PKGCONFIG="$PKG_CONFIG"
28358 else
28359 if test -n "$ac_tool_prefix"; then
28360 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
28361set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
28362{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
28363$as_echo_n "checking for $ac_word... " >&6; }
28364if ${ac_cv_path_PKGCONFIG+:} false; then :
28365 $as_echo_n "(cached) " >&6
28366else
28367 case $PKGCONFIG in
28368 [\\/]* | ?:[\\/]*)
28369 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
28370 ;;
28371 *)
28372 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28373as_dummy="$PATH:/usr/bin:/usr/local/bin"
28374for as_dir in $as_dummy
28375do
28376 IFS=$as_save_IFS
28377 test -z "$as_dir" && as_dir=.
28378 for ac_exec_ext in '' $ac_executable_extensions; do
28379 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
28380 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
28381 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
28382 break 2
28383 fi
28384done
28385 done
28386IFS=$as_save_IFS
28387
28388 ;;
28389esac
28390fi
28391PKGCONFIG=$ac_cv_path_PKGCONFIG
28392if test -n "$PKGCONFIG"; then
28393 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
28394$as_echo "$PKGCONFIG" >&6; }
28395else
28396 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28397$as_echo "no" >&6; }
28398fi
28399
28400
28401fi
28402if test -z "$ac_cv_path_PKGCONFIG"; then
28403 ac_pt_PKGCONFIG=$PKGCONFIG
28404 # Extract the first word of "pkg-config", so it can be a program name with args.
28405set dummy pkg-config; ac_word=$2
28406{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
28407$as_echo_n "checking for $ac_word... " >&6; }
28408if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
28409 $as_echo_n "(cached) " >&6
28410else
28411 case $ac_pt_PKGCONFIG in
28412 [\\/]* | ?:[\\/]*)
28413 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
28414 ;;
28415 *)
28416 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28417as_dummy="$PATH:/usr/bin:/usr/local/bin"
28418for as_dir in $as_dummy
28419do
28420 IFS=$as_save_IFS
28421 test -z "$as_dir" && as_dir=.
28422 for ac_exec_ext in '' $ac_executable_extensions; do
28423 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
28424 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
28425 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
28426 break 2
28427 fi
28428done
28429 done
28430IFS=$as_save_IFS
28431
28432 ;;
28433esac
28434fi
28435ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
28436if test -n "$ac_pt_PKGCONFIG"; then
28437 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
28438$as_echo "$ac_pt_PKGCONFIG" >&6; }
28439else
28440 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28441$as_echo "no" >&6; }
28442fi
28443
28444 if test "x$ac_pt_PKGCONFIG" = x; then
28445 PKGCONFIG="no"
28446 else
28447 case $cross_compiling:$ac_tool_warned in
28448yes:)
28449{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
28450$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
28451ac_tool_warned=yes ;;
28452esac
28453 PKGCONFIG=$ac_pt_PKGCONFIG
28454 fi
28455else
28456 PKGCONFIG="$ac_cv_path_PKGCONFIG"
28457fi
28458
28459 fi
28460
28461 if test "x$PKGCONFIG" != "xno"; then
28462 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for quiche options with pkg-config" >&5
28463$as_echo_n "checking for quiche options with pkg-config... " >&6; }
28464 itexists=`
28465 if test -n "$want_quiche_path"; then
28466 PKG_CONFIG_LIBDIR="$want_quiche_path"
28467 export PKG_CONFIG_LIBDIR
28468 fi
28469 $PKGCONFIG --exists quiche >/dev/null 2>&1 && echo 1`
28470
28471 if test -z "$itexists"; then
28472 PKGCONFIG="no"
28473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28474$as_echo "no" >&6; }
28475 else
28476 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
28477$as_echo "found" >&6; }
28478 fi
28479 fi
28480
28481
28482 if test "$PKGCONFIG" != "no" ; then
28483 LIB_QUICHE=`
28484 if test -n "$want_quiche_path"; then
28485 PKG_CONFIG_LIBDIR="$want_quiche_path"
28486 export PKG_CONFIG_LIBDIR
28487 fi
28488
28489 $PKGCONFIG --libs-only-l quiche`
28490 { $as_echo "$as_me:${as_lineno-$LINENO}: -l is $LIB_QUICHE" >&5
28491$as_echo "$as_me: -l is $LIB_QUICHE" >&6;}
28492
28493 CPP_QUICHE=`
28494 if test -n "$want_quiche_path"; then
28495 PKG_CONFIG_LIBDIR="$want_quiche_path"
28496 export PKG_CONFIG_LIBDIR
28497 fi
28498 $PKGCONFIG --cflags-only-I quiche`
28499 { $as_echo "$as_me:${as_lineno-$LINENO}: -I is $CPP_QUICHE" >&5
28500$as_echo "$as_me: -I is $CPP_QUICHE" >&6;}
28501
28502 LD_QUICHE=`
28503 if test -n "$want_quiche_path"; then
28504 PKG_CONFIG_LIBDIR="$want_quiche_path"
28505 export PKG_CONFIG_LIBDIR
28506 fi
28507
28508 $PKGCONFIG --libs-only-L quiche`
28509 { $as_echo "$as_me:${as_lineno-$LINENO}: -L is $LD_QUICHE" >&5
28510$as_echo "$as_me: -L is $LD_QUICHE" >&6;}
28511
28512 LDFLAGS="$LDFLAGS $LD_QUICHE"
28513 CPPFLAGS="$CPPFLAGS $CPP_QUICHE"
28514 LIBS="$LIB_QUICHE $LIBS"
28515
28516 if test "x$cross_compiling" != "xyes"; then
28517 DIR_QUICHE=`echo $LD_QUICHE | $SED -e 's/-L//'`
28518 fi
28519 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for quiche_connect in -lquiche" >&5
28520$as_echo_n "checking for quiche_connect in -lquiche... " >&6; }
28521if ${ac_cv_lib_quiche_quiche_connect+:} false; then :
28522 $as_echo_n "(cached) " >&6
28523else
28524 ac_check_lib_save_LIBS=$LIBS
28525LIBS="-lquiche $LIBS"
28526cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28527/* end confdefs.h. */
28528
28529
28530#ifdef __cplusplus
28531extern "C"
28532#endif
28533char quiche_connect ();
28534int main (void)
28535{
28536return quiche_connect ();
28537 ;
28538 return 0;
28539}
28540_ACEOF
28541if ac_fn_c_try_link "$LINENO"; then :
28542 ac_cv_lib_quiche_quiche_connect=yes
28543else
28544 ac_cv_lib_quiche_quiche_connect=no
28545fi
28546rm -f core conftest.err conftest.$ac_objext \
28547 conftest$ac_exeext conftest.$ac_ext
28548LIBS=$ac_check_lib_save_LIBS
28549fi
28550{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_quiche_quiche_connect" >&5
28551$as_echo "$ac_cv_lib_quiche_quiche_connect" >&6; }
28552if test "x$ac_cv_lib_quiche_quiche_connect" = xyes; then :
28553
28554 for ac_header in quiche.h
28555do :
28556 ac_fn_c_check_header_mongrel "$LINENO" "quiche.h" "ac_cv_header_quiche_h" "$ac_includes_default"
28557if test "x$ac_cv_header_quiche_h" = xyes; then :
28558 cat >>confdefs.h <<_ACEOF
28559#define HAVE_QUICHE_H 1
28560_ACEOF
28561 experimental="$experimental HTTP3"
28562 { $as_echo "$as_me:${as_lineno-$LINENO}: HTTP3 support is experimental" >&5
28563$as_echo "$as_me: HTTP3 support is experimental" >&6;}
28564 curl_h3_msg="enabled (quiche)"
28565 QUICHE_ENABLED=1
28566
28567$as_echo "#define USE_QUICHE 1" >>confdefs.h
28568
28569 USE_QUICHE=1
28570
28571 CURL_LIBRARY_PATH="$CURL_LIBRARY_PATH:$DIR_QUICHE"
28572 export CURL_LIBRARY_PATH
28573 { $as_echo "$as_me:${as_lineno-$LINENO}: Added $DIR_QUICHE to CURL_LIBRARY_PATH" >&5
28574$as_echo "$as_me: Added $DIR_QUICHE to CURL_LIBRARY_PATH" >&6;}
28575fi
28576
28577done
28578
28579
28580else
28581 LDFLAGS=$CLEANLDFLAGS
28582 CPPFLAGS=$CLEANCPPFLAGS
28583 LIBS=$CLEANLIBS
28584
28585fi
28586
28587 else
28588 if test X"$want_quiche" != Xdefault; then
28589 as_fn_error $? "--with-quiche was specified but could not find quiche pkg-config file." "$LINENO" 5
28590 fi
28591 fi
28592fi
28593
28594
Elliott Hughes82be86d2017-09-20 17:00:17 -070028595OPT_ZSH_FPATH=default
28596
28597# Check whether --with-zsh-functions-dir was given.
28598if test "${with_zsh_functions_dir+set}" = set; then :
28599 withval=$with_zsh_functions_dir; OPT_ZSH_FPATH=$withval
28600fi
28601
28602case "$OPT_ZSH_FPATH" in
28603 no)
28604 ;;
28605 default|yes)
28606 ZSH_FUNCTIONS_DIR="$datarootdir/zsh/site-functions"
28607
28608 ;;
28609 *)
28610 ZSH_FUNCTIONS_DIR="$withval"
28611
28612 ;;
28613esac
28614
28615
Haibo Huang65021c72019-03-27 15:37:23 -070028616OPT_FISH_FPATH=default
28617
28618# Check whether --with-fish-functions-dir was given.
28619if test "${with_fish_functions_dir+set}" = set; then :
28620 withval=$with_fish_functions_dir; OPT_FISH_FPATH=$withval
28621fi
28622
28623case "$OPT_FISH_FPATH" in
28624 no)
28625 ;;
28626 default|yes)
Haibo Huang34ab3462019-05-22 00:50:27 -070028627
28628 if test -n "$PKG_CONFIG"; then
28629 PKGCONFIG="$PKG_CONFIG"
28630 else
28631 if test -n "$ac_tool_prefix"; then
28632 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
28633set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
28634{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
28635$as_echo_n "checking for $ac_word... " >&6; }
28636if ${ac_cv_path_PKGCONFIG+:} false; then :
28637 $as_echo_n "(cached) " >&6
28638else
28639 case $PKGCONFIG in
28640 [\\/]* | ?:[\\/]*)
28641 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
28642 ;;
28643 *)
28644 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28645as_dummy="$PATH:/usr/bin:/usr/local/bin"
28646for as_dir in $as_dummy
28647do
28648 IFS=$as_save_IFS
28649 test -z "$as_dir" && as_dir=.
28650 for ac_exec_ext in '' $ac_executable_extensions; do
28651 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
28652 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
28653 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
28654 break 2
28655 fi
28656done
28657 done
28658IFS=$as_save_IFS
28659
28660 ;;
28661esac
28662fi
28663PKGCONFIG=$ac_cv_path_PKGCONFIG
28664if test -n "$PKGCONFIG"; then
28665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
28666$as_echo "$PKGCONFIG" >&6; }
28667else
28668 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28669$as_echo "no" >&6; }
28670fi
28671
28672
28673fi
28674if test -z "$ac_cv_path_PKGCONFIG"; then
28675 ac_pt_PKGCONFIG=$PKGCONFIG
28676 # Extract the first word of "pkg-config", so it can be a program name with args.
28677set dummy pkg-config; ac_word=$2
28678{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
28679$as_echo_n "checking for $ac_word... " >&6; }
28680if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
28681 $as_echo_n "(cached) " >&6
28682else
28683 case $ac_pt_PKGCONFIG in
28684 [\\/]* | ?:[\\/]*)
28685 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
28686 ;;
28687 *)
28688 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28689as_dummy="$PATH:/usr/bin:/usr/local/bin"
28690for as_dir in $as_dummy
28691do
28692 IFS=$as_save_IFS
28693 test -z "$as_dir" && as_dir=.
28694 for ac_exec_ext in '' $ac_executable_extensions; do
28695 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
28696 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
28697 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
28698 break 2
28699 fi
28700done
28701 done
28702IFS=$as_save_IFS
28703
28704 ;;
28705esac
28706fi
28707ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
28708if test -n "$ac_pt_PKGCONFIG"; then
28709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
28710$as_echo "$ac_pt_PKGCONFIG" >&6; }
28711else
28712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28713$as_echo "no" >&6; }
28714fi
28715
28716 if test "x$ac_pt_PKGCONFIG" = x; then
28717 PKGCONFIG="no"
28718 else
28719 case $cross_compiling:$ac_tool_warned in
28720yes:)
28721{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
28722$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
28723ac_tool_warned=yes ;;
28724esac
28725 PKGCONFIG=$ac_pt_PKGCONFIG
28726 fi
28727else
28728 PKGCONFIG="$ac_cv_path_PKGCONFIG"
28729fi
28730
28731 fi
28732
28733 if test "x$PKGCONFIG" != "xno"; then
28734 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fish options with pkg-config" >&5
28735$as_echo_n "checking for fish options with pkg-config... " >&6; }
28736 itexists=`
28737 if test -n ""; then
28738 PKG_CONFIG_LIBDIR=""
28739 export PKG_CONFIG_LIBDIR
28740 fi
28741 $PKGCONFIG --exists fish >/dev/null 2>&1 && echo 1`
28742
28743 if test -z "$itexists"; then
28744 PKGCONFIG="no"
28745 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28746$as_echo "no" >&6; }
28747 else
28748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
28749$as_echo "found" >&6; }
28750 fi
28751 fi
28752
28753 if test "$PKGCONFIG" != "no" ; then
28754 FISH_FUNCTIONS_DIR="$($PKGCONFIG --variable completionsdir fish)"
28755 else
28756 FISH_FUNCTIONS_DIR="$datarootdir/fish/vendor_completions.d"
28757 fi
Haibo Huang65021c72019-03-27 15:37:23 -070028758
28759 ;;
28760 *)
28761 FISH_FUNCTIONS_DIR="$withval"
28762
28763 ;;
28764esac
28765
28766
Elliott Hughes82be86d2017-09-20 17:00:17 -070028767{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
28768$as_echo_n "checking for ANSI C header files... " >&6; }
28769if ${ac_cv_header_stdc+:} false; then :
28770 $as_echo_n "(cached) " >&6
28771else
28772 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28773/* end confdefs.h. */
28774#include <stdlib.h>
28775#include <stdarg.h>
28776#include <string.h>
28777#include <float.h>
28778
28779int main (void)
28780{
28781
28782 ;
28783 return 0;
28784}
28785_ACEOF
28786if ac_fn_c_try_compile "$LINENO"; then :
28787 ac_cv_header_stdc=yes
28788else
28789 ac_cv_header_stdc=no
28790fi
28791rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28792
28793if test $ac_cv_header_stdc = yes; then
28794 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
28795 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28796/* end confdefs.h. */
28797#include <string.h>
28798
28799_ACEOF
28800if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
28801 $EGREP "memchr" >/dev/null 2>&1; then :
28802
28803else
28804 ac_cv_header_stdc=no
28805fi
28806rm -f conftest*
28807
28808fi
28809
28810if test $ac_cv_header_stdc = yes; then
28811 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
28812 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28813/* end confdefs.h. */
28814#include <stdlib.h>
28815
28816_ACEOF
28817if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
28818 $EGREP "free" >/dev/null 2>&1; then :
28819
28820else
28821 ac_cv_header_stdc=no
28822fi
28823rm -f conftest*
28824
28825fi
28826
28827if test $ac_cv_header_stdc = yes; then
28828 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
28829 if test "$cross_compiling" = yes; then :
28830 :
28831else
28832 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28833/* end confdefs.h. */
28834#include <ctype.h>
28835#include <stdlib.h>
28836#if ((' ' & 0x0FF) == 0x020)
28837# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
28838# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
28839#else
28840# define ISLOWER(c) \
28841 (('a' <= (c) && (c) <= 'i') \
28842 || ('j' <= (c) && (c) <= 'r') \
28843 || ('s' <= (c) && (c) <= 'z'))
28844# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
28845#endif
28846
28847#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
28848int
28849main ()
28850{
28851 int i;
28852 for (i = 0; i < 256; i++)
28853 if (XOR (islower (i), ISLOWER (i))
28854 || toupper (i) != TOUPPER (i))
28855 return 2;
28856 return 0;
28857}
28858_ACEOF
28859if ac_fn_c_try_run "$LINENO"; then :
28860
28861else
28862 ac_cv_header_stdc=no
28863fi
28864rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28865 conftest.$ac_objext conftest.beam conftest.$ac_ext
28866fi
28867
28868fi
28869fi
28870{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
28871$as_echo "$ac_cv_header_stdc" >&6; }
28872if test $ac_cv_header_stdc = yes; then
28873
28874$as_echo "#define STDC_HEADERS 1" >>confdefs.h
28875
28876fi
28877
28878
28879
28880 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for malloc.h" >&5
28881$as_echo_n "checking for malloc.h... " >&6; }
28882if ${curl_cv_header_malloc_h+:} false; then :
28883 $as_echo_n "(cached) " >&6
28884else
28885
28886 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28887/* end confdefs.h. */
28888
28889
28890#include <malloc.h>
28891
28892int main (void)
28893{
28894
28895 void *p = malloc(10);
28896 void *q = calloc(10,10);
28897 free(p);
28898 free(q);
28899
28900 ;
28901 return 0;
28902}
28903
28904_ACEOF
28905if ac_fn_c_try_compile "$LINENO"; then :
28906
28907 curl_cv_header_malloc_h="yes"
28908
28909else
28910
28911 curl_cv_header_malloc_h="no"
28912
28913fi
28914rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28915
28916fi
28917{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_malloc_h" >&5
28918$as_echo "$curl_cv_header_malloc_h" >&6; }
28919 if test "$curl_cv_header_malloc_h" = "yes"; then
28920
28921cat >>confdefs.h <<_ACEOF
28922#define HAVE_MALLOC_H 1
28923_ACEOF
28924
28925 #
28926 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28927/* end confdefs.h. */
28928
28929
28930#include <stdlib.h>
28931
28932int main (void)
28933{
28934
28935 void *p = malloc(10);
28936 void *q = calloc(10,10);
28937 free(p);
28938 free(q);
28939
28940 ;
28941 return 0;
28942}
28943
28944_ACEOF
28945if ac_fn_c_try_compile "$LINENO"; then :
28946
28947 curl_cv_need_header_malloc_h="no"
28948
28949else
28950
28951 curl_cv_need_header_malloc_h="yes"
28952
28953fi
28954rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28955 #
28956 case "$curl_cv_need_header_malloc_h" in
28957 yes)
28958
28959cat >>confdefs.h <<_ACEOF
28960#define NEED_MALLOC_H 1
28961_ACEOF
28962
28963 ;;
28964 esac
28965 fi
28966
28967
28968 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for memory.h" >&5
28969$as_echo_n "checking for memory.h... " >&6; }
28970if ${curl_cv_header_memory_h+:} false; then :
28971 $as_echo_n "(cached) " >&6
28972else
28973
28974 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28975/* end confdefs.h. */
28976
28977
28978#include <memory.h>
28979
28980int main (void)
28981{
28982
28983 void *p = malloc(10);
28984 void *q = calloc(10,10);
28985 free(p);
28986 free(q);
28987
28988 ;
28989 return 0;
28990}
28991
28992_ACEOF
28993if ac_fn_c_try_compile "$LINENO"; then :
28994
28995 curl_cv_header_memory_h="yes"
28996
28997else
28998
28999 curl_cv_header_memory_h="no"
29000
29001fi
29002rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29003
29004fi
29005{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_memory_h" >&5
29006$as_echo "$curl_cv_header_memory_h" >&6; }
29007 if test "$curl_cv_header_memory_h" = "yes"; then
29008
29009cat >>confdefs.h <<_ACEOF
29010#define HAVE_MEMORY_H 1
29011_ACEOF
29012
29013 #
29014 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29015/* end confdefs.h. */
29016
29017
29018#include <stdlib.h>
29019
29020int main (void)
29021{
29022
29023 void *p = malloc(10);
29024 void *q = calloc(10,10);
29025 free(p);
29026 free(q);
29027
29028 ;
29029 return 0;
29030}
29031
29032_ACEOF
29033if ac_fn_c_try_compile "$LINENO"; then :
29034
29035 curl_cv_need_header_memory_h="no"
29036
29037else
29038
29039 curl_cv_need_header_memory_h="yes"
29040
29041fi
29042rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29043 #
29044 case "$curl_cv_need_header_memory_h" in
29045 yes)
29046
29047cat >>confdefs.h <<_ACEOF
29048#define NEED_MEMORY_H 1
29049_ACEOF
29050
29051 ;;
29052 esac
29053 fi
29054
29055
29056for ac_header in sys/types.h \
29057 sys/time.h \
29058 sys/select.h \
29059 sys/socket.h \
29060 sys/ioctl.h \
29061 sys/uio.h \
29062 assert.h \
29063 unistd.h \
29064 stdlib.h \
Elliott Hughes82be86d2017-09-20 17:00:17 -070029065 arpa/inet.h \
29066 net/if.h \
29067 netinet/in.h \
Elliott Hughes0128fe42018-02-27 14:57:55 -080029068 netinet/in6.h \
Elliott Hughes82be86d2017-09-20 17:00:17 -070029069 sys/un.h \
Alex Deymo486467e2017-12-19 19:04:07 +010029070 linux/tcp.h \
Elliott Hughes82be86d2017-09-20 17:00:17 -070029071 netinet/tcp.h \
29072 netdb.h \
29073 sys/sockio.h \
29074 sys/stat.h \
29075 sys/param.h \
29076 termios.h \
29077 termio.h \
29078 sgtty.h \
29079 fcntl.h \
29080 alloca.h \
29081 time.h \
29082 io.h \
29083 pwd.h \
29084 utime.h \
29085 sys/utime.h \
29086 sys/poll.h \
29087 poll.h \
29088 socket.h \
29089 sys/resource.h \
29090 libgen.h \
29091 locale.h \
29092 errno.h \
29093 stdbool.h \
29094 arpa/tftp.h \
29095 sys/filio.h \
29096 sys/wait.h \
29097 setjmp.h
29098do :
29099 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
29100ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "
29101#ifdef HAVE_SYS_TYPES_H
29102#include <sys/types.h>
29103#endif
29104#ifdef HAVE_SYS_TIME_H
29105#include <sys/time.h>
29106#endif
29107#ifdef HAVE_SYS_SELECT_H
29108#include <sys/select.h>
29109#endif
29110#ifdef HAVE_SYS_SOCKET_H
29111#include <sys/socket.h>
29112#endif
29113#ifdef HAVE_NETINET_IN_H
29114#include <netinet/in.h>
29115#endif
Elliott Hughes0128fe42018-02-27 14:57:55 -080029116#ifdef HAVE_NETINET_IN6_H
29117#include <netinet/in6.h>
29118#endif
Elliott Hughes82be86d2017-09-20 17:00:17 -070029119#ifdef HAVE_SYS_UN_H
29120#include <sys/un.h>
29121#endif
29122
29123
29124"
29125if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
29126 cat >>confdefs.h <<_ACEOF
29127#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
29128_ACEOF
29129
29130fi
29131
29132done
29133
29134
Haibo Huang65021c72019-03-27 15:37:23 -070029135
Elliott Hughes82be86d2017-09-20 17:00:17 -070029136{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
29137$as_echo_n "checking for an ANSI C-conforming const... " >&6; }
29138if ${ac_cv_c_const+:} false; then :
29139 $as_echo_n "(cached) " >&6
29140else
29141 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29142/* end confdefs.h. */
29143
29144int main (void)
29145{
29146
29147#ifndef __cplusplus
29148 /* Ultrix mips cc rejects this sort of thing. */
29149 typedef int charset[2];
29150 const charset cs = { 0, 0 };
29151 /* SunOS 4.1.1 cc rejects this. */
29152 char const *const *pcpcc;
29153 char **ppc;
29154 /* NEC SVR4.0.2 mips cc rejects this. */
29155 struct point {int x, y;};
29156 static struct point const zero = {0,0};
29157 /* AIX XL C 1.02.0.0 rejects this.
29158 It does not let you subtract one const X* pointer from another in
29159 an arm of an if-expression whose if-part is not a constant
29160 expression */
29161 const char *g = "string";
29162 pcpcc = &g + (g ? g-g : 0);
29163 /* HPUX 7.0 cc rejects these. */
29164 ++pcpcc;
29165 ppc = (char**) pcpcc;
29166 pcpcc = (char const *const *) ppc;
29167 { /* SCO 3.2v4 cc rejects this sort of thing. */
29168 char tx;
29169 char *t = &tx;
29170 char const *s = 0 ? (char *) 0 : (char const *) 0;
29171
29172 *t++ = 0;
29173 if (s) return 0;
29174 }
29175 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
29176 int x[] = {25, 17};
29177 const int *foo = &x[0];
29178 ++foo;
29179 }
29180 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
29181 typedef const int *iptr;
29182 iptr p = 0;
29183 ++p;
29184 }
29185 { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying
29186 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
29187 struct s { int j; const int *ap[3]; } bx;
29188 struct s *b = &bx; b->j = 5;
29189 }
29190 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
29191 const int foo = 10;
29192 if (!foo) return 0;
29193 }
29194 return !cs[0] && !zero.x;
29195#endif
29196
29197 ;
29198 return 0;
29199}
29200_ACEOF
29201if ac_fn_c_try_compile "$LINENO"; then :
29202 ac_cv_c_const=yes
29203else
29204 ac_cv_c_const=no
29205fi
29206rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29207fi
29208{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
29209$as_echo "$ac_cv_c_const" >&6; }
29210if test $ac_cv_c_const = no; then
29211
29212$as_echo "#define const /**/" >>confdefs.h
29213
29214fi
29215
29216
29217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compiler support of C99 variadic macro style" >&5
29218$as_echo_n "checking for compiler support of C99 variadic macro style... " >&6; }
29219if ${curl_cv_variadic_macros_c99+:} false; then :
29220 $as_echo_n "(cached) " >&6
29221else
29222
29223 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29224/* end confdefs.h. */
29225
29226
29227#define c99_vmacro3(first, ...) fun3(first, __VA_ARGS__)
29228#define c99_vmacro2(first, ...) fun2(first, __VA_ARGS__)
29229 int fun3(int arg1, int arg2, int arg3);
29230 int fun2(int arg1, int arg2);
29231 int fun3(int arg1, int arg2, int arg3)
29232 { return arg1 + arg2 + arg3; }
29233 int fun2(int arg1, int arg2)
29234 { return arg1 + arg2; }
29235
29236int main (void)
29237{
29238
29239 int res3 = c99_vmacro3(1, 2, 3);
29240 int res2 = c99_vmacro2(1, 2);
29241
29242 ;
29243 return 0;
29244}
29245
29246_ACEOF
29247if ac_fn_c_try_compile "$LINENO"; then :
29248
29249 curl_cv_variadic_macros_c99="yes"
29250
29251else
29252
29253 curl_cv_variadic_macros_c99="no"
29254
29255fi
29256rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29257
29258fi
29259{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_variadic_macros_c99" >&5
29260$as_echo "$curl_cv_variadic_macros_c99" >&6; }
29261 case "$curl_cv_variadic_macros_c99" in
29262 yes)
29263
29264cat >>confdefs.h <<_ACEOF
29265#define HAVE_VARIADIC_MACROS_C99 1
29266_ACEOF
29267
29268 ;;
29269 esac
29270 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compiler support of old gcc variadic macro style" >&5
29271$as_echo_n "checking for compiler support of old gcc variadic macro style... " >&6; }
29272if ${curl_cv_variadic_macros_gcc+:} false; then :
29273 $as_echo_n "(cached) " >&6
29274else
29275
29276 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29277/* end confdefs.h. */
29278
29279
29280#define gcc_vmacro3(first, args...) fun3(first, args)
29281#define gcc_vmacro2(first, args...) fun2(first, args)
29282 int fun3(int arg1, int arg2, int arg3);
29283 int fun2(int arg1, int arg2);
29284 int fun3(int arg1, int arg2, int arg3)
29285 { return arg1 + arg2 + arg3; }
29286 int fun2(int arg1, int arg2)
29287 { return arg1 + arg2; }
29288
29289int main (void)
29290{
29291
29292 int res3 = gcc_vmacro3(1, 2, 3);
29293 int res2 = gcc_vmacro2(1, 2);
29294
29295 ;
29296 return 0;
29297}
29298
29299_ACEOF
29300if ac_fn_c_try_compile "$LINENO"; then :
29301
29302 curl_cv_variadic_macros_gcc="yes"
29303
29304else
29305
29306 curl_cv_variadic_macros_gcc="no"
29307
29308fi
29309rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29310
29311fi
29312{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_variadic_macros_gcc" >&5
29313$as_echo "$curl_cv_variadic_macros_gcc" >&6; }
29314 case "$curl_cv_variadic_macros_gcc" in
29315 yes)
29316
29317cat >>confdefs.h <<_ACEOF
29318#define HAVE_VARIADIC_MACROS_GCC 1
29319_ACEOF
29320
29321 ;;
29322 esac
29323
29324ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
29325if test "x$ac_cv_type_size_t" = xyes; then :
29326
29327else
29328
29329cat >>confdefs.h <<_ACEOF
29330#define size_t unsigned int
29331_ACEOF
29332
29333fi
29334
29335{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
29336$as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
29337if ${ac_cv_header_time+:} false; then :
29338 $as_echo_n "(cached) " >&6
29339else
29340 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29341/* end confdefs.h. */
29342#include <sys/types.h>
29343#include <sys/time.h>
29344#include <time.h>
29345
29346int main (void)
29347{
29348if ((struct tm *) 0)
29349return 0;
29350 ;
29351 return 0;
29352}
29353_ACEOF
29354if ac_fn_c_try_compile "$LINENO"; then :
29355 ac_cv_header_time=yes
29356else
29357 ac_cv_header_time=no
29358fi
29359rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29360fi
29361{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
29362$as_echo "$ac_cv_header_time" >&6; }
29363if test $ac_cv_header_time = yes; then
29364
29365$as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
29366
29367fi
29368
29369
29370 for ac_header in sys/types.h sys/time.h time.h sys/socket.h
29371do :
29372 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
29373ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
29374if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
29375 cat >>confdefs.h <<_ACEOF
29376#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
29377_ACEOF
29378
29379fi
29380
29381done
29382
29383 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
29384$as_echo_n "checking for struct timeval... " >&6; }
29385if ${curl_cv_struct_timeval+:} false; then :
29386 $as_echo_n "(cached) " >&6
29387else
29388
29389 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29390/* end confdefs.h. */
29391
29392
29393#undef inline
29394#ifdef HAVE_WINDOWS_H
29395#ifndef WIN32_LEAN_AND_MEAN
29396#define WIN32_LEAN_AND_MEAN
29397#endif
29398#include <windows.h>
29399#ifdef HAVE_WINSOCK2_H
29400#include <winsock2.h>
29401#else
29402#ifdef HAVE_WINSOCK_H
29403#include <winsock.h>
29404#endif
29405#endif
29406#endif
29407#ifdef HAVE_SYS_TYPES_H
29408#include <sys/types.h>
29409#endif
29410#ifdef HAVE_SYS_TIME_H
29411#include <sys/time.h>
29412#ifdef TIME_WITH_SYS_TIME
29413#include <time.h>
29414#endif
29415#else
29416#ifdef HAVE_TIME_H
29417#include <time.h>
29418#endif
29419#endif
29420#ifdef HAVE_SYS_SOCKET_H
29421#include <sys/socket.h>
29422#endif
29423
29424int main (void)
29425{
29426
29427 struct timeval ts;
29428 ts.tv_sec = 0;
29429 ts.tv_usec = 0;
29430
29431 ;
29432 return 0;
29433}
29434
29435_ACEOF
29436if ac_fn_c_try_compile "$LINENO"; then :
29437
29438 curl_cv_struct_timeval="yes"
29439
29440else
29441
29442 curl_cv_struct_timeval="no"
29443
29444fi
29445rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29446
29447fi
29448{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_struct_timeval" >&5
29449$as_echo "$curl_cv_struct_timeval" >&6; }
29450 case "$curl_cv_struct_timeval" in
29451 yes)
29452
29453cat >>confdefs.h <<_ACEOF
29454#define HAVE_STRUCT_TIMEVAL 1
29455_ACEOF
29456
29457 ;;
29458 esac
29459
29460
29461
29462 if test "x$cross_compiling" != xyes; then
29463
29464 { $as_echo "$as_me:${as_lineno-$LINENO}: checking run-time libs availability" >&5
29465$as_echo_n "checking run-time libs availability... " >&6; }
Elliott Hughes72d948d2018-08-03 14:37:21 -070029466
29467
29468 old=$LD_LIBRARY_PATH
29469 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
29470 export LD_LIBRARY_PATH
29471 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070029472 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
29473$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
29474as_fn_error $? "cannot run test program while cross compiling
29475See \`config.log' for more details" "$LINENO" 5; }
29476else
29477 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29478/* end confdefs.h. */
29479
Elliott Hughesb1ef70f2018-10-30 11:28:38 -070029480int main()
Elliott Hughes82be86d2017-09-20 17:00:17 -070029481{
29482 return 0;
29483}
29484
29485_ACEOF
29486if ac_fn_c_try_run "$LINENO"; then :
29487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: fine" >&5
29488$as_echo "fine" >&6; }
29489else
29490 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
29491$as_echo "failed" >&6; }
29492 as_fn_error $? "one or more libs available at link-time are not available run-time. Libs used at link-time: $LIBS" "$LINENO" 5
29493
29494fi
29495rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
29496 conftest.$ac_objext conftest.beam conftest.$ac_ext
29497fi
29498
Elliott Hughes72d948d2018-08-03 14:37:21 -070029499 LD_LIBRARY_PATH=$old # restore
29500
Elliott Hughes82be86d2017-09-20 17:00:17 -070029501
29502 fi
29503
29504
Elliott Hughes82be86d2017-09-20 17:00:17 -070029505{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of size_t" >&5
29506$as_echo_n "checking size of size_t... " >&6; }
29507if ${ac_cv_sizeof_size_t+:} false; then :
29508 $as_echo_n "(cached) " >&6
29509else
Elliott Hughes72d948d2018-08-03 14:37:21 -070029510 for ac_size in 4 8 1 2 16 ; do # List sizes in rough order of prevalence.
29511 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29512/* end confdefs.h. */
Elliott Hughes82be86d2017-09-20 17:00:17 -070029513
Elliott Hughes72d948d2018-08-03 14:37:21 -070029514#include <sys/types.h>
29515
29516
29517int main (void)
29518{
29519switch (0) case 0: case (sizeof (size_t) == $ac_size):;
29520 ;
29521 return 0;
29522}
29523_ACEOF
29524if ac_fn_c_try_compile "$LINENO"; then :
29525 ac_cv_sizeof_size_t=$ac_size
29526fi
29527rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29528 if test x$ac_cv_sizeof_size_t != x ; then break; fi
29529done
29530
Elliott Hughes82be86d2017-09-20 17:00:17 -070029531fi
29532
Elliott Hughes72d948d2018-08-03 14:37:21 -070029533if test x$ac_cv_sizeof_size_t = x ; then
29534 as_fn_error $? "cannot determine a size for size_t" "$LINENO" 5
Elliott Hughes82be86d2017-09-20 17:00:17 -070029535fi
29536{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_size_t" >&5
29537$as_echo "$ac_cv_sizeof_size_t" >&6; }
29538
Elliott Hughes82be86d2017-09-20 17:00:17 -070029539cat >>confdefs.h <<_ACEOF
29540#define SIZEOF_SIZE_T $ac_cv_sizeof_size_t
29541_ACEOF
29542
29543
Elliott Hughes82be86d2017-09-20 17:00:17 -070029544{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
29545$as_echo_n "checking size of long... " >&6; }
29546if ${ac_cv_sizeof_long+:} false; then :
29547 $as_echo_n "(cached) " >&6
29548else
Elliott Hughes72d948d2018-08-03 14:37:21 -070029549 for ac_size in 4 8 1 2 16 ; do # List sizes in rough order of prevalence.
29550 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29551/* end confdefs.h. */
Elliott Hughes82be86d2017-09-20 17:00:17 -070029552
Elliott Hughes72d948d2018-08-03 14:37:21 -070029553#include <sys/types.h>
29554
29555
29556int main (void)
29557{
29558switch (0) case 0: case (sizeof (long) == $ac_size):;
29559 ;
29560 return 0;
29561}
29562_ACEOF
29563if ac_fn_c_try_compile "$LINENO"; then :
29564 ac_cv_sizeof_long=$ac_size
29565fi
29566rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29567 if test x$ac_cv_sizeof_long != x ; then break; fi
29568done
29569
Elliott Hughes82be86d2017-09-20 17:00:17 -070029570fi
29571
Elliott Hughes72d948d2018-08-03 14:37:21 -070029572if test x$ac_cv_sizeof_long = x ; then
29573 as_fn_error $? "cannot determine a size for long" "$LINENO" 5
Elliott Hughes82be86d2017-09-20 17:00:17 -070029574fi
29575{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
29576$as_echo "$ac_cv_sizeof_long" >&6; }
29577
Elliott Hughes82be86d2017-09-20 17:00:17 -070029578cat >>confdefs.h <<_ACEOF
29579#define SIZEOF_LONG $ac_cv_sizeof_long
29580_ACEOF
29581
29582
Elliott Hughes82be86d2017-09-20 17:00:17 -070029583{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5
29584$as_echo_n "checking size of int... " >&6; }
29585if ${ac_cv_sizeof_int+:} false; then :
29586 $as_echo_n "(cached) " >&6
29587else
Elliott Hughes72d948d2018-08-03 14:37:21 -070029588 for ac_size in 4 8 1 2 16 ; do # List sizes in rough order of prevalence.
29589 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29590/* end confdefs.h. */
Elliott Hughes82be86d2017-09-20 17:00:17 -070029591
Elliott Hughes72d948d2018-08-03 14:37:21 -070029592#include <sys/types.h>
29593
29594
29595int main (void)
29596{
29597switch (0) case 0: case (sizeof (int) == $ac_size):;
29598 ;
29599 return 0;
29600}
29601_ACEOF
29602if ac_fn_c_try_compile "$LINENO"; then :
29603 ac_cv_sizeof_int=$ac_size
29604fi
29605rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29606 if test x$ac_cv_sizeof_int != x ; then break; fi
29607done
29608
Elliott Hughes82be86d2017-09-20 17:00:17 -070029609fi
29610
Elliott Hughes72d948d2018-08-03 14:37:21 -070029611if test x$ac_cv_sizeof_int = x ; then
29612 as_fn_error $? "cannot determine a size for int" "$LINENO" 5
Elliott Hughes82be86d2017-09-20 17:00:17 -070029613fi
29614{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5
29615$as_echo "$ac_cv_sizeof_int" >&6; }
29616
Elliott Hughes82be86d2017-09-20 17:00:17 -070029617cat >>confdefs.h <<_ACEOF
29618#define SIZEOF_INT $ac_cv_sizeof_int
29619_ACEOF
29620
29621
Elliott Hughes82be86d2017-09-20 17:00:17 -070029622{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5
29623$as_echo_n "checking size of short... " >&6; }
29624if ${ac_cv_sizeof_short+:} false; then :
29625 $as_echo_n "(cached) " >&6
29626else
Elliott Hughes72d948d2018-08-03 14:37:21 -070029627 for ac_size in 4 8 1 2 16 ; do # List sizes in rough order of prevalence.
29628 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29629/* end confdefs.h. */
Elliott Hughes82be86d2017-09-20 17:00:17 -070029630
Elliott Hughes72d948d2018-08-03 14:37:21 -070029631#include <sys/types.h>
29632
29633
29634int main (void)
29635{
29636switch (0) case 0: case (sizeof (short) == $ac_size):;
29637 ;
29638 return 0;
29639}
29640_ACEOF
29641if ac_fn_c_try_compile "$LINENO"; then :
29642 ac_cv_sizeof_short=$ac_size
29643fi
29644rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29645 if test x$ac_cv_sizeof_short != x ; then break; fi
29646done
29647
Elliott Hughes82be86d2017-09-20 17:00:17 -070029648fi
29649
Elliott Hughes72d948d2018-08-03 14:37:21 -070029650if test x$ac_cv_sizeof_short = x ; then
29651 as_fn_error $? "cannot determine a size for short" "$LINENO" 5
Elliott Hughes82be86d2017-09-20 17:00:17 -070029652fi
29653{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5
29654$as_echo "$ac_cv_sizeof_short" >&6; }
29655
Elliott Hughes82be86d2017-09-20 17:00:17 -070029656cat >>confdefs.h <<_ACEOF
29657#define SIZEOF_SHORT $ac_cv_sizeof_short
29658_ACEOF
29659
29660
Elliott Hughes82be86d2017-09-20 17:00:17 -070029661{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of time_t" >&5
29662$as_echo_n "checking size of time_t... " >&6; }
29663if ${ac_cv_sizeof_time_t+:} false; then :
29664 $as_echo_n "(cached) " >&6
29665else
Elliott Hughes72d948d2018-08-03 14:37:21 -070029666 for ac_size in 4 8 1 2 16 ; do # List sizes in rough order of prevalence.
29667 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29668/* end confdefs.h. */
Elliott Hughes82be86d2017-09-20 17:00:17 -070029669
Elliott Hughes72d948d2018-08-03 14:37:21 -070029670#include <sys/types.h>
29671
29672
29673int main (void)
29674{
29675switch (0) case 0: case (sizeof (time_t) == $ac_size):;
29676 ;
29677 return 0;
29678}
29679_ACEOF
29680if ac_fn_c_try_compile "$LINENO"; then :
29681 ac_cv_sizeof_time_t=$ac_size
29682fi
29683rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29684 if test x$ac_cv_sizeof_time_t != x ; then break; fi
29685done
29686
Elliott Hughes82be86d2017-09-20 17:00:17 -070029687fi
29688
Elliott Hughes72d948d2018-08-03 14:37:21 -070029689if test x$ac_cv_sizeof_time_t = x ; then
29690 as_fn_error $? "cannot determine a size for time_t" "$LINENO" 5
Elliott Hughes82be86d2017-09-20 17:00:17 -070029691fi
29692{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_time_t" >&5
29693$as_echo "$ac_cv_sizeof_time_t" >&6; }
29694
Elliott Hughes82be86d2017-09-20 17:00:17 -070029695cat >>confdefs.h <<_ACEOF
29696#define SIZEOF_TIME_T $ac_cv_sizeof_time_t
29697_ACEOF
29698
29699
Elliott Hughes82be86d2017-09-20 17:00:17 -070029700{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of off_t" >&5
29701$as_echo_n "checking size of off_t... " >&6; }
29702if ${ac_cv_sizeof_off_t+:} false; then :
29703 $as_echo_n "(cached) " >&6
29704else
Elliott Hughes72d948d2018-08-03 14:37:21 -070029705 for ac_size in 4 8 1 2 16 ; do # List sizes in rough order of prevalence.
29706 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29707/* end confdefs.h. */
Elliott Hughes82be86d2017-09-20 17:00:17 -070029708
Elliott Hughes72d948d2018-08-03 14:37:21 -070029709#include <sys/types.h>
29710
29711
29712int main (void)
29713{
29714switch (0) case 0: case (sizeof (off_t) == $ac_size):;
29715 ;
29716 return 0;
29717}
29718_ACEOF
29719if ac_fn_c_try_compile "$LINENO"; then :
29720 ac_cv_sizeof_off_t=$ac_size
29721fi
29722rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29723 if test x$ac_cv_sizeof_off_t != x ; then break; fi
29724done
29725
Elliott Hughes82be86d2017-09-20 17:00:17 -070029726fi
29727
Elliott Hughes72d948d2018-08-03 14:37:21 -070029728if test x$ac_cv_sizeof_off_t = x ; then
29729 as_fn_error $? "cannot determine a size for off_t" "$LINENO" 5
Elliott Hughes82be86d2017-09-20 17:00:17 -070029730fi
29731{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_off_t" >&5
29732$as_echo "$ac_cv_sizeof_off_t" >&6; }
29733
Elliott Hughes82be86d2017-09-20 17:00:17 -070029734cat >>confdefs.h <<_ACEOF
29735#define SIZEOF_OFF_T $ac_cv_sizeof_off_t
29736_ACEOF
29737
29738
29739
Alex Deymo486467e2017-12-19 19:04:07 +010029740o=$CPPFLAGS
29741CPPFLAGS="-I$srcdir/include $CPPFLAGS"
Alex Deymo486467e2017-12-19 19:04:07 +010029742{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of curl_off_t" >&5
29743$as_echo_n "checking size of curl_off_t... " >&6; }
29744if ${ac_cv_sizeof_curl_off_t+:} false; then :
29745 $as_echo_n "(cached) " >&6
29746else
Elliott Hughes72d948d2018-08-03 14:37:21 -070029747 for ac_size in 4 8 1 2 16 ; do # List sizes in rough order of prevalence.
29748 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29749/* end confdefs.h. */
29750
29751#include <sys/types.h>
29752
Alex Deymo486467e2017-12-19 19:04:07 +010029753#include <curl/system.h>
29754
Alex Deymo486467e2017-12-19 19:04:07 +010029755
Elliott Hughes72d948d2018-08-03 14:37:21 -070029756int main (void)
29757{
29758switch (0) case 0: case (sizeof (curl_off_t) == $ac_size):;
29759 ;
29760 return 0;
29761}
29762_ACEOF
29763if ac_fn_c_try_compile "$LINENO"; then :
29764 ac_cv_sizeof_curl_off_t=$ac_size
29765fi
29766rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29767 if test x$ac_cv_sizeof_curl_off_t != x ; then break; fi
29768done
29769
Elliott Hughes82be86d2017-09-20 17:00:17 -070029770fi
29771
Elliott Hughes72d948d2018-08-03 14:37:21 -070029772if test x$ac_cv_sizeof_curl_off_t = x ; then
29773 as_fn_error $? "cannot determine a size for curl_off_t" "$LINENO" 5
Alex Deymo486467e2017-12-19 19:04:07 +010029774fi
29775{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_curl_off_t" >&5
29776$as_echo "$ac_cv_sizeof_curl_off_t" >&6; }
29777
Alex Deymo486467e2017-12-19 19:04:07 +010029778cat >>confdefs.h <<_ACEOF
29779#define SIZEOF_CURL_OFF_T $ac_cv_sizeof_curl_off_t
29780_ACEOF
29781
29782
29783CPPFLAGS=$o
Elliott Hughes82be86d2017-09-20 17:00:17 -070029784
29785ac_fn_c_check_type "$LINENO" "long long" "ac_cv_type_long_long" "$ac_includes_default"
29786if test "x$ac_cv_type_long_long" = xyes; then :
29787
29788$as_echo "#define HAVE_LONGLONG 1" >>confdefs.h
29789
29790 longlong="yes"
29791
29792fi
29793
29794
29795if test "xyes" = "x$longlong"; then
29796 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if numberLL works" >&5
29797$as_echo_n "checking if numberLL works... " >&6; }
29798 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29799/* end confdefs.h. */
29800
29801
29802
29803int main (void)
29804{
29805
29806 long long val = 1000LL;
29807
29808 ;
29809 return 0;
29810}
29811
29812_ACEOF
29813if ac_fn_c_try_compile "$LINENO"; then :
29814
29815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
29816$as_echo "yes" >&6; }
29817
29818$as_echo "#define HAVE_LL 1" >>confdefs.h
29819
29820
29821else
29822
29823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29824$as_echo "no" >&6; }
29825
29826fi
29827rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29828fi
29829
29830
29831# check for ssize_t
29832ac_fn_c_check_type "$LINENO" "ssize_t" "ac_cv_type_ssize_t" "$ac_includes_default"
29833if test "x$ac_cv_type_ssize_t" = xyes; then :
29834
29835else
29836
29837$as_echo "#define ssize_t int" >>confdefs.h
29838
29839fi
29840
29841
29842# check for bool type
29843ac_fn_c_check_type "$LINENO" "bool" "ac_cv_type_bool" "
29844#ifdef HAVE_SYS_TYPES_H
29845#include <sys/types.h>
29846#endif
29847#ifdef HAVE_STDBOOL_H
29848#include <stdbool.h>
29849#endif
29850
29851"
29852if test "x$ac_cv_type_bool" = xyes; then :
29853
29854
29855$as_echo "#define HAVE_BOOL_T 1" >>confdefs.h
29856
29857
29858fi
29859
29860
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070029861# check for sa_family_t
29862ac_fn_c_check_type "$LINENO" "sa_family_t" "ac_cv_type_sa_family_t" "
29863#ifdef HAVE_SYS_SOCKET_H
29864#include <sys/socket.h>
29865#endif
29866
29867"
29868if test "x$ac_cv_type_sa_family_t" = xyes; then :
29869
29870$as_echo "#define CURL_SA_FAMILY_T sa_family_t" >>confdefs.h
29871
29872else
29873
29874 # The windows name?
29875 ac_fn_c_check_type "$LINENO" "ADDRESS_FAMILY" "ac_cv_type_ADDRESS_FAMILY" "
29876#ifdef HAVE_SYS_SOCKET_H
29877#include <sys/socket.h>
29878#endif
29879
29880"
29881if test "x$ac_cv_type_ADDRESS_FAMILY" = xyes; then :
29882
29883$as_echo "#define CURL_SA_FAMILY_T ADDRESS_FAMILY" >>confdefs.h
29884
29885else
29886
29887$as_echo "#define CURL_SA_FAMILY_T unsigned short" >>confdefs.h
29888
29889fi
29890
29891
29892fi
29893
29894
Elliott Hughescac39802018-04-27 16:19:43 -070029895{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if time_t is unsigned" >&5
29896$as_echo_n "checking if time_t is unsigned... " >&6; }
Elliott Hughescac39802018-04-27 16:19:43 -070029897
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070029898
29899 old=$LD_LIBRARY_PATH
Elliott Hughes72d948d2018-08-03 14:37:21 -070029900 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
29901 export LD_LIBRARY_PATH
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070029902 if test "$cross_compiling" = yes; then :
Elliott Hughescac39802018-04-27 16:19:43 -070029903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29904$as_echo "no" >&6; }
29905
29906else
29907 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29908/* end confdefs.h. */
29909
Elliott Hughescac39802018-04-27 16:19:43 -070029910 #include <time.h>
29911 #include <limits.h>
29912 time_t t = -1;
29913 return (t > 0);
29914
29915_ACEOF
29916if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughescac39802018-04-27 16:19:43 -070029917 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
29918$as_echo "yes" >&6; }
29919
29920$as_echo "#define HAVE_TIME_T_UNSIGNED 1" >>confdefs.h
29921
29922
29923else
Elliott Hughescac39802018-04-27 16:19:43 -070029924 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29925$as_echo "no" >&6; }
29926
29927fi
29928rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
29929 conftest.$ac_objext conftest.beam conftest.$ac_ext
29930fi
29931
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070029932 LD_LIBRARY_PATH=$old # restore
29933
Elliott Hughescac39802018-04-27 16:19:43 -070029934
Elliott Hughes82be86d2017-09-20 17:00:17 -070029935
Elliott Hughes82be86d2017-09-20 17:00:17 -070029936curl_includes_poll="\
29937/* includes start */
29938#ifdef HAVE_SYS_TYPES_H
29939# include <sys/types.h>
29940#endif
29941#ifdef HAVE_POLL_H
29942# include <poll.h>
29943#endif
29944#ifdef HAVE_SYS_POLL_H
29945# include <sys/poll.h>
29946#endif
29947/* includes end */"
29948 for ac_header in sys/types.h poll.h sys/poll.h
29949do :
29950 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
29951ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_poll
29952"
29953if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
29954 cat >>confdefs.h <<_ACEOF
29955#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
29956_ACEOF
29957
29958fi
29959
29960done
29961
29962
29963
29964 #
29965 tst_poll_events_macro_defined="unknown"
29966 #
29967 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29968/* end confdefs.h. */
29969
29970
29971 $curl_includes_poll
29972
29973int main (void)
29974{
29975
29976#if defined(events) || defined(revents)
29977 return 0;
29978#else
29979 force compilation error
29980#endif
29981
29982 ;
29983 return 0;
29984}
29985
29986_ACEOF
29987if ac_fn_c_try_compile "$LINENO"; then :
29988
29989 tst_poll_events_macro_defined="yes"
29990
29991else
29992
29993 tst_poll_events_macro_defined="no"
29994
29995fi
29996rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29997 #
29998 if test "$tst_poll_events_macro_defined" = "yes"; then
29999 if test "x$ac_cv_header_sys_poll_h" = "xyes"; then
30000
30001cat >>confdefs.h <<_EOF
30002#define CURL_PULL_SYS_POLL_H 1
30003_EOF
30004
30005 fi
30006 fi
30007 #
30008
30009
30010
30011 ac_fn_c_check_type "$LINENO" "in_addr_t" "ac_cv_type_in_addr_t" "
30012#undef inline
30013#ifdef HAVE_WINDOWS_H
30014#ifndef WIN32_LEAN_AND_MEAN
30015#define WIN32_LEAN_AND_MEAN
30016#endif
30017#include <windows.h>
30018#ifdef HAVE_WINSOCK2_H
30019#include <winsock2.h>
30020#else
30021#ifdef HAVE_WINSOCK_H
30022#include <winsock.h>
30023#endif
30024#endif
30025#else
30026#ifdef HAVE_SYS_TYPES_H
30027#include <sys/types.h>
30028#endif
30029#ifdef HAVE_SYS_SOCKET_H
30030#include <sys/socket.h>
30031#endif
30032#ifdef HAVE_NETINET_IN_H
30033#include <netinet/in.h>
30034#endif
30035#ifdef HAVE_ARPA_INET_H
30036#include <arpa/inet.h>
30037#endif
30038#endif
30039
30040"
30041if test "x$ac_cv_type_in_addr_t" = xyes; then :
30042
30043else
30044
30045 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for in_addr_t equivalent" >&5
30046$as_echo_n "checking for in_addr_t equivalent... " >&6; }
30047if ${curl_cv_in_addr_t_equiv+:} false; then :
30048 $as_echo_n "(cached) " >&6
30049else
30050
30051 curl_cv_in_addr_t_equiv="unknown"
30052 for t in "unsigned long" int size_t unsigned long; do
30053 if test "$curl_cv_in_addr_t_equiv" = "unknown"; then
30054 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30055/* end confdefs.h. */
30056
30057
30058#undef inline
30059#ifdef HAVE_WINDOWS_H
30060#ifndef WIN32_LEAN_AND_MEAN
30061#define WIN32_LEAN_AND_MEAN
30062#endif
30063#include <windows.h>
30064#ifdef HAVE_WINSOCK2_H
30065#include <winsock2.h>
30066#else
30067#ifdef HAVE_WINSOCK_H
30068#include <winsock.h>
30069#endif
30070#endif
30071#else
30072#ifdef HAVE_SYS_TYPES_H
30073#include <sys/types.h>
30074#endif
30075#ifdef HAVE_SYS_SOCKET_H
30076#include <sys/socket.h>
30077#endif
30078#ifdef HAVE_NETINET_IN_H
30079#include <netinet/in.h>
30080#endif
30081#ifdef HAVE_ARPA_INET_H
30082#include <arpa/inet.h>
30083#endif
30084#endif
30085
30086int main (void)
30087{
30088
30089 $t data = inet_addr ("1.2.3.4");
30090
30091 ;
30092 return 0;
30093}
30094
30095_ACEOF
30096if ac_fn_c_try_link "$LINENO"; then :
30097
30098 curl_cv_in_addr_t_equiv="$t"
30099
30100fi
30101rm -f core conftest.err conftest.$ac_objext \
30102 conftest$ac_exeext conftest.$ac_ext
30103 fi
30104 done
30105
30106fi
30107{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_in_addr_t_equiv" >&5
30108$as_echo "$curl_cv_in_addr_t_equiv" >&6; }
30109 case "$curl_cv_in_addr_t_equiv" in
30110 unknown)
30111 as_fn_error $? "Cannot find a type to use in place of in_addr_t" "$LINENO" 5
30112 ;;
30113 *)
30114
30115cat >>confdefs.h <<_ACEOF
30116#define in_addr_t $curl_cv_in_addr_t_equiv
30117_ACEOF
30118
30119 ;;
30120 esac
30121
30122fi
30123
30124
30125
30126
30127 ac_fn_c_check_type "$LINENO" "struct sockaddr_storage" "ac_cv_type_struct_sockaddr_storage" "
30128#undef inline
30129#ifdef HAVE_WINDOWS_H
30130#ifndef WIN32_LEAN_AND_MEAN
30131#define WIN32_LEAN_AND_MEAN
30132#endif
30133#include <windows.h>
30134#ifdef HAVE_WINSOCK2_H
30135#include <winsock2.h>
30136#endif
30137#else
30138#ifdef HAVE_SYS_TYPES_H
30139#include <sys/types.h>
30140#endif
30141#ifdef HAVE_SYS_SOCKET_H
30142#include <sys/socket.h>
30143#endif
30144#ifdef HAVE_NETINET_IN_H
30145#include <netinet/in.h>
30146#endif
30147#ifdef HAVE_ARPA_INET_H
30148#include <arpa/inet.h>
30149#endif
30150#endif
30151
30152"
30153if test "x$ac_cv_type_struct_sockaddr_storage" = xyes; then :
30154
30155$as_echo "#define HAVE_STRUCT_SOCKADDR_STORAGE 1" >>confdefs.h
30156
30157fi
30158
30159
30160
30161
30162 for ac_header in signal.h
30163do :
30164 ac_fn_c_check_header_mongrel "$LINENO" "signal.h" "ac_cv_header_signal_h" "$ac_includes_default"
30165if test "x$ac_cv_header_signal_h" = xyes; then :
30166 cat >>confdefs.h <<_ACEOF
30167#define HAVE_SIGNAL_H 1
30168_ACEOF
30169
30170fi
30171
30172done
30173
30174 ac_fn_c_check_type "$LINENO" "sig_atomic_t" "ac_cv_type_sig_atomic_t" "
30175#ifdef HAVE_SIGNAL_H
30176#include <signal.h>
30177#endif
30178
30179"
30180if test "x$ac_cv_type_sig_atomic_t" = xyes; then :
30181
30182
30183$as_echo "#define HAVE_SIG_ATOMIC_T 1" >>confdefs.h
30184
30185
30186fi
30187
30188 case "$ac_cv_type_sig_atomic_t" in
30189 yes)
30190 #
30191 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sig_atomic_t is already defined as volatile" >&5
30192$as_echo_n "checking if sig_atomic_t is already defined as volatile... " >&6; }
30193 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30194/* end confdefs.h. */
30195
30196
30197#ifdef HAVE_SIGNAL_H
30198#include <signal.h>
30199#endif
30200
30201int main (void)
30202{
30203
30204 static volatile sig_atomic_t dummy = 0;
30205
30206 ;
30207 return 0;
30208}
30209
30210_ACEOF
30211if ac_fn_c_try_link "$LINENO"; then :
30212
30213 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30214$as_echo "no" >&6; }
30215 curl_cv_sig_atomic_t_volatile="no"
30216
30217else
30218
30219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30220$as_echo "yes" >&6; }
30221 curl_cv_sig_atomic_t_volatile="yes"
30222
30223fi
30224rm -f core conftest.err conftest.$ac_objext \
30225 conftest$ac_exeext conftest.$ac_ext
30226 #
30227 if test "$curl_cv_sig_atomic_t_volatile" = "yes"; then
30228
30229$as_echo "#define HAVE_SIG_ATOMIC_T_VOLATILE 1" >>confdefs.h
30230
30231 fi
30232 ;;
30233 esac
30234
30235
30236{ $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5
30237$as_echo_n "checking return type of signal handlers... " >&6; }
30238if ${ac_cv_type_signal+:} false; then :
30239 $as_echo_n "(cached) " >&6
30240else
30241 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30242/* end confdefs.h. */
30243#include <sys/types.h>
30244#include <signal.h>
30245
30246int main (void)
30247{
30248return *(signal (0, 0)) (0) == 1;
30249 ;
30250 return 0;
30251}
30252_ACEOF
30253if ac_fn_c_try_compile "$LINENO"; then :
30254 ac_cv_type_signal=int
30255else
30256 ac_cv_type_signal=void
30257fi
30258rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30259fi
30260{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5
30261$as_echo "$ac_cv_type_signal" >&6; }
30262
30263cat >>confdefs.h <<_ACEOF
30264#define RETSIGTYPE $ac_cv_type_signal
30265_ACEOF
30266
30267
30268
30269
30270 for ac_header in sys/select.h sys/socket.h
30271do :
30272 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
30273ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
30274if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
30275 cat >>confdefs.h <<_ACEOF
30276#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
30277_ACEOF
30278
30279fi
30280
30281done
30282
30283 #
30284 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for select" >&5
30285$as_echo_n "checking for select... " >&6; }
30286 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30287/* end confdefs.h. */
30288
30289
30290#undef inline
30291#ifdef HAVE_WINDOWS_H
30292#ifndef WIN32_LEAN_AND_MEAN
30293#define WIN32_LEAN_AND_MEAN
30294#endif
30295#include <windows.h>
30296#ifdef HAVE_WINSOCK2_H
30297#include <winsock2.h>
30298#else
30299#ifdef HAVE_WINSOCK_H
30300#include <winsock.h>
30301#endif
30302#endif
30303#endif
30304#ifdef HAVE_SYS_TYPES_H
30305#include <sys/types.h>
30306#endif
30307#ifdef HAVE_SYS_TIME_H
30308#include <sys/time.h>
30309#ifdef TIME_WITH_SYS_TIME
30310#include <time.h>
30311#endif
30312#else
30313#ifdef HAVE_TIME_H
30314#include <time.h>
30315#endif
30316#endif
30317#ifndef HAVE_WINDOWS_H
Haibo Huang65021c72019-03-27 15:37:23 -070030318#ifdef HAVE_PROTO_BSDSOCKET_H
30319#include <proto/bsdsocket.h>
30320struct Library *SocketBase = NULL;
30321#define select(a,b,c,d,e) WaitSelect(a,b,c,d,e,0)
30322#endif
Elliott Hughes82be86d2017-09-20 17:00:17 -070030323#ifdef HAVE_SYS_SELECT_H
30324#include <sys/select.h>
30325#endif
30326#ifdef HAVE_SYS_SOCKET_H
30327#include <sys/socket.h>
30328#endif
30329#endif
30330
30331int main (void)
30332{
30333
30334 select(0, 0, 0, 0, 0);
30335
30336 ;
30337 return 0;
30338}
30339
30340_ACEOF
30341if ac_fn_c_try_link "$LINENO"; then :
30342
30343 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30344$as_echo "yes" >&6; }
30345 curl_cv_select="yes"
30346
30347else
30348
30349 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30350$as_echo "no" >&6; }
30351 curl_cv_select="no"
30352
30353fi
30354rm -f core conftest.err conftest.$ac_objext \
30355 conftest$ac_exeext conftest.$ac_ext
30356 #
30357 if test "$curl_cv_select" = "yes"; then
30358 { $as_echo "$as_me:${as_lineno-$LINENO}: checking types of args and return type for select" >&5
30359$as_echo_n "checking types of args and return type for select... " >&6; }
30360if ${curl_cv_func_select_args+:} false; then :
30361 $as_echo_n "(cached) " >&6
30362else
30363
30364 curl_cv_func_select_args="unknown"
30365 for sel_retv in 'int' 'ssize_t'; do
30366 for sel_arg1 in 'int' 'ssize_t' 'size_t' 'unsigned long int' 'unsigned int'; do
30367 for sel_arg234 in 'fd_set *' 'int *' 'void *'; do
30368 for sel_arg5 in 'struct timeval *' 'const struct timeval *'; do
30369 if test "$curl_cv_func_select_args" = "unknown"; then
30370 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30371/* end confdefs.h. */
30372
30373
30374#undef inline
30375#ifdef HAVE_WINDOWS_H
30376#ifndef WIN32_LEAN_AND_MEAN
30377#define WIN32_LEAN_AND_MEAN
30378#endif
30379#include <windows.h>
30380#ifdef HAVE_WINSOCK2_H
30381#include <winsock2.h>
30382#else
30383#ifdef HAVE_WINSOCK_H
30384#include <winsock.h>
30385#endif
30386#endif
30387#define SELECTCALLCONV PASCAL
30388#endif
30389#ifdef HAVE_SYS_TYPES_H
30390#include <sys/types.h>
30391#endif
30392#ifdef HAVE_SYS_TIME_H
30393#include <sys/time.h>
30394#ifdef TIME_WITH_SYS_TIME
30395#include <time.h>
30396#endif
30397#else
30398#ifdef HAVE_TIME_H
30399#include <time.h>
30400#endif
30401#endif
30402#ifndef HAVE_WINDOWS_H
Haibo Huang65021c72019-03-27 15:37:23 -070030403#ifdef HAVE_PROTO_BSDSOCKET_H
30404#include <proto/bsdsocket.h>
30405struct Library *SocketBase = NULL;
30406#define select(a,b,c,d,e) WaitSelect(a,b,c,d,e,0)
30407#endif
Elliott Hughes82be86d2017-09-20 17:00:17 -070030408#ifdef HAVE_SYS_SELECT_H
30409#include <sys/select.h>
30410#endif
30411#ifdef HAVE_SYS_SOCKET_H
30412#include <sys/socket.h>
30413#endif
30414#define SELECTCALLCONV
30415#endif
30416#ifndef HAVE_STRUCT_TIMEVAL
30417 struct timeval {
30418 long tv_sec;
30419 long tv_usec;
30420 };
30421#endif
Haibo Huang65021c72019-03-27 15:37:23 -070030422#ifndef HAVE_PROTO_BSDSOCKET_H
Elliott Hughes82be86d2017-09-20 17:00:17 -070030423 extern $sel_retv SELECTCALLCONV
Haibo Huang51d9d882019-02-06 01:36:06 -080030424 select($sel_arg1,
Elliott Hughes82be86d2017-09-20 17:00:17 -070030425 $sel_arg234,
30426 $sel_arg234,
30427 $sel_arg234,
30428 $sel_arg5);
Haibo Huang65021c72019-03-27 15:37:23 -070030429#endif
Elliott Hughes82be86d2017-09-20 17:00:17 -070030430
30431int main (void)
30432{
30433
30434 $sel_arg1 nfds=0;
30435 $sel_arg234 rfds=0;
30436 $sel_arg234 wfds=0;
30437 $sel_arg234 efds=0;
30438 $sel_retv res = select(nfds, rfds, wfds, efds, 0);
30439
30440 ;
30441 return 0;
30442}
30443
30444_ACEOF
30445if ac_fn_c_try_compile "$LINENO"; then :
30446
30447 curl_cv_func_select_args="$sel_arg1,$sel_arg234,$sel_arg5,$sel_retv"
30448
30449fi
30450rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30451 fi
30452 done
30453 done
30454 done
30455 done
30456
30457fi
30458{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_func_select_args" >&5
30459$as_echo "$curl_cv_func_select_args" >&6; } # AC-CACHE-CHECK
30460 if test "$curl_cv_func_select_args" = "unknown"; then
30461 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Cannot find proper types to use for select args" >&5
30462$as_echo "$as_me: WARNING: Cannot find proper types to use for select args" >&2;}
30463 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: HAVE_SELECT will not be defined" >&5
30464$as_echo "$as_me: WARNING: HAVE_SELECT will not be defined" >&2;}
30465 else
30466 select_prev_IFS=$IFS; IFS=','
30467 set dummy `echo "$curl_cv_func_select_args" | sed 's/\*/\*/g'`
30468 IFS=$select_prev_IFS
30469 shift
30470 #
30471 sel_qual_type_arg5=$3
30472 #
30473
30474cat >>confdefs.h <<_ACEOF
30475#define SELECT_TYPE_ARG1 $1
30476_ACEOF
30477
30478
30479cat >>confdefs.h <<_ACEOF
30480#define SELECT_TYPE_ARG234 $2
30481_ACEOF
30482
30483
30484cat >>confdefs.h <<_ACEOF
30485#define SELECT_TYPE_RETV $4
30486_ACEOF
30487
30488 #
30489 prev_sh_opts=$-
30490 #
30491 case $prev_sh_opts in
30492 *f*)
30493 ;;
30494 *)
30495 set -f
30496 ;;
30497 esac
30498 #
30499 case "$sel_qual_type_arg5" in
30500 const*)
30501 sel_qual_arg5=const
30502 sel_type_arg5=`echo $sel_qual_type_arg5 | sed 's/^const //'`
30503 ;;
30504 *)
30505 sel_qual_arg5=
30506 sel_type_arg5=$sel_qual_type_arg5
30507 ;;
30508 esac
30509 #
30510
30511cat >>confdefs.h <<_ACEOF
30512#define SELECT_QUAL_ARG5 $sel_qual_arg5
30513_ACEOF
30514
30515
30516cat >>confdefs.h <<_ACEOF
30517#define SELECT_TYPE_ARG5 $sel_type_arg5
30518_ACEOF
30519
30520 #
30521 case $prev_sh_opts in
30522 *f*)
30523 ;;
30524 *)
30525 set +f
30526 ;;
30527 esac
30528 #
30529
30530cat >>confdefs.h <<_ACEOF
30531#define HAVE_SELECT 1
30532_ACEOF
30533
30534 curl_cv_func_select="yes"
30535 fi
30536 fi
30537
30538
30539
30540 for ac_header in sys/types.h sys/socket.h
30541do :
30542 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
30543ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
30544if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
30545 cat >>confdefs.h <<_ACEOF
30546#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
30547_ACEOF
30548
30549fi
30550
30551done
30552
30553 #
30554 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for recv" >&5
30555$as_echo_n "checking for recv... " >&6; }
30556 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30557/* end confdefs.h. */
30558
30559
30560#undef inline
30561#ifdef HAVE_WINDOWS_H
30562#ifndef WIN32_LEAN_AND_MEAN
30563#define WIN32_LEAN_AND_MEAN
30564#endif
30565#include <windows.h>
30566#ifdef HAVE_WINSOCK2_H
30567#include <winsock2.h>
30568#else
30569#ifdef HAVE_WINSOCK_H
30570#include <winsock.h>
30571#endif
30572#endif
30573#else
Haibo Huang65021c72019-03-27 15:37:23 -070030574#ifdef HAVE_PROTO_BSDSOCKET_H
30575#include <proto/bsdsocket.h>
30576struct Library *SocketBase = NULL;
30577#endif
Elliott Hughes82be86d2017-09-20 17:00:17 -070030578#ifdef HAVE_SYS_TYPES_H
30579#include <sys/types.h>
30580#endif
30581#ifdef HAVE_SYS_SOCKET_H
30582#include <sys/socket.h>
30583#endif
30584#endif
30585
30586int main (void)
30587{
30588
30589 recv(0, 0, 0, 0);
30590
30591 ;
30592 return 0;
30593}
30594
30595_ACEOF
30596if ac_fn_c_try_link "$LINENO"; then :
30597
30598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30599$as_echo "yes" >&6; }
30600 curl_cv_recv="yes"
30601
30602else
30603
30604 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30605$as_echo "no" >&6; }
30606 curl_cv_recv="no"
30607
30608fi
30609rm -f core conftest.err conftest.$ac_objext \
30610 conftest$ac_exeext conftest.$ac_ext
30611 #
30612 if test "$curl_cv_recv" = "yes"; then
30613 { $as_echo "$as_me:${as_lineno-$LINENO}: checking types of args and return type for recv" >&5
30614$as_echo_n "checking types of args and return type for recv... " >&6; }
30615if ${curl_cv_func_recv_args+:} false; then :
30616 $as_echo_n "(cached) " >&6
30617else
30618
30619 curl_cv_func_recv_args="unknown"
30620 for recv_retv in 'int' 'ssize_t'; do
30621 for recv_arg1 in 'int' 'ssize_t' 'SOCKET'; do
30622 for recv_arg2 in 'char *' 'void *'; do
30623 for recv_arg3 in 'size_t' 'int' 'socklen_t' 'unsigned int'; do
30624 for recv_arg4 in 'int' 'unsigned int'; do
30625 if test "$curl_cv_func_recv_args" = "unknown"; then
30626 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30627/* end confdefs.h. */
30628
30629
30630#undef inline
30631#ifdef HAVE_WINDOWS_H
30632#ifndef WIN32_LEAN_AND_MEAN
30633#define WIN32_LEAN_AND_MEAN
30634#endif
30635#include <windows.h>
30636#ifdef HAVE_WINSOCK2_H
30637#include <winsock2.h>
30638#else
30639#ifdef HAVE_WINSOCK_H
30640#include <winsock.h>
30641#endif
30642#endif
30643#define RECVCALLCONV PASCAL
30644#else
Haibo Huang65021c72019-03-27 15:37:23 -070030645#ifdef HAVE_PROTO_BSDSOCKET_H
30646#include <proto/bsdsocket.h>
30647struct Library *SocketBase = NULL;
30648#endif
Elliott Hughes82be86d2017-09-20 17:00:17 -070030649#ifdef HAVE_SYS_TYPES_H
30650#include <sys/types.h>
30651#endif
30652#ifdef HAVE_SYS_SOCKET_H
30653#include <sys/socket.h>
30654#endif
30655#define RECVCALLCONV
30656#endif
Haibo Huang65021c72019-03-27 15:37:23 -070030657#ifndef HAVE_PROTO_BSDSOCKET_H
Elliott Hughes82be86d2017-09-20 17:00:17 -070030658 extern $recv_retv RECVCALLCONV
Elliott Hughes82be86d2017-09-20 17:00:17 -070030659 recv($recv_arg1, $recv_arg2, $recv_arg3, $recv_arg4);
Haibo Huang65021c72019-03-27 15:37:23 -070030660#endif
Elliott Hughes82be86d2017-09-20 17:00:17 -070030661
30662int main (void)
30663{
30664
30665 $recv_arg1 s=0;
30666 $recv_arg2 buf=0;
30667 $recv_arg3 len=0;
30668 $recv_arg4 flags=0;
30669 $recv_retv res = recv(s, buf, len, flags);
30670
30671 ;
30672 return 0;
30673}
30674
30675_ACEOF
30676if ac_fn_c_try_compile "$LINENO"; then :
30677
30678 curl_cv_func_recv_args="$recv_arg1,$recv_arg2,$recv_arg3,$recv_arg4,$recv_retv"
30679
30680fi
30681rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30682 fi
30683 done
30684 done
30685 done
30686 done
30687 done
30688
30689fi
30690{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_func_recv_args" >&5
30691$as_echo "$curl_cv_func_recv_args" >&6; } # AC-CACHE-CHECK
30692 if test "$curl_cv_func_recv_args" = "unknown"; then
30693 as_fn_error $? "Cannot find proper types to use for recv args" "$LINENO" 5
30694 else
30695 recv_prev_IFS=$IFS; IFS=','
30696 set dummy `echo "$curl_cv_func_recv_args" | sed 's/\*/\*/g'`
30697 IFS=$recv_prev_IFS
30698 shift
30699 #
30700
30701cat >>confdefs.h <<_ACEOF
30702#define RECV_TYPE_ARG1 $1
30703_ACEOF
30704
30705
30706cat >>confdefs.h <<_ACEOF
30707#define RECV_TYPE_ARG2 $2
30708_ACEOF
30709
30710
30711cat >>confdefs.h <<_ACEOF
30712#define RECV_TYPE_ARG3 $3
30713_ACEOF
30714
30715
30716cat >>confdefs.h <<_ACEOF
30717#define RECV_TYPE_ARG4 $4
30718_ACEOF
30719
30720
30721cat >>confdefs.h <<_ACEOF
30722#define RECV_TYPE_RETV $5
30723_ACEOF
30724
30725 #
30726
30727cat >>confdefs.h <<_ACEOF
30728#define HAVE_RECV 1
30729_ACEOF
30730
30731 curl_cv_func_recv="yes"
30732 fi
30733 else
30734 as_fn_error $? "Unable to link function recv" "$LINENO" 5
30735 fi
30736
30737
30738 for ac_header in sys/types.h sys/socket.h
30739do :
30740 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
30741ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
30742if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
30743 cat >>confdefs.h <<_ACEOF
30744#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
30745_ACEOF
30746
30747fi
30748
30749done
30750
30751 #
30752 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for send" >&5
30753$as_echo_n "checking for send... " >&6; }
30754 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30755/* end confdefs.h. */
30756
30757
30758#undef inline
30759#ifdef HAVE_WINDOWS_H
30760#ifndef WIN32_LEAN_AND_MEAN
30761#define WIN32_LEAN_AND_MEAN
30762#endif
30763#include <windows.h>
30764#ifdef HAVE_WINSOCK2_H
30765#include <winsock2.h>
30766#else
30767#ifdef HAVE_WINSOCK_H
30768#include <winsock.h>
30769#endif
30770#endif
30771#else
Haibo Huang65021c72019-03-27 15:37:23 -070030772#ifdef HAVE_PROTO_BSDSOCKET_H
30773#include <proto/bsdsocket.h>
30774struct Library *SocketBase = NULL;
30775#endif
Elliott Hughes82be86d2017-09-20 17:00:17 -070030776#ifdef HAVE_SYS_TYPES_H
30777#include <sys/types.h>
30778#endif
30779#ifdef HAVE_SYS_SOCKET_H
30780#include <sys/socket.h>
30781#endif
30782#endif
30783
30784int main (void)
30785{
30786
30787 send(0, 0, 0, 0);
30788
30789 ;
30790 return 0;
30791}
30792
30793_ACEOF
30794if ac_fn_c_try_link "$LINENO"; then :
30795
30796 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30797$as_echo "yes" >&6; }
30798 curl_cv_send="yes"
30799
30800else
30801
30802 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30803$as_echo "no" >&6; }
30804 curl_cv_send="no"
30805
30806fi
30807rm -f core conftest.err conftest.$ac_objext \
30808 conftest$ac_exeext conftest.$ac_ext
30809 #
30810 if test "$curl_cv_send" = "yes"; then
30811 { $as_echo "$as_me:${as_lineno-$LINENO}: checking types of args and return type for send" >&5
30812$as_echo_n "checking types of args and return type for send... " >&6; }
30813if ${curl_cv_func_send_args+:} false; then :
30814 $as_echo_n "(cached) " >&6
30815else
30816
30817 curl_cv_func_send_args="unknown"
30818 for send_retv in 'int' 'ssize_t'; do
30819 for send_arg1 in 'int' 'ssize_t' 'SOCKET'; do
30820 for send_arg2 in 'char *' 'void *' 'const char *' 'const void *'; do
30821 for send_arg3 in 'size_t' 'int' 'socklen_t' 'unsigned int'; do
30822 for send_arg4 in 'int' 'unsigned int'; do
30823 if test "$curl_cv_func_send_args" = "unknown"; then
30824 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30825/* end confdefs.h. */
30826
30827
30828#undef inline
30829#ifdef HAVE_WINDOWS_H
30830#ifndef WIN32_LEAN_AND_MEAN
30831#define WIN32_LEAN_AND_MEAN
30832#endif
30833#include <windows.h>
30834#ifdef HAVE_WINSOCK2_H
30835#include <winsock2.h>
30836#else
30837#ifdef HAVE_WINSOCK_H
30838#include <winsock.h>
30839#endif
30840#endif
30841#define SENDCALLCONV PASCAL
30842#else
Haibo Huang65021c72019-03-27 15:37:23 -070030843#ifdef HAVE_PROTO_BSDSOCKET_H
30844#include <proto/bsdsocket.h>
30845struct Library *SocketBase = NULL;
30846#endif
Elliott Hughes82be86d2017-09-20 17:00:17 -070030847#ifdef HAVE_SYS_TYPES_H
30848#include <sys/types.h>
30849#endif
30850#ifdef HAVE_SYS_SOCKET_H
30851#include <sys/socket.h>
30852#endif
30853#define SENDCALLCONV
30854#endif
Haibo Huang65021c72019-03-27 15:37:23 -070030855#ifndef HAVE_PROTO_BSDSOCKET_H
Elliott Hughes82be86d2017-09-20 17:00:17 -070030856 extern $send_retv SENDCALLCONV
Elliott Hughes82be86d2017-09-20 17:00:17 -070030857 send($send_arg1, $send_arg2, $send_arg3, $send_arg4);
Haibo Huang65021c72019-03-27 15:37:23 -070030858#endif
Elliott Hughes82be86d2017-09-20 17:00:17 -070030859
30860int main (void)
30861{
30862
30863 $send_arg1 s=0;
30864 $send_arg3 len=0;
30865 $send_arg4 flags=0;
30866 $send_retv res = send(s, 0, len, flags);
30867
30868 ;
30869 return 0;
30870}
30871
30872_ACEOF
30873if ac_fn_c_try_compile "$LINENO"; then :
30874
30875 curl_cv_func_send_args="$send_arg1,$send_arg2,$send_arg3,$send_arg4,$send_retv"
30876
30877fi
30878rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30879 fi
30880 done
30881 done
30882 done
30883 done
30884 done
30885
30886fi
30887{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_func_send_args" >&5
30888$as_echo "$curl_cv_func_send_args" >&6; } # AC-CACHE-CHECK
30889 if test "$curl_cv_func_send_args" = "unknown"; then
30890 as_fn_error $? "Cannot find proper types to use for send args" "$LINENO" 5
30891 else
30892 send_prev_IFS=$IFS; IFS=','
30893 set dummy `echo "$curl_cv_func_send_args" | sed 's/\*/\*/g'`
30894 IFS=$send_prev_IFS
30895 shift
30896 #
30897 send_qual_type_arg2=$2
30898 #
30899
30900cat >>confdefs.h <<_ACEOF
30901#define SEND_TYPE_ARG1 $1
30902_ACEOF
30903
30904
30905cat >>confdefs.h <<_ACEOF
30906#define SEND_TYPE_ARG3 $3
30907_ACEOF
30908
30909
30910cat >>confdefs.h <<_ACEOF
30911#define SEND_TYPE_ARG4 $4
30912_ACEOF
30913
30914
30915cat >>confdefs.h <<_ACEOF
30916#define SEND_TYPE_RETV $5
30917_ACEOF
30918
30919 #
30920 prev_sh_opts=$-
30921 #
30922 case $prev_sh_opts in
30923 *f*)
30924 ;;
30925 *)
30926 set -f
30927 ;;
30928 esac
30929 #
30930 case "$send_qual_type_arg2" in
30931 const*)
30932 send_qual_arg2=const
30933 send_type_arg2=`echo $send_qual_type_arg2 | sed 's/^const //'`
30934 ;;
30935 *)
30936 send_qual_arg2=
30937 send_type_arg2=$send_qual_type_arg2
30938 ;;
30939 esac
30940 #
30941
30942cat >>confdefs.h <<_ACEOF
30943#define SEND_QUAL_ARG2 $send_qual_arg2
30944_ACEOF
30945
30946
30947cat >>confdefs.h <<_ACEOF
30948#define SEND_TYPE_ARG2 $send_type_arg2
30949_ACEOF
30950
30951 #
30952 case $prev_sh_opts in
30953 *f*)
30954 ;;
30955 *)
30956 set +f
30957 ;;
30958 esac
30959 #
30960
30961cat >>confdefs.h <<_ACEOF
30962#define HAVE_SEND 1
30963_ACEOF
30964
30965 curl_cv_func_send="yes"
30966 fi
30967 else
30968 as_fn_error $? "Unable to link function send" "$LINENO" 5
30969 fi
30970
30971
30972 for ac_header in sys/types.h sys/socket.h
30973do :
30974 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
30975ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
30976if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
30977 cat >>confdefs.h <<_ACEOF
30978#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
30979_ACEOF
30980
30981fi
30982
30983done
30984
30985 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MSG_NOSIGNAL" >&5
30986$as_echo_n "checking for MSG_NOSIGNAL... " >&6; }
30987if ${curl_cv_msg_nosignal+:} false; then :
30988 $as_echo_n "(cached) " >&6
30989else
30990
30991 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30992/* end confdefs.h. */
30993
30994
30995#undef inline
30996#ifdef HAVE_WINDOWS_H
30997#ifndef WIN32_LEAN_AND_MEAN
30998#define WIN32_LEAN_AND_MEAN
30999#endif
31000#include <windows.h>
31001#ifdef HAVE_WINSOCK2_H
31002#include <winsock2.h>
31003#else
31004#ifdef HAVE_WINSOCK_H
31005#include <winsock.h>
31006#endif
31007#endif
31008#else
Haibo Huang65021c72019-03-27 15:37:23 -070031009#ifdef HAVE_PROTO_BSDSOCKET_H
31010#include <proto/bsdsocket.h>
31011struct Library *SocketBase = NULL;
31012#endif
Elliott Hughes82be86d2017-09-20 17:00:17 -070031013#ifdef HAVE_SYS_TYPES_H
31014#include <sys/types.h>
31015#endif
31016#ifdef HAVE_SYS_SOCKET_H
31017#include <sys/socket.h>
31018#endif
31019#endif
31020
31021int main (void)
31022{
31023
31024 int flag=MSG_NOSIGNAL;
31025
31026 ;
31027 return 0;
31028}
31029
31030_ACEOF
31031if ac_fn_c_try_compile "$LINENO"; then :
31032
31033 curl_cv_msg_nosignal="yes"
31034
31035else
31036
31037 curl_cv_msg_nosignal="no"
31038
31039fi
31040rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31041
31042fi
31043{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_msg_nosignal" >&5
31044$as_echo "$curl_cv_msg_nosignal" >&6; }
31045 case "$curl_cv_msg_nosignal" in
31046 yes)
31047
31048cat >>confdefs.h <<_ACEOF
31049#define HAVE_MSG_NOSIGNAL 1
31050_ACEOF
31051
31052 ;;
31053 esac
31054
31055
31056
31057curl_includes_unistd="\
31058/* includes start */
31059#ifdef HAVE_SYS_TYPES_H
31060# include <sys/types.h>
31061#endif
31062#ifdef HAVE_UNISTD_H
31063# include <unistd.h>
31064#endif
31065/* includes end */"
31066 for ac_header in sys/types.h unistd.h
31067do :
31068 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
31069ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_unistd
31070"
31071if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
31072 cat >>confdefs.h <<_ACEOF
31073#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
31074_ACEOF
31075
31076fi
31077
31078done
31079
31080
31081
31082 #
31083 tst_links_alarm="unknown"
31084 tst_proto_alarm="unknown"
31085 tst_compi_alarm="unknown"
31086 tst_allow_alarm="unknown"
31087 #
31088 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if alarm can be linked" >&5
31089$as_echo_n "checking if alarm can be linked... " >&6; }
31090 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31091/* end confdefs.h. */
31092
31093
31094#define alarm innocuous_alarm
31095#ifdef __STDC__
31096# include <limits.h>
31097#else
31098# include <assert.h>
31099#endif
31100#undef alarm
31101#ifdef __cplusplus
31102extern "C"
31103#endif
31104char alarm ();
31105#if defined __stub_alarm || defined __stub___alarm
31106choke me
31107#endif
31108
31109int main (void)
31110{
31111return alarm ();
31112 ;
31113 return 0;
31114}
31115
31116_ACEOF
31117if ac_fn_c_try_link "$LINENO"; then :
31118
31119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31120$as_echo "yes" >&6; }
31121 tst_links_alarm="yes"
31122
31123else
31124
31125 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31126$as_echo "no" >&6; }
31127 tst_links_alarm="no"
31128
31129fi
31130rm -f core conftest.err conftest.$ac_objext \
31131 conftest$ac_exeext conftest.$ac_ext
31132 #
31133 if test "$tst_links_alarm" = "yes"; then
31134 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if alarm is prototyped" >&5
31135$as_echo_n "checking if alarm is prototyped... " >&6; }
31136 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31137/* end confdefs.h. */
31138
31139 $curl_includes_unistd
31140
31141_ACEOF
31142if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
31143 $EGREP "alarm" >/dev/null 2>&1; then :
31144
31145 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31146$as_echo "yes" >&6; }
31147 tst_proto_alarm="yes"
31148
31149else
31150
31151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31152$as_echo "no" >&6; }
31153 tst_proto_alarm="no"
31154
31155fi
31156rm -f conftest*
31157
31158 fi
31159 #
31160 if test "$tst_proto_alarm" = "yes"; then
31161 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if alarm is compilable" >&5
31162$as_echo_n "checking if alarm is compilable... " >&6; }
31163 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31164/* end confdefs.h. */
31165
31166
31167 $curl_includes_unistd
31168
31169int main (void)
31170{
31171
31172 if(0 != alarm(0))
31173 return 1;
31174
31175 ;
31176 return 0;
31177}
31178
31179_ACEOF
31180if ac_fn_c_try_compile "$LINENO"; then :
31181
31182 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31183$as_echo "yes" >&6; }
31184 tst_compi_alarm="yes"
31185
31186else
31187
31188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31189$as_echo "no" >&6; }
31190 tst_compi_alarm="no"
31191
31192fi
31193rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31194 fi
31195 #
31196 if test "$tst_compi_alarm" = "yes"; then
31197 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if alarm usage allowed" >&5
31198$as_echo_n "checking if alarm usage allowed... " >&6; }
31199 if test "x$curl_disallow_alarm" != "xyes"; then
31200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31201$as_echo "yes" >&6; }
31202 tst_allow_alarm="yes"
31203 else
31204 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31205$as_echo "no" >&6; }
31206 tst_allow_alarm="no"
31207 fi
31208 fi
31209 #
31210 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if alarm might be used" >&5
31211$as_echo_n "checking if alarm might be used... " >&6; }
31212 if test "$tst_links_alarm" = "yes" &&
31213 test "$tst_proto_alarm" = "yes" &&
31214 test "$tst_compi_alarm" = "yes" &&
31215 test "$tst_allow_alarm" = "yes"; then
31216 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31217$as_echo "yes" >&6; }
31218
31219cat >>confdefs.h <<_ACEOF
31220#define HAVE_ALARM 1
31221_ACEOF
31222
31223 curl_cv_func_alarm="yes"
31224 else
31225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31226$as_echo "no" >&6; }
31227 curl_cv_func_alarm="no"
31228 fi
31229
31230
31231curl_includes_string="\
31232/* includes start */
31233#ifdef HAVE_SYS_TYPES_H
31234# include <sys/types.h>
31235#endif
31236#ifdef HAVE_STRING_H
31237# include <string.h>
31238#endif
31239#ifdef HAVE_STRINGS_H
31240# include <strings.h>
31241#endif
31242/* includes end */"
31243 for ac_header in sys/types.h string.h strings.h
31244do :
31245 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
31246ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_string
31247"
31248if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
31249 cat >>confdefs.h <<_ACEOF
31250#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
31251_ACEOF
31252
31253fi
31254
31255done
31256
31257
31258
31259curl_includes_libgen="\
31260/* includes start */
31261#ifdef HAVE_SYS_TYPES_H
31262# include <sys/types.h>
31263#endif
31264#ifdef HAVE_LIBGEN_H
31265# include <libgen.h>
31266#endif
31267/* includes end */"
31268 for ac_header in sys/types.h libgen.h
31269do :
31270 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
31271ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_libgen
31272"
31273if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
31274 cat >>confdefs.h <<_ACEOF
31275#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
31276_ACEOF
31277
31278fi
31279
31280done
31281
31282
31283
31284 #
31285 tst_links_basename="unknown"
31286 tst_proto_basename="unknown"
31287 tst_compi_basename="unknown"
31288 tst_allow_basename="unknown"
31289 #
31290 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if basename can be linked" >&5
31291$as_echo_n "checking if basename can be linked... " >&6; }
31292 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31293/* end confdefs.h. */
31294
31295
31296#define basename innocuous_basename
31297#ifdef __STDC__
31298# include <limits.h>
31299#else
31300# include <assert.h>
31301#endif
31302#undef basename
31303#ifdef __cplusplus
31304extern "C"
31305#endif
31306char basename ();
31307#if defined __stub_basename || defined __stub___basename
31308choke me
31309#endif
31310
31311int main (void)
31312{
31313return basename ();
31314 ;
31315 return 0;
31316}
31317
31318_ACEOF
31319if ac_fn_c_try_link "$LINENO"; then :
31320
31321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31322$as_echo "yes" >&6; }
31323 tst_links_basename="yes"
31324
31325else
31326
31327 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31328$as_echo "no" >&6; }
31329 tst_links_basename="no"
31330
31331fi
31332rm -f core conftest.err conftest.$ac_objext \
31333 conftest$ac_exeext conftest.$ac_ext
31334 #
31335 if test "$tst_links_basename" = "yes"; then
31336 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if basename is prototyped" >&5
31337$as_echo_n "checking if basename is prototyped... " >&6; }
31338 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31339/* end confdefs.h. */
31340
31341 $curl_includes_string
31342 $curl_includes_libgen
31343 $curl_includes_unistd
31344
31345_ACEOF
31346if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
31347 $EGREP "basename" >/dev/null 2>&1; then :
31348
31349 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31350$as_echo "yes" >&6; }
31351 tst_proto_basename="yes"
31352
31353else
31354
31355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31356$as_echo "no" >&6; }
31357 tst_proto_basename="no"
31358
31359fi
31360rm -f conftest*
31361
31362 fi
31363 #
31364 if test "$tst_proto_basename" = "yes"; then
31365 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if basename is compilable" >&5
31366$as_echo_n "checking if basename is compilable... " >&6; }
31367 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31368/* end confdefs.h. */
31369
31370
31371 $curl_includes_string
31372 $curl_includes_libgen
31373 $curl_includes_unistd
31374
31375int main (void)
31376{
31377
31378 if(0 != basename(0))
31379 return 1;
31380
31381 ;
31382 return 0;
31383}
31384
31385_ACEOF
31386if ac_fn_c_try_compile "$LINENO"; then :
31387
31388 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31389$as_echo "yes" >&6; }
31390 tst_compi_basename="yes"
31391
31392else
31393
31394 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31395$as_echo "no" >&6; }
31396 tst_compi_basename="no"
31397
31398fi
31399rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31400 fi
31401 #
31402 if test "$tst_compi_basename" = "yes"; then
31403 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if basename usage allowed" >&5
31404$as_echo_n "checking if basename usage allowed... " >&6; }
31405 if test "x$curl_disallow_basename" != "xyes"; then
31406 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31407$as_echo "yes" >&6; }
31408 tst_allow_basename="yes"
31409 else
31410 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31411$as_echo "no" >&6; }
31412 tst_allow_basename="no"
31413 fi
31414 fi
31415 #
31416 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if basename might be used" >&5
31417$as_echo_n "checking if basename might be used... " >&6; }
31418 if test "$tst_links_basename" = "yes" &&
31419 test "$tst_proto_basename" = "yes" &&
31420 test "$tst_compi_basename" = "yes" &&
31421 test "$tst_allow_basename" = "yes"; then
31422 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31423$as_echo "yes" >&6; }
31424
31425cat >>confdefs.h <<_ACEOF
31426#define HAVE_BASENAME 1
31427_ACEOF
31428
31429 curl_cv_func_basename="yes"
31430 else
31431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31432$as_echo "no" >&6; }
31433 curl_cv_func_basename="no"
31434 fi
31435
31436
31437curl_includes_socket="\
31438/* includes start */
31439#ifdef HAVE_SYS_TYPES_H
31440# include <sys/types.h>
31441#endif
31442#ifdef HAVE_SOCKET_H
31443# include <socket.h>
31444#endif
31445/* includes end */"
31446 for ac_header in sys/types.h socket.h
31447do :
31448 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
31449ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_socket
31450"
31451if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
31452 cat >>confdefs.h <<_ACEOF
31453#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
31454_ACEOF
31455
31456fi
31457
31458done
31459
31460
31461
31462 #
31463 tst_links_closesocket="unknown"
31464 tst_proto_closesocket="unknown"
31465 tst_compi_closesocket="unknown"
31466 tst_allow_closesocket="unknown"
31467 #
31468 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if closesocket can be linked" >&5
31469$as_echo_n "checking if closesocket can be linked... " >&6; }
31470 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31471/* end confdefs.h. */
31472
31473
31474 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070031475 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070031476 $curl_includes_socket
31477
31478int main (void)
31479{
31480
31481 if(0 != closesocket(0))
31482 return 1;
31483
31484 ;
31485 return 0;
31486}
31487
31488_ACEOF
31489if ac_fn_c_try_link "$LINENO"; then :
31490
31491 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31492$as_echo "yes" >&6; }
31493 tst_links_closesocket="yes"
31494
31495else
31496
31497 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31498$as_echo "no" >&6; }
31499 tst_links_closesocket="no"
31500
31501fi
31502rm -f core conftest.err conftest.$ac_objext \
31503 conftest$ac_exeext conftest.$ac_ext
31504 #
31505 if test "$tst_links_closesocket" = "yes"; then
31506 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if closesocket is prototyped" >&5
31507$as_echo_n "checking if closesocket is prototyped... " >&6; }
31508 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31509/* end confdefs.h. */
31510
31511 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070031512 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070031513 $curl_includes_socket
31514
31515_ACEOF
31516if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
31517 $EGREP "closesocket" >/dev/null 2>&1; then :
31518
31519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31520$as_echo "yes" >&6; }
31521 tst_proto_closesocket="yes"
31522
31523else
31524
31525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31526$as_echo "no" >&6; }
31527 tst_proto_closesocket="no"
31528
31529fi
31530rm -f conftest*
31531
31532 fi
31533 #
31534 if test "$tst_proto_closesocket" = "yes"; then
31535 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if closesocket is compilable" >&5
31536$as_echo_n "checking if closesocket is compilable... " >&6; }
31537 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31538/* end confdefs.h. */
31539
31540
31541 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070031542 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070031543 $curl_includes_socket
31544
31545int main (void)
31546{
31547
31548 if(0 != closesocket(0))
31549 return 1;
31550
31551 ;
31552 return 0;
31553}
31554
31555_ACEOF
31556if ac_fn_c_try_compile "$LINENO"; then :
31557
31558 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31559$as_echo "yes" >&6; }
31560 tst_compi_closesocket="yes"
31561
31562else
31563
31564 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31565$as_echo "no" >&6; }
31566 tst_compi_closesocket="no"
31567
31568fi
31569rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31570 fi
31571 #
31572 if test "$tst_compi_closesocket" = "yes"; then
31573 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if closesocket usage allowed" >&5
31574$as_echo_n "checking if closesocket usage allowed... " >&6; }
31575 if test "x$curl_disallow_closesocket" != "xyes"; then
31576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31577$as_echo "yes" >&6; }
31578 tst_allow_closesocket="yes"
31579 else
31580 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31581$as_echo "no" >&6; }
31582 tst_allow_closesocket="no"
31583 fi
31584 fi
31585 #
31586 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if closesocket might be used" >&5
31587$as_echo_n "checking if closesocket might be used... " >&6; }
31588 if test "$tst_links_closesocket" = "yes" &&
31589 test "$tst_proto_closesocket" = "yes" &&
31590 test "$tst_compi_closesocket" = "yes" &&
31591 test "$tst_allow_closesocket" = "yes"; then
31592 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31593$as_echo "yes" >&6; }
31594
31595cat >>confdefs.h <<_ACEOF
31596#define HAVE_CLOSESOCKET 1
31597_ACEOF
31598
31599 curl_cv_func_closesocket="yes"
31600 else
31601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31602$as_echo "no" >&6; }
31603 curl_cv_func_closesocket="no"
31604 fi
31605
31606
Elliott Hughesa93fb052018-12-12 14:22:48 -080031607curl_includes_sys_socket="\
31608/* includes start */
31609#ifdef HAVE_SYS_TYPES_H
31610# include <sys/types.h>
31611#endif
31612#ifdef HAVE_SYS_SOCKET_H
31613# include <sys/socket.h>
31614#endif
31615/* includes end */"
31616 for ac_header in sys/types.h sys/socket.h
31617do :
31618 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
31619ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_sys_socket
31620"
31621if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
31622 cat >>confdefs.h <<_ACEOF
31623#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
31624_ACEOF
31625
31626fi
31627
31628done
31629
31630
31631
Elliott Hughes82be86d2017-09-20 17:00:17 -070031632 #
31633 tst_links_closesocket_camel="unknown"
31634 tst_proto_closesocket_camel="unknown"
31635 tst_compi_closesocket_camel="unknown"
31636 tst_allow_closesocket_camel="unknown"
31637 #
31638 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if CloseSocket can be linked" >&5
31639$as_echo_n "checking if CloseSocket can be linked... " >&6; }
31640 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31641/* end confdefs.h. */
31642
31643
31644 $curl_includes_sys_socket
31645
31646int main (void)
31647{
31648
31649 if(0 != CloseSocket(0))
31650 return 1;
31651
31652 ;
31653 return 0;
31654}
31655
31656_ACEOF
31657if ac_fn_c_try_link "$LINENO"; then :
31658
31659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31660$as_echo "yes" >&6; }
31661 tst_links_closesocket_camel="yes"
31662
31663else
31664
31665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31666$as_echo "no" >&6; }
31667 tst_links_closesocket_camel="no"
31668
31669fi
31670rm -f core conftest.err conftest.$ac_objext \
31671 conftest$ac_exeext conftest.$ac_ext
31672 #
31673 if test "$tst_links_closesocket_camel" = "yes"; then
31674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if CloseSocket is prototyped" >&5
31675$as_echo_n "checking if CloseSocket is prototyped... " >&6; }
31676 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31677/* end confdefs.h. */
31678
31679 $curl_includes_sys_socket
31680
31681_ACEOF
31682if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
31683 $EGREP "CloseSocket" >/dev/null 2>&1; then :
31684
31685 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31686$as_echo "yes" >&6; }
31687 tst_proto_closesocket_camel="yes"
31688
31689else
31690
31691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31692$as_echo "no" >&6; }
31693 tst_proto_closesocket_camel="no"
31694
31695fi
31696rm -f conftest*
31697
31698 fi
31699 #
31700 if test "$tst_proto_closesocket_camel" = "yes"; then
31701 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if CloseSocket is compilable" >&5
31702$as_echo_n "checking if CloseSocket is compilable... " >&6; }
31703 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31704/* end confdefs.h. */
31705
31706
31707 $curl_includes_sys_socket
31708
31709int main (void)
31710{
31711
31712 if(0 != CloseSocket(0))
31713 return 1;
31714
31715 ;
31716 return 0;
31717}
31718
31719_ACEOF
31720if ac_fn_c_try_compile "$LINENO"; then :
31721
31722 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31723$as_echo "yes" >&6; }
31724 tst_compi_closesocket_camel="yes"
31725
31726else
31727
31728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31729$as_echo "no" >&6; }
31730 tst_compi_closesocket_camel="no"
31731
31732fi
31733rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31734 fi
31735 #
31736 if test "$tst_compi_closesocket_camel" = "yes"; then
31737 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if CloseSocket usage allowed" >&5
31738$as_echo_n "checking if CloseSocket usage allowed... " >&6; }
31739 if test "x$curl_disallow_closesocket_camel" != "xyes"; then
31740 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31741$as_echo "yes" >&6; }
31742 tst_allow_closesocket_camel="yes"
31743 else
31744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31745$as_echo "no" >&6; }
31746 tst_allow_closesocket_camel="no"
31747 fi
31748 fi
31749 #
31750 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if CloseSocket might be used" >&5
31751$as_echo_n "checking if CloseSocket might be used... " >&6; }
31752 if test "$tst_links_closesocket_camel" = "yes" &&
31753 test "$tst_proto_closesocket_camel" = "yes" &&
31754 test "$tst_compi_closesocket_camel" = "yes" &&
31755 test "$tst_allow_closesocket_camel" = "yes"; then
31756 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31757$as_echo "yes" >&6; }
31758
31759cat >>confdefs.h <<_ACEOF
31760#define HAVE_CLOSESOCKET_CAMEL 1
31761_ACEOF
31762
31763 curl_cv_func_closesocket_camel="yes"
31764 else
31765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31766$as_echo "no" >&6; }
31767 curl_cv_func_closesocket_camel="no"
31768 fi
31769
31770
31771 #
31772 tst_links_connect="unknown"
31773 tst_proto_connect="unknown"
31774 tst_compi_connect="unknown"
31775 tst_allow_connect="unknown"
31776 #
31777 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if connect can be linked" >&5
31778$as_echo_n "checking if connect can be linked... " >&6; }
31779 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31780/* end confdefs.h. */
31781
31782
31783 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070031784 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070031785 $curl_includes_sys_socket
31786 $curl_includes_socket
31787
31788int main (void)
31789{
31790
31791 if(0 != connect(0, 0, 0))
31792 return 1;
31793
31794 ;
31795 return 0;
31796}
31797
31798_ACEOF
31799if ac_fn_c_try_link "$LINENO"; then :
31800
31801 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31802$as_echo "yes" >&6; }
31803 tst_links_connect="yes"
31804
31805else
31806
31807 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31808$as_echo "no" >&6; }
31809 tst_links_connect="no"
31810
31811fi
31812rm -f core conftest.err conftest.$ac_objext \
31813 conftest$ac_exeext conftest.$ac_ext
31814 #
31815 if test "$tst_links_connect" = "yes"; then
31816 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if connect is prototyped" >&5
31817$as_echo_n "checking if connect is prototyped... " >&6; }
31818 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31819/* end confdefs.h. */
31820
31821 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070031822 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070031823 $curl_includes_sys_socket
31824 $curl_includes_socket
31825
31826_ACEOF
31827if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
31828 $EGREP "connect" >/dev/null 2>&1; then :
31829
31830 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31831$as_echo "yes" >&6; }
31832 tst_proto_connect="yes"
31833
31834else
31835
31836 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31837$as_echo "no" >&6; }
31838 tst_proto_connect="no"
31839
31840fi
31841rm -f conftest*
31842
31843 fi
31844 #
31845 if test "$tst_proto_connect" = "yes"; then
31846 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if connect is compilable" >&5
31847$as_echo_n "checking if connect is compilable... " >&6; }
31848 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31849/* end confdefs.h. */
31850
31851
31852 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070031853 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070031854 $curl_includes_sys_socket
31855 $curl_includes_socket
31856
31857int main (void)
31858{
31859
31860 if(0 != connect(0, 0, 0))
31861 return 1;
31862
31863 ;
31864 return 0;
31865}
31866
31867_ACEOF
31868if ac_fn_c_try_compile "$LINENO"; then :
31869
31870 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31871$as_echo "yes" >&6; }
31872 tst_compi_connect="yes"
31873
31874else
31875
31876 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31877$as_echo "no" >&6; }
31878 tst_compi_connect="no"
31879
31880fi
31881rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31882 fi
31883 #
31884 if test "$tst_compi_connect" = "yes"; then
31885 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if connect usage allowed" >&5
31886$as_echo_n "checking if connect usage allowed... " >&6; }
31887 if test "x$curl_disallow_connect" != "xyes"; then
31888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31889$as_echo "yes" >&6; }
31890 tst_allow_connect="yes"
31891 else
31892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31893$as_echo "no" >&6; }
31894 tst_allow_connect="no"
31895 fi
31896 fi
31897 #
31898 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if connect might be used" >&5
31899$as_echo_n "checking if connect might be used... " >&6; }
31900 if test "$tst_links_connect" = "yes" &&
31901 test "$tst_proto_connect" = "yes" &&
31902 test "$tst_compi_connect" = "yes" &&
31903 test "$tst_allow_connect" = "yes"; then
31904 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31905$as_echo "yes" >&6; }
31906
31907cat >>confdefs.h <<_ACEOF
31908#define HAVE_CONNECT 1
31909_ACEOF
31910
31911 curl_cv_func_connect="yes"
31912 else
31913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31914$as_echo "no" >&6; }
31915 curl_cv_func_connect="no"
31916 fi
31917
31918
31919curl_includes_fcntl="\
31920/* includes start */
31921#ifdef HAVE_SYS_TYPES_H
31922# include <sys/types.h>
31923#endif
31924#ifdef HAVE_UNISTD_H
31925# include <unistd.h>
31926#endif
31927#ifdef HAVE_FCNTL_H
31928# include <fcntl.h>
31929#endif
31930/* includes end */"
31931 for ac_header in sys/types.h unistd.h fcntl.h
31932do :
31933 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
31934ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_fcntl
31935"
31936if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
31937 cat >>confdefs.h <<_ACEOF
31938#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
31939_ACEOF
31940
31941fi
31942
31943done
31944
31945
31946
31947 #
31948 tst_links_fcntl="unknown"
31949 tst_proto_fcntl="unknown"
31950 tst_compi_fcntl="unknown"
31951 tst_allow_fcntl="unknown"
31952 #
31953 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fcntl can be linked" >&5
31954$as_echo_n "checking if fcntl can be linked... " >&6; }
31955 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31956/* end confdefs.h. */
31957
31958
31959#define fcntl innocuous_fcntl
31960#ifdef __STDC__
31961# include <limits.h>
31962#else
31963# include <assert.h>
31964#endif
31965#undef fcntl
31966#ifdef __cplusplus
31967extern "C"
31968#endif
31969char fcntl ();
31970#if defined __stub_fcntl || defined __stub___fcntl
31971choke me
31972#endif
31973
31974int main (void)
31975{
31976return fcntl ();
31977 ;
31978 return 0;
31979}
31980
31981_ACEOF
31982if ac_fn_c_try_link "$LINENO"; then :
31983
31984 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31985$as_echo "yes" >&6; }
31986 tst_links_fcntl="yes"
31987
31988else
31989
31990 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31991$as_echo "no" >&6; }
31992 tst_links_fcntl="no"
31993
31994fi
31995rm -f core conftest.err conftest.$ac_objext \
31996 conftest$ac_exeext conftest.$ac_ext
31997 #
31998 if test "$tst_links_fcntl" = "yes"; then
31999 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fcntl is prototyped" >&5
32000$as_echo_n "checking if fcntl is prototyped... " >&6; }
32001 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32002/* end confdefs.h. */
32003
32004 $curl_includes_fcntl
32005
32006_ACEOF
32007if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
32008 $EGREP "fcntl" >/dev/null 2>&1; then :
32009
32010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32011$as_echo "yes" >&6; }
32012 tst_proto_fcntl="yes"
32013
32014else
32015
32016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32017$as_echo "no" >&6; }
32018 tst_proto_fcntl="no"
32019
32020fi
32021rm -f conftest*
32022
32023 fi
32024 #
32025 if test "$tst_proto_fcntl" = "yes"; then
32026 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fcntl is compilable" >&5
32027$as_echo_n "checking if fcntl is compilable... " >&6; }
32028 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32029/* end confdefs.h. */
32030
32031
32032 $curl_includes_fcntl
32033
32034int main (void)
32035{
32036
32037 if(0 != fcntl(0, 0, 0))
32038 return 1;
32039
32040 ;
32041 return 0;
32042}
32043
32044_ACEOF
32045if ac_fn_c_try_compile "$LINENO"; then :
32046
32047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32048$as_echo "yes" >&6; }
32049 tst_compi_fcntl="yes"
32050
32051else
32052
32053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32054$as_echo "no" >&6; }
32055 tst_compi_fcntl="no"
32056
32057fi
32058rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32059 fi
32060 #
32061 if test "$tst_compi_fcntl" = "yes"; then
32062 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fcntl usage allowed" >&5
32063$as_echo_n "checking if fcntl usage allowed... " >&6; }
32064 if test "x$curl_disallow_fcntl" != "xyes"; then
32065 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32066$as_echo "yes" >&6; }
32067 tst_allow_fcntl="yes"
32068 else
32069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32070$as_echo "no" >&6; }
32071 tst_allow_fcntl="no"
32072 fi
32073 fi
32074 #
32075 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fcntl might be used" >&5
32076$as_echo_n "checking if fcntl might be used... " >&6; }
32077 if test "$tst_links_fcntl" = "yes" &&
32078 test "$tst_proto_fcntl" = "yes" &&
32079 test "$tst_compi_fcntl" = "yes" &&
32080 test "$tst_allow_fcntl" = "yes"; then
32081 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32082$as_echo "yes" >&6; }
32083
32084cat >>confdefs.h <<_ACEOF
32085#define HAVE_FCNTL 1
32086_ACEOF
32087
32088 curl_cv_func_fcntl="yes"
32089
32090 #
32091 tst_compi_fcntl_o_nonblock="unknown"
32092 tst_allow_fcntl_o_nonblock="unknown"
32093 #
32094 case $host_os in
32095 sunos4* | aix3* | beos*)
32096 curl_disallow_fcntl_o_nonblock="yes"
32097 ;;
32098 esac
32099 #
32100 if test "$curl_cv_func_fcntl" = "yes"; then
32101 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fcntl O_NONBLOCK is compilable" >&5
32102$as_echo_n "checking if fcntl O_NONBLOCK is compilable... " >&6; }
32103 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32104/* end confdefs.h. */
32105
32106
32107 $curl_includes_fcntl
32108
32109int main (void)
32110{
32111
32112 int flags = 0;
32113 if(0 != fcntl(0, F_SETFL, flags | O_NONBLOCK))
32114 return 1;
32115
32116 ;
32117 return 0;
32118}
32119
32120_ACEOF
32121if ac_fn_c_try_compile "$LINENO"; then :
32122
32123 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32124$as_echo "yes" >&6; }
32125 tst_compi_fcntl_o_nonblock="yes"
32126
32127else
32128
32129 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32130$as_echo "no" >&6; }
32131 tst_compi_fcntl_o_nonblock="no"
32132
32133fi
32134rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32135 fi
32136 #
32137 if test "$tst_compi_fcntl_o_nonblock" = "yes"; then
32138 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fcntl O_NONBLOCK usage allowed" >&5
32139$as_echo_n "checking if fcntl O_NONBLOCK usage allowed... " >&6; }
32140 if test "x$curl_disallow_fcntl_o_nonblock" != "xyes"; then
32141 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32142$as_echo "yes" >&6; }
32143 tst_allow_fcntl_o_nonblock="yes"
32144 else
32145 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32146$as_echo "no" >&6; }
32147 tst_allow_fcntl_o_nonblock="no"
32148 fi
32149 fi
32150 #
32151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fcntl O_NONBLOCK might be used" >&5
32152$as_echo_n "checking if fcntl O_NONBLOCK might be used... " >&6; }
32153 if test "$tst_compi_fcntl_o_nonblock" = "yes" &&
32154 test "$tst_allow_fcntl_o_nonblock" = "yes"; then
32155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32156$as_echo "yes" >&6; }
32157
32158cat >>confdefs.h <<_ACEOF
32159#define HAVE_FCNTL_O_NONBLOCK 1
32160_ACEOF
32161
32162 curl_cv_func_fcntl_o_nonblock="yes"
32163 else
32164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32165$as_echo "no" >&6; }
32166 curl_cv_func_fcntl_o_nonblock="no"
32167 fi
32168
32169 else
32170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32171$as_echo "no" >&6; }
32172 curl_cv_func_fcntl="no"
32173 fi
32174
32175
Elliott Hughesa93fb052018-12-12 14:22:48 -080032176curl_includes_ws2tcpip="\
32177/* includes start */
32178#ifdef HAVE_WINDOWS_H
32179# ifndef WIN32_LEAN_AND_MEAN
32180# define WIN32_LEAN_AND_MEAN
32181# endif
32182# include <windows.h>
32183# ifdef HAVE_WINSOCK2_H
32184# include <winsock2.h>
32185# ifdef HAVE_WS2TCPIP_H
32186# include <ws2tcpip.h>
32187# endif
32188# endif
32189#endif
32190/* includes end */"
32191
32192 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for windows.h" >&5
32193$as_echo_n "checking for windows.h... " >&6; }
32194if ${curl_cv_header_windows_h+:} false; then :
32195 $as_echo_n "(cached) " >&6
32196else
32197
32198 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32199/* end confdefs.h. */
32200
32201
32202#undef inline
32203#ifndef WIN32_LEAN_AND_MEAN
32204#define WIN32_LEAN_AND_MEAN
32205#endif
32206#include <windows.h>
32207
32208int main (void)
32209{
32210
32211#if defined(__CYGWIN__) || defined(__CEGCC__)
32212 HAVE_WINDOWS_H shall not be defined.
32213#else
32214 int dummy=2*WINVER;
32215#endif
32216
32217 ;
32218 return 0;
32219}
32220
32221_ACEOF
32222if ac_fn_c_try_compile "$LINENO"; then :
32223
32224 curl_cv_header_windows_h="yes"
32225
32226else
32227
32228 curl_cv_header_windows_h="no"
32229
32230fi
32231rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32232
32233fi
32234{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_windows_h" >&5
32235$as_echo "$curl_cv_header_windows_h" >&6; }
32236 case "$curl_cv_header_windows_h" in
32237 yes)
32238
32239cat >>confdefs.h <<_ACEOF
32240#define HAVE_WINDOWS_H 1
32241_ACEOF
32242
32243 ;;
32244 esac
32245
32246
32247 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for winsock2.h" >&5
32248$as_echo_n "checking for winsock2.h... " >&6; }
32249if ${curl_cv_header_winsock2_h+:} false; then :
32250 $as_echo_n "(cached) " >&6
32251else
32252
32253 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32254/* end confdefs.h. */
32255
32256
32257#undef inline
32258#ifndef WIN32_LEAN_AND_MEAN
32259#define WIN32_LEAN_AND_MEAN
32260#endif
32261#include <windows.h>
32262#include <winsock2.h>
32263
32264int main (void)
32265{
32266
32267#if defined(__CYGWIN__) || defined(__CEGCC__) || defined(__MINGW32CE__)
32268 HAVE_WINSOCK2_H shall not be defined.
32269#else
32270 int dummy=2*IPPROTO_ESP;
32271#endif
32272
32273 ;
32274 return 0;
32275}
32276
32277_ACEOF
32278if ac_fn_c_try_compile "$LINENO"; then :
32279
32280 curl_cv_header_winsock2_h="yes"
32281
32282else
32283
32284 curl_cv_header_winsock2_h="no"
32285
32286fi
32287rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32288
32289fi
32290{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_winsock2_h" >&5
32291$as_echo "$curl_cv_header_winsock2_h" >&6; }
32292 case "$curl_cv_header_winsock2_h" in
32293 yes)
32294
32295cat >>confdefs.h <<_ACEOF
32296#define HAVE_WINSOCK2_H 1
32297_ACEOF
32298
32299 ;;
32300 esac
32301
32302
32303 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ws2tcpip.h" >&5
32304$as_echo_n "checking for ws2tcpip.h... " >&6; }
32305if ${curl_cv_header_ws2tcpip_h+:} false; then :
32306 $as_echo_n "(cached) " >&6
32307else
32308
32309 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32310/* end confdefs.h. */
32311
32312
32313#undef inline
32314#ifndef WIN32_LEAN_AND_MEAN
32315#define WIN32_LEAN_AND_MEAN
32316#endif
32317#include <windows.h>
32318#include <winsock2.h>
32319#include <ws2tcpip.h>
32320
32321int main (void)
32322{
32323
32324#if defined(__CYGWIN__) || defined(__CEGCC__) || defined(__MINGW32CE__)
32325 HAVE_WS2TCPIP_H shall not be defined.
32326#else
32327 int dummy=2*IP_PKTINFO;
32328#endif
32329
32330 ;
32331 return 0;
32332}
32333
32334_ACEOF
32335if ac_fn_c_try_compile "$LINENO"; then :
32336
32337 curl_cv_header_ws2tcpip_h="yes"
32338
32339else
32340
32341 curl_cv_header_ws2tcpip_h="no"
32342
32343fi
32344rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32345
32346fi
32347{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_ws2tcpip_h" >&5
32348$as_echo "$curl_cv_header_ws2tcpip_h" >&6; }
32349 case "$curl_cv_header_ws2tcpip_h" in
32350 yes)
32351
32352cat >>confdefs.h <<_ACEOF
32353#define HAVE_WS2TCPIP_H 1
32354_ACEOF
32355
32356 ;;
32357 esac
32358
32359
32360
Elliott Hughes82be86d2017-09-20 17:00:17 -070032361curl_includes_netdb="\
32362/* includes start */
32363#ifdef HAVE_SYS_TYPES_H
32364# include <sys/types.h>
32365#endif
32366#ifdef HAVE_NETDB_H
32367# include <netdb.h>
32368#endif
32369/* includes end */"
32370 for ac_header in sys/types.h netdb.h
32371do :
32372 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
32373ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_netdb
32374"
32375if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
32376 cat >>confdefs.h <<_ACEOF
32377#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
32378_ACEOF
32379
32380fi
32381
32382done
32383
32384
32385
32386 #
32387 tst_links_freeaddrinfo="unknown"
32388 tst_proto_freeaddrinfo="unknown"
32389 tst_compi_freeaddrinfo="unknown"
32390 tst_allow_freeaddrinfo="unknown"
32391 #
32392 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if freeaddrinfo can be linked" >&5
32393$as_echo_n "checking if freeaddrinfo can be linked... " >&6; }
32394 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32395/* end confdefs.h. */
32396
32397
32398 $curl_includes_ws2tcpip
32399 $curl_includes_sys_socket
32400 $curl_includes_netdb
32401
32402int main (void)
32403{
32404
32405 freeaddrinfo(0);
32406
32407 ;
32408 return 0;
32409}
32410
32411_ACEOF
32412if ac_fn_c_try_link "$LINENO"; then :
32413
32414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32415$as_echo "yes" >&6; }
32416 tst_links_freeaddrinfo="yes"
32417
32418else
32419
32420 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32421$as_echo "no" >&6; }
32422 tst_links_freeaddrinfo="no"
32423
32424fi
32425rm -f core conftest.err conftest.$ac_objext \
32426 conftest$ac_exeext conftest.$ac_ext
32427 #
32428 if test "$tst_links_freeaddrinfo" = "yes"; then
32429 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if freeaddrinfo is prototyped" >&5
32430$as_echo_n "checking if freeaddrinfo is prototyped... " >&6; }
32431 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32432/* end confdefs.h. */
32433
32434 $curl_includes_ws2tcpip
32435 $curl_includes_sys_socket
32436 $curl_includes_netdb
32437
32438_ACEOF
32439if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
32440 $EGREP "freeaddrinfo" >/dev/null 2>&1; then :
32441
32442 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32443$as_echo "yes" >&6; }
32444 tst_proto_freeaddrinfo="yes"
32445
32446else
32447
32448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32449$as_echo "no" >&6; }
32450 tst_proto_freeaddrinfo="no"
32451
32452fi
32453rm -f conftest*
32454
32455 fi
32456 #
32457 if test "$tst_proto_freeaddrinfo" = "yes"; then
32458 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if freeaddrinfo is compilable" >&5
32459$as_echo_n "checking if freeaddrinfo is compilable... " >&6; }
32460 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32461/* end confdefs.h. */
32462
32463
32464 $curl_includes_ws2tcpip
32465 $curl_includes_sys_socket
32466 $curl_includes_netdb
32467
32468int main (void)
32469{
32470
32471 freeaddrinfo(0);
32472
32473 ;
32474 return 0;
32475}
32476
32477_ACEOF
32478if ac_fn_c_try_compile "$LINENO"; then :
32479
32480 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32481$as_echo "yes" >&6; }
32482 tst_compi_freeaddrinfo="yes"
32483
32484else
32485
32486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32487$as_echo "no" >&6; }
32488 tst_compi_freeaddrinfo="no"
32489
32490fi
32491rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32492 fi
32493 #
32494 if test "$tst_compi_freeaddrinfo" = "yes"; then
32495 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if freeaddrinfo usage allowed" >&5
32496$as_echo_n "checking if freeaddrinfo usage allowed... " >&6; }
32497 if test "x$curl_disallow_freeaddrinfo" != "xyes"; then
32498 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32499$as_echo "yes" >&6; }
32500 tst_allow_freeaddrinfo="yes"
32501 else
32502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32503$as_echo "no" >&6; }
32504 tst_allow_freeaddrinfo="no"
32505 fi
32506 fi
32507 #
32508 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if freeaddrinfo might be used" >&5
32509$as_echo_n "checking if freeaddrinfo might be used... " >&6; }
32510 if test "$tst_links_freeaddrinfo" = "yes" &&
32511 test "$tst_proto_freeaddrinfo" = "yes" &&
32512 test "$tst_compi_freeaddrinfo" = "yes" &&
32513 test "$tst_allow_freeaddrinfo" = "yes"; then
32514 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32515$as_echo "yes" >&6; }
32516
32517cat >>confdefs.h <<_ACEOF
32518#define HAVE_FREEADDRINFO 1
32519_ACEOF
32520
32521 curl_cv_func_freeaddrinfo="yes"
32522 else
32523 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32524$as_echo "no" >&6; }
32525 curl_cv_func_freeaddrinfo="no"
32526 fi
32527
32528
32529curl_includes_ifaddrs="\
32530/* includes start */
32531#ifdef HAVE_SYS_TYPES_H
32532# include <sys/types.h>
32533#endif
32534#ifdef HAVE_SYS_SOCKET_H
32535# include <sys/socket.h>
32536#endif
32537#ifdef HAVE_NETINET_IN_H
32538# include <netinet/in.h>
32539#endif
32540#ifdef HAVE_IFADDRS_H
32541# include <ifaddrs.h>
32542#endif
32543/* includes end */"
32544 for ac_header in sys/types.h sys/socket.h netinet/in.h ifaddrs.h
32545do :
32546 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
32547ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_ifaddrs
32548"
32549if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
32550 cat >>confdefs.h <<_ACEOF
32551#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
32552_ACEOF
32553
32554fi
32555
32556done
32557
32558
32559
32560 #
32561 tst_links_freeifaddrs="unknown"
32562 tst_proto_freeifaddrs="unknown"
32563 tst_compi_freeifaddrs="unknown"
32564 tst_allow_freeifaddrs="unknown"
32565 #
32566 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if freeifaddrs can be linked" >&5
32567$as_echo_n "checking if freeifaddrs can be linked... " >&6; }
32568 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32569/* end confdefs.h. */
32570
32571
32572#define freeifaddrs innocuous_freeifaddrs
32573#ifdef __STDC__
32574# include <limits.h>
32575#else
32576# include <assert.h>
32577#endif
32578#undef freeifaddrs
32579#ifdef __cplusplus
32580extern "C"
32581#endif
32582char freeifaddrs ();
32583#if defined __stub_freeifaddrs || defined __stub___freeifaddrs
32584choke me
32585#endif
32586
32587int main (void)
32588{
32589return freeifaddrs ();
32590 ;
32591 return 0;
32592}
32593
32594_ACEOF
32595if ac_fn_c_try_link "$LINENO"; then :
32596
32597 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32598$as_echo "yes" >&6; }
32599 tst_links_freeifaddrs="yes"
32600
32601else
32602
32603 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32604$as_echo "no" >&6; }
32605 tst_links_freeifaddrs="no"
32606
32607fi
32608rm -f core conftest.err conftest.$ac_objext \
32609 conftest$ac_exeext conftest.$ac_ext
32610 #
32611 if test "$tst_links_freeifaddrs" = "yes"; then
32612 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if freeifaddrs is prototyped" >&5
32613$as_echo_n "checking if freeifaddrs is prototyped... " >&6; }
32614 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32615/* end confdefs.h. */
32616
32617 $curl_includes_ifaddrs
32618
32619_ACEOF
32620if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
32621 $EGREP "freeifaddrs" >/dev/null 2>&1; then :
32622
32623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32624$as_echo "yes" >&6; }
32625 tst_proto_freeifaddrs="yes"
32626
32627else
32628
32629 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32630$as_echo "no" >&6; }
32631 tst_proto_freeifaddrs="no"
32632
32633fi
32634rm -f conftest*
32635
32636 fi
32637 #
32638 if test "$tst_proto_freeifaddrs" = "yes"; then
32639 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if freeifaddrs is compilable" >&5
32640$as_echo_n "checking if freeifaddrs is compilable... " >&6; }
32641 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32642/* end confdefs.h. */
32643
32644
32645 $curl_includes_ifaddrs
32646
32647int main (void)
32648{
32649
32650 freeifaddrs(0);
32651
32652 ;
32653 return 0;
32654}
32655
32656_ACEOF
32657if ac_fn_c_try_compile "$LINENO"; then :
32658
32659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32660$as_echo "yes" >&6; }
32661 tst_compi_freeifaddrs="yes"
32662
32663else
32664
32665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32666$as_echo "no" >&6; }
32667 tst_compi_freeifaddrs="no"
32668
32669fi
32670rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32671 fi
32672 #
32673 if test "$tst_compi_freeifaddrs" = "yes"; then
32674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if freeifaddrs usage allowed" >&5
32675$as_echo_n "checking if freeifaddrs usage allowed... " >&6; }
32676 if test "x$curl_disallow_freeifaddrs" != "xyes"; then
32677 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32678$as_echo "yes" >&6; }
32679 tst_allow_freeifaddrs="yes"
32680 else
32681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32682$as_echo "no" >&6; }
32683 tst_allow_freeifaddrs="no"
32684 fi
32685 fi
32686 #
32687 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if freeifaddrs might be used" >&5
32688$as_echo_n "checking if freeifaddrs might be used... " >&6; }
32689 if test "$tst_links_freeifaddrs" = "yes" &&
32690 test "$tst_proto_freeifaddrs" = "yes" &&
32691 test "$tst_compi_freeifaddrs" = "yes" &&
32692 test "$tst_allow_freeifaddrs" = "yes"; then
32693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32694$as_echo "yes" >&6; }
32695
32696cat >>confdefs.h <<_ACEOF
32697#define HAVE_FREEIFADDRS 1
32698_ACEOF
32699
32700 curl_cv_func_freeifaddrs="yes"
32701 else
32702 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32703$as_echo "no" >&6; }
32704 curl_cv_func_freeifaddrs="no"
32705 fi
32706
32707
32708curl_includes_sys_xattr="\
32709/* includes start */
32710#ifdef HAVE_SYS_TYPES_H
32711# include <sys/types.h>
32712#endif
32713#ifdef HAVE_SYS_XATTR_H
32714# include <sys/xattr.h>
32715#endif
32716/* includes end */"
32717 for ac_header in sys/types.h sys/xattr.h
32718do :
32719 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
32720ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_sys_xattr
32721"
32722if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
32723 cat >>confdefs.h <<_ACEOF
32724#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
32725_ACEOF
32726
32727fi
32728
32729done
32730
32731
32732
32733 #
32734 tst_links_fsetxattr="unknown"
32735 tst_proto_fsetxattr="unknown"
32736 tst_compi_fsetxattr="unknown"
32737 tst_allow_fsetxattr="unknown"
32738 tst_nargs_fsetxattr="unknown"
32739 #
32740 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fsetxattr can be linked" >&5
32741$as_echo_n "checking if fsetxattr can be linked... " >&6; }
32742 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32743/* end confdefs.h. */
32744
32745
32746#define fsetxattr innocuous_fsetxattr
32747#ifdef __STDC__
32748# include <limits.h>
32749#else
32750# include <assert.h>
32751#endif
32752#undef fsetxattr
32753#ifdef __cplusplus
32754extern "C"
32755#endif
32756char fsetxattr ();
32757#if defined __stub_fsetxattr || defined __stub___fsetxattr
32758choke me
32759#endif
32760
32761int main (void)
32762{
32763return fsetxattr ();
32764 ;
32765 return 0;
32766}
32767
32768_ACEOF
32769if ac_fn_c_try_link "$LINENO"; then :
32770
32771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32772$as_echo "yes" >&6; }
32773 tst_links_fsetxattr="yes"
32774
32775else
32776
32777 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32778$as_echo "no" >&6; }
32779 tst_links_fsetxattr="no"
32780
32781fi
32782rm -f core conftest.err conftest.$ac_objext \
32783 conftest$ac_exeext conftest.$ac_ext
32784 #
32785 if test "$tst_links_fsetxattr" = "yes"; then
32786 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fsetxattr is prototyped" >&5
32787$as_echo_n "checking if fsetxattr is prototyped... " >&6; }
32788 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32789/* end confdefs.h. */
32790
32791 $curl_includes_sys_xattr
32792
32793_ACEOF
32794if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
32795 $EGREP "fsetxattr" >/dev/null 2>&1; then :
32796
32797 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32798$as_echo "yes" >&6; }
32799 tst_proto_fsetxattr="yes"
32800
32801else
32802
32803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32804$as_echo "no" >&6; }
32805 tst_proto_fsetxattr="no"
32806
32807fi
32808rm -f conftest*
32809
32810 fi
32811 #
32812 if test "$tst_proto_fsetxattr" = "yes"; then
32813 if test "$tst_nargs_fsetxattr" = "unknown"; then
32814 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fsetxattr takes 5 args." >&5
32815$as_echo_n "checking if fsetxattr takes 5 args.... " >&6; }
32816 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32817/* end confdefs.h. */
32818
32819
32820 $curl_includes_sys_xattr
32821
32822int main (void)
32823{
32824
32825 if(0 != fsetxattr(0, 0, 0, 0, 0))
32826 return 1;
32827
32828 ;
32829 return 0;
32830}
32831
32832_ACEOF
32833if ac_fn_c_try_compile "$LINENO"; then :
32834
32835 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32836$as_echo "yes" >&6; }
32837 tst_compi_fsetxattr="yes"
32838 tst_nargs_fsetxattr="5"
32839
32840else
32841
32842 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32843$as_echo "no" >&6; }
32844 tst_compi_fsetxattr="no"
32845
32846fi
32847rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32848 fi
32849 if test "$tst_nargs_fsetxattr" = "unknown"; then
32850 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fsetxattr takes 6 args." >&5
32851$as_echo_n "checking if fsetxattr takes 6 args.... " >&6; }
32852 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32853/* end confdefs.h. */
32854
32855
32856 $curl_includes_sys_xattr
32857
32858int main (void)
32859{
32860
32861 if(0 != fsetxattr(0, 0, 0, 0, 0, 0))
32862 return 1;
32863
32864 ;
32865 return 0;
32866}
32867
32868_ACEOF
32869if ac_fn_c_try_compile "$LINENO"; then :
32870
32871 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32872$as_echo "yes" >&6; }
32873 tst_compi_fsetxattr="yes"
32874 tst_nargs_fsetxattr="6"
32875
32876else
32877
32878 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32879$as_echo "no" >&6; }
32880 tst_compi_fsetxattr="no"
32881
32882fi
32883rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32884 fi
32885 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fsetxattr is compilable" >&5
32886$as_echo_n "checking if fsetxattr is compilable... " >&6; }
32887 if test "$tst_compi_fsetxattr" = "yes"; then
32888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32889$as_echo "yes" >&6; }
32890 else
32891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32892$as_echo "no" >&6; }
32893 fi
32894 fi
32895 #
32896 if test "$tst_compi_fsetxattr" = "yes"; then
32897 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fsetxattr usage allowed" >&5
32898$as_echo_n "checking if fsetxattr usage allowed... " >&6; }
32899 if test "x$curl_disallow_fsetxattr" != "xyes"; then
32900 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32901$as_echo "yes" >&6; }
32902 tst_allow_fsetxattr="yes"
32903 else
32904 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32905$as_echo "no" >&6; }
32906 tst_allow_fsetxattr="no"
32907 fi
32908 fi
32909 #
32910 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fsetxattr might be used" >&5
32911$as_echo_n "checking if fsetxattr might be used... " >&6; }
32912 if test "$tst_links_fsetxattr" = "yes" &&
32913 test "$tst_proto_fsetxattr" = "yes" &&
32914 test "$tst_compi_fsetxattr" = "yes" &&
32915 test "$tst_allow_fsetxattr" = "yes"; then
32916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32917$as_echo "yes" >&6; }
32918
32919cat >>confdefs.h <<_ACEOF
32920#define HAVE_FSETXATTR 1
32921_ACEOF
32922
32923 #
32924 if test "$tst_nargs_fsetxattr" -eq "5"; then
32925
32926$as_echo "#define HAVE_FSETXATTR_5 1" >>confdefs.h
32927
32928 elif test "$tst_nargs_fsetxattr" -eq "6"; then
32929
32930$as_echo "#define HAVE_FSETXATTR_6 1" >>confdefs.h
32931
32932 fi
32933 #
32934 curl_cv_func_fsetxattr="yes"
32935 else
32936 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32937$as_echo "no" >&6; }
32938 curl_cv_func_fsetxattr="no"
32939 fi
32940
32941
32942 #
32943 tst_links_ftruncate="unknown"
32944 tst_proto_ftruncate="unknown"
32945 tst_compi_ftruncate="unknown"
32946 tst_allow_ftruncate="unknown"
32947 #
32948 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ftruncate can be linked" >&5
32949$as_echo_n "checking if ftruncate can be linked... " >&6; }
32950 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32951/* end confdefs.h. */
32952
32953
32954#define ftruncate innocuous_ftruncate
32955#ifdef __STDC__
32956# include <limits.h>
32957#else
32958# include <assert.h>
32959#endif
32960#undef ftruncate
32961#ifdef __cplusplus
32962extern "C"
32963#endif
32964char ftruncate ();
32965#if defined __stub_ftruncate || defined __stub___ftruncate
32966choke me
32967#endif
32968
32969int main (void)
32970{
32971return ftruncate ();
32972 ;
32973 return 0;
32974}
32975
32976_ACEOF
32977if ac_fn_c_try_link "$LINENO"; then :
32978
32979 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32980$as_echo "yes" >&6; }
32981 tst_links_ftruncate="yes"
32982
32983else
32984
32985 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32986$as_echo "no" >&6; }
32987 tst_links_ftruncate="no"
32988
32989fi
32990rm -f core conftest.err conftest.$ac_objext \
32991 conftest$ac_exeext conftest.$ac_ext
32992 #
32993 if test "$tst_links_ftruncate" = "yes"; then
32994 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ftruncate is prototyped" >&5
32995$as_echo_n "checking if ftruncate is prototyped... " >&6; }
32996 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32997/* end confdefs.h. */
32998
32999 $curl_includes_unistd
33000
33001_ACEOF
33002if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
33003 $EGREP "ftruncate" >/dev/null 2>&1; then :
33004
33005 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33006$as_echo "yes" >&6; }
33007 tst_proto_ftruncate="yes"
33008
33009else
33010
33011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33012$as_echo "no" >&6; }
33013 tst_proto_ftruncate="no"
33014
33015fi
33016rm -f conftest*
33017
33018 fi
33019 #
33020 if test "$tst_proto_ftruncate" = "yes"; then
33021 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ftruncate is compilable" >&5
33022$as_echo_n "checking if ftruncate is compilable... " >&6; }
33023 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33024/* end confdefs.h. */
33025
33026
33027 $curl_includes_unistd
33028
33029int main (void)
33030{
33031
33032 if(0 != ftruncate(0, 0))
33033 return 1;
33034
33035 ;
33036 return 0;
33037}
33038
33039_ACEOF
33040if ac_fn_c_try_compile "$LINENO"; then :
33041
33042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33043$as_echo "yes" >&6; }
33044 tst_compi_ftruncate="yes"
33045
33046else
33047
33048 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33049$as_echo "no" >&6; }
33050 tst_compi_ftruncate="no"
33051
33052fi
33053rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33054 fi
33055 #
33056 if test "$tst_compi_ftruncate" = "yes"; then
33057 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ftruncate usage allowed" >&5
33058$as_echo_n "checking if ftruncate usage allowed... " >&6; }
33059 if test "x$curl_disallow_ftruncate" != "xyes"; then
33060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33061$as_echo "yes" >&6; }
33062 tst_allow_ftruncate="yes"
33063 else
33064 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33065$as_echo "no" >&6; }
33066 tst_allow_ftruncate="no"
33067 fi
33068 fi
33069 #
33070 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ftruncate might be used" >&5
33071$as_echo_n "checking if ftruncate might be used... " >&6; }
33072 if test "$tst_links_ftruncate" = "yes" &&
33073 test "$tst_proto_ftruncate" = "yes" &&
33074 test "$tst_compi_ftruncate" = "yes" &&
33075 test "$tst_allow_ftruncate" = "yes"; then
33076 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33077$as_echo "yes" >&6; }
33078
33079cat >>confdefs.h <<_ACEOF
33080#define HAVE_FTRUNCATE 1
33081_ACEOF
33082
33083 curl_cv_func_ftruncate="yes"
33084 else
33085 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33086$as_echo "no" >&6; }
33087 curl_cv_func_ftruncate="no"
33088 fi
33089
33090
33091curl_includes_stdlib="\
33092/* includes start */
33093#ifdef HAVE_SYS_TYPES_H
33094# include <sys/types.h>
33095#endif
33096#ifdef HAVE_STDLIB_H
33097# include <stdlib.h>
33098#endif
33099/* includes end */"
33100 for ac_header in sys/types.h stdlib.h
33101do :
33102 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
33103ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_stdlib
33104"
33105if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
33106 cat >>confdefs.h <<_ACEOF
33107#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
33108_ACEOF
33109
33110fi
33111
33112done
33113
33114
33115
33116 #
33117 tst_links_getaddrinfo="unknown"
33118 tst_proto_getaddrinfo="unknown"
33119 tst_compi_getaddrinfo="unknown"
33120 tst_works_getaddrinfo="unknown"
33121 tst_allow_getaddrinfo="unknown"
33122 tst_tsafe_getaddrinfo="unknown"
33123 #
33124 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getaddrinfo can be linked" >&5
33125$as_echo_n "checking if getaddrinfo can be linked... " >&6; }
33126 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33127/* end confdefs.h. */
33128
33129
33130 $curl_includes_ws2tcpip
33131 $curl_includes_sys_socket
33132 $curl_includes_netdb
33133
33134int main (void)
33135{
33136
33137 if(0 != getaddrinfo(0, 0, 0, 0))
33138 return 1;
33139
33140 ;
33141 return 0;
33142}
33143
33144_ACEOF
33145if ac_fn_c_try_link "$LINENO"; then :
33146
33147 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33148$as_echo "yes" >&6; }
33149 tst_links_getaddrinfo="yes"
33150
33151else
33152
33153 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33154$as_echo "no" >&6; }
33155 tst_links_getaddrinfo="no"
33156
33157fi
33158rm -f core conftest.err conftest.$ac_objext \
33159 conftest$ac_exeext conftest.$ac_ext
33160 #
33161 if test "$tst_links_getaddrinfo" = "yes"; then
33162 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getaddrinfo is prototyped" >&5
33163$as_echo_n "checking if getaddrinfo is prototyped... " >&6; }
33164 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33165/* end confdefs.h. */
33166
33167 $curl_includes_ws2tcpip
33168 $curl_includes_sys_socket
33169 $curl_includes_netdb
33170
33171_ACEOF
33172if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
33173 $EGREP "getaddrinfo" >/dev/null 2>&1; then :
33174
33175 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33176$as_echo "yes" >&6; }
33177 tst_proto_getaddrinfo="yes"
33178
33179else
33180
33181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33182$as_echo "no" >&6; }
33183 tst_proto_getaddrinfo="no"
33184
33185fi
33186rm -f conftest*
33187
33188 fi
33189 #
33190 if test "$tst_proto_getaddrinfo" = "yes"; then
33191 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getaddrinfo is compilable" >&5
33192$as_echo_n "checking if getaddrinfo is compilable... " >&6; }
33193 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33194/* end confdefs.h. */
33195
33196
33197 $curl_includes_ws2tcpip
33198 $curl_includes_sys_socket
33199 $curl_includes_netdb
33200
33201int main (void)
33202{
33203
33204 if(0 != getaddrinfo(0, 0, 0, 0))
33205 return 1;
33206
33207 ;
33208 return 0;
33209}
33210
33211_ACEOF
33212if ac_fn_c_try_compile "$LINENO"; then :
33213
33214 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33215$as_echo "yes" >&6; }
33216 tst_compi_getaddrinfo="yes"
33217
33218else
33219
33220 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33221$as_echo "no" >&6; }
33222 tst_compi_getaddrinfo="no"
33223
33224fi
33225rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33226 fi
33227 #
33228 if test "x$cross_compiling" != "xyes" &&
33229 test "$tst_compi_getaddrinfo" = "yes"; then
33230 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getaddrinfo seems to work" >&5
33231$as_echo_n "checking if getaddrinfo seems to work... " >&6; }
Elliott Hughesa93fb052018-12-12 14:22:48 -080033232
33233
33234 old=$LD_LIBRARY_PATH
33235 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
33236 export LD_LIBRARY_PATH
33237 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070033238 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
33239$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
33240as_fn_error $? "cannot run test program while cross compiling
33241See \`config.log' for more details" "$LINENO" 5; }
33242else
33243 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33244/* end confdefs.h. */
33245
33246
33247 $curl_includes_ws2tcpip
33248 $curl_includes_stdlib
33249 $curl_includes_string
33250 $curl_includes_sys_socket
33251 $curl_includes_netdb
33252
33253int main (void)
33254{
33255
33256 struct addrinfo hints;
33257 struct addrinfo *ai = 0;
33258 int error;
33259
33260 #ifdef HAVE_WINSOCK2_H
33261 WSADATA wsa;
33262 if (WSAStartup(MAKEWORD(2,2), &wsa))
33263 exit(2);
33264 #endif
33265
33266 memset(&hints, 0, sizeof(hints));
33267 hints.ai_flags = AI_NUMERICHOST;
33268 hints.ai_family = AF_UNSPEC;
33269 hints.ai_socktype = SOCK_STREAM;
33270 error = getaddrinfo("127.0.0.1", 0, &hints, &ai);
33271 if(error || !ai)
33272 exit(1); /* fail */
33273 else
33274 exit(0);
33275
33276 ;
33277 return 0;
33278}
33279
33280_ACEOF
33281if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughesa93fb052018-12-12 14:22:48 -080033282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070033283$as_echo "yes" >&6; }
33284 tst_works_getaddrinfo="yes"
33285
33286else
Elliott Hughesa93fb052018-12-12 14:22:48 -080033287 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070033288$as_echo "no" >&6; }
33289 tst_works_getaddrinfo="no"
33290
33291fi
33292rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
33293 conftest.$ac_objext conftest.beam conftest.$ac_ext
33294fi
33295
Elliott Hughesa93fb052018-12-12 14:22:48 -080033296 LD_LIBRARY_PATH=$old # restore
33297
Elliott Hughes82be86d2017-09-20 17:00:17 -070033298 fi
33299 #
33300 if test "$tst_compi_getaddrinfo" = "yes" &&
33301 test "$tst_works_getaddrinfo" != "no"; then
33302 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getaddrinfo usage allowed" >&5
33303$as_echo_n "checking if getaddrinfo usage allowed... " >&6; }
33304 if test "x$curl_disallow_getaddrinfo" != "xyes"; then
33305 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33306$as_echo "yes" >&6; }
33307 tst_allow_getaddrinfo="yes"
33308 else
33309 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33310$as_echo "no" >&6; }
33311 tst_allow_getaddrinfo="no"
33312 fi
33313 fi
33314 #
33315 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getaddrinfo might be used" >&5
33316$as_echo_n "checking if getaddrinfo might be used... " >&6; }
33317 if test "$tst_links_getaddrinfo" = "yes" &&
33318 test "$tst_proto_getaddrinfo" = "yes" &&
33319 test "$tst_compi_getaddrinfo" = "yes" &&
33320 test "$tst_allow_getaddrinfo" = "yes" &&
33321 test "$tst_works_getaddrinfo" != "no"; then
33322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33323$as_echo "yes" >&6; }
33324
33325cat >>confdefs.h <<_ACEOF
33326#define HAVE_GETADDRINFO 1
33327_ACEOF
33328
33329 curl_cv_func_getaddrinfo="yes"
33330 else
33331 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33332$as_echo "no" >&6; }
33333 curl_cv_func_getaddrinfo="no"
33334 curl_cv_func_getaddrinfo_threadsafe="no"
33335 fi
33336 #
33337 if test "$curl_cv_func_getaddrinfo" = "yes"; then
33338 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getaddrinfo is threadsafe" >&5
33339$as_echo_n "checking if getaddrinfo is threadsafe... " >&6; }
33340 case $host_os in
33341 aix[1234].* | aix5.[01].*)
33342 tst_tsafe_getaddrinfo="no"
33343 ;;
33344 aix*)
33345 tst_tsafe_getaddrinfo="yes"
33346 ;;
33347 darwin[12345].*)
33348 tst_tsafe_getaddrinfo="no"
33349 ;;
33350 darwin*)
33351 tst_tsafe_getaddrinfo="yes"
33352 ;;
33353 freebsd[1234].* | freebsd5.[1234]*)
33354 tst_tsafe_getaddrinfo="no"
33355 ;;
33356 freebsd*)
33357 tst_tsafe_getaddrinfo="yes"
33358 ;;
33359 hpux[123456789].* | hpux10.* | hpux11.0* | hpux11.10*)
33360 tst_tsafe_getaddrinfo="no"
33361 ;;
33362 hpux*)
33363 tst_tsafe_getaddrinfo="yes"
33364 ;;
33365 netbsd[123].*)
33366 tst_tsafe_getaddrinfo="no"
33367 ;;
33368 netbsd*)
33369 tst_tsafe_getaddrinfo="yes"
33370 ;;
33371 *bsd*)
33372 tst_tsafe_getaddrinfo="no"
33373 ;;
33374 solaris2*)
33375 tst_tsafe_getaddrinfo="yes"
33376 ;;
33377 esac
33378 if test "$tst_tsafe_getaddrinfo" = "unknown" &&
33379 test "$curl_cv_native_windows" = "yes"; then
33380 tst_tsafe_getaddrinfo="yes"
33381 fi
33382 if test "$tst_tsafe_getaddrinfo" = "unknown"; then
33383
33384
33385 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33386/* end confdefs.h. */
33387
33388
33389 $curl_includes_sys_socket
33390 $curl_includes_netdb
33391
33392int main (void)
33393{
33394#ifdef h_errno
33395 return 0;
33396#else
33397 force compilation error
33398#endif
33399}
33400
33401
33402_ACEOF
33403if ac_fn_c_try_compile "$LINENO"; then :
33404
33405 tst_symbol_defined="yes"
33406
33407else
33408
33409 tst_symbol_defined="no"
33410
33411fi
33412rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33413 if test "$tst_symbol_defined" = "yes"; then
33414 curl_cv_have_def_h_errno=yes
33415
33416 else
33417 curl_cv_have_def_h_errno=no
33418
33419 fi
33420
33421 if test "$curl_cv_have_def_h_errno" = "yes"; then
33422 tst_h_errno_macro="yes"
33423 else
33424 tst_h_errno_macro="no"
33425 fi
33426 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33427/* end confdefs.h. */
33428
33429
33430 $curl_includes_sys_socket
33431 $curl_includes_netdb
33432
33433int main (void)
33434{
33435
33436 h_errno = 2;
33437 if(0 != h_errno)
33438 return 1;
33439
33440 ;
33441 return 0;
33442}
33443
33444_ACEOF
33445if ac_fn_c_try_compile "$LINENO"; then :
33446
33447 tst_h_errno_modifiable_lvalue="yes"
33448
33449else
33450
33451 tst_h_errno_modifiable_lvalue="no"
33452
33453fi
33454rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33455 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33456/* end confdefs.h. */
33457
33458
33459
33460int main (void)
33461{
33462
33463#if defined(_POSIX_C_SOURCE) && (_POSIX_C_SOURCE >= 200809L)
33464 return 0;
33465#elif defined(_XOPEN_SOURCE) && (_XOPEN_SOURCE >= 700)
33466 return 0;
33467#else
33468 force compilation error
33469#endif
33470
33471 ;
33472 return 0;
33473}
33474
33475_ACEOF
33476if ac_fn_c_try_compile "$LINENO"; then :
33477
33478 tst_h_errno_sbs_issue_7="yes"
33479
33480else
33481
33482 tst_h_errno_sbs_issue_7="no"
33483
33484fi
33485rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33486 if test "$tst_h_errno_macro" = "no" &&
33487 test "$tst_h_errno_modifiable_lvalue" = "no" &&
33488 test "$tst_h_errno_sbs_issue_7" = "no"; then
33489 tst_tsafe_getaddrinfo="no"
33490 else
33491 tst_tsafe_getaddrinfo="yes"
33492 fi
33493 fi
33494 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tst_tsafe_getaddrinfo" >&5
33495$as_echo "$tst_tsafe_getaddrinfo" >&6; }
33496 if test "$tst_tsafe_getaddrinfo" = "yes"; then
33497
33498cat >>confdefs.h <<_ACEOF
33499#define HAVE_GETADDRINFO_THREADSAFE 1
33500_ACEOF
33501
33502 curl_cv_func_getaddrinfo_threadsafe="yes"
33503 else
33504 curl_cv_func_getaddrinfo_threadsafe="no"
33505 fi
33506 fi
33507
33508
33509 #
33510 tst_links_gai_strerror="unknown"
33511 tst_proto_gai_strerror="unknown"
33512 tst_compi_gai_strerror="unknown"
33513 tst_allow_gai_strerror="unknown"
33514 #
33515 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gai_strerror can be linked" >&5
33516$as_echo_n "checking if gai_strerror can be linked... " >&6; }
33517 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33518/* end confdefs.h. */
33519
33520
33521 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070033522 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070033523 $curl_includes_netdb
33524
33525int main (void)
33526{
33527
33528 if(0 != gai_strerror(0))
33529 return 1;
33530
33531 ;
33532 return 0;
33533}
33534
33535_ACEOF
33536if ac_fn_c_try_link "$LINENO"; then :
33537
33538 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33539$as_echo "yes" >&6; }
33540 tst_links_gai_strerror="yes"
33541
33542else
33543
33544 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33545$as_echo "no" >&6; }
33546 tst_links_gai_strerror="no"
33547
33548fi
33549rm -f core conftest.err conftest.$ac_objext \
33550 conftest$ac_exeext conftest.$ac_ext
33551 #
33552 if test "$tst_links_gai_strerror" = "yes"; then
33553 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gai_strerror is prototyped" >&5
33554$as_echo_n "checking if gai_strerror is prototyped... " >&6; }
33555 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33556/* end confdefs.h. */
33557
33558 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070033559 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070033560 $curl_includes_netdb
33561
33562_ACEOF
33563if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
33564 $EGREP "gai_strerror" >/dev/null 2>&1; then :
33565
33566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33567$as_echo "yes" >&6; }
33568 tst_proto_gai_strerror="yes"
33569
33570else
33571
33572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33573$as_echo "no" >&6; }
33574 tst_proto_gai_strerror="no"
33575
33576fi
33577rm -f conftest*
33578
33579 fi
33580 #
33581 if test "$tst_proto_gai_strerror" = "yes"; then
33582 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gai_strerror is compilable" >&5
33583$as_echo_n "checking if gai_strerror is compilable... " >&6; }
33584 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33585/* end confdefs.h. */
33586
33587
33588 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070033589 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070033590 $curl_includes_netdb
33591
33592int main (void)
33593{
33594
33595 if(0 != gai_strerror(0))
33596 return 1;
33597
33598 ;
33599 return 0;
33600}
33601
33602_ACEOF
33603if ac_fn_c_try_compile "$LINENO"; then :
33604
33605 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33606$as_echo "yes" >&6; }
33607 tst_compi_gai_strerror="yes"
33608
33609else
33610
33611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33612$as_echo "no" >&6; }
33613 tst_compi_gai_strerror="no"
33614
33615fi
33616rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33617 fi
33618 #
33619 if test "$tst_compi_gai_strerror" = "yes"; then
33620 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gai_strerror usage allowed" >&5
33621$as_echo_n "checking if gai_strerror usage allowed... " >&6; }
33622 if test "x$curl_disallow_gai_strerror" != "xyes"; then
33623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33624$as_echo "yes" >&6; }
33625 tst_allow_gai_strerror="yes"
33626 else
33627 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33628$as_echo "no" >&6; }
33629 tst_allow_gai_strerror="no"
33630 fi
33631 fi
33632 #
33633 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gai_strerror might be used" >&5
33634$as_echo_n "checking if gai_strerror might be used... " >&6; }
33635 if test "$tst_links_gai_strerror" = "yes" &&
33636 test "$tst_proto_gai_strerror" = "yes" &&
33637 test "$tst_compi_gai_strerror" = "yes" &&
33638 test "$tst_allow_gai_strerror" = "yes"; then
33639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33640$as_echo "yes" >&6; }
33641
33642cat >>confdefs.h <<_ACEOF
33643#define HAVE_GAI_STRERROR 1
33644_ACEOF
33645
33646 curl_cv_func_gai_strerror="yes"
33647 else
33648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33649$as_echo "no" >&6; }
33650 curl_cv_func_gai_strerror="no"
33651 fi
33652
33653
33654 #
33655 tst_links_gethostbyaddr="unknown"
33656 tst_proto_gethostbyaddr="unknown"
33657 tst_compi_gethostbyaddr="unknown"
33658 tst_allow_gethostbyaddr="unknown"
33659 #
33660 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyaddr can be linked" >&5
33661$as_echo_n "checking if gethostbyaddr can be linked... " >&6; }
33662 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33663/* end confdefs.h. */
33664
33665
33666 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070033667 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070033668 $curl_includes_netdb
33669
33670int main (void)
33671{
33672
33673 if(0 != gethostbyaddr(0, 0, 0))
33674 return 1;
33675
33676 ;
33677 return 0;
33678}
33679
33680_ACEOF
33681if ac_fn_c_try_link "$LINENO"; then :
33682
33683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33684$as_echo "yes" >&6; }
33685 tst_links_gethostbyaddr="yes"
33686
33687else
33688
33689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33690$as_echo "no" >&6; }
33691 tst_links_gethostbyaddr="no"
33692
33693fi
33694rm -f core conftest.err conftest.$ac_objext \
33695 conftest$ac_exeext conftest.$ac_ext
33696 #
33697 if test "$tst_links_gethostbyaddr" = "yes"; then
33698 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyaddr is prototyped" >&5
33699$as_echo_n "checking if gethostbyaddr is prototyped... " >&6; }
33700 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33701/* end confdefs.h. */
33702
33703 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070033704 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070033705 $curl_includes_netdb
33706
33707_ACEOF
33708if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
33709 $EGREP "gethostbyaddr" >/dev/null 2>&1; then :
33710
33711 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33712$as_echo "yes" >&6; }
33713 tst_proto_gethostbyaddr="yes"
33714
33715else
33716
33717 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33718$as_echo "no" >&6; }
33719 tst_proto_gethostbyaddr="no"
33720
33721fi
33722rm -f conftest*
33723
33724 fi
33725 #
33726 if test "$tst_proto_gethostbyaddr" = "yes"; then
33727 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyaddr is compilable" >&5
33728$as_echo_n "checking if gethostbyaddr is compilable... " >&6; }
33729 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33730/* end confdefs.h. */
33731
33732
33733 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070033734 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070033735 $curl_includes_netdb
33736
33737int main (void)
33738{
33739
33740 if(0 != gethostbyaddr(0, 0, 0))
33741 return 1;
33742
33743 ;
33744 return 0;
33745}
33746
33747_ACEOF
33748if ac_fn_c_try_compile "$LINENO"; then :
33749
33750 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33751$as_echo "yes" >&6; }
33752 tst_compi_gethostbyaddr="yes"
33753
33754else
33755
33756 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33757$as_echo "no" >&6; }
33758 tst_compi_gethostbyaddr="no"
33759
33760fi
33761rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33762 fi
33763 #
33764 if test "$tst_compi_gethostbyaddr" = "yes"; then
33765 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyaddr usage allowed" >&5
33766$as_echo_n "checking if gethostbyaddr usage allowed... " >&6; }
33767 if test "x$curl_disallow_gethostbyaddr" != "xyes"; then
33768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33769$as_echo "yes" >&6; }
33770 tst_allow_gethostbyaddr="yes"
33771 else
33772 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33773$as_echo "no" >&6; }
33774 tst_allow_gethostbyaddr="no"
33775 fi
33776 fi
33777 #
33778 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyaddr might be used" >&5
33779$as_echo_n "checking if gethostbyaddr might be used... " >&6; }
33780 if test "$tst_links_gethostbyaddr" = "yes" &&
33781 test "$tst_proto_gethostbyaddr" = "yes" &&
33782 test "$tst_compi_gethostbyaddr" = "yes" &&
33783 test "$tst_allow_gethostbyaddr" = "yes"; then
33784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33785$as_echo "yes" >&6; }
33786
33787cat >>confdefs.h <<_ACEOF
33788#define HAVE_GETHOSTBYADDR 1
33789_ACEOF
33790
33791 curl_cv_func_gethostbyaddr="yes"
33792 else
33793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33794$as_echo "no" >&6; }
33795 curl_cv_func_gethostbyaddr="no"
33796 fi
33797
33798
33799 #
33800 tst_links_gethostbyaddr_r="unknown"
33801 tst_proto_gethostbyaddr_r="unknown"
33802 tst_compi_gethostbyaddr_r="unknown"
33803 tst_allow_gethostbyaddr_r="unknown"
33804 tst_nargs_gethostbyaddr_r="unknown"
33805 #
33806 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyaddr_r can be linked" >&5
33807$as_echo_n "checking if gethostbyaddr_r can be linked... " >&6; }
33808 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33809/* end confdefs.h. */
33810
33811
33812#define gethostbyaddr_r innocuous_gethostbyaddr_r
33813#ifdef __STDC__
33814# include <limits.h>
33815#else
33816# include <assert.h>
33817#endif
33818#undef gethostbyaddr_r
33819#ifdef __cplusplus
33820extern "C"
33821#endif
33822char gethostbyaddr_r ();
33823#if defined __stub_gethostbyaddr_r || defined __stub___gethostbyaddr_r
33824choke me
33825#endif
33826
33827int main (void)
33828{
33829return gethostbyaddr_r ();
33830 ;
33831 return 0;
33832}
33833
33834_ACEOF
33835if ac_fn_c_try_link "$LINENO"; then :
33836
33837 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33838$as_echo "yes" >&6; }
33839 tst_links_gethostbyaddr_r="yes"
33840
33841else
33842
33843 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33844$as_echo "no" >&6; }
33845 tst_links_gethostbyaddr_r="no"
33846
33847fi
33848rm -f core conftest.err conftest.$ac_objext \
33849 conftest$ac_exeext conftest.$ac_ext
33850 #
33851 if test "$tst_links_gethostbyaddr_r" = "yes"; then
33852 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyaddr_r is prototyped" >&5
33853$as_echo_n "checking if gethostbyaddr_r is prototyped... " >&6; }
33854 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33855/* end confdefs.h. */
33856
33857 $curl_includes_netdb
33858
33859_ACEOF
33860if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
33861 $EGREP "gethostbyaddr_r" >/dev/null 2>&1; then :
33862
33863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33864$as_echo "yes" >&6; }
33865 tst_proto_gethostbyaddr_r="yes"
33866
33867else
33868
33869 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33870$as_echo "no" >&6; }
33871 tst_proto_gethostbyaddr_r="no"
33872
33873fi
33874rm -f conftest*
33875
33876 fi
33877 #
33878 if test "$tst_proto_gethostbyaddr_r" = "yes"; then
33879 if test "$tst_nargs_gethostbyaddr_r" = "unknown"; then
33880 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyaddr_r takes 5 args." >&5
33881$as_echo_n "checking if gethostbyaddr_r takes 5 args.... " >&6; }
33882 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33883/* end confdefs.h. */
33884
33885
33886 $curl_includes_netdb
33887
33888int main (void)
33889{
33890
33891 if(0 != gethostbyaddr_r(0, 0, 0, 0, 0))
33892 return 1;
33893
33894 ;
33895 return 0;
33896}
33897
33898_ACEOF
33899if ac_fn_c_try_compile "$LINENO"; then :
33900
33901 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33902$as_echo "yes" >&6; }
33903 tst_compi_gethostbyaddr_r="yes"
33904 tst_nargs_gethostbyaddr_r="5"
33905
33906else
33907
33908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33909$as_echo "no" >&6; }
33910 tst_compi_gethostbyaddr_r="no"
33911
33912fi
33913rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33914 fi
33915 if test "$tst_nargs_gethostbyaddr_r" = "unknown"; then
33916 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyaddr_r takes 7 args." >&5
33917$as_echo_n "checking if gethostbyaddr_r takes 7 args.... " >&6; }
33918 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33919/* end confdefs.h. */
33920
33921
33922 $curl_includes_netdb
33923
33924int main (void)
33925{
33926
33927 if(0 != gethostbyaddr_r(0, 0, 0, 0, 0, 0, 0))
33928 return 1;
33929
33930 ;
33931 return 0;
33932}
33933
33934_ACEOF
33935if ac_fn_c_try_compile "$LINENO"; then :
33936
33937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33938$as_echo "yes" >&6; }
33939 tst_compi_gethostbyaddr_r="yes"
33940 tst_nargs_gethostbyaddr_r="7"
33941
33942else
33943
33944 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33945$as_echo "no" >&6; }
33946 tst_compi_gethostbyaddr_r="no"
33947
33948fi
33949rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33950 fi
33951 if test "$tst_nargs_gethostbyaddr_r" = "unknown"; then
33952 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyaddr_r takes 8 args." >&5
33953$as_echo_n "checking if gethostbyaddr_r takes 8 args.... " >&6; }
33954 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33955/* end confdefs.h. */
33956
33957
33958 $curl_includes_netdb
33959
33960int main (void)
33961{
33962
33963 if(0 != gethostbyaddr_r(0, 0, 0, 0, 0, 0, 0, 0))
33964 return 1;
33965
33966 ;
33967 return 0;
33968}
33969
33970_ACEOF
33971if ac_fn_c_try_compile "$LINENO"; then :
33972
33973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33974$as_echo "yes" >&6; }
33975 tst_compi_gethostbyaddr_r="yes"
33976 tst_nargs_gethostbyaddr_r="8"
33977
33978else
33979
33980 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33981$as_echo "no" >&6; }
33982 tst_compi_gethostbyaddr_r="no"
33983
33984fi
33985rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33986 fi
33987 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyaddr_r is compilable" >&5
33988$as_echo_n "checking if gethostbyaddr_r is compilable... " >&6; }
33989 if test "$tst_compi_gethostbyaddr_r" = "yes"; then
33990 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33991$as_echo "yes" >&6; }
33992 else
33993 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33994$as_echo "no" >&6; }
33995 fi
33996 fi
33997 #
33998 if test "$tst_compi_gethostbyaddr_r" = "yes"; then
33999 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyaddr_r usage allowed" >&5
34000$as_echo_n "checking if gethostbyaddr_r usage allowed... " >&6; }
34001 if test "x$curl_disallow_gethostbyaddr_r" != "xyes"; then
34002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34003$as_echo "yes" >&6; }
34004 tst_allow_gethostbyaddr_r="yes"
34005 else
34006 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34007$as_echo "no" >&6; }
34008 tst_allow_gethostbyaddr_r="no"
34009 fi
34010 fi
34011 #
34012 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyaddr_r might be used" >&5
34013$as_echo_n "checking if gethostbyaddr_r might be used... " >&6; }
34014 if test "$tst_links_gethostbyaddr_r" = "yes" &&
34015 test "$tst_proto_gethostbyaddr_r" = "yes" &&
34016 test "$tst_compi_gethostbyaddr_r" = "yes" &&
34017 test "$tst_allow_gethostbyaddr_r" = "yes"; then
34018 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34019$as_echo "yes" >&6; }
34020
34021cat >>confdefs.h <<_ACEOF
34022#define HAVE_GETHOSTBYADDR_R 1
34023_ACEOF
34024
34025 #
34026 if test "$tst_nargs_gethostbyaddr_r" -eq "5"; then
34027
34028$as_echo "#define HAVE_GETHOSTBYADDR_R_5 1" >>confdefs.h
34029
34030 elif test "$tst_nargs_gethostbyaddr_r" -eq "7"; then
34031
34032$as_echo "#define HAVE_GETHOSTBYADDR_R_7 1" >>confdefs.h
34033
34034 elif test "$tst_nargs_gethostbyaddr_r" -eq "8"; then
34035
34036$as_echo "#define HAVE_GETHOSTBYADDR_R_8 1" >>confdefs.h
34037
34038 fi
34039 #
34040 curl_cv_func_gethostbyaddr_r="yes"
34041 else
34042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34043$as_echo "no" >&6; }
34044 curl_cv_func_gethostbyaddr_r="no"
34045 fi
34046
34047
34048 #
34049 tst_links_gethostbyname="unknown"
34050 tst_proto_gethostbyname="unknown"
34051 tst_compi_gethostbyname="unknown"
34052 tst_allow_gethostbyname="unknown"
34053 #
34054 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyname can be linked" >&5
34055$as_echo_n "checking if gethostbyname can be linked... " >&6; }
34056 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34057/* end confdefs.h. */
34058
34059
34060 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070034061 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070034062 $curl_includes_netdb
34063
34064int main (void)
34065{
34066
34067 if(0 != gethostbyname(0))
34068 return 1;
34069
34070 ;
34071 return 0;
34072}
34073
34074_ACEOF
34075if ac_fn_c_try_link "$LINENO"; then :
34076
34077 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34078$as_echo "yes" >&6; }
34079 tst_links_gethostbyname="yes"
34080
34081else
34082
34083 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34084$as_echo "no" >&6; }
34085 tst_links_gethostbyname="no"
34086
34087fi
34088rm -f core conftest.err conftest.$ac_objext \
34089 conftest$ac_exeext conftest.$ac_ext
34090 #
34091 if test "$tst_links_gethostbyname" = "yes"; then
34092 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyname is prototyped" >&5
34093$as_echo_n "checking if gethostbyname is prototyped... " >&6; }
34094 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34095/* end confdefs.h. */
34096
34097 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070034098 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070034099 $curl_includes_netdb
34100
34101_ACEOF
34102if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
34103 $EGREP "gethostbyname" >/dev/null 2>&1; then :
34104
34105 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34106$as_echo "yes" >&6; }
34107 tst_proto_gethostbyname="yes"
34108
34109else
34110
34111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34112$as_echo "no" >&6; }
34113 tst_proto_gethostbyname="no"
34114
34115fi
34116rm -f conftest*
34117
34118 fi
34119 #
34120 if test "$tst_proto_gethostbyname" = "yes"; then
34121 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyname is compilable" >&5
34122$as_echo_n "checking if gethostbyname is compilable... " >&6; }
34123 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34124/* end confdefs.h. */
34125
34126
34127 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070034128 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070034129 $curl_includes_netdb
34130
34131int main (void)
34132{
34133
34134 if(0 != gethostbyname(0))
34135 return 1;
34136
34137 ;
34138 return 0;
34139}
34140
34141_ACEOF
34142if ac_fn_c_try_compile "$LINENO"; then :
34143
34144 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34145$as_echo "yes" >&6; }
34146 tst_compi_gethostbyname="yes"
34147
34148else
34149
34150 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34151$as_echo "no" >&6; }
34152 tst_compi_gethostbyname="no"
34153
34154fi
34155rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
34156 fi
34157 #
34158 if test "$tst_compi_gethostbyname" = "yes"; then
34159 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyname usage allowed" >&5
34160$as_echo_n "checking if gethostbyname usage allowed... " >&6; }
34161 if test "x$curl_disallow_gethostbyname" != "xyes"; then
34162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34163$as_echo "yes" >&6; }
34164 tst_allow_gethostbyname="yes"
34165 else
34166 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34167$as_echo "no" >&6; }
34168 tst_allow_gethostbyname="no"
34169 fi
34170 fi
34171 #
34172 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyname might be used" >&5
34173$as_echo_n "checking if gethostbyname might be used... " >&6; }
34174 if test "$tst_links_gethostbyname" = "yes" &&
34175 test "$tst_proto_gethostbyname" = "yes" &&
34176 test "$tst_compi_gethostbyname" = "yes" &&
34177 test "$tst_allow_gethostbyname" = "yes"; then
34178 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34179$as_echo "yes" >&6; }
34180
34181cat >>confdefs.h <<_ACEOF
34182#define HAVE_GETHOSTBYNAME 1
34183_ACEOF
34184
34185 curl_cv_func_gethostbyname="yes"
34186 else
34187 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34188$as_echo "no" >&6; }
34189 curl_cv_func_gethostbyname="no"
34190 fi
34191
34192
34193 #
34194 tst_links_gethostbyname_r="unknown"
34195 tst_proto_gethostbyname_r="unknown"
34196 tst_compi_gethostbyname_r="unknown"
34197 tst_allow_gethostbyname_r="unknown"
34198 tst_nargs_gethostbyname_r="unknown"
34199 #
34200 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyname_r can be linked" >&5
34201$as_echo_n "checking if gethostbyname_r can be linked... " >&6; }
34202 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34203/* end confdefs.h. */
34204
34205
34206#define gethostbyname_r innocuous_gethostbyname_r
34207#ifdef __STDC__
34208# include <limits.h>
34209#else
34210# include <assert.h>
34211#endif
34212#undef gethostbyname_r
34213#ifdef __cplusplus
34214extern "C"
34215#endif
34216char gethostbyname_r ();
34217#if defined __stub_gethostbyname_r || defined __stub___gethostbyname_r
34218choke me
34219#endif
34220
34221int main (void)
34222{
34223return gethostbyname_r ();
34224 ;
34225 return 0;
34226}
34227
34228_ACEOF
34229if ac_fn_c_try_link "$LINENO"; then :
34230
34231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34232$as_echo "yes" >&6; }
34233 tst_links_gethostbyname_r="yes"
34234
34235else
34236
34237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34238$as_echo "no" >&6; }
34239 tst_links_gethostbyname_r="no"
34240
34241fi
34242rm -f core conftest.err conftest.$ac_objext \
34243 conftest$ac_exeext conftest.$ac_ext
34244 #
34245 if test "$tst_links_gethostbyname_r" = "yes"; then
34246 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyname_r is prototyped" >&5
34247$as_echo_n "checking if gethostbyname_r is prototyped... " >&6; }
34248 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34249/* end confdefs.h. */
34250
34251 $curl_includes_netdb
34252
34253_ACEOF
34254if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
34255 $EGREP "gethostbyname_r" >/dev/null 2>&1; then :
34256
34257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34258$as_echo "yes" >&6; }
34259 tst_proto_gethostbyname_r="yes"
34260
34261else
34262
34263 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34264$as_echo "no" >&6; }
34265 tst_proto_gethostbyname_r="no"
34266
34267fi
34268rm -f conftest*
34269
34270 fi
34271 #
34272 if test "$tst_proto_gethostbyname_r" = "yes"; then
34273 if test "$tst_nargs_gethostbyname_r" = "unknown"; then
34274 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyname_r takes 3 args." >&5
34275$as_echo_n "checking if gethostbyname_r takes 3 args.... " >&6; }
34276 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34277/* end confdefs.h. */
34278
34279
34280 $curl_includes_netdb
34281
34282int main (void)
34283{
34284
34285 if(0 != gethostbyname_r(0, 0, 0))
34286 return 1;
34287
34288 ;
34289 return 0;
34290}
34291
34292_ACEOF
34293if ac_fn_c_try_compile "$LINENO"; then :
34294
34295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34296$as_echo "yes" >&6; }
34297 tst_compi_gethostbyname_r="yes"
34298 tst_nargs_gethostbyname_r="3"
34299
34300else
34301
34302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34303$as_echo "no" >&6; }
34304 tst_compi_gethostbyname_r="no"
34305
34306fi
34307rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
34308 fi
34309 if test "$tst_nargs_gethostbyname_r" = "unknown"; then
34310 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyname_r takes 5 args." >&5
34311$as_echo_n "checking if gethostbyname_r takes 5 args.... " >&6; }
34312 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34313/* end confdefs.h. */
34314
34315
34316 $curl_includes_netdb
34317
34318int main (void)
34319{
34320
34321 if(0 != gethostbyname_r(0, 0, 0, 0, 0))
34322 return 1;
34323
34324 ;
34325 return 0;
34326}
34327
34328_ACEOF
34329if ac_fn_c_try_compile "$LINENO"; then :
34330
34331 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34332$as_echo "yes" >&6; }
34333 tst_compi_gethostbyname_r="yes"
34334 tst_nargs_gethostbyname_r="5"
34335
34336else
34337
34338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34339$as_echo "no" >&6; }
34340 tst_compi_gethostbyname_r="no"
34341
34342fi
34343rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
34344 fi
34345 if test "$tst_nargs_gethostbyname_r" = "unknown"; then
34346 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyname_r takes 6 args." >&5
34347$as_echo_n "checking if gethostbyname_r takes 6 args.... " >&6; }
34348 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34349/* end confdefs.h. */
34350
34351
34352 $curl_includes_netdb
34353
34354int main (void)
34355{
34356
34357 if(0 != gethostbyname_r(0, 0, 0, 0, 0, 0))
34358 return 1;
34359
34360 ;
34361 return 0;
34362}
34363
34364_ACEOF
34365if ac_fn_c_try_compile "$LINENO"; then :
34366
34367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34368$as_echo "yes" >&6; }
34369 tst_compi_gethostbyname_r="yes"
34370 tst_nargs_gethostbyname_r="6"
34371
34372else
34373
34374 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34375$as_echo "no" >&6; }
34376 tst_compi_gethostbyname_r="no"
34377
34378fi
34379rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
34380 fi
34381 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyname_r is compilable" >&5
34382$as_echo_n "checking if gethostbyname_r is compilable... " >&6; }
34383 if test "$tst_compi_gethostbyname_r" = "yes"; then
34384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34385$as_echo "yes" >&6; }
34386 else
34387 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34388$as_echo "no" >&6; }
34389 fi
34390 fi
34391 #
34392 if test "$tst_compi_gethostbyname_r" = "yes"; then
34393 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyname_r usage allowed" >&5
34394$as_echo_n "checking if gethostbyname_r usage allowed... " >&6; }
34395 if test "x$curl_disallow_gethostbyname_r" != "xyes"; then
34396 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34397$as_echo "yes" >&6; }
34398 tst_allow_gethostbyname_r="yes"
34399 else
34400 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34401$as_echo "no" >&6; }
34402 tst_allow_gethostbyname_r="no"
34403 fi
34404 fi
34405 #
34406 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyname_r might be used" >&5
34407$as_echo_n "checking if gethostbyname_r might be used... " >&6; }
34408 if test "$tst_links_gethostbyname_r" = "yes" &&
34409 test "$tst_proto_gethostbyname_r" = "yes" &&
34410 test "$tst_compi_gethostbyname_r" = "yes" &&
34411 test "$tst_allow_gethostbyname_r" = "yes"; then
34412 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34413$as_echo "yes" >&6; }
34414
34415cat >>confdefs.h <<_ACEOF
34416#define HAVE_GETHOSTBYNAME_R 1
34417_ACEOF
34418
34419 #
34420 if test "$tst_nargs_gethostbyname_r" -eq "3"; then
34421
34422$as_echo "#define HAVE_GETHOSTBYNAME_R_3 1" >>confdefs.h
34423
34424 elif test "$tst_nargs_gethostbyname_r" -eq "5"; then
34425
34426$as_echo "#define HAVE_GETHOSTBYNAME_R_5 1" >>confdefs.h
34427
34428 elif test "$tst_nargs_gethostbyname_r" -eq "6"; then
34429
34430$as_echo "#define HAVE_GETHOSTBYNAME_R_6 1" >>confdefs.h
34431
34432 fi
34433 #
34434 curl_cv_func_gethostbyname_r="yes"
34435 else
34436 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34437$as_echo "no" >&6; }
34438 curl_cv_func_gethostbyname_r="no"
34439 fi
34440
34441
Elliott Hughesa93fb052018-12-12 14:22:48 -080034442curl_preprocess_callconv="\
34443/* preprocess start */
34444#ifdef HAVE_WINDOWS_H
34445# define FUNCALLCONV __stdcall
34446#else
34447# define FUNCALLCONV
34448#endif
34449/* preprocess end */"
34450
34451
Haibo Huang65021c72019-03-27 15:37:23 -070034452 #
Elliott Hughes82be86d2017-09-20 17:00:17 -070034453 tst_links_gethostname="unknown"
34454 tst_proto_gethostname="unknown"
34455 tst_compi_gethostname="unknown"
34456 tst_allow_gethostname="unknown"
34457 #
34458 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostname can be linked" >&5
34459$as_echo_n "checking if gethostname can be linked... " >&6; }
34460 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34461/* end confdefs.h. */
34462
34463
34464 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070034465 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070034466 $curl_includes_unistd
34467
34468int main (void)
34469{
34470
34471 if(0 != gethostname(0, 0))
34472 return 1;
34473
34474 ;
34475 return 0;
34476}
34477
34478_ACEOF
34479if ac_fn_c_try_link "$LINENO"; then :
34480
34481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34482$as_echo "yes" >&6; }
34483 tst_links_gethostname="yes"
34484
34485else
34486
34487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34488$as_echo "no" >&6; }
34489 tst_links_gethostname="no"
34490
34491fi
34492rm -f core conftest.err conftest.$ac_objext \
34493 conftest$ac_exeext conftest.$ac_ext
34494 #
34495 if test "$tst_links_gethostname" = "yes"; then
34496 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostname is prototyped" >&5
34497$as_echo_n "checking if gethostname is prototyped... " >&6; }
34498 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34499/* end confdefs.h. */
34500
34501 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070034502 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070034503 $curl_includes_unistd
34504
34505_ACEOF
34506if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
34507 $EGREP "gethostname" >/dev/null 2>&1; then :
34508
34509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34510$as_echo "yes" >&6; }
34511 tst_proto_gethostname="yes"
34512
34513else
34514
34515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34516$as_echo "no" >&6; }
34517 tst_proto_gethostname="no"
34518
34519fi
34520rm -f conftest*
34521
34522 fi
34523 #
34524 if test "$tst_proto_gethostname" = "yes"; then
34525 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostname is compilable" >&5
34526$as_echo_n "checking if gethostname is compilable... " >&6; }
34527 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34528/* end confdefs.h. */
34529
34530
34531 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070034532 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070034533 $curl_includes_unistd
34534
34535int main (void)
34536{
34537
34538 if(0 != gethostname(0, 0))
34539 return 1;
34540
34541 ;
34542 return 0;
34543}
34544
34545_ACEOF
34546if ac_fn_c_try_compile "$LINENO"; then :
34547
34548 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34549$as_echo "yes" >&6; }
34550 tst_compi_gethostname="yes"
34551
34552else
34553
34554 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34555$as_echo "no" >&6; }
34556 tst_compi_gethostname="no"
34557
34558fi
34559rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
34560 fi
34561 #
34562 if test "$tst_compi_gethostname" = "yes"; then
34563 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostname arg 2 data type" >&5
34564$as_echo_n "checking for gethostname arg 2 data type... " >&6; }
34565 tst_gethostname_type_arg2="unknown"
34566 for tst_arg1 in 'char *' 'unsigned char *' 'void *'; do
34567 for tst_arg2 in 'int' 'unsigned int' 'size_t'; do
34568 if test "$tst_gethostname_type_arg2" = "unknown"; then
34569 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34570/* end confdefs.h. */
34571
34572
34573 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070034574 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070034575 $curl_includes_unistd
34576 $curl_preprocess_callconv
34577 extern int FUNCALLCONV gethostname($tst_arg1, $tst_arg2);
34578
34579int main (void)
34580{
34581
34582 if(0 != gethostname(0, 0))
34583 return 1;
34584
34585 ;
34586 return 0;
34587}
34588
34589_ACEOF
34590if ac_fn_c_try_compile "$LINENO"; then :
34591
34592 tst_gethostname_type_arg2="$tst_arg2"
34593
34594fi
34595rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
34596 fi
34597 done
34598 done
34599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tst_gethostname_type_arg2" >&5
34600$as_echo "$tst_gethostname_type_arg2" >&6; }
34601 if test "$tst_gethostname_type_arg2" != "unknown"; then
34602
34603cat >>confdefs.h <<_ACEOF
34604#define GETHOSTNAME_TYPE_ARG2 $tst_gethostname_type_arg2
34605_ACEOF
34606
34607 fi
34608 fi
34609 #
34610 if test "$tst_compi_gethostname" = "yes"; then
34611 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostname usage allowed" >&5
34612$as_echo_n "checking if gethostname usage allowed... " >&6; }
34613 if test "x$curl_disallow_gethostname" != "xyes"; then
34614 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34615$as_echo "yes" >&6; }
34616 tst_allow_gethostname="yes"
34617 else
34618 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34619$as_echo "no" >&6; }
34620 tst_allow_gethostname="no"
34621 fi
34622 fi
34623 #
34624 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostname might be used" >&5
34625$as_echo_n "checking if gethostname might be used... " >&6; }
34626 if test "$tst_links_gethostname" = "yes" &&
34627 test "$tst_proto_gethostname" = "yes" &&
34628 test "$tst_compi_gethostname" = "yes" &&
34629 test "$tst_allow_gethostname" = "yes"; then
34630 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34631$as_echo "yes" >&6; }
34632
34633cat >>confdefs.h <<_ACEOF
34634#define HAVE_GETHOSTNAME 1
34635_ACEOF
34636
34637 curl_cv_func_gethostname="yes"
34638 else
34639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34640$as_echo "no" >&6; }
34641 curl_cv_func_gethostname="no"
34642 fi
34643
34644
Haibo Huang34ab3462019-05-22 00:50:27 -070034645 #
34646 tst_links_getpeername="unknown"
34647 tst_proto_getpeername="unknown"
34648 tst_compi_getpeername="unknown"
34649 tst_allow_getpeername="unknown"
34650 #
34651 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getpeername can be linked" >&5
34652$as_echo_n "checking if getpeername can be linked... " >&6; }
34653 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34654/* end confdefs.h. */
34655
34656
34657 $curl_includes_winsock2
34658 $curl_includes_bsdsocket
34659 $curl_includes_sys_socket
34660
34661int main (void)
34662{
34663
34664 if(0 != getpeername(0, (void *)0, (void *)0))
34665 return 1;
34666
34667 ;
34668 return 0;
34669}
34670
34671_ACEOF
34672if ac_fn_c_try_link "$LINENO"; then :
34673
34674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34675$as_echo "yes" >&6; }
34676 tst_links_getpeername="yes"
34677
34678else
34679
34680 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34681$as_echo "no" >&6; }
34682 tst_links_getpeername="no"
34683
34684fi
34685rm -f core conftest.err conftest.$ac_objext \
34686 conftest$ac_exeext conftest.$ac_ext
34687 #
34688 if test "$tst_links_getpeername" = "yes"; then
34689 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getpeername is prototyped" >&5
34690$as_echo_n "checking if getpeername is prototyped... " >&6; }
34691 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34692/* end confdefs.h. */
34693
34694 $curl_includes_winsock2
34695 $curl_includes_bsdsocket
34696 $curl_includes_sys_socket
34697
34698_ACEOF
34699if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
34700 $EGREP "getpeername" >/dev/null 2>&1; then :
34701
34702 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34703$as_echo "yes" >&6; }
34704 tst_proto_getpeername="yes"
34705
34706else
34707
34708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34709$as_echo "no" >&6; }
34710 tst_proto_getpeername="no"
34711
34712fi
34713rm -f conftest*
34714
34715 fi
34716 #
34717 if test "$tst_proto_getpeername" = "yes"; then
34718 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getpeername is compilable" >&5
34719$as_echo_n "checking if getpeername is compilable... " >&6; }
34720 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34721/* end confdefs.h. */
34722
34723
34724 $curl_includes_winsock2
34725 $curl_includes_bsdsocket
34726 $curl_includes_sys_socket
34727
34728int main (void)
34729{
34730
34731 if(0 != getpeername(0, (void *)0, (void *)0))
34732 return 1;
34733
34734 ;
34735 return 0;
34736}
34737
34738_ACEOF
34739if ac_fn_c_try_compile "$LINENO"; then :
34740
34741 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34742$as_echo "yes" >&6; }
34743 tst_compi_getpeername="yes"
34744
34745else
34746
34747 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34748$as_echo "no" >&6; }
34749 tst_compi_getpeername="no"
34750
34751fi
34752rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
34753 fi
34754 #
34755 if test "$tst_compi_getpeername" = "yes"; then
34756 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getpeername usage allowed" >&5
34757$as_echo_n "checking if getpeername usage allowed... " >&6; }
34758 if test "x$curl_disallow_getpeername" != "xyes"; then
34759 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34760$as_echo "yes" >&6; }
34761 tst_allow_getpeername="yes"
34762 else
34763 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34764$as_echo "no" >&6; }
34765 tst_allow_getpeername="no"
34766 fi
34767 fi
34768 #
34769 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getpeername might be used" >&5
34770$as_echo_n "checking if getpeername might be used... " >&6; }
34771 if test "$tst_links_getpeername" = "yes" &&
34772 test "$tst_proto_getpeername" = "yes" &&
34773 test "$tst_compi_getpeername" = "yes" &&
34774 test "$tst_allow_getpeername" = "yes"; then
34775 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34776$as_echo "yes" >&6; }
34777
34778cat >>confdefs.h <<_ACEOF
34779#define HAVE_GETPEERNAME 1
34780_ACEOF
34781
34782 curl_cv_func_getpeername="yes"
34783 else
34784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34785$as_echo "no" >&6; }
34786 curl_cv_func_getpeername="no"
34787 fi
34788
34789
34790 #
34791 tst_links_getsockname="unknown"
34792 tst_proto_getsockname="unknown"
34793 tst_compi_getsockname="unknown"
34794 tst_allow_getsockname="unknown"
34795 #
34796 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getsockname can be linked" >&5
34797$as_echo_n "checking if getsockname can be linked... " >&6; }
34798 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34799/* end confdefs.h. */
34800
34801
34802 $curl_includes_winsock2
34803 $curl_includes_bsdsocket
34804 $curl_includes_sys_socket
34805
34806int main (void)
34807{
34808
34809 if(0 != getsockname(0, (void *)0, (void *)0))
34810 return 1;
34811
34812 ;
34813 return 0;
34814}
34815
34816_ACEOF
34817if ac_fn_c_try_link "$LINENO"; then :
34818
34819 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34820$as_echo "yes" >&6; }
34821 tst_links_getsockname="yes"
34822
34823else
34824
34825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34826$as_echo "no" >&6; }
34827 tst_links_getsockname="no"
34828
34829fi
34830rm -f core conftest.err conftest.$ac_objext \
34831 conftest$ac_exeext conftest.$ac_ext
34832 #
34833 if test "$tst_links_getsockname" = "yes"; then
34834 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getsockname is prototyped" >&5
34835$as_echo_n "checking if getsockname is prototyped... " >&6; }
34836 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34837/* end confdefs.h. */
34838
34839 $curl_includes_winsock2
34840 $curl_includes_bsdsocket
34841 $curl_includes_sys_socket
34842
34843_ACEOF
34844if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
34845 $EGREP "getsockname" >/dev/null 2>&1; then :
34846
34847 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34848$as_echo "yes" >&6; }
34849 tst_proto_getsockname="yes"
34850
34851else
34852
34853 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34854$as_echo "no" >&6; }
34855 tst_proto_getsockname="no"
34856
34857fi
34858rm -f conftest*
34859
34860 fi
34861 #
34862 if test "$tst_proto_getsockname" = "yes"; then
34863 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getsockname is compilable" >&5
34864$as_echo_n "checking if getsockname is compilable... " >&6; }
34865 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34866/* end confdefs.h. */
34867
34868
34869 $curl_includes_winsock2
34870 $curl_includes_bsdsocket
34871 $curl_includes_sys_socket
34872
34873int main (void)
34874{
34875
34876 if(0 != getsockname(0, (void *)0, (void *)0))
34877 return 1;
34878
34879 ;
34880 return 0;
34881}
34882
34883_ACEOF
34884if ac_fn_c_try_compile "$LINENO"; then :
34885
34886 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34887$as_echo "yes" >&6; }
34888 tst_compi_getsockname="yes"
34889
34890else
34891
34892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34893$as_echo "no" >&6; }
34894 tst_compi_getsockname="no"
34895
34896fi
34897rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
34898 fi
34899 #
34900 if test "$tst_compi_getsockname" = "yes"; then
34901 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getsockname usage allowed" >&5
34902$as_echo_n "checking if getsockname usage allowed... " >&6; }
34903 if test "x$curl_disallow_getsockname" != "xyes"; then
34904 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34905$as_echo "yes" >&6; }
34906 tst_allow_getsockname="yes"
34907 else
34908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34909$as_echo "no" >&6; }
34910 tst_allow_getsockname="no"
34911 fi
34912 fi
34913 #
34914 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getsockname might be used" >&5
34915$as_echo_n "checking if getsockname might be used... " >&6; }
34916 if test "$tst_links_getsockname" = "yes" &&
34917 test "$tst_proto_getsockname" = "yes" &&
34918 test "$tst_compi_getsockname" = "yes" &&
34919 test "$tst_allow_getsockname" = "yes"; then
34920 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34921$as_echo "yes" >&6; }
34922
34923cat >>confdefs.h <<_ACEOF
34924#define HAVE_GETSOCKNAME 1
34925_ACEOF
34926
34927 curl_cv_func_getsockname="yes"
34928 else
34929 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34930$as_echo "no" >&6; }
34931 curl_cv_func_getsockname="no"
34932 fi
34933
34934
Haibo Huangb6336c12019-06-05 01:34:44 -070034935curl_includes_netif="\
34936/* includes start */
34937#ifdef HAVE_NET_IF_H
34938# include <net/if.h>
34939#endif
34940/* includes end */"
34941 for ac_header in net/if.h
34942do :
34943 ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "$curl_includes_netif
34944"
34945if test "x$ac_cv_header_net_if_h" = xyes; then :
34946 cat >>confdefs.h <<_ACEOF
34947#define HAVE_NET_IF_H 1
34948_ACEOF
34949
34950fi
34951
34952done
34953
34954
34955
34956 #
34957 tst_links_if_nametoindex="unknown"
34958 tst_proto_if_nametoindex="unknown"
34959 tst_compi_if_nametoindex="unknown"
34960 tst_allow_if_nametoindex="unknown"
34961 #
34962 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if if_nametoindex can be linked" >&5
34963$as_echo_n "checking if if_nametoindex can be linked... " >&6; }
34964 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34965/* end confdefs.h. */
34966
34967
34968 $curl_includes_winsock2
34969 $curl_includes_bsdsocket
34970 #include <net/if.h>
34971
34972int main (void)
34973{
34974
34975 if(0 != if_nametoindex(""))
34976 return 1;
34977
34978 ;
34979 return 0;
34980}
34981
34982_ACEOF
34983if ac_fn_c_try_link "$LINENO"; then :
34984
34985 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34986$as_echo "yes" >&6; }
34987 tst_links_if_nametoindex="yes"
34988
34989else
34990
34991 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34992$as_echo "no" >&6; }
34993 tst_links_if_nametoindex="no"
34994
34995fi
34996rm -f core conftest.err conftest.$ac_objext \
34997 conftest$ac_exeext conftest.$ac_ext
34998 #
34999 if test "$tst_links_if_nametoindex" = "yes"; then
35000 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if if_nametoindex is prototyped" >&5
35001$as_echo_n "checking if if_nametoindex is prototyped... " >&6; }
35002 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35003/* end confdefs.h. */
35004
35005 $curl_includes_winsock2
35006 $curl_includes_netif
35007
35008_ACEOF
35009if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
35010 $EGREP "if_nametoindex" >/dev/null 2>&1; then :
35011
35012 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35013$as_echo "yes" >&6; }
35014 tst_proto_if_nametoindex="yes"
35015
35016else
35017
35018 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35019$as_echo "no" >&6; }
35020 tst_proto_if_nametoindex="no"
35021
35022fi
35023rm -f conftest*
35024
35025 fi
35026 #
35027 if test "$tst_proto_if_nametoindex" = "yes"; then
35028 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if if_nametoindex is compilable" >&5
35029$as_echo_n "checking if if_nametoindex is compilable... " >&6; }
35030 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35031/* end confdefs.h. */
35032
35033
35034 $curl_includes_winsock2
35035 $curl_includes_netif
35036
35037int main (void)
35038{
35039
35040 if(0 != if_nametoindex(""))
35041 return 1;
35042
35043 ;
35044 return 0;
35045}
35046
35047_ACEOF
35048if ac_fn_c_try_compile "$LINENO"; then :
35049
35050 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35051$as_echo "yes" >&6; }
35052 tst_compi_if_nametoindex="yes"
35053
35054else
35055
35056 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35057$as_echo "no" >&6; }
35058 tst_compi_if_nametoindex="no"
35059
35060fi
35061rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
35062 fi
35063 #
35064 if test "$tst_compi_if_nametoindex" = "yes"; then
35065 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if if_nametoindex usage allowed" >&5
35066$as_echo_n "checking if if_nametoindex usage allowed... " >&6; }
35067 if test "x$curl_disallow_if_nametoindex" != "xyes"; then
35068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35069$as_echo "yes" >&6; }
35070 tst_allow_if_nametoindex="yes"
35071 else
35072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35073$as_echo "no" >&6; }
35074 tst_allow_if_nametoindex="no"
35075 fi
35076 fi
35077 #
35078 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if if_nametoindex might be used" >&5
35079$as_echo_n "checking if if_nametoindex might be used... " >&6; }
35080 if test "$tst_links_if_nametoindex" = "yes" &&
35081 test "$tst_proto_if_nametoindex" = "yes" &&
35082 test "$tst_compi_if_nametoindex" = "yes" &&
35083 test "$tst_allow_if_nametoindex" = "yes"; then
35084 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35085$as_echo "yes" >&6; }
35086
35087cat >>confdefs.h <<_ACEOF
35088#define HAVE_IF_NAMETOINDEX 1
35089_ACEOF
35090
35091 curl_cv_func_if_nametoindex="yes"
35092 else
35093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35094$as_echo "no" >&6; }
35095 curl_cv_func_if_nametoindex="no"
35096 fi
35097
35098
Elliott Hughes82be86d2017-09-20 17:00:17 -070035099 #
35100 tst_links_getifaddrs="unknown"
35101 tst_proto_getifaddrs="unknown"
35102 tst_compi_getifaddrs="unknown"
35103 tst_works_getifaddrs="unknown"
35104 tst_allow_getifaddrs="unknown"
35105 #
35106 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getifaddrs can be linked" >&5
35107$as_echo_n "checking if getifaddrs can be linked... " >&6; }
35108 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35109/* end confdefs.h. */
35110
35111
35112#define getifaddrs innocuous_getifaddrs
35113#ifdef __STDC__
35114# include <limits.h>
35115#else
35116# include <assert.h>
35117#endif
35118#undef getifaddrs
35119#ifdef __cplusplus
35120extern "C"
35121#endif
35122char getifaddrs ();
35123#if defined __stub_getifaddrs || defined __stub___getifaddrs
35124choke me
35125#endif
35126
35127int main (void)
35128{
35129return getifaddrs ();
35130 ;
35131 return 0;
35132}
35133
35134_ACEOF
35135if ac_fn_c_try_link "$LINENO"; then :
35136
35137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35138$as_echo "yes" >&6; }
35139 tst_links_getifaddrs="yes"
35140
35141else
35142
35143 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35144$as_echo "no" >&6; }
35145 tst_links_getifaddrs="no"
35146
35147fi
35148rm -f core conftest.err conftest.$ac_objext \
35149 conftest$ac_exeext conftest.$ac_ext
35150 #
35151 if test "$tst_links_getifaddrs" = "yes"; then
35152 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getifaddrs is prototyped" >&5
35153$as_echo_n "checking if getifaddrs is prototyped... " >&6; }
35154 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35155/* end confdefs.h. */
35156
35157 $curl_includes_ifaddrs
35158
35159_ACEOF
35160if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
35161 $EGREP "getifaddrs" >/dev/null 2>&1; then :
35162
35163 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35164$as_echo "yes" >&6; }
35165 tst_proto_getifaddrs="yes"
35166
35167else
35168
35169 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35170$as_echo "no" >&6; }
35171 tst_proto_getifaddrs="no"
35172
35173fi
35174rm -f conftest*
35175
35176 fi
35177 #
35178 if test "$tst_proto_getifaddrs" = "yes"; then
35179 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getifaddrs is compilable" >&5
35180$as_echo_n "checking if getifaddrs is compilable... " >&6; }
35181 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35182/* end confdefs.h. */
35183
35184
35185 $curl_includes_ifaddrs
35186
35187int main (void)
35188{
35189
35190 if(0 != getifaddrs(0))
35191 return 1;
35192
35193 ;
35194 return 0;
35195}
35196
35197_ACEOF
35198if ac_fn_c_try_compile "$LINENO"; then :
35199
35200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35201$as_echo "yes" >&6; }
35202 tst_compi_getifaddrs="yes"
35203
35204else
35205
35206 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35207$as_echo "no" >&6; }
35208 tst_compi_getifaddrs="no"
35209
35210fi
35211rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
35212 fi
35213 #
35214 if test "x$cross_compiling" != "xyes" &&
35215 test "$tst_compi_getifaddrs" = "yes"; then
35216 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getifaddrs seems to work" >&5
35217$as_echo_n "checking if getifaddrs seems to work... " >&6; }
Elliott Hughesa93fb052018-12-12 14:22:48 -080035218
35219
35220 old=$LD_LIBRARY_PATH
35221 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
35222 export LD_LIBRARY_PATH
35223 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070035224 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
35225$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
35226as_fn_error $? "cannot run test program while cross compiling
35227See \`config.log' for more details" "$LINENO" 5; }
35228else
35229 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35230/* end confdefs.h. */
35231
35232
35233 $curl_includes_stdlib
35234 $curl_includes_ifaddrs
35235
35236int main (void)
35237{
35238
35239 struct ifaddrs *ifa = 0;
35240 int error;
35241
35242 error = getifaddrs(&ifa);
35243 if(error || !ifa)
35244 exit(1); /* fail */
35245 else
35246 exit(0);
35247
35248 ;
35249 return 0;
35250}
35251
35252_ACEOF
35253if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughesa93fb052018-12-12 14:22:48 -080035254 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070035255$as_echo "yes" >&6; }
35256 tst_works_getifaddrs="yes"
35257
35258else
Elliott Hughesa93fb052018-12-12 14:22:48 -080035259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070035260$as_echo "no" >&6; }
35261 tst_works_getifaddrs="no"
35262
35263fi
35264rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
35265 conftest.$ac_objext conftest.beam conftest.$ac_ext
35266fi
35267
Elliott Hughesa93fb052018-12-12 14:22:48 -080035268 LD_LIBRARY_PATH=$old # restore
35269
Elliott Hughes82be86d2017-09-20 17:00:17 -070035270 fi
35271 #
35272 if test "$tst_compi_getifaddrs" = "yes" &&
35273 test "$tst_works_getifaddrs" != "no"; then
35274 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getifaddrs usage allowed" >&5
35275$as_echo_n "checking if getifaddrs usage allowed... " >&6; }
35276 if test "x$curl_disallow_getifaddrs" != "xyes"; then
35277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35278$as_echo "yes" >&6; }
35279 tst_allow_getifaddrs="yes"
35280 else
35281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35282$as_echo "no" >&6; }
35283 tst_allow_getifaddrs="no"
35284 fi
35285 fi
35286 #
35287 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getifaddrs might be used" >&5
35288$as_echo_n "checking if getifaddrs might be used... " >&6; }
35289 if test "$tst_links_getifaddrs" = "yes" &&
35290 test "$tst_proto_getifaddrs" = "yes" &&
35291 test "$tst_compi_getifaddrs" = "yes" &&
35292 test "$tst_allow_getifaddrs" = "yes" &&
35293 test "$tst_works_getifaddrs" != "no"; then
35294 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35295$as_echo "yes" >&6; }
35296
35297cat >>confdefs.h <<_ACEOF
35298#define HAVE_GETIFADDRS 1
35299_ACEOF
35300
35301 curl_cv_func_getifaddrs="yes"
35302 else
35303 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35304$as_echo "no" >&6; }
35305 curl_cv_func_getifaddrs="no"
35306 fi
35307
35308
35309 #
35310 tst_links_getservbyport_r="unknown"
35311 tst_proto_getservbyport_r="unknown"
35312 tst_compi_getservbyport_r="unknown"
35313 tst_allow_getservbyport_r="unknown"
35314 tst_nargs_getservbyport_r="unknown"
35315 #
35316 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getservbyport_r can be linked" >&5
35317$as_echo_n "checking if getservbyport_r can be linked... " >&6; }
35318 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35319/* end confdefs.h. */
35320
35321
35322#define getservbyport_r innocuous_getservbyport_r
35323#ifdef __STDC__
35324# include <limits.h>
35325#else
35326# include <assert.h>
35327#endif
35328#undef getservbyport_r
35329#ifdef __cplusplus
35330extern "C"
35331#endif
35332char getservbyport_r ();
35333#if defined __stub_getservbyport_r || defined __stub___getservbyport_r
35334choke me
35335#endif
35336
35337int main (void)
35338{
35339return getservbyport_r ();
35340 ;
35341 return 0;
35342}
35343
35344_ACEOF
35345if ac_fn_c_try_link "$LINENO"; then :
35346
35347 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35348$as_echo "yes" >&6; }
35349 tst_links_getservbyport_r="yes"
35350
35351else
35352
35353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35354$as_echo "no" >&6; }
35355 tst_links_getservbyport_r="no"
35356
35357fi
35358rm -f core conftest.err conftest.$ac_objext \
35359 conftest$ac_exeext conftest.$ac_ext
35360 #
35361 if test "$tst_links_getservbyport_r" = "yes"; then
35362 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getservbyport_r is prototyped" >&5
35363$as_echo_n "checking if getservbyport_r is prototyped... " >&6; }
35364 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35365/* end confdefs.h. */
35366
35367 $curl_includes_netdb
35368
35369_ACEOF
35370if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
35371 $EGREP "getservbyport_r" >/dev/null 2>&1; then :
35372
35373 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35374$as_echo "yes" >&6; }
35375 tst_proto_getservbyport_r="yes"
35376
35377else
35378
35379 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35380$as_echo "no" >&6; }
35381 tst_proto_getservbyport_r="no"
35382
35383fi
35384rm -f conftest*
35385
35386 fi
35387 #
35388 if test "$tst_proto_getservbyport_r" = "yes"; then
35389 if test "$tst_nargs_getservbyport_r" = "unknown"; then
35390 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getservbyport_r takes 4 args." >&5
35391$as_echo_n "checking if getservbyport_r takes 4 args.... " >&6; }
35392 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35393/* end confdefs.h. */
35394
35395
35396 $curl_includes_netdb
35397
35398int main (void)
35399{
35400
35401 if(0 != getservbyport_r(0, 0, 0, 0))
35402 return 1;
35403
35404 ;
35405 return 0;
35406}
35407
35408_ACEOF
35409if ac_fn_c_try_compile "$LINENO"; then :
35410
35411 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35412$as_echo "yes" >&6; }
35413 tst_compi_getservbyport_r="yes"
35414 tst_nargs_getservbyport_r="4"
35415
35416else
35417
35418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35419$as_echo "no" >&6; }
35420 tst_compi_getservbyport_r="no"
35421
35422fi
35423rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
35424 fi
35425 if test "$tst_nargs_getservbyport_r" = "unknown"; then
35426 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getservbyport_r takes 5 args." >&5
35427$as_echo_n "checking if getservbyport_r takes 5 args.... " >&6; }
35428 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35429/* end confdefs.h. */
35430
35431
35432 $curl_includes_netdb
35433
35434int main (void)
35435{
35436
35437 if(0 != getservbyport_r(0, 0, 0, 0, 0))
35438 return 1;
35439
35440 ;
35441 return 0;
35442}
35443
35444_ACEOF
35445if ac_fn_c_try_compile "$LINENO"; then :
35446
35447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35448$as_echo "yes" >&6; }
35449 tst_compi_getservbyport_r="yes"
35450 tst_nargs_getservbyport_r="5"
35451
35452else
35453
35454 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35455$as_echo "no" >&6; }
35456 tst_compi_getservbyport_r="no"
35457
35458fi
35459rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
35460 fi
35461 if test "$tst_nargs_getservbyport_r" = "unknown"; then
35462 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getservbyport_r takes 6 args." >&5
35463$as_echo_n "checking if getservbyport_r takes 6 args.... " >&6; }
35464 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35465/* end confdefs.h. */
35466
35467
35468 $curl_includes_netdb
35469
35470int main (void)
35471{
35472
35473 if(0 != getservbyport_r(0, 0, 0, 0, 0, 0))
35474 return 1;
35475
35476 ;
35477 return 0;
35478}
35479
35480_ACEOF
35481if ac_fn_c_try_compile "$LINENO"; then :
35482
35483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35484$as_echo "yes" >&6; }
35485 tst_compi_getservbyport_r="yes"
35486 tst_nargs_getservbyport_r="6"
35487
35488else
35489
35490 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35491$as_echo "no" >&6; }
35492 tst_compi_getservbyport_r="no"
35493
35494fi
35495rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
35496 fi
35497 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getservbyport_r is compilable" >&5
35498$as_echo_n "checking if getservbyport_r is compilable... " >&6; }
35499 if test "$tst_compi_getservbyport_r" = "yes"; then
35500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35501$as_echo "yes" >&6; }
35502 else
35503 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35504$as_echo "no" >&6; }
35505 fi
35506 fi
35507 #
35508 if test "$tst_compi_getservbyport_r" = "yes"; then
35509 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getservbyport_r usage allowed" >&5
35510$as_echo_n "checking if getservbyport_r usage allowed... " >&6; }
35511 if test "x$curl_disallow_getservbyport_r" != "xyes"; then
35512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35513$as_echo "yes" >&6; }
35514 tst_allow_getservbyport_r="yes"
35515 else
35516 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35517$as_echo "no" >&6; }
35518 tst_allow_getservbyport_r="no"
35519 fi
35520 fi
35521 #
35522 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getservbyport_r might be used" >&5
35523$as_echo_n "checking if getservbyport_r might be used... " >&6; }
35524 if test "$tst_links_getservbyport_r" = "yes" &&
35525 test "$tst_proto_getservbyport_r" = "yes" &&
35526 test "$tst_compi_getservbyport_r" = "yes" &&
35527 test "$tst_allow_getservbyport_r" = "yes"; then
35528 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35529$as_echo "yes" >&6; }
35530
35531cat >>confdefs.h <<_ACEOF
35532#define HAVE_GETSERVBYPORT_R 1
35533_ACEOF
35534
35535
35536cat >>confdefs.h <<_ACEOF
35537#define GETSERVBYPORT_R_ARGS $tst_nargs_getservbyport_r
35538_ACEOF
35539
35540 if test "$tst_nargs_getservbyport_r" -eq "4"; then
35541
35542$as_echo "#define GETSERVBYPORT_R_BUFSIZE sizeof(struct servent_data)" >>confdefs.h
35543
35544 else
35545
35546$as_echo "#define GETSERVBYPORT_R_BUFSIZE 4096" >>confdefs.h
35547
35548 fi
35549 curl_cv_func_getservbyport_r="yes"
35550 else
35551 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35552$as_echo "no" >&6; }
35553 curl_cv_func_getservbyport_r="no"
35554 fi
35555
35556
35557curl_includes_time="\
35558/* includes start */
35559#ifdef HAVE_SYS_TYPES_H
35560# include <sys/types.h>
35561#endif
35562#ifdef HAVE_SYS_TIME_H
35563# include <sys/time.h>
35564# ifdef TIME_WITH_SYS_TIME
35565# include <time.h>
35566# endif
35567#else
35568# ifdef HAVE_TIME_H
35569# include <time.h>
35570# endif
35571#endif
35572/* includes end */"
35573 for ac_header in sys/types.h sys/time.h time.h
35574do :
35575 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
35576ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_time
35577"
35578if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
35579 cat >>confdefs.h <<_ACEOF
35580#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
35581_ACEOF
35582
35583fi
35584
35585done
35586
35587
35588
35589 #
35590 tst_links_gmtime_r="unknown"
35591 tst_proto_gmtime_r="unknown"
35592 tst_compi_gmtime_r="unknown"
35593 tst_works_gmtime_r="unknown"
35594 tst_allow_gmtime_r="unknown"
35595 #
35596 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gmtime_r can be linked" >&5
35597$as_echo_n "checking if gmtime_r can be linked... " >&6; }
35598 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35599/* end confdefs.h. */
35600
35601
35602#define gmtime_r innocuous_gmtime_r
35603#ifdef __STDC__
35604# include <limits.h>
35605#else
35606# include <assert.h>
35607#endif
35608#undef gmtime_r
35609#ifdef __cplusplus
35610extern "C"
35611#endif
35612char gmtime_r ();
35613#if defined __stub_gmtime_r || defined __stub___gmtime_r
35614choke me
35615#endif
35616
35617int main (void)
35618{
35619return gmtime_r ();
35620 ;
35621 return 0;
35622}
35623
35624_ACEOF
35625if ac_fn_c_try_link "$LINENO"; then :
35626
35627 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35628$as_echo "yes" >&6; }
35629 tst_links_gmtime_r="yes"
35630
35631else
35632
35633 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35634$as_echo "no" >&6; }
35635 tst_links_gmtime_r="no"
35636
35637fi
35638rm -f core conftest.err conftest.$ac_objext \
35639 conftest$ac_exeext conftest.$ac_ext
35640 #
35641 if test "$tst_links_gmtime_r" = "yes"; then
35642 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gmtime_r is prototyped" >&5
35643$as_echo_n "checking if gmtime_r is prototyped... " >&6; }
35644 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35645/* end confdefs.h. */
35646
35647 $curl_includes_time
35648
35649_ACEOF
35650if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
35651 $EGREP "gmtime_r" >/dev/null 2>&1; then :
35652
35653 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35654$as_echo "yes" >&6; }
35655 tst_proto_gmtime_r="yes"
35656
35657else
35658
35659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35660$as_echo "no" >&6; }
35661 tst_proto_gmtime_r="no"
35662
35663fi
35664rm -f conftest*
35665
35666 fi
35667 #
35668 if test "$tst_proto_gmtime_r" = "yes"; then
35669 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gmtime_r is compilable" >&5
35670$as_echo_n "checking if gmtime_r is compilable... " >&6; }
35671 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35672/* end confdefs.h. */
35673
35674
35675 $curl_includes_time
35676
35677int main (void)
35678{
35679
35680 if(0 != gmtime_r(0, 0))
35681 return 1;
35682
35683 ;
35684 return 0;
35685}
35686
35687_ACEOF
35688if ac_fn_c_try_compile "$LINENO"; then :
35689
35690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35691$as_echo "yes" >&6; }
35692 tst_compi_gmtime_r="yes"
35693
35694else
35695
35696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35697$as_echo "no" >&6; }
35698 tst_compi_gmtime_r="no"
35699
35700fi
35701rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
35702 fi
35703 #
35704 if test "x$cross_compiling" != "xyes" &&
35705 test "$tst_compi_gmtime_r" = "yes"; then
35706 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gmtime_r seems to work" >&5
35707$as_echo_n "checking if gmtime_r seems to work... " >&6; }
Elliott Hughesa93fb052018-12-12 14:22:48 -080035708
35709
35710 old=$LD_LIBRARY_PATH
35711 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
35712 export LD_LIBRARY_PATH
35713 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070035714 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
35715$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
35716as_fn_error $? "cannot run test program while cross compiling
35717See \`config.log' for more details" "$LINENO" 5; }
35718else
35719 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35720/* end confdefs.h. */
35721
35722
35723 $curl_includes_stdlib
35724 $curl_includes_time
35725
35726int main (void)
35727{
35728
35729 time_t local = 1170352587;
35730 struct tm *gmt = 0;
35731 struct tm result;
35732 gmt = gmtime_r(&local, &result);
35733 if(gmt)
35734 exit(0);
35735 else
35736 exit(1);
35737
35738 ;
35739 return 0;
35740}
35741
35742_ACEOF
35743if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughesa93fb052018-12-12 14:22:48 -080035744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070035745$as_echo "yes" >&6; }
35746 tst_works_gmtime_r="yes"
35747
35748else
Elliott Hughesa93fb052018-12-12 14:22:48 -080035749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070035750$as_echo "no" >&6; }
35751 tst_works_gmtime_r="no"
35752
35753fi
35754rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
35755 conftest.$ac_objext conftest.beam conftest.$ac_ext
35756fi
35757
Elliott Hughesa93fb052018-12-12 14:22:48 -080035758 LD_LIBRARY_PATH=$old # restore
35759
Elliott Hughes82be86d2017-09-20 17:00:17 -070035760 fi
35761 #
35762 if test "$tst_compi_gmtime_r" = "yes" &&
35763 test "$tst_works_gmtime_r" != "no"; then
35764 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gmtime_r usage allowed" >&5
35765$as_echo_n "checking if gmtime_r usage allowed... " >&6; }
35766 if test "x$curl_disallow_gmtime_r" != "xyes"; then
35767 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35768$as_echo "yes" >&6; }
35769 tst_allow_gmtime_r="yes"
35770 else
35771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35772$as_echo "no" >&6; }
35773 tst_allow_gmtime_r="no"
35774 fi
35775 fi
35776 #
35777 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gmtime_r might be used" >&5
35778$as_echo_n "checking if gmtime_r might be used... " >&6; }
35779 if test "$tst_links_gmtime_r" = "yes" &&
35780 test "$tst_proto_gmtime_r" = "yes" &&
35781 test "$tst_compi_gmtime_r" = "yes" &&
35782 test "$tst_allow_gmtime_r" = "yes" &&
35783 test "$tst_works_gmtime_r" != "no"; then
35784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35785$as_echo "yes" >&6; }
35786
35787cat >>confdefs.h <<_ACEOF
35788#define HAVE_GMTIME_R 1
35789_ACEOF
35790
35791 curl_cv_func_gmtime_r="yes"
35792 else
35793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35794$as_echo "no" >&6; }
35795 curl_cv_func_gmtime_r="no"
35796 fi
35797
35798
35799curl_includes_arpa_inet="\
35800/* includes start */
35801#ifdef HAVE_SYS_TYPES_H
35802# include <sys/types.h>
35803#endif
35804#ifdef HAVE_SYS_SOCKET_H
35805# include <sys/socket.h>
35806#endif
35807#ifdef HAVE_NETINET_IN_H
35808# include <netinet/in.h>
35809#endif
35810#ifdef HAVE_ARPA_INET_H
35811# include <arpa/inet.h>
35812#endif
35813#ifdef HAVE_WINSOCK2_H
35814#include <winsock2.h>
35815#include <ws2tcpip.h>
35816#endif
35817/* includes end */"
35818 for ac_header in sys/types.h sys/socket.h netinet/in.h arpa/inet.h
35819do :
35820 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
35821ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_arpa_inet
35822"
35823if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
35824 cat >>confdefs.h <<_ACEOF
35825#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
35826_ACEOF
35827
35828fi
35829
35830done
35831
35832
35833
35834 #
35835 tst_links_inet_ntoa_r="unknown"
35836 tst_proto_inet_ntoa_r="unknown"
35837 tst_compi_inet_ntoa_r="unknown"
35838 tst_allow_inet_ntoa_r="unknown"
35839 tst_nargs_inet_ntoa_r="unknown"
35840 #
35841 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_ntoa_r can be linked" >&5
35842$as_echo_n "checking if inet_ntoa_r can be linked... " >&6; }
35843 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35844/* end confdefs.h. */
35845
35846
35847#define inet_ntoa_r innocuous_inet_ntoa_r
35848#ifdef __STDC__
35849# include <limits.h>
35850#else
35851# include <assert.h>
35852#endif
35853#undef inet_ntoa_r
35854#ifdef __cplusplus
35855extern "C"
35856#endif
35857char inet_ntoa_r ();
35858#if defined __stub_inet_ntoa_r || defined __stub___inet_ntoa_r
35859choke me
35860#endif
35861
35862int main (void)
35863{
35864return inet_ntoa_r ();
35865 ;
35866 return 0;
35867}
35868
35869_ACEOF
35870if ac_fn_c_try_link "$LINENO"; then :
35871
35872 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35873$as_echo "yes" >&6; }
35874 tst_links_inet_ntoa_r="yes"
35875
35876else
35877
35878 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35879$as_echo "no" >&6; }
35880 tst_links_inet_ntoa_r="no"
35881
35882fi
35883rm -f core conftest.err conftest.$ac_objext \
35884 conftest$ac_exeext conftest.$ac_ext
35885 #
35886 if test "$tst_links_inet_ntoa_r" = "yes"; then
35887 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_ntoa_r is prototyped" >&5
35888$as_echo_n "checking if inet_ntoa_r is prototyped... " >&6; }
35889 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35890/* end confdefs.h. */
35891
35892 $curl_includes_arpa_inet
35893
35894_ACEOF
35895if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
35896 $EGREP "inet_ntoa_r" >/dev/null 2>&1; then :
35897
35898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35899$as_echo "yes" >&6; }
35900 tst_proto_inet_ntoa_r="yes"
35901
35902else
35903
35904 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35905$as_echo "no" >&6; }
35906 tst_proto_inet_ntoa_r="no"
35907
35908fi
35909rm -f conftest*
35910
35911 fi
35912 #
35913 if test "$tst_proto_inet_ntoa_r" = "yes"; then
35914 if test "$tst_nargs_inet_ntoa_r" = "unknown"; then
35915 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_ntoa_r takes 2 args." >&5
35916$as_echo_n "checking if inet_ntoa_r takes 2 args.... " >&6; }
35917 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35918/* end confdefs.h. */
35919
35920
35921 $curl_includes_arpa_inet
35922
35923int main (void)
35924{
35925
35926 struct in_addr addr;
35927 if(0 != inet_ntoa_r(addr, 0))
35928 return 1;
35929
35930 ;
35931 return 0;
35932}
35933
35934_ACEOF
35935if ac_fn_c_try_compile "$LINENO"; then :
35936
35937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35938$as_echo "yes" >&6; }
35939 tst_compi_inet_ntoa_r="yes"
35940 tst_nargs_inet_ntoa_r="2"
35941
35942else
35943
35944 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35945$as_echo "no" >&6; }
35946 tst_compi_inet_ntoa_r="no"
35947
35948fi
35949rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
35950 fi
35951 if test "$tst_nargs_inet_ntoa_r" = "unknown"; then
35952 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_ntoa_r takes 3 args." >&5
35953$as_echo_n "checking if inet_ntoa_r takes 3 args.... " >&6; }
35954 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35955/* end confdefs.h. */
35956
35957
35958 $curl_includes_arpa_inet
35959
35960int main (void)
35961{
35962
35963 struct in_addr addr;
35964 if(0 != inet_ntoa_r(addr, 0, 0))
35965 return 1;
35966
35967 ;
35968 return 0;
35969}
35970
35971_ACEOF
35972if ac_fn_c_try_compile "$LINENO"; then :
35973
35974 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35975$as_echo "yes" >&6; }
35976 tst_compi_inet_ntoa_r="yes"
35977 tst_nargs_inet_ntoa_r="3"
35978
35979else
35980
35981 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35982$as_echo "no" >&6; }
35983 tst_compi_inet_ntoa_r="no"
35984
35985fi
35986rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
35987 fi
35988 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_ntoa_r is compilable" >&5
35989$as_echo_n "checking if inet_ntoa_r is compilable... " >&6; }
35990 if test "$tst_compi_inet_ntoa_r" = "yes"; then
35991 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35992$as_echo "yes" >&6; }
35993 else
35994 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35995$as_echo "no" >&6; }
35996 fi
35997 fi
35998 #
35999 if test "$tst_compi_inet_ntoa_r" = "yes"; then
36000 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_ntoa_r usage allowed" >&5
36001$as_echo_n "checking if inet_ntoa_r usage allowed... " >&6; }
36002 if test "x$curl_disallow_inet_ntoa_r" != "xyes"; then
36003 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36004$as_echo "yes" >&6; }
36005 tst_allow_inet_ntoa_r="yes"
36006 else
36007 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36008$as_echo "no" >&6; }
36009 tst_allow_inet_ntoa_r="no"
36010 fi
36011 fi
36012 #
36013 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_ntoa_r might be used" >&5
36014$as_echo_n "checking if inet_ntoa_r might be used... " >&6; }
36015 if test "$tst_links_inet_ntoa_r" = "yes" &&
36016 test "$tst_proto_inet_ntoa_r" = "yes" &&
36017 test "$tst_compi_inet_ntoa_r" = "yes" &&
36018 test "$tst_allow_inet_ntoa_r" = "yes"; then
36019 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36020$as_echo "yes" >&6; }
36021
36022cat >>confdefs.h <<_ACEOF
36023#define HAVE_INET_NTOA_R 1
36024_ACEOF
36025
36026 #
36027 if test "$tst_nargs_inet_ntoa_r" -eq "2"; then
36028
36029$as_echo "#define HAVE_INET_NTOA_R_2 1" >>confdefs.h
36030
36031 elif test "$tst_nargs_inet_ntoa_r" -eq "3"; then
36032
36033$as_echo "#define HAVE_INET_NTOA_R_3 1" >>confdefs.h
36034
36035 fi
36036 #
36037 curl_cv_func_inet_ntoa_r="yes"
36038 else
36039 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36040$as_echo "no" >&6; }
36041 curl_cv_func_inet_ntoa_r="no"
36042 fi
36043
36044
36045 #
36046 tst_links_inet_ntop="unknown"
36047 tst_proto_inet_ntop="unknown"
36048 tst_compi_inet_ntop="unknown"
36049 tst_works_inet_ntop="unknown"
36050 tst_allow_inet_ntop="unknown"
36051 #
36052 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_ntop can be linked" >&5
36053$as_echo_n "checking if inet_ntop can be linked... " >&6; }
36054 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36055/* end confdefs.h. */
36056
36057
36058#define inet_ntop innocuous_inet_ntop
36059#ifdef __STDC__
36060# include <limits.h>
36061#else
36062# include <assert.h>
36063#endif
36064#undef inet_ntop
36065#ifdef __cplusplus
36066extern "C"
36067#endif
36068char inet_ntop ();
36069#if defined __stub_inet_ntop || defined __stub___inet_ntop
36070choke me
36071#endif
36072
36073int main (void)
36074{
36075return inet_ntop ();
36076 ;
36077 return 0;
36078}
36079
36080_ACEOF
36081if ac_fn_c_try_link "$LINENO"; then :
36082
36083 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36084$as_echo "yes" >&6; }
36085 tst_links_inet_ntop="yes"
36086
36087else
36088
36089 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36090$as_echo "no" >&6; }
36091 tst_links_inet_ntop="no"
36092
36093fi
36094rm -f core conftest.err conftest.$ac_objext \
36095 conftest$ac_exeext conftest.$ac_ext
36096 #
36097 if test "$tst_links_inet_ntop" = "yes"; then
36098 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_ntop is prototyped" >&5
36099$as_echo_n "checking if inet_ntop is prototyped... " >&6; }
36100 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36101/* end confdefs.h. */
36102
36103 $curl_includes_arpa_inet
36104
36105_ACEOF
36106if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
36107 $EGREP "inet_ntop" >/dev/null 2>&1; then :
36108
36109 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36110$as_echo "yes" >&6; }
36111 tst_proto_inet_ntop="yes"
36112
36113else
36114
36115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36116$as_echo "no" >&6; }
36117 tst_proto_inet_ntop="no"
36118
36119fi
36120rm -f conftest*
36121
36122 fi
36123 #
36124 if test "$tst_proto_inet_ntop" = "yes"; then
36125 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_ntop is compilable" >&5
36126$as_echo_n "checking if inet_ntop is compilable... " >&6; }
36127 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36128/* end confdefs.h. */
36129
36130
36131 $curl_includes_arpa_inet
36132
36133int main (void)
36134{
36135
36136 if(0 != inet_ntop(0, 0, 0, 0))
36137 return 1;
36138
36139 ;
36140 return 0;
36141}
36142
36143_ACEOF
36144if ac_fn_c_try_compile "$LINENO"; then :
36145
36146 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36147$as_echo "yes" >&6; }
36148 tst_compi_inet_ntop="yes"
36149
36150else
36151
36152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36153$as_echo "no" >&6; }
36154 tst_compi_inet_ntop="no"
36155
36156fi
36157rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
36158 fi
36159 #
36160 if test "x$cross_compiling" != "xyes" &&
36161 test "$tst_compi_inet_ntop" = "yes"; then
36162 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_ntop seems to work" >&5
36163$as_echo_n "checking if inet_ntop seems to work... " >&6; }
Elliott Hughesa93fb052018-12-12 14:22:48 -080036164
36165
36166 old=$LD_LIBRARY_PATH
36167 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
36168 export LD_LIBRARY_PATH
36169 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070036170 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
36171$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
36172as_fn_error $? "cannot run test program while cross compiling
36173See \`config.log' for more details" "$LINENO" 5; }
36174else
36175 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36176/* end confdefs.h. */
36177
36178
36179 $curl_includes_stdlib
36180 $curl_includes_arpa_inet
36181 $curl_includes_string
36182
36183int main (void)
36184{
36185
36186 char ipv6res[sizeof("ffff:ffff:ffff:ffff:ffff:ffff:255.255.255.255")];
36187 char ipv4res[sizeof "255.255.255.255"];
36188 unsigned char ipv6a[26];
36189 unsigned char ipv4a[5];
36190 char *ipv6ptr = 0;
36191 char *ipv4ptr = 0;
36192 /* - */
36193 ipv4res[0] = '\0';
36194 ipv4a[0] = 0xc0;
36195 ipv4a[1] = 0xa8;
36196 ipv4a[2] = 0x64;
36197 ipv4a[3] = 0x01;
36198 ipv4a[4] = 0x01;
36199 /* - */
36200 ipv4ptr = inet_ntop(AF_INET, ipv4a, ipv4res, sizeof(ipv4res));
36201 if(!ipv4ptr)
36202 exit(1); /* fail */
36203 if(ipv4ptr != ipv4res)
36204 exit(1); /* fail */
36205 if(!ipv4ptr[0])
36206 exit(1); /* fail */
36207 if(memcmp(ipv4res, "192.168.100.1", 13) != 0)
36208 exit(1); /* fail */
36209 /* - */
36210 ipv6res[0] = '\0';
36211 memset(ipv6a, 0, sizeof(ipv6a));
36212 ipv6a[0] = 0xfe;
36213 ipv6a[1] = 0x80;
36214 ipv6a[8] = 0x02;
36215 ipv6a[9] = 0x14;
36216 ipv6a[10] = 0x4f;
36217 ipv6a[11] = 0xff;
36218 ipv6a[12] = 0xfe;
36219 ipv6a[13] = 0x0b;
36220 ipv6a[14] = 0x76;
36221 ipv6a[15] = 0xc8;
36222 ipv6a[25] = 0x01;
36223 /* - */
36224 ipv6ptr = inet_ntop(AF_INET6, ipv6a, ipv6res, sizeof(ipv6res));
36225 if(!ipv6ptr)
36226 exit(1); /* fail */
36227 if(ipv6ptr != ipv6res)
36228 exit(1); /* fail */
36229 if(!ipv6ptr[0])
36230 exit(1); /* fail */
36231 if(memcmp(ipv6res, "fe80::214:4fff:fe0b:76c8", 24) != 0)
36232 exit(1); /* fail */
36233 /* - */
36234 exit(0);
36235
36236 ;
36237 return 0;
36238}
36239
36240_ACEOF
36241if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughesa93fb052018-12-12 14:22:48 -080036242 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070036243$as_echo "yes" >&6; }
36244 tst_works_inet_ntop="yes"
36245
36246else
Elliott Hughesa93fb052018-12-12 14:22:48 -080036247 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070036248$as_echo "no" >&6; }
36249 tst_works_inet_ntop="no"
36250
36251fi
36252rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
36253 conftest.$ac_objext conftest.beam conftest.$ac_ext
36254fi
36255
Elliott Hughesa93fb052018-12-12 14:22:48 -080036256 LD_LIBRARY_PATH=$old # restore
36257
Elliott Hughes82be86d2017-09-20 17:00:17 -070036258 fi
36259 #
36260 if test "$tst_compi_inet_ntop" = "yes" &&
36261 test "$tst_works_inet_ntop" != "no"; then
36262 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_ntop usage allowed" >&5
36263$as_echo_n "checking if inet_ntop usage allowed... " >&6; }
36264 if test "x$curl_disallow_inet_ntop" != "xyes"; then
36265 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36266$as_echo "yes" >&6; }
36267 tst_allow_inet_ntop="yes"
36268 else
36269 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36270$as_echo "no" >&6; }
36271 tst_allow_inet_ntop="no"
36272 fi
36273 fi
36274 #
36275 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_ntop might be used" >&5
36276$as_echo_n "checking if inet_ntop might be used... " >&6; }
36277 if test "$tst_links_inet_ntop" = "yes" &&
36278 test "$tst_proto_inet_ntop" = "yes" &&
36279 test "$tst_compi_inet_ntop" = "yes" &&
36280 test "$tst_allow_inet_ntop" = "yes" &&
36281 test "$tst_works_inet_ntop" != "no"; then
36282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36283$as_echo "yes" >&6; }
36284
36285cat >>confdefs.h <<_ACEOF
36286#define HAVE_INET_NTOP 1
36287_ACEOF
36288
36289 curl_cv_func_inet_ntop="yes"
36290 else
36291 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36292$as_echo "no" >&6; }
36293 curl_cv_func_inet_ntop="no"
36294 fi
36295
36296
36297 #
36298 tst_links_inet_pton="unknown"
36299 tst_proto_inet_pton="unknown"
36300 tst_compi_inet_pton="unknown"
36301 tst_works_inet_pton="unknown"
36302 tst_allow_inet_pton="unknown"
36303 #
36304 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_pton can be linked" >&5
36305$as_echo_n "checking if inet_pton can be linked... " >&6; }
36306 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36307/* end confdefs.h. */
36308
36309
36310#define inet_pton innocuous_inet_pton
36311#ifdef __STDC__
36312# include <limits.h>
36313#else
36314# include <assert.h>
36315#endif
36316#undef inet_pton
36317#ifdef __cplusplus
36318extern "C"
36319#endif
36320char inet_pton ();
36321#if defined __stub_inet_pton || defined __stub___inet_pton
36322choke me
36323#endif
36324
36325int main (void)
36326{
36327return inet_pton ();
36328 ;
36329 return 0;
36330}
36331
36332_ACEOF
36333if ac_fn_c_try_link "$LINENO"; then :
36334
36335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36336$as_echo "yes" >&6; }
36337 tst_links_inet_pton="yes"
36338
36339else
36340
36341 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36342$as_echo "no" >&6; }
36343 tst_links_inet_pton="no"
36344
36345fi
36346rm -f core conftest.err conftest.$ac_objext \
36347 conftest$ac_exeext conftest.$ac_ext
36348 #
36349 if test "$tst_links_inet_pton" = "yes"; then
36350 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_pton is prototyped" >&5
36351$as_echo_n "checking if inet_pton is prototyped... " >&6; }
36352 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36353/* end confdefs.h. */
36354
36355 $curl_includes_arpa_inet
36356
36357_ACEOF
36358if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
36359 $EGREP "inet_pton" >/dev/null 2>&1; then :
36360
36361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36362$as_echo "yes" >&6; }
36363 tst_proto_inet_pton="yes"
36364
36365else
36366
36367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36368$as_echo "no" >&6; }
36369 tst_proto_inet_pton="no"
36370
36371fi
36372rm -f conftest*
36373
36374 fi
36375 #
36376 if test "$tst_proto_inet_pton" = "yes"; then
36377 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_pton is compilable" >&5
36378$as_echo_n "checking if inet_pton is compilable... " >&6; }
36379 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36380/* end confdefs.h. */
36381
36382
36383 $curl_includes_arpa_inet
36384
36385int main (void)
36386{
36387
36388 if(0 != inet_pton(0, 0, 0))
36389 return 1;
36390
36391 ;
36392 return 0;
36393}
36394
36395_ACEOF
36396if ac_fn_c_try_compile "$LINENO"; then :
36397
36398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36399$as_echo "yes" >&6; }
36400 tst_compi_inet_pton="yes"
36401
36402else
36403
36404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36405$as_echo "no" >&6; }
36406 tst_compi_inet_pton="no"
36407
36408fi
36409rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
36410 fi
36411 #
36412 if test "x$cross_compiling" != "xyes" &&
36413 test "$tst_compi_inet_pton" = "yes"; then
36414 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_pton seems to work" >&5
36415$as_echo_n "checking if inet_pton seems to work... " >&6; }
Elliott Hughesa93fb052018-12-12 14:22:48 -080036416
36417
36418 old=$LD_LIBRARY_PATH
36419 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
36420 export LD_LIBRARY_PATH
36421 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070036422 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
36423$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
36424as_fn_error $? "cannot run test program while cross compiling
36425See \`config.log' for more details" "$LINENO" 5; }
36426else
36427 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36428/* end confdefs.h. */
36429
36430
36431 $curl_includes_stdlib
36432 $curl_includes_arpa_inet
36433 $curl_includes_string
36434
36435int main (void)
36436{
36437
36438 unsigned char ipv6a[16+1];
36439 unsigned char ipv4a[4+1];
36440 const char *ipv6src = "fe80::214:4fff:fe0b:76c8";
36441 const char *ipv4src = "192.168.100.1";
36442 /* - */
36443 memset(ipv4a, 1, sizeof(ipv4a));
36444 if(1 != inet_pton(AF_INET, ipv4src, ipv4a))
36445 exit(1); /* fail */
36446 /* - */
36447 if( (ipv4a[0] != 0xc0) ||
36448 (ipv4a[1] != 0xa8) ||
36449 (ipv4a[2] != 0x64) ||
36450 (ipv4a[3] != 0x01) ||
36451 (ipv4a[4] != 0x01) )
36452 exit(1); /* fail */
36453 /* - */
36454 memset(ipv6a, 1, sizeof(ipv6a));
36455 if(1 != inet_pton(AF_INET6, ipv6src, ipv6a))
36456 exit(1); /* fail */
36457 /* - */
36458 if( (ipv6a[0] != 0xfe) ||
36459 (ipv6a[1] != 0x80) ||
36460 (ipv6a[8] != 0x02) ||
36461 (ipv6a[9] != 0x14) ||
36462 (ipv6a[10] != 0x4f) ||
36463 (ipv6a[11] != 0xff) ||
36464 (ipv6a[12] != 0xfe) ||
36465 (ipv6a[13] != 0x0b) ||
36466 (ipv6a[14] != 0x76) ||
36467 (ipv6a[15] != 0xc8) ||
36468 (ipv6a[16] != 0x01) )
36469 exit(1); /* fail */
36470 /* - */
36471 if( (ipv6a[2] != 0x0) ||
36472 (ipv6a[3] != 0x0) ||
36473 (ipv6a[4] != 0x0) ||
36474 (ipv6a[5] != 0x0) ||
36475 (ipv6a[6] != 0x0) ||
36476 (ipv6a[7] != 0x0) )
36477 exit(1); /* fail */
36478 /* - */
36479 exit(0);
36480
36481 ;
36482 return 0;
36483}
36484
36485_ACEOF
36486if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughesa93fb052018-12-12 14:22:48 -080036487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070036488$as_echo "yes" >&6; }
36489 tst_works_inet_pton="yes"
36490
36491else
Elliott Hughesa93fb052018-12-12 14:22:48 -080036492 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070036493$as_echo "no" >&6; }
36494 tst_works_inet_pton="no"
36495
36496fi
36497rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
36498 conftest.$ac_objext conftest.beam conftest.$ac_ext
36499fi
36500
Elliott Hughesa93fb052018-12-12 14:22:48 -080036501 LD_LIBRARY_PATH=$old # restore
36502
Elliott Hughes82be86d2017-09-20 17:00:17 -070036503 fi
36504 #
36505 if test "$tst_compi_inet_pton" = "yes" &&
36506 test "$tst_works_inet_pton" != "no"; then
36507 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_pton usage allowed" >&5
36508$as_echo_n "checking if inet_pton usage allowed... " >&6; }
36509 if test "x$curl_disallow_inet_pton" != "xyes"; then
36510 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36511$as_echo "yes" >&6; }
36512 tst_allow_inet_pton="yes"
36513 else
36514 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36515$as_echo "no" >&6; }
36516 tst_allow_inet_pton="no"
36517 fi
36518 fi
36519 #
36520 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_pton might be used" >&5
36521$as_echo_n "checking if inet_pton might be used... " >&6; }
36522 if test "$tst_links_inet_pton" = "yes" &&
36523 test "$tst_proto_inet_pton" = "yes" &&
36524 test "$tst_compi_inet_pton" = "yes" &&
36525 test "$tst_allow_inet_pton" = "yes" &&
36526 test "$tst_works_inet_pton" != "no"; then
36527 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36528$as_echo "yes" >&6; }
36529
36530cat >>confdefs.h <<_ACEOF
36531#define HAVE_INET_PTON 1
36532_ACEOF
36533
36534 curl_cv_func_inet_pton="yes"
36535 else
36536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36537$as_echo "no" >&6; }
36538 curl_cv_func_inet_pton="no"
36539 fi
36540
36541
36542curl_includes_stropts="\
36543/* includes start */
36544#ifdef HAVE_SYS_TYPES_H
36545# include <sys/types.h>
36546#endif
36547#ifdef HAVE_UNISTD_H
36548# include <unistd.h>
36549#endif
36550#ifdef HAVE_SYS_SOCKET_H
36551# include <sys/socket.h>
36552#endif
36553#ifdef HAVE_SYS_IOCTL_H
36554# include <sys/ioctl.h>
36555#endif
36556#ifdef HAVE_STROPTS_H
36557# include <stropts.h>
36558#endif
36559/* includes end */"
36560 for ac_header in sys/types.h unistd.h sys/socket.h sys/ioctl.h stropts.h
36561do :
36562 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
36563ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_stropts
36564"
36565if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
36566 cat >>confdefs.h <<_ACEOF
36567#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
36568_ACEOF
36569
36570fi
36571
36572done
36573
36574
36575
36576 #
36577 tst_links_ioctl="unknown"
36578 tst_proto_ioctl="unknown"
36579 tst_compi_ioctl="unknown"
36580 tst_allow_ioctl="unknown"
36581 #
36582 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctl can be linked" >&5
36583$as_echo_n "checking if ioctl can be linked... " >&6; }
36584 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36585/* end confdefs.h. */
36586
36587
36588#define ioctl innocuous_ioctl
36589#ifdef __STDC__
36590# include <limits.h>
36591#else
36592# include <assert.h>
36593#endif
36594#undef ioctl
36595#ifdef __cplusplus
36596extern "C"
36597#endif
36598char ioctl ();
36599#if defined __stub_ioctl || defined __stub___ioctl
36600choke me
36601#endif
36602
36603int main (void)
36604{
36605return ioctl ();
36606 ;
36607 return 0;
36608}
36609
36610_ACEOF
36611if ac_fn_c_try_link "$LINENO"; then :
36612
36613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36614$as_echo "yes" >&6; }
36615 tst_links_ioctl="yes"
36616
36617else
36618
36619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36620$as_echo "no" >&6; }
36621 tst_links_ioctl="no"
36622
36623fi
36624rm -f core conftest.err conftest.$ac_objext \
36625 conftest$ac_exeext conftest.$ac_ext
36626 #
36627 if test "$tst_links_ioctl" = "yes"; then
36628 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctl is prototyped" >&5
36629$as_echo_n "checking if ioctl is prototyped... " >&6; }
36630 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36631/* end confdefs.h. */
36632
36633 $curl_includes_stropts
36634
36635_ACEOF
36636if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
36637 $EGREP "ioctl" >/dev/null 2>&1; then :
36638
36639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36640$as_echo "yes" >&6; }
36641 tst_proto_ioctl="yes"
36642
36643else
36644
36645 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36646$as_echo "no" >&6; }
36647 tst_proto_ioctl="no"
36648
36649fi
36650rm -f conftest*
36651
36652 fi
36653 #
36654 if test "$tst_proto_ioctl" = "yes"; then
36655 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctl is compilable" >&5
36656$as_echo_n "checking if ioctl is compilable... " >&6; }
36657 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36658/* end confdefs.h. */
36659
36660
36661 $curl_includes_stropts
36662
36663int main (void)
36664{
36665
36666 if(0 != ioctl(0, 0, 0))
36667 return 1;
36668
36669 ;
36670 return 0;
36671}
36672
36673_ACEOF
36674if ac_fn_c_try_compile "$LINENO"; then :
36675
36676 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36677$as_echo "yes" >&6; }
36678 tst_compi_ioctl="yes"
36679
36680else
36681
36682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36683$as_echo "no" >&6; }
36684 tst_compi_ioctl="no"
36685
36686fi
36687rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
36688 fi
36689 #
36690 if test "$tst_compi_ioctl" = "yes"; then
36691 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctl usage allowed" >&5
36692$as_echo_n "checking if ioctl usage allowed... " >&6; }
36693 if test "x$curl_disallow_ioctl" != "xyes"; then
36694 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36695$as_echo "yes" >&6; }
36696 tst_allow_ioctl="yes"
36697 else
36698 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36699$as_echo "no" >&6; }
36700 tst_allow_ioctl="no"
36701 fi
36702 fi
36703 #
36704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctl might be used" >&5
36705$as_echo_n "checking if ioctl might be used... " >&6; }
36706 if test "$tst_links_ioctl" = "yes" &&
36707 test "$tst_proto_ioctl" = "yes" &&
36708 test "$tst_compi_ioctl" = "yes" &&
36709 test "$tst_allow_ioctl" = "yes"; then
36710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36711$as_echo "yes" >&6; }
36712
36713cat >>confdefs.h <<_ACEOF
36714#define HAVE_IOCTL 1
36715_ACEOF
36716
36717 curl_cv_func_ioctl="yes"
36718
36719 #
36720 tst_compi_ioctl_fionbio="unknown"
36721 tst_allow_ioctl_fionbio="unknown"
36722 #
36723 if test "$curl_cv_func_ioctl" = "yes"; then
36724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctl FIONBIO is compilable" >&5
36725$as_echo_n "checking if ioctl FIONBIO is compilable... " >&6; }
36726 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36727/* end confdefs.h. */
36728
36729
36730 $curl_includes_stropts
36731
36732int main (void)
36733{
36734
36735 int flags = 0;
36736 if(0 != ioctl(0, FIONBIO, &flags))
36737 return 1;
36738
36739 ;
36740 return 0;
36741}
36742
36743_ACEOF
36744if ac_fn_c_try_compile "$LINENO"; then :
36745
36746 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36747$as_echo "yes" >&6; }
36748 tst_compi_ioctl_fionbio="yes"
36749
36750else
36751
36752 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36753$as_echo "no" >&6; }
36754 tst_compi_ioctl_fionbio="no"
36755
36756fi
36757rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
36758 fi
36759 #
36760 if test "$tst_compi_ioctl_fionbio" = "yes"; then
36761 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctl FIONBIO usage allowed" >&5
36762$as_echo_n "checking if ioctl FIONBIO usage allowed... " >&6; }
36763 if test "x$curl_disallow_ioctl_fionbio" != "xyes"; then
36764 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36765$as_echo "yes" >&6; }
36766 tst_allow_ioctl_fionbio="yes"
36767 else
36768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36769$as_echo "no" >&6; }
36770 tst_allow_ioctl_fionbio="no"
36771 fi
36772 fi
36773 #
36774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctl FIONBIO might be used" >&5
36775$as_echo_n "checking if ioctl FIONBIO might be used... " >&6; }
36776 if test "$tst_compi_ioctl_fionbio" = "yes" &&
36777 test "$tst_allow_ioctl_fionbio" = "yes"; then
36778 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36779$as_echo "yes" >&6; }
36780
36781cat >>confdefs.h <<_ACEOF
36782#define HAVE_IOCTL_FIONBIO 1
36783_ACEOF
36784
36785 curl_cv_func_ioctl_fionbio="yes"
36786 else
36787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36788$as_echo "no" >&6; }
36789 curl_cv_func_ioctl_fionbio="no"
36790 fi
36791
36792
36793 #
36794 tst_compi_ioctl_siocgifaddr="unknown"
36795 tst_allow_ioctl_siocgifaddr="unknown"
36796 #
36797 if test "$curl_cv_func_ioctl" = "yes"; then
36798 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctl SIOCGIFADDR is compilable" >&5
36799$as_echo_n "checking if ioctl SIOCGIFADDR is compilable... " >&6; }
36800 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36801/* end confdefs.h. */
36802
36803
36804 $curl_includes_stropts
36805 #include <net/if.h>
36806
36807int main (void)
36808{
36809
36810 struct ifreq ifr;
36811 if(0 != ioctl(0, SIOCGIFADDR, &ifr))
36812 return 1;
36813
36814 ;
36815 return 0;
36816}
36817
36818_ACEOF
36819if ac_fn_c_try_compile "$LINENO"; then :
36820
36821 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36822$as_echo "yes" >&6; }
36823 tst_compi_ioctl_siocgifaddr="yes"
36824
36825else
36826
36827 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36828$as_echo "no" >&6; }
36829 tst_compi_ioctl_siocgifaddr="no"
36830
36831fi
36832rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
36833 fi
36834 #
36835 if test "$tst_compi_ioctl_siocgifaddr" = "yes"; then
36836 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctl SIOCGIFADDR usage allowed" >&5
36837$as_echo_n "checking if ioctl SIOCGIFADDR usage allowed... " >&6; }
36838 if test "x$curl_disallow_ioctl_siocgifaddr" != "xyes"; then
36839 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36840$as_echo "yes" >&6; }
36841 tst_allow_ioctl_siocgifaddr="yes"
36842 else
36843 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36844$as_echo "no" >&6; }
36845 tst_allow_ioctl_siocgifaddr="no"
36846 fi
36847 fi
36848 #
36849 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctl SIOCGIFADDR might be used" >&5
36850$as_echo_n "checking if ioctl SIOCGIFADDR might be used... " >&6; }
36851 if test "$tst_compi_ioctl_siocgifaddr" = "yes" &&
36852 test "$tst_allow_ioctl_siocgifaddr" = "yes"; then
36853 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36854$as_echo "yes" >&6; }
36855
36856cat >>confdefs.h <<_ACEOF
36857#define HAVE_IOCTL_SIOCGIFADDR 1
36858_ACEOF
36859
36860 curl_cv_func_ioctl_siocgifaddr="yes"
36861 else
36862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36863$as_echo "no" >&6; }
36864 curl_cv_func_ioctl_siocgifaddr="no"
36865 fi
36866
36867 else
36868 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36869$as_echo "no" >&6; }
36870 curl_cv_func_ioctl="no"
36871 fi
36872
36873
36874 #
36875 tst_links_ioctlsocket="unknown"
36876 tst_proto_ioctlsocket="unknown"
36877 tst_compi_ioctlsocket="unknown"
36878 tst_allow_ioctlsocket="unknown"
36879 #
36880 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctlsocket can be linked" >&5
36881$as_echo_n "checking if ioctlsocket can be linked... " >&6; }
36882 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36883/* end confdefs.h. */
36884
36885
36886 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070036887 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070036888
36889int main (void)
36890{
36891
36892 if(0 != ioctlsocket(0, 0, 0))
36893 return 1;
36894
36895 ;
36896 return 0;
36897}
36898
36899_ACEOF
36900if ac_fn_c_try_link "$LINENO"; then :
36901
36902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36903$as_echo "yes" >&6; }
36904 tst_links_ioctlsocket="yes"
36905
36906else
36907
36908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36909$as_echo "no" >&6; }
36910 tst_links_ioctlsocket="no"
36911
36912fi
36913rm -f core conftest.err conftest.$ac_objext \
36914 conftest$ac_exeext conftest.$ac_ext
36915 #
36916 if test "$tst_links_ioctlsocket" = "yes"; then
36917 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctlsocket is prototyped" >&5
36918$as_echo_n "checking if ioctlsocket is prototyped... " >&6; }
36919 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36920/* end confdefs.h. */
36921
36922 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070036923 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070036924
36925_ACEOF
36926if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
36927 $EGREP "ioctlsocket" >/dev/null 2>&1; then :
36928
36929 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36930$as_echo "yes" >&6; }
36931 tst_proto_ioctlsocket="yes"
36932
36933else
36934
36935 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36936$as_echo "no" >&6; }
36937 tst_proto_ioctlsocket="no"
36938
36939fi
36940rm -f conftest*
36941
36942 fi
36943 #
36944 if test "$tst_proto_ioctlsocket" = "yes"; then
36945 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctlsocket is compilable" >&5
36946$as_echo_n "checking if ioctlsocket is compilable... " >&6; }
36947 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36948/* end confdefs.h. */
36949
36950
36951 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070036952 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070036953
36954int main (void)
36955{
36956
36957 if(0 != ioctlsocket(0, 0, 0))
36958 return 1;
36959
36960 ;
36961 return 0;
36962}
36963
36964_ACEOF
36965if ac_fn_c_try_compile "$LINENO"; then :
36966
36967 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36968$as_echo "yes" >&6; }
36969 tst_compi_ioctlsocket="yes"
36970
36971else
36972
36973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36974$as_echo "no" >&6; }
36975 tst_compi_ioctlsocket="no"
36976
36977fi
36978rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
36979 fi
36980 #
36981 if test "$tst_compi_ioctlsocket" = "yes"; then
36982 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctlsocket usage allowed" >&5
36983$as_echo_n "checking if ioctlsocket usage allowed... " >&6; }
36984 if test "x$curl_disallow_ioctlsocket" != "xyes"; then
36985 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36986$as_echo "yes" >&6; }
36987 tst_allow_ioctlsocket="yes"
36988 else
36989 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36990$as_echo "no" >&6; }
36991 tst_allow_ioctlsocket="no"
36992 fi
36993 fi
36994 #
36995 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctlsocket might be used" >&5
36996$as_echo_n "checking if ioctlsocket might be used... " >&6; }
36997 if test "$tst_links_ioctlsocket" = "yes" &&
36998 test "$tst_proto_ioctlsocket" = "yes" &&
36999 test "$tst_compi_ioctlsocket" = "yes" &&
37000 test "$tst_allow_ioctlsocket" = "yes"; then
37001 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37002$as_echo "yes" >&6; }
37003
37004cat >>confdefs.h <<_ACEOF
37005#define HAVE_IOCTLSOCKET 1
37006_ACEOF
37007
37008 curl_cv_func_ioctlsocket="yes"
37009
37010 #
37011 tst_compi_ioctlsocket_fionbio="unknown"
37012 tst_allow_ioctlsocket_fionbio="unknown"
37013 #
37014 if test "$curl_cv_func_ioctlsocket" = "yes"; then
37015 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctlsocket FIONBIO is compilable" >&5
37016$as_echo_n "checking if ioctlsocket FIONBIO is compilable... " >&6; }
37017 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37018/* end confdefs.h. */
37019
37020
37021 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070037022 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070037023
37024int main (void)
37025{
37026
37027 int flags = 0;
37028 if(0 != ioctlsocket(0, FIONBIO, &flags))
37029 return 1;
37030
37031 ;
37032 return 0;
37033}
37034
37035_ACEOF
37036if ac_fn_c_try_compile "$LINENO"; then :
37037
37038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37039$as_echo "yes" >&6; }
37040 tst_compi_ioctlsocket_fionbio="yes"
37041
37042else
37043
37044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37045$as_echo "no" >&6; }
37046 tst_compi_ioctlsocket_fionbio="no"
37047
37048fi
37049rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
37050 fi
37051 #
37052 if test "$tst_compi_ioctlsocket_fionbio" = "yes"; then
37053 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctlsocket FIONBIO usage allowed" >&5
37054$as_echo_n "checking if ioctlsocket FIONBIO usage allowed... " >&6; }
37055 if test "x$curl_disallow_ioctlsocket_fionbio" != "xyes"; then
37056 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37057$as_echo "yes" >&6; }
37058 tst_allow_ioctlsocket_fionbio="yes"
37059 else
37060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37061$as_echo "no" >&6; }
37062 tst_allow_ioctlsocket_fionbio="no"
37063 fi
37064 fi
37065 #
37066 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctlsocket FIONBIO might be used" >&5
37067$as_echo_n "checking if ioctlsocket FIONBIO might be used... " >&6; }
37068 if test "$tst_compi_ioctlsocket_fionbio" = "yes" &&
37069 test "$tst_allow_ioctlsocket_fionbio" = "yes"; then
37070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37071$as_echo "yes" >&6; }
37072
37073cat >>confdefs.h <<_ACEOF
37074#define HAVE_IOCTLSOCKET_FIONBIO 1
37075_ACEOF
37076
37077 curl_cv_func_ioctlsocket_fionbio="yes"
37078 else
37079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37080$as_echo "no" >&6; }
37081 curl_cv_func_ioctlsocket_fionbio="no"
37082 fi
37083
37084 else
37085 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37086$as_echo "no" >&6; }
37087 curl_cv_func_ioctlsocket="no"
37088 fi
37089
37090
37091 #
37092 tst_links_ioctlsocket_camel="unknown"
37093 tst_proto_ioctlsocket_camel="unknown"
37094 tst_compi_ioctlsocket_camel="unknown"
37095 tst_allow_ioctlsocket_camel="unknown"
37096 #
37097 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if IoctlSocket can be linked" >&5
37098$as_echo_n "checking if IoctlSocket can be linked... " >&6; }
37099 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37100/* end confdefs.h. */
37101
37102
37103#define IoctlSocket innocuous_IoctlSocket
37104#ifdef __STDC__
37105# include <limits.h>
37106#else
37107# include <assert.h>
37108#endif
37109#undef IoctlSocket
37110#ifdef __cplusplus
37111extern "C"
37112#endif
37113char IoctlSocket ();
37114#if defined __stub_IoctlSocket || defined __stub___IoctlSocket
37115choke me
37116#endif
37117
37118int main (void)
37119{
37120return IoctlSocket ();
37121 ;
37122 return 0;
37123}
37124
37125_ACEOF
37126if ac_fn_c_try_link "$LINENO"; then :
37127
37128 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37129$as_echo "yes" >&6; }
37130 tst_links_ioctlsocket_camel="yes"
37131
37132else
37133
37134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37135$as_echo "no" >&6; }
37136 tst_links_ioctlsocket_camel="no"
37137
37138fi
37139rm -f core conftest.err conftest.$ac_objext \
37140 conftest$ac_exeext conftest.$ac_ext
37141 #
37142 if test "$tst_links_ioctlsocket_camel" = "yes"; then
37143 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if IoctlSocket is prototyped" >&5
37144$as_echo_n "checking if IoctlSocket is prototyped... " >&6; }
37145 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37146/* end confdefs.h. */
37147
37148 $curl_includes_stropts
37149
37150_ACEOF
37151if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
37152 $EGREP "IoctlSocket" >/dev/null 2>&1; then :
37153
37154 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37155$as_echo "yes" >&6; }
37156 tst_proto_ioctlsocket_camel="yes"
37157
37158else
37159
37160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37161$as_echo "no" >&6; }
37162 tst_proto_ioctlsocket_camel="no"
37163
37164fi
37165rm -f conftest*
37166
37167 fi
37168 #
37169 if test "$tst_proto_ioctlsocket_camel" = "yes"; then
37170 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if IoctlSocket is compilable" >&5
37171$as_echo_n "checking if IoctlSocket is compilable... " >&6; }
37172 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37173/* end confdefs.h. */
37174
37175
37176 $curl_includes_stropts
37177
37178int main (void)
37179{
37180
37181 if(0 != IoctlSocket(0, 0, 0))
37182 return 1;
37183
37184 ;
37185 return 0;
37186}
37187
37188_ACEOF
37189if ac_fn_c_try_compile "$LINENO"; then :
37190
37191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37192$as_echo "yes" >&6; }
37193 tst_compi_ioctlsocket_camel="yes"
37194
37195else
37196
37197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37198$as_echo "no" >&6; }
37199 tst_compi_ioctlsocket_camel="no"
37200
37201fi
37202rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
37203 fi
37204 #
37205 if test "$tst_compi_ioctlsocket_camel" = "yes"; then
37206 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if IoctlSocket usage allowed" >&5
37207$as_echo_n "checking if IoctlSocket usage allowed... " >&6; }
37208 if test "x$curl_disallow_ioctlsocket_camel" != "xyes"; then
37209 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37210$as_echo "yes" >&6; }
37211 tst_allow_ioctlsocket_camel="yes"
37212 else
37213 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37214$as_echo "no" >&6; }
37215 tst_allow_ioctlsocket_camel="no"
37216 fi
37217 fi
37218 #
37219 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if IoctlSocket might be used" >&5
37220$as_echo_n "checking if IoctlSocket might be used... " >&6; }
37221 if test "$tst_links_ioctlsocket_camel" = "yes" &&
37222 test "$tst_proto_ioctlsocket_camel" = "yes" &&
37223 test "$tst_compi_ioctlsocket_camel" = "yes" &&
37224 test "$tst_allow_ioctlsocket_camel" = "yes"; then
37225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37226$as_echo "yes" >&6; }
37227
37228cat >>confdefs.h <<_ACEOF
37229#define HAVE_IOCTLSOCKET_CAMEL 1
37230_ACEOF
37231
37232 curl_cv_func_ioctlsocket_camel="yes"
37233
37234 #
37235 tst_compi_ioctlsocket_camel_fionbio="unknown"
37236 tst_allow_ioctlsocket_camel_fionbio="unknown"
37237 #
37238 if test "$curl_cv_func_ioctlsocket_camel" = "yes"; then
37239 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if IoctlSocket FIONBIO is compilable" >&5
37240$as_echo_n "checking if IoctlSocket FIONBIO is compilable... " >&6; }
37241 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37242/* end confdefs.h. */
37243
37244
37245 $curl_includes_stropts
37246
37247int main (void)
37248{
37249
37250 long flags = 0;
37251 if(0 != ioctlsocket(0, FIONBIO, &flags))
37252 return 1;
37253
37254 ;
37255 return 0;
37256}
37257
37258_ACEOF
37259if ac_fn_c_try_compile "$LINENO"; then :
37260
37261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37262$as_echo "yes" >&6; }
37263 tst_compi_ioctlsocket_camel_fionbio="yes"
37264
37265else
37266
37267 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37268$as_echo "no" >&6; }
37269 tst_compi_ioctlsocket_camel_fionbio="no"
37270
37271fi
37272rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
37273 fi
37274 #
37275 if test "$tst_compi_ioctlsocket_camel_fionbio" = "yes"; then
37276 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if IoctlSocket FIONBIO usage allowed" >&5
37277$as_echo_n "checking if IoctlSocket FIONBIO usage allowed... " >&6; }
37278 if test "x$curl_disallow_ioctlsocket_camel_fionbio" != "xyes"; then
37279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37280$as_echo "yes" >&6; }
37281 tst_allow_ioctlsocket_camel_fionbio="yes"
37282 else
37283 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37284$as_echo "no" >&6; }
37285 tst_allow_ioctlsocket_camel_fionbio="no"
37286 fi
37287 fi
37288 #
37289 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if IoctlSocket FIONBIO might be used" >&5
37290$as_echo_n "checking if IoctlSocket FIONBIO might be used... " >&6; }
37291 if test "$tst_compi_ioctlsocket_camel_fionbio" = "yes" &&
37292 test "$tst_allow_ioctlsocket_camel_fionbio" = "yes"; then
37293 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37294$as_echo "yes" >&6; }
37295
37296cat >>confdefs.h <<_ACEOF
37297#define HAVE_IOCTLSOCKET_CAMEL_FIONBIO 1
37298_ACEOF
37299
37300 curl_cv_func_ioctlsocket_camel_fionbio="yes"
37301 else
37302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37303$as_echo "no" >&6; }
37304 curl_cv_func_ioctlsocket_camel_fionbio="no"
37305 fi
37306
37307 else
37308 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37309$as_echo "no" >&6; }
37310 curl_cv_func_ioctlsocket_camel="no"
37311 fi
37312
37313
37314 #
37315 tst_links_localtime_r="unknown"
37316 tst_proto_localtime_r="unknown"
37317 tst_compi_localtime_r="unknown"
37318 tst_works_localtime_r="unknown"
37319 tst_allow_localtime_r="unknown"
37320 #
37321 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if localtime_r can be linked" >&5
37322$as_echo_n "checking if localtime_r can be linked... " >&6; }
37323 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37324/* end confdefs.h. */
37325
37326
37327#define localtime_r innocuous_localtime_r
37328#ifdef __STDC__
37329# include <limits.h>
37330#else
37331# include <assert.h>
37332#endif
37333#undef localtime_r
37334#ifdef __cplusplus
37335extern "C"
37336#endif
37337char localtime_r ();
37338#if defined __stub_localtime_r || defined __stub___localtime_r
37339choke me
37340#endif
37341
37342int main (void)
37343{
37344return localtime_r ();
37345 ;
37346 return 0;
37347}
37348
37349_ACEOF
37350if ac_fn_c_try_link "$LINENO"; then :
37351
37352 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37353$as_echo "yes" >&6; }
37354 tst_links_localtime_r="yes"
37355
37356else
37357
37358 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37359$as_echo "no" >&6; }
37360 tst_links_localtime_r="no"
37361
37362fi
37363rm -f core conftest.err conftest.$ac_objext \
37364 conftest$ac_exeext conftest.$ac_ext
37365 #
37366 if test "$tst_links_localtime_r" = "yes"; then
37367 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if localtime_r is prototyped" >&5
37368$as_echo_n "checking if localtime_r is prototyped... " >&6; }
37369 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37370/* end confdefs.h. */
37371
37372 $curl_includes_time
37373
37374_ACEOF
37375if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
37376 $EGREP "localtime_r" >/dev/null 2>&1; then :
37377
37378 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37379$as_echo "yes" >&6; }
37380 tst_proto_localtime_r="yes"
37381
37382else
37383
37384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37385$as_echo "no" >&6; }
37386 tst_proto_localtime_r="no"
37387
37388fi
37389rm -f conftest*
37390
37391 fi
37392 #
37393 if test "$tst_proto_localtime_r" = "yes"; then
37394 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if localtime_r is compilable" >&5
37395$as_echo_n "checking if localtime_r is compilable... " >&6; }
37396 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37397/* end confdefs.h. */
37398
37399
37400 $curl_includes_time
37401
37402int main (void)
37403{
37404
37405 if(0 != localtime_r(0, 0))
37406 return 1;
37407
37408 ;
37409 return 0;
37410}
37411
37412_ACEOF
37413if ac_fn_c_try_compile "$LINENO"; then :
37414
37415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37416$as_echo "yes" >&6; }
37417 tst_compi_localtime_r="yes"
37418
37419else
37420
37421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37422$as_echo "no" >&6; }
37423 tst_compi_localtime_r="no"
37424
37425fi
37426rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
37427 fi
37428 #
37429 if test "x$cross_compiling" != "xyes" &&
37430 test "$tst_compi_localtime_r" = "yes"; then
37431 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if localtime_r seems to work" >&5
37432$as_echo_n "checking if localtime_r seems to work... " >&6; }
Elliott Hughesa93fb052018-12-12 14:22:48 -080037433
37434
37435 old=$LD_LIBRARY_PATH
37436 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
37437 export LD_LIBRARY_PATH
37438 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070037439 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
37440$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
37441as_fn_error $? "cannot run test program while cross compiling
37442See \`config.log' for more details" "$LINENO" 5; }
37443else
37444 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37445/* end confdefs.h. */
37446
37447
37448 $curl_includes_stdlib
37449 $curl_includes_time
37450
37451int main (void)
37452{
37453
37454 time_t clock = 1170352587;
37455 struct tm *tmp = 0;
37456 struct tm result;
37457 tmp = localtime_r(&clock, &result);
37458 if(tmp)
37459 exit(0);
37460 else
37461 exit(1);
37462
37463 ;
37464 return 0;
37465}
37466
37467_ACEOF
37468if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughesa93fb052018-12-12 14:22:48 -080037469 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070037470$as_echo "yes" >&6; }
37471 tst_works_localtime_r="yes"
37472
37473else
Elliott Hughesa93fb052018-12-12 14:22:48 -080037474 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070037475$as_echo "no" >&6; }
37476 tst_works_localtime_r="no"
37477
37478fi
37479rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
37480 conftest.$ac_objext conftest.beam conftest.$ac_ext
37481fi
37482
Elliott Hughesa93fb052018-12-12 14:22:48 -080037483 LD_LIBRARY_PATH=$old # restore
37484
Elliott Hughes82be86d2017-09-20 17:00:17 -070037485 fi
37486 #
37487 if test "$tst_compi_localtime_r" = "yes" &&
37488 test "$tst_works_localtime_r" != "no"; then
37489 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if localtime_r usage allowed" >&5
37490$as_echo_n "checking if localtime_r usage allowed... " >&6; }
37491 if test "x$curl_disallow_localtime_r" != "xyes"; then
37492 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37493$as_echo "yes" >&6; }
37494 tst_allow_localtime_r="yes"
37495 else
37496 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37497$as_echo "no" >&6; }
37498 tst_allow_localtime_r="no"
37499 fi
37500 fi
37501 #
37502 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if localtime_r might be used" >&5
37503$as_echo_n "checking if localtime_r might be used... " >&6; }
37504 if test "$tst_links_localtime_r" = "yes" &&
37505 test "$tst_proto_localtime_r" = "yes" &&
37506 test "$tst_compi_localtime_r" = "yes" &&
37507 test "$tst_allow_localtime_r" = "yes" &&
37508 test "$tst_works_localtime_r" != "no"; then
37509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37510$as_echo "yes" >&6; }
37511
37512cat >>confdefs.h <<_ACEOF
37513#define HAVE_LOCALTIME_R 1
37514_ACEOF
37515
37516 curl_cv_func_localtime_r="yes"
37517 else
37518 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37519$as_echo "no" >&6; }
37520 curl_cv_func_localtime_r="no"
37521 fi
37522
37523
37524 #
37525 tst_links_memrchr="unknown"
37526 tst_macro_memrchr="unknown"
37527 tst_proto_memrchr="unknown"
37528 tst_compi_memrchr="unknown"
37529 tst_allow_memrchr="unknown"
37530 #
37531 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if memrchr can be linked" >&5
37532$as_echo_n "checking if memrchr can be linked... " >&6; }
37533 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37534/* end confdefs.h. */
37535
37536
37537#define memrchr innocuous_memrchr
37538#ifdef __STDC__
37539# include <limits.h>
37540#else
37541# include <assert.h>
37542#endif
37543#undef memrchr
37544#ifdef __cplusplus
37545extern "C"
37546#endif
37547char memrchr ();
37548#if defined __stub_memrchr || defined __stub___memrchr
37549choke me
37550#endif
37551
37552int main (void)
37553{
37554return memrchr ();
37555 ;
37556 return 0;
37557}
37558
37559_ACEOF
37560if ac_fn_c_try_link "$LINENO"; then :
37561
37562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37563$as_echo "yes" >&6; }
37564 tst_links_memrchr="yes"
37565
37566else
37567
37568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37569$as_echo "no" >&6; }
37570 tst_links_memrchr="no"
37571
37572fi
37573rm -f core conftest.err conftest.$ac_objext \
37574 conftest$ac_exeext conftest.$ac_ext
37575 #
37576 if test "$tst_links_memrchr" = "no"; then
37577 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if memrchr seems a macro" >&5
37578$as_echo_n "checking if memrchr seems a macro... " >&6; }
37579 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37580/* end confdefs.h. */
37581
37582
37583 $curl_includes_string
37584
37585int main (void)
37586{
37587
37588 if(0 != memrchr(0, 0, 0))
37589 return 1;
37590
37591 ;
37592 return 0;
37593}
37594
37595_ACEOF
37596if ac_fn_c_try_link "$LINENO"; then :
37597
37598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37599$as_echo "yes" >&6; }
37600 tst_macro_memrchr="yes"
37601
37602else
37603
37604 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37605$as_echo "no" >&6; }
37606 tst_macro_memrchr="no"
37607
37608fi
37609rm -f core conftest.err conftest.$ac_objext \
37610 conftest$ac_exeext conftest.$ac_ext
37611 fi
37612 #
37613 if test "$tst_links_memrchr" = "yes"; then
37614 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if memrchr is prototyped" >&5
37615$as_echo_n "checking if memrchr is prototyped... " >&6; }
37616 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37617/* end confdefs.h. */
37618
37619 $curl_includes_string
37620
37621_ACEOF
37622if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
37623 $EGREP "memrchr" >/dev/null 2>&1; then :
37624
37625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37626$as_echo "yes" >&6; }
37627 tst_proto_memrchr="yes"
37628
37629else
37630
37631 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37632$as_echo "no" >&6; }
37633 tst_proto_memrchr="no"
37634
37635fi
37636rm -f conftest*
37637
37638 fi
37639 #
37640 if test "$tst_proto_memrchr" = "yes" ||
37641 test "$tst_macro_memrchr" = "yes"; then
37642 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if memrchr is compilable" >&5
37643$as_echo_n "checking if memrchr is compilable... " >&6; }
37644 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37645/* end confdefs.h. */
37646
37647
37648 $curl_includes_string
37649
37650int main (void)
37651{
37652
37653 if(0 != memrchr(0, 0, 0))
37654 return 1;
37655
37656 ;
37657 return 0;
37658}
37659
37660_ACEOF
37661if ac_fn_c_try_compile "$LINENO"; then :
37662
37663 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37664$as_echo "yes" >&6; }
37665 tst_compi_memrchr="yes"
37666
37667else
37668
37669 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37670$as_echo "no" >&6; }
37671 tst_compi_memrchr="no"
37672
37673fi
37674rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
37675 fi
37676 #
37677 if test "$tst_compi_memrchr" = "yes"; then
37678 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if memrchr usage allowed" >&5
37679$as_echo_n "checking if memrchr usage allowed... " >&6; }
37680 if test "x$curl_disallow_memrchr" != "xyes"; then
37681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37682$as_echo "yes" >&6; }
37683 tst_allow_memrchr="yes"
37684 else
37685 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37686$as_echo "no" >&6; }
37687 tst_allow_memrchr="no"
37688 fi
37689 fi
37690 #
37691 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if memrchr might be used" >&5
37692$as_echo_n "checking if memrchr might be used... " >&6; }
37693 if (test "$tst_proto_memrchr" = "yes" ||
37694 test "$tst_macro_memrchr" = "yes") &&
37695 test "$tst_compi_memrchr" = "yes" &&
37696 test "$tst_allow_memrchr" = "yes"; then
37697 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37698$as_echo "yes" >&6; }
37699
37700cat >>confdefs.h <<_ACEOF
37701#define HAVE_MEMRCHR 1
37702_ACEOF
37703
37704 curl_cv_func_memrchr="yes"
37705 else
37706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37707$as_echo "no" >&6; }
37708 curl_cv_func_memrchr="no"
37709 fi
37710
37711
37712 #
37713 tst_links_poll="unknown"
37714 tst_proto_poll="unknown"
37715 tst_compi_poll="unknown"
37716 tst_works_poll="unknown"
37717 tst_allow_poll="unknown"
37718 #
37719 case $host_os in
37720 darwin*|interix*)
37721 curl_disallow_poll="yes"
37722 tst_compi_poll="no"
37723 ;;
37724 esac
37725 #
37726 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if poll can be linked" >&5
37727$as_echo_n "checking if poll can be linked... " >&6; }
37728 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37729/* end confdefs.h. */
37730
37731
37732 $curl_includes_poll
37733
37734int main (void)
37735{
37736
37737 if(0 != poll(0, 0, 0))
37738 return 1;
37739
37740 ;
37741 return 0;
37742}
37743
37744_ACEOF
37745if ac_fn_c_try_link "$LINENO"; then :
37746
37747 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37748$as_echo "yes" >&6; }
37749 tst_links_poll="yes"
37750
37751else
37752
37753 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37754$as_echo "no" >&6; }
37755 tst_links_poll="no"
37756
37757fi
37758rm -f core conftest.err conftest.$ac_objext \
37759 conftest$ac_exeext conftest.$ac_ext
37760 #
37761 if test "$tst_links_poll" = "yes"; then
37762 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if poll is prototyped" >&5
37763$as_echo_n "checking if poll is prototyped... " >&6; }
37764 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37765/* end confdefs.h. */
37766
37767 $curl_includes_poll
37768
37769_ACEOF
37770if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
37771 $EGREP "poll" >/dev/null 2>&1; then :
37772
37773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37774$as_echo "yes" >&6; }
37775 tst_proto_poll="yes"
37776
37777else
37778
37779 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37780$as_echo "no" >&6; }
37781 tst_proto_poll="no"
37782
37783fi
37784rm -f conftest*
37785
37786 fi
37787 #
37788 if test "$tst_proto_poll" = "yes"; then
37789 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if poll is compilable" >&5
37790$as_echo_n "checking if poll is compilable... " >&6; }
37791 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37792/* end confdefs.h. */
37793
37794
37795 $curl_includes_poll
37796
37797int main (void)
37798{
37799
37800 if(0 != poll(0, 0, 0))
37801 return 1;
37802
37803 ;
37804 return 0;
37805}
37806
37807_ACEOF
37808if ac_fn_c_try_compile "$LINENO"; then :
37809
37810 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37811$as_echo "yes" >&6; }
37812 tst_compi_poll="yes"
37813
37814else
37815
37816 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37817$as_echo "no" >&6; }
37818 tst_compi_poll="no"
37819
37820fi
37821rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
37822 fi
37823 #
37824 if test "x$cross_compiling" != "xyes" &&
37825 test "$tst_compi_poll" = "yes"; then
37826 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if poll seems to work" >&5
37827$as_echo_n "checking if poll seems to work... " >&6; }
Elliott Hughesa93fb052018-12-12 14:22:48 -080037828
37829
37830 old=$LD_LIBRARY_PATH
37831 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
37832 export LD_LIBRARY_PATH
37833 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070037834 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
37835$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
37836as_fn_error $? "cannot run test program while cross compiling
37837See \`config.log' for more details" "$LINENO" 5; }
37838else
37839 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37840/* end confdefs.h. */
37841
37842
37843 $curl_includes_stdlib
37844 $curl_includes_poll
37845 $curl_includes_time
37846
37847int main (void)
37848{
37849
37850 /* detect the original poll() breakage */
37851 if(0 != poll(0, 0, 10))
37852 exit(1); /* fail */
37853 else {
37854 /* detect the 10.12 poll() breakage */
37855 struct timeval before, after;
37856 int rc;
37857 size_t us;
37858
37859 gettimeofday(&before, NULL);
37860 rc = poll(NULL, 0, 500);
37861 gettimeofday(&after, NULL);
37862
37863 us = (after.tv_sec - before.tv_sec) * 1000000 +
37864 (after.tv_usec - before.tv_usec);
37865
37866 if(us < 400000)
37867 exit(1);
37868 }
37869
37870 ;
37871 return 0;
37872}
37873
37874_ACEOF
37875if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughesa93fb052018-12-12 14:22:48 -080037876 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070037877$as_echo "yes" >&6; }
37878 tst_works_poll="yes"
37879
37880else
Elliott Hughesa93fb052018-12-12 14:22:48 -080037881 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070037882$as_echo "no" >&6; }
37883 tst_works_poll="no"
37884
37885fi
37886rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
37887 conftest.$ac_objext conftest.beam conftest.$ac_ext
37888fi
37889
Elliott Hughesa93fb052018-12-12 14:22:48 -080037890 LD_LIBRARY_PATH=$old # restore
37891
Elliott Hughes82be86d2017-09-20 17:00:17 -070037892 fi
37893 #
37894 if test "$tst_compi_poll" = "yes" &&
37895 test "$tst_works_poll" != "no"; then
37896 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if poll usage allowed" >&5
37897$as_echo_n "checking if poll usage allowed... " >&6; }
37898 if test "x$curl_disallow_poll" != "xyes"; then
37899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37900$as_echo "yes" >&6; }
37901 tst_allow_poll="yes"
37902 else
37903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37904$as_echo "no" >&6; }
37905 tst_allow_poll="no"
37906 fi
37907 fi
37908 #
37909 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if poll might be used" >&5
37910$as_echo_n "checking if poll might be used... " >&6; }
37911 if test "$tst_links_poll" = "yes" &&
37912 test "$tst_proto_poll" = "yes" &&
37913 test "$tst_compi_poll" = "yes" &&
37914 test "$tst_allow_poll" = "yes" &&
37915 test "$tst_works_poll" != "no"; then
37916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37917$as_echo "yes" >&6; }
37918
37919cat >>confdefs.h <<_ACEOF
37920#define HAVE_POLL 1
37921_ACEOF
37922
37923
37924cat >>confdefs.h <<_ACEOF
37925#define HAVE_POLL_FINE 1
37926_ACEOF
37927
37928 curl_cv_func_poll="yes"
37929 else
37930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37931$as_echo "no" >&6; }
37932 curl_cv_func_poll="no"
37933 fi
37934
37935
37936 #
37937 tst_links_setsockopt="unknown"
37938 tst_proto_setsockopt="unknown"
37939 tst_compi_setsockopt="unknown"
37940 tst_allow_setsockopt="unknown"
37941 #
37942 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if setsockopt can be linked" >&5
37943$as_echo_n "checking if setsockopt can be linked... " >&6; }
37944 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37945/* end confdefs.h. */
37946
37947
37948 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070037949 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070037950 $curl_includes_sys_socket
37951
37952int main (void)
37953{
37954
37955 if(0 != setsockopt(0, 0, 0, 0, 0))
37956 return 1;
37957
37958 ;
37959 return 0;
37960}
37961
37962_ACEOF
37963if ac_fn_c_try_link "$LINENO"; then :
37964
37965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37966$as_echo "yes" >&6; }
37967 tst_links_setsockopt="yes"
37968
37969else
37970
37971 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37972$as_echo "no" >&6; }
37973 tst_links_setsockopt="no"
37974
37975fi
37976rm -f core conftest.err conftest.$ac_objext \
37977 conftest$ac_exeext conftest.$ac_ext
37978 #
37979 if test "$tst_links_setsockopt" = "yes"; then
37980 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if setsockopt is prototyped" >&5
37981$as_echo_n "checking if setsockopt is prototyped... " >&6; }
37982 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37983/* end confdefs.h. */
37984
37985 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070037986 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070037987 $curl_includes_sys_socket
37988
37989_ACEOF
37990if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
37991 $EGREP "setsockopt" >/dev/null 2>&1; then :
37992
37993 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37994$as_echo "yes" >&6; }
37995 tst_proto_setsockopt="yes"
37996
37997else
37998
37999 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38000$as_echo "no" >&6; }
38001 tst_proto_setsockopt="no"
38002
38003fi
38004rm -f conftest*
38005
38006 fi
38007 #
38008 if test "$tst_proto_setsockopt" = "yes"; then
38009 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if setsockopt is compilable" >&5
38010$as_echo_n "checking if setsockopt is compilable... " >&6; }
38011 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38012/* end confdefs.h. */
38013
38014
38015 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070038016 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070038017 $curl_includes_sys_socket
38018
38019int main (void)
38020{
38021
38022 if(0 != setsockopt(0, 0, 0, 0, 0))
38023 return 1;
38024
38025 ;
38026 return 0;
38027}
38028
38029_ACEOF
38030if ac_fn_c_try_compile "$LINENO"; then :
38031
38032 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38033$as_echo "yes" >&6; }
38034 tst_compi_setsockopt="yes"
38035
38036else
38037
38038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38039$as_echo "no" >&6; }
38040 tst_compi_setsockopt="no"
38041
38042fi
38043rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
38044 fi
38045 #
38046 if test "$tst_compi_setsockopt" = "yes"; then
38047 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if setsockopt usage allowed" >&5
38048$as_echo_n "checking if setsockopt usage allowed... " >&6; }
38049 if test "x$curl_disallow_setsockopt" != "xyes"; then
38050 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38051$as_echo "yes" >&6; }
38052 tst_allow_setsockopt="yes"
38053 else
38054 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38055$as_echo "no" >&6; }
38056 tst_allow_setsockopt="no"
38057 fi
38058 fi
38059 #
38060 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if setsockopt might be used" >&5
38061$as_echo_n "checking if setsockopt might be used... " >&6; }
38062 if test "$tst_links_setsockopt" = "yes" &&
38063 test "$tst_proto_setsockopt" = "yes" &&
38064 test "$tst_compi_setsockopt" = "yes" &&
38065 test "$tst_allow_setsockopt" = "yes"; then
38066 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38067$as_echo "yes" >&6; }
38068
38069cat >>confdefs.h <<_ACEOF
38070#define HAVE_SETSOCKOPT 1
38071_ACEOF
38072
38073 curl_cv_func_setsockopt="yes"
38074
38075 #
38076 tst_compi_setsockopt_so_nonblock="unknown"
38077 tst_allow_setsockopt_so_nonblock="unknown"
38078 #
38079 if test "$curl_cv_func_setsockopt" = "yes"; then
38080 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if setsockopt SO_NONBLOCK is compilable" >&5
38081$as_echo_n "checking if setsockopt SO_NONBLOCK is compilable... " >&6; }
38082 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38083/* end confdefs.h. */
38084
38085
38086 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070038087 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070038088 $curl_includes_sys_socket
38089
38090int main (void)
38091{
38092
38093 if(0 != setsockopt(0, SOL_SOCKET, SO_NONBLOCK, 0, 0))
38094 return 1;
38095
38096 ;
38097 return 0;
38098}
38099
38100_ACEOF
38101if ac_fn_c_try_compile "$LINENO"; then :
38102
38103 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38104$as_echo "yes" >&6; }
38105 tst_compi_setsockopt_so_nonblock="yes"
38106
38107else
38108
38109 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38110$as_echo "no" >&6; }
38111 tst_compi_setsockopt_so_nonblock="no"
38112
38113fi
38114rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
38115 fi
38116 #
38117 if test "$tst_compi_setsockopt_so_nonblock" = "yes"; then
38118 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if setsockopt SO_NONBLOCK usage allowed" >&5
38119$as_echo_n "checking if setsockopt SO_NONBLOCK usage allowed... " >&6; }
38120 if test "x$curl_disallow_setsockopt_so_nonblock" != "xyes"; then
38121 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38122$as_echo "yes" >&6; }
38123 tst_allow_setsockopt_so_nonblock="yes"
38124 else
38125 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38126$as_echo "no" >&6; }
38127 tst_allow_setsockopt_so_nonblock="no"
38128 fi
38129 fi
38130 #
38131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if setsockopt SO_NONBLOCK might be used" >&5
38132$as_echo_n "checking if setsockopt SO_NONBLOCK might be used... " >&6; }
38133 if test "$tst_compi_setsockopt_so_nonblock" = "yes" &&
38134 test "$tst_allow_setsockopt_so_nonblock" = "yes"; then
38135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38136$as_echo "yes" >&6; }
38137
38138cat >>confdefs.h <<_ACEOF
38139#define HAVE_SETSOCKOPT_SO_NONBLOCK 1
38140_ACEOF
38141
38142 curl_cv_func_setsockopt_so_nonblock="yes"
38143 else
38144 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38145$as_echo "no" >&6; }
38146 curl_cv_func_setsockopt_so_nonblock="no"
38147 fi
38148
38149 else
38150 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38151$as_echo "no" >&6; }
38152 curl_cv_func_setsockopt="no"
38153 fi
38154
38155
38156curl_includes_signal="\
38157/* includes start */
38158#ifdef HAVE_SYS_TYPES_H
38159# include <sys/types.h>
38160#endif
38161#ifdef HAVE_SIGNAL_H
38162# include <signal.h>
38163#endif
38164/* includes end */"
38165 for ac_header in sys/types.h signal.h
38166do :
38167 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
38168ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_signal
38169"
38170if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
38171 cat >>confdefs.h <<_ACEOF
38172#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
38173_ACEOF
38174
38175fi
38176
38177done
38178
38179
38180
38181 #
38182 tst_links_sigaction="unknown"
38183 tst_proto_sigaction="unknown"
38184 tst_compi_sigaction="unknown"
38185 tst_allow_sigaction="unknown"
38186 #
38187 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sigaction can be linked" >&5
38188$as_echo_n "checking if sigaction can be linked... " >&6; }
38189 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38190/* end confdefs.h. */
38191
38192
38193#define sigaction innocuous_sigaction
38194#ifdef __STDC__
38195# include <limits.h>
38196#else
38197# include <assert.h>
38198#endif
38199#undef sigaction
38200#ifdef __cplusplus
38201extern "C"
38202#endif
38203char sigaction ();
38204#if defined __stub_sigaction || defined __stub___sigaction
38205choke me
38206#endif
38207
38208int main (void)
38209{
38210return sigaction ();
38211 ;
38212 return 0;
38213}
38214
38215_ACEOF
38216if ac_fn_c_try_link "$LINENO"; then :
38217
38218 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38219$as_echo "yes" >&6; }
38220 tst_links_sigaction="yes"
38221
38222else
38223
38224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38225$as_echo "no" >&6; }
38226 tst_links_sigaction="no"
38227
38228fi
38229rm -f core conftest.err conftest.$ac_objext \
38230 conftest$ac_exeext conftest.$ac_ext
38231 #
38232 if test "$tst_links_sigaction" = "yes"; then
38233 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sigaction is prototyped" >&5
38234$as_echo_n "checking if sigaction is prototyped... " >&6; }
38235 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38236/* end confdefs.h. */
38237
38238 $curl_includes_signal
38239
38240_ACEOF
38241if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
38242 $EGREP "sigaction" >/dev/null 2>&1; then :
38243
38244 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38245$as_echo "yes" >&6; }
38246 tst_proto_sigaction="yes"
38247
38248else
38249
38250 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38251$as_echo "no" >&6; }
38252 tst_proto_sigaction="no"
38253
38254fi
38255rm -f conftest*
38256
38257 fi
38258 #
38259 if test "$tst_proto_sigaction" = "yes"; then
38260 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sigaction is compilable" >&5
38261$as_echo_n "checking if sigaction is compilable... " >&6; }
38262 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38263/* end confdefs.h. */
38264
38265
38266 $curl_includes_signal
38267
38268int main (void)
38269{
38270
38271 if(0 != sigaction(0, 0, 0))
38272 return 1;
38273
38274 ;
38275 return 0;
38276}
38277
38278_ACEOF
38279if ac_fn_c_try_compile "$LINENO"; then :
38280
38281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38282$as_echo "yes" >&6; }
38283 tst_compi_sigaction="yes"
38284
38285else
38286
38287 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38288$as_echo "no" >&6; }
38289 tst_compi_sigaction="no"
38290
38291fi
38292rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
38293 fi
38294 #
38295 if test "$tst_compi_sigaction" = "yes"; then
38296 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sigaction usage allowed" >&5
38297$as_echo_n "checking if sigaction usage allowed... " >&6; }
38298 if test "x$curl_disallow_sigaction" != "xyes"; then
38299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38300$as_echo "yes" >&6; }
38301 tst_allow_sigaction="yes"
38302 else
38303 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38304$as_echo "no" >&6; }
38305 tst_allow_sigaction="no"
38306 fi
38307 fi
38308 #
38309 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sigaction might be used" >&5
38310$as_echo_n "checking if sigaction might be used... " >&6; }
38311 if test "$tst_links_sigaction" = "yes" &&
38312 test "$tst_proto_sigaction" = "yes" &&
38313 test "$tst_compi_sigaction" = "yes" &&
38314 test "$tst_allow_sigaction" = "yes"; then
38315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38316$as_echo "yes" >&6; }
38317
38318cat >>confdefs.h <<_ACEOF
38319#define HAVE_SIGACTION 1
38320_ACEOF
38321
38322 curl_cv_func_sigaction="yes"
38323 else
38324 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38325$as_echo "no" >&6; }
38326 curl_cv_func_sigaction="no"
38327 fi
38328
38329
38330 #
38331 tst_links_siginterrupt="unknown"
38332 tst_proto_siginterrupt="unknown"
38333 tst_compi_siginterrupt="unknown"
38334 tst_allow_siginterrupt="unknown"
38335 #
38336 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if siginterrupt can be linked" >&5
38337$as_echo_n "checking if siginterrupt can be linked... " >&6; }
38338 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38339/* end confdefs.h. */
38340
38341
38342#define siginterrupt innocuous_siginterrupt
38343#ifdef __STDC__
38344# include <limits.h>
38345#else
38346# include <assert.h>
38347#endif
38348#undef siginterrupt
38349#ifdef __cplusplus
38350extern "C"
38351#endif
38352char siginterrupt ();
38353#if defined __stub_siginterrupt || defined __stub___siginterrupt
38354choke me
38355#endif
38356
38357int main (void)
38358{
38359return siginterrupt ();
38360 ;
38361 return 0;
38362}
38363
38364_ACEOF
38365if ac_fn_c_try_link "$LINENO"; then :
38366
38367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38368$as_echo "yes" >&6; }
38369 tst_links_siginterrupt="yes"
38370
38371else
38372
38373 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38374$as_echo "no" >&6; }
38375 tst_links_siginterrupt="no"
38376
38377fi
38378rm -f core conftest.err conftest.$ac_objext \
38379 conftest$ac_exeext conftest.$ac_ext
38380 #
38381 if test "$tst_links_siginterrupt" = "yes"; then
38382 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if siginterrupt is prototyped" >&5
38383$as_echo_n "checking if siginterrupt is prototyped... " >&6; }
38384 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38385/* end confdefs.h. */
38386
38387 $curl_includes_signal
38388
38389_ACEOF
38390if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
38391 $EGREP "siginterrupt" >/dev/null 2>&1; then :
38392
38393 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38394$as_echo "yes" >&6; }
38395 tst_proto_siginterrupt="yes"
38396
38397else
38398
38399 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38400$as_echo "no" >&6; }
38401 tst_proto_siginterrupt="no"
38402
38403fi
38404rm -f conftest*
38405
38406 fi
38407 #
38408 if test "$tst_proto_siginterrupt" = "yes"; then
38409 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if siginterrupt is compilable" >&5
38410$as_echo_n "checking if siginterrupt is compilable... " >&6; }
38411 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38412/* end confdefs.h. */
38413
38414
38415 $curl_includes_signal
38416
38417int main (void)
38418{
38419
38420 if(0 != siginterrupt(0, 0))
38421 return 1;
38422
38423 ;
38424 return 0;
38425}
38426
38427_ACEOF
38428if ac_fn_c_try_compile "$LINENO"; then :
38429
38430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38431$as_echo "yes" >&6; }
38432 tst_compi_siginterrupt="yes"
38433
38434else
38435
38436 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38437$as_echo "no" >&6; }
38438 tst_compi_siginterrupt="no"
38439
38440fi
38441rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
38442 fi
38443 #
38444 if test "$tst_compi_siginterrupt" = "yes"; then
38445 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if siginterrupt usage allowed" >&5
38446$as_echo_n "checking if siginterrupt usage allowed... " >&6; }
38447 if test "x$curl_disallow_siginterrupt" != "xyes"; then
38448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38449$as_echo "yes" >&6; }
38450 tst_allow_siginterrupt="yes"
38451 else
38452 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38453$as_echo "no" >&6; }
38454 tst_allow_siginterrupt="no"
38455 fi
38456 fi
38457 #
38458 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if siginterrupt might be used" >&5
38459$as_echo_n "checking if siginterrupt might be used... " >&6; }
38460 if test "$tst_links_siginterrupt" = "yes" &&
38461 test "$tst_proto_siginterrupt" = "yes" &&
38462 test "$tst_compi_siginterrupt" = "yes" &&
38463 test "$tst_allow_siginterrupt" = "yes"; then
38464 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38465$as_echo "yes" >&6; }
38466
38467cat >>confdefs.h <<_ACEOF
38468#define HAVE_SIGINTERRUPT 1
38469_ACEOF
38470
38471 curl_cv_func_siginterrupt="yes"
38472 else
38473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38474$as_echo "no" >&6; }
38475 curl_cv_func_siginterrupt="no"
38476 fi
38477
38478
38479 #
38480 tst_links_signal="unknown"
38481 tst_proto_signal="unknown"
38482 tst_compi_signal="unknown"
38483 tst_allow_signal="unknown"
38484 #
38485 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if signal can be linked" >&5
38486$as_echo_n "checking if signal can be linked... " >&6; }
38487 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38488/* end confdefs.h. */
38489
38490
38491#define signal innocuous_signal
38492#ifdef __STDC__
38493# include <limits.h>
38494#else
38495# include <assert.h>
38496#endif
38497#undef signal
38498#ifdef __cplusplus
38499extern "C"
38500#endif
38501char signal ();
38502#if defined __stub_signal || defined __stub___signal
38503choke me
38504#endif
38505
38506int main (void)
38507{
38508return signal ();
38509 ;
38510 return 0;
38511}
38512
38513_ACEOF
38514if ac_fn_c_try_link "$LINENO"; then :
38515
38516 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38517$as_echo "yes" >&6; }
38518 tst_links_signal="yes"
38519
38520else
38521
38522 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38523$as_echo "no" >&6; }
38524 tst_links_signal="no"
38525
38526fi
38527rm -f core conftest.err conftest.$ac_objext \
38528 conftest$ac_exeext conftest.$ac_ext
38529 #
38530 if test "$tst_links_signal" = "yes"; then
38531 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if signal is prototyped" >&5
38532$as_echo_n "checking if signal is prototyped... " >&6; }
38533 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38534/* end confdefs.h. */
38535
38536 $curl_includes_signal
38537
38538_ACEOF
38539if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
38540 $EGREP "signal" >/dev/null 2>&1; then :
38541
38542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38543$as_echo "yes" >&6; }
38544 tst_proto_signal="yes"
38545
38546else
38547
38548 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38549$as_echo "no" >&6; }
38550 tst_proto_signal="no"
38551
38552fi
38553rm -f conftest*
38554
38555 fi
38556 #
38557 if test "$tst_proto_signal" = "yes"; then
38558 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if signal is compilable" >&5
38559$as_echo_n "checking if signal is compilable... " >&6; }
38560 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38561/* end confdefs.h. */
38562
38563
38564 $curl_includes_signal
38565
38566int main (void)
38567{
38568
38569 if(0 != signal(0, 0))
38570 return 1;
38571
38572 ;
38573 return 0;
38574}
38575
38576_ACEOF
38577if ac_fn_c_try_compile "$LINENO"; then :
38578
38579 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38580$as_echo "yes" >&6; }
38581 tst_compi_signal="yes"
38582
38583else
38584
38585 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38586$as_echo "no" >&6; }
38587 tst_compi_signal="no"
38588
38589fi
38590rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
38591 fi
38592 #
38593 if test "$tst_compi_signal" = "yes"; then
38594 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if signal usage allowed" >&5
38595$as_echo_n "checking if signal usage allowed... " >&6; }
38596 if test "x$curl_disallow_signal" != "xyes"; then
38597 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38598$as_echo "yes" >&6; }
38599 tst_allow_signal="yes"
38600 else
38601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38602$as_echo "no" >&6; }
38603 tst_allow_signal="no"
38604 fi
38605 fi
38606 #
38607 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if signal might be used" >&5
38608$as_echo_n "checking if signal might be used... " >&6; }
38609 if test "$tst_links_signal" = "yes" &&
38610 test "$tst_proto_signal" = "yes" &&
38611 test "$tst_compi_signal" = "yes" &&
38612 test "$tst_allow_signal" = "yes"; then
38613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38614$as_echo "yes" >&6; }
38615
38616cat >>confdefs.h <<_ACEOF
38617#define HAVE_SIGNAL 1
38618_ACEOF
38619
38620 curl_cv_func_signal="yes"
38621 else
38622 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38623$as_echo "no" >&6; }
38624 curl_cv_func_signal="no"
38625 fi
38626
38627
38628curl_includes_setjmp="\
38629/* includes start */
38630#ifdef HAVE_SYS_TYPES_H
38631# include <sys/types.h>
38632#endif
38633#ifdef HAVE_SETJMP_H
38634# include <setjmp.h>
38635#endif
38636/* includes end */"
38637 for ac_header in sys/types.h setjmp.h
38638do :
38639 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
38640ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_setjmp
38641"
38642if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
38643 cat >>confdefs.h <<_ACEOF
38644#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
38645_ACEOF
38646
38647fi
38648
38649done
38650
38651
38652
38653 #
38654 tst_links_sigsetjmp="unknown"
38655 tst_macro_sigsetjmp="unknown"
38656 tst_proto_sigsetjmp="unknown"
38657 tst_compi_sigsetjmp="unknown"
38658 tst_allow_sigsetjmp="unknown"
38659 #
38660 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sigsetjmp can be linked" >&5
38661$as_echo_n "checking if sigsetjmp can be linked... " >&6; }
38662 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38663/* end confdefs.h. */
38664
38665
38666#define sigsetjmp innocuous_sigsetjmp
38667#ifdef __STDC__
38668# include <limits.h>
38669#else
38670# include <assert.h>
38671#endif
38672#undef sigsetjmp
38673#ifdef __cplusplus
38674extern "C"
38675#endif
38676char sigsetjmp ();
38677#if defined __stub_sigsetjmp || defined __stub___sigsetjmp
38678choke me
38679#endif
38680
38681int main (void)
38682{
38683return sigsetjmp ();
38684 ;
38685 return 0;
38686}
38687
38688_ACEOF
38689if ac_fn_c_try_link "$LINENO"; then :
38690
38691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38692$as_echo "yes" >&6; }
38693 tst_links_sigsetjmp="yes"
38694
38695else
38696
38697 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38698$as_echo "no" >&6; }
38699 tst_links_sigsetjmp="no"
38700
38701fi
38702rm -f core conftest.err conftest.$ac_objext \
38703 conftest$ac_exeext conftest.$ac_ext
38704 #
38705 if test "$tst_links_sigsetjmp" = "no"; then
38706 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sigsetjmp seems a macro" >&5
38707$as_echo_n "checking if sigsetjmp seems a macro... " >&6; }
38708 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38709/* end confdefs.h. */
38710
38711
38712 $curl_includes_setjmp
38713
38714int main (void)
38715{
38716
38717 sigjmp_buf env;
38718 if(0 != sigsetjmp(env, 0))
38719 return 1;
38720
38721 ;
38722 return 0;
38723}
38724
38725_ACEOF
38726if ac_fn_c_try_link "$LINENO"; then :
38727
38728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38729$as_echo "yes" >&6; }
38730 tst_macro_sigsetjmp="yes"
38731
38732else
38733
38734 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38735$as_echo "no" >&6; }
38736 tst_macro_sigsetjmp="no"
38737
38738fi
38739rm -f core conftest.err conftest.$ac_objext \
38740 conftest$ac_exeext conftest.$ac_ext
38741 fi
38742 #
38743 if test "$tst_links_sigsetjmp" = "yes"; then
38744 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sigsetjmp is prototyped" >&5
38745$as_echo_n "checking if sigsetjmp is prototyped... " >&6; }
38746 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38747/* end confdefs.h. */
38748
38749 $curl_includes_setjmp
38750
38751_ACEOF
38752if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
38753 $EGREP "sigsetjmp" >/dev/null 2>&1; then :
38754
38755 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38756$as_echo "yes" >&6; }
38757 tst_proto_sigsetjmp="yes"
38758
38759else
38760
38761 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38762$as_echo "no" >&6; }
38763 tst_proto_sigsetjmp="no"
38764
38765fi
38766rm -f conftest*
38767
38768 fi
38769 #
38770 if test "$tst_proto_sigsetjmp" = "yes" ||
38771 test "$tst_macro_sigsetjmp" = "yes"; then
38772 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sigsetjmp is compilable" >&5
38773$as_echo_n "checking if sigsetjmp is compilable... " >&6; }
38774 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38775/* end confdefs.h. */
38776
38777
38778 $curl_includes_setjmp
38779
38780int main (void)
38781{
38782
38783 sigjmp_buf env;
38784 if(0 != sigsetjmp(env, 0))
38785 return 1;
38786
38787 ;
38788 return 0;
38789}
38790
38791_ACEOF
38792if ac_fn_c_try_compile "$LINENO"; then :
38793
38794 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38795$as_echo "yes" >&6; }
38796 tst_compi_sigsetjmp="yes"
38797
38798else
38799
38800 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38801$as_echo "no" >&6; }
38802 tst_compi_sigsetjmp="no"
38803
38804fi
38805rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
38806 fi
38807 #
38808 if test "$tst_compi_sigsetjmp" = "yes"; then
38809 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sigsetjmp usage allowed" >&5
38810$as_echo_n "checking if sigsetjmp usage allowed... " >&6; }
38811 if test "x$curl_disallow_sigsetjmp" != "xyes"; then
38812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38813$as_echo "yes" >&6; }
38814 tst_allow_sigsetjmp="yes"
38815 else
38816 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38817$as_echo "no" >&6; }
38818 tst_allow_sigsetjmp="no"
38819 fi
38820 fi
38821 #
38822 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sigsetjmp might be used" >&5
38823$as_echo_n "checking if sigsetjmp might be used... " >&6; }
38824 if (test "$tst_proto_sigsetjmp" = "yes" ||
38825 test "$tst_macro_sigsetjmp" = "yes") &&
38826 test "$tst_compi_sigsetjmp" = "yes" &&
38827 test "$tst_allow_sigsetjmp" = "yes"; then
38828 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38829$as_echo "yes" >&6; }
38830
38831cat >>confdefs.h <<_ACEOF
38832#define HAVE_SIGSETJMP 1
38833_ACEOF
38834
38835 curl_cv_func_sigsetjmp="yes"
38836 else
38837 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38838$as_echo "no" >&6; }
38839 curl_cv_func_sigsetjmp="no"
38840 fi
38841
38842
38843 #
38844 tst_links_socket="unknown"
38845 tst_proto_socket="unknown"
38846 tst_compi_socket="unknown"
38847 tst_allow_socket="unknown"
38848 #
38849 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if socket can be linked" >&5
38850$as_echo_n "checking if socket can be linked... " >&6; }
38851 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38852/* end confdefs.h. */
38853
38854
38855 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070038856 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070038857 $curl_includes_sys_socket
38858 $curl_includes_socket
38859
38860int main (void)
38861{
38862
38863 if(0 != socket(0, 0, 0))
38864 return 1;
38865
38866 ;
38867 return 0;
38868}
38869
38870_ACEOF
38871if ac_fn_c_try_link "$LINENO"; then :
38872
38873 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38874$as_echo "yes" >&6; }
38875 tst_links_socket="yes"
38876
38877else
38878
38879 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38880$as_echo "no" >&6; }
38881 tst_links_socket="no"
38882
38883fi
38884rm -f core conftest.err conftest.$ac_objext \
38885 conftest$ac_exeext conftest.$ac_ext
38886 #
38887 if test "$tst_links_socket" = "yes"; then
38888 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if socket is prototyped" >&5
38889$as_echo_n "checking if socket is prototyped... " >&6; }
38890 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38891/* end confdefs.h. */
38892
38893 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070038894 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070038895 $curl_includes_sys_socket
38896 $curl_includes_socket
38897
38898_ACEOF
38899if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
38900 $EGREP "socket" >/dev/null 2>&1; then :
38901
38902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38903$as_echo "yes" >&6; }
38904 tst_proto_socket="yes"
38905
38906else
38907
38908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38909$as_echo "no" >&6; }
38910 tst_proto_socket="no"
38911
38912fi
38913rm -f conftest*
38914
38915 fi
38916 #
38917 if test "$tst_proto_socket" = "yes"; then
38918 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if socket is compilable" >&5
38919$as_echo_n "checking if socket is compilable... " >&6; }
38920 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38921/* end confdefs.h. */
38922
38923
38924 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070038925 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070038926 $curl_includes_sys_socket
38927 $curl_includes_socket
38928
38929int main (void)
38930{
38931
38932 if(0 != socket(0, 0, 0))
38933 return 1;
38934
38935 ;
38936 return 0;
38937}
38938
38939_ACEOF
38940if ac_fn_c_try_compile "$LINENO"; then :
38941
38942 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38943$as_echo "yes" >&6; }
38944 tst_compi_socket="yes"
38945
38946else
38947
38948 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38949$as_echo "no" >&6; }
38950 tst_compi_socket="no"
38951
38952fi
38953rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
38954 fi
38955 #
38956 if test "$tst_compi_socket" = "yes"; then
38957 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if socket usage allowed" >&5
38958$as_echo_n "checking if socket usage allowed... " >&6; }
38959 if test "x$curl_disallow_socket" != "xyes"; then
38960 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38961$as_echo "yes" >&6; }
38962 tst_allow_socket="yes"
38963 else
38964 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38965$as_echo "no" >&6; }
38966 tst_allow_socket="no"
38967 fi
38968 fi
38969 #
38970 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if socket might be used" >&5
38971$as_echo_n "checking if socket might be used... " >&6; }
38972 if test "$tst_links_socket" = "yes" &&
38973 test "$tst_proto_socket" = "yes" &&
38974 test "$tst_compi_socket" = "yes" &&
38975 test "$tst_allow_socket" = "yes"; then
38976 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38977$as_echo "yes" >&6; }
38978
38979cat >>confdefs.h <<_ACEOF
38980#define HAVE_SOCKET 1
38981_ACEOF
38982
38983 curl_cv_func_socket="yes"
38984 else
38985 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38986$as_echo "no" >&6; }
38987 curl_cv_func_socket="no"
38988 fi
38989
38990
38991 #
38992 tst_links_socketpair="unknown"
38993 tst_proto_socketpair="unknown"
38994 tst_compi_socketpair="unknown"
38995 tst_allow_socketpair="unknown"
38996 #
38997 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if socketpair can be linked" >&5
38998$as_echo_n "checking if socketpair can be linked... " >&6; }
38999 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39000/* end confdefs.h. */
39001
39002
39003#define socketpair innocuous_socketpair
39004#ifdef __STDC__
39005# include <limits.h>
39006#else
39007# include <assert.h>
39008#endif
39009#undef socketpair
39010#ifdef __cplusplus
39011extern "C"
39012#endif
39013char socketpair ();
39014#if defined __stub_socketpair || defined __stub___socketpair
39015choke me
39016#endif
39017
39018int main (void)
39019{
39020return socketpair ();
39021 ;
39022 return 0;
39023}
39024
39025_ACEOF
39026if ac_fn_c_try_link "$LINENO"; then :
39027
39028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39029$as_echo "yes" >&6; }
39030 tst_links_socketpair="yes"
39031
39032else
39033
39034 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39035$as_echo "no" >&6; }
39036 tst_links_socketpair="no"
39037
39038fi
39039rm -f core conftest.err conftest.$ac_objext \
39040 conftest$ac_exeext conftest.$ac_ext
39041 #
39042 if test "$tst_links_socketpair" = "yes"; then
39043 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if socketpair is prototyped" >&5
39044$as_echo_n "checking if socketpair is prototyped... " >&6; }
39045 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39046/* end confdefs.h. */
39047
39048 $curl_includes_sys_socket
39049 $curl_includes_socket
39050
39051_ACEOF
39052if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
39053 $EGREP "socketpair" >/dev/null 2>&1; then :
39054
39055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39056$as_echo "yes" >&6; }
39057 tst_proto_socketpair="yes"
39058
39059else
39060
39061 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39062$as_echo "no" >&6; }
39063 tst_proto_socketpair="no"
39064
39065fi
39066rm -f conftest*
39067
39068 fi
39069 #
39070 if test "$tst_proto_socketpair" = "yes"; then
39071 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if socketpair is compilable" >&5
39072$as_echo_n "checking if socketpair is compilable... " >&6; }
39073 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39074/* end confdefs.h. */
39075
39076
39077 $curl_includes_sys_socket
39078 $curl_includes_socket
39079
39080int main (void)
39081{
39082
39083 int sv[2];
39084 if(0 != socketpair(0, 0, 0, sv))
39085 return 1;
39086
39087 ;
39088 return 0;
39089}
39090
39091_ACEOF
39092if ac_fn_c_try_compile "$LINENO"; then :
39093
39094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39095$as_echo "yes" >&6; }
39096 tst_compi_socketpair="yes"
39097
39098else
39099
39100 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39101$as_echo "no" >&6; }
39102 tst_compi_socketpair="no"
39103
39104fi
39105rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
39106 fi
39107 #
39108 if test "$tst_compi_socketpair" = "yes"; then
39109 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if socketpair usage allowed" >&5
39110$as_echo_n "checking if socketpair usage allowed... " >&6; }
39111 if test "x$curl_disallow_socketpair" != "xyes"; then
39112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39113$as_echo "yes" >&6; }
39114 tst_allow_socketpair="yes"
39115 else
39116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39117$as_echo "no" >&6; }
39118 tst_allow_socketpair="no"
39119 fi
39120 fi
39121 #
39122 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if socketpair might be used" >&5
39123$as_echo_n "checking if socketpair might be used... " >&6; }
39124 if test "$tst_links_socketpair" = "yes" &&
39125 test "$tst_proto_socketpair" = "yes" &&
39126 test "$tst_compi_socketpair" = "yes" &&
39127 test "$tst_allow_socketpair" = "yes"; then
39128 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39129$as_echo "yes" >&6; }
39130
39131cat >>confdefs.h <<_ACEOF
39132#define HAVE_SOCKETPAIR 1
39133_ACEOF
39134
39135 curl_cv_func_socketpair="yes"
39136 else
39137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39138$as_echo "no" >&6; }
39139 curl_cv_func_socketpair="no"
39140 fi
39141
39142
39143 #
39144 tst_links_strcasecmp="unknown"
39145 tst_proto_strcasecmp="unknown"
39146 tst_compi_strcasecmp="unknown"
39147 tst_allow_strcasecmp="unknown"
39148 #
39149 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strcasecmp can be linked" >&5
39150$as_echo_n "checking if strcasecmp can be linked... " >&6; }
39151 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39152/* end confdefs.h. */
39153
39154
39155#define strcasecmp innocuous_strcasecmp
39156#ifdef __STDC__
39157# include <limits.h>
39158#else
39159# include <assert.h>
39160#endif
39161#undef strcasecmp
39162#ifdef __cplusplus
39163extern "C"
39164#endif
39165char strcasecmp ();
39166#if defined __stub_strcasecmp || defined __stub___strcasecmp
39167choke me
39168#endif
39169
39170int main (void)
39171{
39172return strcasecmp ();
39173 ;
39174 return 0;
39175}
39176
39177_ACEOF
39178if ac_fn_c_try_link "$LINENO"; then :
39179
39180 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39181$as_echo "yes" >&6; }
39182 tst_links_strcasecmp="yes"
39183
39184else
39185
39186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39187$as_echo "no" >&6; }
39188 tst_links_strcasecmp="no"
39189
39190fi
39191rm -f core conftest.err conftest.$ac_objext \
39192 conftest$ac_exeext conftest.$ac_ext
39193 #
39194 if test "$tst_links_strcasecmp" = "yes"; then
39195 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strcasecmp is prototyped" >&5
39196$as_echo_n "checking if strcasecmp is prototyped... " >&6; }
39197 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39198/* end confdefs.h. */
39199
39200 $curl_includes_string
39201
39202_ACEOF
39203if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
39204 $EGREP "strcasecmp" >/dev/null 2>&1; then :
39205
39206 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39207$as_echo "yes" >&6; }
39208 tst_proto_strcasecmp="yes"
39209
39210else
39211
39212 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39213$as_echo "no" >&6; }
39214 tst_proto_strcasecmp="no"
39215
39216fi
39217rm -f conftest*
39218
39219 fi
39220 #
39221 if test "$tst_proto_strcasecmp" = "yes"; then
39222 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strcasecmp is compilable" >&5
39223$as_echo_n "checking if strcasecmp is compilable... " >&6; }
39224 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39225/* end confdefs.h. */
39226
39227
39228 $curl_includes_string
39229
39230int main (void)
39231{
39232
39233 if(0 != strcasecmp(0, 0))
39234 return 1;
39235
39236 ;
39237 return 0;
39238}
39239
39240_ACEOF
39241if ac_fn_c_try_compile "$LINENO"; then :
39242
39243 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39244$as_echo "yes" >&6; }
39245 tst_compi_strcasecmp="yes"
39246
39247else
39248
39249 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39250$as_echo "no" >&6; }
39251 tst_compi_strcasecmp="no"
39252
39253fi
39254rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
39255 fi
39256 #
39257 if test "$tst_compi_strcasecmp" = "yes"; then
39258 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strcasecmp usage allowed" >&5
39259$as_echo_n "checking if strcasecmp usage allowed... " >&6; }
39260 if test "x$curl_disallow_strcasecmp" != "xyes"; then
39261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39262$as_echo "yes" >&6; }
39263 tst_allow_strcasecmp="yes"
39264 else
39265 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39266$as_echo "no" >&6; }
39267 tst_allow_strcasecmp="no"
39268 fi
39269 fi
39270 #
39271 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strcasecmp might be used" >&5
39272$as_echo_n "checking if strcasecmp might be used... " >&6; }
39273 if test "$tst_links_strcasecmp" = "yes" &&
39274 test "$tst_proto_strcasecmp" = "yes" &&
39275 test "$tst_compi_strcasecmp" = "yes" &&
39276 test "$tst_allow_strcasecmp" = "yes"; then
39277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39278$as_echo "yes" >&6; }
39279
39280cat >>confdefs.h <<_ACEOF
39281#define HAVE_STRCASECMP 1
39282_ACEOF
39283
39284 curl_cv_func_strcasecmp="yes"
39285 else
39286 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39287$as_echo "no" >&6; }
39288 curl_cv_func_strcasecmp="no"
39289 fi
39290
39291
39292 #
39293 tst_links_strcmpi="unknown"
39294 tst_proto_strcmpi="unknown"
39295 tst_compi_strcmpi="unknown"
39296 tst_allow_strcmpi="unknown"
39297 #
39298 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strcmpi can be linked" >&5
39299$as_echo_n "checking if strcmpi can be linked... " >&6; }
39300 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39301/* end confdefs.h. */
39302
39303
39304#define strcmpi innocuous_strcmpi
39305#ifdef __STDC__
39306# include <limits.h>
39307#else
39308# include <assert.h>
39309#endif
39310#undef strcmpi
39311#ifdef __cplusplus
39312extern "C"
39313#endif
39314char strcmpi ();
39315#if defined __stub_strcmpi || defined __stub___strcmpi
39316choke me
39317#endif
39318
39319int main (void)
39320{
39321return strcmpi ();
39322 ;
39323 return 0;
39324}
39325
39326_ACEOF
39327if ac_fn_c_try_link "$LINENO"; then :
39328
39329 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39330$as_echo "yes" >&6; }
39331 tst_links_strcmpi="yes"
39332
39333else
39334
39335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39336$as_echo "no" >&6; }
39337 tst_links_strcmpi="no"
39338
39339fi
39340rm -f core conftest.err conftest.$ac_objext \
39341 conftest$ac_exeext conftest.$ac_ext
39342 #
39343 if test "$tst_links_strcmpi" = "yes"; then
39344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strcmpi is prototyped" >&5
39345$as_echo_n "checking if strcmpi is prototyped... " >&6; }
39346 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39347/* end confdefs.h. */
39348
39349 $curl_includes_string
39350
39351_ACEOF
39352if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
39353 $EGREP "strcmpi" >/dev/null 2>&1; then :
39354
39355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39356$as_echo "yes" >&6; }
39357 tst_proto_strcmpi="yes"
39358
39359else
39360
39361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39362$as_echo "no" >&6; }
39363 tst_proto_strcmpi="no"
39364
39365fi
39366rm -f conftest*
39367
39368 fi
39369 #
39370 if test "$tst_proto_strcmpi" = "yes"; then
39371 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strcmpi is compilable" >&5
39372$as_echo_n "checking if strcmpi is compilable... " >&6; }
39373 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39374/* end confdefs.h. */
39375
39376
39377 $curl_includes_string
39378
39379int main (void)
39380{
39381
39382 if(0 != strcmpi(0, 0))
39383 return 1;
39384
39385 ;
39386 return 0;
39387}
39388
39389_ACEOF
39390if ac_fn_c_try_compile "$LINENO"; then :
39391
39392 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39393$as_echo "yes" >&6; }
39394 tst_compi_strcmpi="yes"
39395
39396else
39397
39398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39399$as_echo "no" >&6; }
39400 tst_compi_strcmpi="no"
39401
39402fi
39403rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
39404 fi
39405 #
39406 if test "$tst_compi_strcmpi" = "yes"; then
39407 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strcmpi usage allowed" >&5
39408$as_echo_n "checking if strcmpi usage allowed... " >&6; }
39409 if test "x$curl_disallow_strcmpi" != "xyes"; then
39410 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39411$as_echo "yes" >&6; }
39412 tst_allow_strcmpi="yes"
39413 else
39414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39415$as_echo "no" >&6; }
39416 tst_allow_strcmpi="no"
39417 fi
39418 fi
39419 #
39420 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strcmpi might be used" >&5
39421$as_echo_n "checking if strcmpi might be used... " >&6; }
39422 if test "$tst_links_strcmpi" = "yes" &&
39423 test "$tst_proto_strcmpi" = "yes" &&
39424 test "$tst_compi_strcmpi" = "yes" &&
39425 test "$tst_allow_strcmpi" = "yes"; then
39426 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39427$as_echo "yes" >&6; }
39428
39429cat >>confdefs.h <<_ACEOF
39430#define HAVE_STRCMPI 1
39431_ACEOF
39432
39433 curl_cv_func_strcmpi="yes"
39434 else
39435 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39436$as_echo "no" >&6; }
39437 curl_cv_func_strcmpi="no"
39438 fi
39439
39440
39441 #
39442 tst_links_strdup="unknown"
39443 tst_proto_strdup="unknown"
39444 tst_compi_strdup="unknown"
39445 tst_allow_strdup="unknown"
39446 #
39447 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strdup can be linked" >&5
39448$as_echo_n "checking if strdup can be linked... " >&6; }
39449 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39450/* end confdefs.h. */
39451
39452
39453#define strdup innocuous_strdup
39454#ifdef __STDC__
39455# include <limits.h>
39456#else
39457# include <assert.h>
39458#endif
39459#undef strdup
39460#ifdef __cplusplus
39461extern "C"
39462#endif
39463char strdup ();
39464#if defined __stub_strdup || defined __stub___strdup
39465choke me
39466#endif
39467
39468int main (void)
39469{
39470return strdup ();
39471 ;
39472 return 0;
39473}
39474
39475_ACEOF
39476if ac_fn_c_try_link "$LINENO"; then :
39477
39478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39479$as_echo "yes" >&6; }
39480 tst_links_strdup="yes"
39481
39482else
39483
39484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39485$as_echo "no" >&6; }
39486 tst_links_strdup="no"
39487
39488fi
39489rm -f core conftest.err conftest.$ac_objext \
39490 conftest$ac_exeext conftest.$ac_ext
39491 #
39492 if test "$tst_links_strdup" = "yes"; then
39493 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strdup is prototyped" >&5
39494$as_echo_n "checking if strdup is prototyped... " >&6; }
39495 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39496/* end confdefs.h. */
39497
39498 $curl_includes_string
39499
39500_ACEOF
39501if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
39502 $EGREP "strdup" >/dev/null 2>&1; then :
39503
39504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39505$as_echo "yes" >&6; }
39506 tst_proto_strdup="yes"
39507
39508else
39509
39510 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39511$as_echo "no" >&6; }
39512 tst_proto_strdup="no"
39513
39514fi
39515rm -f conftest*
39516
39517 fi
39518 #
39519 if test "$tst_proto_strdup" = "yes"; then
39520 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strdup is compilable" >&5
39521$as_echo_n "checking if strdup is compilable... " >&6; }
39522 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39523/* end confdefs.h. */
39524
39525
39526 $curl_includes_string
39527
39528int main (void)
39529{
39530
39531 if(0 != strdup(0))
39532 return 1;
39533
39534 ;
39535 return 0;
39536}
39537
39538_ACEOF
39539if ac_fn_c_try_compile "$LINENO"; then :
39540
39541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39542$as_echo "yes" >&6; }
39543 tst_compi_strdup="yes"
39544
39545else
39546
39547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39548$as_echo "no" >&6; }
39549 tst_compi_strdup="no"
39550
39551fi
39552rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
39553 fi
39554 #
39555 if test "$tst_compi_strdup" = "yes"; then
39556 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strdup usage allowed" >&5
39557$as_echo_n "checking if strdup usage allowed... " >&6; }
39558 if test "x$curl_disallow_strdup" != "xyes"; then
39559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39560$as_echo "yes" >&6; }
39561 tst_allow_strdup="yes"
39562 else
39563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39564$as_echo "no" >&6; }
39565 tst_allow_strdup="no"
39566 fi
39567 fi
39568 #
39569 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strdup might be used" >&5
39570$as_echo_n "checking if strdup might be used... " >&6; }
39571 if test "$tst_links_strdup" = "yes" &&
39572 test "$tst_proto_strdup" = "yes" &&
39573 test "$tst_compi_strdup" = "yes" &&
39574 test "$tst_allow_strdup" = "yes"; then
39575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39576$as_echo "yes" >&6; }
39577
39578cat >>confdefs.h <<_ACEOF
39579#define HAVE_STRDUP 1
39580_ACEOF
39581
39582 curl_cv_func_strdup="yes"
39583 else
39584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39585$as_echo "no" >&6; }
39586 curl_cv_func_strdup="no"
39587 fi
39588
39589
39590 #
39591 tst_links_strerror_r="unknown"
39592 tst_proto_strerror_r="unknown"
39593 tst_compi_strerror_r="unknown"
39594 tst_glibc_strerror_r="unknown"
39595 tst_posix_strerror_r="unknown"
39596 tst_allow_strerror_r="unknown"
39597 tst_works_glibc_strerror_r="unknown"
39598 tst_works_posix_strerror_r="unknown"
39599 tst_glibc_strerror_r_type_arg3="unknown"
39600 tst_posix_strerror_r_type_arg3="unknown"
39601 #
39602 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strerror_r can be linked" >&5
39603$as_echo_n "checking if strerror_r can be linked... " >&6; }
39604 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39605/* end confdefs.h. */
39606
39607
39608#define strerror_r innocuous_strerror_r
39609#ifdef __STDC__
39610# include <limits.h>
39611#else
39612# include <assert.h>
39613#endif
39614#undef strerror_r
39615#ifdef __cplusplus
39616extern "C"
39617#endif
39618char strerror_r ();
39619#if defined __stub_strerror_r || defined __stub___strerror_r
39620choke me
39621#endif
39622
39623int main (void)
39624{
39625return strerror_r ();
39626 ;
39627 return 0;
39628}
39629
39630_ACEOF
39631if ac_fn_c_try_link "$LINENO"; then :
39632
39633 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39634$as_echo "yes" >&6; }
39635 tst_links_strerror_r="yes"
39636
39637else
39638
39639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39640$as_echo "no" >&6; }
39641 tst_links_strerror_r="no"
39642
39643fi
39644rm -f core conftest.err conftest.$ac_objext \
39645 conftest$ac_exeext conftest.$ac_ext
39646 #
39647 if test "$tst_links_strerror_r" = "yes"; then
39648 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strerror_r is prototyped" >&5
39649$as_echo_n "checking if strerror_r is prototyped... " >&6; }
39650 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39651/* end confdefs.h. */
39652
39653 $curl_includes_string
39654
39655_ACEOF
39656if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
39657 $EGREP "strerror_r" >/dev/null 2>&1; then :
39658
39659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39660$as_echo "yes" >&6; }
39661 tst_proto_strerror_r="yes"
39662
39663else
39664
39665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39666$as_echo "no" >&6; }
39667 tst_proto_strerror_r="no"
39668
39669fi
39670rm -f conftest*
39671
39672 fi
39673 #
39674 if test "$tst_proto_strerror_r" = "yes"; then
39675 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strerror_r is compilable" >&5
39676$as_echo_n "checking if strerror_r is compilable... " >&6; }
39677 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39678/* end confdefs.h. */
39679
39680
39681 $curl_includes_string
39682
39683int main (void)
39684{
39685
39686 if(0 != strerror_r(0, 0, 0))
39687 return 1;
39688
39689 ;
39690 return 0;
39691}
39692
39693_ACEOF
39694if ac_fn_c_try_compile "$LINENO"; then :
39695
39696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39697$as_echo "yes" >&6; }
39698 tst_compi_strerror_r="yes"
39699
39700else
39701
39702 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39703$as_echo "no" >&6; }
39704 tst_compi_strerror_r="no"
39705
39706fi
39707rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
39708 fi
39709 #
39710 if test "$tst_compi_strerror_r" = "yes"; then
39711 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strerror_r is glibc like" >&5
39712$as_echo_n "checking if strerror_r is glibc like... " >&6; }
39713 tst_glibc_strerror_r_type_arg3="unknown"
39714 for arg3 in 'size_t' 'int' 'unsigned int'; do
39715 if test "$tst_glibc_strerror_r_type_arg3" = "unknown"; then
39716 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39717/* end confdefs.h. */
39718
39719
39720 $curl_includes_string
39721 char *strerror_r(int errnum, char *workbuf, $arg3 bufsize);
39722
39723int main (void)
39724{
39725
39726 if(0 != strerror_r(0, 0, 0))
39727 return 1;
39728
39729 ;
39730 return 0;
39731}
39732
39733_ACEOF
39734if ac_fn_c_try_compile "$LINENO"; then :
39735
39736 tst_glibc_strerror_r_type_arg3="$arg3"
39737
39738fi
39739rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
39740 fi
39741 done
39742 case "$tst_glibc_strerror_r_type_arg3" in
39743 unknown)
39744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39745$as_echo "no" >&6; }
39746 tst_glibc_strerror_r="no"
39747 ;;
39748 *)
39749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39750$as_echo "yes" >&6; }
39751 tst_glibc_strerror_r="yes"
39752 ;;
39753 esac
39754 fi
39755 #
39756 if test "x$cross_compiling" != "xyes" &&
39757 test "$tst_glibc_strerror_r" = "yes"; then
39758 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strerror_r seems to work" >&5
39759$as_echo_n "checking if strerror_r seems to work... " >&6; }
Elliott Hughesa93fb052018-12-12 14:22:48 -080039760
39761
39762 old=$LD_LIBRARY_PATH
39763 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
39764 export LD_LIBRARY_PATH
39765 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070039766 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
39767$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
39768as_fn_error $? "cannot run test program while cross compiling
39769See \`config.log' for more details" "$LINENO" 5; }
39770else
39771 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39772/* end confdefs.h. */
39773
39774
39775 $curl_includes_stdlib
39776 $curl_includes_string
39777# include <errno.h>
39778
39779int main (void)
39780{
39781
39782 char buffer[1024];
39783 char *string = 0;
39784 buffer[0] = '\0';
39785 string = strerror_r(EACCES, buffer, sizeof(buffer));
39786 if(!string)
39787 exit(1); /* fail */
39788 if(!string[0])
39789 exit(1); /* fail */
39790 else
39791 exit(0);
39792
39793 ;
39794 return 0;
39795}
39796
39797_ACEOF
39798if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughesa93fb052018-12-12 14:22:48 -080039799 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070039800$as_echo "yes" >&6; }
39801 tst_works_glibc_strerror_r="yes"
39802
39803else
Elliott Hughesa93fb052018-12-12 14:22:48 -080039804 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070039805$as_echo "no" >&6; }
39806 tst_works_glibc_strerror_r="no"
39807
39808fi
39809rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
39810 conftest.$ac_objext conftest.beam conftest.$ac_ext
39811fi
39812
Elliott Hughesa93fb052018-12-12 14:22:48 -080039813 LD_LIBRARY_PATH=$old # restore
39814
Elliott Hughes82be86d2017-09-20 17:00:17 -070039815 fi
39816 #
39817 if test "$tst_compi_strerror_r" = "yes" &&
39818 test "$tst_works_glibc_strerror_r" != "yes"; then
39819 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strerror_r is POSIX like" >&5
39820$as_echo_n "checking if strerror_r is POSIX like... " >&6; }
39821 tst_posix_strerror_r_type_arg3="unknown"
39822 for arg3 in 'size_t' 'int' 'unsigned int'; do
39823 if test "$tst_posix_strerror_r_type_arg3" = "unknown"; then
39824 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39825/* end confdefs.h. */
39826
39827
39828 $curl_includes_string
39829 int strerror_r(int errnum, char *resultbuf, $arg3 bufsize);
39830
39831int main (void)
39832{
39833
39834 if(0 != strerror_r(0, 0, 0))
39835 return 1;
39836
39837 ;
39838 return 0;
39839}
39840
39841_ACEOF
39842if ac_fn_c_try_compile "$LINENO"; then :
39843
39844 tst_posix_strerror_r_type_arg3="$arg3"
39845
39846fi
39847rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
39848 fi
39849 done
39850 case "$tst_posix_strerror_r_type_arg3" in
39851 unknown)
39852 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39853$as_echo "no" >&6; }
39854 tst_posix_strerror_r="no"
39855 ;;
39856 *)
39857 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39858$as_echo "yes" >&6; }
39859 tst_posix_strerror_r="yes"
39860 ;;
39861 esac
39862 fi
39863 #
39864 if test "x$cross_compiling" != "xyes" &&
39865 test "$tst_posix_strerror_r" = "yes"; then
39866 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strerror_r seems to work" >&5
39867$as_echo_n "checking if strerror_r seems to work... " >&6; }
Elliott Hughesa93fb052018-12-12 14:22:48 -080039868
39869
39870 old=$LD_LIBRARY_PATH
39871 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
39872 export LD_LIBRARY_PATH
39873 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070039874 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
39875$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
39876as_fn_error $? "cannot run test program while cross compiling
39877See \`config.log' for more details" "$LINENO" 5; }
39878else
39879 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39880/* end confdefs.h. */
39881
39882
39883 $curl_includes_stdlib
39884 $curl_includes_string
39885# include <errno.h>
39886
39887int main (void)
39888{
39889
39890 char buffer[1024];
39891 int error = 1;
39892 buffer[0] = '\0';
39893 error = strerror_r(EACCES, buffer, sizeof(buffer));
39894 if(error)
39895 exit(1); /* fail */
39896 if(buffer[0] == '\0')
39897 exit(1); /* fail */
39898 else
39899 exit(0);
39900
39901 ;
39902 return 0;
39903}
39904
39905_ACEOF
39906if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughesa93fb052018-12-12 14:22:48 -080039907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070039908$as_echo "yes" >&6; }
39909 tst_works_posix_strerror_r="yes"
39910
39911else
Elliott Hughesa93fb052018-12-12 14:22:48 -080039912 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070039913$as_echo "no" >&6; }
39914 tst_works_posix_strerror_r="no"
39915
39916fi
39917rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
39918 conftest.$ac_objext conftest.beam conftest.$ac_ext
39919fi
39920
Elliott Hughesa93fb052018-12-12 14:22:48 -080039921 LD_LIBRARY_PATH=$old # restore
39922
Elliott Hughes82be86d2017-09-20 17:00:17 -070039923 fi
39924 #
39925 if test "$tst_works_glibc_strerror_r" = "yes"; then
39926 tst_posix_strerror_r="no"
39927 fi
39928 if test "$tst_works_posix_strerror_r" = "yes"; then
39929 tst_glibc_strerror_r="no"
39930 fi
39931 if test "$tst_glibc_strerror_r" = "yes" &&
39932 test "$tst_works_glibc_strerror_r" != "no" &&
39933 test "$tst_posix_strerror_r" != "yes"; then
39934 tst_allow_strerror_r="check"
39935 fi
39936 if test "$tst_posix_strerror_r" = "yes" &&
39937 test "$tst_works_posix_strerror_r" != "no" &&
39938 test "$tst_glibc_strerror_r" != "yes"; then
39939 tst_allow_strerror_r="check"
39940 fi
39941 if test "$tst_allow_strerror_r" = "check"; then
39942 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strerror_r usage allowed" >&5
39943$as_echo_n "checking if strerror_r usage allowed... " >&6; }
39944 if test "x$curl_disallow_strerror_r" != "xyes"; then
39945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39946$as_echo "yes" >&6; }
39947 tst_allow_strerror_r="yes"
39948 else
39949 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39950$as_echo "no" >&6; }
39951 tst_allow_strerror_r="no"
39952 fi
39953 fi
39954 #
39955 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strerror_r might be used" >&5
39956$as_echo_n "checking if strerror_r might be used... " >&6; }
39957 if test "$tst_links_strerror_r" = "yes" &&
39958 test "$tst_proto_strerror_r" = "yes" &&
39959 test "$tst_compi_strerror_r" = "yes" &&
39960 test "$tst_allow_strerror_r" = "yes"; then
39961 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39962$as_echo "yes" >&6; }
39963 if test "$tst_glibc_strerror_r" = "yes"; then
39964
39965cat >>confdefs.h <<_ACEOF
39966#define HAVE_STRERROR_R 1
39967_ACEOF
39968
39969
39970cat >>confdefs.h <<_ACEOF
39971#define HAVE_GLIBC_STRERROR_R 1
39972_ACEOF
39973
39974
39975cat >>confdefs.h <<_ACEOF
39976#define STRERROR_R_TYPE_ARG3 $tst_glibc_strerror_r_type_arg3
39977_ACEOF
39978
39979 fi
39980 if test "$tst_posix_strerror_r" = "yes"; then
39981
39982cat >>confdefs.h <<_ACEOF
39983#define HAVE_STRERROR_R 1
39984_ACEOF
39985
39986
39987cat >>confdefs.h <<_ACEOF
39988#define HAVE_POSIX_STRERROR_R 1
39989_ACEOF
39990
39991
39992cat >>confdefs.h <<_ACEOF
39993#define STRERROR_R_TYPE_ARG3 $tst_posix_strerror_r_type_arg3
39994_ACEOF
39995
39996 fi
39997 curl_cv_func_strerror_r="yes"
39998 else
39999 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40000$as_echo "no" >&6; }
40001 curl_cv_func_strerror_r="no"
40002 fi
40003 #
40004 if test "$tst_compi_strerror_r" = "yes" &&
40005 test "$tst_allow_strerror_r" = "unknown"; then
40006 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot determine strerror_r() style: edit lib/curl_config.h manually." >&5
40007$as_echo "$as_me: WARNING: cannot determine strerror_r() style: edit lib/curl_config.h manually." >&2;}
40008 fi
40009 #
40010
40011
40012 #
40013 tst_links_stricmp="unknown"
40014 tst_proto_stricmp="unknown"
40015 tst_compi_stricmp="unknown"
40016 tst_allow_stricmp="unknown"
40017 #
40018 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if stricmp can be linked" >&5
40019$as_echo_n "checking if stricmp can be linked... " >&6; }
40020 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40021/* end confdefs.h. */
40022
40023
40024#define stricmp innocuous_stricmp
40025#ifdef __STDC__
40026# include <limits.h>
40027#else
40028# include <assert.h>
40029#endif
40030#undef stricmp
40031#ifdef __cplusplus
40032extern "C"
40033#endif
40034char stricmp ();
40035#if defined __stub_stricmp || defined __stub___stricmp
40036choke me
40037#endif
40038
40039int main (void)
40040{
40041return stricmp ();
40042 ;
40043 return 0;
40044}
40045
40046_ACEOF
40047if ac_fn_c_try_link "$LINENO"; then :
40048
40049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40050$as_echo "yes" >&6; }
40051 tst_links_stricmp="yes"
40052
40053else
40054
40055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40056$as_echo "no" >&6; }
40057 tst_links_stricmp="no"
40058
40059fi
40060rm -f core conftest.err conftest.$ac_objext \
40061 conftest$ac_exeext conftest.$ac_ext
40062 #
40063 if test "$tst_links_stricmp" = "yes"; then
40064 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if stricmp is prototyped" >&5
40065$as_echo_n "checking if stricmp is prototyped... " >&6; }
40066 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40067/* end confdefs.h. */
40068
40069 $curl_includes_string
40070
40071_ACEOF
40072if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
40073 $EGREP "stricmp" >/dev/null 2>&1; then :
40074
40075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40076$as_echo "yes" >&6; }
40077 tst_proto_stricmp="yes"
40078
40079else
40080
40081 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40082$as_echo "no" >&6; }
40083 tst_proto_stricmp="no"
40084
40085fi
40086rm -f conftest*
40087
40088 fi
40089 #
40090 if test "$tst_proto_stricmp" = "yes"; then
40091 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if stricmp is compilable" >&5
40092$as_echo_n "checking if stricmp is compilable... " >&6; }
40093 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40094/* end confdefs.h. */
40095
40096
40097 $curl_includes_string
40098
40099int main (void)
40100{
40101
40102 if(0 != stricmp(0, 0))
40103 return 1;
40104
40105 ;
40106 return 0;
40107}
40108
40109_ACEOF
40110if ac_fn_c_try_compile "$LINENO"; then :
40111
40112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40113$as_echo "yes" >&6; }
40114 tst_compi_stricmp="yes"
40115
40116else
40117
40118 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40119$as_echo "no" >&6; }
40120 tst_compi_stricmp="no"
40121
40122fi
40123rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
40124 fi
40125 #
40126 if test "$tst_compi_stricmp" = "yes"; then
40127 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if stricmp usage allowed" >&5
40128$as_echo_n "checking if stricmp usage allowed... " >&6; }
40129 if test "x$curl_disallow_stricmp" != "xyes"; then
40130 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40131$as_echo "yes" >&6; }
40132 tst_allow_stricmp="yes"
40133 else
40134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40135$as_echo "no" >&6; }
40136 tst_allow_stricmp="no"
40137 fi
40138 fi
40139 #
40140 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if stricmp might be used" >&5
40141$as_echo_n "checking if stricmp might be used... " >&6; }
40142 if test "$tst_links_stricmp" = "yes" &&
40143 test "$tst_proto_stricmp" = "yes" &&
40144 test "$tst_compi_stricmp" = "yes" &&
40145 test "$tst_allow_stricmp" = "yes"; then
40146 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40147$as_echo "yes" >&6; }
40148
40149cat >>confdefs.h <<_ACEOF
40150#define HAVE_STRICMP 1
40151_ACEOF
40152
40153 curl_cv_func_stricmp="yes"
40154 else
40155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40156$as_echo "no" >&6; }
40157 curl_cv_func_stricmp="no"
40158 fi
40159
40160
40161 #
40162 tst_links_strncasecmp="unknown"
40163 tst_proto_strncasecmp="unknown"
40164 tst_compi_strncasecmp="unknown"
40165 tst_allow_strncasecmp="unknown"
40166 #
40167 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strncasecmp can be linked" >&5
40168$as_echo_n "checking if strncasecmp can be linked... " >&6; }
40169 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40170/* end confdefs.h. */
40171
40172
40173#define strncasecmp innocuous_strncasecmp
40174#ifdef __STDC__
40175# include <limits.h>
40176#else
40177# include <assert.h>
40178#endif
40179#undef strncasecmp
40180#ifdef __cplusplus
40181extern "C"
40182#endif
40183char strncasecmp ();
40184#if defined __stub_strncasecmp || defined __stub___strncasecmp
40185choke me
40186#endif
40187
40188int main (void)
40189{
40190return strncasecmp ();
40191 ;
40192 return 0;
40193}
40194
40195_ACEOF
40196if ac_fn_c_try_link "$LINENO"; then :
40197
40198 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40199$as_echo "yes" >&6; }
40200 tst_links_strncasecmp="yes"
40201
40202else
40203
40204 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40205$as_echo "no" >&6; }
40206 tst_links_strncasecmp="no"
40207
40208fi
40209rm -f core conftest.err conftest.$ac_objext \
40210 conftest$ac_exeext conftest.$ac_ext
40211 #
40212 if test "$tst_links_strncasecmp" = "yes"; then
40213 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strncasecmp is prototyped" >&5
40214$as_echo_n "checking if strncasecmp is prototyped... " >&6; }
40215 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40216/* end confdefs.h. */
40217
40218 $curl_includes_string
40219
40220_ACEOF
40221if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
40222 $EGREP "strncasecmp" >/dev/null 2>&1; then :
40223
40224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40225$as_echo "yes" >&6; }
40226 tst_proto_strncasecmp="yes"
40227
40228else
40229
40230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40231$as_echo "no" >&6; }
40232 tst_proto_strncasecmp="no"
40233
40234fi
40235rm -f conftest*
40236
40237 fi
40238 #
40239 if test "$tst_proto_strncasecmp" = "yes"; then
40240 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strncasecmp is compilable" >&5
40241$as_echo_n "checking if strncasecmp is compilable... " >&6; }
40242 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40243/* end confdefs.h. */
40244
40245
40246 $curl_includes_string
40247
40248int main (void)
40249{
40250
40251 if(0 != strncasecmp(0, 0, 0))
40252 return 1;
40253
40254 ;
40255 return 0;
40256}
40257
40258_ACEOF
40259if ac_fn_c_try_compile "$LINENO"; then :
40260
40261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40262$as_echo "yes" >&6; }
40263 tst_compi_strncasecmp="yes"
40264
40265else
40266
40267 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40268$as_echo "no" >&6; }
40269 tst_compi_strncasecmp="no"
40270
40271fi
40272rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
40273 fi
40274 #
40275 if test "$tst_compi_strncasecmp" = "yes"; then
40276 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strncasecmp usage allowed" >&5
40277$as_echo_n "checking if strncasecmp usage allowed... " >&6; }
40278 if test "x$curl_disallow_strncasecmp" != "xyes"; then
40279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40280$as_echo "yes" >&6; }
40281 tst_allow_strncasecmp="yes"
40282 else
40283 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40284$as_echo "no" >&6; }
40285 tst_allow_strncasecmp="no"
40286 fi
40287 fi
40288 #
40289 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strncasecmp might be used" >&5
40290$as_echo_n "checking if strncasecmp might be used... " >&6; }
40291 if test "$tst_links_strncasecmp" = "yes" &&
40292 test "$tst_proto_strncasecmp" = "yes" &&
40293 test "$tst_compi_strncasecmp" = "yes" &&
40294 test "$tst_allow_strncasecmp" = "yes"; then
40295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40296$as_echo "yes" >&6; }
40297
40298cat >>confdefs.h <<_ACEOF
40299#define HAVE_STRNCASECMP 1
40300_ACEOF
40301
40302 curl_cv_func_strncasecmp="yes"
40303 else
40304 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40305$as_echo "no" >&6; }
40306 curl_cv_func_strncasecmp="no"
40307 fi
40308
40309
40310 #
40311 tst_links_strncmpi="unknown"
40312 tst_proto_strncmpi="unknown"
40313 tst_compi_strncmpi="unknown"
40314 tst_allow_strncmpi="unknown"
40315 #
40316 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strncmpi can be linked" >&5
40317$as_echo_n "checking if strncmpi can be linked... " >&6; }
40318 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40319/* end confdefs.h. */
40320
40321
40322#define strncmpi innocuous_strncmpi
40323#ifdef __STDC__
40324# include <limits.h>
40325#else
40326# include <assert.h>
40327#endif
40328#undef strncmpi
40329#ifdef __cplusplus
40330extern "C"
40331#endif
40332char strncmpi ();
40333#if defined __stub_strncmpi || defined __stub___strncmpi
40334choke me
40335#endif
40336
40337int main (void)
40338{
40339return strncmpi ();
40340 ;
40341 return 0;
40342}
40343
40344_ACEOF
40345if ac_fn_c_try_link "$LINENO"; then :
40346
40347 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40348$as_echo "yes" >&6; }
40349 tst_links_strncmpi="yes"
40350
40351else
40352
40353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40354$as_echo "no" >&6; }
40355 tst_links_strncmpi="no"
40356
40357fi
40358rm -f core conftest.err conftest.$ac_objext \
40359 conftest$ac_exeext conftest.$ac_ext
40360 #
40361 if test "$tst_links_strncmpi" = "yes"; then
40362 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strncmpi is prototyped" >&5
40363$as_echo_n "checking if strncmpi is prototyped... " >&6; }
40364 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40365/* end confdefs.h. */
40366
40367 $curl_includes_string
40368
40369_ACEOF
40370if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
40371 $EGREP "strncmpi" >/dev/null 2>&1; then :
40372
40373 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40374$as_echo "yes" >&6; }
40375 tst_proto_strncmpi="yes"
40376
40377else
40378
40379 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40380$as_echo "no" >&6; }
40381 tst_proto_strncmpi="no"
40382
40383fi
40384rm -f conftest*
40385
40386 fi
40387 #
40388 if test "$tst_proto_strncmpi" = "yes"; then
40389 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strncmpi is compilable" >&5
40390$as_echo_n "checking if strncmpi is compilable... " >&6; }
40391 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40392/* end confdefs.h. */
40393
40394
40395 $curl_includes_string
40396
40397int main (void)
40398{
40399
40400 if(0 != strncmpi(0, 0))
40401 return 1;
40402
40403 ;
40404 return 0;
40405}
40406
40407_ACEOF
40408if ac_fn_c_try_compile "$LINENO"; then :
40409
40410 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40411$as_echo "yes" >&6; }
40412 tst_compi_strncmpi="yes"
40413
40414else
40415
40416 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40417$as_echo "no" >&6; }
40418 tst_compi_strncmpi="no"
40419
40420fi
40421rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
40422 fi
40423 #
40424 if test "$tst_compi_strncmpi" = "yes"; then
40425 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strncmpi usage allowed" >&5
40426$as_echo_n "checking if strncmpi usage allowed... " >&6; }
40427 if test "x$curl_disallow_strncmpi" != "xyes"; then
40428 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40429$as_echo "yes" >&6; }
40430 tst_allow_strncmpi="yes"
40431 else
40432 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40433$as_echo "no" >&6; }
40434 tst_allow_strncmpi="no"
40435 fi
40436 fi
40437 #
40438 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strncmpi might be used" >&5
40439$as_echo_n "checking if strncmpi might be used... " >&6; }
40440 if test "$tst_links_strncmpi" = "yes" &&
40441 test "$tst_proto_strncmpi" = "yes" &&
40442 test "$tst_compi_strncmpi" = "yes" &&
40443 test "$tst_allow_strncmpi" = "yes"; then
40444 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40445$as_echo "yes" >&6; }
40446
40447cat >>confdefs.h <<_ACEOF
40448#define HAVE_STRNCMPI 1
40449_ACEOF
40450
40451 curl_cv_func_strncmpi="yes"
40452 else
40453 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40454$as_echo "no" >&6; }
40455 curl_cv_func_strncmpi="no"
40456 fi
40457
40458
40459 #
40460 tst_links_strnicmp="unknown"
40461 tst_proto_strnicmp="unknown"
40462 tst_compi_strnicmp="unknown"
40463 tst_allow_strnicmp="unknown"
40464 #
40465 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strnicmp can be linked" >&5
40466$as_echo_n "checking if strnicmp can be linked... " >&6; }
40467 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40468/* end confdefs.h. */
40469
40470
40471#define strnicmp innocuous_strnicmp
40472#ifdef __STDC__
40473# include <limits.h>
40474#else
40475# include <assert.h>
40476#endif
40477#undef strnicmp
40478#ifdef __cplusplus
40479extern "C"
40480#endif
40481char strnicmp ();
40482#if defined __stub_strnicmp || defined __stub___strnicmp
40483choke me
40484#endif
40485
40486int main (void)
40487{
40488return strnicmp ();
40489 ;
40490 return 0;
40491}
40492
40493_ACEOF
40494if ac_fn_c_try_link "$LINENO"; then :
40495
40496 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40497$as_echo "yes" >&6; }
40498 tst_links_strnicmp="yes"
40499
40500else
40501
40502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40503$as_echo "no" >&6; }
40504 tst_links_strnicmp="no"
40505
40506fi
40507rm -f core conftest.err conftest.$ac_objext \
40508 conftest$ac_exeext conftest.$ac_ext
40509 #
40510 if test "$tst_links_strnicmp" = "yes"; then
40511 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strnicmp is prototyped" >&5
40512$as_echo_n "checking if strnicmp is prototyped... " >&6; }
40513 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40514/* end confdefs.h. */
40515
40516 $curl_includes_string
40517
40518_ACEOF
40519if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
40520 $EGREP "strnicmp" >/dev/null 2>&1; then :
40521
40522 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40523$as_echo "yes" >&6; }
40524 tst_proto_strnicmp="yes"
40525
40526else
40527
40528 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40529$as_echo "no" >&6; }
40530 tst_proto_strnicmp="no"
40531
40532fi
40533rm -f conftest*
40534
40535 fi
40536 #
40537 if test "$tst_proto_strnicmp" = "yes"; then
40538 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strnicmp is compilable" >&5
40539$as_echo_n "checking if strnicmp is compilable... " >&6; }
40540 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40541/* end confdefs.h. */
40542
40543
40544 $curl_includes_string
40545
40546int main (void)
40547{
40548
40549 if(0 != strnicmp(0, 0))
40550 return 1;
40551
40552 ;
40553 return 0;
40554}
40555
40556_ACEOF
40557if ac_fn_c_try_compile "$LINENO"; then :
40558
40559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40560$as_echo "yes" >&6; }
40561 tst_compi_strnicmp="yes"
40562
40563else
40564
40565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40566$as_echo "no" >&6; }
40567 tst_compi_strnicmp="no"
40568
40569fi
40570rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
40571 fi
40572 #
40573 if test "$tst_compi_strnicmp" = "yes"; then
40574 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strnicmp usage allowed" >&5
40575$as_echo_n "checking if strnicmp usage allowed... " >&6; }
40576 if test "x$curl_disallow_strnicmp" != "xyes"; then
40577 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40578$as_echo "yes" >&6; }
40579 tst_allow_strnicmp="yes"
40580 else
40581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40582$as_echo "no" >&6; }
40583 tst_allow_strnicmp="no"
40584 fi
40585 fi
40586 #
40587 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strnicmp might be used" >&5
40588$as_echo_n "checking if strnicmp might be used... " >&6; }
40589 if test "$tst_links_strnicmp" = "yes" &&
40590 test "$tst_proto_strnicmp" = "yes" &&
40591 test "$tst_compi_strnicmp" = "yes" &&
40592 test "$tst_allow_strnicmp" = "yes"; then
40593 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40594$as_echo "yes" >&6; }
40595
40596cat >>confdefs.h <<_ACEOF
40597#define HAVE_STRNICMP 1
40598_ACEOF
40599
40600 curl_cv_func_strnicmp="yes"
40601 else
40602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40603$as_echo "no" >&6; }
40604 curl_cv_func_strnicmp="no"
40605 fi
40606
40607
40608 #
40609 tst_links_strstr="unknown"
40610 tst_proto_strstr="unknown"
40611 tst_compi_strstr="unknown"
40612 tst_allow_strstr="unknown"
40613 #
40614 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strstr can be linked" >&5
40615$as_echo_n "checking if strstr can be linked... " >&6; }
40616 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40617/* end confdefs.h. */
40618
40619
40620#define strstr innocuous_strstr
40621#ifdef __STDC__
40622# include <limits.h>
40623#else
40624# include <assert.h>
40625#endif
40626#undef strstr
40627#ifdef __cplusplus
40628extern "C"
40629#endif
40630char strstr ();
40631#if defined __stub_strstr || defined __stub___strstr
40632choke me
40633#endif
40634
40635int main (void)
40636{
40637return strstr ();
40638 ;
40639 return 0;
40640}
40641
40642_ACEOF
40643if ac_fn_c_try_link "$LINENO"; then :
40644
40645 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40646$as_echo "yes" >&6; }
40647 tst_links_strstr="yes"
40648
40649else
40650
40651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40652$as_echo "no" >&6; }
40653 tst_links_strstr="no"
40654
40655fi
40656rm -f core conftest.err conftest.$ac_objext \
40657 conftest$ac_exeext conftest.$ac_ext
40658 #
40659 if test "$tst_links_strstr" = "yes"; then
40660 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strstr is prototyped" >&5
40661$as_echo_n "checking if strstr is prototyped... " >&6; }
40662 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40663/* end confdefs.h. */
40664
40665 $curl_includes_string
40666
40667_ACEOF
40668if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
40669 $EGREP "strstr" >/dev/null 2>&1; then :
40670
40671 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40672$as_echo "yes" >&6; }
40673 tst_proto_strstr="yes"
40674
40675else
40676
40677 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40678$as_echo "no" >&6; }
40679 tst_proto_strstr="no"
40680
40681fi
40682rm -f conftest*
40683
40684 fi
40685 #
40686 if test "$tst_proto_strstr" = "yes"; then
40687 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strstr is compilable" >&5
40688$as_echo_n "checking if strstr is compilable... " >&6; }
40689 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40690/* end confdefs.h. */
40691
40692
40693 $curl_includes_string
40694
40695int main (void)
40696{
40697
40698 if(0 != strstr(0, 0))
40699 return 1;
40700
40701 ;
40702 return 0;
40703}
40704
40705_ACEOF
40706if ac_fn_c_try_compile "$LINENO"; then :
40707
40708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40709$as_echo "yes" >&6; }
40710 tst_compi_strstr="yes"
40711
40712else
40713
40714 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40715$as_echo "no" >&6; }
40716 tst_compi_strstr="no"
40717
40718fi
40719rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
40720 fi
40721 #
40722 if test "$tst_compi_strstr" = "yes"; then
40723 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strstr usage allowed" >&5
40724$as_echo_n "checking if strstr usage allowed... " >&6; }
40725 if test "x$curl_disallow_strstr" != "xyes"; then
40726 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40727$as_echo "yes" >&6; }
40728 tst_allow_strstr="yes"
40729 else
40730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40731$as_echo "no" >&6; }
40732 tst_allow_strstr="no"
40733 fi
40734 fi
40735 #
40736 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strstr might be used" >&5
40737$as_echo_n "checking if strstr might be used... " >&6; }
40738 if test "$tst_links_strstr" = "yes" &&
40739 test "$tst_proto_strstr" = "yes" &&
40740 test "$tst_compi_strstr" = "yes" &&
40741 test "$tst_allow_strstr" = "yes"; then
40742 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40743$as_echo "yes" >&6; }
40744
40745cat >>confdefs.h <<_ACEOF
40746#define HAVE_STRSTR 1
40747_ACEOF
40748
40749 curl_cv_func_strstr="yes"
40750 else
40751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40752$as_echo "no" >&6; }
40753 curl_cv_func_strstr="no"
40754 fi
40755
40756
40757 #
40758 tst_links_strtok_r="unknown"
40759 tst_proto_strtok_r="unknown"
40760 tst_compi_strtok_r="unknown"
40761 tst_allow_strtok_r="unknown"
40762 #
40763 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strtok_r can be linked" >&5
40764$as_echo_n "checking if strtok_r can be linked... " >&6; }
40765 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40766/* end confdefs.h. */
40767
40768
40769#define strtok_r innocuous_strtok_r
40770#ifdef __STDC__
40771# include <limits.h>
40772#else
40773# include <assert.h>
40774#endif
40775#undef strtok_r
40776#ifdef __cplusplus
40777extern "C"
40778#endif
40779char strtok_r ();
40780#if defined __stub_strtok_r || defined __stub___strtok_r
40781choke me
40782#endif
40783
40784int main (void)
40785{
40786return strtok_r ();
40787 ;
40788 return 0;
40789}
40790
40791_ACEOF
40792if ac_fn_c_try_link "$LINENO"; then :
40793
40794 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40795$as_echo "yes" >&6; }
40796 tst_links_strtok_r="yes"
40797
40798else
40799
40800 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40801$as_echo "no" >&6; }
40802 tst_links_strtok_r="no"
40803
40804fi
40805rm -f core conftest.err conftest.$ac_objext \
40806 conftest$ac_exeext conftest.$ac_ext
40807 #
40808 if test "$tst_links_strtok_r" = "yes"; then
40809 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strtok_r is prototyped" >&5
40810$as_echo_n "checking if strtok_r is prototyped... " >&6; }
40811 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40812/* end confdefs.h. */
40813
40814 $curl_includes_string
40815
40816_ACEOF
40817if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
40818 $EGREP "strtok_r" >/dev/null 2>&1; then :
40819
40820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40821$as_echo "yes" >&6; }
40822 tst_proto_strtok_r="yes"
40823
40824else
40825
40826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40827$as_echo "no" >&6; }
40828 tst_proto_strtok_r="no"
40829
40830fi
40831rm -f conftest*
40832
40833 fi
40834 #
40835 if test "$tst_proto_strtok_r" = "yes"; then
40836 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strtok_r is compilable" >&5
40837$as_echo_n "checking if strtok_r is compilable... " >&6; }
40838 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40839/* end confdefs.h. */
40840
40841
40842 $curl_includes_string
40843
40844int main (void)
40845{
40846
40847 if(0 != strtok_r(0, 0, 0))
40848 return 1;
40849
40850 ;
40851 return 0;
40852}
40853
40854_ACEOF
40855if ac_fn_c_try_compile "$LINENO"; then :
40856
40857 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40858$as_echo "yes" >&6; }
40859 tst_compi_strtok_r="yes"
40860
40861else
40862
40863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40864$as_echo "no" >&6; }
40865 tst_compi_strtok_r="no"
40866
40867fi
40868rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
40869 fi
40870 #
40871 if test "$tst_compi_strtok_r" = "yes"; then
40872 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strtok_r usage allowed" >&5
40873$as_echo_n "checking if strtok_r usage allowed... " >&6; }
40874 if test "x$curl_disallow_strtok_r" != "xyes"; then
40875 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40876$as_echo "yes" >&6; }
40877 tst_allow_strtok_r="yes"
40878 else
40879 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40880$as_echo "no" >&6; }
40881 tst_allow_strtok_r="no"
40882 fi
40883 fi
40884 #
40885 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strtok_r might be used" >&5
40886$as_echo_n "checking if strtok_r might be used... " >&6; }
40887 if test "$tst_links_strtok_r" = "yes" &&
40888 test "$tst_proto_strtok_r" = "yes" &&
40889 test "$tst_compi_strtok_r" = "yes" &&
40890 test "$tst_allow_strtok_r" = "yes"; then
40891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40892$as_echo "yes" >&6; }
40893
40894cat >>confdefs.h <<_ACEOF
40895#define HAVE_STRTOK_R 1
40896_ACEOF
40897
40898 curl_cv_func_strtok_r="yes"
40899 else
40900 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40901$as_echo "no" >&6; }
40902 curl_cv_func_strtok_r="no"
40903 fi
40904
40905
40906 #
40907 tst_links_strtoll="unknown"
40908 tst_proto_strtoll="unknown"
40909 tst_compi_strtoll="unknown"
40910 tst_allow_strtoll="unknown"
40911 #
40912 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strtoll can be linked" >&5
40913$as_echo_n "checking if strtoll can be linked... " >&6; }
40914 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40915/* end confdefs.h. */
40916
40917
40918#define strtoll innocuous_strtoll
40919#ifdef __STDC__
40920# include <limits.h>
40921#else
40922# include <assert.h>
40923#endif
40924#undef strtoll
40925#ifdef __cplusplus
40926extern "C"
40927#endif
40928char strtoll ();
40929#if defined __stub_strtoll || defined __stub___strtoll
40930choke me
40931#endif
40932
40933int main (void)
40934{
40935return strtoll ();
40936 ;
40937 return 0;
40938}
40939
40940_ACEOF
40941if ac_fn_c_try_link "$LINENO"; then :
40942
40943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40944$as_echo "yes" >&6; }
40945 tst_links_strtoll="yes"
40946
40947else
40948
40949 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40950$as_echo "no" >&6; }
40951 tst_links_strtoll="no"
40952
40953fi
40954rm -f core conftest.err conftest.$ac_objext \
40955 conftest$ac_exeext conftest.$ac_ext
40956 #
40957 if test "$tst_links_strtoll" = "yes"; then
40958 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strtoll is prototyped" >&5
40959$as_echo_n "checking if strtoll is prototyped... " >&6; }
40960 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40961/* end confdefs.h. */
40962
40963 $curl_includes_stdlib
40964
40965_ACEOF
40966if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
40967 $EGREP "strtoll" >/dev/null 2>&1; then :
40968
40969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40970$as_echo "yes" >&6; }
40971 tst_proto_strtoll="yes"
40972
40973else
40974
40975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40976$as_echo "no" >&6; }
40977 tst_proto_strtoll="no"
40978
40979fi
40980rm -f conftest*
40981
40982 fi
40983 #
40984 if test "$tst_proto_strtoll" = "yes"; then
40985 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strtoll is compilable" >&5
40986$as_echo_n "checking if strtoll is compilable... " >&6; }
40987 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40988/* end confdefs.h. */
40989
40990
40991 $curl_includes_stdlib
40992
40993int main (void)
40994{
40995
40996 if(0 != strtoll(0, 0, 0))
40997 return 1;
40998
40999 ;
41000 return 0;
41001}
41002
41003_ACEOF
41004if ac_fn_c_try_compile "$LINENO"; then :
41005
41006 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41007$as_echo "yes" >&6; }
41008 tst_compi_strtoll="yes"
41009
41010else
41011
41012 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41013$as_echo "no" >&6; }
41014 tst_compi_strtoll="no"
41015
41016fi
41017rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41018 fi
41019 #
41020 if test "$tst_compi_strtoll" = "yes"; then
41021 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strtoll usage allowed" >&5
41022$as_echo_n "checking if strtoll usage allowed... " >&6; }
41023 if test "x$curl_disallow_strtoll" != "xyes"; then
41024 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41025$as_echo "yes" >&6; }
41026 tst_allow_strtoll="yes"
41027 else
41028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41029$as_echo "no" >&6; }
41030 tst_allow_strtoll="no"
41031 fi
41032 fi
41033 #
41034 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strtoll might be used" >&5
41035$as_echo_n "checking if strtoll might be used... " >&6; }
41036 if test "$tst_links_strtoll" = "yes" &&
41037 test "$tst_proto_strtoll" = "yes" &&
41038 test "$tst_compi_strtoll" = "yes" &&
41039 test "$tst_allow_strtoll" = "yes"; then
41040 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41041$as_echo "yes" >&6; }
41042
41043cat >>confdefs.h <<_ACEOF
41044#define HAVE_STRTOLL 1
41045_ACEOF
41046
41047 curl_cv_func_strtoll="yes"
41048 else
41049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41050$as_echo "no" >&6; }
41051 curl_cv_func_strtoll="no"
41052 fi
41053
41054
41055curl_includes_sys_uio="\
41056/* includes start */
41057#ifdef HAVE_SYS_TYPES_H
41058# include <sys/types.h>
41059#endif
41060#ifdef HAVE_SYS_UIO_H
41061# include <sys/uio.h>
41062#endif
41063/* includes end */"
41064 for ac_header in sys/types.h sys/uio.h
41065do :
41066 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
41067ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_sys_uio
41068"
41069if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
41070 cat >>confdefs.h <<_ACEOF
41071#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
41072_ACEOF
41073
41074fi
41075
41076done
41077
41078
41079
41080 #
41081 tst_links_writev="unknown"
41082 tst_proto_writev="unknown"
41083 tst_compi_writev="unknown"
41084 tst_allow_writev="unknown"
41085 #
41086 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if writev can be linked" >&5
41087$as_echo_n "checking if writev can be linked... " >&6; }
41088 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41089/* end confdefs.h. */
41090
41091
41092#define writev innocuous_writev
41093#ifdef __STDC__
41094# include <limits.h>
41095#else
41096# include <assert.h>
41097#endif
41098#undef writev
41099#ifdef __cplusplus
41100extern "C"
41101#endif
41102char writev ();
41103#if defined __stub_writev || defined __stub___writev
41104choke me
41105#endif
41106
41107int main (void)
41108{
41109return writev ();
41110 ;
41111 return 0;
41112}
41113
41114_ACEOF
41115if ac_fn_c_try_link "$LINENO"; then :
41116
41117 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41118$as_echo "yes" >&6; }
41119 tst_links_writev="yes"
41120
41121else
41122
41123 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41124$as_echo "no" >&6; }
41125 tst_links_writev="no"
41126
41127fi
41128rm -f core conftest.err conftest.$ac_objext \
41129 conftest$ac_exeext conftest.$ac_ext
41130 #
41131 if test "$tst_links_writev" = "yes"; then
41132 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if writev is prototyped" >&5
41133$as_echo_n "checking if writev is prototyped... " >&6; }
41134 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41135/* end confdefs.h. */
41136
41137 $curl_includes_sys_uio
41138
41139_ACEOF
41140if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
41141 $EGREP "writev" >/dev/null 2>&1; then :
41142
41143 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41144$as_echo "yes" >&6; }
41145 tst_proto_writev="yes"
41146
41147else
41148
41149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41150$as_echo "no" >&6; }
41151 tst_proto_writev="no"
41152
41153fi
41154rm -f conftest*
41155
41156 fi
41157 #
41158 if test "$tst_proto_writev" = "yes"; then
41159 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if writev is compilable" >&5
41160$as_echo_n "checking if writev is compilable... " >&6; }
41161 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41162/* end confdefs.h. */
41163
41164
41165 $curl_includes_sys_uio
41166
41167int main (void)
41168{
41169
41170 if(0 != writev(0, 0, 0))
41171 return 1;
41172
41173 ;
41174 return 0;
41175}
41176
41177_ACEOF
41178if ac_fn_c_try_compile "$LINENO"; then :
41179
41180 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41181$as_echo "yes" >&6; }
41182 tst_compi_writev="yes"
41183
41184else
41185
41186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41187$as_echo "no" >&6; }
41188 tst_compi_writev="no"
41189
41190fi
41191rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41192 fi
41193 #
41194 if test "$tst_compi_writev" = "yes"; then
41195 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if writev usage allowed" >&5
41196$as_echo_n "checking if writev usage allowed... " >&6; }
41197 if test "x$curl_disallow_writev" != "xyes"; then
41198 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41199$as_echo "yes" >&6; }
41200 tst_allow_writev="yes"
41201 else
41202 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41203$as_echo "no" >&6; }
41204 tst_allow_writev="no"
41205 fi
41206 fi
41207 #
41208 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if writev might be used" >&5
41209$as_echo_n "checking if writev might be used... " >&6; }
41210 if test "$tst_links_writev" = "yes" &&
41211 test "$tst_proto_writev" = "yes" &&
41212 test "$tst_compi_writev" = "yes" &&
41213 test "$tst_allow_writev" = "yes"; then
41214 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41215$as_echo "yes" >&6; }
41216
41217cat >>confdefs.h <<_ACEOF
41218#define HAVE_WRITEV 1
41219_ACEOF
41220
41221 curl_cv_func_writev="yes"
41222 else
41223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41224$as_echo "no" >&6; }
41225 curl_cv_func_writev="no"
41226 fi
41227
41228
41229case $host in
41230 *msdosdjgpp)
41231 ac_cv_func_pipe=no
41232 skipcheck_pipe=yes
41233 { $as_echo "$as_me:${as_lineno-$LINENO}: skip check for pipe on msdosdjgpp" >&5
41234$as_echo "$as_me: skip check for pipe on msdosdjgpp" >&6;}
41235 ;;
41236esac
41237
Elliott Hughes72d948d2018-08-03 14:37:21 -070041238ac_fn_c_check_decl "$LINENO" "getpwuid_r" "ac_cv_have_decl_getpwuid_r" "#include <pwd.h>
41239 #include <sys/types.h>
41240"
41241if test "x$ac_cv_have_decl_getpwuid_r" = xyes; then :
41242 ac_have_decl=1
41243else
41244 ac_have_decl=0
41245fi
41246
41247cat >>confdefs.h <<_ACEOF
41248#define HAVE_DECL_GETPWUID_R $ac_have_decl
41249_ACEOF
41250if test $ac_have_decl = 1; then :
41251
41252else
41253
41254$as_echo "#define HAVE_DECL_GETPWUID_R_MISSING 1" >>confdefs.h
41255
41256fi
41257
41258
41259
41260for ac_func in fnmatch \
41261 geteuid \
Elliott Hughes82be86d2017-09-20 17:00:17 -070041262 getpass_r \
41263 getppid \
41264 getpwuid \
41265 getpwuid_r \
41266 getrlimit \
41267 gettimeofday \
41268 if_nametoindex \
Alex Deymo486467e2017-12-19 19:04:07 +010041269 mach_absolute_time \
Elliott Hughes82be86d2017-09-20 17:00:17 -070041270 pipe \
41271 setlocale \
41272 setmode \
41273 setrlimit \
Haibo Huang445085a2019-09-11 13:33:50 -070041274 usleep \
Elliott Hughes82be86d2017-09-20 17:00:17 -070041275 utime \
41276 utimes
41277
41278do :
41279 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
41280ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
41281if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
41282 cat >>confdefs.h <<_ACEOF
41283#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
41284_ACEOF
41285
41286
41287else
41288
41289 func="$ac_func"
41290 eval skipcheck=\$skipcheck_$func
41291 if test "x$skipcheck" != "xyes"; then
41292 { $as_echo "$as_me:${as_lineno-$LINENO}: checking deeper for $func" >&5
41293$as_echo_n "checking deeper for $func... " >&6; }
41294 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41295/* end confdefs.h. */
41296
41297
41298
41299int main (void)
41300{
41301
41302 $func ();
41303
41304 ;
41305 return 0;
41306}
41307
41308_ACEOF
41309if ac_fn_c_try_link "$LINENO"; then :
41310
41311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41312$as_echo "yes" >&6; }
41313 eval "ac_cv_func_$func=yes"
41314
41315cat >>confdefs.h <<_ACEOF
41316#define `echo "HAVE_$func" | sed 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/' | sed 's/^A-Z0-9_/_/g'` 1
41317_ACEOF
41318
41319
41320else
41321
41322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: but still no" >&5
41323$as_echo "but still no" >&6; }
41324
41325fi
41326rm -f core conftest.err conftest.$ac_objext \
41327 conftest$ac_exeext conftest.$ac_ext
41328 fi
41329
41330fi
41331done
41332
41333
Elliott Hughes82be86d2017-09-20 17:00:17 -070041334if test "$ipv6" = "yes"; then
41335 if test "$curl_cv_func_getaddrinfo" = "yes"; then
41336
41337$as_echo "#define ENABLE_IPV6 1" >>confdefs.h
41338
41339 IPV6_ENABLED=1
41340
Haibo Huang31944072019-11-06 02:28:57 -080041341 curl_ipv6_msg="enabled"
Elliott Hughes82be86d2017-09-20 17:00:17 -070041342 fi
Elliott Hughes82be86d2017-09-20 17:00:17 -070041343fi
41344
41345
41346 #
41347 tst_method="unknown"
41348
41349 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to set a socket into non-blocking mode" >&5
41350$as_echo_n "checking how to set a socket into non-blocking mode... " >&6; }
41351 if test "x$curl_cv_func_fcntl_o_nonblock" = "xyes"; then
41352 tst_method="fcntl O_NONBLOCK"
41353 elif test "x$curl_cv_func_ioctl_fionbio" = "xyes"; then
41354 tst_method="ioctl FIONBIO"
41355 elif test "x$curl_cv_func_ioctlsocket_fionbio" = "xyes"; then
41356 tst_method="ioctlsocket FIONBIO"
41357 elif test "x$curl_cv_func_ioctlsocket_camel_fionbio" = "xyes"; then
41358 tst_method="IoctlSocket FIONBIO"
41359 elif test "x$curl_cv_func_setsockopt_so_nonblock" = "xyes"; then
41360 tst_method="setsockopt SO_NONBLOCK"
41361 fi
41362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tst_method" >&5
41363$as_echo "$tst_method" >&6; }
41364 if test "$tst_method" = "unknown"; then
41365 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot determine non-blocking socket method." >&5
41366$as_echo "$as_me: WARNING: cannot determine non-blocking socket method." >&2;}
41367 fi
41368
41369
41370
41371# Extract the first word of "perl", so it can be a program name with args.
41372set dummy perl; ac_word=$2
41373{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
41374$as_echo_n "checking for $ac_word... " >&6; }
41375if ${ac_cv_path_PERL+:} false; then :
41376 $as_echo_n "(cached) " >&6
41377else
41378 case $PERL in
41379 [\\/]* | ?:[\\/]*)
41380 ac_cv_path_PERL="$PERL" # Let the user override the test with a path.
41381 ;;
41382 *)
41383 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
41384as_dummy="$PATH:/usr/local/bin/perl:/usr/bin/:/usr/local/bin "
41385for as_dir in $as_dummy
41386do
41387 IFS=$as_save_IFS
41388 test -z "$as_dir" && as_dir=.
41389 for ac_exec_ext in '' $ac_executable_extensions; do
41390 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
41391 ac_cv_path_PERL="$as_dir/$ac_word$ac_exec_ext"
41392 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
41393 break 2
41394 fi
41395done
41396 done
41397IFS=$as_save_IFS
41398
41399 ;;
41400esac
41401fi
41402PERL=$ac_cv_path_PERL
41403if test -n "$PERL"; then
41404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PERL" >&5
41405$as_echo "$PERL" >&6; }
41406else
41407 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41408$as_echo "no" >&6; }
41409fi
41410
41411
41412
41413
41414for ac_prog in gnroff nroff
41415do
41416 # Extract the first word of "$ac_prog", so it can be a program name with args.
41417set dummy $ac_prog; ac_word=$2
41418{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
41419$as_echo_n "checking for $ac_word... " >&6; }
41420if ${ac_cv_path_NROFF+:} false; then :
41421 $as_echo_n "(cached) " >&6
41422else
41423 case $NROFF in
41424 [\\/]* | ?:[\\/]*)
41425 ac_cv_path_NROFF="$NROFF" # Let the user override the test with a path.
41426 ;;
41427 *)
41428 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
41429as_dummy="$PATH:/usr/bin/:/usr/local/bin "
41430for as_dir in $as_dummy
41431do
41432 IFS=$as_save_IFS
41433 test -z "$as_dir" && as_dir=.
41434 for ac_exec_ext in '' $ac_executable_extensions; do
41435 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
41436 ac_cv_path_NROFF="$as_dir/$ac_word$ac_exec_ext"
41437 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
41438 break 2
41439 fi
41440done
41441 done
41442IFS=$as_save_IFS
41443
41444 ;;
41445esac
41446fi
41447NROFF=$ac_cv_path_NROFF
41448if test -n "$NROFF"; then
41449 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NROFF" >&5
41450$as_echo "$NROFF" >&6; }
41451else
41452 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41453$as_echo "no" >&6; }
41454fi
41455
41456
41457 test -n "$NROFF" && break
41458done
41459
41460
41461
41462if test -n "$NROFF"; then
41463
41464 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to use *nroff to get plain text from man pages" >&5
41465$as_echo_n "checking how to use *nroff to get plain text from man pages... " >&6; }
41466 MANOPT="-man"
41467 mancheck=`echo foo | $NROFF $MANOPT 2>/dev/null`
41468 if test -z "$mancheck"; then
41469 MANOPT="-mandoc"
41470 mancheck=`echo foo | $NROFF $MANOPT 2>/dev/null`
41471 if test -z "$mancheck"; then
41472 MANOPT=""
41473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
41474$as_echo "failed" >&6; }
41475 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: found no *nroff option to get plaintext from man pages" >&5
41476$as_echo "$as_me: WARNING: found no *nroff option to get plaintext from man pages" >&2;}
41477 else
41478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANOPT" >&5
41479$as_echo "$MANOPT" >&6; }
41480 fi
41481 else
41482 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANOPT" >&5
41483$as_echo "$MANOPT" >&6; }
41484 fi
41485
41486fi
41487
41488if test -z "$MANOPT"
41489then
41490 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: disabling built-in manual" >&5
41491$as_echo "$as_me: WARNING: disabling built-in manual" >&2;}
41492 USE_MANUAL="no";
41493fi
41494
41495
41496if test "$USE_MANUAL" = "1"; then
41497
41498$as_echo "#define USE_MANUAL 1" >>confdefs.h
41499
41500 curl_manual_msg="enabled"
41501fi
41502
41503 if test x"$USE_MANUAL" = x1; then
41504 USE_MANUAL_TRUE=
41505 USE_MANUAL_FALSE='#'
41506else
41507 USE_MANUAL_TRUE='#'
41508 USE_MANUAL_FALSE=
41509fi
41510
41511
41512
41513
41514
41515 #
41516 if test "$want_ares" = "yes"; then
41517 clean_CPPFLAGS="$CPPFLAGS"
41518 clean_LDFLAGS="$LDFLAGS"
41519 clean_LIBS="$LIBS"
41520 embedded_ares="unknown"
41521 configure_runpath=`pwd`
41522 embedded_ares_builddir="$configure_runpath/ares"
41523 if test -n "$want_ares_path"; then
Elliott Hughes72d948d2018-08-03 14:37:21 -070041524 ARES_PCDIR="$want_ares_path/lib/pkgconfig"
41525
41526 if test -n "$PKG_CONFIG"; then
41527 PKGCONFIG="$PKG_CONFIG"
41528 else
41529 if test -n "$ac_tool_prefix"; then
41530 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
41531set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
41532{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
41533$as_echo_n "checking for $ac_word... " >&6; }
41534if ${ac_cv_path_PKGCONFIG+:} false; then :
41535 $as_echo_n "(cached) " >&6
41536else
41537 case $PKGCONFIG in
41538 [\\/]* | ?:[\\/]*)
41539 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
41540 ;;
41541 *)
41542 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
41543as_dummy="$PATH:/usr/bin:/usr/local/bin"
41544for as_dir in $as_dummy
41545do
41546 IFS=$as_save_IFS
41547 test -z "$as_dir" && as_dir=.
41548 for ac_exec_ext in '' $ac_executable_extensions; do
41549 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
41550 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
41551 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
41552 break 2
41553 fi
41554done
41555 done
41556IFS=$as_save_IFS
41557
41558 ;;
41559esac
41560fi
41561PKGCONFIG=$ac_cv_path_PKGCONFIG
41562if test -n "$PKGCONFIG"; then
41563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
41564$as_echo "$PKGCONFIG" >&6; }
41565else
41566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41567$as_echo "no" >&6; }
41568fi
41569
41570
41571fi
41572if test -z "$ac_cv_path_PKGCONFIG"; then
41573 ac_pt_PKGCONFIG=$PKGCONFIG
41574 # Extract the first word of "pkg-config", so it can be a program name with args.
41575set dummy pkg-config; ac_word=$2
41576{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
41577$as_echo_n "checking for $ac_word... " >&6; }
41578if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
41579 $as_echo_n "(cached) " >&6
41580else
41581 case $ac_pt_PKGCONFIG in
41582 [\\/]* | ?:[\\/]*)
41583 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
41584 ;;
41585 *)
41586 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
41587as_dummy="$PATH:/usr/bin:/usr/local/bin"
41588for as_dir in $as_dummy
41589do
41590 IFS=$as_save_IFS
41591 test -z "$as_dir" && as_dir=.
41592 for ac_exec_ext in '' $ac_executable_extensions; do
41593 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
41594 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
41595 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
41596 break 2
41597 fi
41598done
41599 done
41600IFS=$as_save_IFS
41601
41602 ;;
41603esac
41604fi
41605ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
41606if test -n "$ac_pt_PKGCONFIG"; then
41607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
41608$as_echo "$ac_pt_PKGCONFIG" >&6; }
41609else
41610 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41611$as_echo "no" >&6; }
41612fi
41613
41614 if test "x$ac_pt_PKGCONFIG" = x; then
41615 PKGCONFIG="no"
41616 else
41617 case $cross_compiling:$ac_tool_warned in
41618yes:)
41619{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
41620$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
41621ac_tool_warned=yes ;;
41622esac
41623 PKGCONFIG=$ac_pt_PKGCONFIG
41624 fi
41625else
41626 PKGCONFIG="$ac_cv_path_PKGCONFIG"
41627fi
41628
41629 fi
41630
41631 if test "x$PKGCONFIG" != "xno"; then
41632 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libcares options with pkg-config" >&5
41633$as_echo_n "checking for libcares options with pkg-config... " >&6; }
41634 itexists=`
41635 if test -n "$ARES_PCDIR"; then
41636 PKG_CONFIG_LIBDIR="$ARES_PCDIR"
41637 export PKG_CONFIG_LIBDIR
41638 fi
41639 $PKGCONFIG --exists libcares >/dev/null 2>&1 && echo 1`
41640
41641 if test -z "$itexists"; then
41642 PKGCONFIG="no"
41643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41644$as_echo "no" >&6; }
41645 else
41646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
41647$as_echo "found" >&6; }
41648 fi
41649 fi
41650
41651 if test "$PKGCONFIG" != "no" ; then
41652 ares_LIBS=`
41653 if test -n "$ARES_PCDIR"; then
41654 PKG_CONFIG_LIBDIR="$ARES_PCDIR"
41655 export PKG_CONFIG_LIBDIR
41656 fi
41657
41658 $PKGCONFIG --libs-only-l libcares`
41659 ares_LDFLAGS=`
41660 if test -n "$ARES_PCDIR"; then
41661 PKG_CONFIG_LIBDIR="$ARES_PCDIR"
41662 export PKG_CONFIG_LIBDIR
41663 fi
41664
41665 $PKGCONFIG --libs-only-L libcares`
41666 ares_CPPFLAGS=`
41667 if test -n "$ARES_PCDIR"; then
41668 PKG_CONFIG_LIBDIR="$ARES_PCDIR"
41669 export PKG_CONFIG_LIBDIR
41670 fi
41671
41672 $PKGCONFIG --cflags-only-I libcares`
41673 { $as_echo "$as_me:${as_lineno-$LINENO}: pkg-config: ares LIBS: \"$ares_LIBS\"" >&5
41674$as_echo "$as_me: pkg-config: ares LIBS: \"$ares_LIBS\"" >&6;}
41675 { $as_echo "$as_me:${as_lineno-$LINENO}: pkg-config: ares LDFLAGS: \"$ares_LDFLAGS\"" >&5
41676$as_echo "$as_me: pkg-config: ares LDFLAGS: \"$ares_LDFLAGS\"" >&6;}
41677 { $as_echo "$as_me:${as_lineno-$LINENO}: pkg-config: ares CPPFLAGS: \"$ares_CPPFLAGS\"" >&5
41678$as_echo "$as_me: pkg-config: ares CPPFLAGS: \"$ares_CPPFLAGS\"" >&6;}
41679 else
41680 ares_CPPFLAGS="-I$want_ares_path/include"
41681 ares_LDFLAGS="-L$want_ares_path/lib"
41682 ares_LIBS="-lcares"
41683 fi
Elliott Hughes82be86d2017-09-20 17:00:17 -070041684 else
41685 if test -d "$srcdir/ares"; then
41686 embedded_ares="yes"
41687 subdirs="$subdirs ares"
41688
41689 ares_CPPFLAGS=""
41690 ares_LDFLAGS="-L$embedded_ares_builddir"
41691 ares_LIBS="-lcares"
41692 else
Elliott Hughes72d948d2018-08-03 14:37:21 -070041693
41694 if test -n "$PKG_CONFIG"; then
41695 PKGCONFIG="$PKG_CONFIG"
41696 else
41697 if test -n "$ac_tool_prefix"; then
41698 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
41699set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
41700{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
41701$as_echo_n "checking for $ac_word... " >&6; }
41702if ${ac_cv_path_PKGCONFIG+:} false; then :
41703 $as_echo_n "(cached) " >&6
41704else
41705 case $PKGCONFIG in
41706 [\\/]* | ?:[\\/]*)
41707 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
41708 ;;
41709 *)
41710 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
41711as_dummy="$PATH:/usr/bin:/usr/local/bin"
41712for as_dir in $as_dummy
41713do
41714 IFS=$as_save_IFS
41715 test -z "$as_dir" && as_dir=.
41716 for ac_exec_ext in '' $ac_executable_extensions; do
41717 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
41718 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
41719 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
41720 break 2
41721 fi
41722done
41723 done
41724IFS=$as_save_IFS
41725
41726 ;;
41727esac
41728fi
41729PKGCONFIG=$ac_cv_path_PKGCONFIG
41730if test -n "$PKGCONFIG"; then
41731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
41732$as_echo "$PKGCONFIG" >&6; }
41733else
41734 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41735$as_echo "no" >&6; }
41736fi
41737
41738
41739fi
41740if test -z "$ac_cv_path_PKGCONFIG"; then
41741 ac_pt_PKGCONFIG=$PKGCONFIG
41742 # Extract the first word of "pkg-config", so it can be a program name with args.
41743set dummy pkg-config; ac_word=$2
41744{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
41745$as_echo_n "checking for $ac_word... " >&6; }
41746if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
41747 $as_echo_n "(cached) " >&6
41748else
41749 case $ac_pt_PKGCONFIG in
41750 [\\/]* | ?:[\\/]*)
41751 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
41752 ;;
41753 *)
41754 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
41755as_dummy="$PATH:/usr/bin:/usr/local/bin"
41756for as_dir in $as_dummy
41757do
41758 IFS=$as_save_IFS
41759 test -z "$as_dir" && as_dir=.
41760 for ac_exec_ext in '' $ac_executable_extensions; do
41761 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
41762 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
41763 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
41764 break 2
41765 fi
41766done
41767 done
41768IFS=$as_save_IFS
41769
41770 ;;
41771esac
41772fi
41773ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
41774if test -n "$ac_pt_PKGCONFIG"; then
41775 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
41776$as_echo "$ac_pt_PKGCONFIG" >&6; }
41777else
41778 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41779$as_echo "no" >&6; }
41780fi
41781
41782 if test "x$ac_pt_PKGCONFIG" = x; then
41783 PKGCONFIG="no"
41784 else
41785 case $cross_compiling:$ac_tool_warned in
41786yes:)
41787{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
41788$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
41789ac_tool_warned=yes ;;
41790esac
41791 PKGCONFIG=$ac_pt_PKGCONFIG
41792 fi
41793else
41794 PKGCONFIG="$ac_cv_path_PKGCONFIG"
41795fi
41796
41797 fi
41798
41799 if test "x$PKGCONFIG" != "xno"; then
41800 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libcares options with pkg-config" >&5
41801$as_echo_n "checking for libcares options with pkg-config... " >&6; }
41802 itexists=`
41803 if test -n ""; then
41804 PKG_CONFIG_LIBDIR=""
41805 export PKG_CONFIG_LIBDIR
41806 fi
41807 $PKGCONFIG --exists libcares >/dev/null 2>&1 && echo 1`
41808
41809 if test -z "$itexists"; then
41810 PKGCONFIG="no"
41811 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41812$as_echo "no" >&6; }
41813 else
41814 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
41815$as_echo "found" >&6; }
41816 fi
41817 fi
41818
41819 if test "$PKGCONFIG" != "no" ; then
41820 ares_LIBS=`$PKGCONFIG --libs-only-l libcares`
41821 ares_LDFLAGS=`$PKGCONFIG --libs-only-L libcares`
41822 ares_CPPFLAGS=`$PKGCONFIG --cflags-only-I libcares`
41823 { $as_echo "$as_me:${as_lineno-$LINENO}: pkg-config: ares_LIBS: \"$ares_LIBS\"" >&5
41824$as_echo "$as_me: pkg-config: ares_LIBS: \"$ares_LIBS\"" >&6;}
41825 { $as_echo "$as_me:${as_lineno-$LINENO}: pkg-config: ares_LDFLAGS: \"$ares_LDFLAGS\"" >&5
41826$as_echo "$as_me: pkg-config: ares_LDFLAGS: \"$ares_LDFLAGS\"" >&6;}
41827 { $as_echo "$as_me:${as_lineno-$LINENO}: pkg-config: ares_CPPFLAGS: \"$ares_CPPFLAGS\"" >&5
41828$as_echo "$as_me: pkg-config: ares_CPPFLAGS: \"$ares_CPPFLAGS\"" >&6;}
41829 else
41830 ares_CPPFLAGS=""
41831 ares_LDFLAGS=""
41832 ares_LIBS="-lcares"
41833 fi
Elliott Hughes82be86d2017-09-20 17:00:17 -070041834 fi
41835 fi
41836 #
41837 CPPFLAGS="$clean_CPPFLAGS $ares_CPPFLAGS"
41838 LDFLAGS="$clean_LDFLAGS $ares_LDFLAGS"
41839 LIBS="$ares_LIBS $clean_LIBS"
41840 #
41841 if test "$embedded_ares" != "yes"; then
41842 { $as_echo "$as_me:${as_lineno-$LINENO}: checking that c-ares is good and recent enough" >&5
41843$as_echo_n "checking that c-ares is good and recent enough... " >&6; }
41844 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41845/* end confdefs.h. */
41846
41847
41848#include <ares.h>
41849 /* set of dummy functions in case c-ares was built with debug */
41850 void curl_dofree() { }
41851 void curl_sclose() { }
41852 void curl_domalloc() { }
41853 void curl_docalloc() { }
41854 void curl_socket() { }
41855
41856int main (void)
41857{
41858
41859 ares_channel channel;
41860 ares_cancel(channel); /* added in 1.2.0 */
41861 ares_process_fd(channel, 0, 0); /* added in 1.4.0 */
41862 ares_dup(&channel, channel); /* added in 1.6.0 */
41863
41864 ;
41865 return 0;
41866}
41867
41868_ACEOF
41869if ac_fn_c_try_link "$LINENO"; then :
41870
41871 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41872$as_echo "yes" >&6; }
41873
41874else
41875
41876 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41877$as_echo "no" >&6; }
41878 as_fn_error $? "c-ares library defective or too old" "$LINENO" 5
41879 CPPFLAGS="$clean_CPPFLAGS"
41880 LDFLAGS="$clean_LDFLAGS"
41881 LIBS="$clean_LIBS"
41882 # prevent usage
41883 want_ares="no"
41884
41885fi
41886rm -f core conftest.err conftest.$ac_objext \
41887 conftest$ac_exeext conftest.$ac_ext
41888 fi
41889 if test "$want_ares" = "yes"; then
41890
41891$as_echo "#define USE_ARES 1" >>confdefs.h
41892
41893 USE_ARES=1
41894
41895 curl_res_msg="c-ares"
41896 fi
41897 fi
41898
41899 if test x$embedded_ares = xyes; then
41900 USE_EMBEDDED_ARES_TRUE=
41901 USE_EMBEDDED_ARES_FALSE='#'
41902else
41903 USE_EMBEDDED_ARES_TRUE='#'
41904 USE_EMBEDDED_ARES_FALSE=
41905fi
41906
41907
41908if test "x$curl_cv_native_windows" != "xyes" &&
41909 test "x$enable_shared" = "xyes"; then
41910 build_libhostname=yes
41911else
41912 build_libhostname=no
41913fi
41914 if test x$build_libhostname = xyes; then
41915 BUILD_LIBHOSTNAME_TRUE=
41916 BUILD_LIBHOSTNAME_FALSE='#'
41917else
41918 BUILD_LIBHOSTNAME_TRUE='#'
41919 BUILD_LIBHOSTNAME_FALSE=
41920fi
41921
41922
41923if test "x$want_ares" != xyes; then
41924
41925 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable the threaded resolver" >&5
41926$as_echo_n "checking whether to enable the threaded resolver... " >&6; }
41927 OPT_THRES="default"
41928 # Check whether --enable-threaded_resolver was given.
41929if test "${enable_threaded_resolver+set}" = set; then :
41930 enableval=$enable_threaded_resolver; OPT_THRES=$enableval
41931fi
41932
41933 case "$OPT_THRES" in
Elliott Hughes82be86d2017-09-20 17:00:17 -070041934 no)
41935 want_thres="no"
41936 ;;
Alex Deymo486467e2017-12-19 19:04:07 +010041937 *)
41938 want_thres="yes"
41939 ;;
Elliott Hughes82be86d2017-09-20 17:00:17 -070041940 esac
41941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $want_thres" >&5
41942$as_echo "$want_thres" >&6; }
41943
41944fi
41945
41946{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use POSIX threads for threaded resolver" >&5
41947$as_echo_n "checking whether to use POSIX threads for threaded resolver... " >&6; }
41948# Check whether --enable-pthreads was given.
41949if test "${enable_pthreads+set}" = set; then :
41950 enableval=$enable_pthreads; case "$enableval" in
41951 no) { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41952$as_echo "no" >&6; }
41953 want_pthreads=no
41954 ;;
41955 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41956$as_echo "yes" >&6; }
41957 want_pthreads=yes
41958 ;;
41959 esac
41960else
41961
41962 { $as_echo "$as_me:${as_lineno-$LINENO}: result: auto" >&5
41963$as_echo "auto" >&6; }
41964 want_pthreads=auto
41965
41966
41967fi
41968
41969
41970if test "$want_pthreads" != "no"; then
41971 if test "$want_pthreads" = "yes" && test "$dontwant_rt" = "yes"; then
41972 as_fn_error $? "options --enable-pthreads and --disable-rt are mutually exclusive" "$LINENO" 5
41973 fi
41974 if test "$dontwant_rt" != "no"; then
41975 if test "$want_pthreads" = "yes"; then
41976 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --enable-pthreads Ignored since librt is disabled." >&5
41977$as_echo "$as_me: WARNING: --enable-pthreads Ignored since librt is disabled." >&2;}
41978 fi
41979 want_pthreads=no
41980 fi
41981fi
41982
41983if test "$want_pthreads" != "no" && test "$want_thres" != "yes"; then
41984 want_pthreads=no
41985fi
41986
41987if test "$want_pthreads" != "no"; then
41988 ac_fn_c_check_header_mongrel "$LINENO" "pthread.h" "ac_cv_header_pthread_h" "$ac_includes_default"
41989if test "x$ac_cv_header_pthread_h" = xyes; then :
41990
41991$as_echo "#define HAVE_PTHREAD_H 1" >>confdefs.h
41992
41993 save_CFLAGS="$CFLAGS"
41994
41995 ac_fn_c_check_func "$LINENO" "pthread_create" "ac_cv_func_pthread_create"
41996if test "x$ac_cv_func_pthread_create" = xyes; then :
41997 USE_THREADS_POSIX=1
41998fi
41999
42000
Elliott Hughesa93fb052018-12-12 14:22:48 -080042001 case $host in
42002 *-hp-hpux*)
42003 USE_THREADS_POSIX=""
42004 ;;
42005 *)
42006 ;;
42007 esac
42008
Elliott Hughes82be86d2017-09-20 17:00:17 -070042009 if test "$USE_THREADS_POSIX" != "1"
42010 then
42011 CFLAGS="$CFLAGS -pthread"
42012 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lpthread" >&5
42013$as_echo_n "checking for pthread_create in -lpthread... " >&6; }
42014if ${ac_cv_lib_pthread_pthread_create+:} false; then :
42015 $as_echo_n "(cached) " >&6
42016else
42017 ac_check_lib_save_LIBS=$LIBS
42018LIBS="-lpthread $LIBS"
42019cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42020/* end confdefs.h. */
42021
42022
42023#ifdef __cplusplus
42024extern "C"
42025#endif
42026char pthread_create ();
42027int main (void)
42028{
42029return pthread_create ();
42030 ;
42031 return 0;
42032}
42033_ACEOF
42034if ac_fn_c_try_link "$LINENO"; then :
42035 ac_cv_lib_pthread_pthread_create=yes
42036else
42037 ac_cv_lib_pthread_pthread_create=no
42038fi
42039rm -f core conftest.err conftest.$ac_objext \
42040 conftest$ac_exeext conftest.$ac_ext
42041LIBS=$ac_check_lib_save_LIBS
42042fi
42043{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_create" >&5
42044$as_echo "$ac_cv_lib_pthread_pthread_create" >&6; }
42045if test "x$ac_cv_lib_pthread_pthread_create" = xyes; then :
42046 USE_THREADS_POSIX=1
42047else
42048 CFLAGS="$save_CFLAGS"
42049fi
42050
42051 fi
42052
42053 if test "x$USE_THREADS_POSIX" = "x1"
42054 then
42055
42056$as_echo "#define USE_THREADS_POSIX 1" >>confdefs.h
42057
42058 curl_res_msg="POSIX threaded"
42059 fi
42060
42061fi
42062
42063
42064fi
42065
42066if test "$want_thres" = "yes" && test "x$USE_THREADS_POSIX" != "x1"; then
42067 if test "$want_pthreads" = "yes"; then
42068 as_fn_error $? "--enable-pthreads but pthreads was not found" "$LINENO" 5
42069 fi
42070 if test "$curl_cv_native_windows" = "yes"; then
42071 USE_THREADS_WIN32=1
42072
42073$as_echo "#define USE_THREADS_WIN32 1" >>confdefs.h
42074
42075 curl_res_msg="Win32 threaded"
42076 else
42077 as_fn_error $? "Threaded resolver enabled but no thread library found" "$LINENO" 5
42078 fi
42079fi
42080
42081{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable verbose strings" >&5
42082$as_echo_n "checking whether to enable verbose strings... " >&6; }
42083# Check whether --enable-verbose was given.
42084if test "${enable_verbose+set}" = set; then :
42085 enableval=$enable_verbose; case "$enableval" in
42086 no)
42087 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42088$as_echo "no" >&6; }
42089
42090$as_echo "#define CURL_DISABLE_VERBOSE_STRINGS 1" >>confdefs.h
42091
42092 curl_verbose_msg="no"
42093 ;;
42094 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42095$as_echo "yes" >&6; }
42096 ;;
42097 esac
42098else
42099 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42100$as_echo "yes" >&6; }
42101
42102fi
42103
42104
42105{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable SSPI support (Windows native builds only)" >&5
42106$as_echo_n "checking whether to enable SSPI support (Windows native builds only)... " >&6; }
42107# Check whether --enable-sspi was given.
42108if test "${enable_sspi+set}" = set; then :
42109 enableval=$enable_sspi; case "$enableval" in
42110 yes)
42111 if test "$curl_cv_native_windows" = "yes"; then
42112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42113$as_echo "yes" >&6; }
42114
42115$as_echo "#define USE_WINDOWS_SSPI 1" >>confdefs.h
42116
42117 USE_WINDOWS_SSPI=1
42118
42119 curl_sspi_msg="enabled"
42120 else
42121 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42122$as_echo "no" >&6; }
42123 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --enable-sspi Ignored. Only supported on native Windows builds." >&5
42124$as_echo "$as_me: WARNING: --enable-sspi Ignored. Only supported on native Windows builds." >&2;}
42125 fi
42126 ;;
42127 *)
42128 if test "x$WINSSL_ENABLED" = "x1"; then
42129 # --with-winssl implies --enable-sspi
42130 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42131$as_echo "yes" >&6; }
42132 else
42133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42134$as_echo "no" >&6; }
42135 fi
42136 ;;
42137 esac
42138else
42139 if test "x$WINSSL_ENABLED" = "x1"; then
42140 # --with-winssl implies --enable-sspi
42141 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42142$as_echo "yes" >&6; }
42143 else
42144 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42145$as_echo "no" >&6; }
42146 fi
42147
42148fi
42149
42150
42151{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable cryptographic authentication methods" >&5
42152$as_echo_n "checking whether to enable cryptographic authentication methods... " >&6; }
42153# Check whether --enable-crypto-auth was given.
42154if test "${enable_crypto_auth+set}" = set; then :
42155 enableval=$enable_crypto_auth; case "$enableval" in
42156 no)
42157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42158$as_echo "no" >&6; }
42159
42160$as_echo "#define CURL_DISABLE_CRYPTO_AUTH 1" >>confdefs.h
42161
42162 CURL_DISABLE_CRYPTO_AUTH=1
42163 ;;
42164 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42165$as_echo "yes" >&6; }
42166 ;;
42167 esac
42168else
42169 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42170$as_echo "yes" >&6; }
42171
42172fi
42173
42174
42175
42176 OPT_NTLM_WB="default"
42177 # Check whether --enable-ntlm-wb was given.
42178if test "${enable_ntlm_wb+set}" = set; then :
42179 enableval=$enable_ntlm_wb; OPT_NTLM_WB=$enableval
42180fi
42181
42182 want_ntlm_wb_file="/usr/bin/ntlm_auth"
42183 case "$OPT_NTLM_WB" in
42184 no)
42185 want_ntlm_wb="no"
42186 ;;
42187 default)
42188 want_ntlm_wb="yes"
42189 ;;
42190 *)
42191 want_ntlm_wb="yes"
42192 if test -n "$enableval" && test "$enableval" != "yes"; then
42193 want_ntlm_wb_file="$enableval"
42194 fi
42195 ;;
42196 esac
42197
42198
42199
42200 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable NTLM delegation to winbind's helper" >&5
42201$as_echo_n "checking whether to enable NTLM delegation to winbind's helper... " >&6; }
42202 if test "$curl_cv_native_windows" = "yes" ||
42203 test "x$SSL_ENABLED" = "x"; then
42204 want_ntlm_wb_file=""
42205 want_ntlm_wb="no"
42206 fi
42207 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $want_ntlm_wb" >&5
42208$as_echo "$want_ntlm_wb" >&6; }
42209 if test "$want_ntlm_wb" = "yes"; then
42210
42211$as_echo "#define NTLM_WB_ENABLED 1" >>confdefs.h
42212
42213
42214cat >>confdefs.h <<_ACEOF
42215#define NTLM_WB_FILE "$want_ntlm_wb_file"
42216_ACEOF
42217
42218 NTLM_WB_ENABLED=1
42219 fi
42220
42221
42222{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable TLS-SRP authentication" >&5
42223$as_echo_n "checking whether to enable TLS-SRP authentication... " >&6; }
42224# Check whether --enable-tls-srp was given.
42225if test "${enable_tls_srp+set}" = set; then :
42226 enableval=$enable_tls_srp; case "$enableval" in
42227 no)
42228 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42229$as_echo "no" >&6; }
Elliott Hughes82be86d2017-09-20 17:00:17 -070042230 want_tls_srp=no
42231 ;;
42232 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42233$as_echo "yes" >&6; }
42234 want_tls_srp=yes
42235 ;;
42236 esac
42237else
42238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42239$as_echo "yes" >&6; }
42240 want_tls_srp=yes
42241
42242fi
42243
42244
42245if test "$want_tls_srp" = "yes" && ( test "x$HAVE_GNUTLS_SRP" = "x1" || test "x$HAVE_OPENSSL_SRP" = "x1") ; then
42246
42247$as_echo "#define USE_TLS_SRP 1" >>confdefs.h
42248
42249 USE_TLS_SRP=1
42250 curl_tls_srp_msg="enabled"
42251fi
42252
42253{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable Unix domain sockets" >&5
42254$as_echo_n "checking whether to enable Unix domain sockets... " >&6; }
42255# Check whether --enable-unix-sockets was given.
42256if test "${enable_unix_sockets+set}" = set; then :
42257 enableval=$enable_unix_sockets; case "$enableval" in
42258 no) { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42259$as_echo "no" >&6; }
42260 want_unix_sockets=no
42261 ;;
42262 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42263$as_echo "yes" >&6; }
42264 want_unix_sockets=yes
42265 ;;
42266 esac
42267else
42268
42269 { $as_echo "$as_me:${as_lineno-$LINENO}: result: auto" >&5
42270$as_echo "auto" >&6; }
42271 want_unix_sockets=auto
42272
42273
42274fi
42275
42276if test "x$want_unix_sockets" != "xno"; then
42277 ac_fn_c_check_member "$LINENO" "struct sockaddr_un" "sun_path" "ac_cv_member_struct_sockaddr_un_sun_path" "
42278 #include <sys/un.h>
42279
42280"
42281if test "x$ac_cv_member_struct_sockaddr_un_sun_path" = xyes; then :
42282
42283
42284$as_echo "#define USE_UNIX_SOCKETS 1" >>confdefs.h
42285
42286 USE_UNIX_SOCKETS=1
42287
42288 curl_unix_sockets_msg="enabled"
42289
42290else
42291
42292 if test "x$want_unix_sockets" = "xyes"; then
42293 as_fn_error $? "--enable-unix-sockets is not available on this platform!" "$LINENO" 5
42294 fi
42295
42296fi
42297
42298fi
42299
Haibo Huang001784b2019-07-19 05:27:28 -070042300{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support cookies" >&5
42301$as_echo_n "checking whether to support cookies... " >&6; }
Elliott Hughes82be86d2017-09-20 17:00:17 -070042302# Check whether --enable-cookies was given.
42303if test "${enable_cookies+set}" = set; then :
42304 enableval=$enable_cookies; case "$enableval" in
42305 no)
42306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42307$as_echo "no" >&6; }
42308
42309$as_echo "#define CURL_DISABLE_COOKIES 1" >>confdefs.h
42310
42311 ;;
42312 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42313$as_echo "yes" >&6; }
42314 ;;
42315 esac
42316else
42317 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42318$as_echo "yes" >&6; }
42319
42320fi
42321
42322
Haibo Huang001784b2019-07-19 05:27:28 -070042323{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support HTTP authentication" >&5
42324$as_echo_n "checking whether to support HTTP authentication... " >&6; }
42325# Check whether --enable-http-auth was given.
42326if test "${enable_http_auth+set}" = set; then :
42327 enableval=$enable_http_auth; case "$enableval" in
42328 no)
42329 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42330$as_echo "no" >&6; }
42331
42332$as_echo "#define CURL_DISABLE_HTTP_AUTH 1" >>confdefs.h
42333
42334 ;;
42335 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42336$as_echo "yes" >&6; }
42337 ;;
42338 esac
42339else
42340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42341$as_echo "yes" >&6; }
42342
42343fi
42344
42345
42346{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support DoH" >&5
42347$as_echo_n "checking whether to support DoH... " >&6; }
42348# Check whether --enable-doh was given.
42349if test "${enable_doh+set}" = set; then :
42350 enableval=$enable_doh; case "$enableval" in
42351 no)
42352 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42353$as_echo "no" >&6; }
42354
42355$as_echo "#define CURL_DISABLE_DOH 1" >>confdefs.h
42356
42357 ;;
42358 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42359$as_echo "yes" >&6; }
42360 ;;
42361 esac
42362else
42363 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42364$as_echo "yes" >&6; }
42365
42366fi
42367
42368
42369{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support the MIME API" >&5
42370$as_echo_n "checking whether to support the MIME API... " >&6; }
42371# Check whether --enable-mime was given.
42372if test "${enable_mime+set}" = set; then :
42373 enableval=$enable_mime; case "$enableval" in
42374 no)
42375 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42376$as_echo "no" >&6; }
42377
42378$as_echo "#define CURL_DISABLE_MIME 1" >>confdefs.h
42379
42380 ;;
42381 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42382$as_echo "yes" >&6; }
42383 ;;
42384 esac
42385else
42386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42387$as_echo "yes" >&6; }
42388
42389fi
42390
42391
42392{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support date parsing" >&5
42393$as_echo_n "checking whether to support date parsing... " >&6; }
42394# Check whether --enable-dateparse was given.
42395if test "${enable_dateparse+set}" = set; then :
42396 enableval=$enable_dateparse; case "$enableval" in
42397 no)
42398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42399$as_echo "no" >&6; }
42400
42401$as_echo "#define CURL_DISABLE_PARSEDATE 1" >>confdefs.h
42402
42403 ;;
42404 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42405$as_echo "yes" >&6; }
42406 ;;
42407 esac
42408else
42409 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42410$as_echo "yes" >&6; }
42411
42412fi
42413
42414
42415{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support netrc parsing" >&5
42416$as_echo_n "checking whether to support netrc parsing... " >&6; }
42417# Check whether --enable-netrc was given.
42418if test "${enable_netrc+set}" = set; then :
42419 enableval=$enable_netrc; case "$enableval" in
42420 no)
42421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42422$as_echo "no" >&6; }
42423
42424$as_echo "#define CURL_DISABLE_NETRC 1" >>confdefs.h
42425
42426 ;;
42427 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42428$as_echo "yes" >&6; }
42429 ;;
42430 esac
42431else
42432 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42433$as_echo "yes" >&6; }
42434
42435fi
42436
42437
42438{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support progress-meter" >&5
42439$as_echo_n "checking whether to support progress-meter... " >&6; }
42440# Check whether --enable-progress-meter was given.
42441if test "${enable_progress_meter+set}" = set; then :
42442 enableval=$enable_progress_meter; case "$enableval" in
42443 no)
42444 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42445$as_echo "no" >&6; }
42446
42447$as_echo "#define CURL_DISABLE_PROGRESS_METER 1" >>confdefs.h
42448
42449 ;;
42450 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42451$as_echo "yes" >&6; }
42452 ;;
42453 esac
42454else
42455 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42456$as_echo "yes" >&6; }
42457
42458fi
42459
42460
42461{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support DNS shuffling" >&5
42462$as_echo_n "checking whether to support DNS shuffling... " >&6; }
42463# Check whether --enable-dnsshuffle was given.
42464if test "${enable_dnsshuffle+set}" = set; then :
42465 enableval=$enable_dnsshuffle; case "$enableval" in
42466 no)
42467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42468$as_echo "no" >&6; }
42469
42470$as_echo "#define CURL_DISABLE_SHUFFLE_DNS 1" >>confdefs.h
42471
42472 ;;
42473 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42474$as_echo "yes" >&6; }
42475 ;;
42476 esac
42477else
42478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42479$as_echo "yes" >&6; }
42480
42481fi
42482
42483
Haibo Huang65021c72019-03-27 15:37:23 -070042484curl_altsvc_msg="no (--enable-alt-svc)";
42485{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support alt-svc" >&5
42486$as_echo_n "checking whether to support alt-svc... " >&6; }
42487# Check whether --enable-alt-svc was given.
42488if test "${enable_alt_svc+set}" = set; then :
42489 enableval=$enable_alt_svc; case "$enableval" in
42490 no)
42491 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42492$as_echo "no" >&6; }
42493 ;;
42494 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42495$as_echo "yes" >&6; }
42496 curl_altsvc_msg="enabled";
42497 enable_altsvc="yes"
Haibo Huang65021c72019-03-27 15:37:23 -070042498 ;;
42499 esac
42500else
42501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42502$as_echo "no" >&6; }
42503
42504fi
42505
42506
42507if test "$enable_altsvc" = "yes"; then
42508
42509$as_echo "#define USE_ALTSVC 1" >>confdefs.h
42510
Haibo Huang445085a2019-09-11 13:33:50 -070042511 experimental="$experimental alt-svc"
Haibo Huang65021c72019-03-27 15:37:23 -070042512fi
42513
Haibo Huang31944072019-11-06 02:28:57 -080042514if test "x$want_esni" != "xno"; then
42515 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ESNI support is available" >&5
42516$as_echo_n "checking whether ESNI support is available... " >&6; }
42517
42518 ESNI_ENABLED=0
42519 ESNI_SUPPORT=''
42520
42521 if test "x$OPENSSL_ENABLED" == "x1"; then
42522 for ac_func in SSL_get_esni_status
42523do :
42524 ac_fn_c_check_func "$LINENO" "SSL_get_esni_status" "ac_cv_func_SSL_get_esni_status"
42525if test "x$ac_cv_func_SSL_get_esni_status" = xyes; then :
42526 cat >>confdefs.h <<_ACEOF
42527#define HAVE_SSL_GET_ESNI_STATUS 1
42528_ACEOF
42529 ESNI_SUPPORT="ESNI support available (OpenSSL with SSL_get_esni_status)"
42530 ESNI_ENABLED=1
42531fi
42532done
42533
42534
42535 fi
42536
42537 if test "x$ESNI_ENABLED" == "x1"; then
42538
42539$as_echo "#define USE_ESNI 1" >>confdefs.h
42540
42541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ESNI_SUPPORT" >&5
42542$as_echo "$ESNI_SUPPORT" >&6; }
42543 experimental="$experimental ESNI"
42544 else
42545 as_fn_error $? "--enable-esni ignored: No ESNI support found" "$LINENO" 5
42546 fi
42547fi
42548
Elliott Hughes82be86d2017-09-20 17:00:17 -070042549
42550 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether hiding of library internal symbols will actually happen" >&5
42551$as_echo_n "checking whether hiding of library internal symbols will actually happen... " >&6; }
42552 CFLAG_CURL_SYMBOL_HIDING=""
42553 doing_symbol_hiding="no"
42554 if test x"$curl_cv_native_windows" != "xyes" &&
42555 test "$want_symbol_hiding" = "yes" &&
42556 test "$supports_symbol_hiding" = "yes"; then
42557 doing_symbol_hiding="yes"
42558 CFLAG_CURL_SYMBOL_HIDING="$symbol_hiding_CFLAGS"
42559
42560cat >>confdefs.h <<_ACEOF
42561#define CURL_EXTERN_SYMBOL $symbol_hiding_EXTERN
42562_ACEOF
42563
42564 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
42565$as_echo "yes" >&6; }
42566 else
42567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42568$as_echo "no" >&6; }
42569 fi
42570 if test x$doing_symbol_hiding = xyes; then
42571 DOING_CURL_SYMBOL_HIDING_TRUE=
42572 DOING_CURL_SYMBOL_HIDING_FALSE='#'
42573else
42574 DOING_CURL_SYMBOL_HIDING_TRUE='#'
42575 DOING_CURL_SYMBOL_HIDING_FALSE=
42576fi
42577
42578
42579
42580
Elliott Hughes82be86d2017-09-20 17:00:17 -070042581LIBCURL_LIBS=$LIBS
42582
42583
42584
42585
42586
42587BLANK_AT_MAKETIME=
42588
42589
42590 if test x$cross_compiling = xyes; then
42591 CROSSCOMPILING_TRUE=
42592 CROSSCOMPILING_FALSE='#'
42593else
42594 CROSSCOMPILING_TRUE='#'
42595 CROSSCOMPILING_FALSE=
42596fi
42597
42598
42599ENABLE_SHARED="$enable_shared"
42600
42601
42602ENABLE_STATIC="$enable_static"
42603
42604
42605
42606
42607if test "x$OPENSSL_ENABLED" = "x1"; then
42608 SUPPORT_FEATURES="$SUPPORT_FEATURES SSL"
42609elif test -n "$SSL_ENABLED"; then
42610 SUPPORT_FEATURES="$SUPPORT_FEATURES SSL"
42611fi
42612if test "x$IPV6_ENABLED" = "x1"; then
42613 SUPPORT_FEATURES="$SUPPORT_FEATURES IPv6"
42614fi
42615if test "x$USE_UNIX_SOCKETS" = "x1"; then
42616 SUPPORT_FEATURES="$SUPPORT_FEATURES UnixSockets"
42617fi
42618if test "x$HAVE_LIBZ" = "x1"; then
42619 SUPPORT_FEATURES="$SUPPORT_FEATURES libz"
42620fi
Alex Deymo486467e2017-12-19 19:04:07 +010042621if test "x$HAVE_BROTLI" = "x1"; then
42622 SUPPORT_FEATURES="$SUPPORT_FEATURES brotli"
42623fi
Elliott Hughes82be86d2017-09-20 17:00:17 -070042624if test "x$USE_ARES" = "x1" -o "x$USE_THREADS_POSIX" = "x1" \
42625 -o "x$USE_THREADS_WIN32" = "x1"; then
42626 SUPPORT_FEATURES="$SUPPORT_FEATURES AsynchDNS"
42627fi
42628if test "x$IDN_ENABLED" = "x1"; then
42629 SUPPORT_FEATURES="$SUPPORT_FEATURES IDN"
42630fi
42631if test "x$USE_WINDOWS_SSPI" = "x1"; then
42632 SUPPORT_FEATURES="$SUPPORT_FEATURES SSPI"
42633fi
42634
42635if test "x$HAVE_GSSAPI" = "x1"; then
42636 SUPPORT_FEATURES="$SUPPORT_FEATURES GSS-API"
42637fi
42638
Haibo Huang65021c72019-03-27 15:37:23 -070042639if test "x$curl_psl_msg" = "xenabled"; then
Elliott Hughes82be86d2017-09-20 17:00:17 -070042640 SUPPORT_FEATURES="$SUPPORT_FEATURES PSL"
42641fi
42642
Haibo Huang65021c72019-03-27 15:37:23 -070042643if test "x$enable_altsvc" = "xyes"; then
42644 SUPPORT_FEATURES="$SUPPORT_FEATURES alt-svc"
42645fi
42646
Elliott Hughes82be86d2017-09-20 17:00:17 -070042647if test "x$CURL_DISABLE_CRYPTO_AUTH" != "x1" -a \
42648 \( "x$HAVE_GSSAPI" = "x1" -o "x$USE_WINDOWS_SSPI" = "x1" \); then
42649 SUPPORT_FEATURES="$SUPPORT_FEATURES SPNEGO"
42650fi
42651
42652if test "x$CURL_DISABLE_CRYPTO_AUTH" != "x1" -a \
42653 \( "x$HAVE_GSSAPI" = "x1" -o "x$USE_WINDOWS_SSPI" = "x1" \); then
42654 SUPPORT_FEATURES="$SUPPORT_FEATURES Kerberos"
42655fi
42656
42657if test "x$CURL_DISABLE_CRYPTO_AUTH" != "x1"; then
42658 if test "x$OPENSSL_ENABLED" = "x1" -o "x$USE_WINDOWS_SSPI" = "x1" \
42659 -o "x$GNUTLS_ENABLED" = "x1" -o "x$MBEDTLS_ENABLED" = "x1" \
Haibo Huang65021c72019-03-27 15:37:23 -070042660 -o "x$NSS_ENABLED" = "x1" -o "x$SECURETRANSPORT_ENABLED" = "x1"; then
Elliott Hughes82be86d2017-09-20 17:00:17 -070042661 SUPPORT_FEATURES="$SUPPORT_FEATURES NTLM"
42662
42663 if test "x$CURL_DISABLE_HTTP" != "x1" -a \
42664 "x$NTLM_WB_ENABLED" = "x1"; then
42665 SUPPORT_FEATURES="$SUPPORT_FEATURES NTLM_WB"
42666 fi
42667 fi
42668fi
42669
42670if test "x$USE_TLS_SRP" = "x1"; then
42671 SUPPORT_FEATURES="$SUPPORT_FEATURES TLS-SRP"
42672fi
42673
42674if test "x$USE_NGHTTP2" = "x1"; then
42675 SUPPORT_FEATURES="$SUPPORT_FEATURES HTTP2"
42676fi
42677
Haibo Huang445085a2019-09-11 13:33:50 -070042678if test "x$USE_NGTCP2" = "x1" -o "x$USE_QUICHE" = "x1"; then
42679 SUPPORT_FEATURES="$SUPPORT_FEATURES HTTP3"
42680fi
42681
Alex Deymo486467e2017-12-19 19:04:07 +010042682if test "x$CURL_WITH_MULTI_SSL" = "x1"; then
42683 SUPPORT_FEATURES="$SUPPORT_FEATURES MultiSSL"
42684fi
42685
Elliott Hughes82be86d2017-09-20 17:00:17 -070042686if test "x$OPENSSL_ENABLED" = "x1" -o "x$GNUTLS_ENABLED" = "x1" \
42687 -o "x$NSS_ENABLED" = "x1"; then
42688 SUPPORT_FEATURES="$SUPPORT_FEATURES HTTPS-proxy"
42689fi
42690
Haibo Huang31944072019-11-06 02:28:57 -080042691if test "x$ESNI_ENABLED" = "x1"; then
42692 SUPPORT_FEATURES="$SUPPORT_FEATURES ESNI"
42693fi
42694
Elliott Hughes82be86d2017-09-20 17:00:17 -070042695
42696
42697if test "x$CURL_DISABLE_HTTP" != "x1"; then
42698 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS HTTP"
42699 if test "x$SSL_ENABLED" = "x1"; then
42700 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS HTTPS"
42701 fi
42702fi
42703if test "x$CURL_DISABLE_FTP" != "x1"; then
42704 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS FTP"
42705 if test "x$SSL_ENABLED" = "x1"; then
42706 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS FTPS"
42707 fi
42708fi
42709if test "x$CURL_DISABLE_FILE" != "x1"; then
42710 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS FILE"
42711fi
42712if test "x$CURL_DISABLE_TELNET" != "x1"; then
42713 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS TELNET"
42714fi
42715if test "x$CURL_DISABLE_LDAP" != "x1"; then
42716 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS LDAP"
42717 if test "x$CURL_DISABLE_LDAPS" != "x1"; then
42718 if (test "x$USE_OPENLDAP" = "x1" && test "x$SSL_ENABLED" = "x1") ||
42719 (test "x$USE_OPENLDAP" != "x1" && test "x$HAVE_LDAP_SSL" = "x1"); then
42720 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS LDAPS"
42721 fi
42722 fi
42723fi
42724if test "x$CURL_DISABLE_DICT" != "x1"; then
42725 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS DICT"
42726fi
42727if test "x$CURL_DISABLE_TFTP" != "x1"; then
42728 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS TFTP"
42729fi
42730if test "x$CURL_DISABLE_GOPHER" != "x1"; then
42731 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS GOPHER"
42732fi
42733if test "x$CURL_DISABLE_POP3" != "x1"; then
42734 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS POP3"
42735 if test "x$SSL_ENABLED" = "x1"; then
42736 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS POP3S"
42737 fi
42738fi
42739if test "x$CURL_DISABLE_IMAP" != "x1"; then
42740 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS IMAP"
42741 if test "x$SSL_ENABLED" = "x1"; then
42742 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS IMAPS"
42743 fi
42744fi
42745if test "x$CURL_DISABLE_SMB" != "x1" \
42746 -a "x$CURL_DISABLE_CRYPTO_AUTH" != "x1" \
42747 -a \( "x$OPENSSL_ENABLED" = "x1" -o "x$USE_WINDOWS_SSPI" = "x1" \
42748 -o "x$GNUTLS_ENABLED" = "x1" -o "x$MBEDTLS_ENABLED" = "x1" \
Haibo Huang65021c72019-03-27 15:37:23 -070042749 -o "x$NSS_ENABLED" = "x1" -o "x$SECURETRANSPORT_ENABLED" = "x1" \); then
Elliott Hughes82be86d2017-09-20 17:00:17 -070042750 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS SMB"
42751 if test "x$SSL_ENABLED" = "x1"; then
42752 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS SMBS"
42753 fi
42754fi
42755if test "x$CURL_DISABLE_SMTP" != "x1"; then
42756 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS SMTP"
42757 if test "x$SSL_ENABLED" = "x1"; then
42758 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS SMTPS"
42759 fi
42760fi
42761if test "x$USE_LIBSSH2" = "x1"; then
42762 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS SCP"
42763 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS SFTP"
42764fi
Elliott Hughes0128fe42018-02-27 14:57:55 -080042765if test "x$USE_LIBSSH" = "x1"; then
42766 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS SCP"
42767 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS SFTP"
42768fi
Elliott Hughes82be86d2017-09-20 17:00:17 -070042769if test "x$CURL_DISABLE_RTSP" != "x1"; then
42770 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS RTSP"
42771fi
42772if test "x$USE_LIBRTMP" = "x1"; then
42773 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS RTMP"
42774fi
42775
42776SUPPORT_PROTOCOLS=`echo $SUPPORT_PROTOCOLS | tr ' ' '\012' | sort | tr '\012' ' '`
42777
42778
42779
42780
42781squeeze CFLAGS
42782squeeze CPPFLAGS
42783squeeze DEFS
42784squeeze LDFLAGS
42785squeeze LIBS
42786
42787squeeze LIBCURL_LIBS
42788squeeze CURL_NETWORK_LIBS
42789squeeze CURL_NETWORK_AND_TIME_LIBS
42790
42791squeeze SUPPORT_FEATURES
42792squeeze SUPPORT_PROTOCOLS
42793
42794
42795
42796 xc_bad_var_libs=no
42797 for xc_word in $LIBS; do
42798 case "$xc_word" in
42799 -l* | --library=*)
42800 :
42801 ;;
42802 *)
42803 xc_bad_var_libs=yes
42804 ;;
42805 esac
42806 done
42807 if test $xc_bad_var_libs = yes; then
42808 { $as_echo "$as_me:${as_lineno-$LINENO}: using LIBS: $LIBS" >&5
42809$as_echo "$as_me: using LIBS: $LIBS" >&6;}
42810 { $as_echo "$as_me:${as_lineno-$LINENO}: LIBS note: LIBS should only be used to specify libraries (-lname)." >&5
42811$as_echo "$as_me: LIBS note: LIBS should only be used to specify libraries (-lname)." >&6;}
42812 fi
42813
42814
42815 xc_bad_var_ldflags=no
42816 for xc_word in $LDFLAGS; do
42817 case "$xc_word" in
42818 -D*)
42819 xc_bad_var_ldflags=yes
42820 ;;
42821 -U*)
42822 xc_bad_var_ldflags=yes
42823 ;;
42824 -I*)
42825 xc_bad_var_ldflags=yes
42826 ;;
42827 -l* | --library=*)
42828 xc_bad_var_ldflags=yes
42829 ;;
42830 esac
42831 done
42832 if test $xc_bad_var_ldflags = yes; then
42833 { $as_echo "$as_me:${as_lineno-$LINENO}: using LDFLAGS: $LDFLAGS" >&5
42834$as_echo "$as_me: using LDFLAGS: $LDFLAGS" >&6;}
42835 xc_bad_var_msg="LDFLAGS note: LDFLAGS should only be used to specify linker flags, not"
42836 for xc_word in $LDFLAGS; do
42837 case "$xc_word" in
42838 -D*)
42839 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg macro definitions. Use CPPFLAGS for: $xc_word" >&5
42840$as_echo "$as_me: $xc_bad_var_msg macro definitions. Use CPPFLAGS for: $xc_word" >&6;}
42841 ;;
42842 -U*)
42843 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg macro suppressions. Use CPPFLAGS for: $xc_word" >&5
42844$as_echo "$as_me: $xc_bad_var_msg macro suppressions. Use CPPFLAGS for: $xc_word" >&6;}
42845 ;;
42846 -I*)
42847 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg include directories. Use CPPFLAGS for: $xc_word" >&5
42848$as_echo "$as_me: $xc_bad_var_msg include directories. Use CPPFLAGS for: $xc_word" >&6;}
42849 ;;
42850 -l* | --library=*)
42851 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg libraries. Use LIBS for: $xc_word" >&5
42852$as_echo "$as_me: $xc_bad_var_msg libraries. Use LIBS for: $xc_word" >&6;}
42853 ;;
42854 esac
42855 done
42856 fi
42857
42858
42859 xc_bad_var_cppflags=no
42860 for xc_word in $CPPFLAGS; do
42861 case "$xc_word" in
42862 -rpath*)
42863 xc_bad_var_cppflags=yes
42864 ;;
42865 -L* | --library-path=*)
42866 xc_bad_var_cppflags=yes
42867 ;;
42868 -l* | --library=*)
42869 xc_bad_var_cppflags=yes
42870 ;;
42871 esac
42872 done
42873 if test $xc_bad_var_cppflags = yes; then
42874 { $as_echo "$as_me:${as_lineno-$LINENO}: using CPPFLAGS: $CPPFLAGS" >&5
42875$as_echo "$as_me: using CPPFLAGS: $CPPFLAGS" >&6;}
42876 xc_bad_var_msg="CPPFLAGS note: CPPFLAGS should only be used to specify C preprocessor flags, not"
42877 for xc_word in $CPPFLAGS; do
42878 case "$xc_word" in
42879 -rpath*)
42880 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg library runtime directories. Use LDFLAGS for: $xc_word" >&5
42881$as_echo "$as_me: $xc_bad_var_msg library runtime directories. Use LDFLAGS for: $xc_word" >&6;}
42882 ;;
42883 -L* | --library-path=*)
42884 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg library directories. Use LDFLAGS for: $xc_word" >&5
42885$as_echo "$as_me: $xc_bad_var_msg library directories. Use LDFLAGS for: $xc_word" >&6;}
42886 ;;
42887 -l* | --library=*)
42888 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg libraries. Use LIBS for: $xc_word" >&5
42889$as_echo "$as_me: $xc_bad_var_msg libraries. Use LIBS for: $xc_word" >&6;}
42890 ;;
42891 esac
42892 done
42893 fi
42894
42895
42896 xc_bad_var_cflags=no
42897 for xc_word in $CFLAGS; do
42898 case "$xc_word" in
42899 -D*)
42900 xc_bad_var_cflags=yes
42901 ;;
42902 -U*)
42903 xc_bad_var_cflags=yes
42904 ;;
42905 -I*)
42906 xc_bad_var_cflags=yes
42907 ;;
42908 -rpath*)
42909 xc_bad_var_cflags=yes
42910 ;;
42911 -L* | --library-path=*)
42912 xc_bad_var_cflags=yes
42913 ;;
42914 -l* | --library=*)
42915 xc_bad_var_cflags=yes
42916 ;;
42917 esac
42918 done
42919 if test $xc_bad_var_cflags = yes; then
42920 { $as_echo "$as_me:${as_lineno-$LINENO}: using CFLAGS: $CFLAGS" >&5
42921$as_echo "$as_me: using CFLAGS: $CFLAGS" >&6;}
42922 xc_bad_var_msg="CFLAGS note: CFLAGS should only be used to specify C compiler flags, not"
42923 for xc_word in $CFLAGS; do
42924 case "$xc_word" in
42925 -D*)
42926 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg macro definitions. Use CPPFLAGS for: $xc_word" >&5
42927$as_echo "$as_me: $xc_bad_var_msg macro definitions. Use CPPFLAGS for: $xc_word" >&6;}
42928 ;;
42929 -U*)
42930 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg macro suppressions. Use CPPFLAGS for: $xc_word" >&5
42931$as_echo "$as_me: $xc_bad_var_msg macro suppressions. Use CPPFLAGS for: $xc_word" >&6;}
42932 ;;
42933 -I*)
42934 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg include directories. Use CPPFLAGS for: $xc_word" >&5
42935$as_echo "$as_me: $xc_bad_var_msg include directories. Use CPPFLAGS for: $xc_word" >&6;}
42936 ;;
42937 -rpath*)
42938 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg library runtime directories. Use LDFLAGS for: $xc_word" >&5
42939$as_echo "$as_me: $xc_bad_var_msg library runtime directories. Use LDFLAGS for: $xc_word" >&6;}
42940 ;;
42941 -L* | --library-path=*)
42942 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg library directories. Use LDFLAGS for: $xc_word" >&5
42943$as_echo "$as_me: $xc_bad_var_msg library directories. Use LDFLAGS for: $xc_word" >&6;}
42944 ;;
42945 -l* | --library=*)
42946 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg libraries. Use LIBS for: $xc_word" >&5
42947$as_echo "$as_me: $xc_bad_var_msg libraries. Use LIBS for: $xc_word" >&6;}
42948 ;;
42949 esac
42950 done
42951 fi
42952
42953 if test $xc_bad_var_libs = yes ||
42954 test $xc_bad_var_cflags = yes ||
42955 test $xc_bad_var_ldflags = yes ||
42956 test $xc_bad_var_cppflags = yes; then
42957 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Continuing even with errors mentioned immediately above this line." >&5
42958$as_echo "$as_me: WARNING: Continuing even with errors mentioned immediately above this line." >&2;}
42959 fi
42960
42961
Elliott Hughes0128fe42018-02-27 14:57:55 -080042962SSL_BACKENDS=${ssl_backends}
42963
42964
Elliott Hughes82be86d2017-09-20 17:00:17 -070042965if test "x$want_curldebug_assumed" = "xyes" &&
42966 test "x$want_curldebug" = "xyes" && test "x$USE_ARES" = "x1"; then
42967 ac_configure_args="$ac_configure_args --enable-curldebug"
42968fi
42969
Haibo Huang21926d52019-01-08 14:27:10 -080042970ac_config_files="$ac_config_files Makefile docs/Makefile docs/examples/Makefile docs/libcurl/Makefile docs/libcurl/opts/Makefile docs/cmdline-opts/Makefile include/Makefile include/curl/Makefile src/Makefile lib/Makefile scripts/Makefile lib/libcurl.vers tests/Makefile tests/certs/Makefile tests/certs/scripts/Makefile tests/data/Makefile tests/server/Makefile tests/libtest/Makefile tests/unit/Makefile packages/Makefile packages/vms/Makefile curl-config libcurl.pc"
Elliott Hughes82be86d2017-09-20 17:00:17 -070042971
42972cat >confcache <<\_ACEOF
42973# This file is a shell script that caches the results of configure
42974# tests run on this system so they can be shared between configure
42975# scripts and configure runs, see configure's option --config-cache.
42976# It is not useful on other systems. If it contains results you don't
42977# want to keep, you may remove or edit it.
42978#
42979# config.status only pays attention to the cache file if you give it
42980# the --recheck option to rerun configure.
42981#
42982# `ac_cv_env_foo' variables (set or unset) will be overridden when
42983# loading this file, other *unset* `ac_cv_foo' will be assigned the
42984# following values.
42985
42986_ACEOF
42987
42988# The following way of writing the cache mishandles newlines in values,
42989# but we know of no workaround that is simple, portable, and efficient.
42990# So, we kill variables containing newlines.
42991# Ultrix sh set writes to stderr and can't be redirected directly,
42992# and sets the high bit in the cache file unless we assign to the vars.
42993(
42994 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
42995 eval ac_val=\$$ac_var
42996 case $ac_val in #(
42997 *${as_nl}*)
42998 case $ac_var in #(
42999 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
43000$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
43001 esac
43002 case $ac_var in #(
43003 _ | IFS | as_nl) ;; #(
43004 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
43005 *) { eval $ac_var=; unset $ac_var;} ;;
43006 esac ;;
43007 esac
43008 done
43009
43010 (set) 2>&1 |
43011 case $as_nl`(ac_space=' '; set) 2>&1` in #(
43012 *${as_nl}ac_space=\ *)
43013 # `set' does not quote correctly, so add quotes: double-quote
43014 # substitution turns \\\\ into \\, and sed turns \\ into \.
43015 sed -n \
43016 "s/'/'\\\\''/g;
43017 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
43018 ;; #(
43019 *)
43020 # `set' quotes correctly as required by POSIX, so do not add quotes.
43021 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
43022 ;;
43023 esac |
43024 sort
43025) |
43026 sed '
43027 /^ac_cv_env_/b end
43028 t clear
43029 :clear
43030 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
43031 t end
43032 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
43033 :end' >>confcache
43034if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
43035 if test -w "$cache_file"; then
43036 if test "x$cache_file" != "x/dev/null"; then
43037 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
43038$as_echo "$as_me: updating cache $cache_file" >&6;}
43039 if test ! -f "$cache_file" || test -h "$cache_file"; then
43040 cat confcache >"$cache_file"
43041 else
43042 case $cache_file in #(
43043 */* | ?:*)
43044 mv -f confcache "$cache_file"$$ &&
43045 mv -f "$cache_file"$$ "$cache_file" ;; #(
43046 *)
43047 mv -f confcache "$cache_file" ;;
43048 esac
43049 fi
43050 fi
43051 else
43052 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
43053$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
43054 fi
43055fi
43056rm -f confcache
43057
43058test "x$prefix" = xNONE && prefix=$ac_default_prefix
43059# Let make expand exec_prefix.
43060test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
43061
43062DEFS=-DHAVE_CONFIG_H
43063
43064ac_libobjs=
43065ac_ltlibobjs=
43066U=
43067for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
43068 # 1. Remove the extension, and $U if already installed.
43069 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
43070 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
43071 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
43072 # will be set to the directory where LIBOBJS objects are built.
43073 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
43074 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
43075done
43076LIBOBJS=$ac_libobjs
43077
43078LTLIBOBJS=$ac_ltlibobjs
43079
43080
43081if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
43082 as_fn_error $? "conditional \"MAINTAINER_MODE\" was never defined.
43083Usually this means the macro was only invoked conditionally." "$LINENO" 5
43084fi
Elliott Hughes82be86d2017-09-20 17:00:17 -070043085{ $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5
43086$as_echo_n "checking that generated files are newer than configure... " >&6; }
43087 if test -n "$am_sleep_pid"; then
43088 # Hide warnings about reused PIDs.
43089 wait $am_sleep_pid 2>/dev/null
43090 fi
43091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5
43092$as_echo "done" >&6; }
43093if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
43094 as_fn_error $? "conditional \"AMDEP\" was never defined.
43095Usually this means the macro was only invoked conditionally." "$LINENO" 5
43096fi
43097if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
43098 as_fn_error $? "conditional \"am__fastdepCC\" was never defined.
43099Usually this means the macro was only invoked conditionally." "$LINENO" 5
43100fi
43101 if test -n "$EXEEXT"; then
43102 am__EXEEXT_TRUE=
43103 am__EXEEXT_FALSE='#'
43104else
43105 am__EXEEXT_TRUE='#'
43106 am__EXEEXT_FALSE=
43107fi
43108
43109if test -z "${CURL_LT_SHLIB_USE_VERSION_INFO_TRUE}" && test -z "${CURL_LT_SHLIB_USE_VERSION_INFO_FALSE}"; then
43110 as_fn_error $? "conditional \"CURL_LT_SHLIB_USE_VERSION_INFO\" was never defined.
43111Usually this means the macro was only invoked conditionally." "$LINENO" 5
43112fi
43113if test -z "${CURL_LT_SHLIB_USE_NO_UNDEFINED_TRUE}" && test -z "${CURL_LT_SHLIB_USE_NO_UNDEFINED_FALSE}"; then
43114 as_fn_error $? "conditional \"CURL_LT_SHLIB_USE_NO_UNDEFINED\" was never defined.
43115Usually this means the macro was only invoked conditionally." "$LINENO" 5
43116fi
43117if test -z "${CURL_LT_SHLIB_USE_MIMPURE_TEXT_TRUE}" && test -z "${CURL_LT_SHLIB_USE_MIMPURE_TEXT_FALSE}"; then
43118 as_fn_error $? "conditional \"CURL_LT_SHLIB_USE_MIMPURE_TEXT\" was never defined.
43119Usually this means the macro was only invoked conditionally." "$LINENO" 5
43120fi
43121if test -z "${USE_CPPFLAG_CURL_STATICLIB_TRUE}" && test -z "${USE_CPPFLAG_CURL_STATICLIB_FALSE}"; then
43122 as_fn_error $? "conditional \"USE_CPPFLAG_CURL_STATICLIB\" was never defined.
43123Usually this means the macro was only invoked conditionally." "$LINENO" 5
43124fi
43125if test -z "${USE_EXPLICIT_LIB_DEPS_TRUE}" && test -z "${USE_EXPLICIT_LIB_DEPS_FALSE}"; then
43126 as_fn_error $? "conditional \"USE_EXPLICIT_LIB_DEPS\" was never defined.
43127Usually this means the macro was only invoked conditionally." "$LINENO" 5
43128fi
43129if test -z "${CURLDEBUG_TRUE}" && test -z "${CURLDEBUG_FALSE}"; then
43130 as_fn_error $? "conditional \"CURLDEBUG\" was never defined.
43131Usually this means the macro was only invoked conditionally." "$LINENO" 5
43132fi
43133if test -z "${BUILD_UNITTESTS_TRUE}" && test -z "${BUILD_UNITTESTS_FALSE}"; then
43134 as_fn_error $? "conditional \"BUILD_UNITTESTS\" was never defined.
43135Usually this means the macro was only invoked conditionally." "$LINENO" 5
43136fi
43137if test -z "${DOING_NATIVE_WINDOWS_TRUE}" && test -z "${DOING_NATIVE_WINDOWS_FALSE}"; then
43138 as_fn_error $? "conditional \"DOING_NATIVE_WINDOWS\" was never defined.
43139Usually this means the macro was only invoked conditionally." "$LINENO" 5
43140fi
43141if test -z "${HAVE_LIBZ_TRUE}" && test -z "${HAVE_LIBZ_FALSE}"; then
43142 as_fn_error $? "conditional \"HAVE_LIBZ\" was never defined.
43143Usually this means the macro was only invoked conditionally." "$LINENO" 5
43144fi
Alex Deymo486467e2017-12-19 19:04:07 +010043145if test -z "${BUILD_STUB_GSS_TRUE}" && test -z "${BUILD_STUB_GSS_FALSE}"; then
43146 as_fn_error $? "conditional \"BUILD_STUB_GSS\" was never defined.
43147Usually this means the macro was only invoked conditionally." "$LINENO" 5
43148fi
Elliott Hughes82be86d2017-09-20 17:00:17 -070043149if test -z "${USE_LIBPSL_TRUE}" && test -z "${USE_LIBPSL_FALSE}"; then
43150 as_fn_error $? "conditional \"USE_LIBPSL\" was never defined.
43151Usually this means the macro was only invoked conditionally." "$LINENO" 5
43152fi
43153if test -z "${CURL_LT_SHLIB_USE_VERSIONED_SYMBOLS_TRUE}" && test -z "${CURL_LT_SHLIB_USE_VERSIONED_SYMBOLS_FALSE}"; then
43154 as_fn_error $? "conditional \"CURL_LT_SHLIB_USE_VERSIONED_SYMBOLS\" was never defined.
43155Usually this means the macro was only invoked conditionally." "$LINENO" 5
43156fi
43157if test -z "${USE_MANUAL_TRUE}" && test -z "${USE_MANUAL_FALSE}"; then
43158 as_fn_error $? "conditional \"USE_MANUAL\" was never defined.
43159Usually this means the macro was only invoked conditionally." "$LINENO" 5
43160fi
43161if test -z "${USE_EMBEDDED_ARES_TRUE}" && test -z "${USE_EMBEDDED_ARES_FALSE}"; then
43162 as_fn_error $? "conditional \"USE_EMBEDDED_ARES\" was never defined.
43163Usually this means the macro was only invoked conditionally." "$LINENO" 5
43164fi
43165if test -z "${BUILD_LIBHOSTNAME_TRUE}" && test -z "${BUILD_LIBHOSTNAME_FALSE}"; then
43166 as_fn_error $? "conditional \"BUILD_LIBHOSTNAME\" was never defined.
43167Usually this means the macro was only invoked conditionally." "$LINENO" 5
43168fi
43169if test -z "${DOING_CURL_SYMBOL_HIDING_TRUE}" && test -z "${DOING_CURL_SYMBOL_HIDING_FALSE}"; then
43170 as_fn_error $? "conditional \"DOING_CURL_SYMBOL_HIDING\" was never defined.
43171Usually this means the macro was only invoked conditionally." "$LINENO" 5
43172fi
Elliott Hughes82be86d2017-09-20 17:00:17 -070043173if test -z "${CROSSCOMPILING_TRUE}" && test -z "${CROSSCOMPILING_FALSE}"; then
43174 as_fn_error $? "conditional \"CROSSCOMPILING\" was never defined.
43175Usually this means the macro was only invoked conditionally." "$LINENO" 5
43176fi
43177
43178: "${CONFIG_STATUS=./config.status}"
43179ac_write_fail=0
43180ac_clean_files_save=$ac_clean_files
43181ac_clean_files="$ac_clean_files $CONFIG_STATUS"
43182{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
43183$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
43184as_write_fail=0
43185cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
43186#! $SHELL
43187# Generated by $as_me.
43188# Run this file to recreate the current configuration.
43189# Compiler output produced by configure, useful for debugging
43190# configure, is in config.log if it exists.
43191
43192debug=false
43193ac_cs_recheck=false
43194ac_cs_silent=false
43195
43196SHELL=\${CONFIG_SHELL-$SHELL}
43197export SHELL
43198_ASEOF
43199cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
43200## -------------------- ##
43201## M4sh Initialization. ##
43202## -------------------- ##
43203
43204# Be more Bourne compatible
43205DUALCASE=1; export DUALCASE # for MKS sh
43206if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
43207 emulate sh
43208 NULLCMD=:
43209 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
43210 # is contrary to our usage. Disable this feature.
43211 alias -g '${1+"$@"}'='"$@"'
43212 setopt NO_GLOB_SUBST
43213else
43214 case `(set -o) 2>/dev/null` in #(
43215 *posix*) :
43216 set -o posix ;; #(
43217 *) :
43218 ;;
43219esac
43220fi
43221
43222
43223as_nl='
43224'
43225export as_nl
43226# Printing a long string crashes Solaris 7 /usr/bin/printf.
43227as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
43228as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
43229as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
43230# Prefer a ksh shell builtin over an external printf program on Solaris,
43231# but without wasting forks for bash or zsh.
43232if test -z "$BASH_VERSION$ZSH_VERSION" \
43233 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
43234 as_echo='print -r --'
43235 as_echo_n='print -rn --'
43236elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
43237 as_echo='printf %s\n'
43238 as_echo_n='printf %s'
43239else
43240 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
43241 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
43242 as_echo_n='/usr/ucb/echo -n'
43243 else
43244 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
43245 as_echo_n_body='eval
43246 arg=$1;
43247 case $arg in #(
43248 *"$as_nl"*)
43249 expr "X$arg" : "X\\(.*\\)$as_nl";
43250 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
43251 esac;
43252 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
43253 '
43254 export as_echo_n_body
43255 as_echo_n='sh -c $as_echo_n_body as_echo'
43256 fi
43257 export as_echo_body
43258 as_echo='sh -c $as_echo_body as_echo'
43259fi
43260
43261
43262
43263# IFS
43264# We need space, tab and new line, in precisely that order. Quoting is
43265# there to prevent editors from complaining about space-tab.
43266# (If _AS_PATH_WALK were called with IFS unset, it would disable word
43267# splitting by setting IFS to empty value.)
43268IFS=" "" $as_nl"
43269
43270# Find who we are. Look in the path if we contain no directory separator.
43271as_myself=
43272case $0 in #((
43273 *[\\/]* ) as_myself=$0 ;;
43274 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
43275for as_dir in $PATH
43276do
43277 IFS=$as_save_IFS
43278 test -z "$as_dir" && as_dir=.
43279 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
43280 done
43281IFS=$as_save_IFS
43282
43283 ;;
43284esac
43285# We did not find ourselves, most probably we were run as `sh COMMAND'
43286# in which case we are not to be found in the path.
43287if test "x$as_myself" = x; then
43288 as_myself=$0
43289fi
43290if test ! -f "$as_myself"; then
43291 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
43292 exit 1
43293fi
43294
43295# Unset variables that we do not need and which cause bugs (e.g. in
43296# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
43297# suppresses any "Segmentation fault" message there. '((' could
43298# trigger a bug in pdksh 5.2.14.
43299for as_var in BASH_ENV ENV MAIL MAILPATH
43300do eval test x\${$as_var+set} = xset \
43301 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
43302done
43303PS1='$ '
43304PS2='> '
43305PS4='+ '
43306
43307# NLS nuisances.
43308LC_ALL=C
43309export LC_ALL
43310LANGUAGE=C
43311export LANGUAGE
43312
43313# CDPATH.
43314(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
43315
43316
43317# as_fn_error STATUS ERROR [LINENO LOG_FD]
43318# ----------------------------------------
43319# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
43320# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
43321# script with STATUS, using 1 if that was 0.
43322as_fn_error ()
43323{
43324 as_status=$1; test $as_status -eq 0 && as_status=1
43325 if test "$4"; then
43326 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
43327 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
43328 fi
43329 $as_echo "$as_me: error: $2" >&2
43330 as_fn_exit $as_status
43331} # as_fn_error
43332
43333
43334# as_fn_set_status STATUS
43335# -----------------------
43336# Set $? to STATUS, without forking.
43337as_fn_set_status ()
43338{
43339 return $1
43340} # as_fn_set_status
43341
43342# as_fn_exit STATUS
43343# -----------------
43344# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
43345as_fn_exit ()
43346{
43347 set +e
43348 as_fn_set_status $1
43349 exit $1
43350} # as_fn_exit
43351
43352# as_fn_unset VAR
43353# ---------------
43354# Portably unset VAR.
43355as_fn_unset ()
43356{
43357 { eval $1=; unset $1;}
43358}
43359as_unset=as_fn_unset
43360# as_fn_append VAR VALUE
43361# ----------------------
43362# Append the text in VALUE to the end of the definition contained in VAR. Take
43363# advantage of any shell optimizations that allow amortized linear growth over
43364# repeated appends, instead of the typical quadratic growth present in naive
43365# implementations.
43366if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
43367 eval 'as_fn_append ()
43368 {
43369 eval $1+=\$2
43370 }'
43371else
43372 as_fn_append ()
43373 {
43374 eval $1=\$$1\$2
43375 }
43376fi # as_fn_append
43377
43378# as_fn_arith ARG...
43379# ------------------
43380# Perform arithmetic evaluation on the ARGs, and store the result in the
43381# global $as_val. Take advantage of shells that can avoid forks. The arguments
43382# must be portable across $(()) and expr.
43383if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
43384 eval 'as_fn_arith ()
43385 {
43386 as_val=$(( $* ))
43387 }'
43388else
43389 as_fn_arith ()
43390 {
43391 as_val=`expr "$@" || test $? -eq 1`
43392 }
43393fi # as_fn_arith
43394
43395
43396if expr a : '\(a\)' >/dev/null 2>&1 &&
43397 test "X`expr 00001 : '.*\(...\)'`" = X001; then
43398 as_expr=expr
43399else
43400 as_expr=false
43401fi
43402
43403if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
43404 as_basename=basename
43405else
43406 as_basename=false
43407fi
43408
43409if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
43410 as_dirname=dirname
43411else
43412 as_dirname=false
43413fi
43414
43415as_me=`$as_basename -- "$0" ||
43416$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
43417 X"$0" : 'X\(//\)$' \| \
43418 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
43419$as_echo X/"$0" |
43420 sed '/^.*\/\([^/][^/]*\)\/*$/{
43421 s//\1/
43422 q
43423 }
43424 /^X\/\(\/\/\)$/{
43425 s//\1/
43426 q
43427 }
43428 /^X\/\(\/\).*/{
43429 s//\1/
43430 q
43431 }
43432 s/.*/./; q'`
43433
43434# Avoid depending upon Character Ranges.
43435as_cr_letters='abcdefghijklmnopqrstuvwxyz'
43436as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
43437as_cr_Letters=$as_cr_letters$as_cr_LETTERS
43438as_cr_digits='0123456789'
43439as_cr_alnum=$as_cr_Letters$as_cr_digits
43440
43441ECHO_C= ECHO_N= ECHO_T=
43442case `echo -n x` in #(((((
43443-n*)
43444 case `echo 'xy\c'` in
43445 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
43446 xy) ECHO_C='\c';;
43447 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
43448 ECHO_T=' ';;
43449 esac;;
43450*)
43451 ECHO_N='-n';;
43452esac
43453
43454rm -f conf$$ conf$$.exe conf$$.file
43455if test -d conf$$.dir; then
43456 rm -f conf$$.dir/conf$$.file
43457else
43458 rm -f conf$$.dir
43459 mkdir conf$$.dir 2>/dev/null
43460fi
43461if (echo >conf$$.file) 2>/dev/null; then
43462 if ln -s conf$$.file conf$$ 2>/dev/null; then
43463 as_ln_s='ln -s'
43464 # ... but there are two gotchas:
43465 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
43466 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
43467 # In both cases, we have to default to `cp -pR'.
43468 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
43469 as_ln_s='cp -pR'
43470 elif ln conf$$.file conf$$ 2>/dev/null; then
43471 as_ln_s=ln
43472 else
43473 as_ln_s='cp -pR'
43474 fi
43475else
43476 as_ln_s='cp -pR'
43477fi
43478rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
43479rmdir conf$$.dir 2>/dev/null
43480
43481
43482# as_fn_mkdir_p
43483# -------------
43484# Create "$as_dir" as a directory, including parents if necessary.
43485as_fn_mkdir_p ()
43486{
43487
43488 case $as_dir in #(
43489 -*) as_dir=./$as_dir;;
43490 esac
43491 test -d "$as_dir" || eval $as_mkdir_p || {
43492 as_dirs=
43493 while :; do
43494 case $as_dir in #(
43495 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
43496 *) as_qdir=$as_dir;;
43497 esac
43498 as_dirs="'$as_qdir' $as_dirs"
43499 as_dir=`$as_dirname -- "$as_dir" ||
43500$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
43501 X"$as_dir" : 'X\(//\)[^/]' \| \
43502 X"$as_dir" : 'X\(//\)$' \| \
43503 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
43504$as_echo X"$as_dir" |
43505 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
43506 s//\1/
43507 q
43508 }
43509 /^X\(\/\/\)[^/].*/{
43510 s//\1/
43511 q
43512 }
43513 /^X\(\/\/\)$/{
43514 s//\1/
43515 q
43516 }
43517 /^X\(\/\).*/{
43518 s//\1/
43519 q
43520 }
43521 s/.*/./; q'`
43522 test -d "$as_dir" && break
43523 done
43524 test -z "$as_dirs" || eval "mkdir $as_dirs"
43525 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
43526
43527
43528} # as_fn_mkdir_p
43529if mkdir -p . 2>/dev/null; then
43530 as_mkdir_p='mkdir -p "$as_dir"'
43531else
43532 test -d ./-p && rmdir ./-p
43533 as_mkdir_p=false
43534fi
43535
43536
43537# as_fn_executable_p FILE
43538# -----------------------
43539# Test if FILE is an executable regular file.
43540as_fn_executable_p ()
43541{
43542 test -f "$1" && test -x "$1"
43543} # as_fn_executable_p
43544as_test_x='test -x'
43545as_executable_p=as_fn_executable_p
43546
43547# Sed expression to map a string onto a valid CPP name.
43548as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
43549
43550# Sed expression to map a string onto a valid variable name.
43551as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
43552
43553
43554exec 6>&1
43555## ----------------------------------- ##
43556## Main body of $CONFIG_STATUS script. ##
43557## ----------------------------------- ##
43558_ASEOF
43559test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
43560
43561cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
43562# Save the log message, to keep $0 and so on meaningful, and to
43563# report actual input values of CONFIG_FILES etc. instead of their
43564# values after options handling.
43565ac_log="
43566This file was extended by curl $as_me -, which was
43567generated by GNU Autoconf 2.69. Invocation command line was
43568
43569 CONFIG_FILES = $CONFIG_FILES
43570 CONFIG_HEADERS = $CONFIG_HEADERS
43571 CONFIG_LINKS = $CONFIG_LINKS
43572 CONFIG_COMMANDS = $CONFIG_COMMANDS
43573 $ $0 $@
43574
43575on `(hostname || uname -n) 2>/dev/null | sed 1q`
43576"
43577
43578_ACEOF
43579
43580case $ac_config_files in *"
43581"*) set x $ac_config_files; shift; ac_config_files=$*;;
43582esac
43583
43584case $ac_config_headers in *"
43585"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
43586esac
43587
43588
43589cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
43590# Files that config.status was made for.
43591config_files="$ac_config_files"
43592config_headers="$ac_config_headers"
43593config_commands="$ac_config_commands"
43594
43595_ACEOF
43596
43597cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
43598ac_cs_usage="\
43599\`$as_me' instantiates files and other configuration actions
43600from templates according to the current configuration. Unless the files
43601and actions are specified as TAGs, all are instantiated by default.
43602
43603Usage: $0 [OPTION]... [TAG]...
43604
43605 -h, --help print this help, then exit
43606 -V, --version print version number and configuration settings, then exit
43607 --config print configuration, then exit
43608 -q, --quiet, --silent
43609 do not print progress messages
43610 -d, --debug don't remove temporary files
43611 --recheck update $as_me by reconfiguring in the same conditions
43612 --file=FILE[:TEMPLATE]
43613 instantiate the configuration file FILE
43614 --header=FILE[:TEMPLATE]
43615 instantiate the configuration header FILE
43616
43617Configuration files:
43618$config_files
43619
43620Configuration headers:
43621$config_headers
43622
43623Configuration commands:
43624$config_commands
43625
43626Report bugs to <a suitable curl mailing list: https://curl.haxx.se/mail/>."
43627
43628_ACEOF
43629cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
43630ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
43631ac_cs_version="\\
43632curl config.status -
43633configured by $0, generated by GNU Autoconf 2.69,
43634 with options \\"\$ac_cs_config\\"
43635
43636Copyright (C) 2012 Free Software Foundation, Inc.
43637This config.status script is free software; the Free Software Foundation
43638gives unlimited permission to copy, distribute and modify it."
43639
43640ac_pwd='$ac_pwd'
43641srcdir='$srcdir'
43642INSTALL='$INSTALL'
43643MKDIR_P='$MKDIR_P'
43644AWK='$AWK'
43645test -n "\$AWK" || AWK=awk
43646_ACEOF
43647
43648cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
43649# The default lists apply if the user does not specify any file.
43650ac_need_defaults=:
43651while test $# != 0
43652do
43653 case $1 in
43654 --*=?*)
43655 ac_option=`expr "X$1" : 'X\([^=]*\)='`
43656 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
43657 ac_shift=:
43658 ;;
43659 --*=)
43660 ac_option=`expr "X$1" : 'X\([^=]*\)='`
43661 ac_optarg=
43662 ac_shift=:
43663 ;;
43664 *)
43665 ac_option=$1
43666 ac_optarg=$2
43667 ac_shift=shift
43668 ;;
43669 esac
43670
43671 case $ac_option in
43672 # Handling of the options.
43673 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
43674 ac_cs_recheck=: ;;
43675 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
43676 $as_echo "$ac_cs_version"; exit ;;
43677 --config | --confi | --conf | --con | --co | --c )
43678 $as_echo "$ac_cs_config"; exit ;;
43679 --debug | --debu | --deb | --de | --d | -d )
43680 debug=: ;;
43681 --file | --fil | --fi | --f )
43682 $ac_shift
43683 case $ac_optarg in
43684 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
43685 '') as_fn_error $? "missing file argument" ;;
43686 esac
43687 as_fn_append CONFIG_FILES " '$ac_optarg'"
43688 ac_need_defaults=false;;
43689 --header | --heade | --head | --hea )
43690 $ac_shift
43691 case $ac_optarg in
43692 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
43693 esac
43694 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
43695 ac_need_defaults=false;;
43696 --he | --h)
43697 # Conflict between --help and --header
43698 as_fn_error $? "ambiguous option: \`$1'
43699Try \`$0 --help' for more information.";;
43700 --help | --hel | -h )
43701 $as_echo "$ac_cs_usage"; exit ;;
43702 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
43703 | -silent | --silent | --silen | --sile | --sil | --si | --s)
43704 ac_cs_silent=: ;;
43705
43706 # This is an error.
43707 -*) as_fn_error $? "unrecognized option: \`$1'
43708Try \`$0 --help' for more information." ;;
43709
43710 *) as_fn_append ac_config_targets " $1"
43711 ac_need_defaults=false ;;
43712
43713 esac
43714 shift
43715done
43716
43717ac_configure_extra_args=
43718
43719if $ac_cs_silent; then
43720 exec 6>/dev/null
43721 ac_configure_extra_args="$ac_configure_extra_args --silent"
43722fi
43723
43724_ACEOF
43725cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
43726if \$ac_cs_recheck; then
43727 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
43728 shift
43729 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
43730 CONFIG_SHELL='$SHELL'
43731 export CONFIG_SHELL
43732 exec "\$@"
43733fi
43734
43735_ACEOF
43736cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
43737exec 5>>config.log
43738{
43739 echo
43740 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
43741## Running $as_me. ##
43742_ASBOX
43743 $as_echo "$ac_log"
43744} >&5
43745
43746_ACEOF
43747cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
43748#
43749# INIT-COMMANDS
43750#
Haibo Huang001784b2019-07-19 05:27:28 -070043751AMDEP_TRUE="$AMDEP_TRUE" MAKE="${MAKE-make}"
Elliott Hughes82be86d2017-09-20 17:00:17 -070043752
43753
43754# The HP-UX ksh and POSIX shell print the target directory to stdout
43755# if CDPATH is set.
43756(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
43757
43758sed_quote_subst='$sed_quote_subst'
43759double_quote_subst='$double_quote_subst'
43760delay_variable_subst='$delay_variable_subst'
43761macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`'
43762macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`'
43763AS='`$ECHO "$AS" | $SED "$delay_single_quote_subst"`'
43764DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`'
43765OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`'
43766enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`'
43767enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`'
43768pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`'
43769enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`'
43770shared_archive_member_spec='`$ECHO "$shared_archive_member_spec" | $SED "$delay_single_quote_subst"`'
43771SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`'
43772ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`'
43773PATH_SEPARATOR='`$ECHO "$PATH_SEPARATOR" | $SED "$delay_single_quote_subst"`'
43774host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`'
43775host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`'
43776host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`'
43777build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`'
43778build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`'
43779build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`'
43780SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`'
43781Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`'
43782GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`'
43783EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`'
43784FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`'
43785LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`'
43786NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`'
43787LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`'
43788max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`'
43789ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`'
43790exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
43791lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
43792lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
43793lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
43794lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`'
43795lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`'
43796reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`'
43797reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`'
43798deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`'
43799file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`'
43800file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`'
43801want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`'
43802sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`'
43803AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`'
43804AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`'
43805archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`'
43806STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
43807RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
43808old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
43809old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
43810old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`'
43811lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`'
43812CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`'
43813CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`'
43814compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`'
43815GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`'
43816lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`'
43817lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
43818lt_cv_sys_global_symbol_to_import='`$ECHO "$lt_cv_sys_global_symbol_to_import" | $SED "$delay_single_quote_subst"`'
43819lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
43820lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
43821lt_cv_nm_interface='`$ECHO "$lt_cv_nm_interface" | $SED "$delay_single_quote_subst"`'
43822nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`'
43823lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`'
43824lt_cv_truncate_bin='`$ECHO "$lt_cv_truncate_bin" | $SED "$delay_single_quote_subst"`'
43825objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`'
43826MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`'
43827lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`'
43828lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`'
43829lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
43830lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`'
43831lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`'
43832need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`'
43833MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`'
43834DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
43835NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
43836LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
43837OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`'
43838OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`'
43839libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`'
43840shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`'
43841extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
43842archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`'
43843enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`'
43844export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`'
43845whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`'
43846compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`'
43847old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`'
43848old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
43849archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`'
43850archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`'
43851module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`'
43852module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`'
43853with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`'
43854allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`'
43855no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`'
43856hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`'
43857hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`'
43858hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`'
43859hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`'
43860hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`'
43861hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`'
43862hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
43863inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
43864link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
43865always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`'
43866export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`'
43867exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`'
43868include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`'
43869prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`'
43870postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`'
43871file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
43872variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
43873need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
43874need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`'
43875version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`'
43876runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`'
43877shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`'
43878shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`'
43879libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`'
43880library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`'
43881soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`'
43882install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`'
43883postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`'
43884postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
43885finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`'
43886finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`'
43887hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`'
43888sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`'
43889configure_time_dlsearch_path='`$ECHO "$configure_time_dlsearch_path" | $SED "$delay_single_quote_subst"`'
43890configure_time_lt_sys_library_path='`$ECHO "$configure_time_lt_sys_library_path" | $SED "$delay_single_quote_subst"`'
43891hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`'
43892enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`'
43893enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`'
43894enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`'
43895old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`'
43896striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`'
43897
43898LTCC='$LTCC'
43899LTCFLAGS='$LTCFLAGS'
43900compiler='$compiler_DEFAULT'
43901
43902# A function that is used when there is no print builtin or printf.
43903func_fallback_echo ()
43904{
43905 eval 'cat <<_LTECHO_EOF
43906\$1
43907_LTECHO_EOF'
43908}
43909
43910# Quote evaled strings.
43911for var in AS \
43912DLLTOOL \
43913OBJDUMP \
43914SHELL \
43915ECHO \
43916PATH_SEPARATOR \
43917SED \
43918GREP \
43919EGREP \
43920FGREP \
43921LD \
43922NM \
43923LN_S \
43924lt_SP2NL \
43925lt_NL2SP \
43926reload_flag \
43927deplibs_check_method \
43928file_magic_cmd \
43929file_magic_glob \
43930want_nocaseglob \
43931sharedlib_from_linklib_cmd \
43932AR \
43933AR_FLAGS \
43934archiver_list_spec \
43935STRIP \
43936RANLIB \
43937CC \
43938CFLAGS \
43939compiler \
43940lt_cv_sys_global_symbol_pipe \
43941lt_cv_sys_global_symbol_to_cdecl \
43942lt_cv_sys_global_symbol_to_import \
43943lt_cv_sys_global_symbol_to_c_name_address \
43944lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
43945lt_cv_nm_interface \
43946nm_file_list_spec \
43947lt_cv_truncate_bin \
43948lt_prog_compiler_no_builtin_flag \
43949lt_prog_compiler_pic \
43950lt_prog_compiler_wl \
43951lt_prog_compiler_static \
43952lt_cv_prog_compiler_c_o \
43953need_locks \
43954MANIFEST_TOOL \
43955DSYMUTIL \
43956NMEDIT \
43957LIPO \
43958OTOOL \
43959OTOOL64 \
43960shrext_cmds \
43961export_dynamic_flag_spec \
43962whole_archive_flag_spec \
43963compiler_needs_object \
43964with_gnu_ld \
43965allow_undefined_flag \
43966no_undefined_flag \
43967hardcode_libdir_flag_spec \
43968hardcode_libdir_separator \
43969exclude_expsyms \
43970include_expsyms \
43971file_list_spec \
43972variables_saved_for_relink \
43973libname_spec \
43974library_names_spec \
43975soname_spec \
43976install_override_mode \
43977finish_eval \
43978old_striplib \
43979striplib; do
43980 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
43981 *[\\\\\\\`\\"\\\$]*)
43982 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes
43983 ;;
43984 *)
43985 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
43986 ;;
43987 esac
43988done
43989
43990# Double-quote double-evaled strings.
43991for var in reload_cmds \
43992old_postinstall_cmds \
43993old_postuninstall_cmds \
43994old_archive_cmds \
43995extract_expsyms_cmds \
43996old_archive_from_new_cmds \
43997old_archive_from_expsyms_cmds \
43998archive_cmds \
43999archive_expsym_cmds \
44000module_cmds \
44001module_expsym_cmds \
44002export_symbols_cmds \
44003prelink_cmds \
44004postlink_cmds \
44005postinstall_cmds \
44006postuninstall_cmds \
44007finish_cmds \
44008sys_lib_search_path_spec \
44009configure_time_dlsearch_path \
44010configure_time_lt_sys_library_path; do
44011 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
44012 *[\\\\\\\`\\"\\\$]*)
44013 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes
44014 ;;
44015 *)
44016 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
44017 ;;
44018 esac
44019done
44020
44021ac_aux_dir='$ac_aux_dir'
44022
44023# See if we are running on zsh, and set the options that allow our
44024# commands through without removal of \ escapes INIT.
44025if test -n "\${ZSH_VERSION+set}"; then
44026 setopt NO_GLOB_SUBST
44027fi
44028
44029
44030 PACKAGE='$PACKAGE'
44031 VERSION='$VERSION'
44032 RM='$RM'
44033 ofile='$ofile'
44034
44035
44036
44037
44038_ACEOF
44039
44040cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
44041
44042# Handling of arguments.
44043for ac_config_target in $ac_config_targets
44044do
44045 case $ac_config_target in
44046 "lib/curl_config.h") CONFIG_HEADERS="$CONFIG_HEADERS lib/curl_config.h" ;;
44047 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
44048 "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;;
44049 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
44050 "docs/Makefile") CONFIG_FILES="$CONFIG_FILES docs/Makefile" ;;
44051 "docs/examples/Makefile") CONFIG_FILES="$CONFIG_FILES docs/examples/Makefile" ;;
44052 "docs/libcurl/Makefile") CONFIG_FILES="$CONFIG_FILES docs/libcurl/Makefile" ;;
44053 "docs/libcurl/opts/Makefile") CONFIG_FILES="$CONFIG_FILES docs/libcurl/opts/Makefile" ;;
44054 "docs/cmdline-opts/Makefile") CONFIG_FILES="$CONFIG_FILES docs/cmdline-opts/Makefile" ;;
44055 "include/Makefile") CONFIG_FILES="$CONFIG_FILES include/Makefile" ;;
44056 "include/curl/Makefile") CONFIG_FILES="$CONFIG_FILES include/curl/Makefile" ;;
44057 "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
44058 "lib/Makefile") CONFIG_FILES="$CONFIG_FILES lib/Makefile" ;;
44059 "scripts/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/Makefile" ;;
44060 "lib/libcurl.vers") CONFIG_FILES="$CONFIG_FILES lib/libcurl.vers" ;;
44061 "tests/Makefile") CONFIG_FILES="$CONFIG_FILES tests/Makefile" ;;
44062 "tests/certs/Makefile") CONFIG_FILES="$CONFIG_FILES tests/certs/Makefile" ;;
44063 "tests/certs/scripts/Makefile") CONFIG_FILES="$CONFIG_FILES tests/certs/scripts/Makefile" ;;
44064 "tests/data/Makefile") CONFIG_FILES="$CONFIG_FILES tests/data/Makefile" ;;
44065 "tests/server/Makefile") CONFIG_FILES="$CONFIG_FILES tests/server/Makefile" ;;
44066 "tests/libtest/Makefile") CONFIG_FILES="$CONFIG_FILES tests/libtest/Makefile" ;;
44067 "tests/unit/Makefile") CONFIG_FILES="$CONFIG_FILES tests/unit/Makefile" ;;
Elliott Hughes82be86d2017-09-20 17:00:17 -070044068 "packages/Makefile") CONFIG_FILES="$CONFIG_FILES packages/Makefile" ;;
Elliott Hughes82be86d2017-09-20 17:00:17 -070044069 "packages/vms/Makefile") CONFIG_FILES="$CONFIG_FILES packages/vms/Makefile" ;;
Elliott Hughes82be86d2017-09-20 17:00:17 -070044070 "curl-config") CONFIG_FILES="$CONFIG_FILES curl-config" ;;
44071 "libcurl.pc") CONFIG_FILES="$CONFIG_FILES libcurl.pc" ;;
44072
44073 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
44074 esac
44075done
44076
44077
44078# If the user did not use the arguments to specify the items to instantiate,
44079# then the envvar interface is used. Set only those that are not.
44080# We use the long form for the default assignment because of an extremely
44081# bizarre bug on SunOS 4.1.3.
44082if $ac_need_defaults; then
44083 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
44084 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
44085 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
44086fi
44087
44088# Have a temporary directory for convenience. Make it in the build tree
44089# simply because there is no reason against having it here, and in addition,
44090# creating and moving files from /tmp can sometimes cause problems.
44091# Hook for its removal unless debugging.
44092# Note that there is a small window in which the directory will not be cleaned:
44093# after its creation but before its name has been assigned to `$tmp'.
44094$debug ||
44095{
44096 tmp= ac_tmp=
44097 trap 'exit_status=$?
44098 : "${ac_tmp:=$tmp}"
44099 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
44100' 0
44101 trap 'as_fn_exit 1' 1 2 13 15
44102}
44103# Create a (secure) tmp directory for tmp files.
44104
44105{
44106 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
44107 test -d "$tmp"
44108} ||
44109{
44110 tmp=./conf$$-$RANDOM
44111 (umask 077 && mkdir "$tmp")
44112} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
44113ac_tmp=$tmp
44114
44115# Set up the scripts for CONFIG_FILES section.
44116# No need to generate them if there are no CONFIG_FILES.
44117# This happens for instance with `./config.status config.h'.
44118if test -n "$CONFIG_FILES"; then
44119
44120
44121ac_cr=`echo X | tr X '\015'`
44122# On cygwin, bash can eat \r inside `` if the user requested igncr.
44123# But we know of no other shell where ac_cr would be empty at this
44124# point, so we can use a bashism as a fallback.
44125if test "x$ac_cr" = x; then
44126 eval ac_cr=\$\'\\r\'
44127fi
44128ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
44129if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
44130 ac_cs_awk_cr='\\r'
44131else
44132 ac_cs_awk_cr=$ac_cr
44133fi
44134
44135echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
44136_ACEOF
44137
44138
44139{
44140 echo "cat >conf$$subs.awk <<_ACEOF" &&
44141 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
44142 echo "_ACEOF"
44143} >conf$$subs.sh ||
44144 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
44145ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
44146ac_delim='%!_!# '
44147for ac_last_try in false false false false false :; do
44148 . ./conf$$subs.sh ||
44149 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
44150
44151 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
44152 if test $ac_delim_n = $ac_delim_num; then
44153 break
44154 elif $ac_last_try; then
44155 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
44156 else
44157 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
44158 fi
44159done
44160rm -f conf$$subs.sh
44161
44162cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
44163cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
44164_ACEOF
44165sed -n '
44166h
44167s/^/S["/; s/!.*/"]=/
44168p
44169g
44170s/^[^!]*!//
44171:repl
44172t repl
44173s/'"$ac_delim"'$//
44174t delim
44175:nl
44176h
44177s/\(.\{148\}\)..*/\1/
44178t more1
44179s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
44180p
44181n
44182b repl
44183:more1
44184s/["\\]/\\&/g; s/^/"/; s/$/"\\/
44185p
44186g
44187s/.\{148\}//
44188t nl
44189:delim
44190h
44191s/\(.\{148\}\)..*/\1/
44192t more2
44193s/["\\]/\\&/g; s/^/"/; s/$/"/
44194p
44195b
44196:more2
44197s/["\\]/\\&/g; s/^/"/; s/$/"\\/
44198p
44199g
44200s/.\{148\}//
44201t delim
44202' <conf$$subs.awk | sed '
44203/^[^""]/{
44204 N
44205 s/\n//
44206}
44207' >>$CONFIG_STATUS || ac_write_fail=1
44208rm -f conf$$subs.awk
44209cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
44210_ACAWK
44211cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
44212 for (key in S) S_is_set[key] = 1
44213 FS = ""
44214
44215}
44216{
44217 line = $ 0
44218 nfields = split(line, field, "@")
44219 substed = 0
44220 len = length(field[1])
44221 for (i = 2; i < nfields; i++) {
44222 key = field[i]
44223 keylen = length(key)
44224 if (S_is_set[key]) {
44225 value = S[key]
44226 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
44227 len += length(value) + length(field[++i])
44228 substed = 1
44229 } else
44230 len += 1 + keylen
44231 }
44232
44233 print line
44234}
44235
44236_ACAWK
44237_ACEOF
44238cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
44239if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
44240 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
44241else
44242 cat
44243fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
44244 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
44245_ACEOF
44246
44247# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
44248# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
44249# trailing colons and then remove the whole line if VPATH becomes empty
44250# (actually we leave an empty line to preserve line numbers).
44251if test "x$srcdir" = x.; then
44252 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
44253h
44254s///
44255s/^/:/
44256s/[ ]*$/:/
44257s/:\$(srcdir):/:/g
44258s/:\${srcdir}:/:/g
44259s/:@srcdir@:/:/g
44260s/^:*//
44261s/:*$//
44262x
44263s/\(=[ ]*\).*/\1/
44264G
44265s/\n//
44266s/^[^=]*=[ ]*$//
44267}'
44268fi
44269
44270cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
44271fi # test -n "$CONFIG_FILES"
44272
44273# Set up the scripts for CONFIG_HEADERS section.
44274# No need to generate them if there are no CONFIG_HEADERS.
44275# This happens for instance with `./config.status Makefile'.
44276if test -n "$CONFIG_HEADERS"; then
44277cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
44278BEGIN {
44279_ACEOF
44280
44281# Transform confdefs.h into an awk script `defines.awk', embedded as
44282# here-document in config.status, that substitutes the proper values into
44283# config.h.in to produce config.h.
44284
44285# Create a delimiter string that does not exist in confdefs.h, to ease
44286# handling of long lines.
44287ac_delim='%!_!# '
44288for ac_last_try in false false :; do
44289 ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
44290 if test -z "$ac_tt"; then
44291 break
44292 elif $ac_last_try; then
44293 as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
44294 else
44295 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
44296 fi
44297done
44298
44299# For the awk script, D is an array of macro values keyed by name,
44300# likewise P contains macro parameters if any. Preserve backslash
44301# newline sequences.
44302
44303ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
44304sed -n '
44305s/.\{148\}/&'"$ac_delim"'/g
44306t rset
44307:rset
44308s/^[ ]*#[ ]*define[ ][ ]*/ /
44309t def
44310d
44311:def
44312s/\\$//
44313t bsnl
44314s/["\\]/\\&/g
44315s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
44316D["\1"]=" \3"/p
44317s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
44318d
44319:bsnl
44320s/["\\]/\\&/g
44321s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
44322D["\1"]=" \3\\\\\\n"\\/p
44323t cont
44324s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
44325t cont
44326d
44327:cont
44328n
44329s/.\{148\}/&'"$ac_delim"'/g
44330t clear
44331:clear
44332s/\\$//
44333t bsnlc
44334s/["\\]/\\&/g; s/^/"/; s/$/"/p
44335d
44336:bsnlc
44337s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
44338b cont
44339' <confdefs.h | sed '
44340s/'"$ac_delim"'/"\\\
44341"/g' >>$CONFIG_STATUS || ac_write_fail=1
44342
44343cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
44344 for (key in D) D_is_set[key] = 1
44345 FS = ""
44346}
44347/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
44348 line = \$ 0
44349 split(line, arg, " ")
44350 if (arg[1] == "#") {
44351 defundef = arg[2]
44352 mac1 = arg[3]
44353 } else {
44354 defundef = substr(arg[1], 2)
44355 mac1 = arg[2]
44356 }
44357 split(mac1, mac2, "(") #)
44358 macro = mac2[1]
44359 prefix = substr(line, 1, index(line, defundef) - 1)
44360 if (D_is_set[macro]) {
44361 # Preserve the white space surrounding the "#".
44362 print prefix "define", macro P[macro] D[macro]
44363 next
44364 } else {
44365 # Replace #undef with comments. This is necessary, for example,
44366 # in the case of _POSIX_SOURCE, which is predefined and required
44367 # on some systems where configure will not decide to define it.
44368 if (defundef == "undef") {
44369 print "/*", prefix defundef, macro, "*/"
44370 next
44371 }
44372 }
44373}
44374{ print }
44375_ACAWK
44376_ACEOF
44377cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
44378 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
44379fi # test -n "$CONFIG_HEADERS"
44380
44381
44382eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
44383shift
44384for ac_tag
44385do
44386 case $ac_tag in
44387 :[FHLC]) ac_mode=$ac_tag; continue;;
44388 esac
44389 case $ac_mode$ac_tag in
44390 :[FHL]*:*);;
44391 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
44392 :[FH]-) ac_tag=-:-;;
44393 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
44394 esac
44395 ac_save_IFS=$IFS
44396 IFS=:
44397 set x $ac_tag
44398 IFS=$ac_save_IFS
44399 shift
44400 ac_file=$1
44401 shift
44402
44403 case $ac_mode in
44404 :L) ac_source=$1;;
44405 :[FH])
44406 ac_file_inputs=
44407 for ac_f
44408 do
44409 case $ac_f in
44410 -) ac_f="$ac_tmp/stdin";;
44411 *) # Look for the file first in the build tree, then in the source tree
44412 # (if the path is not absolute). The absolute path cannot be DOS-style,
44413 # because $ac_f cannot contain `:'.
44414 test -f "$ac_f" ||
44415 case $ac_f in
44416 [\\/$]*) false;;
44417 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
44418 esac ||
44419 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
44420 esac
44421 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
44422 as_fn_append ac_file_inputs " '$ac_f'"
44423 done
44424
44425 # Let's still pretend it is `configure' which instantiates (i.e., don't
44426 # use $as_me), people would be surprised to read:
44427 # /* config.h. Generated by config.status. */
44428 configure_input='Generated from '`
44429 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
44430 `' by configure.'
44431 if test x"$ac_file" != x-; then
44432 configure_input="$ac_file. $configure_input"
44433 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
44434$as_echo "$as_me: creating $ac_file" >&6;}
44435 fi
44436 # Neutralize special characters interpreted by sed in replacement strings.
44437 case $configure_input in #(
44438 *\&* | *\|* | *\\* )
44439 ac_sed_conf_input=`$as_echo "$configure_input" |
44440 sed 's/[\\\\&|]/\\\\&/g'`;; #(
44441 *) ac_sed_conf_input=$configure_input;;
44442 esac
44443
44444 case $ac_tag in
44445 *:-:* | *:-) cat >"$ac_tmp/stdin" \
44446 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
44447 esac
44448 ;;
44449 esac
44450
44451 ac_dir=`$as_dirname -- "$ac_file" ||
44452$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
44453 X"$ac_file" : 'X\(//\)[^/]' \| \
44454 X"$ac_file" : 'X\(//\)$' \| \
44455 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
44456$as_echo X"$ac_file" |
44457 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
44458 s//\1/
44459 q
44460 }
44461 /^X\(\/\/\)[^/].*/{
44462 s//\1/
44463 q
44464 }
44465 /^X\(\/\/\)$/{
44466 s//\1/
44467 q
44468 }
44469 /^X\(\/\).*/{
44470 s//\1/
44471 q
44472 }
44473 s/.*/./; q'`
44474 as_dir="$ac_dir"; as_fn_mkdir_p
44475 ac_builddir=.
44476
44477case "$ac_dir" in
44478.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
44479*)
44480 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
44481 # A ".." for each directory in $ac_dir_suffix.
44482 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
44483 case $ac_top_builddir_sub in
44484 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
44485 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
44486 esac ;;
44487esac
44488ac_abs_top_builddir=$ac_pwd
44489ac_abs_builddir=$ac_pwd$ac_dir_suffix
44490# for backward compatibility:
44491ac_top_builddir=$ac_top_build_prefix
44492
44493case $srcdir in
44494 .) # We are building in place.
44495 ac_srcdir=.
44496 ac_top_srcdir=$ac_top_builddir_sub
44497 ac_abs_top_srcdir=$ac_pwd ;;
44498 [\\/]* | ?:[\\/]* ) # Absolute name.
44499 ac_srcdir=$srcdir$ac_dir_suffix;
44500 ac_top_srcdir=$srcdir
44501 ac_abs_top_srcdir=$srcdir ;;
44502 *) # Relative name.
44503 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
44504 ac_top_srcdir=$ac_top_build_prefix$srcdir
44505 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
44506esac
44507ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
44508
44509
44510 case $ac_mode in
44511 :F)
44512 #
44513 # CONFIG_FILE
44514 #
44515
44516 case $INSTALL in
44517 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
44518 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
44519 esac
44520 ac_MKDIR_P=$MKDIR_P
44521 case $MKDIR_P in
44522 [\\/$]* | ?:[\\/]* ) ;;
44523 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
44524 esac
44525_ACEOF
44526
44527cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
44528# If the template does not know about datarootdir, expand it.
44529# FIXME: This hack should be removed a few years after 2.60.
44530ac_datarootdir_hack=; ac_datarootdir_seen=
44531ac_sed_dataroot='
44532/datarootdir/ {
44533 p
44534 q
44535}
44536/@datadir@/p
44537/@docdir@/p
44538/@infodir@/p
44539/@localedir@/p
44540/@mandir@/p'
44541case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
44542*datarootdir*) ac_datarootdir_seen=yes;;
44543*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
44544 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
44545$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
44546_ACEOF
44547cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
44548 ac_datarootdir_hack='
44549 s&@datadir@&$datadir&g
44550 s&@docdir@&$docdir&g
44551 s&@infodir@&$infodir&g
44552 s&@localedir@&$localedir&g
44553 s&@mandir@&$mandir&g
44554 s&\\\${datarootdir}&$datarootdir&g' ;;
44555esac
44556_ACEOF
44557
44558# Neutralize VPATH when `$srcdir' = `.'.
44559# Shell code in configure.ac might set extrasub.
44560# FIXME: do we really want to maintain this feature?
44561cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
44562ac_sed_extra="$ac_vpsub
44563$extrasub
44564_ACEOF
44565cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
44566:t
44567/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
44568s|@configure_input@|$ac_sed_conf_input|;t t
44569s&@top_builddir@&$ac_top_builddir_sub&;t t
44570s&@top_build_prefix@&$ac_top_build_prefix&;t t
44571s&@srcdir@&$ac_srcdir&;t t
44572s&@abs_srcdir@&$ac_abs_srcdir&;t t
44573s&@top_srcdir@&$ac_top_srcdir&;t t
44574s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
44575s&@builddir@&$ac_builddir&;t t
44576s&@abs_builddir@&$ac_abs_builddir&;t t
44577s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
44578s&@INSTALL@&$ac_INSTALL&;t t
44579s&@MKDIR_P@&$ac_MKDIR_P&;t t
44580$ac_datarootdir_hack
44581"
44582eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
44583 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
44584
44585test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
44586 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
44587 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
44588 "$ac_tmp/out"`; test -z "$ac_out"; } &&
44589 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
44590which seems to be undefined. Please make sure it is defined" >&5
44591$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
44592which seems to be undefined. Please make sure it is defined" >&2;}
44593
44594 rm -f "$ac_tmp/stdin"
44595 case $ac_file in
44596 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
44597 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
44598 esac \
44599 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
44600 ;;
44601 :H)
44602 #
44603 # CONFIG_HEADER
44604 #
44605 if test x"$ac_file" != x-; then
44606 {
44607 $as_echo "/* $configure_input */" \
44608 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
44609 } >"$ac_tmp/config.h" \
44610 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
44611 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
44612 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
44613$as_echo "$as_me: $ac_file is unchanged" >&6;}
44614 else
44615 rm -f "$ac_file"
44616 mv "$ac_tmp/config.h" "$ac_file" \
44617 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
44618 fi
44619 else
44620 $as_echo "/* $configure_input */" \
44621 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
44622 || as_fn_error $? "could not create -" "$LINENO" 5
44623 fi
44624# Compute "$ac_file"'s index in $config_headers.
44625_am_arg="$ac_file"
44626_am_stamp_count=1
44627for _am_header in $config_headers :; do
44628 case $_am_header in
44629 $_am_arg | $_am_arg:* )
44630 break ;;
44631 * )
44632 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
44633 esac
44634done
44635echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
44636$as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
44637 X"$_am_arg" : 'X\(//\)[^/]' \| \
44638 X"$_am_arg" : 'X\(//\)$' \| \
44639 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
44640$as_echo X"$_am_arg" |
44641 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
44642 s//\1/
44643 q
44644 }
44645 /^X\(\/\/\)[^/].*/{
44646 s//\1/
44647 q
44648 }
44649 /^X\(\/\/\)$/{
44650 s//\1/
44651 q
44652 }
44653 /^X\(\/\).*/{
44654 s//\1/
44655 q
44656 }
44657 s/.*/./; q'`/stamp-h$_am_stamp_count
44658 ;;
44659
44660 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
44661$as_echo "$as_me: executing $ac_file commands" >&6;}
44662 ;;
44663 esac
44664
44665
44666 case $ac_file$ac_mode in
44667 "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
44668 # Older Autoconf quotes --file arguments for eval, but not when files
44669 # are listed without --file. Let's play safe and only enable the eval
44670 # if we detect the quoting.
Haibo Huang001784b2019-07-19 05:27:28 -070044671 # TODO: see whether this extra hack can be removed once we start
44672 # requiring Autoconf 2.70 or later.
44673 case $CONFIG_FILES in #(
44674 *\'*) :
44675 eval set x "$CONFIG_FILES" ;; #(
44676 *) :
44677 set x $CONFIG_FILES ;; #(
44678 *) :
44679 ;;
44680esac
Elliott Hughes82be86d2017-09-20 17:00:17 -070044681 shift
Haibo Huang001784b2019-07-19 05:27:28 -070044682 # Used to flag and report bootstrapping failures.
44683 am_rc=0
44684 for am_mf
Elliott Hughes82be86d2017-09-20 17:00:17 -070044685 do
44686 # Strip MF so we end up with the name of the file.
Haibo Huang001784b2019-07-19 05:27:28 -070044687 am_mf=`$as_echo "$am_mf" | sed -e 's/:.*$//'`
44688 # Check whether this is an Automake generated Makefile which includes
44689 # dependency-tracking related rules and includes.
44690 # Grep'ing the whole file directly is not great: AIX grep has a line
Elliott Hughes82be86d2017-09-20 17:00:17 -070044691 # limit of 2048, but all sed's we know have understand at least 4000.
Haibo Huang001784b2019-07-19 05:27:28 -070044692 sed -n 's,^am--depfiles:.*,X,p' "$am_mf" | grep X >/dev/null 2>&1 \
44693 || continue
44694 am_dirpart=`$as_dirname -- "$am_mf" ||
44695$as_expr X"$am_mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
44696 X"$am_mf" : 'X\(//\)[^/]' \| \
44697 X"$am_mf" : 'X\(//\)$' \| \
44698 X"$am_mf" : 'X\(/\)' \| . 2>/dev/null ||
44699$as_echo X"$am_mf" |
Elliott Hughes82be86d2017-09-20 17:00:17 -070044700 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
44701 s//\1/
44702 q
44703 }
44704 /^X\(\/\/\)[^/].*/{
44705 s//\1/
44706 q
44707 }
44708 /^X\(\/\/\)$/{
44709 s//\1/
44710 q
44711 }
44712 /^X\(\/\).*/{
44713 s//\1/
44714 q
44715 }
44716 s/.*/./; q'`
Haibo Huang001784b2019-07-19 05:27:28 -070044717 am_filepart=`$as_basename -- "$am_mf" ||
44718$as_expr X/"$am_mf" : '.*/\([^/][^/]*\)/*$' \| \
44719 X"$am_mf" : 'X\(//\)$' \| \
44720 X"$am_mf" : 'X\(/\)' \| . 2>/dev/null ||
44721$as_echo X/"$am_mf" |
44722 sed '/^.*\/\([^/][^/]*\)\/*$/{
Elliott Hughes82be86d2017-09-20 17:00:17 -070044723 s//\1/
44724 q
44725 }
Haibo Huang001784b2019-07-19 05:27:28 -070044726 /^X\/\(\/\/\)$/{
Elliott Hughes82be86d2017-09-20 17:00:17 -070044727 s//\1/
44728 q
44729 }
Haibo Huang001784b2019-07-19 05:27:28 -070044730 /^X\/\(\/\).*/{
Elliott Hughes82be86d2017-09-20 17:00:17 -070044731 s//\1/
44732 q
44733 }
44734 s/.*/./; q'`
Haibo Huang001784b2019-07-19 05:27:28 -070044735 { echo "$as_me:$LINENO: cd "$am_dirpart" \
44736 && sed -e '/# am--include-marker/d' "$am_filepart" \
44737 | $MAKE -f - am--depfiles" >&5
44738 (cd "$am_dirpart" \
44739 && sed -e '/# am--include-marker/d' "$am_filepart" \
44740 | $MAKE -f - am--depfiles) >&5 2>&5
44741 ac_status=$?
44742 echo "$as_me:$LINENO: \$? = $ac_status" >&5
44743 (exit $ac_status); } || am_rc=$?
Elliott Hughes82be86d2017-09-20 17:00:17 -070044744 done
Haibo Huang001784b2019-07-19 05:27:28 -070044745 if test $am_rc -ne 0; then
44746 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
44747$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
44748as_fn_error $? "Something went wrong bootstrapping makefile fragments
44749 for automatic dependency tracking. Try re-running configure with the
44750 '--disable-dependency-tracking' option to at least be able to build
44751 the package (albeit without support for automatic dependency tracking).
44752See \`config.log' for more details" "$LINENO" 5; }
44753 fi
44754 { am_dirpart=; unset am_dirpart;}
44755 { am_filepart=; unset am_filepart;}
44756 { am_mf=; unset am_mf;}
44757 { am_rc=; unset am_rc;}
44758 rm -f conftest-deps.mk
Elliott Hughes82be86d2017-09-20 17:00:17 -070044759}
44760 ;;
44761 "libtool":C)
44762
44763 # See if we are running on zsh, and set the options that allow our
44764 # commands through without removal of \ escapes.
44765 if test -n "${ZSH_VERSION+set}"; then
44766 setopt NO_GLOB_SUBST
44767 fi
44768
44769 cfgfile=${ofile}T
44770 trap "$RM \"$cfgfile\"; exit 1" 1 2 15
44771 $RM "$cfgfile"
44772
44773 cat <<_LT_EOF >> "$cfgfile"
44774#! $SHELL
44775# Generated automatically by $as_me ($PACKAGE) $VERSION
44776# NOTE: Changes made to this file will be lost: look at ltmain.sh.
44777
44778# Provide generalized library-building support services.
44779# Written by Gordon Matzigkeit, 1996
44780
44781# Copyright (C) 2014 Free Software Foundation, Inc.
44782# This is free software; see the source for copying conditions. There is NO
44783# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
44784
44785# GNU Libtool is free software; you can redistribute it and/or modify
44786# it under the terms of the GNU General Public License as published by
44787# the Free Software Foundation; either version 2 of of the License, or
44788# (at your option) any later version.
44789#
44790# As a special exception to the GNU General Public License, if you
44791# distribute this file as part of a program or library that is built
44792# using GNU Libtool, you may include this file under the same
44793# distribution terms that you use for the rest of that program.
44794#
44795# GNU Libtool is distributed in the hope that it will be useful, but
44796# WITHOUT ANY WARRANTY; without even the implied warranty of
44797# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
44798# GNU General Public License for more details.
44799#
44800# You should have received a copy of the GNU General Public License
44801# along with this program. If not, see <http://www.gnu.org/licenses/>.
44802
44803
44804# The names of the tagged configurations supported by this script.
44805available_tags=''
44806
44807# Configured defaults for sys_lib_dlsearch_path munging.
44808: \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"}
44809
44810# ### BEGIN LIBTOOL CONFIG
44811
44812# Which release of libtool.m4 was used?
44813macro_version=$macro_version
44814macro_revision=$macro_revision
44815
44816# Assembler program.
44817AS=$lt_AS
44818
44819# DLL creation program.
44820DLLTOOL=$lt_DLLTOOL
44821
44822# Object dumper program.
44823OBJDUMP=$lt_OBJDUMP
44824
44825# Whether or not to build shared libraries.
44826build_libtool_libs=$enable_shared
44827
44828# Whether or not to build static libraries.
44829build_old_libs=$enable_static
44830
44831# What type of objects to build.
44832pic_mode=$pic_mode
44833
44834# Whether or not to optimize for fast installation.
44835fast_install=$enable_fast_install
44836
44837# Shared archive member basename,for filename based shared library versioning on AIX.
44838shared_archive_member_spec=$shared_archive_member_spec
44839
44840# Shell to use when invoking shell scripts.
44841SHELL=$lt_SHELL
44842
44843# An echo program that protects backslashes.
44844ECHO=$lt_ECHO
44845
44846# The PATH separator for the build system.
44847PATH_SEPARATOR=$lt_PATH_SEPARATOR
44848
44849# The host system.
44850host_alias=$host_alias
44851host=$host
44852host_os=$host_os
44853
44854# The build system.
44855build_alias=$build_alias
44856build=$build
44857build_os=$build_os
44858
44859# A sed program that does not truncate output.
44860SED=$lt_SED
44861
44862# Sed that helps us avoid accidentally triggering echo(1) options like -n.
44863Xsed="\$SED -e 1s/^X//"
44864
44865# A grep program that handles long lines.
44866GREP=$lt_GREP
44867
44868# An ERE matcher.
44869EGREP=$lt_EGREP
44870
44871# A literal string matcher.
44872FGREP=$lt_FGREP
44873
44874# A BSD- or MS-compatible name lister.
44875NM=$lt_NM
44876
44877# Whether we need soft or hard links.
44878LN_S=$lt_LN_S
44879
44880# What is the maximum length of a command?
44881max_cmd_len=$max_cmd_len
44882
44883# Object file suffix (normally "o").
44884objext=$ac_objext
44885
44886# Executable file suffix (normally "").
44887exeext=$exeext
44888
44889# whether the shell understands "unset".
44890lt_unset=$lt_unset
44891
44892# turn spaces into newlines.
44893SP2NL=$lt_lt_SP2NL
44894
44895# turn newlines into spaces.
44896NL2SP=$lt_lt_NL2SP
44897
44898# convert \$build file names to \$host format.
44899to_host_file_cmd=$lt_cv_to_host_file_cmd
44900
44901# convert \$build files to toolchain format.
44902to_tool_file_cmd=$lt_cv_to_tool_file_cmd
44903
44904# Method to check whether dependent libraries are shared objects.
44905deplibs_check_method=$lt_deplibs_check_method
44906
44907# Command to use when deplibs_check_method = "file_magic".
44908file_magic_cmd=$lt_file_magic_cmd
44909
44910# How to find potential files when deplibs_check_method = "file_magic".
44911file_magic_glob=$lt_file_magic_glob
44912
44913# Find potential files using nocaseglob when deplibs_check_method = "file_magic".
44914want_nocaseglob=$lt_want_nocaseglob
44915
44916# Command to associate shared and link libraries.
44917sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd
44918
44919# The archiver.
44920AR=$lt_AR
44921
44922# Flags to create an archive.
44923AR_FLAGS=$lt_AR_FLAGS
44924
44925# How to feed a file listing to the archiver.
44926archiver_list_spec=$lt_archiver_list_spec
44927
44928# A symbol stripping program.
44929STRIP=$lt_STRIP
44930
44931# Commands used to install an old-style archive.
44932RANLIB=$lt_RANLIB
44933old_postinstall_cmds=$lt_old_postinstall_cmds
44934old_postuninstall_cmds=$lt_old_postuninstall_cmds
44935
44936# Whether to use a lock for old archive extraction.
44937lock_old_archive_extraction=$lock_old_archive_extraction
44938
44939# A C compiler.
44940LTCC=$lt_CC
44941
44942# LTCC compiler flags.
44943LTCFLAGS=$lt_CFLAGS
44944
44945# Take the output of nm and produce a listing of raw symbols and C names.
44946global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
44947
44948# Transform the output of nm in a proper C declaration.
44949global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
44950
44951# Transform the output of nm into a list of symbols to manually relocate.
44952global_symbol_to_import=$lt_lt_cv_sys_global_symbol_to_import
44953
44954# Transform the output of nm in a C name address pair.
44955global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
44956
44957# Transform the output of nm in a C name address pair when lib prefix is needed.
44958global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
44959
44960# The name lister interface.
44961nm_interface=$lt_lt_cv_nm_interface
44962
44963# Specify filename containing input files for \$NM.
44964nm_file_list_spec=$lt_nm_file_list_spec
44965
44966# The root where to search for dependent libraries,and where our libraries should be installed.
44967lt_sysroot=$lt_sysroot
44968
44969# Command to truncate a binary pipe.
44970lt_truncate_bin=$lt_lt_cv_truncate_bin
44971
44972# The name of the directory that contains temporary libtool files.
44973objdir=$objdir
44974
44975# Used to examine libraries when file_magic_cmd begins with "file".
44976MAGIC_CMD=$MAGIC_CMD
44977
44978# Must we lock files when doing compilation?
44979need_locks=$lt_need_locks
44980
44981# Manifest tool.
44982MANIFEST_TOOL=$lt_MANIFEST_TOOL
44983
44984# Tool to manipulate archived DWARF debug symbol files on Mac OS X.
44985DSYMUTIL=$lt_DSYMUTIL
44986
44987# Tool to change global to local symbols on Mac OS X.
44988NMEDIT=$lt_NMEDIT
44989
44990# Tool to manipulate fat objects and archives on Mac OS X.
44991LIPO=$lt_LIPO
44992
44993# ldd/readelf like tool for Mach-O binaries on Mac OS X.
44994OTOOL=$lt_OTOOL
44995
44996# ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4.
44997OTOOL64=$lt_OTOOL64
44998
44999# Old archive suffix (normally "a").
45000libext=$libext
45001
45002# Shared library suffix (normally ".so").
45003shrext_cmds=$lt_shrext_cmds
45004
45005# The commands to extract the exported symbol list from a shared archive.
45006extract_expsyms_cmds=$lt_extract_expsyms_cmds
45007
45008# Variables whose values should be saved in libtool wrapper scripts and
45009# restored at link time.
45010variables_saved_for_relink=$lt_variables_saved_for_relink
45011
45012# Do we need the "lib" prefix for modules?
45013need_lib_prefix=$need_lib_prefix
45014
45015# Do we need a version for libraries?
45016need_version=$need_version
45017
45018# Library versioning type.
45019version_type=$version_type
45020
45021# Shared library runtime path variable.
45022runpath_var=$runpath_var
45023
45024# Shared library path variable.
45025shlibpath_var=$shlibpath_var
45026
45027# Is shlibpath searched before the hard-coded library search path?
45028shlibpath_overrides_runpath=$shlibpath_overrides_runpath
45029
45030# Format of library name prefix.
45031libname_spec=$lt_libname_spec
45032
45033# List of archive names. First name is the real one, the rest are links.
45034# The last name is the one that the linker finds with -lNAME
45035library_names_spec=$lt_library_names_spec
45036
45037# The coded name of the library, if different from the real name.
45038soname_spec=$lt_soname_spec
45039
45040# Permission mode override for installation of shared libraries.
45041install_override_mode=$lt_install_override_mode
45042
45043# Command to use after installation of a shared archive.
45044postinstall_cmds=$lt_postinstall_cmds
45045
45046# Command to use after uninstallation of a shared archive.
45047postuninstall_cmds=$lt_postuninstall_cmds
45048
45049# Commands used to finish a libtool library installation in a directory.
45050finish_cmds=$lt_finish_cmds
45051
45052# As "finish_cmds", except a single script fragment to be evaled but
45053# not shown.
45054finish_eval=$lt_finish_eval
45055
45056# Whether we should hardcode library paths into libraries.
45057hardcode_into_libs=$hardcode_into_libs
45058
45059# Compile-time system search path for libraries.
45060sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
45061
45062# Detected run-time system search path for libraries.
45063sys_lib_dlsearch_path_spec=$lt_configure_time_dlsearch_path
45064
45065# Explicit LT_SYS_LIBRARY_PATH set during ./configure time.
45066configure_time_lt_sys_library_path=$lt_configure_time_lt_sys_library_path
45067
45068# Whether dlopen is supported.
45069dlopen_support=$enable_dlopen
45070
45071# Whether dlopen of programs is supported.
45072dlopen_self=$enable_dlopen_self
45073
45074# Whether dlopen of statically linked programs is supported.
45075dlopen_self_static=$enable_dlopen_self_static
45076
45077# Commands to strip libraries.
45078old_striplib=$lt_old_striplib
45079striplib=$lt_striplib
45080
45081
45082# The linker used to build libraries.
45083LD=$lt_LD
45084
45085# How to create reloadable object files.
45086reload_flag=$lt_reload_flag
45087reload_cmds=$lt_reload_cmds
45088
45089# Commands used to build an old-style archive.
45090old_archive_cmds=$lt_old_archive_cmds
45091
45092# A language specific compiler.
45093CC=$lt_compiler
45094
45095# Is the compiler the GNU compiler?
45096with_gcc=$GCC
45097
45098# Compiler flag to turn off builtin functions.
45099no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
45100
45101# Additional compiler flags for building library objects.
45102pic_flag=$lt_lt_prog_compiler_pic
45103
45104# How to pass a linker flag through the compiler.
45105wl=$lt_lt_prog_compiler_wl
45106
45107# Compiler flag to prevent dynamic linking.
45108link_static_flag=$lt_lt_prog_compiler_static
45109
45110# Does compiler simultaneously support -c and -o options?
45111compiler_c_o=$lt_lt_cv_prog_compiler_c_o
45112
45113# Whether or not to add -lc for building shared libraries.
45114build_libtool_need_lc=$archive_cmds_need_lc
45115
45116# Whether or not to disallow shared libs when runtime libs are static.
45117allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes
45118
45119# Compiler flag to allow reflexive dlopens.
45120export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
45121
45122# Compiler flag to generate shared objects directly from archives.
45123whole_archive_flag_spec=$lt_whole_archive_flag_spec
45124
45125# Whether the compiler copes with passing no objects directly.
45126compiler_needs_object=$lt_compiler_needs_object
45127
45128# Create an old-style archive from a shared archive.
45129old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
45130
45131# Create a temporary old-style archive to link instead of a shared archive.
45132old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
45133
45134# Commands used to build a shared archive.
45135archive_cmds=$lt_archive_cmds
45136archive_expsym_cmds=$lt_archive_expsym_cmds
45137
45138# Commands used to build a loadable module if different from building
45139# a shared archive.
45140module_cmds=$lt_module_cmds
45141module_expsym_cmds=$lt_module_expsym_cmds
45142
45143# Whether we are building with GNU ld or not.
45144with_gnu_ld=$lt_with_gnu_ld
45145
45146# Flag that allows shared libraries with undefined symbols to be built.
45147allow_undefined_flag=$lt_allow_undefined_flag
45148
45149# Flag that enforces no undefined symbols.
45150no_undefined_flag=$lt_no_undefined_flag
45151
45152# Flag to hardcode \$libdir into a binary during linking.
45153# This must work even if \$libdir does not exist
45154hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
45155
45156# Whether we need a single "-rpath" flag with a separated argument.
45157hardcode_libdir_separator=$lt_hardcode_libdir_separator
45158
45159# Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes
45160# DIR into the resulting binary.
45161hardcode_direct=$hardcode_direct
45162
45163# Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes
45164# DIR into the resulting binary and the resulting library dependency is
45165# "absolute",i.e impossible to change by setting \$shlibpath_var if the
45166# library is relocated.
45167hardcode_direct_absolute=$hardcode_direct_absolute
45168
45169# Set to "yes" if using the -LDIR flag during linking hardcodes DIR
45170# into the resulting binary.
45171hardcode_minus_L=$hardcode_minus_L
45172
45173# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
45174# into the resulting binary.
45175hardcode_shlibpath_var=$hardcode_shlibpath_var
45176
45177# Set to "yes" if building a shared library automatically hardcodes DIR
45178# into the library and all subsequent libraries and executables linked
45179# against it.
45180hardcode_automatic=$hardcode_automatic
45181
45182# Set to yes if linker adds runtime paths of dependent libraries
45183# to runtime path list.
45184inherit_rpath=$inherit_rpath
45185
45186# Whether libtool must link a program against all its dependency libraries.
45187link_all_deplibs=$link_all_deplibs
45188
45189# Set to "yes" if exported symbols are required.
45190always_export_symbols=$always_export_symbols
45191
45192# The commands to list exported symbols.
45193export_symbols_cmds=$lt_export_symbols_cmds
45194
45195# Symbols that should not be listed in the preloaded symbols.
45196exclude_expsyms=$lt_exclude_expsyms
45197
45198# Symbols that must always be exported.
45199include_expsyms=$lt_include_expsyms
45200
45201# Commands necessary for linking programs (against libraries) with templates.
45202prelink_cmds=$lt_prelink_cmds
45203
45204# Commands necessary for finishing linking programs.
45205postlink_cmds=$lt_postlink_cmds
45206
45207# Specify filename containing input files.
45208file_list_spec=$lt_file_list_spec
45209
45210# How to hardcode a shared library path into an executable.
45211hardcode_action=$hardcode_action
45212
45213# ### END LIBTOOL CONFIG
45214
45215_LT_EOF
45216
45217 cat <<'_LT_EOF' >> "$cfgfile"
45218
45219# ### BEGIN FUNCTIONS SHARED WITH CONFIGURE
45220
45221# func_munge_path_list VARIABLE PATH
45222# -----------------------------------
45223# VARIABLE is name of variable containing _space_ separated list of
45224# directories to be munged by the contents of PATH, which is string
45225# having a format:
45226# "DIR[:DIR]:"
45227# string "DIR[ DIR]" will be prepended to VARIABLE
45228# ":DIR[:DIR]"
45229# string "DIR[ DIR]" will be appended to VARIABLE
45230# "DIRP[:DIRP]::[DIRA:]DIRA"
45231# string "DIRP[ DIRP]" will be prepended to VARIABLE and string
45232# "DIRA[ DIRA]" will be appended to VARIABLE
45233# "DIR[:DIR]"
45234# VARIABLE will be replaced by "DIR[ DIR]"
45235func_munge_path_list ()
45236{
45237 case x$2 in
45238 x)
45239 ;;
45240 *:)
45241 eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\"
45242 ;;
45243 x:*)
45244 eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\"
45245 ;;
45246 *::*)
45247 eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\"
45248 eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\"
45249 ;;
45250 *)
45251 eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\"
45252 ;;
45253 esac
45254}
45255
45256
45257# Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
45258func_cc_basename ()
45259{
45260 for cc_temp in $*""; do
45261 case $cc_temp in
45262 compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
45263 distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
45264 \-*) ;;
45265 *) break;;
45266 esac
45267 done
45268 func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
45269}
45270
45271
45272# ### END FUNCTIONS SHARED WITH CONFIGURE
45273
45274_LT_EOF
45275
45276 case $host_os in
45277 aix3*)
45278 cat <<\_LT_EOF >> "$cfgfile"
45279# AIX sometimes has problems with the GCC collect2 program. For some
45280# reason, if we set the COLLECT_NAMES environment variable, the problems
45281# vanish in a puff of smoke.
45282if test set != "${COLLECT_NAMES+set}"; then
45283 COLLECT_NAMES=
45284 export COLLECT_NAMES
45285fi
45286_LT_EOF
45287 ;;
45288 esac
45289
45290
45291ltmain=$ac_aux_dir/ltmain.sh
45292
45293
45294 # We use sed instead of cat because bash on DJGPP gets confused if
45295 # if finds mixed CR/LF and LF-only lines. Since sed operates in
45296 # text mode, it properly converts lines to CR/LF. This bash problem
45297 # is reportedly fixed, but why not run on old versions too?
45298 sed '$q' "$ltmain" >> "$cfgfile" \
45299 || (rm -f "$cfgfile"; exit 1)
45300
45301 mv -f "$cfgfile" "$ofile" ||
45302 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
45303 chmod +x "$ofile"
45304
45305 ;;
45306
45307 esac
45308done # for ac_tag
45309
45310
45311as_fn_exit 0
45312_ACEOF
45313ac_clean_files=$ac_clean_files_save
45314
45315test $ac_write_fail = 0 ||
45316 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
45317
45318
45319# configure is writing to config.log, and then calls config.status.
45320# config.status does its own redirection, appending to config.log.
45321# Unfortunately, on DOS this fails, as config.log is still kept open
45322# by configure, so config.status won't be able to write to it; its
45323# output is simply discarded. So we exec the FD to /dev/null,
45324# effectively closing config.log, so it can be properly (re)opened and
45325# appended to by config.status. When coming back to configure, we
45326# need to make the FD available again.
45327if test "$no_create" != yes; then
45328 ac_cs_success=:
45329 ac_config_status_args=
45330 test "$silent" = yes &&
45331 ac_config_status_args="$ac_config_status_args --quiet"
45332 exec 5>/dev/null
45333 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
45334 exec 5>>config.log
45335 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
45336 # would make configure fail if this is the last instruction.
45337 $ac_cs_success || as_fn_exit 1
45338fi
45339
45340#
45341# CONFIG_SUBDIRS section.
45342#
45343if test "$no_recursion" != yes; then
45344
45345 # Remove --cache-file, --srcdir, and --disable-option-checking arguments
45346 # so they do not pile up.
45347 ac_sub_configure_args=
45348 ac_prev=
45349 eval "set x $ac_configure_args"
45350 shift
45351 for ac_arg
45352 do
45353 if test -n "$ac_prev"; then
45354 ac_prev=
45355 continue
45356 fi
45357 case $ac_arg in
45358 -cache-file | --cache-file | --cache-fil | --cache-fi \
45359 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
45360 ac_prev=cache_file ;;
45361 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
45362 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* \
45363 | --c=*)
45364 ;;
45365 --config-cache | -C)
45366 ;;
45367 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
45368 ac_prev=srcdir ;;
45369 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
45370 ;;
45371 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
45372 ac_prev=prefix ;;
45373 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
45374 ;;
45375 --disable-option-checking)
45376 ;;
45377 *)
45378 case $ac_arg in
45379 *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
45380 esac
45381 as_fn_append ac_sub_configure_args " '$ac_arg'" ;;
45382 esac
45383 done
45384
45385 # Always prepend --prefix to ensure using the same prefix
45386 # in subdir configurations.
45387 ac_arg="--prefix=$prefix"
45388 case $ac_arg in
45389 *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
45390 esac
45391 ac_sub_configure_args="'$ac_arg' $ac_sub_configure_args"
45392
45393 # Pass --silent
45394 if test "$silent" = yes; then
45395 ac_sub_configure_args="--silent $ac_sub_configure_args"
45396 fi
45397
45398 # Always prepend --disable-option-checking to silence warnings, since
45399 # different subdirs can have different --enable and --with options.
45400 ac_sub_configure_args="--disable-option-checking $ac_sub_configure_args"
45401
45402 ac_popdir=`pwd`
45403 for ac_dir in : $subdirs; do test "x$ac_dir" = x: && continue
45404
45405 # Do not complain, so a configure script can configure whichever
45406 # parts of a large source tree are present.
45407 test -d "$srcdir/$ac_dir" || continue
45408
45409 ac_msg="=== configuring in $ac_dir (`pwd`/$ac_dir)"
45410 $as_echo "$as_me:${as_lineno-$LINENO}: $ac_msg" >&5
45411 $as_echo "$ac_msg" >&6
45412 as_dir="$ac_dir"; as_fn_mkdir_p
45413 ac_builddir=.
45414
45415case "$ac_dir" in
45416.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
45417*)
45418 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
45419 # A ".." for each directory in $ac_dir_suffix.
45420 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
45421 case $ac_top_builddir_sub in
45422 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
45423 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
45424 esac ;;
45425esac
45426ac_abs_top_builddir=$ac_pwd
45427ac_abs_builddir=$ac_pwd$ac_dir_suffix
45428# for backward compatibility:
45429ac_top_builddir=$ac_top_build_prefix
45430
45431case $srcdir in
45432 .) # We are building in place.
45433 ac_srcdir=.
45434 ac_top_srcdir=$ac_top_builddir_sub
45435 ac_abs_top_srcdir=$ac_pwd ;;
45436 [\\/]* | ?:[\\/]* ) # Absolute name.
45437 ac_srcdir=$srcdir$ac_dir_suffix;
45438 ac_top_srcdir=$srcdir
45439 ac_abs_top_srcdir=$srcdir ;;
45440 *) # Relative name.
45441 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
45442 ac_top_srcdir=$ac_top_build_prefix$srcdir
45443 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
45444esac
45445ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
45446
45447
45448 cd "$ac_dir"
45449
45450 # Check for guested configure; otherwise get Cygnus style configure.
45451 if test -f "$ac_srcdir/configure.gnu"; then
45452 ac_sub_configure=$ac_srcdir/configure.gnu
45453 elif test -f "$ac_srcdir/configure"; then
45454 ac_sub_configure=$ac_srcdir/configure
45455 elif test -f "$ac_srcdir/configure.in"; then
45456 # This should be Cygnus configure.
45457 ac_sub_configure=$ac_aux_dir/configure
45458 else
45459 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no configuration information is in $ac_dir" >&5
45460$as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2;}
45461 ac_sub_configure=
45462 fi
45463
45464 # The recursion is here.
45465 if test -n "$ac_sub_configure"; then
45466 # Make the cache file name correct relative to the subdirectory.
45467 case $cache_file in
45468 [\\/]* | ?:[\\/]* ) ac_sub_cache_file=$cache_file ;;
45469 *) # Relative name.
45470 ac_sub_cache_file=$ac_top_build_prefix$cache_file ;;
45471 esac
45472
45473 { $as_echo "$as_me:${as_lineno-$LINENO}: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&5
45474$as_echo "$as_me: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&6;}
45475 # The eval makes quoting arguments work.
45476 eval "\$SHELL \"\$ac_sub_configure\" $ac_sub_configure_args \
45477 --cache-file=\"\$ac_sub_cache_file\" --srcdir=\"\$ac_srcdir\"" ||
45478 as_fn_error $? "$ac_sub_configure failed for $ac_dir" "$LINENO" 5
45479 fi
45480
45481 cd "$ac_popdir"
45482 done
45483fi
45484if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
45485 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
45486$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
45487fi
45488
45489
45490
45491 tmp_cpp=`eval echo "$ac_cpp" 2>/dev/null`
45492 if test -z "$tmp_cpp"; then
45493 tmp_cpp='cpp'
45494 fi
45495 cat >./tests/configurehelp.pm <<_EOF
45496# This is a generated file. Do not edit.
45497
45498package configurehelp;
45499
45500use strict;
45501use warnings;
45502use Exporter;
45503
45504use vars qw(
45505 @ISA
45506 @EXPORT_OK
45507 \$Cpreprocessor
45508 );
45509
45510@ISA = qw(Exporter);
45511
45512@EXPORT_OK = qw(
45513 \$Cpreprocessor
45514 );
45515
45516\$Cpreprocessor = '$tmp_cpp';
45517
455181;
45519_EOF
45520
45521
45522
45523## ---------------------------------- ##
45524## Start of distclean amending code ##
45525## ---------------------------------- ##
45526
45527for xc_subdir in lib src tests/unit tests/server tests/libtest docs/examples
45528do
45529
45530if test ! -f "$xc_subdir/Makefile"; then
45531 echo "$xc_msg_err $xc_subdir/Makefile file not found. $xc_msg_abrt" >&2
45532 exit 1
45533fi
45534
45535# Fetch dependency tracking file list from Makefile include lines.
45536
45537xc_inc_lines=`grep '^include .*(DEPDIR)' "$xc_subdir/Makefile" 2>/dev/null`
45538xc_cnt_words=`echo "$xc_inc_lines" | wc -w | tr -d "$xc_space$xc_tab"`
45539
45540# --disable-dependency-tracking might have been used, consequently
45541# there is nothing to amend without a dependency tracking file list.
45542
45543if test $xc_cnt_words -gt 0; then
45544
45545{ $as_echo "$as_me:${as_lineno-$LINENO}: amending $xc_subdir/Makefile" >&5
45546$as_echo "$as_me: amending $xc_subdir/Makefile" >&6;}
45547
45548# Build Makefile specific patch hunk.
45549
45550xc_p="$xc_subdir/xc_patch.tmp"
45551
45552xc_rm_depfiles=`echo "$xc_inc_lines" \
45553 | $SED 's%include% -rm -f%' 2>/dev/null`
45554
45555xc_dep_subdirs=`echo "$xc_inc_lines" \
45556 | $SED 's%include[ ][ ]*%%' 2>/dev/null \
45557 | $SED 's%(DEPDIR)/.*%(DEPDIR)%' 2>/dev/null \
45558 | sort | uniq`
45559
45560echo "$xc_rm_depfiles" >$xc_p
45561
45562for xc_dep_dir in $xc_dep_subdirs; do
45563 echo "${xc_tab}@xm_dep_cnt=\`ls $xc_dep_dir | wc -l 2>/dev/null\`; \\" >>$xc_p
45564 echo "${xc_tab}if test \$\$xm_dep_cnt -eq 0 && test -d $xc_dep_dir; then \\" >>$xc_p
45565 echo "${xc_tab} rm -rf $xc_dep_dir; \\" >>$xc_p
45566 echo "${xc_tab}fi" >>$xc_p
45567done
45568
45569# Build Makefile patching sed scripts.
45570
45571xc_s1="$xc_subdir/xc_script_1.tmp"
45572xc_s2="$xc_subdir/xc_script_2.tmp"
45573xc_s3="$xc_subdir/xc_script_3.tmp"
45574
45575cat >$xc_s1 <<\_EOT
45576/^distclean[ ]*:/,/^[^ ][^ ]*:/{
45577 s/^.*(DEPDIR)/___xc_depdir_line___/
45578}
45579/^maintainer-clean[ ]*:/,/^[^ ][^ ]*:/{
45580 s/^.*(DEPDIR)/___xc_depdir_line___/
45581}
45582_EOT
45583
45584cat >$xc_s2 <<\_EOT
45585/___xc_depdir_line___$/{
45586 N
45587 /___xc_depdir_line___$/D
45588}
45589_EOT
45590
45591cat >$xc_s3 <<_EOT
45592/^___xc_depdir_line___/{
45593 r $xc_p
45594 d
45595}
45596_EOT
45597
45598# Apply patch to Makefile and cleanup.
45599
45600$SED -f "$xc_s1" "$xc_subdir/Makefile" >"$xc_subdir/Makefile.tmp1"
45601$SED -f "$xc_s2" "$xc_subdir/Makefile.tmp1" >"$xc_subdir/Makefile.tmp2"
45602$SED -f "$xc_s3" "$xc_subdir/Makefile.tmp2" >"$xc_subdir/Makefile.tmp3"
45603
45604if test -f "$xc_subdir/Makefile.tmp3"; then
45605 mv -f "$xc_subdir/Makefile.tmp3" "$xc_subdir/Makefile"
45606fi
45607
45608test -f "$xc_subdir/Makefile.tmp1" && rm -f "$xc_subdir/Makefile.tmp1"
45609test -f "$xc_subdir/Makefile.tmp2" && rm -f "$xc_subdir/Makefile.tmp2"
45610test -f "$xc_subdir/Makefile.tmp3" && rm -f "$xc_subdir/Makefile.tmp3"
45611
45612test -f "$xc_p" && rm -f "$xc_p"
45613test -f "$xc_s1" && rm -f "$xc_s1"
45614test -f "$xc_s2" && rm -f "$xc_s2"
45615test -f "$xc_s3" && rm -f "$xc_s3"
45616
45617fi
45618
45619done
45620
45621## -------------------------------- ##
45622## End of distclean amending code ##
45623## -------------------------------- ##
45624
45625
45626
45627{ $as_echo "$as_me:${as_lineno-$LINENO}: Configured to build curl/libcurl:
45628
Elliott Hughes82be86d2017-09-20 17:00:17 -070045629 Host setup: ${host}
45630 Install prefix: ${prefix}
45631 Compiler: ${CC}
Haibo Huang21926d52019-01-08 14:27:10 -080045632 CFLAGS: ${CFLAGS}
45633 CPPFLAGS: ${CPPFLAGS}
45634 LDFLAGS: ${LDFLAGS}
45635 LIBS: ${LIBS}
45636
45637 curl version: ${CURLVERSION}
Haibo Huang65021c72019-03-27 15:37:23 -070045638 SSL: ${curl_ssl_msg}
45639 SSH: ${curl_ssh_msg}
45640 zlib: ${curl_zlib_msg}
45641 brotli: ${curl_brotli_msg}
45642 GSS-API: ${curl_gss_msg}
45643 TLS-SRP: ${curl_tls_srp_msg}
Elliott Hughes82be86d2017-09-20 17:00:17 -070045644 resolver: ${curl_res_msg}
Haibo Huang65021c72019-03-27 15:37:23 -070045645 IPv6: ${curl_ipv6_msg}
45646 Unix sockets: ${curl_unix_sockets_msg}
45647 IDN: ${curl_idn_msg}
Elliott Hughes82be86d2017-09-20 17:00:17 -070045648 Build libcurl: Shared=${enable_shared}, Static=${enable_static}
45649 Built-in manual: ${curl_manual_msg}
45650 --libcurl option: ${curl_libcurl_msg}
45651 Verbose errors: ${curl_verbose_msg}
Haibo Huang51d9d882019-02-06 01:36:06 -080045652 Code coverage: ${curl_coverage_msg}
Haibo Huang65021c72019-03-27 15:37:23 -070045653 SSPI: ${curl_sspi_msg}
Elliott Hughes82be86d2017-09-20 17:00:17 -070045654 ca cert bundle: ${ca}${ca_warning}
45655 ca cert path: ${capath}${capath_warning}
45656 ca fallback: ${with_ca_fallback}
Haibo Huang65021c72019-03-27 15:37:23 -070045657 LDAP: ${curl_ldap_msg}
45658 LDAPS: ${curl_ldaps_msg}
45659 RTSP: ${curl_rtsp_msg}
45660 RTMP: ${curl_rtmp_msg}
45661 Metalink: ${curl_mtlnk_msg}
45662 PSL: ${curl_psl_msg}
45663 Alt-svc: ${curl_altsvc_msg}
45664 HTTP2: ${curl_h2_msg}
Haibo Huang445085a2019-09-11 13:33:50 -070045665 HTTP3: ${curl_h3_msg}
Haibo Huang31944072019-11-06 02:28:57 -080045666 ESNI: ${curl_esni_msg}
Elliott Hughes82be86d2017-09-20 17:00:17 -070045667 Protocols: ${SUPPORT_PROTOCOLS}
Haibo Huang65021c72019-03-27 15:37:23 -070045668 Features: ${SUPPORT_FEATURES}
Elliott Hughes82be86d2017-09-20 17:00:17 -070045669" >&5
45670$as_echo "$as_me: Configured to build curl/libcurl:
45671
Elliott Hughes82be86d2017-09-20 17:00:17 -070045672 Host setup: ${host}
45673 Install prefix: ${prefix}
45674 Compiler: ${CC}
Haibo Huang21926d52019-01-08 14:27:10 -080045675 CFLAGS: ${CFLAGS}
45676 CPPFLAGS: ${CPPFLAGS}
45677 LDFLAGS: ${LDFLAGS}
45678 LIBS: ${LIBS}
45679
45680 curl version: ${CURLVERSION}
Haibo Huang65021c72019-03-27 15:37:23 -070045681 SSL: ${curl_ssl_msg}
45682 SSH: ${curl_ssh_msg}
45683 zlib: ${curl_zlib_msg}
45684 brotli: ${curl_brotli_msg}
45685 GSS-API: ${curl_gss_msg}
45686 TLS-SRP: ${curl_tls_srp_msg}
Elliott Hughes82be86d2017-09-20 17:00:17 -070045687 resolver: ${curl_res_msg}
Haibo Huang65021c72019-03-27 15:37:23 -070045688 IPv6: ${curl_ipv6_msg}
45689 Unix sockets: ${curl_unix_sockets_msg}
45690 IDN: ${curl_idn_msg}
Elliott Hughes82be86d2017-09-20 17:00:17 -070045691 Build libcurl: Shared=${enable_shared}, Static=${enable_static}
45692 Built-in manual: ${curl_manual_msg}
45693 --libcurl option: ${curl_libcurl_msg}
45694 Verbose errors: ${curl_verbose_msg}
Haibo Huang51d9d882019-02-06 01:36:06 -080045695 Code coverage: ${curl_coverage_msg}
Haibo Huang65021c72019-03-27 15:37:23 -070045696 SSPI: ${curl_sspi_msg}
Elliott Hughes82be86d2017-09-20 17:00:17 -070045697 ca cert bundle: ${ca}${ca_warning}
45698 ca cert path: ${capath}${capath_warning}
45699 ca fallback: ${with_ca_fallback}
Haibo Huang65021c72019-03-27 15:37:23 -070045700 LDAP: ${curl_ldap_msg}
45701 LDAPS: ${curl_ldaps_msg}
45702 RTSP: ${curl_rtsp_msg}
45703 RTMP: ${curl_rtmp_msg}
45704 Metalink: ${curl_mtlnk_msg}
45705 PSL: ${curl_psl_msg}
45706 Alt-svc: ${curl_altsvc_msg}
45707 HTTP2: ${curl_h2_msg}
Haibo Huang445085a2019-09-11 13:33:50 -070045708 HTTP3: ${curl_h3_msg}
Haibo Huang31944072019-11-06 02:28:57 -080045709 ESNI: ${curl_esni_msg}
Elliott Hughes82be86d2017-09-20 17:00:17 -070045710 Protocols: ${SUPPORT_PROTOCOLS}
Haibo Huang65021c72019-03-27 15:37:23 -070045711 Features: ${SUPPORT_FEATURES}
Elliott Hughes82be86d2017-09-20 17:00:17 -070045712" >&6;}
Haibo Huang65021c72019-03-27 15:37:23 -070045713if test -n "$experimental"; then
45714 cat >&2 << _EOF
Haibo Huang445085a2019-09-11 13:33:50 -070045715 WARNING: $experimental enabled but marked EXPERIMENTAL. Use with caution!
Haibo Huang65021c72019-03-27 15:37:23 -070045716_EOF
45717fi