blob: 28092b4710d943fd7ff475668793fbf98f09a2b2 [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
908USE_NGHTTP2
909IDN_ENABLED
910CURL_LT_SHLIB_USE_VERSIONED_SYMBOLS_FALSE
911CURL_LT_SHLIB_USE_VERSIONED_SYMBOLS_TRUE
912CURL_LT_SHLIB_VERSIONED_FLAVOUR
913USE_LIBRTMP
Elliott Hughes0128fe42018-02-27 14:57:55 -0800914USE_LIBSSH
Elliott Hughes82be86d2017-09-20 17:00:17 -0700915USE_LIBSSH2
916LIBMETALINK_CPPFLAGS
917LIBMETALINK_LDFLAGS
918LIBMETALINK_LIBS
919USE_LIBPSL_FALSE
920USE_LIBPSL_TRUE
921CURL_CA_BUNDLE
Alex Deymo486467e2017-12-19 19:04:07 +0100922CURL_WITH_MULTI_SSL
Elliott Hughes82be86d2017-09-20 17:00:17 -0700923SSL_ENABLED
Elliott Hughes82be86d2017-09-20 17:00:17 -0700924NSS_LIBS
925USE_NSS
Elliott Hughesa93fb052018-12-12 14:22:48 -0800926USE_MESALINK
Haibo Huang001784b2019-07-19 05:27:28 -0700927USE_WOLFSSL
Elliott Hughes82be86d2017-09-20 17:00:17 -0700928USE_MBEDTLS
Elliott Hughes82be86d2017-09-20 17:00:17 -0700929HAVE_GNUTLS_SRP
930USE_GNUTLS_NETTLE
931USE_GNUTLS
932HAVE_OPENSSL_SRP
933RANDOM_FILE
934SSL_LIBS
Haibo Huang65021c72019-03-27 15:37:23 -0700935USE_SECTRANSP
Elliott Hughes82be86d2017-09-20 17:00:17 -0700936USE_WINDOWS_SSPI
937USE_SCHANNEL
Alex Deymo486467e2017-12-19 19:04:07 +0100938DEFAULT_SSL_BACKEND
939BUILD_STUB_GSS_FALSE
940BUILD_STUB_GSS_TRUE
Elliott Hughes82be86d2017-09-20 17:00:17 -0700941USE_OPENLDAP
Alex Deymo486467e2017-12-19 19:04:07 +0100942HAVE_BROTLI
Elliott Hughes82be86d2017-09-20 17:00:17 -0700943ZLIB_LIBS
944HAVE_LIBZ_FALSE
945HAVE_LIBZ_TRUE
946HAVE_LIBZ
947PKGCONFIG
Haibo Huang65021c72019-03-27 15:37:23 -0700948HAVE_PROTO_BSDSOCKET_H
Elliott Hughes82be86d2017-09-20 17:00:17 -0700949CURL_DISABLE_GOPHER
950CURL_DISABLE_SMTP
951CURL_DISABLE_SMB
952CURL_DISABLE_IMAP
953CURL_DISABLE_POP3
954CURL_DISABLE_TFTP
955CURL_DISABLE_TELNET
956CURL_DISABLE_DICT
957CURL_DISABLE_PROXY
958HAVE_LDAP_SSL
959CURL_DISABLE_LDAPS
960CURL_DISABLE_LDAP
961CURL_DISABLE_FILE
962CURL_DISABLE_FTP
963CURL_DISABLE_RTSP
964CURL_DISABLE_HTTP
965DOING_NATIVE_WINDOWS_FALSE
966DOING_NATIVE_WINDOWS_TRUE
967BUILD_UNITTESTS_FALSE
968BUILD_UNITTESTS_TRUE
969CURLDEBUG_FALSE
970CURLDEBUG_TRUE
971USE_EXPLICIT_LIB_DEPS_FALSE
972USE_EXPLICIT_LIB_DEPS_TRUE
973REQUIRE_LIB_DEPS
974CPPFLAG_CURL_STATICLIB
975USE_CPPFLAG_CURL_STATICLIB_FALSE
976USE_CPPFLAG_CURL_STATICLIB_TRUE
977CURL_LT_SHLIB_USE_MIMPURE_TEXT_FALSE
978CURL_LT_SHLIB_USE_MIMPURE_TEXT_TRUE
979CURL_LT_SHLIB_USE_NO_UNDEFINED_FALSE
980CURL_LT_SHLIB_USE_NO_UNDEFINED_TRUE
981CURL_LT_SHLIB_USE_VERSION_INFO_FALSE
982CURL_LT_SHLIB_USE_VERSION_INFO_TRUE
983LT_SYS_LIBRARY_PATH
984OTOOL64
985OTOOL
986LIPO
987NMEDIT
988DSYMUTIL
989MANIFEST_TOOL
990RANLIB
991ac_ct_AR
992LN_S
993NM
994ac_ct_DUMPBIN
995DUMPBIN
996LD
997FGREP
998LIBTOOL
999OBJDUMP
1000DLLTOOL
1001AS
Elliott Hughes72d948d2018-08-03 14:37:21 -07001002AR_FLAGS
Elliott Hughes82be86d2017-09-20 17:00:17 -07001003host_os
1004host_vendor
1005host_cpu
1006host
1007build_os
1008build_vendor
1009build_cpu
1010build
1011PKGADD_VENDOR
1012PKGADD_NAME
1013PKGADD_PKG
1014VERSIONNUM
1015CURLVERSION
1016am__fastdepCC_FALSE
1017am__fastdepCC_TRUE
1018CCDEPMODE
1019am__nodep
1020AMDEPBACKSLASH
1021AMDEP_FALSE
1022AMDEP_TRUE
Elliott Hughes82be86d2017-09-20 17:00:17 -07001023am__include
1024DEPDIR
1025am__untar
1026am__tar
1027AMTAR
1028am__leading_dot
1029SET_MAKE
1030AWK
1031mkdir_p
1032MKDIR_P
1033INSTALL_STRIP_PROGRAM
1034STRIP
1035install_sh
1036MAKEINFO
1037AUTOHEADER
1038AUTOMAKE
1039AUTOCONF
1040ACLOCAL
1041VERSION
1042PACKAGE
1043CYGPATH_W
1044am__isrc
Elliott Hughes0128fe42018-02-27 14:57:55 -08001045LCOV
1046GCOV
Elliott Hughes82be86d2017-09-20 17:00:17 -07001047CPP
1048OBJEXT
1049EXEEXT
1050ac_ct_CC
1051CPPFLAGS
1052LDFLAGS
1053CFLAGS
1054CC
1055INSTALL_DATA
1056INSTALL_SCRIPT
1057INSTALL_PROGRAM
1058libext
1059AR
1060EGREP
1061GREP
Elliott Hughes0128fe42018-02-27 14:57:55 -08001062SED
Elliott Hughes82be86d2017-09-20 17:00:17 -07001063CURL_CFLAG_EXTRAS
1064CONFIGURE_OPTIONS
Elliott Hughes82be86d2017-09-20 17:00:17 -07001065AM_BACKSLASH
1066AM_DEFAULT_VERBOSITY
1067AM_DEFAULT_V
1068AM_V
1069MAINT
1070MAINTAINER_MODE_FALSE
1071MAINTAINER_MODE_TRUE
1072target_alias
1073host_alias
1074build_alias
1075LIBS
1076ECHO_T
1077ECHO_N
1078ECHO_C
1079DEFS
1080mandir
1081localedir
1082libdir
1083psdir
1084pdfdir
1085dvidir
1086htmldir
1087infodir
1088docdir
1089oldincludedir
1090includedir
1091runstatedir
1092localstatedir
1093sharedstatedir
1094sysconfdir
1095datadir
1096datarootdir
1097libexecdir
1098sbindir
1099bindir
1100program_transform_name
1101prefix
1102exec_prefix
1103PACKAGE_URL
1104PACKAGE_BUGREPORT
1105PACKAGE_STRING
1106PACKAGE_VERSION
1107PACKAGE_TARNAME
1108PACKAGE_NAME
1109SHELL
Haibo Huang001784b2019-07-19 05:27:28 -07001110PATH_SEPARATOR
1111am__quote'
Elliott Hughes82be86d2017-09-20 17:00:17 -07001112ac_subst_files=''
1113ac_user_opts='
1114enable_option_checking
1115enable_maintainer_mode
1116enable_silent_rules
1117enable_debug
1118enable_optimize
1119enable_warnings
1120enable_werror
1121enable_curldebug
1122enable_symbol_hiding
1123enable_hidden_symbols
1124enable_ares
1125enable_rt
Elliott Hughes82be86d2017-09-20 17:00:17 -07001126enable_code_coverage
1127enable_dependency_tracking
1128enable_largefile
1129enable_shared
1130enable_static
1131with_pic
1132enable_fast_install
1133with_aix_soname
1134with_gnu_ld
1135with_sysroot
1136enable_libtool_lock
1137enable_http
1138enable_ftp
1139enable_file
1140enable_ldap
1141enable_ldaps
1142enable_rtsp
1143enable_proxy
1144enable_dict
1145enable_telnet
1146enable_tftp
1147enable_pop3
1148enable_imap
1149enable_smb
1150enable_smtp
1151enable_gopher
1152enable_manual
1153enable_libcurl_option
1154enable_libgcc
1155with_zlib
Alex Deymo486467e2017-12-19 19:04:07 +01001156with_brotli
Elliott Hughes82be86d2017-09-20 17:00:17 -07001157with_ldap_lib
1158with_lber_lib
1159enable_ipv6
1160with_gssapi_includes
1161with_gssapi_libs
1162with_gssapi
Alex Deymo486467e2017-12-19 19:04:07 +01001163with_default_ssl_backend
Elliott Hughes82be86d2017-09-20 17:00:17 -07001164with_winssl
Haibo Huang51d9d882019-02-06 01:36:06 -08001165with_schannel
Elliott Hughes82be86d2017-09-20 17:00:17 -07001166with_darwinssl
Haibo Huang65021c72019-03-27 15:37:23 -07001167with_secure_transport
1168with_amissl
Elliott Hughes82be86d2017-09-20 17:00:17 -07001169with_ssl
1170with_egd_socket
1171with_random
Elliott Hughesa93fb052018-12-12 14:22:48 -08001172enable_openssl_auto_load_config
Elliott Hughes82be86d2017-09-20 17:00:17 -07001173with_gnutls
Elliott Hughes82be86d2017-09-20 17:00:17 -07001174with_mbedtls
1175with_cyassl
Elliott Hughes1ef06ba2018-05-30 15:43:58 -07001176with_wolfssl
Elliott Hughesa93fb052018-12-12 14:22:48 -08001177with_mesalink
Elliott Hughes82be86d2017-09-20 17:00:17 -07001178with_nss
Elliott Hughes82be86d2017-09-20 17:00:17 -07001179with_ca_bundle
1180with_ca_path
1181with_ca_fallback
1182with_libpsl
1183with_libmetalink
1184with_libssh2
Elliott Hughes0128fe42018-02-27 14:57:55 -08001185with_libssh
Elliott Hughes82be86d2017-09-20 17:00:17 -07001186with_librtmp
1187enable_versioned_symbols
1188with_winidn
1189with_libidn2
1190with_nghttp2
1191with_zsh_functions_dir
Haibo Huang65021c72019-03-27 15:37:23 -07001192with_fish_functions_dir
Elliott Hughes82be86d2017-09-20 17:00:17 -07001193enable_threaded_resolver
1194enable_pthreads
1195enable_verbose
1196enable_sspi
1197enable_crypto_auth
1198enable_ntlm_wb
1199enable_tls_srp
1200enable_unix_sockets
1201enable_cookies
Haibo Huang001784b2019-07-19 05:27:28 -07001202enable_http_auth
1203enable_doh
1204enable_mime
1205enable_dateparse
1206enable_netrc
1207enable_progress_meter
1208enable_dnsshuffle
Haibo Huang65021c72019-03-27 15:37:23 -07001209enable_alt_svc
Elliott Hughes82be86d2017-09-20 17:00:17 -07001210'
1211 ac_precious_vars='build_alias
1212host_alias
1213target_alias
1214CC
1215CFLAGS
1216LDFLAGS
1217LIBS
1218CPPFLAGS
1219CPP
1220LT_SYS_LIBRARY_PATH'
1221ac_subdirs_all='ares'
1222
1223# Initialize some variables set by options.
1224ac_init_help=
1225ac_init_version=false
1226ac_unrecognized_opts=
1227ac_unrecognized_sep=
1228# The variables have the same names as the options, with
1229# dashes changed to underlines.
1230cache_file=/dev/null
1231exec_prefix=NONE
1232no_create=
1233no_recursion=
1234prefix=NONE
1235program_prefix=NONE
1236program_suffix=NONE
1237program_transform_name=s,x,x,
1238silent=
1239site=
1240srcdir=
1241verbose=
1242x_includes=NONE
1243x_libraries=NONE
1244
1245# Installation directory options.
1246# These are left unexpanded so users can "make install exec_prefix=/foo"
1247# and all the variables that are supposed to be based on exec_prefix
1248# by default will actually change.
1249# Use braces instead of parens because sh, perl, etc. also accept them.
1250# (The list follows the same order as the GNU Coding Standards.)
1251bindir='${exec_prefix}/bin'
1252sbindir='${exec_prefix}/sbin'
1253libexecdir='${exec_prefix}/libexec'
1254datarootdir='${prefix}/share'
1255datadir='${datarootdir}'
1256sysconfdir='${prefix}/etc'
1257sharedstatedir='${prefix}/com'
1258localstatedir='${prefix}/var'
1259runstatedir='${localstatedir}/run'
1260includedir='${prefix}/include'
1261oldincludedir='/usr/include'
1262docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
1263infodir='${datarootdir}/info'
1264htmldir='${docdir}'
1265dvidir='${docdir}'
1266pdfdir='${docdir}'
1267psdir='${docdir}'
1268libdir='${exec_prefix}/lib'
1269localedir='${datarootdir}/locale'
1270mandir='${datarootdir}/man'
1271
1272ac_prev=
1273ac_dashdash=
1274for ac_option
1275do
1276 # If the previous option needs an argument, assign it.
1277 if test -n "$ac_prev"; then
1278 eval $ac_prev=\$ac_option
1279 ac_prev=
1280 continue
1281 fi
1282
1283 case $ac_option in
1284 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1285 *=) ac_optarg= ;;
1286 *) ac_optarg=yes ;;
1287 esac
1288
1289 # Accept the important Cygnus configure options, so we can diagnose typos.
1290
1291 case $ac_dashdash$ac_option in
1292 --)
1293 ac_dashdash=yes ;;
1294
1295 -bindir | --bindir | --bindi | --bind | --bin | --bi)
1296 ac_prev=bindir ;;
1297 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1298 bindir=$ac_optarg ;;
1299
1300 -build | --build | --buil | --bui | --bu)
1301 ac_prev=build_alias ;;
1302 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1303 build_alias=$ac_optarg ;;
1304
1305 -cache-file | --cache-file | --cache-fil | --cache-fi \
1306 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1307 ac_prev=cache_file ;;
1308 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1309 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1310 cache_file=$ac_optarg ;;
1311
1312 --config-cache | -C)
1313 cache_file=config.cache ;;
1314
1315 -datadir | --datadir | --datadi | --datad)
1316 ac_prev=datadir ;;
1317 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1318 datadir=$ac_optarg ;;
1319
1320 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1321 | --dataroo | --dataro | --datar)
1322 ac_prev=datarootdir ;;
1323 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1324 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1325 datarootdir=$ac_optarg ;;
1326
1327 -disable-* | --disable-*)
1328 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1329 # Reject names that are not valid shell variable names.
1330 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1331 as_fn_error $? "invalid feature name: $ac_useropt"
1332 ac_useropt_orig=$ac_useropt
1333 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1334 case $ac_user_opts in
1335 *"
1336"enable_$ac_useropt"
1337"*) ;;
1338 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1339 ac_unrecognized_sep=', ';;
1340 esac
1341 eval enable_$ac_useropt=no ;;
1342
1343 -docdir | --docdir | --docdi | --doc | --do)
1344 ac_prev=docdir ;;
1345 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1346 docdir=$ac_optarg ;;
1347
1348 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1349 ac_prev=dvidir ;;
1350 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1351 dvidir=$ac_optarg ;;
1352
1353 -enable-* | --enable-*)
1354 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1355 # Reject names that are not valid shell variable names.
1356 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1357 as_fn_error $? "invalid feature name: $ac_useropt"
1358 ac_useropt_orig=$ac_useropt
1359 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1360 case $ac_user_opts in
1361 *"
1362"enable_$ac_useropt"
1363"*) ;;
1364 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1365 ac_unrecognized_sep=', ';;
1366 esac
1367 eval enable_$ac_useropt=\$ac_optarg ;;
1368
1369 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1370 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1371 | --exec | --exe | --ex)
1372 ac_prev=exec_prefix ;;
1373 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1374 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1375 | --exec=* | --exe=* | --ex=*)
1376 exec_prefix=$ac_optarg ;;
1377
1378 -gas | --gas | --ga | --g)
1379 # Obsolete; use --with-gas.
1380 with_gas=yes ;;
1381
1382 -help | --help | --hel | --he | -h)
1383 ac_init_help=long ;;
1384 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1385 ac_init_help=recursive ;;
1386 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1387 ac_init_help=short ;;
1388
1389 -host | --host | --hos | --ho)
1390 ac_prev=host_alias ;;
1391 -host=* | --host=* | --hos=* | --ho=*)
1392 host_alias=$ac_optarg ;;
1393
1394 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1395 ac_prev=htmldir ;;
1396 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1397 | --ht=*)
1398 htmldir=$ac_optarg ;;
1399
1400 -includedir | --includedir | --includedi | --included | --include \
1401 | --includ | --inclu | --incl | --inc)
1402 ac_prev=includedir ;;
1403 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1404 | --includ=* | --inclu=* | --incl=* | --inc=*)
1405 includedir=$ac_optarg ;;
1406
1407 -infodir | --infodir | --infodi | --infod | --info | --inf)
1408 ac_prev=infodir ;;
1409 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1410 infodir=$ac_optarg ;;
1411
1412 -libdir | --libdir | --libdi | --libd)
1413 ac_prev=libdir ;;
1414 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1415 libdir=$ac_optarg ;;
1416
1417 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1418 | --libexe | --libex | --libe)
1419 ac_prev=libexecdir ;;
1420 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1421 | --libexe=* | --libex=* | --libe=*)
1422 libexecdir=$ac_optarg ;;
1423
1424 -localedir | --localedir | --localedi | --localed | --locale)
1425 ac_prev=localedir ;;
1426 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1427 localedir=$ac_optarg ;;
1428
1429 -localstatedir | --localstatedir | --localstatedi | --localstated \
1430 | --localstate | --localstat | --localsta | --localst | --locals)
1431 ac_prev=localstatedir ;;
1432 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1433 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1434 localstatedir=$ac_optarg ;;
1435
1436 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1437 ac_prev=mandir ;;
1438 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1439 mandir=$ac_optarg ;;
1440
1441 -nfp | --nfp | --nf)
1442 # Obsolete; use --without-fp.
1443 with_fp=no ;;
1444
1445 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1446 | --no-cr | --no-c | -n)
1447 no_create=yes ;;
1448
1449 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1450 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1451 no_recursion=yes ;;
1452
1453 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1454 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1455 | --oldin | --oldi | --old | --ol | --o)
1456 ac_prev=oldincludedir ;;
1457 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1458 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1459 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1460 oldincludedir=$ac_optarg ;;
1461
1462 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1463 ac_prev=prefix ;;
1464 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1465 prefix=$ac_optarg ;;
1466
1467 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1468 | --program-pre | --program-pr | --program-p)
1469 ac_prev=program_prefix ;;
1470 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1471 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1472 program_prefix=$ac_optarg ;;
1473
1474 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1475 | --program-suf | --program-su | --program-s)
1476 ac_prev=program_suffix ;;
1477 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1478 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1479 program_suffix=$ac_optarg ;;
1480
1481 -program-transform-name | --program-transform-name \
1482 | --program-transform-nam | --program-transform-na \
1483 | --program-transform-n | --program-transform- \
1484 | --program-transform | --program-transfor \
1485 | --program-transfo | --program-transf \
1486 | --program-trans | --program-tran \
1487 | --progr-tra | --program-tr | --program-t)
1488 ac_prev=program_transform_name ;;
1489 -program-transform-name=* | --program-transform-name=* \
1490 | --program-transform-nam=* | --program-transform-na=* \
1491 | --program-transform-n=* | --program-transform-=* \
1492 | --program-transform=* | --program-transfor=* \
1493 | --program-transfo=* | --program-transf=* \
1494 | --program-trans=* | --program-tran=* \
1495 | --progr-tra=* | --program-tr=* | --program-t=*)
1496 program_transform_name=$ac_optarg ;;
1497
1498 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1499 ac_prev=pdfdir ;;
1500 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1501 pdfdir=$ac_optarg ;;
1502
1503 -psdir | --psdir | --psdi | --psd | --ps)
1504 ac_prev=psdir ;;
1505 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1506 psdir=$ac_optarg ;;
1507
1508 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1509 | -silent | --silent | --silen | --sile | --sil)
1510 silent=yes ;;
1511
1512 -runstatedir | --runstatedir | --runstatedi | --runstated \
1513 | --runstate | --runstat | --runsta | --runst | --runs \
1514 | --run | --ru | --r)
1515 ac_prev=runstatedir ;;
1516 -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
1517 | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \
1518 | --run=* | --ru=* | --r=*)
1519 runstatedir=$ac_optarg ;;
1520
1521 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1522 ac_prev=sbindir ;;
1523 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1524 | --sbi=* | --sb=*)
1525 sbindir=$ac_optarg ;;
1526
1527 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1528 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1529 | --sharedst | --shareds | --shared | --share | --shar \
1530 | --sha | --sh)
1531 ac_prev=sharedstatedir ;;
1532 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1533 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1534 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1535 | --sha=* | --sh=*)
1536 sharedstatedir=$ac_optarg ;;
1537
1538 -site | --site | --sit)
1539 ac_prev=site ;;
1540 -site=* | --site=* | --sit=*)
1541 site=$ac_optarg ;;
1542
1543 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1544 ac_prev=srcdir ;;
1545 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1546 srcdir=$ac_optarg ;;
1547
1548 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1549 | --syscon | --sysco | --sysc | --sys | --sy)
1550 ac_prev=sysconfdir ;;
1551 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1552 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1553 sysconfdir=$ac_optarg ;;
1554
1555 -target | --target | --targe | --targ | --tar | --ta | --t)
1556 ac_prev=target_alias ;;
1557 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1558 target_alias=$ac_optarg ;;
1559
1560 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1561 verbose=yes ;;
1562
1563 -version | --version | --versio | --versi | --vers | -V)
1564 ac_init_version=: ;;
1565
1566 -with-* | --with-*)
1567 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1568 # Reject names that are not valid shell variable names.
1569 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1570 as_fn_error $? "invalid package name: $ac_useropt"
1571 ac_useropt_orig=$ac_useropt
1572 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1573 case $ac_user_opts in
1574 *"
1575"with_$ac_useropt"
1576"*) ;;
1577 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1578 ac_unrecognized_sep=', ';;
1579 esac
1580 eval with_$ac_useropt=\$ac_optarg ;;
1581
1582 -without-* | --without-*)
1583 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1584 # Reject names that are not valid shell variable names.
1585 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1586 as_fn_error $? "invalid package name: $ac_useropt"
1587 ac_useropt_orig=$ac_useropt
1588 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1589 case $ac_user_opts in
1590 *"
1591"with_$ac_useropt"
1592"*) ;;
1593 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1594 ac_unrecognized_sep=', ';;
1595 esac
1596 eval with_$ac_useropt=no ;;
1597
1598 --x)
1599 # Obsolete; use --with-x.
1600 with_x=yes ;;
1601
1602 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1603 | --x-incl | --x-inc | --x-in | --x-i)
1604 ac_prev=x_includes ;;
1605 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1606 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1607 x_includes=$ac_optarg ;;
1608
1609 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1610 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1611 ac_prev=x_libraries ;;
1612 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1613 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1614 x_libraries=$ac_optarg ;;
1615
1616 -*) as_fn_error $? "unrecognized option: \`$ac_option'
1617Try \`$0 --help' for more information"
1618 ;;
1619
1620 *=*)
1621 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1622 # Reject names that are not valid shell variable names.
1623 case $ac_envvar in #(
1624 '' | [0-9]* | *[!_$as_cr_alnum]* )
1625 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1626 esac
1627 eval $ac_envvar=\$ac_optarg
1628 export $ac_envvar ;;
1629
1630 *)
1631 # FIXME: should be removed in autoconf 3.0.
1632 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1633 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1634 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1635 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1636 ;;
1637
1638 esac
1639done
1640
1641if test -n "$ac_prev"; then
1642 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1643 as_fn_error $? "missing argument to $ac_option"
1644fi
1645
1646if test -n "$ac_unrecognized_opts"; then
1647 case $enable_option_checking in
1648 no) ;;
1649 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1650 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1651 esac
1652fi
1653
1654# Check all directory arguments for consistency.
1655for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1656 datadir sysconfdir sharedstatedir localstatedir includedir \
1657 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1658 libdir localedir mandir runstatedir
1659do
1660 eval ac_val=\$$ac_var
1661 # Remove trailing slashes.
1662 case $ac_val in
1663 */ )
1664 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1665 eval $ac_var=\$ac_val;;
1666 esac
1667 # Be sure to have absolute directory names.
1668 case $ac_val in
1669 [\\/$]* | ?:[\\/]* ) continue;;
1670 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1671 esac
1672 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1673done
1674
1675# There might be people who depend on the old broken behavior: `$host'
1676# used to hold the argument of --host etc.
1677# FIXME: To remove some day.
1678build=$build_alias
1679host=$host_alias
1680target=$target_alias
1681
1682# FIXME: To remove some day.
1683if test "x$host_alias" != x; then
1684 if test "x$build_alias" = x; then
1685 cross_compiling=maybe
1686 elif test "x$build_alias" != "x$host_alias"; then
1687 cross_compiling=yes
1688 fi
1689fi
1690
1691ac_tool_prefix=
1692test -n "$host_alias" && ac_tool_prefix=$host_alias-
1693
1694test "$silent" = yes && exec 6>/dev/null
1695
1696
1697ac_pwd=`pwd` && test -n "$ac_pwd" &&
1698ac_ls_di=`ls -di .` &&
1699ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1700 as_fn_error $? "working directory cannot be determined"
1701test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1702 as_fn_error $? "pwd does not report name of working directory"
1703
1704
1705# Find the source files, if location was not specified.
1706if test -z "$srcdir"; then
1707 ac_srcdir_defaulted=yes
1708 # Try the directory containing this script, then the parent directory.
1709 ac_confdir=`$as_dirname -- "$as_myself" ||
1710$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1711 X"$as_myself" : 'X\(//\)[^/]' \| \
1712 X"$as_myself" : 'X\(//\)$' \| \
1713 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1714$as_echo X"$as_myself" |
1715 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1716 s//\1/
1717 q
1718 }
1719 /^X\(\/\/\)[^/].*/{
1720 s//\1/
1721 q
1722 }
1723 /^X\(\/\/\)$/{
1724 s//\1/
1725 q
1726 }
1727 /^X\(\/\).*/{
1728 s//\1/
1729 q
1730 }
1731 s/.*/./; q'`
1732 srcdir=$ac_confdir
1733 if test ! -r "$srcdir/$ac_unique_file"; then
1734 srcdir=..
1735 fi
1736else
1737 ac_srcdir_defaulted=no
1738fi
1739if test ! -r "$srcdir/$ac_unique_file"; then
1740 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1741 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1742fi
1743ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1744ac_abs_confdir=`(
1745 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1746 pwd)`
1747# When building in place, set srcdir=.
1748if test "$ac_abs_confdir" = "$ac_pwd"; then
1749 srcdir=.
1750fi
1751# Remove unnecessary trailing slashes from srcdir.
1752# Double slashes in file names in object file debugging info
1753# mess up M-x gdb in Emacs.
1754case $srcdir in
1755*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1756esac
1757for ac_var in $ac_precious_vars; do
1758 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1759 eval ac_env_${ac_var}_value=\$${ac_var}
1760 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1761 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1762done
1763
1764#
1765# Report the --help message.
1766#
1767if test "$ac_init_help" = "long"; then
1768 # Omit some internal or obsolete options to make the list less imposing.
1769 # This message is too long to be a string in the A/UX 3.1 sh.
1770 cat <<_ACEOF
1771\`configure' configures curl - to adapt to many kinds of systems.
1772
1773Usage: $0 [OPTION]... [VAR=VALUE]...
1774
1775To assign environment variables (e.g., CC, CFLAGS...), specify them as
1776VAR=VALUE. See below for descriptions of some of the useful variables.
1777
1778Defaults for the options are specified in brackets.
1779
1780Configuration:
1781 -h, --help display this help and exit
1782 --help=short display options specific to this package
1783 --help=recursive display the short help of all the included packages
1784 -V, --version display version information and exit
1785 -q, --quiet, --silent do not print \`checking ...' messages
1786 --cache-file=FILE cache test results in FILE [disabled]
1787 -C, --config-cache alias for \`--cache-file=config.cache'
1788 -n, --no-create do not create output files
1789 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1790
1791Installation directories:
1792 --prefix=PREFIX install architecture-independent files in PREFIX
1793 [$ac_default_prefix]
1794 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1795 [PREFIX]
1796
1797By default, \`make install' will install all the files in
1798\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1799an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1800for instance \`--prefix=\$HOME'.
1801
1802For better control, use the options below.
1803
1804Fine tuning of the installation directories:
1805 --bindir=DIR user executables [EPREFIX/bin]
1806 --sbindir=DIR system admin executables [EPREFIX/sbin]
1807 --libexecdir=DIR program executables [EPREFIX/libexec]
1808 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1809 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1810 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1811 --runstatedir=DIR modifiable per-process data [LOCALSTATEDIR/run]
1812 --libdir=DIR object code libraries [EPREFIX/lib]
1813 --includedir=DIR C header files [PREFIX/include]
1814 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1815 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1816 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1817 --infodir=DIR info documentation [DATAROOTDIR/info]
1818 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1819 --mandir=DIR man documentation [DATAROOTDIR/man]
1820 --docdir=DIR documentation root [DATAROOTDIR/doc/curl]
1821 --htmldir=DIR html documentation [DOCDIR]
1822 --dvidir=DIR dvi documentation [DOCDIR]
1823 --pdfdir=DIR pdf documentation [DOCDIR]
1824 --psdir=DIR ps documentation [DOCDIR]
1825_ACEOF
1826
1827 cat <<\_ACEOF
1828
1829Program names:
1830 --program-prefix=PREFIX prepend PREFIX to installed program names
1831 --program-suffix=SUFFIX append SUFFIX to installed program names
1832 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
1833
1834System types:
1835 --build=BUILD configure for building on BUILD [guessed]
1836 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1837_ACEOF
1838fi
1839
1840if test -n "$ac_init_help"; then
1841 case $ac_init_help in
1842 short | recursive ) echo "Configuration of curl -:";;
1843 esac
1844 cat <<\_ACEOF
1845
1846Optional Features:
1847 --disable-option-checking ignore unrecognized --enable/--with options
1848 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1849 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
1850 --enable-maintainer-mode
1851 enable make rules and dependencies not useful (and
1852 sometimes confusing) to the casual installer
1853 --enable-silent-rules less verbose build output (undo: "make V=1")
1854 --disable-silent-rules verbose build output (undo: "make V=0")
1855 --enable-debug Enable debug build options
1856 --disable-debug Disable debug build options
1857 --enable-optimize Enable compiler optimizations
1858 --disable-optimize Disable compiler optimizations
1859 --enable-warnings Enable strict compiler warnings
1860 --disable-warnings Disable strict compiler warnings
1861 --enable-werror Enable compiler warnings as errors
1862 --disable-werror Disable compiler warnings as errors
1863 --enable-curldebug Enable curl debug memory tracking
1864 --disable-curldebug Disable curl debug memory tracking
1865 --enable-symbol-hiding Enable hiding of library internal symbols
1866 --disable-symbol-hiding Disable hiding of library internal symbols
1867 --enable-hidden-symbols To be deprecated, use --enable-symbol-hiding
1868 --disable-hidden-symbols
1869 To be deprecated, use --disable-symbol-hiding
1870 --enable-ares[=PATH] Enable c-ares for DNS lookups
1871 --disable-ares Disable c-ares for DNS lookups
1872 --disable-rt disable dependency on -lrt
Haibo Huang51d9d882019-02-06 01:36:06 -08001873 --enable-code-coverage Provide code coverage
Elliott Hughes82be86d2017-09-20 17:00:17 -07001874 --enable-dependency-tracking
1875 do not reject slow dependency extractors
1876 --disable-dependency-tracking
1877 speeds up one-time build
1878 --disable-largefile omit support for large files
1879 --enable-shared[=PKGS] build shared libraries [default=yes]
1880 --enable-static[=PKGS] build static libraries [default=yes]
1881 --enable-fast-install[=PKGS]
1882 optimize for fast installation [default=yes]
1883 --disable-libtool-lock avoid locking (might break parallel builds)
1884 --enable-http Enable HTTP support
1885 --disable-http Disable HTTP support
1886 --enable-ftp Enable FTP support
1887 --disable-ftp Disable FTP support
1888 --enable-file Enable FILE support
1889 --disable-file Disable FILE support
1890 --enable-ldap Enable LDAP support
1891 --disable-ldap Disable LDAP support
1892 --enable-ldaps Enable LDAPS support
1893 --disable-ldaps Disable LDAPS support
1894 --enable-rtsp Enable RTSP support
1895 --disable-rtsp Disable RTSP support
1896 --enable-proxy Enable proxy support
1897 --disable-proxy Disable proxy support
1898 --enable-dict Enable DICT support
1899 --disable-dict Disable DICT support
1900 --enable-telnet Enable TELNET support
1901 --disable-telnet Disable TELNET support
1902 --enable-tftp Enable TFTP support
1903 --disable-tftp Disable TFTP support
1904 --enable-pop3 Enable POP3 support
1905 --disable-pop3 Disable POP3 support
1906 --enable-imap Enable IMAP support
1907 --disable-imap Disable IMAP support
1908 --enable-smb Enable SMB/CIFS support
1909 --disable-smb Disable SMB/CIFS support
1910 --enable-smtp Enable SMTP support
1911 --disable-smtp Disable SMTP support
1912 --enable-gopher Enable Gopher support
1913 --disable-gopher Disable Gopher support
1914 --enable-manual Enable built-in manual
1915 --disable-manual Disable built-in manual
1916 --enable-libcurl-option Enable --libcurl C code generation support
1917 --disable-libcurl-option
1918 Disable --libcurl C code generation support
1919 --enable-libgcc use libgcc when linking
1920 --enable-ipv6 Enable IPv6 (with IPv4) support
1921 --disable-ipv6 Disable IPv6 support
Elliott Hughesa93fb052018-12-12 14:22:48 -08001922 --enable-openssl-auto-load-config
1923 Enable automatic loading of OpenSSL configuration
1924 --disable-openssl-auto-load-config
1925 Disable automatic loading of OpenSSL configuration
Elliott Hughes82be86d2017-09-20 17:00:17 -07001926 --enable-versioned-symbols
1927 Enable versioned symbols in shared library
1928 --disable-versioned-symbols
1929 Disable versioned symbols in shared library
1930 --enable-threaded-resolver
1931 Enable threaded resolver
1932 --disable-threaded-resolver
1933 Disable threaded resolver
1934 --enable-pthreads Enable POSIX threads (default for threaded resolver)
1935 --disable-pthreads Disable POSIX threads
1936 --enable-verbose Enable verbose strings
1937 --disable-verbose Disable verbose strings
1938 --enable-sspi Enable SSPI
1939 --disable-sspi Disable SSPI
1940 --enable-crypto-auth Enable cryptographic authentication
1941 --disable-crypto-auth Disable cryptographic authentication
1942 --enable-ntlm-wb[=FILE] Enable NTLM delegation to winbind's ntlm_auth
1943 helper, where FILE is ntlm_auth's absolute filename
1944 (default: /usr/bin/ntlm_auth)
1945 --disable-ntlm-wb Disable NTLM delegation to winbind's ntlm_auth
1946 helper
1947 --enable-tls-srp Enable TLS-SRP authentication
1948 --disable-tls-srp Disable TLS-SRP authentication
1949 --enable-unix-sockets Enable Unix domain sockets
1950 --disable-unix-sockets Disable Unix domain sockets
1951 --enable-cookies Enable cookies support
1952 --disable-cookies Disable cookies support
Haibo Huang001784b2019-07-19 05:27:28 -07001953 --enable-http-auth Enable HTTP authentication support
1954 --disable-http-auth Disable HTTP authentication support
1955 --enable-doh Enable DoH support
1956 --disable-doh Disable DoH support
1957 --enable-mime Enable mime API support
1958 --disable-mime Disable mime API support
1959 --enable-dateparse Enable date parsing
1960 --disable-dateparse Disable date parsing
1961 --enable-netrc Enable netrc parsing
1962 --disable-netrc Disable netrc parsing
1963 --enable-progress-meter Enable progress-meter
1964 --disable-progress-meter
1965 Disable progress-meter
1966 --enable-dnsshuffle Enable DNS shuffling
1967 --disable-dnsshuffle Disable DNS shufflinf
Haibo Huang65021c72019-03-27 15:37:23 -07001968 --enable-alt-svc Enable alt-svc support
1969 --disable-alt-svc Disable alt-svc support
Elliott Hughes82be86d2017-09-20 17:00:17 -07001970
1971Optional Packages:
1972 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1973 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
Elliott Hughes82be86d2017-09-20 17:00:17 -07001974 --with-pic[=PKGS] try to use only PIC/non-PIC objects [default=use
1975 both]
1976 --with-aix-soname=aix|svr4|both
1977 shared library versioning (aka "SONAME") variant to
1978 provide on AIX, [default=aix].
1979 --with-gnu-ld assume the C compiler uses GNU ld [default=no]
1980 --with-sysroot[=DIR] Search for dependent libraries within DIR (or the
1981 compiler's sysroot if not specified).
1982 --with-zlib=PATH search for zlib in PATH
1983 --without-zlib disable use of zlib
Alex Deymo486467e2017-12-19 19:04:07 +01001984 --with-brotli=PATH Where to look for brotli, PATH points to the BROTLI
1985 installation; when possible, set the PKG_CONFIG_PATH
1986 environment variable instead of using this option
1987 --without-brotli disable BROTLI
Elliott Hughes82be86d2017-09-20 17:00:17 -07001988 --with-ldap-lib=libname Specify name of ldap lib file
1989 --with-lber-lib=libname Specify name of lber lib file
1990 --with-gssapi-includes=DIR
1991 Specify location of GSS-API headers
1992 --with-gssapi-libs=DIR Specify location of GSS-API libs
1993 --with-gssapi=DIR Where to look for GSS-API
Alex Deymo486467e2017-12-19 19:04:07 +01001994 --with-default-ssl-backend=NAME
1995 Use NAME as default SSL backend
1996 --without-default-ssl-backend
1997 Use implicit default SSL backend
Elliott Hughes82be86d2017-09-20 17:00:17 -07001998 --with-winssl enable Windows native SSL/TLS
1999 --without-winssl disable Windows native SSL/TLS
Haibo Huang51d9d882019-02-06 01:36:06 -08002000 --with-schannel enable Windows native SSL/TLS
2001 --without-schannel disable Windows native SSL/TLS
Elliott Hughes82be86d2017-09-20 17:00:17 -07002002 --with-darwinssl enable Apple OS native SSL/TLS
2003 --without-darwinssl disable Apple OS native SSL/TLS
Haibo Huang65021c72019-03-27 15:37:23 -07002004 --with-secure-transport enable Apple OS native SSL/TLS
2005 --without-secure-transport
2006 disable Apple OS native SSL/TLS
2007 --with-amissl enable Amiga native SSL/TLS (AmiSSL)
2008 --without-amissl disable Amiga native SSL/TLS (AmiSSL)
Elliott Hughes82be86d2017-09-20 17:00:17 -07002009 --with-ssl=PATH Where to look for OpenSSL, PATH points to the SSL
2010 installation (default: /usr/local/ssl); when
2011 possible, set the PKG_CONFIG_PATH environment
2012 variable instead of using this option
2013 --without-ssl disable OpenSSL
2014 --with-egd-socket=FILE Entropy Gathering Daemon socket pathname
2015 --with-random=FILE read randomness from FILE (default=/dev/urandom)
2016 --with-gnutls=PATH where to look for GnuTLS, PATH points to the
2017 installation root
2018 --without-gnutls disable GnuTLS detection
Elliott Hughes82be86d2017-09-20 17:00:17 -07002019 --with-mbedtls=PATH where to look for mbedTLS, PATH points to the
2020 installation root
2021 --without-mbedtls disable mbedTLS detection
2022 --with-cyassl=PATH where to look for CyaSSL, PATH points to the
2023 installation root (default: system lib default)
2024 --without-cyassl disable CyaSSL detection
Elliott Hughes1ef06ba2018-05-30 15:43:58 -07002025 --with-wolfssl=PATH where to look for WolfSSL, PATH points to the
2026 installation root (default: system lib default)
2027 --without-wolfssl disable WolfSSL detection
Elliott Hughesa93fb052018-12-12 14:22:48 -08002028 --with-mesalink=PATH where to look for MesaLink, PATH points to the
2029 installation root
2030 --without-mesalink disable MesaLink detection
Elliott Hughes82be86d2017-09-20 17:00:17 -07002031 --with-nss=PATH where to look for NSS, PATH points to the
2032 installation root
2033 --without-nss disable NSS detection
Elliott Hughes82be86d2017-09-20 17:00:17 -07002034 --with-ca-bundle=FILE Path to a file containing CA certificates (example:
2035 /etc/ca-bundle.crt)
2036 --without-ca-bundle Don't use a default CA bundle
2037 --with-ca-path=DIRECTORY
2038 Path to a directory containing CA certificates
2039 stored individually, with their filenames in a hash
2040 format. This option can be used with OpenSSL, GnuTLS
2041 and PolarSSL backends. Refer to OpenSSL c_rehash for
2042 details. (example: /etc/certificates)
2043 --without-ca-path Don't use a default CA path
2044 --with-ca-fallback Use the built in CA store of the SSL library
2045 --without-ca-fallback Don't use the built in CA store of the SSL library
2046 --without-libpsl disable support for libpsl cookie checking
2047 --with-libmetalink=PATH where to look for libmetalink, PATH points to the
2048 installation root
2049 --without-libmetalink disable libmetalink detection
2050 --with-libssh2=PATH Where to look for libssh2, PATH points to the
2051 LIBSSH2 installation; when possible, set the
2052 PKG_CONFIG_PATH environment variable instead of
2053 using this option
Elliott Hughes0128fe42018-02-27 14:57:55 -08002054 --with-libssh2 enable LIBSSH2
2055 --with-libssh=PATH Where to look for libssh, PATH points to the LIBSSH
2056 installation; when possible, set the PKG_CONFIG_PATH
2057 environment variable instead of using this option
2058 --with-libssh enable LIBSSH
Elliott Hughes82be86d2017-09-20 17:00:17 -07002059 --with-librtmp=PATH Where to look for librtmp, PATH points to the
2060 LIBRTMP installation; when possible, set the
2061 PKG_CONFIG_PATH environment variable instead of
2062 using this option
2063 --without-librtmp disable LIBRTMP
2064 --with-winidn=PATH enable Windows native IDN
2065 --without-winidn disable Windows native IDN
2066 --with-libidn2=PATH Enable libidn2 usage
2067 --without-libidn2 Disable libidn2 usage
2068 --with-nghttp2=PATH Enable nghttp2 usage
2069 --without-nghttp2 Disable nghttp2 usage
2070 --with-zsh-functions-dir=PATH
2071 Install zsh completions to PATH
2072 --without-zsh-functions-dir
2073 Do not install zsh completions
Haibo Huang65021c72019-03-27 15:37:23 -07002074 --with-fish-functions-dir=PATH
2075 Install fish completions to PATH
2076 --without-fish-functions-dir
2077 Do not install fish completions
Elliott Hughes82be86d2017-09-20 17:00:17 -07002078
2079Some influential environment variables:
2080 CC C compiler command
2081 CFLAGS C compiler flags
2082 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
2083 nonstandard directory <lib dir>
2084 LIBS libraries to pass to the linker, e.g. -l<library>
2085 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
2086 you have headers in a nonstandard directory <include dir>
2087 CPP C preprocessor
2088 LT_SYS_LIBRARY_PATH
2089 User-defined run-time library search path.
2090
2091Use these variables to override the choices made by `configure' or to help
2092it to find libraries and programs with nonstandard names/locations.
2093
2094Report bugs to <a suitable curl mailing list: https://curl.haxx.se/mail/>.
2095_ACEOF
2096ac_status=$?
2097fi
2098
2099if test "$ac_init_help" = "recursive"; then
2100 # If there are subdirs, report their specific --help.
2101 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2102 test -d "$ac_dir" ||
2103 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2104 continue
2105 ac_builddir=.
2106
2107case "$ac_dir" in
2108.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2109*)
2110 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
2111 # A ".." for each directory in $ac_dir_suffix.
2112 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
2113 case $ac_top_builddir_sub in
2114 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2115 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2116 esac ;;
2117esac
2118ac_abs_top_builddir=$ac_pwd
2119ac_abs_builddir=$ac_pwd$ac_dir_suffix
2120# for backward compatibility:
2121ac_top_builddir=$ac_top_build_prefix
2122
2123case $srcdir in
2124 .) # We are building in place.
2125 ac_srcdir=.
2126 ac_top_srcdir=$ac_top_builddir_sub
2127 ac_abs_top_srcdir=$ac_pwd ;;
2128 [\\/]* | ?:[\\/]* ) # Absolute name.
2129 ac_srcdir=$srcdir$ac_dir_suffix;
2130 ac_top_srcdir=$srcdir
2131 ac_abs_top_srcdir=$srcdir ;;
2132 *) # Relative name.
2133 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2134 ac_top_srcdir=$ac_top_build_prefix$srcdir
2135 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2136esac
2137ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2138
2139 cd "$ac_dir" || { ac_status=$?; continue; }
2140 # Check for guested configure.
2141 if test -f "$ac_srcdir/configure.gnu"; then
2142 echo &&
2143 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2144 elif test -f "$ac_srcdir/configure"; then
2145 echo &&
2146 $SHELL "$ac_srcdir/configure" --help=recursive
2147 else
2148 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2149 fi || ac_status=$?
2150 cd "$ac_pwd" || { ac_status=$?; break; }
2151 done
2152fi
2153
2154test -n "$ac_init_help" && exit $ac_status
2155if $ac_init_version; then
2156 cat <<\_ACEOF
2157curl configure -
2158generated by GNU Autoconf 2.69
2159
2160Copyright (C) 2012 Free Software Foundation, Inc.
2161This configure script is free software; the Free Software Foundation
2162gives unlimited permission to copy, distribute and modify it.
2163
Haibo Huang51d9d882019-02-06 01:36:06 -08002164Copyright (c) 1998 - 2019 Daniel Stenberg, <daniel@haxx.se>
Elliott Hughes82be86d2017-09-20 17:00:17 -07002165This configure script may be copied, distributed and modified under the
2166terms of the curl license; see COPYING for more details
2167_ACEOF
2168 exit
2169fi
2170
2171## ------------------------ ##
2172## Autoconf initialization. ##
2173## ------------------------ ##
2174
2175# ac_fn_c_try_compile LINENO
2176# --------------------------
2177# Try to compile conftest.$ac_ext, and return whether this succeeded.
2178ac_fn_c_try_compile ()
2179{
2180 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2181 rm -f conftest.$ac_objext
2182 if { { ac_try="$ac_compile"
2183case "(($ac_try" in
2184 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2185 *) ac_try_echo=$ac_try;;
2186esac
2187eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2188$as_echo "$ac_try_echo"; } >&5
2189 (eval "$ac_compile") 2>conftest.err
2190 ac_status=$?
2191 if test -s conftest.err; then
2192 grep -v '^ *+' conftest.err >conftest.er1
2193 cat conftest.er1 >&5
2194 mv -f conftest.er1 conftest.err
2195 fi
2196 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2197 test $ac_status = 0; } && {
2198 test -z "$ac_c_werror_flag" ||
2199 test ! -s conftest.err
2200 } && test -s conftest.$ac_objext; then :
2201 ac_retval=0
2202else
2203 $as_echo "$as_me: failed program was:" >&5
2204sed 's/^/| /' conftest.$ac_ext >&5
2205
2206 ac_retval=1
2207fi
2208 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2209 as_fn_set_status $ac_retval
2210
2211} # ac_fn_c_try_compile
2212
2213# ac_fn_c_try_cpp LINENO
2214# ----------------------
2215# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2216ac_fn_c_try_cpp ()
2217{
2218 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2219 if { { ac_try="$ac_cpp conftest.$ac_ext"
2220case "(($ac_try" in
2221 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2222 *) ac_try_echo=$ac_try;;
2223esac
2224eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2225$as_echo "$ac_try_echo"; } >&5
2226 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2227 ac_status=$?
2228 if test -s conftest.err; then
2229 grep -v '^ *+' conftest.err >conftest.er1
2230 cat conftest.er1 >&5
2231 mv -f conftest.er1 conftest.err
2232 fi
2233 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2234 test $ac_status = 0; } > conftest.i && {
2235 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2236 test ! -s conftest.err
2237 }; then :
2238 ac_retval=0
2239else
2240 $as_echo "$as_me: failed program was:" >&5
2241sed 's/^/| /' conftest.$ac_ext >&5
2242
2243 ac_retval=1
2244fi
2245 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2246 as_fn_set_status $ac_retval
2247
2248} # ac_fn_c_try_cpp
2249
Alex Deymo486467e2017-12-19 19:04:07 +01002250# ac_fn_c_try_link LINENO
2251# -----------------------
2252# Try to link conftest.$ac_ext, and return whether this succeeded.
2253ac_fn_c_try_link ()
2254{
2255 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2256 rm -f conftest.$ac_objext conftest$ac_exeext
2257 if { { ac_try="$ac_link"
2258case "(($ac_try" in
2259 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2260 *) ac_try_echo=$ac_try;;
2261esac
2262eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2263$as_echo "$ac_try_echo"; } >&5
2264 (eval "$ac_link") 2>conftest.err
2265 ac_status=$?
2266 if test -s conftest.err; then
2267 grep -v '^ *+' conftest.err >conftest.er1
2268 cat conftest.er1 >&5
2269 mv -f conftest.er1 conftest.err
2270 fi
2271 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2272 test $ac_status = 0; } && {
2273 test -z "$ac_c_werror_flag" ||
2274 test ! -s conftest.err
2275 } && test -s conftest$ac_exeext && {
2276 test "$cross_compiling" = yes ||
2277 test -x conftest$ac_exeext
2278 }; then :
2279 ac_retval=0
2280else
2281 $as_echo "$as_me: failed program was:" >&5
2282sed 's/^/| /' conftest.$ac_ext >&5
2283
2284 ac_retval=1
2285fi
2286 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2287 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2288 # interfere with the next link command; also delete a directory that is
2289 # left behind by Apple's compiler. We do this before executing the actions.
2290 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2291 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2292 as_fn_set_status $ac_retval
2293
2294} # ac_fn_c_try_link
2295
Elliott Hughes82be86d2017-09-20 17:00:17 -07002296# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2297# -------------------------------------------------------
2298# Tests whether HEADER exists and can be compiled using the include files in
2299# INCLUDES, setting the cache variable VAR accordingly.
2300ac_fn_c_check_header_compile ()
2301{
2302 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2303 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2304$as_echo_n "checking for $2... " >&6; }
2305if eval \${$3+:} false; then :
2306 $as_echo_n "(cached) " >&6
2307else
2308 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2309/* end confdefs.h. */
2310$4
2311#include <$2>
2312_ACEOF
2313if ac_fn_c_try_compile "$LINENO"; then :
2314 eval "$3=yes"
2315else
2316 eval "$3=no"
2317fi
2318rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2319fi
2320eval ac_res=\$$3
2321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2322$as_echo "$ac_res" >&6; }
2323 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2324
2325} # ac_fn_c_check_header_compile
2326
2327# ac_fn_c_try_run LINENO
2328# ----------------------
2329# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2330# that executables *can* be run.
2331ac_fn_c_try_run ()
2332{
2333 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2334 if { { ac_try="$ac_link"
2335case "(($ac_try" in
2336 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2337 *) ac_try_echo=$ac_try;;
2338esac
2339eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2340$as_echo "$ac_try_echo"; } >&5
2341 (eval "$ac_link") 2>&5
2342 ac_status=$?
2343 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2344 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2345 { { case "(($ac_try" in
2346 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2347 *) ac_try_echo=$ac_try;;
2348esac
2349eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2350$as_echo "$ac_try_echo"; } >&5
2351 (eval "$ac_try") 2>&5
2352 ac_status=$?
2353 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2354 test $ac_status = 0; }; }; then :
2355 ac_retval=0
2356else
2357 $as_echo "$as_me: program exited with status $ac_status" >&5
2358 $as_echo "$as_me: failed program was:" >&5
2359sed 's/^/| /' conftest.$ac_ext >&5
2360
2361 ac_retval=$ac_status
2362fi
2363 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2364 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2365 as_fn_set_status $ac_retval
2366
2367} # ac_fn_c_try_run
2368
Alex Deymo486467e2017-12-19 19:04:07 +01002369# ac_fn_c_check_func LINENO FUNC VAR
2370# ----------------------------------
2371# Tests whether FUNC exists, setting the cache variable VAR accordingly
2372ac_fn_c_check_func ()
2373{
2374 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2375 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2376$as_echo_n "checking for $2... " >&6; }
2377if eval \${$3+:} false; then :
2378 $as_echo_n "(cached) " >&6
2379else
2380 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2381/* end confdefs.h. */
2382
2383#define $2 innocuous_$2
2384#ifdef __STDC__
2385# include <limits.h>
2386#else
2387# include <assert.h>
2388#endif
2389#undef $2
2390#ifdef __cplusplus
2391extern "C"
2392#endif
2393char $2 ();
2394#if defined __stub_$2 || defined __stub___$2
2395choke me
2396#endif
2397
2398int main (void)
2399{
2400return $2 ();
2401 ;
2402 return 0;
2403}
2404_ACEOF
2405if ac_fn_c_try_link "$LINENO"; then :
2406 eval "$3=yes"
2407else
2408 eval "$3=no"
2409fi
2410rm -f core conftest.err conftest.$ac_objext \
2411 conftest$ac_exeext conftest.$ac_ext
2412fi
2413eval ac_res=\$$3
2414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2415$as_echo "$ac_res" >&6; }
2416 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2417
2418} # ac_fn_c_check_func
2419
2420# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
2421# -------------------------------------------------------
2422# Tests whether HEADER exists, giving a warning if it cannot be compiled using
2423# the include files in INCLUDES and setting the cache variable VAR
2424# accordingly.
2425ac_fn_c_check_header_mongrel ()
2426{
2427 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2428 if eval \${$3+:} false; then :
2429 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2430$as_echo_n "checking for $2... " >&6; }
2431if eval \${$3+:} false; then :
2432 $as_echo_n "(cached) " >&6
2433fi
2434eval ac_res=\$$3
2435 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2436$as_echo "$ac_res" >&6; }
2437else
2438 # Is the header compilable?
2439{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2440$as_echo_n "checking $2 usability... " >&6; }
2441cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2442/* end confdefs.h. */
2443$4
2444#include <$2>
2445_ACEOF
2446if ac_fn_c_try_compile "$LINENO"; then :
2447 ac_header_compiler=yes
2448else
2449 ac_header_compiler=no
2450fi
2451rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2452{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2453$as_echo "$ac_header_compiler" >&6; }
2454
2455# Is the header present?
2456{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2457$as_echo_n "checking $2 presence... " >&6; }
2458cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2459/* end confdefs.h. */
2460#include <$2>
2461_ACEOF
2462if ac_fn_c_try_cpp "$LINENO"; then :
2463 ac_header_preproc=yes
2464else
2465 ac_header_preproc=no
2466fi
2467rm -f conftest.err conftest.i conftest.$ac_ext
2468{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2469$as_echo "$ac_header_preproc" >&6; }
2470
2471# So? What about this header?
2472case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
2473 yes:no: )
2474 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2475$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2476 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2477$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2478 ;;
2479 no:yes:* )
2480 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2481$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2482 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
2483$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
2484 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2485$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2486 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
2487$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&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( $as_echo "## ----------------------------------------------------------------------- ##
2491## Report this to a suitable curl mailing list: https://curl.haxx.se/mail/ ##
2492## ----------------------------------------------------------------------- ##"
2493 ) | sed "s/^/$as_me: WARNING: /" >&2
2494 ;;
2495esac
2496 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2497$as_echo_n "checking for $2... " >&6; }
2498if eval \${$3+:} false; then :
2499 $as_echo_n "(cached) " >&6
2500else
2501 eval "$3=\$ac_header_compiler"
2502fi
2503eval ac_res=\$$3
2504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2505$as_echo "$ac_res" >&6; }
2506fi
2507 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2508
2509} # ac_fn_c_check_header_mongrel
2510
Elliott Hughes82be86d2017-09-20 17:00:17 -07002511# ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2512# -------------------------------------------
2513# Tests whether TYPE exists after having included INCLUDES, setting cache
2514# variable VAR accordingly.
2515ac_fn_c_check_type ()
2516{
2517 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2518 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2519$as_echo_n "checking for $2... " >&6; }
2520if eval \${$3+:} false; then :
2521 $as_echo_n "(cached) " >&6
2522else
2523 eval "$3=no"
2524 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2525/* end confdefs.h. */
2526$4
2527int main (void)
2528{
2529if (sizeof ($2))
2530 return 0;
2531 ;
2532 return 0;
2533}
2534_ACEOF
2535if ac_fn_c_try_compile "$LINENO"; then :
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
2549else
2550 eval "$3=yes"
2551fi
2552rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2553fi
2554rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2555fi
2556eval ac_res=\$$3
2557 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2558$as_echo "$ac_res" >&6; }
2559 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2560
2561} # ac_fn_c_check_type
2562
Elliott Hughes72d948d2018-08-03 14:37:21 -07002563# ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
2564# ---------------------------------------------
2565# Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
2566# accordingly.
2567ac_fn_c_check_decl ()
2568{
2569 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2570 as_decl_name=`echo $2|sed 's/ *(.*//'`
2571 as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
2572 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2573$as_echo_n "checking whether $as_decl_name is declared... " >&6; }
2574if eval \${$3+:} false; then :
2575 $as_echo_n "(cached) " >&6
2576else
2577 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2578/* end confdefs.h. */
2579$4
2580int main (void)
2581{
2582#ifndef $as_decl_name
2583#ifdef __cplusplus
2584 (void) $as_decl_use;
2585#else
2586 (void) $as_decl_name;
2587#endif
2588#endif
2589
2590 ;
2591 return 0;
2592}
2593_ACEOF
2594if ac_fn_c_try_compile "$LINENO"; then :
2595 eval "$3=yes"
2596else
2597 eval "$3=no"
2598fi
2599rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2600fi
2601eval ac_res=\$$3
2602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2603$as_echo "$ac_res" >&6; }
2604 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2605
2606} # ac_fn_c_check_decl
2607
Elliott Hughes82be86d2017-09-20 17:00:17 -07002608# ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2609# ----------------------------------------------------
2610# Tries to find if the field MEMBER exists in type AGGR, after including
2611# INCLUDES, setting cache variable VAR accordingly.
2612ac_fn_c_check_member ()
2613{
2614 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2615 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2616$as_echo_n "checking for $2.$3... " >&6; }
2617if eval \${$4+:} false; then :
2618 $as_echo_n "(cached) " >&6
2619else
2620 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2621/* end confdefs.h. */
2622$5
2623int main (void)
2624{
2625static $2 ac_aggr;
2626if (ac_aggr.$3)
2627return 0;
2628 ;
2629 return 0;
2630}
2631_ACEOF
2632if ac_fn_c_try_compile "$LINENO"; then :
2633 eval "$4=yes"
2634else
2635 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2636/* end confdefs.h. */
2637$5
2638int main (void)
2639{
2640static $2 ac_aggr;
2641if (sizeof ac_aggr.$3)
2642return 0;
2643 ;
2644 return 0;
2645}
2646_ACEOF
2647if ac_fn_c_try_compile "$LINENO"; then :
2648 eval "$4=yes"
2649else
2650 eval "$4=no"
2651fi
2652rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2653fi
2654rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2655fi
2656eval ac_res=\$$4
2657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2658$as_echo "$ac_res" >&6; }
2659 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2660
2661} # ac_fn_c_check_member
2662cat >config.log <<_ACEOF
2663This file contains any messages produced by compilers while
2664running configure, to aid debugging if configure makes a mistake.
2665
2666It was created by curl $as_me -, which was
2667generated by GNU Autoconf 2.69. Invocation command line was
2668
2669 $ $0 $@
2670
2671_ACEOF
2672exec 5>>config.log
2673{
2674cat <<_ASUNAME
2675## --------- ##
2676## Platform. ##
2677## --------- ##
2678
2679hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2680uname -m = `(uname -m) 2>/dev/null || echo unknown`
2681uname -r = `(uname -r) 2>/dev/null || echo unknown`
2682uname -s = `(uname -s) 2>/dev/null || echo unknown`
2683uname -v = `(uname -v) 2>/dev/null || echo unknown`
2684
2685/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2686/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2687
2688/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2689/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2690/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2691/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2692/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2693/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2694/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2695
2696_ASUNAME
2697
2698as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2699for as_dir in $PATH
2700do
2701 IFS=$as_save_IFS
2702 test -z "$as_dir" && as_dir=.
2703 $as_echo "PATH: $as_dir"
2704 done
2705IFS=$as_save_IFS
2706
2707} >&5
2708
2709cat >&5 <<_ACEOF
2710
2711
2712## ----------- ##
2713## Core tests. ##
2714## ----------- ##
2715
2716_ACEOF
2717
2718
2719# Keep a trace of the command line.
2720# Strip out --no-create and --no-recursion so they do not pile up.
2721# Strip out --silent because we don't want to record it for future runs.
2722# Also quote any args containing shell meta-characters.
2723# Make two passes to allow for proper duplicate-argument suppression.
2724ac_configure_args=
2725ac_configure_args0=
2726ac_configure_args1=
2727ac_must_keep_next=false
2728for ac_pass in 1 2
2729do
2730 for ac_arg
2731 do
2732 case $ac_arg in
2733 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2734 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2735 | -silent | --silent | --silen | --sile | --sil)
2736 continue ;;
2737 *\'*)
2738 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2739 esac
2740 case $ac_pass in
2741 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2742 2)
2743 as_fn_append ac_configure_args1 " '$ac_arg'"
2744 if test $ac_must_keep_next = true; then
2745 ac_must_keep_next=false # Got value, back to normal.
2746 else
2747 case $ac_arg in
2748 *=* | --config-cache | -C | -disable-* | --disable-* \
2749 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2750 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2751 | -with-* | --with-* | -without-* | --without-* | --x)
2752 case "$ac_configure_args0 " in
2753 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2754 esac
2755 ;;
2756 -* ) ac_must_keep_next=true ;;
2757 esac
2758 fi
2759 as_fn_append ac_configure_args " '$ac_arg'"
2760 ;;
2761 esac
2762 done
2763done
2764{ ac_configure_args0=; unset ac_configure_args0;}
2765{ ac_configure_args1=; unset ac_configure_args1;}
2766
2767# When interrupted or exit'd, cleanup temporary files, and complete
2768# config.log. We remove comments because anyway the quotes in there
2769# would cause problems or look ugly.
2770# WARNING: Use '\'' to represent an apostrophe within the trap.
2771# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2772trap 'exit_status=$?
2773 # Save into config.log some information that might help in debugging.
2774 {
2775 echo
2776
2777 $as_echo "## ---------------- ##
2778## Cache variables. ##
2779## ---------------- ##"
2780 echo
2781 # The following way of writing the cache mishandles newlines in values,
2782(
2783 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2784 eval ac_val=\$$ac_var
2785 case $ac_val in #(
2786 *${as_nl}*)
2787 case $ac_var in #(
2788 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2789$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2790 esac
2791 case $ac_var in #(
2792 _ | IFS | as_nl) ;; #(
2793 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2794 *) { eval $ac_var=; unset $ac_var;} ;;
2795 esac ;;
2796 esac
2797 done
2798 (set) 2>&1 |
2799 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2800 *${as_nl}ac_space=\ *)
2801 sed -n \
2802 "s/'\''/'\''\\\\'\'''\''/g;
2803 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2804 ;; #(
2805 *)
2806 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2807 ;;
2808 esac |
2809 sort
2810)
2811 echo
2812
2813 $as_echo "## ----------------- ##
2814## Output variables. ##
2815## ----------------- ##"
2816 echo
2817 for ac_var in $ac_subst_vars
2818 do
2819 eval ac_val=\$$ac_var
2820 case $ac_val in
2821 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2822 esac
2823 $as_echo "$ac_var='\''$ac_val'\''"
2824 done | sort
2825 echo
2826
2827 if test -n "$ac_subst_files"; then
2828 $as_echo "## ------------------- ##
2829## File substitutions. ##
2830## ------------------- ##"
2831 echo
2832 for ac_var in $ac_subst_files
2833 do
2834 eval ac_val=\$$ac_var
2835 case $ac_val in
2836 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2837 esac
2838 $as_echo "$ac_var='\''$ac_val'\''"
2839 done | sort
2840 echo
2841 fi
2842
2843 if test -s confdefs.h; then
2844 $as_echo "## ----------- ##
2845## confdefs.h. ##
2846## ----------- ##"
2847 echo
2848 cat confdefs.h
2849 echo
2850 fi
2851 test "$ac_signal" != 0 &&
2852 $as_echo "$as_me: caught signal $ac_signal"
2853 $as_echo "$as_me: exit $exit_status"
2854 } >&5
2855 rm -f core *.core core.conftest.* &&
2856 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2857 exit $exit_status
2858' 0
2859for ac_signal in 1 2 13 15; do
2860 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2861done
2862ac_signal=0
2863
2864# confdefs.h avoids OS command line length limits that DEFS can exceed.
2865rm -f -r conftest* confdefs.h
2866
2867$as_echo "/* confdefs.h */" > confdefs.h
2868
2869# Predefined preprocessor variables.
2870
2871cat >>confdefs.h <<_ACEOF
2872#define PACKAGE_NAME "$PACKAGE_NAME"
2873_ACEOF
2874
2875cat >>confdefs.h <<_ACEOF
2876#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2877_ACEOF
2878
2879cat >>confdefs.h <<_ACEOF
2880#define PACKAGE_VERSION "$PACKAGE_VERSION"
2881_ACEOF
2882
2883cat >>confdefs.h <<_ACEOF
2884#define PACKAGE_STRING "$PACKAGE_STRING"
2885_ACEOF
2886
2887cat >>confdefs.h <<_ACEOF
2888#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2889_ACEOF
2890
2891cat >>confdefs.h <<_ACEOF
2892#define PACKAGE_URL "$PACKAGE_URL"
2893_ACEOF
2894
2895
2896# Let the site file select an alternate cache file if it wants to.
2897# Prefer an explicitly selected file to automatically selected ones.
2898ac_site_file1=NONE
2899ac_site_file2=NONE
2900if test -n "$CONFIG_SITE"; then
2901 # We do not want a PATH search for config.site.
2902 case $CONFIG_SITE in #((
2903 -*) ac_site_file1=./$CONFIG_SITE;;
2904 */*) ac_site_file1=$CONFIG_SITE;;
2905 *) ac_site_file1=./$CONFIG_SITE;;
2906 esac
2907elif test "x$prefix" != xNONE; then
2908 ac_site_file1=$prefix/share/config.site
2909 ac_site_file2=$prefix/etc/config.site
2910else
2911 ac_site_file1=$ac_default_prefix/share/config.site
2912 ac_site_file2=$ac_default_prefix/etc/config.site
2913fi
2914for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2915do
2916 test "x$ac_site_file" = xNONE && continue
2917 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
2918 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2919$as_echo "$as_me: loading site script $ac_site_file" >&6;}
2920 sed 's/^/| /' "$ac_site_file" >&5
2921 . "$ac_site_file" \
2922 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2923$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2924as_fn_error $? "failed to load site script $ac_site_file
2925See \`config.log' for more details" "$LINENO" 5; }
2926 fi
2927done
2928
2929if test -r "$cache_file"; then
2930 # Some versions of bash will fail to source /dev/null (special files
2931 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
2932 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2933 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2934$as_echo "$as_me: loading cache $cache_file" >&6;}
2935 case $cache_file in
2936 [\\/]* | ?:[\\/]* ) . "$cache_file";;
2937 *) . "./$cache_file";;
2938 esac
2939 fi
2940else
2941 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2942$as_echo "$as_me: creating cache $cache_file" >&6;}
2943 >$cache_file
2944fi
2945
2946# Check that the precious variables saved in the cache have kept the same
2947# value.
2948ac_cache_corrupted=false
2949for ac_var in $ac_precious_vars; do
2950 eval ac_old_set=\$ac_cv_env_${ac_var}_set
2951 eval ac_new_set=\$ac_env_${ac_var}_set
2952 eval ac_old_val=\$ac_cv_env_${ac_var}_value
2953 eval ac_new_val=\$ac_env_${ac_var}_value
2954 case $ac_old_set,$ac_new_set in
2955 set,)
2956 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2957$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2958 ac_cache_corrupted=: ;;
2959 ,set)
2960 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2961$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2962 ac_cache_corrupted=: ;;
2963 ,);;
2964 *)
2965 if test "x$ac_old_val" != "x$ac_new_val"; then
2966 # differences in whitespace do not lead to failure.
2967 ac_old_val_w=`echo x $ac_old_val`
2968 ac_new_val_w=`echo x $ac_new_val`
2969 if test "$ac_old_val_w" != "$ac_new_val_w"; then
2970 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2971$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2972 ac_cache_corrupted=:
2973 else
2974 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2975$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2976 eval $ac_var=\$ac_old_val
2977 fi
2978 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
2979$as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
2980 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
2981$as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
2982 fi;;
2983 esac
2984 # Pass precious variables to config.status.
2985 if test "$ac_new_set" = set; then
2986 case $ac_new_val in
2987 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2988 *) ac_arg=$ac_var=$ac_new_val ;;
2989 esac
2990 case " $ac_configure_args " in
2991 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
2992 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2993 esac
2994 fi
2995done
2996if $ac_cache_corrupted; then
2997 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2998$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2999 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3000$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
3001 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3002fi
3003## -------------------- ##
3004## Main body of script. ##
3005## -------------------- ##
3006
3007ac_ext=c
3008ac_cpp='$CPP $CPPFLAGS'
3009ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3010ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3011ac_compiler_gnu=$ac_cv_c_compiler_gnu
3012
3013
3014
3015
3016
3017
3018
3019# using curl-override.m4
3020
3021
3022
3023
3024
3025ac_config_headers="$ac_config_headers lib/curl_config.h"
3026
3027
3028
3029{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
3030$as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
3031 # Check whether --enable-maintainer-mode was given.
3032if test "${enable_maintainer_mode+set}" = set; then :
3033 enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
3034else
3035 USE_MAINTAINER_MODE=no
3036fi
3037
3038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5
3039$as_echo "$USE_MAINTAINER_MODE" >&6; }
3040 if test $USE_MAINTAINER_MODE = yes; then
3041 MAINTAINER_MODE_TRUE=
3042 MAINTAINER_MODE_FALSE='#'
3043else
3044 MAINTAINER_MODE_TRUE='#'
3045 MAINTAINER_MODE_FALSE=
3046fi
3047
3048 MAINT=$MAINTAINER_MODE_TRUE
3049
3050
3051# Check whether --enable-silent-rules was given.
3052if test "${enable_silent_rules+set}" = set; then :
3053 enableval=$enable_silent_rules;
3054fi
3055
3056case $enable_silent_rules in # (((
3057 yes) AM_DEFAULT_VERBOSITY=0;;
3058 no) AM_DEFAULT_VERBOSITY=1;;
3059 *) AM_DEFAULT_VERBOSITY=0;;
3060esac
3061am_make=${MAKE-make}
3062{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
3063$as_echo_n "checking whether $am_make supports nested variables... " >&6; }
3064if ${am_cv_make_support_nested_variables+:} false; then :
3065 $as_echo_n "(cached) " >&6
3066else
3067 if $as_echo 'TRUE=$(BAR$(V))
3068BAR0=false
3069BAR1=true
3070V=1
3071am__doit:
3072 @$(TRUE)
3073.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
3074 am_cv_make_support_nested_variables=yes
3075else
3076 am_cv_make_support_nested_variables=no
3077fi
3078fi
3079{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
3080$as_echo "$am_cv_make_support_nested_variables" >&6; }
3081if test $am_cv_make_support_nested_variables = yes; then
3082 AM_V='$(V)'
3083 AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
3084else
3085 AM_V=$AM_DEFAULT_VERBOSITY
3086 AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
3087fi
3088AM_BACKSLASH='\'
3089
3090
3091
3092 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable debug build options" >&5
3093$as_echo_n "checking whether to enable debug build options... " >&6; }
3094 OPT_DEBUG_BUILD="default"
3095 # Check whether --enable-debug was given.
3096if test "${enable_debug+set}" = set; then :
3097 enableval=$enable_debug; OPT_DEBUG_BUILD=$enableval
3098fi
3099
3100 case "$OPT_DEBUG_BUILD" in
3101 no)
3102 want_debug="no"
3103 ;;
3104 default)
3105 want_debug="no"
3106 ;;
3107 *)
3108 want_debug="yes"
Elliott Hughes1ef06ba2018-05-30 15:43:58 -07003109
3110$as_echo "#define DEBUGBUILD 1" >>confdefs.h
3111
Elliott Hughes82be86d2017-09-20 17:00:17 -07003112 ;;
3113 esac
3114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $want_debug" >&5
3115$as_echo "$want_debug" >&6; }
3116
3117
3118 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable compiler optimizer" >&5
3119$as_echo_n "checking whether to enable compiler optimizer... " >&6; }
3120 OPT_COMPILER_OPTIMIZE="default"
3121 # Check whether --enable-optimize was given.
3122if test "${enable_optimize+set}" = set; then :
3123 enableval=$enable_optimize; OPT_COMPILER_OPTIMIZE=$enableval
3124fi
3125
3126 case "$OPT_COMPILER_OPTIMIZE" in
3127 no)
3128 want_optimize="no"
3129 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3130$as_echo "no" >&6; }
3131 ;;
3132 default)
3133 if test "$want_debug" = "yes"; then
3134 want_optimize="assume_no"
3135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: (assumed) no" >&5
3136$as_echo "(assumed) no" >&6; }
3137 else
3138 want_optimize="assume_yes"
3139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: (assumed) yes" >&5
3140$as_echo "(assumed) yes" >&6; }
3141 fi
3142 ;;
3143 *)
3144 want_optimize="yes"
3145 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3146$as_echo "yes" >&6; }
3147 ;;
3148 esac
3149
3150
3151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable strict compiler warnings" >&5
3152$as_echo_n "checking whether to enable strict compiler warnings... " >&6; }
3153 OPT_COMPILER_WARNINGS="default"
3154 # Check whether --enable-warnings was given.
3155if test "${enable_warnings+set}" = set; then :
3156 enableval=$enable_warnings; OPT_COMPILER_WARNINGS=$enableval
3157fi
3158
3159 case "$OPT_COMPILER_WARNINGS" in
3160 no)
3161 want_warnings="no"
3162 ;;
3163 default)
3164 want_warnings="$want_debug"
3165 ;;
3166 *)
3167 want_warnings="yes"
3168 ;;
3169 esac
3170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $want_warnings" >&5
3171$as_echo "$want_warnings" >&6; }
3172
3173
3174 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable compiler warnings as errors" >&5
3175$as_echo_n "checking whether to enable compiler warnings as errors... " >&6; }
3176 OPT_COMPILER_WERROR="default"
3177 # Check whether --enable-werror was given.
3178if test "${enable_werror+set}" = set; then :
3179 enableval=$enable_werror; OPT_COMPILER_WERROR=$enableval
3180fi
3181
3182 case "$OPT_COMPILER_WERROR" in
3183 no)
3184 want_werror="no"
3185 ;;
3186 default)
3187 want_werror="no"
3188 ;;
3189 *)
3190 want_werror="yes"
3191 ;;
3192 esac
3193 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $want_werror" >&5
3194$as_echo "$want_werror" >&6; }
3195
3196
3197 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable curl debug memory tracking" >&5
3198$as_echo_n "checking whether to enable curl debug memory tracking... " >&6; }
3199 OPT_CURLDEBUG_BUILD="default"
3200 # Check whether --enable-curldebug was given.
3201if test "${enable_curldebug+set}" = set; then :
3202 enableval=$enable_curldebug; OPT_CURLDEBUG_BUILD=$enableval
3203fi
3204
3205 case "$OPT_CURLDEBUG_BUILD" in
3206 no)
3207 want_curldebug="no"
3208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3209$as_echo "no" >&6; }
3210 ;;
3211 default)
3212 if test "$want_debug" = "yes"; then
3213 { $as_echo "$as_me:${as_lineno-$LINENO}: result: (assumed) yes" >&5
3214$as_echo "(assumed) yes" >&6; }
Elliott Hughes1ef06ba2018-05-30 15:43:58 -07003215
3216$as_echo "#define CURLDEBUG 1" >>confdefs.h
3217
Elliott Hughes82be86d2017-09-20 17:00:17 -07003218 else
3219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3220$as_echo "no" >&6; }
3221 fi
3222 want_curldebug_assumed="yes"
3223 want_curldebug="$want_debug"
3224 ;;
3225 *)
3226 want_curldebug="yes"
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 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3231$as_echo "yes" >&6; }
3232 ;;
3233 esac
3234
3235
3236 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable hiding of library internal symbols" >&5
3237$as_echo_n "checking whether to enable hiding of library internal symbols... " >&6; }
3238 OPT_SYMBOL_HIDING="default"
3239 # Check whether --enable-symbol-hiding was given.
3240if test "${enable_symbol_hiding+set}" = set; then :
3241 enableval=$enable_symbol_hiding; OPT_SYMBOL_HIDING=$enableval
3242fi
3243
3244 # Check whether --enable-hidden-symbols was given.
3245if test "${enable_hidden_symbols+set}" = set; then :
3246 enableval=$enable_hidden_symbols; OPT_SYMBOL_HIDING=$enableval
3247fi
3248
3249 case "$OPT_SYMBOL_HIDING" in
3250 no)
3251 want_symbol_hiding="no"
3252 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3253$as_echo "no" >&6; }
3254 ;;
3255 default)
3256 want_symbol_hiding="yes"
3257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3258$as_echo "yes" >&6; }
3259 ;;
3260 *)
3261 want_symbol_hiding="yes"
3262 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3263$as_echo "yes" >&6; }
3264 ;;
3265 esac
3266
3267
3268 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable c-ares for DNS lookups" >&5
3269$as_echo_n "checking whether to enable c-ares for DNS lookups... " >&6; }
3270 OPT_ARES="default"
3271 # Check whether --enable-ares was given.
3272if test "${enable_ares+set}" = set; then :
3273 enableval=$enable_ares; OPT_ARES=$enableval
3274fi
3275
3276 case "$OPT_ARES" in
3277 no)
3278 want_ares="no"
3279 ;;
3280 default)
3281 want_ares="no"
3282 ;;
3283 *)
3284 want_ares="yes"
3285 if test -n "$enableval" && test "$enableval" != "yes"; then
3286 want_ares_path="$enableval"
3287 fi
3288 ;;
3289 esac
3290 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $want_ares" >&5
3291$as_echo "$want_ares" >&6; }
3292
3293
3294 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to disable dependency on -lrt" >&5
3295$as_echo_n "checking whether to disable dependency on -lrt... " >&6; }
3296 OPT_RT="default"
3297 # Check whether --enable-rt was given.
3298if test "${enable_rt+set}" = set; then :
3299 enableval=$enable_rt; OPT_RT=$enableval
3300fi
3301
3302 case "$OPT_RT" in
3303 no)
3304 dontwant_rt="yes"
3305 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3306$as_echo "yes" >&6; }
3307 ;;
3308 default)
3309 dontwant_rt="no"
3310 { $as_echo "$as_me:${as_lineno-$LINENO}: result: (assumed no)" >&5
3311$as_echo "(assumed no)" >&6; }
3312 ;;
3313 *)
3314 dontwant_rt="no"
3315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3316$as_echo "no" >&6; }
3317 ;;
3318 esac
3319
3320
3321#
3322# Check that 'XC_CONFIGURE_PREAMBLE' has already run.
3323#
3324
3325if test -z "$xc_configure_preamble_result"; then
3326 as_fn_error $? "xc_configure_preamble_result not set (internal problem)" "$LINENO" 5
3327fi
3328
3329#
3330# Check that 'PATH_SEPARATOR' has already been set.
3331#
3332
3333if test -z "$xc_PATH_SEPARATOR"; then
3334 as_fn_error $? "xc_PATH_SEPARATOR not set (internal problem)" "$LINENO" 5
3335fi
3336if test -z "$PATH_SEPARATOR"; then
3337 as_fn_error $? "PATH_SEPARATOR not set (internal or config.site problem)" "$LINENO" 5
3338fi
3339{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for path separator" >&5
3340$as_echo_n "checking for path separator... " >&6; }
3341{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATH_SEPARATOR" >&5
3342$as_echo "$PATH_SEPARATOR" >&6; }
3343if test "x$PATH_SEPARATOR" != "x$xc_PATH_SEPARATOR"; then
3344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for initial path separator" >&5
3345$as_echo_n "checking for initial path separator... " >&6; }
3346 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $xc_PATH_SEPARATOR" >&5
3347$as_echo "$xc_PATH_SEPARATOR" >&6; }
3348 as_fn_error $? "path separator mismatch (internal or config.site problem)" "$LINENO" 5
3349fi
3350
Elliott Hughes82be86d2017-09-20 17:00:17 -07003351
3352#
3353# save the configure arguments
3354#
3355CONFIGURE_OPTIONS="\"$ac_configure_args\""
3356
3357
3358CURL_CFLAG_EXTRAS=""
3359if test X"$want_werror" = Xyes; then
3360 CURL_CFLAG_EXTRAS="-Werror"
Elliott Hughesb1ef70f2018-10-30 11:28:38 -07003361 if test "$compiler_id" = "GNU_C"; then
3362 if test "$compiler_num" -ge "500"; then
3363 CURL_CFLAG_EXTRAS="$CURL_CFLAG_EXTRAS -pedantic-errors"
3364 fi
3365 fi
Elliott Hughes82be86d2017-09-20 17:00:17 -07003366fi
3367
3368
3369if test -z "$SED"; then
3370 # Extract the first word of "sed", so it can be a program name with args.
3371set dummy sed; ac_word=$2
3372{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3373$as_echo_n "checking for $ac_word... " >&6; }
3374if ${ac_cv_path_SED+:} false; then :
3375 $as_echo_n "(cached) " >&6
3376else
3377 case $SED in
3378 [\\/]* | ?:[\\/]*)
3379 ac_cv_path_SED="$SED" # Let the user override the test with a path.
3380 ;;
3381 *)
3382 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3383as_dummy="$PATH:/usr/bin:/usr/local/bin"
3384for as_dir in $as_dummy
3385do
3386 IFS=$as_save_IFS
3387 test -z "$as_dir" && as_dir=.
3388 for ac_exec_ext in '' $ac_executable_extensions; do
3389 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3390 ac_cv_path_SED="$as_dir/$ac_word$ac_exec_ext"
3391 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3392 break 2
3393 fi
3394done
3395 done
3396IFS=$as_save_IFS
3397
3398 test -z "$ac_cv_path_SED" && ac_cv_path_SED="not_found"
3399 ;;
3400esac
3401fi
3402SED=$ac_cv_path_SED
3403if test -n "$SED"; then
3404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SED" >&5
3405$as_echo "$SED" >&6; }
3406else
3407 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3408$as_echo "no" >&6; }
3409fi
3410
3411
3412 if test -z "$SED" || test "$SED" = "not_found"; then
3413 as_fn_error $? "sed not found in PATH. Cannot continue without sed." "$LINENO" 5
3414 fi
3415fi
3416
3417
3418if test -z "$GREP"; then
3419 # Extract the first word of "grep", so it can be a program name with args.
3420set dummy grep; ac_word=$2
3421{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3422$as_echo_n "checking for $ac_word... " >&6; }
3423if ${ac_cv_path_GREP+:} false; then :
3424 $as_echo_n "(cached) " >&6
3425else
3426 case $GREP in
3427 [\\/]* | ?:[\\/]*)
3428 ac_cv_path_GREP="$GREP" # Let the user override the test with a path.
3429 ;;
3430 *)
3431 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3432as_dummy="$PATH:/usr/bin:/usr/local/bin"
3433for as_dir in $as_dummy
3434do
3435 IFS=$as_save_IFS
3436 test -z "$as_dir" && as_dir=.
3437 for ac_exec_ext in '' $ac_executable_extensions; do
3438 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3439 ac_cv_path_GREP="$as_dir/$ac_word$ac_exec_ext"
3440 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3441 break 2
3442 fi
3443done
3444 done
3445IFS=$as_save_IFS
3446
3447 test -z "$ac_cv_path_GREP" && ac_cv_path_GREP="not_found"
3448 ;;
3449esac
3450fi
3451GREP=$ac_cv_path_GREP
3452if test -n "$GREP"; then
3453 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GREP" >&5
3454$as_echo "$GREP" >&6; }
3455else
3456 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3457$as_echo "no" >&6; }
3458fi
3459
3460
3461 if test -z "$GREP" || test "$GREP" = "not_found"; then
3462 as_fn_error $? "grep not found in PATH. Cannot continue without grep." "$LINENO" 5
3463 fi
3464fi
3465
3466
3467if test -z "$EGREP"; then
3468 if echo a | ($GREP -E '(a|b)') >/dev/null 2>&1; then
3469 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
3470$as_echo_n "checking for egrep... " >&6; }
3471 EGREP="$GREP -E"
3472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EGREP" >&5
3473$as_echo "$EGREP" >&6; }
3474 else
3475 # Extract the first word of "egrep", so it can be a program name with args.
3476set dummy egrep; ac_word=$2
3477{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3478$as_echo_n "checking for $ac_word... " >&6; }
3479if ${ac_cv_path_EGREP+:} false; then :
3480 $as_echo_n "(cached) " >&6
3481else
3482 case $EGREP in
3483 [\\/]* | ?:[\\/]*)
3484 ac_cv_path_EGREP="$EGREP" # Let the user override the test with a path.
3485 ;;
3486 *)
3487 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3488as_dummy="$PATH:/usr/bin:/usr/local/bin"
3489for as_dir in $as_dummy
3490do
3491 IFS=$as_save_IFS
3492 test -z "$as_dir" && as_dir=.
3493 for ac_exec_ext in '' $ac_executable_extensions; do
3494 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3495 ac_cv_path_EGREP="$as_dir/$ac_word$ac_exec_ext"
3496 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3497 break 2
3498 fi
3499done
3500 done
3501IFS=$as_save_IFS
3502
3503 test -z "$ac_cv_path_EGREP" && ac_cv_path_EGREP="not_found"
3504 ;;
3505esac
3506fi
3507EGREP=$ac_cv_path_EGREP
3508if test -n "$EGREP"; then
3509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EGREP" >&5
3510$as_echo "$EGREP" >&6; }
3511else
3512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3513$as_echo "no" >&6; }
3514fi
3515
3516
3517 fi
3518fi
3519if test -z "$EGREP" || test "$EGREP" = "not_found"; then
3520 as_fn_error $? "egrep not found in PATH. Cannot continue without egrep." "$LINENO" 5
3521fi
3522
3523
3524if test -z "$AR"; then
3525 if test -n "$ac_tool_prefix"; then
3526 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
3527set dummy ${ac_tool_prefix}ar; ac_word=$2
3528{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3529$as_echo_n "checking for $ac_word... " >&6; }
3530if ${ac_cv_path_AR+:} false; then :
3531 $as_echo_n "(cached) " >&6
3532else
3533 case $AR in
3534 [\\/]* | ?:[\\/]*)
3535 ac_cv_path_AR="$AR" # Let the user override the test with a path.
3536 ;;
3537 *)
3538 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3539as_dummy="$PATH:/usr/bin:/usr/local/bin"
3540for as_dir in $as_dummy
3541do
3542 IFS=$as_save_IFS
3543 test -z "$as_dir" && as_dir=.
3544 for ac_exec_ext in '' $ac_executable_extensions; do
3545 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3546 ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext"
3547 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3548 break 2
3549 fi
3550done
3551 done
3552IFS=$as_save_IFS
3553
3554 ;;
3555esac
3556fi
3557AR=$ac_cv_path_AR
3558if test -n "$AR"; then
3559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
3560$as_echo "$AR" >&6; }
3561else
3562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3563$as_echo "no" >&6; }
3564fi
3565
3566
3567fi
3568if test -z "$ac_cv_path_AR"; then
3569 ac_pt_AR=$AR
3570 # Extract the first word of "ar", so it can be a program name with args.
3571set dummy ar; ac_word=$2
3572{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3573$as_echo_n "checking for $ac_word... " >&6; }
3574if ${ac_cv_path_ac_pt_AR+:} false; then :
3575 $as_echo_n "(cached) " >&6
3576else
3577 case $ac_pt_AR in
3578 [\\/]* | ?:[\\/]*)
3579 ac_cv_path_ac_pt_AR="$ac_pt_AR" # Let the user override the test with a path.
3580 ;;
3581 *)
3582 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3583as_dummy="$PATH:/usr/bin:/usr/local/bin"
3584for as_dir in $as_dummy
3585do
3586 IFS=$as_save_IFS
3587 test -z "$as_dir" && as_dir=.
3588 for ac_exec_ext in '' $ac_executable_extensions; do
3589 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3590 ac_cv_path_ac_pt_AR="$as_dir/$ac_word$ac_exec_ext"
3591 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3592 break 2
3593 fi
3594done
3595 done
3596IFS=$as_save_IFS
3597
3598 ;;
3599esac
3600fi
3601ac_pt_AR=$ac_cv_path_ac_pt_AR
3602if test -n "$ac_pt_AR"; then
3603 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_AR" >&5
3604$as_echo "$ac_pt_AR" >&6; }
3605else
3606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3607$as_echo "no" >&6; }
3608fi
3609
3610 if test "x$ac_pt_AR" = x; then
3611 AR="not_found"
3612 else
3613 case $cross_compiling:$ac_tool_warned in
3614yes:)
3615{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3616$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3617ac_tool_warned=yes ;;
3618esac
3619 AR=$ac_pt_AR
3620 fi
3621else
3622 AR="$ac_cv_path_AR"
3623fi
3624
3625 if test -z "$AR" || test "$AR" = "not_found"; then
3626 as_fn_error $? "ar not found in PATH. Cannot continue without ar." "$LINENO" 5
3627 fi
3628fi
3629
3630
3631
3632
3633CURLVERSION=`$SED -ne 's/^#define LIBCURL_VERSION "\(.*\)".*/\1/p' ${srcdir}/include/curl/curlver.h`
3634
3635 xc_prog_cc_prev_IFS=$IFS
3636 xc_prog_cc_prev_LIBS=$LIBS
3637 xc_prog_cc_prev_CFLAGS=$CFLAGS
3638 xc_prog_cc_prev_LDFLAGS=$LDFLAGS
3639 xc_prog_cc_prev_CPPFLAGS=$CPPFLAGS
3640
3641
3642
3643 xc_bad_var_libs=no
3644 for xc_word in $LIBS; do
3645 case "$xc_word" in
3646 -l* | --library=*)
3647 :
3648 ;;
3649 *)
3650 xc_bad_var_libs=yes
3651 ;;
3652 esac
3653 done
3654 if test $xc_bad_var_libs = yes; then
3655 { $as_echo "$as_me:${as_lineno-$LINENO}: using LIBS: $LIBS" >&5
3656$as_echo "$as_me: using LIBS: $LIBS" >&6;}
3657 { $as_echo "$as_me:${as_lineno-$LINENO}: LIBS note: LIBS should only be used to specify libraries (-lname)." >&5
3658$as_echo "$as_me: LIBS note: LIBS should only be used to specify libraries (-lname)." >&6;}
3659 fi
3660
3661
3662 xc_bad_var_ldflags=no
3663 for xc_word in $LDFLAGS; do
3664 case "$xc_word" in
3665 -D*)
3666 xc_bad_var_ldflags=yes
3667 ;;
3668 -U*)
3669 xc_bad_var_ldflags=yes
3670 ;;
3671 -I*)
3672 xc_bad_var_ldflags=yes
3673 ;;
3674 -l* | --library=*)
3675 xc_bad_var_ldflags=yes
3676 ;;
3677 esac
3678 done
3679 if test $xc_bad_var_ldflags = yes; then
3680 { $as_echo "$as_me:${as_lineno-$LINENO}: using LDFLAGS: $LDFLAGS" >&5
3681$as_echo "$as_me: using LDFLAGS: $LDFLAGS" >&6;}
3682 xc_bad_var_msg="LDFLAGS note: LDFLAGS should only be used to specify linker flags, not"
3683 for xc_word in $LDFLAGS; do
3684 case "$xc_word" in
3685 -D*)
3686 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg macro definitions. Use CPPFLAGS for: $xc_word" >&5
3687$as_echo "$as_me: $xc_bad_var_msg macro definitions. Use CPPFLAGS for: $xc_word" >&6;}
3688 ;;
3689 -U*)
3690 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg macro suppressions. Use CPPFLAGS for: $xc_word" >&5
3691$as_echo "$as_me: $xc_bad_var_msg macro suppressions. Use CPPFLAGS for: $xc_word" >&6;}
3692 ;;
3693 -I*)
3694 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg include directories. Use CPPFLAGS for: $xc_word" >&5
3695$as_echo "$as_me: $xc_bad_var_msg include directories. Use CPPFLAGS for: $xc_word" >&6;}
3696 ;;
3697 -l* | --library=*)
3698 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg libraries. Use LIBS for: $xc_word" >&5
3699$as_echo "$as_me: $xc_bad_var_msg libraries. Use LIBS for: $xc_word" >&6;}
3700 ;;
3701 esac
3702 done
3703 fi
3704
3705
3706 xc_bad_var_cppflags=no
3707 for xc_word in $CPPFLAGS; do
3708 case "$xc_word" in
3709 -rpath*)
3710 xc_bad_var_cppflags=yes
3711 ;;
3712 -L* | --library-path=*)
3713 xc_bad_var_cppflags=yes
3714 ;;
3715 -l* | --library=*)
3716 xc_bad_var_cppflags=yes
3717 ;;
3718 esac
3719 done
3720 if test $xc_bad_var_cppflags = yes; then
3721 { $as_echo "$as_me:${as_lineno-$LINENO}: using CPPFLAGS: $CPPFLAGS" >&5
3722$as_echo "$as_me: using CPPFLAGS: $CPPFLAGS" >&6;}
3723 xc_bad_var_msg="CPPFLAGS note: CPPFLAGS should only be used to specify C preprocessor flags, not"
3724 for xc_word in $CPPFLAGS; do
3725 case "$xc_word" in
3726 -rpath*)
3727 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg library runtime directories. Use LDFLAGS for: $xc_word" >&5
3728$as_echo "$as_me: $xc_bad_var_msg library runtime directories. Use LDFLAGS for: $xc_word" >&6;}
3729 ;;
3730 -L* | --library-path=*)
3731 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg library directories. Use LDFLAGS for: $xc_word" >&5
3732$as_echo "$as_me: $xc_bad_var_msg library directories. Use LDFLAGS for: $xc_word" >&6;}
3733 ;;
3734 -l* | --library=*)
3735 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg libraries. Use LIBS for: $xc_word" >&5
3736$as_echo "$as_me: $xc_bad_var_msg libraries. Use LIBS for: $xc_word" >&6;}
3737 ;;
3738 esac
3739 done
3740 fi
3741
3742
3743 xc_bad_var_cflags=no
3744 for xc_word in $CFLAGS; do
3745 case "$xc_word" in
3746 -D*)
3747 xc_bad_var_cflags=yes
3748 ;;
3749 -U*)
3750 xc_bad_var_cflags=yes
3751 ;;
3752 -I*)
3753 xc_bad_var_cflags=yes
3754 ;;
3755 -rpath*)
3756 xc_bad_var_cflags=yes
3757 ;;
3758 -L* | --library-path=*)
3759 xc_bad_var_cflags=yes
3760 ;;
3761 -l* | --library=*)
3762 xc_bad_var_cflags=yes
3763 ;;
3764 esac
3765 done
3766 if test $xc_bad_var_cflags = yes; then
3767 { $as_echo "$as_me:${as_lineno-$LINENO}: using CFLAGS: $CFLAGS" >&5
3768$as_echo "$as_me: using CFLAGS: $CFLAGS" >&6;}
3769 xc_bad_var_msg="CFLAGS note: CFLAGS should only be used to specify C compiler flags, not"
3770 for xc_word in $CFLAGS; do
3771 case "$xc_word" in
3772 -D*)
3773 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg macro definitions. Use CPPFLAGS for: $xc_word" >&5
3774$as_echo "$as_me: $xc_bad_var_msg macro definitions. Use CPPFLAGS for: $xc_word" >&6;}
3775 ;;
3776 -U*)
3777 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg macro suppressions. Use CPPFLAGS for: $xc_word" >&5
3778$as_echo "$as_me: $xc_bad_var_msg macro suppressions. Use CPPFLAGS for: $xc_word" >&6;}
3779 ;;
3780 -I*)
3781 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg include directories. Use CPPFLAGS for: $xc_word" >&5
3782$as_echo "$as_me: $xc_bad_var_msg include directories. Use CPPFLAGS for: $xc_word" >&6;}
3783 ;;
3784 -rpath*)
3785 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg library runtime directories. Use LDFLAGS for: $xc_word" >&5
3786$as_echo "$as_me: $xc_bad_var_msg library runtime directories. Use LDFLAGS for: $xc_word" >&6;}
3787 ;;
3788 -L* | --library-path=*)
3789 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg library directories. Use LDFLAGS for: $xc_word" >&5
3790$as_echo "$as_me: $xc_bad_var_msg library directories. Use LDFLAGS for: $xc_word" >&6;}
3791 ;;
3792 -l* | --library=*)
3793 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg libraries. Use LIBS for: $xc_word" >&5
3794$as_echo "$as_me: $xc_bad_var_msg libraries. Use LIBS for: $xc_word" >&6;}
3795 ;;
3796 esac
3797 done
3798 fi
3799
3800 if test $xc_bad_var_libs = yes ||
3801 test $xc_bad_var_cflags = yes ||
3802 test $xc_bad_var_ldflags = yes ||
3803 test $xc_bad_var_cppflags = yes; then
3804 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Continuing even with errors mentioned immediately above this line." >&5
3805$as_echo "$as_me: WARNING: Continuing even with errors mentioned immediately above this line." >&2;}
3806 fi
3807
3808ac_aux_dir=
3809for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
3810 if test -f "$ac_dir/install-sh"; then
3811 ac_aux_dir=$ac_dir
3812 ac_install_sh="$ac_aux_dir/install-sh -c"
3813 break
3814 elif test -f "$ac_dir/install.sh"; then
3815 ac_aux_dir=$ac_dir
3816 ac_install_sh="$ac_aux_dir/install.sh -c"
3817 break
3818 elif test -f "$ac_dir/shtool"; then
3819 ac_aux_dir=$ac_dir
3820 ac_install_sh="$ac_aux_dir/shtool install -c"
3821 break
3822 fi
3823done
3824if test -z "$ac_aux_dir"; then
3825 as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
3826fi
3827
3828# These three variables are undocumented and unsupported,
3829# and are intended to be withdrawn in a future Autoconf release.
3830# They can cause serious problems if a builder's source tree is in a directory
3831# whose full name contains unusual characters.
3832ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
3833ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
3834ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
3835
3836
3837# Find a good install program. We prefer a C program (faster),
3838# so one script is as good as another. But avoid the broken or
3839# incompatible versions:
3840# SysV /etc/install, /usr/sbin/install
3841# SunOS /usr/etc/install
3842# IRIX /sbin/install
3843# AIX /bin/install
3844# AmigaOS /C/install, which installs bootblocks on floppy discs
3845# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3846# AFS /usr/afsws/bin/install, which mishandles nonexistent args
3847# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3848# OS/2's system install, which has a completely different semantic
3849# ./install, which can be erroneously created by make from ./install.sh.
3850# Reject install programs that cannot install multiple files.
3851{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
3852$as_echo_n "checking for a BSD-compatible install... " >&6; }
3853if test -z "$INSTALL"; then
3854if ${ac_cv_path_install+:} false; then :
3855 $as_echo_n "(cached) " >&6
3856else
3857 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3858for as_dir in $PATH
3859do
3860 IFS=$as_save_IFS
3861 test -z "$as_dir" && as_dir=.
3862 # Account for people who put trailing slashes in PATH elements.
3863case $as_dir/ in #((
3864 ./ | .// | /[cC]/* | \
3865 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3866 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
3867 /usr/ucb/* ) ;;
3868 *)
3869 # OSF1 and SCO ODT 3.0 have their own names for install.
3870 # Don't use installbsd from OSF since it installs stuff as root
3871 # by default.
3872 for ac_prog in ginstall scoinst install; do
3873 for ac_exec_ext in '' $ac_executable_extensions; do
3874 if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
3875 if test $ac_prog = install &&
3876 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3877 # AIX install. It has an incompatible calling convention.
3878 :
3879 elif test $ac_prog = install &&
3880 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3881 # program-specific install script used by HP pwplus--don't use.
3882 :
3883 else
3884 rm -rf conftest.one conftest.two conftest.dir
3885 echo one > conftest.one
3886 echo two > conftest.two
3887 mkdir conftest.dir
3888 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
3889 test -s conftest.one && test -s conftest.two &&
3890 test -s conftest.dir/conftest.one &&
3891 test -s conftest.dir/conftest.two
3892 then
3893 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3894 break 3
3895 fi
3896 fi
3897 fi
3898 done
3899 done
3900 ;;
3901esac
3902
3903 done
3904IFS=$as_save_IFS
3905
3906rm -rf conftest.one conftest.two conftest.dir
3907
3908fi
3909 if test "${ac_cv_path_install+set}" = set; then
3910 INSTALL=$ac_cv_path_install
3911 else
3912 # As a last resort, use the slow shell script. Don't cache a
3913 # value for INSTALL within a source directory, because that will
3914 # break other packages using the cache if that directory is
3915 # removed, or if the value is a relative name.
3916 INSTALL=$ac_install_sh
3917 fi
3918fi
3919{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
3920$as_echo "$INSTALL" >&6; }
3921
3922# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3923# It thinks the first close brace ends the variable substitution.
3924test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3925
3926test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3927
3928test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3929
3930# Expand $ac_aux_dir to an absolute path.
3931am_aux_dir=`cd "$ac_aux_dir" && pwd`
3932
3933ac_ext=c
3934ac_cpp='$CPP $CPPFLAGS'
3935ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3936ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3937ac_compiler_gnu=$ac_cv_c_compiler_gnu
3938if test -n "$ac_tool_prefix"; then
3939 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
3940set dummy ${ac_tool_prefix}gcc; ac_word=$2
3941{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3942$as_echo_n "checking for $ac_word... " >&6; }
3943if ${ac_cv_prog_CC+:} false; then :
3944 $as_echo_n "(cached) " >&6
3945else
3946 if test -n "$CC"; then
3947 ac_cv_prog_CC="$CC" # Let the user override the test.
3948else
3949as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3950for as_dir in $PATH
3951do
3952 IFS=$as_save_IFS
3953 test -z "$as_dir" && as_dir=.
3954 for ac_exec_ext in '' $ac_executable_extensions; do
3955 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3956 ac_cv_prog_CC="${ac_tool_prefix}gcc"
3957 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3958 break 2
3959 fi
3960done
3961 done
3962IFS=$as_save_IFS
3963
3964fi
3965fi
3966CC=$ac_cv_prog_CC
3967if test -n "$CC"; then
3968 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3969$as_echo "$CC" >&6; }
3970else
3971 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3972$as_echo "no" >&6; }
3973fi
3974
3975
3976fi
3977if test -z "$ac_cv_prog_CC"; then
3978 ac_ct_CC=$CC
3979 # Extract the first word of "gcc", so it can be a program name with args.
3980set dummy gcc; ac_word=$2
3981{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3982$as_echo_n "checking for $ac_word... " >&6; }
3983if ${ac_cv_prog_ac_ct_CC+:} false; then :
3984 $as_echo_n "(cached) " >&6
3985else
3986 if test -n "$ac_ct_CC"; then
3987 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3988else
3989as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3990for as_dir in $PATH
3991do
3992 IFS=$as_save_IFS
3993 test -z "$as_dir" && as_dir=.
3994 for ac_exec_ext in '' $ac_executable_extensions; do
3995 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3996 ac_cv_prog_ac_ct_CC="gcc"
3997 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3998 break 2
3999 fi
4000done
4001 done
4002IFS=$as_save_IFS
4003
4004fi
4005fi
4006ac_ct_CC=$ac_cv_prog_ac_ct_CC
4007if test -n "$ac_ct_CC"; then
4008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4009$as_echo "$ac_ct_CC" >&6; }
4010else
4011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4012$as_echo "no" >&6; }
4013fi
4014
4015 if test "x$ac_ct_CC" = x; then
4016 CC=""
4017 else
4018 case $cross_compiling:$ac_tool_warned in
4019yes:)
4020{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4021$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4022ac_tool_warned=yes ;;
4023esac
4024 CC=$ac_ct_CC
4025 fi
4026else
4027 CC="$ac_cv_prog_CC"
4028fi
4029
4030if test -z "$CC"; then
4031 if test -n "$ac_tool_prefix"; then
4032 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4033set dummy ${ac_tool_prefix}cc; ac_word=$2
4034{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4035$as_echo_n "checking for $ac_word... " >&6; }
4036if ${ac_cv_prog_CC+:} false; then :
4037 $as_echo_n "(cached) " >&6
4038else
4039 if test -n "$CC"; then
4040 ac_cv_prog_CC="$CC" # Let the user override the test.
4041else
4042as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4043for as_dir in $PATH
4044do
4045 IFS=$as_save_IFS
4046 test -z "$as_dir" && as_dir=.
4047 for ac_exec_ext in '' $ac_executable_extensions; do
4048 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4049 ac_cv_prog_CC="${ac_tool_prefix}cc"
4050 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4051 break 2
4052 fi
4053done
4054 done
4055IFS=$as_save_IFS
4056
4057fi
4058fi
4059CC=$ac_cv_prog_CC
4060if test -n "$CC"; then
4061 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4062$as_echo "$CC" >&6; }
4063else
4064 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4065$as_echo "no" >&6; }
4066fi
4067
4068
4069 fi
4070fi
4071if test -z "$CC"; then
4072 # Extract the first word of "cc", so it can be a program name with args.
4073set dummy cc; ac_word=$2
4074{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4075$as_echo_n "checking for $ac_word... " >&6; }
4076if ${ac_cv_prog_CC+:} false; then :
4077 $as_echo_n "(cached) " >&6
4078else
4079 if test -n "$CC"; then
4080 ac_cv_prog_CC="$CC" # Let the user override the test.
4081else
4082 ac_prog_rejected=no
4083as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4084for as_dir in $PATH
4085do
4086 IFS=$as_save_IFS
4087 test -z "$as_dir" && as_dir=.
4088 for ac_exec_ext in '' $ac_executable_extensions; do
4089 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4090 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
4091 ac_prog_rejected=yes
4092 continue
4093 fi
4094 ac_cv_prog_CC="cc"
4095 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4096 break 2
4097 fi
4098done
4099 done
4100IFS=$as_save_IFS
4101
4102if test $ac_prog_rejected = yes; then
4103 # We found a bogon in the path, so make sure we never use it.
4104 set dummy $ac_cv_prog_CC
4105 shift
4106 if test $# != 0; then
4107 # We chose a different compiler from the bogus one.
4108 # However, it has the same basename, so the bogon will be chosen
4109 # first if we set CC to just the basename; use the full file name.
4110 shift
4111 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
4112 fi
4113fi
4114fi
4115fi
4116CC=$ac_cv_prog_CC
4117if test -n "$CC"; then
4118 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4119$as_echo "$CC" >&6; }
4120else
4121 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4122$as_echo "no" >&6; }
4123fi
4124
4125
4126fi
4127if test -z "$CC"; then
4128 if test -n "$ac_tool_prefix"; then
4129 for ac_prog in cl.exe
4130 do
4131 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4132set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4133{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4134$as_echo_n "checking for $ac_word... " >&6; }
4135if ${ac_cv_prog_CC+:} false; then :
4136 $as_echo_n "(cached) " >&6
4137else
4138 if test -n "$CC"; then
4139 ac_cv_prog_CC="$CC" # Let the user override the test.
4140else
4141as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4142for as_dir in $PATH
4143do
4144 IFS=$as_save_IFS
4145 test -z "$as_dir" && as_dir=.
4146 for ac_exec_ext in '' $ac_executable_extensions; do
4147 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4148 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
4149 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4150 break 2
4151 fi
4152done
4153 done
4154IFS=$as_save_IFS
4155
4156fi
4157fi
4158CC=$ac_cv_prog_CC
4159if test -n "$CC"; then
4160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4161$as_echo "$CC" >&6; }
4162else
4163 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4164$as_echo "no" >&6; }
4165fi
4166
4167
4168 test -n "$CC" && break
4169 done
4170fi
4171if test -z "$CC"; then
4172 ac_ct_CC=$CC
4173 for ac_prog in cl.exe
4174do
4175 # Extract the first word of "$ac_prog", so it can be a program name with args.
4176set dummy $ac_prog; ac_word=$2
4177{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4178$as_echo_n "checking for $ac_word... " >&6; }
4179if ${ac_cv_prog_ac_ct_CC+:} false; then :
4180 $as_echo_n "(cached) " >&6
4181else
4182 if test -n "$ac_ct_CC"; then
4183 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4184else
4185as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4186for as_dir in $PATH
4187do
4188 IFS=$as_save_IFS
4189 test -z "$as_dir" && as_dir=.
4190 for ac_exec_ext in '' $ac_executable_extensions; do
4191 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4192 ac_cv_prog_ac_ct_CC="$ac_prog"
4193 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4194 break 2
4195 fi
4196done
4197 done
4198IFS=$as_save_IFS
4199
4200fi
4201fi
4202ac_ct_CC=$ac_cv_prog_ac_ct_CC
4203if test -n "$ac_ct_CC"; then
4204 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4205$as_echo "$ac_ct_CC" >&6; }
4206else
4207 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4208$as_echo "no" >&6; }
4209fi
4210
4211
4212 test -n "$ac_ct_CC" && break
4213done
4214
4215 if test "x$ac_ct_CC" = x; then
4216 CC=""
4217 else
4218 case $cross_compiling:$ac_tool_warned in
4219yes:)
4220{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4221$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4222ac_tool_warned=yes ;;
4223esac
4224 CC=$ac_ct_CC
4225 fi
4226fi
4227
4228fi
4229
4230
4231test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4232$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4233as_fn_error $? "no acceptable C compiler found in \$PATH
4234See \`config.log' for more details" "$LINENO" 5; }
4235
4236# Provide some information about the compiler.
4237$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
4238set X $ac_compile
4239ac_compiler=$2
4240for ac_option in --version -v -V -qversion; do
4241 { { ac_try="$ac_compiler $ac_option >&5"
4242case "(($ac_try" in
4243 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4244 *) ac_try_echo=$ac_try;;
4245esac
4246eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4247$as_echo "$ac_try_echo"; } >&5
4248 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
4249 ac_status=$?
4250 if test -s conftest.err; then
4251 sed '10a\
4252... rest of stderr output deleted ...
4253 10q' conftest.err >conftest.er1
4254 cat conftest.er1 >&5
4255 fi
4256 rm -f conftest.er1 conftest.err
4257 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4258 test $ac_status = 0; }
4259done
4260
4261cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4262/* end confdefs.h. */
4263
4264int main (void)
4265{
4266
4267 ;
4268 return 0;
4269}
4270_ACEOF
4271ac_clean_files_save=$ac_clean_files
4272ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
4273# Try to create an executable without -o first, disregard a.out.
4274# It will help us diagnose broken compilers, and finding out an intuition
4275# of exeext.
4276{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
4277$as_echo_n "checking whether the C compiler works... " >&6; }
4278ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
4279
4280# The possible output files:
4281ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
4282
4283ac_rmfiles=
4284for ac_file in $ac_files
4285do
4286 case $ac_file in
4287 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4288 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
4289 esac
4290done
4291rm -f $ac_rmfiles
4292
4293if { { ac_try="$ac_link_default"
4294case "(($ac_try" in
4295 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4296 *) ac_try_echo=$ac_try;;
4297esac
4298eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4299$as_echo "$ac_try_echo"; } >&5
4300 (eval "$ac_link_default") 2>&5
4301 ac_status=$?
4302 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4303 test $ac_status = 0; }; then :
4304 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
4305# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
4306# in a Makefile. We should not override ac_cv_exeext if it was cached,
4307# so that the user can short-circuit this test for compilers unknown to
4308# Autoconf.
4309for ac_file in $ac_files ''
4310do
4311 test -f "$ac_file" || continue
4312 case $ac_file in
4313 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
4314 ;;
4315 [ab].out )
4316 # We found the default executable, but exeext='' is most
4317 # certainly right.
4318 break;;
4319 *.* )
4320 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
4321 then :; else
4322 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4323 fi
4324 # We set ac_cv_exeext here because the later test for it is not
4325 # safe: cross compilers may not add the suffix if given an `-o'
4326 # argument, so we may need to know it at that point already.
4327 # Even if this section looks crufty: it has the advantage of
4328 # actually working.
4329 break;;
4330 * )
4331 break;;
4332 esac
4333done
4334test "$ac_cv_exeext" = no && ac_cv_exeext=
4335
4336else
4337 ac_file=''
4338fi
4339if test -z "$ac_file"; then :
4340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4341$as_echo "no" >&6; }
4342$as_echo "$as_me: failed program was:" >&5
4343sed 's/^/| /' conftest.$ac_ext >&5
4344
4345{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4346$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4347as_fn_error 77 "C compiler cannot create executables
4348See \`config.log' for more details" "$LINENO" 5; }
4349else
4350 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4351$as_echo "yes" >&6; }
4352fi
4353{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
4354$as_echo_n "checking for C compiler default output file name... " >&6; }
4355{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
4356$as_echo "$ac_file" >&6; }
4357ac_exeext=$ac_cv_exeext
4358
4359rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
4360ac_clean_files=$ac_clean_files_save
4361{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
4362$as_echo_n "checking for suffix of executables... " >&6; }
4363if { { ac_try="$ac_link"
4364case "(($ac_try" in
4365 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4366 *) ac_try_echo=$ac_try;;
4367esac
4368eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4369$as_echo "$ac_try_echo"; } >&5
4370 (eval "$ac_link") 2>&5
4371 ac_status=$?
4372 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4373 test $ac_status = 0; }; then :
4374 # If both `conftest.exe' and `conftest' are `present' (well, observable)
4375# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
4376# work properly (i.e., refer to `conftest.exe'), while it won't with
4377# `rm'.
4378for ac_file in conftest.exe conftest conftest.*; do
4379 test -f "$ac_file" || continue
4380 case $ac_file in
4381 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4382 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4383 break;;
4384 * ) break;;
4385 esac
4386done
4387else
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 $? "cannot compute suffix of executables: cannot compile and link
4391See \`config.log' for more details" "$LINENO" 5; }
4392fi
4393rm -f conftest conftest$ac_cv_exeext
4394{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
4395$as_echo "$ac_cv_exeext" >&6; }
4396
4397rm -f conftest.$ac_ext
4398EXEEXT=$ac_cv_exeext
4399ac_exeext=$EXEEXT
4400cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4401/* end confdefs.h. */
4402#include <stdio.h>
4403int main (void)
4404{
4405FILE *f = fopen ("conftest.out", "w");
4406 return ferror (f) || fclose (f) != 0;
4407
4408 ;
4409 return 0;
4410}
4411_ACEOF
4412ac_clean_files="$ac_clean_files conftest.out"
4413# Check that the compiler produces executables we can run. If not, either
4414# the compiler is broken, or we cross compile.
4415{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
4416$as_echo_n "checking whether we are cross compiling... " >&6; }
4417if test "$cross_compiling" != yes; then
4418 { { ac_try="$ac_link"
4419case "(($ac_try" in
4420 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4421 *) ac_try_echo=$ac_try;;
4422esac
4423eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4424$as_echo "$ac_try_echo"; } >&5
4425 (eval "$ac_link") 2>&5
4426 ac_status=$?
4427 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4428 test $ac_status = 0; }
4429 if { ac_try='./conftest$ac_cv_exeext'
4430 { { case "(($ac_try" in
4431 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4432 *) ac_try_echo=$ac_try;;
4433esac
4434eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4435$as_echo "$ac_try_echo"; } >&5
4436 (eval "$ac_try") 2>&5
4437 ac_status=$?
4438 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4439 test $ac_status = 0; }; }; then
4440 cross_compiling=no
4441 else
4442 if test "$cross_compiling" = maybe; then
4443 cross_compiling=yes
4444 else
4445 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4446$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4447as_fn_error $? "cannot run C compiled programs.
4448If you meant to cross compile, use \`--host'.
4449See \`config.log' for more details" "$LINENO" 5; }
4450 fi
4451 fi
4452fi
4453{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
4454$as_echo "$cross_compiling" >&6; }
4455
4456rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
4457ac_clean_files=$ac_clean_files_save
4458{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
4459$as_echo_n "checking for suffix of object files... " >&6; }
4460if ${ac_cv_objext+:} false; then :
4461 $as_echo_n "(cached) " >&6
4462else
4463 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4464/* end confdefs.h. */
4465
4466int main (void)
4467{
4468
4469 ;
4470 return 0;
4471}
4472_ACEOF
4473rm -f conftest.o conftest.obj
4474if { { ac_try="$ac_compile"
4475case "(($ac_try" in
4476 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4477 *) ac_try_echo=$ac_try;;
4478esac
4479eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4480$as_echo "$ac_try_echo"; } >&5
4481 (eval "$ac_compile") 2>&5
4482 ac_status=$?
4483 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4484 test $ac_status = 0; }; then :
4485 for ac_file in conftest.o conftest.obj conftest.*; do
4486 test -f "$ac_file" || continue;
4487 case $ac_file in
4488 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
4489 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
4490 break;;
4491 esac
4492done
4493else
4494 $as_echo "$as_me: failed program was:" >&5
4495sed 's/^/| /' conftest.$ac_ext >&5
4496
4497{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4498$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4499as_fn_error $? "cannot compute suffix of object files: cannot compile
4500See \`config.log' for more details" "$LINENO" 5; }
4501fi
4502rm -f conftest.$ac_cv_objext conftest.$ac_ext
4503fi
4504{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
4505$as_echo "$ac_cv_objext" >&6; }
4506OBJEXT=$ac_cv_objext
4507ac_objext=$OBJEXT
4508{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
4509$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
4510if ${ac_cv_c_compiler_gnu+:} false; then :
4511 $as_echo_n "(cached) " >&6
4512else
4513 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4514/* end confdefs.h. */
4515
4516int main (void)
4517{
4518#ifndef __GNUC__
4519 choke me
4520#endif
4521
4522 ;
4523 return 0;
4524}
4525_ACEOF
4526if ac_fn_c_try_compile "$LINENO"; then :
4527 ac_compiler_gnu=yes
4528else
4529 ac_compiler_gnu=no
4530fi
4531rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4532ac_cv_c_compiler_gnu=$ac_compiler_gnu
4533
4534fi
4535{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
4536$as_echo "$ac_cv_c_compiler_gnu" >&6; }
4537if test $ac_compiler_gnu = yes; then
4538 GCC=yes
4539else
4540 GCC=
4541fi
4542ac_test_CFLAGS=${CFLAGS+set}
4543ac_save_CFLAGS=$CFLAGS
4544{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
4545$as_echo_n "checking whether $CC accepts -g... " >&6; }
4546if ${ac_cv_prog_cc_g+:} false; then :
4547 $as_echo_n "(cached) " >&6
4548else
4549 ac_save_c_werror_flag=$ac_c_werror_flag
4550 ac_c_werror_flag=yes
4551 ac_cv_prog_cc_g=no
4552 CFLAGS="-g"
4553 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4554/* end confdefs.h. */
4555
4556int main (void)
4557{
4558
4559 ;
4560 return 0;
4561}
4562_ACEOF
4563if ac_fn_c_try_compile "$LINENO"; then :
4564 ac_cv_prog_cc_g=yes
4565else
4566 CFLAGS=""
4567 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4568/* end confdefs.h. */
4569
4570int main (void)
4571{
4572
4573 ;
4574 return 0;
4575}
4576_ACEOF
4577if ac_fn_c_try_compile "$LINENO"; then :
4578
4579else
4580 ac_c_werror_flag=$ac_save_c_werror_flag
4581 CFLAGS="-g"
4582 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4583/* end confdefs.h. */
4584
4585int main (void)
4586{
4587
4588 ;
4589 return 0;
4590}
4591_ACEOF
4592if ac_fn_c_try_compile "$LINENO"; then :
4593 ac_cv_prog_cc_g=yes
4594fi
4595rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4596fi
4597rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4598fi
4599rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4600 ac_c_werror_flag=$ac_save_c_werror_flag
4601fi
4602{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
4603$as_echo "$ac_cv_prog_cc_g" >&6; }
4604if test "$ac_test_CFLAGS" = set; then
4605 CFLAGS=$ac_save_CFLAGS
4606elif test $ac_cv_prog_cc_g = yes; then
4607 if test "$GCC" = yes; then
4608 CFLAGS="-g -O2"
4609 else
4610 CFLAGS="-g"
4611 fi
4612else
4613 if test "$GCC" = yes; then
4614 CFLAGS="-O2"
4615 else
4616 CFLAGS=
4617 fi
4618fi
4619{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
4620$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
4621if ${ac_cv_prog_cc_c89+:} false; then :
4622 $as_echo_n "(cached) " >&6
4623else
4624 ac_cv_prog_cc_c89=no
4625ac_save_CC=$CC
4626cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4627/* end confdefs.h. */
4628#include <stdarg.h>
4629#include <stdio.h>
4630struct stat;
4631/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
4632struct buf { int x; };
4633FILE * (*rcsopen) (struct buf *, struct stat *, int);
4634static char *e (p, i)
4635 char **p;
4636 int i;
4637{
4638 return p[i];
4639}
4640static char *f (char * (*g) (char **, int), char **p, ...)
4641{
4642 char *s;
4643 va_list v;
4644 va_start (v,p);
4645 s = g (p, va_arg (v,int));
4646 va_end (v);
4647 return s;
4648}
4649
4650/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
4651 function prototypes and stuff, but not '\xHH' hex character constants.
4652 These don't provoke an error unfortunately, instead are silently treated
4653 as 'x'. The following induces an error, until -std is added to get
4654 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
4655 array size at least. It's necessary to write '\x00'==0 to get something
4656 that's true only with -std. */
4657int osf4_cc_array ['\x00' == 0 ? 1 : -1];
4658
4659/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
4660 inside strings and character constants. */
4661#define FOO(x) 'x'
4662int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
4663
4664int test (int i, double x);
4665struct s1 {int (*f) (int a);};
4666struct s2 {int (*f) (double a);};
4667int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4668int argc;
4669char **argv;
4670int main (void)
4671{
4672return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
4673 ;
4674 return 0;
4675}
4676_ACEOF
4677for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
4678 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4679do
4680 CC="$ac_save_CC $ac_arg"
4681 if ac_fn_c_try_compile "$LINENO"; then :
4682 ac_cv_prog_cc_c89=$ac_arg
4683fi
4684rm -f core conftest.err conftest.$ac_objext
4685 test "x$ac_cv_prog_cc_c89" != "xno" && break
4686done
4687rm -f conftest.$ac_ext
4688CC=$ac_save_CC
4689
4690fi
4691# AC_CACHE_VAL
4692case "x$ac_cv_prog_cc_c89" in
4693 x)
4694 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4695$as_echo "none needed" >&6; } ;;
4696 xno)
4697 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4698$as_echo "unsupported" >&6; } ;;
4699 *)
4700 CC="$CC $ac_cv_prog_cc_c89"
4701 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
4702$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
4703esac
4704if test "x$ac_cv_prog_cc_c89" != xno; then :
4705
4706fi
4707
4708ac_ext=c
4709ac_cpp='$CPP $CPPFLAGS'
4710ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4711ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4712ac_compiler_gnu=$ac_cv_c_compiler_gnu
4713
4714ac_ext=c
4715ac_cpp='$CPP $CPPFLAGS'
4716ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4717ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4718ac_compiler_gnu=$ac_cv_c_compiler_gnu
4719{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5
4720$as_echo_n "checking whether $CC understands -c and -o together... " >&6; }
4721if ${am_cv_prog_cc_c_o+:} false; then :
4722 $as_echo_n "(cached) " >&6
4723else
4724 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4725/* end confdefs.h. */
4726
4727int main (void)
4728{
4729
4730 ;
4731 return 0;
4732}
4733_ACEOF
4734 # Make sure it works both with $CC and with simple cc.
4735 # Following AC_PROG_CC_C_O, we do the test twice because some
4736 # compilers refuse to overwrite an existing .o file with -o,
4737 # though they will create one.
4738 am_cv_prog_cc_c_o=yes
4739 for am_i in 1 2; do
4740 if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5
4741 ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5
4742 ac_status=$?
4743 echo "$as_me:$LINENO: \$? = $ac_status" >&5
4744 (exit $ac_status); } \
4745 && test -f conftest2.$ac_objext; then
4746 : OK
4747 else
4748 am_cv_prog_cc_c_o=no
4749 break
4750 fi
4751 done
4752 rm -f core conftest*
4753 unset am_i
4754fi
4755{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5
4756$as_echo "$am_cv_prog_cc_c_o" >&6; }
4757if test "$am_cv_prog_cc_c_o" != yes; then
4758 # Losing compiler, so override with the script.
4759 # FIXME: It is wrong to rewrite CC.
4760 # But if we don't then we get into trouble of one sort or another.
4761 # A longer-term fix would be to have automake use am__CC in this case,
4762 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
4763 CC="$am_aux_dir/compile $CC"
4764fi
4765ac_ext=c
4766ac_cpp='$CPP $CPPFLAGS'
4767ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4768ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4769ac_compiler_gnu=$ac_cv_c_compiler_gnu
4770
4771
4772
4773ac_ext=c
4774ac_cpp='$CPP $CPPFLAGS'
4775ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4776ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4777ac_compiler_gnu=$ac_cv_c_compiler_gnu
4778{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
4779$as_echo_n "checking how to run the C preprocessor... " >&6; }
4780# On Suns, sometimes $CPP names a directory.
4781if test -n "$CPP" && test -d "$CPP"; then
4782 CPP=
4783fi
4784if test -z "$CPP"; then
4785 if ${ac_cv_prog_CPP+:} false; then :
4786 $as_echo_n "(cached) " >&6
4787else
4788 # Double quotes because CPP needs to be expanded
4789 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
4790 do
4791 ac_preproc_ok=false
4792for ac_c_preproc_warn_flag in '' yes
4793do
4794 # Use a header file that comes with gcc, so configuring glibc
4795 # with a fresh cross-compiler works.
4796 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4797 # <limits.h> exists even on freestanding compilers.
4798 # On the NeXT, cc -E runs the code through the compiler's parser,
4799 # not just through cpp. "Syntax error" is here to catch this case.
4800 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4801/* end confdefs.h. */
4802#ifdef __STDC__
4803# include <limits.h>
4804#else
4805# include <assert.h>
4806#endif
4807 Syntax error
4808_ACEOF
4809if ac_fn_c_try_cpp "$LINENO"; then :
4810
4811else
4812 # Broken: fails on valid input.
4813continue
4814fi
4815rm -f conftest.err conftest.i conftest.$ac_ext
4816
4817 # OK, works on sane cases. Now check whether nonexistent headers
4818 # can be detected and how.
4819 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4820/* end confdefs.h. */
4821#include <ac_nonexistent.h>
4822_ACEOF
4823if ac_fn_c_try_cpp "$LINENO"; then :
4824 # Broken: success on invalid input.
4825continue
4826else
4827 # Passes both tests.
4828ac_preproc_ok=:
4829break
4830fi
4831rm -f conftest.err conftest.i conftest.$ac_ext
4832
4833done
4834# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4835rm -f conftest.i conftest.err conftest.$ac_ext
4836if $ac_preproc_ok; then :
4837 break
4838fi
4839
4840 done
4841 ac_cv_prog_CPP=$CPP
4842
4843fi
4844 CPP=$ac_cv_prog_CPP
4845else
4846 ac_cv_prog_CPP=$CPP
4847fi
4848{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
4849$as_echo "$CPP" >&6; }
4850ac_preproc_ok=false
4851for ac_c_preproc_warn_flag in '' yes
4852do
4853 # Use a header file that comes with gcc, so configuring glibc
4854 # with a fresh cross-compiler works.
4855 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4856 # <limits.h> exists even on freestanding compilers.
4857 # On the NeXT, cc -E runs the code through the compiler's parser,
4858 # not just through cpp. "Syntax error" is here to catch this case.
4859 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4860/* end confdefs.h. */
4861#ifdef __STDC__
4862# include <limits.h>
4863#else
4864# include <assert.h>
4865#endif
4866 Syntax error
4867_ACEOF
4868if ac_fn_c_try_cpp "$LINENO"; then :
4869
4870else
4871 # Broken: fails on valid input.
4872continue
4873fi
4874rm -f conftest.err conftest.i conftest.$ac_ext
4875
4876 # OK, works on sane cases. Now check whether nonexistent headers
4877 # can be detected and how.
4878 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4879/* end confdefs.h. */
4880#include <ac_nonexistent.h>
4881_ACEOF
4882if ac_fn_c_try_cpp "$LINENO"; then :
4883 # Broken: success on invalid input.
4884continue
4885else
4886 # Passes both tests.
4887ac_preproc_ok=:
4888break
4889fi
4890rm -f conftest.err conftest.i conftest.$ac_ext
4891
4892done
4893# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4894rm -f conftest.i conftest.err conftest.$ac_ext
4895if $ac_preproc_ok; then :
4896
4897else
4898 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4899$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4900as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
4901See \`config.log' for more details" "$LINENO" 5; }
4902fi
4903
4904ac_ext=c
4905ac_cpp='$CPP $CPPFLAGS'
4906ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4907ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4908ac_compiler_gnu=$ac_cv_c_compiler_gnu
4909
4910
4911 IFS=$xc_prog_cc_prev_IFS
4912 LIBS=$xc_prog_cc_prev_LIBS
4913 CFLAGS=$xc_prog_cc_prev_CFLAGS
4914 LDFLAGS=$xc_prog_cc_prev_LDFLAGS
4915 CPPFLAGS=$xc_prog_cc_prev_CPPFLAGS
4916
4917
4918
4919
4920
Elliott Hughes0128fe42018-02-27 14:57:55 -08004921
4922{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
4923$as_echo_n "checking for a sed that does not truncate output... " >&6; }
4924if ${ac_cv_path_SED+:} false; then :
4925 $as_echo_n "(cached) " >&6
4926else
4927 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
4928 for ac_i in 1 2 3 4 5 6 7; do
4929 ac_script="$ac_script$as_nl$ac_script"
4930 done
4931 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
4932 { ac_script=; unset ac_script;}
4933 if test -z "$SED"; then
4934 ac_path_SED_found=false
4935 # Loop through the user's path and test for each of PROGNAME-LIST
4936 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4937for as_dir in $PATH
4938do
4939 IFS=$as_save_IFS
4940 test -z "$as_dir" && as_dir=.
4941 for ac_prog in sed gsed; do
4942 for ac_exec_ext in '' $ac_executable_extensions; do
4943 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
4944 as_fn_executable_p "$ac_path_SED" || continue
4945# Check for GNU ac_path_SED and select it if it is found.
4946 # Check for GNU $ac_path_SED
4947case `"$ac_path_SED" --version 2>&1` in
4948*GNU*)
4949 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
4950*)
4951 ac_count=0
4952 $as_echo_n 0123456789 >"conftest.in"
4953 while :
4954 do
4955 cat "conftest.in" "conftest.in" >"conftest.tmp"
4956 mv "conftest.tmp" "conftest.in"
4957 cp "conftest.in" "conftest.nl"
4958 $as_echo '' >> "conftest.nl"
4959 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
4960 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4961 as_fn_arith $ac_count + 1 && ac_count=$as_val
4962 if test $ac_count -gt ${ac_path_SED_max-0}; then
4963 # Best one so far, save it but keep looking for a better one
4964 ac_cv_path_SED="$ac_path_SED"
4965 ac_path_SED_max=$ac_count
4966 fi
4967 # 10*(2^10) chars as input seems more than enough
4968 test $ac_count -gt 10 && break
4969 done
4970 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4971esac
4972
4973 $ac_path_SED_found && break 3
4974 done
4975 done
4976 done
4977IFS=$as_save_IFS
4978 if test -z "$ac_cv_path_SED"; then
4979 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
4980 fi
4981else
4982 ac_cv_path_SED=$SED
4983fi
4984
4985fi
4986{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
4987$as_echo "$ac_cv_path_SED" >&6; }
4988 SED="$ac_cv_path_SED"
4989 rm -f conftest.sed
4990
Elliott Hughes0128fe42018-02-27 14:57:55 -08004991
4992
4993
Haibo Huang51d9d882019-02-06 01:36:06 -08004994 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for code coverage support" >&5
4995$as_echo_n "checking for code coverage support... " >&6; }
4996 coverage="no"
4997 curl_coverage_msg="disabled"
Elliott Hughes0128fe42018-02-27 14:57:55 -08004998
Haibo Huang51d9d882019-02-06 01:36:06 -08004999 # Check whether --enable-code-coverage was given.
Elliott Hughes0128fe42018-02-27 14:57:55 -08005000if test "${enable_code_coverage+set}" = set; then :
Haibo Huang001784b2019-07-19 05:27:28 -07005001 enableval=$enable_code_coverage; coverage="$enableval"
Elliott Hughes0128fe42018-02-27 14:57:55 -08005002fi
5003
5004
Haibo Huang51d9d882019-02-06 01:36:06 -08005005 if test "$GCC" != "yes" ; then :
5006 coverage="no"
Elliott Hughes0128fe42018-02-27 14:57:55 -08005007fi
Haibo Huang51d9d882019-02-06 01:36:06 -08005008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $coverage" >&5
5009$as_echo "$coverage" >&6; }
Elliott Hughes0128fe42018-02-27 14:57:55 -08005010
Haibo Huang51d9d882019-02-06 01:36:06 -08005011 if test "x$coverage" = "xyes"; then
5012 curl_coverage_msg="enabled"
Elliott Hughes0128fe42018-02-27 14:57:55 -08005013
Haibo Huang51d9d882019-02-06 01:36:06 -08005014 if test -n "$ac_tool_prefix"; then
5015 # Extract the first word of "${ac_tool_prefix}gcov", so it can be a program name with args.
5016set dummy ${ac_tool_prefix}gcov; ac_word=$2
Elliott Hughes0128fe42018-02-27 14:57:55 -08005017{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5018$as_echo_n "checking for $ac_word... " >&6; }
5019if ${ac_cv_prog_GCOV+:} false; then :
5020 $as_echo_n "(cached) " >&6
5021else
5022 if test -n "$GCOV"; then
5023 ac_cv_prog_GCOV="$GCOV" # Let the user override the test.
5024else
5025as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5026for as_dir in $PATH
5027do
5028 IFS=$as_save_IFS
5029 test -z "$as_dir" && as_dir=.
5030 for ac_exec_ext in '' $ac_executable_extensions; do
5031 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
Haibo Huang51d9d882019-02-06 01:36:06 -08005032 ac_cv_prog_GCOV="${ac_tool_prefix}gcov"
Elliott Hughes0128fe42018-02-27 14:57:55 -08005033 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5034 break 2
5035 fi
5036done
5037 done
5038IFS=$as_save_IFS
5039
5040fi
5041fi
5042GCOV=$ac_cv_prog_GCOV
5043if test -n "$GCOV"; then
5044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCOV" >&5
5045$as_echo "$GCOV" >&6; }
5046else
5047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5048$as_echo "no" >&6; }
5049fi
5050
5051
5052fi
5053if test -z "$ac_cv_prog_GCOV"; then
5054 ac_ct_GCOV=$GCOV
Haibo Huang51d9d882019-02-06 01:36:06 -08005055 # Extract the first word of "gcov", so it can be a program name with args.
5056set dummy gcov; ac_word=$2
Elliott Hughes0128fe42018-02-27 14:57:55 -08005057{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5058$as_echo_n "checking for $ac_word... " >&6; }
5059if ${ac_cv_prog_ac_ct_GCOV+:} false; then :
5060 $as_echo_n "(cached) " >&6
5061else
5062 if test -n "$ac_ct_GCOV"; then
5063 ac_cv_prog_ac_ct_GCOV="$ac_ct_GCOV" # Let the user override the test.
5064else
5065as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5066for as_dir in $PATH
5067do
5068 IFS=$as_save_IFS
5069 test -z "$as_dir" && as_dir=.
5070 for ac_exec_ext in '' $ac_executable_extensions; do
5071 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
Haibo Huang51d9d882019-02-06 01:36:06 -08005072 ac_cv_prog_ac_ct_GCOV="gcov"
Elliott Hughes0128fe42018-02-27 14:57:55 -08005073 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5074 break 2
5075 fi
5076done
5077 done
5078IFS=$as_save_IFS
5079
5080fi
5081fi
5082ac_ct_GCOV=$ac_cv_prog_ac_ct_GCOV
5083if test -n "$ac_ct_GCOV"; then
5084 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_GCOV" >&5
5085$as_echo "$ac_ct_GCOV" >&6; }
5086else
5087 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5088$as_echo "no" >&6; }
5089fi
5090
5091 if test "x$ac_ct_GCOV" = x; then
Haibo Huang51d9d882019-02-06 01:36:06 -08005092 GCOV="gcov"
Elliott Hughes0128fe42018-02-27 14:57:55 -08005093 else
5094 case $cross_compiling:$ac_tool_warned in
5095yes:)
5096{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5097$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5098ac_tool_warned=yes ;;
5099esac
5100 GCOV=$ac_ct_GCOV
5101 fi
5102else
5103 GCOV="$ac_cv_prog_GCOV"
5104fi
5105
Haibo Huang51d9d882019-02-06 01:36:06 -08005106 if test -z "$GCOV"; then
5107 as_fn_error $? "needs gcov for code coverage" "$LINENO" 5
5108 fi
5109 # Extract the first word of "lcov", so it can be a program name with args.
Elliott Hughes0128fe42018-02-27 14:57:55 -08005110set dummy lcov; ac_word=$2
5111{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5112$as_echo_n "checking for $ac_word... " >&6; }
5113if ${ac_cv_prog_LCOV+:} false; then :
5114 $as_echo_n "(cached) " >&6
5115else
5116 if test -n "$LCOV"; then
5117 ac_cv_prog_LCOV="$LCOV" # Let the user override the test.
5118else
5119as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5120for as_dir in $PATH
5121do
5122 IFS=$as_save_IFS
5123 test -z "$as_dir" && as_dir=.
5124 for ac_exec_ext in '' $ac_executable_extensions; do
5125 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5126 ac_cv_prog_LCOV="lcov"
5127 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5128 break 2
5129 fi
5130done
5131 done
5132IFS=$as_save_IFS
5133
5134fi
5135fi
5136LCOV=$ac_cv_prog_LCOV
5137if test -n "$LCOV"; then
5138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LCOV" >&5
5139$as_echo "$LCOV" >&6; }
5140else
5141 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5142$as_echo "no" >&6; }
5143fi
5144
5145
Haibo Huang51d9d882019-02-06 01:36:06 -08005146 if test -z "$LCOV"; then
5147 as_fn_error $? "needs lcov for code coverage" "$LINENO" 5
5148 fi
5149
5150 CPPFLAGS="$CPPFLAGS -DNDEBUG"
5151 CFLAGS="$CLAGS -O0 -g -fprofile-arcs -ftest-coverage"
5152 LIBS="$LIBS -lgcov"
Elliott Hughes0128fe42018-02-27 14:57:55 -08005153 fi
Elliott Hughes0128fe42018-02-27 14:57:55 -08005154
Elliott Hughes0128fe42018-02-27 14:57:55 -08005155
Haibo Huang001784b2019-07-19 05:27:28 -07005156am__api_version='1.16'
Elliott Hughes82be86d2017-09-20 17:00:17 -07005157
5158{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
5159$as_echo_n "checking whether build environment is sane... " >&6; }
5160# Reject unsafe characters in $srcdir or the absolute working directory
5161# name. Accept space and tab only in the latter.
5162am_lf='
5163'
5164case `pwd` in
5165 *[\\\"\#\$\&\'\`$am_lf]*)
5166 as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;;
5167esac
5168case $srcdir in
5169 *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
5170 as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;;
5171esac
5172
5173# Do 'set' in a subshell so we don't clobber the current shell's
5174# arguments. Must try -L first in case configure is actually a
5175# symlink; some systems play weird games with the mod time of symlinks
5176# (eg FreeBSD returns the mod time of the symlink's containing
5177# directory).
5178if (
5179 am_has_slept=no
5180 for am_try in 1 2; do
5181 echo "timestamp, slept: $am_has_slept" > conftest.file
5182 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
5183 if test "$*" = "X"; then
5184 # -L didn't work.
5185 set X `ls -t "$srcdir/configure" conftest.file`
5186 fi
5187 if test "$*" != "X $srcdir/configure conftest.file" \
5188 && test "$*" != "X conftest.file $srcdir/configure"; then
5189
5190 # If neither matched, then we have a broken ls. This can happen
5191 # if, for instance, CONFIG_SHELL is bash and it inherits a
5192 # broken ls alias from the environment. This has actually
5193 # happened. Such a system could not be considered "sane".
5194 as_fn_error $? "ls -t appears to fail. Make sure there is not a broken
5195 alias in your environment" "$LINENO" 5
5196 fi
5197 if test "$2" = conftest.file || test $am_try -eq 2; then
5198 break
5199 fi
5200 # Just in case.
5201 sleep 1
5202 am_has_slept=yes
5203 done
5204 test "$2" = conftest.file
5205 )
5206then
5207 # Ok.
5208 :
5209else
5210 as_fn_error $? "newly created file is older than distributed files!
5211Check your system clock" "$LINENO" 5
5212fi
5213{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5214$as_echo "yes" >&6; }
5215# If we didn't sleep, we still need to ensure time stamps of config.status and
5216# generated files are strictly newer.
5217am_sleep_pid=
5218if grep 'slept: no' conftest.file >/dev/null 2>&1; then
5219 ( sleep 1 ) &
5220 am_sleep_pid=$!
5221fi
5222
5223rm -f conftest.file
5224
5225test "$program_prefix" != NONE &&
5226 program_transform_name="s&^&$program_prefix&;$program_transform_name"
5227# Use a double $ so make ignores it.
5228test "$program_suffix" != NONE &&
5229 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
5230# Double any \ or $.
5231# By default was `s,x,x', remove it if useless.
5232ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
5233program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
5234
5235if test x"${MISSING+set}" != xset; then
5236 case $am_aux_dir in
5237 *\ * | *\ *)
5238 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
5239 *)
5240 MISSING="\${SHELL} $am_aux_dir/missing" ;;
5241 esac
5242fi
5243# Use eval to expand $SHELL
5244if eval "$MISSING --is-lightweight"; then
5245 am_missing_run="$MISSING "
5246else
5247 am_missing_run=
5248 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5
5249$as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;}
5250fi
5251
5252if test x"${install_sh+set}" != xset; then
5253 case $am_aux_dir in
5254 *\ * | *\ *)
5255 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
5256 *)
5257 install_sh="\${SHELL} $am_aux_dir/install-sh"
5258 esac
5259fi
5260
5261# Installed binaries are usually stripped using 'strip' when the user
5262# run "make install-strip". However 'strip' might not be the right
5263# tool to use in cross-compilation environments, therefore Automake
5264# will honor the 'STRIP' environment variable to overrule this program.
5265if test "$cross_compiling" != no; then
5266 if test -n "$ac_tool_prefix"; then
5267 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
5268set dummy ${ac_tool_prefix}strip; ac_word=$2
5269{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5270$as_echo_n "checking for $ac_word... " >&6; }
5271if ${ac_cv_prog_STRIP+:} false; then :
5272 $as_echo_n "(cached) " >&6
5273else
5274 if test -n "$STRIP"; then
5275 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
5276else
5277as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5278for as_dir in $PATH
5279do
5280 IFS=$as_save_IFS
5281 test -z "$as_dir" && as_dir=.
5282 for ac_exec_ext in '' $ac_executable_extensions; do
5283 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5284 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
5285 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5286 break 2
5287 fi
5288done
5289 done
5290IFS=$as_save_IFS
5291
5292fi
5293fi
5294STRIP=$ac_cv_prog_STRIP
5295if test -n "$STRIP"; then
5296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
5297$as_echo "$STRIP" >&6; }
5298else
5299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5300$as_echo "no" >&6; }
5301fi
5302
5303
5304fi
5305if test -z "$ac_cv_prog_STRIP"; then
5306 ac_ct_STRIP=$STRIP
5307 # Extract the first word of "strip", so it can be a program name with args.
5308set dummy strip; ac_word=$2
5309{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5310$as_echo_n "checking for $ac_word... " >&6; }
5311if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
5312 $as_echo_n "(cached) " >&6
5313else
5314 if test -n "$ac_ct_STRIP"; then
5315 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
5316else
5317as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5318for as_dir in $PATH
5319do
5320 IFS=$as_save_IFS
5321 test -z "$as_dir" && as_dir=.
5322 for ac_exec_ext in '' $ac_executable_extensions; do
5323 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5324 ac_cv_prog_ac_ct_STRIP="strip"
5325 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5326 break 2
5327 fi
5328done
5329 done
5330IFS=$as_save_IFS
5331
5332fi
5333fi
5334ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
5335if test -n "$ac_ct_STRIP"; then
5336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
5337$as_echo "$ac_ct_STRIP" >&6; }
5338else
5339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5340$as_echo "no" >&6; }
5341fi
5342
5343 if test "x$ac_ct_STRIP" = x; then
5344 STRIP=":"
5345 else
5346 case $cross_compiling:$ac_tool_warned in
5347yes:)
5348{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5349$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5350ac_tool_warned=yes ;;
5351esac
5352 STRIP=$ac_ct_STRIP
5353 fi
5354else
5355 STRIP="$ac_cv_prog_STRIP"
5356fi
5357
5358fi
5359INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
5360
5361{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
5362$as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
5363if test -z "$MKDIR_P"; then
5364 if ${ac_cv_path_mkdir+:} false; then :
5365 $as_echo_n "(cached) " >&6
5366else
5367 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5368for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
5369do
5370 IFS=$as_save_IFS
5371 test -z "$as_dir" && as_dir=.
5372 for ac_prog in mkdir gmkdir; do
5373 for ac_exec_ext in '' $ac_executable_extensions; do
5374 as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue
5375 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
5376 'mkdir (GNU coreutils) '* | \
5377 'mkdir (coreutils) '* | \
5378 'mkdir (fileutils) '4.1*)
5379 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
5380 break 3;;
5381 esac
5382 done
5383 done
5384 done
5385IFS=$as_save_IFS
5386
5387fi
5388
5389 test -d ./--version && rmdir ./--version
5390 if test "${ac_cv_path_mkdir+set}" = set; then
5391 MKDIR_P="$ac_cv_path_mkdir -p"
5392 else
5393 # As a last resort, use the slow shell script. Don't cache a
5394 # value for MKDIR_P within a source directory, because that will
5395 # break other packages using the cache if that directory is
5396 # removed, or if the value is a relative name.
5397 MKDIR_P="$ac_install_sh -d"
5398 fi
5399fi
5400{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
5401$as_echo "$MKDIR_P" >&6; }
5402
5403for ac_prog in gawk mawk nawk awk
5404do
5405 # Extract the first word of "$ac_prog", so it can be a program name with args.
5406set dummy $ac_prog; ac_word=$2
5407{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5408$as_echo_n "checking for $ac_word... " >&6; }
5409if ${ac_cv_prog_AWK+:} false; then :
5410 $as_echo_n "(cached) " >&6
5411else
5412 if test -n "$AWK"; then
5413 ac_cv_prog_AWK="$AWK" # Let the user override the test.
5414else
5415as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5416for as_dir in $PATH
5417do
5418 IFS=$as_save_IFS
5419 test -z "$as_dir" && as_dir=.
5420 for ac_exec_ext in '' $ac_executable_extensions; do
5421 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5422 ac_cv_prog_AWK="$ac_prog"
5423 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5424 break 2
5425 fi
5426done
5427 done
5428IFS=$as_save_IFS
5429
5430fi
5431fi
5432AWK=$ac_cv_prog_AWK
5433if test -n "$AWK"; then
5434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
5435$as_echo "$AWK" >&6; }
5436else
5437 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5438$as_echo "no" >&6; }
5439fi
5440
5441
5442 test -n "$AWK" && break
5443done
5444
5445{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
5446$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
5447set x ${MAKE-make}
5448ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
5449if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then :
5450 $as_echo_n "(cached) " >&6
5451else
5452 cat >conftest.make <<\_ACEOF
5453SHELL = /bin/sh
5454all:
5455 @echo '@@@%%%=$(MAKE)=@@@%%%'
5456_ACEOF
5457# GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
5458case `${MAKE-make} -f conftest.make 2>/dev/null` in
5459 *@@@%%%=?*=@@@%%%*)
5460 eval ac_cv_prog_make_${ac_make}_set=yes;;
5461 *)
5462 eval ac_cv_prog_make_${ac_make}_set=no;;
5463esac
5464rm -f conftest.make
5465fi
5466if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
5467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5468$as_echo "yes" >&6; }
5469 SET_MAKE=
5470else
5471 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5472$as_echo "no" >&6; }
5473 SET_MAKE="MAKE=${MAKE-make}"
5474fi
5475
5476rm -rf .tst 2>/dev/null
5477mkdir .tst 2>/dev/null
5478if test -d .tst; then
5479 am__leading_dot=.
5480else
5481 am__leading_dot=_
5482fi
5483rmdir .tst 2>/dev/null
5484
5485DEPDIR="${am__leading_dot}deps"
5486
5487ac_config_commands="$ac_config_commands depfiles"
5488
Haibo Huang001784b2019-07-19 05:27:28 -07005489{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} supports the include directive" >&5
5490$as_echo_n "checking whether ${MAKE-make} supports the include directive... " >&6; }
5491cat > confinc.mk << 'END'
Elliott Hughes82be86d2017-09-20 17:00:17 -07005492am__doit:
Haibo Huang001784b2019-07-19 05:27:28 -07005493 @echo this is the am__doit target >confinc.out
Elliott Hughes82be86d2017-09-20 17:00:17 -07005494.PHONY: am__doit
5495END
Elliott Hughes82be86d2017-09-20 17:00:17 -07005496am__include="#"
5497am__quote=
Haibo Huang001784b2019-07-19 05:27:28 -07005498# BSD make does it like this.
5499echo '.include "confinc.mk" # ignored' > confmf.BSD
5500# Other make implementations (GNU, Solaris 10, AIX) do it like this.
5501echo 'include confinc.mk # ignored' > confmf.GNU
5502_am_result=no
5503for s in GNU BSD; do
5504 { echo "$as_me:$LINENO: ${MAKE-make} -f confmf.$s && cat confinc.out" >&5
5505 (${MAKE-make} -f confmf.$s && cat confinc.out) >&5 2>&5
5506 ac_status=$?
5507 echo "$as_me:$LINENO: \$? = $ac_status" >&5
5508 (exit $ac_status); }
5509 case $?:`cat confinc.out 2>/dev/null` in #(
5510 '0:this is the am__doit target') :
5511 case $s in #(
5512 BSD) :
5513 am__include='.include' am__quote='"' ;; #(
5514 *) :
5515 am__include='include' am__quote='' ;;
5516esac ;; #(
5517 *) :
Elliott Hughes82be86d2017-09-20 17:00:17 -07005518 ;;
Haibo Huang001784b2019-07-19 05:27:28 -07005519esac
5520 if test "$am__include" != "#"; then
5521 _am_result="yes ($s style)"
5522 break
5523 fi
5524done
5525rm -f confinc.* confmf.*
5526{ $as_echo "$as_me:${as_lineno-$LINENO}: result: ${_am_result}" >&5
5527$as_echo "${_am_result}" >&6; }
Elliott Hughes82be86d2017-09-20 17:00:17 -07005528
5529# Check whether --enable-dependency-tracking was given.
5530if test "${enable_dependency_tracking+set}" = set; then :
5531 enableval=$enable_dependency_tracking;
5532fi
5533
5534if test "x$enable_dependency_tracking" != xno; then
5535 am_depcomp="$ac_aux_dir/depcomp"
5536 AMDEPBACKSLASH='\'
5537 am__nodep='_no'
5538fi
5539 if test "x$enable_dependency_tracking" != xno; then
5540 AMDEP_TRUE=
5541 AMDEP_FALSE='#'
5542else
5543 AMDEP_TRUE='#'
5544 AMDEP_FALSE=
5545fi
5546
5547
5548## --------------------------------------- ##
5549## Start of automake initialization code ##
5550## --------------------------------------- ##
5551
5552if test "`cd $srcdir && pwd`" != "`pwd`"; then
5553 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
5554 # is not polluted with repeated "-I."
5555 am__isrc=' -I$(srcdir)'
5556 # test to see if srcdir already configured
5557 if test -f $srcdir/config.status; then
5558 as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
5559 fi
5560fi
5561
5562# test whether we have cygpath
5563if test -z "$CYGPATH_W"; then
5564 if (cygpath --version) >/dev/null 2>/dev/null; then
5565 CYGPATH_W='cygpath -w'
5566 else
5567 CYGPATH_W=echo
5568 fi
5569fi
5570
5571
5572# Define the identity of the package.
5573 PACKAGE='curl'
5574 VERSION='-'
5575
5576
5577cat >>confdefs.h <<_ACEOF
5578#define PACKAGE "$PACKAGE"
5579_ACEOF
5580
5581
5582cat >>confdefs.h <<_ACEOF
5583#define VERSION "$VERSION"
5584_ACEOF
5585
5586# Some tools Automake needs.
5587
5588ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
5589
5590
5591AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
5592
5593
5594AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
5595
5596
5597AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
5598
5599
5600MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
5601
5602# For better backward compatibility. To be removed once Automake 1.9.x
5603# dies out for good. For more background, see:
Haibo Huang001784b2019-07-19 05:27:28 -07005604# <https://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
5605# <https://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
Elliott Hughes82be86d2017-09-20 17:00:17 -07005606mkdir_p='$(MKDIR_P)'
5607
5608# We need awk for the "check" target (and possibly the TAP driver). The
5609# system "awk" is bad on some platforms.
5610# Always define AMTAR for backward compatibility. Yes, it's still used
5611# in the wild :-( We should find a proper way to deprecate it ...
5612AMTAR='$${TAR-tar}'
5613
5614
5615# We'll loop over all known methods to create a tar archive until one works.
5616_am_tools='gnutar pax cpio none'
5617
5618am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'
5619
5620
5621
5622
5623
5624depcc="$CC" am_compiler_list=
5625
5626{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
5627$as_echo_n "checking dependency style of $depcc... " >&6; }
5628if ${am_cv_CC_dependencies_compiler_type+:} false; then :
5629 $as_echo_n "(cached) " >&6
5630else
5631 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
5632 # We make a subdir and do the tests there. Otherwise we can end up
5633 # making bogus files that we don't know about and never remove. For
5634 # instance it was reported that on HP-UX the gcc test will end up
5635 # making a dummy file named 'D' -- because '-MD' means "put the output
5636 # in D".
5637 rm -rf conftest.dir
5638 mkdir conftest.dir
5639 # Copy depcomp to subdir because otherwise we won't find it if we're
5640 # using a relative directory.
5641 cp "$am_depcomp" conftest.dir
5642 cd conftest.dir
5643 # We will build objects and dependencies in a subdirectory because
5644 # it helps to detect inapplicable dependency modes. For instance
5645 # both Tru64's cc and ICC support -MD to output dependencies as a
5646 # side effect of compilation, but ICC will put the dependencies in
5647 # the current directory while Tru64 will put them in the object
5648 # directory.
5649 mkdir sub
5650
5651 am_cv_CC_dependencies_compiler_type=none
5652 if test "$am_compiler_list" = ""; then
5653 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
5654 fi
5655 am__universal=false
5656 case " $depcc " in #(
5657 *\ -arch\ *\ -arch\ *) am__universal=true ;;
5658 esac
5659
5660 for depmode in $am_compiler_list; do
5661 # Setup a source with many dependencies, because some compilers
5662 # like to wrap large dependency lists on column 80 (with \), and
5663 # we should not choose a depcomp mode which is confused by this.
5664 #
5665 # We need to recreate these files for each test, as the compiler may
5666 # overwrite some of them when testing with obscure command lines.
5667 # This happens at least with the AIX C compiler.
5668 : > sub/conftest.c
5669 for i in 1 2 3 4 5 6; do
5670 echo '#include "conftst'$i'.h"' >> sub/conftest.c
5671 # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
5672 # Solaris 10 /bin/sh.
5673 echo '/* dummy */' > sub/conftst$i.h
5674 done
5675 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
5676
5677 # We check with '-c' and '-o' for the sake of the "dashmstdout"
5678 # mode. It turns out that the SunPro C++ compiler does not properly
5679 # handle '-M -o', and we need to detect this. Also, some Intel
5680 # versions had trouble with output in subdirs.
5681 am__obj=sub/conftest.${OBJEXT-o}
5682 am__minus_obj="-o $am__obj"
5683 case $depmode in
5684 gcc)
5685 # This depmode causes a compiler race in universal mode.
5686 test "$am__universal" = false || continue
5687 ;;
5688 nosideeffect)
5689 # After this tag, mechanisms are not by side-effect, so they'll
5690 # only be used when explicitly requested.
5691 if test "x$enable_dependency_tracking" = xyes; then
5692 continue
5693 else
5694 break
5695 fi
5696 ;;
5697 msvc7 | msvc7msys | msvisualcpp | msvcmsys)
5698 # This compiler won't grok '-c -o', but also, the minuso test has
5699 # not run yet. These depmodes are late enough in the game, and
5700 # so weak that their functioning should not be impacted.
5701 am__obj=conftest.${OBJEXT-o}
5702 am__minus_obj=
5703 ;;
5704 none) break ;;
5705 esac
5706 if depmode=$depmode \
5707 source=sub/conftest.c object=$am__obj \
5708 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
5709 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
5710 >/dev/null 2>conftest.err &&
5711 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
5712 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
5713 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
5714 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
5715 # icc doesn't choke on unknown options, it will just issue warnings
5716 # or remarks (even with -Werror). So we grep stderr for any message
5717 # that says an option was ignored or not supported.
5718 # When given -MP, icc 7.0 and 7.1 complain thusly:
5719 # icc: Command line warning: ignoring option '-M'; no argument required
5720 # The diagnosis changed in icc 8.0:
5721 # icc: Command line remark: option '-MP' not supported
5722 if (grep 'ignoring option' conftest.err ||
5723 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
5724 am_cv_CC_dependencies_compiler_type=$depmode
5725 break
5726 fi
5727 fi
5728 done
5729
5730 cd ..
5731 rm -rf conftest.dir
5732else
5733 am_cv_CC_dependencies_compiler_type=none
5734fi
5735
5736fi
5737{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
5738$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
5739CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
5740
5741 if
5742 test "x$enable_dependency_tracking" != xno \
5743 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
5744 am__fastdepCC_TRUE=
5745 am__fastdepCC_FALSE='#'
5746else
5747 am__fastdepCC_TRUE='#'
5748 am__fastdepCC_FALSE=
5749fi
5750
5751
5752
5753# POSIX will say in a future version that running "rm -f" with no argument
5754# is OK; and we want to be able to make that assumption in our Makefile
5755# recipes. So use an aggressive probe to check that the usage we want is
5756# actually supported "in the wild" to an acceptable degree.
5757# See automake bug#10828.
5758# To make any issue more visible, cause the running configure to be aborted
5759# by default if the 'rm' program in use doesn't match our expectations; the
5760# user can still override this though.
5761if rm -f && rm -fr && rm -rf; then : OK; else
5762 cat >&2 <<'END'
5763Oops!
5764
5765Your 'rm' program seems unable to run without file operands specified
5766on the command line, even when the '-f' option is present. This is contrary
5767to the behaviour of most rm programs out there, and not conforming with
5768the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
5769
5770Please tell bug-automake@gnu.org about your system, including the value
5771of your $PATH and any error possibly output before this message. This
5772can help us improve future automake versions.
5773
5774END
5775 if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then
5776 echo 'Configuration will proceed anyway, since you have set the' >&2
5777 echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
5778 echo >&2
5779 else
5780 cat >&2 <<'END'
5781Aborting the configuration process, to ensure you take notice of the issue.
5782
5783You can download and install GNU coreutils to get an 'rm' implementation
Haibo Huang001784b2019-07-19 05:27:28 -07005784that behaves properly: <https://www.gnu.org/software/coreutils/>.
Elliott Hughes82be86d2017-09-20 17:00:17 -07005785
5786If you want to complete the configuration process using your problematic
5787'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
5788to "yes", and re-run configure.
5789
5790END
5791 as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5
5792 fi
5793fi
5794
5795## ------------------------------------- ##
5796## End of automake initialization code ##
5797## ------------------------------------- ##
5798
5799
5800{ $as_echo "$as_me:${as_lineno-$LINENO}: checking curl version" >&5
5801$as_echo_n "checking curl version... " >&6; }
5802{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CURLVERSION" >&5
5803$as_echo "$CURLVERSION" >&6; }
5804
5805
5806
5807VERSIONNUM=`$SED -ne 's/^#define LIBCURL_VERSION_NUM 0x\([0-9A-Fa-f]*\).*/\1/p' ${srcdir}/include/curl/curlver.h`
5808
5809
5810PKGADD_PKG="HAXXcurl"
5811PKGADD_NAME="curl - a client that groks URLs"
5812PKGADD_VENDOR="curl.haxx.se"
5813
5814
5815
5816
Haibo Huang001784b2019-07-19 05:27:28 -07005817 curl_ssl_msg="no (--with-{ssl,gnutls,nss,mbedtls,wolfssl,schannel,secure-transport,mesalink,amissl} )"
Elliott Hughes82be86d2017-09-20 17:00:17 -07005818 curl_ssh_msg="no (--with-libssh2)"
5819 curl_zlib_msg="no (--with-zlib)"
Alex Deymo486467e2017-12-19 19:04:07 +01005820 curl_brotli_msg="no (--with-brotli)"
Elliott Hughes82be86d2017-09-20 17:00:17 -07005821 curl_gss_msg="no (--with-gssapi)"
5822curl_tls_srp_msg="no (--enable-tls-srp)"
5823 curl_res_msg="default (--enable-ares / --enable-threaded-resolver)"
5824 curl_ipv6_msg="no (--enable-ipv6)"
5825curl_unix_sockets_msg="no (--enable-unix-sockets)"
5826 curl_idn_msg="no (--with-{libidn2,winidn})"
5827 curl_manual_msg="no (--enable-manual)"
5828curl_libcurl_msg="enabled (--disable-libcurl-option)"
5829curl_verbose_msg="enabled (--disable-verbose)"
5830 curl_sspi_msg="no (--enable-sspi)"
5831 curl_ldap_msg="no (--enable-ldap / --with-ldap-lib / --with-lber-lib)"
5832 curl_ldaps_msg="no (--enable-ldaps)"
5833 curl_rtsp_msg="no (--enable-rtsp)"
5834 curl_rtmp_msg="no (--with-librtmp)"
5835 curl_mtlnk_msg="no (--with-libmetalink)"
5836 curl_psl_msg="no (--with-libpsl)"
5837
Alex Deymo486467e2017-12-19 19:04:07 +01005838 ssl_backends=
Elliott Hughes82be86d2017-09-20 17:00:17 -07005839
5840INITIAL_LDFLAGS=$LDFLAGS
5841INITIAL_LIBS=$LIBS
5842
5843
5844# Make sure we can run config.sub.
5845$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
5846 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
5847
5848{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
5849$as_echo_n "checking build system type... " >&6; }
5850if ${ac_cv_build+:} false; then :
5851 $as_echo_n "(cached) " >&6
5852else
5853 ac_build_alias=$build_alias
5854test "x$ac_build_alias" = x &&
5855 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
5856test "x$ac_build_alias" = x &&
5857 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
5858ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
5859 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
5860
5861fi
5862{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
5863$as_echo "$ac_cv_build" >&6; }
5864case $ac_cv_build in
5865*-*-*) ;;
5866*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
5867esac
5868build=$ac_cv_build
5869ac_save_IFS=$IFS; IFS='-'
5870set x $ac_cv_build
5871shift
5872build_cpu=$1
5873build_vendor=$2
5874shift; shift
5875# Remember, the first character of IFS is used to create $*,
5876# except with old shells:
5877build_os=$*
5878IFS=$ac_save_IFS
5879case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
5880
5881
5882{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
5883$as_echo_n "checking host system type... " >&6; }
5884if ${ac_cv_host+:} false; then :
5885 $as_echo_n "(cached) " >&6
5886else
5887 if test "x$host_alias" = x; then
5888 ac_cv_host=$ac_cv_build
5889else
5890 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
5891 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
5892fi
5893
5894fi
5895{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
5896$as_echo "$ac_cv_host" >&6; }
5897case $ac_cv_host in
5898*-*-*) ;;
5899*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
5900esac
5901host=$ac_cv_host
5902ac_save_IFS=$IFS; IFS='-'
5903set x $ac_cv_host
5904shift
5905host_cpu=$1
5906host_vendor=$2
5907shift; shift
5908# Remember, the first character of IFS is used to create $*,
5909# except with old shells:
5910host_os=$*
5911IFS=$ac_save_IFS
5912case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
5913
5914
5915
5916cat >>confdefs.h <<_ACEOF
5917#define OS "${host}"
5918_ACEOF
5919
5920
Elliott Hughes72d948d2018-08-03 14:37:21 -07005921# Silence warning: ar: 'u' modifier ignored since 'D' is the default
5922AR_FLAGS=cr
5923
Elliott Hughes82be86d2017-09-20 17:00:17 -07005924
5925
5926
Elliott Hughes82be86d2017-09-20 17:00:17 -07005927{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
5928$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
5929if ${ac_cv_path_GREP+:} false; then :
5930 $as_echo_n "(cached) " >&6
5931else
5932 if test -z "$GREP"; then
5933 ac_path_GREP_found=false
5934 # Loop through the user's path and test for each of PROGNAME-LIST
5935 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5936for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5937do
5938 IFS=$as_save_IFS
5939 test -z "$as_dir" && as_dir=.
5940 for ac_prog in grep ggrep; do
5941 for ac_exec_ext in '' $ac_executable_extensions; do
5942 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
5943 as_fn_executable_p "$ac_path_GREP" || continue
5944# Check for GNU ac_path_GREP and select it if it is found.
5945 # Check for GNU $ac_path_GREP
5946case `"$ac_path_GREP" --version 2>&1` in
5947*GNU*)
5948 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
5949*)
5950 ac_count=0
5951 $as_echo_n 0123456789 >"conftest.in"
5952 while :
5953 do
5954 cat "conftest.in" "conftest.in" >"conftest.tmp"
5955 mv "conftest.tmp" "conftest.in"
5956 cp "conftest.in" "conftest.nl"
5957 $as_echo 'GREP' >> "conftest.nl"
5958 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5959 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5960 as_fn_arith $ac_count + 1 && ac_count=$as_val
5961 if test $ac_count -gt ${ac_path_GREP_max-0}; then
5962 # Best one so far, save it but keep looking for a better one
5963 ac_cv_path_GREP="$ac_path_GREP"
5964 ac_path_GREP_max=$ac_count
5965 fi
5966 # 10*(2^10) chars as input seems more than enough
5967 test $ac_count -gt 10 && break
5968 done
5969 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5970esac
5971
5972 $ac_path_GREP_found && break 3
5973 done
5974 done
5975 done
5976IFS=$as_save_IFS
5977 if test -z "$ac_cv_path_GREP"; then
5978 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
5979 fi
5980else
5981 ac_cv_path_GREP=$GREP
5982fi
5983
5984fi
5985{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
5986$as_echo "$ac_cv_path_GREP" >&6; }
5987 GREP="$ac_cv_path_GREP"
5988
5989
5990{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
5991$as_echo_n "checking for egrep... " >&6; }
5992if ${ac_cv_path_EGREP+:} false; then :
5993 $as_echo_n "(cached) " >&6
5994else
5995 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
5996 then ac_cv_path_EGREP="$GREP -E"
5997 else
5998 if test -z "$EGREP"; then
5999 ac_path_EGREP_found=false
6000 # Loop through the user's path and test for each of PROGNAME-LIST
6001 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6002for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
6003do
6004 IFS=$as_save_IFS
6005 test -z "$as_dir" && as_dir=.
6006 for ac_prog in egrep; do
6007 for ac_exec_ext in '' $ac_executable_extensions; do
6008 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
6009 as_fn_executable_p "$ac_path_EGREP" || continue
6010# Check for GNU ac_path_EGREP and select it if it is found.
6011 # Check for GNU $ac_path_EGREP
6012case `"$ac_path_EGREP" --version 2>&1` in
6013*GNU*)
6014 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
6015*)
6016 ac_count=0
6017 $as_echo_n 0123456789 >"conftest.in"
6018 while :
6019 do
6020 cat "conftest.in" "conftest.in" >"conftest.tmp"
6021 mv "conftest.tmp" "conftest.in"
6022 cp "conftest.in" "conftest.nl"
6023 $as_echo 'EGREP' >> "conftest.nl"
6024 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
6025 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
6026 as_fn_arith $ac_count + 1 && ac_count=$as_val
6027 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
6028 # Best one so far, save it but keep looking for a better one
6029 ac_cv_path_EGREP="$ac_path_EGREP"
6030 ac_path_EGREP_max=$ac_count
6031 fi
6032 # 10*(2^10) chars as input seems more than enough
6033 test $ac_count -gt 10 && break
6034 done
6035 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
6036esac
6037
6038 $ac_path_EGREP_found && break 3
6039 done
6040 done
6041 done
6042IFS=$as_save_IFS
6043 if test -z "$ac_cv_path_EGREP"; then
6044 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
6045 fi
6046else
6047 ac_cv_path_EGREP=$EGREP
6048fi
6049
6050 fi
6051fi
6052{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
6053$as_echo "$ac_cv_path_EGREP" >&6; }
6054 EGREP="$ac_cv_path_EGREP"
6055
6056
Elliott Hughes82be86d2017-09-20 17:00:17 -07006057
6058
6059 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if OS is AIX (to define _ALL_SOURCE)" >&5
6060$as_echo_n "checking if OS is AIX (to define _ALL_SOURCE)... " >&6; }
6061 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6062/* end confdefs.h. */
6063
6064#ifdef _AIX
6065 yes_this_is_aix
6066#endif
6067
6068_ACEOF
6069if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6070 $EGREP "yes_this_is_aix" >/dev/null 2>&1; then :
6071
6072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6073$as_echo "yes" >&6; }
6074 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
6075
6076
6077else
6078
6079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6080$as_echo "no" >&6; }
6081
6082fi
6083rm -f conftest*
6084
6085
6086
6087
6088 #
6089 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if _THREAD_SAFE is already defined" >&5
6090$as_echo_n "checking if _THREAD_SAFE is already defined... " >&6; }
6091 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6092/* end confdefs.h. */
6093
6094
6095
6096int main (void)
6097{
6098
6099#ifdef _THREAD_SAFE
6100 int dummy=1;
6101#else
6102 force compilation error
6103#endif
6104
6105 ;
6106 return 0;
6107}
6108
6109_ACEOF
6110if ac_fn_c_try_compile "$LINENO"; then :
6111
6112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6113$as_echo "yes" >&6; }
6114 tmp_thread_safe_initially_defined="yes"
6115
6116else
6117
6118 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6119$as_echo "no" >&6; }
6120 tmp_thread_safe_initially_defined="no"
6121
6122fi
6123rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6124 #
6125 if test "$tmp_thread_safe_initially_defined" = "no"; then
6126 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if _THREAD_SAFE is actually needed" >&5
6127$as_echo_n "checking if _THREAD_SAFE is actually needed... " >&6; }
6128
6129 case $host_os in
6130 aix[123].* | aix4.[012].*)
6131 tmp_need_thread_safe="no"
6132 ;;
6133 aix*)
6134 tmp_need_thread_safe="yes"
6135 ;;
6136 *)
6137 tmp_need_thread_safe="no"
6138 ;;
6139 esac
6140
6141 if test "$tmp_need_thread_safe" = "yes"; then
6142 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6143$as_echo "yes" >&6; }
6144 else
6145 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6146$as_echo "no" >&6; }
6147 fi
6148 fi
6149 #
6150 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if _THREAD_SAFE is onwards defined" >&5
6151$as_echo_n "checking if _THREAD_SAFE is onwards defined... " >&6; }
6152 if test "$tmp_thread_safe_initially_defined" = "yes" ||
6153 test "$tmp_need_thread_safe" = "yes"; then
6154
6155
6156$as_echo "#define NEED_THREAD_SAFE 1" >>confdefs.h
6157
6158cat >>confdefs.h <<_EOF
6159#ifndef _THREAD_SAFE
6160# define _THREAD_SAFE
6161#endif
6162_EOF
6163
6164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6165$as_echo "yes" >&6; }
6166 else
6167 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6168$as_echo "no" >&6; }
6169 fi
6170 #
6171
6172
6173 #
6174 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if _REENTRANT is already defined" >&5
6175$as_echo_n "checking if _REENTRANT is already defined... " >&6; }
6176 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6177/* end confdefs.h. */
6178
6179
6180
6181int main (void)
6182{
6183
6184#ifdef _REENTRANT
6185 int dummy=1;
6186#else
6187 force compilation error
6188#endif
6189
6190 ;
6191 return 0;
6192}
6193
6194_ACEOF
6195if ac_fn_c_try_compile "$LINENO"; then :
6196
6197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6198$as_echo "yes" >&6; }
6199 tmp_reentrant_initially_defined="yes"
6200
6201else
6202
6203 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6204$as_echo "no" >&6; }
6205 tmp_reentrant_initially_defined="no"
6206
6207fi
6208rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6209 #
6210 if test "$tmp_reentrant_initially_defined" = "no"; then
6211 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if _REENTRANT is actually needed" >&5
6212$as_echo_n "checking if _REENTRANT is actually needed... " >&6; }
6213
6214 case $host_os in
6215 solaris*)
6216 tmp_need_reentrant="yes"
6217 ;;
6218 *)
6219 tmp_need_reentrant="no"
6220 ;;
6221 esac
6222
6223 if test "$tmp_need_reentrant" = "no"; then
6224
6225 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6226/* end confdefs.h. */
6227
6228
6229#include <errno.h>
6230
6231int main (void)
6232{
6233
6234 if(0 != errno)
6235 return 1;
6236
6237 ;
6238 return 0;
6239}
6240
6241_ACEOF
6242if ac_fn_c_try_compile "$LINENO"; then :
6243
6244 tmp_errno="yes"
6245
6246else
6247
6248 tmp_errno="no"
6249
6250fi
6251rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6252 if test "$tmp_errno" = "yes"; then
6253 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6254/* end confdefs.h. */
6255
6256
6257#include <errno.h>
6258
6259int main (void)
6260{
6261
6262#ifdef errno
6263 int dummy=1;
6264#else
6265 force compilation error
6266#endif
6267
6268 ;
6269 return 0;
6270}
6271
6272_ACEOF
6273if ac_fn_c_try_compile "$LINENO"; then :
6274
6275 tmp_errno="errno_macro_defined"
6276
6277else
6278
6279 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6280/* end confdefs.h. */
6281
6282
6283#define _REENTRANT
6284#include <errno.h>
6285
6286int main (void)
6287{
6288
6289#ifdef errno
6290 int dummy=1;
6291#else
6292 force compilation error
6293#endif
6294
6295 ;
6296 return 0;
6297}
6298
6299_ACEOF
6300if ac_fn_c_try_compile "$LINENO"; then :
6301
6302 tmp_errno="errno_macro_needs_reentrant"
6303 tmp_need_reentrant="yes"
6304
6305fi
6306rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6307
6308fi
6309rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6310 fi
6311
6312 fi
6313 if test "$tmp_need_reentrant" = "no"; then
6314
6315 if test "$tmp_need_reentrant" = "no"; then
6316
6317 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6318/* end confdefs.h. */
6319
6320
6321#define gmtime_r innocuous_gmtime_r
6322#ifdef __STDC__
6323# include <limits.h>
6324#else
6325# include <assert.h>
6326#endif
6327#undef gmtime_r
6328#ifdef __cplusplus
6329extern "C"
6330#endif
6331char gmtime_r ();
6332#if defined __stub_gmtime_r || defined __stub___gmtime_r
6333choke me
6334#endif
6335
6336int main (void)
6337{
6338return gmtime_r ();
6339 ;
6340 return 0;
6341}
6342
6343_ACEOF
6344if ac_fn_c_try_link "$LINENO"; then :
6345
6346 tmp_gmtime_r="yes"
6347
6348else
6349
6350 tmp_gmtime_r="no"
6351
6352fi
6353rm -f core conftest.err conftest.$ac_objext \
6354 conftest$ac_exeext conftest.$ac_ext
6355 if test "$tmp_gmtime_r" = "yes"; then
6356 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6357/* end confdefs.h. */
6358
6359#include <sys/types.h>
6360#include <time.h>
6361
6362_ACEOF
6363if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6364 $EGREP "gmtime_r" >/dev/null 2>&1; then :
6365
6366 tmp_gmtime_r="proto_declared"
6367
6368else
6369
6370 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6371/* end confdefs.h. */
6372
6373#define _REENTRANT
6374#include <sys/types.h>
6375#include <time.h>
6376
6377_ACEOF
6378if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6379 $EGREP "gmtime_r" >/dev/null 2>&1; then :
6380
6381 tmp_gmtime_r="proto_needs_reentrant"
6382 tmp_need_reentrant="yes"
6383
6384fi
6385rm -f conftest*
6386
6387
6388fi
6389rm -f conftest*
6390
6391 fi
6392
6393 fi
6394 if test "$tmp_need_reentrant" = "no"; then
6395
6396 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6397/* end confdefs.h. */
6398
6399
6400#define localtime_r innocuous_localtime_r
6401#ifdef __STDC__
6402# include <limits.h>
6403#else
6404# include <assert.h>
6405#endif
6406#undef localtime_r
6407#ifdef __cplusplus
6408extern "C"
6409#endif
6410char localtime_r ();
6411#if defined __stub_localtime_r || defined __stub___localtime_r
6412choke me
6413#endif
6414
6415int main (void)
6416{
6417return localtime_r ();
6418 ;
6419 return 0;
6420}
6421
6422_ACEOF
6423if ac_fn_c_try_link "$LINENO"; then :
6424
6425 tmp_localtime_r="yes"
6426
6427else
6428
6429 tmp_localtime_r="no"
6430
6431fi
6432rm -f core conftest.err conftest.$ac_objext \
6433 conftest$ac_exeext conftest.$ac_ext
6434 if test "$tmp_localtime_r" = "yes"; then
6435 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6436/* end confdefs.h. */
6437
6438#include <sys/types.h>
6439#include <time.h>
6440
6441_ACEOF
6442if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6443 $EGREP "localtime_r" >/dev/null 2>&1; then :
6444
6445 tmp_localtime_r="proto_declared"
6446
6447else
6448
6449 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6450/* end confdefs.h. */
6451
6452#define _REENTRANT
6453#include <sys/types.h>
6454#include <time.h>
6455
6456_ACEOF
6457if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6458 $EGREP "localtime_r" >/dev/null 2>&1; then :
6459
6460 tmp_localtime_r="proto_needs_reentrant"
6461 tmp_need_reentrant="yes"
6462
6463fi
6464rm -f conftest*
6465
6466
6467fi
6468rm -f conftest*
6469
6470 fi
6471
6472 fi
6473 if test "$tmp_need_reentrant" = "no"; then
6474
6475 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6476/* end confdefs.h. */
6477
6478
6479#define strerror_r innocuous_strerror_r
6480#ifdef __STDC__
6481# include <limits.h>
6482#else
6483# include <assert.h>
6484#endif
6485#undef strerror_r
6486#ifdef __cplusplus
6487extern "C"
6488#endif
6489char strerror_r ();
6490#if defined __stub_strerror_r || defined __stub___strerror_r
6491choke me
6492#endif
6493
6494int main (void)
6495{
6496return strerror_r ();
6497 ;
6498 return 0;
6499}
6500
6501_ACEOF
6502if ac_fn_c_try_link "$LINENO"; then :
6503
6504 tmp_strerror_r="yes"
6505
6506else
6507
6508 tmp_strerror_r="no"
6509
6510fi
6511rm -f core conftest.err conftest.$ac_objext \
6512 conftest$ac_exeext conftest.$ac_ext
6513 if test "$tmp_strerror_r" = "yes"; then
6514 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6515/* end confdefs.h. */
6516
6517#include <sys/types.h>
6518#include <string.h>
6519
6520_ACEOF
6521if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6522 $EGREP "strerror_r" >/dev/null 2>&1; then :
6523
6524 tmp_strerror_r="proto_declared"
6525
6526else
6527
6528 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6529/* end confdefs.h. */
6530
6531#define _REENTRANT
6532#include <sys/types.h>
6533#include <string.h>
6534
6535_ACEOF
6536if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6537 $EGREP "strerror_r" >/dev/null 2>&1; then :
6538
6539 tmp_strerror_r="proto_needs_reentrant"
6540 tmp_need_reentrant="yes"
6541
6542fi
6543rm -f conftest*
6544
6545
6546fi
6547rm -f conftest*
6548
6549 fi
6550
6551 fi
6552 if test "$tmp_need_reentrant" = "no"; then
6553
6554 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6555/* end confdefs.h. */
6556
6557
6558#define strtok_r innocuous_strtok_r
6559#ifdef __STDC__
6560# include <limits.h>
6561#else
6562# include <assert.h>
6563#endif
6564#undef strtok_r
6565#ifdef __cplusplus
6566extern "C"
6567#endif
6568char strtok_r ();
6569#if defined __stub_strtok_r || defined __stub___strtok_r
6570choke me
6571#endif
6572
6573int main (void)
6574{
6575return strtok_r ();
6576 ;
6577 return 0;
6578}
6579
6580_ACEOF
6581if ac_fn_c_try_link "$LINENO"; then :
6582
6583 tmp_strtok_r="yes"
6584
6585else
6586
6587 tmp_strtok_r="no"
6588
6589fi
6590rm -f core conftest.err conftest.$ac_objext \
6591 conftest$ac_exeext conftest.$ac_ext
6592 if test "$tmp_strtok_r" = "yes"; then
6593 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6594/* end confdefs.h. */
6595
6596#include <sys/types.h>
6597#include <string.h>
6598
6599_ACEOF
6600if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6601 $EGREP "strtok_r" >/dev/null 2>&1; then :
6602
6603 tmp_strtok_r="proto_declared"
6604
6605else
6606
6607 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6608/* end confdefs.h. */
6609
6610#define _REENTRANT
6611#include <sys/types.h>
6612#include <string.h>
6613
6614_ACEOF
6615if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6616 $EGREP "strtok_r" >/dev/null 2>&1; then :
6617
6618 tmp_strtok_r="proto_needs_reentrant"
6619 tmp_need_reentrant="yes"
6620
6621fi
6622rm -f conftest*
6623
6624
6625fi
6626rm -f conftest*
6627
6628 fi
6629
6630 fi
6631 if test "$tmp_need_reentrant" = "no"; then
6632
6633 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6634/* end confdefs.h. */
6635
6636
6637#define inet_ntoa_r innocuous_inet_ntoa_r
6638#ifdef __STDC__
6639# include <limits.h>
6640#else
6641# include <assert.h>
6642#endif
6643#undef inet_ntoa_r
6644#ifdef __cplusplus
6645extern "C"
6646#endif
6647char inet_ntoa_r ();
6648#if defined __stub_inet_ntoa_r || defined __stub___inet_ntoa_r
6649choke me
6650#endif
6651
6652int main (void)
6653{
6654return inet_ntoa_r ();
6655 ;
6656 return 0;
6657}
6658
6659_ACEOF
6660if ac_fn_c_try_link "$LINENO"; then :
6661
6662 tmp_inet_ntoa_r="yes"
6663
6664else
6665
6666 tmp_inet_ntoa_r="no"
6667
6668fi
6669rm -f core conftest.err conftest.$ac_objext \
6670 conftest$ac_exeext conftest.$ac_ext
6671 if test "$tmp_inet_ntoa_r" = "yes"; then
6672 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6673/* end confdefs.h. */
6674
6675#include <sys/types.h>
6676#include <sys/socket.h>
6677#include <netinet/in.h>
6678#include <arpa/inet.h>
6679
6680_ACEOF
6681if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6682 $EGREP "inet_ntoa_r" >/dev/null 2>&1; then :
6683
6684 tmp_inet_ntoa_r="proto_declared"
6685
6686else
6687
6688 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6689/* end confdefs.h. */
6690
6691#define _REENTRANT
6692#include <sys/types.h>
6693#include <sys/socket.h>
6694#include <netinet/in.h>
6695#include <arpa/inet.h>
6696
6697_ACEOF
6698if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6699 $EGREP "inet_ntoa_r" >/dev/null 2>&1; then :
6700
6701 tmp_inet_ntoa_r="proto_needs_reentrant"
6702 tmp_need_reentrant="yes"
6703
6704fi
6705rm -f conftest*
6706
6707
6708fi
6709rm -f conftest*
6710
6711 fi
6712
6713 fi
6714 if test "$tmp_need_reentrant" = "no"; then
6715
6716 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6717/* end confdefs.h. */
6718
6719
6720#define gethostbyaddr_r innocuous_gethostbyaddr_r
6721#ifdef __STDC__
6722# include <limits.h>
6723#else
6724# include <assert.h>
6725#endif
6726#undef gethostbyaddr_r
6727#ifdef __cplusplus
6728extern "C"
6729#endif
6730char gethostbyaddr_r ();
6731#if defined __stub_gethostbyaddr_r || defined __stub___gethostbyaddr_r
6732choke me
6733#endif
6734
6735int main (void)
6736{
6737return gethostbyaddr_r ();
6738 ;
6739 return 0;
6740}
6741
6742_ACEOF
6743if ac_fn_c_try_link "$LINENO"; then :
6744
6745 tmp_gethostbyaddr_r="yes"
6746
6747else
6748
6749 tmp_gethostbyaddr_r="no"
6750
6751fi
6752rm -f core conftest.err conftest.$ac_objext \
6753 conftest$ac_exeext conftest.$ac_ext
6754 if test "$tmp_gethostbyaddr_r" = "yes"; then
6755 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6756/* end confdefs.h. */
6757
6758#include <sys/types.h>
6759#include <netdb.h>
6760
6761_ACEOF
6762if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6763 $EGREP "gethostbyaddr_r" >/dev/null 2>&1; then :
6764
6765 tmp_gethostbyaddr_r="proto_declared"
6766
6767else
6768
6769 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6770/* end confdefs.h. */
6771
6772#define _REENTRANT
6773#include <sys/types.h>
6774#include <netdb.h>
6775
6776_ACEOF
6777if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6778 $EGREP "gethostbyaddr_r" >/dev/null 2>&1; then :
6779
6780 tmp_gethostbyaddr_r="proto_needs_reentrant"
6781 tmp_need_reentrant="yes"
6782
6783fi
6784rm -f conftest*
6785
6786
6787fi
6788rm -f conftest*
6789
6790 fi
6791
6792 fi
6793 if test "$tmp_need_reentrant" = "no"; then
6794
6795 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6796/* end confdefs.h. */
6797
6798
6799#define gethostbyname_r innocuous_gethostbyname_r
6800#ifdef __STDC__
6801# include <limits.h>
6802#else
6803# include <assert.h>
6804#endif
6805#undef gethostbyname_r
6806#ifdef __cplusplus
6807extern "C"
6808#endif
6809char gethostbyname_r ();
6810#if defined __stub_gethostbyname_r || defined __stub___gethostbyname_r
6811choke me
6812#endif
6813
6814int main (void)
6815{
6816return gethostbyname_r ();
6817 ;
6818 return 0;
6819}
6820
6821_ACEOF
6822if ac_fn_c_try_link "$LINENO"; then :
6823
6824 tmp_gethostbyname_r="yes"
6825
6826else
6827
6828 tmp_gethostbyname_r="no"
6829
6830fi
6831rm -f core conftest.err conftest.$ac_objext \
6832 conftest$ac_exeext conftest.$ac_ext
6833 if test "$tmp_gethostbyname_r" = "yes"; then
6834 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6835/* end confdefs.h. */
6836
6837#include <sys/types.h>
6838#include <netdb.h>
6839
6840_ACEOF
6841if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6842 $EGREP "gethostbyname_r" >/dev/null 2>&1; then :
6843
6844 tmp_gethostbyname_r="proto_declared"
6845
6846else
6847
6848 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6849/* end confdefs.h. */
6850
6851#define _REENTRANT
6852#include <sys/types.h>
6853#include <netdb.h>
6854
6855_ACEOF
6856if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6857 $EGREP "gethostbyname_r" >/dev/null 2>&1; then :
6858
6859 tmp_gethostbyname_r="proto_needs_reentrant"
6860 tmp_need_reentrant="yes"
6861
6862fi
6863rm -f conftest*
6864
6865
6866fi
6867rm -f conftest*
6868
6869 fi
6870
6871 fi
6872 if test "$tmp_need_reentrant" = "no"; then
6873
6874 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6875/* end confdefs.h. */
6876
6877
6878#define getprotobyname_r innocuous_getprotobyname_r
6879#ifdef __STDC__
6880# include <limits.h>
6881#else
6882# include <assert.h>
6883#endif
6884#undef getprotobyname_r
6885#ifdef __cplusplus
6886extern "C"
6887#endif
6888char getprotobyname_r ();
6889#if defined __stub_getprotobyname_r || defined __stub___getprotobyname_r
6890choke me
6891#endif
6892
6893int main (void)
6894{
6895return getprotobyname_r ();
6896 ;
6897 return 0;
6898}
6899
6900_ACEOF
6901if ac_fn_c_try_link "$LINENO"; then :
6902
6903 tmp_getprotobyname_r="yes"
6904
6905else
6906
6907 tmp_getprotobyname_r="no"
6908
6909fi
6910rm -f core conftest.err conftest.$ac_objext \
6911 conftest$ac_exeext conftest.$ac_ext
6912 if test "$tmp_getprotobyname_r" = "yes"; then
6913 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6914/* end confdefs.h. */
6915
6916#include <sys/types.h>
6917#include <netdb.h>
6918
6919_ACEOF
6920if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6921 $EGREP "getprotobyname_r" >/dev/null 2>&1; then :
6922
6923 tmp_getprotobyname_r="proto_declared"
6924
6925else
6926
6927 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6928/* end confdefs.h. */
6929
6930#define _REENTRANT
6931#include <sys/types.h>
6932#include <netdb.h>
6933
6934_ACEOF
6935if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6936 $EGREP "getprotobyname_r" >/dev/null 2>&1; then :
6937
6938 tmp_getprotobyname_r="proto_needs_reentrant"
6939 tmp_need_reentrant="yes"
6940
6941fi
6942rm -f conftest*
6943
6944
6945fi
6946rm -f conftest*
6947
6948 fi
6949
6950 fi
6951 if test "$tmp_need_reentrant" = "no"; then
6952
6953 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6954/* end confdefs.h. */
6955
6956
6957#define getservbyport_r innocuous_getservbyport_r
6958#ifdef __STDC__
6959# include <limits.h>
6960#else
6961# include <assert.h>
6962#endif
6963#undef getservbyport_r
6964#ifdef __cplusplus
6965extern "C"
6966#endif
6967char getservbyport_r ();
6968#if defined __stub_getservbyport_r || defined __stub___getservbyport_r
6969choke me
6970#endif
6971
6972int main (void)
6973{
6974return getservbyport_r ();
6975 ;
6976 return 0;
6977}
6978
6979_ACEOF
6980if ac_fn_c_try_link "$LINENO"; then :
6981
6982 tmp_getservbyport_r="yes"
6983
6984else
6985
6986 tmp_getservbyport_r="no"
6987
6988fi
6989rm -f core conftest.err conftest.$ac_objext \
6990 conftest$ac_exeext conftest.$ac_ext
6991 if test "$tmp_getservbyport_r" = "yes"; then
6992 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6993/* end confdefs.h. */
6994
6995#include <sys/types.h>
6996#include <netdb.h>
6997
6998_ACEOF
6999if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7000 $EGREP "getservbyport_r" >/dev/null 2>&1; then :
7001
7002 tmp_getservbyport_r="proto_declared"
7003
7004else
7005
7006 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7007/* end confdefs.h. */
7008
7009#define _REENTRANT
7010#include <sys/types.h>
7011#include <netdb.h>
7012
7013_ACEOF
7014if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7015 $EGREP "getservbyport_r" >/dev/null 2>&1; then :
7016
7017 tmp_getservbyport_r="proto_needs_reentrant"
7018 tmp_need_reentrant="yes"
7019
7020fi
7021rm -f conftest*
7022
7023
7024fi
7025rm -f conftest*
7026
7027 fi
7028
7029 fi
7030
7031 fi
7032 if test "$tmp_need_reentrant" = "yes"; then
7033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7034$as_echo "yes" >&6; }
7035 else
7036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7037$as_echo "no" >&6; }
7038 fi
7039 fi
7040 #
7041 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if _REENTRANT is onwards defined" >&5
7042$as_echo_n "checking if _REENTRANT is onwards defined... " >&6; }
7043 if test "$tmp_reentrant_initially_defined" = "yes" ||
7044 test "$tmp_need_reentrant" = "yes"; then
7045
7046
7047$as_echo "#define NEED_REENTRANT 1" >>confdefs.h
7048
7049cat >>confdefs.h <<_EOF
7050#ifndef _REENTRANT
7051# define _REENTRANT
7052#endif
7053_EOF
7054
7055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7056$as_echo "yes" >&6; }
7057 else
7058 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7059$as_echo "no" >&6; }
7060 fi
7061 #
7062
7063
7064# Check whether --enable-largefile was given.
7065if test "${enable_largefile+set}" = set; then :
7066 enableval=$enable_largefile;
7067fi
7068
7069if test "$enable_largefile" != no; then
7070
7071 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
7072$as_echo_n "checking for special C compiler options needed for large files... " >&6; }
7073if ${ac_cv_sys_largefile_CC+:} false; then :
7074 $as_echo_n "(cached) " >&6
7075else
7076 ac_cv_sys_largefile_CC=no
7077 if test "$GCC" != yes; then
7078 ac_save_CC=$CC
7079 while :; do
7080 # IRIX 6.2 and later do not support large files by default,
7081 # so use the C compiler's -n32 option if that helps.
7082 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7083/* end confdefs.h. */
7084#include <sys/types.h>
7085 /* Check that off_t can represent 2**63 - 1 correctly.
7086 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7087 since some C++ compilers masquerading as C compilers
7088 incorrectly reject 9223372036854775807. */
7089#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
7090 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7091 && LARGE_OFF_T % 2147483647 == 1)
7092 ? 1 : -1];
7093int main (void)
7094{
7095
7096 ;
7097 return 0;
7098}
7099_ACEOF
7100 if ac_fn_c_try_compile "$LINENO"; then :
7101 break
7102fi
7103rm -f core conftest.err conftest.$ac_objext
7104 CC="$CC -n32"
7105 if ac_fn_c_try_compile "$LINENO"; then :
7106 ac_cv_sys_largefile_CC=' -n32'; break
7107fi
7108rm -f core conftest.err conftest.$ac_objext
7109 break
7110 done
7111 CC=$ac_save_CC
7112 rm -f conftest.$ac_ext
7113 fi
7114fi
7115{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
7116$as_echo "$ac_cv_sys_largefile_CC" >&6; }
7117 if test "$ac_cv_sys_largefile_CC" != no; then
7118 CC=$CC$ac_cv_sys_largefile_CC
7119 fi
7120
7121 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
7122$as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
7123if ${ac_cv_sys_file_offset_bits+:} false; then :
7124 $as_echo_n "(cached) " >&6
7125else
7126 while :; do
7127 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7128/* end confdefs.h. */
7129#include <sys/types.h>
7130 /* Check that off_t can represent 2**63 - 1 correctly.
7131 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7132 since some C++ compilers masquerading as C compilers
7133 incorrectly reject 9223372036854775807. */
7134#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
7135 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7136 && LARGE_OFF_T % 2147483647 == 1)
7137 ? 1 : -1];
7138int main (void)
7139{
7140
7141 ;
7142 return 0;
7143}
7144_ACEOF
7145if ac_fn_c_try_compile "$LINENO"; then :
7146 ac_cv_sys_file_offset_bits=no; break
7147fi
7148rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7149 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7150/* end confdefs.h. */
7151#define _FILE_OFFSET_BITS 64
7152#include <sys/types.h>
7153 /* Check that off_t can represent 2**63 - 1 correctly.
7154 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7155 since some C++ compilers masquerading as C compilers
7156 incorrectly reject 9223372036854775807. */
7157#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
7158 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7159 && LARGE_OFF_T % 2147483647 == 1)
7160 ? 1 : -1];
7161int main (void)
7162{
7163
7164 ;
7165 return 0;
7166}
7167_ACEOF
7168if ac_fn_c_try_compile "$LINENO"; then :
7169 ac_cv_sys_file_offset_bits=64; break
7170fi
7171rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7172 ac_cv_sys_file_offset_bits=unknown
7173 break
7174done
7175fi
7176{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
7177$as_echo "$ac_cv_sys_file_offset_bits" >&6; }
7178case $ac_cv_sys_file_offset_bits in #(
7179 no | unknown) ;;
7180 *)
7181cat >>confdefs.h <<_ACEOF
7182#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
7183_ACEOF
7184;;
7185esac
7186rm -rf conftest*
7187 if test $ac_cv_sys_file_offset_bits = unknown; then
7188 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
7189$as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
7190if ${ac_cv_sys_large_files+:} false; then :
7191 $as_echo_n "(cached) " >&6
7192else
7193 while :; do
7194 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7195/* end confdefs.h. */
7196#include <sys/types.h>
7197 /* Check that off_t can represent 2**63 - 1 correctly.
7198 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7199 since some C++ compilers masquerading as C compilers
7200 incorrectly reject 9223372036854775807. */
7201#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
7202 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7203 && LARGE_OFF_T % 2147483647 == 1)
7204 ? 1 : -1];
7205int main (void)
7206{
7207
7208 ;
7209 return 0;
7210}
7211_ACEOF
7212if ac_fn_c_try_compile "$LINENO"; then :
7213 ac_cv_sys_large_files=no; break
7214fi
7215rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7216 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7217/* end confdefs.h. */
7218#define _LARGE_FILES 1
7219#include <sys/types.h>
7220 /* Check that off_t can represent 2**63 - 1 correctly.
7221 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7222 since some C++ compilers masquerading as C compilers
7223 incorrectly reject 9223372036854775807. */
7224#define LARGE_OFF_T ((((off_t) 1 << 31) << 31) - 1 + (((off_t) 1 << 31) << 31))
7225 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7226 && LARGE_OFF_T % 2147483647 == 1)
7227 ? 1 : -1];
7228int main (void)
7229{
7230
7231 ;
7232 return 0;
7233}
7234_ACEOF
7235if ac_fn_c_try_compile "$LINENO"; then :
7236 ac_cv_sys_large_files=1; break
7237fi
7238rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7239 ac_cv_sys_large_files=unknown
7240 break
7241done
7242fi
7243{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
7244$as_echo "$ac_cv_sys_large_files" >&6; }
7245case $ac_cv_sys_large_files in #(
7246 no | unknown) ;;
7247 *)
7248cat >>confdefs.h <<_ACEOF
7249#define _LARGE_FILES $ac_cv_sys_large_files
7250_ACEOF
7251;;
7252esac
7253rm -rf conftest*
7254 fi
7255
7256
7257fi
7258
7259
7260case `pwd` in
7261 *\ * | *\ *)
7262 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5
7263$as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;;
7264esac
7265
7266
7267
7268macro_version='2.4.6'
7269macro_revision='2.4.6'
7270
7271
7272
7273
7274
7275
7276
7277
7278
7279
7280
7281
7282
7283ltmain=$ac_aux_dir/ltmain.sh
7284
7285# Backslashify metacharacters that are still active within
7286# double-quoted strings.
7287sed_quote_subst='s/\(["`$\\]\)/\\\1/g'
7288
7289# Same as above, but do not quote variable references.
7290double_quote_subst='s/\(["`\\]\)/\\\1/g'
7291
7292# Sed substitution to delay expansion of an escaped shell variable in a
7293# double_quote_subst'ed string.
7294delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
7295
7296# Sed substitution to delay expansion of an escaped single quote.
7297delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
7298
7299# Sed substitution to avoid accidental globbing in evaled expressions
7300no_glob_subst='s/\*/\\\*/g'
7301
7302ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
7303ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
7304ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
7305
7306{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
7307$as_echo_n "checking how to print strings... " >&6; }
7308# Test print first, because it will be a builtin if present.
7309if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
7310 test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
7311 ECHO='print -r --'
7312elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
7313 ECHO='printf %s\n'
7314else
7315 # Use this function as a fallback that always works.
7316 func_fallback_echo ()
7317 {
7318 eval 'cat <<_LTECHO_EOF
7319$1
7320_LTECHO_EOF'
7321 }
7322 ECHO='func_fallback_echo'
7323fi
7324
7325# func_echo_all arg...
7326# Invoke $ECHO with all args, space-separated.
7327func_echo_all ()
7328{
7329 $ECHO ""
7330}
7331
7332case $ECHO in
7333 printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5
7334$as_echo "printf" >&6; } ;;
7335 print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5
7336$as_echo "print -r" >&6; } ;;
7337 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5
7338$as_echo "cat" >&6; } ;;
7339esac
7340
7341
7342
7343
7344
7345
7346
7347
7348
7349
7350
7351
7352
7353
7354{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
7355$as_echo_n "checking for a sed that does not truncate output... " >&6; }
7356if ${ac_cv_path_SED+:} false; then :
7357 $as_echo_n "(cached) " >&6
7358else
7359 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
7360 for ac_i in 1 2 3 4 5 6 7; do
7361 ac_script="$ac_script$as_nl$ac_script"
7362 done
7363 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
7364 { ac_script=; unset ac_script;}
7365 if test -z "$SED"; then
7366 ac_path_SED_found=false
7367 # Loop through the user's path and test for each of PROGNAME-LIST
7368 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7369for as_dir in $PATH
7370do
7371 IFS=$as_save_IFS
7372 test -z "$as_dir" && as_dir=.
7373 for ac_prog in sed gsed; do
7374 for ac_exec_ext in '' $ac_executable_extensions; do
7375 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
7376 as_fn_executable_p "$ac_path_SED" || continue
7377# Check for GNU ac_path_SED and select it if it is found.
7378 # Check for GNU $ac_path_SED
7379case `"$ac_path_SED" --version 2>&1` in
7380*GNU*)
7381 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
7382*)
7383 ac_count=0
7384 $as_echo_n 0123456789 >"conftest.in"
7385 while :
7386 do
7387 cat "conftest.in" "conftest.in" >"conftest.tmp"
7388 mv "conftest.tmp" "conftest.in"
7389 cp "conftest.in" "conftest.nl"
7390 $as_echo '' >> "conftest.nl"
7391 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
7392 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
7393 as_fn_arith $ac_count + 1 && ac_count=$as_val
7394 if test $ac_count -gt ${ac_path_SED_max-0}; then
7395 # Best one so far, save it but keep looking for a better one
7396 ac_cv_path_SED="$ac_path_SED"
7397 ac_path_SED_max=$ac_count
7398 fi
7399 # 10*(2^10) chars as input seems more than enough
7400 test $ac_count -gt 10 && break
7401 done
7402 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
7403esac
7404
7405 $ac_path_SED_found && break 3
7406 done
7407 done
7408 done
7409IFS=$as_save_IFS
7410 if test -z "$ac_cv_path_SED"; then
7411 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
7412 fi
7413else
7414 ac_cv_path_SED=$SED
7415fi
7416
7417fi
7418{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
7419$as_echo "$ac_cv_path_SED" >&6; }
7420 SED="$ac_cv_path_SED"
7421 rm -f conftest.sed
7422
7423test -z "$SED" && SED=sed
7424Xsed="$SED -e 1s/^X//"
7425
7426
7427
7428
7429
7430
7431
7432
7433
7434
7435
7436{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
7437$as_echo_n "checking for fgrep... " >&6; }
7438if ${ac_cv_path_FGREP+:} false; then :
7439 $as_echo_n "(cached) " >&6
7440else
7441 if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
7442 then ac_cv_path_FGREP="$GREP -F"
7443 else
7444 if test -z "$FGREP"; then
7445 ac_path_FGREP_found=false
7446 # Loop through the user's path and test for each of PROGNAME-LIST
7447 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7448for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
7449do
7450 IFS=$as_save_IFS
7451 test -z "$as_dir" && as_dir=.
7452 for ac_prog in fgrep; do
7453 for ac_exec_ext in '' $ac_executable_extensions; do
7454 ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
7455 as_fn_executable_p "$ac_path_FGREP" || continue
7456# Check for GNU ac_path_FGREP and select it if it is found.
7457 # Check for GNU $ac_path_FGREP
7458case `"$ac_path_FGREP" --version 2>&1` in
7459*GNU*)
7460 ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
7461*)
7462 ac_count=0
7463 $as_echo_n 0123456789 >"conftest.in"
7464 while :
7465 do
7466 cat "conftest.in" "conftest.in" >"conftest.tmp"
7467 mv "conftest.tmp" "conftest.in"
7468 cp "conftest.in" "conftest.nl"
7469 $as_echo 'FGREP' >> "conftest.nl"
7470 "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
7471 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
7472 as_fn_arith $ac_count + 1 && ac_count=$as_val
7473 if test $ac_count -gt ${ac_path_FGREP_max-0}; then
7474 # Best one so far, save it but keep looking for a better one
7475 ac_cv_path_FGREP="$ac_path_FGREP"
7476 ac_path_FGREP_max=$ac_count
7477 fi
7478 # 10*(2^10) chars as input seems more than enough
7479 test $ac_count -gt 10 && break
7480 done
7481 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
7482esac
7483
7484 $ac_path_FGREP_found && break 3
7485 done
7486 done
7487 done
7488IFS=$as_save_IFS
7489 if test -z "$ac_cv_path_FGREP"; then
7490 as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
7491 fi
7492else
7493 ac_cv_path_FGREP=$FGREP
7494fi
7495
7496 fi
7497fi
7498{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
7499$as_echo "$ac_cv_path_FGREP" >&6; }
7500 FGREP="$ac_cv_path_FGREP"
7501
7502
7503test -z "$GREP" && GREP=grep
7504
7505
7506
7507
7508
7509
7510
7511
7512
7513
7514
7515
7516
7517
7518
7519
7520
7521
7522
7523# Check whether --with-gnu-ld was given.
7524if test "${with_gnu_ld+set}" = set; then :
7525 withval=$with_gnu_ld; test no = "$withval" || with_gnu_ld=yes
7526else
7527 with_gnu_ld=no
7528fi
7529
7530ac_prog=ld
7531if test yes = "$GCC"; then
7532 # Check if gcc -print-prog-name=ld gives a path.
7533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
7534$as_echo_n "checking for ld used by $CC... " >&6; }
7535 case $host in
7536 *-*-mingw*)
7537 # gcc leaves a trailing carriage return, which upsets mingw
7538 ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
7539 *)
7540 ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
7541 esac
7542 case $ac_prog in
7543 # Accept absolute paths.
7544 [\\/]* | ?:[\\/]*)
7545 re_direlt='/[^/][^/]*/\.\./'
7546 # Canonicalize the pathname of ld
7547 ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
7548 while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
7549 ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
7550 done
7551 test -z "$LD" && LD=$ac_prog
7552 ;;
7553 "")
7554 # If it fails, then pretend we aren't using GCC.
7555 ac_prog=ld
7556 ;;
7557 *)
7558 # If it is relative, then search for the first ld in PATH.
7559 with_gnu_ld=unknown
7560 ;;
7561 esac
7562elif test yes = "$with_gnu_ld"; then
7563 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
7564$as_echo_n "checking for GNU ld... " >&6; }
7565else
7566 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
7567$as_echo_n "checking for non-GNU ld... " >&6; }
7568fi
7569if ${lt_cv_path_LD+:} false; then :
7570 $as_echo_n "(cached) " >&6
7571else
7572 if test -z "$LD"; then
7573 lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
7574 for ac_dir in $PATH; do
7575 IFS=$lt_save_ifs
7576 test -z "$ac_dir" && ac_dir=.
7577 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
7578 lt_cv_path_LD=$ac_dir/$ac_prog
7579 # Check to see if the program is GNU ld. I'd rather use --version,
7580 # but apparently some variants of GNU ld only accept -v.
7581 # Break only if it was the GNU/non-GNU ld that we prefer.
7582 case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
7583 *GNU* | *'with BFD'*)
7584 test no != "$with_gnu_ld" && break
7585 ;;
7586 *)
7587 test yes != "$with_gnu_ld" && break
7588 ;;
7589 esac
7590 fi
7591 done
7592 IFS=$lt_save_ifs
7593else
7594 lt_cv_path_LD=$LD # Let the user override the test with a path.
7595fi
7596fi
7597
7598LD=$lt_cv_path_LD
7599if test -n "$LD"; then
7600 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
7601$as_echo "$LD" >&6; }
7602else
7603 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7604$as_echo "no" >&6; }
7605fi
7606test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
7607{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
7608$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
7609if ${lt_cv_prog_gnu_ld+:} false; then :
7610 $as_echo_n "(cached) " >&6
7611else
7612 # I'd rather use --version here, but apparently some GNU lds only accept -v.
7613case `$LD -v 2>&1 </dev/null` in
7614*GNU* | *'with BFD'*)
7615 lt_cv_prog_gnu_ld=yes
7616 ;;
7617*)
7618 lt_cv_prog_gnu_ld=no
7619 ;;
7620esac
7621fi
7622{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
7623$as_echo "$lt_cv_prog_gnu_ld" >&6; }
7624with_gnu_ld=$lt_cv_prog_gnu_ld
7625
7626
7627
7628
7629
7630
7631
7632
7633
7634{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5
7635$as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; }
7636if ${lt_cv_path_NM+:} false; then :
7637 $as_echo_n "(cached) " >&6
7638else
7639 if test -n "$NM"; then
7640 # Let the user override the test.
7641 lt_cv_path_NM=$NM
7642else
7643 lt_nm_to_check=${ac_tool_prefix}nm
7644 if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
7645 lt_nm_to_check="$lt_nm_to_check nm"
7646 fi
7647 for lt_tmp_nm in $lt_nm_to_check; do
7648 lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
7649 for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
7650 IFS=$lt_save_ifs
7651 test -z "$ac_dir" && ac_dir=.
7652 tmp_nm=$ac_dir/$lt_tmp_nm
7653 if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then
7654 # Check to see if the nm accepts a BSD-compat flag.
7655 # Adding the 'sed 1q' prevents false positives on HP-UX, which says:
7656 # nm: unknown option "B" ignored
7657 # Tru64's nm complains that /dev/null is an invalid object file
7658 # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty
7659 case $build_os in
7660 mingw*) lt_bad_file=conftest.nm/nofile ;;
7661 *) lt_bad_file=/dev/null ;;
7662 esac
7663 case `"$tmp_nm" -B $lt_bad_file 2>&1 | sed '1q'` in
7664 *$lt_bad_file* | *'Invalid file or object type'*)
7665 lt_cv_path_NM="$tmp_nm -B"
7666 break 2
7667 ;;
7668 *)
7669 case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
7670 */dev/null*)
7671 lt_cv_path_NM="$tmp_nm -p"
7672 break 2
7673 ;;
7674 *)
7675 lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
7676 continue # so that we can try to find one that supports BSD flags
7677 ;;
7678 esac
7679 ;;
7680 esac
7681 fi
7682 done
7683 IFS=$lt_save_ifs
7684 done
7685 : ${lt_cv_path_NM=no}
7686fi
7687fi
7688{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5
7689$as_echo "$lt_cv_path_NM" >&6; }
7690if test no != "$lt_cv_path_NM"; then
7691 NM=$lt_cv_path_NM
7692else
7693 # Didn't find any BSD compatible name lister, look for dumpbin.
7694 if test -n "$DUMPBIN"; then :
7695 # Let the user override the test.
7696 else
7697 if test -n "$ac_tool_prefix"; then
7698 for ac_prog in dumpbin "link -dump"
7699 do
7700 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
7701set dummy $ac_tool_prefix$ac_prog; ac_word=$2
7702{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7703$as_echo_n "checking for $ac_word... " >&6; }
7704if ${ac_cv_prog_DUMPBIN+:} false; then :
7705 $as_echo_n "(cached) " >&6
7706else
7707 if test -n "$DUMPBIN"; then
7708 ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test.
7709else
7710as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7711for as_dir in $PATH
7712do
7713 IFS=$as_save_IFS
7714 test -z "$as_dir" && as_dir=.
7715 for ac_exec_ext in '' $ac_executable_extensions; do
7716 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7717 ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog"
7718 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7719 break 2
7720 fi
7721done
7722 done
7723IFS=$as_save_IFS
7724
7725fi
7726fi
7727DUMPBIN=$ac_cv_prog_DUMPBIN
7728if test -n "$DUMPBIN"; then
7729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5
7730$as_echo "$DUMPBIN" >&6; }
7731else
7732 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7733$as_echo "no" >&6; }
7734fi
7735
7736
7737 test -n "$DUMPBIN" && break
7738 done
7739fi
7740if test -z "$DUMPBIN"; then
7741 ac_ct_DUMPBIN=$DUMPBIN
7742 for ac_prog in dumpbin "link -dump"
7743do
7744 # Extract the first word of "$ac_prog", so it can be a program name with args.
7745set dummy $ac_prog; ac_word=$2
7746{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7747$as_echo_n "checking for $ac_word... " >&6; }
7748if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then :
7749 $as_echo_n "(cached) " >&6
7750else
7751 if test -n "$ac_ct_DUMPBIN"; then
7752 ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test.
7753else
7754as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7755for as_dir in $PATH
7756do
7757 IFS=$as_save_IFS
7758 test -z "$as_dir" && as_dir=.
7759 for ac_exec_ext in '' $ac_executable_extensions; do
7760 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
7761 ac_cv_prog_ac_ct_DUMPBIN="$ac_prog"
7762 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7763 break 2
7764 fi
7765done
7766 done
7767IFS=$as_save_IFS
7768
7769fi
7770fi
7771ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN
7772if test -n "$ac_ct_DUMPBIN"; then
7773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5
7774$as_echo "$ac_ct_DUMPBIN" >&6; }
7775else
7776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7777$as_echo "no" >&6; }
7778fi
7779
7780
7781 test -n "$ac_ct_DUMPBIN" && break
7782done
7783
7784 if test "x$ac_ct_DUMPBIN" = x; then
7785 DUMPBIN=":"
7786 else
7787 case $cross_compiling:$ac_tool_warned in
7788yes:)
7789{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7790$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7791ac_tool_warned=yes ;;
7792esac
7793 DUMPBIN=$ac_ct_DUMPBIN
7794 fi
7795fi
7796
7797 case `$DUMPBIN -symbols -headers /dev/null 2>&1 | sed '1q'` in
7798 *COFF*)
7799 DUMPBIN="$DUMPBIN -symbols -headers"
7800 ;;
7801 *)
7802 DUMPBIN=:
7803 ;;
7804 esac
7805 fi
7806
7807 if test : != "$DUMPBIN"; then
7808 NM=$DUMPBIN
7809 fi
7810fi
7811test -z "$NM" && NM=nm
7812
7813
7814
7815
7816
7817
7818{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5
7819$as_echo_n "checking the name lister ($NM) interface... " >&6; }
7820if ${lt_cv_nm_interface+:} false; then :
7821 $as_echo_n "(cached) " >&6
7822else
7823 lt_cv_nm_interface="BSD nm"
7824 echo "int some_variable = 0;" > conftest.$ac_ext
7825 (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5)
7826 (eval "$ac_compile" 2>conftest.err)
7827 cat conftest.err >&5
7828 (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
7829 (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
7830 cat conftest.err >&5
7831 (eval echo "\"\$as_me:$LINENO: output\"" >&5)
7832 cat conftest.out >&5
7833 if $GREP 'External.*some_variable' conftest.out > /dev/null; then
7834 lt_cv_nm_interface="MS dumpbin"
7835 fi
7836 rm -f conftest*
7837fi
7838{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5
7839$as_echo "$lt_cv_nm_interface" >&6; }
7840
7841{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
7842$as_echo_n "checking whether ln -s works... " >&6; }
7843LN_S=$as_ln_s
7844if test "$LN_S" = "ln -s"; then
7845 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7846$as_echo "yes" >&6; }
7847else
7848 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
7849$as_echo "no, using $LN_S" >&6; }
7850fi
7851
7852# find the maximum length of command line arguments
7853{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5
7854$as_echo_n "checking the maximum length of command line arguments... " >&6; }
7855if ${lt_cv_sys_max_cmd_len+:} false; then :
7856 $as_echo_n "(cached) " >&6
7857else
7858 i=0
7859 teststring=ABCD
7860
7861 case $build_os in
7862 msdosdjgpp*)
7863 # On DJGPP, this test can blow up pretty badly due to problems in libc
7864 # (any single argument exceeding 2000 bytes causes a buffer overrun
7865 # during glob expansion). Even if it were fixed, the result of this
7866 # check would be larger than it should be.
7867 lt_cv_sys_max_cmd_len=12288; # 12K is about right
7868 ;;
7869
7870 gnu*)
7871 # Under GNU Hurd, this test is not required because there is
7872 # no limit to the length of command line arguments.
7873 # Libtool will interpret -1 as no limit whatsoever
7874 lt_cv_sys_max_cmd_len=-1;
7875 ;;
7876
7877 cygwin* | mingw* | cegcc*)
7878 # On Win9x/ME, this test blows up -- it succeeds, but takes
7879 # about 5 minutes as the teststring grows exponentially.
7880 # Worse, since 9x/ME are not pre-emptively multitasking,
7881 # you end up with a "frozen" computer, even though with patience
7882 # the test eventually succeeds (with a max line length of 256k).
7883 # Instead, let's just punt: use the minimum linelength reported by
7884 # all of the supported platforms: 8192 (on NT/2K/XP).
7885 lt_cv_sys_max_cmd_len=8192;
7886 ;;
7887
7888 mint*)
7889 # On MiNT this can take a long time and run out of memory.
7890 lt_cv_sys_max_cmd_len=8192;
7891 ;;
7892
7893 amigaos*)
7894 # On AmigaOS with pdksh, this test takes hours, literally.
7895 # So we just punt and use a minimum line length of 8192.
7896 lt_cv_sys_max_cmd_len=8192;
7897 ;;
7898
7899 bitrig* | darwin* | dragonfly* | freebsd* | netbsd* | openbsd*)
7900 # This has been around since 386BSD, at least. Likely further.
7901 if test -x /sbin/sysctl; then
7902 lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
7903 elif test -x /usr/sbin/sysctl; then
7904 lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
7905 else
7906 lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
7907 fi
7908 # And add a safety zone
7909 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
7910 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
7911 ;;
7912
7913 interix*)
7914 # We know the value 262144 and hardcode it with a safety zone (like BSD)
7915 lt_cv_sys_max_cmd_len=196608
7916 ;;
7917
7918 os2*)
7919 # The test takes a long time on OS/2.
7920 lt_cv_sys_max_cmd_len=8192
7921 ;;
7922
7923 osf*)
7924 # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
7925 # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
7926 # nice to cause kernel panics so lets avoid the loop below.
7927 # First set a reasonable default.
7928 lt_cv_sys_max_cmd_len=16384
7929 #
7930 if test -x /sbin/sysconfig; then
7931 case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
7932 *1*) lt_cv_sys_max_cmd_len=-1 ;;
7933 esac
7934 fi
7935 ;;
7936 sco3.2v5*)
7937 lt_cv_sys_max_cmd_len=102400
7938 ;;
7939 sysv5* | sco5v6* | sysv4.2uw2*)
7940 kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
7941 if test -n "$kargmax"; then
7942 lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'`
7943 else
7944 lt_cv_sys_max_cmd_len=32768
7945 fi
7946 ;;
7947 *)
7948 lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
7949 if test -n "$lt_cv_sys_max_cmd_len" && \
7950 test undefined != "$lt_cv_sys_max_cmd_len"; then
7951 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
7952 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
7953 else
7954 # Make teststring a little bigger before we do anything with it.
7955 # a 1K string should be a reasonable start.
7956 for i in 1 2 3 4 5 6 7 8; do
7957 teststring=$teststring$teststring
7958 done
7959 SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
7960 # If test is not a shell built-in, we'll probably end up computing a
7961 # maximum length that is only half of the actual maximum length, but
7962 # we can't tell.
7963 while { test X`env echo "$teststring$teststring" 2>/dev/null` \
7964 = "X$teststring$teststring"; } >/dev/null 2>&1 &&
7965 test 17 != "$i" # 1/2 MB should be enough
7966 do
7967 i=`expr $i + 1`
7968 teststring=$teststring$teststring
7969 done
7970 # Only check the string length outside the loop.
7971 lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
7972 teststring=
7973 # Add a significant safety factor because C++ compilers can tack on
7974 # massive amounts of additional arguments before passing them to the
7975 # linker. It appears as though 1/2 is a usable value.
7976 lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
7977 fi
7978 ;;
7979 esac
7980
7981fi
7982
7983if test -n "$lt_cv_sys_max_cmd_len"; then
7984 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5
7985$as_echo "$lt_cv_sys_max_cmd_len" >&6; }
7986else
7987 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5
7988$as_echo "none" >&6; }
7989fi
7990max_cmd_len=$lt_cv_sys_max_cmd_len
7991
7992
7993
7994
7995
7996
7997: ${CP="cp -f"}
7998: ${MV="mv -f"}
7999: ${RM="rm -f"}
8000
8001if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
8002 lt_unset=unset
8003else
8004 lt_unset=false
8005fi
8006
8007
8008
8009
8010
8011# test EBCDIC or ASCII
8012case `echo X|tr X '\101'` in
8013 A) # ASCII based system
8014 # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
8015 lt_SP2NL='tr \040 \012'
8016 lt_NL2SP='tr \015\012 \040\040'
8017 ;;
8018 *) # EBCDIC based system
8019 lt_SP2NL='tr \100 \n'
8020 lt_NL2SP='tr \r\n \100\100'
8021 ;;
8022esac
8023
8024
8025
8026
8027
8028
8029
8030
8031
8032{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5
8033$as_echo_n "checking how to convert $build file names to $host format... " >&6; }
8034if ${lt_cv_to_host_file_cmd+:} false; then :
8035 $as_echo_n "(cached) " >&6
8036else
8037 case $host in
8038 *-*-mingw* )
8039 case $build in
8040 *-*-mingw* ) # actually msys
8041 lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
8042 ;;
8043 *-*-cygwin* )
8044 lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
8045 ;;
8046 * ) # otherwise, assume *nix
8047 lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
8048 ;;
8049 esac
8050 ;;
8051 *-*-cygwin* )
8052 case $build in
8053 *-*-mingw* ) # actually msys
8054 lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
8055 ;;
8056 *-*-cygwin* )
8057 lt_cv_to_host_file_cmd=func_convert_file_noop
8058 ;;
8059 * ) # otherwise, assume *nix
8060 lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
8061 ;;
8062 esac
8063 ;;
8064 * ) # unhandled hosts (and "normal" native builds)
8065 lt_cv_to_host_file_cmd=func_convert_file_noop
8066 ;;
8067esac
8068
8069fi
8070
8071to_host_file_cmd=$lt_cv_to_host_file_cmd
8072{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5
8073$as_echo "$lt_cv_to_host_file_cmd" >&6; }
8074
8075
8076
8077
8078
8079{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5
8080$as_echo_n "checking how to convert $build file names to toolchain format... " >&6; }
8081if ${lt_cv_to_tool_file_cmd+:} false; then :
8082 $as_echo_n "(cached) " >&6
8083else
8084 #assume ordinary cross tools, or native build.
8085lt_cv_to_tool_file_cmd=func_convert_file_noop
8086case $host in
8087 *-*-mingw* )
8088 case $build in
8089 *-*-mingw* ) # actually msys
8090 lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
8091 ;;
8092 esac
8093 ;;
8094esac
8095
8096fi
8097
8098to_tool_file_cmd=$lt_cv_to_tool_file_cmd
8099{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5
8100$as_echo "$lt_cv_to_tool_file_cmd" >&6; }
8101
8102
8103
8104
8105
8106{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
8107$as_echo_n "checking for $LD option to reload object files... " >&6; }
8108if ${lt_cv_ld_reload_flag+:} false; then :
8109 $as_echo_n "(cached) " >&6
8110else
8111 lt_cv_ld_reload_flag='-r'
8112fi
8113{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5
8114$as_echo "$lt_cv_ld_reload_flag" >&6; }
8115reload_flag=$lt_cv_ld_reload_flag
8116case $reload_flag in
8117"" | " "*) ;;
8118*) reload_flag=" $reload_flag" ;;
8119esac
8120reload_cmds='$LD$reload_flag -o $output$reload_objs'
8121case $host_os in
8122 cygwin* | mingw* | pw32* | cegcc*)
8123 if test yes != "$GCC"; then
8124 reload_cmds=false
8125 fi
8126 ;;
8127 darwin*)
8128 if test yes = "$GCC"; then
8129 reload_cmds='$LTCC $LTCFLAGS -nostdlib $wl-r -o $output$reload_objs'
8130 else
8131 reload_cmds='$LD$reload_flag -o $output$reload_objs'
8132 fi
8133 ;;
8134esac
8135
8136
8137
8138
8139
8140
8141
8142
8143
8144if test -n "$ac_tool_prefix"; then
8145 # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
8146set dummy ${ac_tool_prefix}objdump; ac_word=$2
8147{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8148$as_echo_n "checking for $ac_word... " >&6; }
8149if ${ac_cv_prog_OBJDUMP+:} false; then :
8150 $as_echo_n "(cached) " >&6
8151else
8152 if test -n "$OBJDUMP"; then
8153 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
8154else
8155as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8156for as_dir in $PATH
8157do
8158 IFS=$as_save_IFS
8159 test -z "$as_dir" && as_dir=.
8160 for ac_exec_ext in '' $ac_executable_extensions; do
8161 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8162 ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
8163 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8164 break 2
8165 fi
8166done
8167 done
8168IFS=$as_save_IFS
8169
8170fi
8171fi
8172OBJDUMP=$ac_cv_prog_OBJDUMP
8173if test -n "$OBJDUMP"; then
8174 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
8175$as_echo "$OBJDUMP" >&6; }
8176else
8177 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8178$as_echo "no" >&6; }
8179fi
8180
8181
8182fi
8183if test -z "$ac_cv_prog_OBJDUMP"; then
8184 ac_ct_OBJDUMP=$OBJDUMP
8185 # Extract the first word of "objdump", so it can be a program name with args.
8186set dummy objdump; ac_word=$2
8187{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8188$as_echo_n "checking for $ac_word... " >&6; }
8189if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
8190 $as_echo_n "(cached) " >&6
8191else
8192 if test -n "$ac_ct_OBJDUMP"; then
8193 ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
8194else
8195as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8196for as_dir in $PATH
8197do
8198 IFS=$as_save_IFS
8199 test -z "$as_dir" && as_dir=.
8200 for ac_exec_ext in '' $ac_executable_extensions; do
8201 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8202 ac_cv_prog_ac_ct_OBJDUMP="objdump"
8203 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8204 break 2
8205 fi
8206done
8207 done
8208IFS=$as_save_IFS
8209
8210fi
8211fi
8212ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
8213if test -n "$ac_ct_OBJDUMP"; then
8214 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
8215$as_echo "$ac_ct_OBJDUMP" >&6; }
8216else
8217 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8218$as_echo "no" >&6; }
8219fi
8220
8221 if test "x$ac_ct_OBJDUMP" = x; then
8222 OBJDUMP="false"
8223 else
8224 case $cross_compiling:$ac_tool_warned in
8225yes:)
8226{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8227$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8228ac_tool_warned=yes ;;
8229esac
8230 OBJDUMP=$ac_ct_OBJDUMP
8231 fi
8232else
8233 OBJDUMP="$ac_cv_prog_OBJDUMP"
8234fi
8235
8236test -z "$OBJDUMP" && OBJDUMP=objdump
8237
8238
8239
8240
8241
8242
8243{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5
8244$as_echo_n "checking how to recognize dependent libraries... " >&6; }
8245if ${lt_cv_deplibs_check_method+:} false; then :
8246 $as_echo_n "(cached) " >&6
8247else
8248 lt_cv_file_magic_cmd='$MAGIC_CMD'
8249lt_cv_file_magic_test_file=
8250lt_cv_deplibs_check_method='unknown'
8251# Need to set the preceding variable on all platforms that support
8252# interlibrary dependencies.
8253# 'none' -- dependencies not supported.
8254# 'unknown' -- same as none, but documents that we really don't know.
8255# 'pass_all' -- all dependencies passed with no checks.
8256# 'test_compile' -- check by making test program.
8257# 'file_magic [[regex]]' -- check by looking for files in library path
8258# that responds to the $file_magic_cmd with a given extended regex.
8259# If you have 'file' or equivalent on your system and you're not sure
8260# whether 'pass_all' will *always* work, you probably want this one.
8261
8262case $host_os in
8263aix[4-9]*)
8264 lt_cv_deplibs_check_method=pass_all
8265 ;;
8266
8267beos*)
8268 lt_cv_deplibs_check_method=pass_all
8269 ;;
8270
8271bsdi[45]*)
8272 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
8273 lt_cv_file_magic_cmd='/usr/bin/file -L'
8274 lt_cv_file_magic_test_file=/shlib/libc.so
8275 ;;
8276
8277cygwin*)
8278 # func_win32_libid is a shell function defined in ltmain.sh
8279 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
8280 lt_cv_file_magic_cmd='func_win32_libid'
8281 ;;
8282
8283mingw* | pw32*)
8284 # Base MSYS/MinGW do not provide the 'file' command needed by
8285 # func_win32_libid shell function, so use a weaker test based on 'objdump',
8286 # unless we find 'file', for example because we are cross-compiling.
8287 if ( file / ) >/dev/null 2>&1; then
8288 lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
8289 lt_cv_file_magic_cmd='func_win32_libid'
8290 else
8291 # Keep this pattern in sync with the one in func_win32_libid.
8292 lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
8293 lt_cv_file_magic_cmd='$OBJDUMP -f'
8294 fi
8295 ;;
8296
8297cegcc*)
8298 # use the weaker test based on 'objdump'. See mingw*.
8299 lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
8300 lt_cv_file_magic_cmd='$OBJDUMP -f'
8301 ;;
8302
8303darwin* | rhapsody*)
8304 lt_cv_deplibs_check_method=pass_all
8305 ;;
8306
8307freebsd* | dragonfly*)
8308 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
8309 case $host_cpu in
8310 i*86 )
8311 # Not sure whether the presence of OpenBSD here was a mistake.
8312 # Let's accept both of them until this is cleared up.
8313 lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library'
8314 lt_cv_file_magic_cmd=/usr/bin/file
8315 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
8316 ;;
8317 esac
8318 else
8319 lt_cv_deplibs_check_method=pass_all
8320 fi
8321 ;;
8322
8323haiku*)
8324 lt_cv_deplibs_check_method=pass_all
8325 ;;
8326
8327hpux10.20* | hpux11*)
8328 lt_cv_file_magic_cmd=/usr/bin/file
8329 case $host_cpu in
8330 ia64*)
8331 lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
8332 lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
8333 ;;
8334 hppa*64*)
8335 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]'
8336 lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
8337 ;;
8338 *)
8339 lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library'
8340 lt_cv_file_magic_test_file=/usr/lib/libc.sl
8341 ;;
8342 esac
8343 ;;
8344
8345interix[3-9]*)
8346 # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
8347 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$'
8348 ;;
8349
8350irix5* | irix6* | nonstopux*)
8351 case $LD in
8352 *-32|*"-32 ") libmagic=32-bit;;
8353 *-n32|*"-n32 ") libmagic=N32;;
8354 *-64|*"-64 ") libmagic=64-bit;;
8355 *) libmagic=never-match;;
8356 esac
8357 lt_cv_deplibs_check_method=pass_all
8358 ;;
8359
8360# This must be glibc/ELF.
8361linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
8362 lt_cv_deplibs_check_method=pass_all
8363 ;;
8364
8365netbsd* | netbsdelf*-gnu)
8366 if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
8367 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
8368 else
8369 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$'
8370 fi
8371 ;;
8372
8373newos6*)
8374 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
8375 lt_cv_file_magic_cmd=/usr/bin/file
8376 lt_cv_file_magic_test_file=/usr/lib/libnls.so
8377 ;;
8378
8379*nto* | *qnx*)
8380 lt_cv_deplibs_check_method=pass_all
8381 ;;
8382
8383openbsd* | bitrig*)
8384 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
8385 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$'
8386 else
8387 lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
8388 fi
8389 ;;
8390
8391osf3* | osf4* | osf5*)
8392 lt_cv_deplibs_check_method=pass_all
8393 ;;
8394
8395rdos*)
8396 lt_cv_deplibs_check_method=pass_all
8397 ;;
8398
8399solaris*)
8400 lt_cv_deplibs_check_method=pass_all
8401 ;;
8402
8403sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
8404 lt_cv_deplibs_check_method=pass_all
8405 ;;
8406
8407sysv4 | sysv4.3*)
8408 case $host_vendor in
8409 motorola)
8410 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]'
8411 lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
8412 ;;
8413 ncr)
8414 lt_cv_deplibs_check_method=pass_all
8415 ;;
8416 sequent)
8417 lt_cv_file_magic_cmd='/bin/file'
8418 lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
8419 ;;
8420 sni)
8421 lt_cv_file_magic_cmd='/bin/file'
8422 lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
8423 lt_cv_file_magic_test_file=/lib/libc.so
8424 ;;
8425 siemens)
8426 lt_cv_deplibs_check_method=pass_all
8427 ;;
8428 pc)
8429 lt_cv_deplibs_check_method=pass_all
8430 ;;
8431 esac
8432 ;;
8433
8434tpf*)
8435 lt_cv_deplibs_check_method=pass_all
8436 ;;
8437os2*)
8438 lt_cv_deplibs_check_method=pass_all
8439 ;;
8440esac
8441
8442fi
8443{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
8444$as_echo "$lt_cv_deplibs_check_method" >&6; }
8445
8446file_magic_glob=
8447want_nocaseglob=no
8448if test "$build" = "$host"; then
8449 case $host_os in
8450 mingw* | pw32*)
8451 if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
8452 want_nocaseglob=yes
8453 else
8454 file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"`
8455 fi
8456 ;;
8457 esac
8458fi
8459
8460file_magic_cmd=$lt_cv_file_magic_cmd
8461deplibs_check_method=$lt_cv_deplibs_check_method
8462test -z "$deplibs_check_method" && deplibs_check_method=unknown
8463
8464
8465
8466
8467
8468
8469
8470
8471
8472
8473
8474
8475
8476
8477
8478
8479
8480
8481
8482
8483
8484
8485if test -n "$ac_tool_prefix"; then
8486 # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
8487set dummy ${ac_tool_prefix}dlltool; ac_word=$2
8488{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8489$as_echo_n "checking for $ac_word... " >&6; }
8490if ${ac_cv_prog_DLLTOOL+:} false; then :
8491 $as_echo_n "(cached) " >&6
8492else
8493 if test -n "$DLLTOOL"; then
8494 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
8495else
8496as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8497for as_dir in $PATH
8498do
8499 IFS=$as_save_IFS
8500 test -z "$as_dir" && as_dir=.
8501 for ac_exec_ext in '' $ac_executable_extensions; do
8502 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8503 ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
8504 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8505 break 2
8506 fi
8507done
8508 done
8509IFS=$as_save_IFS
8510
8511fi
8512fi
8513DLLTOOL=$ac_cv_prog_DLLTOOL
8514if test -n "$DLLTOOL"; then
8515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
8516$as_echo "$DLLTOOL" >&6; }
8517else
8518 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8519$as_echo "no" >&6; }
8520fi
8521
8522
8523fi
8524if test -z "$ac_cv_prog_DLLTOOL"; then
8525 ac_ct_DLLTOOL=$DLLTOOL
8526 # Extract the first word of "dlltool", so it can be a program name with args.
8527set dummy dlltool; ac_word=$2
8528{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8529$as_echo_n "checking for $ac_word... " >&6; }
8530if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
8531 $as_echo_n "(cached) " >&6
8532else
8533 if test -n "$ac_ct_DLLTOOL"; then
8534 ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
8535else
8536as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8537for as_dir in $PATH
8538do
8539 IFS=$as_save_IFS
8540 test -z "$as_dir" && as_dir=.
8541 for ac_exec_ext in '' $ac_executable_extensions; do
8542 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8543 ac_cv_prog_ac_ct_DLLTOOL="dlltool"
8544 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8545 break 2
8546 fi
8547done
8548 done
8549IFS=$as_save_IFS
8550
8551fi
8552fi
8553ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
8554if test -n "$ac_ct_DLLTOOL"; then
8555 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
8556$as_echo "$ac_ct_DLLTOOL" >&6; }
8557else
8558 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8559$as_echo "no" >&6; }
8560fi
8561
8562 if test "x$ac_ct_DLLTOOL" = x; then
8563 DLLTOOL="false"
8564 else
8565 case $cross_compiling:$ac_tool_warned in
8566yes:)
8567{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8568$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8569ac_tool_warned=yes ;;
8570esac
8571 DLLTOOL=$ac_ct_DLLTOOL
8572 fi
8573else
8574 DLLTOOL="$ac_cv_prog_DLLTOOL"
8575fi
8576
8577test -z "$DLLTOOL" && DLLTOOL=dlltool
8578
8579
8580
8581
8582
8583
8584
8585{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5
8586$as_echo_n "checking how to associate runtime and link libraries... " >&6; }
8587if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then :
8588 $as_echo_n "(cached) " >&6
8589else
8590 lt_cv_sharedlib_from_linklib_cmd='unknown'
8591
8592case $host_os in
8593cygwin* | mingw* | pw32* | cegcc*)
8594 # two different shell functions defined in ltmain.sh;
8595 # decide which one to use based on capabilities of $DLLTOOL
8596 case `$DLLTOOL --help 2>&1` in
8597 *--identify-strict*)
8598 lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
8599 ;;
8600 *)
8601 lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
8602 ;;
8603 esac
8604 ;;
8605*)
8606 # fallback: assume linklib IS sharedlib
8607 lt_cv_sharedlib_from_linklib_cmd=$ECHO
8608 ;;
8609esac
8610
8611fi
8612{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5
8613$as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; }
8614sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
8615test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
8616
8617
8618
8619
8620
8621
8622
8623if test -n "$ac_tool_prefix"; then
8624 for ac_prog in ar
8625 do
8626 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
8627set dummy $ac_tool_prefix$ac_prog; ac_word=$2
8628{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8629$as_echo_n "checking for $ac_word... " >&6; }
8630if ${ac_cv_prog_AR+:} false; then :
8631 $as_echo_n "(cached) " >&6
8632else
8633 if test -n "$AR"; then
8634 ac_cv_prog_AR="$AR" # Let the user override the test.
8635else
8636as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8637for as_dir in $PATH
8638do
8639 IFS=$as_save_IFS
8640 test -z "$as_dir" && as_dir=.
8641 for ac_exec_ext in '' $ac_executable_extensions; do
8642 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8643 ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
8644 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8645 break 2
8646 fi
8647done
8648 done
8649IFS=$as_save_IFS
8650
8651fi
8652fi
8653AR=$ac_cv_prog_AR
8654if test -n "$AR"; then
8655 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
8656$as_echo "$AR" >&6; }
8657else
8658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8659$as_echo "no" >&6; }
8660fi
8661
8662
8663 test -n "$AR" && break
8664 done
8665fi
8666if test -z "$AR"; then
8667 ac_ct_AR=$AR
8668 for ac_prog in ar
8669do
8670 # Extract the first word of "$ac_prog", so it can be a program name with args.
8671set dummy $ac_prog; ac_word=$2
8672{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8673$as_echo_n "checking for $ac_word... " >&6; }
8674if ${ac_cv_prog_ac_ct_AR+:} false; then :
8675 $as_echo_n "(cached) " >&6
8676else
8677 if test -n "$ac_ct_AR"; then
8678 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
8679else
8680as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8681for as_dir in $PATH
8682do
8683 IFS=$as_save_IFS
8684 test -z "$as_dir" && as_dir=.
8685 for ac_exec_ext in '' $ac_executable_extensions; do
8686 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8687 ac_cv_prog_ac_ct_AR="$ac_prog"
8688 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8689 break 2
8690 fi
8691done
8692 done
8693IFS=$as_save_IFS
8694
8695fi
8696fi
8697ac_ct_AR=$ac_cv_prog_ac_ct_AR
8698if test -n "$ac_ct_AR"; then
8699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
8700$as_echo "$ac_ct_AR" >&6; }
8701else
8702 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8703$as_echo "no" >&6; }
8704fi
8705
8706
8707 test -n "$ac_ct_AR" && break
8708done
8709
8710 if test "x$ac_ct_AR" = x; then
8711 AR="false"
8712 else
8713 case $cross_compiling:$ac_tool_warned in
8714yes:)
8715{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8716$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8717ac_tool_warned=yes ;;
8718esac
8719 AR=$ac_ct_AR
8720 fi
8721fi
8722
8723: ${AR=ar}
8724: ${AR_FLAGS=cru}
8725
8726
8727
8728
8729
8730
8731
8732
8733
8734
8735
8736{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
8737$as_echo_n "checking for archiver @FILE support... " >&6; }
8738if ${lt_cv_ar_at_file+:} false; then :
8739 $as_echo_n "(cached) " >&6
8740else
8741 lt_cv_ar_at_file=no
8742 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8743/* end confdefs.h. */
8744
8745int main (void)
8746{
8747
8748 ;
8749 return 0;
8750}
8751_ACEOF
8752if ac_fn_c_try_compile "$LINENO"; then :
8753 echo conftest.$ac_objext > conftest.lst
8754 lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5'
8755 { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
8756 (eval $lt_ar_try) 2>&5
8757 ac_status=$?
8758 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8759 test $ac_status = 0; }
8760 if test 0 -eq "$ac_status"; then
8761 # Ensure the archiver fails upon bogus file names.
8762 rm -f conftest.$ac_objext libconftest.a
8763 { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
8764 (eval $lt_ar_try) 2>&5
8765 ac_status=$?
8766 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
8767 test $ac_status = 0; }
8768 if test 0 -ne "$ac_status"; then
8769 lt_cv_ar_at_file=@
8770 fi
8771 fi
8772 rm -f conftest.* libconftest.a
8773
8774fi
8775rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8776
8777fi
8778{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5
8779$as_echo "$lt_cv_ar_at_file" >&6; }
8780
8781if test no = "$lt_cv_ar_at_file"; then
8782 archiver_list_spec=
8783else
8784 archiver_list_spec=$lt_cv_ar_at_file
8785fi
8786
8787
8788
8789
8790
8791
8792
8793if test -n "$ac_tool_prefix"; then
8794 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
8795set dummy ${ac_tool_prefix}strip; ac_word=$2
8796{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8797$as_echo_n "checking for $ac_word... " >&6; }
8798if ${ac_cv_prog_STRIP+:} false; then :
8799 $as_echo_n "(cached) " >&6
8800else
8801 if test -n "$STRIP"; then
8802 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
8803else
8804as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8805for as_dir in $PATH
8806do
8807 IFS=$as_save_IFS
8808 test -z "$as_dir" && as_dir=.
8809 for ac_exec_ext in '' $ac_executable_extensions; do
8810 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8811 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
8812 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8813 break 2
8814 fi
8815done
8816 done
8817IFS=$as_save_IFS
8818
8819fi
8820fi
8821STRIP=$ac_cv_prog_STRIP
8822if test -n "$STRIP"; then
8823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
8824$as_echo "$STRIP" >&6; }
8825else
8826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8827$as_echo "no" >&6; }
8828fi
8829
8830
8831fi
8832if test -z "$ac_cv_prog_STRIP"; then
8833 ac_ct_STRIP=$STRIP
8834 # Extract the first word of "strip", so it can be a program name with args.
8835set dummy strip; ac_word=$2
8836{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8837$as_echo_n "checking for $ac_word... " >&6; }
8838if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
8839 $as_echo_n "(cached) " >&6
8840else
8841 if test -n "$ac_ct_STRIP"; then
8842 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
8843else
8844as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8845for as_dir in $PATH
8846do
8847 IFS=$as_save_IFS
8848 test -z "$as_dir" && as_dir=.
8849 for ac_exec_ext in '' $ac_executable_extensions; do
8850 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8851 ac_cv_prog_ac_ct_STRIP="strip"
8852 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8853 break 2
8854 fi
8855done
8856 done
8857IFS=$as_save_IFS
8858
8859fi
8860fi
8861ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
8862if test -n "$ac_ct_STRIP"; then
8863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
8864$as_echo "$ac_ct_STRIP" >&6; }
8865else
8866 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8867$as_echo "no" >&6; }
8868fi
8869
8870 if test "x$ac_ct_STRIP" = x; then
8871 STRIP=":"
8872 else
8873 case $cross_compiling:$ac_tool_warned in
8874yes:)
8875{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8876$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8877ac_tool_warned=yes ;;
8878esac
8879 STRIP=$ac_ct_STRIP
8880 fi
8881else
8882 STRIP="$ac_cv_prog_STRIP"
8883fi
8884
8885test -z "$STRIP" && STRIP=:
8886
8887
8888
8889
8890
8891
8892if test -n "$ac_tool_prefix"; then
8893 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
8894set dummy ${ac_tool_prefix}ranlib; ac_word=$2
8895{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8896$as_echo_n "checking for $ac_word... " >&6; }
8897if ${ac_cv_prog_RANLIB+:} false; then :
8898 $as_echo_n "(cached) " >&6
8899else
8900 if test -n "$RANLIB"; then
8901 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
8902else
8903as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8904for as_dir in $PATH
8905do
8906 IFS=$as_save_IFS
8907 test -z "$as_dir" && as_dir=.
8908 for ac_exec_ext in '' $ac_executable_extensions; do
8909 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8910 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
8911 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8912 break 2
8913 fi
8914done
8915 done
8916IFS=$as_save_IFS
8917
8918fi
8919fi
8920RANLIB=$ac_cv_prog_RANLIB
8921if test -n "$RANLIB"; then
8922 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
8923$as_echo "$RANLIB" >&6; }
8924else
8925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8926$as_echo "no" >&6; }
8927fi
8928
8929
8930fi
8931if test -z "$ac_cv_prog_RANLIB"; then
8932 ac_ct_RANLIB=$RANLIB
8933 # Extract the first word of "ranlib", so it can be a program name with args.
8934set dummy ranlib; ac_word=$2
8935{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8936$as_echo_n "checking for $ac_word... " >&6; }
8937if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
8938 $as_echo_n "(cached) " >&6
8939else
8940 if test -n "$ac_ct_RANLIB"; then
8941 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
8942else
8943as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8944for as_dir in $PATH
8945do
8946 IFS=$as_save_IFS
8947 test -z "$as_dir" && as_dir=.
8948 for ac_exec_ext in '' $ac_executable_extensions; do
8949 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
8950 ac_cv_prog_ac_ct_RANLIB="ranlib"
8951 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8952 break 2
8953 fi
8954done
8955 done
8956IFS=$as_save_IFS
8957
8958fi
8959fi
8960ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
8961if test -n "$ac_ct_RANLIB"; then
8962 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
8963$as_echo "$ac_ct_RANLIB" >&6; }
8964else
8965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8966$as_echo "no" >&6; }
8967fi
8968
8969 if test "x$ac_ct_RANLIB" = x; then
8970 RANLIB=":"
8971 else
8972 case $cross_compiling:$ac_tool_warned in
8973yes:)
8974{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
8975$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
8976ac_tool_warned=yes ;;
8977esac
8978 RANLIB=$ac_ct_RANLIB
8979 fi
8980else
8981 RANLIB="$ac_cv_prog_RANLIB"
8982fi
8983
8984test -z "$RANLIB" && RANLIB=:
8985
8986
8987
8988
8989
8990
8991# Determine commands to create old-style static archives.
8992old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
8993old_postinstall_cmds='chmod 644 $oldlib'
8994old_postuninstall_cmds=
8995
8996if test -n "$RANLIB"; then
8997 case $host_os in
8998 bitrig* | openbsd*)
8999 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib"
9000 ;;
9001 *)
9002 old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib"
9003 ;;
9004 esac
9005 old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib"
9006fi
9007
9008case $host_os in
9009 darwin*)
9010 lock_old_archive_extraction=yes ;;
9011 *)
9012 lock_old_archive_extraction=no ;;
9013esac
9014
9015
9016
9017
9018
9019
9020
9021
9022
9023
9024
9025
9026
9027
9028
9029
9030
9031
9032
9033
9034
9035
9036
9037
9038
9039
9040
9041
9042
9043
9044
9045
9046
9047
9048
9049
9050
9051
9052
9053# If no C compiler was specified, use CC.
9054LTCC=${LTCC-"$CC"}
9055
9056# If no C compiler flags were specified, use CFLAGS.
9057LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
9058
9059# Allow CC to be a program name with arguments.
9060compiler=$CC
9061
9062
9063# Check for command to grab the raw symbol name followed by C symbol from nm.
9064{ $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5
9065$as_echo_n "checking command to parse $NM output from $compiler object... " >&6; }
9066if ${lt_cv_sys_global_symbol_pipe+:} false; then :
9067 $as_echo_n "(cached) " >&6
9068else
9069
9070# These are sane defaults that work on at least a few old systems.
9071# [They come from Ultrix. What could be older than Ultrix?!! ;)]
9072
9073# Character class describing NM global symbol codes.
9074symcode='[BCDEGRST]'
9075
9076# Regexp to match symbols that can be accessed directly from C.
9077sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
9078
9079# Define system-specific variables.
9080case $host_os in
9081aix*)
9082 symcode='[BCDT]'
9083 ;;
9084cygwin* | mingw* | pw32* | cegcc*)
9085 symcode='[ABCDGISTW]'
9086 ;;
9087hpux*)
9088 if test ia64 = "$host_cpu"; then
9089 symcode='[ABCDEGRST]'
9090 fi
9091 ;;
9092irix* | nonstopux*)
9093 symcode='[BCDEGRST]'
9094 ;;
9095osf*)
9096 symcode='[BCDEGQRST]'
9097 ;;
9098solaris*)
9099 symcode='[BDRT]'
9100 ;;
9101sco3.2v5*)
9102 symcode='[DT]'
9103 ;;
9104sysv4.2uw2*)
9105 symcode='[DT]'
9106 ;;
9107sysv5* | sco5v6* | unixware* | OpenUNIX*)
9108 symcode='[ABDT]'
9109 ;;
9110sysv4)
9111 symcode='[DFNSTU]'
9112 ;;
9113esac
9114
9115# If we're using GNU nm, then use its standard symbol codes.
9116case `$NM -V 2>&1` in
9117*GNU* | *'with BFD'*)
9118 symcode='[ABCDGIRSTW]' ;;
9119esac
9120
9121if test "$lt_cv_nm_interface" = "MS dumpbin"; then
9122 # Gets list of data symbols to import.
9123 lt_cv_sys_global_symbol_to_import="sed -n -e 's/^I .* \(.*\)$/\1/p'"
9124 # Adjust the below global symbol transforms to fixup imported variables.
9125 lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'"
9126 lt_c_name_hook=" -e 's/^I .* \(.*\)$/ {\"\1\", (void *) 0},/p'"
9127 lt_c_name_lib_hook="\
9128 -e 's/^I .* \(lib.*\)$/ {\"\1\", (void *) 0},/p'\
9129 -e 's/^I .* \(.*\)$/ {\"lib\1\", (void *) 0},/p'"
9130else
9131 # Disable hooks by default.
9132 lt_cv_sys_global_symbol_to_import=
9133 lt_cdecl_hook=
9134 lt_c_name_hook=
9135 lt_c_name_lib_hook=
9136fi
9137
9138# Transform an extracted symbol line into a proper C declaration.
9139# Some systems (esp. on ia64) link data and code symbols differently,
9140# so use this general approach.
9141lt_cv_sys_global_symbol_to_cdecl="sed -n"\
9142$lt_cdecl_hook\
9143" -e 's/^T .* \(.*\)$/extern int \1();/p'"\
9144" -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'"
9145
9146# Transform an extracted symbol line into symbol name and symbol address
9147lt_cv_sys_global_symbol_to_c_name_address="sed -n"\
9148$lt_c_name_hook\
9149" -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\
9150" -e 's/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/p'"
9151
9152# Transform an extracted symbol line into symbol name with lib prefix and
9153# symbol address.
9154lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n"\
9155$lt_c_name_lib_hook\
9156" -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\
9157" -e 's/^$symcode$symcode* .* \(lib.*\)$/ {\"\1\", (void *) \&\1},/p'"\
9158" -e 's/^$symcode$symcode* .* \(.*\)$/ {\"lib\1\", (void *) \&\1},/p'"
9159
9160# Handle CRLF in mingw tool chain
9161opt_cr=
9162case $build_os in
9163mingw*)
9164 opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
9165 ;;
9166esac
9167
9168# Try without a prefix underscore, then with it.
9169for ac_symprfx in "" "_"; do
9170
9171 # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
9172 symxfrm="\\1 $ac_symprfx\\2 \\2"
9173
9174 # Write the raw and C identifiers.
9175 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
9176 # Fake it for dumpbin and say T for any non-static function,
9177 # D for any global variable and I for any imported variable.
9178 # Also find C++ and __fastcall symbols from MSVC++,
9179 # which start with @ or ?.
9180 lt_cv_sys_global_symbol_pipe="$AWK '"\
9181" {last_section=section; section=\$ 3};"\
9182" /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\
9183" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
9184" /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\
9185" /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\
9186" /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\
9187" \$ 0!~/External *\|/{next};"\
9188" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
9189" {if(hide[section]) next};"\
9190" {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\
9191" {split(\$ 0,a,/\||\r/); split(a[2],s)};"\
9192" s[1]~/^[@?]/{print f,s[1],s[1]; next};"\
9193" s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\
9194" ' prfx=^$ac_symprfx"
9195 else
9196 lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
9197 fi
9198 lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
9199
9200 # Check to see that the pipe works correctly.
9201 pipe_works=no
9202
9203 rm -f conftest*
9204 cat > conftest.$ac_ext <<_LT_EOF
9205#ifdef __cplusplus
9206extern "C" {
9207#endif
9208char nm_test_var;
9209void nm_test_func(void);
9210void nm_test_func(void){}
9211#ifdef __cplusplus
9212}
9213#endif
9214int main(){nm_test_var='a';nm_test_func();return(0);}
9215_LT_EOF
9216
9217 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9218 (eval $ac_compile) 2>&5
9219 ac_status=$?
9220 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9221 test $ac_status = 0; }; then
9222 # Now try to grab the symbols.
9223 nlist=conftest.nm
Haibo Huang001784b2019-07-19 05:27:28 -07009224 $ECHO "$as_me:$LINENO: $NM conftest.$ac_objext | $lt_cv_sys_global_symbol_pipe > $nlist" >&5
9225 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 -07009226 # Try sorting and uniquifying the output.
9227 if sort "$nlist" | uniq > "$nlist"T; then
9228 mv -f "$nlist"T "$nlist"
9229 else
9230 rm -f "$nlist"T
9231 fi
9232
9233 # Make sure that we snagged all the symbols we need.
9234 if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
9235 if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
9236 cat <<_LT_EOF > conftest.$ac_ext
9237/* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */
9238#if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE
9239/* DATA imports from DLLs on WIN32 can't be const, because runtime
9240 relocations are performed -- see ld's documentation on pseudo-relocs. */
9241# define LT_DLSYM_CONST
9242#elif defined __osf__
9243/* This system does not cope well with relocations in const data. */
9244# define LT_DLSYM_CONST
9245#else
9246# define LT_DLSYM_CONST const
9247#endif
9248
9249#ifdef __cplusplus
9250extern "C" {
9251#endif
9252
9253_LT_EOF
9254 # Now generate the symbol file.
9255 eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
9256
9257 cat <<_LT_EOF >> conftest.$ac_ext
9258
9259/* The mapping between symbol names and symbols. */
9260LT_DLSYM_CONST struct {
9261 const char *name;
9262 void *address;
9263}
9264lt__PROGRAM__LTX_preloaded_symbols[] =
9265{
9266 { "@PROGRAM@", (void *) 0 },
9267_LT_EOF
9268 $SED "s/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
9269 cat <<\_LT_EOF >> conftest.$ac_ext
9270 {0, (void *) 0}
9271};
9272
9273/* This works around a problem in FreeBSD linker */
9274#ifdef FREEBSD_WORKAROUND
9275static const void *lt_preloaded_setup() {
9276 return lt__PROGRAM__LTX_preloaded_symbols;
9277}
9278#endif
9279
9280#ifdef __cplusplus
9281}
9282#endif
9283_LT_EOF
9284 # Now try linking the two files.
9285 mv -f conftest.$ac_objext conftstm.$ac_objext
9286 lt_globsym_save_LIBS=$LIBS
9287 lt_globsym_save_CFLAGS=$CFLAGS
9288 LIBS=conftstm.$ac_objext
9289 CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
9290 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
9291 (eval $ac_link) 2>&5
9292 ac_status=$?
9293 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9294 test $ac_status = 0; } && test -s conftest$ac_exeext; then
9295 pipe_works=yes
9296 fi
9297 LIBS=$lt_globsym_save_LIBS
9298 CFLAGS=$lt_globsym_save_CFLAGS
9299 else
9300 echo "cannot find nm_test_func in $nlist" >&5
9301 fi
9302 else
9303 echo "cannot find nm_test_var in $nlist" >&5
9304 fi
9305 else
9306 echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
9307 fi
9308 else
9309 echo "$progname: failed program was:" >&5
9310 cat conftest.$ac_ext >&5
9311 fi
9312 rm -rf conftest* conftst*
9313
9314 # Do not use the global_symbol_pipe unless it works.
9315 if test yes = "$pipe_works"; then
9316 break
9317 else
9318 lt_cv_sys_global_symbol_pipe=
9319 fi
9320done
9321
9322fi
9323
9324if test -z "$lt_cv_sys_global_symbol_pipe"; then
9325 lt_cv_sys_global_symbol_to_cdecl=
9326fi
9327if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
9328 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
9329$as_echo "failed" >&6; }
9330else
9331 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
9332$as_echo "ok" >&6; }
9333fi
9334
9335# Response file support.
9336if test "$lt_cv_nm_interface" = "MS dumpbin"; then
9337 nm_file_list_spec='@'
9338elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then
9339 nm_file_list_spec='@'
9340fi
9341
9342
9343
9344
9345
9346
9347
9348
9349
9350
9351
9352
9353
9354
9355
9356
9357
9358
9359
9360
9361
9362
9363
9364
9365
9366
9367
9368
9369
9370
9371
9372
9373
9374
9375
9376
9377
9378{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
9379$as_echo_n "checking for sysroot... " >&6; }
9380
9381# Check whether --with-sysroot was given.
9382if test "${with_sysroot+set}" = set; then :
9383 withval=$with_sysroot;
9384else
9385 with_sysroot=no
9386fi
9387
9388
9389lt_sysroot=
9390case $with_sysroot in #(
9391 yes)
9392 if test yes = "$GCC"; then
9393 lt_sysroot=`$CC --print-sysroot 2>/dev/null`
9394 fi
9395 ;; #(
9396 /*)
9397 lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"`
9398 ;; #(
9399 no|'')
9400 ;; #(
9401 *)
9402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_sysroot" >&5
9403$as_echo "$with_sysroot" >&6; }
9404 as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5
9405 ;;
9406esac
9407
9408 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5
9409$as_echo "${lt_sysroot:-no}" >&6; }
9410
9411
9412
9413
9414
9415{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a working dd" >&5
9416$as_echo_n "checking for a working dd... " >&6; }
9417if ${ac_cv_path_lt_DD+:} false; then :
9418 $as_echo_n "(cached) " >&6
9419else
9420 printf 0123456789abcdef0123456789abcdef >conftest.i
9421cat conftest.i conftest.i >conftest2.i
9422: ${lt_DD:=$DD}
9423if test -z "$lt_DD"; then
9424 ac_path_lt_DD_found=false
9425 # Loop through the user's path and test for each of PROGNAME-LIST
9426 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9427for as_dir in $PATH
9428do
9429 IFS=$as_save_IFS
9430 test -z "$as_dir" && as_dir=.
9431 for ac_prog in dd; do
9432 for ac_exec_ext in '' $ac_executable_extensions; do
9433 ac_path_lt_DD="$as_dir/$ac_prog$ac_exec_ext"
9434 as_fn_executable_p "$ac_path_lt_DD" || continue
9435if "$ac_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then
9436 cmp -s conftest.i conftest.out \
9437 && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=:
9438fi
9439 $ac_path_lt_DD_found && break 3
9440 done
9441 done
9442 done
9443IFS=$as_save_IFS
9444 if test -z "$ac_cv_path_lt_DD"; then
9445 :
9446 fi
9447else
9448 ac_cv_path_lt_DD=$lt_DD
9449fi
9450
9451rm -f conftest.i conftest2.i conftest.out
9452fi
9453{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_lt_DD" >&5
9454$as_echo "$ac_cv_path_lt_DD" >&6; }
9455
9456
9457{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to truncate binary pipes" >&5
9458$as_echo_n "checking how to truncate binary pipes... " >&6; }
9459if ${lt_cv_truncate_bin+:} false; then :
9460 $as_echo_n "(cached) " >&6
9461else
9462 printf 0123456789abcdef0123456789abcdef >conftest.i
9463cat conftest.i conftest.i >conftest2.i
9464lt_cv_truncate_bin=
9465if "$ac_cv_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then
9466 cmp -s conftest.i conftest.out \
9467 && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1"
9468fi
9469rm -f conftest.i conftest2.i conftest.out
9470test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q"
9471fi
9472{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_truncate_bin" >&5
9473$as_echo "$lt_cv_truncate_bin" >&6; }
9474
9475
9476
9477
9478
9479
9480
9481# Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
9482func_cc_basename ()
9483{
9484 for cc_temp in $*""; do
9485 case $cc_temp in
9486 compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
9487 distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
9488 \-*) ;;
9489 *) break;;
9490 esac
9491 done
9492 func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
9493}
9494
9495# Check whether --enable-libtool-lock was given.
9496if test "${enable_libtool_lock+set}" = set; then :
9497 enableval=$enable_libtool_lock;
9498fi
9499
9500test no = "$enable_libtool_lock" || enable_libtool_lock=yes
9501
9502# Some flags need to be propagated to the compiler or linker for good
9503# libtool support.
9504case $host in
9505ia64-*-hpux*)
9506 # Find out what ABI is being produced by ac_compile, and set mode
9507 # options accordingly.
9508 echo 'int i;' > conftest.$ac_ext
9509 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9510 (eval $ac_compile) 2>&5
9511 ac_status=$?
9512 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9513 test $ac_status = 0; }; then
9514 case `/usr/bin/file conftest.$ac_objext` in
9515 *ELF-32*)
9516 HPUX_IA64_MODE=32
9517 ;;
9518 *ELF-64*)
9519 HPUX_IA64_MODE=64
9520 ;;
9521 esac
9522 fi
9523 rm -rf conftest*
9524 ;;
9525*-*-irix6*)
9526 # Find out what ABI is being produced by ac_compile, and set linker
9527 # options accordingly.
9528 echo '#line '$LINENO' "configure"' > conftest.$ac_ext
9529 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9530 (eval $ac_compile) 2>&5
9531 ac_status=$?
9532 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9533 test $ac_status = 0; }; then
9534 if test yes = "$lt_cv_prog_gnu_ld"; then
9535 case `/usr/bin/file conftest.$ac_objext` in
9536 *32-bit*)
9537 LD="${LD-ld} -melf32bsmip"
9538 ;;
9539 *N32*)
9540 LD="${LD-ld} -melf32bmipn32"
9541 ;;
9542 *64-bit*)
9543 LD="${LD-ld} -melf64bmip"
9544 ;;
9545 esac
9546 else
9547 case `/usr/bin/file conftest.$ac_objext` in
9548 *32-bit*)
9549 LD="${LD-ld} -32"
9550 ;;
9551 *N32*)
9552 LD="${LD-ld} -n32"
9553 ;;
9554 *64-bit*)
9555 LD="${LD-ld} -64"
9556 ;;
9557 esac
9558 fi
9559 fi
9560 rm -rf conftest*
9561 ;;
9562
9563mips64*-*linux*)
9564 # Find out what ABI is being produced by ac_compile, and set linker
9565 # options accordingly.
9566 echo '#line '$LINENO' "configure"' > conftest.$ac_ext
9567 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9568 (eval $ac_compile) 2>&5
9569 ac_status=$?
9570 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9571 test $ac_status = 0; }; then
9572 emul=elf
9573 case `/usr/bin/file conftest.$ac_objext` in
9574 *32-bit*)
9575 emul="${emul}32"
9576 ;;
9577 *64-bit*)
9578 emul="${emul}64"
9579 ;;
9580 esac
9581 case `/usr/bin/file conftest.$ac_objext` in
9582 *MSB*)
9583 emul="${emul}btsmip"
9584 ;;
9585 *LSB*)
9586 emul="${emul}ltsmip"
9587 ;;
9588 esac
9589 case `/usr/bin/file conftest.$ac_objext` in
9590 *N32*)
9591 emul="${emul}n32"
9592 ;;
9593 esac
9594 LD="${LD-ld} -m $emul"
9595 fi
9596 rm -rf conftest*
9597 ;;
9598
9599x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \
9600s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
9601 # Find out what ABI is being produced by ac_compile, and set linker
9602 # options accordingly. Note that the listed cases only cover the
9603 # situations where additional linker options are needed (such as when
9604 # doing 32-bit compilation for a host where ld defaults to 64-bit, or
9605 # vice versa); the common cases where no linker options are needed do
9606 # not appear in the list.
9607 echo 'int i;' > conftest.$ac_ext
9608 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9609 (eval $ac_compile) 2>&5
9610 ac_status=$?
9611 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9612 test $ac_status = 0; }; then
9613 case `/usr/bin/file conftest.o` in
9614 *32-bit*)
9615 case $host in
9616 x86_64-*kfreebsd*-gnu)
9617 LD="${LD-ld} -m elf_i386_fbsd"
9618 ;;
9619 x86_64-*linux*)
9620 case `/usr/bin/file conftest.o` in
9621 *x86-64*)
9622 LD="${LD-ld} -m elf32_x86_64"
9623 ;;
9624 *)
9625 LD="${LD-ld} -m elf_i386"
9626 ;;
9627 esac
9628 ;;
9629 powerpc64le-*linux*)
9630 LD="${LD-ld} -m elf32lppclinux"
9631 ;;
9632 powerpc64-*linux*)
9633 LD="${LD-ld} -m elf32ppclinux"
9634 ;;
9635 s390x-*linux*)
9636 LD="${LD-ld} -m elf_s390"
9637 ;;
9638 sparc64-*linux*)
9639 LD="${LD-ld} -m elf32_sparc"
9640 ;;
9641 esac
9642 ;;
9643 *64-bit*)
9644 case $host in
9645 x86_64-*kfreebsd*-gnu)
9646 LD="${LD-ld} -m elf_x86_64_fbsd"
9647 ;;
9648 x86_64-*linux*)
9649 LD="${LD-ld} -m elf_x86_64"
9650 ;;
9651 powerpcle-*linux*)
9652 LD="${LD-ld} -m elf64lppc"
9653 ;;
9654 powerpc-*linux*)
9655 LD="${LD-ld} -m elf64ppc"
9656 ;;
9657 s390*-*linux*|s390*-*tpf*)
9658 LD="${LD-ld} -m elf64_s390"
9659 ;;
9660 sparc*-*linux*)
9661 LD="${LD-ld} -m elf64_sparc"
9662 ;;
9663 esac
9664 ;;
9665 esac
9666 fi
9667 rm -rf conftest*
9668 ;;
9669
9670*-*-sco3.2v5*)
9671 # On SCO OpenServer 5, we need -belf to get full-featured binaries.
9672 SAVE_CFLAGS=$CFLAGS
9673 CFLAGS="$CFLAGS -belf"
9674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5
9675$as_echo_n "checking whether the C compiler needs -belf... " >&6; }
9676if ${lt_cv_cc_needs_belf+:} false; then :
9677 $as_echo_n "(cached) " >&6
9678else
9679 ac_ext=c
9680ac_cpp='$CPP $CPPFLAGS'
9681ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
9682ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
9683ac_compiler_gnu=$ac_cv_c_compiler_gnu
9684
9685 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9686/* end confdefs.h. */
9687
9688int main (void)
9689{
9690
9691 ;
9692 return 0;
9693}
9694_ACEOF
9695if ac_fn_c_try_link "$LINENO"; then :
9696 lt_cv_cc_needs_belf=yes
9697else
9698 lt_cv_cc_needs_belf=no
9699fi
9700rm -f core conftest.err conftest.$ac_objext \
9701 conftest$ac_exeext conftest.$ac_ext
9702 ac_ext=c
9703ac_cpp='$CPP $CPPFLAGS'
9704ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
9705ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
9706ac_compiler_gnu=$ac_cv_c_compiler_gnu
9707
9708fi
9709{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5
9710$as_echo "$lt_cv_cc_needs_belf" >&6; }
9711 if test yes != "$lt_cv_cc_needs_belf"; then
9712 # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
9713 CFLAGS=$SAVE_CFLAGS
9714 fi
9715 ;;
9716*-*solaris*)
9717 # Find out what ABI is being produced by ac_compile, and set linker
9718 # options accordingly.
9719 echo 'int i;' > conftest.$ac_ext
9720 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9721 (eval $ac_compile) 2>&5
9722 ac_status=$?
9723 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9724 test $ac_status = 0; }; then
9725 case `/usr/bin/file conftest.o` in
9726 *64-bit*)
9727 case $lt_cv_prog_gnu_ld in
9728 yes*)
9729 case $host in
9730 i?86-*-solaris*|x86_64-*-solaris*)
9731 LD="${LD-ld} -m elf_x86_64"
9732 ;;
9733 sparc*-*-solaris*)
9734 LD="${LD-ld} -m elf64_sparc"
9735 ;;
9736 esac
9737 # GNU ld 2.21 introduced _sol2 emulations. Use them if available.
9738 if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then
9739 LD=${LD-ld}_sol2
9740 fi
9741 ;;
9742 *)
9743 if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
9744 LD="${LD-ld} -64"
9745 fi
9746 ;;
9747 esac
9748 ;;
9749 esac
9750 fi
9751 rm -rf conftest*
9752 ;;
9753esac
9754
9755need_locks=$enable_libtool_lock
9756
9757if test -n "$ac_tool_prefix"; then
9758 # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args.
9759set dummy ${ac_tool_prefix}mt; ac_word=$2
9760{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9761$as_echo_n "checking for $ac_word... " >&6; }
9762if ${ac_cv_prog_MANIFEST_TOOL+:} false; then :
9763 $as_echo_n "(cached) " >&6
9764else
9765 if test -n "$MANIFEST_TOOL"; then
9766 ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test.
9767else
9768as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9769for as_dir in $PATH
9770do
9771 IFS=$as_save_IFS
9772 test -z "$as_dir" && as_dir=.
9773 for ac_exec_ext in '' $ac_executable_extensions; do
9774 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9775 ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt"
9776 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9777 break 2
9778 fi
9779done
9780 done
9781IFS=$as_save_IFS
9782
9783fi
9784fi
9785MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL
9786if test -n "$MANIFEST_TOOL"; then
9787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5
9788$as_echo "$MANIFEST_TOOL" >&6; }
9789else
9790 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9791$as_echo "no" >&6; }
9792fi
9793
9794
9795fi
9796if test -z "$ac_cv_prog_MANIFEST_TOOL"; then
9797 ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL
9798 # Extract the first word of "mt", so it can be a program name with args.
9799set dummy mt; ac_word=$2
9800{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9801$as_echo_n "checking for $ac_word... " >&6; }
9802if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then :
9803 $as_echo_n "(cached) " >&6
9804else
9805 if test -n "$ac_ct_MANIFEST_TOOL"; then
9806 ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test.
9807else
9808as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9809for as_dir in $PATH
9810do
9811 IFS=$as_save_IFS
9812 test -z "$as_dir" && as_dir=.
9813 for ac_exec_ext in '' $ac_executable_extensions; do
9814 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9815 ac_cv_prog_ac_ct_MANIFEST_TOOL="mt"
9816 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9817 break 2
9818 fi
9819done
9820 done
9821IFS=$as_save_IFS
9822
9823fi
9824fi
9825ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL
9826if test -n "$ac_ct_MANIFEST_TOOL"; then
9827 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5
9828$as_echo "$ac_ct_MANIFEST_TOOL" >&6; }
9829else
9830 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9831$as_echo "no" >&6; }
9832fi
9833
9834 if test "x$ac_ct_MANIFEST_TOOL" = x; then
9835 MANIFEST_TOOL=":"
9836 else
9837 case $cross_compiling:$ac_tool_warned in
9838yes:)
9839{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9840$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9841ac_tool_warned=yes ;;
9842esac
9843 MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL
9844 fi
9845else
9846 MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL"
9847fi
9848
9849test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
9850{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5
9851$as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; }
9852if ${lt_cv_path_mainfest_tool+:} false; then :
9853 $as_echo_n "(cached) " >&6
9854else
9855 lt_cv_path_mainfest_tool=no
9856 echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5
9857 $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
9858 cat conftest.err >&5
9859 if $GREP 'Manifest Tool' conftest.out > /dev/null; then
9860 lt_cv_path_mainfest_tool=yes
9861 fi
9862 rm -f conftest*
9863fi
9864{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5
9865$as_echo "$lt_cv_path_mainfest_tool" >&6; }
9866if test yes != "$lt_cv_path_mainfest_tool"; then
9867 MANIFEST_TOOL=:
9868fi
9869
9870
9871
9872
9873
9874
9875 case $host_os in
9876 rhapsody* | darwin*)
9877 if test -n "$ac_tool_prefix"; then
9878 # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args.
9879set dummy ${ac_tool_prefix}dsymutil; ac_word=$2
9880{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9881$as_echo_n "checking for $ac_word... " >&6; }
9882if ${ac_cv_prog_DSYMUTIL+:} false; then :
9883 $as_echo_n "(cached) " >&6
9884else
9885 if test -n "$DSYMUTIL"; then
9886 ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
9887else
9888as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9889for as_dir in $PATH
9890do
9891 IFS=$as_save_IFS
9892 test -z "$as_dir" && as_dir=.
9893 for ac_exec_ext in '' $ac_executable_extensions; do
9894 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9895 ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil"
9896 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9897 break 2
9898 fi
9899done
9900 done
9901IFS=$as_save_IFS
9902
9903fi
9904fi
9905DSYMUTIL=$ac_cv_prog_DSYMUTIL
9906if test -n "$DSYMUTIL"; then
9907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
9908$as_echo "$DSYMUTIL" >&6; }
9909else
9910 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9911$as_echo "no" >&6; }
9912fi
9913
9914
9915fi
9916if test -z "$ac_cv_prog_DSYMUTIL"; then
9917 ac_ct_DSYMUTIL=$DSYMUTIL
9918 # Extract the first word of "dsymutil", so it can be a program name with args.
9919set dummy dsymutil; ac_word=$2
9920{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9921$as_echo_n "checking for $ac_word... " >&6; }
9922if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then :
9923 $as_echo_n "(cached) " >&6
9924else
9925 if test -n "$ac_ct_DSYMUTIL"; then
9926 ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test.
9927else
9928as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9929for as_dir in $PATH
9930do
9931 IFS=$as_save_IFS
9932 test -z "$as_dir" && as_dir=.
9933 for ac_exec_ext in '' $ac_executable_extensions; do
9934 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9935 ac_cv_prog_ac_ct_DSYMUTIL="dsymutil"
9936 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9937 break 2
9938 fi
9939done
9940 done
9941IFS=$as_save_IFS
9942
9943fi
9944fi
9945ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL
9946if test -n "$ac_ct_DSYMUTIL"; then
9947 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5
9948$as_echo "$ac_ct_DSYMUTIL" >&6; }
9949else
9950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9951$as_echo "no" >&6; }
9952fi
9953
9954 if test "x$ac_ct_DSYMUTIL" = x; then
9955 DSYMUTIL=":"
9956 else
9957 case $cross_compiling:$ac_tool_warned in
9958yes:)
9959{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
9960$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
9961ac_tool_warned=yes ;;
9962esac
9963 DSYMUTIL=$ac_ct_DSYMUTIL
9964 fi
9965else
9966 DSYMUTIL="$ac_cv_prog_DSYMUTIL"
9967fi
9968
9969 if test -n "$ac_tool_prefix"; then
9970 # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args.
9971set dummy ${ac_tool_prefix}nmedit; ac_word=$2
9972{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9973$as_echo_n "checking for $ac_word... " >&6; }
9974if ${ac_cv_prog_NMEDIT+:} false; then :
9975 $as_echo_n "(cached) " >&6
9976else
9977 if test -n "$NMEDIT"; then
9978 ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test.
9979else
9980as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9981for as_dir in $PATH
9982do
9983 IFS=$as_save_IFS
9984 test -z "$as_dir" && as_dir=.
9985 for ac_exec_ext in '' $ac_executable_extensions; do
9986 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
9987 ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit"
9988 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9989 break 2
9990 fi
9991done
9992 done
9993IFS=$as_save_IFS
9994
9995fi
9996fi
9997NMEDIT=$ac_cv_prog_NMEDIT
9998if test -n "$NMEDIT"; then
9999 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5
10000$as_echo "$NMEDIT" >&6; }
10001else
10002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10003$as_echo "no" >&6; }
10004fi
10005
10006
10007fi
10008if test -z "$ac_cv_prog_NMEDIT"; then
10009 ac_ct_NMEDIT=$NMEDIT
10010 # Extract the first word of "nmedit", so it can be a program name with args.
10011set dummy nmedit; ac_word=$2
10012{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10013$as_echo_n "checking for $ac_word... " >&6; }
10014if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then :
10015 $as_echo_n "(cached) " >&6
10016else
10017 if test -n "$ac_ct_NMEDIT"; then
10018 ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test.
10019else
10020as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10021for as_dir in $PATH
10022do
10023 IFS=$as_save_IFS
10024 test -z "$as_dir" && as_dir=.
10025 for ac_exec_ext in '' $ac_executable_extensions; do
10026 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10027 ac_cv_prog_ac_ct_NMEDIT="nmedit"
10028 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10029 break 2
10030 fi
10031done
10032 done
10033IFS=$as_save_IFS
10034
10035fi
10036fi
10037ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT
10038if test -n "$ac_ct_NMEDIT"; then
10039 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5
10040$as_echo "$ac_ct_NMEDIT" >&6; }
10041else
10042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10043$as_echo "no" >&6; }
10044fi
10045
10046 if test "x$ac_ct_NMEDIT" = x; then
10047 NMEDIT=":"
10048 else
10049 case $cross_compiling:$ac_tool_warned in
10050yes:)
10051{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
10052$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
10053ac_tool_warned=yes ;;
10054esac
10055 NMEDIT=$ac_ct_NMEDIT
10056 fi
10057else
10058 NMEDIT="$ac_cv_prog_NMEDIT"
10059fi
10060
10061 if test -n "$ac_tool_prefix"; then
10062 # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args.
10063set dummy ${ac_tool_prefix}lipo; ac_word=$2
10064{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10065$as_echo_n "checking for $ac_word... " >&6; }
10066if ${ac_cv_prog_LIPO+:} false; then :
10067 $as_echo_n "(cached) " >&6
10068else
10069 if test -n "$LIPO"; then
10070 ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
10071else
10072as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10073for as_dir in $PATH
10074do
10075 IFS=$as_save_IFS
10076 test -z "$as_dir" && as_dir=.
10077 for ac_exec_ext in '' $ac_executable_extensions; do
10078 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10079 ac_cv_prog_LIPO="${ac_tool_prefix}lipo"
10080 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10081 break 2
10082 fi
10083done
10084 done
10085IFS=$as_save_IFS
10086
10087fi
10088fi
10089LIPO=$ac_cv_prog_LIPO
10090if test -n "$LIPO"; then
10091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
10092$as_echo "$LIPO" >&6; }
10093else
10094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10095$as_echo "no" >&6; }
10096fi
10097
10098
10099fi
10100if test -z "$ac_cv_prog_LIPO"; then
10101 ac_ct_LIPO=$LIPO
10102 # Extract the first word of "lipo", so it can be a program name with args.
10103set dummy lipo; ac_word=$2
10104{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10105$as_echo_n "checking for $ac_word... " >&6; }
10106if ${ac_cv_prog_ac_ct_LIPO+:} false; then :
10107 $as_echo_n "(cached) " >&6
10108else
10109 if test -n "$ac_ct_LIPO"; then
10110 ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test.
10111else
10112as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10113for as_dir in $PATH
10114do
10115 IFS=$as_save_IFS
10116 test -z "$as_dir" && as_dir=.
10117 for ac_exec_ext in '' $ac_executable_extensions; do
10118 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10119 ac_cv_prog_ac_ct_LIPO="lipo"
10120 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10121 break 2
10122 fi
10123done
10124 done
10125IFS=$as_save_IFS
10126
10127fi
10128fi
10129ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO
10130if test -n "$ac_ct_LIPO"; then
10131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5
10132$as_echo "$ac_ct_LIPO" >&6; }
10133else
10134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10135$as_echo "no" >&6; }
10136fi
10137
10138 if test "x$ac_ct_LIPO" = x; then
10139 LIPO=":"
10140 else
10141 case $cross_compiling:$ac_tool_warned in
10142yes:)
10143{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
10144$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
10145ac_tool_warned=yes ;;
10146esac
10147 LIPO=$ac_ct_LIPO
10148 fi
10149else
10150 LIPO="$ac_cv_prog_LIPO"
10151fi
10152
10153 if test -n "$ac_tool_prefix"; then
10154 # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args.
10155set dummy ${ac_tool_prefix}otool; ac_word=$2
10156{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10157$as_echo_n "checking for $ac_word... " >&6; }
10158if ${ac_cv_prog_OTOOL+:} false; then :
10159 $as_echo_n "(cached) " >&6
10160else
10161 if test -n "$OTOOL"; then
10162 ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
10163else
10164as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10165for as_dir in $PATH
10166do
10167 IFS=$as_save_IFS
10168 test -z "$as_dir" && as_dir=.
10169 for ac_exec_ext in '' $ac_executable_extensions; do
10170 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10171 ac_cv_prog_OTOOL="${ac_tool_prefix}otool"
10172 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10173 break 2
10174 fi
10175done
10176 done
10177IFS=$as_save_IFS
10178
10179fi
10180fi
10181OTOOL=$ac_cv_prog_OTOOL
10182if test -n "$OTOOL"; then
10183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
10184$as_echo "$OTOOL" >&6; }
10185else
10186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10187$as_echo "no" >&6; }
10188fi
10189
10190
10191fi
10192if test -z "$ac_cv_prog_OTOOL"; then
10193 ac_ct_OTOOL=$OTOOL
10194 # Extract the first word of "otool", so it can be a program name with args.
10195set dummy otool; ac_word=$2
10196{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10197$as_echo_n "checking for $ac_word... " >&6; }
10198if ${ac_cv_prog_ac_ct_OTOOL+:} false; then :
10199 $as_echo_n "(cached) " >&6
10200else
10201 if test -n "$ac_ct_OTOOL"; then
10202 ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test.
10203else
10204as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10205for as_dir in $PATH
10206do
10207 IFS=$as_save_IFS
10208 test -z "$as_dir" && as_dir=.
10209 for ac_exec_ext in '' $ac_executable_extensions; do
10210 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10211 ac_cv_prog_ac_ct_OTOOL="otool"
10212 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10213 break 2
10214 fi
10215done
10216 done
10217IFS=$as_save_IFS
10218
10219fi
10220fi
10221ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL
10222if test -n "$ac_ct_OTOOL"; then
10223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5
10224$as_echo "$ac_ct_OTOOL" >&6; }
10225else
10226 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10227$as_echo "no" >&6; }
10228fi
10229
10230 if test "x$ac_ct_OTOOL" = x; then
10231 OTOOL=":"
10232 else
10233 case $cross_compiling:$ac_tool_warned in
10234yes:)
10235{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
10236$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
10237ac_tool_warned=yes ;;
10238esac
10239 OTOOL=$ac_ct_OTOOL
10240 fi
10241else
10242 OTOOL="$ac_cv_prog_OTOOL"
10243fi
10244
10245 if test -n "$ac_tool_prefix"; then
10246 # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args.
10247set dummy ${ac_tool_prefix}otool64; ac_word=$2
10248{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10249$as_echo_n "checking for $ac_word... " >&6; }
10250if ${ac_cv_prog_OTOOL64+:} false; then :
10251 $as_echo_n "(cached) " >&6
10252else
10253 if test -n "$OTOOL64"; then
10254 ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test.
10255else
10256as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10257for as_dir in $PATH
10258do
10259 IFS=$as_save_IFS
10260 test -z "$as_dir" && as_dir=.
10261 for ac_exec_ext in '' $ac_executable_extensions; do
10262 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10263 ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64"
10264 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10265 break 2
10266 fi
10267done
10268 done
10269IFS=$as_save_IFS
10270
10271fi
10272fi
10273OTOOL64=$ac_cv_prog_OTOOL64
10274if test -n "$OTOOL64"; then
10275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5
10276$as_echo "$OTOOL64" >&6; }
10277else
10278 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10279$as_echo "no" >&6; }
10280fi
10281
10282
10283fi
10284if test -z "$ac_cv_prog_OTOOL64"; then
10285 ac_ct_OTOOL64=$OTOOL64
10286 # Extract the first word of "otool64", so it can be a program name with args.
10287set dummy otool64; ac_word=$2
10288{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10289$as_echo_n "checking for $ac_word... " >&6; }
10290if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then :
10291 $as_echo_n "(cached) " >&6
10292else
10293 if test -n "$ac_ct_OTOOL64"; then
10294 ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test.
10295else
10296as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10297for as_dir in $PATH
10298do
10299 IFS=$as_save_IFS
10300 test -z "$as_dir" && as_dir=.
10301 for ac_exec_ext in '' $ac_executable_extensions; do
10302 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10303 ac_cv_prog_ac_ct_OTOOL64="otool64"
10304 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10305 break 2
10306 fi
10307done
10308 done
10309IFS=$as_save_IFS
10310
10311fi
10312fi
10313ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64
10314if test -n "$ac_ct_OTOOL64"; then
10315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5
10316$as_echo "$ac_ct_OTOOL64" >&6; }
10317else
10318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10319$as_echo "no" >&6; }
10320fi
10321
10322 if test "x$ac_ct_OTOOL64" = x; then
10323 OTOOL64=":"
10324 else
10325 case $cross_compiling:$ac_tool_warned in
10326yes:)
10327{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
10328$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
10329ac_tool_warned=yes ;;
10330esac
10331 OTOOL64=$ac_ct_OTOOL64
10332 fi
10333else
10334 OTOOL64="$ac_cv_prog_OTOOL64"
10335fi
10336
10337
10338
10339
10340
10341
10342
10343
10344
10345
10346
10347
10348
10349
10350
10351
10352
10353
10354
10355
10356
10357
10358
10359
10360
10361
10362
10363 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5
10364$as_echo_n "checking for -single_module linker flag... " >&6; }
10365if ${lt_cv_apple_cc_single_mod+:} false; then :
10366 $as_echo_n "(cached) " >&6
10367else
10368 lt_cv_apple_cc_single_mod=no
10369 if test -z "$LT_MULTI_MODULE"; then
10370 # By default we will add the -single_module flag. You can override
10371 # by either setting the environment variable LT_MULTI_MODULE
10372 # non-empty at configure time, or by adding -multi_module to the
10373 # link flags.
10374 rm -rf libconftest.dylib*
10375 echo "int foo(void){return 1;}" > conftest.c
10376 echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
10377-dynamiclib -Wl,-single_module conftest.c" >&5
10378 $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
10379 -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
10380 _lt_result=$?
10381 # If there is a non-empty error log, and "single_module"
10382 # appears in it, assume the flag caused a linker warning
10383 if test -s conftest.err && $GREP single_module conftest.err; then
10384 cat conftest.err >&5
10385 # Otherwise, if the output was created with a 0 exit code from
10386 # the compiler, it worked.
10387 elif test -f libconftest.dylib && test 0 = "$_lt_result"; then
10388 lt_cv_apple_cc_single_mod=yes
10389 else
10390 cat conftest.err >&5
10391 fi
10392 rm -rf libconftest.dylib*
10393 rm -f conftest.*
10394 fi
10395fi
10396{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5
10397$as_echo "$lt_cv_apple_cc_single_mod" >&6; }
10398
10399 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5
10400$as_echo_n "checking for -exported_symbols_list linker flag... " >&6; }
10401if ${lt_cv_ld_exported_symbols_list+:} false; then :
10402 $as_echo_n "(cached) " >&6
10403else
10404 lt_cv_ld_exported_symbols_list=no
10405 save_LDFLAGS=$LDFLAGS
10406 echo "_main" > conftest.sym
10407 LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
10408 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10409/* end confdefs.h. */
10410
10411int main (void)
10412{
10413
10414 ;
10415 return 0;
10416}
10417_ACEOF
10418if ac_fn_c_try_link "$LINENO"; then :
10419 lt_cv_ld_exported_symbols_list=yes
10420else
10421 lt_cv_ld_exported_symbols_list=no
10422fi
10423rm -f core conftest.err conftest.$ac_objext \
10424 conftest$ac_exeext conftest.$ac_ext
10425 LDFLAGS=$save_LDFLAGS
10426
10427fi
10428{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5
10429$as_echo "$lt_cv_ld_exported_symbols_list" >&6; }
10430
10431 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5
10432$as_echo_n "checking for -force_load linker flag... " >&6; }
10433if ${lt_cv_ld_force_load+:} false; then :
10434 $as_echo_n "(cached) " >&6
10435else
10436 lt_cv_ld_force_load=no
10437 cat > conftest.c << _LT_EOF
10438int forced_loaded() { return 2;}
10439_LT_EOF
10440 echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5
10441 $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
10442 echo "$AR cru libconftest.a conftest.o" >&5
10443 $AR cru libconftest.a conftest.o 2>&5
10444 echo "$RANLIB libconftest.a" >&5
10445 $RANLIB libconftest.a 2>&5
10446 cat > conftest.c << _LT_EOF
10447int main() { return 0;}
10448_LT_EOF
10449 echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5
10450 $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
10451 _lt_result=$?
10452 if test -s conftest.err && $GREP force_load conftest.err; then
10453 cat conftest.err >&5
10454 elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then
10455 lt_cv_ld_force_load=yes
10456 else
10457 cat conftest.err >&5
10458 fi
10459 rm -f conftest.err libconftest.a conftest conftest.c
10460 rm -rf conftest.dSYM
10461
10462fi
10463{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5
10464$as_echo "$lt_cv_ld_force_load" >&6; }
10465 case $host_os in
10466 rhapsody* | darwin1.[012])
10467 _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;;
10468 darwin1.*)
10469 _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
10470 darwin*) # darwin 5.x on
10471 # if running on 10.5 or later, the deployment target defaults
10472 # to the OS version, if on x86, and 10.4, the deployment
10473 # target defaults to 10.4. Don't you love it?
10474 case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
10475 10.0,*86*-darwin8*|10.0,*-darwin[91]*)
10476 _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;;
10477 10.[012][,.]*)
10478 _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;;
10479 10.*)
10480 _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;;
10481 esac
10482 ;;
10483 esac
10484 if test yes = "$lt_cv_apple_cc_single_mod"; then
10485 _lt_dar_single_mod='$single_module'
10486 fi
10487 if test yes = "$lt_cv_ld_exported_symbols_list"; then
10488 _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym'
10489 else
10490 _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib'
10491 fi
10492 if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then
10493 _lt_dsymutil='~$DSYMUTIL $lib || :'
10494 else
10495 _lt_dsymutil=
10496 fi
10497 ;;
10498 esac
10499
10500# func_munge_path_list VARIABLE PATH
10501# -----------------------------------
10502# VARIABLE is name of variable containing _space_ separated list of
10503# directories to be munged by the contents of PATH, which is string
10504# having a format:
10505# "DIR[:DIR]:"
10506# string "DIR[ DIR]" will be prepended to VARIABLE
10507# ":DIR[:DIR]"
10508# string "DIR[ DIR]" will be appended to VARIABLE
10509# "DIRP[:DIRP]::[DIRA:]DIRA"
10510# string "DIRP[ DIRP]" will be prepended to VARIABLE and string
10511# "DIRA[ DIRA]" will be appended to VARIABLE
10512# "DIR[:DIR]"
10513# VARIABLE will be replaced by "DIR[ DIR]"
10514func_munge_path_list ()
10515{
10516 case x$2 in
10517 x)
10518 ;;
10519 *:)
10520 eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\"
10521 ;;
10522 x:*)
10523 eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\"
10524 ;;
10525 *::*)
10526 eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\"
10527 eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\"
10528 ;;
10529 *)
10530 eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\"
10531 ;;
10532 esac
10533}
10534
Alex Deymo486467e2017-12-19 19:04:07 +010010535{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
10536$as_echo_n "checking for ANSI C header files... " >&6; }
10537if ${ac_cv_header_stdc+:} false; then :
10538 $as_echo_n "(cached) " >&6
10539else
10540 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10541/* end confdefs.h. */
10542#include <stdlib.h>
10543#include <stdarg.h>
10544#include <string.h>
10545#include <float.h>
10546
10547int main (void)
10548{
10549
10550 ;
10551 return 0;
10552}
10553_ACEOF
10554if ac_fn_c_try_compile "$LINENO"; then :
10555 ac_cv_header_stdc=yes
10556else
10557 ac_cv_header_stdc=no
10558fi
10559rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10560
10561if test $ac_cv_header_stdc = yes; then
10562 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
10563 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10564/* end confdefs.h. */
10565#include <string.h>
10566
10567_ACEOF
10568if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10569 $EGREP "memchr" >/dev/null 2>&1; then :
10570
10571else
10572 ac_cv_header_stdc=no
10573fi
10574rm -f conftest*
10575
10576fi
10577
10578if test $ac_cv_header_stdc = yes; then
10579 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
10580 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10581/* end confdefs.h. */
10582#include <stdlib.h>
10583
10584_ACEOF
10585if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10586 $EGREP "free" >/dev/null 2>&1; then :
10587
10588else
10589 ac_cv_header_stdc=no
10590fi
10591rm -f conftest*
10592
10593fi
10594
10595if test $ac_cv_header_stdc = yes; then
10596 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
10597 if test "$cross_compiling" = yes; then :
10598 :
10599else
10600 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10601/* end confdefs.h. */
10602#include <ctype.h>
10603#include <stdlib.h>
10604#if ((' ' & 0x0FF) == 0x020)
10605# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
10606# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
10607#else
10608# define ISLOWER(c) \
10609 (('a' <= (c) && (c) <= 'i') \
10610 || ('j' <= (c) && (c) <= 'r') \
10611 || ('s' <= (c) && (c) <= 'z'))
10612# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
10613#endif
10614
10615#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
10616int
10617main ()
10618{
10619 int i;
10620 for (i = 0; i < 256; i++)
10621 if (XOR (islower (i), ISLOWER (i))
10622 || toupper (i) != TOUPPER (i))
10623 return 2;
10624 return 0;
10625}
10626_ACEOF
10627if ac_fn_c_try_run "$LINENO"; then :
10628
10629else
10630 ac_cv_header_stdc=no
10631fi
10632rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10633 conftest.$ac_objext conftest.beam conftest.$ac_ext
10634fi
10635
10636fi
10637fi
10638{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
10639$as_echo "$ac_cv_header_stdc" >&6; }
10640if test $ac_cv_header_stdc = yes; then
10641
10642$as_echo "#define STDC_HEADERS 1" >>confdefs.h
10643
10644fi
10645
10646# On IRIX 5.3, sys/types and inttypes.h are conflicting.
10647for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
10648 inttypes.h stdint.h unistd.h
10649do :
10650 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10651ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
10652"
10653if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
10654 cat >>confdefs.h <<_ACEOF
10655#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10656_ACEOF
10657
10658fi
10659
10660done
10661
10662
Elliott Hughes82be86d2017-09-20 17:00:17 -070010663for ac_header in dlfcn.h
10664do :
10665 ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
10666"
10667if test "x$ac_cv_header_dlfcn_h" = xyes; then :
10668 cat >>confdefs.h <<_ACEOF
10669#define HAVE_DLFCN_H 1
10670_ACEOF
10671
10672fi
10673
10674done
10675
10676# ------------------------------------ #
10677# Determine libtool default behavior #
10678# ------------------------------------ #
10679
10680#
10681# Default behavior is to enable shared and static libraries on systems
10682# where libtool knows how to build both library versions, and does not
10683# require separate configuration and build runs for each flavor.
10684#
10685
10686xc_lt_want_enable_shared='yes'
10687xc_lt_want_enable_static='yes'
10688
10689#
10690# User may have disabled shared or static libraries.
10691#
10692case "x$enable_shared" in # (
10693 xno)
10694 xc_lt_want_enable_shared='no'
10695 ;;
10696esac
10697case "x$enable_static" in # (
10698 xno)
10699 xc_lt_want_enable_static='no'
10700 ;;
10701esac
10702if test "x$xc_lt_want_enable_shared" = 'xno' &&
10703 test "x$xc_lt_want_enable_static" = 'xno'; then
10704 as_fn_error $? "can not disable shared and static libraries simultaneously" "$LINENO" 5
10705fi
10706
10707#
10708# Default behavior on systems that require independent configuration
10709# and build runs for shared and static is to enable shared libraries
10710# and disable static ones. On these systems option '--disable-shared'
10711# must be used in order to build a proper static library.
10712#
10713
10714if test "x$xc_lt_want_enable_shared" = 'xyes' &&
10715 test "x$xc_lt_want_enable_static" = 'xyes'; then
10716 case $host_os in # (
10717 pw32* | cegcc* | os2* | aix*)
10718 xc_lt_want_enable_static='no'
10719 ;;
10720 esac
10721fi
10722
10723#
10724# Make libtool aware of current shared and static library preferences
10725# taking in account that, depending on host characteristics, libtool
10726# may modify these option preferences later in this configure script.
10727#
10728
10729enable_shared=$xc_lt_want_enable_shared
10730enable_static=$xc_lt_want_enable_static
10731
10732#
10733# Default behavior is to build PIC objects for shared libraries and
10734# non-PIC objects for static libraries.
10735#
10736
10737xc_lt_want_with_pic='default'
10738
10739#
10740# User may have specified PIC preference.
10741#
10742
10743case "x$with_pic" in # ((
10744 xno)
10745 xc_lt_want_with_pic='no'
10746 ;;
10747 xyes)
10748 xc_lt_want_with_pic='yes'
10749 ;;
10750esac
10751
10752#
10753# Default behavior on some systems where building a shared library out
10754# of non-PIC compiled objects will fail with following linker error
10755# "relocation R_X86_64_32 can not be used when making a shared object"
10756# is to build PIC objects even for static libraries. This behavior may
10757# be overridden using 'configure --disable-shared --without-pic'.
10758#
10759
10760if test "x$xc_lt_want_with_pic" = 'xdefault'; then
10761 case $host_cpu in # (
10762 x86_64 | amd64 | ia64)
10763 case $host_os in # (
10764 linux* | freebsd*)
10765 xc_lt_want_with_pic='yes'
10766 ;;
10767 esac
10768 ;;
10769 esac
10770fi
10771
10772#
10773# Make libtool aware of current PIC preference taking in account that,
10774# depending on host characteristics, libtool may modify PIC default
10775# behavior to fit host system idiosyncrasies later in this script.
10776#
10777
10778with_pic=$xc_lt_want_with_pic
10779
10780## ----------------------- ##
10781## Start of libtool code ##
10782## ----------------------- ##
10783
10784
10785
10786
10787# Set options
10788enable_win32_dll=yes
10789
10790case $host in
10791*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*)
10792 if test -n "$ac_tool_prefix"; then
10793 # Extract the first word of "${ac_tool_prefix}as", so it can be a program name with args.
10794set dummy ${ac_tool_prefix}as; ac_word=$2
10795{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10796$as_echo_n "checking for $ac_word... " >&6; }
10797if ${ac_cv_prog_AS+:} false; then :
10798 $as_echo_n "(cached) " >&6
10799else
10800 if test -n "$AS"; then
10801 ac_cv_prog_AS="$AS" # Let the user override the test.
10802else
10803as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10804for as_dir in $PATH
10805do
10806 IFS=$as_save_IFS
10807 test -z "$as_dir" && as_dir=.
10808 for ac_exec_ext in '' $ac_executable_extensions; do
10809 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10810 ac_cv_prog_AS="${ac_tool_prefix}as"
10811 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10812 break 2
10813 fi
10814done
10815 done
10816IFS=$as_save_IFS
10817
10818fi
10819fi
10820AS=$ac_cv_prog_AS
10821if test -n "$AS"; then
10822 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
10823$as_echo "$AS" >&6; }
10824else
10825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10826$as_echo "no" >&6; }
10827fi
10828
10829
10830fi
10831if test -z "$ac_cv_prog_AS"; then
10832 ac_ct_AS=$AS
10833 # Extract the first word of "as", so it can be a program name with args.
10834set dummy as; ac_word=$2
10835{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10836$as_echo_n "checking for $ac_word... " >&6; }
10837if ${ac_cv_prog_ac_ct_AS+:} false; then :
10838 $as_echo_n "(cached) " >&6
10839else
10840 if test -n "$ac_ct_AS"; then
10841 ac_cv_prog_ac_ct_AS="$ac_ct_AS" # Let the user override the test.
10842else
10843as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10844for as_dir in $PATH
10845do
10846 IFS=$as_save_IFS
10847 test -z "$as_dir" && as_dir=.
10848 for ac_exec_ext in '' $ac_executable_extensions; do
10849 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10850 ac_cv_prog_ac_ct_AS="as"
10851 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10852 break 2
10853 fi
10854done
10855 done
10856IFS=$as_save_IFS
10857
10858fi
10859fi
10860ac_ct_AS=$ac_cv_prog_ac_ct_AS
10861if test -n "$ac_ct_AS"; then
10862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AS" >&5
10863$as_echo "$ac_ct_AS" >&6; }
10864else
10865 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10866$as_echo "no" >&6; }
10867fi
10868
10869 if test "x$ac_ct_AS" = x; then
10870 AS="false"
10871 else
10872 case $cross_compiling:$ac_tool_warned in
10873yes:)
10874{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
10875$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
10876ac_tool_warned=yes ;;
10877esac
10878 AS=$ac_ct_AS
10879 fi
10880else
10881 AS="$ac_cv_prog_AS"
10882fi
10883
10884 if test -n "$ac_tool_prefix"; then
10885 # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
10886set dummy ${ac_tool_prefix}dlltool; ac_word=$2
10887{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10888$as_echo_n "checking for $ac_word... " >&6; }
10889if ${ac_cv_prog_DLLTOOL+:} false; then :
10890 $as_echo_n "(cached) " >&6
10891else
10892 if test -n "$DLLTOOL"; then
10893 ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
10894else
10895as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10896for as_dir in $PATH
10897do
10898 IFS=$as_save_IFS
10899 test -z "$as_dir" && as_dir=.
10900 for ac_exec_ext in '' $ac_executable_extensions; do
10901 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10902 ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
10903 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10904 break 2
10905 fi
10906done
10907 done
10908IFS=$as_save_IFS
10909
10910fi
10911fi
10912DLLTOOL=$ac_cv_prog_DLLTOOL
10913if test -n "$DLLTOOL"; then
10914 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
10915$as_echo "$DLLTOOL" >&6; }
10916else
10917 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10918$as_echo "no" >&6; }
10919fi
10920
10921
10922fi
10923if test -z "$ac_cv_prog_DLLTOOL"; then
10924 ac_ct_DLLTOOL=$DLLTOOL
10925 # Extract the first word of "dlltool", so it can be a program name with args.
10926set dummy dlltool; ac_word=$2
10927{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10928$as_echo_n "checking for $ac_word... " >&6; }
10929if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
10930 $as_echo_n "(cached) " >&6
10931else
10932 if test -n "$ac_ct_DLLTOOL"; then
10933 ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
10934else
10935as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10936for as_dir in $PATH
10937do
10938 IFS=$as_save_IFS
10939 test -z "$as_dir" && as_dir=.
10940 for ac_exec_ext in '' $ac_executable_extensions; do
10941 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10942 ac_cv_prog_ac_ct_DLLTOOL="dlltool"
10943 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10944 break 2
10945 fi
10946done
10947 done
10948IFS=$as_save_IFS
10949
10950fi
10951fi
10952ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
10953if test -n "$ac_ct_DLLTOOL"; then
10954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
10955$as_echo "$ac_ct_DLLTOOL" >&6; }
10956else
10957 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10958$as_echo "no" >&6; }
10959fi
10960
10961 if test "x$ac_ct_DLLTOOL" = x; then
10962 DLLTOOL="false"
10963 else
10964 case $cross_compiling:$ac_tool_warned in
10965yes:)
10966{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
10967$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
10968ac_tool_warned=yes ;;
10969esac
10970 DLLTOOL=$ac_ct_DLLTOOL
10971 fi
10972else
10973 DLLTOOL="$ac_cv_prog_DLLTOOL"
10974fi
10975
10976 if test -n "$ac_tool_prefix"; then
10977 # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
10978set dummy ${ac_tool_prefix}objdump; ac_word=$2
10979{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10980$as_echo_n "checking for $ac_word... " >&6; }
10981if ${ac_cv_prog_OBJDUMP+:} false; then :
10982 $as_echo_n "(cached) " >&6
10983else
10984 if test -n "$OBJDUMP"; then
10985 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
10986else
10987as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10988for as_dir in $PATH
10989do
10990 IFS=$as_save_IFS
10991 test -z "$as_dir" && as_dir=.
10992 for ac_exec_ext in '' $ac_executable_extensions; do
10993 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
10994 ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
10995 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10996 break 2
10997 fi
10998done
10999 done
11000IFS=$as_save_IFS
11001
11002fi
11003fi
11004OBJDUMP=$ac_cv_prog_OBJDUMP
11005if test -n "$OBJDUMP"; then
11006 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
11007$as_echo "$OBJDUMP" >&6; }
11008else
11009 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11010$as_echo "no" >&6; }
11011fi
11012
11013
11014fi
11015if test -z "$ac_cv_prog_OBJDUMP"; then
11016 ac_ct_OBJDUMP=$OBJDUMP
11017 # Extract the first word of "objdump", so it can be a program name with args.
11018set dummy objdump; ac_word=$2
11019{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11020$as_echo_n "checking for $ac_word... " >&6; }
11021if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
11022 $as_echo_n "(cached) " >&6
11023else
11024 if test -n "$ac_ct_OBJDUMP"; then
11025 ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
11026else
11027as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11028for as_dir in $PATH
11029do
11030 IFS=$as_save_IFS
11031 test -z "$as_dir" && as_dir=.
11032 for ac_exec_ext in '' $ac_executable_extensions; do
11033 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
11034 ac_cv_prog_ac_ct_OBJDUMP="objdump"
11035 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11036 break 2
11037 fi
11038done
11039 done
11040IFS=$as_save_IFS
11041
11042fi
11043fi
11044ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
11045if test -n "$ac_ct_OBJDUMP"; then
11046 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
11047$as_echo "$ac_ct_OBJDUMP" >&6; }
11048else
11049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11050$as_echo "no" >&6; }
11051fi
11052
11053 if test "x$ac_ct_OBJDUMP" = x; then
11054 OBJDUMP="false"
11055 else
11056 case $cross_compiling:$ac_tool_warned in
11057yes:)
11058{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
11059$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
11060ac_tool_warned=yes ;;
11061esac
11062 OBJDUMP=$ac_ct_OBJDUMP
11063 fi
11064else
11065 OBJDUMP="$ac_cv_prog_OBJDUMP"
11066fi
11067
11068 ;;
11069esac
11070
11071test -z "$AS" && AS=as
11072
11073
11074
11075
11076
11077test -z "$DLLTOOL" && DLLTOOL=dlltool
11078
11079
11080
11081
11082
11083test -z "$OBJDUMP" && OBJDUMP=objdump
11084
11085
11086
11087
11088
11089
11090
11091 enable_dlopen=no
11092
11093
11094
11095 # Check whether --enable-shared was given.
11096if test "${enable_shared+set}" = set; then :
11097 enableval=$enable_shared; p=${PACKAGE-default}
11098 case $enableval in
11099 yes) enable_shared=yes ;;
11100 no) enable_shared=no ;;
11101 *)
11102 enable_shared=no
11103 # Look at the argument we got. We use all the common list separators.
11104 lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
11105 for pkg in $enableval; do
11106 IFS=$lt_save_ifs
11107 if test "X$pkg" = "X$p"; then
11108 enable_shared=yes
11109 fi
11110 done
11111 IFS=$lt_save_ifs
11112 ;;
11113 esac
11114else
11115 enable_shared=yes
11116fi
11117
11118
11119
11120
11121
11122
11123
11124
11125
11126 # Check whether --enable-static was given.
11127if test "${enable_static+set}" = set; then :
11128 enableval=$enable_static; p=${PACKAGE-default}
11129 case $enableval in
11130 yes) enable_static=yes ;;
11131 no) enable_static=no ;;
11132 *)
11133 enable_static=no
11134 # Look at the argument we got. We use all the common list separators.
11135 lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
11136 for pkg in $enableval; do
11137 IFS=$lt_save_ifs
11138 if test "X$pkg" = "X$p"; then
11139 enable_static=yes
11140 fi
11141 done
11142 IFS=$lt_save_ifs
11143 ;;
11144 esac
11145else
11146 enable_static=yes
11147fi
11148
11149
11150
11151
11152
11153
11154
11155
11156
11157
11158# Check whether --with-pic was given.
11159if test "${with_pic+set}" = set; then :
11160 withval=$with_pic; lt_p=${PACKAGE-default}
11161 case $withval in
11162 yes|no) pic_mode=$withval ;;
11163 *)
11164 pic_mode=default
11165 # Look at the argument we got. We use all the common list separators.
11166 lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
11167 for lt_pkg in $withval; do
11168 IFS=$lt_save_ifs
11169 if test "X$lt_pkg" = "X$lt_p"; then
11170 pic_mode=yes
11171 fi
11172 done
11173 IFS=$lt_save_ifs
11174 ;;
11175 esac
11176else
11177 pic_mode=default
11178fi
11179
11180
11181
11182
11183
11184
11185
11186
11187 # Check whether --enable-fast-install was given.
11188if test "${enable_fast_install+set}" = set; then :
11189 enableval=$enable_fast_install; p=${PACKAGE-default}
11190 case $enableval in
11191 yes) enable_fast_install=yes ;;
11192 no) enable_fast_install=no ;;
11193 *)
11194 enable_fast_install=no
11195 # Look at the argument we got. We use all the common list separators.
11196 lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR,
11197 for pkg in $enableval; do
11198 IFS=$lt_save_ifs
11199 if test "X$pkg" = "X$p"; then
11200 enable_fast_install=yes
11201 fi
11202 done
11203 IFS=$lt_save_ifs
11204 ;;
11205 esac
11206else
11207 enable_fast_install=yes
11208fi
11209
11210
11211
11212
11213
11214
11215
11216
11217 shared_archive_member_spec=
11218case $host,$enable_shared in
11219power*-*-aix[5-9]*,yes)
11220 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of shared library versioning to provide" >&5
11221$as_echo_n "checking which variant of shared library versioning to provide... " >&6; }
11222
11223# Check whether --with-aix-soname was given.
11224if test "${with_aix_soname+set}" = set; then :
11225 withval=$with_aix_soname; case $withval in
11226 aix|svr4|both)
11227 ;;
11228 *)
11229 as_fn_error $? "Unknown argument to --with-aix-soname" "$LINENO" 5
11230 ;;
11231 esac
11232 lt_cv_with_aix_soname=$with_aix_soname
11233else
11234 if ${lt_cv_with_aix_soname+:} false; then :
11235 $as_echo_n "(cached) " >&6
11236else
11237 lt_cv_with_aix_soname=aix
11238fi
11239
11240 with_aix_soname=$lt_cv_with_aix_soname
11241fi
11242
11243 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_aix_soname" >&5
11244$as_echo "$with_aix_soname" >&6; }
11245 if test aix != "$with_aix_soname"; then
11246 # For the AIX way of multilib, we name the shared archive member
11247 # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o',
11248 # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File.
11249 # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag,
11250 # the AIX toolchain works better with OBJECT_MODE set (default 32).
11251 if test 64 = "${OBJECT_MODE-32}"; then
11252 shared_archive_member_spec=shr_64
11253 else
11254 shared_archive_member_spec=shr
11255 fi
11256 fi
11257 ;;
11258*)
11259 with_aix_soname=aix
11260 ;;
11261esac
11262
11263
11264
11265
11266
11267
11268
11269
11270
11271
11272# This can be used to rebuild libtool when needed
11273LIBTOOL_DEPS=$ltmain
11274
11275# Always use our own libtool.
11276LIBTOOL='$(SHELL) $(top_builddir)/libtool'
11277
11278
11279
11280
11281
11282
11283
11284
11285
11286
11287
11288
11289
11290
11291
11292
11293
11294
11295
11296
11297
11298
11299
11300
11301
11302
11303
11304
11305
11306
11307test -z "$LN_S" && LN_S="ln -s"
11308
11309
11310
11311
11312
11313
11314
11315
11316
11317
11318
11319
11320
11321
11322if test -n "${ZSH_VERSION+set}"; then
11323 setopt NO_GLOB_SUBST
11324fi
11325
11326{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5
11327$as_echo_n "checking for objdir... " >&6; }
11328if ${lt_cv_objdir+:} false; then :
11329 $as_echo_n "(cached) " >&6
11330else
11331 rm -f .libs 2>/dev/null
11332mkdir .libs 2>/dev/null
11333if test -d .libs; then
11334 lt_cv_objdir=.libs
11335else
11336 # MS-DOS does not allow filenames that begin with a dot.
11337 lt_cv_objdir=_libs
11338fi
11339rmdir .libs 2>/dev/null
11340fi
11341{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5
11342$as_echo "$lt_cv_objdir" >&6; }
11343objdir=$lt_cv_objdir
11344
11345
11346
11347
11348
11349cat >>confdefs.h <<_ACEOF
11350#define LT_OBJDIR "$lt_cv_objdir/"
11351_ACEOF
11352
11353
11354
11355
11356case $host_os in
11357aix3*)
11358 # AIX sometimes has problems with the GCC collect2 program. For some
11359 # reason, if we set the COLLECT_NAMES environment variable, the problems
11360 # vanish in a puff of smoke.
11361 if test set != "${COLLECT_NAMES+set}"; then
11362 COLLECT_NAMES=
11363 export COLLECT_NAMES
11364 fi
11365 ;;
11366esac
11367
11368# Global variables:
11369ofile=libtool
11370can_build_shared=yes
11371
11372# All known linkers require a '.a' archive for static linking (except MSVC,
11373# which needs '.lib').
11374libext=a
11375
11376with_gnu_ld=$lt_cv_prog_gnu_ld
11377
11378old_CC=$CC
11379old_CFLAGS=$CFLAGS
11380
11381# Set sane defaults for various variables
11382test -z "$CC" && CC=cc
11383test -z "$LTCC" && LTCC=$CC
11384test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
11385test -z "$LD" && LD=ld
11386test -z "$ac_objext" && ac_objext=o
11387
11388func_cc_basename $compiler
11389cc_basename=$func_cc_basename_result
11390
11391
11392# Only perform the check for file, if the check method requires it
11393test -z "$MAGIC_CMD" && MAGIC_CMD=file
11394case $deplibs_check_method in
11395file_magic*)
11396 if test "$file_magic_cmd" = '$MAGIC_CMD'; then
11397 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5
11398$as_echo_n "checking for ${ac_tool_prefix}file... " >&6; }
11399if ${lt_cv_path_MAGIC_CMD+:} false; then :
11400 $as_echo_n "(cached) " >&6
11401else
11402 case $MAGIC_CMD in
11403[\\/*] | ?:[\\/]*)
11404 lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path.
11405 ;;
11406*)
11407 lt_save_MAGIC_CMD=$MAGIC_CMD
11408 lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
11409 ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
11410 for ac_dir in $ac_dummy; do
11411 IFS=$lt_save_ifs
11412 test -z "$ac_dir" && ac_dir=.
11413 if test -f "$ac_dir/${ac_tool_prefix}file"; then
11414 lt_cv_path_MAGIC_CMD=$ac_dir/"${ac_tool_prefix}file"
11415 if test -n "$file_magic_test_file"; then
11416 case $deplibs_check_method in
11417 "file_magic "*)
11418 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
11419 MAGIC_CMD=$lt_cv_path_MAGIC_CMD
11420 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
11421 $EGREP "$file_magic_regex" > /dev/null; then
11422 :
11423 else
11424 cat <<_LT_EOF 1>&2
11425
11426*** Warning: the command libtool uses to detect shared libraries,
11427*** $file_magic_cmd, produces output that libtool cannot recognize.
11428*** The result is that libtool may fail to recognize shared libraries
11429*** as such. This will affect the creation of libtool libraries that
11430*** depend on shared libraries, but programs linked with such libtool
11431*** libraries will work regardless of this problem. Nevertheless, you
11432*** may want to report the problem to your system manager and/or to
11433*** bug-libtool@gnu.org
11434
11435_LT_EOF
11436 fi ;;
11437 esac
11438 fi
11439 break
11440 fi
11441 done
11442 IFS=$lt_save_ifs
11443 MAGIC_CMD=$lt_save_MAGIC_CMD
11444 ;;
11445esac
11446fi
11447
11448MAGIC_CMD=$lt_cv_path_MAGIC_CMD
11449if test -n "$MAGIC_CMD"; then
11450 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
11451$as_echo "$MAGIC_CMD" >&6; }
11452else
11453 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11454$as_echo "no" >&6; }
11455fi
11456
11457
11458
11459
11460
11461if test -z "$lt_cv_path_MAGIC_CMD"; then
11462 if test -n "$ac_tool_prefix"; then
11463 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5
11464$as_echo_n "checking for file... " >&6; }
11465if ${lt_cv_path_MAGIC_CMD+:} false; then :
11466 $as_echo_n "(cached) " >&6
11467else
11468 case $MAGIC_CMD in
11469[\\/*] | ?:[\\/]*)
11470 lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path.
11471 ;;
11472*)
11473 lt_save_MAGIC_CMD=$MAGIC_CMD
11474 lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR
11475 ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
11476 for ac_dir in $ac_dummy; do
11477 IFS=$lt_save_ifs
11478 test -z "$ac_dir" && ac_dir=.
11479 if test -f "$ac_dir/file"; then
11480 lt_cv_path_MAGIC_CMD=$ac_dir/"file"
11481 if test -n "$file_magic_test_file"; then
11482 case $deplibs_check_method in
11483 "file_magic "*)
11484 file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
11485 MAGIC_CMD=$lt_cv_path_MAGIC_CMD
11486 if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
11487 $EGREP "$file_magic_regex" > /dev/null; then
11488 :
11489 else
11490 cat <<_LT_EOF 1>&2
11491
11492*** Warning: the command libtool uses to detect shared libraries,
11493*** $file_magic_cmd, produces output that libtool cannot recognize.
11494*** The result is that libtool may fail to recognize shared libraries
11495*** as such. This will affect the creation of libtool libraries that
11496*** depend on shared libraries, but programs linked with such libtool
11497*** libraries will work regardless of this problem. Nevertheless, you
11498*** may want to report the problem to your system manager and/or to
11499*** bug-libtool@gnu.org
11500
11501_LT_EOF
11502 fi ;;
11503 esac
11504 fi
11505 break
11506 fi
11507 done
11508 IFS=$lt_save_ifs
11509 MAGIC_CMD=$lt_save_MAGIC_CMD
11510 ;;
11511esac
11512fi
11513
11514MAGIC_CMD=$lt_cv_path_MAGIC_CMD
11515if test -n "$MAGIC_CMD"; then
11516 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
11517$as_echo "$MAGIC_CMD" >&6; }
11518else
11519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11520$as_echo "no" >&6; }
11521fi
11522
11523
11524 else
11525 MAGIC_CMD=:
11526 fi
11527fi
11528
11529 fi
11530 ;;
11531esac
11532
11533# Use C for the default configuration in the libtool script
11534
11535lt_save_CC=$CC
11536ac_ext=c
11537ac_cpp='$CPP $CPPFLAGS'
11538ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
11539ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
11540ac_compiler_gnu=$ac_cv_c_compiler_gnu
11541
11542
11543# Source file extension for C test sources.
11544ac_ext=c
11545
11546# Object file extension for compiled C test sources.
11547objext=o
11548objext=$objext
11549
11550# Code to be used in simple compile tests
11551lt_simple_compile_test_code="int some_variable = 0;"
11552
11553# Code to be used in simple link tests
11554lt_simple_link_test_code='int main(){return(0);}'
11555
11556
11557
11558
11559
11560
11561
11562# If no C compiler was specified, use CC.
11563LTCC=${LTCC-"$CC"}
11564
11565# If no C compiler flags were specified, use CFLAGS.
11566LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
11567
11568# Allow CC to be a program name with arguments.
11569compiler=$CC
11570
11571# Save the default compiler, since it gets overwritten when the other
11572# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
11573compiler_DEFAULT=$CC
11574
11575# save warnings/boilerplate of simple test code
11576ac_outfile=conftest.$ac_objext
11577echo "$lt_simple_compile_test_code" >conftest.$ac_ext
11578eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
11579_lt_compiler_boilerplate=`cat conftest.err`
11580$RM conftest*
11581
11582ac_outfile=conftest.$ac_objext
11583echo "$lt_simple_link_test_code" >conftest.$ac_ext
11584eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
11585_lt_linker_boilerplate=`cat conftest.err`
11586$RM -r conftest*
11587
11588
11589## CAVEAT EMPTOR:
11590## There is no encapsulation within the following macros, do not change
11591## the running order or otherwise move them around unless you know exactly
11592## what you are doing...
11593if test -n "$compiler"; then
11594
11595lt_prog_compiler_no_builtin_flag=
11596
11597if test yes = "$GCC"; then
11598 case $cc_basename in
11599 nvcc*)
11600 lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;;
11601 *)
11602 lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;;
11603 esac
11604
11605 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
11606$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; }
11607if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then :
11608 $as_echo_n "(cached) " >&6
11609else
11610 lt_cv_prog_compiler_rtti_exceptions=no
11611 ac_outfile=conftest.$ac_objext
11612 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
11613 lt_compiler_flag="-fno-rtti -fno-exceptions" ## exclude from sc_useless_quotes_in_assignment
11614 # Insert the option either (1) after the last *FLAGS variable, or
11615 # (2) before a word containing "conftest.", or (3) at the end.
11616 # Note that $ac_compile itself does not contain backslashes and begins
11617 # with a dollar sign (not a hyphen), so the echo should work correctly.
11618 # The option is referenced via a variable to avoid confusing sed.
11619 lt_compile=`echo "$ac_compile" | $SED \
11620 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
11621 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
11622 -e 's:$: $lt_compiler_flag:'`
11623 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
11624 (eval "$lt_compile" 2>conftest.err)
11625 ac_status=$?
11626 cat conftest.err >&5
11627 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11628 if (exit $ac_status) && test -s "$ac_outfile"; then
11629 # The compiler can only warn and ignore the option if not recognized
11630 # So say no if there are warnings other than the usual output.
11631 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
11632 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
11633 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
11634 lt_cv_prog_compiler_rtti_exceptions=yes
11635 fi
11636 fi
11637 $RM conftest*
11638
11639fi
11640{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
11641$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; }
11642
11643if test yes = "$lt_cv_prog_compiler_rtti_exceptions"; then
11644 lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
11645else
11646 :
11647fi
11648
11649fi
11650
11651
11652
11653
11654
11655
11656 lt_prog_compiler_wl=
11657lt_prog_compiler_pic=
11658lt_prog_compiler_static=
11659
11660
11661 if test yes = "$GCC"; then
11662 lt_prog_compiler_wl='-Wl,'
11663 lt_prog_compiler_static='-static'
11664
11665 case $host_os in
11666 aix*)
11667 # All AIX code is PIC.
11668 if test ia64 = "$host_cpu"; then
11669 # AIX 5 now supports IA64 processor
11670 lt_prog_compiler_static='-Bstatic'
11671 fi
11672 lt_prog_compiler_pic='-fPIC'
11673 ;;
11674
11675 amigaos*)
11676 case $host_cpu in
11677 powerpc)
11678 # see comment about AmigaOS4 .so support
11679 lt_prog_compiler_pic='-fPIC'
11680 ;;
11681 m68k)
11682 # FIXME: we need at least 68020 code to build shared libraries, but
11683 # adding the '-m68020' flag to GCC prevents building anything better,
11684 # like '-m68040'.
11685 lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
11686 ;;
11687 esac
11688 ;;
11689
11690 beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
11691 # PIC is the default for these OSes.
11692 ;;
11693
11694 mingw* | cygwin* | pw32* | os2* | cegcc*)
11695 # This hack is so that the source file can tell whether it is being
11696 # built for inclusion in a dll (and should export symbols for example).
11697 # Although the cygwin gcc ignores -fPIC, still need this for old-style
11698 # (--disable-auto-import) libraries
11699 lt_prog_compiler_pic='-DDLL_EXPORT'
11700 case $host_os in
11701 os2*)
11702 lt_prog_compiler_static='$wl-static'
11703 ;;
11704 esac
11705 ;;
11706
11707 darwin* | rhapsody*)
11708 # PIC is the default on this platform
11709 # Common symbols not allowed in MH_DYLIB files
11710 lt_prog_compiler_pic='-fno-common'
11711 ;;
11712
11713 haiku*)
11714 # PIC is the default for Haiku.
11715 # The "-static" flag exists, but is broken.
11716 lt_prog_compiler_static=
11717 ;;
11718
11719 hpux*)
11720 # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
11721 # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
11722 # sets the default TLS model and affects inlining.
11723 case $host_cpu in
11724 hppa*64*)
11725 # +Z the default
11726 ;;
11727 *)
11728 lt_prog_compiler_pic='-fPIC'
11729 ;;
11730 esac
11731 ;;
11732
11733 interix[3-9]*)
11734 # Interix 3.x gcc -fpic/-fPIC options generate broken code.
11735 # Instead, we relocate shared libraries at runtime.
11736 ;;
11737
11738 msdosdjgpp*)
11739 # Just because we use GCC doesn't mean we suddenly get shared libraries
11740 # on systems that don't support them.
11741 lt_prog_compiler_can_build_shared=no
11742 enable_shared=no
11743 ;;
11744
11745 *nto* | *qnx*)
11746 # QNX uses GNU C++, but need to define -shared option too, otherwise
11747 # it will coredump.
11748 lt_prog_compiler_pic='-fPIC -shared'
11749 ;;
11750
11751 sysv4*MP*)
11752 if test -d /usr/nec; then
11753 lt_prog_compiler_pic=-Kconform_pic
11754 fi
11755 ;;
11756
11757 *)
11758 lt_prog_compiler_pic='-fPIC'
11759 ;;
11760 esac
11761
11762 case $cc_basename in
11763 nvcc*) # Cuda Compiler Driver 2.2
11764 lt_prog_compiler_wl='-Xlinker '
11765 if test -n "$lt_prog_compiler_pic"; then
11766 lt_prog_compiler_pic="-Xcompiler $lt_prog_compiler_pic"
11767 fi
11768 ;;
11769 esac
11770 else
11771 # PORTME Check for flag to pass linker flags through the system compiler.
11772 case $host_os in
11773 aix*)
11774 lt_prog_compiler_wl='-Wl,'
11775 if test ia64 = "$host_cpu"; then
11776 # AIX 5 now supports IA64 processor
11777 lt_prog_compiler_static='-Bstatic'
11778 else
11779 lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp'
11780 fi
11781 ;;
11782
11783 darwin* | rhapsody*)
11784 # PIC is the default on this platform
11785 # Common symbols not allowed in MH_DYLIB files
11786 lt_prog_compiler_pic='-fno-common'
11787 case $cc_basename in
11788 nagfor*)
11789 # NAG Fortran compiler
11790 lt_prog_compiler_wl='-Wl,-Wl,,'
11791 lt_prog_compiler_pic='-PIC'
11792 lt_prog_compiler_static='-Bstatic'
11793 ;;
11794 esac
11795 ;;
11796
11797 mingw* | cygwin* | pw32* | os2* | cegcc*)
11798 # This hack is so that the source file can tell whether it is being
11799 # built for inclusion in a dll (and should export symbols for example).
11800 lt_prog_compiler_pic='-DDLL_EXPORT'
11801 case $host_os in
11802 os2*)
11803 lt_prog_compiler_static='$wl-static'
11804 ;;
11805 esac
11806 ;;
11807
11808 hpux9* | hpux10* | hpux11*)
11809 lt_prog_compiler_wl='-Wl,'
11810 # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
11811 # not for PA HP-UX.
11812 case $host_cpu in
11813 hppa*64*|ia64*)
11814 # +Z the default
11815 ;;
11816 *)
11817 lt_prog_compiler_pic='+Z'
11818 ;;
11819 esac
11820 # Is there a better lt_prog_compiler_static that works with the bundled CC?
11821 lt_prog_compiler_static='$wl-a ${wl}archive'
11822 ;;
11823
11824 irix5* | irix6* | nonstopux*)
11825 lt_prog_compiler_wl='-Wl,'
11826 # PIC (with -KPIC) is the default.
11827 lt_prog_compiler_static='-non_shared'
11828 ;;
11829
11830 linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
11831 case $cc_basename in
11832 # old Intel for x86_64, which still supported -KPIC.
11833 ecc*)
11834 lt_prog_compiler_wl='-Wl,'
11835 lt_prog_compiler_pic='-KPIC'
11836 lt_prog_compiler_static='-static'
11837 ;;
Haibo Huang001784b2019-07-19 05:27:28 -070011838 # flang / f18. f95 an alias for gfortran or flang on Debian
11839 flang* | f18* | f95*)
11840 lt_prog_compiler_wl='-Wl,'
11841 lt_prog_compiler_pic='-fPIC'
11842 lt_prog_compiler_static='-static'
11843 ;;
Elliott Hughes82be86d2017-09-20 17:00:17 -070011844 # icc used to be incompatible with GCC.
11845 # ICC 10 doesn't accept -KPIC any more.
11846 icc* | ifort*)
11847 lt_prog_compiler_wl='-Wl,'
11848 lt_prog_compiler_pic='-fPIC'
11849 lt_prog_compiler_static='-static'
11850 ;;
11851 # Lahey Fortran 8.1.
11852 lf95*)
11853 lt_prog_compiler_wl='-Wl,'
11854 lt_prog_compiler_pic='--shared'
11855 lt_prog_compiler_static='--static'
11856 ;;
11857 nagfor*)
11858 # NAG Fortran compiler
11859 lt_prog_compiler_wl='-Wl,-Wl,,'
11860 lt_prog_compiler_pic='-PIC'
11861 lt_prog_compiler_static='-Bstatic'
11862 ;;
11863 tcc*)
11864 # Fabrice Bellard et al's Tiny C Compiler
11865 lt_prog_compiler_wl='-Wl,'
11866 lt_prog_compiler_pic='-fPIC'
11867 lt_prog_compiler_static='-static'
11868 ;;
11869 pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
11870 # Portland Group compilers (*not* the Pentium gcc compiler,
11871 # which looks to be a dead project)
11872 lt_prog_compiler_wl='-Wl,'
11873 lt_prog_compiler_pic='-fpic'
11874 lt_prog_compiler_static='-Bstatic'
11875 ;;
11876 ccc*)
11877 lt_prog_compiler_wl='-Wl,'
11878 # All Alpha code is PIC.
11879 lt_prog_compiler_static='-non_shared'
11880 ;;
11881 xl* | bgxl* | bgf* | mpixl*)
11882 # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
11883 lt_prog_compiler_wl='-Wl,'
11884 lt_prog_compiler_pic='-qpic'
11885 lt_prog_compiler_static='-qstaticlink'
11886 ;;
11887 *)
11888 case `$CC -V 2>&1 | sed 5q` in
11889 *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [1-7].* | *Sun*Fortran*\ 8.[0-3]*)
11890 # Sun Fortran 8.3 passes all unrecognized flags to the linker
11891 lt_prog_compiler_pic='-KPIC'
11892 lt_prog_compiler_static='-Bstatic'
11893 lt_prog_compiler_wl=''
11894 ;;
11895 *Sun\ F* | *Sun*Fortran*)
11896 lt_prog_compiler_pic='-KPIC'
11897 lt_prog_compiler_static='-Bstatic'
11898 lt_prog_compiler_wl='-Qoption ld '
11899 ;;
11900 *Sun\ C*)
11901 # Sun C 5.9
11902 lt_prog_compiler_pic='-KPIC'
11903 lt_prog_compiler_static='-Bstatic'
11904 lt_prog_compiler_wl='-Wl,'
11905 ;;
11906 *Intel*\ [CF]*Compiler*)
11907 lt_prog_compiler_wl='-Wl,'
11908 lt_prog_compiler_pic='-fPIC'
11909 lt_prog_compiler_static='-static'
11910 ;;
11911 *Portland\ Group*)
11912 lt_prog_compiler_wl='-Wl,'
11913 lt_prog_compiler_pic='-fpic'
11914 lt_prog_compiler_static='-Bstatic'
11915 ;;
11916 esac
11917 ;;
11918 esac
11919 ;;
11920
11921 newsos6)
11922 lt_prog_compiler_pic='-KPIC'
11923 lt_prog_compiler_static='-Bstatic'
11924 ;;
11925
11926 *nto* | *qnx*)
11927 # QNX uses GNU C++, but need to define -shared option too, otherwise
11928 # it will coredump.
11929 lt_prog_compiler_pic='-fPIC -shared'
11930 ;;
11931
11932 osf3* | osf4* | osf5*)
11933 lt_prog_compiler_wl='-Wl,'
11934 # All OSF/1 code is PIC.
11935 lt_prog_compiler_static='-non_shared'
11936 ;;
11937
11938 rdos*)
11939 lt_prog_compiler_static='-non_shared'
11940 ;;
11941
11942 solaris*)
11943 lt_prog_compiler_pic='-KPIC'
11944 lt_prog_compiler_static='-Bstatic'
11945 case $cc_basename in
11946 f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
11947 lt_prog_compiler_wl='-Qoption ld ';;
11948 *)
11949 lt_prog_compiler_wl='-Wl,';;
11950 esac
11951 ;;
11952
11953 sunos4*)
11954 lt_prog_compiler_wl='-Qoption ld '
11955 lt_prog_compiler_pic='-PIC'
11956 lt_prog_compiler_static='-Bstatic'
11957 ;;
11958
11959 sysv4 | sysv4.2uw2* | sysv4.3*)
11960 lt_prog_compiler_wl='-Wl,'
11961 lt_prog_compiler_pic='-KPIC'
11962 lt_prog_compiler_static='-Bstatic'
11963 ;;
11964
11965 sysv4*MP*)
11966 if test -d /usr/nec; then
11967 lt_prog_compiler_pic='-Kconform_pic'
11968 lt_prog_compiler_static='-Bstatic'
11969 fi
11970 ;;
11971
11972 sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
11973 lt_prog_compiler_wl='-Wl,'
11974 lt_prog_compiler_pic='-KPIC'
11975 lt_prog_compiler_static='-Bstatic'
11976 ;;
11977
11978 unicos*)
11979 lt_prog_compiler_wl='-Wl,'
11980 lt_prog_compiler_can_build_shared=no
11981 ;;
11982
11983 uts4*)
11984 lt_prog_compiler_pic='-pic'
11985 lt_prog_compiler_static='-Bstatic'
11986 ;;
11987
11988 *)
11989 lt_prog_compiler_can_build_shared=no
11990 ;;
11991 esac
11992 fi
11993
11994case $host_os in
11995 # For platforms that do not support PIC, -DPIC is meaningless:
11996 *djgpp*)
11997 lt_prog_compiler_pic=
11998 ;;
11999 *)
12000 lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
12001 ;;
12002esac
12003
12004{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
12005$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
12006if ${lt_cv_prog_compiler_pic+:} false; then :
12007 $as_echo_n "(cached) " >&6
12008else
12009 lt_cv_prog_compiler_pic=$lt_prog_compiler_pic
12010fi
12011{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5
12012$as_echo "$lt_cv_prog_compiler_pic" >&6; }
12013lt_prog_compiler_pic=$lt_cv_prog_compiler_pic
12014
12015#
12016# Check to make sure the PIC flag actually works.
12017#
12018if test -n "$lt_prog_compiler_pic"; then
12019 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
12020$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; }
12021if ${lt_cv_prog_compiler_pic_works+:} false; then :
12022 $as_echo_n "(cached) " >&6
12023else
12024 lt_cv_prog_compiler_pic_works=no
12025 ac_outfile=conftest.$ac_objext
12026 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
12027 lt_compiler_flag="$lt_prog_compiler_pic -DPIC" ## exclude from sc_useless_quotes_in_assignment
12028 # Insert the option either (1) after the last *FLAGS variable, or
12029 # (2) before a word containing "conftest.", or (3) at the end.
12030 # Note that $ac_compile itself does not contain backslashes and begins
12031 # with a dollar sign (not a hyphen), so the echo should work correctly.
12032 # The option is referenced via a variable to avoid confusing sed.
12033 lt_compile=`echo "$ac_compile" | $SED \
12034 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
12035 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
12036 -e 's:$: $lt_compiler_flag:'`
12037 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
12038 (eval "$lt_compile" 2>conftest.err)
12039 ac_status=$?
12040 cat conftest.err >&5
12041 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12042 if (exit $ac_status) && test -s "$ac_outfile"; then
12043 # The compiler can only warn and ignore the option if not recognized
12044 # So say no if there are warnings other than the usual output.
12045 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
12046 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
12047 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
12048 lt_cv_prog_compiler_pic_works=yes
12049 fi
12050 fi
12051 $RM conftest*
12052
12053fi
12054{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5
12055$as_echo "$lt_cv_prog_compiler_pic_works" >&6; }
12056
12057if test yes = "$lt_cv_prog_compiler_pic_works"; then
12058 case $lt_prog_compiler_pic in
12059 "" | " "*) ;;
12060 *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
12061 esac
12062else
12063 lt_prog_compiler_pic=
12064 lt_prog_compiler_can_build_shared=no
12065fi
12066
12067fi
12068
12069
12070
12071
12072
12073
12074
12075
12076
12077
12078
12079#
12080# Check to make sure the static flag actually works.
12081#
12082wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\"
12083{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
12084$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
12085if ${lt_cv_prog_compiler_static_works+:} false; then :
12086 $as_echo_n "(cached) " >&6
12087else
12088 lt_cv_prog_compiler_static_works=no
12089 save_LDFLAGS=$LDFLAGS
12090 LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
12091 echo "$lt_simple_link_test_code" > conftest.$ac_ext
12092 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
12093 # The linker can only warn and ignore the option if not recognized
12094 # So say no if there are warnings
12095 if test -s conftest.err; then
12096 # Append any errors to the config.log.
12097 cat conftest.err 1>&5
12098 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
12099 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
12100 if diff conftest.exp conftest.er2 >/dev/null; then
12101 lt_cv_prog_compiler_static_works=yes
12102 fi
12103 else
12104 lt_cv_prog_compiler_static_works=yes
12105 fi
12106 fi
12107 $RM -r conftest*
12108 LDFLAGS=$save_LDFLAGS
12109
12110fi
12111{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5
12112$as_echo "$lt_cv_prog_compiler_static_works" >&6; }
12113
12114if test yes = "$lt_cv_prog_compiler_static_works"; then
12115 :
12116else
12117 lt_prog_compiler_static=
12118fi
12119
12120
12121
12122
12123
12124
12125
12126 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
12127$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
12128if ${lt_cv_prog_compiler_c_o+:} false; then :
12129 $as_echo_n "(cached) " >&6
12130else
12131 lt_cv_prog_compiler_c_o=no
12132 $RM -r conftest 2>/dev/null
12133 mkdir conftest
12134 cd conftest
12135 mkdir out
12136 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
12137
12138 lt_compiler_flag="-o out/conftest2.$ac_objext"
12139 # Insert the option either (1) after the last *FLAGS variable, or
12140 # (2) before a word containing "conftest.", or (3) at the end.
12141 # Note that $ac_compile itself does not contain backslashes and begins
12142 # with a dollar sign (not a hyphen), so the echo should work correctly.
12143 lt_compile=`echo "$ac_compile" | $SED \
12144 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
12145 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
12146 -e 's:$: $lt_compiler_flag:'`
12147 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
12148 (eval "$lt_compile" 2>out/conftest.err)
12149 ac_status=$?
12150 cat out/conftest.err >&5
12151 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12152 if (exit $ac_status) && test -s out/conftest2.$ac_objext
12153 then
12154 # The compiler can only warn and ignore the option if not recognized
12155 # So say no if there are warnings
12156 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
12157 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
12158 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
12159 lt_cv_prog_compiler_c_o=yes
12160 fi
12161 fi
12162 chmod u+w . 2>&5
12163 $RM conftest*
12164 # SGI C++ compiler will create directory out/ii_files/ for
12165 # template instantiation
12166 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
12167 $RM out/* && rmdir out
12168 cd ..
12169 $RM -r conftest
12170 $RM conftest*
12171
12172fi
12173{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
12174$as_echo "$lt_cv_prog_compiler_c_o" >&6; }
12175
12176
12177
12178
12179
12180
12181 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
12182$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
12183if ${lt_cv_prog_compiler_c_o+:} false; then :
12184 $as_echo_n "(cached) " >&6
12185else
12186 lt_cv_prog_compiler_c_o=no
12187 $RM -r conftest 2>/dev/null
12188 mkdir conftest
12189 cd conftest
12190 mkdir out
12191 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
12192
12193 lt_compiler_flag="-o out/conftest2.$ac_objext"
12194 # Insert the option either (1) after the last *FLAGS variable, or
12195 # (2) before a word containing "conftest.", or (3) at the end.
12196 # Note that $ac_compile itself does not contain backslashes and begins
12197 # with a dollar sign (not a hyphen), so the echo should work correctly.
12198 lt_compile=`echo "$ac_compile" | $SED \
12199 -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
12200 -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
12201 -e 's:$: $lt_compiler_flag:'`
12202 (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
12203 (eval "$lt_compile" 2>out/conftest.err)
12204 ac_status=$?
12205 cat out/conftest.err >&5
12206 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12207 if (exit $ac_status) && test -s out/conftest2.$ac_objext
12208 then
12209 # The compiler can only warn and ignore the option if not recognized
12210 # So say no if there are warnings
12211 $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
12212 $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
12213 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
12214 lt_cv_prog_compiler_c_o=yes
12215 fi
12216 fi
12217 chmod u+w . 2>&5
12218 $RM conftest*
12219 # SGI C++ compiler will create directory out/ii_files/ for
12220 # template instantiation
12221 test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
12222 $RM out/* && rmdir out
12223 cd ..
12224 $RM -r conftest
12225 $RM conftest*
12226
12227fi
12228{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
12229$as_echo "$lt_cv_prog_compiler_c_o" >&6; }
12230
12231
12232
12233
12234hard_links=nottested
12235if test no = "$lt_cv_prog_compiler_c_o" && test no != "$need_locks"; then
12236 # do not overwrite the value of need_locks provided by the user
12237 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
12238$as_echo_n "checking if we can lock with hard links... " >&6; }
12239 hard_links=yes
12240 $RM conftest*
12241 ln conftest.a conftest.b 2>/dev/null && hard_links=no
12242 touch conftest.a
12243 ln conftest.a conftest.b 2>&5 || hard_links=no
12244 ln conftest.a conftest.b 2>/dev/null && hard_links=no
12245 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
12246$as_echo "$hard_links" >&6; }
12247 if test no = "$hard_links"; then
12248 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&5
12249$as_echo "$as_me: WARNING: '$CC' does not support '-c -o', so 'make -j' may be unsafe" >&2;}
12250 need_locks=warn
12251 fi
12252else
12253 need_locks=no
12254fi
12255
12256
12257
12258
12259
12260
12261 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
12262$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
12263
12264 runpath_var=
12265 allow_undefined_flag=
12266 always_export_symbols=no
12267 archive_cmds=
12268 archive_expsym_cmds=
12269 compiler_needs_object=no
12270 enable_shared_with_static_runtimes=no
12271 export_dynamic_flag_spec=
12272 export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
12273 hardcode_automatic=no
12274 hardcode_direct=no
12275 hardcode_direct_absolute=no
12276 hardcode_libdir_flag_spec=
12277 hardcode_libdir_separator=
12278 hardcode_minus_L=no
12279 hardcode_shlibpath_var=unsupported
12280 inherit_rpath=no
12281 link_all_deplibs=unknown
12282 module_cmds=
12283 module_expsym_cmds=
12284 old_archive_from_new_cmds=
12285 old_archive_from_expsyms_cmds=
12286 thread_safe_flag_spec=
12287 whole_archive_flag_spec=
12288 # include_expsyms should be a list of space-separated symbols to be *always*
12289 # included in the symbol list
12290 include_expsyms=
12291 # exclude_expsyms can be an extended regexp of symbols to exclude
12292 # it will be wrapped by ' (' and ')$', so one must not match beginning or
12293 # end of line. Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc',
12294 # as well as any symbol that contains 'd'.
12295 exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
12296 # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
12297 # platforms (ab)use it in PIC code, but their linkers get confused if
12298 # the symbol is explicitly referenced. Since portable code cannot
12299 # rely on this symbol name, it's probably fine to never include it in
12300 # preloaded symbol tables.
12301 # Exclude shared library initialization/finalization symbols.
12302 extract_expsyms_cmds=
12303
12304 case $host_os in
12305 cygwin* | mingw* | pw32* | cegcc*)
12306 # FIXME: the MSVC++ port hasn't been tested in a loooong time
12307 # When not using gcc, we currently assume that we are using
12308 # Microsoft Visual C++.
12309 if test yes != "$GCC"; then
12310 with_gnu_ld=no
12311 fi
12312 ;;
12313 interix*)
12314 # we just hope/assume this is gcc and not c89 (= MSVC++)
12315 with_gnu_ld=yes
12316 ;;
12317 openbsd* | bitrig*)
12318 with_gnu_ld=no
12319 ;;
12320 linux* | k*bsd*-gnu | gnu*)
12321 link_all_deplibs=no
12322 ;;
12323 esac
12324
12325 ld_shlibs=yes
12326
12327 # On some targets, GNU ld is compatible enough with the native linker
12328 # that we're better off using the native interface for both.
12329 lt_use_gnu_ld_interface=no
12330 if test yes = "$with_gnu_ld"; then
12331 case $host_os in
12332 aix*)
12333 # The AIX port of GNU ld has always aspired to compatibility
12334 # with the native linker. However, as the warning in the GNU ld
12335 # block says, versions before 2.19.5* couldn't really create working
12336 # shared libraries, regardless of the interface used.
12337 case `$LD -v 2>&1` in
12338 *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
12339 *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;;
12340 *\ \(GNU\ Binutils\)\ [3-9]*) ;;
12341 *)
12342 lt_use_gnu_ld_interface=yes
12343 ;;
12344 esac
12345 ;;
12346 *)
12347 lt_use_gnu_ld_interface=yes
12348 ;;
12349 esac
12350 fi
12351
12352 if test yes = "$lt_use_gnu_ld_interface"; then
12353 # If archive_cmds runs LD, not CC, wlarc should be empty
12354 wlarc='$wl'
12355
12356 # Set some defaults for GNU ld with shared library support. These
12357 # are reset later if shared libraries are not supported. Putting them
12358 # here allows them to be overridden if necessary.
12359 runpath_var=LD_RUN_PATH
12360 hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
12361 export_dynamic_flag_spec='$wl--export-dynamic'
12362 # ancient GNU ld didn't support --whole-archive et. al.
12363 if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
12364 whole_archive_flag_spec=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive'
12365 else
12366 whole_archive_flag_spec=
12367 fi
12368 supports_anon_versioning=no
12369 case `$LD -v | $SED -e 's/(^)\+)\s\+//' 2>&1` in
12370 *GNU\ gold*) supports_anon_versioning=yes ;;
12371 *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
12372 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
12373 *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
12374 *\ 2.11.*) ;; # other 2.11 versions
12375 *) supports_anon_versioning=yes ;;
12376 esac
12377
12378 # See if GNU ld supports shared libraries.
12379 case $host_os in
12380 aix[3-9]*)
12381 # On AIX/PPC, the GNU linker is very broken
12382 if test ia64 != "$host_cpu"; then
12383 ld_shlibs=no
12384 cat <<_LT_EOF 1>&2
12385
12386*** Warning: the GNU linker, at least up to release 2.19, is reported
12387*** to be unable to reliably create shared libraries on AIX.
12388*** Therefore, libtool is disabling shared libraries support. If you
12389*** really care for shared libraries, you may want to install binutils
12390*** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
12391*** You will then need to restart the configuration process.
12392
12393_LT_EOF
12394 fi
12395 ;;
12396
12397 amigaos*)
12398 case $host_cpu in
12399 powerpc)
12400 # see comment about AmigaOS4 .so support
12401 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
12402 archive_expsym_cmds=''
12403 ;;
12404 m68k)
12405 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)'
12406 hardcode_libdir_flag_spec='-L$libdir'
12407 hardcode_minus_L=yes
12408 ;;
12409 esac
12410 ;;
12411
12412 beos*)
12413 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
12414 allow_undefined_flag=unsupported
12415 # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
12416 # support --undefined. This deserves some investigation. FIXME
12417 archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
12418 else
12419 ld_shlibs=no
12420 fi
12421 ;;
12422
12423 cygwin* | mingw* | pw32* | cegcc*)
12424 # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
12425 # as there is no search path for DLLs.
12426 hardcode_libdir_flag_spec='-L$libdir'
12427 export_dynamic_flag_spec='$wl--export-all-symbols'
12428 allow_undefined_flag=unsupported
12429 always_export_symbols=no
12430 enable_shared_with_static_runtimes=yes
12431 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'
12432 exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'
12433
12434 if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
12435 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
12436 # If the export-symbols file already is a .def file, use it as
12437 # is; otherwise, prepend EXPORTS...
12438 archive_expsym_cmds='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then
12439 cp $export_symbols $output_objdir/$soname.def;
12440 else
12441 echo EXPORTS > $output_objdir/$soname.def;
12442 cat $export_symbols >> $output_objdir/$soname.def;
12443 fi~
12444 $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
12445 else
12446 ld_shlibs=no
12447 fi
12448 ;;
12449
12450 haiku*)
12451 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
12452 link_all_deplibs=yes
12453 ;;
12454
12455 os2*)
12456 hardcode_libdir_flag_spec='-L$libdir'
12457 hardcode_minus_L=yes
12458 allow_undefined_flag=unsupported
12459 shrext_cmds=.dll
12460 archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
12461 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
12462 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
12463 $ECHO EXPORTS >> $output_objdir/$libname.def~
12464 emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
12465 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
12466 emximp -o $lib $output_objdir/$libname.def'
12467 archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
12468 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
12469 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
12470 $ECHO EXPORTS >> $output_objdir/$libname.def~
12471 prefix_cmds="$SED"~
12472 if test EXPORTS = "`$SED 1q $export_symbols`"; then
12473 prefix_cmds="$prefix_cmds -e 1d";
12474 fi~
12475 prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
12476 cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
12477 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
12478 emximp -o $lib $output_objdir/$libname.def'
12479 old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
12480 enable_shared_with_static_runtimes=yes
12481 ;;
12482
12483 interix[3-9]*)
12484 hardcode_direct=no
12485 hardcode_shlibpath_var=no
12486 hardcode_libdir_flag_spec='$wl-rpath,$libdir'
12487 export_dynamic_flag_spec='$wl-E'
12488 # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
12489 # Instead, shared libraries are loaded at an image base (0x10000000 by
12490 # default) and relocated if they conflict, which is a slow very memory
12491 # consuming and fragmenting process. To avoid this, we pick a random,
12492 # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
12493 # time. Moving up from 0x10000000 also allows more sbrk(2) space.
12494 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
12495 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'
12496 ;;
12497
12498 gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
12499 tmp_diet=no
12500 if test linux-dietlibc = "$host_os"; then
12501 case $cc_basename in
12502 diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
12503 esac
12504 fi
12505 if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
12506 && test no = "$tmp_diet"
12507 then
12508 tmp_addflag=' $pic_flag'
12509 tmp_sharedflag='-shared'
12510 case $cc_basename,$host_cpu in
12511 pgcc*) # Portland Group C compiler
12512 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'
12513 tmp_addflag=' $pic_flag'
12514 ;;
12515 pgf77* | pgf90* | pgf95* | pgfortran*)
12516 # Portland Group f77 and f90 compilers
12517 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'
12518 tmp_addflag=' $pic_flag -Mnomain' ;;
12519 ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
12520 tmp_addflag=' -i_dynamic' ;;
12521 efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
12522 tmp_addflag=' -i_dynamic -nofor_main' ;;
12523 ifc* | ifort*) # Intel Fortran compiler
12524 tmp_addflag=' -nofor_main' ;;
12525 lf95*) # Lahey Fortran 8.1
12526 whole_archive_flag_spec=
12527 tmp_sharedflag='--shared' ;;
12528 nagfor*) # NAGFOR 5.3
12529 tmp_sharedflag='-Wl,-shared' ;;
12530 xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below)
12531 tmp_sharedflag='-qmkshrobj'
12532 tmp_addflag= ;;
12533 nvcc*) # Cuda Compiler Driver 2.2
12534 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'
12535 compiler_needs_object=yes
12536 ;;
12537 esac
12538 case `$CC -V 2>&1 | sed 5q` in
12539 *Sun\ C*) # Sun C 5.9
12540 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'
12541 compiler_needs_object=yes
12542 tmp_sharedflag='-G' ;;
12543 *Sun\ F*) # Sun Fortran 8.3
12544 tmp_sharedflag='-G' ;;
12545 esac
12546 archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
12547
12548 if test yes = "$supports_anon_versioning"; then
12549 archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
12550 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
12551 echo "local: *; };" >> $output_objdir/$libname.ver~
12552 $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib'
12553 fi
12554
12555 case $cc_basename in
12556 tcc*)
12557 export_dynamic_flag_spec='-rdynamic'
12558 ;;
12559 xlf* | bgf* | bgxlf* | mpixlf*)
12560 # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
12561 whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
12562 hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
12563 archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
12564 if test yes = "$supports_anon_versioning"; then
12565 archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
12566 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
12567 echo "local: *; };" >> $output_objdir/$libname.ver~
12568 $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
12569 fi
12570 ;;
12571 esac
12572 else
12573 ld_shlibs=no
12574 fi
12575 ;;
12576
12577 netbsd* | netbsdelf*-gnu)
12578 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
12579 archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
12580 wlarc=
12581 else
12582 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
12583 archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
12584 fi
12585 ;;
12586
12587 solaris*)
12588 if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
12589 ld_shlibs=no
12590 cat <<_LT_EOF 1>&2
12591
12592*** Warning: The releases 2.8.* of the GNU linker cannot reliably
12593*** create shared libraries on Solaris systems. Therefore, libtool
12594*** is disabling shared libraries support. We urge you to upgrade GNU
12595*** binutils to release 2.9.1 or newer. Another option is to modify
12596*** your PATH or compiler configuration so that the native linker is
12597*** used, and then restart.
12598
12599_LT_EOF
12600 elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
12601 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
12602 archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
12603 else
12604 ld_shlibs=no
12605 fi
12606 ;;
12607
12608 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
12609 case `$LD -v 2>&1` in
12610 *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*)
12611 ld_shlibs=no
12612 cat <<_LT_EOF 1>&2
12613
12614*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot
12615*** reliably create shared libraries on SCO systems. Therefore, libtool
12616*** is disabling shared libraries support. We urge you to upgrade GNU
12617*** binutils to release 2.16.91.0.3 or newer. Another option is to modify
12618*** your PATH or compiler configuration so that the native linker is
12619*** used, and then restart.
12620
12621_LT_EOF
12622 ;;
12623 *)
12624 # For security reasons, it is highly recommended that you always
12625 # use absolute paths for naming shared libraries, and exclude the
12626 # DT_RUNPATH tag from executables and libraries. But doing so
12627 # requires that you compile everything twice, which is a pain.
12628 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
12629 hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
12630 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
12631 archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
12632 else
12633 ld_shlibs=no
12634 fi
12635 ;;
12636 esac
12637 ;;
12638
12639 sunos4*)
12640 archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
12641 wlarc=
12642 hardcode_direct=yes
12643 hardcode_shlibpath_var=no
12644 ;;
12645
12646 *)
12647 if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
12648 archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
12649 archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib'
12650 else
12651 ld_shlibs=no
12652 fi
12653 ;;
12654 esac
12655
12656 if test no = "$ld_shlibs"; then
12657 runpath_var=
12658 hardcode_libdir_flag_spec=
12659 export_dynamic_flag_spec=
12660 whole_archive_flag_spec=
12661 fi
12662 else
12663 # PORTME fill in a description of your system's linker (not GNU ld)
12664 case $host_os in
12665 aix3*)
12666 allow_undefined_flag=unsupported
12667 always_export_symbols=yes
12668 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'
12669 # Note: this linker hardcodes the directories in LIBPATH if there
12670 # are no directories specified by -L.
12671 hardcode_minus_L=yes
12672 if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then
12673 # Neither direct hardcoding nor static linking is supported with a
12674 # broken collect2.
12675 hardcode_direct=unsupported
12676 fi
12677 ;;
12678
12679 aix[4-9]*)
12680 if test ia64 = "$host_cpu"; then
12681 # On IA64, the linker does run time linking by default, so we don't
12682 # have to do anything special.
12683 aix_use_runtimelinking=no
12684 exp_sym_flag='-Bexport'
12685 no_entry_flag=
12686 else
12687 # If we're using GNU nm, then we don't want the "-C" option.
12688 # -C means demangle to GNU nm, but means don't demangle to AIX nm.
12689 # Without the "-l" option, or with the "-B" option, AIX nm treats
12690 # weak defined symbols like other global defined symbols, whereas
12691 # GNU nm marks them as "W".
12692 # While the 'weak' keyword is ignored in the Export File, we need
12693 # it in the Import File for the 'aix-soname' feature, so we have
12694 # to replace the "-B" option with "-P" for AIX nm.
12695 if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
12696 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'
12697 else
12698 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'
12699 fi
12700 aix_use_runtimelinking=no
12701
12702 # Test if we are trying to use run time linking or normal
12703 # AIX style linking. If -brtl is somewhere in LDFLAGS, we
12704 # have runtime linking enabled, and use it for executables.
12705 # For shared libraries, we enable/disable runtime linking
12706 # depending on the kind of the shared library created -
12707 # when "with_aix_soname,aix_use_runtimelinking" is:
12708 # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables
12709 # "aix,yes" lib.so shared, rtl:yes, for executables
12710 # lib.a static archive
12711 # "both,no" lib.so.V(shr.o) shared, rtl:yes
12712 # lib.a(lib.so.V) shared, rtl:no, for executables
12713 # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables
12714 # lib.a(lib.so.V) shared, rtl:no
12715 # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables
12716 # lib.a static archive
12717 case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
12718 for ld_flag in $LDFLAGS; do
12719 if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then
12720 aix_use_runtimelinking=yes
12721 break
12722 fi
12723 done
12724 if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then
12725 # With aix-soname=svr4, we create the lib.so.V shared archives only,
12726 # so we don't have lib.a shared libs to link our executables.
12727 # We have to force runtime linking in this case.
12728 aix_use_runtimelinking=yes
12729 LDFLAGS="$LDFLAGS -Wl,-brtl"
12730 fi
12731 ;;
12732 esac
12733
12734 exp_sym_flag='-bexport'
12735 no_entry_flag='-bnoentry'
12736 fi
12737
12738 # When large executables or shared objects are built, AIX ld can
12739 # have problems creating the table of contents. If linking a library
12740 # or program results in "error TOC overflow" add -mminimal-toc to
12741 # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
12742 # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
12743
12744 archive_cmds=''
12745 hardcode_direct=yes
12746 hardcode_direct_absolute=yes
12747 hardcode_libdir_separator=':'
12748 link_all_deplibs=yes
12749 file_list_spec='$wl-f,'
12750 case $with_aix_soname,$aix_use_runtimelinking in
12751 aix,*) ;; # traditional, no import file
12752 svr4,* | *,yes) # use import file
12753 # The Import File defines what to hardcode.
12754 hardcode_direct=no
12755 hardcode_direct_absolute=no
12756 ;;
12757 esac
12758
12759 if test yes = "$GCC"; then
12760 case $host_os in aix4.[012]|aix4.[012].*)
12761 # We only want to do this on AIX 4.2 and lower, the check
12762 # below for broken collect2 doesn't work under 4.3+
12763 collect2name=`$CC -print-prog-name=collect2`
12764 if test -f "$collect2name" &&
12765 strings "$collect2name" | $GREP resolve_lib_name >/dev/null
12766 then
12767 # We have reworked collect2
12768 :
12769 else
12770 # We have old collect2
12771 hardcode_direct=unsupported
12772 # It fails to find uninstalled libraries when the uninstalled
12773 # path is not listed in the libpath. Setting hardcode_minus_L
12774 # to unsupported forces relinking
12775 hardcode_minus_L=yes
12776 hardcode_libdir_flag_spec='-L$libdir'
12777 hardcode_libdir_separator=
12778 fi
12779 ;;
12780 esac
12781 shared_flag='-shared'
12782 if test yes = "$aix_use_runtimelinking"; then
12783 shared_flag="$shared_flag "'$wl-G'
12784 fi
12785 # Need to ensure runtime linking is disabled for the traditional
12786 # shared library, or the linker may eventually find shared libraries
12787 # /with/ Import File - we do not want to mix them.
12788 shared_flag_aix='-shared'
12789 shared_flag_svr4='-shared $wl-G'
12790 else
12791 # not using gcc
12792 if test ia64 = "$host_cpu"; then
12793 # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
12794 # chokes on -Wl,-G. The following line is correct:
12795 shared_flag='-G'
12796 else
12797 if test yes = "$aix_use_runtimelinking"; then
12798 shared_flag='$wl-G'
12799 else
12800 shared_flag='$wl-bM:SRE'
12801 fi
12802 shared_flag_aix='$wl-bM:SRE'
12803 shared_flag_svr4='$wl-G'
12804 fi
12805 fi
12806
12807 export_dynamic_flag_spec='$wl-bexpall'
12808 # It seems that -bexpall does not export symbols beginning with
12809 # underscore (_), so it is better to generate a list of symbols to export.
12810 always_export_symbols=yes
12811 if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then
12812 # Warning - without using the other runtime loading flags (-brtl),
12813 # -berok will link without error, but may produce a broken library.
12814 allow_undefined_flag='-berok'
12815 # Determine the default libpath from the value encoded in an
12816 # empty executable.
12817 if test set = "${lt_cv_aix_libpath+set}"; then
12818 aix_libpath=$lt_cv_aix_libpath
12819else
12820 if ${lt_cv_aix_libpath_+:} false; then :
12821 $as_echo_n "(cached) " >&6
12822else
12823 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12824/* end confdefs.h. */
12825
12826int main (void)
12827{
12828
12829 ;
12830 return 0;
12831}
12832_ACEOF
12833if ac_fn_c_try_link "$LINENO"; then :
12834
12835 lt_aix_libpath_sed='
12836 /Import File Strings/,/^$/ {
12837 /^0/ {
12838 s/^0 *\([^ ]*\) *$/\1/
12839 p
12840 }
12841 }'
12842 lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12843 # Check for a 64-bit object if we didn't find anything.
12844 if test -z "$lt_cv_aix_libpath_"; then
12845 lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12846 fi
12847fi
12848rm -f core conftest.err conftest.$ac_objext \
12849 conftest$ac_exeext conftest.$ac_ext
12850 if test -z "$lt_cv_aix_libpath_"; then
12851 lt_cv_aix_libpath_=/usr/lib:/lib
12852 fi
12853
12854fi
12855
12856 aix_libpath=$lt_cv_aix_libpath_
12857fi
12858
12859 hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath"
12860 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
12861 else
12862 if test ia64 = "$host_cpu"; then
12863 hardcode_libdir_flag_spec='$wl-R $libdir:/usr/lib:/lib'
12864 allow_undefined_flag="-z nodefs"
12865 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"
12866 else
12867 # Determine the default libpath from the value encoded in an
12868 # empty executable.
12869 if test set = "${lt_cv_aix_libpath+set}"; then
12870 aix_libpath=$lt_cv_aix_libpath
12871else
12872 if ${lt_cv_aix_libpath_+:} false; then :
12873 $as_echo_n "(cached) " >&6
12874else
12875 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12876/* end confdefs.h. */
12877
12878int main (void)
12879{
12880
12881 ;
12882 return 0;
12883}
12884_ACEOF
12885if ac_fn_c_try_link "$LINENO"; then :
12886
12887 lt_aix_libpath_sed='
12888 /Import File Strings/,/^$/ {
12889 /^0/ {
12890 s/^0 *\([^ ]*\) *$/\1/
12891 p
12892 }
12893 }'
12894 lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12895 # Check for a 64-bit object if we didn't find anything.
12896 if test -z "$lt_cv_aix_libpath_"; then
12897 lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
12898 fi
12899fi
12900rm -f core conftest.err conftest.$ac_objext \
12901 conftest$ac_exeext conftest.$ac_ext
12902 if test -z "$lt_cv_aix_libpath_"; then
12903 lt_cv_aix_libpath_=/usr/lib:/lib
12904 fi
12905
12906fi
12907
12908 aix_libpath=$lt_cv_aix_libpath_
12909fi
12910
12911 hardcode_libdir_flag_spec='$wl-blibpath:$libdir:'"$aix_libpath"
12912 # Warning - without using the other run time loading flags,
12913 # -berok will link without error, but may produce a broken library.
12914 no_undefined_flag=' $wl-bernotok'
12915 allow_undefined_flag=' $wl-berok'
12916 if test yes = "$with_gnu_ld"; then
12917 # We only use this code for GNU lds that support --whole-archive.
12918 whole_archive_flag_spec='$wl--whole-archive$convenience $wl--no-whole-archive'
12919 else
12920 # Exported symbols can be pulled into shared objects from archives
12921 whole_archive_flag_spec='$convenience'
12922 fi
12923 archive_cmds_need_lc=yes
12924 archive_expsym_cmds='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d'
12925 # -brtl affects multiple linker settings, -berok does not and is overridden later
12926 compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([, ]\\)%-berok\\1%g"`'
12927 if test svr4 != "$with_aix_soname"; then
12928 # This is similar to how AIX traditionally builds its shared libraries.
12929 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'
12930 fi
12931 if test aix != "$with_aix_soname"; then
12932 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'
12933 else
12934 # used by -dlpreopen to get the symbols
12935 archive_expsym_cmds="$archive_expsym_cmds"'~$MV $output_objdir/$realname.d/$soname $output_objdir'
12936 fi
12937 archive_expsym_cmds="$archive_expsym_cmds"'~$RM -r $output_objdir/$realname.d'
12938 fi
12939 fi
12940 ;;
12941
12942 amigaos*)
12943 case $host_cpu in
12944 powerpc)
12945 # see comment about AmigaOS4 .so support
12946 archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib'
12947 archive_expsym_cmds=''
12948 ;;
12949 m68k)
12950 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)'
12951 hardcode_libdir_flag_spec='-L$libdir'
12952 hardcode_minus_L=yes
12953 ;;
12954 esac
12955 ;;
12956
12957 bsdi[45]*)
12958 export_dynamic_flag_spec=-rdynamic
12959 ;;
12960
12961 cygwin* | mingw* | pw32* | cegcc*)
12962 # When not using gcc, we currently assume that we are using
12963 # Microsoft Visual C++.
12964 # hardcode_libdir_flag_spec is actually meaningless, as there is
12965 # no search path for DLLs.
12966 case $cc_basename in
12967 cl*)
12968 # Native MSVC
12969 hardcode_libdir_flag_spec=' '
12970 allow_undefined_flag=unsupported
12971 always_export_symbols=yes
12972 file_list_spec='@'
12973 # Tell ltmain to make .lib files, not .a files.
12974 libext=lib
12975 # Tell ltmain to make .dll files, not .so files.
12976 shrext_cmds=.dll
12977 # FIXME: Setting linknames here is a bad hack.
12978 archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames='
12979 archive_expsym_cmds='if test DEF = "`$SED -n -e '\''s/^[ ]*//'\'' -e '\''/^\(;.*\)*$/d'\'' -e '\''s/^\(EXPORTS\|LIBRARY\)\([ ].*\)*$/DEF/p'\'' -e q $export_symbols`" ; then
12980 cp "$export_symbols" "$output_objdir/$soname.def";
12981 echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp";
12982 else
12983 $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp;
12984 fi~
12985 $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
12986 linknames='
12987 # The linker will not automatically build a static lib if we build a DLL.
12988 # _LT_TAGVAR(old_archive_from_new_cmds, )='true'
12989 enable_shared_with_static_runtimes=yes
12990 exclude_expsyms='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
12991 export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
12992 # Don't use ranlib
12993 old_postinstall_cmds='chmod 644 $oldlib'
12994 postlink_cmds='lt_outputfile="@OUTPUT@"~
12995 lt_tool_outputfile="@TOOL_OUTPUT@"~
12996 case $lt_outputfile in
12997 *.exe|*.EXE) ;;
12998 *)
12999 lt_outputfile=$lt_outputfile.exe
13000 lt_tool_outputfile=$lt_tool_outputfile.exe
13001 ;;
13002 esac~
13003 if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then
13004 $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
13005 $RM "$lt_outputfile.manifest";
13006 fi'
13007 ;;
13008 *)
13009 # Assume MSVC wrapper
13010 hardcode_libdir_flag_spec=' '
13011 allow_undefined_flag=unsupported
13012 # Tell ltmain to make .lib files, not .a files.
13013 libext=lib
13014 # Tell ltmain to make .dll files, not .so files.
13015 shrext_cmds=.dll
13016 # FIXME: Setting linknames here is a bad hack.
13017 archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
13018 # The linker will automatically build a .lib file if we build a DLL.
13019 old_archive_from_new_cmds='true'
13020 # FIXME: Should let the user specify the lib program.
13021 old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
13022 enable_shared_with_static_runtimes=yes
13023 ;;
13024 esac
13025 ;;
13026
13027 darwin* | rhapsody*)
13028
13029
13030 archive_cmds_need_lc=no
13031 hardcode_direct=no
13032 hardcode_automatic=yes
13033 hardcode_shlibpath_var=unsupported
13034 if test yes = "$lt_cv_ld_force_load"; then
13035 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\"`'
13036
13037 else
13038 whole_archive_flag_spec=''
13039 fi
13040 link_all_deplibs=yes
13041 allow_undefined_flag=$_lt_dar_allow_undefined
13042 case $cc_basename in
13043 ifort*|nagfor*) _lt_dar_can_shared=yes ;;
13044 *) _lt_dar_can_shared=$GCC ;;
13045 esac
13046 if test yes = "$_lt_dar_can_shared"; then
13047 output_verbose_link_cmd=func_echo_all
13048 archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil"
13049 module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil"
13050 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"
13051 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"
13052
13053 else
13054 ld_shlibs=no
13055 fi
13056
13057 ;;
13058
13059 dgux*)
13060 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
13061 hardcode_libdir_flag_spec='-L$libdir'
13062 hardcode_shlibpath_var=no
13063 ;;
13064
13065 # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
13066 # support. Future versions do this automatically, but an explicit c++rt0.o
13067 # does not break anything, and helps significantly (at the cost of a little
13068 # extra space).
13069 freebsd2.2*)
13070 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
13071 hardcode_libdir_flag_spec='-R$libdir'
13072 hardcode_direct=yes
13073 hardcode_shlibpath_var=no
13074 ;;
13075
13076 # Unfortunately, older versions of FreeBSD 2 do not have this feature.
13077 freebsd2.*)
13078 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
13079 hardcode_direct=yes
13080 hardcode_minus_L=yes
13081 hardcode_shlibpath_var=no
13082 ;;
13083
13084 # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
13085 freebsd* | dragonfly*)
13086 archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
13087 hardcode_libdir_flag_spec='-R$libdir'
13088 hardcode_direct=yes
13089 hardcode_shlibpath_var=no
13090 ;;
13091
13092 hpux9*)
13093 if test yes = "$GCC"; then
13094 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'
13095 else
13096 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'
13097 fi
13098 hardcode_libdir_flag_spec='$wl+b $wl$libdir'
13099 hardcode_libdir_separator=:
13100 hardcode_direct=yes
13101
13102 # hardcode_minus_L: Not really in the search PATH,
13103 # but as the default location of the library.
13104 hardcode_minus_L=yes
13105 export_dynamic_flag_spec='$wl-E'
13106 ;;
13107
13108 hpux10*)
13109 if test yes,no = "$GCC,$with_gnu_ld"; then
13110 archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
13111 else
13112 archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
13113 fi
13114 if test no = "$with_gnu_ld"; then
13115 hardcode_libdir_flag_spec='$wl+b $wl$libdir'
13116 hardcode_libdir_separator=:
13117 hardcode_direct=yes
13118 hardcode_direct_absolute=yes
13119 export_dynamic_flag_spec='$wl-E'
13120 # hardcode_minus_L: Not really in the search PATH,
13121 # but as the default location of the library.
13122 hardcode_minus_L=yes
13123 fi
13124 ;;
13125
13126 hpux11*)
13127 if test yes,no = "$GCC,$with_gnu_ld"; then
13128 case $host_cpu in
13129 hppa*64*)
13130 archive_cmds='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
13131 ;;
13132 ia64*)
13133 archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
13134 ;;
13135 *)
13136 archive_cmds='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
13137 ;;
13138 esac
13139 else
13140 case $host_cpu in
13141 hppa*64*)
13142 archive_cmds='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
13143 ;;
13144 ia64*)
13145 archive_cmds='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
13146 ;;
13147 *)
13148
13149 # Older versions of the 11.00 compiler do not understand -b yet
13150 # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
13151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5
13152$as_echo_n "checking if $CC understands -b... " >&6; }
13153if ${lt_cv_prog_compiler__b+:} false; then :
13154 $as_echo_n "(cached) " >&6
13155else
13156 lt_cv_prog_compiler__b=no
13157 save_LDFLAGS=$LDFLAGS
13158 LDFLAGS="$LDFLAGS -b"
13159 echo "$lt_simple_link_test_code" > conftest.$ac_ext
13160 if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
13161 # The linker can only warn and ignore the option if not recognized
13162 # So say no if there are warnings
13163 if test -s conftest.err; then
13164 # Append any errors to the config.log.
13165 cat conftest.err 1>&5
13166 $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
13167 $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
13168 if diff conftest.exp conftest.er2 >/dev/null; then
13169 lt_cv_prog_compiler__b=yes
13170 fi
13171 else
13172 lt_cv_prog_compiler__b=yes
13173 fi
13174 fi
13175 $RM -r conftest*
13176 LDFLAGS=$save_LDFLAGS
13177
13178fi
13179{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5
13180$as_echo "$lt_cv_prog_compiler__b" >&6; }
13181
13182if test yes = "$lt_cv_prog_compiler__b"; then
13183 archive_cmds='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
13184else
13185 archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
13186fi
13187
13188 ;;
13189 esac
13190 fi
13191 if test no = "$with_gnu_ld"; then
13192 hardcode_libdir_flag_spec='$wl+b $wl$libdir'
13193 hardcode_libdir_separator=:
13194
13195 case $host_cpu in
13196 hppa*64*|ia64*)
13197 hardcode_direct=no
13198 hardcode_shlibpath_var=no
13199 ;;
13200 *)
13201 hardcode_direct=yes
13202 hardcode_direct_absolute=yes
13203 export_dynamic_flag_spec='$wl-E'
13204
13205 # hardcode_minus_L: Not really in the search PATH,
13206 # but as the default location of the library.
13207 hardcode_minus_L=yes
13208 ;;
13209 esac
13210 fi
13211 ;;
13212
13213 irix5* | irix6* | nonstopux*)
13214 if test yes = "$GCC"; then
13215 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'
13216 # Try to use the -exported_symbol ld option, if it does not
13217 # work, assume that -exports_file does not work either and
13218 # implicitly export all symbols.
13219 # This should be the same for all languages, so no per-tag cache variable.
13220 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
13221$as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
13222if ${lt_cv_irix_exported_symbol+:} false; then :
13223 $as_echo_n "(cached) " >&6
13224else
13225 save_LDFLAGS=$LDFLAGS
13226 LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null"
13227 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13228/* end confdefs.h. */
13229int foo (void) { return 0; }
13230_ACEOF
13231if ac_fn_c_try_link "$LINENO"; then :
13232 lt_cv_irix_exported_symbol=yes
13233else
13234 lt_cv_irix_exported_symbol=no
13235fi
13236rm -f core conftest.err conftest.$ac_objext \
13237 conftest$ac_exeext conftest.$ac_ext
13238 LDFLAGS=$save_LDFLAGS
13239fi
13240{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5
13241$as_echo "$lt_cv_irix_exported_symbol" >&6; }
13242 if test yes = "$lt_cv_irix_exported_symbol"; then
13243 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'
13244 fi
13245 link_all_deplibs=no
13246 else
13247 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'
13248 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'
13249 fi
13250 archive_cmds_need_lc='no'
13251 hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
13252 hardcode_libdir_separator=:
13253 inherit_rpath=yes
13254 link_all_deplibs=yes
13255 ;;
13256
13257 linux*)
13258 case $cc_basename in
13259 tcc*)
13260 # Fabrice Bellard et al's Tiny C Compiler
13261 ld_shlibs=yes
13262 archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
13263 ;;
13264 esac
13265 ;;
13266
13267 netbsd* | netbsdelf*-gnu)
13268 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
13269 archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
13270 else
13271 archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
13272 fi
13273 hardcode_libdir_flag_spec='-R$libdir'
13274 hardcode_direct=yes
13275 hardcode_shlibpath_var=no
13276 ;;
13277
13278 newsos6)
13279 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
13280 hardcode_direct=yes
13281 hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
13282 hardcode_libdir_separator=:
13283 hardcode_shlibpath_var=no
13284 ;;
13285
13286 *nto* | *qnx*)
13287 ;;
13288
13289 openbsd* | bitrig*)
13290 if test -f /usr/libexec/ld.so; then
13291 hardcode_direct=yes
13292 hardcode_shlibpath_var=no
13293 hardcode_direct_absolute=yes
13294 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
13295 archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
13296 archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols'
13297 hardcode_libdir_flag_spec='$wl-rpath,$libdir'
13298 export_dynamic_flag_spec='$wl-E'
13299 else
13300 archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
13301 hardcode_libdir_flag_spec='$wl-rpath,$libdir'
13302 fi
13303 else
13304 ld_shlibs=no
13305 fi
13306 ;;
13307
13308 os2*)
13309 hardcode_libdir_flag_spec='-L$libdir'
13310 hardcode_minus_L=yes
13311 allow_undefined_flag=unsupported
13312 shrext_cmds=.dll
13313 archive_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
13314 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
13315 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
13316 $ECHO EXPORTS >> $output_objdir/$libname.def~
13317 emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~
13318 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
13319 emximp -o $lib $output_objdir/$libname.def'
13320 archive_expsym_cmds='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~
13321 $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~
13322 $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~
13323 $ECHO EXPORTS >> $output_objdir/$libname.def~
13324 prefix_cmds="$SED"~
13325 if test EXPORTS = "`$SED 1q $export_symbols`"; then
13326 prefix_cmds="$prefix_cmds -e 1d";
13327 fi~
13328 prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~
13329 cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~
13330 $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~
13331 emximp -o $lib $output_objdir/$libname.def'
13332 old_archive_From_new_cmds='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def'
13333 enable_shared_with_static_runtimes=yes
13334 ;;
13335
13336 osf3*)
13337 if test yes = "$GCC"; then
13338 allow_undefined_flag=' $wl-expect_unresolved $wl\*'
13339 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'
13340 else
13341 allow_undefined_flag=' -expect_unresolved \*'
13342 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'
13343 fi
13344 archive_cmds_need_lc='no'
13345 hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
13346 hardcode_libdir_separator=:
13347 ;;
13348
13349 osf4* | osf5*) # as osf3* with the addition of -msym flag
13350 if test yes = "$GCC"; then
13351 allow_undefined_flag=' $wl-expect_unresolved $wl\*'
13352 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'
13353 hardcode_libdir_flag_spec='$wl-rpath $wl$libdir'
13354 else
13355 allow_undefined_flag=' -expect_unresolved \*'
13356 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'
13357 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~
13358 $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'
13359
13360 # Both c and cxx compiler support -rpath directly
13361 hardcode_libdir_flag_spec='-rpath $libdir'
13362 fi
13363 archive_cmds_need_lc='no'
13364 hardcode_libdir_separator=:
13365 ;;
13366
13367 solaris*)
13368 no_undefined_flag=' -z defs'
13369 if test yes = "$GCC"; then
13370 wlarc='$wl'
13371 archive_cmds='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags'
13372 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
13373 $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'
13374 else
13375 case `$CC -V 2>&1` in
13376 *"Compilers 5.0"*)
13377 wlarc=''
13378 archive_cmds='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags'
13379 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
13380 $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
13381 ;;
13382 *)
13383 wlarc='$wl'
13384 archive_cmds='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags'
13385 archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
13386 $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
13387 ;;
13388 esac
13389 fi
13390 hardcode_libdir_flag_spec='-R$libdir'
13391 hardcode_shlibpath_var=no
13392 case $host_os in
13393 solaris2.[0-5] | solaris2.[0-5].*) ;;
13394 *)
13395 # The compiler driver will combine and reorder linker options,
13396 # but understands '-z linker_flag'. GCC discards it without '$wl',
13397 # but is careful enough not to reorder.
13398 # Supported since Solaris 2.6 (maybe 2.5.1?)
13399 if test yes = "$GCC"; then
13400 whole_archive_flag_spec='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract'
13401 else
13402 whole_archive_flag_spec='-z allextract$convenience -z defaultextract'
13403 fi
13404 ;;
13405 esac
13406 link_all_deplibs=yes
13407 ;;
13408
13409 sunos4*)
13410 if test sequent = "$host_vendor"; then
13411 # Use $CC to link under sequent, because it throws in some extra .o
13412 # files that make .init and .fini sections work.
13413 archive_cmds='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags'
13414 else
13415 archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
13416 fi
13417 hardcode_libdir_flag_spec='-L$libdir'
13418 hardcode_direct=yes
13419 hardcode_minus_L=yes
13420 hardcode_shlibpath_var=no
13421 ;;
13422
13423 sysv4)
13424 case $host_vendor in
13425 sni)
13426 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
13427 hardcode_direct=yes # is this really true???
13428 ;;
13429 siemens)
13430 ## LD is ld it makes a PLAMLIB
13431 ## CC just makes a GrossModule.
13432 archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
13433 reload_cmds='$CC -r -o $output$reload_objs'
13434 hardcode_direct=no
13435 ;;
13436 motorola)
13437 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
13438 hardcode_direct=no #Motorola manual says yes, but my tests say they lie
13439 ;;
13440 esac
13441 runpath_var='LD_RUN_PATH'
13442 hardcode_shlibpath_var=no
13443 ;;
13444
13445 sysv4.3*)
13446 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
13447 hardcode_shlibpath_var=no
13448 export_dynamic_flag_spec='-Bexport'
13449 ;;
13450
13451 sysv4*MP*)
13452 if test -d /usr/nec; then
13453 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
13454 hardcode_shlibpath_var=no
13455 runpath_var=LD_RUN_PATH
13456 hardcode_runpath_var=yes
13457 ld_shlibs=yes
13458 fi
13459 ;;
13460
13461 sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
13462 no_undefined_flag='$wl-z,text'
13463 archive_cmds_need_lc=no
13464 hardcode_shlibpath_var=no
13465 runpath_var='LD_RUN_PATH'
13466
13467 if test yes = "$GCC"; then
13468 archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13469 archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13470 else
13471 archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13472 archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13473 fi
13474 ;;
13475
13476 sysv5* | sco3.2v5* | sco5v6*)
13477 # Note: We CANNOT use -z defs as we might desire, because we do not
13478 # link with -lc, and that would cause any symbols used from libc to
13479 # always be unresolved, which means just about no library would
13480 # ever link correctly. If we're not using GNU ld we use -z text
13481 # though, which does catch some bad symbols but isn't as heavy-handed
13482 # as -z defs.
13483 no_undefined_flag='$wl-z,text'
13484 allow_undefined_flag='$wl-z,nodefs'
13485 archive_cmds_need_lc=no
13486 hardcode_shlibpath_var=no
13487 hardcode_libdir_flag_spec='$wl-R,$libdir'
13488 hardcode_libdir_separator=':'
13489 link_all_deplibs=yes
13490 export_dynamic_flag_spec='$wl-Bexport'
13491 runpath_var='LD_RUN_PATH'
13492
13493 if test yes = "$GCC"; then
13494 archive_cmds='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13495 archive_expsym_cmds='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13496 else
13497 archive_cmds='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13498 archive_expsym_cmds='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
13499 fi
13500 ;;
13501
13502 uts4*)
13503 archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
13504 hardcode_libdir_flag_spec='-L$libdir'
13505 hardcode_shlibpath_var=no
13506 ;;
13507
13508 *)
13509 ld_shlibs=no
13510 ;;
13511 esac
13512
13513 if test sni = "$host_vendor"; then
13514 case $host in
13515 sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
13516 export_dynamic_flag_spec='$wl-Blargedynsym'
13517 ;;
13518 esac
13519 fi
13520 fi
13521
13522{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5
13523$as_echo "$ld_shlibs" >&6; }
13524test no = "$ld_shlibs" && can_build_shared=no
13525
13526with_gnu_ld=$with_gnu_ld
13527
13528
13529
13530
13531
13532
13533
13534
13535
13536
13537
13538
13539
13540
13541
13542#
13543# Do we need to explicitly link libc?
13544#
13545case "x$archive_cmds_need_lc" in
13546x|xyes)
13547 # Assume -lc should be added
13548 archive_cmds_need_lc=yes
13549
13550 if test yes,yes = "$GCC,$enable_shared"; then
13551 case $archive_cmds in
13552 *'~'*)
13553 # FIXME: we may have to deal with multi-command sequences.
13554 ;;
13555 '$CC '*)
13556 # Test whether the compiler implicitly links with -lc since on some
13557 # systems, -lgcc has to come before -lc. If gcc already passes -lc
13558 # to ld, don't add -lc before -lgcc.
13559 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
13560$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
13561if ${lt_cv_archive_cmds_need_lc+:} false; then :
13562 $as_echo_n "(cached) " >&6
13563else
13564 $RM conftest*
13565 echo "$lt_simple_compile_test_code" > conftest.$ac_ext
13566
13567 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
13568 (eval $ac_compile) 2>&5
13569 ac_status=$?
13570 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
13571 test $ac_status = 0; } 2>conftest.err; then
13572 soname=conftest
13573 lib=conftest
13574 libobjs=conftest.$ac_objext
13575 deplibs=
13576 wl=$lt_prog_compiler_wl
13577 pic_flag=$lt_prog_compiler_pic
13578 compiler_flags=-v
13579 linker_flags=-v
13580 verstring=
13581 output_objdir=.
13582 libname=conftest
13583 lt_save_allow_undefined_flag=$allow_undefined_flag
13584 allow_undefined_flag=
13585 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
13586 (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
13587 ac_status=$?
13588 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
13589 test $ac_status = 0; }
13590 then
13591 lt_cv_archive_cmds_need_lc=no
13592 else
13593 lt_cv_archive_cmds_need_lc=yes
13594 fi
13595 allow_undefined_flag=$lt_save_allow_undefined_flag
13596 else
13597 cat conftest.err 1>&5
13598 fi
13599 $RM conftest*
13600
13601fi
13602{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5
13603$as_echo "$lt_cv_archive_cmds_need_lc" >&6; }
13604 archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc
13605 ;;
13606 esac
13607 fi
13608 ;;
13609esac
13610
13611
13612
13613
13614
13615
13616
13617
13618
13619
13620
13621
13622
13623
13624
13625
13626
13627
13628
13629
13630
13631
13632
13633
13634
13635
13636
13637
13638
13639
13640
13641
13642
13643
13644
13645
13646
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 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
13763$as_echo_n "checking dynamic linker characteristics... " >&6; }
13764
13765if test yes = "$GCC"; then
13766 case $host_os in
13767 darwin*) lt_awk_arg='/^libraries:/,/LR/' ;;
13768 *) lt_awk_arg='/^libraries:/' ;;
13769 esac
13770 case $host_os in
13771 mingw* | cegcc*) lt_sed_strip_eq='s|=\([A-Za-z]:\)|\1|g' ;;
13772 *) lt_sed_strip_eq='s|=/|/|g' ;;
13773 esac
13774 lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
13775 case $lt_search_path_spec in
13776 *\;*)
13777 # if the path contains ";" then we assume it to be the separator
13778 # otherwise default to the standard path separator (i.e. ":") - it is
13779 # assumed that no part of a normal pathname contains ";" but that should
13780 # okay in the real world where ";" in dirpaths is itself problematic.
13781 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
13782 ;;
13783 *)
13784 lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
13785 ;;
13786 esac
13787 # Ok, now we have the path, separated by spaces, we can step through it
13788 # and add multilib dir if necessary...
13789 lt_tmp_lt_search_path_spec=
13790 lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
13791 # ...but if some path component already ends with the multilib dir we assume
13792 # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer).
13793 case "$lt_multi_os_dir; $lt_search_path_spec " in
13794 "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*)
13795 lt_multi_os_dir=
13796 ;;
13797 esac
13798 for lt_sys_path in $lt_search_path_spec; do
13799 if test -d "$lt_sys_path$lt_multi_os_dir"; then
13800 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir"
13801 elif test -n "$lt_multi_os_dir"; then
13802 test -d "$lt_sys_path" && \
13803 lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
13804 fi
13805 done
13806 lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
13807BEGIN {RS = " "; FS = "/|\n";} {
13808 lt_foo = "";
13809 lt_count = 0;
13810 for (lt_i = NF; lt_i > 0; lt_i--) {
13811 if ($lt_i != "" && $lt_i != ".") {
13812 if ($lt_i == "..") {
13813 lt_count++;
13814 } else {
13815 if (lt_count == 0) {
13816 lt_foo = "/" $lt_i lt_foo;
13817 } else {
13818 lt_count--;
13819 }
13820 }
13821 }
13822 }
13823 if (lt_foo != "") { lt_freq[lt_foo]++; }
13824 if (lt_freq[lt_foo] == 1) { print lt_foo; }
13825}'`
13826 # AWK program above erroneously prepends '/' to C:/dos/paths
13827 # for these hosts.
13828 case $host_os in
13829 mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
13830 $SED 's|/\([A-Za-z]:\)|\1|g'` ;;
13831 esac
13832 sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
13833else
13834 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
13835fi
13836library_names_spec=
13837libname_spec='lib$name'
13838soname_spec=
13839shrext_cmds=.so
13840postinstall_cmds=
13841postuninstall_cmds=
13842finish_cmds=
13843finish_eval=
13844shlibpath_var=
13845shlibpath_overrides_runpath=unknown
13846version_type=none
13847dynamic_linker="$host_os ld.so"
13848sys_lib_dlsearch_path_spec="/lib /usr/lib"
13849need_lib_prefix=unknown
13850hardcode_into_libs=no
13851
13852# when you set need_version to no, make sure it does not cause -set_version
13853# flags to be left without arguments
13854need_version=unknown
13855
13856
13857
13858case $host_os in
13859aix3*)
13860 version_type=linux # correct to gnu/linux during the next big refactor
13861 library_names_spec='$libname$release$shared_ext$versuffix $libname.a'
13862 shlibpath_var=LIBPATH
13863
13864 # AIX 3 has no versioning support, so we append a major version to the name.
13865 soname_spec='$libname$release$shared_ext$major'
13866 ;;
13867
13868aix[4-9]*)
13869 version_type=linux # correct to gnu/linux during the next big refactor
13870 need_lib_prefix=no
13871 need_version=no
13872 hardcode_into_libs=yes
13873 if test ia64 = "$host_cpu"; then
13874 # AIX 5 supports IA64
13875 library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext'
13876 shlibpath_var=LD_LIBRARY_PATH
13877 else
13878 # With GCC up to 2.95.x, collect2 would create an import file
13879 # for dependence libraries. The import file would start with
13880 # the line '#! .'. This would cause the generated library to
13881 # depend on '.', always an invalid library. This was fixed in
13882 # development snapshots of GCC prior to 3.0.
13883 case $host_os in
13884 aix4 | aix4.[01] | aix4.[01].*)
13885 if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
13886 echo ' yes '
13887 echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then
13888 :
13889 else
13890 can_build_shared=no
13891 fi
13892 ;;
13893 esac
13894 # Using Import Files as archive members, it is possible to support
13895 # filename-based versioning of shared library archives on AIX. While
13896 # this would work for both with and without runtime linking, it will
13897 # prevent static linking of such archives. So we do filename-based
13898 # shared library versioning with .so extension only, which is used
13899 # when both runtime linking and shared linking is enabled.
13900 # Unfortunately, runtime linking may impact performance, so we do
13901 # not want this to be the default eventually. Also, we use the
13902 # versioned .so libs for executables only if there is the -brtl
13903 # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only.
13904 # To allow for filename-based versioning support, we need to create
13905 # libNAME.so.V as an archive file, containing:
13906 # *) an Import File, referring to the versioned filename of the
13907 # archive as well as the shared archive member, telling the
13908 # bitwidth (32 or 64) of that shared object, and providing the
13909 # list of exported symbols of that shared object, eventually
13910 # decorated with the 'weak' keyword
13911 # *) the shared object with the F_LOADONLY flag set, to really avoid
13912 # it being seen by the linker.
13913 # At run time we better use the real file rather than another symlink,
13914 # but for link time we create the symlink libNAME.so -> libNAME.so.V
13915
13916 case $with_aix_soname,$aix_use_runtimelinking in
13917 # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct
13918 # soname into executable. Probably we can add versioning support to
13919 # collect2, so additional links can be useful in future.
13920 aix,yes) # traditional libtool
13921 dynamic_linker='AIX unversionable lib.so'
13922 # If using run time linking (on AIX 4.2 or later) use lib<name>.so
13923 # instead of lib<name>.a to let people know that these are not
13924 # typical AIX shared libraries.
13925 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13926 ;;
13927 aix,no) # traditional AIX only
13928 dynamic_linker='AIX lib.a(lib.so.V)'
13929 # We preserve .a as extension for shared libraries through AIX4.2
13930 # and later when we are not doing run time linking.
13931 library_names_spec='$libname$release.a $libname.a'
13932 soname_spec='$libname$release$shared_ext$major'
13933 ;;
13934 svr4,*) # full svr4 only
13935 dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o)"
13936 library_names_spec='$libname$release$shared_ext$major $libname$shared_ext'
13937 # We do not specify a path in Import Files, so LIBPATH fires.
13938 shlibpath_overrides_runpath=yes
13939 ;;
13940 *,yes) # both, prefer svr4
13941 dynamic_linker="AIX lib.so.V($shared_archive_member_spec.o), lib.a(lib.so.V)"
13942 library_names_spec='$libname$release$shared_ext$major $libname$shared_ext'
13943 # unpreferred sharedlib libNAME.a needs extra handling
13944 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"'
13945 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"'
13946 # We do not specify a path in Import Files, so LIBPATH fires.
13947 shlibpath_overrides_runpath=yes
13948 ;;
13949 *,no) # both, prefer aix
13950 dynamic_linker="AIX lib.a(lib.so.V), lib.so.V($shared_archive_member_spec.o)"
13951 library_names_spec='$libname$release.a $libname.a'
13952 soname_spec='$libname$release$shared_ext$major'
13953 # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling
13954 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)'
13955 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"'
13956 ;;
13957 esac
13958 shlibpath_var=LIBPATH
13959 fi
13960 ;;
13961
13962amigaos*)
13963 case $host_cpu in
13964 powerpc)
13965 # Since July 2007 AmigaOS4 officially supports .so libraries.
13966 # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
13967 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13968 ;;
13969 m68k)
13970 library_names_spec='$libname.ixlibrary $libname.a'
13971 # Create ${libname}_ixlibrary.a entries in /sys/libs.
13972 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'
13973 ;;
13974 esac
13975 ;;
13976
13977beos*)
13978 library_names_spec='$libname$shared_ext'
13979 dynamic_linker="$host_os ld.so"
13980 shlibpath_var=LIBRARY_PATH
13981 ;;
13982
13983bsdi[45]*)
13984 version_type=linux # correct to gnu/linux during the next big refactor
13985 need_version=no
13986 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
13987 soname_spec='$libname$release$shared_ext$major'
13988 finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
13989 shlibpath_var=LD_LIBRARY_PATH
13990 sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
13991 sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
13992 # the default ld.so.conf also contains /usr/contrib/lib and
13993 # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
13994 # libtool to hard-code these into programs
13995 ;;
13996
13997cygwin* | mingw* | pw32* | cegcc*)
13998 version_type=windows
13999 shrext_cmds=.dll
14000 need_version=no
14001 need_lib_prefix=no
14002
14003 case $GCC,$cc_basename in
14004 yes,*)
14005 # gcc
14006 library_names_spec='$libname.dll.a'
14007 # DLL is installed to $(libdir)/../bin by postinstall_cmds
14008 postinstall_cmds='base_file=`basename \$file`~
14009 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
14010 dldir=$destdir/`dirname \$dlpath`~
14011 test -d \$dldir || mkdir -p \$dldir~
14012 $install_prog $dir/$dlname \$dldir/$dlname~
14013 chmod a+x \$dldir/$dlname~
14014 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
14015 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
14016 fi'
14017 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
14018 dlpath=$dir/\$dldll~
14019 $RM \$dlpath'
14020 shlibpath_overrides_runpath=yes
14021
14022 case $host_os in
14023 cygwin*)
14024 # Cygwin DLLs use 'cyg' prefix rather than 'lib'
14025 soname_spec='`echo $libname | sed -e 's/^lib/cyg/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
14026
14027 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"
14028 ;;
14029 mingw* | cegcc*)
14030 # MinGW DLLs use traditional 'lib' prefix
14031 soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
14032 ;;
14033 pw32*)
14034 # pw32 DLLs use 'pw' prefix rather than 'lib'
14035 library_names_spec='`echo $libname | sed -e 's/^lib/pw/'``echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
14036 ;;
14037 esac
14038 dynamic_linker='Win32 ld.exe'
14039 ;;
14040
14041 *,cl*)
14042 # Native MSVC
14043 libname_spec='$name'
14044 soname_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext'
14045 library_names_spec='$libname.dll.lib'
14046
14047 case $build_os in
14048 mingw*)
14049 sys_lib_search_path_spec=
14050 lt_save_ifs=$IFS
14051 IFS=';'
14052 for lt_path in $LIB
14053 do
14054 IFS=$lt_save_ifs
14055 # Let DOS variable expansion print the short 8.3 style file name.
14056 lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
14057 sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
14058 done
14059 IFS=$lt_save_ifs
14060 # Convert to MSYS style.
14061 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'`
14062 ;;
14063 cygwin*)
14064 # Convert to unix form, then to dos form, then back to unix form
14065 # but this time dos style (no spaces!) so that the unix form looks
14066 # like /cygdrive/c/PROGRA~1:/cygdr...
14067 sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
14068 sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
14069 sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
14070 ;;
14071 *)
14072 sys_lib_search_path_spec=$LIB
14073 if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
14074 # It is most probably a Windows format PATH.
14075 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
14076 else
14077 sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
14078 fi
14079 # FIXME: find the short name or the path components, as spaces are
14080 # common. (e.g. "Program Files" -> "PROGRA~1")
14081 ;;
14082 esac
14083
14084 # DLL is installed to $(libdir)/../bin by postinstall_cmds
14085 postinstall_cmds='base_file=`basename \$file`~
14086 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~
14087 dldir=$destdir/`dirname \$dlpath`~
14088 test -d \$dldir || mkdir -p \$dldir~
14089 $install_prog $dir/$dlname \$dldir/$dlname'
14090 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
14091 dlpath=$dir/\$dldll~
14092 $RM \$dlpath'
14093 shlibpath_overrides_runpath=yes
14094 dynamic_linker='Win32 link.exe'
14095 ;;
14096
14097 *)
14098 # Assume MSVC wrapper
14099 library_names_spec='$libname`echo $release | $SED -e 's/[.]/-/g'`$versuffix$shared_ext $libname.lib'
14100 dynamic_linker='Win32 ld.exe'
14101 ;;
14102 esac
14103 # FIXME: first we should search . and the directory the executable is in
14104 shlibpath_var=PATH
14105 ;;
14106
14107darwin* | rhapsody*)
14108 dynamic_linker="$host_os dyld"
14109 version_type=darwin
14110 need_lib_prefix=no
14111 need_version=no
14112 library_names_spec='$libname$release$major$shared_ext $libname$shared_ext'
14113 soname_spec='$libname$release$major$shared_ext'
14114 shlibpath_overrides_runpath=yes
14115 shlibpath_var=DYLD_LIBRARY_PATH
14116 shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
14117
14118 sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"
14119 sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
14120 ;;
14121
14122dgux*)
14123 version_type=linux # correct to gnu/linux during the next big refactor
14124 need_lib_prefix=no
14125 need_version=no
14126 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14127 soname_spec='$libname$release$shared_ext$major'
14128 shlibpath_var=LD_LIBRARY_PATH
14129 ;;
14130
14131freebsd* | dragonfly*)
14132 # DragonFly does not have aout. When/if they implement a new
14133 # versioning mechanism, adjust this.
14134 if test -x /usr/bin/objformat; then
14135 objformat=`/usr/bin/objformat`
14136 else
14137 case $host_os in
14138 freebsd[23].*) objformat=aout ;;
14139 *) objformat=elf ;;
14140 esac
14141 fi
14142 version_type=freebsd-$objformat
14143 case $version_type in
14144 freebsd-elf*)
14145 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14146 soname_spec='$libname$release$shared_ext$major'
14147 need_version=no
14148 need_lib_prefix=no
14149 ;;
14150 freebsd-*)
14151 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
14152 need_version=yes
14153 ;;
14154 esac
14155 shlibpath_var=LD_LIBRARY_PATH
14156 case $host_os in
14157 freebsd2.*)
14158 shlibpath_overrides_runpath=yes
14159 ;;
14160 freebsd3.[01]* | freebsdelf3.[01]*)
14161 shlibpath_overrides_runpath=yes
14162 hardcode_into_libs=yes
14163 ;;
14164 freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
14165 freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
14166 shlibpath_overrides_runpath=no
14167 hardcode_into_libs=yes
14168 ;;
14169 *) # from 4.6 on, and DragonFly
14170 shlibpath_overrides_runpath=yes
14171 hardcode_into_libs=yes
14172 ;;
14173 esac
14174 ;;
14175
14176haiku*)
14177 version_type=linux # correct to gnu/linux during the next big refactor
14178 need_lib_prefix=no
14179 need_version=no
14180 dynamic_linker="$host_os runtime_loader"
14181 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14182 soname_spec='$libname$release$shared_ext$major'
14183 shlibpath_var=LIBRARY_PATH
14184 shlibpath_overrides_runpath=no
14185 sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
14186 hardcode_into_libs=yes
14187 ;;
14188
14189hpux9* | hpux10* | hpux11*)
14190 # Give a soname corresponding to the major version so that dld.sl refuses to
14191 # link against other versions.
14192 version_type=sunos
14193 need_lib_prefix=no
14194 need_version=no
14195 case $host_cpu in
14196 ia64*)
14197 shrext_cmds='.so'
14198 hardcode_into_libs=yes
14199 dynamic_linker="$host_os dld.so"
14200 shlibpath_var=LD_LIBRARY_PATH
14201 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
14202 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14203 soname_spec='$libname$release$shared_ext$major'
14204 if test 32 = "$HPUX_IA64_MODE"; then
14205 sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
14206 sys_lib_dlsearch_path_spec=/usr/lib/hpux32
14207 else
14208 sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
14209 sys_lib_dlsearch_path_spec=/usr/lib/hpux64
14210 fi
14211 ;;
14212 hppa*64*)
14213 shrext_cmds='.sl'
14214 hardcode_into_libs=yes
14215 dynamic_linker="$host_os dld.sl"
14216 shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
14217 shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
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 sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
14221 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
14222 ;;
14223 *)
14224 shrext_cmds='.sl'
14225 dynamic_linker="$host_os dld.sl"
14226 shlibpath_var=SHLIB_PATH
14227 shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
14228 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14229 soname_spec='$libname$release$shared_ext$major'
14230 ;;
14231 esac
14232 # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
14233 postinstall_cmds='chmod 555 $lib'
14234 # or fails outright, so override atomically:
14235 install_override_mode=555
14236 ;;
14237
14238interix[3-9]*)
14239 version_type=linux # correct to gnu/linux during the next big refactor
14240 need_lib_prefix=no
14241 need_version=no
14242 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14243 soname_spec='$libname$release$shared_ext$major'
14244 dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
14245 shlibpath_var=LD_LIBRARY_PATH
14246 shlibpath_overrides_runpath=no
14247 hardcode_into_libs=yes
14248 ;;
14249
14250irix5* | irix6* | nonstopux*)
14251 case $host_os in
14252 nonstopux*) version_type=nonstopux ;;
14253 *)
14254 if test yes = "$lt_cv_prog_gnu_ld"; then
14255 version_type=linux # correct to gnu/linux during the next big refactor
14256 else
14257 version_type=irix
14258 fi ;;
14259 esac
14260 need_lib_prefix=no
14261 need_version=no
14262 soname_spec='$libname$release$shared_ext$major'
14263 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext'
14264 case $host_os in
14265 irix5* | nonstopux*)
14266 libsuff= shlibsuff=
14267 ;;
14268 *)
14269 case $LD in # libtool.m4 will add one of these switches to LD
14270 *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
14271 libsuff= shlibsuff= libmagic=32-bit;;
14272 *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
14273 libsuff=32 shlibsuff=N32 libmagic=N32;;
14274 *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
14275 libsuff=64 shlibsuff=64 libmagic=64-bit;;
14276 *) libsuff= shlibsuff= libmagic=never-match;;
14277 esac
14278 ;;
14279 esac
14280 shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
14281 shlibpath_overrides_runpath=no
14282 sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff"
14283 sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff"
14284 hardcode_into_libs=yes
14285 ;;
14286
14287# No shared lib support for Linux oldld, aout, or coff.
14288linux*oldld* | linux*aout* | linux*coff*)
14289 dynamic_linker=no
14290 ;;
14291
14292linux*android*)
14293 version_type=none # Android doesn't support versioned libraries.
14294 need_lib_prefix=no
14295 need_version=no
14296 library_names_spec='$libname$release$shared_ext'
14297 soname_spec='$libname$release$shared_ext'
14298 finish_cmds=
14299 shlibpath_var=LD_LIBRARY_PATH
14300 shlibpath_overrides_runpath=yes
14301
14302 # This implies no fast_install, which is unacceptable.
14303 # Some rework will be needed to allow for fast_install
14304 # before this can be enabled.
14305 hardcode_into_libs=yes
14306
14307 dynamic_linker='Android linker'
14308 # Don't embed -rpath directories since the linker doesn't support them.
14309 hardcode_libdir_flag_spec='-L$libdir'
14310 ;;
14311
14312# This must be glibc/ELF.
14313linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*)
14314 version_type=linux # correct to gnu/linux during the next big refactor
14315 need_lib_prefix=no
14316 need_version=no
14317 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14318 soname_spec='$libname$release$shared_ext$major'
14319 finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
14320 shlibpath_var=LD_LIBRARY_PATH
14321 shlibpath_overrides_runpath=no
14322
14323 # Some binutils ld are patched to set DT_RUNPATH
14324 if ${lt_cv_shlibpath_overrides_runpath+:} false; then :
14325 $as_echo_n "(cached) " >&6
14326else
14327 lt_cv_shlibpath_overrides_runpath=no
14328 save_LDFLAGS=$LDFLAGS
14329 save_libdir=$libdir
14330 eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \
14331 LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\""
14332 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14333/* end confdefs.h. */
14334
14335int main (void)
14336{
14337
14338 ;
14339 return 0;
14340}
14341_ACEOF
14342if ac_fn_c_try_link "$LINENO"; then :
14343 if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then :
14344 lt_cv_shlibpath_overrides_runpath=yes
14345fi
14346fi
14347rm -f core conftest.err conftest.$ac_objext \
14348 conftest$ac_exeext conftest.$ac_ext
14349 LDFLAGS=$save_LDFLAGS
14350 libdir=$save_libdir
14351
14352fi
14353
14354 shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
14355
14356 # This implies no fast_install, which is unacceptable.
14357 # Some rework will be needed to allow for fast_install
14358 # before this can be enabled.
14359 hardcode_into_libs=yes
14360
14361 # Ideally, we could use ldconfig to report *all* directores which are
14362 # searched for libraries, however this is still not possible. Aside from not
14363 # being certain /sbin/ldconfig is available, command
14364 # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64,
14365 # even though it is searched at run-time. Try to do the best guess by
14366 # appending ld.so.conf contents (and includes) to the search path.
14367 if test -f /etc/ld.so.conf; then
14368 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' ' '`
14369 sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
14370 fi
14371
14372 # We used to test for /lib/ld.so.1 and disable shared libraries on
14373 # powerpc, because MkLinux only supported shared libraries with the
14374 # GNU dynamic linker. Since this was broken with cross compilers,
14375 # most powerpc-linux boxes support dynamic linking these days and
14376 # people can always --disable-shared, the test was removed, and we
14377 # assume the GNU/Linux dynamic linker is in use.
14378 dynamic_linker='GNU/Linux ld.so'
14379 ;;
14380
14381netbsdelf*-gnu)
14382 version_type=linux
14383 need_lib_prefix=no
14384 need_version=no
14385 library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
14386 soname_spec='${libname}${release}${shared_ext}$major'
14387 shlibpath_var=LD_LIBRARY_PATH
14388 shlibpath_overrides_runpath=no
14389 hardcode_into_libs=yes
14390 dynamic_linker='NetBSD ld.elf_so'
14391 ;;
14392
14393netbsd*)
14394 version_type=sunos
14395 need_lib_prefix=no
14396 need_version=no
14397 if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
14398 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
14399 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
14400 dynamic_linker='NetBSD (a.out) ld.so'
14401 else
14402 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14403 soname_spec='$libname$release$shared_ext$major'
14404 dynamic_linker='NetBSD ld.elf_so'
14405 fi
14406 shlibpath_var=LD_LIBRARY_PATH
14407 shlibpath_overrides_runpath=yes
14408 hardcode_into_libs=yes
14409 ;;
14410
14411newsos6)
14412 version_type=linux # correct to gnu/linux during the next big refactor
14413 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14414 shlibpath_var=LD_LIBRARY_PATH
14415 shlibpath_overrides_runpath=yes
14416 ;;
14417
14418*nto* | *qnx*)
14419 version_type=qnx
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='ldqnx.so'
14428 ;;
14429
14430openbsd* | bitrig*)
14431 version_type=sunos
14432 sys_lib_dlsearch_path_spec=/usr/lib
14433 need_lib_prefix=no
14434 if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then
14435 need_version=no
14436 else
14437 need_version=yes
14438 fi
14439 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
14440 finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
14441 shlibpath_var=LD_LIBRARY_PATH
14442 shlibpath_overrides_runpath=yes
14443 ;;
14444
14445os2*)
14446 libname_spec='$name'
14447 version_type=windows
14448 shrext_cmds=.dll
14449 need_version=no
14450 need_lib_prefix=no
14451 # OS/2 can only load a DLL with a base name of 8 characters or less.
14452 soname_spec='`test -n "$os2dllname" && libname="$os2dllname";
14453 v=$($ECHO $release$versuffix | tr -d .-);
14454 n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _);
14455 $ECHO $n$v`$shared_ext'
14456 library_names_spec='${libname}_dll.$libext'
14457 dynamic_linker='OS/2 ld.exe'
14458 shlibpath_var=BEGINLIBPATH
14459 sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
14460 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
14461 postinstall_cmds='base_file=`basename \$file`~
14462 dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~
14463 dldir=$destdir/`dirname \$dlpath`~
14464 test -d \$dldir || mkdir -p \$dldir~
14465 $install_prog $dir/$dlname \$dldir/$dlname~
14466 chmod a+x \$dldir/$dlname~
14467 if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
14468 eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
14469 fi'
14470 postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~
14471 dlpath=$dir/\$dldll~
14472 $RM \$dlpath'
14473 ;;
14474
14475osf3* | osf4* | osf5*)
14476 version_type=osf
14477 need_lib_prefix=no
14478 need_version=no
14479 soname_spec='$libname$release$shared_ext$major'
14480 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14481 shlibpath_var=LD_LIBRARY_PATH
14482 sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
14483 sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
14484 ;;
14485
14486rdos*)
14487 dynamic_linker=no
14488 ;;
14489
14490solaris*)
14491 version_type=linux # correct to gnu/linux during the next big refactor
14492 need_lib_prefix=no
14493 need_version=no
14494 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14495 soname_spec='$libname$release$shared_ext$major'
14496 shlibpath_var=LD_LIBRARY_PATH
14497 shlibpath_overrides_runpath=yes
14498 hardcode_into_libs=yes
14499 # ldd complains unless libraries are executable
14500 postinstall_cmds='chmod +x $lib'
14501 ;;
14502
14503sunos4*)
14504 version_type=sunos
14505 library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix'
14506 finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
14507 shlibpath_var=LD_LIBRARY_PATH
14508 shlibpath_overrides_runpath=yes
14509 if test yes = "$with_gnu_ld"; then
14510 need_lib_prefix=no
14511 fi
14512 need_version=yes
14513 ;;
14514
14515sysv4 | sysv4.3*)
14516 version_type=linux # correct to gnu/linux during the next big refactor
14517 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14518 soname_spec='$libname$release$shared_ext$major'
14519 shlibpath_var=LD_LIBRARY_PATH
14520 case $host_vendor in
14521 sni)
14522 shlibpath_overrides_runpath=no
14523 need_lib_prefix=no
14524 runpath_var=LD_RUN_PATH
14525 ;;
14526 siemens)
14527 need_lib_prefix=no
14528 ;;
14529 motorola)
14530 need_lib_prefix=no
14531 need_version=no
14532 shlibpath_overrides_runpath=no
14533 sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
14534 ;;
14535 esac
14536 ;;
14537
14538sysv4*MP*)
14539 if test -d /usr/nec; then
14540 version_type=linux # correct to gnu/linux during the next big refactor
14541 library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext'
14542 soname_spec='$libname$shared_ext.$major'
14543 shlibpath_var=LD_LIBRARY_PATH
14544 fi
14545 ;;
14546
14547sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
14548 version_type=sco
14549 need_lib_prefix=no
14550 need_version=no
14551 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext'
14552 soname_spec='$libname$release$shared_ext$major'
14553 shlibpath_var=LD_LIBRARY_PATH
14554 shlibpath_overrides_runpath=yes
14555 hardcode_into_libs=yes
14556 if test yes = "$with_gnu_ld"; then
14557 sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
14558 else
14559 sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
14560 case $host_os in
14561 sco3.2v5*)
14562 sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
14563 ;;
14564 esac
14565 fi
14566 sys_lib_dlsearch_path_spec='/usr/lib'
14567 ;;
14568
14569tpf*)
14570 # TPF is a cross-target only. Preferred cross-host = GNU/Linux.
14571 version_type=linux # correct to gnu/linux during the next big refactor
14572 need_lib_prefix=no
14573 need_version=no
14574 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14575 shlibpath_var=LD_LIBRARY_PATH
14576 shlibpath_overrides_runpath=no
14577 hardcode_into_libs=yes
14578 ;;
14579
14580uts4*)
14581 version_type=linux # correct to gnu/linux during the next big refactor
14582 library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext'
14583 soname_spec='$libname$release$shared_ext$major'
14584 shlibpath_var=LD_LIBRARY_PATH
14585 ;;
14586
14587*)
14588 dynamic_linker=no
14589 ;;
14590esac
14591{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
14592$as_echo "$dynamic_linker" >&6; }
14593test no = "$dynamic_linker" && can_build_shared=no
14594
14595variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
14596if test yes = "$GCC"; then
14597 variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
14598fi
14599
14600if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then
14601 sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec
14602fi
14603
14604if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then
14605 sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec
14606fi
14607
14608# remember unaugmented sys_lib_dlsearch_path content for libtool script decls...
14609configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec
14610
14611# ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code
14612func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH"
14613
14614# to be used as default LT_SYS_LIBRARY_PATH value in generated libtool
14615configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH
14616
14617
14618
14619
14620
14621
14622
14623
14624
14625
14626
14627
14628
14629
14630
14631
14632
14633
14634
14635
14636
14637
14638
14639
14640
14641
14642
14643
14644
14645
14646
14647
14648
14649
14650
14651
14652
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 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
14714$as_echo_n "checking how to hardcode library paths into programs... " >&6; }
14715hardcode_action=
14716if test -n "$hardcode_libdir_flag_spec" ||
14717 test -n "$runpath_var" ||
14718 test yes = "$hardcode_automatic"; then
14719
14720 # We can hardcode non-existent directories.
14721 if test no != "$hardcode_direct" &&
14722 # If the only mechanism to avoid hardcoding is shlibpath_var, we
14723 # have to relink, otherwise we might link with an installed library
14724 # when we should be linking with a yet-to-be-installed one
14725 ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, )" &&
14726 test no != "$hardcode_minus_L"; then
14727 # Linking always hardcodes the temporary library directory.
14728 hardcode_action=relink
14729 else
14730 # We can link without hardcoding, and we can hardcode nonexisting dirs.
14731 hardcode_action=immediate
14732 fi
14733else
14734 # We cannot hardcode anything, or else we can only hardcode existing
14735 # directories.
14736 hardcode_action=unsupported
14737fi
14738{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5
14739$as_echo "$hardcode_action" >&6; }
14740
14741if test relink = "$hardcode_action" ||
14742 test yes = "$inherit_rpath"; then
14743 # Fast installation is not supported
14744 enable_fast_install=no
14745elif test yes = "$shlibpath_overrides_runpath" ||
14746 test no = "$enable_shared"; then
14747 # Fast installation is not necessary
14748 enable_fast_install=needless
14749fi
14750
14751
14752
14753
14754
14755
14756 if test yes != "$enable_dlopen"; then
14757 enable_dlopen=unknown
14758 enable_dlopen_self=unknown
14759 enable_dlopen_self_static=unknown
14760else
14761 lt_cv_dlopen=no
14762 lt_cv_dlopen_libs=
14763
14764 case $host_os in
14765 beos*)
14766 lt_cv_dlopen=load_add_on
14767 lt_cv_dlopen_libs=
14768 lt_cv_dlopen_self=yes
14769 ;;
14770
14771 mingw* | pw32* | cegcc*)
14772 lt_cv_dlopen=LoadLibrary
14773 lt_cv_dlopen_libs=
14774 ;;
14775
14776 cygwin*)
14777 lt_cv_dlopen=dlopen
14778 lt_cv_dlopen_libs=
14779 ;;
14780
14781 darwin*)
14782 # if libdl is installed we need to link against it
14783 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
14784$as_echo_n "checking for dlopen in -ldl... " >&6; }
14785if ${ac_cv_lib_dl_dlopen+:} false; then :
14786 $as_echo_n "(cached) " >&6
14787else
14788 ac_check_lib_save_LIBS=$LIBS
14789LIBS="-ldl $LIBS"
14790cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14791/* end confdefs.h. */
14792
14793
14794#ifdef __cplusplus
14795extern "C"
14796#endif
14797char dlopen ();
14798int main (void)
14799{
14800return dlopen ();
14801 ;
14802 return 0;
14803}
14804_ACEOF
14805if ac_fn_c_try_link "$LINENO"; then :
14806 ac_cv_lib_dl_dlopen=yes
14807else
14808 ac_cv_lib_dl_dlopen=no
14809fi
14810rm -f core conftest.err conftest.$ac_objext \
14811 conftest$ac_exeext conftest.$ac_ext
14812LIBS=$ac_check_lib_save_LIBS
14813fi
14814{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
14815$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
14816if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
14817 lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl
14818else
14819
14820 lt_cv_dlopen=dyld
14821 lt_cv_dlopen_libs=
14822 lt_cv_dlopen_self=yes
14823
14824fi
14825
14826 ;;
14827
14828 tpf*)
14829 # Don't try to run any link tests for TPF. We know it's impossible
14830 # because TPF is a cross-compiler, and we know how we open DSOs.
14831 lt_cv_dlopen=dlopen
14832 lt_cv_dlopen_libs=
14833 lt_cv_dlopen_self=no
14834 ;;
14835
14836 *)
14837 ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load"
14838if test "x$ac_cv_func_shl_load" = xyes; then :
14839 lt_cv_dlopen=shl_load
14840else
14841 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
14842$as_echo_n "checking for shl_load in -ldld... " >&6; }
14843if ${ac_cv_lib_dld_shl_load+:} false; then :
14844 $as_echo_n "(cached) " >&6
14845else
14846 ac_check_lib_save_LIBS=$LIBS
14847LIBS="-ldld $LIBS"
14848cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14849/* end confdefs.h. */
14850
14851
14852#ifdef __cplusplus
14853extern "C"
14854#endif
14855char shl_load ();
14856int main (void)
14857{
14858return shl_load ();
14859 ;
14860 return 0;
14861}
14862_ACEOF
14863if ac_fn_c_try_link "$LINENO"; then :
14864 ac_cv_lib_dld_shl_load=yes
14865else
14866 ac_cv_lib_dld_shl_load=no
14867fi
14868rm -f core conftest.err conftest.$ac_objext \
14869 conftest$ac_exeext conftest.$ac_ext
14870LIBS=$ac_check_lib_save_LIBS
14871fi
14872{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
14873$as_echo "$ac_cv_lib_dld_shl_load" >&6; }
14874if test "x$ac_cv_lib_dld_shl_load" = xyes; then :
14875 lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld
14876else
14877 ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
14878if test "x$ac_cv_func_dlopen" = xyes; then :
14879 lt_cv_dlopen=dlopen
14880else
14881 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
14882$as_echo_n "checking for dlopen in -ldl... " >&6; }
14883if ${ac_cv_lib_dl_dlopen+:} false; then :
14884 $as_echo_n "(cached) " >&6
14885else
14886 ac_check_lib_save_LIBS=$LIBS
14887LIBS="-ldl $LIBS"
14888cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14889/* end confdefs.h. */
14890
14891
14892#ifdef __cplusplus
14893extern "C"
14894#endif
14895char dlopen ();
14896int main (void)
14897{
14898return dlopen ();
14899 ;
14900 return 0;
14901}
14902_ACEOF
14903if ac_fn_c_try_link "$LINENO"; then :
14904 ac_cv_lib_dl_dlopen=yes
14905else
14906 ac_cv_lib_dl_dlopen=no
14907fi
14908rm -f core conftest.err conftest.$ac_objext \
14909 conftest$ac_exeext conftest.$ac_ext
14910LIBS=$ac_check_lib_save_LIBS
14911fi
14912{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
14913$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
14914if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
14915 lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl
14916else
14917 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5
14918$as_echo_n "checking for dlopen in -lsvld... " >&6; }
14919if ${ac_cv_lib_svld_dlopen+:} false; then :
14920 $as_echo_n "(cached) " >&6
14921else
14922 ac_check_lib_save_LIBS=$LIBS
14923LIBS="-lsvld $LIBS"
14924cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14925/* end confdefs.h. */
14926
14927
14928#ifdef __cplusplus
14929extern "C"
14930#endif
14931char dlopen ();
14932int main (void)
14933{
14934return dlopen ();
14935 ;
14936 return 0;
14937}
14938_ACEOF
14939if ac_fn_c_try_link "$LINENO"; then :
14940 ac_cv_lib_svld_dlopen=yes
14941else
14942 ac_cv_lib_svld_dlopen=no
14943fi
14944rm -f core conftest.err conftest.$ac_objext \
14945 conftest$ac_exeext conftest.$ac_ext
14946LIBS=$ac_check_lib_save_LIBS
14947fi
14948{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5
14949$as_echo "$ac_cv_lib_svld_dlopen" >&6; }
14950if test "x$ac_cv_lib_svld_dlopen" = xyes; then :
14951 lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld
14952else
14953 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5
14954$as_echo_n "checking for dld_link in -ldld... " >&6; }
14955if ${ac_cv_lib_dld_dld_link+:} false; then :
14956 $as_echo_n "(cached) " >&6
14957else
14958 ac_check_lib_save_LIBS=$LIBS
14959LIBS="-ldld $LIBS"
14960cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14961/* end confdefs.h. */
14962
14963
14964#ifdef __cplusplus
14965extern "C"
14966#endif
14967char dld_link ();
14968int main (void)
14969{
14970return dld_link ();
14971 ;
14972 return 0;
14973}
14974_ACEOF
14975if ac_fn_c_try_link "$LINENO"; then :
14976 ac_cv_lib_dld_dld_link=yes
14977else
14978 ac_cv_lib_dld_dld_link=no
14979fi
14980rm -f core conftest.err conftest.$ac_objext \
14981 conftest$ac_exeext conftest.$ac_ext
14982LIBS=$ac_check_lib_save_LIBS
14983fi
14984{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5
14985$as_echo "$ac_cv_lib_dld_dld_link" >&6; }
14986if test "x$ac_cv_lib_dld_dld_link" = xyes; then :
14987 lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld
14988fi
14989
14990
14991fi
14992
14993
14994fi
14995
14996
14997fi
14998
14999
15000fi
15001
15002
15003fi
15004
15005 ;;
15006 esac
15007
15008 if test no = "$lt_cv_dlopen"; then
15009 enable_dlopen=no
15010 else
15011 enable_dlopen=yes
15012 fi
15013
15014 case $lt_cv_dlopen in
15015 dlopen)
15016 save_CPPFLAGS=$CPPFLAGS
15017 test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
15018
15019 save_LDFLAGS=$LDFLAGS
15020 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
15021
15022 save_LIBS=$LIBS
15023 LIBS="$lt_cv_dlopen_libs $LIBS"
15024
15025 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5
15026$as_echo_n "checking whether a program can dlopen itself... " >&6; }
15027if ${lt_cv_dlopen_self+:} false; then :
15028 $as_echo_n "(cached) " >&6
15029else
15030 if test yes = "$cross_compiling"; then :
15031 lt_cv_dlopen_self=cross
15032else
15033 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
15034 lt_status=$lt_dlunknown
15035 cat > conftest.$ac_ext <<_LT_EOF
15036#line $LINENO "configure"
15037#include "confdefs.h"
15038
15039#if HAVE_DLFCN_H
15040#include <dlfcn.h>
15041#endif
15042
15043#include <stdio.h>
15044
15045#ifdef RTLD_GLOBAL
15046# define LT_DLGLOBAL RTLD_GLOBAL
15047#else
15048# ifdef DL_GLOBAL
15049# define LT_DLGLOBAL DL_GLOBAL
15050# else
15051# define LT_DLGLOBAL 0
15052# endif
15053#endif
15054
15055/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
15056 find out it does not work in some platform. */
15057#ifndef LT_DLLAZY_OR_NOW
15058# ifdef RTLD_LAZY
15059# define LT_DLLAZY_OR_NOW RTLD_LAZY
15060# else
15061# ifdef DL_LAZY
15062# define LT_DLLAZY_OR_NOW DL_LAZY
15063# else
15064# ifdef RTLD_NOW
15065# define LT_DLLAZY_OR_NOW RTLD_NOW
15066# else
15067# ifdef DL_NOW
15068# define LT_DLLAZY_OR_NOW DL_NOW
15069# else
15070# define LT_DLLAZY_OR_NOW 0
15071# endif
15072# endif
15073# endif
15074# endif
15075#endif
15076
15077/* When -fvisibility=hidden is used, assume the code has been annotated
15078 correspondingly for the symbols needed. */
15079#if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
15080int fnord () __attribute__((visibility("default")));
15081#endif
15082
15083int fnord () { return 42; }
15084int main ()
15085{
15086 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
15087 int status = $lt_dlunknown;
15088
15089 if (self)
15090 {
15091 if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
15092 else
15093 {
15094 if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
15095 else puts (dlerror ());
15096 }
15097 /* dlclose (self); */
15098 }
15099 else
15100 puts (dlerror ());
15101
15102 return status;
15103}
15104_LT_EOF
15105 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
15106 (eval $ac_link) 2>&5
15107 ac_status=$?
15108 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
15109 test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then
15110 (./conftest; exit; ) >&5 2>/dev/null
15111 lt_status=$?
15112 case x$lt_status in
15113 x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
15114 x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
15115 x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;;
15116 esac
15117 else :
15118 # compilation failed
15119 lt_cv_dlopen_self=no
15120 fi
15121fi
15122rm -fr conftest*
15123
15124
15125fi
15126{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5
15127$as_echo "$lt_cv_dlopen_self" >&6; }
15128
15129 if test yes = "$lt_cv_dlopen_self"; then
15130 wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
15131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5
15132$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; }
15133if ${lt_cv_dlopen_self_static+:} false; then :
15134 $as_echo_n "(cached) " >&6
15135else
15136 if test yes = "$cross_compiling"; then :
15137 lt_cv_dlopen_self_static=cross
15138else
15139 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
15140 lt_status=$lt_dlunknown
15141 cat > conftest.$ac_ext <<_LT_EOF
15142#line $LINENO "configure"
15143#include "confdefs.h"
15144
15145#if HAVE_DLFCN_H
15146#include <dlfcn.h>
15147#endif
15148
15149#include <stdio.h>
15150
15151#ifdef RTLD_GLOBAL
15152# define LT_DLGLOBAL RTLD_GLOBAL
15153#else
15154# ifdef DL_GLOBAL
15155# define LT_DLGLOBAL DL_GLOBAL
15156# else
15157# define LT_DLGLOBAL 0
15158# endif
15159#endif
15160
15161/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
15162 find out it does not work in some platform. */
15163#ifndef LT_DLLAZY_OR_NOW
15164# ifdef RTLD_LAZY
15165# define LT_DLLAZY_OR_NOW RTLD_LAZY
15166# else
15167# ifdef DL_LAZY
15168# define LT_DLLAZY_OR_NOW DL_LAZY
15169# else
15170# ifdef RTLD_NOW
15171# define LT_DLLAZY_OR_NOW RTLD_NOW
15172# else
15173# ifdef DL_NOW
15174# define LT_DLLAZY_OR_NOW DL_NOW
15175# else
15176# define LT_DLLAZY_OR_NOW 0
15177# endif
15178# endif
15179# endif
15180# endif
15181#endif
15182
15183/* When -fvisibility=hidden is used, assume the code has been annotated
15184 correspondingly for the symbols needed. */
15185#if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
15186int fnord () __attribute__((visibility("default")));
15187#endif
15188
15189int fnord () { return 42; }
15190int main ()
15191{
15192 void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
15193 int status = $lt_dlunknown;
15194
15195 if (self)
15196 {
15197 if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
15198 else
15199 {
15200 if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
15201 else puts (dlerror ());
15202 }
15203 /* dlclose (self); */
15204 }
15205 else
15206 puts (dlerror ());
15207
15208 return status;
15209}
15210_LT_EOF
15211 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
15212 (eval $ac_link) 2>&5
15213 ac_status=$?
15214 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
15215 test $ac_status = 0; } && test -s "conftest$ac_exeext" 2>/dev/null; then
15216 (./conftest; exit; ) >&5 2>/dev/null
15217 lt_status=$?
15218 case x$lt_status in
15219 x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
15220 x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
15221 x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;;
15222 esac
15223 else :
15224 # compilation failed
15225 lt_cv_dlopen_self_static=no
15226 fi
15227fi
15228rm -fr conftest*
15229
15230
15231fi
15232{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5
15233$as_echo "$lt_cv_dlopen_self_static" >&6; }
15234 fi
15235
15236 CPPFLAGS=$save_CPPFLAGS
15237 LDFLAGS=$save_LDFLAGS
15238 LIBS=$save_LIBS
15239 ;;
15240 esac
15241
15242 case $lt_cv_dlopen_self in
15243 yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
15244 *) enable_dlopen_self=unknown ;;
15245 esac
15246
15247 case $lt_cv_dlopen_self_static in
15248 yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
15249 *) enable_dlopen_self_static=unknown ;;
15250 esac
15251fi
15252
15253
15254
15255
15256
15257
15258
15259
15260
15261
15262
15263
15264
15265
15266
15267
15268
15269striplib=
15270old_striplib=
15271{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5
15272$as_echo_n "checking whether stripping libraries is possible... " >&6; }
15273if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
15274 test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
15275 test -z "$striplib" && striplib="$STRIP --strip-unneeded"
15276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15277$as_echo "yes" >&6; }
15278else
15279# FIXME - insert some real tests, host_os isn't really good enough
15280 case $host_os in
15281 darwin*)
15282 if test -n "$STRIP"; then
15283 striplib="$STRIP -x"
15284 old_striplib="$STRIP -S"
15285 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15286$as_echo "yes" >&6; }
15287 else
15288 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15289$as_echo "no" >&6; }
15290 fi
15291 ;;
15292 *)
15293 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15294$as_echo "no" >&6; }
15295 ;;
15296 esac
15297fi
15298
15299
15300
15301
15302
15303
15304
15305
15306
15307
15308
15309
15310 # Report what library types will actually be built
15311 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5
15312$as_echo_n "checking if libtool supports shared libraries... " >&6; }
15313 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5
15314$as_echo "$can_build_shared" >&6; }
15315
15316 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5
15317$as_echo_n "checking whether to build shared libraries... " >&6; }
15318 test no = "$can_build_shared" && enable_shared=no
15319
15320 # On AIX, shared libraries and static libraries use the same namespace, and
15321 # are all built from PIC.
15322 case $host_os in
15323 aix3*)
15324 test yes = "$enable_shared" && enable_static=no
15325 if test -n "$RANLIB"; then
15326 archive_cmds="$archive_cmds~\$RANLIB \$lib"
15327 postinstall_cmds='$RANLIB $lib'
15328 fi
15329 ;;
15330
15331 aix[4-9]*)
15332 if test ia64 != "$host_cpu"; then
15333 case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in
15334 yes,aix,yes) ;; # shared object as lib.so file only
15335 yes,svr4,*) ;; # shared object as lib.so archive member only
15336 yes,*) enable_static=no ;; # shared object in lib.a archive as well
15337 esac
15338 fi
15339 ;;
15340 esac
15341 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5
15342$as_echo "$enable_shared" >&6; }
15343
15344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5
15345$as_echo_n "checking whether to build static libraries... " >&6; }
15346 # Make sure either enable_shared or enable_static is yes.
15347 test yes = "$enable_shared" || enable_static=yes
15348 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5
15349$as_echo "$enable_static" >&6; }
15350
15351
15352
15353
15354fi
15355ac_ext=c
15356ac_cpp='$CPP $CPPFLAGS'
15357ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
15358ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
15359ac_compiler_gnu=$ac_cv_c_compiler_gnu
15360
15361CC=$lt_save_CC
15362
15363
15364
15365
15366
15367
15368
15369
15370
15371
15372
15373
15374
15375
15376
15377 ac_config_commands="$ac_config_commands libtool"
15378
15379
15380
15381
15382# Only expand once:
15383
15384
15385## --------------------- ##
15386## End of libtool code ##
15387## --------------------- ##
15388
15389#
15390# Verify if finally libtool shared libraries will be built
15391#
15392
15393case "x$enable_shared" in # ((
15394 xyes | xno)
15395 xc_lt_build_shared=$enable_shared
15396 ;;
15397 *)
15398 as_fn_error $? "unexpected libtool enable_shared value: $enable_shared" "$LINENO" 5
15399 ;;
15400esac
15401
15402#
15403# Verify if finally libtool static libraries will be built
15404#
15405
15406case "x$enable_static" in # ((
15407 xyes | xno)
15408 xc_lt_build_static=$enable_static
15409 ;;
15410 *)
15411 as_fn_error $? "unexpected libtool enable_static value: $enable_static" "$LINENO" 5
15412 ;;
15413esac
15414
15415#
15416# Verify if libtool shared libraries should be linked using flag -version-info
15417#
15418
15419{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries with -version-info" >&5
15420$as_echo_n "checking whether to build shared libraries with -version-info... " >&6; }
15421xc_lt_shlib_use_version_info='yes'
15422if test "x$version_type" = 'xnone'; then
15423 xc_lt_shlib_use_version_info='no'
15424fi
15425case $host_os in # (
15426 amigaos*)
15427 xc_lt_shlib_use_version_info='yes'
15428 ;;
15429esac
15430{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $xc_lt_shlib_use_version_info" >&5
15431$as_echo "$xc_lt_shlib_use_version_info" >&6; }
15432
15433#
15434# Verify if libtool shared libraries should be linked using flag -no-undefined
15435#
15436
15437{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries with -no-undefined" >&5
15438$as_echo_n "checking whether to build shared libraries with -no-undefined... " >&6; }
15439xc_lt_shlib_use_no_undefined='no'
15440if test "x$allow_undefined" = 'xno'; then
15441 xc_lt_shlib_use_no_undefined='yes'
15442elif test "x$allow_undefined_flag" = 'xunsupported'; then
15443 xc_lt_shlib_use_no_undefined='yes'
15444fi
15445case $host_os in # (
15446 cygwin* | mingw* | pw32* | cegcc* | os2* | aix*)
15447 xc_lt_shlib_use_no_undefined='yes'
15448 ;;
15449esac
15450{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $xc_lt_shlib_use_no_undefined" >&5
15451$as_echo "$xc_lt_shlib_use_no_undefined" >&6; }
15452
15453#
15454# Verify if libtool shared libraries should be linked using flag -mimpure-text
15455#
15456
15457{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries with -mimpure-text" >&5
15458$as_echo_n "checking whether to build shared libraries with -mimpure-text... " >&6; }
15459xc_lt_shlib_use_mimpure_text='no'
15460case $host_os in # (
15461 solaris2*)
15462 if test "x$GCC" = 'xyes'; then
15463 xc_lt_shlib_use_mimpure_text='yes'
15464 fi
15465 ;;
15466esac
15467{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $xc_lt_shlib_use_mimpure_text" >&5
15468$as_echo "$xc_lt_shlib_use_mimpure_text" >&6; }
15469
15470#
15471# Find out whether libtool libraries would be built wit PIC
15472#
15473
15474case "x$pic_mode" in # ((((
15475 xdefault)
15476 xc_lt_build_shared_with_pic='yes'
15477 xc_lt_build_static_with_pic='no'
15478 ;;
15479 xyes)
15480 xc_lt_build_shared_with_pic='yes'
15481 xc_lt_build_static_with_pic='yes'
15482 ;;
15483 xno)
15484 xc_lt_build_shared_with_pic='no'
15485 xc_lt_build_static_with_pic='no'
15486 ;;
15487 *)
15488 xc_lt_build_shared_with_pic='unknown'
15489 xc_lt_build_static_with_pic='unknown'
15490 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unexpected libtool pic_mode value: $pic_mode" >&5
15491$as_echo "$as_me: WARNING: unexpected libtool pic_mode value: $pic_mode" >&2;}
15492 ;;
15493esac
15494{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries with PIC" >&5
15495$as_echo_n "checking whether to build shared libraries with PIC... " >&6; }
15496{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $xc_lt_build_shared_with_pic" >&5
15497$as_echo "$xc_lt_build_shared_with_pic" >&6; }
15498{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries with PIC" >&5
15499$as_echo_n "checking whether to build static libraries with PIC... " >&6; }
15500{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $xc_lt_build_static_with_pic" >&5
15501$as_echo "$xc_lt_build_static_with_pic" >&6; }
15502
15503#
15504# Verify if libtool shared libraries will be built while static not built
15505#
15506
15507{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries only" >&5
15508$as_echo_n "checking whether to build shared libraries only... " >&6; }
15509if test "$xc_lt_build_shared" = 'yes' &&
15510 test "$xc_lt_build_static" = 'no'; then
15511 xc_lt_build_shared_only='yes'
15512else
15513 xc_lt_build_shared_only='no'
15514fi
15515{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $xc_lt_build_shared_only" >&5
15516$as_echo "$xc_lt_build_shared_only" >&6; }
15517
15518#
15519# Verify if libtool static libraries will be built while shared not built
15520#
15521
15522{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries only" >&5
15523$as_echo_n "checking whether to build static libraries only... " >&6; }
15524if test "$xc_lt_build_static" = 'yes' &&
15525 test "$xc_lt_build_shared" = 'no'; then
15526 xc_lt_build_static_only='yes'
15527else
15528 xc_lt_build_static_only='no'
15529fi
15530{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $xc_lt_build_static_only" >&5
15531$as_echo "$xc_lt_build_static_only" >&6; }
15532
15533
15534
15535
15536#
15537# Automake conditionals based on libtool related checks
15538#
15539
15540 if test "x$xc_lt_shlib_use_version_info" = 'xyes'; then
15541 CURL_LT_SHLIB_USE_VERSION_INFO_TRUE=
15542 CURL_LT_SHLIB_USE_VERSION_INFO_FALSE='#'
15543else
15544 CURL_LT_SHLIB_USE_VERSION_INFO_TRUE='#'
15545 CURL_LT_SHLIB_USE_VERSION_INFO_FALSE=
15546fi
15547
15548 if test "x$xc_lt_shlib_use_no_undefined" = 'xyes'; then
15549 CURL_LT_SHLIB_USE_NO_UNDEFINED_TRUE=
15550 CURL_LT_SHLIB_USE_NO_UNDEFINED_FALSE='#'
15551else
15552 CURL_LT_SHLIB_USE_NO_UNDEFINED_TRUE='#'
15553 CURL_LT_SHLIB_USE_NO_UNDEFINED_FALSE=
15554fi
15555
15556 if test "x$xc_lt_shlib_use_mimpure_text" = 'xyes'; then
15557 CURL_LT_SHLIB_USE_MIMPURE_TEXT_TRUE=
15558 CURL_LT_SHLIB_USE_MIMPURE_TEXT_FALSE='#'
15559else
15560 CURL_LT_SHLIB_USE_MIMPURE_TEXT_TRUE='#'
15561 CURL_LT_SHLIB_USE_MIMPURE_TEXT_FALSE=
15562fi
15563
15564
15565#
15566# Due to libtool and automake machinery limitations of not allowing
15567# specifying separate CPPFLAGS or CFLAGS when compiling objects for
15568# inclusion of these in shared or static libraries, we are forced to
15569# build using separate configure runs for shared and static libraries
15570# on systems where different CPPFLAGS or CFLAGS are mandatory in order
15571# to compile objects for each kind of library. Notice that relying on
15572# the '-DPIC' CFLAG that libtool provides is not valid given that the
15573# user might for example choose to build static libraries with PIC.
15574#
15575
15576#
15577# Make our Makefile.am files use the staticlib CPPFLAG only when strictly
15578# targeting a static library and not building its shared counterpart.
15579#
15580
15581 if test "x$xc_lt_build_static_only" = 'xyes'; then
15582 USE_CPPFLAG_CURL_STATICLIB_TRUE=
15583 USE_CPPFLAG_CURL_STATICLIB_FALSE='#'
15584else
15585 USE_CPPFLAG_CURL_STATICLIB_TRUE='#'
15586 USE_CPPFLAG_CURL_STATICLIB_FALSE=
15587fi
15588
15589
15590#
15591# Make staticlib CPPFLAG variable and its definition visible in output
15592# files unconditionally, providing an empty definition unless strictly
15593# targeting a static library and not building its shared counterpart.
15594#
15595
15596CPPFLAG_CURL_STATICLIB=
15597if test "x$xc_lt_build_static_only" = 'xyes'; then
15598 CPPFLAG_CURL_STATICLIB='-DCURL_STATICLIB'
15599fi
15600
15601
15602
15603# Determine whether all dependent libraries must be specified when linking
15604if test "X$enable_shared" = "Xyes" -a "X$link_all_deplibs" = "Xno"
15605then
15606 REQUIRE_LIB_DEPS=no
15607else
15608 REQUIRE_LIB_DEPS=yes
15609fi
15610
15611 if test x$REQUIRE_LIB_DEPS = xyes; then
15612 USE_EXPLICIT_LIB_DEPS_TRUE=
15613 USE_EXPLICIT_LIB_DEPS_FALSE='#'
15614else
15615 USE_EXPLICIT_LIB_DEPS_TRUE='#'
15616 USE_EXPLICIT_LIB_DEPS_FALSE=
15617fi
15618
15619
15620{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
15621$as_echo_n "checking for inline... " >&6; }
15622if ${ac_cv_c_inline+:} false; then :
15623 $as_echo_n "(cached) " >&6
15624else
15625 ac_cv_c_inline=no
15626for ac_kw in inline __inline__ __inline; do
15627 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15628/* end confdefs.h. */
15629#ifndef __cplusplus
15630typedef int foo_t;
15631static $ac_kw foo_t static_foo () {return 0; }
15632$ac_kw foo_t foo () {return 0; }
15633#endif
15634
15635_ACEOF
15636if ac_fn_c_try_compile "$LINENO"; then :
15637 ac_cv_c_inline=$ac_kw
15638fi
15639rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15640 test "$ac_cv_c_inline" != no && break
15641done
15642
15643fi
15644{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
15645$as_echo "$ac_cv_c_inline" >&6; }
15646
15647case $ac_cv_c_inline in
15648 inline | yes) ;;
15649 *)
15650 case $ac_cv_c_inline in
15651 no) ac_val=;;
15652 *) ac_val=$ac_cv_c_inline;;
15653 esac
15654 cat >>confdefs.h <<_ACEOF
15655#ifndef __cplusplus
15656#define inline $ac_val
15657#endif
15658_ACEOF
15659 ;;
15660esac
15661
15662
15663
15664
Alex Deymo486467e2017-12-19 19:04:07 +010015665 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if cpp -P is needed" >&5
15666$as_echo_n "checking if cpp -P is needed... " >&6; }
15667 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15668/* end confdefs.h. */
15669
15670 #include <errno.h>
15671TEST EINVAL TEST
15672
15673_ACEOF
15674if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15675 $EGREP "TEST.*TEST" >/dev/null 2>&1; then :
15676 cpp=no
15677else
15678 cpp=yes
15679fi
15680rm -f conftest*
15681
15682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cpp" >&5
15683$as_echo "$cpp" >&6; }
15684
15685 if test "x$cpp" = "xyes"; then
15686 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if cpp -P works" >&5
15687$as_echo_n "checking if cpp -P works... " >&6; }
15688 OLDCPPFLAGS=$CPPFLAGS
15689 CPPFLAGS="$CPPFLAGS -P"
15690 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15691/* end confdefs.h. */
15692
15693 #include <errno.h>
15694TEST EINVAL TEST
15695
15696_ACEOF
15697if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15698 $EGREP "TEST.*TEST" >/dev/null 2>&1; then :
15699 cpp_p=yes
15700else
15701 cpp_p=no
15702fi
15703rm -f conftest*
15704
15705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cpp_p" >&5
15706$as_echo "$cpp_p" >&6; }
15707
15708 if test "x$cpp_p" = "xno"; then
15709 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: failed to figure out cpp -P alternative" >&5
15710$as_echo "$as_me: WARNING: failed to figure out cpp -P alternative" >&2;}
15711 # without -P
15712 CPPPFLAG=""
15713 else
15714 # with -P
15715 CPPPFLAG="-P"
15716 fi
15717 CPPFLAGS=$OLDCPPFLAGS
15718 else
15719 # without -P
15720 CPPPFLAG=""
15721 fi
15722
15723
Elliott Hughes82be86d2017-09-20 17:00:17 -070015724 #
15725 compiler_id="unknown"
15726 compiler_num="0"
15727 #
15728 flags_dbg_all="unknown"
15729 flags_dbg_yes="unknown"
15730 flags_dbg_off="unknown"
15731 flags_opt_all="unknown"
15732 flags_opt_yes="unknown"
15733 flags_opt_off="unknown"
15734 #
15735 flags_prefer_cppflags="no"
15736 #
15737
15738 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler is DEC/Compaq/HP C" >&5
15739$as_echo_n "checking if compiler is DEC/Compaq/HP C... " >&6; }
15740
15741 OLDCPPFLAGS=$CPPFLAGS
15742 # CPPPFLAG comes from CURL_CPP_P
15743 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
15744 if test -z "$SED"; then
15745 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
15746 fi
15747 if test -z "$GREP"; then
15748 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
15749 fi
15750
15751 tmp_exp=""
15752 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15753/* end confdefs.h. */
15754
15755
15756#ifdef __DECC
15757CURL_DEF_TOKEN __DECC
15758#endif
15759
15760
15761_ACEOF
15762if ac_fn_c_try_cpp "$LINENO"; then :
15763
15764 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
15765 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
15766 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
15767 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
15768 if test -z "$tmp_exp" || test "$tmp_exp" = "__DECC"; then
15769 tmp_exp=""
15770 fi
15771
15772fi
15773rm -f conftest.err conftest.i conftest.$ac_ext
15774 if test -z "$tmp_exp"; then
15775 curl_cv_have_def___DECC=no
15776
15777 else
15778 curl_cv_have_def___DECC=yes
15779 curl_cv_def___DECC=$tmp_exp
15780
15781 fi
15782 CPPFLAGS=$OLDCPPFLAGS
15783
15784
15785 OLDCPPFLAGS=$CPPFLAGS
15786 # CPPPFLAG comes from CURL_CPP_P
15787 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
15788 if test -z "$SED"; then
15789 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
15790 fi
15791 if test -z "$GREP"; then
15792 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
15793 fi
15794
15795 tmp_exp=""
15796 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15797/* end confdefs.h. */
15798
15799
15800#ifdef __DECC_VER
15801CURL_DEF_TOKEN __DECC_VER
15802#endif
15803
15804
15805_ACEOF
15806if ac_fn_c_try_cpp "$LINENO"; then :
15807
15808 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
15809 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
15810 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
15811 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
15812 if test -z "$tmp_exp" || test "$tmp_exp" = "__DECC_VER"; then
15813 tmp_exp=""
15814 fi
15815
15816fi
15817rm -f conftest.err conftest.i conftest.$ac_ext
15818 if test -z "$tmp_exp"; then
15819 curl_cv_have_def___DECC_VER=no
15820
15821 else
15822 curl_cv_have_def___DECC_VER=yes
15823 curl_cv_def___DECC_VER=$tmp_exp
15824
15825 fi
15826 CPPFLAGS=$OLDCPPFLAGS
15827
15828 if test "$curl_cv_have_def___DECC" = "yes" &&
15829 test "$curl_cv_have_def___DECC_VER" = "yes"; then
15830 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15831$as_echo "yes" >&6; }
15832 compiler_id="DEC_C"
15833 flags_dbg_all="-g -g0 -g1 -g2 -g3"
15834 flags_dbg_yes="-g2"
15835 flags_dbg_off=""
15836 flags_opt_all="-O -O0 -O1 -O2 -O3 -O4"
15837 flags_opt_yes="-O1"
15838 flags_opt_off="-O0"
15839 else
15840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15841$as_echo "no" >&6; }
15842 fi
15843
15844
15845 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler is HP-UX C" >&5
15846$as_echo_n "checking if compiler is HP-UX C... " >&6; }
15847
15848 OLDCPPFLAGS=$CPPFLAGS
15849 # CPPPFLAG comes from CURL_CPP_P
15850 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
15851 if test -z "$SED"; then
15852 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
15853 fi
15854 if test -z "$GREP"; then
15855 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
15856 fi
15857
15858 tmp_exp=""
15859 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15860/* end confdefs.h. */
15861
15862
15863#ifdef __HP_cc
15864CURL_DEF_TOKEN __HP_cc
15865#endif
15866
15867
15868_ACEOF
15869if ac_fn_c_try_cpp "$LINENO"; then :
15870
15871 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
15872 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
15873 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
15874 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
15875 if test -z "$tmp_exp" || test "$tmp_exp" = "__HP_cc"; then
15876 tmp_exp=""
15877 fi
15878
15879fi
15880rm -f conftest.err conftest.i conftest.$ac_ext
15881 if test -z "$tmp_exp"; then
15882 curl_cv_have_def___HP_cc=no
15883
15884 else
15885 curl_cv_have_def___HP_cc=yes
15886 curl_cv_def___HP_cc=$tmp_exp
15887
15888 fi
15889 CPPFLAGS=$OLDCPPFLAGS
15890
15891 if test "$curl_cv_have_def___HP_cc" = "yes"; then
15892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15893$as_echo "yes" >&6; }
15894 compiler_id="HP_UX_C"
15895 flags_dbg_all="-g -s"
15896 flags_dbg_yes="-g"
15897 flags_dbg_off="-s"
15898 flags_opt_all="-O +O0 +O1 +O2 +O3 +O4"
15899 flags_opt_yes="+O2"
15900 flags_opt_off="+O0"
15901 else
15902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15903$as_echo "no" >&6; }
15904 fi
15905
15906
15907 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler is IBM C" >&5
15908$as_echo_n "checking if compiler is IBM C... " >&6; }
15909
15910 OLDCPPFLAGS=$CPPFLAGS
15911 # CPPPFLAG comes from CURL_CPP_P
15912 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
15913 if test -z "$SED"; then
15914 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
15915 fi
15916 if test -z "$GREP"; then
15917 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
15918 fi
15919
15920 tmp_exp=""
15921 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15922/* end confdefs.h. */
15923
15924
15925#ifdef __IBMC__
15926CURL_DEF_TOKEN __IBMC__
15927#endif
15928
15929
15930_ACEOF
15931if ac_fn_c_try_cpp "$LINENO"; then :
15932
15933 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
15934 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
15935 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
15936 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
15937 if test -z "$tmp_exp" || test "$tmp_exp" = "__IBMC__"; then
15938 tmp_exp=""
15939 fi
15940
15941fi
15942rm -f conftest.err conftest.i conftest.$ac_ext
15943 if test -z "$tmp_exp"; then
15944 curl_cv_have_def___IBMC__=no
15945
15946 else
15947 curl_cv_have_def___IBMC__=yes
15948 curl_cv_def___IBMC__=$tmp_exp
15949
15950 fi
15951 CPPFLAGS=$OLDCPPFLAGS
15952
15953 if test "$curl_cv_have_def___IBMC__" = "yes"; then
15954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15955$as_echo "yes" >&6; }
15956 compiler_id="IBM_C"
15957 flags_dbg_all="-g -g0 -g1 -g2 -g3"
15958 flags_dbg_yes="-g"
15959 flags_dbg_off=""
15960 flags_opt_all="-O -O0 -O1 -O2 -O3 -O4 -O5"
15961 flags_opt_all="$flags_opt_all -qnooptimize"
15962 flags_opt_all="$flags_opt_all -qoptimize=0"
15963 flags_opt_all="$flags_opt_all -qoptimize=1"
15964 flags_opt_all="$flags_opt_all -qoptimize=2"
15965 flags_opt_all="$flags_opt_all -qoptimize=3"
15966 flags_opt_all="$flags_opt_all -qoptimize=4"
15967 flags_opt_all="$flags_opt_all -qoptimize=5"
15968 flags_opt_yes="-O2"
15969 flags_opt_off="-qnooptimize"
15970 flags_prefer_cppflags="yes"
15971 else
15972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15973$as_echo "no" >&6; }
15974 fi
15975
15976
15977 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler is Intel C" >&5
15978$as_echo_n "checking if compiler is Intel C... " >&6; }
15979
15980 OLDCPPFLAGS=$CPPFLAGS
15981 # CPPPFLAG comes from CURL_CPP_P
15982 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
15983 if test -z "$SED"; then
15984 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
15985 fi
15986 if test -z "$GREP"; then
15987 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
15988 fi
15989
15990 tmp_exp=""
15991 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15992/* end confdefs.h. */
15993
15994
15995#ifdef __INTEL_COMPILER
15996CURL_DEF_TOKEN __INTEL_COMPILER
15997#endif
15998
15999
16000_ACEOF
16001if ac_fn_c_try_cpp "$LINENO"; then :
16002
16003 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16004 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16005 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16006 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16007 if test -z "$tmp_exp" || test "$tmp_exp" = "__INTEL_COMPILER"; then
16008 tmp_exp=""
16009 fi
16010
16011fi
16012rm -f conftest.err conftest.i conftest.$ac_ext
16013 if test -z "$tmp_exp"; then
16014 curl_cv_have_def___INTEL_COMPILER=no
16015
16016 else
16017 curl_cv_have_def___INTEL_COMPILER=yes
16018 curl_cv_def___INTEL_COMPILER=$tmp_exp
16019
16020 fi
16021 CPPFLAGS=$OLDCPPFLAGS
16022
16023 if test "$curl_cv_have_def___INTEL_COMPILER" = "yes"; then
16024 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16025$as_echo "yes" >&6; }
16026 compiler_num="$curl_cv_def___INTEL_COMPILER"
16027
16028 OLDCPPFLAGS=$CPPFLAGS
16029 # CPPPFLAG comes from CURL_CPP_P
16030 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16031 if test -z "$SED"; then
16032 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16033 fi
16034 if test -z "$GREP"; then
16035 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16036 fi
16037
16038 tmp_exp=""
16039 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16040/* end confdefs.h. */
16041
16042
16043#ifdef __unix__
16044CURL_DEF_TOKEN __unix__
16045#endif
16046
16047
16048_ACEOF
16049if ac_fn_c_try_cpp "$LINENO"; then :
16050
16051 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16052 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16053 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16054 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16055 if test -z "$tmp_exp" || test "$tmp_exp" = ""; then
16056 tmp_exp=""
16057 fi
16058
16059fi
16060rm -f conftest.err conftest.i conftest.$ac_ext
16061 if test -z "$tmp_exp"; then
16062 curl_cv_have_def___unix__=no
16063
16064 else
16065 curl_cv_have_def___unix__=yes
16066 curl_cv_def___unix__=$tmp_exp
16067
16068 fi
16069 CPPFLAGS=$OLDCPPFLAGS
16070
16071 if test "$curl_cv_have_def___unix__" = "yes"; then
16072 compiler_id="INTEL_UNIX_C"
16073 flags_dbg_all="-g -g0"
16074 flags_dbg_yes="-g"
16075 flags_dbg_off=""
16076 flags_opt_all="-O -O0 -O1 -O2 -O3 -Os"
16077 flags_opt_yes="-O2"
16078 flags_opt_off="-O0"
16079 else
16080 compiler_id="INTEL_WINDOWS_C"
16081 flags_dbg_all="/ZI /Zi /zI /zi /ZD /Zd /zD /zd /Z7 /z7 /Oy /Oy-"
16082 flags_dbg_all="$flags_dbg_all /debug"
16083 flags_dbg_all="$flags_dbg_all /debug:none"
16084 flags_dbg_all="$flags_dbg_all /debug:minimal"
16085 flags_dbg_all="$flags_dbg_all /debug:partial"
16086 flags_dbg_all="$flags_dbg_all /debug:full"
16087 flags_dbg_all="$flags_dbg_all /debug:semantic_stepping"
16088 flags_dbg_all="$flags_dbg_all /debug:extended"
16089 flags_dbg_yes="/Zi /Oy-"
16090 flags_dbg_off="/debug:none /Oy-"
16091 flags_opt_all="/O /O0 /O1 /O2 /O3 /Od /Og /Og- /Oi /Oi-"
16092 flags_opt_yes="/O2"
16093 flags_opt_off="/Od"
16094 fi
16095 else
16096 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16097$as_echo "no" >&6; }
16098 fi
16099
16100
16101 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler is clang" >&5
16102$as_echo_n "checking if compiler is clang... " >&6; }
16103
16104 OLDCPPFLAGS=$CPPFLAGS
16105 # CPPPFLAG comes from CURL_CPP_P
16106 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16107 if test -z "$SED"; then
16108 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16109 fi
16110 if test -z "$GREP"; then
16111 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16112 fi
16113
16114 tmp_exp=""
16115 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16116/* end confdefs.h. */
16117
16118
16119#ifdef __clang__
16120CURL_DEF_TOKEN __clang__
16121#endif
16122
16123
16124_ACEOF
16125if ac_fn_c_try_cpp "$LINENO"; then :
16126
16127 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16128 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16129 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16130 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16131 if test -z "$tmp_exp" || test "$tmp_exp" = "__clang__"; then
16132 tmp_exp=""
16133 fi
16134
16135fi
16136rm -f conftest.err conftest.i conftest.$ac_ext
16137 if test -z "$tmp_exp"; then
16138 curl_cv_have_def___clang__=no
16139
16140 else
16141 curl_cv_have_def___clang__=yes
16142 curl_cv_def___clang__=$tmp_exp
16143
16144 fi
16145 CPPFLAGS=$OLDCPPFLAGS
16146
16147 if test "$curl_cv_have_def___clang__" = "yes"; then
16148 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16149$as_echo "yes" >&6; }
Haibo Huang51d9d882019-02-06 01:36:06 -080016150 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler is xlclang" >&5
16151$as_echo_n "checking if compiler is xlclang... " >&6; }
16152
16153 OLDCPPFLAGS=$CPPFLAGS
16154 # CPPPFLAG comes from CURL_CPP_P
16155 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16156 if test -z "$SED"; then
16157 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16158 fi
16159 if test -z "$GREP"; then
16160 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16161 fi
16162
16163 tmp_exp=""
16164 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16165/* end confdefs.h. */
16166
16167
16168#ifdef __ibmxl__
16169CURL_DEF_TOKEN __ibmxl__
16170#endif
16171
16172
16173_ACEOF
16174if ac_fn_c_try_cpp "$LINENO"; then :
16175
16176 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16177 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16178 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16179 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16180 if test -z "$tmp_exp" || test "$tmp_exp" = "__ibmxl__"; then
16181 tmp_exp=""
16182 fi
16183
16184fi
16185rm -f conftest.err conftest.i conftest.$ac_ext
16186 if test -z "$tmp_exp"; then
16187 curl_cv_have_def___ibmxl__=no
16188
16189 else
16190 curl_cv_have_def___ibmxl__=yes
16191 curl_cv_def___ibmxl__=$tmp_exp
16192
16193 fi
16194 CPPFLAGS=$OLDCPPFLAGS
16195
16196 if test "$curl_cv_have_def___ibmxl__" = "yes" ; then
16197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16198$as_echo "yes" >&6; }
16199 compiler_id="XLCLANG"
16200 else
16201 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16202$as_echo "no" >&6; }
16203 compiler_id="CLANG"
16204 fi
Elliott Hughes82be86d2017-09-20 17:00:17 -070016205 fullclangver=`$CC -v 2>&1 | grep version`
16206 clangver=`echo $fullclangver | grep "based on LLVM " | "$SED" 's/.*(based on LLVM \([0-9]*\.[0-9]*\).*)/\1/'`
16207 if test -z "$clangver"; then
16208 if echo $fullclangver | grep "Apple LLVM version " >/dev/null; then
Alex Deymo486467e2017-12-19 19:04:07 +010016209 clangver="3.7"
Elliott Hughes82be86d2017-09-20 17:00:17 -070016210 else
16211 clangver=`echo $fullclangver | "$SED" 's/.*version \([0-9]*\.[0-9]*\).*/\1/'`
16212 fi
16213 fi
16214 clangvhi=`echo $clangver | cut -d . -f1`
16215 clangvlo=`echo $clangver | cut -d . -f2`
16216 compiler_num=`(expr $clangvhi "*" 100 + $clangvlo) 2>/dev/null`
16217 flags_dbg_all="-g -g0 -g1 -g2 -g3"
16218 flags_dbg_all="$flags_dbg_all -ggdb"
16219 flags_dbg_all="$flags_dbg_all -gstabs"
16220 flags_dbg_all="$flags_dbg_all -gstabs+"
16221 flags_dbg_all="$flags_dbg_all -gcoff"
16222 flags_dbg_all="$flags_dbg_all -gxcoff"
16223 flags_dbg_all="$flags_dbg_all -gdwarf-2"
16224 flags_dbg_all="$flags_dbg_all -gvms"
16225 flags_dbg_yes="-g"
16226 flags_dbg_off=""
16227 flags_opt_all="-O -O0 -O1 -O2 -Os -O3 -O4"
16228 flags_opt_yes="-Os"
16229 flags_opt_off="-O0"
16230 else
16231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16232$as_echo "no" >&6; }
16233 fi
16234
16235
16236 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler is GNU C" >&5
16237$as_echo_n "checking if compiler is GNU C... " >&6; }
16238
16239 OLDCPPFLAGS=$CPPFLAGS
16240 # CPPPFLAG comes from CURL_CPP_P
16241 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16242 if test -z "$SED"; then
16243 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16244 fi
16245 if test -z "$GREP"; then
16246 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16247 fi
16248
16249 tmp_exp=""
16250 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16251/* end confdefs.h. */
16252
16253
16254#ifdef __GNUC__
16255CURL_DEF_TOKEN __GNUC__
16256#endif
16257
16258
16259_ACEOF
16260if ac_fn_c_try_cpp "$LINENO"; then :
16261
16262 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16263 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16264 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16265 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16266 if test -z "$tmp_exp" || test "$tmp_exp" = "__GNUC__"; then
16267 tmp_exp=""
16268 fi
16269
16270fi
16271rm -f conftest.err conftest.i conftest.$ac_ext
16272 if test -z "$tmp_exp"; then
16273 curl_cv_have_def___GNUC__=no
16274
16275 else
16276 curl_cv_have_def___GNUC__=yes
16277 curl_cv_def___GNUC__=$tmp_exp
16278
16279 fi
16280 CPPFLAGS=$OLDCPPFLAGS
16281
16282 if test "$curl_cv_have_def___GNUC__" = "yes" &&
16283 test "$compiler_id" = "unknown"; then
16284 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16285$as_echo "yes" >&6; }
16286 compiler_id="GNU_C"
16287 gccver=`$CC -dumpversion`
16288 gccvhi=`echo $gccver | cut -d . -f1`
16289 gccvlo=`echo $gccver | cut -d . -f2`
16290 compiler_num=`(expr $gccvhi "*" 100 + $gccvlo) 2>/dev/null`
16291 flags_dbg_all="-g -g0 -g1 -g2 -g3"
16292 flags_dbg_all="$flags_dbg_all -ggdb"
16293 flags_dbg_all="$flags_dbg_all -gstabs"
16294 flags_dbg_all="$flags_dbg_all -gstabs+"
16295 flags_dbg_all="$flags_dbg_all -gcoff"
16296 flags_dbg_all="$flags_dbg_all -gxcoff"
16297 flags_dbg_all="$flags_dbg_all -gdwarf-2"
16298 flags_dbg_all="$flags_dbg_all -gvms"
16299 flags_dbg_yes="-g"
16300 flags_dbg_off=""
16301 flags_opt_all="-O -O0 -O1 -O2 -O3 -Os -Og -Ofast"
16302 flags_opt_yes="-O2"
16303 flags_opt_off="-O0"
16304
16305 OLDCPPFLAGS=$CPPFLAGS
16306 # CPPPFLAG comes from CURL_CPP_P
16307 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16308 if test -z "$SED"; then
16309 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16310 fi
16311 if test -z "$GREP"; then
16312 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16313 fi
16314
16315 tmp_exp=""
16316 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16317/* end confdefs.h. */
16318
16319
16320#ifdef _WIN32
16321CURL_DEF_TOKEN _WIN32
16322#endif
16323
16324
16325_ACEOF
16326if ac_fn_c_try_cpp "$LINENO"; then :
16327
16328 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16329 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16330 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16331 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16332 if test -z "$tmp_exp" || test "$tmp_exp" = "_WIN32"; then
16333 tmp_exp=""
16334 fi
16335
16336fi
16337rm -f conftest.err conftest.i conftest.$ac_ext
16338 if test -z "$tmp_exp"; then
16339 curl_cv_have_def__WIN32=no
16340
16341 else
16342 curl_cv_have_def__WIN32=yes
16343 curl_cv_def__WIN32=$tmp_exp
16344
16345 fi
16346 CPPFLAGS=$OLDCPPFLAGS
16347
16348 else
16349 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16350$as_echo "no" >&6; }
16351 fi
16352
16353
16354 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler is LCC" >&5
16355$as_echo_n "checking if compiler is LCC... " >&6; }
16356
16357 OLDCPPFLAGS=$CPPFLAGS
16358 # CPPPFLAG comes from CURL_CPP_P
16359 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16360 if test -z "$SED"; then
16361 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16362 fi
16363 if test -z "$GREP"; then
16364 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16365 fi
16366
16367 tmp_exp=""
16368 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16369/* end confdefs.h. */
16370
16371
16372#ifdef __LCC__
16373CURL_DEF_TOKEN __LCC__
16374#endif
16375
16376
16377_ACEOF
16378if ac_fn_c_try_cpp "$LINENO"; then :
16379
16380 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16381 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16382 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16383 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16384 if test -z "$tmp_exp" || test "$tmp_exp" = "__LCC__"; then
16385 tmp_exp=""
16386 fi
16387
16388fi
16389rm -f conftest.err conftest.i conftest.$ac_ext
16390 if test -z "$tmp_exp"; then
16391 curl_cv_have_def___LCC__=no
16392
16393 else
16394 curl_cv_have_def___LCC__=yes
16395 curl_cv_def___LCC__=$tmp_exp
16396
16397 fi
16398 CPPFLAGS=$OLDCPPFLAGS
16399
16400 if test "$curl_cv_have_def___LCC__" = "yes"; then
16401 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16402$as_echo "yes" >&6; }
16403 compiler_id="LCC"
16404 flags_dbg_all="-g"
16405 flags_dbg_yes="-g"
16406 flags_dbg_off=""
16407 flags_opt_all=""
16408 flags_opt_yes=""
16409 flags_opt_off=""
16410 else
16411 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16412$as_echo "no" >&6; }
16413 fi
16414
16415
16416 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler is SGI MIPSpro C" >&5
16417$as_echo_n "checking if compiler is SGI MIPSpro C... " >&6; }
16418
16419 OLDCPPFLAGS=$CPPFLAGS
16420 # CPPPFLAG comes from CURL_CPP_P
16421 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16422 if test -z "$SED"; then
16423 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16424 fi
16425 if test -z "$GREP"; then
16426 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16427 fi
16428
16429 tmp_exp=""
16430 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16431/* end confdefs.h. */
16432
16433
16434#ifdef __GNUC__
16435CURL_DEF_TOKEN __GNUC__
16436#endif
16437
16438
16439_ACEOF
16440if ac_fn_c_try_cpp "$LINENO"; then :
16441
16442 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16443 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16444 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16445 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16446 if test -z "$tmp_exp" || test "$tmp_exp" = "__GNUC__"; then
16447 tmp_exp=""
16448 fi
16449
16450fi
16451rm -f conftest.err conftest.i conftest.$ac_ext
16452 if test -z "$tmp_exp"; then
16453 curl_cv_have_def___GNUC__=no
16454
16455 else
16456 curl_cv_have_def___GNUC__=yes
16457 curl_cv_def___GNUC__=$tmp_exp
16458
16459 fi
16460 CPPFLAGS=$OLDCPPFLAGS
16461
16462
16463 OLDCPPFLAGS=$CPPFLAGS
16464 # CPPPFLAG comes from CURL_CPP_P
16465 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16466 if test -z "$SED"; then
16467 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16468 fi
16469 if test -z "$GREP"; then
16470 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16471 fi
16472
16473 tmp_exp=""
16474 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16475/* end confdefs.h. */
16476
16477
16478#ifdef _COMPILER_VERSION
16479CURL_DEF_TOKEN _COMPILER_VERSION
16480#endif
16481
16482
16483_ACEOF
16484if ac_fn_c_try_cpp "$LINENO"; then :
16485
16486 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16487 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16488 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16489 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16490 if test -z "$tmp_exp" || test "$tmp_exp" = "_COMPILER_VERSION"; then
16491 tmp_exp=""
16492 fi
16493
16494fi
16495rm -f conftest.err conftest.i conftest.$ac_ext
16496 if test -z "$tmp_exp"; then
16497 curl_cv_have_def__COMPILER_VERSION=no
16498
16499 else
16500 curl_cv_have_def__COMPILER_VERSION=yes
16501 curl_cv_def__COMPILER_VERSION=$tmp_exp
16502
16503 fi
16504 CPPFLAGS=$OLDCPPFLAGS
16505
16506
16507 OLDCPPFLAGS=$CPPFLAGS
16508 # CPPPFLAG comes from CURL_CPP_P
16509 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16510 if test -z "$SED"; then
16511 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16512 fi
16513 if test -z "$GREP"; then
16514 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16515 fi
16516
16517 tmp_exp=""
16518 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16519/* end confdefs.h. */
16520
16521
16522#ifdef _SGI_COMPILER_VERSION
16523CURL_DEF_TOKEN _SGI_COMPILER_VERSION
16524#endif
16525
16526
16527_ACEOF
16528if ac_fn_c_try_cpp "$LINENO"; then :
16529
16530 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16531 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16532 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16533 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16534 if test -z "$tmp_exp" || test "$tmp_exp" = "_SGI_COMPILER_VERSION"; then
16535 tmp_exp=""
16536 fi
16537
16538fi
16539rm -f conftest.err conftest.i conftest.$ac_ext
16540 if test -z "$tmp_exp"; then
16541 curl_cv_have_def__SGI_COMPILER_VERSION=no
16542
16543 else
16544 curl_cv_have_def__SGI_COMPILER_VERSION=yes
16545 curl_cv_def__SGI_COMPILER_VERSION=$tmp_exp
16546
16547 fi
16548 CPPFLAGS=$OLDCPPFLAGS
16549
16550 if test "$curl_cv_have_def___GNUC__" = "no" &&
16551 (test "$curl_cv_have_def__SGI_COMPILER_VERSION" = "yes" ||
16552 test "$curl_cv_have_def__COMPILER_VERSION" = "yes"); then
16553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16554$as_echo "yes" >&6; }
16555 compiler_id="SGI_MIPSPRO_C"
16556 flags_dbg_all="-g -g0 -g1 -g2 -g3"
16557 flags_dbg_yes="-g"
16558 flags_dbg_off=""
16559 flags_opt_all="-O -O0 -O1 -O2 -O3 -Ofast"
16560 flags_opt_yes="-O2"
16561 flags_opt_off="-O0"
16562 else
16563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16564$as_echo "no" >&6; }
16565 fi
16566
16567
16568 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler is SGI MIPS C" >&5
16569$as_echo_n "checking if compiler is SGI MIPS C... " >&6; }
16570
16571 OLDCPPFLAGS=$CPPFLAGS
16572 # CPPPFLAG comes from CURL_CPP_P
16573 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16574 if test -z "$SED"; then
16575 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16576 fi
16577 if test -z "$GREP"; then
16578 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16579 fi
16580
16581 tmp_exp=""
16582 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16583/* end confdefs.h. */
16584
16585
16586#ifdef __GNUC__
16587CURL_DEF_TOKEN __GNUC__
16588#endif
16589
16590
16591_ACEOF
16592if ac_fn_c_try_cpp "$LINENO"; then :
16593
16594 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16595 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16596 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16597 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16598 if test -z "$tmp_exp" || test "$tmp_exp" = "__GNUC__"; then
16599 tmp_exp=""
16600 fi
16601
16602fi
16603rm -f conftest.err conftest.i conftest.$ac_ext
16604 if test -z "$tmp_exp"; then
16605 curl_cv_have_def___GNUC__=no
16606
16607 else
16608 curl_cv_have_def___GNUC__=yes
16609 curl_cv_def___GNUC__=$tmp_exp
16610
16611 fi
16612 CPPFLAGS=$OLDCPPFLAGS
16613
16614
16615 OLDCPPFLAGS=$CPPFLAGS
16616 # CPPPFLAG comes from CURL_CPP_P
16617 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16618 if test -z "$SED"; then
16619 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16620 fi
16621 if test -z "$GREP"; then
16622 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16623 fi
16624
16625 tmp_exp=""
16626 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16627/* end confdefs.h. */
16628
16629
16630#ifdef __sgi
16631CURL_DEF_TOKEN __sgi
16632#endif
16633
16634
16635_ACEOF
16636if ac_fn_c_try_cpp "$LINENO"; then :
16637
16638 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16639 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16640 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16641 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16642 if test -z "$tmp_exp" || test "$tmp_exp" = "__sgi"; then
16643 tmp_exp=""
16644 fi
16645
16646fi
16647rm -f conftest.err conftest.i conftest.$ac_ext
16648 if test -z "$tmp_exp"; then
16649 curl_cv_have_def___sgi=no
16650
16651 else
16652 curl_cv_have_def___sgi=yes
16653 curl_cv_def___sgi=$tmp_exp
16654
16655 fi
16656 CPPFLAGS=$OLDCPPFLAGS
16657
16658 if test "$curl_cv_have_def___GNUC__" = "no" &&
16659 test "$curl_cv_have_def___sgi" = "yes" &&
16660 test "$compiler_id" = "unknown"; then
16661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16662$as_echo "yes" >&6; }
16663 compiler_id="SGI_MIPS_C"
16664 flags_dbg_all="-g -g0 -g1 -g2 -g3"
16665 flags_dbg_yes="-g"
16666 flags_dbg_off=""
16667 flags_opt_all="-O -O0 -O1 -O2 -O3 -Ofast"
16668 flags_opt_yes="-O2"
16669 flags_opt_off="-O0"
16670 else
16671 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16672$as_echo "no" >&6; }
16673 fi
16674
16675
16676 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler is SunPro C" >&5
16677$as_echo_n "checking if compiler is SunPro C... " >&6; }
16678
16679 OLDCPPFLAGS=$CPPFLAGS
16680 # CPPPFLAG comes from CURL_CPP_P
16681 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16682 if test -z "$SED"; then
16683 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16684 fi
16685 if test -z "$GREP"; then
16686 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16687 fi
16688
16689 tmp_exp=""
16690 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16691/* end confdefs.h. */
16692
16693
16694#ifdef __SUNPRO_C
16695CURL_DEF_TOKEN __SUNPRO_C
16696#endif
16697
16698
16699_ACEOF
16700if ac_fn_c_try_cpp "$LINENO"; then :
16701
16702 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16703 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16704 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16705 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16706 if test -z "$tmp_exp" || test "$tmp_exp" = "__SUNPRO_C"; then
16707 tmp_exp=""
16708 fi
16709
16710fi
16711rm -f conftest.err conftest.i conftest.$ac_ext
16712 if test -z "$tmp_exp"; then
16713 curl_cv_have_def___SUNPRO_C=no
16714
16715 else
16716 curl_cv_have_def___SUNPRO_C=yes
16717 curl_cv_def___SUNPRO_C=$tmp_exp
16718
16719 fi
16720 CPPFLAGS=$OLDCPPFLAGS
16721
16722 if test "$curl_cv_have_def___SUNPRO_C" = "yes"; then
16723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16724$as_echo "yes" >&6; }
16725 compiler_id="SUNPRO_C"
16726 flags_dbg_all="-g -s"
16727 flags_dbg_yes="-g"
16728 flags_dbg_off="-s"
16729 flags_opt_all="-O -xO -xO1 -xO2 -xO3 -xO4 -xO5"
16730 flags_opt_yes="-xO2"
16731 flags_opt_off=""
16732 else
16733 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16734$as_echo "no" >&6; }
16735 fi
16736
16737
16738 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler is Tiny C" >&5
16739$as_echo_n "checking if compiler is Tiny C... " >&6; }
16740
16741 OLDCPPFLAGS=$CPPFLAGS
16742 # CPPPFLAG comes from CURL_CPP_P
16743 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16744 if test -z "$SED"; then
16745 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16746 fi
16747 if test -z "$GREP"; then
16748 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16749 fi
16750
16751 tmp_exp=""
16752 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16753/* end confdefs.h. */
16754
16755
16756#ifdef __TINYC__
16757CURL_DEF_TOKEN __TINYC__
16758#endif
16759
16760
16761_ACEOF
16762if ac_fn_c_try_cpp "$LINENO"; then :
16763
16764 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16765 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16766 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16767 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16768 if test -z "$tmp_exp" || test "$tmp_exp" = "__TINYC__"; then
16769 tmp_exp=""
16770 fi
16771
16772fi
16773rm -f conftest.err conftest.i conftest.$ac_ext
16774 if test -z "$tmp_exp"; then
16775 curl_cv_have_def___TINYC__=no
16776
16777 else
16778 curl_cv_have_def___TINYC__=yes
16779 curl_cv_def___TINYC__=$tmp_exp
16780
16781 fi
16782 CPPFLAGS=$OLDCPPFLAGS
16783
16784 if test "$curl_cv_have_def___TINYC__" = "yes"; then
16785 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16786$as_echo "yes" >&6; }
16787 compiler_id="TINY_C"
16788 flags_dbg_all="-g -b"
16789 flags_dbg_yes="-g"
16790 flags_dbg_off=""
16791 flags_opt_all=""
16792 flags_opt_yes=""
16793 flags_opt_off=""
16794 else
16795 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16796$as_echo "no" >&6; }
16797 fi
16798
16799
16800 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler is Watcom C" >&5
16801$as_echo_n "checking if compiler is Watcom C... " >&6; }
16802
16803 OLDCPPFLAGS=$CPPFLAGS
16804 # CPPPFLAG comes from CURL_CPP_P
16805 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16806 if test -z "$SED"; then
16807 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16808 fi
16809 if test -z "$GREP"; then
16810 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16811 fi
16812
16813 tmp_exp=""
16814 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16815/* end confdefs.h. */
16816
16817
16818#ifdef __WATCOMC__
16819CURL_DEF_TOKEN __WATCOMC__
16820#endif
16821
16822
16823_ACEOF
16824if ac_fn_c_try_cpp "$LINENO"; then :
16825
16826 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16827 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16828 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16829 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16830 if test -z "$tmp_exp" || test "$tmp_exp" = "__WATCOMC__"; then
16831 tmp_exp=""
16832 fi
16833
16834fi
16835rm -f conftest.err conftest.i conftest.$ac_ext
16836 if test -z "$tmp_exp"; then
16837 curl_cv_have_def___WATCOMC__=no
16838
16839 else
16840 curl_cv_have_def___WATCOMC__=yes
16841 curl_cv_def___WATCOMC__=$tmp_exp
16842
16843 fi
16844 CPPFLAGS=$OLDCPPFLAGS
16845
16846 if test "$curl_cv_have_def___WATCOMC__" = "yes"; then
16847 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16848$as_echo "yes" >&6; }
16849
16850 OLDCPPFLAGS=$CPPFLAGS
16851 # CPPPFLAG comes from CURL_CPP_P
16852 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
16853 if test -z "$SED"; then
16854 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
16855 fi
16856 if test -z "$GREP"; then
16857 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
16858 fi
16859
16860 tmp_exp=""
16861 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16862/* end confdefs.h. */
16863
16864
16865#ifdef __UNIX__
16866CURL_DEF_TOKEN __UNIX__
16867#endif
16868
16869
16870_ACEOF
16871if ac_fn_c_try_cpp "$LINENO"; then :
16872
16873 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
16874 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
16875 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
16876 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
16877 if test -z "$tmp_exp" || test "$tmp_exp" = "__UNIX__"; then
16878 tmp_exp=""
16879 fi
16880
16881fi
16882rm -f conftest.err conftest.i conftest.$ac_ext
16883 if test -z "$tmp_exp"; then
16884 curl_cv_have_def___UNIX__=no
16885
16886 else
16887 curl_cv_have_def___UNIX__=yes
16888 curl_cv_def___UNIX__=$tmp_exp
16889
16890 fi
16891 CPPFLAGS=$OLDCPPFLAGS
16892
16893 if test "$curl_cv_have_def___UNIX__" = "yes"; then
16894 compiler_id="WATCOM_UNIX_C"
16895 flags_dbg_all="-g1 -g1+ -g2 -g3"
16896 flags_dbg_yes="-g2"
16897 flags_dbg_off=""
16898 flags_opt_all="-O0 -O1 -O2 -O3"
16899 flags_opt_yes="-O2"
16900 flags_opt_off="-O0"
16901 else
16902 compiler_id="WATCOM_WINDOWS_C"
16903 flags_dbg_all=""
16904 flags_dbg_yes=""
16905 flags_dbg_off=""
16906 flags_opt_all=""
16907 flags_opt_yes=""
16908 flags_opt_off=""
16909 fi
16910 else
16911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16912$as_echo "no" >&6; }
16913 fi
16914
16915 #
16916 if test "$compiler_id" = "unknown"; then
16917 cat <<_EOF 1>&2
16918***
16919*** Warning: This configure script does not have information about the
16920*** compiler you are using, relative to the flags required to enable or
16921*** disable generation of debug info, optimization options or warnings.
16922***
16923*** Whatever settings are present in CFLAGS will be used for this run.
16924***
16925*** If you wish to help the curl project to better support your compiler
16926*** you can report this and the required info on the libcurl development
16927*** mailing list: https://cool.haxx.se/mailman/listinfo/curl-library/
16928***
16929_EOF
16930 fi
16931
16932
16933squeeze() {
16934 _sqz_result=""
16935 eval _sqz_input=\$$1
16936 for _sqz_token in $_sqz_input; do
16937 if test -z "$_sqz_result"; then
16938 _sqz_result="$_sqz_token"
16939 else
16940 _sqz_result="$_sqz_result $_sqz_token"
16941 fi
16942 done
16943 eval $1=\$_sqz_result
16944 return 0
16945}
16946
16947
16948 #
16949 if test "$compiler_id" != "unknown"; then
16950 #
16951 if test "$compiler_id" = "GNU_C" ||
16952 test "$compiler_id" = "CLANG"; then
16953
16954 if test "$compiler_id" = "GNU_C" ||
16955 test "$compiler_id" = "CLANG"; then
16956 tmp_has_include="no"
16957 tmp_chg_FLAGS="$CFLAGS"
16958 for word1 in $tmp_chg_FLAGS; do
16959 case "$word1" in
16960 -I*)
16961 tmp_has_include="yes"
16962 ;;
16963 esac
16964 done
16965 if test "$tmp_has_include" = "yes"; then
16966 tmp_chg_FLAGS=`echo "$tmp_chg_FLAGS" | "$SED" 's/^-I/ -isystem /g'`
16967 tmp_chg_FLAGS=`echo "$tmp_chg_FLAGS" | "$SED" 's/ -I/ -isystem /g'`
16968 CFLAGS="$tmp_chg_FLAGS"
16969 squeeze CFLAGS
16970 fi
16971 tmp_has_include="no"
16972 tmp_chg_FLAGS="$CPPFLAGS"
16973 for word1 in $tmp_chg_FLAGS; do
16974 case "$word1" in
16975 -I*)
16976 tmp_has_include="yes"
16977 ;;
16978 esac
16979 done
16980 if test "$tmp_has_include" = "yes"; then
16981 tmp_chg_FLAGS=`echo "$tmp_chg_FLAGS" | "$SED" 's/^-I/ -isystem /g'`
16982 tmp_chg_FLAGS=`echo "$tmp_chg_FLAGS" | "$SED" 's/ -I/ -isystem /g'`
16983 CPPFLAGS="$tmp_chg_FLAGS"
16984 squeeze CPPFLAGS
16985 fi
16986 fi
16987
16988 fi
16989 #
16990 tmp_save_CPPFLAGS="$CPPFLAGS"
16991 tmp_save_CFLAGS="$CFLAGS"
16992 tmp_CPPFLAGS=""
16993 tmp_CFLAGS=""
16994 #
16995 case "$compiler_id" in
16996 #
16997 CLANG)
16998 #
16999 tmp_CFLAGS="$tmp_CFLAGS -Qunused-arguments"
17000 ;;
17001 #
17002 DEC_C)
17003 #
17004 tmp_CFLAGS="$tmp_CFLAGS -std1"
17005 tmp_CFLAGS="$tmp_CFLAGS -noansi_alias"
17006 tmp_CFLAGS="$tmp_CFLAGS -warnprotos"
17007 tmp_CFLAGS="$tmp_CFLAGS -msg_fatal toofewargs,toomanyargs"
17008 ;;
17009 #
17010 GNU_C)
17011 #
17012 if test "$compiler_num" -ge "295"; then
17013 tmp_CFLAGS="$tmp_CFLAGS -Werror-implicit-function-declaration"
17014 fi
17015 ;;
17016 #
17017 HP_UX_C)
17018 #
17019 tmp_CFLAGS="$tmp_CFLAGS -z"
17020 tmp_CFLAGS="$tmp_CFLAGS +W 4227,4255"
17021 ;;
17022 #
17023 IBM_C)
17024 #
17025 tmp_CPPFLAGS="$tmp_CPPFLAGS -qthreaded"
17026 tmp_CPPFLAGS="$tmp_CPPFLAGS -qnoansialias"
17027 tmp_CPPFLAGS="$tmp_CPPFLAGS -qhalt=e"
17028 ;;
17029 #
17030 INTEL_UNIX_C)
17031 #
17032 tmp_CFLAGS="$tmp_CFLAGS -std=gnu89"
17033 tmp_CPPFLAGS="$tmp_CPPFLAGS -we140,147,165,266"
17034 tmp_CPPFLAGS="$tmp_CPPFLAGS -wd279,981,1469"
17035 ;;
17036 #
17037 INTEL_WINDOWS_C)
17038 #
17039 tmp_CFLAGS="$tmp_CFLAGS"
17040 ;;
17041 #
17042 LCC)
17043 #
17044 tmp_CFLAGS="$tmp_CFLAGS -n"
17045 ;;
17046 #
17047 SGI_MIPS_C)
17048 #
17049 tmp_CFLAGS="$tmp_CFLAGS"
17050 ;;
17051 #
17052 SGI_MIPSPRO_C)
17053 #
17054 tmp_CFLAGS="$tmp_CFLAGS"
17055 ;;
17056 #
17057 SUNPRO_C)
17058 #
17059 tmp_CFLAGS="$tmp_CFLAGS"
17060 ;;
17061 #
17062 TINY_C)
17063 #
17064 tmp_CFLAGS="$tmp_CFLAGS"
17065 ;;
17066 #
17067 WATCOM_UNIX_C)
17068 #
17069 tmp_CFLAGS="$tmp_CFLAGS"
17070 ;;
17071 #
17072 WATCOM_WINDOWS_C)
17073 #
17074 tmp_CFLAGS="$tmp_CFLAGS"
17075 ;;
17076 #
17077 esac
17078 #
17079 squeeze tmp_CPPFLAGS
17080 squeeze tmp_CFLAGS
17081 #
17082 if test ! -z "$tmp_CFLAGS" || test ! -z "$tmp_CPPFLAGS"; then
17083 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler accepts some basic options" >&5
17084$as_echo_n "checking if compiler accepts some basic options... " >&6; }
17085 CPPFLAGS="$tmp_save_CPPFLAGS $tmp_CPPFLAGS"
17086 CFLAGS="$tmp_save_CFLAGS $tmp_CFLAGS"
17087 squeeze CPPFLAGS
17088 squeeze CFLAGS
17089
17090 tmp_compiler_works="unknown"
17091 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17092/* end confdefs.h. */
17093
17094
17095
17096int main (void)
17097{
17098
17099 int i = 1;
17100 return i;
17101
17102 ;
17103 return 0;
17104}
17105
17106_ACEOF
17107if ac_fn_c_try_compile "$LINENO"; then :
17108
17109 tmp_compiler_works="yes"
17110
17111else
17112
17113 tmp_compiler_works="no"
17114 echo " " >&6
17115 sed 's/^/cc-fail: /' conftest.err >&6
17116 echo " " >&6
17117
17118fi
17119rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17120 if test "$tmp_compiler_works" = "yes"; then
17121 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17122/* end confdefs.h. */
17123
17124
17125
17126int main (void)
17127{
17128
17129 int i = 1;
17130 return i;
17131
17132 ;
17133 return 0;
17134}
17135
17136_ACEOF
17137if ac_fn_c_try_link "$LINENO"; then :
17138
17139 tmp_compiler_works="yes"
17140
17141else
17142
17143 tmp_compiler_works="no"
17144 echo " " >&6
17145 sed 's/^/link-fail: /' conftest.err >&6
17146 echo " " >&6
17147
17148fi
17149rm -f core conftest.err conftest.$ac_objext \
17150 conftest$ac_exeext conftest.$ac_ext
17151 fi
17152 if test "x$cross_compiling" != "xyes" &&
17153 test "$tmp_compiler_works" = "yes"; then
Elliott Hughesa93fb052018-12-12 14:22:48 -080017154
17155
17156 old=$LD_LIBRARY_PATH
17157 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
17158 export LD_LIBRARY_PATH
17159 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070017160 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17161$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17162as_fn_error $? "cannot run test program while cross compiling
17163See \`config.log' for more details" "$LINENO" 5; }
17164else
17165 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17166/* end confdefs.h. */
17167
17168
17169# ifdef __STDC__
17170# include <stdlib.h>
17171# endif
17172
17173int main (void)
17174{
17175
17176 int i = 0;
17177 exit(i);
17178
17179 ;
17180 return 0;
17181}
17182
17183_ACEOF
17184if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughesa93fb052018-12-12 14:22:48 -080017185 tmp_compiler_works="yes"
Elliott Hughes82be86d2017-09-20 17:00:17 -070017186
17187else
Elliott Hughesa93fb052018-12-12 14:22:48 -080017188 tmp_compiler_works="no"
Elliott Hughes82be86d2017-09-20 17:00:17 -070017189 echo " " >&6
17190 echo "run-fail: test program exited with status $ac_status" >&6
17191 echo " " >&6
17192
17193fi
17194rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17195 conftest.$ac_objext conftest.beam conftest.$ac_ext
17196fi
17197
Elliott Hughesa93fb052018-12-12 14:22:48 -080017198 LD_LIBRARY_PATH=$old # restore
17199
Elliott Hughes82be86d2017-09-20 17:00:17 -070017200 fi
17201 if test "$tmp_compiler_works" = "yes"; then
17202
17203 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17204$as_echo "yes" >&6; }
17205 { $as_echo "$as_me:${as_lineno-$LINENO}: compiler options added: $tmp_CFLAGS $tmp_CPPFLAGS" >&5
17206$as_echo "$as_me: compiler options added: $tmp_CFLAGS $tmp_CPPFLAGS" >&6;}
17207
17208 else
17209
17210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17211$as_echo "no" >&6; }
17212 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: compiler options rejected: $tmp_CFLAGS $tmp_CPPFLAGS" >&5
17213$as_echo "$as_me: WARNING: compiler options rejected: $tmp_CFLAGS $tmp_CPPFLAGS" >&2;}
17214 CPPFLAGS="$tmp_save_CPPFLAGS"
17215 CFLAGS="$tmp_save_CFLAGS"
17216
17217 fi
17218
17219 fi
17220 #
17221 fi
17222
17223
17224 #
17225 if test "$compiler_id" != "unknown"; then
17226 #
17227 tmp_save_CFLAGS="$CFLAGS"
17228 tmp_save_CPPFLAGS="$CPPFLAGS"
17229 #
17230 tmp_options=""
17231 tmp_CFLAGS="$CFLAGS"
17232 tmp_CPPFLAGS="$CPPFLAGS"
17233
17234 ac_var_stripped=""
17235 for word1 in $tmp_CFLAGS; do
17236 ac_var_strip_word="no"
17237 for word2 in $flags_dbg_all; do
17238 if test "$word1" = "$word2"; then
17239 ac_var_strip_word="yes"
17240 fi
17241 done
17242 if test "$ac_var_strip_word" = "no"; then
17243 ac_var_stripped="$ac_var_stripped $word1"
17244 fi
17245 done
17246 tmp_CFLAGS="$ac_var_stripped"
17247 squeeze tmp_CFLAGS
17248
17249
17250 ac_var_stripped=""
17251 for word1 in $tmp_CPPFLAGS; do
17252 ac_var_strip_word="no"
17253 for word2 in $flags_dbg_all; do
17254 if test "$word1" = "$word2"; then
17255 ac_var_strip_word="yes"
17256 fi
17257 done
17258 if test "$ac_var_strip_word" = "no"; then
17259 ac_var_stripped="$ac_var_stripped $word1"
17260 fi
17261 done
17262 tmp_CPPFLAGS="$ac_var_stripped"
17263 squeeze tmp_CPPFLAGS
17264
17265 #
17266 if test "$want_debug" = "yes"; then
17267 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler accepts debug enabling options" >&5
17268$as_echo_n "checking if compiler accepts debug enabling options... " >&6; }
17269 tmp_options="$flags_dbg_yes"
17270 fi
17271 if test "$want_debug" = "no"; then
17272 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler accepts debug disabling options" >&5
17273$as_echo_n "checking if compiler accepts debug disabling options... " >&6; }
17274 tmp_options="$flags_dbg_off"
17275 fi
17276 #
17277 if test "$flags_prefer_cppflags" = "yes"; then
17278 CPPFLAGS="$tmp_CPPFLAGS $tmp_options"
17279 CFLAGS="$tmp_CFLAGS"
17280 else
17281 CPPFLAGS="$tmp_CPPFLAGS"
17282 CFLAGS="$tmp_CFLAGS $tmp_options"
17283 fi
17284 squeeze CPPFLAGS
17285 squeeze CFLAGS
17286
17287 tmp_compiler_works="unknown"
17288 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17289/* end confdefs.h. */
17290
17291
17292
17293int main (void)
17294{
17295
17296 int i = 1;
17297 return i;
17298
17299 ;
17300 return 0;
17301}
17302
17303_ACEOF
17304if ac_fn_c_try_compile "$LINENO"; then :
17305
17306 tmp_compiler_works="yes"
17307
17308else
17309
17310 tmp_compiler_works="no"
17311 echo " " >&6
17312 sed 's/^/cc-fail: /' conftest.err >&6
17313 echo " " >&6
17314
17315fi
17316rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17317 if test "$tmp_compiler_works" = "yes"; then
17318 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17319/* end confdefs.h. */
17320
17321
17322
17323int main (void)
17324{
17325
17326 int i = 1;
17327 return i;
17328
17329 ;
17330 return 0;
17331}
17332
17333_ACEOF
17334if ac_fn_c_try_link "$LINENO"; then :
17335
17336 tmp_compiler_works="yes"
17337
17338else
17339
17340 tmp_compiler_works="no"
17341 echo " " >&6
17342 sed 's/^/link-fail: /' conftest.err >&6
17343 echo " " >&6
17344
17345fi
17346rm -f core conftest.err conftest.$ac_objext \
17347 conftest$ac_exeext conftest.$ac_ext
17348 fi
17349 if test "x$cross_compiling" != "xyes" &&
17350 test "$tmp_compiler_works" = "yes"; then
Elliott Hughesa93fb052018-12-12 14:22:48 -080017351
17352
17353 old=$LD_LIBRARY_PATH
17354 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
17355 export LD_LIBRARY_PATH
17356 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070017357 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17358$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17359as_fn_error $? "cannot run test program while cross compiling
17360See \`config.log' for more details" "$LINENO" 5; }
17361else
17362 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17363/* end confdefs.h. */
17364
17365
17366# ifdef __STDC__
17367# include <stdlib.h>
17368# endif
17369
17370int main (void)
17371{
17372
17373 int i = 0;
17374 exit(i);
17375
17376 ;
17377 return 0;
17378}
17379
17380_ACEOF
17381if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughesa93fb052018-12-12 14:22:48 -080017382 tmp_compiler_works="yes"
Elliott Hughes82be86d2017-09-20 17:00:17 -070017383
17384else
Elliott Hughesa93fb052018-12-12 14:22:48 -080017385 tmp_compiler_works="no"
Elliott Hughes82be86d2017-09-20 17:00:17 -070017386 echo " " >&6
17387 echo "run-fail: test program exited with status $ac_status" >&6
17388 echo " " >&6
17389
17390fi
17391rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17392 conftest.$ac_objext conftest.beam conftest.$ac_ext
17393fi
17394
Elliott Hughesa93fb052018-12-12 14:22:48 -080017395 LD_LIBRARY_PATH=$old # restore
17396
Elliott Hughes82be86d2017-09-20 17:00:17 -070017397 fi
17398 if test "$tmp_compiler_works" = "yes"; then
17399
17400 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17401$as_echo "yes" >&6; }
17402 { $as_echo "$as_me:${as_lineno-$LINENO}: compiler options added: $tmp_options" >&5
17403$as_echo "$as_me: compiler options added: $tmp_options" >&6;}
17404
17405 else
17406
17407 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17408$as_echo "no" >&6; }
17409 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: compiler options rejected: $tmp_options" >&5
17410$as_echo "$as_me: WARNING: compiler options rejected: $tmp_options" >&2;}
17411 CPPFLAGS="$tmp_save_CPPFLAGS"
17412 CFLAGS="$tmp_save_CFLAGS"
17413
17414 fi
17415
17416 #
17417 fi
17418
17419
17420 #
17421 if test "$compiler_id" != "unknown"; then
17422 #
17423 tmp_save_CFLAGS="$CFLAGS"
17424 tmp_save_CPPFLAGS="$CPPFLAGS"
17425 #
17426 tmp_options=""
17427 tmp_CFLAGS="$CFLAGS"
17428 tmp_CPPFLAGS="$CPPFLAGS"
17429 honor_optimize_option="yes"
17430 #
17431 #
17432 if test "$want_optimize" = "assume_no" ||
17433 test "$want_optimize" = "assume_yes"; then
17434 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler optimizer assumed setting might be used" >&5
17435$as_echo_n "checking if compiler optimizer assumed setting might be used... " >&6; }
17436
17437
17438 ac_var_match_word="no"
17439 for word1 in $tmp_CFLAGS; do
17440 for word2 in $flags_opt_all; do
17441 if test "$word1" = "$word2"; then
17442 ac_var_match_word="yes"
17443 fi
17444 done
17445 done
17446
17447 if test "$ac_var_match_word" = "yes"; then
17448
17449 honor_optimize_option="no"
17450
17451
17452 fi
17453
17454
17455
17456 ac_var_match_word="no"
17457 for word1 in $tmp_CPPFLAGS; do
17458 for word2 in $flags_opt_all; do
17459 if test "$word1" = "$word2"; then
17460 ac_var_match_word="yes"
17461 fi
17462 done
17463 done
17464
17465 if test "$ac_var_match_word" = "yes"; then
17466
17467 honor_optimize_option="no"
17468
17469
17470 fi
17471
17472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $honor_optimize_option" >&5
17473$as_echo "$honor_optimize_option" >&6; }
17474 if test "$honor_optimize_option" = "yes"; then
17475 if test "$want_optimize" = "assume_yes"; then
17476 want_optimize="yes"
17477 fi
17478 if test "$want_optimize" = "assume_no"; then
17479 want_optimize="no"
17480 fi
17481 fi
17482 fi
17483 #
17484 if test "$honor_optimize_option" = "yes"; then
17485
17486 ac_var_stripped=""
17487 for word1 in $tmp_CFLAGS; do
17488 ac_var_strip_word="no"
17489 for word2 in $flags_opt_all; do
17490 if test "$word1" = "$word2"; then
17491 ac_var_strip_word="yes"
17492 fi
17493 done
17494 if test "$ac_var_strip_word" = "no"; then
17495 ac_var_stripped="$ac_var_stripped $word1"
17496 fi
17497 done
17498 tmp_CFLAGS="$ac_var_stripped"
17499 squeeze tmp_CFLAGS
17500
17501
17502 ac_var_stripped=""
17503 for word1 in $tmp_CPPFLAGS; do
17504 ac_var_strip_word="no"
17505 for word2 in $flags_opt_all; do
17506 if test "$word1" = "$word2"; then
17507 ac_var_strip_word="yes"
17508 fi
17509 done
17510 if test "$ac_var_strip_word" = "no"; then
17511 ac_var_stripped="$ac_var_stripped $word1"
17512 fi
17513 done
17514 tmp_CPPFLAGS="$ac_var_stripped"
17515 squeeze tmp_CPPFLAGS
17516
17517 if test "$want_optimize" = "yes"; then
17518 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler accepts optimizer enabling options" >&5
17519$as_echo_n "checking if compiler accepts optimizer enabling options... " >&6; }
17520 tmp_options="$flags_opt_yes"
17521 fi
17522 if test "$want_optimize" = "no"; then
17523 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler accepts optimizer disabling options" >&5
17524$as_echo_n "checking if compiler accepts optimizer disabling options... " >&6; }
17525 tmp_options="$flags_opt_off"
17526 fi
17527 if test "$flags_prefer_cppflags" = "yes"; then
17528 CPPFLAGS="$tmp_CPPFLAGS $tmp_options"
17529 CFLAGS="$tmp_CFLAGS"
17530 else
17531 CPPFLAGS="$tmp_CPPFLAGS"
17532 CFLAGS="$tmp_CFLAGS $tmp_options"
17533 fi
17534 squeeze CPPFLAGS
17535 squeeze CFLAGS
17536
17537 tmp_compiler_works="unknown"
17538 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17539/* end confdefs.h. */
17540
17541
17542
17543int main (void)
17544{
17545
17546 int i = 1;
17547 return i;
17548
17549 ;
17550 return 0;
17551}
17552
17553_ACEOF
17554if ac_fn_c_try_compile "$LINENO"; then :
17555
17556 tmp_compiler_works="yes"
17557
17558else
17559
17560 tmp_compiler_works="no"
17561 echo " " >&6
17562 sed 's/^/cc-fail: /' conftest.err >&6
17563 echo " " >&6
17564
17565fi
17566rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17567 if test "$tmp_compiler_works" = "yes"; then
17568 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17569/* end confdefs.h. */
17570
17571
17572
17573int main (void)
17574{
17575
17576 int i = 1;
17577 return i;
17578
17579 ;
17580 return 0;
17581}
17582
17583_ACEOF
17584if ac_fn_c_try_link "$LINENO"; then :
17585
17586 tmp_compiler_works="yes"
17587
17588else
17589
17590 tmp_compiler_works="no"
17591 echo " " >&6
17592 sed 's/^/link-fail: /' conftest.err >&6
17593 echo " " >&6
17594
17595fi
17596rm -f core conftest.err conftest.$ac_objext \
17597 conftest$ac_exeext conftest.$ac_ext
17598 fi
17599 if test "x$cross_compiling" != "xyes" &&
17600 test "$tmp_compiler_works" = "yes"; then
Elliott Hughesa93fb052018-12-12 14:22:48 -080017601
17602
17603 old=$LD_LIBRARY_PATH
17604 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
17605 export LD_LIBRARY_PATH
17606 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070017607 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17608$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17609as_fn_error $? "cannot run test program while cross compiling
17610See \`config.log' for more details" "$LINENO" 5; }
17611else
17612 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17613/* end confdefs.h. */
17614
17615
17616# ifdef __STDC__
17617# include <stdlib.h>
17618# endif
17619
17620int main (void)
17621{
17622
17623 int i = 0;
17624 exit(i);
17625
17626 ;
17627 return 0;
17628}
17629
17630_ACEOF
17631if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughesa93fb052018-12-12 14:22:48 -080017632 tmp_compiler_works="yes"
Elliott Hughes82be86d2017-09-20 17:00:17 -070017633
17634else
Elliott Hughesa93fb052018-12-12 14:22:48 -080017635 tmp_compiler_works="no"
Elliott Hughes82be86d2017-09-20 17:00:17 -070017636 echo " " >&6
17637 echo "run-fail: test program exited with status $ac_status" >&6
17638 echo " " >&6
17639
17640fi
17641rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17642 conftest.$ac_objext conftest.beam conftest.$ac_ext
17643fi
17644
Elliott Hughesa93fb052018-12-12 14:22:48 -080017645 LD_LIBRARY_PATH=$old # restore
17646
Elliott Hughes82be86d2017-09-20 17:00:17 -070017647 fi
17648 if test "$tmp_compiler_works" = "yes"; then
17649
17650 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
17651$as_echo "yes" >&6; }
17652 { $as_echo "$as_me:${as_lineno-$LINENO}: compiler options added: $tmp_options" >&5
17653$as_echo "$as_me: compiler options added: $tmp_options" >&6;}
17654
17655 else
17656
17657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17658$as_echo "no" >&6; }
17659 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: compiler options rejected: $tmp_options" >&5
17660$as_echo "$as_me: WARNING: compiler options rejected: $tmp_options" >&2;}
17661 CPPFLAGS="$tmp_save_CPPFLAGS"
17662 CFLAGS="$tmp_save_CFLAGS"
17663
17664 fi
17665
17666 fi
17667 #
17668 fi
17669
17670
17671 #
17672 if test "$compiler_id" != "unknown"; then
17673 #
17674 tmp_save_CPPFLAGS="$CPPFLAGS"
17675 tmp_save_CFLAGS="$CFLAGS"
17676 tmp_CPPFLAGS=""
17677 tmp_CFLAGS=""
17678 #
17679 case "$compiler_id" in
17680 #
17681 CLANG)
17682 #
17683 if test "$want_warnings" = "yes"; then
17684 tmp_CFLAGS="$tmp_CFLAGS -pedantic"
17685 tmp_CFLAGS="$tmp_CFLAGS -Wall -Wextra"
17686 tmp_CFLAGS="$tmp_CFLAGS -Wpointer-arith -Wwrite-strings"
17687 tmp_CFLAGS="$tmp_CFLAGS -Wshadow"
17688 tmp_CFLAGS="$tmp_CFLAGS -Winline -Wnested-externs"
17689 tmp_CFLAGS="$tmp_CFLAGS -Wmissing-declarations"
17690 tmp_CFLAGS="$tmp_CFLAGS -Wmissing-prototypes"
17691 tmp_CFLAGS="$tmp_CFLAGS -Wno-long-long"
17692 tmp_CFLAGS="$tmp_CFLAGS -Wfloat-equal"
17693 tmp_CFLAGS="$tmp_CFLAGS -Wno-multichar -Wsign-compare"
17694 tmp_CFLAGS="$tmp_CFLAGS -Wundef"
17695 tmp_CFLAGS="$tmp_CFLAGS -Wno-format-nonliteral"
17696 tmp_CFLAGS="$tmp_CFLAGS -Wendif-labels -Wstrict-prototypes"
17697 tmp_CFLAGS="$tmp_CFLAGS -Wdeclaration-after-statement"
17698 tmp_CFLAGS="$tmp_CFLAGS -Wcast-align"
17699 tmp_CFLAGS="$tmp_CFLAGS -Wno-system-headers"
17700 tmp_CFLAGS="$tmp_CFLAGS -Wshorten-64-to-32"
17701 #
17702 if test "$compiler_num" -ge "101"; then
17703 tmp_CFLAGS="$tmp_CFLAGS -Wunused"
17704 fi
17705 #
17706 if test "$compiler_num" -ge "208"; then
17707 tmp_CFLAGS="$tmp_CFLAGS -Wvla"
17708 fi
17709 #
17710 if test "$compiler_num" -ge "209"; then
17711 tmp_CFLAGS="$tmp_CFLAGS -Wshift-sign-overflow"
17712 fi
17713 #
17714 if test "$compiler_num" -ge "302"; then
17715 case $host_os in
17716 cygwin* | mingw*)
17717 ;;
17718 *)
17719 tmp_CFLAGS="$tmp_CFLAGS -Wmissing-variable-declarations"
17720 ;;
17721 esac
17722 fi
17723 #
17724 if test "$compiler_num" -ge "306"; then
17725 tmp_CFLAGS="$tmp_CFLAGS -Wdouble-promotion"
17726 fi
17727 #
17728 if test "$compiler_num" -ge "309"; then
17729 tmp_CFLAGS="$tmp_CFLAGS -Wcomma"
Alex Deymo486467e2017-12-19 19:04:07 +010017730 # avoid the varargs warning, fixed in 4.0
17731 # https://bugs.llvm.org/show_bug.cgi?id=29140
17732 if test "$compiler_num" -lt "400"; then
17733 tmp_CFLAGS="$tmp_CFLAGS -Wno-varargs"
17734 fi
Elliott Hughes82be86d2017-09-20 17:00:17 -070017735 fi
17736 fi
17737 ;;
17738 #
17739 DEC_C)
17740 #
17741 if test "$want_warnings" = "yes"; then
17742 tmp_CFLAGS="$tmp_CFLAGS -msg_enable level3"
17743 fi
17744 ;;
17745 #
17746 GNU_C)
17747 #
17748 if test "$want_warnings" = "yes"; then
17749 #
17750 if test "x$cross_compiling" != "xyes" ||
17751 test "$compiler_num" -ge "300"; then
17752 tmp_CFLAGS="$tmp_CFLAGS -pedantic"
17753 fi
17754 #
17755 tmp_CFLAGS="$tmp_CFLAGS -Wall -W"
17756 #
17757 if test "$compiler_num" -ge "104"; then
17758 tmp_CFLAGS="$tmp_CFLAGS -Wpointer-arith -Wwrite-strings"
17759 if test "x$cross_compiling" != "xyes" ||
17760 test "$compiler_num" -ge "300"; then
17761 tmp_CFLAGS="$tmp_CFLAGS -Wunused -Wshadow"
17762 fi
17763 fi
17764 #
17765 if test "$compiler_num" -ge "207"; then
17766 tmp_CFLAGS="$tmp_CFLAGS -Winline -Wnested-externs"
17767 if test "x$cross_compiling" != "xyes" ||
17768 test "$compiler_num" -ge "300"; then
17769 tmp_CFLAGS="$tmp_CFLAGS -Wmissing-declarations"
17770 tmp_CFLAGS="$tmp_CFLAGS -Wmissing-prototypes"
17771 fi
17772 fi
17773 #
17774 if test "$compiler_num" -ge "295"; then
17775 tmp_CFLAGS="$tmp_CFLAGS -Wno-long-long"
Elliott Hughesb1ef70f2018-10-30 11:28:38 -070017776 tmp_CFLAGS="$tmp_CFLAGS -Wbad-function-cast"
Elliott Hughes82be86d2017-09-20 17:00:17 -070017777 fi
17778 #
17779 if test "$compiler_num" -ge "296"; then
17780 tmp_CFLAGS="$tmp_CFLAGS -Wfloat-equal"
17781 tmp_CFLAGS="$tmp_CFLAGS -Wno-multichar -Wsign-compare"
17782 tmp_CFLAGS="$tmp_CFLAGS -Wundef"
17783 fi
17784 #
17785 if test "$compiler_num" -ge "297"; then
17786 tmp_CFLAGS="$tmp_CFLAGS -Wno-format-nonliteral"
17787 fi
17788 #
17789 if test "$compiler_num" -ge "300"; then
17790 tmp_CFLAGS="$tmp_CFLAGS"
17791 fi
17792 #
17793 if test "$compiler_num" -ge "303"; then
17794 tmp_CFLAGS="$tmp_CFLAGS -Wendif-labels -Wstrict-prototypes"
17795 fi
17796 #
17797 if test "$compiler_num" -ge "304"; then
17798 tmp_CFLAGS="$tmp_CFLAGS -Wdeclaration-after-statement"
Elliott Hughesb1ef70f2018-10-30 11:28:38 -070017799 tmp_CFLAGS="$tmp_CFLAGS -Wold-style-definition"
Elliott Hughes82be86d2017-09-20 17:00:17 -070017800 fi
17801 #
17802 if test "$compiler_num" -ge "400"; then
17803 tmp_CFLAGS="$tmp_CFLAGS -Wstrict-aliasing=3"
17804 fi
17805 #
17806 if test "$compiler_num" -ge "402"; then
17807 tmp_CFLAGS="$tmp_CFLAGS -Wcast-align"
17808 fi
17809 #
17810 if test "$compiler_num" -ge "403"; then
17811 tmp_CFLAGS="$tmp_CFLAGS -Wtype-limits -Wold-style-declaration"
17812 tmp_CFLAGS="$tmp_CFLAGS -Wmissing-parameter-type -Wempty-body"
17813 tmp_CFLAGS="$tmp_CFLAGS -Wclobbered -Wignored-qualifiers"
17814 tmp_CFLAGS="$tmp_CFLAGS -Wconversion -Wno-sign-conversion -Wvla"
Elliott Hughesb1ef70f2018-10-30 11:28:38 -070017815 tmp_CFLAGS="$tmp_CFLAGS -ftree-vrp"
Elliott Hughes82be86d2017-09-20 17:00:17 -070017816 fi
17817 #
17818 if test "$compiler_num" -ge "405"; then
17819 if test "$curl_cv_have_def__WIN32" = "yes"; then
17820 tmp_CFLAGS="$tmp_CFLAGS -Wno-pedantic-ms-format"
17821 fi
17822 fi
17823 #
17824 if test "$compiler_num" -ge "406"; then
17825 tmp_CFLAGS="$tmp_CFLAGS -Wdouble-promotion"
17826 fi
17827 #
Elliott Hughesb1ef70f2018-10-30 11:28:38 -070017828 if test "$compiler_num" -ge "408"; then
17829 tmp_CFLAGS="$tmp_CFLAGS -Wformat=2"
17830 fi
17831 #
17832 if test "$compiler_num" -ge "500"; then
17833 tmp_CFLAGS="$tmp_CFLAGS -Warray-bounds=2"
17834 fi
17835 #
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070017836 if test "$compiler_num" -ge "600"; then
17837 tmp_CFLAGS="$tmp_CFLAGS -Wshift-negative-value"
17838 tmp_CFLAGS="$tmp_CFLAGS -Wshift-overflow=2"
Elliott Hughesb1ef70f2018-10-30 11:28:38 -070017839 tmp_CFLAGS="$tmp_CFLAGS -Wnull-dereference -fdelete-null-pointer-checks"
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070017840 tmp_CFLAGS="$tmp_CFLAGS -Wduplicated-cond"
Elliott Hughesb1ef70f2018-10-30 11:28:38 -070017841 tmp_CFLAGS="$tmp_CFLAGS -Wunused-const-variable"
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070017842 fi
17843 #
17844 if test "$compiler_num" -ge "700"; then
17845 tmp_CFLAGS="$tmp_CFLAGS -Wduplicated-branches"
17846 tmp_CFLAGS="$tmp_CFLAGS -Wrestrict"
17847 tmp_CFLAGS="$tmp_CFLAGS -Walloc-zero"
17848 tmp_CFLAGS="$tmp_CFLAGS -Wformat-overflow=2"
17849 tmp_CFLAGS="$tmp_CFLAGS -Wformat-truncation=2"
Elliott Hughesb1ef70f2018-10-30 11:28:38 -070017850 tmp_CFLAGS="$tmp_CFLAGS -Wimplicit-fallthrough=4"
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070017851 fi
17852 #
Elliott Hughes82be86d2017-09-20 17:00:17 -070017853 fi
17854 #
17855 if test "$compiler_num" -ge "300"; then
17856 tmp_CFLAGS="$tmp_CFLAGS -Wno-system-headers"
17857 else
17858 if test "x$cross_compiling" = "xyes"; then
17859 if test "$compiler_num" -ge "104"; then
17860 tmp_CFLAGS="$tmp_CFLAGS -Wno-unused -Wno-shadow"
17861 fi
17862 if test "$compiler_num" -ge "207"; then
17863 tmp_CFLAGS="$tmp_CFLAGS -Wno-missing-declarations"
17864 tmp_CFLAGS="$tmp_CFLAGS -Wno-missing-prototypes"
17865 fi
17866 fi
17867 fi
17868 ;;
17869 #
17870 HP_UX_C)
17871 #
17872 if test "$want_warnings" = "yes"; then
17873 tmp_CFLAGS="$tmp_CFLAGS +w1"
17874 fi
17875 ;;
17876 #
17877 IBM_C)
17878 #
17879 tmp_CFLAGS="$tmp_CFLAGS"
17880 ;;
17881 #
17882 INTEL_UNIX_C)
17883 #
17884 if test "$want_warnings" = "yes"; then
17885 if test "$compiler_num" -gt "600"; then
17886 tmp_CPPFLAGS="$tmp_CPPFLAGS -Wall -w2"
17887 tmp_CPPFLAGS="$tmp_CPPFLAGS -Wcheck"
17888 tmp_CPPFLAGS="$tmp_CPPFLAGS -Wcomment"
17889 tmp_CPPFLAGS="$tmp_CPPFLAGS -Wdeprecated"
17890 tmp_CPPFLAGS="$tmp_CPPFLAGS -Wmissing-prototypes"
17891 tmp_CPPFLAGS="$tmp_CPPFLAGS -Wp64"
17892 tmp_CPPFLAGS="$tmp_CPPFLAGS -Wpointer-arith"
17893 tmp_CPPFLAGS="$tmp_CPPFLAGS -Wreturn-type"
17894 tmp_CPPFLAGS="$tmp_CPPFLAGS -Wshadow"
17895 tmp_CPPFLAGS="$tmp_CPPFLAGS -Wuninitialized"
17896 tmp_CPPFLAGS="$tmp_CPPFLAGS -Wunused-function"
17897 fi
17898 fi
17899 tmp_CFLAGS="$tmp_CFLAGS -fno-omit-frame-pointer"
17900 tmp_CFLAGS="$tmp_CFLAGS -fno-strict-aliasing"
17901 tmp_CFLAGS="$tmp_CFLAGS -fp-model precise"
17902 if test "$compiler_num" -ge "1000"; then
17903 tmp_CFLAGS="$tmp_CFLAGS -vec-report0"
17904 fi
17905 ;;
17906 #
17907 INTEL_WINDOWS_C)
17908 #
17909 tmp_CFLAGS="$tmp_CFLAGS"
17910 ;;
17911 #
17912 LCC)
17913 #
17914 if test "$want_warnings" = "yes"; then
17915 tmp_CFLAGS="$tmp_CFLAGS"
17916 fi
17917 ;;
17918 #
17919 SGI_MIPS_C)
17920 #
17921 if test "$want_warnings" = "yes"; then
17922 tmp_CFLAGS="$tmp_CFLAGS -fullwarn"
17923 fi
17924 ;;
17925 #
17926 SGI_MIPSPRO_C)
17927 #
17928 if test "$want_warnings" = "yes"; then
17929 tmp_CFLAGS="$tmp_CFLAGS -fullwarn"
17930 tmp_CFLAGS="$tmp_CFLAGS -woff 1209"
17931 fi
17932 ;;
17933 #
17934 SUNPRO_C)
17935 #
17936 if test "$want_warnings" = "yes"; then
17937 tmp_CFLAGS="$tmp_CFLAGS -v"
17938 fi
17939 ;;
17940 #
17941 TINY_C)
17942 #
17943 if test "$want_warnings" = "yes"; then
17944 tmp_CFLAGS="$tmp_CFLAGS -Wall"
17945 tmp_CFLAGS="$tmp_CFLAGS -Wwrite-strings"
17946 tmp_CFLAGS="$tmp_CFLAGS -Wunsupported"
17947 fi
17948 ;;
17949 #
17950 WATCOM_UNIX_C)
17951 #
17952 if test "$want_warnings" = "yes"; then
17953 tmp_CFLAGS="$tmp_CFLAGS -Wall -Wextra"
17954 fi
17955 ;;
17956 #
17957 WATCOM_WINDOWS_C)
17958 #
17959 tmp_CFLAGS="$tmp_CFLAGS"
17960 ;;
17961 #
17962 esac
17963 #
17964 squeeze tmp_CPPFLAGS
17965 squeeze tmp_CFLAGS
17966 #
17967 if test ! -z "$tmp_CFLAGS" || test ! -z "$tmp_CPPFLAGS"; then
17968 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler accepts strict warning options" >&5
17969$as_echo_n "checking if compiler accepts strict warning options... " >&6; }
17970 CPPFLAGS="$tmp_save_CPPFLAGS $tmp_CPPFLAGS"
17971 CFLAGS="$tmp_save_CFLAGS $tmp_CFLAGS"
17972 squeeze CPPFLAGS
17973 squeeze CFLAGS
17974
17975 tmp_compiler_works="unknown"
17976 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17977/* end confdefs.h. */
17978
17979
17980
17981int main (void)
17982{
17983
17984 int i = 1;
17985 return i;
17986
17987 ;
17988 return 0;
17989}
17990
17991_ACEOF
17992if ac_fn_c_try_compile "$LINENO"; then :
17993
17994 tmp_compiler_works="yes"
17995
17996else
17997
17998 tmp_compiler_works="no"
17999 echo " " >&6
18000 sed 's/^/cc-fail: /' conftest.err >&6
18001 echo " " >&6
18002
18003fi
18004rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18005 if test "$tmp_compiler_works" = "yes"; then
18006 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18007/* end confdefs.h. */
18008
18009
18010
18011int main (void)
18012{
18013
18014 int i = 1;
18015 return i;
18016
18017 ;
18018 return 0;
18019}
18020
18021_ACEOF
18022if ac_fn_c_try_link "$LINENO"; then :
18023
18024 tmp_compiler_works="yes"
18025
18026else
18027
18028 tmp_compiler_works="no"
18029 echo " " >&6
18030 sed 's/^/link-fail: /' conftest.err >&6
18031 echo " " >&6
18032
18033fi
18034rm -f core conftest.err conftest.$ac_objext \
18035 conftest$ac_exeext conftest.$ac_ext
18036 fi
18037 if test "x$cross_compiling" != "xyes" &&
18038 test "$tmp_compiler_works" = "yes"; then
Elliott Hughesa93fb052018-12-12 14:22:48 -080018039
18040
18041 old=$LD_LIBRARY_PATH
18042 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
18043 export LD_LIBRARY_PATH
18044 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070018045 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
18046$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18047as_fn_error $? "cannot run test program while cross compiling
18048See \`config.log' for more details" "$LINENO" 5; }
18049else
18050 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18051/* end confdefs.h. */
18052
18053
18054# ifdef __STDC__
18055# include <stdlib.h>
18056# endif
18057
18058int main (void)
18059{
18060
18061 int i = 0;
18062 exit(i);
18063
18064 ;
18065 return 0;
18066}
18067
18068_ACEOF
18069if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughesa93fb052018-12-12 14:22:48 -080018070 tmp_compiler_works="yes"
Elliott Hughes82be86d2017-09-20 17:00:17 -070018071
18072else
Elliott Hughesa93fb052018-12-12 14:22:48 -080018073 tmp_compiler_works="no"
Elliott Hughes82be86d2017-09-20 17:00:17 -070018074 echo " " >&6
18075 echo "run-fail: test program exited with status $ac_status" >&6
18076 echo " " >&6
18077
18078fi
18079rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18080 conftest.$ac_objext conftest.beam conftest.$ac_ext
18081fi
18082
Elliott Hughesa93fb052018-12-12 14:22:48 -080018083 LD_LIBRARY_PATH=$old # restore
18084
Elliott Hughes82be86d2017-09-20 17:00:17 -070018085 fi
18086 if test "$tmp_compiler_works" = "yes"; then
18087
18088 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18089$as_echo "yes" >&6; }
18090 { $as_echo "$as_me:${as_lineno-$LINENO}: compiler options added: $tmp_CFLAGS $tmp_CPPFLAGS" >&5
18091$as_echo "$as_me: compiler options added: $tmp_CFLAGS $tmp_CPPFLAGS" >&6;}
18092
18093 else
18094
18095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18096$as_echo "no" >&6; }
18097 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: compiler options rejected: $tmp_CFLAGS $tmp_CPPFLAGS" >&5
18098$as_echo "$as_me: WARNING: compiler options rejected: $tmp_CFLAGS $tmp_CPPFLAGS" >&2;}
18099 CPPFLAGS="$tmp_save_CPPFLAGS"
18100 CFLAGS="$tmp_save_CFLAGS"
18101
18102 fi
18103
18104 fi
18105 #
18106 fi
18107
18108
18109if test "$compiler_id" = "INTEL_UNIX_C"; then
18110 #
18111 if test "$compiler_num" -ge "1000"; then
18112 CFLAGS="$CFLAGS -shared-intel"
18113 elif test "$compiler_num" -ge "900"; then
18114 CFLAGS="$CFLAGS -i-dynamic"
18115 fi
18116 #
18117fi
18118
18119
18120 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler halts on compilation errors" >&5
18121$as_echo_n "checking if compiler halts on compilation errors... " >&6; }
18122 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18123/* end confdefs.h. */
18124
18125
18126
18127int main (void)
18128{
18129
18130 force compilation error
18131
18132 ;
18133 return 0;
18134}
18135
18136_ACEOF
18137if ac_fn_c_try_compile "$LINENO"; then :
18138
18139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18140$as_echo "no" >&6; }
18141 as_fn_error $? "compiler does not halt on compilation errors." "$LINENO" 5
18142
18143else
18144
18145 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18146$as_echo "yes" >&6; }
18147
18148fi
18149rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18150
18151
18152 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler halts on negative sized arrays" >&5
18153$as_echo_n "checking if compiler halts on negative sized arrays... " >&6; }
18154 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18155/* end confdefs.h. */
18156
18157
18158 typedef char bad_t[sizeof(char) == sizeof(int) ? -1 : -1 ];
18159
18160int main (void)
18161{
18162
18163 bad_t dummy;
18164
18165 ;
18166 return 0;
18167}
18168
18169_ACEOF
18170if ac_fn_c_try_compile "$LINENO"; then :
18171
18172 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18173$as_echo "no" >&6; }
18174 as_fn_error $? "compiler does not halt on negative sized arrays." "$LINENO" 5
18175
18176else
18177
18178 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18179$as_echo "yes" >&6; }
18180
18181fi
18182rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18183
18184
18185 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler halts on function prototype mismatch" >&5
18186$as_echo_n "checking if compiler halts on function prototype mismatch... " >&6; }
18187 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18188/* end confdefs.h. */
18189
18190
18191# include <stdlib.h>
18192 int rand(int n);
18193 int rand(int n)
18194 {
18195 if(n)
18196 return ++n;
18197 else
18198 return n;
18199 }
18200
18201int main (void)
18202{
18203
18204 int i[2]={0,0};
18205 int j = rand(i[0]);
18206 if(j)
18207 return j;
18208
18209 ;
18210 return 0;
18211}
18212
18213_ACEOF
18214if ac_fn_c_try_compile "$LINENO"; then :
18215
18216 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18217$as_echo "no" >&6; }
18218 as_fn_error $? "compiler does not halt on function prototype mismatch." "$LINENO" 5
18219
18220else
18221
18222 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18223$as_echo "yes" >&6; }
18224
18225fi
18226rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18227
18228
18229 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler supports hiding library internal symbols" >&5
18230$as_echo_n "checking if compiler supports hiding library internal symbols... " >&6; }
18231 supports_symbol_hiding="no"
18232 symbol_hiding_CFLAGS=""
18233 symbol_hiding_EXTERN=""
18234 tmp_CFLAGS=""
18235 tmp_EXTERN=""
18236 case "$compiler_id" in
18237 CLANG)
18238 tmp_EXTERN="__attribute__ ((__visibility__ (\"default\")))"
18239 tmp_CFLAGS="-fvisibility=hidden"
18240 supports_symbol_hiding="yes"
18241 ;;
18242 GNU_C)
18243 if test "$compiler_num" -ge "304"; then
18244 if $CC --help --verbose 2>/dev/null | grep fvisibility= >/dev/null ; then
18245 tmp_EXTERN="__attribute__ ((__visibility__ (\"default\")))"
18246 tmp_CFLAGS="-fvisibility=hidden"
18247 supports_symbol_hiding="yes"
18248 fi
18249 fi
18250 ;;
18251 INTEL_UNIX_C)
18252 if test "$compiler_num" -ge "900"; then
18253 if $CC --help --verbose 2>&1 | grep fvisibility= > /dev/null ; then
18254 tmp_save_CFLAGS="$CFLAGS"
18255 CFLAGS="$CFLAGS -fvisibility=hidden"
18256 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18257/* end confdefs.h. */
18258
18259
18260# include <stdio.h>
18261
18262int main (void)
18263{
18264
18265 printf("icc fvisibility bug test");
18266
18267 ;
18268 return 0;
18269}
18270
18271_ACEOF
18272if ac_fn_c_try_link "$LINENO"; then :
18273
18274 tmp_EXTERN="__attribute__ ((__visibility__ (\"default\")))"
18275 tmp_CFLAGS="-fvisibility=hidden"
18276 supports_symbol_hiding="yes"
18277
18278fi
18279rm -f core conftest.err conftest.$ac_objext \
18280 conftest$ac_exeext conftest.$ac_ext
18281 CFLAGS="$tmp_save_CFLAGS"
18282 fi
18283 fi
18284 ;;
18285 SUNPRO_C)
18286 if $CC 2>&1 | grep flags >/dev/null && $CC -flags | grep xldscope= >/dev/null ; then
18287 tmp_EXTERN="__global"
18288 tmp_CFLAGS="-xldscope=hidden"
18289 supports_symbol_hiding="yes"
18290 fi
18291 ;;
18292 esac
18293 if test "$supports_symbol_hiding" = "yes"; then
18294 tmp_save_CFLAGS="$CFLAGS"
18295 CFLAGS="$tmp_save_CFLAGS $tmp_CFLAGS"
18296 squeeze CFLAGS
18297 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18298/* end confdefs.h. */
18299
18300
18301 $tmp_EXTERN char *dummy(char *buff);
18302 char *dummy(char *buff)
18303 {
18304 if(buff)
18305 return ++buff;
18306 else
18307 return buff;
18308 }
18309
18310int main (void)
18311{
18312
18313 char b[16];
18314 char *r = dummy(&b[0]);
18315 if(r)
18316 return (int)*r;
18317
18318 ;
18319 return 0;
18320}
18321
18322_ACEOF
18323if ac_fn_c_try_compile "$LINENO"; then :
18324
18325 supports_symbol_hiding="yes"
18326 if test -f conftest.err; then
18327 grep 'visibility' conftest.err >/dev/null
18328 if test "$?" -eq "0"; then
18329 supports_symbol_hiding="no"
18330 fi
18331 fi
18332
18333else
18334
18335 supports_symbol_hiding="no"
18336 echo " " >&6
18337 sed 's/^/cc-src: /' conftest.$ac_ext >&6
18338 sed 's/^/cc-err: /' conftest.err >&6
18339 echo " " >&6
18340
18341fi
18342rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18343 CFLAGS="$tmp_save_CFLAGS"
18344 fi
18345 if test "$supports_symbol_hiding" = "yes"; then
18346 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18347$as_echo "yes" >&6; }
18348 symbol_hiding_CFLAGS="$tmp_CFLAGS"
18349 symbol_hiding_EXTERN="$tmp_EXTERN"
18350 else
18351 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18352$as_echo "no" >&6; }
18353 fi
18354
18355
18356
18357 supports_curldebug="unknown"
18358 if test "$want_curldebug" = "yes"; then
18359 if test "x$enable_shared" != "xno" &&
18360 test "x$enable_shared" != "xyes"; then
18361 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unknown enable_shared setting." >&5
18362$as_echo "$as_me: WARNING: unknown enable_shared setting." >&2;}
18363 supports_curldebug="no"
18364 fi
18365 if test "x$enable_static" != "xno" &&
18366 test "x$enable_static" != "xyes"; then
18367 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unknown enable_static setting." >&5
18368$as_echo "$as_me: WARNING: unknown enable_static setting." >&2;}
18369 supports_curldebug="no"
18370 fi
18371 if test "$supports_curldebug" != "no"; then
18372 if test "$enable_shared" = "yes" &&
18373 test "x$xc_lt_shlib_use_no_undefined" = 'xyes'; then
18374 supports_curldebug="no"
18375 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: shared library does not support undefined symbols." >&5
18376$as_echo "$as_me: WARNING: shared library does not support undefined symbols." >&2;}
18377 fi
18378 fi
18379 fi
18380 #
18381 if test "$want_curldebug" = "yes"; then
18382 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if curl debug memory tracking can be enabled" >&5
18383$as_echo_n "checking if curl debug memory tracking can be enabled... " >&6; }
18384 test "$supports_curldebug" = "no" || supports_curldebug="yes"
18385 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports_curldebug" >&5
18386$as_echo "$supports_curldebug" >&6; }
18387 if test "$supports_curldebug" = "no"; then
18388 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot enable curl debug memory tracking." >&5
18389$as_echo "$as_me: WARNING: cannot enable curl debug memory tracking." >&2;}
18390 want_curldebug="no"
18391 fi
18392 fi
Elliott Hughes82be86d2017-09-20 17:00:17 -070018393
18394 if test x$want_curldebug = xyes; then
18395 CURLDEBUG_TRUE=
18396 CURLDEBUG_FALSE='#'
18397else
18398 CURLDEBUG_TRUE='#'
18399 CURLDEBUG_FALSE=
18400fi
18401
18402
18403supports_unittests=yes
18404# cross-compilation of unit tests static library/programs fails when
18405# libcurl shared library is built. This might be due to a libtool or
18406# automake issue. In this case we disable unit tests.
18407if test "x$cross_compiling" != "xno" &&
18408 test "x$enable_shared" != "xno"; then
18409 supports_unittests=no
18410fi
18411
18412# IRIX 6.5.24 gcc 3.3 autobuilds fail unittests library compilation due to
18413# a problem related with OpenSSL headers and library versions not matching.
18414# Disable unit tests while time to further investigate this is found.
18415case $host in
18416 mips-sgi-irix6.5)
18417 if test "$compiler_id" = "GNU_C"; then
18418 supports_unittests=no
18419 fi
18420 ;;
18421esac
18422
18423# All AIX autobuilds fails unit tests linking against unittests library
18424# due to unittests library being built with no symbols or members. Libtool ?
18425# Disable unit tests while time to further investigate this is found.
18426case $host_os in
18427 aix*)
18428 supports_unittests=no
18429 ;;
18430esac
18431
18432if test "x$want_debug" = "xyes" &&
18433 test "x$supports_unittests" = "xyes"; then
18434 want_unittests=yes
18435else
18436 want_unittests=no
18437fi
18438 if test x$want_unittests = xyes; then
18439 BUILD_UNITTESTS_TRUE=
18440 BUILD_UNITTESTS_FALSE='#'
18441else
18442 BUILD_UNITTESTS_TRUE='#'
18443 BUILD_UNITTESTS_FALSE=
18444fi
18445
18446
18447
18448
18449
18450 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for windows.h" >&5
18451$as_echo_n "checking for windows.h... " >&6; }
18452if ${curl_cv_header_windows_h+:} false; then :
18453 $as_echo_n "(cached) " >&6
18454else
18455
18456 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18457/* end confdefs.h. */
18458
18459
18460#undef inline
18461#ifndef WIN32_LEAN_AND_MEAN
18462#define WIN32_LEAN_AND_MEAN
18463#endif
18464#include <windows.h>
18465
18466int main (void)
18467{
18468
18469#if defined(__CYGWIN__) || defined(__CEGCC__)
18470 HAVE_WINDOWS_H shall not be defined.
18471#else
18472 int dummy=2*WINVER;
18473#endif
18474
18475 ;
18476 return 0;
18477}
18478
18479_ACEOF
18480if ac_fn_c_try_compile "$LINENO"; then :
18481
18482 curl_cv_header_windows_h="yes"
18483
18484else
18485
18486 curl_cv_header_windows_h="no"
18487
18488fi
18489rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18490
18491fi
18492{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_windows_h" >&5
18493$as_echo "$curl_cv_header_windows_h" >&6; }
18494 case "$curl_cv_header_windows_h" in
18495 yes)
18496
18497cat >>confdefs.h <<_ACEOF
18498#define HAVE_WINDOWS_H 1
18499_ACEOF
18500
18501 ;;
18502 esac
18503
18504
18505 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build target is a native Windows one" >&5
18506$as_echo_n "checking whether build target is a native Windows one... " >&6; }
18507if ${curl_cv_native_windows+:} false; then :
18508 $as_echo_n "(cached) " >&6
18509else
18510
18511 if test "$curl_cv_header_windows_h" = "no"; then
18512 curl_cv_native_windows="no"
18513 else
18514 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18515/* end confdefs.h. */
18516
18517
18518
18519int main (void)
18520{
18521
18522#if defined(__MINGW32__) || defined(__MINGW32CE__) || \
18523 (defined(_MSC_VER) && (defined(_WIN32) || defined(_WIN64)))
18524 int dummy=1;
18525#else
18526 Not a native Windows build target.
18527#endif
18528
18529 ;
18530 return 0;
18531}
18532
18533_ACEOF
18534if ac_fn_c_try_compile "$LINENO"; then :
18535
18536 curl_cv_native_windows="yes"
18537
18538else
18539
18540 curl_cv_native_windows="no"
18541
18542fi
18543rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18544 fi
18545
18546fi
18547{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_native_windows" >&5
18548$as_echo "$curl_cv_native_windows" >&6; }
18549 if test "x$curl_cv_native_windows" = xyes; then
18550 DOING_NATIVE_WINDOWS_TRUE=
18551 DOING_NATIVE_WINDOWS_FALSE='#'
18552else
18553 DOING_NATIVE_WINDOWS_TRUE='#'
18554 DOING_NATIVE_WINDOWS_FALSE=
18555fi
18556
18557
18558case X-"$curl_cv_native_windows" in
18559 X-yes)
18560
18561 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for winsock.h" >&5
18562$as_echo_n "checking for winsock.h... " >&6; }
18563if ${curl_cv_header_winsock_h+:} false; then :
18564 $as_echo_n "(cached) " >&6
18565else
18566
18567 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18568/* end confdefs.h. */
18569
18570
18571#undef inline
18572#ifndef WIN32_LEAN_AND_MEAN
18573#define WIN32_LEAN_AND_MEAN
18574#endif
18575#include <windows.h>
18576#include <winsock.h>
18577
18578int main (void)
18579{
18580
18581#if defined(__CYGWIN__) || defined(__CEGCC__)
18582 HAVE_WINSOCK_H shall not be defined.
18583#else
18584 int dummy=WSACleanup();
18585#endif
18586
18587 ;
18588 return 0;
18589}
18590
18591_ACEOF
18592if ac_fn_c_try_compile "$LINENO"; then :
18593
18594 curl_cv_header_winsock_h="yes"
18595
18596else
18597
18598 curl_cv_header_winsock_h="no"
18599
18600fi
18601rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18602
18603fi
18604{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_winsock_h" >&5
18605$as_echo "$curl_cv_header_winsock_h" >&6; }
18606 case "$curl_cv_header_winsock_h" in
18607 yes)
18608
18609cat >>confdefs.h <<_ACEOF
18610#define HAVE_WINSOCK_H 1
18611_ACEOF
18612
18613 ;;
18614 esac
18615
18616
18617 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for winsock2.h" >&5
18618$as_echo_n "checking for winsock2.h... " >&6; }
18619if ${curl_cv_header_winsock2_h+:} false; then :
18620 $as_echo_n "(cached) " >&6
18621else
18622
18623 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18624/* end confdefs.h. */
18625
18626
18627#undef inline
18628#ifndef WIN32_LEAN_AND_MEAN
18629#define WIN32_LEAN_AND_MEAN
18630#endif
18631#include <windows.h>
18632#include <winsock2.h>
18633
18634int main (void)
18635{
18636
18637#if defined(__CYGWIN__) || defined(__CEGCC__) || defined(__MINGW32CE__)
18638 HAVE_WINSOCK2_H shall not be defined.
18639#else
18640 int dummy=2*IPPROTO_ESP;
18641#endif
18642
18643 ;
18644 return 0;
18645}
18646
18647_ACEOF
18648if ac_fn_c_try_compile "$LINENO"; then :
18649
18650 curl_cv_header_winsock2_h="yes"
18651
18652else
18653
18654 curl_cv_header_winsock2_h="no"
18655
18656fi
18657rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18658
18659fi
18660{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_winsock2_h" >&5
18661$as_echo "$curl_cv_header_winsock2_h" >&6; }
18662 case "$curl_cv_header_winsock2_h" in
18663 yes)
18664
18665cat >>confdefs.h <<_ACEOF
18666#define HAVE_WINSOCK2_H 1
18667_ACEOF
18668
18669 ;;
18670 esac
18671
18672
18673 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ws2tcpip.h" >&5
18674$as_echo_n "checking for ws2tcpip.h... " >&6; }
18675if ${curl_cv_header_ws2tcpip_h+:} false; then :
18676 $as_echo_n "(cached) " >&6
18677else
18678
18679 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18680/* end confdefs.h. */
18681
18682
18683#undef inline
18684#ifndef WIN32_LEAN_AND_MEAN
18685#define WIN32_LEAN_AND_MEAN
18686#endif
18687#include <windows.h>
18688#include <winsock2.h>
18689#include <ws2tcpip.h>
18690
18691int main (void)
18692{
18693
18694#if defined(__CYGWIN__) || defined(__CEGCC__) || defined(__MINGW32CE__)
18695 HAVE_WS2TCPIP_H shall not be defined.
18696#else
18697 int dummy=2*IP_PKTINFO;
18698#endif
18699
18700 ;
18701 return 0;
18702}
18703
18704_ACEOF
18705if ac_fn_c_try_compile "$LINENO"; then :
18706
18707 curl_cv_header_ws2tcpip_h="yes"
18708
18709else
18710
18711 curl_cv_header_ws2tcpip_h="no"
18712
18713fi
18714rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18715
18716fi
18717{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_ws2tcpip_h" >&5
18718$as_echo "$curl_cv_header_ws2tcpip_h" >&6; }
18719 case "$curl_cv_header_ws2tcpip_h" in
18720 yes)
18721
18722cat >>confdefs.h <<_ACEOF
18723#define HAVE_WS2TCPIP_H 1
18724_ACEOF
18725
18726 ;;
18727 esac
18728
18729
18730 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for winldap.h" >&5
18731$as_echo_n "checking for winldap.h... " >&6; }
18732if ${curl_cv_header_winldap_h+:} false; then :
18733 $as_echo_n "(cached) " >&6
18734else
18735
18736 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18737/* end confdefs.h. */
18738
18739
18740#undef inline
18741#ifdef HAVE_WINDOWS_H
18742#ifndef WIN32_LEAN_AND_MEAN
18743#define WIN32_LEAN_AND_MEAN
18744#endif
18745#include <windows.h>
18746#endif
18747#include <winldap.h>
18748
18749int main (void)
18750{
18751
18752#if defined(__CYGWIN__) || defined(__CEGCC__)
18753 HAVE_WINLDAP_H shall not be defined.
18754#else
18755 LDAP *ldp = ldap_init("dummy", LDAP_PORT);
18756 ULONG res = ldap_unbind(ldp);
18757#endif
18758
18759 ;
18760 return 0;
18761}
18762
18763_ACEOF
18764if ac_fn_c_try_compile "$LINENO"; then :
18765
18766 curl_cv_header_winldap_h="yes"
18767
18768else
18769
18770 curl_cv_header_winldap_h="no"
18771
18772fi
18773rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18774
18775fi
18776{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_winldap_h" >&5
18777$as_echo "$curl_cv_header_winldap_h" >&6; }
18778 case "$curl_cv_header_winldap_h" in
18779 yes)
18780
18781cat >>confdefs.h <<_ACEOF
18782#define HAVE_WINLDAP_H 1
18783_ACEOF
18784
18785 ;;
18786 esac
18787
18788
18789 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for winber.h" >&5
18790$as_echo_n "checking for winber.h... " >&6; }
18791if ${curl_cv_header_winber_h+:} false; then :
18792 $as_echo_n "(cached) " >&6
18793else
18794
18795 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18796/* end confdefs.h. */
18797
18798
18799#undef inline
18800#ifdef HAVE_WINDOWS_H
18801#ifndef WIN32_LEAN_AND_MEAN
18802#define WIN32_LEAN_AND_MEAN
18803#endif
18804#include <windows.h>
18805#endif
18806#include <winldap.h>
18807#include <winber.h>
18808
18809int main (void)
18810{
18811
18812#if defined(__CYGWIN__) || defined(__CEGCC__)
18813 HAVE_WINBER_H shall not be defined.
18814#else
18815 BERVAL *bvp = NULL;
18816 BerElement *bep = ber_init(bvp);
18817 ber_free(bep, 1);
18818#endif
18819
18820 ;
18821 return 0;
18822}
18823
18824_ACEOF
18825if ac_fn_c_try_compile "$LINENO"; then :
18826
18827 curl_cv_header_winber_h="yes"
18828
18829else
18830
18831 curl_cv_header_winber_h="no"
18832
18833fi
18834rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18835
18836fi
18837{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_winber_h" >&5
18838$as_echo "$curl_cv_header_winber_h" >&6; }
18839 case "$curl_cv_header_winber_h" in
18840 yes)
18841
18842cat >>confdefs.h <<_ACEOF
18843#define HAVE_WINBER_H 1
18844_ACEOF
18845
18846 ;;
18847 esac
18848
18849 ;;
18850 *)
18851 curl_cv_header_winsock_h="no"
18852 curl_cv_header_winsock2_h="no"
18853 curl_cv_header_ws2tcpip_h="no"
18854 curl_cv_header_winldap_h="no"
18855 curl_cv_header_winber_h="no"
18856 ;;
18857esac
18858
18859 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build target supports WIN32 file API" >&5
18860$as_echo_n "checking whether build target supports WIN32 file API... " >&6; }
18861 curl_win32_file_api="no"
18862 if test "$curl_cv_header_windows_h" = "yes"; then
18863 if test x"$enable_largefile" != "xno"; then
18864 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18865/* end confdefs.h. */
18866
18867
18868
18869int main (void)
18870{
18871
18872#if !defined(_WIN32_WCE) && \
18873 (defined(__MINGW32__) || \
18874 (defined(_MSC_VER) && (defined(_WIN32) || defined(_WIN64))))
18875 int dummy=1;
18876#else
18877 WIN32 large file API not supported.
18878#endif
18879
18880 ;
18881 return 0;
18882}
18883
18884_ACEOF
18885if ac_fn_c_try_compile "$LINENO"; then :
18886
18887 curl_win32_file_api="win32_large_files"
18888
18889fi
18890rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18891 fi
18892 if test "$curl_win32_file_api" = "no"; then
18893 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18894/* end confdefs.h. */
18895
18896
18897
18898int main (void)
18899{
18900
18901#if defined(_WIN32_WCE) || defined(__MINGW32__) || defined(_MSC_VER)
18902 int dummy=1;
18903#else
18904 WIN32 small file API not supported.
18905#endif
18906
18907 ;
18908 return 0;
18909}
18910
18911_ACEOF
18912if ac_fn_c_try_compile "$LINENO"; then :
18913
18914 curl_win32_file_api="win32_small_files"
18915
18916fi
18917rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18918 fi
18919 fi
18920 case "$curl_win32_file_api" in
18921 win32_large_files)
18922 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (large file enabled)" >&5
18923$as_echo "yes (large file enabled)" >&6; }
18924
18925cat >>confdefs.h <<_ACEOF
18926#define USE_WIN32_LARGE_FILES 1
18927_ACEOF
18928
18929 ;;
18930 win32_small_files)
18931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (large file disabled)" >&5
18932$as_echo "yes (large file disabled)" >&6; }
18933
18934cat >>confdefs.h <<_ACEOF
18935#define USE_WIN32_SMALL_FILES 1
18936_ACEOF
18937
18938 ;;
18939 *)
18940 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18941$as_echo "no" >&6; }
18942 ;;
18943 esac
18944
18945
18946
18947
18948 tst_cflags="no"
18949 case $host_os in
18950 darwin*)
18951 tst_cflags="yes"
18952 ;;
18953 esac
18954
18955 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for good-to-use Mac CFLAGS" >&5
18956$as_echo_n "checking for good-to-use Mac CFLAGS... " >&6; }
18957 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tst_cflags" >&5
18958$as_echo "$tst_cflags" >&6; };
18959
18960 if test "$tst_cflags" = "yes"; then
18961 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for *version-min in CFLAGS" >&5
18962$as_echo_n "checking for *version-min in CFLAGS... " >&6; }
18963 min=""
18964 if test -z "$(echo $CFLAGS | grep m.*os.*-version-min)"; then
18965 min="-mmacosx-version-min=10.8"
18966 CFLAGS="$CFLAGS $min"
18967 fi
18968 if test -z "$min"; then
18969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: set by user" >&5
18970$as_echo "set by user" >&6; }
18971 else
18972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $min set" >&5
18973$as_echo "$min set" >&6; }
18974 fi
18975
18976 old_CFLAGS=$CFLAGS
18977 CFLAGS="$CFLAGS -Werror=partial-availability"
18978 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -Werror=partial-availability" >&5
18979$as_echo_n "checking whether $CC accepts -Werror=partial-availability... " >&6; }
18980 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18981/* end confdefs.h. */
18982
18983int main (void)
18984{
18985
18986 ;
18987 return 0;
18988}
18989_ACEOF
18990if ac_fn_c_try_compile "$LINENO"; then :
18991 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
18992$as_echo "yes" >&6; }
18993else
18994 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18995$as_echo "no" >&6; }
18996 CFLAGS=$old_CFLAGS
18997fi
18998rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18999 fi
19000
19001
19002
Alex Deymo486467e2017-12-19 19:04:07 +010019003 { $as_echo "$as_me:${as_lineno-$LINENO}: checking to see if the compiler supports __builtin_available()" >&5
19004$as_echo_n "checking to see if the compiler supports __builtin_available()... " >&6; }
19005 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19006/* end confdefs.h. */
19007
19008
19009#include <stdlib.h>
19010
19011int main (void)
19012{
19013
19014 if (__builtin_available(macOS 10.8, iOS 5.0, *)) {}
19015
19016 ;
19017 return 0;
19018}
19019
19020_ACEOF
19021if ac_fn_c_try_compile "$LINENO"; then :
19022
19023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19024$as_echo "yes" >&6; }
19025
19026cat >>confdefs.h <<_ACEOF
19027#define HAVE_BUILTIN_AVAILABLE 1
19028_ACEOF
19029
19030
19031else
19032
19033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19034$as_echo "no" >&6; }
19035
19036fi
19037rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19038
19039
Haibo Huang65021c72019-03-27 15:37:23 -070019040
Elliott Hughes82be86d2017-09-20 17:00:17 -070019041{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support http" >&5
19042$as_echo_n "checking whether to support http... " >&6; }
19043# Check whether --enable-http was given.
19044if test "${enable_http+set}" = set; then :
19045 enableval=$enable_http; case "$enableval" in
19046 no)
19047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19048$as_echo "no" >&6; }
19049
19050$as_echo "#define CURL_DISABLE_HTTP 1" >>confdefs.h
19051
19052 disable_http="yes"
19053 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: disable HTTP disables FTP over proxy and RTSP" >&5
19054$as_echo "$as_me: WARNING: disable HTTP disables FTP over proxy and RTSP" >&2;}
19055 CURL_DISABLE_HTTP=1
19056
19057
19058$as_echo "#define CURL_DISABLE_RTSP 1" >>confdefs.h
19059
19060 CURL_DISABLE_RTSP=1
19061
19062 ;;
19063 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19064$as_echo "yes" >&6; }
19065 ;;
19066 esac
19067else
19068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19069$as_echo "yes" >&6; }
19070
19071fi
19072
19073{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support ftp" >&5
19074$as_echo_n "checking whether to support ftp... " >&6; }
19075# Check whether --enable-ftp was given.
19076if test "${enable_ftp+set}" = set; then :
19077 enableval=$enable_ftp; case "$enableval" in
19078 no)
19079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19080$as_echo "no" >&6; }
19081
19082$as_echo "#define CURL_DISABLE_FTP 1" >>confdefs.h
19083
19084 CURL_DISABLE_FTP=1
19085
19086 ;;
19087 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19088$as_echo "yes" >&6; }
19089 ;;
19090 esac
19091else
19092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19093$as_echo "yes" >&6; }
19094
19095fi
19096
19097{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support file" >&5
19098$as_echo_n "checking whether to support file... " >&6; }
19099# Check whether --enable-file was given.
19100if test "${enable_file+set}" = set; then :
19101 enableval=$enable_file; case "$enableval" in
19102 no)
19103 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19104$as_echo "no" >&6; }
19105
19106$as_echo "#define CURL_DISABLE_FILE 1" >>confdefs.h
19107
19108 CURL_DISABLE_FILE=1
19109
19110 ;;
19111 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19112$as_echo "yes" >&6; }
19113 ;;
19114 esac
19115else
19116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19117$as_echo "yes" >&6; }
19118
19119fi
19120
19121{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support ldap" >&5
19122$as_echo_n "checking whether to support ldap... " >&6; }
19123# Check whether --enable-ldap was given.
19124if test "${enable_ldap+set}" = set; then :
19125 enableval=$enable_ldap; case "$enableval" in
19126 no)
19127 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19128$as_echo "no" >&6; }
19129
19130$as_echo "#define CURL_DISABLE_LDAP 1" >>confdefs.h
19131
19132 CURL_DISABLE_LDAP=1
19133
19134 ;;
19135 *)
19136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19137$as_echo "yes" >&6; }
19138 ;;
19139 esac
19140else
19141
19142 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19143$as_echo "yes" >&6; }
19144
19145fi
19146
19147{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support ldaps" >&5
19148$as_echo_n "checking whether to support ldaps... " >&6; }
19149# Check whether --enable-ldaps was given.
19150if test "${enable_ldaps+set}" = set; then :
19151 enableval=$enable_ldaps; case "$enableval" in
19152 no)
19153 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19154$as_echo "no" >&6; }
19155
19156$as_echo "#define CURL_DISABLE_LDAPS 1" >>confdefs.h
19157
19158 CURL_DISABLE_LDAPS=1
19159
19160 ;;
19161 *) if test "x$CURL_DISABLE_LDAP" = "x1" ; then
19162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: LDAP needs to be enabled to support LDAPS" >&5
19163$as_echo "LDAP needs to be enabled to support LDAPS" >&6; }
19164
19165$as_echo "#define CURL_DISABLE_LDAPS 1" >>confdefs.h
19166
19167 CURL_DISABLE_LDAPS=1
19168
19169 else
19170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19171$as_echo "yes" >&6; }
19172
19173$as_echo "#define HAVE_LDAP_SSL 1" >>confdefs.h
19174
19175 HAVE_LDAP_SSL=1
19176
19177 fi
19178 ;;
19179 esac
19180else
19181
19182 if test "x$CURL_DISABLE_LDAP" = "x1" ; then
19183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19184$as_echo "no" >&6; }
19185
19186$as_echo "#define CURL_DISABLE_LDAPS 1" >>confdefs.h
19187
19188 CURL_DISABLE_LDAPS=1
19189
19190 else
19191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19192$as_echo "yes" >&6; }
19193
19194$as_echo "#define HAVE_LDAP_SSL 1" >>confdefs.h
19195
19196 HAVE_LDAP_SSL=1
19197
19198 fi
19199
19200fi
19201
19202
19203{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support rtsp" >&5
19204$as_echo_n "checking whether to support rtsp... " >&6; }
19205# Check whether --enable-rtsp was given.
19206if test "${enable_rtsp+set}" = set; then :
19207 enableval=$enable_rtsp; case "$enableval" in
19208 no)
19209 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19210$as_echo "no" >&6; }
19211
19212$as_echo "#define CURL_DISABLE_RTSP 1" >>confdefs.h
19213
19214 CURL_DISABLE_RTSP=1
19215
19216 ;;
19217 *) if test x$CURL_DISABLE_HTTP = x1 ; then
19218 as_fn_error $? "HTTP support needs to be enabled in order to enable RTSP support!" "$LINENO" 5
19219 else
19220 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19221$as_echo "yes" >&6; }
19222 curl_rtsp_msg="enabled"
19223 fi
19224 ;;
19225 esac
19226else
19227 if test "x$CURL_DISABLE_HTTP" != "x1"; then
19228 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19229$as_echo "yes" >&6; }
19230 curl_rtsp_msg="enabled"
19231 else
19232 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19233$as_echo "no" >&6; }
19234 fi
19235
19236fi
19237
19238
19239{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support proxies" >&5
19240$as_echo_n "checking whether to support proxies... " >&6; }
19241# Check whether --enable-proxy was given.
19242if test "${enable_proxy+set}" = set; then :
19243 enableval=$enable_proxy; case "$enableval" in
19244 no)
19245 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19246$as_echo "no" >&6; }
19247
19248$as_echo "#define CURL_DISABLE_PROXY 1" >>confdefs.h
19249
19250 CURL_DISABLE_PROXY=1
19251
19252 ;;
19253 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19254$as_echo "yes" >&6; }
19255 ;;
19256 esac
19257else
19258 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19259$as_echo "yes" >&6; }
19260
19261fi
19262
19263
19264{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support dict" >&5
19265$as_echo_n "checking whether to support dict... " >&6; }
19266# Check whether --enable-dict was given.
19267if test "${enable_dict+set}" = set; then :
19268 enableval=$enable_dict; case "$enableval" in
19269 no)
19270 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19271$as_echo "no" >&6; }
19272
19273$as_echo "#define CURL_DISABLE_DICT 1" >>confdefs.h
19274
19275 CURL_DISABLE_DICT=1
19276
19277 ;;
19278 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19279$as_echo "yes" >&6; }
19280 ;;
19281 esac
19282else
19283 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19284$as_echo "yes" >&6; }
19285
19286fi
19287
19288{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support telnet" >&5
19289$as_echo_n "checking whether to support telnet... " >&6; }
19290# Check whether --enable-telnet was given.
19291if test "${enable_telnet+set}" = set; then :
19292 enableval=$enable_telnet; case "$enableval" in
19293 no)
19294 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19295$as_echo "no" >&6; }
19296
19297$as_echo "#define CURL_DISABLE_TELNET 1" >>confdefs.h
19298
19299 CURL_DISABLE_TELNET=1
19300
19301 ;;
19302 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19303$as_echo "yes" >&6; }
19304 ;;
19305 esac
19306else
19307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19308$as_echo "yes" >&6; }
19309
19310fi
19311
19312{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support tftp" >&5
19313$as_echo_n "checking whether to support tftp... " >&6; }
19314# Check whether --enable-tftp was given.
19315if test "${enable_tftp+set}" = set; then :
19316 enableval=$enable_tftp; case "$enableval" in
19317 no)
19318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19319$as_echo "no" >&6; }
19320
19321$as_echo "#define CURL_DISABLE_TFTP 1" >>confdefs.h
19322
19323 CURL_DISABLE_TFTP=1
19324
19325 ;;
19326 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19327$as_echo "yes" >&6; }
19328 ;;
19329 esac
19330else
19331 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19332$as_echo "yes" >&6; }
19333
19334fi
19335
19336
19337{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support pop3" >&5
19338$as_echo_n "checking whether to support pop3... " >&6; }
19339# Check whether --enable-pop3 was given.
19340if test "${enable_pop3+set}" = set; then :
19341 enableval=$enable_pop3; case "$enableval" in
19342 no)
19343 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19344$as_echo "no" >&6; }
19345
19346$as_echo "#define CURL_DISABLE_POP3 1" >>confdefs.h
19347
19348 CURL_DISABLE_POP3=1
19349
19350 ;;
19351 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19352$as_echo "yes" >&6; }
19353 ;;
19354 esac
19355else
19356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19357$as_echo "yes" >&6; }
19358
19359fi
19360
19361
19362
19363{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support imap" >&5
19364$as_echo_n "checking whether to support imap... " >&6; }
19365# Check whether --enable-imap was given.
19366if test "${enable_imap+set}" = set; then :
19367 enableval=$enable_imap; case "$enableval" in
19368 no)
19369 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19370$as_echo "no" >&6; }
19371
19372$as_echo "#define CURL_DISABLE_IMAP 1" >>confdefs.h
19373
19374 CURL_DISABLE_IMAP=1
19375
19376 ;;
19377 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19378$as_echo "yes" >&6; }
19379 ;;
19380 esac
19381else
19382 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19383$as_echo "yes" >&6; }
19384
19385fi
19386
19387
19388
19389{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support smb" >&5
19390$as_echo_n "checking whether to support smb... " >&6; }
19391# Check whether --enable-smb was given.
19392if test "${enable_smb+set}" = set; then :
19393 enableval=$enable_smb; case "$enableval" in
19394 no)
19395 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19396$as_echo "no" >&6; }
19397
19398$as_echo "#define CURL_DISABLE_SMB 1" >>confdefs.h
19399
19400 CURL_DISABLE_SMB=1
19401
19402 ;;
19403 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19404$as_echo "yes" >&6; }
19405 ;;
19406 esac
19407else
19408 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19409$as_echo "yes" >&6; }
19410
19411fi
19412
19413
19414{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support smtp" >&5
19415$as_echo_n "checking whether to support smtp... " >&6; }
19416# Check whether --enable-smtp was given.
19417if test "${enable_smtp+set}" = set; then :
19418 enableval=$enable_smtp; case "$enableval" in
19419 no)
19420 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19421$as_echo "no" >&6; }
19422
19423$as_echo "#define CURL_DISABLE_SMTP 1" >>confdefs.h
19424
19425 CURL_DISABLE_SMTP=1
19426
19427 ;;
19428 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19429$as_echo "yes" >&6; }
19430 ;;
19431 esac
19432else
19433 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19434$as_echo "yes" >&6; }
19435
19436fi
19437
19438
19439{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support gopher" >&5
19440$as_echo_n "checking whether to support gopher... " >&6; }
19441# Check whether --enable-gopher was given.
19442if test "${enable_gopher+set}" = set; then :
19443 enableval=$enable_gopher; case "$enableval" in
19444 no)
19445 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19446$as_echo "no" >&6; }
19447
19448$as_echo "#define CURL_DISABLE_GOPHER 1" >>confdefs.h
19449
19450 CURL_DISABLE_GOPHER=1
19451
19452 ;;
19453 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19454$as_echo "yes" >&6; }
19455 ;;
19456 esac
19457else
19458 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19459$as_echo "yes" >&6; }
19460
19461fi
19462
19463
19464
19465
19466{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to provide built-in manual" >&5
19467$as_echo_n "checking whether to provide built-in manual... " >&6; }
19468# Check whether --enable-manual was given.
19469if test "${enable_manual+set}" = set; then :
19470 enableval=$enable_manual; case "$enableval" in
19471 no)
19472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19473$as_echo "no" >&6; }
19474 ;;
19475 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19476$as_echo "yes" >&6; }
19477 USE_MANUAL="1"
19478 ;;
19479 esac
19480else
19481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19482$as_echo "yes" >&6; }
19483 USE_MANUAL="1"
19484
19485fi
19486
19487
19488{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable generation of C code" >&5
19489$as_echo_n "checking whether to enable generation of C code... " >&6; }
19490# Check whether --enable-libcurl_option was given.
19491if test "${enable_libcurl_option+set}" = set; then :
19492 enableval=$enable_libcurl_option; case "$enableval" in
19493 no)
19494 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19495$as_echo "no" >&6; }
19496
19497$as_echo "#define CURL_DISABLE_LIBCURL_OPTION 1" >>confdefs.h
19498
19499 curl_libcurl_msg="no"
19500 ;;
19501 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19502$as_echo "yes" >&6; }
19503 ;;
19504 esac
19505else
19506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19507$as_echo "yes" >&6; }
19508
19509fi
19510
19511
19512
19513{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use libgcc" >&5
19514$as_echo_n "checking whether to use libgcc... " >&6; }
19515# Check whether --enable-libgcc was given.
19516if test "${enable_libgcc+set}" = set; then :
19517 enableval=$enable_libgcc; case "$enableval" in
19518 yes)
19519 LIBS="-lgcc $LIBS"
19520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19521$as_echo "yes" >&6; }
19522 ;;
19523 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19524$as_echo "no" >&6; }
19525 ;;
19526 esac
19527else
19528 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19529$as_echo "no" >&6; }
19530
19531fi
19532
19533
19534
19535 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if X/Open network library is required" >&5
19536$as_echo_n "checking if X/Open network library is required... " >&6; }
19537 tst_lib_xnet_required="no"
19538 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19539/* end confdefs.h. */
19540
19541
19542int main (void)
19543{
19544#if defined(__hpux) && defined(_XOPEN_SOURCE) && (_XOPEN_SOURCE >= 600)
19545 return 0;
19546#elif defined(__hpux) && defined(_XOPEN_SOURCE_EXTENDED)
19547 return 0;
19548#else
19549 force compilation error
19550#endif
19551}
19552
19553
19554_ACEOF
19555if ac_fn_c_try_compile "$LINENO"; then :
19556
19557 tst_lib_xnet_required="yes"
19558 LIBS="-lxnet $LIBS"
19559
19560fi
19561rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tst_lib_xnet_required" >&5
19563$as_echo "$tst_lib_xnet_required" >&6; }
19564
19565
19566ac_fn_c_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname"
19567if test "x$ac_cv_func_gethostbyname" = xyes; then :
19568 HAVE_GETHOSTBYNAME="1"
19569
19570else
19571 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lnsl" >&5
19572$as_echo_n "checking for gethostbyname in -lnsl... " >&6; }
19573if ${ac_cv_lib_nsl_gethostbyname+:} false; then :
19574 $as_echo_n "(cached) " >&6
19575else
19576 ac_check_lib_save_LIBS=$LIBS
19577LIBS="-lnsl $LIBS"
19578cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19579/* end confdefs.h. */
19580
19581
19582#ifdef __cplusplus
19583extern "C"
19584#endif
19585char gethostbyname ();
19586int main (void)
19587{
19588return gethostbyname ();
19589 ;
19590 return 0;
19591}
19592_ACEOF
19593if ac_fn_c_try_link "$LINENO"; then :
19594 ac_cv_lib_nsl_gethostbyname=yes
19595else
19596 ac_cv_lib_nsl_gethostbyname=no
19597fi
19598rm -f core conftest.err conftest.$ac_objext \
19599 conftest$ac_exeext conftest.$ac_ext
19600LIBS=$ac_check_lib_save_LIBS
19601fi
19602{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_gethostbyname" >&5
19603$as_echo "$ac_cv_lib_nsl_gethostbyname" >&6; }
19604if test "x$ac_cv_lib_nsl_gethostbyname" = xyes; then :
19605 HAVE_GETHOSTBYNAME="1"
19606 LIBS="-lnsl $LIBS"
19607
19608fi
19609
19610
19611fi
19612
19613
19614if test "$HAVE_GETHOSTBYNAME" != "1"
19615then
19616 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lsocket" >&5
19617$as_echo_n "checking for gethostbyname in -lsocket... " >&6; }
19618if ${ac_cv_lib_socket_gethostbyname+:} false; then :
19619 $as_echo_n "(cached) " >&6
19620else
19621 ac_check_lib_save_LIBS=$LIBS
19622LIBS="-lsocket $LIBS"
19623cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19624/* end confdefs.h. */
19625
19626
19627#ifdef __cplusplus
19628extern "C"
19629#endif
19630char gethostbyname ();
19631int main (void)
19632{
19633return gethostbyname ();
19634 ;
19635 return 0;
19636}
19637_ACEOF
19638if ac_fn_c_try_link "$LINENO"; then :
19639 ac_cv_lib_socket_gethostbyname=yes
19640else
19641 ac_cv_lib_socket_gethostbyname=no
19642fi
19643rm -f core conftest.err conftest.$ac_objext \
19644 conftest$ac_exeext conftest.$ac_ext
19645LIBS=$ac_check_lib_save_LIBS
19646fi
19647{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_gethostbyname" >&5
19648$as_echo "$ac_cv_lib_socket_gethostbyname" >&6; }
19649if test "x$ac_cv_lib_socket_gethostbyname" = xyes; then :
19650 HAVE_GETHOSTBYNAME="1"
19651 LIBS="-lsocket $LIBS"
19652
19653fi
19654
19655fi
19656
19657if test "$HAVE_GETHOSTBYNAME" != "1"
19658then
19659 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lwatt" >&5
19660$as_echo_n "checking for gethostbyname in -lwatt... " >&6; }
19661if ${ac_cv_lib_watt_gethostbyname+:} false; then :
19662 $as_echo_n "(cached) " >&6
19663else
19664 ac_check_lib_save_LIBS=$LIBS
19665LIBS="-lwatt $LIBS"
19666cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19667/* end confdefs.h. */
19668
19669
19670#ifdef __cplusplus
19671extern "C"
19672#endif
19673char gethostbyname ();
19674int main (void)
19675{
19676return gethostbyname ();
19677 ;
19678 return 0;
19679}
19680_ACEOF
19681if ac_fn_c_try_link "$LINENO"; then :
19682 ac_cv_lib_watt_gethostbyname=yes
19683else
19684 ac_cv_lib_watt_gethostbyname=no
19685fi
19686rm -f core conftest.err conftest.$ac_objext \
19687 conftest$ac_exeext conftest.$ac_ext
19688LIBS=$ac_check_lib_save_LIBS
19689fi
19690{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_watt_gethostbyname" >&5
19691$as_echo "$ac_cv_lib_watt_gethostbyname" >&6; }
19692if test "x$ac_cv_lib_watt_gethostbyname" = xyes; then :
19693 HAVE_GETHOSTBYNAME="1"
19694 CPPFLAGS="-I/dev/env/WATT_ROOT/inc"
19695 LDFLAGS="-L/dev/env/WATT_ROOT/lib"
19696 LIBS="-lwatt $LIBS"
19697
19698fi
19699
19700fi
19701
19702if test "$HAVE_GETHOSTBYNAME" != "1"
19703then
19704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname with both nsl and socket libs" >&5
19705$as_echo_n "checking for gethostbyname with both nsl and socket libs... " >&6; }
19706 my_ac_save_LIBS=$LIBS
19707 LIBS="-lnsl -lsocket $LIBS"
19708 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19709/* end confdefs.h. */
19710
19711
19712
19713int main (void)
19714{
19715
19716 gethostbyname();
19717
19718 ;
19719 return 0;
19720}
19721
19722_ACEOF
19723if ac_fn_c_try_link "$LINENO"; then :
19724
19725 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19726$as_echo "yes" >&6; }
19727 HAVE_GETHOSTBYNAME="1"
19728
19729else
19730
19731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19732$as_echo "no" >&6; }
19733 LIBS=$my_ac_save_LIBS
19734
19735fi
19736rm -f core conftest.err conftest.$ac_objext \
19737 conftest$ac_exeext conftest.$ac_ext
19738fi
19739
19740if test "$HAVE_GETHOSTBYNAME" != "1"
19741then
19742 if test "$curl_cv_header_windows_h" = "yes"; then
19743 if test "$curl_cv_header_winsock_h" = "yes"; then
19744 case $host in
19745 *-*-mingw32ce*)
19746 winsock_LIB="-lwinsock"
19747 ;;
19748 *)
19749 winsock_LIB="-lwsock32"
19750 ;;
19751 esac
19752 fi
19753 if test "$curl_cv_header_winsock2_h" = "yes"; then
19754 winsock_LIB="-lws2_32"
19755 fi
19756 if test ! -z "$winsock_LIB"; then
19757 my_ac_save_LIBS=$LIBS
19758 LIBS="$winsock_LIB $LIBS"
19759 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in $winsock_LIB" >&5
19760$as_echo_n "checking for gethostbyname in $winsock_LIB... " >&6; }
19761 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19762/* end confdefs.h. */
19763
19764
19765#ifdef HAVE_WINDOWS_H
19766#ifndef WIN32_LEAN_AND_MEAN
19767#define WIN32_LEAN_AND_MEAN
19768#endif
19769#include <windows.h>
19770#ifdef HAVE_WINSOCK2_H
19771#include <winsock2.h>
19772#else
19773#ifdef HAVE_WINSOCK_H
19774#include <winsock.h>
19775#endif
19776#endif
19777#endif
19778
19779int main (void)
19780{
19781
19782 gethostbyname("www.dummysite.com");
19783
19784 ;
19785 return 0;
19786}
19787
19788_ACEOF
19789if ac_fn_c_try_link "$LINENO"; then :
19790
19791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19792$as_echo "yes" >&6; }
19793 HAVE_GETHOSTBYNAME="1"
19794
19795else
19796
19797 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19798$as_echo "no" >&6; }
19799 winsock_LIB=""
19800 LIBS=$my_ac_save_LIBS
19801
19802fi
19803rm -f core conftest.err conftest.$ac_objext \
19804 conftest$ac_exeext conftest.$ac_ext
19805 fi
19806 fi
19807fi
19808
19809if test "$HAVE_GETHOSTBYNAME" != "1"
19810then
19811 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname for Minix 3" >&5
19812$as_echo_n "checking for gethostbyname for Minix 3... " >&6; }
19813 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19814/* end confdefs.h. */
19815
19816
19817/* Older Minix versions may need <net/gen/netdb.h> here instead */
19818#include <netdb.h>
19819
19820int main (void)
19821{
19822
19823 gethostbyname("www.dummysite.com");
19824
19825 ;
19826 return 0;
19827}
19828
19829_ACEOF
19830if ac_fn_c_try_link "$LINENO"; then :
19831
19832 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
19833$as_echo "yes" >&6; }
19834 HAVE_GETHOSTBYNAME="1"
19835
19836else
19837
19838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19839$as_echo "no" >&6; }
19840
19841fi
19842rm -f core conftest.err conftest.$ac_objext \
19843 conftest$ac_exeext conftest.$ac_ext
19844fi
19845
19846if test "$HAVE_GETHOSTBYNAME" != "1"
19847then
19848 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname for eCos" >&5
19849$as_echo_n "checking for gethostbyname for eCos... " >&6; }
19850 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19851/* end confdefs.h. */
19852
19853
19854#include <stdio.h>
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
Haibo Huang65021c72019-03-27 15:37:23 -070019885 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname for AmigaOS bsdsocket.library" >&5
19886$as_echo_n "checking for gethostbyname for AmigaOS bsdsocket.library... " >&6; }
19887 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19888/* end confdefs.h. */
19889
19890
19891#include <proto/bsdsocket.h>
19892struct Library *SocketBase = NULL;
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 HAVE_PROTO_BSDSOCKET_H="1"
19910
19911$as_echo "#define HAVE_PROTO_BSDSOCKET_H 1" >>confdefs.h
19912
19913 HAVE_PROTO_BSDSOCKET_H=1
19914
19915
19916else
19917
19918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19919$as_echo "no" >&6; }
19920
19921fi
19922rm -f core conftest.err conftest.$ac_objext \
19923 conftest$ac_exeext conftest.$ac_ext
19924fi
19925
19926if test "$HAVE_GETHOSTBYNAME" != "1"
19927then
Elliott Hughes82be86d2017-09-20 17:00:17 -070019928 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lnetwork" >&5
19929$as_echo_n "checking for gethostbyname in -lnetwork... " >&6; }
19930if ${ac_cv_lib_network_gethostbyname+:} false; then :
19931 $as_echo_n "(cached) " >&6
19932else
19933 ac_check_lib_save_LIBS=$LIBS
19934LIBS="-lnetwork $LIBS"
19935cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19936/* end confdefs.h. */
19937
19938
19939#ifdef __cplusplus
19940extern "C"
19941#endif
19942char gethostbyname ();
19943int main (void)
19944{
19945return gethostbyname ();
19946 ;
19947 return 0;
19948}
19949_ACEOF
19950if ac_fn_c_try_link "$LINENO"; then :
19951 ac_cv_lib_network_gethostbyname=yes
19952else
19953 ac_cv_lib_network_gethostbyname=no
19954fi
19955rm -f core conftest.err conftest.$ac_objext \
19956 conftest$ac_exeext conftest.$ac_ext
19957LIBS=$ac_check_lib_save_LIBS
19958fi
19959{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_network_gethostbyname" >&5
19960$as_echo "$ac_cv_lib_network_gethostbyname" >&6; }
19961if test "x$ac_cv_lib_network_gethostbyname" = xyes; then :
19962 HAVE_GETHOSTBYNAME="1"
19963 LIBS="-lnetwork $LIBS"
19964
19965fi
19966
19967fi
19968
19969if test "$HAVE_GETHOSTBYNAME" != "1"
19970then
19971 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lnet" >&5
19972$as_echo_n "checking for gethostbyname in -lnet... " >&6; }
19973if ${ac_cv_lib_net_gethostbyname+:} false; then :
19974 $as_echo_n "(cached) " >&6
19975else
19976 ac_check_lib_save_LIBS=$LIBS
19977LIBS="-lnet $LIBS"
19978cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19979/* end confdefs.h. */
19980
19981
19982#ifdef __cplusplus
19983extern "C"
19984#endif
19985char gethostbyname ();
19986int main (void)
19987{
19988return gethostbyname ();
19989 ;
19990 return 0;
19991}
19992_ACEOF
19993if ac_fn_c_try_link "$LINENO"; then :
19994 ac_cv_lib_net_gethostbyname=yes
19995else
19996 ac_cv_lib_net_gethostbyname=no
19997fi
19998rm -f core conftest.err conftest.$ac_objext \
19999 conftest$ac_exeext conftest.$ac_ext
20000LIBS=$ac_check_lib_save_LIBS
20001fi
20002{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_net_gethostbyname" >&5
20003$as_echo "$ac_cv_lib_net_gethostbyname" >&6; }
20004if test "x$ac_cv_lib_net_gethostbyname" = xyes; then :
20005 HAVE_GETHOSTBYNAME="1"
20006 LIBS="-lnet $LIBS"
20007
20008fi
20009
20010fi
20011
20012
20013if test "$HAVE_GETHOSTBYNAME" != "1"; then
20014 as_fn_error $? "couldn't find libraries for gethostbyname()" "$LINENO" 5
20015fi
20016
20017
20018curl_includes_winsock2="\
20019/* includes start */
20020#ifdef HAVE_WINDOWS_H
20021# ifndef WIN32_LEAN_AND_MEAN
20022# define WIN32_LEAN_AND_MEAN
20023# endif
20024# include <windows.h>
20025# ifdef HAVE_WINSOCK2_H
20026# include <winsock2.h>
20027# else
20028# ifdef HAVE_WINSOCK_H
20029# include <winsock.h>
20030# endif
20031# endif
20032#endif
20033/* includes end */"
20034
20035 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for windows.h" >&5
20036$as_echo_n "checking for windows.h... " >&6; }
20037if ${curl_cv_header_windows_h+:} false; then :
20038 $as_echo_n "(cached) " >&6
20039else
20040
20041 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20042/* end confdefs.h. */
20043
20044
20045#undef inline
20046#ifndef WIN32_LEAN_AND_MEAN
20047#define WIN32_LEAN_AND_MEAN
20048#endif
20049#include <windows.h>
20050
20051int main (void)
20052{
20053
20054#if defined(__CYGWIN__) || defined(__CEGCC__)
20055 HAVE_WINDOWS_H shall not be defined.
20056#else
20057 int dummy=2*WINVER;
20058#endif
20059
20060 ;
20061 return 0;
20062}
20063
20064_ACEOF
20065if ac_fn_c_try_compile "$LINENO"; then :
20066
20067 curl_cv_header_windows_h="yes"
20068
20069else
20070
20071 curl_cv_header_windows_h="no"
20072
20073fi
20074rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20075
20076fi
20077{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_windows_h" >&5
20078$as_echo "$curl_cv_header_windows_h" >&6; }
20079 case "$curl_cv_header_windows_h" in
20080 yes)
20081
20082cat >>confdefs.h <<_ACEOF
20083#define HAVE_WINDOWS_H 1
20084_ACEOF
20085
20086 ;;
20087 esac
20088
20089
20090 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for winsock.h" >&5
20091$as_echo_n "checking for winsock.h... " >&6; }
20092if ${curl_cv_header_winsock_h+:} false; then :
20093 $as_echo_n "(cached) " >&6
20094else
20095
20096 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20097/* end confdefs.h. */
20098
20099
20100#undef inline
20101#ifndef WIN32_LEAN_AND_MEAN
20102#define WIN32_LEAN_AND_MEAN
20103#endif
20104#include <windows.h>
20105#include <winsock.h>
20106
20107int main (void)
20108{
20109
20110#if defined(__CYGWIN__) || defined(__CEGCC__)
20111 HAVE_WINSOCK_H shall not be defined.
20112#else
20113 int dummy=WSACleanup();
20114#endif
20115
20116 ;
20117 return 0;
20118}
20119
20120_ACEOF
20121if ac_fn_c_try_compile "$LINENO"; then :
20122
20123 curl_cv_header_winsock_h="yes"
20124
20125else
20126
20127 curl_cv_header_winsock_h="no"
20128
20129fi
20130rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20131
20132fi
20133{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_winsock_h" >&5
20134$as_echo "$curl_cv_header_winsock_h" >&6; }
20135 case "$curl_cv_header_winsock_h" in
20136 yes)
20137
20138cat >>confdefs.h <<_ACEOF
20139#define HAVE_WINSOCK_H 1
20140_ACEOF
20141
20142 ;;
20143 esac
20144
20145
20146 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for winsock2.h" >&5
20147$as_echo_n "checking for winsock2.h... " >&6; }
20148if ${curl_cv_header_winsock2_h+:} false; then :
20149 $as_echo_n "(cached) " >&6
20150else
20151
20152 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20153/* end confdefs.h. */
20154
20155
20156#undef inline
20157#ifndef WIN32_LEAN_AND_MEAN
20158#define WIN32_LEAN_AND_MEAN
20159#endif
20160#include <windows.h>
20161#include <winsock2.h>
20162
20163int main (void)
20164{
20165
20166#if defined(__CYGWIN__) || defined(__CEGCC__) || defined(__MINGW32CE__)
20167 HAVE_WINSOCK2_H shall not be defined.
20168#else
20169 int dummy=2*IPPROTO_ESP;
20170#endif
20171
20172 ;
20173 return 0;
20174}
20175
20176_ACEOF
20177if ac_fn_c_try_compile "$LINENO"; then :
20178
20179 curl_cv_header_winsock2_h="yes"
20180
20181else
20182
20183 curl_cv_header_winsock2_h="no"
20184
20185fi
20186rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20187
20188fi
20189{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_winsock2_h" >&5
20190$as_echo "$curl_cv_header_winsock2_h" >&6; }
20191 case "$curl_cv_header_winsock2_h" in
20192 yes)
20193
20194cat >>confdefs.h <<_ACEOF
20195#define HAVE_WINSOCK2_H 1
20196_ACEOF
20197
20198 ;;
20199 esac
20200
20201
20202
Haibo Huang65021c72019-03-27 15:37:23 -070020203curl_includes_bsdsocket="\
20204/* includes start */
20205#ifdef HAVE_PROTO_BSDSOCKET_H
20206# include <proto/bsdsocket.h>
20207 struct Library *SocketBase = NULL;
20208#endif
20209/* includes end */"
20210 for ac_header in proto/bsdsocket.h
20211do :
20212 ac_fn_c_check_header_compile "$LINENO" "proto/bsdsocket.h" "ac_cv_header_proto_bsdsocket_h" " $curl_includes_bsdsocket
20213"
20214if test "x$ac_cv_header_proto_bsdsocket_h" = xyes; then :
20215 cat >>confdefs.h <<_ACEOF
20216#define HAVE_PROTO_BSDSOCKET_H 1
20217_ACEOF
20218
20219fi
20220
20221done
20222
20223
20224
20225 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for connect in libraries" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070020226$as_echo_n "checking for connect in libraries... " >&6; }
20227 tst_connect_save_LIBS="$LIBS"
20228 tst_connect_need_LIBS="unknown"
20229 for tst_lib in '' '-lsocket' ; do
20230 if test "$tst_connect_need_LIBS" = "unknown"; then
20231 LIBS="$tst_lib $tst_connect_save_LIBS"
20232 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20233/* end confdefs.h. */
20234
20235
20236 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070020237 $curl_includes_bsdsocket
20238 #if !defined(HAVE_WINDOWS_H) && !defined(HAVE_PROTO_BSDSOCKET_H)
Elliott Hughes82be86d2017-09-20 17:00:17 -070020239 int connect(int, void*, int);
20240 #endif
20241
20242int main (void)
20243{
20244
20245 if(0 != connect(0, 0, 0))
20246 return 1;
20247
20248 ;
20249 return 0;
20250}
20251
20252_ACEOF
20253if ac_fn_c_try_link "$LINENO"; then :
20254
20255 tst_connect_need_LIBS="$tst_lib"
20256
20257fi
20258rm -f core conftest.err conftest.$ac_objext \
20259 conftest$ac_exeext conftest.$ac_ext
20260 fi
20261 done
20262 LIBS="$tst_connect_save_LIBS"
20263 #
20264 case X-"$tst_connect_need_LIBS" in
20265 X-unknown)
20266 { $as_echo "$as_me:${as_lineno-$LINENO}: result: cannot find connect" >&5
20267$as_echo "cannot find connect" >&6; }
20268 as_fn_error $? "cannot find connect function in libraries." "$LINENO" 5
20269 ;;
20270 X-)
20271 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
20272$as_echo "yes" >&6; }
20273 ;;
20274 *)
20275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tst_connect_need_LIBS" >&5
20276$as_echo "$tst_connect_need_LIBS" >&6; }
20277 LIBS="$tst_connect_need_LIBS $tst_connect_save_LIBS"
20278 ;;
20279 esac
20280
20281
20282CURL_NETWORK_LIBS=$LIBS
20283
20284{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
20285$as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
20286if ${ac_cv_header_time+:} false; then :
20287 $as_echo_n "(cached) " >&6
20288else
20289 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20290/* end confdefs.h. */
20291#include <sys/types.h>
20292#include <sys/time.h>
20293#include <time.h>
20294
20295int main (void)
20296{
20297if ((struct tm *) 0)
20298return 0;
20299 ;
20300 return 0;
20301}
20302_ACEOF
20303if ac_fn_c_try_compile "$LINENO"; then :
20304 ac_cv_header_time=yes
20305else
20306 ac_cv_header_time=no
20307fi
20308rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20309fi
20310{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
20311$as_echo "$ac_cv_header_time" >&6; }
20312if test $ac_cv_header_time = yes; then
20313
20314$as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
20315
20316fi
20317
20318
20319 for ac_header in sys/types.h sys/time.h time.h
20320do :
20321 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
20322ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
20323if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
20324 cat >>confdefs.h <<_ACEOF
20325#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
20326_ACEOF
20327
20328fi
20329
20330done
20331
20332 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for monotonic clock_gettime" >&5
20333$as_echo_n "checking for monotonic clock_gettime... " >&6; }
20334 #
20335 if test "x$dontwant_rt" = "xno" ; then
20336 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20337/* end confdefs.h. */
20338
20339
20340#ifdef HAVE_SYS_TYPES_H
20341#include <sys/types.h>
20342#endif
20343#ifdef HAVE_SYS_TIME_H
20344#include <sys/time.h>
20345#ifdef TIME_WITH_SYS_TIME
20346#include <time.h>
20347#endif
20348#else
20349#ifdef HAVE_TIME_H
20350#include <time.h>
20351#endif
20352#endif
20353
20354int main (void)
20355{
20356
20357 struct timespec ts;
20358 (void)clock_gettime(CLOCK_MONOTONIC, &ts);
20359
20360 ;
20361 return 0;
20362}
20363
20364_ACEOF
20365if ac_fn_c_try_compile "$LINENO"; then :
20366
20367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
20368$as_echo "yes" >&6; }
20369 curl_func_clock_gettime="yes"
20370
20371else
20372
20373 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20374$as_echo "no" >&6; }
20375 curl_func_clock_gettime="no"
20376
20377fi
20378rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20379 fi
20380
20381
20382 #
20383 if test "$curl_func_clock_gettime" = "yes"; then
20384 #
20385 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clock_gettime in libraries" >&5
20386$as_echo_n "checking for clock_gettime in libraries... " >&6; }
20387 #
20388 curl_cv_save_LIBS="$LIBS"
20389 curl_cv_gclk_LIBS="unknown"
20390 #
20391 for x_xlibs in '' '-lrt' '-lposix4' ; do
20392 if test "$curl_cv_gclk_LIBS" = "unknown"; then
20393 if test -z "$x_xlibs"; then
20394 LIBS="$curl_cv_save_LIBS"
20395 else
20396 LIBS="$x_xlibs $curl_cv_save_LIBS"
20397 fi
20398 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20399/* end confdefs.h. */
20400
20401
20402#ifdef HAVE_SYS_TYPES_H
20403#include <sys/types.h>
20404#endif
20405#ifdef HAVE_SYS_TIME_H
20406#include <sys/time.h>
20407#ifdef TIME_WITH_SYS_TIME
20408#include <time.h>
20409#endif
20410#else
20411#ifdef HAVE_TIME_H
20412#include <time.h>
20413#endif
20414#endif
20415
20416int main (void)
20417{
20418
20419 struct timespec ts;
20420 (void)clock_gettime(CLOCK_MONOTONIC, &ts);
20421
20422 ;
20423 return 0;
20424}
20425
20426_ACEOF
20427if ac_fn_c_try_link "$LINENO"; then :
20428
20429 curl_cv_gclk_LIBS="$x_xlibs"
20430
20431fi
20432rm -f core conftest.err conftest.$ac_objext \
20433 conftest$ac_exeext conftest.$ac_ext
20434 fi
20435 done
20436 #
20437 LIBS="$curl_cv_save_LIBS"
20438 #
20439 case X-"$curl_cv_gclk_LIBS" in
20440 X-unknown)
20441 { $as_echo "$as_me:${as_lineno-$LINENO}: result: cannot find clock_gettime" >&5
20442$as_echo "cannot find clock_gettime" >&6; }
20443 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: HAVE_CLOCK_GETTIME_MONOTONIC will not be defined" >&5
20444$as_echo "$as_me: WARNING: HAVE_CLOCK_GETTIME_MONOTONIC will not be defined" >&2;}
20445 curl_func_clock_gettime="no"
20446 ;;
20447 X-)
20448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no additional lib required" >&5
20449$as_echo "no additional lib required" >&6; }
20450 curl_func_clock_gettime="yes"
20451 ;;
20452 *)
20453 if test -z "$curl_cv_save_LIBS"; then
20454 LIBS="$curl_cv_gclk_LIBS"
20455 else
20456 LIBS="$curl_cv_gclk_LIBS $curl_cv_save_LIBS"
20457 fi
20458 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_gclk_LIBS" >&5
20459$as_echo "$curl_cv_gclk_LIBS" >&6; }
20460 curl_func_clock_gettime="yes"
20461 ;;
20462 esac
20463 #
20464 if test "x$cross_compiling" != "xyes" &&
20465 test "$curl_func_clock_gettime" = "yes"; then
20466 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if monotonic clock_gettime works" >&5
20467$as_echo_n "checking if monotonic clock_gettime works... " >&6; }
Elliott Hughesa93fb052018-12-12 14:22:48 -080020468
20469
20470 old=$LD_LIBRARY_PATH
20471 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
20472 export LD_LIBRARY_PATH
20473 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070020474 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
20475$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
20476as_fn_error $? "cannot run test program while cross compiling
20477See \`config.log' for more details" "$LINENO" 5; }
20478else
20479 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20480/* end confdefs.h. */
20481
20482
20483#ifdef HAVE_STDLIB_H
20484#include <stdlib.h>
20485#endif
20486#ifdef HAVE_SYS_TYPES_H
20487#include <sys/types.h>
20488#endif
20489#ifdef HAVE_SYS_TIME_H
20490#include <sys/time.h>
20491#ifdef TIME_WITH_SYS_TIME
20492#include <time.h>
20493#endif
20494#else
20495#ifdef HAVE_TIME_H
20496#include <time.h>
20497#endif
20498#endif
20499
20500int main (void)
20501{
20502
20503 struct timespec ts;
20504 if (0 == clock_gettime(CLOCK_MONOTONIC, &ts))
20505 exit(0);
20506 else
20507 exit(1);
20508
20509 ;
20510 return 0;
20511}
20512
20513_ACEOF
20514if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughesa93fb052018-12-12 14:22:48 -080020515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070020516$as_echo "yes" >&6; }
20517
20518else
Elliott Hughesa93fb052018-12-12 14:22:48 -080020519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070020520$as_echo "no" >&6; }
20521 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: HAVE_CLOCK_GETTIME_MONOTONIC will not be defined" >&5
20522$as_echo "$as_me: WARNING: HAVE_CLOCK_GETTIME_MONOTONIC will not be defined" >&2;}
20523 curl_func_clock_gettime="no"
20524 LIBS="$curl_cv_save_LIBS"
20525
20526fi
20527rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20528 conftest.$ac_objext conftest.beam conftest.$ac_ext
20529fi
20530
Elliott Hughesa93fb052018-12-12 14:22:48 -080020531 LD_LIBRARY_PATH=$old # restore
20532
Elliott Hughes82be86d2017-09-20 17:00:17 -070020533 fi
20534 #
20535 case "$curl_func_clock_gettime" in
20536 yes)
20537
20538cat >>confdefs.h <<_ACEOF
20539#define HAVE_CLOCK_GETTIME_MONOTONIC 1
20540_ACEOF
20541
20542 ;;
20543 esac
20544 #
20545 fi
20546 #
20547
20548
20549CURL_NETWORK_AND_TIME_LIBS=$LIBS
20550
20551
20552
20553clean_CPPFLAGS=$CPPFLAGS
20554clean_LDFLAGS=$LDFLAGS
20555clean_LIBS=$LIBS
20556ZLIB_LIBS=""
20557
20558# Check whether --with-zlib was given.
20559if test "${with_zlib+set}" = set; then :
20560 withval=$with_zlib; OPT_ZLIB="$withval"
20561fi
20562
20563
20564if test "$OPT_ZLIB" = "no" ; then
20565 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: zlib disabled" >&5
20566$as_echo "$as_me: WARNING: zlib disabled" >&2;}
20567else
20568 if test "$OPT_ZLIB" = "yes" ; then
20569 OPT_ZLIB=""
20570 fi
20571
20572 if test -z "$OPT_ZLIB" ; then
20573
20574 if test -n "$PKG_CONFIG"; then
20575 PKGCONFIG="$PKG_CONFIG"
20576 else
20577 if test -n "$ac_tool_prefix"; then
20578 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
20579set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
20580{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
20581$as_echo_n "checking for $ac_word... " >&6; }
20582if ${ac_cv_path_PKGCONFIG+:} false; then :
20583 $as_echo_n "(cached) " >&6
20584else
20585 case $PKGCONFIG in
20586 [\\/]* | ?:[\\/]*)
20587 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
20588 ;;
20589 *)
20590 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
20591as_dummy="$PATH:/usr/bin:/usr/local/bin"
20592for as_dir in $as_dummy
20593do
20594 IFS=$as_save_IFS
20595 test -z "$as_dir" && as_dir=.
20596 for ac_exec_ext in '' $ac_executable_extensions; do
20597 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
20598 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
20599 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
20600 break 2
20601 fi
20602done
20603 done
20604IFS=$as_save_IFS
20605
20606 ;;
20607esac
20608fi
20609PKGCONFIG=$ac_cv_path_PKGCONFIG
20610if test -n "$PKGCONFIG"; then
20611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
20612$as_echo "$PKGCONFIG" >&6; }
20613else
20614 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20615$as_echo "no" >&6; }
20616fi
20617
20618
20619fi
20620if test -z "$ac_cv_path_PKGCONFIG"; then
20621 ac_pt_PKGCONFIG=$PKGCONFIG
20622 # Extract the first word of "pkg-config", so it can be a program name with args.
20623set dummy pkg-config; ac_word=$2
20624{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
20625$as_echo_n "checking for $ac_word... " >&6; }
20626if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
20627 $as_echo_n "(cached) " >&6
20628else
20629 case $ac_pt_PKGCONFIG in
20630 [\\/]* | ?:[\\/]*)
20631 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
20632 ;;
20633 *)
20634 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
20635as_dummy="$PATH:/usr/bin:/usr/local/bin"
20636for as_dir in $as_dummy
20637do
20638 IFS=$as_save_IFS
20639 test -z "$as_dir" && as_dir=.
20640 for ac_exec_ext in '' $ac_executable_extensions; do
20641 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
20642 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
20643 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
20644 break 2
20645 fi
20646done
20647 done
20648IFS=$as_save_IFS
20649
20650 ;;
20651esac
20652fi
20653ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
20654if test -n "$ac_pt_PKGCONFIG"; then
20655 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
20656$as_echo "$ac_pt_PKGCONFIG" >&6; }
20657else
20658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20659$as_echo "no" >&6; }
20660fi
20661
20662 if test "x$ac_pt_PKGCONFIG" = x; then
20663 PKGCONFIG="no"
20664 else
20665 case $cross_compiling:$ac_tool_warned in
20666yes:)
20667{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
20668$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
20669ac_tool_warned=yes ;;
20670esac
20671 PKGCONFIG=$ac_pt_PKGCONFIG
20672 fi
20673else
20674 PKGCONFIG="$ac_cv_path_PKGCONFIG"
20675fi
20676
20677 fi
20678
20679 if test "x$PKGCONFIG" != "xno"; then
20680 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for zlib options with pkg-config" >&5
20681$as_echo_n "checking for zlib options with pkg-config... " >&6; }
20682 itexists=`
20683 if test -n ""; then
20684 PKG_CONFIG_LIBDIR=""
20685 export PKG_CONFIG_LIBDIR
20686 fi
20687 $PKGCONFIG --exists zlib >/dev/null 2>&1 && echo 1`
20688
20689 if test -z "$itexists"; then
20690 PKGCONFIG="no"
20691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20692$as_echo "no" >&6; }
20693 else
20694 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
20695$as_echo "found" >&6; }
20696 fi
20697 fi
20698
20699
20700 if test "$PKGCONFIG" != "no" ; then
20701 LIBS="`$PKGCONFIG --libs-only-l zlib` $LIBS"
20702 LDFLAGS="$LDFLAGS `$PKGCONFIG --libs-only-L zlib`"
20703 CPPFLAGS="$CPPFLAGS `$PKGCONFIG --cflags-only-I zlib`"
20704 OPT_ZLIB=""
20705 HAVE_LIBZ="1"
20706 fi
20707
20708 if test -z "$HAVE_LIBZ"; then
20709
20710
20711 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inflateEnd in -lz" >&5
20712$as_echo_n "checking for inflateEnd in -lz... " >&6; }
20713if ${ac_cv_lib_z_inflateEnd+:} false; then :
20714 $as_echo_n "(cached) " >&6
20715else
20716 ac_check_lib_save_LIBS=$LIBS
20717LIBS="-lz $LIBS"
20718cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20719/* end confdefs.h. */
20720
20721
20722#ifdef __cplusplus
20723extern "C"
20724#endif
20725char inflateEnd ();
20726int main (void)
20727{
20728return inflateEnd ();
20729 ;
20730 return 0;
20731}
20732_ACEOF
20733if ac_fn_c_try_link "$LINENO"; then :
20734 ac_cv_lib_z_inflateEnd=yes
20735else
20736 ac_cv_lib_z_inflateEnd=no
20737fi
20738rm -f core conftest.err conftest.$ac_objext \
20739 conftest$ac_exeext conftest.$ac_ext
20740LIBS=$ac_check_lib_save_LIBS
20741fi
20742{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_inflateEnd" >&5
20743$as_echo "$ac_cv_lib_z_inflateEnd" >&6; }
20744if test "x$ac_cv_lib_z_inflateEnd" = xyes; then :
20745 HAVE_LIBZ="1"
20746 LIBS="-lz $LIBS"
20747else
20748 OPT_ZLIB="/usr/local"
20749fi
20750
20751 fi
20752 fi
20753
20754 if test -n "$OPT_ZLIB"; then
20755 CPPFLAGS="$CPPFLAGS -I$OPT_ZLIB/include"
20756 LDFLAGS="$LDFLAGS -L$OPT_ZLIB/lib$libsuff"
20757 fi
20758
20759 ac_fn_c_check_header_mongrel "$LINENO" "zlib.h" "ac_cv_header_zlib_h" "$ac_includes_default"
20760if test "x$ac_cv_header_zlib_h" = xyes; then :
20761
20762 HAVE_ZLIB_H="1"
20763 if test "$HAVE_LIBZ" != "1"; then
20764 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gzread in -lz" >&5
20765$as_echo_n "checking for gzread in -lz... " >&6; }
20766if ${ac_cv_lib_z_gzread+:} false; then :
20767 $as_echo_n "(cached) " >&6
20768else
20769 ac_check_lib_save_LIBS=$LIBS
20770LIBS="-lz $LIBS"
20771cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20772/* end confdefs.h. */
20773
20774
20775#ifdef __cplusplus
20776extern "C"
20777#endif
20778char gzread ();
20779int main (void)
20780{
20781return gzread ();
20782 ;
20783 return 0;
20784}
20785_ACEOF
20786if ac_fn_c_try_link "$LINENO"; then :
20787 ac_cv_lib_z_gzread=yes
20788else
20789 ac_cv_lib_z_gzread=no
20790fi
20791rm -f core conftest.err conftest.$ac_objext \
20792 conftest$ac_exeext conftest.$ac_ext
20793LIBS=$ac_check_lib_save_LIBS
20794fi
20795{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_gzread" >&5
20796$as_echo "$ac_cv_lib_z_gzread" >&6; }
20797if test "x$ac_cv_lib_z_gzread" = xyes; then :
20798
20799 HAVE_LIBZ="1"
20800 LIBS="-lz $LIBS"
20801
20802else
20803 CPPFLAGS=$clean_CPPFLAGS
20804 LDFLAGS=$clean_LDFLAGS
20805fi
20806
20807 fi
20808
20809else
20810
20811 CPPFLAGS=$clean_CPPFLAGS
20812 LDFLAGS=$clean_LDFLAGS
20813
20814fi
20815
20816
20817
20818 if test "$HAVE_LIBZ" = "1" && test "$HAVE_ZLIB_H" != "1"
20819 then
20820 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: configure found only the libz lib, not the header file!" >&5
20821$as_echo "$as_me: WARNING: configure found only the libz lib, not the header file!" >&2;}
20822 HAVE_LIBZ=""
20823 CPPFLAGS=$clean_CPPFLAGS
20824 LDFLAGS=$clean_LDFLAGS
20825 LIBS=$clean_LIBS
20826 elif test "$HAVE_LIBZ" != "1" && test "$HAVE_ZLIB_H" = "1"
20827 then
20828 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: configure found only the libz header file, not the lib!" >&5
20829$as_echo "$as_me: WARNING: configure found only the libz header file, not the lib!" >&2;}
20830 CPPFLAGS=$clean_CPPFLAGS
20831 LDFLAGS=$clean_LDFLAGS
20832 LIBS=$clean_LIBS
20833 elif test "$HAVE_LIBZ" = "1" && test "$HAVE_ZLIB_H" = "1"
20834 then
20835
20836
20837$as_echo "#define HAVE_ZLIB_H 1" >>confdefs.h
20838
20839
20840$as_echo "#define HAVE_LIBZ 1" >>confdefs.h
20841
20842
20843 ZLIB_LIBS="-lz"
20844 LIBS="-lz $clean_LIBS"
20845
20846 AMFIXLIB="1"
20847 { $as_echo "$as_me:${as_lineno-$LINENO}: found both libz and libz.h header" >&5
20848$as_echo "$as_me: found both libz and libz.h header" >&6;}
20849 curl_zlib_msg="enabled"
20850 fi
20851fi
20852
20853 if test x"$AMFIXLIB" = x1; then
20854 HAVE_LIBZ_TRUE=
20855 HAVE_LIBZ_FALSE='#'
20856else
20857 HAVE_LIBZ_TRUE='#'
20858 HAVE_LIBZ_FALSE=
20859fi
20860
20861
20862
20863
Alex Deymo486467e2017-12-19 19:04:07 +010020864
20865OPT_BROTLI=off
20866
20867# Check whether --with-brotli was given.
20868if test "${with_brotli+set}" = set; then :
20869 withval=$with_brotli; OPT_BROTLI=$withval
20870fi
20871
20872
20873if test X"$OPT_BROTLI" != Xno; then
20874 CLEANLDFLAGS="$LDFLAGS"
20875 CLEANCPPFLAGS="$CPPFLAGS"
20876 CLEANLIBS="$LIBS"
20877
20878 case "$OPT_BROTLI" in
20879 yes)
20880
20881 if test -n "$PKG_CONFIG"; then
20882 PKGCONFIG="$PKG_CONFIG"
20883 else
20884 if test -n "$ac_tool_prefix"; then
20885 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
20886set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
20887{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
20888$as_echo_n "checking for $ac_word... " >&6; }
20889if ${ac_cv_path_PKGCONFIG+:} false; then :
20890 $as_echo_n "(cached) " >&6
20891else
20892 case $PKGCONFIG in
20893 [\\/]* | ?:[\\/]*)
20894 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
20895 ;;
20896 *)
20897 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
20898as_dummy="$PATH:/usr/bin:/usr/local/bin"
20899for as_dir in $as_dummy
20900do
20901 IFS=$as_save_IFS
20902 test -z "$as_dir" && as_dir=.
20903 for ac_exec_ext in '' $ac_executable_extensions; do
20904 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
20905 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
20906 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
20907 break 2
20908 fi
20909done
20910 done
20911IFS=$as_save_IFS
20912
20913 ;;
20914esac
20915fi
20916PKGCONFIG=$ac_cv_path_PKGCONFIG
20917if test -n "$PKGCONFIG"; then
20918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
20919$as_echo "$PKGCONFIG" >&6; }
20920else
20921 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20922$as_echo "no" >&6; }
20923fi
20924
20925
20926fi
20927if test -z "$ac_cv_path_PKGCONFIG"; then
20928 ac_pt_PKGCONFIG=$PKGCONFIG
20929 # Extract the first word of "pkg-config", so it can be a program name with args.
20930set dummy pkg-config; ac_word=$2
20931{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
20932$as_echo_n "checking for $ac_word... " >&6; }
20933if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
20934 $as_echo_n "(cached) " >&6
20935else
20936 case $ac_pt_PKGCONFIG in
20937 [\\/]* | ?:[\\/]*)
20938 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
20939 ;;
20940 *)
20941 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
20942as_dummy="$PATH:/usr/bin:/usr/local/bin"
20943for as_dir in $as_dummy
20944do
20945 IFS=$as_save_IFS
20946 test -z "$as_dir" && as_dir=.
20947 for ac_exec_ext in '' $ac_executable_extensions; do
20948 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
20949 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
20950 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
20951 break 2
20952 fi
20953done
20954 done
20955IFS=$as_save_IFS
20956
20957 ;;
20958esac
20959fi
20960ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
20961if test -n "$ac_pt_PKGCONFIG"; then
20962 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
20963$as_echo "$ac_pt_PKGCONFIG" >&6; }
20964else
20965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20966$as_echo "no" >&6; }
20967fi
20968
20969 if test "x$ac_pt_PKGCONFIG" = x; then
20970 PKGCONFIG="no"
20971 else
20972 case $cross_compiling:$ac_tool_warned in
20973yes:)
20974{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
20975$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
20976ac_tool_warned=yes ;;
20977esac
20978 PKGCONFIG=$ac_pt_PKGCONFIG
20979 fi
20980else
20981 PKGCONFIG="$ac_cv_path_PKGCONFIG"
20982fi
20983
20984 fi
20985
20986 if test "x$PKGCONFIG" != "xno"; then
20987 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libbrotlidec options with pkg-config" >&5
20988$as_echo_n "checking for libbrotlidec options with pkg-config... " >&6; }
20989 itexists=`
20990 if test -n ""; then
20991 PKG_CONFIG_LIBDIR=""
20992 export PKG_CONFIG_LIBDIR
20993 fi
20994 $PKGCONFIG --exists libbrotlidec >/dev/null 2>&1 && echo 1`
20995
20996 if test -z "$itexists"; then
20997 PKGCONFIG="no"
20998 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20999$as_echo "no" >&6; }
21000 else
21001 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
21002$as_echo "found" >&6; }
21003 fi
21004 fi
21005
21006
21007 if test "$PKGCONFIG" != "no" ; then
21008 LIB_BROTLI=`$PKGCONFIG --libs-only-l libbrotlidec`
21009 LD_BROTLI=`$PKGCONFIG --libs-only-L libbrotlidec`
21010 CPP_BROTLI=`$PKGCONFIG --cflags-only-I libbrotlidec`
21011 version=`$PKGCONFIG --modversion libbrotlidec`
21012 DIR_BROTLI=`echo $LD_BROTLI | $SED -e 's/-L//'`
21013 fi
21014
21015 ;;
21016 off)
21017 ;;
21018 *)
21019 PREFIX_BROTLI=$OPT_BROTLI
21020 ;;
21021 esac
21022
21023 if test -n "$PREFIX_BROTLI"; then
21024 LIB_BROTLI="-lbrotlidec"
21025 LD_BROTLI=-L${PREFIX_BROTLI}/lib$libsuff
21026 CPP_BROTLI=-I${PREFIX_BROTLI}/include
21027 DIR_BROTLI=${PREFIX_BROTLI}/lib$libsuff
21028 fi
21029
21030 LDFLAGS="$LDFLAGS $LD_BROTLI"
21031 CPPFLAGS="$CPPFLAGS $CPP_BROTLI"
21032 LIBS="$LIB_BROTLI $LIBS"
21033
21034 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BrotliDecoderDecompress in -lbrotlidec" >&5
21035$as_echo_n "checking for BrotliDecoderDecompress in -lbrotlidec... " >&6; }
21036if ${ac_cv_lib_brotlidec_BrotliDecoderDecompress+:} false; then :
21037 $as_echo_n "(cached) " >&6
21038else
21039 ac_check_lib_save_LIBS=$LIBS
21040LIBS="-lbrotlidec $LIBS"
21041cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21042/* end confdefs.h. */
21043
21044
21045#ifdef __cplusplus
21046extern "C"
21047#endif
21048char BrotliDecoderDecompress ();
21049int main (void)
21050{
21051return BrotliDecoderDecompress ();
21052 ;
21053 return 0;
21054}
21055_ACEOF
21056if ac_fn_c_try_link "$LINENO"; then :
21057 ac_cv_lib_brotlidec_BrotliDecoderDecompress=yes
21058else
21059 ac_cv_lib_brotlidec_BrotliDecoderDecompress=no
21060fi
21061rm -f core conftest.err conftest.$ac_objext \
21062 conftest$ac_exeext conftest.$ac_ext
21063LIBS=$ac_check_lib_save_LIBS
21064fi
21065{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_brotlidec_BrotliDecoderDecompress" >&5
21066$as_echo "$ac_cv_lib_brotlidec_BrotliDecoderDecompress" >&6; }
21067if test "x$ac_cv_lib_brotlidec_BrotliDecoderDecompress" = xyes; then :
21068 cat >>confdefs.h <<_ACEOF
21069#define HAVE_LIBBROTLIDEC 1
21070_ACEOF
21071
21072 LIBS="-lbrotlidec $LIBS"
21073
21074fi
21075
21076
21077 for ac_header in brotli/decode.h
21078do :
21079 ac_fn_c_check_header_mongrel "$LINENO" "brotli/decode.h" "ac_cv_header_brotli_decode_h" "$ac_includes_default"
21080if test "x$ac_cv_header_brotli_decode_h" = xyes; then :
21081 cat >>confdefs.h <<_ACEOF
21082#define HAVE_BROTLI_DECODE_H 1
21083_ACEOF
21084 curl_brotli_msg="enabled (libbrotlidec)"
21085 HAVE_BROTLI=1
21086
21087$as_echo "#define HAVE_BROTLI 1" >>confdefs.h
21088
21089 HAVE_BROTLI=1
21090
21091
21092fi
21093
21094done
21095
21096
21097 if test X"$OPT_BROTLI" != Xoff &&
21098 test "$HAVE_BROTLI" != "1"; then
21099 as_fn_error $? "BROTLI libs and/or directories were not found where specified!" "$LINENO" 5
21100 fi
21101
21102 if test "$HAVE_BROTLI" = "1"; then
21103 if test -n "$DIR_BROTLI"; then
21104
21105 if test "x$cross_compiling" != "xyes"; then
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070021106 CURL_LIBRARY_PATH="$CURL_LIBRARY_PATH:$DIR_BROTLI"
21107 export CURL_LIBRARY_PATH
21108 { $as_echo "$as_me:${as_lineno-$LINENO}: Added $DIR_BROTLI to CURL_LIBRARY_PATH" >&5
21109$as_echo "$as_me: Added $DIR_BROTLI to CURL_LIBRARY_PATH" >&6;}
Alex Deymo486467e2017-12-19 19:04:07 +010021110 fi
21111 fi
21112 else
21113 LDFLAGS=$CLEANLDFLAGS
21114 CPPFLAGS=$CLEANCPPFLAGS
21115 LIBS=$CLEANLIBS
21116 fi
21117fi
21118
21119
Elliott Hughes82be86d2017-09-20 17:00:17 -070021120LDAPLIBNAME=""
21121
21122# Check whether --with-ldap-lib was given.
21123if test "${with_ldap_lib+set}" = set; then :
21124 withval=$with_ldap_lib; LDAPLIBNAME="$withval"
21125fi
21126
21127
21128LBERLIBNAME=""
21129
21130# Check whether --with-lber-lib was given.
21131if test "${with_lber_lib+set}" = set; then :
21132 withval=$with_lber_lib; LBERLIBNAME="$withval"
21133fi
21134
21135
21136if test x$CURL_DISABLE_LDAP != x1 ; then
21137
21138
21139 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lber.h" >&5
21140$as_echo_n "checking for lber.h... " >&6; }
21141if ${curl_cv_header_lber_h+:} false; then :
21142 $as_echo_n "(cached) " >&6
21143else
21144
21145 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21146/* end confdefs.h. */
21147
21148
21149#undef inline
21150#ifdef HAVE_WINDOWS_H
21151#ifndef WIN32_LEAN_AND_MEAN
21152#define WIN32_LEAN_AND_MEAN
21153#endif
21154#include <windows.h>
21155#else
21156#ifdef HAVE_SYS_TYPES_H
21157#include <sys/types.h>
21158#endif
21159#endif
21160#ifndef NULL
21161#define NULL (void *)0
21162#endif
21163#include <lber.h>
21164
21165int main (void)
21166{
21167
21168 BerValue *bvp = NULL;
21169 BerElement *bep = ber_init(bvp);
21170 ber_free(bep, 1);
21171
21172 ;
21173 return 0;
21174}
21175
21176_ACEOF
21177if ac_fn_c_try_compile "$LINENO"; then :
21178
21179 curl_cv_header_lber_h="yes"
21180
21181else
21182
21183 curl_cv_header_lber_h="no"
21184
21185fi
21186rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21187
21188fi
21189{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_lber_h" >&5
21190$as_echo "$curl_cv_header_lber_h" >&6; }
21191 if test "$curl_cv_header_lber_h" = "yes"; then
21192
21193cat >>confdefs.h <<_ACEOF
21194#define HAVE_LBER_H 1
21195_ACEOF
21196
21197 #
21198 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21199/* end confdefs.h. */
21200
21201
21202#undef inline
21203#ifdef HAVE_WINDOWS_H
21204#ifndef WIN32_LEAN_AND_MEAN
21205#define WIN32_LEAN_AND_MEAN
21206#endif
21207#include <windows.h>
21208#else
21209#ifdef HAVE_SYS_TYPES_H
21210#include <sys/types.h>
21211#endif
21212#endif
21213#ifndef NULL
21214#define NULL (void *)0
21215#endif
21216#ifndef LDAP_DEPRECATED
21217#define LDAP_DEPRECATED 1
21218#endif
21219#include <ldap.h>
21220
21221int main (void)
21222{
21223
21224 BerValue *bvp = NULL;
21225 BerElement *bep = ber_init(bvp);
21226 ber_free(bep, 1);
21227
21228 ;
21229 return 0;
21230}
21231
21232_ACEOF
21233if ac_fn_c_try_compile "$LINENO"; then :
21234
21235 curl_cv_need_header_lber_h="no"
21236
21237else
21238
21239 curl_cv_need_header_lber_h="yes"
21240
21241fi
21242rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21243 #
21244 case "$curl_cv_need_header_lber_h" in
21245 yes)
21246
21247cat >>confdefs.h <<_ACEOF
21248#define NEED_LBER_H 1
21249_ACEOF
21250
21251 ;;
21252 esac
21253 fi
21254
21255
21256 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ldap.h" >&5
21257$as_echo_n "checking for ldap.h... " >&6; }
21258if ${curl_cv_header_ldap_h+:} false; then :
21259 $as_echo_n "(cached) " >&6
21260else
21261
21262 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21263/* end confdefs.h. */
21264
21265
21266#undef inline
21267#ifdef HAVE_WINDOWS_H
21268#ifndef WIN32_LEAN_AND_MEAN
21269#define WIN32_LEAN_AND_MEAN
21270#endif
21271#include <windows.h>
21272#else
21273#ifdef HAVE_SYS_TYPES_H
21274#include <sys/types.h>
21275#endif
21276#endif
21277#ifndef LDAP_DEPRECATED
21278#define LDAP_DEPRECATED 1
21279#endif
21280#ifdef NEED_LBER_H
21281#include <lber.h>
21282#endif
21283#include <ldap.h>
21284
21285int main (void)
21286{
21287
21288 LDAP *ldp = ldap_init("dummy", LDAP_PORT);
21289 int res = ldap_unbind(ldp);
21290
21291 ;
21292 return 0;
21293}
21294
21295_ACEOF
21296if ac_fn_c_try_compile "$LINENO"; then :
21297
21298 curl_cv_header_ldap_h="yes"
21299
21300else
21301
21302 curl_cv_header_ldap_h="no"
21303
21304fi
21305rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21306
21307fi
21308{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_ldap_h" >&5
21309$as_echo "$curl_cv_header_ldap_h" >&6; }
21310 case "$curl_cv_header_ldap_h" in
21311 yes)
21312
21313cat >>confdefs.h <<_ACEOF
21314#define HAVE_LDAP_H 1
21315_ACEOF
21316
21317 ;;
21318 esac
21319
21320
21321 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ldapssl.h" >&5
21322$as_echo_n "checking for ldapssl.h... " >&6; }
21323if ${curl_cv_header_ldapssl_h+:} false; then :
21324 $as_echo_n "(cached) " >&6
21325else
21326
21327 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21328/* end confdefs.h. */
21329
21330
21331#undef inline
21332#ifdef HAVE_WINDOWS_H
21333#ifndef WIN32_LEAN_AND_MEAN
21334#define WIN32_LEAN_AND_MEAN
21335#endif
21336#include <windows.h>
21337#else
21338#ifdef HAVE_SYS_TYPES_H
21339#include <sys/types.h>
21340#endif
21341#endif
21342#ifndef NULL
21343#define NULL (void *)0
21344#endif
21345#ifndef LDAP_DEPRECATED
21346#define LDAP_DEPRECATED 1
21347#endif
21348#ifdef NEED_LBER_H
21349#include <lber.h>
21350#endif
21351#ifdef HAVE_LDAP_H
21352#include <ldap.h>
21353#endif
21354#include <ldapssl.h>
21355
21356int main (void)
21357{
21358
21359 char *cert_label = NULL;
21360 LDAP *ldp = ldap_ssl_init("dummy", LDAPS_PORT, cert_label);
21361
21362 ;
21363 return 0;
21364}
21365
21366_ACEOF
21367if ac_fn_c_try_compile "$LINENO"; then :
21368
21369 curl_cv_header_ldapssl_h="yes"
21370
21371else
21372
21373 curl_cv_header_ldapssl_h="no"
21374
21375fi
21376rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21377
21378fi
21379{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_ldapssl_h" >&5
21380$as_echo "$curl_cv_header_ldapssl_h" >&6; }
21381 case "$curl_cv_header_ldapssl_h" in
21382 yes)
21383
21384cat >>confdefs.h <<_ACEOF
21385#define HAVE_LDAPSSL_H 1
21386_ACEOF
21387
21388 ;;
21389 esac
21390
21391
21392 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ldap_ssl.h" >&5
21393$as_echo_n "checking for ldap_ssl.h... " >&6; }
21394if ${curl_cv_header_ldap_ssl_h+:} false; then :
21395 $as_echo_n "(cached) " >&6
21396else
21397
21398 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21399/* end confdefs.h. */
21400
21401
21402#undef inline
21403#ifdef HAVE_WINDOWS_H
21404#ifndef WIN32_LEAN_AND_MEAN
21405#define WIN32_LEAN_AND_MEAN
21406#endif
21407#include <windows.h>
21408#else
21409#ifdef HAVE_SYS_TYPES_H
21410#include <sys/types.h>
21411#endif
21412#endif
21413#ifndef LDAP_DEPRECATED
21414#define LDAP_DEPRECATED 1
21415#endif
21416#ifdef NEED_LBER_H
21417#include <lber.h>
21418#endif
21419#ifdef HAVE_LDAP_H
21420#include <ldap.h>
21421#endif
21422#include <ldap_ssl.h>
21423
21424int main (void)
21425{
21426
21427 LDAP *ldp = ldapssl_init("dummy", LDAPS_PORT, 1);
21428
21429 ;
21430 return 0;
21431}
21432
21433_ACEOF
21434if ac_fn_c_try_compile "$LINENO"; then :
21435
21436 curl_cv_header_ldap_ssl_h="yes"
21437
21438else
21439
21440 curl_cv_header_ldap_ssl_h="no"
21441
21442fi
21443rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21444
21445fi
21446{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_ldap_ssl_h" >&5
21447$as_echo "$curl_cv_header_ldap_ssl_h" >&6; }
21448 case "$curl_cv_header_ldap_ssl_h" in
21449 yes)
21450
21451cat >>confdefs.h <<_ACEOF
21452#define HAVE_LDAP_SSL_H 1
21453_ACEOF
21454
21455 ;;
21456 esac
21457
21458
21459 if test -z "$LDAPLIBNAME" ; then
21460 if test "$curl_cv_native_windows" = "yes"; then
21461 LDAPLIBNAME="wldap32"
21462 LBERLIBNAME="no"
21463 fi
21464 fi
21465
21466 if test "$LDAPLIBNAME" ; then
21467 as_ac_Lib=`$as_echo "ac_cv_lib_"$LDAPLIBNAME"''_ldap_init" | $as_tr_sh`
21468{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ldap_init in -l\"$LDAPLIBNAME\"" >&5
21469$as_echo_n "checking for ldap_init in -l\"$LDAPLIBNAME\"... " >&6; }
21470if eval \${$as_ac_Lib+:} false; then :
21471 $as_echo_n "(cached) " >&6
21472else
21473 ac_check_lib_save_LIBS=$LIBS
21474LIBS="-l"$LDAPLIBNAME" $LIBS"
21475cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21476/* end confdefs.h. */
21477
21478
21479#ifdef __cplusplus
21480extern "C"
21481#endif
21482char ldap_init ();
21483int main (void)
21484{
21485return ldap_init ();
21486 ;
21487 return 0;
21488}
21489_ACEOF
21490if ac_fn_c_try_link "$LINENO"; then :
21491 eval "$as_ac_Lib=yes"
21492else
21493 eval "$as_ac_Lib=no"
21494fi
21495rm -f core conftest.err conftest.$ac_objext \
21496 conftest$ac_exeext conftest.$ac_ext
21497LIBS=$ac_check_lib_save_LIBS
21498fi
21499eval ac_res=\$$as_ac_Lib
21500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
21501$as_echo "$ac_res" >&6; }
21502if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
21503 cat >>confdefs.h <<_ACEOF
21504#define `$as_echo "HAVE_LIB"$LDAPLIBNAME"" | $as_tr_cpp` 1
21505_ACEOF
21506
21507 LIBS="-l"$LDAPLIBNAME" $LIBS"
21508
21509else
21510
21511 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \"$LDAPLIBNAME\" is not an LDAP library: LDAP disabled" >&5
21512$as_echo "$as_me: WARNING: \"$LDAPLIBNAME\" is not an LDAP library: LDAP disabled" >&2;}
21513
21514$as_echo "#define CURL_DISABLE_LDAP 1" >>confdefs.h
21515
21516 CURL_DISABLE_LDAP=1
21517
21518
21519$as_echo "#define CURL_DISABLE_LDAPS 1" >>confdefs.h
21520
21521 CURL_DISABLE_LDAPS=1
21522
21523fi
21524
21525 else
21526
21527 #
21528 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LDAP libraries" >&5
21529$as_echo_n "checking for LDAP libraries... " >&6; }
21530 #
21531 u_libs=""
21532 #
21533
21534 #
21535 curl_cv_save_LIBS="$LIBS"
21536 curl_cv_ldap_LIBS="unknown"
21537 #
21538 for x_nlibs in '' "$u_libs" \
21539 '-lldap' \
21540 '-lldap -llber' \
21541 '-llber -lldap' \
21542 '-lldapssl -lldapx -lldapsdk' \
Haibo Huang65021c72019-03-27 15:37:23 -070021543 '-lldapsdk -lldapx -lldapssl' \
21544 '-lldap -llber -lssl -lcrypto' ; do
21545
Elliott Hughes82be86d2017-09-20 17:00:17 -070021546 if test "$curl_cv_ldap_LIBS" = "unknown"; then
21547 if test -z "$x_nlibs"; then
21548 LIBS="$curl_cv_save_LIBS"
21549 else
21550 LIBS="$x_nlibs $curl_cv_save_LIBS"
21551 fi
21552 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21553/* end confdefs.h. */
21554
21555
21556#undef inline
21557#ifdef HAVE_WINDOWS_H
21558#ifndef WIN32_LEAN_AND_MEAN
21559#define WIN32_LEAN_AND_MEAN
21560#endif
21561#include <windows.h>
21562#else
21563#ifdef HAVE_SYS_TYPES_H
21564#include <sys/types.h>
21565#endif
21566#endif
21567#ifndef NULL
21568#define NULL (void *)0
21569#endif
21570#ifndef LDAP_DEPRECATED
21571#define LDAP_DEPRECATED 1
21572#endif
21573#ifdef NEED_LBER_H
21574#include <lber.h>
21575#endif
21576#ifdef HAVE_LDAP_H
21577#include <ldap.h>
21578#endif
21579
21580int main (void)
21581{
21582
21583 BerValue *bvp = NULL;
21584 BerElement *bep = ber_init(bvp);
21585 LDAP *ldp = ldap_init("dummy", LDAP_PORT);
21586 int res = ldap_unbind(ldp);
21587 ber_free(bep, 1);
21588
21589 ;
21590 return 0;
21591}
21592
21593_ACEOF
21594if ac_fn_c_try_link "$LINENO"; then :
21595
21596 curl_cv_ldap_LIBS="$x_nlibs"
21597
21598fi
21599rm -f core conftest.err conftest.$ac_objext \
21600 conftest$ac_exeext conftest.$ac_ext
21601 fi
21602 done
21603 #
21604 LIBS="$curl_cv_save_LIBS"
21605 #
21606 case X-"$curl_cv_ldap_LIBS" in
21607 X-unknown)
21608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: cannot find LDAP libraries" >&5
21609$as_echo "cannot find LDAP libraries" >&6; }
21610 ;;
21611 X-)
21612 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no additional lib required" >&5
21613$as_echo "no additional lib required" >&6; }
21614 ;;
21615 *)
21616 if test -z "$curl_cv_save_LIBS"; then
21617 LIBS="$curl_cv_ldap_LIBS"
21618 else
21619 LIBS="$curl_cv_ldap_LIBS $curl_cv_save_LIBS"
21620 fi
21621 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_ldap_LIBS" >&5
21622$as_echo "$curl_cv_ldap_LIBS" >&6; }
21623 ;;
21624 esac
21625 #
21626
21627 case X-"$curl_cv_ldap_LIBS" in
21628 X-unknown)
21629 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Cannot find libraries for LDAP support: LDAP disabled" >&5
21630$as_echo "$as_me: WARNING: Cannot find libraries for LDAP support: LDAP disabled" >&2;}
21631
21632$as_echo "#define CURL_DISABLE_LDAP 1" >>confdefs.h
21633
21634 CURL_DISABLE_LDAP=1
21635
21636
21637$as_echo "#define CURL_DISABLE_LDAPS 1" >>confdefs.h
21638
21639 CURL_DISABLE_LDAPS=1
21640
21641 ;;
21642 esac
21643 fi
21644fi
21645
21646if test x$CURL_DISABLE_LDAP != x1 ; then
21647
21648 if test "$LBERLIBNAME" ; then
21649 if test "$LBERLIBNAME" != "no" ; then
21650 as_ac_Lib=`$as_echo "ac_cv_lib_"$LBERLIBNAME"''_ber_free" | $as_tr_sh`
21651{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ber_free in -l\"$LBERLIBNAME\"" >&5
21652$as_echo_n "checking for ber_free in -l\"$LBERLIBNAME\"... " >&6; }
21653if eval \${$as_ac_Lib+:} false; then :
21654 $as_echo_n "(cached) " >&6
21655else
21656 ac_check_lib_save_LIBS=$LIBS
21657LIBS="-l"$LBERLIBNAME" $LIBS"
21658cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21659/* end confdefs.h. */
21660
21661
21662#ifdef __cplusplus
21663extern "C"
21664#endif
21665char ber_free ();
21666int main (void)
21667{
21668return ber_free ();
21669 ;
21670 return 0;
21671}
21672_ACEOF
21673if ac_fn_c_try_link "$LINENO"; then :
21674 eval "$as_ac_Lib=yes"
21675else
21676 eval "$as_ac_Lib=no"
21677fi
21678rm -f core conftest.err conftest.$ac_objext \
21679 conftest$ac_exeext conftest.$ac_ext
21680LIBS=$ac_check_lib_save_LIBS
21681fi
21682eval ac_res=\$$as_ac_Lib
21683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
21684$as_echo "$ac_res" >&6; }
21685if eval test \"x\$"$as_ac_Lib"\" = x"yes"; then :
21686 cat >>confdefs.h <<_ACEOF
21687#define `$as_echo "HAVE_LIB"$LBERLIBNAME"" | $as_tr_cpp` 1
21688_ACEOF
21689
21690 LIBS="-l"$LBERLIBNAME" $LIBS"
21691
21692else
21693
21694 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \"$LBERLIBNAME\" is not an LBER library: LDAP disabled" >&5
21695$as_echo "$as_me: WARNING: \"$LBERLIBNAME\" is not an LBER library: LDAP disabled" >&2;}
21696
21697$as_echo "#define CURL_DISABLE_LDAP 1" >>confdefs.h
21698
21699 CURL_DISABLE_LDAP=1
21700
21701
21702$as_echo "#define CURL_DISABLE_LDAPS 1" >>confdefs.h
21703
21704 CURL_DISABLE_LDAPS=1
21705
21706fi
21707
21708 fi
21709 fi
21710fi
21711
21712if test x$CURL_DISABLE_LDAP != x1 ; then
21713 for ac_func in ldap_url_parse ldap_init_fd
21714do :
21715 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21716ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
21717if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
21718 cat >>confdefs.h <<_ACEOF
21719#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21720_ACEOF
21721
21722fi
21723done
21724
21725
21726 if test "$LDAPLIBNAME" = "wldap32"; then
21727 curl_ldap_msg="enabled (winldap)"
21728
21729$as_echo "#define USE_WIN32_LDAP 1" >>confdefs.h
21730
21731 else
21732 curl_ldap_msg="enabled (OpenLDAP)"
21733 if test "x$ac_cv_func_ldap_init_fd" = "xyes"; then
21734
21735$as_echo "#define USE_OPENLDAP 1" >>confdefs.h
21736
21737 USE_OPENLDAP=1
21738
21739 fi
21740 fi
21741fi
21742
21743if test x$CURL_DISABLE_LDAPS != x1 ; then
21744 curl_ldaps_msg="enabled"
21745fi
21746
21747
21748{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable IPv6" >&5
21749$as_echo_n "checking whether to enable IPv6... " >&6; }
21750# Check whether --enable-ipv6 was given.
21751if test "${enable_ipv6+set}" = set; then :
21752 enableval=$enable_ipv6; case "$enableval" in
21753 no)
21754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21755$as_echo "no" >&6; }
21756 ipv6=no
21757 ;;
21758 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
21759$as_echo "yes" >&6; }
21760 ipv6=yes
21761 ;;
21762 esac
21763else
21764 if test "$cross_compiling" = yes; then :
21765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
21766$as_echo "yes" >&6; }
21767 ipv6=yes
21768
21769else
21770 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21771/* end confdefs.h. */
21772 /* is AF_INET6 available? */
21773#include <sys/types.h>
21774#ifdef HAVE_WINSOCK2_H
21775#include <winsock2.h>
21776#else
21777#include <sys/socket.h>
21778#endif
21779#include <stdlib.h> /* for exit() */
21780main()
21781{
21782 if (socket(AF_INET6, SOCK_STREAM, 0) < 0)
21783 exit(1);
21784 else
21785 exit(0);
21786}
21787
21788_ACEOF
21789if ac_fn_c_try_run "$LINENO"; then :
21790 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
21791$as_echo "yes" >&6; }
21792 ipv6=yes
21793else
21794 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21795$as_echo "no" >&6; }
21796 ipv6=no
21797fi
21798rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21799 conftest.$ac_objext conftest.beam conftest.$ac_ext
21800fi
21801
21802fi
21803
21804
21805if test "$ipv6" = "yes"; then
21806 curl_ipv6_msg="enabled"
21807fi
21808
21809# Check if struct sockaddr_in6 have sin6_scope_id member
21810if test "$ipv6" = yes; then
21811 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if struct sockaddr_in6 has sin6_scope_id member" >&5
21812$as_echo_n "checking if struct sockaddr_in6 has sin6_scope_id member... " >&6; }
21813 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21814/* end confdefs.h. */
21815
21816#include <sys/types.h>
21817#ifdef HAVE_WINSOCK2_H
21818#include <winsock2.h>
21819#include <ws2tcpip.h>
21820#else
21821#include <netinet/in.h>
Elliott Hughes0128fe42018-02-27 14:57:55 -080021822#if defined (__TANDEM)
21823# include <netinet/in6.h>
21824#endif
Elliott Hughes82be86d2017-09-20 17:00:17 -070021825#endif
21826int main (void)
21827{
21828struct sockaddr_in6 s; s.sin6_scope_id = 0;
21829 ;
21830 return 0;
21831}
21832_ACEOF
21833if ac_fn_c_try_compile "$LINENO"; then :
21834 have_sin6_scope_id=yes
21835fi
21836rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21837 if test "$have_sin6_scope_id" = yes; then
21838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
21839$as_echo "yes" >&6; }
21840
21841$as_echo "#define HAVE_SOCKADDR_IN6_SIN6_SCOPE_ID 1" >>confdefs.h
21842
21843 else
21844 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21845$as_echo "no" >&6; }
21846 fi
21847fi
21848
21849
21850{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if argv can be written to" >&5
21851$as_echo_n "checking if argv can be written to... " >&6; }
Elliott Hughes82be86d2017-09-20 17:00:17 -070021852
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070021853
21854 old=$LD_LIBRARY_PATH
Elliott Hughes72d948d2018-08-03 14:37:21 -070021855 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
21856 export LD_LIBRARY_PATH
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070021857 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070021858 curl_cv_writable_argv=cross
21859
21860else
21861 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21862/* end confdefs.h. */
21863
Elliott Hughes82be86d2017-09-20 17:00:17 -070021864int main(int argc, char ** argv) {
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070021865 argv00 = ' ';
21866 return (argv00 == ' ')?0:1;
Elliott Hughes82be86d2017-09-20 17:00:17 -070021867}
21868
Elliott Hughes82be86d2017-09-20 17:00:17 -070021869_ACEOF
21870if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070021871 curl_cv_writable_argv=yes
21872
21873else
Elliott Hughes82be86d2017-09-20 17:00:17 -070021874 curl_cv_writable_argv=no
21875
21876fi
21877rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21878 conftest.$ac_objext conftest.beam conftest.$ac_ext
21879fi
21880
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070021881 LD_LIBRARY_PATH=$old # restore
21882
Elliott Hughes82be86d2017-09-20 17:00:17 -070021883case $curl_cv_writable_argv in
21884yes)
21885
21886$as_echo "#define HAVE_WRITABLE_ARGV 1" >>confdefs.h
21887
21888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
21889$as_echo "yes" >&6; }
21890 ;;
21891no)
21892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21893$as_echo "no" >&6; }
21894 ;;
21895*)
21896 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
21897$as_echo "no" >&6; }
21898 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: the previous check could not be made default was used" >&5
21899$as_echo "$as_me: WARNING: the previous check could not be made default was used" >&2;}
21900 ;;
21901esac
21902
21903
21904
21905GSSAPI_ROOT="/usr"
21906
21907# Check whether --with-gssapi-includes was given.
21908if test "${with_gssapi_includes+set}" = set; then :
21909 withval=$with_gssapi_includes; GSSAPI_INCS="-I$withval"
21910 want_gss="yes"
21911
21912fi
21913
21914
21915
21916# Check whether --with-gssapi-libs was given.
21917if test "${with_gssapi_libs+set}" = set; then :
21918 withval=$with_gssapi_libs; GSSAPI_LIB_DIR="-L$withval"
21919 want_gss="yes"
21920
21921fi
21922
21923
21924
21925# Check whether --with-gssapi was given.
21926if test "${with_gssapi+set}" = set; then :
21927 withval=$with_gssapi;
21928 GSSAPI_ROOT="$withval"
21929 if test x"$GSSAPI_ROOT" != xno; then
21930 want_gss="yes"
21931 if test x"$GSSAPI_ROOT" = xyes; then
21932 GSSAPI_ROOT="/usr"
21933 fi
21934 fi
21935
21936fi
21937
21938
21939: ${KRB5CONFIG:="$GSSAPI_ROOT/bin/krb5-config"}
21940
21941save_CPPFLAGS="$CPPFLAGS"
21942{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if GSS-API support is requested" >&5
21943$as_echo_n "checking if GSS-API support is requested... " >&6; }
21944if test x"$want_gss" = xyes; then
21945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
21946$as_echo "yes" >&6; }
21947
21948 if test -z "$GSSAPI_INCS"; then
21949 if test -n "$host_alias" -a -f "$GSSAPI_ROOT/bin/$host_alias-krb5-config"; then
21950 GSSAPI_INCS=`$GSSAPI_ROOT/bin/$host_alias-krb5-config --cflags gssapi`
21951 elif test -f "$KRB5CONFIG"; then
21952 GSSAPI_INCS=`$KRB5CONFIG --cflags gssapi`
21953 elif test "$GSSAPI_ROOT" != "yes"; then
21954 GSSAPI_INCS="-I$GSSAPI_ROOT/include"
21955 fi
21956 fi
21957
21958 CPPFLAGS="$CPPFLAGS $GSSAPI_INCS"
21959
21960 ac_fn_c_check_header_mongrel "$LINENO" "gss.h" "ac_cv_header_gss_h" "$ac_includes_default"
21961if test "x$ac_cv_header_gss_h" = xyes; then :
21962
21963
21964$as_echo "#define HAVE_GSSGNU 1" >>confdefs.h
21965
21966 gnu_gss=yes
21967
21968else
21969
21970 for ac_header in gssapi/gssapi.h
21971do :
21972 ac_fn_c_check_header_mongrel "$LINENO" "gssapi/gssapi.h" "ac_cv_header_gssapi_gssapi_h" "$ac_includes_default"
21973if test "x$ac_cv_header_gssapi_gssapi_h" = xyes; then :
21974 cat >>confdefs.h <<_ACEOF
21975#define HAVE_GSSAPI_GSSAPI_H 1
21976_ACEOF
21977
21978else
21979 not_mit=1
21980fi
21981
21982done
21983
21984 for ac_header in gssapi/gssapi_generic.h gssapi/gssapi_krb5.h
21985do :
21986 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
21987ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "
21988$ac_includes_default
21989#ifdef HAVE_GSSAPI_GSSAPI_H
21990#include <gssapi/gssapi.h>
21991#endif
21992
21993"
21994if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
21995 cat >>confdefs.h <<_ACEOF
21996#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
21997_ACEOF
21998
21999else
22000 not_mit=1
22001fi
22002
22003done
22004
22005 if test "x$not_mit" = "x1"; then
22006 ac_fn_c_check_header_mongrel "$LINENO" "gssapi.h" "ac_cv_header_gssapi_h" "$ac_includes_default"
22007if test "x$ac_cv_header_gssapi_h" = xyes; then :
22008
22009
22010$as_echo "#define HAVE_GSSHEIMDAL 1" >>confdefs.h
22011
22012
22013else
22014
22015 want_gss=no
22016 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: disabling GSS-API support since no header files were found" >&5
22017$as_echo "$as_me: WARNING: disabling GSS-API support since no header files were found" >&2;}
22018
22019
22020fi
22021
22022
22023 else
22024
22025$as_echo "#define HAVE_GSSMIT 1" >>confdefs.h
22026
22027 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if GSS-API headers declare GSS_C_NT_HOSTBASED_SERVICE" >&5
22028$as_echo_n "checking if GSS-API headers declare GSS_C_NT_HOSTBASED_SERVICE... " >&6; }
22029 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22030/* end confdefs.h. */
22031
22032
22033#include <gssapi/gssapi.h>
22034#include <gssapi/gssapi_generic.h>
22035#include <gssapi/gssapi_krb5.h>
22036
22037int main (void)
22038{
22039
22040 gss_import_name(
22041 (OM_uint32 *)0,
22042 (gss_buffer_t)0,
22043 GSS_C_NT_HOSTBASED_SERVICE,
22044 (gss_name_t *)0);
22045
22046 ;
22047 return 0;
22048}
22049
22050_ACEOF
22051if ac_fn_c_try_compile "$LINENO"; then :
22052
22053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22054$as_echo "yes" >&6; }
22055
22056else
22057
22058 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22059$as_echo "no" >&6; }
22060
22061$as_echo "#define HAVE_OLD_GSSMIT 1" >>confdefs.h
22062
22063
22064fi
22065rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22066 fi
22067
22068
22069fi
22070
22071
22072else
22073 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22074$as_echo "no" >&6; }
22075fi
22076if test x"$want_gss" = xyes; then
22077
22078$as_echo "#define HAVE_GSSAPI 1" >>confdefs.h
22079
22080 HAVE_GSSAPI=1
22081 curl_gss_msg="enabled (MIT Kerberos/Heimdal)"
22082
22083 if test -n "$gnu_gss"; then
22084 curl_gss_msg="enabled (GNU GSS)"
22085 LDFLAGS="$LDFLAGS $GSSAPI_LIB_DIR"
22086 LIBS="-lgss $LIBS"
22087 elif test -z "$GSSAPI_LIB_DIR"; then
22088 case $host in
22089 *-*-darwin*)
22090 LIBS="-lgssapi_krb5 -lresolv $LIBS"
22091 ;;
22092 *)
22093 if test -n "$host_alias" -a -f "$GSSAPI_ROOT/bin/$host_alias-krb5-config"; then
22094 gss_libs=`$GSSAPI_ROOT/bin/$host_alias-krb5-config --libs gssapi`
22095 LIBS="$gss_libs $LIBS"
22096 elif test -f "$KRB5CONFIG"; then
22097 gss_libs=`$KRB5CONFIG --libs gssapi`
22098 LIBS="$gss_libs $LIBS"
22099 else
22100 case $host in
22101 *-hp-hpux*)
22102 gss_libname="gss"
22103 ;;
22104 *)
22105 gss_libname="gssapi"
22106 ;;
22107 esac
22108
22109 if test "$GSSAPI_ROOT" != "yes"; then
22110 LDFLAGS="$LDFLAGS -L$GSSAPI_ROOT/lib$libsuff"
22111 LIBS="-l$gss_libname $LIBS"
22112 else
22113 LIBS="-l$gss_libname $LIBS"
22114 fi
22115 fi
22116 ;;
22117 esac
22118 else
22119 LDFLAGS="$LDFLAGS $GSSAPI_LIB_DIR"
22120 case $host in
22121 *-hp-hpux*)
22122 LIBS="-lgss $LIBS"
22123 ;;
22124 *)
22125 LIBS="-lgssapi $LIBS"
22126 ;;
22127 esac
22128 fi
22129else
22130 CPPFLAGS="$save_CPPFLAGS"
22131fi
22132
Alex Deymo486467e2017-12-19 19:04:07 +010022133build_libstubgss=no
22134if test x"$want_gss" = "xyes"; then
22135 build_libstubgss=yes
22136fi
22137
22138 if test "x$build_libstubgss" = "xyes"; then
22139 BUILD_STUB_GSS_TRUE=
22140 BUILD_STUB_GSS_FALSE='#'
22141else
22142 BUILD_STUB_GSS_TRUE='#'
22143 BUILD_STUB_GSS_FALSE=
22144fi
22145
22146
22147
22148DEFAULT_SSL_BACKEND=no
22149VALID_DEFAULT_SSL_BACKEND=
22150
22151# Check whether --with-default-ssl-backend was given.
22152if test "${with_default_ssl_backend+set}" = set; then :
22153 withval=$with_default_ssl_backend; DEFAULT_SSL_BACKEND=$withval
22154fi
22155
22156case "$DEFAULT_SSL_BACKEND" in
22157 no)
22158 ;;
22159 default|yes)
22160 as_fn_error $? "The name of the default SSL backend is required." "$LINENO" 5
22161 ;;
22162 *)
22163
22164 VALID_DEFAULT_SSL_BACKEND=no
22165 ;;
22166esac
22167
22168
Elliott Hughes82be86d2017-09-20 17:00:17 -070022169
22170OPT_WINSSL=no
22171
22172# Check whether --with-winssl was given.
22173if test "${with_winssl+set}" = set; then :
22174 withval=$with_winssl; OPT_WINSSL=$withval
22175fi
22176
22177
Haibo Huang51d9d882019-02-06 01:36:06 -080022178
22179# Check whether --with-schannel was given.
22180if test "${with_schannel+set}" = set; then :
22181 withval=$with_schannel; OPT_WINSSL=$withval
22182fi
22183
22184
Elliott Hughes82be86d2017-09-20 17:00:17 -070022185{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable Windows native SSL/TLS (Windows native builds only)" >&5
22186$as_echo_n "checking whether to enable Windows native SSL/TLS (Windows native builds only)... " >&6; }
Alex Deymo486467e2017-12-19 19:04:07 +010022187if test -z "$ssl_backends" -o "x$OPT_WINSSL" != xno; then
22188 ssl_msg=
Elliott Hughes82be86d2017-09-20 17:00:17 -070022189 if test "x$OPT_WINSSL" != "xno" &&
22190 test "x$curl_cv_native_windows" = "xyes"; then
22191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22192$as_echo "yes" >&6; }
22193
22194$as_echo "#define USE_SCHANNEL 1" >>confdefs.h
22195
22196 USE_SCHANNEL=1
22197
Alex Deymo486467e2017-12-19 19:04:07 +010022198 ssl_msg="Windows-native"
22199 test schannel != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
Elliott Hughes82be86d2017-09-20 17:00:17 -070022200 WINSSL_ENABLED=1
22201 # --with-winssl implies --enable-sspi
22202
22203$as_echo "#define USE_WINDOWS_SSPI 1" >>confdefs.h
22204
22205 USE_WINDOWS_SSPI=1
22206
22207 curl_sspi_msg="enabled"
22208 LIBS="-lcrypt32 $LIBS"
22209 else
22210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22211$as_echo "no" >&6; }
22212 fi
Alex Deymo486467e2017-12-19 19:04:07 +010022213 test -z "$ssl_msg" || ssl_backends="${ssl_backends:+$ssl_backends, }$ssl_msg"
Elliott Hughes82be86d2017-09-20 17:00:17 -070022214else
22215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22216$as_echo "no" >&6; }
22217fi
22218
Haibo Huang65021c72019-03-27 15:37:23 -070022219OPT_SECURETRANSPORT=no
Elliott Hughes82be86d2017-09-20 17:00:17 -070022220
22221# Check whether --with-darwinssl was given.
22222if test "${with_darwinssl+set}" = set; then :
Haibo Huang65021c72019-03-27 15:37:23 -070022223 withval=$with_darwinssl; OPT_SECURETRANSPORT=$withval
Elliott Hughes82be86d2017-09-20 17:00:17 -070022224fi
22225
22226
Haibo Huang65021c72019-03-27 15:37:23 -070022227
22228# Check whether --with-secure-transport was given.
22229if test "${with_secure_transport+set}" = set; then :
22230 withval=$with_secure_transport; OPT_SECURETRANSPORT=$withval
22231fi
22232
22233
22234{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable Secure Transport" >&5
22235$as_echo_n "checking whether to enable Secure Transport... " >&6; }
22236if test -z "$ssl_backends" -o "x$OPT_SECURETRANSPORT" != xno; then
22237 if test "x$OPT_SECURETRANSPORT" != "xno" &&
Elliott Hughes82be86d2017-09-20 17:00:17 -070022238 test -d "/System/Library/Frameworks/Security.framework"; then
22239 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22240$as_echo "yes" >&6; }
22241
Haibo Huang65021c72019-03-27 15:37:23 -070022242$as_echo "#define USE_SECTRANSP 1" >>confdefs.h
Elliott Hughes82be86d2017-09-20 17:00:17 -070022243
Haibo Huang65021c72019-03-27 15:37:23 -070022244 USE_SECTRANSP=1
Elliott Hughes82be86d2017-09-20 17:00:17 -070022245
Haibo Huang65021c72019-03-27 15:37:23 -070022246 ssl_msg="Secure Transport"
22247 test secure-transport != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
22248 SECURETRANSPORT_ENABLED=1
Elliott Hughes82be86d2017-09-20 17:00:17 -070022249 LDFLAGS="$LDFLAGS -framework CoreFoundation -framework Security"
22250 else
22251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22252$as_echo "no" >&6; }
22253 fi
Alex Deymo486467e2017-12-19 19:04:07 +010022254 test -z "$ssl_msg" || ssl_backends="${ssl_backends:+$ssl_backends, }$ssl_msg"
Elliott Hughes82be86d2017-09-20 17:00:17 -070022255else
22256 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22257$as_echo "no" >&6; }
22258fi
22259
Haibo Huang65021c72019-03-27 15:37:23 -070022260OPT_AMISSL=no
22261
22262# Check whether --with-amissl was given.
22263if test "${with_amissl+set}" = set; then :
22264 withval=$with_amissl; OPT_AMISSL=$withval
22265fi
22266
22267
22268{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable Amiga native SSL/TLS (AmiSSL)" >&5
22269$as_echo_n "checking whether to enable Amiga native SSL/TLS (AmiSSL)... " >&6; }
Haibo Huang34ab3462019-05-22 00:50:27 -070022270if test "$HAVE_PROTO_BSDSOCKET_H" = "1"; then
Haibo Huang65021c72019-03-27 15:37:23 -070022271 if test -z "$ssl_backends" -o "x$OPT_AMISSL" != xno; then
22272 ssl_msg=
22273 if test "x$OPT_AMISSL" != "xno"; then
22274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22275$as_echo "yes" >&6; }
22276 ssl_msg="AmiSSL"
22277 test amissl != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
22278 AMISSL_ENABLED=1
22279 LIBS="-lamisslauto $LIBS"
22280
22281$as_echo "#define USE_AMISSL 1" >>confdefs.h
22282
22283
22284$as_echo "#define USE_OPENSSL 1" >>confdefs.h
22285
22286 else
22287 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22288$as_echo "no" >&6; }
22289 fi
22290 test -z "$ssl_msg" || ssl_backends="${ssl_backends:+$ssl_backends, }$ssl_msg"
22291 else
22292 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22293$as_echo "no" >&6; }
22294 fi
22295else
22296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22297$as_echo "no" >&6; }
22298fi
22299
Elliott Hughes82be86d2017-09-20 17:00:17 -070022300
22301OPT_SSL=off
22302ca="no"
22303
22304# Check whether --with-ssl was given.
22305if test "${with_ssl+set}" = set; then :
22306 withval=$with_ssl; OPT_SSL=$withval
22307fi
22308
22309
Alex Deymo486467e2017-12-19 19:04:07 +010022310if test -z "$ssl_backends" -o "x$OPT_SSL" != xno &&
22311 test X"$OPT_SSL" != Xno; then
22312 ssl_msg=
22313
Elliott Hughes82be86d2017-09-20 17:00:17 -070022314 CLEANLDFLAGS="$LDFLAGS"
22315 CLEANCPPFLAGS="$CPPFLAGS"
22316 CLEANLIBS="$LIBS"
22317
22318 case $host in
22319 *-*-msys* | *-*-mingw*)
22320 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gdi32" >&5
22321$as_echo_n "checking for gdi32... " >&6; }
22322 my_ac_save_LIBS=$LIBS
22323 LIBS="-lgdi32 $LIBS"
22324 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22325/* end confdefs.h. */
22326#include <windef.h>
22327 #include <wingdi.h>
22328int main (void)
22329{
22330GdiFlush();
22331 ;
22332 return 0;
22333}
22334_ACEOF
22335if ac_fn_c_try_link "$LINENO"; then :
22336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22337$as_echo "yes" >&6; }
22338else
22339 LIBS=$my_ac_save_LIBS
22340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22341$as_echo "no" >&6; }
22342
22343fi
22344rm -f core conftest.err conftest.$ac_objext \
22345 conftest$ac_exeext conftest.$ac_ext
22346 ;;
22347 esac
22348
22349 case "$OPT_SSL" in
22350 yes)
22351 if test x$cross_compiling != xyes; then
22352 PKGTEST="yes"
22353 fi
22354 PREFIX_OPENSSL=/usr/local/ssl
22355 LIB_OPENSSL="$PREFIX_OPENSSL/lib$libsuff"
22356 ;;
22357 off)
22358 if test x$cross_compiling != xyes; then
22359 PKGTEST="yes"
22360 fi
22361 PREFIX_OPENSSL=
22362 ;;
22363 *)
22364 PKGTEST="no"
22365 PREFIX_OPENSSL=$OPT_SSL
22366
22367 OPENSSL_PCDIR="$OPT_SSL/lib/pkgconfig"
Elliott Hughes82be86d2017-09-20 17:00:17 -070022368 if test -f "$OPENSSL_PCDIR/openssl.pc"; then
Elliott Hughes72d948d2018-08-03 14:37:21 -070022369 { $as_echo "$as_me:${as_lineno-$LINENO}: PKG_CONFIG_LIBDIR will be set to \"$OPENSSL_PCDIR\"" >&5
22370$as_echo "$as_me: PKG_CONFIG_LIBDIR will be set to \"$OPENSSL_PCDIR\"" >&6;}
Elliott Hughes82be86d2017-09-20 17:00:17 -070022371 PKGTEST="yes"
Elliott Hughes72d948d2018-08-03 14:37:21 -070022372 elif test ! -f "$PREFIX_OPENSSL/include/openssl/ssl.h"; then
22373 as_fn_error $? "$PREFIX_OPENSSL is a bad --with-ssl prefix!" "$LINENO" 5
Elliott Hughes82be86d2017-09-20 17:00:17 -070022374 fi
22375
22376 LIB_OPENSSL="$PREFIX_OPENSSL/lib$libsuff"
22377 if test "$PREFIX_OPENSSL" != "/usr" ; then
22378 SSL_LDFLAGS="-L$LIB_OPENSSL"
22379 SSL_CPPFLAGS="-I$PREFIX_OPENSSL/include"
22380 fi
22381 SSL_CPPFLAGS="$SSL_CPPFLAGS -I$PREFIX_OPENSSL/include/openssl"
22382 ;;
22383 esac
22384
22385 if test "$PKGTEST" = "yes"; then
22386
22387
22388 if test -n "$PKG_CONFIG"; then
22389 PKGCONFIG="$PKG_CONFIG"
22390 else
22391 if test -n "$ac_tool_prefix"; then
22392 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
22393set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
22394{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
22395$as_echo_n "checking for $ac_word... " >&6; }
22396if ${ac_cv_path_PKGCONFIG+:} false; then :
22397 $as_echo_n "(cached) " >&6
22398else
22399 case $PKGCONFIG in
22400 [\\/]* | ?:[\\/]*)
22401 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
22402 ;;
22403 *)
22404 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22405as_dummy="$PATH:/usr/bin:/usr/local/bin"
22406for as_dir in $as_dummy
22407do
22408 IFS=$as_save_IFS
22409 test -z "$as_dir" && as_dir=.
22410 for ac_exec_ext in '' $ac_executable_extensions; do
22411 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
22412 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
22413 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
22414 break 2
22415 fi
22416done
22417 done
22418IFS=$as_save_IFS
22419
22420 ;;
22421esac
22422fi
22423PKGCONFIG=$ac_cv_path_PKGCONFIG
22424if test -n "$PKGCONFIG"; then
22425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
22426$as_echo "$PKGCONFIG" >&6; }
22427else
22428 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22429$as_echo "no" >&6; }
22430fi
22431
22432
22433fi
22434if test -z "$ac_cv_path_PKGCONFIG"; then
22435 ac_pt_PKGCONFIG=$PKGCONFIG
22436 # Extract the first word of "pkg-config", so it can be a program name with args.
22437set dummy pkg-config; ac_word=$2
22438{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
22439$as_echo_n "checking for $ac_word... " >&6; }
22440if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
22441 $as_echo_n "(cached) " >&6
22442else
22443 case $ac_pt_PKGCONFIG in
22444 [\\/]* | ?:[\\/]*)
22445 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
22446 ;;
22447 *)
22448 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22449as_dummy="$PATH:/usr/bin:/usr/local/bin"
22450for as_dir in $as_dummy
22451do
22452 IFS=$as_save_IFS
22453 test -z "$as_dir" && as_dir=.
22454 for ac_exec_ext in '' $ac_executable_extensions; do
22455 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
22456 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
22457 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
22458 break 2
22459 fi
22460done
22461 done
22462IFS=$as_save_IFS
22463
22464 ;;
22465esac
22466fi
22467ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
22468if test -n "$ac_pt_PKGCONFIG"; then
22469 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
22470$as_echo "$ac_pt_PKGCONFIG" >&6; }
22471else
22472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22473$as_echo "no" >&6; }
22474fi
22475
22476 if test "x$ac_pt_PKGCONFIG" = x; then
22477 PKGCONFIG="no"
22478 else
22479 case $cross_compiling:$ac_tool_warned in
22480yes:)
22481{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
22482$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
22483ac_tool_warned=yes ;;
22484esac
22485 PKGCONFIG=$ac_pt_PKGCONFIG
22486 fi
22487else
22488 PKGCONFIG="$ac_cv_path_PKGCONFIG"
22489fi
22490
22491 fi
22492
22493 if test "x$PKGCONFIG" != "xno"; then
22494 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openssl options with pkg-config" >&5
22495$as_echo_n "checking for openssl options with pkg-config... " >&6; }
22496 itexists=`
22497 if test -n "$OPENSSL_PCDIR"; then
22498 PKG_CONFIG_LIBDIR="$OPENSSL_PCDIR"
22499 export PKG_CONFIG_LIBDIR
22500 fi
22501 $PKGCONFIG --exists openssl >/dev/null 2>&1 && echo 1`
22502
22503 if test -z "$itexists"; then
22504 PKGCONFIG="no"
22505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22506$as_echo "no" >&6; }
22507 else
22508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
22509$as_echo "found" >&6; }
22510 fi
22511 fi
22512
22513
22514 if test "$PKGCONFIG" != "no" ; then
22515 SSL_LIBS=`
22516 if test -n "$OPENSSL_PCDIR"; then
22517 PKG_CONFIG_LIBDIR="$OPENSSL_PCDIR"
22518 export PKG_CONFIG_LIBDIR
22519 fi
Haibo Huang21926d52019-01-08 14:27:10 -080022520 $PKGCONFIG --libs-only-l --libs-only-other openssl 2>/dev/null`
Elliott Hughes82be86d2017-09-20 17:00:17 -070022521
22522 SSL_LDFLAGS=`
22523 if test -n "$OPENSSL_PCDIR"; then
22524 PKG_CONFIG_LIBDIR="$OPENSSL_PCDIR"
22525 export PKG_CONFIG_LIBDIR
22526 fi
22527 $PKGCONFIG --libs-only-L openssl 2>/dev/null`
22528
22529 SSL_CPPFLAGS=`
22530 if test -n "$OPENSSL_PCDIR"; then
22531 PKG_CONFIG_LIBDIR="$OPENSSL_PCDIR"
22532 export PKG_CONFIG_LIBDIR
22533 fi
22534 $PKGCONFIG --cflags-only-I openssl 2>/dev/null`
22535
22536
22537 { $as_echo "$as_me:${as_lineno-$LINENO}: pkg-config: SSL_LIBS: \"$SSL_LIBS\"" >&5
22538$as_echo "$as_me: pkg-config: SSL_LIBS: \"$SSL_LIBS\"" >&6;}
22539 { $as_echo "$as_me:${as_lineno-$LINENO}: pkg-config: SSL_LDFLAGS: \"$SSL_LDFLAGS\"" >&5
22540$as_echo "$as_me: pkg-config: SSL_LDFLAGS: \"$SSL_LDFLAGS\"" >&6;}
22541 { $as_echo "$as_me:${as_lineno-$LINENO}: pkg-config: SSL_CPPFLAGS: \"$SSL_CPPFLAGS\"" >&5
22542$as_echo "$as_me: pkg-config: SSL_CPPFLAGS: \"$SSL_CPPFLAGS\"" >&6;}
22543
22544 LIB_OPENSSL=`echo $SSL_LDFLAGS | sed -e 's/-L//g'`
22545
22546 LIBS="$SSL_LIBS $LIBS"
22547 fi
22548 fi
22549
22550 CPPFLAGS="$CPPFLAGS $SSL_CPPFLAGS"
22551 LDFLAGS="$LDFLAGS $SSL_LDFLAGS"
22552
22553 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HMAC_Update in -lcrypto" >&5
22554$as_echo_n "checking for HMAC_Update in -lcrypto... " >&6; }
22555if ${ac_cv_lib_crypto_HMAC_Update+:} false; then :
22556 $as_echo_n "(cached) " >&6
22557else
22558 ac_check_lib_save_LIBS=$LIBS
22559LIBS="-lcrypto $LIBS"
22560cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22561/* end confdefs.h. */
22562
22563
22564#ifdef __cplusplus
22565extern "C"
22566#endif
22567char HMAC_Update ();
22568int main (void)
22569{
22570return HMAC_Update ();
22571 ;
22572 return 0;
22573}
22574_ACEOF
22575if ac_fn_c_try_link "$LINENO"; then :
22576 ac_cv_lib_crypto_HMAC_Update=yes
22577else
22578 ac_cv_lib_crypto_HMAC_Update=no
22579fi
22580rm -f core conftest.err conftest.$ac_objext \
22581 conftest$ac_exeext conftest.$ac_ext
22582LIBS=$ac_check_lib_save_LIBS
22583fi
22584{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_HMAC_Update" >&5
22585$as_echo "$ac_cv_lib_crypto_HMAC_Update" >&6; }
22586if test "x$ac_cv_lib_crypto_HMAC_Update" = xyes; then :
22587
22588 HAVECRYPTO="yes"
22589 LIBS="-lcrypto $LIBS"
22590
22591else
22592
22593 LDFLAGS="$CLEANLDFLAGS -L$LIB_OPENSSL"
Elliott Hughesb1ef70f2018-10-30 11:28:38 -070022594 if test "$PKGCONFIG" = "no" ; then
22595 # only set this if pkg-config wasn't used
22596 CPPFLAGS="$CLEANCPPFLAGS -I$PREFIX_OPENSSL/include/openssl -I$PREFIX_OPENSSL/include"
22597 fi
Elliott Hughes82be86d2017-09-20 17:00:17 -070022598 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HMAC_Init_ex in -lcrypto" >&5
22599$as_echo_n "checking for HMAC_Init_ex in -lcrypto... " >&6; }
22600if ${ac_cv_lib_crypto_HMAC_Init_ex+:} false; then :
22601 $as_echo_n "(cached) " >&6
22602else
22603 ac_check_lib_save_LIBS=$LIBS
22604LIBS="-lcrypto $LIBS"
22605cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22606/* end confdefs.h. */
22607
22608
22609#ifdef __cplusplus
22610extern "C"
22611#endif
22612char HMAC_Init_ex ();
22613int main (void)
22614{
22615return HMAC_Init_ex ();
22616 ;
22617 return 0;
22618}
22619_ACEOF
22620if ac_fn_c_try_link "$LINENO"; then :
22621 ac_cv_lib_crypto_HMAC_Init_ex=yes
22622else
22623 ac_cv_lib_crypto_HMAC_Init_ex=no
22624fi
22625rm -f core conftest.err conftest.$ac_objext \
22626 conftest$ac_exeext conftest.$ac_ext
22627LIBS=$ac_check_lib_save_LIBS
22628fi
22629{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_HMAC_Init_ex" >&5
22630$as_echo "$ac_cv_lib_crypto_HMAC_Init_ex" >&6; }
22631if test "x$ac_cv_lib_crypto_HMAC_Init_ex" = xyes; then :
22632
22633 HAVECRYPTO="yes"
22634 LIBS="-lcrypto $LIBS"
22635else
22636
22637
22638 { $as_echo "$as_me:${as_lineno-$LINENO}: checking OpenSSL linking with -ldl" >&5
22639$as_echo_n "checking OpenSSL linking with -ldl... " >&6; }
Elliott Hughes72d948d2018-08-03 14:37:21 -070022640 LIBS="$CLEANLIBS -lcrypto -ldl"
Elliott Hughes82be86d2017-09-20 17:00:17 -070022641 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22642/* end confdefs.h. */
22643
22644 #include <openssl/err.h>
22645
22646int main (void)
22647{
22648
22649 ERR_clear_error();
22650
22651 ;
22652 return 0;
22653}
22654_ACEOF
22655if ac_fn_c_try_link "$LINENO"; then :
22656
22657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22658$as_echo "yes" >&6; }
22659 HAVECRYPTO="yes"
22660
22661else
22662
22663 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22664$as_echo "no" >&6; }
22665
22666 { $as_echo "$as_me:${as_lineno-$LINENO}: checking OpenSSL linking with -ldl and -lpthread" >&5
22667$as_echo_n "checking OpenSSL linking with -ldl and -lpthread... " >&6; }
Elliott Hughes72d948d2018-08-03 14:37:21 -070022668 LIBS="$CLEANLIBS -lcrypto -ldl -lpthread"
Elliott Hughes82be86d2017-09-20 17:00:17 -070022669 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22670/* end confdefs.h. */
22671
22672 #include <openssl/err.h>
22673
22674int main (void)
22675{
22676
22677 ERR_clear_error();
22678
22679 ;
22680 return 0;
22681}
22682_ACEOF
22683if ac_fn_c_try_link "$LINENO"; then :
22684
22685 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22686$as_echo "yes" >&6; }
22687 HAVECRYPTO="yes"
22688
22689else
22690
22691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22692$as_echo "no" >&6; }
22693 LDFLAGS="$CLEANLDFLAGS"
22694 CPPFLAGS="$CLEANCPPFLAGS"
22695 LIBS="$CLEANLIBS"
22696
22697
22698fi
22699rm -f core conftest.err conftest.$ac_objext \
22700 conftest$ac_exeext conftest.$ac_ext
22701
22702
22703fi
22704rm -f core conftest.err conftest.$ac_objext \
22705 conftest$ac_exeext conftest.$ac_ext
22706
22707
22708fi
22709
22710
22711fi
22712
22713
22714 if test X"$HAVECRYPTO" = X"yes"; then
22715
22716 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SSL_connect in -lssl" >&5
22717$as_echo_n "checking for SSL_connect in -lssl... " >&6; }
22718if ${ac_cv_lib_ssl_SSL_connect+:} false; then :
22719 $as_echo_n "(cached) " >&6
22720else
22721 ac_check_lib_save_LIBS=$LIBS
22722LIBS="-lssl $LIBS"
22723cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22724/* end confdefs.h. */
22725
22726
22727#ifdef __cplusplus
22728extern "C"
22729#endif
22730char SSL_connect ();
22731int main (void)
22732{
22733return SSL_connect ();
22734 ;
22735 return 0;
22736}
22737_ACEOF
22738if ac_fn_c_try_link "$LINENO"; then :
22739 ac_cv_lib_ssl_SSL_connect=yes
22740else
22741 ac_cv_lib_ssl_SSL_connect=no
22742fi
22743rm -f core conftest.err conftest.$ac_objext \
22744 conftest$ac_exeext conftest.$ac_ext
22745LIBS=$ac_check_lib_save_LIBS
22746fi
22747{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ssl_SSL_connect" >&5
22748$as_echo "$ac_cv_lib_ssl_SSL_connect" >&6; }
22749if test "x$ac_cv_lib_ssl_SSL_connect" = xyes; then :
22750 cat >>confdefs.h <<_ACEOF
22751#define HAVE_LIBSSL 1
22752_ACEOF
22753
22754 LIBS="-lssl $LIBS"
22755
22756fi
22757
22758
22759 if test "$ac_cv_lib_ssl_SSL_connect" != yes; then
22760 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssl with RSAglue/rsaref libs in use" >&5
22761$as_echo_n "checking for ssl with RSAglue/rsaref libs in use... " >&6; };
22762 OLIBS=$LIBS
22763 LIBS="-lRSAglue -lrsaref $LIBS"
22764 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SSL_connect in -lssl" >&5
22765$as_echo_n "checking for SSL_connect in -lssl... " >&6; }
22766if ${ac_cv_lib_ssl_SSL_connect+:} false; then :
22767 $as_echo_n "(cached) " >&6
22768else
22769 ac_check_lib_save_LIBS=$LIBS
22770LIBS="-lssl $LIBS"
22771cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22772/* end confdefs.h. */
22773
22774
22775#ifdef __cplusplus
22776extern "C"
22777#endif
22778char SSL_connect ();
22779int main (void)
22780{
22781return SSL_connect ();
22782 ;
22783 return 0;
22784}
22785_ACEOF
22786if ac_fn_c_try_link "$LINENO"; then :
22787 ac_cv_lib_ssl_SSL_connect=yes
22788else
22789 ac_cv_lib_ssl_SSL_connect=no
22790fi
22791rm -f core conftest.err conftest.$ac_objext \
22792 conftest$ac_exeext conftest.$ac_ext
22793LIBS=$ac_check_lib_save_LIBS
22794fi
22795{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ssl_SSL_connect" >&5
22796$as_echo "$ac_cv_lib_ssl_SSL_connect" >&6; }
22797if test "x$ac_cv_lib_ssl_SSL_connect" = xyes; then :
22798 cat >>confdefs.h <<_ACEOF
22799#define HAVE_LIBSSL 1
22800_ACEOF
22801
22802 LIBS="-lssl $LIBS"
22803
22804fi
22805
22806 if test "$ac_cv_lib_ssl_SSL_connect" != yes; then
22807 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22808$as_echo "no" >&6; }
22809 LIBS=$OLIBS
22810 else
22811 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22812$as_echo "yes" >&6; }
22813 fi
22814
22815 else
22816
22817 for ac_header in openssl/x509.h openssl/rsa.h openssl/crypto.h \
22818 openssl/pem.h openssl/ssl.h openssl/err.h
22819do :
22820 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
22821ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
22822if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
22823 cat >>confdefs.h <<_ACEOF
22824#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
22825_ACEOF
Alex Deymo486467e2017-12-19 19:04:07 +010022826 ssl_msg="OpenSSL"
22827 test openssl != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
Elliott Hughes82be86d2017-09-20 17:00:17 -070022828 OPENSSL_ENABLED=1
22829
22830$as_echo "#define USE_OPENSSL 1" >>confdefs.h
22831
22832fi
22833
22834done
22835
22836
22837 if test $ac_cv_header_openssl_x509_h = no; then
22838 for ac_header in x509.h rsa.h crypto.h pem.h ssl.h err.h
22839do :
22840 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
22841ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
22842if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
22843 cat >>confdefs.h <<_ACEOF
22844#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
22845_ACEOF
22846
22847fi
22848
22849done
22850
22851
22852 if test $ac_cv_header_x509_h = yes &&
22853 test $ac_cv_header_crypto_h = yes &&
22854 test $ac_cv_header_ssl_h = yes; then
Alex Deymo486467e2017-12-19 19:04:07 +010022855 ssl_msg="OpenSSL"
Elliott Hughes82be86d2017-09-20 17:00:17 -070022856 OPENSSL_ENABLED=1
22857 fi
22858 fi
22859 fi
22860
Alex Deymo486467e2017-12-19 19:04:07 +010022861 if test X"$OPENSSL_ENABLED" != X"1"; then
Elliott Hughes82be86d2017-09-20 17:00:17 -070022862 LIBS="$CLEANLIBS"
22863 fi
22864
22865 if test X"$OPT_SSL" != Xoff &&
22866 test "$OPENSSL_ENABLED" != "1"; then
22867 as_fn_error $? "OpenSSL libs and/or directories were not found where specified!" "$LINENO" 5
22868 fi
22869 fi
22870
22871 if test X"$OPENSSL_ENABLED" = X"1"; then
Elliott Hughes82be86d2017-09-20 17:00:17 -070022872
22873 for ac_func in RAND_egd \
Haibo Huang51d9d882019-02-06 01:36:06 -080022874 SSLv2_client_method \
22875 OpenSSL_version
Elliott Hughes82be86d2017-09-20 17:00:17 -070022876do :
22877 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
22878ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
22879if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
22880 cat >>confdefs.h <<_ACEOF
22881#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
22882_ACEOF
22883
22884fi
22885done
22886
22887
22888 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BoringSSL" >&5
22889$as_echo_n "checking for BoringSSL... " >&6; }
22890 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22891/* end confdefs.h. */
22892
22893
22894 #include <openssl/base.h>
22895
22896int main (void)
22897{
22898
22899 #ifndef OPENSSL_IS_BORINGSSL
22900 #error not boringssl
22901 #endif
22902
22903 ;
22904 return 0;
22905}
22906
22907_ACEOF
22908if ac_fn_c_try_compile "$LINENO"; then :
22909
22910 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22911$as_echo "yes" >&6; }
22912
22913cat >>confdefs.h <<_ACEOF
22914#define HAVE_BORINGSSL 1
22915_ACEOF
22916
Alex Deymo486467e2017-12-19 19:04:07 +010022917 ssl_msg="BoringSSL"
Elliott Hughes82be86d2017-09-20 17:00:17 -070022918
22919else
22920
22921 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22922$as_echo "no" >&6; }
22923
22924fi
22925rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22926
22927 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libressl" >&5
22928$as_echo_n "checking for libressl... " >&6; }
22929 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22930/* end confdefs.h. */
22931
22932
22933#include <openssl/opensslv.h>
22934
22935int main (void)
22936{
22937
22938 int dummy = LIBRESSL_VERSION_NUMBER;
22939
22940 ;
22941 return 0;
22942}
22943
22944_ACEOF
22945if ac_fn_c_try_compile "$LINENO"; then :
22946
22947 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22948$as_echo "yes" >&6; }
22949
22950cat >>confdefs.h <<_ACEOF
22951#define HAVE_LIBRESSL 1
22952_ACEOF
22953
Alex Deymo486467e2017-12-19 19:04:07 +010022954 ssl_msg="libressl"
Elliott Hughes82be86d2017-09-20 17:00:17 -070022955
22956else
22957
22958 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22959$as_echo "no" >&6; }
22960
22961fi
22962rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22963 fi
22964
22965 if test "$OPENSSL_ENABLED" = "1"; then
22966 if test -n "$LIB_OPENSSL"; then
22967 if test "x$cross_compiling" != "xyes"; then
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070022968 CURL_LIBRARY_PATH="$CURL_LIBRARY_PATH:$LIB_OPENSSL"
22969 export CURL_LIBRARY_PATH
22970 { $as_echo "$as_me:${as_lineno-$LINENO}: Added $LIB_OPENSSL to CURL_LIBRARY_PATH" >&5
22971$as_echo "$as_me: Added $LIB_OPENSSL to CURL_LIBRARY_PATH" >&6;}
Elliott Hughes82be86d2017-09-20 17:00:17 -070022972 fi
22973 fi
22974
22975 #
22976
22977 #
22978 tst_api="unknown"
22979 #
22980 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OpenSSL headers version" >&5
22981$as_echo_n "checking for OpenSSL headers version... " >&6; }
22982
22983 OLDCPPFLAGS=$CPPFLAGS
22984 # CPPPFLAG comes from CURL_CPP_P
22985 CPPFLAGS="$CPPFLAGS $CPPPFLAG"
22986 if test -z "$SED"; then
22987 as_fn_error $? "SED not set. Cannot continue without SED being set." "$LINENO" 5
22988 fi
22989 if test -z "$GREP"; then
22990 as_fn_error $? "GREP not set. Cannot continue without GREP being set." "$LINENO" 5
22991 fi
22992
22993 tmp_exp=""
22994 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22995/* end confdefs.h. */
22996
22997
22998# ifdef USE_OPENSSL
22999# include <openssl/crypto.h>
23000# else
23001# include <crypto.h>
23002# endif
23003
23004#ifdef OPENSSL_VERSION_NUMBER
23005CURL_DEF_TOKEN OPENSSL_VERSION_NUMBER
23006#endif
23007
23008
23009_ACEOF
23010if ac_fn_c_try_cpp "$LINENO"; then :
23011
23012 tmp_exp=`eval "$ac_cpp conftest.$ac_ext" 2>/dev/null | \
23013 "$GREP" CURL_DEF_TOKEN 2>/dev/null | \
23014 "$SED" 's/.*CURL_DEF_TOKEN[ ][ ]*//' 2>/dev/null | \
23015 "$SED" 's/["][ ]*["]//g' 2>/dev/null`
23016 if test -z "$tmp_exp" || test "$tmp_exp" = "OPENSSL_VERSION_NUMBER"; then
23017 tmp_exp=""
23018 fi
23019
23020fi
23021rm -f conftest.err conftest.i conftest.$ac_ext
23022 if test -z "$tmp_exp"; then
23023 curl_cv_have_def_OPENSSL_VERSION_NUMBER=no
23024
23025 else
23026 curl_cv_have_def_OPENSSL_VERSION_NUMBER=yes
23027 curl_cv_def_OPENSSL_VERSION_NUMBER=$tmp_exp
23028
23029 fi
23030 CPPFLAGS=$OLDCPPFLAGS
23031
23032 if test "$curl_cv_have_def_OPENSSL_VERSION_NUMBER" = "yes"; then
23033 tst_verlen=`expr "$curl_cv_def_OPENSSL_VERSION_NUMBER" : '.*'`
23034 case "x$tst_verlen" in
23035 x6)
23036 tst_vermaj=`echo $curl_cv_def_OPENSSL_VERSION_NUMBER | cut -c 3`
23037 tst_vermin=`echo $curl_cv_def_OPENSSL_VERSION_NUMBER | cut -c 4`
23038 tst_verfix=`echo $curl_cv_def_OPENSSL_VERSION_NUMBER | cut -c 5`
23039 tst_api=0x$tst_vermaj$tst_vermin$tst_verfix
23040 ;;
23041 x11|x10)
23042 tst_vermaj=`echo $curl_cv_def_OPENSSL_VERSION_NUMBER | cut -c 3`
23043 tst_vermin=`echo $curl_cv_def_OPENSSL_VERSION_NUMBER | cut -c 5`
23044 tst_verfix=`echo $curl_cv_def_OPENSSL_VERSION_NUMBER | cut -c 7`
23045 tst_api=0x$tst_vermaj$tst_vermin$tst_verfix
23046 ;;
23047 *)
23048 tst_api="unknown"
23049 ;;
23050 esac
23051 case $tst_api in
Elliott Hughescac39802018-04-27 16:19:43 -070023052 0x111) tst_show="1.1.1" ;;
Elliott Hughes82be86d2017-09-20 17:00:17 -070023053 0x110) tst_show="1.1.0" ;;
23054 0x102) tst_show="1.0.2" ;;
23055 0x101) tst_show="1.0.1" ;;
23056 0x100) tst_show="1.0.0" ;;
23057 0x099) tst_show="0.9.9" ;;
23058 0x098) tst_show="0.9.8" ;;
23059 0x097) tst_show="0.9.7" ;;
23060 0x096) tst_show="0.9.6" ;;
23061 0x095) tst_show="0.9.5" ;;
23062 0x094) tst_show="0.9.4" ;;
23063 0x093) tst_show="0.9.3" ;;
23064 0x092) tst_show="0.9.2" ;;
23065 0x091) tst_show="0.9.1" ;;
23066 *) tst_show="unknown" ;;
23067 esac
23068 tst_show="$tst_show - $curl_cv_def_OPENSSL_VERSION_NUMBER"
23069 else
23070 tst_show="unknown"
23071 fi
23072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tst_show" >&5
23073$as_echo "$tst_show" >&6; }
23074 #
23075 curl_openssl_api_headers=$tst_api
23076
23077
23078 #
23079 tst_api="unknown"
23080 #
23081 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OpenSSL library version" >&5
23082$as_echo_n "checking for OpenSSL library version... " >&6; }
23083 if test "$tst_api" = "unknown"; then
Elliott Hughescac39802018-04-27 16:19:43 -070023084 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23085/* end confdefs.h. */
23086
23087
23088#define ERR_clear_last_mark innocuous_ERR_clear_last_mark
23089#ifdef __STDC__
23090# include <limits.h>
23091#else
23092# include <assert.h>
23093#endif
23094#undef ERR_clear_last_mark
23095#ifdef __cplusplus
23096extern "C"
23097#endif
23098char ERR_clear_last_mark ();
23099#if defined __stub_ERR_clear_last_mark || defined __stub___ERR_clear_last_mark
23100choke me
23101#endif
23102
23103int main (void)
23104{
23105return ERR_clear_last_mark ();
23106 ;
23107 return 0;
23108}
23109
23110_ACEOF
23111if ac_fn_c_try_link "$LINENO"; then :
23112
23113 tst_api="0x111"
23114
23115fi
23116rm -f core conftest.err conftest.$ac_objext \
23117 conftest$ac_exeext conftest.$ac_ext
23118 fi
23119 if test "$tst_api" = "unknown"; then
Elliott Hughes82be86d2017-09-20 17:00:17 -070023120 case $host in
23121 *-*-vms*)
23122 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23123/* end confdefs.h. */
23124
23125
23126#define SSL_CTX_set_not_resumbl_sess_cb innocuous_SSL_CTX_set_not_resumbl_sess_cb
23127#ifdef __STDC__
23128# include <limits.h>
23129#else
23130# include <assert.h>
23131#endif
23132#undef SSL_CTX_set_not_resumbl_sess_cb
23133#ifdef __cplusplus
23134extern "C"
23135#endif
23136char SSL_CTX_set_not_resumbl_sess_cb ();
23137#if defined __stub_SSL_CTX_set_not_resumbl_sess_cb || defined __stub___SSL_CTX_set_not_resumbl_sess_cb
23138choke me
23139#endif
23140
23141int main (void)
23142{
23143return SSL_CTX_set_not_resumbl_sess_cb ();
23144 ;
23145 return 0;
23146}
23147
23148_ACEOF
23149if ac_fn_c_try_link "$LINENO"; then :
23150
23151 tst_api="0x110"
23152
23153fi
23154rm -f core conftest.err conftest.$ac_objext \
23155 conftest$ac_exeext conftest.$ac_ext
23156 ;;
23157 *)
23158 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23159/* end confdefs.h. */
23160
23161
23162#define SSL_CTX_set_not_resumable_session_callback innocuous_SSL_CTX_set_not_resumable_session_callback
23163#ifdef __STDC__
23164# include <limits.h>
23165#else
23166# include <assert.h>
23167#endif
23168#undef SSL_CTX_set_not_resumable_session_callback
23169#ifdef __cplusplus
23170extern "C"
23171#endif
23172char SSL_CTX_set_not_resumable_session_callback ();
23173#if defined __stub_SSL_CTX_set_not_resumable_session_callback || defined __stub___SSL_CTX_set_not_resumable_session_callback
23174choke me
23175#endif
23176
23177int main (void)
23178{
23179return SSL_CTX_set_not_resumable_session_callback ();
23180 ;
23181 return 0;
23182}
23183
23184_ACEOF
23185if ac_fn_c_try_link "$LINENO"; then :
23186
23187 tst_api="0x110"
23188
23189fi
23190rm -f core conftest.err conftest.$ac_objext \
23191 conftest$ac_exeext conftest.$ac_ext
23192 ;;
23193 esac
23194 fi
23195 if test "$tst_api" = "unknown"; then
23196 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23197/* end confdefs.h. */
23198
23199
23200#define SSL_CONF_CTX_new innocuous_SSL_CONF_CTX_new
23201#ifdef __STDC__
23202# include <limits.h>
23203#else
23204# include <assert.h>
23205#endif
23206#undef SSL_CONF_CTX_new
23207#ifdef __cplusplus
23208extern "C"
23209#endif
23210char SSL_CONF_CTX_new ();
23211#if defined __stub_SSL_CONF_CTX_new || defined __stub___SSL_CONF_CTX_new
23212choke me
23213#endif
23214
23215int main (void)
23216{
23217return SSL_CONF_CTX_new ();
23218 ;
23219 return 0;
23220}
23221
23222_ACEOF
23223if ac_fn_c_try_link "$LINENO"; then :
23224
23225 tst_api="0x102"
23226
23227fi
23228rm -f core conftest.err conftest.$ac_objext \
23229 conftest$ac_exeext conftest.$ac_ext
23230 fi
23231 if test "$tst_api" = "unknown"; then
23232 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23233/* end confdefs.h. */
23234
23235
23236#define SSL_renegotiate_abbreviated innocuous_SSL_renegotiate_abbreviated
23237#ifdef __STDC__
23238# include <limits.h>
23239#else
23240# include <assert.h>
23241#endif
23242#undef SSL_renegotiate_abbreviated
23243#ifdef __cplusplus
23244extern "C"
23245#endif
23246char SSL_renegotiate_abbreviated ();
23247#if defined __stub_SSL_renegotiate_abbreviated || defined __stub___SSL_renegotiate_abbreviated
23248choke me
23249#endif
23250
23251int main (void)
23252{
23253return SSL_renegotiate_abbreviated ();
23254 ;
23255 return 0;
23256}
23257
23258_ACEOF
23259if ac_fn_c_try_link "$LINENO"; then :
23260
23261 tst_api="0x101"
23262
23263fi
23264rm -f core conftest.err conftest.$ac_objext \
23265 conftest$ac_exeext conftest.$ac_ext
23266 fi
23267 if test "$tst_api" = "unknown"; then
23268 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23269/* end confdefs.h. */
23270
23271
23272#define OBJ_add_sigid innocuous_OBJ_add_sigid
23273#ifdef __STDC__
23274# include <limits.h>
23275#else
23276# include <assert.h>
23277#endif
23278#undef OBJ_add_sigid
23279#ifdef __cplusplus
23280extern "C"
23281#endif
23282char OBJ_add_sigid ();
23283#if defined __stub_OBJ_add_sigid || defined __stub___OBJ_add_sigid
23284choke me
23285#endif
23286
23287int main (void)
23288{
23289return OBJ_add_sigid ();
23290 ;
23291 return 0;
23292}
23293
23294_ACEOF
23295if ac_fn_c_try_link "$LINENO"; then :
23296
23297 tst_api="0x100"
23298
23299fi
23300rm -f core conftest.err conftest.$ac_objext \
23301 conftest$ac_exeext conftest.$ac_ext
23302 fi
23303 if test "$tst_api" = "unknown"; then
23304 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23305/* end confdefs.h. */
23306
23307
23308#define ERR_set_mark innocuous_ERR_set_mark
23309#ifdef __STDC__
23310# include <limits.h>
23311#else
23312# include <assert.h>
23313#endif
23314#undef ERR_set_mark
23315#ifdef __cplusplus
23316extern "C"
23317#endif
23318char ERR_set_mark ();
23319#if defined __stub_ERR_set_mark || defined __stub___ERR_set_mark
23320choke me
23321#endif
23322
23323int main (void)
23324{
23325return ERR_set_mark ();
23326 ;
23327 return 0;
23328}
23329
23330_ACEOF
23331if ac_fn_c_try_link "$LINENO"; then :
23332
23333 tst_api="0x098"
23334
23335fi
23336rm -f core conftest.err conftest.$ac_objext \
23337 conftest$ac_exeext conftest.$ac_ext
23338 fi
23339 if test "$tst_api" = "unknown"; then
23340 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23341/* end confdefs.h. */
23342
23343
23344#define ERR_peek_last_error innocuous_ERR_peek_last_error
23345#ifdef __STDC__
23346# include <limits.h>
23347#else
23348# include <assert.h>
23349#endif
23350#undef ERR_peek_last_error
23351#ifdef __cplusplus
23352extern "C"
23353#endif
23354char ERR_peek_last_error ();
23355#if defined __stub_ERR_peek_last_error || defined __stub___ERR_peek_last_error
23356choke me
23357#endif
23358
23359int main (void)
23360{
23361return ERR_peek_last_error ();
23362 ;
23363 return 0;
23364}
23365
23366_ACEOF
23367if ac_fn_c_try_link "$LINENO"; then :
23368
23369 tst_api="0x097"
23370
23371fi
23372rm -f core conftest.err conftest.$ac_objext \
23373 conftest$ac_exeext conftest.$ac_ext
23374 fi
23375 if test "$tst_api" = "unknown"; then
23376 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23377/* end confdefs.h. */
23378
23379
23380#define c2i_ASN1_OBJECT innocuous_c2i_ASN1_OBJECT
23381#ifdef __STDC__
23382# include <limits.h>
23383#else
23384# include <assert.h>
23385#endif
23386#undef c2i_ASN1_OBJECT
23387#ifdef __cplusplus
23388extern "C"
23389#endif
23390char c2i_ASN1_OBJECT ();
23391#if defined __stub_c2i_ASN1_OBJECT || defined __stub___c2i_ASN1_OBJECT
23392choke me
23393#endif
23394
23395int main (void)
23396{
23397return c2i_ASN1_OBJECT ();
23398 ;
23399 return 0;
23400}
23401
23402_ACEOF
23403if ac_fn_c_try_link "$LINENO"; then :
23404
23405 tst_api="0x096"
23406
23407fi
23408rm -f core conftest.err conftest.$ac_objext \
23409 conftest$ac_exeext conftest.$ac_ext
23410 fi
23411 if test "$tst_api" = "unknown"; then
23412 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23413/* end confdefs.h. */
23414
23415
23416#define SSL_CTX_set_purpose innocuous_SSL_CTX_set_purpose
23417#ifdef __STDC__
23418# include <limits.h>
23419#else
23420# include <assert.h>
23421#endif
23422#undef SSL_CTX_set_purpose
23423#ifdef __cplusplus
23424extern "C"
23425#endif
23426char SSL_CTX_set_purpose ();
23427#if defined __stub_SSL_CTX_set_purpose || defined __stub___SSL_CTX_set_purpose
23428choke me
23429#endif
23430
23431int main (void)
23432{
23433return SSL_CTX_set_purpose ();
23434 ;
23435 return 0;
23436}
23437
23438_ACEOF
23439if ac_fn_c_try_link "$LINENO"; then :
23440
23441 tst_api="0x095"
23442
23443fi
23444rm -f core conftest.err conftest.$ac_objext \
23445 conftest$ac_exeext conftest.$ac_ext
23446 fi
23447 if test "$tst_api" = "unknown"; then
23448 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23449/* end confdefs.h. */
23450
23451
23452#define OBJ_obj2txt innocuous_OBJ_obj2txt
23453#ifdef __STDC__
23454# include <limits.h>
23455#else
23456# include <assert.h>
23457#endif
23458#undef OBJ_obj2txt
23459#ifdef __cplusplus
23460extern "C"
23461#endif
23462char OBJ_obj2txt ();
23463#if defined __stub_OBJ_obj2txt || defined __stub___OBJ_obj2txt
23464choke me
23465#endif
23466
23467int main (void)
23468{
23469return OBJ_obj2txt ();
23470 ;
23471 return 0;
23472}
23473
23474_ACEOF
23475if ac_fn_c_try_link "$LINENO"; then :
23476
23477 tst_api="0x094"
23478
23479fi
23480rm -f core conftest.err conftest.$ac_objext \
23481 conftest$ac_exeext conftest.$ac_ext
23482 fi
23483 if test "$tst_api" = "unknown"; then
23484 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23485/* end confdefs.h. */
23486
23487
23488#define SSL_get_verify_depth innocuous_SSL_get_verify_depth
23489#ifdef __STDC__
23490# include <limits.h>
23491#else
23492# include <assert.h>
23493#endif
23494#undef SSL_get_verify_depth
23495#ifdef __cplusplus
23496extern "C"
23497#endif
23498char SSL_get_verify_depth ();
23499#if defined __stub_SSL_get_verify_depth || defined __stub___SSL_get_verify_depth
23500choke me
23501#endif
23502
23503int main (void)
23504{
23505return SSL_get_verify_depth ();
23506 ;
23507 return 0;
23508}
23509
23510_ACEOF
23511if ac_fn_c_try_link "$LINENO"; then :
23512
23513 tst_api="0x093"
23514
23515fi
23516rm -f core conftest.err conftest.$ac_objext \
23517 conftest$ac_exeext conftest.$ac_ext
23518 fi
23519 if test "$tst_api" = "unknown"; then
23520 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23521/* end confdefs.h. */
23522
23523
23524#define SSL_library_init innocuous_SSL_library_init
23525#ifdef __STDC__
23526# include <limits.h>
23527#else
23528# include <assert.h>
23529#endif
23530#undef SSL_library_init
23531#ifdef __cplusplus
23532extern "C"
23533#endif
23534char SSL_library_init ();
23535#if defined __stub_SSL_library_init || defined __stub___SSL_library_init
23536choke me
23537#endif
23538
23539int main (void)
23540{
23541return SSL_library_init ();
23542 ;
23543 return 0;
23544}
23545
23546_ACEOF
23547if ac_fn_c_try_link "$LINENO"; then :
23548
23549 tst_api="0x092"
23550
23551fi
23552rm -f core conftest.err conftest.$ac_objext \
23553 conftest$ac_exeext conftest.$ac_ext
23554 fi
23555 if test "$tst_api" = "unknown"; then
23556 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23557/* end confdefs.h. */
23558
23559
23560#define SSL_CTX_set_cipher_list innocuous_SSL_CTX_set_cipher_list
23561#ifdef __STDC__
23562# include <limits.h>
23563#else
23564# include <assert.h>
23565#endif
23566#undef SSL_CTX_set_cipher_list
23567#ifdef __cplusplus
23568extern "C"
23569#endif
23570char SSL_CTX_set_cipher_list ();
23571#if defined __stub_SSL_CTX_set_cipher_list || defined __stub___SSL_CTX_set_cipher_list
23572choke me
23573#endif
23574
23575int main (void)
23576{
23577return SSL_CTX_set_cipher_list ();
23578 ;
23579 return 0;
23580}
23581
23582_ACEOF
23583if ac_fn_c_try_link "$LINENO"; then :
23584
23585 tst_api="0x091"
23586
23587fi
23588rm -f core conftest.err conftest.$ac_objext \
23589 conftest$ac_exeext conftest.$ac_ext
23590 fi
23591 case $tst_api in
Elliott Hughescac39802018-04-27 16:19:43 -070023592 0x111) tst_show="1.1.1" ;;
Elliott Hughes82be86d2017-09-20 17:00:17 -070023593 0x110) tst_show="1.1.0" ;;
23594 0x102) tst_show="1.0.2" ;;
23595 0x101) tst_show="1.0.1" ;;
23596 0x100) tst_show="1.0.0" ;;
23597 0x099) tst_show="0.9.9" ;;
23598 0x098) tst_show="0.9.8" ;;
23599 0x097) tst_show="0.9.7" ;;
23600 0x096) tst_show="0.9.6" ;;
23601 0x095) tst_show="0.9.5" ;;
23602 0x094) tst_show="0.9.4" ;;
23603 0x093) tst_show="0.9.3" ;;
23604 0x092) tst_show="0.9.2" ;;
23605 0x091) tst_show="0.9.1" ;;
23606 *) tst_show="unknown" ;;
23607 esac
23608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tst_show" >&5
23609$as_echo "$tst_show" >&6; }
23610 #
23611 curl_openssl_api_library=$tst_api
23612
23613 #
23614 tst_match="yes"
23615 #
23616 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OpenSSL headers and library versions matching" >&5
23617$as_echo_n "checking for OpenSSL headers and library versions matching... " >&6; }
23618 if test "$curl_openssl_api_headers" = "unknown" ||
23619 test "$curl_openssl_api_library" = "unknown"; then
23620 tst_match="fail"
23621 tst_warns="Can not compare OpenSSL headers and library versions."
23622 elif test "$curl_openssl_api_headers" != "$curl_openssl_api_library"; then
23623 tst_match="no"
23624 tst_warns="OpenSSL headers and library versions do not match."
23625 fi
23626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tst_match" >&5
23627$as_echo "$tst_match" >&6; }
23628 if test "$tst_match" != "yes"; then
23629 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $tst_warns" >&5
23630$as_echo "$as_me: WARNING: $tst_warns" >&2;}
23631 fi
23632
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070023633 check_for_ca_bundle=1
Elliott Hughes82be86d2017-09-20 17:00:17 -070023634 fi
23635
Alex Deymo486467e2017-12-19 19:04:07 +010023636 test -z "$ssl_msg" || ssl_backends="${ssl_backends:+$ssl_backends, }$ssl_msg"
Elliott Hughes82be86d2017-09-20 17:00:17 -070023637fi
23638
Haibo Huang34ab3462019-05-22 00:50:27 -070023639if test X"$OPT_SSL" != Xoff &&
23640 test X"$OPT_SSL" != Xno &&
23641 test "$OPENSSL_ENABLED" != "1"; then
23642 { $as_echo "$as_me:${as_lineno-$LINENO}: OPT_SSL: $OPT_SSL" >&5
23643$as_echo "$as_me: OPT_SSL: $OPT_SSL" >&6;}
23644 { $as_echo "$as_me:${as_lineno-$LINENO}: OPENSSL_ENABLED: $OPENSSL_ENABLED" >&5
23645$as_echo "$as_me: OPENSSL_ENABLED: $OPENSSL_ENABLED" >&6;}
23646 as_fn_error $? "--with-ssl was given but OpenSSL could not be detected" "$LINENO" 5
23647fi
23648
Elliott Hughes82be86d2017-09-20 17:00:17 -070023649
23650if test X"$OPENSSL_ENABLED" = X"1"; then
23651
23652# Check whether --with-egd-socket was given.
23653if test "${with_egd_socket+set}" = set; then :
23654 withval=$with_egd_socket; EGD_SOCKET="$withval"
23655
23656fi
23657
23658 if test -n "$EGD_SOCKET" ; then
23659
23660cat >>confdefs.h <<_ACEOF
23661#define EGD_SOCKET "$EGD_SOCKET"
23662_ACEOF
23663
23664 fi
23665
23666
23667# Check whether --with-random was given.
23668if test "${with_random+set}" = set; then :
23669 withval=$with_random; RANDOM_FILE="$withval"
23670else
23671
23672 if test x$cross_compiling != xyes; then
23673 as_ac_File=`$as_echo "ac_cv_file_"/dev/urandom"" | $as_tr_sh`
23674{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for \"/dev/urandom\"" >&5
23675$as_echo_n "checking for \"/dev/urandom\"... " >&6; }
23676if eval \${$as_ac_File+:} false; then :
23677 $as_echo_n "(cached) " >&6
23678else
23679 test "$cross_compiling" = yes &&
23680 as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
23681if test -r ""/dev/urandom""; then
23682 eval "$as_ac_File=yes"
23683else
23684 eval "$as_ac_File=no"
23685fi
23686fi
23687eval ac_res=\$$as_ac_File
23688 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
23689$as_echo "$ac_res" >&6; }
23690if eval test \"x\$"$as_ac_File"\" = x"yes"; then :
23691 RANDOM_FILE="/dev/urandom"
23692fi
23693
23694 else
23695 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: skipped the /dev/urandom detection when cross-compiling" >&5
23696$as_echo "$as_me: WARNING: skipped the /dev/urandom detection when cross-compiling" >&2;}
23697 fi
23698
23699
23700fi
23701
23702 if test -n "$RANDOM_FILE" && test X"$RANDOM_FILE" != Xno ; then
23703
23704
23705cat >>confdefs.h <<_ACEOF
23706#define RANDOM_FILE "$RANDOM_FILE"
23707_ACEOF
23708
23709 fi
23710fi
23711
23712if test "$OPENSSL_ENABLED" = "1"; then
23713 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SRP_Calc_client_key in -lcrypto" >&5
23714$as_echo_n "checking for SRP_Calc_client_key in -lcrypto... " >&6; }
23715if ${ac_cv_lib_crypto_SRP_Calc_client_key+:} false; then :
23716 $as_echo_n "(cached) " >&6
23717else
23718 ac_check_lib_save_LIBS=$LIBS
23719LIBS="-lcrypto $LIBS"
23720cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23721/* end confdefs.h. */
23722
23723
23724#ifdef __cplusplus
23725extern "C"
23726#endif
23727char SRP_Calc_client_key ();
23728int main (void)
23729{
23730return SRP_Calc_client_key ();
23731 ;
23732 return 0;
23733}
23734_ACEOF
23735if ac_fn_c_try_link "$LINENO"; then :
23736 ac_cv_lib_crypto_SRP_Calc_client_key=yes
23737else
23738 ac_cv_lib_crypto_SRP_Calc_client_key=no
23739fi
23740rm -f core conftest.err conftest.$ac_objext \
23741 conftest$ac_exeext conftest.$ac_ext
23742LIBS=$ac_check_lib_save_LIBS
23743fi
23744{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_SRP_Calc_client_key" >&5
23745$as_echo "$ac_cv_lib_crypto_SRP_Calc_client_key" >&6; }
23746if test "x$ac_cv_lib_crypto_SRP_Calc_client_key" = xyes; then :
23747
23748
23749$as_echo "#define HAVE_OPENSSL_SRP 1" >>confdefs.h
23750
23751 HAVE_OPENSSL_SRP=1
23752
23753
23754fi
23755
23756fi
23757
Elliott Hughesa93fb052018-12-12 14:22:48 -080023758if test X"$OPENSSL_ENABLED" = X"1"; then
23759# Check whether --enable-openssl-auto-load-config was given.
23760if test "${enable_openssl_auto_load_config+set}" = set; then :
23761 enableval=$enable_openssl_auto_load_config; if test X"$enableval" = X"no"; then
23762 { $as_echo "$as_me:${as_lineno-$LINENO}: automatic loading of OpenSSL configuration disabled" >&5
23763$as_echo "$as_me: automatic loading of OpenSSL configuration disabled" >&6;}
23764
23765$as_echo "#define CURL_DISABLE_OPENSSL_AUTO_LOAD_CONFIG 1" >>confdefs.h
23766
23767 fi
23768
23769fi
23770
23771fi
23772
Elliott Hughes82be86d2017-09-20 17:00:17 -070023773
23774OPT_GNUTLS=no
23775
23776
23777# Check whether --with-gnutls was given.
23778if test "${with_gnutls+set}" = set; then :
23779 withval=$with_gnutls; OPT_GNUTLS=$withval
23780fi
23781
23782
Alex Deymo486467e2017-12-19 19:04:07 +010023783if test -z "$ssl_backends" -o "x$OPT_GNUTLS" != xno; then
23784 ssl_msg=
Elliott Hughes82be86d2017-09-20 17:00:17 -070023785
23786 if test X"$OPT_GNUTLS" != Xno; then
23787
23788 addld=""
23789 addlib=""
23790 gtlslib=""
23791 version=""
23792 addcflags=""
23793
23794 if test "x$OPT_GNUTLS" = "xyes"; then
23795
23796 if test -n "$PKG_CONFIG"; then
23797 PKGCONFIG="$PKG_CONFIG"
23798 else
23799 if test -n "$ac_tool_prefix"; then
23800 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
23801set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
23802{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
23803$as_echo_n "checking for $ac_word... " >&6; }
23804if ${ac_cv_path_PKGCONFIG+:} false; then :
23805 $as_echo_n "(cached) " >&6
23806else
23807 case $PKGCONFIG in
23808 [\\/]* | ?:[\\/]*)
23809 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
23810 ;;
23811 *)
23812 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
23813as_dummy="$PATH:/usr/bin:/usr/local/bin"
23814for as_dir in $as_dummy
23815do
23816 IFS=$as_save_IFS
23817 test -z "$as_dir" && as_dir=.
23818 for ac_exec_ext in '' $ac_executable_extensions; do
23819 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
23820 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
23821 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
23822 break 2
23823 fi
23824done
23825 done
23826IFS=$as_save_IFS
23827
23828 ;;
23829esac
23830fi
23831PKGCONFIG=$ac_cv_path_PKGCONFIG
23832if test -n "$PKGCONFIG"; then
23833 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
23834$as_echo "$PKGCONFIG" >&6; }
23835else
23836 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
23837$as_echo "no" >&6; }
23838fi
23839
23840
23841fi
23842if test -z "$ac_cv_path_PKGCONFIG"; then
23843 ac_pt_PKGCONFIG=$PKGCONFIG
23844 # Extract the first word of "pkg-config", so it can be a program name with args.
23845set dummy pkg-config; ac_word=$2
23846{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
23847$as_echo_n "checking for $ac_word... " >&6; }
23848if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
23849 $as_echo_n "(cached) " >&6
23850else
23851 case $ac_pt_PKGCONFIG in
23852 [\\/]* | ?:[\\/]*)
23853 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
23854 ;;
23855 *)
23856 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
23857as_dummy="$PATH:/usr/bin:/usr/local/bin"
23858for as_dir in $as_dummy
23859do
23860 IFS=$as_save_IFS
23861 test -z "$as_dir" && as_dir=.
23862 for ac_exec_ext in '' $ac_executable_extensions; do
23863 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
23864 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
23865 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
23866 break 2
23867 fi
23868done
23869 done
23870IFS=$as_save_IFS
23871
23872 ;;
23873esac
23874fi
23875ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
23876if test -n "$ac_pt_PKGCONFIG"; then
23877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
23878$as_echo "$ac_pt_PKGCONFIG" >&6; }
23879else
23880 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
23881$as_echo "no" >&6; }
23882fi
23883
23884 if test "x$ac_pt_PKGCONFIG" = x; then
23885 PKGCONFIG="no"
23886 else
23887 case $cross_compiling:$ac_tool_warned in
23888yes:)
23889{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
23890$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
23891ac_tool_warned=yes ;;
23892esac
23893 PKGCONFIG=$ac_pt_PKGCONFIG
23894 fi
23895else
23896 PKGCONFIG="$ac_cv_path_PKGCONFIG"
23897fi
23898
23899 fi
23900
23901 if test "x$PKGCONFIG" != "xno"; then
23902 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gnutls options with pkg-config" >&5
23903$as_echo_n "checking for gnutls options with pkg-config... " >&6; }
23904 itexists=`
23905 if test -n ""; then
23906 PKG_CONFIG_LIBDIR=""
23907 export PKG_CONFIG_LIBDIR
23908 fi
23909 $PKGCONFIG --exists gnutls >/dev/null 2>&1 && echo 1`
23910
23911 if test -z "$itexists"; then
23912 PKGCONFIG="no"
23913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
23914$as_echo "no" >&6; }
23915 else
23916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
23917$as_echo "found" >&6; }
23918 fi
23919 fi
23920
23921
23922 if test "$PKGCONFIG" != "no" ; then
23923 addlib=`$PKGCONFIG --libs-only-l gnutls`
23924 addld=`$PKGCONFIG --libs-only-L gnutls`
23925 addcflags=`$PKGCONFIG --cflags-only-I gnutls`
23926 version=`$PKGCONFIG --modversion gnutls`
23927 gtlslib=`echo $addld | $SED -e 's/-L//'`
23928 else
23929 check=`libgnutls-config --version 2>/dev/null`
23930 if test -n "$check"; then
23931 addlib=`libgnutls-config --libs`
23932 addcflags=`libgnutls-config --cflags`
23933 version=`libgnutls-config --version`
23934 gtlslib=`libgnutls-config --prefix`/lib$libsuff
23935 fi
23936 fi
23937 else
23938 cfg=$OPT_GNUTLS/bin/libgnutls-config
23939 check=`$cfg --version 2>/dev/null`
23940 if test -n "$check"; then
23941 addlib=`$cfg --libs`
23942 addcflags=`$cfg --cflags`
23943 version=`$cfg --version`
23944 gtlslib=`$cfg --prefix`/lib$libsuff
23945 else
23946 addlib=-lgnutls
23947 addld=-L$OPT_GNUTLS/lib$libsuff
23948 addcflags=-I$OPT_GNUTLS/include
23949 version="" # we just don't know
23950 gtlslib=$OPT_GNUTLS/lib$libsuff
23951 fi
23952 fi
23953
23954 if test -z "$version"; then
23955 version="unknown"
23956 fi
23957
23958 if test -n "$addlib"; then
23959
23960 CLEANLIBS="$LIBS"
23961 CLEANCPPFLAGS="$CPPFLAGS"
23962 CLEANLDFLAGS="$LDFLAGS"
23963
23964 LIBS="$addlib $LIBS"
23965 LDFLAGS="$LDFLAGS $addld"
23966 if test "$addcflags" != "-I/usr/include"; then
23967 CPPFLAGS="$CPPFLAGS $addcflags"
23968 fi
23969
23970 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gnutls_check_version in -lgnutls" >&5
23971$as_echo_n "checking for gnutls_check_version in -lgnutls... " >&6; }
23972if ${ac_cv_lib_gnutls_gnutls_check_version+:} false; then :
23973 $as_echo_n "(cached) " >&6
23974else
23975 ac_check_lib_save_LIBS=$LIBS
23976LIBS="-lgnutls $LIBS"
23977cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23978/* end confdefs.h. */
23979
23980
23981#ifdef __cplusplus
23982extern "C"
23983#endif
23984char gnutls_check_version ();
23985int main (void)
23986{
23987return gnutls_check_version ();
23988 ;
23989 return 0;
23990}
23991_ACEOF
23992if ac_fn_c_try_link "$LINENO"; then :
23993 ac_cv_lib_gnutls_gnutls_check_version=yes
23994else
23995 ac_cv_lib_gnutls_gnutls_check_version=no
23996fi
23997rm -f core conftest.err conftest.$ac_objext \
23998 conftest$ac_exeext conftest.$ac_ext
23999LIBS=$ac_check_lib_save_LIBS
24000fi
24001{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gnutls_gnutls_check_version" >&5
24002$as_echo "$ac_cv_lib_gnutls_gnutls_check_version" >&6; }
24003if test "x$ac_cv_lib_gnutls_gnutls_check_version" = xyes; then :
24004
24005
24006$as_echo "#define USE_GNUTLS 1" >>confdefs.h
24007
24008 USE_GNUTLS=1
24009
24010 GNUTLS_ENABLED=1
24011 USE_GNUTLS="yes"
Alex Deymo486467e2017-12-19 19:04:07 +010024012 ssl_msg="GnuTLS"
24013 test gnutls != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
Elliott Hughes82be86d2017-09-20 17:00:17 -070024014
24015else
24016
24017 LIBS="$CLEANLIBS"
24018 CPPFLAGS="$CLEANCPPFLAGS"
24019
24020fi
24021
24022
24023 if test "x$USE_GNUTLS" = "xyes"; then
24024 { $as_echo "$as_me:${as_lineno-$LINENO}: detected GnuTLS version $version" >&5
24025$as_echo "$as_me: detected GnuTLS version $version" >&6;}
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070024026 check_for_ca_bundle=1
Elliott Hughes82be86d2017-09-20 17:00:17 -070024027 if test -n "$gtlslib"; then
24028 if test "x$cross_compiling" != "xyes"; then
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070024029 CURL_LIBRARY_PATH="$CURL_LIBRARY_PATH:$gtlslib"
24030 export CURL_LIBRARY_PATH
24031 { $as_echo "$as_me:${as_lineno-$LINENO}: Added $gtlslib to CURL_LIBRARY_PATH" >&5
24032$as_echo "$as_me: Added $gtlslib to CURL_LIBRARY_PATH" >&6;}
Elliott Hughes82be86d2017-09-20 17:00:17 -070024033 fi
24034 fi
24035 for ac_func in gnutls_certificate_set_x509_key_file2 gnutls_alpn_set_protocols gnutls_ocsp_req_init
24036do :
24037 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
24038ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
24039if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
24040 cat >>confdefs.h <<_ACEOF
24041#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
24042_ACEOF
24043
24044fi
24045done
24046
24047 fi
24048
24049 fi
24050
24051 fi
Alex Deymo486467e2017-12-19 19:04:07 +010024052 test -z "$ssl_msg" || ssl_backends="${ssl_backends:+$ssl_backends, }$ssl_msg"
Elliott Hughes82be86d2017-09-20 17:00:17 -070024053fi
24054
24055
24056if test "$GNUTLS_ENABLED" = "1"; then
24057 USE_GNUTLS_NETTLE=
24058 # First check if we can detect either crypto library via transitive linking
24059 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nettle_MD5Init in -lgnutls" >&5
24060$as_echo_n "checking for nettle_MD5Init in -lgnutls... " >&6; }
24061if ${ac_cv_lib_gnutls_nettle_MD5Init+:} false; then :
24062 $as_echo_n "(cached) " >&6
24063else
24064 ac_check_lib_save_LIBS=$LIBS
24065LIBS="-lgnutls $LIBS"
24066cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24067/* end confdefs.h. */
24068
24069
24070#ifdef __cplusplus
24071extern "C"
24072#endif
24073char nettle_MD5Init ();
24074int main (void)
24075{
24076return nettle_MD5Init ();
24077 ;
24078 return 0;
24079}
24080_ACEOF
24081if ac_fn_c_try_link "$LINENO"; then :
24082 ac_cv_lib_gnutls_nettle_MD5Init=yes
24083else
24084 ac_cv_lib_gnutls_nettle_MD5Init=no
24085fi
24086rm -f core conftest.err conftest.$ac_objext \
24087 conftest$ac_exeext conftest.$ac_ext
24088LIBS=$ac_check_lib_save_LIBS
24089fi
24090{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gnutls_nettle_MD5Init" >&5
24091$as_echo "$ac_cv_lib_gnutls_nettle_MD5Init" >&6; }
24092if test "x$ac_cv_lib_gnutls_nettle_MD5Init" = xyes; then :
24093 USE_GNUTLS_NETTLE=1
24094fi
24095
24096 if test "$USE_GNUTLS_NETTLE" = ""; then
24097 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gcry_control in -lgnutls" >&5
24098$as_echo_n "checking for gcry_control in -lgnutls... " >&6; }
24099if ${ac_cv_lib_gnutls_gcry_control+:} false; then :
24100 $as_echo_n "(cached) " >&6
24101else
24102 ac_check_lib_save_LIBS=$LIBS
24103LIBS="-lgnutls $LIBS"
24104cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24105/* end confdefs.h. */
24106
24107
24108#ifdef __cplusplus
24109extern "C"
24110#endif
24111char gcry_control ();
24112int main (void)
24113{
24114return gcry_control ();
24115 ;
24116 return 0;
24117}
24118_ACEOF
24119if ac_fn_c_try_link "$LINENO"; then :
24120 ac_cv_lib_gnutls_gcry_control=yes
24121else
24122 ac_cv_lib_gnutls_gcry_control=no
24123fi
24124rm -f core conftest.err conftest.$ac_objext \
24125 conftest$ac_exeext conftest.$ac_ext
24126LIBS=$ac_check_lib_save_LIBS
24127fi
24128{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gnutls_gcry_control" >&5
24129$as_echo "$ac_cv_lib_gnutls_gcry_control" >&6; }
24130if test "x$ac_cv_lib_gnutls_gcry_control" = xyes; then :
24131 USE_GNUTLS_NETTLE=0
24132fi
24133
24134 fi
24135 # If not, try linking directly to both of them to see if they are available
24136 if test "$USE_GNUTLS_NETTLE" = ""; then
24137 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nettle_MD5Init in -lnettle" >&5
24138$as_echo_n "checking for nettle_MD5Init in -lnettle... " >&6; }
24139if ${ac_cv_lib_nettle_nettle_MD5Init+:} false; then :
24140 $as_echo_n "(cached) " >&6
24141else
24142 ac_check_lib_save_LIBS=$LIBS
24143LIBS="-lnettle $LIBS"
24144cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24145/* end confdefs.h. */
24146
24147
24148#ifdef __cplusplus
24149extern "C"
24150#endif
24151char nettle_MD5Init ();
24152int main (void)
24153{
24154return nettle_MD5Init ();
24155 ;
24156 return 0;
24157}
24158_ACEOF
24159if ac_fn_c_try_link "$LINENO"; then :
24160 ac_cv_lib_nettle_nettle_MD5Init=yes
24161else
24162 ac_cv_lib_nettle_nettle_MD5Init=no
24163fi
24164rm -f core conftest.err conftest.$ac_objext \
24165 conftest$ac_exeext conftest.$ac_ext
24166LIBS=$ac_check_lib_save_LIBS
24167fi
24168{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nettle_nettle_MD5Init" >&5
24169$as_echo "$ac_cv_lib_nettle_nettle_MD5Init" >&6; }
24170if test "x$ac_cv_lib_nettle_nettle_MD5Init" = xyes; then :
24171 USE_GNUTLS_NETTLE=1
24172fi
24173
24174 fi
24175 if test "$USE_GNUTLS_NETTLE" = ""; then
24176 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gcry_control in -lgcrypt" >&5
24177$as_echo_n "checking for gcry_control in -lgcrypt... " >&6; }
24178if ${ac_cv_lib_gcrypt_gcry_control+:} false; then :
24179 $as_echo_n "(cached) " >&6
24180else
24181 ac_check_lib_save_LIBS=$LIBS
24182LIBS="-lgcrypt $LIBS"
24183cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24184/* end confdefs.h. */
24185
24186
24187#ifdef __cplusplus
24188extern "C"
24189#endif
24190char gcry_control ();
24191int main (void)
24192{
24193return gcry_control ();
24194 ;
24195 return 0;
24196}
24197_ACEOF
24198if ac_fn_c_try_link "$LINENO"; then :
24199 ac_cv_lib_gcrypt_gcry_control=yes
24200else
24201 ac_cv_lib_gcrypt_gcry_control=no
24202fi
24203rm -f core conftest.err conftest.$ac_objext \
24204 conftest$ac_exeext conftest.$ac_ext
24205LIBS=$ac_check_lib_save_LIBS
24206fi
24207{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gcrypt_gcry_control" >&5
24208$as_echo "$ac_cv_lib_gcrypt_gcry_control" >&6; }
24209if test "x$ac_cv_lib_gcrypt_gcry_control" = xyes; then :
24210 USE_GNUTLS_NETTLE=0
24211fi
24212
24213 fi
24214 if test "$USE_GNUTLS_NETTLE" = ""; then
24215 as_fn_error $? "GnuTLS found, but neither gcrypt nor nettle found" "$LINENO" 5
24216 fi
24217 if test "$USE_GNUTLS_NETTLE" = "1"; then
24218
24219$as_echo "#define USE_GNUTLS_NETTLE 1" >>confdefs.h
24220
24221 USE_GNUTLS_NETTLE=1
24222
24223 LIBS="-lnettle $LIBS"
24224 else
24225 LIBS="-lgcrypt $LIBS"
24226 fi
24227fi
24228
24229if test "$GNUTLS_ENABLED" = "1"; then
24230 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gnutls_srp_verifier in -lgnutls" >&5
24231$as_echo_n "checking for gnutls_srp_verifier in -lgnutls... " >&6; }
24232if ${ac_cv_lib_gnutls_gnutls_srp_verifier+:} false; then :
24233 $as_echo_n "(cached) " >&6
24234else
24235 ac_check_lib_save_LIBS=$LIBS
24236LIBS="-lgnutls $LIBS"
24237cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24238/* end confdefs.h. */
24239
24240
24241#ifdef __cplusplus
24242extern "C"
24243#endif
24244char gnutls_srp_verifier ();
24245int main (void)
24246{
24247return gnutls_srp_verifier ();
24248 ;
24249 return 0;
24250}
24251_ACEOF
24252if ac_fn_c_try_link "$LINENO"; then :
24253 ac_cv_lib_gnutls_gnutls_srp_verifier=yes
24254else
24255 ac_cv_lib_gnutls_gnutls_srp_verifier=no
24256fi
24257rm -f core conftest.err conftest.$ac_objext \
24258 conftest$ac_exeext conftest.$ac_ext
24259LIBS=$ac_check_lib_save_LIBS
24260fi
24261{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gnutls_gnutls_srp_verifier" >&5
24262$as_echo "$ac_cv_lib_gnutls_gnutls_srp_verifier" >&6; }
24263if test "x$ac_cv_lib_gnutls_gnutls_srp_verifier" = xyes; then :
24264
24265
24266$as_echo "#define HAVE_GNUTLS_SRP 1" >>confdefs.h
24267
24268 HAVE_GNUTLS_SRP=1
24269
24270
24271fi
24272
24273fi
24274
24275
Elliott Hughes82be86d2017-09-20 17:00:17 -070024276OPT_MBEDTLS=no
24277
24278_cppflags=$CPPFLAGS
24279_ldflags=$LDFLAGS
24280
24281# Check whether --with-mbedtls was given.
24282if test "${with_mbedtls+set}" = set; then :
24283 withval=$with_mbedtls; OPT_MBEDTLS=$withval
24284fi
24285
24286
Alex Deymo486467e2017-12-19 19:04:07 +010024287if test -z "$ssl_backends" -o "x$OPT_MBEDTLS" != xno; then
24288 ssl_msg=
Elliott Hughes82be86d2017-09-20 17:00:17 -070024289
24290 if test X"$OPT_MBEDTLS" != Xno; then
24291
24292 if test "$OPT_MBEDTLS" = "yes"; then
24293 OPT_MBEDTLS=""
24294 fi
24295
24296 if test -z "$OPT_MBEDTLS" ; then
24297
24298 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbedtls_havege_init in -lmbedtls" >&5
24299$as_echo_n "checking for mbedtls_havege_init in -lmbedtls... " >&6; }
24300if ${ac_cv_lib_mbedtls_mbedtls_havege_init+:} false; then :
24301 $as_echo_n "(cached) " >&6
24302else
24303 ac_check_lib_save_LIBS=$LIBS
24304LIBS="-lmbedtls -lmbedx509 -lmbedcrypto $LIBS"
24305cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24306/* end confdefs.h. */
24307
24308
24309#ifdef __cplusplus
24310extern "C"
24311#endif
24312char mbedtls_havege_init ();
24313int main (void)
24314{
24315return mbedtls_havege_init ();
24316 ;
24317 return 0;
24318}
24319_ACEOF
24320if ac_fn_c_try_link "$LINENO"; then :
24321 ac_cv_lib_mbedtls_mbedtls_havege_init=yes
24322else
24323 ac_cv_lib_mbedtls_mbedtls_havege_init=no
24324fi
24325rm -f core conftest.err conftest.$ac_objext \
24326 conftest$ac_exeext conftest.$ac_ext
24327LIBS=$ac_check_lib_save_LIBS
24328fi
24329{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mbedtls_mbedtls_havege_init" >&5
24330$as_echo "$ac_cv_lib_mbedtls_mbedtls_havege_init" >&6; }
24331if test "x$ac_cv_lib_mbedtls_mbedtls_havege_init" = xyes; then :
24332
24333
24334$as_echo "#define USE_MBEDTLS 1" >>confdefs.h
24335
24336 USE_MBEDTLS=1
24337
24338 MBEDTLS_ENABLED=1
24339 USE_MBEDTLS="yes"
Alex Deymo486467e2017-12-19 19:04:07 +010024340 ssl_msg="mbedTLS"
24341 test mbedtls != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
Elliott Hughes82be86d2017-09-20 17:00:17 -070024342
24343fi
24344
24345 fi
24346
24347 addld=""
24348 addlib=""
24349 addcflags=""
24350 mbedtlslib=""
24351
24352 if test "x$USE_MBEDTLS" != "xyes"; then
24353 addld=-L$OPT_MBEDTLS/lib$libsuff
24354 addcflags=-I$OPT_MBEDTLS/include
24355 mbedtlslib=$OPT_MBEDTLS/lib$libsuff
24356
24357 LDFLAGS="$LDFLAGS $addld"
24358 if test "$addcflags" != "-I/usr/include"; then
24359 CPPFLAGS="$CPPFLAGS $addcflags"
24360 fi
24361
24362 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbedtls_ssl_init in -lmbedtls" >&5
24363$as_echo_n "checking for mbedtls_ssl_init in -lmbedtls... " >&6; }
24364if ${ac_cv_lib_mbedtls_mbedtls_ssl_init+:} false; then :
24365 $as_echo_n "(cached) " >&6
24366else
24367 ac_check_lib_save_LIBS=$LIBS
24368LIBS="-lmbedtls -lmbedx509 -lmbedcrypto $LIBS"
24369cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24370/* end confdefs.h. */
24371
24372
24373#ifdef __cplusplus
24374extern "C"
24375#endif
24376char mbedtls_ssl_init ();
24377int main (void)
24378{
24379return mbedtls_ssl_init ();
24380 ;
24381 return 0;
24382}
24383_ACEOF
24384if ac_fn_c_try_link "$LINENO"; then :
24385 ac_cv_lib_mbedtls_mbedtls_ssl_init=yes
24386else
24387 ac_cv_lib_mbedtls_mbedtls_ssl_init=no
24388fi
24389rm -f core conftest.err conftest.$ac_objext \
24390 conftest$ac_exeext conftest.$ac_ext
24391LIBS=$ac_check_lib_save_LIBS
24392fi
24393{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mbedtls_mbedtls_ssl_init" >&5
24394$as_echo "$ac_cv_lib_mbedtls_mbedtls_ssl_init" >&6; }
24395if test "x$ac_cv_lib_mbedtls_mbedtls_ssl_init" = xyes; then :
24396
24397
24398$as_echo "#define USE_MBEDTLS 1" >>confdefs.h
24399
24400 USE_MBEDTLS=1
24401
24402 MBEDTLS_ENABLED=1
24403 USE_MBEDTLS="yes"
Alex Deymo486467e2017-12-19 19:04:07 +010024404 ssl_msg="mbedTLS"
24405 test mbedtls != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
Elliott Hughes82be86d2017-09-20 17:00:17 -070024406
24407else
24408
24409 CPPFLAGS=$_cppflags
24410 LDFLAGS=$_ldflags
24411
24412fi
24413
24414 fi
24415
24416 if test "x$USE_MBEDTLS" = "xyes"; then
24417 { $as_echo "$as_me:${as_lineno-$LINENO}: detected mbedTLS" >&5
24418$as_echo "$as_me: detected mbedTLS" >&6;}
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070024419 check_for_ca_bundle=1
Elliott Hughes82be86d2017-09-20 17:00:17 -070024420
24421 LIBS="-lmbedtls -lmbedx509 -lmbedcrypto $LIBS"
24422
24423 if test -n "$mbedtlslib"; then
24424 if test "x$cross_compiling" != "xyes"; then
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070024425 CURL_LIBRARY_PATH="$CURL_LIBRARY_PATH:$mbedtlslib"
24426 export CURL_LIBRARY_PATH
24427 { $as_echo "$as_me:${as_lineno-$LINENO}: Added $mbedtlslib to CURL_LIBRARY_PATH" >&5
24428$as_echo "$as_me: Added $mbedtlslib to CURL_LIBRARY_PATH" >&6;}
Elliott Hughes82be86d2017-09-20 17:00:17 -070024429 fi
24430 fi
24431 fi
24432
24433 fi
Alex Deymo486467e2017-12-19 19:04:07 +010024434 test -z "$ssl_msg" || ssl_backends="${ssl_backends:+$ssl_backends, }$ssl_msg"
Elliott Hughes82be86d2017-09-20 17:00:17 -070024435fi
24436
24437
Haibo Huang001784b2019-07-19 05:27:28 -070024438OPT_WOLFSSL=no
Elliott Hughes82be86d2017-09-20 17:00:17 -070024439
24440_cppflags=$CPPFLAGS
24441_ldflags=$LDFLAGS
24442
24443# Check whether --with-cyassl was given.
24444if test "${with_cyassl+set}" = set; then :
Haibo Huang001784b2019-07-19 05:27:28 -070024445 withval=$with_cyassl; OPT_WOLFSSL=$withval
Elliott Hughes82be86d2017-09-20 17:00:17 -070024446fi
24447
24448
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070024449
24450# Check whether --with-wolfssl was given.
24451if test "${with_wolfssl+set}" = set; then :
Haibo Huang001784b2019-07-19 05:27:28 -070024452 withval=$with_wolfssl; OPT_WOLFSSL=$withval
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070024453fi
24454
24455
Haibo Huang001784b2019-07-19 05:27:28 -070024456if test -z "$ssl_backends" -o "x$OPT_WOLFSSL" != xno; then
Alex Deymo486467e2017-12-19 19:04:07 +010024457 ssl_msg=
Elliott Hughes82be86d2017-09-20 17:00:17 -070024458
Haibo Huang001784b2019-07-19 05:27:28 -070024459 if test X"$OPT_WOLFSSL" != Xno; then
Elliott Hughes82be86d2017-09-20 17:00:17 -070024460
Haibo Huang001784b2019-07-19 05:27:28 -070024461 if test "$OPT_WOLFSSL" = "yes"; then
24462 OPT_WOLFSSL=""
Elliott Hughes82be86d2017-09-20 17:00:17 -070024463 fi
24464
24465
24466 cyassllibname=cyassl
24467
Haibo Huang001784b2019-07-19 05:27:28 -070024468 if test -z "$OPT_WOLFSSL" ; then
Elliott Hughes82be86d2017-09-20 17:00:17 -070024469
24470 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CyaSSL_Init in -lcyassl" >&5
24471$as_echo_n "checking for CyaSSL_Init in -lcyassl... " >&6; }
24472if ${ac_cv_lib_cyassl_CyaSSL_Init+:} false; then :
24473 $as_echo_n "(cached) " >&6
24474else
24475 ac_check_lib_save_LIBS=$LIBS
24476LIBS="-lcyassl $LIBS"
24477cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24478/* end confdefs.h. */
24479
24480
24481#ifdef __cplusplus
24482extern "C"
24483#endif
24484char CyaSSL_Init ();
24485int main (void)
24486{
24487return CyaSSL_Init ();
24488 ;
24489 return 0;
24490}
24491_ACEOF
24492if ac_fn_c_try_link "$LINENO"; then :
24493 ac_cv_lib_cyassl_CyaSSL_Init=yes
24494else
24495 ac_cv_lib_cyassl_CyaSSL_Init=no
24496fi
24497rm -f core conftest.err conftest.$ac_objext \
24498 conftest$ac_exeext conftest.$ac_ext
24499LIBS=$ac_check_lib_save_LIBS
24500fi
24501{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_cyassl_CyaSSL_Init" >&5
24502$as_echo "$ac_cv_lib_cyassl_CyaSSL_Init" >&6; }
24503if test "x$ac_cv_lib_cyassl_CyaSSL_Init" = xyes; then :
24504
24505
Haibo Huang001784b2019-07-19 05:27:28 -070024506$as_echo "#define USE_WOLFSSL 1" >>confdefs.h
Elliott Hughes82be86d2017-09-20 17:00:17 -070024507
Haibo Huang001784b2019-07-19 05:27:28 -070024508 USE_WOLFSSL=1
Elliott Hughes82be86d2017-09-20 17:00:17 -070024509
Haibo Huang001784b2019-07-19 05:27:28 -070024510 WOLFSSL_ENABLED=1
24511 USE_WOLFSSL="yes"
Alex Deymo486467e2017-12-19 19:04:07 +010024512 ssl_msg="CyaSSL"
24513 test cyassl != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
Elliott Hughes82be86d2017-09-20 17:00:17 -070024514
24515fi
24516
24517 fi
24518
24519 addld=""
24520 addlib=""
24521 addcflags=""
24522 cyassllib=""
24523
Haibo Huang001784b2019-07-19 05:27:28 -070024524 if test "x$USE_WOLFSSL" != "xyes"; then
24525 addld=-L$OPT_WOLFSSL/lib$libsuff
24526 addcflags=-I$OPT_WOLFSSL/include
24527 cyassllib=$OPT_WOLFSSL/lib$libsuff
Elliott Hughes82be86d2017-09-20 17:00:17 -070024528
24529 LDFLAGS="$LDFLAGS $addld"
24530 if test "$addcflags" != "-I/usr/include"; then
24531 CPPFLAGS="$CPPFLAGS $addcflags"
24532 fi
24533
24534 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CyaSSL_Init in -lcyassl" >&5
24535$as_echo_n "checking for CyaSSL_Init in -lcyassl... " >&6; }
24536if ${ac_cv_lib_cyassl_CyaSSL_Init+:} false; then :
24537 $as_echo_n "(cached) " >&6
24538else
24539 ac_check_lib_save_LIBS=$LIBS
24540LIBS="-lcyassl $LIBS"
24541cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24542/* end confdefs.h. */
24543
24544
24545#ifdef __cplusplus
24546extern "C"
24547#endif
24548char CyaSSL_Init ();
24549int main (void)
24550{
24551return CyaSSL_Init ();
24552 ;
24553 return 0;
24554}
24555_ACEOF
24556if ac_fn_c_try_link "$LINENO"; then :
24557 ac_cv_lib_cyassl_CyaSSL_Init=yes
24558else
24559 ac_cv_lib_cyassl_CyaSSL_Init=no
24560fi
24561rm -f core conftest.err conftest.$ac_objext \
24562 conftest$ac_exeext conftest.$ac_ext
24563LIBS=$ac_check_lib_save_LIBS
24564fi
24565{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_cyassl_CyaSSL_Init" >&5
24566$as_echo "$ac_cv_lib_cyassl_CyaSSL_Init" >&6; }
24567if test "x$ac_cv_lib_cyassl_CyaSSL_Init" = xyes; then :
24568
24569
Haibo Huang001784b2019-07-19 05:27:28 -070024570$as_echo "#define USE_WOLFSSL 1" >>confdefs.h
Elliott Hughes82be86d2017-09-20 17:00:17 -070024571
Haibo Huang001784b2019-07-19 05:27:28 -070024572 USE_WOLFSSL=1
Elliott Hughes82be86d2017-09-20 17:00:17 -070024573
Haibo Huang001784b2019-07-19 05:27:28 -070024574 WOLFSSL_ENABLED=1
24575 USE_WOLFSSL="yes"
Alex Deymo486467e2017-12-19 19:04:07 +010024576 ssl_msg="CyaSSL"
24577 test cyassl != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
Elliott Hughes82be86d2017-09-20 17:00:17 -070024578
24579else
24580
24581 CPPFLAGS=$_cppflags
24582 LDFLAGS=$_ldflags
24583 cyassllib=""
24584
24585fi
24586
24587 fi
24588
24589 addld=""
24590 addlib=""
24591 addcflags=""
24592
Haibo Huang001784b2019-07-19 05:27:28 -070024593 if test "x$USE_WOLFSSL" != "xyes"; then
24594 addld=-L$OPT_WOLFSSL/lib$libsuff
24595 addcflags=-I$OPT_WOLFSSL/include
24596 cyassllib=$OPT_WOLFSSL/lib$libsuff
Elliott Hughes82be86d2017-09-20 17:00:17 -070024597
24598 LDFLAGS="$LDFLAGS $addld"
24599 if test "$addcflags" != "-I/usr/include"; then
24600 CPPFLAGS="$CPPFLAGS $addcflags"
24601 fi
24602
24603 cyassllibname=wolfssl
24604 my_ac_save_LIBS="$LIBS"
24605 LIBS="-l$cyassllibname -lm $LIBS"
24606
24607 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CyaSSL_Init in -lwolfssl" >&5
24608$as_echo_n "checking for CyaSSL_Init in -lwolfssl... " >&6; }
24609 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24610/* end confdefs.h. */
24611
24612
24613/* These aren't needed for detection and confuse WolfSSL.
24614 They are set up properly later if it is detected. */
24615#undef SIZEOF_LONG
24616#undef SIZEOF_LONG_LONG
24617#include <cyassl/ssl.h>
24618
24619int main (void)
24620{
24621
24622 return CyaSSL_Init();
24623
24624 ;
24625 return 0;
24626}
24627
24628_ACEOF
24629if ac_fn_c_try_link "$LINENO"; then :
24630
24631 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
24632$as_echo "yes" >&6; }
24633
Haibo Huang001784b2019-07-19 05:27:28 -070024634$as_echo "#define USE_WOLFSSL 1" >>confdefs.h
Elliott Hughes82be86d2017-09-20 17:00:17 -070024635
Haibo Huang001784b2019-07-19 05:27:28 -070024636 USE_WOLFSSL=1
Elliott Hughes82be86d2017-09-20 17:00:17 -070024637
Haibo Huang001784b2019-07-19 05:27:28 -070024638 WOLFSSL_ENABLED=1
24639 USE_WOLFSSL="yes"
Alex Deymo486467e2017-12-19 19:04:07 +010024640 ssl_msg="WolfSSL"
24641 test cyassl != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
Elliott Hughes82be86d2017-09-20 17:00:17 -070024642
24643else
24644
24645 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24646$as_echo "no" >&6; }
24647 CPPFLAGS=$_cppflags
24648 LDFLAGS=$_ldflags
24649 cyassllib=""
24650
24651fi
24652rm -f core conftest.err conftest.$ac_objext \
24653 conftest$ac_exeext conftest.$ac_ext
24654 LIBS="$my_ac_save_LIBS"
24655 fi
24656
Haibo Huang001784b2019-07-19 05:27:28 -070024657 if test "x$USE_WOLFSSL" = "xyes"; then
Elliott Hughes82be86d2017-09-20 17:00:17 -070024658 { $as_echo "$as_me:${as_lineno-$LINENO}: detected $cyassllibname" >&5
24659$as_echo "$as_me: detected $cyassllibname" >&6;}
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070024660 check_for_ca_bundle=1
Elliott Hughes82be86d2017-09-20 17:00:17 -070024661
Elliott Hughes72d948d2018-08-03 14:37:21 -070024662 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070024663$as_echo_n "checking size of long long... " >&6; }
24664if ${ac_cv_sizeof_long_long+:} false; then :
24665 $as_echo_n "(cached) " >&6
24666else
Elliott Hughes72d948d2018-08-03 14:37:21 -070024667 for ac_size in 4 8 1 2 16 ; do # List sizes in rough order of prevalence.
24668 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24669/* end confdefs.h. */
Elliott Hughes82be86d2017-09-20 17:00:17 -070024670
Elliott Hughes72d948d2018-08-03 14:37:21 -070024671#include <sys/types.h>
24672
24673
24674int main (void)
24675{
24676switch (0) case 0: case (sizeof (long long) == $ac_size):;
24677 ;
24678 return 0;
24679}
24680_ACEOF
24681if ac_fn_c_try_compile "$LINENO"; then :
24682 ac_cv_sizeof_long_long=$ac_size
24683fi
24684rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24685 if test x$ac_cv_sizeof_long_long != x ; then break; fi
24686done
24687
Elliott Hughes82be86d2017-09-20 17:00:17 -070024688fi
24689
Elliott Hughes72d948d2018-08-03 14:37:21 -070024690if test x$ac_cv_sizeof_long_long = x ; then
24691 as_fn_error $? "cannot determine a size for long long" "$LINENO" 5
Elliott Hughes82be86d2017-09-20 17:00:17 -070024692fi
24693{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5
24694$as_echo "$ac_cv_sizeof_long_long" >&6; }
24695
Elliott Hughes82be86d2017-09-20 17:00:17 -070024696cat >>confdefs.h <<_ACEOF
24697#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
24698_ACEOF
24699
24700
24701
Elliott Hughes82be86d2017-09-20 17:00:17 -070024702 LIBS="-l$cyassllibname -lm $LIBS"
24703
Haibo Huang001784b2019-07-19 05:27:28 -070024704 for ac_func in wolfSSLv3_client_method \
24705 wolfSSL_get_peer_certificate \
24706 wolfSSL_UseALPN
Elliott Hughes82be86d2017-09-20 17:00:17 -070024707do :
24708 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
24709ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
24710if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
24711 cat >>confdefs.h <<_ACEOF
24712#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
24713_ACEOF
24714
24715fi
24716done
24717
Elliott Hughes82be86d2017-09-20 17:00:17 -070024718
24719 if test -n "$cyassllib"; then
24720 if test "x$cross_compiling" != "xyes"; then
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070024721 CURL_LIBRARY_PATH="$CURL_LIBRARY_PATH:$cyassllib"
24722 export CURL_LIBRARY_PATH
24723 { $as_echo "$as_me:${as_lineno-$LINENO}: Added $cyassllib to CURL_LIBRARY_PATH" >&5
24724$as_echo "$as_me: Added $cyassllib to CURL_LIBRARY_PATH" >&6;}
Elliott Hughes82be86d2017-09-20 17:00:17 -070024725 fi
24726 fi
24727
24728 fi
24729
24730 fi
Alex Deymo486467e2017-12-19 19:04:07 +010024731 test -z "$ssl_msg" || ssl_backends="${ssl_backends:+$ssl_backends, }$ssl_msg"
Elliott Hughes82be86d2017-09-20 17:00:17 -070024732fi
24733
24734
Elliott Hughesa93fb052018-12-12 14:22:48 -080024735OPT_MESALINK=no
24736
24737_cppflags=$CPPFLAGS
24738_ldflags=$LDFLAGS
24739
24740# Check whether --with-mesalink was given.
24741if test "${with_mesalink+set}" = set; then :
24742 withval=$with_mesalink; OPT_MESALINK=$withval
24743fi
24744
24745
24746if test -z "$ssl_backends" -o "x$OPT_MESALINK" != xno; then
24747 ssl_msg=
24748
24749 if test X"$OPT_MESALINK" != Xno; then
24750
24751 if test "$OPT_MESALINK" = "yes"; then
24752 OPT_MESALINK=""
24753 fi
24754
24755 if test -z "$OPT_MESALINK" ; then
24756
24757 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mesalink_library_init in -lmesalink" >&5
24758$as_echo_n "checking for mesalink_library_init in -lmesalink... " >&6; }
24759if ${ac_cv_lib_mesalink_mesalink_library_init+:} false; then :
24760 $as_echo_n "(cached) " >&6
24761else
24762 ac_check_lib_save_LIBS=$LIBS
24763LIBS="-lmesalink $LIBS"
24764cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24765/* end confdefs.h. */
24766
24767
24768#ifdef __cplusplus
24769extern "C"
24770#endif
24771char mesalink_library_init ();
24772int main (void)
24773{
24774return mesalink_library_init ();
24775 ;
24776 return 0;
24777}
24778_ACEOF
24779if ac_fn_c_try_link "$LINENO"; then :
24780 ac_cv_lib_mesalink_mesalink_library_init=yes
24781else
24782 ac_cv_lib_mesalink_mesalink_library_init=no
24783fi
24784rm -f core conftest.err conftest.$ac_objext \
24785 conftest$ac_exeext conftest.$ac_ext
24786LIBS=$ac_check_lib_save_LIBS
24787fi
24788{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mesalink_mesalink_library_init" >&5
24789$as_echo "$ac_cv_lib_mesalink_mesalink_library_init" >&6; }
24790if test "x$ac_cv_lib_mesalink_mesalink_library_init" = xyes; then :
24791
24792
24793$as_echo "#define USE_MESALINK 1" >>confdefs.h
24794
24795 USE_MESALINK=1
24796
24797 MESALINK_ENABLED=1
24798 USE_MESALINK="yes"
24799 ssl_msg="MesaLink"
24800 test mesalink != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
24801
24802fi
24803
24804 fi
24805
24806 addld=""
24807 addlib=""
24808 addcflags=""
24809 mesalinklib=""
24810
24811 if test "x$USE_MESALINK" != "xyes"; then
24812 addld=-L$OPT_MESALINK/lib$libsuff
24813 addcflags=-I$OPT_MESALINK/include
24814 mesalinklib=$OPT_MESALINK/lib$libsuff
24815
24816 LDFLAGS="$LDFLAGS $addld"
24817 if test "$addcflags" != "-I/usr/include"; then
24818 CPPFLAGS="$CPPFLAGS $addcflags"
24819 fi
24820
24821 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mesalink_library_init in -lmesalink" >&5
24822$as_echo_n "checking for mesalink_library_init in -lmesalink... " >&6; }
24823if ${ac_cv_lib_mesalink_mesalink_library_init+:} false; then :
24824 $as_echo_n "(cached) " >&6
24825else
24826 ac_check_lib_save_LIBS=$LIBS
24827LIBS="-lmesalink $LIBS"
24828cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24829/* end confdefs.h. */
24830
24831
24832#ifdef __cplusplus
24833extern "C"
24834#endif
24835char mesalink_library_init ();
24836int main (void)
24837{
24838return mesalink_library_init ();
24839 ;
24840 return 0;
24841}
24842_ACEOF
24843if ac_fn_c_try_link "$LINENO"; then :
24844 ac_cv_lib_mesalink_mesalink_library_init=yes
24845else
24846 ac_cv_lib_mesalink_mesalink_library_init=no
24847fi
24848rm -f core conftest.err conftest.$ac_objext \
24849 conftest$ac_exeext conftest.$ac_ext
24850LIBS=$ac_check_lib_save_LIBS
24851fi
24852{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mesalink_mesalink_library_init" >&5
24853$as_echo "$ac_cv_lib_mesalink_mesalink_library_init" >&6; }
24854if test "x$ac_cv_lib_mesalink_mesalink_library_init" = xyes; then :
24855
24856
24857$as_echo "#define USE_MESALINK 1" >>confdefs.h
24858
24859 USE_MESALINK=1
24860
24861 MESALINK_ENABLED=1
24862 USE_MESALINK="yes"
24863 ssl_msg="MesaLink"
24864 test mesalink != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
24865
24866else
24867
24868 CPPFLAGS=$_cppflags
24869 LDFLAGS=$_ldflags
24870
24871fi
24872
24873 fi
24874
24875 if test "x$USE_MESALINK" = "xyes"; then
24876 { $as_echo "$as_me:${as_lineno-$LINENO}: detected MesaLink" >&5
24877$as_echo "$as_me: detected MesaLink" >&6;}
24878
24879 LIBS="-lmesalink $LIBS"
24880
24881 if test -n "$mesalinklib"; then
24882 if test "x$cross_compiling" != "xyes"; then
24883 LD_LIBRARY_PATH="$LD_LIBRARY_PATH:$mesalinklib"
24884 export LD_LIBRARY_PATH
24885 { $as_echo "$as_me:${as_lineno-$LINENO}: Added $mesalinklib to LD_LIBRARY_PATH" >&5
24886$as_echo "$as_me: Added $mesalinklib to LD_LIBRARY_PATH" >&6;}
24887 fi
24888 fi
24889 fi
24890
24891 fi
24892 test -z "$ssl_msg" || ssl_backends="${ssl_backends:+$ssl_backends, }$ssl_msg"
24893fi
24894
24895
Elliott Hughes82be86d2017-09-20 17:00:17 -070024896OPT_NSS=no
24897
24898
24899# Check whether --with-nss was given.
24900if test "${with_nss+set}" = set; then :
24901 withval=$with_nss; OPT_NSS=$withval
24902fi
24903
24904
Alex Deymo486467e2017-12-19 19:04:07 +010024905if test -z "$ssl_backends" -o "x$OPT_NSS" != xno; then
24906 ssl_msg=
Elliott Hughes82be86d2017-09-20 17:00:17 -070024907
24908 if test X"$OPT_NSS" != Xno; then
24909
24910 addld=""
24911 addlib=""
24912 addcflags=""
24913 nssprefix=""
24914 version=""
24915
24916 if test "x$OPT_NSS" = "xyes"; then
24917
24918
24919 if test -n "$PKG_CONFIG"; then
24920 PKGCONFIG="$PKG_CONFIG"
24921 else
24922 if test -n "$ac_tool_prefix"; then
24923 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
24924set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
24925{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24926$as_echo_n "checking for $ac_word... " >&6; }
24927if ${ac_cv_path_PKGCONFIG+:} false; then :
24928 $as_echo_n "(cached) " >&6
24929else
24930 case $PKGCONFIG in
24931 [\\/]* | ?:[\\/]*)
24932 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
24933 ;;
24934 *)
24935 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24936as_dummy="$PATH:/usr/bin:/usr/local/bin"
24937for as_dir in $as_dummy
24938do
24939 IFS=$as_save_IFS
24940 test -z "$as_dir" && as_dir=.
24941 for ac_exec_ext in '' $ac_executable_extensions; do
24942 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
24943 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
24944 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
24945 break 2
24946 fi
24947done
24948 done
24949IFS=$as_save_IFS
24950
24951 ;;
24952esac
24953fi
24954PKGCONFIG=$ac_cv_path_PKGCONFIG
24955if test -n "$PKGCONFIG"; then
24956 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
24957$as_echo "$PKGCONFIG" >&6; }
24958else
24959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24960$as_echo "no" >&6; }
24961fi
24962
24963
24964fi
24965if test -z "$ac_cv_path_PKGCONFIG"; then
24966 ac_pt_PKGCONFIG=$PKGCONFIG
24967 # Extract the first word of "pkg-config", so it can be a program name with args.
24968set dummy pkg-config; ac_word=$2
24969{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24970$as_echo_n "checking for $ac_word... " >&6; }
24971if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
24972 $as_echo_n "(cached) " >&6
24973else
24974 case $ac_pt_PKGCONFIG in
24975 [\\/]* | ?:[\\/]*)
24976 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
24977 ;;
24978 *)
24979 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24980as_dummy="$PATH:/usr/bin:/usr/local/bin"
24981for as_dir in $as_dummy
24982do
24983 IFS=$as_save_IFS
24984 test -z "$as_dir" && as_dir=.
24985 for ac_exec_ext in '' $ac_executable_extensions; do
24986 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
24987 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
24988 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
24989 break 2
24990 fi
24991done
24992 done
24993IFS=$as_save_IFS
24994
24995 ;;
24996esac
24997fi
24998ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
24999if test -n "$ac_pt_PKGCONFIG"; then
25000 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
25001$as_echo "$ac_pt_PKGCONFIG" >&6; }
25002else
25003 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25004$as_echo "no" >&6; }
25005fi
25006
25007 if test "x$ac_pt_PKGCONFIG" = x; then
25008 PKGCONFIG="no"
25009 else
25010 case $cross_compiling:$ac_tool_warned in
25011yes:)
25012{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
25013$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
25014ac_tool_warned=yes ;;
25015esac
25016 PKGCONFIG=$ac_pt_PKGCONFIG
25017 fi
25018else
25019 PKGCONFIG="$ac_cv_path_PKGCONFIG"
25020fi
25021
25022 fi
25023
25024 if test "x$PKGCONFIG" != "xno"; then
25025 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nss options with pkg-config" >&5
25026$as_echo_n "checking for nss options with pkg-config... " >&6; }
25027 itexists=`
25028 if test -n ""; then
25029 PKG_CONFIG_LIBDIR=""
25030 export PKG_CONFIG_LIBDIR
25031 fi
25032 $PKGCONFIG --exists nss >/dev/null 2>&1 && echo 1`
25033
25034 if test -z "$itexists"; then
25035 PKGCONFIG="no"
25036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25037$as_echo "no" >&6; }
25038 else
25039 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
25040$as_echo "found" >&6; }
25041 fi
25042 fi
25043
25044
25045 if test "$PKGCONFIG" != "no" ; then
25046 addlib=`$PKGCONFIG --libs nss`
25047 addcflags=`$PKGCONFIG --cflags nss`
25048 version=`$PKGCONFIG --modversion nss`
25049 nssprefix=`$PKGCONFIG --variable=prefix nss`
25050 else
25051
25052 check=`nss-config --version 2>/dev/null`
25053 if test -n "$check"; then
25054 addlib=`nss-config --libs`
25055 addcflags=`nss-config --cflags`
25056 version=`nss-config --version`
25057 nssprefix=`nss-config --prefix`
25058 else
25059 addlib="-lnss3"
25060 addcflags=""
25061 version="unknown"
25062 fi
25063 fi
25064 else
25065 NSS_PCDIR="$OPT_NSS/lib/pkgconfig"
25066 if test -f "$NSS_PCDIR/nss.pc"; then
25067
25068 if test -n "$PKG_CONFIG"; then
25069 PKGCONFIG="$PKG_CONFIG"
25070 else
25071 if test -n "$ac_tool_prefix"; then
25072 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
25073set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
25074{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25075$as_echo_n "checking for $ac_word... " >&6; }
25076if ${ac_cv_path_PKGCONFIG+:} false; then :
25077 $as_echo_n "(cached) " >&6
25078else
25079 case $PKGCONFIG in
25080 [\\/]* | ?:[\\/]*)
25081 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
25082 ;;
25083 *)
25084 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25085as_dummy="$PATH:/usr/bin:/usr/local/bin"
25086for as_dir in $as_dummy
25087do
25088 IFS=$as_save_IFS
25089 test -z "$as_dir" && as_dir=.
25090 for ac_exec_ext in '' $ac_executable_extensions; do
25091 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25092 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
25093 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25094 break 2
25095 fi
25096done
25097 done
25098IFS=$as_save_IFS
25099
25100 ;;
25101esac
25102fi
25103PKGCONFIG=$ac_cv_path_PKGCONFIG
25104if test -n "$PKGCONFIG"; then
25105 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
25106$as_echo "$PKGCONFIG" >&6; }
25107else
25108 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25109$as_echo "no" >&6; }
25110fi
25111
25112
25113fi
25114if test -z "$ac_cv_path_PKGCONFIG"; then
25115 ac_pt_PKGCONFIG=$PKGCONFIG
25116 # Extract the first word of "pkg-config", so it can be a program name with args.
25117set dummy pkg-config; ac_word=$2
25118{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25119$as_echo_n "checking for $ac_word... " >&6; }
25120if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
25121 $as_echo_n "(cached) " >&6
25122else
25123 case $ac_pt_PKGCONFIG in
25124 [\\/]* | ?:[\\/]*)
25125 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
25126 ;;
25127 *)
25128 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25129as_dummy="$PATH:/usr/bin:/usr/local/bin"
25130for as_dir in $as_dummy
25131do
25132 IFS=$as_save_IFS
25133 test -z "$as_dir" && as_dir=.
25134 for ac_exec_ext in '' $ac_executable_extensions; do
25135 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25136 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
25137 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25138 break 2
25139 fi
25140done
25141 done
25142IFS=$as_save_IFS
25143
25144 ;;
25145esac
25146fi
25147ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
25148if test -n "$ac_pt_PKGCONFIG"; then
25149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
25150$as_echo "$ac_pt_PKGCONFIG" >&6; }
25151else
25152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25153$as_echo "no" >&6; }
25154fi
25155
25156 if test "x$ac_pt_PKGCONFIG" = x; then
25157 PKGCONFIG="no"
25158 else
25159 case $cross_compiling:$ac_tool_warned in
25160yes:)
25161{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
25162$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
25163ac_tool_warned=yes ;;
25164esac
25165 PKGCONFIG=$ac_pt_PKGCONFIG
25166 fi
25167else
25168 PKGCONFIG="$ac_cv_path_PKGCONFIG"
25169fi
25170
25171 fi
25172
25173 if test "x$PKGCONFIG" != "xno"; then
25174 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nss options with pkg-config" >&5
25175$as_echo_n "checking for nss options with pkg-config... " >&6; }
25176 itexists=`
25177 if test -n "$NSS_PCDIR"; then
25178 PKG_CONFIG_LIBDIR="$NSS_PCDIR"
25179 export PKG_CONFIG_LIBDIR
25180 fi
25181 $PKGCONFIG --exists nss >/dev/null 2>&1 && echo 1`
25182
25183 if test -z "$itexists"; then
25184 PKGCONFIG="no"
25185 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25186$as_echo "no" >&6; }
25187 else
25188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
25189$as_echo "found" >&6; }
25190 fi
25191 fi
25192
25193 if test "$PKGCONFIG" != "no" ; then
25194 addld=`
25195 if test -n "$NSS_PCDIR"; then
25196 PKG_CONFIG_LIBDIR="$NSS_PCDIR"
25197 export PKG_CONFIG_LIBDIR
25198 fi
25199 $PKGCONFIG --libs-only-L nss`
25200 addlib=`
25201 if test -n "$NSS_PCDIR"; then
25202 PKG_CONFIG_LIBDIR="$NSS_PCDIR"
25203 export PKG_CONFIG_LIBDIR
25204 fi
25205 $PKGCONFIG --libs-only-l nss`
25206 addcflags=`
25207 if test -n "$NSS_PCDIR"; then
25208 PKG_CONFIG_LIBDIR="$NSS_PCDIR"
25209 export PKG_CONFIG_LIBDIR
25210 fi
25211 $PKGCONFIG --cflags nss`
25212 version=`
25213 if test -n "$NSS_PCDIR"; then
25214 PKG_CONFIG_LIBDIR="$NSS_PCDIR"
25215 export PKG_CONFIG_LIBDIR
25216 fi
25217 $PKGCONFIG --modversion nss`
25218 nssprefix=`
25219 if test -n "$NSS_PCDIR"; then
25220 PKG_CONFIG_LIBDIR="$NSS_PCDIR"
25221 export PKG_CONFIG_LIBDIR
25222 fi
25223 $PKGCONFIG --variable=prefix nss`
25224 fi
25225 fi
25226 fi
25227
25228 if test -z "$addlib"; then
25229 # Without pkg-config, we'll kludge in some defaults
25230 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Using hard-wired libraries and compilation flags for NSS." >&5
25231$as_echo "$as_me: WARNING: Using hard-wired libraries and compilation flags for NSS." >&2;}
25232 addld="-L$OPT_NSS/lib"
25233 addlib="-lssl3 -lsmime3 -lnss3 -lplds4 -lplc4 -lnspr4"
25234 addcflags="-I$OPT_NSS/include"
25235 version="unknown"
25236 nssprefix=$OPT_NSS
25237 fi
25238
25239 CLEANLDFLAGS="$LDFLAGS"
25240 CLEANLIBS="$LIBS"
25241 CLEANCPPFLAGS="$CPPFLAGS"
25242
25243 LDFLAGS="$addld $LDFLAGS"
25244 LIBS="$addlib $LIBS"
25245 if test "$addcflags" != "-I/usr/include"; then
25246 CPPFLAGS="$CPPFLAGS $addcflags"
25247 fi
25248
25249 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SSL_VersionRangeSet in -lnss3" >&5
25250$as_echo_n "checking for SSL_VersionRangeSet in -lnss3... " >&6; }
25251if ${ac_cv_lib_nss3_SSL_VersionRangeSet+:} false; then :
25252 $as_echo_n "(cached) " >&6
25253else
25254 ac_check_lib_save_LIBS=$LIBS
25255LIBS="-lnss3 $LIBS"
25256cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25257/* end confdefs.h. */
25258
25259
25260#ifdef __cplusplus
25261extern "C"
25262#endif
25263char SSL_VersionRangeSet ();
25264int main (void)
25265{
25266return SSL_VersionRangeSet ();
25267 ;
25268 return 0;
25269}
25270_ACEOF
25271if ac_fn_c_try_link "$LINENO"; then :
25272 ac_cv_lib_nss3_SSL_VersionRangeSet=yes
25273else
25274 ac_cv_lib_nss3_SSL_VersionRangeSet=no
25275fi
25276rm -f core conftest.err conftest.$ac_objext \
25277 conftest$ac_exeext conftest.$ac_ext
25278LIBS=$ac_check_lib_save_LIBS
25279fi
25280{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nss3_SSL_VersionRangeSet" >&5
25281$as_echo "$ac_cv_lib_nss3_SSL_VersionRangeSet" >&6; }
25282if test "x$ac_cv_lib_nss3_SSL_VersionRangeSet" = xyes; then :
25283
25284
25285$as_echo "#define USE_NSS 1" >>confdefs.h
25286
25287 USE_NSS=1
25288
25289 USE_NSS="yes"
25290 NSS_ENABLED=1
Alex Deymo486467e2017-12-19 19:04:07 +010025291 ssl_msg="NSS"
25292 test nss != "$DEFAULT_SSL_BACKEND" || VALID_DEFAULT_SSL_BACKEND=yes
Elliott Hughes82be86d2017-09-20 17:00:17 -070025293
25294else
25295
25296 LDFLAGS="$CLEANLDFLAGS"
25297 LIBS="$CLEANLIBS"
25298 CPPFLAGS="$CLEANCPPFLAGS"
25299
25300fi
25301
25302
25303 if test "x$USE_NSS" = "xyes"; then
25304 { $as_echo "$as_me:${as_lineno-$LINENO}: detected NSS version $version" >&5
25305$as_echo "$as_me: detected NSS version $version" >&6;}
25306
Elliott Hughescac39802018-04-27 16:19:43 -070025307 ac_fn_c_check_func "$LINENO" "PK11_CreateManagedGenericObject" "ac_cv_func_PK11_CreateManagedGenericObject"
25308if test "x$ac_cv_func_PK11_CreateManagedGenericObject" = xyes; then :
25309
25310
25311$as_echo "#define HAVE_PK11_CREATEMANAGEDGENERICOBJECT 1" >>confdefs.h
25312
25313
25314fi
25315
25316
Elliott Hughes82be86d2017-09-20 17:00:17 -070025317 NSS_LIBS=$addlib
25318
25319
25320 if test "x$cross_compiling" != "xyes"; then
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070025321 CURL_LIBRARY_PATH="$CURL_LIBRARY_PATH:$nssprefix/lib$libsuff"
25322 export CURL_LIBRARY_PATH
25323 { $as_echo "$as_me:${as_lineno-$LINENO}: Added $nssprefix/lib$libsuff to CURL_LIBRARY_PATH" >&5
25324$as_echo "$as_me: Added $nssprefix/lib$libsuff to CURL_LIBRARY_PATH" >&6;}
Elliott Hughes82be86d2017-09-20 17:00:17 -070025325 fi
25326
25327 fi
25328 fi
Alex Deymo486467e2017-12-19 19:04:07 +010025329 test -z "$ssl_msg" || ssl_backends="${ssl_backends:+$ssl_backends, }$ssl_msg"
Elliott Hughes82be86d2017-09-20 17:00:17 -070025330fi
Alex Deymo486467e2017-12-19 19:04:07 +010025331
Haibo Huang001784b2019-07-19 05:27:28 -070025332case "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 +010025333x)
Elliott Hughes82be86d2017-09-20 17:00:17 -070025334 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: SSL disabled, you will not be able to use HTTPS, FTPS, NTLM and more." >&5
25335$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 -070025336 { $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
25337$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 +010025338 ;;
25339x1)
25340 # one SSL backend is enabled
Elliott Hughes82be86d2017-09-20 17:00:17 -070025341
25342 SSL_ENABLED="1"
Alex Deymo486467e2017-12-19 19:04:07 +010025343 { $as_echo "$as_me:${as_lineno-$LINENO}: built with one SSL backend" >&5
25344$as_echo "$as_me: built with one SSL backend" >&6;}
25345 ;;
25346*)
25347 # more than one SSL backend is enabled
25348
25349 SSL_ENABLED="1"
25350
25351 CURL_WITH_MULTI_SSL="1"
25352
25353$as_echo "#define CURL_WITH_MULTI_SSL 1" >>confdefs.h
25354
25355 { $as_echo "$as_me:${as_lineno-$LINENO}: built with multiple SSL backends" >&5
25356$as_echo "$as_me: built with multiple SSL backends" >&6;}
25357 ;;
25358esac
25359
25360if test -n "$ssl_backends"; then
25361 curl_ssl_msg="enabled ($ssl_backends)"
25362fi
25363
25364if test no = "$VALID_DEFAULT_SSL_BACKEND"
25365then
25366 if test -n "$SSL_ENABLED"
25367 then
25368 as_fn_error $? "Default SSL backend $DEFAULT_SSL_BACKEND not enabled!" "$LINENO" 5
25369 else
25370 as_fn_error $? "Default SSL backend requires SSL!" "$LINENO" 5
25371 fi
25372elif test yes = "$VALID_DEFAULT_SSL_BACKEND"
25373then
25374
25375cat >>confdefs.h <<_ACEOF
25376#define CURL_DEFAULT_SSL_BACKEND "$DEFAULT_SSL_BACKEND"
25377_ACEOF
25378
Elliott Hughes82be86d2017-09-20 17:00:17 -070025379fi
25380
25381
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070025382if test "$check_for_ca_bundle" -gt 0; then
Elliott Hughes82be86d2017-09-20 17:00:17 -070025383
25384
25385 { $as_echo "$as_me:${as_lineno-$LINENO}: checking default CA cert bundle/path" >&5
25386$as_echo_n "checking default CA cert bundle/path... " >&6; }
25387
25388
25389# Check whether --with-ca-bundle was given.
25390if test "${with_ca_bundle+set}" = set; then :
25391 withval=$with_ca_bundle;
25392 want_ca="$withval"
25393 if test "x$want_ca" = "xyes"; then
25394 as_fn_error $? "--with-ca-bundle=FILE requires a path to the CA bundle" "$LINENO" 5
25395 fi
25396
25397else
25398 want_ca="unset"
25399fi
25400
25401
25402# Check whether --with-ca-path was given.
25403if test "${with_ca_path+set}" = set; then :
25404 withval=$with_ca_path;
25405 want_capath="$withval"
25406 if test "x$want_capath" = "xyes"; then
25407 as_fn_error $? "--with-ca-path=DIRECTORY requires a path to the CA path directory" "$LINENO" 5
25408 fi
25409
25410else
25411 want_capath="unset"
25412fi
25413
25414
25415 ca_warning=" (warning: certs not found)"
25416 capath_warning=" (warning: certs not found)"
25417 check_capath=""
25418
25419 if test "x$want_ca" != "xno" -a "x$want_ca" != "xunset" -a \
25420 "x$want_capath" != "xno" -a "x$want_capath" != "xunset"; then
25421 ca="$want_ca"
25422 capath="$want_capath"
25423 elif test "x$want_ca" != "xno" -a "x$want_ca" != "xunset"; then
25424 ca="$want_ca"
25425 capath="no"
25426 elif test "x$want_capath" != "xno" -a "x$want_capath" != "xunset"; then
25427 if test "x$OPENSSL_ENABLED" != "x1" -a "x$GNUTLS_ENABLED" != "x1" -a "x$POLARSSL_ENABLED" != "x1"; then
25428 as_fn_error $? "--with-ca-path only works with OpenSSL, GnuTLS or PolarSSL" "$LINENO" 5
25429 fi
25430 capath="$want_capath"
25431 ca="no"
25432 else
25433 ca="no"
25434 capath="no"
25435 if test "x$cross_compiling" != "xyes"; then
25436 if test "x$want_ca" = "xunset"; then
25437 if test "x$prefix" != xNONE; then
25438 cac="${prefix}/share/curl/curl-ca-bundle.crt"
25439 else
25440 cac="$ac_default_prefix/share/curl/curl-ca-bundle.crt"
25441 fi
25442
25443 for a in /etc/ssl/certs/ca-certificates.crt \
25444 /etc/pki/tls/certs/ca-bundle.crt \
25445 /usr/share/ssl/certs/ca-bundle.crt \
25446 /usr/local/share/certs/ca-root-nss.crt \
25447 /etc/ssl/cert.pem \
25448 "$cac"; do
25449 if test -f "$a"; then
25450 ca="$a"
25451 break
25452 fi
25453 done
25454 fi
25455 if test "x$want_capath" = "xunset" -a "x$ca" = "xno" -a \
25456 "x$OPENSSL_ENABLED" = "x1"; then
25457 check_capath="/etc/ssl/certs/"
25458 fi
25459 else
25460 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: skipped the ca-cert path detection when cross-compiling" >&5
25461$as_echo "$as_me: WARNING: skipped the ca-cert path detection when cross-compiling" >&2;}
25462 fi
25463 fi
25464
25465 if test "x$ca" = "xno" || test -f "$ca"; then
25466 ca_warning=""
25467 fi
25468
25469 if test "x$capath" != "xno"; then
25470 check_capath="$capath"
25471 fi
25472
25473 if test ! -z "$check_capath"; then
25474 for a in "$check_capath"; do
25475 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
25476 if test "x$capath" = "xno"; then
25477 capath="$a"
25478 fi
25479 capath_warning=""
25480 break
25481 fi
25482 done
25483 fi
25484
25485 if test "x$capath" = "xno"; then
25486 capath_warning=""
25487 fi
25488
25489 if test "x$ca" != "xno"; then
25490 CURL_CA_BUNDLE='"'$ca'"'
25491
25492cat >>confdefs.h <<_ACEOF
25493#define CURL_CA_BUNDLE "$ca"
25494_ACEOF
25495
25496
25497 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ca" >&5
25498$as_echo "$ca" >&6; }
25499 fi
25500 if test "x$capath" != "xno"; then
25501 CURL_CA_PATH="\"$capath\""
25502
25503cat >>confdefs.h <<_ACEOF
25504#define CURL_CA_PATH "$capath"
25505_ACEOF
25506
25507 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $capath (capath)" >&5
25508$as_echo "$capath (capath)" >&6; }
25509 fi
25510 if test "x$ca" = "xno" && test "x$capath" = "xno"; then
25511 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25512$as_echo "no" >&6; }
25513 fi
25514
25515 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use builtin CA store of SSL library" >&5
25516$as_echo_n "checking whether to use builtin CA store of SSL library... " >&6; }
25517
25518# Check whether --with-ca-fallback was given.
25519if test "${with_ca_fallback+set}" = set; then :
25520 withval=$with_ca_fallback;
25521 if test "x$with_ca_fallback" != "xyes" -a "x$with_ca_fallback" != "xno"; then
25522 as_fn_error $? "--with-ca-fallback only allows yes or no as parameter" "$LINENO" 5
25523 fi
25524
25525else
25526 with_ca_fallback="no"
25527fi
25528
25529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_ca_fallback" >&5
25530$as_echo "$with_ca_fallback" >&6; }
25531 if test "x$with_ca_fallback" = "xyes"; then
25532 if test "x$OPENSSL_ENABLED" != "x1" -a "x$GNUTLS_ENABLED" != "x1"; then
25533 as_fn_error $? "--with-ca-fallback only works with OpenSSL or GnuTLS" "$LINENO" 5
25534 fi
25535
25536cat >>confdefs.h <<_ACEOF
25537#define CURL_CA_FALLBACK 1
25538_ACEOF
25539
25540 fi
25541
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070025542fi
Elliott Hughes82be86d2017-09-20 17:00:17 -070025543
25544
25545
25546# Check whether --with-libpsl was given.
25547if test "${with_libpsl+set}" = set; then :
25548 withval=$with_libpsl; with_libpsl=$withval
25549else
25550 with_libpsl=yes
25551fi
25552
25553if test $with_libpsl != "no"; then
25554 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing psl_builtin" >&5
25555$as_echo_n "checking for library containing psl_builtin... " >&6; }
25556if ${ac_cv_search_psl_builtin+:} false; then :
25557 $as_echo_n "(cached) " >&6
25558else
25559 ac_func_search_save_LIBS=$LIBS
25560cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25561/* end confdefs.h. */
25562
25563
25564#ifdef __cplusplus
25565extern "C"
25566#endif
25567char psl_builtin ();
25568int main (void)
25569{
25570return psl_builtin ();
25571 ;
25572 return 0;
25573}
25574_ACEOF
25575for ac_lib in '' psl; do
25576 if test -z "$ac_lib"; then
25577 ac_res="none required"
25578 else
25579 ac_res=-l$ac_lib
25580 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
25581 fi
25582 if ac_fn_c_try_link "$LINENO"; then :
25583 ac_cv_search_psl_builtin=$ac_res
25584fi
25585rm -f core conftest.err conftest.$ac_objext \
25586 conftest$ac_exeext
25587 if ${ac_cv_search_psl_builtin+:} false; then :
25588 break
25589fi
25590done
25591if ${ac_cv_search_psl_builtin+:} false; then :
25592
25593else
25594 ac_cv_search_psl_builtin=no
25595fi
25596rm conftest.$ac_ext
25597LIBS=$ac_func_search_save_LIBS
25598fi
25599{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_psl_builtin" >&5
25600$as_echo "$ac_cv_search_psl_builtin" >&6; }
25601ac_res=$ac_cv_search_psl_builtin
25602if test "$ac_res" != no; then :
25603 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
Haibo Huang65021c72019-03-27 15:37:23 -070025604 curl_psl_msg="enabled";
Elliott Hughes82be86d2017-09-20 17:00:17 -070025605
25606$as_echo "#define USE_LIBPSL 1" >>confdefs.h
25607
25608
25609else
25610 curl_psl_msg="no (libpsl not found)";
25611 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libpsl was not found" >&5
25612$as_echo "$as_me: WARNING: libpsl was not found" >&2;}
25613
25614
25615fi
25616
25617fi
Haibo Huang65021c72019-03-27 15:37:23 -070025618 if test "$curl_psl_msg" = "enabled"; then
Elliott Hughes82be86d2017-09-20 17:00:17 -070025619 USE_LIBPSL_TRUE=
25620 USE_LIBPSL_FALSE='#'
25621else
25622 USE_LIBPSL_TRUE='#'
25623 USE_LIBPSL_FALSE=
25624fi
25625
25626
25627
25628OPT_LIBMETALINK=no
25629
25630
25631# Check whether --with-libmetalink was given.
25632if test "${with_libmetalink+set}" = set; then :
25633 withval=$with_libmetalink; OPT_LIBMETALINK=$withval
25634fi
25635
25636
25637if test X"$OPT_LIBMETALINK" != Xno; then
25638
25639 addld=""
25640 addlib=""
25641 addcflags=""
25642 version=""
25643 libmetalinklib=""
25644
25645 PKGTEST="no"
25646 if test "x$OPT_LIBMETALINK" = "xyes"; then
25647 PKGTEST="yes"
25648
25649 if test -n "$PKG_CONFIG"; then
25650 PKGCONFIG="$PKG_CONFIG"
25651 else
25652 if test -n "$ac_tool_prefix"; then
25653 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
25654set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
25655{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25656$as_echo_n "checking for $ac_word... " >&6; }
25657if ${ac_cv_path_PKGCONFIG+:} false; then :
25658 $as_echo_n "(cached) " >&6
25659else
25660 case $PKGCONFIG in
25661 [\\/]* | ?:[\\/]*)
25662 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
25663 ;;
25664 *)
25665 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25666as_dummy="$PATH:/usr/bin:/usr/local/bin"
25667for as_dir in $as_dummy
25668do
25669 IFS=$as_save_IFS
25670 test -z "$as_dir" && as_dir=.
25671 for ac_exec_ext in '' $ac_executable_extensions; do
25672 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25673 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
25674 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25675 break 2
25676 fi
25677done
25678 done
25679IFS=$as_save_IFS
25680
25681 ;;
25682esac
25683fi
25684PKGCONFIG=$ac_cv_path_PKGCONFIG
25685if test -n "$PKGCONFIG"; then
25686 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
25687$as_echo "$PKGCONFIG" >&6; }
25688else
25689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25690$as_echo "no" >&6; }
25691fi
25692
25693
25694fi
25695if test -z "$ac_cv_path_PKGCONFIG"; then
25696 ac_pt_PKGCONFIG=$PKGCONFIG
25697 # Extract the first word of "pkg-config", so it can be a program name with args.
25698set dummy pkg-config; ac_word=$2
25699{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25700$as_echo_n "checking for $ac_word... " >&6; }
25701if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
25702 $as_echo_n "(cached) " >&6
25703else
25704 case $ac_pt_PKGCONFIG in
25705 [\\/]* | ?:[\\/]*)
25706 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
25707 ;;
25708 *)
25709 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25710as_dummy="$PATH:/usr/bin:/usr/local/bin"
25711for as_dir in $as_dummy
25712do
25713 IFS=$as_save_IFS
25714 test -z "$as_dir" && as_dir=.
25715 for ac_exec_ext in '' $ac_executable_extensions; do
25716 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25717 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
25718 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25719 break 2
25720 fi
25721done
25722 done
25723IFS=$as_save_IFS
25724
25725 ;;
25726esac
25727fi
25728ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
25729if test -n "$ac_pt_PKGCONFIG"; then
25730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
25731$as_echo "$ac_pt_PKGCONFIG" >&6; }
25732else
25733 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25734$as_echo "no" >&6; }
25735fi
25736
25737 if test "x$ac_pt_PKGCONFIG" = x; then
25738 PKGCONFIG="no"
25739 else
25740 case $cross_compiling:$ac_tool_warned in
25741yes:)
25742{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
25743$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
25744ac_tool_warned=yes ;;
25745esac
25746 PKGCONFIG=$ac_pt_PKGCONFIG
25747 fi
25748else
25749 PKGCONFIG="$ac_cv_path_PKGCONFIG"
25750fi
25751
25752 fi
25753
25754 if test "x$PKGCONFIG" != "xno"; then
25755 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libmetalink options with pkg-config" >&5
25756$as_echo_n "checking for libmetalink options with pkg-config... " >&6; }
25757 itexists=`
25758 if test -n ""; then
25759 PKG_CONFIG_LIBDIR=""
25760 export PKG_CONFIG_LIBDIR
25761 fi
25762 $PKGCONFIG --exists libmetalink >/dev/null 2>&1 && echo 1`
25763
25764 if test -z "$itexists"; then
25765 PKGCONFIG="no"
25766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25767$as_echo "no" >&6; }
25768 else
25769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
25770$as_echo "found" >&6; }
25771 fi
25772 fi
25773
25774 else
25775 LIBMETALINK_PCDIR="$OPT_LIBMETALINK/lib/pkgconfig"
25776 { $as_echo "$as_me:${as_lineno-$LINENO}: PKG_CONFIG_LIBDIR will be set to \"$LIBMETALINK_PCDIR\"" >&5
25777$as_echo "$as_me: PKG_CONFIG_LIBDIR will be set to \"$LIBMETALINK_PCDIR\"" >&6;}
25778 if test -f "$LIBMETALINK_PCDIR/libmetalink.pc"; then
25779 PKGTEST="yes"
25780 fi
25781 if test "$PKGTEST" = "yes"; then
25782
25783 if test -n "$PKG_CONFIG"; then
25784 PKGCONFIG="$PKG_CONFIG"
25785 else
25786 if test -n "$ac_tool_prefix"; then
25787 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
25788set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
25789{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25790$as_echo_n "checking for $ac_word... " >&6; }
25791if ${ac_cv_path_PKGCONFIG+:} false; then :
25792 $as_echo_n "(cached) " >&6
25793else
25794 case $PKGCONFIG in
25795 [\\/]* | ?:[\\/]*)
25796 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
25797 ;;
25798 *)
25799 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25800as_dummy="$PATH:/usr/bin:/usr/local/bin"
25801for as_dir in $as_dummy
25802do
25803 IFS=$as_save_IFS
25804 test -z "$as_dir" && as_dir=.
25805 for ac_exec_ext in '' $ac_executable_extensions; do
25806 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25807 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
25808 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25809 break 2
25810 fi
25811done
25812 done
25813IFS=$as_save_IFS
25814
25815 ;;
25816esac
25817fi
25818PKGCONFIG=$ac_cv_path_PKGCONFIG
25819if test -n "$PKGCONFIG"; then
25820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
25821$as_echo "$PKGCONFIG" >&6; }
25822else
25823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25824$as_echo "no" >&6; }
25825fi
25826
25827
25828fi
25829if test -z "$ac_cv_path_PKGCONFIG"; then
25830 ac_pt_PKGCONFIG=$PKGCONFIG
25831 # Extract the first word of "pkg-config", so it can be a program name with args.
25832set dummy pkg-config; ac_word=$2
25833{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
25834$as_echo_n "checking for $ac_word... " >&6; }
25835if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
25836 $as_echo_n "(cached) " >&6
25837else
25838 case $ac_pt_PKGCONFIG in
25839 [\\/]* | ?:[\\/]*)
25840 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
25841 ;;
25842 *)
25843 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
25844as_dummy="$PATH:/usr/bin:/usr/local/bin"
25845for as_dir in $as_dummy
25846do
25847 IFS=$as_save_IFS
25848 test -z "$as_dir" && as_dir=.
25849 for ac_exec_ext in '' $ac_executable_extensions; do
25850 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
25851 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
25852 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
25853 break 2
25854 fi
25855done
25856 done
25857IFS=$as_save_IFS
25858
25859 ;;
25860esac
25861fi
25862ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
25863if test -n "$ac_pt_PKGCONFIG"; then
25864 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
25865$as_echo "$ac_pt_PKGCONFIG" >&6; }
25866else
25867 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25868$as_echo "no" >&6; }
25869fi
25870
25871 if test "x$ac_pt_PKGCONFIG" = x; then
25872 PKGCONFIG="no"
25873 else
25874 case $cross_compiling:$ac_tool_warned in
25875yes:)
25876{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
25877$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
25878ac_tool_warned=yes ;;
25879esac
25880 PKGCONFIG=$ac_pt_PKGCONFIG
25881 fi
25882else
25883 PKGCONFIG="$ac_cv_path_PKGCONFIG"
25884fi
25885
25886 fi
25887
25888 if test "x$PKGCONFIG" != "xno"; then
25889 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libmetalink options with pkg-config" >&5
25890$as_echo_n "checking for libmetalink options with pkg-config... " >&6; }
25891 itexists=`
25892 if test -n "$LIBMETALINK_PCDIR"; then
25893 PKG_CONFIG_LIBDIR="$LIBMETALINK_PCDIR"
25894 export PKG_CONFIG_LIBDIR
25895 fi
25896 $PKGCONFIG --exists libmetalink >/dev/null 2>&1 && echo 1`
25897
25898 if test -z "$itexists"; then
25899 PKGCONFIG="no"
25900 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25901$as_echo "no" >&6; }
25902 else
25903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
25904$as_echo "found" >&6; }
25905 fi
25906 fi
25907
25908 fi
25909 fi
25910 if test "$PKGTEST" = "yes" && test "$PKGCONFIG" != "no"; then
25911 addlib=`
25912 if test -n "$LIBMETALINK_PCDIR"; then
25913 PKG_CONFIG_LIBDIR="$LIBMETALINK_PCDIR"
25914 export PKG_CONFIG_LIBDIR
25915 fi
25916 $PKGCONFIG --libs-only-l libmetalink`
25917 addld=`
25918 if test -n "$LIBMETALINK_PCDIR"; then
25919 PKG_CONFIG_LIBDIR="$LIBMETALINK_PCDIR"
25920 export PKG_CONFIG_LIBDIR
25921 fi
25922 $PKGCONFIG --libs-only-L libmetalink`
25923 addcflags=`
25924 if test -n "$LIBMETALINK_PCDIR"; then
25925 PKG_CONFIG_LIBDIR="$LIBMETALINK_PCDIR"
25926 export PKG_CONFIG_LIBDIR
25927 fi
25928 $PKGCONFIG --cflags-only-I libmetalink`
25929 version=`
25930 if test -n "$LIBMETALINK_PCDIR"; then
25931 PKG_CONFIG_LIBDIR="$LIBMETALINK_PCDIR"
25932 export PKG_CONFIG_LIBDIR
25933 fi
25934 $PKGCONFIG --modversion libmetalink`
25935 libmetalinklib=`echo $addld | $SED -e 's/-L//'`
25936 fi
25937 if test -n "$addlib"; then
25938
25939 clean_CPPFLAGS="$CPPFLAGS"
25940 clean_LDFLAGS="$LDFLAGS"
25941 clean_LIBS="$LIBS"
25942 CPPFLAGS="$clean_CPPFLAGS $addcflags"
25943 LDFLAGS="$clean_LDFLAGS $addld"
25944 LIBS="$addlib $clean_LIBS"
25945 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libmetalink is recent enough" >&5
25946$as_echo_n "checking if libmetalink is recent enough... " >&6; }
25947 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25948/* end confdefs.h. */
25949
25950
25951# include <metalink/metalink.h>
25952
25953int main (void)
25954{
25955
25956 if(0 != metalink_strerror(0)) /* added in 0.1.0 */
25957 return 1;
25958
25959 ;
25960 return 0;
25961}
25962
25963_ACEOF
25964if ac_fn_c_try_link "$LINENO"; then :
25965
25966 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes ($version)" >&5
25967$as_echo "yes ($version)" >&6; }
25968 want_metalink="yes"
25969
25970else
25971
25972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no ($version)" >&5
25973$as_echo "no ($version)" >&6; }
25974 { $as_echo "$as_me:${as_lineno-$LINENO}: libmetalink library defective or too old" >&5
25975$as_echo "$as_me: libmetalink library defective or too old" >&6;}
25976 want_metalink="no"
25977
25978fi
25979rm -f core conftest.err conftest.$ac_objext \
25980 conftest$ac_exeext conftest.$ac_ext
25981 CPPFLAGS="$clean_CPPFLAGS"
25982 LDFLAGS="$clean_LDFLAGS"
25983 LIBS="$clean_LIBS"
25984 if test "$want_metalink" = "yes"; then
25985
25986$as_echo "#define USE_METALINK 1" >>confdefs.h
25987
25988 LIBMETALINK_LIBS=$addlib
25989 LIBMETALINK_LDFLAGS=$addld
25990 LIBMETALINK_CPPFLAGS=$addcflags
25991
25992
25993
25994 curl_mtlnk_msg="enabled"
25995 fi
25996
25997 fi
25998fi
25999
26000
26001OPT_LIBSSH2=off
26002
26003# Check whether --with-libssh2 was given.
26004if test "${with_libssh2+set}" = set; then :
26005 withval=$with_libssh2; OPT_LIBSSH2=$withval
Elliott Hughes0128fe42018-02-27 14:57:55 -080026006else
26007 OPT_LIBSSH2=no
26008fi
26009
26010
26011
26012OPT_LIBSSH=off
26013
26014# Check whether --with-libssh was given.
26015if test "${with_libssh+set}" = set; then :
26016 withval=$with_libssh; OPT_LIBSSH=$withval
26017else
26018 OPT_LIBSSH=no
Elliott Hughes82be86d2017-09-20 17:00:17 -070026019fi
26020
26021
26022if test X"$OPT_LIBSSH2" != Xno; then
26023 CLEANLDFLAGS="$LDFLAGS"
26024 CLEANCPPFLAGS="$CPPFLAGS"
26025 CLEANLIBS="$LIBS"
26026
26027 case "$OPT_LIBSSH2" in
26028 yes)
26029
26030 if test -n "$PKG_CONFIG"; then
26031 PKGCONFIG="$PKG_CONFIG"
26032 else
26033 if test -n "$ac_tool_prefix"; then
26034 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
26035set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
26036{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
26037$as_echo_n "checking for $ac_word... " >&6; }
26038if ${ac_cv_path_PKGCONFIG+:} false; then :
26039 $as_echo_n "(cached) " >&6
26040else
26041 case $PKGCONFIG in
26042 [\\/]* | ?:[\\/]*)
26043 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
26044 ;;
26045 *)
26046 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26047as_dummy="$PATH:/usr/bin:/usr/local/bin"
26048for as_dir in $as_dummy
26049do
26050 IFS=$as_save_IFS
26051 test -z "$as_dir" && as_dir=.
26052 for ac_exec_ext in '' $ac_executable_extensions; do
26053 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
26054 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
26055 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
26056 break 2
26057 fi
26058done
26059 done
26060IFS=$as_save_IFS
26061
26062 ;;
26063esac
26064fi
26065PKGCONFIG=$ac_cv_path_PKGCONFIG
26066if test -n "$PKGCONFIG"; then
26067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
26068$as_echo "$PKGCONFIG" >&6; }
26069else
26070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26071$as_echo "no" >&6; }
26072fi
26073
26074
26075fi
26076if test -z "$ac_cv_path_PKGCONFIG"; then
26077 ac_pt_PKGCONFIG=$PKGCONFIG
26078 # Extract the first word of "pkg-config", so it can be a program name with args.
26079set dummy pkg-config; ac_word=$2
26080{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
26081$as_echo_n "checking for $ac_word... " >&6; }
26082if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
26083 $as_echo_n "(cached) " >&6
26084else
26085 case $ac_pt_PKGCONFIG in
26086 [\\/]* | ?:[\\/]*)
26087 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
26088 ;;
26089 *)
26090 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26091as_dummy="$PATH:/usr/bin:/usr/local/bin"
26092for as_dir in $as_dummy
26093do
26094 IFS=$as_save_IFS
26095 test -z "$as_dir" && as_dir=.
26096 for ac_exec_ext in '' $ac_executable_extensions; do
26097 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
26098 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
26099 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
26100 break 2
26101 fi
26102done
26103 done
26104IFS=$as_save_IFS
26105
26106 ;;
26107esac
26108fi
26109ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
26110if test -n "$ac_pt_PKGCONFIG"; then
26111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
26112$as_echo "$ac_pt_PKGCONFIG" >&6; }
26113else
26114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26115$as_echo "no" >&6; }
26116fi
26117
26118 if test "x$ac_pt_PKGCONFIG" = x; then
26119 PKGCONFIG="no"
26120 else
26121 case $cross_compiling:$ac_tool_warned in
26122yes:)
26123{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
26124$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
26125ac_tool_warned=yes ;;
26126esac
26127 PKGCONFIG=$ac_pt_PKGCONFIG
26128 fi
26129else
26130 PKGCONFIG="$ac_cv_path_PKGCONFIG"
26131fi
26132
26133 fi
26134
26135 if test "x$PKGCONFIG" != "xno"; then
26136 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libssh2 options with pkg-config" >&5
26137$as_echo_n "checking for libssh2 options with pkg-config... " >&6; }
26138 itexists=`
26139 if test -n ""; then
26140 PKG_CONFIG_LIBDIR=""
26141 export PKG_CONFIG_LIBDIR
26142 fi
26143 $PKGCONFIG --exists libssh2 >/dev/null 2>&1 && echo 1`
26144
26145 if test -z "$itexists"; then
26146 PKGCONFIG="no"
26147 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26148$as_echo "no" >&6; }
26149 else
26150 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
26151$as_echo "found" >&6; }
26152 fi
26153 fi
26154
26155
26156 if test "$PKGCONFIG" != "no" ; then
Elliott Hughes72d948d2018-08-03 14:37:21 -070026157 LIB_SSH2=`$PKGCONFIG --libs libssh2`
Elliott Hughes82be86d2017-09-20 17:00:17 -070026158 LD_SSH2=`$PKGCONFIG --libs-only-L libssh2`
26159 CPP_SSH2=`$PKGCONFIG --cflags-only-I libssh2`
26160 version=`$PKGCONFIG --modversion libssh2`
26161 DIR_SSH2=`echo $LD_SSH2 | $SED -e 's/-L//'`
26162 fi
26163
26164 ;;
26165 off)
26166 ;;
26167 *)
26168 PREFIX_SSH2=$OPT_LIBSSH2
26169 ;;
26170 esac
26171
26172 if test -n "$PREFIX_SSH2"; then
26173 LIB_SSH2="-lssh2"
26174 LD_SSH2=-L${PREFIX_SSH2}/lib$libsuff
26175 CPP_SSH2=-I${PREFIX_SSH2}/include
26176 DIR_SSH2=${PREFIX_SSH2}/lib$libsuff
26177 fi
26178
26179 LDFLAGS="$LDFLAGS $LD_SSH2"
26180 CPPFLAGS="$CPPFLAGS $CPP_SSH2"
26181 LIBS="$LIB_SSH2 $LIBS"
26182
26183 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libssh2_channel_open_ex in -lssh2" >&5
26184$as_echo_n "checking for libssh2_channel_open_ex in -lssh2... " >&6; }
26185if ${ac_cv_lib_ssh2_libssh2_channel_open_ex+:} false; then :
26186 $as_echo_n "(cached) " >&6
26187else
26188 ac_check_lib_save_LIBS=$LIBS
26189LIBS="-lssh2 $LIBS"
26190cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26191/* end confdefs.h. */
26192
26193
26194#ifdef __cplusplus
26195extern "C"
26196#endif
26197char libssh2_channel_open_ex ();
26198int main (void)
26199{
26200return libssh2_channel_open_ex ();
26201 ;
26202 return 0;
26203}
26204_ACEOF
26205if ac_fn_c_try_link "$LINENO"; then :
26206 ac_cv_lib_ssh2_libssh2_channel_open_ex=yes
26207else
26208 ac_cv_lib_ssh2_libssh2_channel_open_ex=no
26209fi
26210rm -f core conftest.err conftest.$ac_objext \
26211 conftest$ac_exeext conftest.$ac_ext
26212LIBS=$ac_check_lib_save_LIBS
26213fi
26214{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ssh2_libssh2_channel_open_ex" >&5
26215$as_echo "$ac_cv_lib_ssh2_libssh2_channel_open_ex" >&6; }
26216if test "x$ac_cv_lib_ssh2_libssh2_channel_open_ex" = xyes; then :
26217 cat >>confdefs.h <<_ACEOF
26218#define HAVE_LIBSSH2 1
26219_ACEOF
26220
26221 LIBS="-lssh2 $LIBS"
26222
26223fi
26224
26225
26226 for ac_header in libssh2.h
26227do :
26228 ac_fn_c_check_header_mongrel "$LINENO" "libssh2.h" "ac_cv_header_libssh2_h" "$ac_includes_default"
26229if test "x$ac_cv_header_libssh2_h" = xyes; then :
26230 cat >>confdefs.h <<_ACEOF
26231#define HAVE_LIBSSH2_H 1
26232_ACEOF
26233 curl_ssh_msg="enabled (libSSH2)"
26234 LIBSSH2_ENABLED=1
26235
26236$as_echo "#define USE_LIBSSH2 1" >>confdefs.h
26237
26238 USE_LIBSSH2=1
26239
26240
26241fi
26242
26243done
26244
26245
26246 if test X"$OPT_LIBSSH2" != Xoff &&
26247 test "$LIBSSH2_ENABLED" != "1"; then
26248 as_fn_error $? "libSSH2 libs and/or directories were not found where specified!" "$LINENO" 5
26249 fi
26250
26251 if test "$LIBSSH2_ENABLED" = "1"; then
26252 if test -n "$DIR_SSH2"; then
26253
26254 if test "x$cross_compiling" != "xyes"; then
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070026255 CURL_LIBRARY_PATH="$CURL_LIBRARY_PATH:$DIR_SSH2"
26256 export CURL_LIBRARY_PATH
26257 { $as_echo "$as_me:${as_lineno-$LINENO}: Added $DIR_SSH2 to CURL_LIBRARY_PATH" >&5
26258$as_echo "$as_me: Added $DIR_SSH2 to CURL_LIBRARY_PATH" >&6;}
Elliott Hughes82be86d2017-09-20 17:00:17 -070026259 fi
26260 fi
26261 else
26262 LDFLAGS=$CLEANLDFLAGS
26263 CPPFLAGS=$CLEANCPPFLAGS
26264 LIBS=$CLEANLIBS
26265 fi
Elliott Hughes0128fe42018-02-27 14:57:55 -080026266elif test X"$OPT_LIBSSH" != Xno; then
26267 CLEANLDFLAGS="$LDFLAGS"
26268 CLEANCPPFLAGS="$CPPFLAGS"
26269 CLEANLIBS="$LIBS"
26270
26271 case "$OPT_LIBSSH" in
26272 yes)
26273
26274 if test -n "$PKG_CONFIG"; then
26275 PKGCONFIG="$PKG_CONFIG"
26276 else
26277 if test -n "$ac_tool_prefix"; then
26278 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
26279set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
26280{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
26281$as_echo_n "checking for $ac_word... " >&6; }
26282if ${ac_cv_path_PKGCONFIG+:} false; then :
26283 $as_echo_n "(cached) " >&6
26284else
26285 case $PKGCONFIG in
26286 [\\/]* | ?:[\\/]*)
26287 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
26288 ;;
26289 *)
26290 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26291as_dummy="$PATH:/usr/bin:/usr/local/bin"
26292for as_dir in $as_dummy
26293do
26294 IFS=$as_save_IFS
26295 test -z "$as_dir" && as_dir=.
26296 for ac_exec_ext in '' $ac_executable_extensions; do
26297 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
26298 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
26299 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
26300 break 2
26301 fi
26302done
26303 done
26304IFS=$as_save_IFS
26305
26306 ;;
26307esac
26308fi
26309PKGCONFIG=$ac_cv_path_PKGCONFIG
26310if test -n "$PKGCONFIG"; then
26311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
26312$as_echo "$PKGCONFIG" >&6; }
26313else
26314 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26315$as_echo "no" >&6; }
26316fi
26317
26318
26319fi
26320if test -z "$ac_cv_path_PKGCONFIG"; then
26321 ac_pt_PKGCONFIG=$PKGCONFIG
26322 # Extract the first word of "pkg-config", so it can be a program name with args.
26323set dummy pkg-config; ac_word=$2
26324{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
26325$as_echo_n "checking for $ac_word... " >&6; }
26326if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
26327 $as_echo_n "(cached) " >&6
26328else
26329 case $ac_pt_PKGCONFIG in
26330 [\\/]* | ?:[\\/]*)
26331 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
26332 ;;
26333 *)
26334 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26335as_dummy="$PATH:/usr/bin:/usr/local/bin"
26336for as_dir in $as_dummy
26337do
26338 IFS=$as_save_IFS
26339 test -z "$as_dir" && as_dir=.
26340 for ac_exec_ext in '' $ac_executable_extensions; do
26341 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
26342 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
26343 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
26344 break 2
26345 fi
26346done
26347 done
26348IFS=$as_save_IFS
26349
26350 ;;
26351esac
26352fi
26353ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
26354if test -n "$ac_pt_PKGCONFIG"; then
26355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
26356$as_echo "$ac_pt_PKGCONFIG" >&6; }
26357else
26358 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26359$as_echo "no" >&6; }
26360fi
26361
26362 if test "x$ac_pt_PKGCONFIG" = x; then
26363 PKGCONFIG="no"
26364 else
26365 case $cross_compiling:$ac_tool_warned in
26366yes:)
26367{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
26368$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
26369ac_tool_warned=yes ;;
26370esac
26371 PKGCONFIG=$ac_pt_PKGCONFIG
26372 fi
26373else
26374 PKGCONFIG="$ac_cv_path_PKGCONFIG"
26375fi
26376
26377 fi
26378
26379 if test "x$PKGCONFIG" != "xno"; then
26380 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libssh options with pkg-config" >&5
26381$as_echo_n "checking for libssh options with pkg-config... " >&6; }
26382 itexists=`
26383 if test -n ""; then
26384 PKG_CONFIG_LIBDIR=""
26385 export PKG_CONFIG_LIBDIR
26386 fi
26387 $PKGCONFIG --exists libssh >/dev/null 2>&1 && echo 1`
26388
26389 if test -z "$itexists"; then
26390 PKGCONFIG="no"
26391 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26392$as_echo "no" >&6; }
26393 else
26394 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
26395$as_echo "found" >&6; }
26396 fi
26397 fi
26398
26399
26400 if test "$PKGCONFIG" != "no" ; then
26401 LIB_SSH=`$PKGCONFIG --libs-only-l libssh`
26402 LD_SSH=`$PKGCONFIG --libs-only-L libssh`
26403 CPP_SSH=`$PKGCONFIG --cflags-only-I libssh`
26404 version=`$PKGCONFIG --modversion libssh`
26405 DIR_SSH=`echo $LD_SSH | $SED -e 's/-L//'`
26406 fi
26407
26408 ;;
26409 off)
26410 ;;
26411 *)
26412 PREFIX_SSH=$OPT_LIBSSH
26413 ;;
26414 esac
26415
26416 if test -n "$PREFIX_SSH"; then
26417 LIB_SSH="-lssh"
26418 LD_SSH=-L${PREFIX_SSH}/lib$libsuff
26419 CPP_SSH=-I${PREFIX_SSH}/include
26420 DIR_SSH=${PREFIX_SSH}/lib$libsuff
26421 fi
26422
26423 LDFLAGS="$LDFLAGS $LD_SSH"
26424 CPPFLAGS="$CPPFLAGS $CPP_SSH"
26425 LIBS="$LIB_SSH $LIBS"
26426
26427 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssh_new in -lssh" >&5
26428$as_echo_n "checking for ssh_new in -lssh... " >&6; }
26429if ${ac_cv_lib_ssh_ssh_new+:} false; then :
26430 $as_echo_n "(cached) " >&6
26431else
26432 ac_check_lib_save_LIBS=$LIBS
26433LIBS="-lssh $LIBS"
26434cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26435/* end confdefs.h. */
26436
26437
26438#ifdef __cplusplus
26439extern "C"
26440#endif
26441char ssh_new ();
26442int main (void)
26443{
26444return ssh_new ();
26445 ;
26446 return 0;
26447}
26448_ACEOF
26449if ac_fn_c_try_link "$LINENO"; then :
26450 ac_cv_lib_ssh_ssh_new=yes
26451else
26452 ac_cv_lib_ssh_ssh_new=no
26453fi
26454rm -f core conftest.err conftest.$ac_objext \
26455 conftest$ac_exeext conftest.$ac_ext
26456LIBS=$ac_check_lib_save_LIBS
26457fi
26458{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ssh_ssh_new" >&5
26459$as_echo "$ac_cv_lib_ssh_ssh_new" >&6; }
26460if test "x$ac_cv_lib_ssh_ssh_new" = xyes; then :
26461 cat >>confdefs.h <<_ACEOF
26462#define HAVE_LIBSSH 1
26463_ACEOF
26464
26465 LIBS="-lssh $LIBS"
26466
26467fi
26468
26469
26470 for ac_header in libssh/libssh.h
26471do :
26472 ac_fn_c_check_header_mongrel "$LINENO" "libssh/libssh.h" "ac_cv_header_libssh_libssh_h" "$ac_includes_default"
26473if test "x$ac_cv_header_libssh_libssh_h" = xyes; then :
26474 cat >>confdefs.h <<_ACEOF
26475#define HAVE_LIBSSH_LIBSSH_H 1
26476_ACEOF
26477 curl_ssh_msg="enabled (libSSH)"
26478 LIBSSH_ENABLED=1
26479
26480$as_echo "#define USE_LIBSSH 1" >>confdefs.h
26481
26482 USE_LIBSSH=1
26483
26484
26485fi
26486
26487done
26488
26489
26490 if test X"$OPT_LIBSSH" != Xoff &&
26491 test "$LIBSSH_ENABLED" != "1"; then
26492 as_fn_error $? "libSSH libs and/or directories were not found where specified!" "$LINENO" 5
26493 fi
26494
26495 if test "$LIBSSH_ENABLED" = "1"; then
26496 if test -n "$DIR_SSH"; then
26497
26498 if test "x$cross_compiling" != "xyes"; then
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070026499 CURL_LIBRARY_PATH="$CURL_LIBRARY_PATH:$DIR_SSH"
26500 export CURL_LIBRARY_PATH
26501 { $as_echo "$as_me:${as_lineno-$LINENO}: Added $DIR_SSH to CURL_LIBRARY_PATH" >&5
26502$as_echo "$as_me: Added $DIR_SSH to CURL_LIBRARY_PATH" >&6;}
Elliott Hughes0128fe42018-02-27 14:57:55 -080026503 fi
26504 fi
26505 else
26506 LDFLAGS=$CLEANLDFLAGS
26507 CPPFLAGS=$CLEANCPPFLAGS
26508 LIBS=$CLEANLIBS
26509 fi
Elliott Hughes82be86d2017-09-20 17:00:17 -070026510fi
26511
26512
26513OPT_LIBRTMP=off
26514
26515# Check whether --with-librtmp was given.
26516if test "${with_librtmp+set}" = set; then :
26517 withval=$with_librtmp; OPT_LIBRTMP=$withval
26518fi
26519
26520
26521if test X"$OPT_LIBRTMP" != Xno; then
26522 CLEANLDFLAGS="$LDFLAGS"
26523 CLEANCPPFLAGS="$CPPFLAGS"
26524 CLEANLIBS="$LIBS"
26525
26526 case "$OPT_LIBRTMP" in
26527 yes)
26528
26529 if test -n "$PKG_CONFIG"; then
26530 PKGCONFIG="$PKG_CONFIG"
26531 else
26532 if test -n "$ac_tool_prefix"; then
26533 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
26534set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
26535{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
26536$as_echo_n "checking for $ac_word... " >&6; }
26537if ${ac_cv_path_PKGCONFIG+:} false; then :
26538 $as_echo_n "(cached) " >&6
26539else
26540 case $PKGCONFIG in
26541 [\\/]* | ?:[\\/]*)
26542 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
26543 ;;
26544 *)
26545 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26546as_dummy="$PATH:/usr/bin:/usr/local/bin"
26547for as_dir in $as_dummy
26548do
26549 IFS=$as_save_IFS
26550 test -z "$as_dir" && as_dir=.
26551 for ac_exec_ext in '' $ac_executable_extensions; do
26552 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
26553 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
26554 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
26555 break 2
26556 fi
26557done
26558 done
26559IFS=$as_save_IFS
26560
26561 ;;
26562esac
26563fi
26564PKGCONFIG=$ac_cv_path_PKGCONFIG
26565if test -n "$PKGCONFIG"; then
26566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
26567$as_echo "$PKGCONFIG" >&6; }
26568else
26569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26570$as_echo "no" >&6; }
26571fi
26572
26573
26574fi
26575if test -z "$ac_cv_path_PKGCONFIG"; then
26576 ac_pt_PKGCONFIG=$PKGCONFIG
26577 # Extract the first word of "pkg-config", so it can be a program name with args.
26578set dummy pkg-config; ac_word=$2
26579{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
26580$as_echo_n "checking for $ac_word... " >&6; }
26581if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
26582 $as_echo_n "(cached) " >&6
26583else
26584 case $ac_pt_PKGCONFIG in
26585 [\\/]* | ?:[\\/]*)
26586 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
26587 ;;
26588 *)
26589 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26590as_dummy="$PATH:/usr/bin:/usr/local/bin"
26591for as_dir in $as_dummy
26592do
26593 IFS=$as_save_IFS
26594 test -z "$as_dir" && as_dir=.
26595 for ac_exec_ext in '' $ac_executable_extensions; do
26596 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
26597 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
26598 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
26599 break 2
26600 fi
26601done
26602 done
26603IFS=$as_save_IFS
26604
26605 ;;
26606esac
26607fi
26608ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
26609if test -n "$ac_pt_PKGCONFIG"; then
26610 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
26611$as_echo "$ac_pt_PKGCONFIG" >&6; }
26612else
26613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26614$as_echo "no" >&6; }
26615fi
26616
26617 if test "x$ac_pt_PKGCONFIG" = x; then
26618 PKGCONFIG="no"
26619 else
26620 case $cross_compiling:$ac_tool_warned in
26621yes:)
26622{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
26623$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
26624ac_tool_warned=yes ;;
26625esac
26626 PKGCONFIG=$ac_pt_PKGCONFIG
26627 fi
26628else
26629 PKGCONFIG="$ac_cv_path_PKGCONFIG"
26630fi
26631
26632 fi
26633
26634 if test "x$PKGCONFIG" != "xno"; then
26635 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for librtmp options with pkg-config" >&5
26636$as_echo_n "checking for librtmp options with pkg-config... " >&6; }
26637 itexists=`
26638 if test -n ""; then
26639 PKG_CONFIG_LIBDIR=""
26640 export PKG_CONFIG_LIBDIR
26641 fi
26642 $PKGCONFIG --exists librtmp >/dev/null 2>&1 && echo 1`
26643
26644 if test -z "$itexists"; then
26645 PKGCONFIG="no"
26646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26647$as_echo "no" >&6; }
26648 else
26649 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
26650$as_echo "found" >&6; }
26651 fi
26652 fi
26653
26654
26655 if test "$PKGCONFIG" != "no" ; then
26656 LIB_RTMP=`$PKGCONFIG --libs-only-l librtmp`
26657 LD_RTMP=`$PKGCONFIG --libs-only-L librtmp`
26658 CPP_RTMP=`$PKGCONFIG --cflags-only-I librtmp`
26659 version=`$PKGCONFIG --modversion librtmp`
26660 DIR_RTMP=`echo $LD_RTMP | $SED -e 's/-L//'`
26661 else
26662 as_fn_error $? "--librtmp was specified but could not find librtmp pkgconfig file." "$LINENO" 5
26663 fi
26664
26665 ;;
26666 off)
26667 LIB_RTMP="-lrtmp"
26668 ;;
26669 *)
26670 LIB_RTMP="-lrtmp"
26671 PREFIX_RTMP=$OPT_LIBRTMP
26672 ;;
26673 esac
26674
26675 if test -n "$PREFIX_RTMP"; then
26676 LD_RTMP=-L${PREFIX_RTMP}/lib$libsuff
26677 CPP_RTMP=-I${PREFIX_RTMP}/include
26678 DIR_RTMP=${PREFIX_RTMP}/lib$libsuff
26679 fi
26680
26681 LDFLAGS="$LDFLAGS $LD_RTMP"
26682 CPPFLAGS="$CPPFLAGS $CPP_RTMP"
26683 LIBS="$LIB_RTMP $LIBS"
26684
26685 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RTMP_Init in -lrtmp" >&5
26686$as_echo_n "checking for RTMP_Init in -lrtmp... " >&6; }
26687if ${ac_cv_lib_rtmp_RTMP_Init+:} false; then :
26688 $as_echo_n "(cached) " >&6
26689else
26690 ac_check_lib_save_LIBS=$LIBS
26691LIBS="-lrtmp $LIBS"
26692cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26693/* end confdefs.h. */
26694
26695
26696#ifdef __cplusplus
26697extern "C"
26698#endif
26699char RTMP_Init ();
26700int main (void)
26701{
26702return RTMP_Init ();
26703 ;
26704 return 0;
26705}
26706_ACEOF
26707if ac_fn_c_try_link "$LINENO"; then :
26708 ac_cv_lib_rtmp_RTMP_Init=yes
26709else
26710 ac_cv_lib_rtmp_RTMP_Init=no
26711fi
26712rm -f core conftest.err conftest.$ac_objext \
26713 conftest$ac_exeext conftest.$ac_ext
26714LIBS=$ac_check_lib_save_LIBS
26715fi
26716{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rtmp_RTMP_Init" >&5
26717$as_echo "$ac_cv_lib_rtmp_RTMP_Init" >&6; }
26718if test "x$ac_cv_lib_rtmp_RTMP_Init" = xyes; then :
26719
26720 for ac_header in librtmp/rtmp.h
26721do :
26722 ac_fn_c_check_header_mongrel "$LINENO" "librtmp/rtmp.h" "ac_cv_header_librtmp_rtmp_h" "$ac_includes_default"
26723if test "x$ac_cv_header_librtmp_rtmp_h" = xyes; then :
26724 cat >>confdefs.h <<_ACEOF
26725#define HAVE_LIBRTMP_RTMP_H 1
26726_ACEOF
26727 curl_rtmp_msg="enabled (librtmp)"
26728 LIBRTMP_ENABLED=1
26729
26730$as_echo "#define USE_LIBRTMP 1" >>confdefs.h
26731
26732 USE_LIBRTMP=1
26733
26734
26735fi
26736
26737done
26738
26739
26740else
26741 LDFLAGS=$CLEANLDFLAGS
26742 CPPFLAGS=$CLEANCPPFLAGS
26743 LIBS=$CLEANLIBS
26744
26745fi
26746
26747
26748 if test X"$OPT_LIBRTMP" != Xoff &&
26749 test "$LIBRTMP_ENABLED" != "1"; then
26750 as_fn_error $? "librtmp libs and/or directories were not found where specified!" "$LINENO" 5
26751 fi
26752
26753fi
26754
26755
26756versioned_symbols_flavour=
26757{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether versioned symbols are wanted" >&5
26758$as_echo_n "checking whether versioned symbols are wanted... " >&6; }
26759# Check whether --enable-versioned-symbols was given.
26760if test "${enable_versioned_symbols+set}" = set; then :
26761 enableval=$enable_versioned_symbols; case "$enableval" in
26762 yes) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
26763$as_echo "yes" >&6; }
26764 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libraries can be versioned" >&5
26765$as_echo_n "checking if libraries can be versioned... " >&6; }
26766 GLD=`$LD --help < /dev/null 2>/dev/null | grep version-script`
26767 if test -z "$GLD"; then
26768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26769$as_echo "no" >&6; }
26770 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: You need an ld version supporting the --version-script option" >&5
26771$as_echo "$as_me: WARNING: You need an ld version supporting the --version-script option" >&2;}
26772 else
26773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
26774$as_echo "yes" >&6; }
Alex Deymo486467e2017-12-19 19:04:07 +010026775 if test "x$CURL_WITH_MULTI_SSL" = "x1"; then
26776 versioned_symbols_flavour="MULTISSL_"
26777 elif test "x$OPENSSL_ENABLED" = "x1"; then
Elliott Hughes82be86d2017-09-20 17:00:17 -070026778 versioned_symbols_flavour="OPENSSL_"
26779 elif test "x$GNUTLS_ENABLED" = "x1"; then
26780 versioned_symbols_flavour="GNUTLS_"
26781 elif test "x$NSS_ENABLED" = "x1"; then
26782 versioned_symbols_flavour="NSS_"
Haibo Huang001784b2019-07-19 05:27:28 -070026783 elif test "x$WOLFSSL_ENABLED" = "x1"; then
26784 versioned_symbols_flavour="WOLFSSL_"
Elliott Hughes82be86d2017-09-20 17:00:17 -070026785 elif test "x$WINSSL_ENABLED" = "x1"; then
Haibo Huang65021c72019-03-27 15:37:23 -070026786 versioned_symbols_flavour="SCHANNEL_"
26787 elif test "x$SECURETRANSPORT_ENABLED" = "x1"; then
26788 versioned_symbols_flavour="SECURE_TRANSPORT_"
Elliott Hughes82be86d2017-09-20 17:00:17 -070026789 else
26790 versioned_symbols_flavour=""
26791 fi
26792 versioned_symbols="yes"
26793 fi
26794 ;;
26795
26796 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26797$as_echo "no" >&6; }
26798 ;;
26799 esac
26800
26801else
26802
26803{ $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26804$as_echo "no" >&6; }
26805
26806
26807fi
26808
26809
26810CURL_LT_SHLIB_VERSIONED_FLAVOUR="$versioned_symbols_flavour"
26811
26812 if test "x$versioned_symbols" = 'xyes'; then
26813 CURL_LT_SHLIB_USE_VERSIONED_SYMBOLS_TRUE=
26814 CURL_LT_SHLIB_USE_VERSIONED_SYMBOLS_FALSE='#'
26815else
26816 CURL_LT_SHLIB_USE_VERSIONED_SYMBOLS_TRUE='#'
26817 CURL_LT_SHLIB_USE_VERSIONED_SYMBOLS_FALSE=
26818fi
26819
26820
26821
26822{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable Windows native IDN (Windows native builds only)" >&5
26823$as_echo_n "checking whether to enable Windows native IDN (Windows native builds only)... " >&6; }
26824OPT_WINIDN="default"
26825
26826# Check whether --with-winidn was given.
26827if test "${with_winidn+set}" = set; then :
26828 withval=$with_winidn; OPT_WINIDN=$withval
26829fi
26830
26831case "$OPT_WINIDN" in
26832 no|default)
26833 want_winidn="no"
26834 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26835$as_echo "no" >&6; }
26836 ;;
26837 yes)
26838 want_winidn="yes"
26839 want_winidn_path="default"
26840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
26841$as_echo "yes" >&6; }
26842 ;;
26843 *)
26844 want_winidn="yes"
26845 want_winidn_path="$withval"
26846 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes ($withval)" >&5
26847$as_echo "yes ($withval)" >&6; }
26848 ;;
26849esac
26850
26851if test "$want_winidn" = "yes"; then
26852 clean_CPPFLAGS="$CPPFLAGS"
26853 clean_LDFLAGS="$LDFLAGS"
26854 clean_LIBS="$LIBS"
26855 WINIDN_LIBS="-lnormaliz"
26856 WINIDN_CPPFLAGS="-DWINVER=0x0600"
26857 #
26858 if test "$want_winidn_path" != "default"; then
26859 WINIDN_LDFLAGS="-L$want_winidn_path/lib$libsuff"
26860 WINIDN_CPPFLAGS="-I$want_winidn_path/include"
26861 WINIDN_DIR="$want_winidn_path/lib$libsuff"
26862 fi
26863 #
26864 CPPFLAGS="$CPPFLAGS $WINIDN_CPPFLAGS"
26865 LDFLAGS="$LDFLAGS $WINIDN_LDFLAGS"
26866 LIBS="$WINIDN_LIBS $LIBS"
26867 #
26868 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if IdnToUnicode can be linked" >&5
26869$as_echo_n "checking if IdnToUnicode can be linked... " >&6; }
26870 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26871/* end confdefs.h. */
26872
26873
26874 #include <windows.h>
26875
26876int main (void)
26877{
26878
26879 IdnToUnicode(0, NULL, 0, NULL, 0);
26880
26881 ;
26882 return 0;
26883}
26884
26885_ACEOF
26886if ac_fn_c_try_link "$LINENO"; then :
26887
26888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
26889$as_echo "yes" >&6; }
26890 tst_links_winidn="yes"
26891
26892else
26893
26894 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26895$as_echo "no" >&6; }
26896 tst_links_winidn="no"
26897
26898fi
26899rm -f core conftest.err conftest.$ac_objext \
26900 conftest$ac_exeext conftest.$ac_ext
26901 #
26902 if test "$tst_links_winidn" = "yes"; then
26903
26904$as_echo "#define USE_WIN32_IDN 1" >>confdefs.h
26905
26906
26907$as_echo "#define WANT_IDN_PROTOTYPES 1" >>confdefs.h
26908
26909 IDN_ENABLED=1
26910
26911 curl_idn_msg="enabled (Windows-native)"
26912 else
26913 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Cannot find libraries for IDN support: IDN disabled" >&5
26914$as_echo "$as_me: WARNING: Cannot find libraries for IDN support: IDN disabled" >&2;}
26915 CPPFLAGS="$clean_CPPFLAGS"
26916 LDFLAGS="$clean_LDFLAGS"
26917 LIBS="$clean_LIBS"
26918 fi
26919fi
26920
26921
26922{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build with libidn2" >&5
26923$as_echo_n "checking whether to build with libidn2... " >&6; }
26924OPT_IDN="default"
26925
26926# Check whether --with-libidn2 was given.
26927if test "${with_libidn2+set}" = set; then :
26928 withval=$with_libidn2; OPT_IDN=$withval
26929fi
26930
26931case "$OPT_IDN" in
26932 no)
26933 want_idn="no"
26934 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26935$as_echo "no" >&6; }
26936 ;;
26937 default)
26938 want_idn="yes"
26939 want_idn_path="default"
26940 { $as_echo "$as_me:${as_lineno-$LINENO}: result: (assumed) yes" >&5
26941$as_echo "(assumed) yes" >&6; }
26942 ;;
26943 yes)
26944 want_idn="yes"
26945 want_idn_path="default"
26946 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
26947$as_echo "yes" >&6; }
26948 ;;
26949 *)
26950 want_idn="yes"
26951 want_idn_path="$withval"
26952 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes ($withval)" >&5
26953$as_echo "yes ($withval)" >&6; }
26954 ;;
26955esac
26956
26957if test "$want_idn" = "yes"; then
26958 clean_CPPFLAGS="$CPPFLAGS"
26959 clean_LDFLAGS="$LDFLAGS"
26960 clean_LIBS="$LIBS"
26961 PKGCONFIG="no"
26962 #
26963 if test "$want_idn_path" != "default"; then
26964 IDN_PCDIR="$want_idn_path/lib$libsuff/pkgconfig"
26965
26966 if test -n "$PKG_CONFIG"; then
26967 PKGCONFIG="$PKG_CONFIG"
26968 else
26969 if test -n "$ac_tool_prefix"; then
26970 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
26971set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
26972{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
26973$as_echo_n "checking for $ac_word... " >&6; }
26974if ${ac_cv_path_PKGCONFIG+:} false; then :
26975 $as_echo_n "(cached) " >&6
26976else
26977 case $PKGCONFIG in
26978 [\\/]* | ?:[\\/]*)
26979 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
26980 ;;
26981 *)
26982 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26983as_dummy="$PATH:/usr/bin:/usr/local/bin"
26984for as_dir in $as_dummy
26985do
26986 IFS=$as_save_IFS
26987 test -z "$as_dir" && as_dir=.
26988 for ac_exec_ext in '' $ac_executable_extensions; do
26989 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
26990 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
26991 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
26992 break 2
26993 fi
26994done
26995 done
26996IFS=$as_save_IFS
26997
26998 ;;
26999esac
27000fi
27001PKGCONFIG=$ac_cv_path_PKGCONFIG
27002if test -n "$PKGCONFIG"; then
27003 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
27004$as_echo "$PKGCONFIG" >&6; }
27005else
27006 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27007$as_echo "no" >&6; }
27008fi
27009
27010
27011fi
27012if test -z "$ac_cv_path_PKGCONFIG"; then
27013 ac_pt_PKGCONFIG=$PKGCONFIG
27014 # Extract the first word of "pkg-config", so it can be a program name with args.
27015set dummy pkg-config; ac_word=$2
27016{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27017$as_echo_n "checking for $ac_word... " >&6; }
27018if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
27019 $as_echo_n "(cached) " >&6
27020else
27021 case $ac_pt_PKGCONFIG in
27022 [\\/]* | ?:[\\/]*)
27023 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
27024 ;;
27025 *)
27026 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27027as_dummy="$PATH:/usr/bin:/usr/local/bin"
27028for as_dir in $as_dummy
27029do
27030 IFS=$as_save_IFS
27031 test -z "$as_dir" && as_dir=.
27032 for ac_exec_ext in '' $ac_executable_extensions; do
27033 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27034 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
27035 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27036 break 2
27037 fi
27038done
27039 done
27040IFS=$as_save_IFS
27041
27042 ;;
27043esac
27044fi
27045ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
27046if test -n "$ac_pt_PKGCONFIG"; then
27047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
27048$as_echo "$ac_pt_PKGCONFIG" >&6; }
27049else
27050 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27051$as_echo "no" >&6; }
27052fi
27053
27054 if test "x$ac_pt_PKGCONFIG" = x; then
27055 PKGCONFIG="no"
27056 else
27057 case $cross_compiling:$ac_tool_warned in
27058yes:)
27059{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
27060$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
27061ac_tool_warned=yes ;;
27062esac
27063 PKGCONFIG=$ac_pt_PKGCONFIG
27064 fi
27065else
27066 PKGCONFIG="$ac_cv_path_PKGCONFIG"
27067fi
27068
27069 fi
27070
27071 if test "x$PKGCONFIG" != "xno"; then
27072 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libidn2 options with pkg-config" >&5
27073$as_echo_n "checking for libidn2 options with pkg-config... " >&6; }
27074 itexists=`
27075 if test -n "$IDN_PCDIR"; then
27076 PKG_CONFIG_LIBDIR="$IDN_PCDIR"
27077 export PKG_CONFIG_LIBDIR
27078 fi
27079 $PKGCONFIG --exists libidn2 >/dev/null 2>&1 && echo 1`
27080
27081 if test -z "$itexists"; then
27082 PKGCONFIG="no"
27083 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27084$as_echo "no" >&6; }
27085 else
27086 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
27087$as_echo "found" >&6; }
27088 fi
27089 fi
27090
27091 if test "$PKGCONFIG" != "no"; then
27092 IDN_LIBS=`
27093 if test -n "$IDN_PCDIR"; then
27094 PKG_CONFIG_LIBDIR="$IDN_PCDIR"
27095 export PKG_CONFIG_LIBDIR
27096 fi
27097 $PKGCONFIG --libs-only-l libidn2 2>/dev/null`
27098 IDN_LDFLAGS=`
27099 if test -n "$IDN_PCDIR"; then
27100 PKG_CONFIG_LIBDIR="$IDN_PCDIR"
27101 export PKG_CONFIG_LIBDIR
27102 fi
27103 $PKGCONFIG --libs-only-L libidn2 2>/dev/null`
27104 IDN_CPPFLAGS=`
27105 if test -n "$IDN_PCDIR"; then
27106 PKG_CONFIG_LIBDIR="$IDN_PCDIR"
27107 export PKG_CONFIG_LIBDIR
27108 fi
27109 $PKGCONFIG --cflags-only-I libidn2 2>/dev/null`
27110 IDN_DIR=`echo $IDN_LDFLAGS | $SED -e 's/-L//'`
27111 else
27112 IDN_LIBS="-lidn2"
27113 IDN_LDFLAGS="-L$want_idn_path/lib$libsuff"
27114 IDN_CPPFLAGS="-I$want_idn_path/include"
27115 IDN_DIR="$want_idn_path/lib$libsuff"
27116 fi
27117 else
27118
27119 if test -n "$PKG_CONFIG"; then
27120 PKGCONFIG="$PKG_CONFIG"
27121 else
27122 if test -n "$ac_tool_prefix"; then
27123 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
27124set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
27125{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27126$as_echo_n "checking for $ac_word... " >&6; }
27127if ${ac_cv_path_PKGCONFIG+:} false; then :
27128 $as_echo_n "(cached) " >&6
27129else
27130 case $PKGCONFIG in
27131 [\\/]* | ?:[\\/]*)
27132 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
27133 ;;
27134 *)
27135 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27136as_dummy="$PATH:/usr/bin:/usr/local/bin"
27137for as_dir in $as_dummy
27138do
27139 IFS=$as_save_IFS
27140 test -z "$as_dir" && as_dir=.
27141 for ac_exec_ext in '' $ac_executable_extensions; do
27142 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27143 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
27144 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27145 break 2
27146 fi
27147done
27148 done
27149IFS=$as_save_IFS
27150
27151 ;;
27152esac
27153fi
27154PKGCONFIG=$ac_cv_path_PKGCONFIG
27155if test -n "$PKGCONFIG"; then
27156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
27157$as_echo "$PKGCONFIG" >&6; }
27158else
27159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27160$as_echo "no" >&6; }
27161fi
27162
27163
27164fi
27165if test -z "$ac_cv_path_PKGCONFIG"; then
27166 ac_pt_PKGCONFIG=$PKGCONFIG
27167 # Extract the first word of "pkg-config", so it can be a program name with args.
27168set dummy pkg-config; ac_word=$2
27169{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27170$as_echo_n "checking for $ac_word... " >&6; }
27171if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
27172 $as_echo_n "(cached) " >&6
27173else
27174 case $ac_pt_PKGCONFIG in
27175 [\\/]* | ?:[\\/]*)
27176 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
27177 ;;
27178 *)
27179 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27180as_dummy="$PATH:/usr/bin:/usr/local/bin"
27181for as_dir in $as_dummy
27182do
27183 IFS=$as_save_IFS
27184 test -z "$as_dir" && as_dir=.
27185 for ac_exec_ext in '' $ac_executable_extensions; do
27186 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27187 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
27188 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27189 break 2
27190 fi
27191done
27192 done
27193IFS=$as_save_IFS
27194
27195 ;;
27196esac
27197fi
27198ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
27199if test -n "$ac_pt_PKGCONFIG"; then
27200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
27201$as_echo "$ac_pt_PKGCONFIG" >&6; }
27202else
27203 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27204$as_echo "no" >&6; }
27205fi
27206
27207 if test "x$ac_pt_PKGCONFIG" = x; then
27208 PKGCONFIG="no"
27209 else
27210 case $cross_compiling:$ac_tool_warned in
27211yes:)
27212{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
27213$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
27214ac_tool_warned=yes ;;
27215esac
27216 PKGCONFIG=$ac_pt_PKGCONFIG
27217 fi
27218else
27219 PKGCONFIG="$ac_cv_path_PKGCONFIG"
27220fi
27221
27222 fi
27223
27224 if test "x$PKGCONFIG" != "xno"; then
27225 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libidn2 options with pkg-config" >&5
27226$as_echo_n "checking for libidn2 options with pkg-config... " >&6; }
27227 itexists=`
27228 if test -n ""; then
27229 PKG_CONFIG_LIBDIR=""
27230 export PKG_CONFIG_LIBDIR
27231 fi
27232 $PKGCONFIG --exists libidn2 >/dev/null 2>&1 && echo 1`
27233
27234 if test -z "$itexists"; then
27235 PKGCONFIG="no"
27236 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27237$as_echo "no" >&6; }
27238 else
27239 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
27240$as_echo "found" >&6; }
27241 fi
27242 fi
27243
27244 if test "$PKGCONFIG" != "no"; then
27245 IDN_LIBS=`$PKGCONFIG --libs-only-l libidn2 2>/dev/null`
27246 IDN_LDFLAGS=`$PKGCONFIG --libs-only-L libidn2 2>/dev/null`
27247 IDN_CPPFLAGS=`$PKGCONFIG --cflags-only-I libidn2 2>/dev/null`
27248 IDN_DIR=`echo $IDN_LDFLAGS | $SED -e 's/-L//'`
27249 else
27250 IDN_LIBS="-lidn2"
27251 fi
27252 fi
27253 #
27254 if test "$PKGCONFIG" != "no"; then
27255 { $as_echo "$as_me:${as_lineno-$LINENO}: pkg-config: IDN_LIBS: \"$IDN_LIBS\"" >&5
27256$as_echo "$as_me: pkg-config: IDN_LIBS: \"$IDN_LIBS\"" >&6;}
27257 { $as_echo "$as_me:${as_lineno-$LINENO}: pkg-config: IDN_LDFLAGS: \"$IDN_LDFLAGS\"" >&5
27258$as_echo "$as_me: pkg-config: IDN_LDFLAGS: \"$IDN_LDFLAGS\"" >&6;}
27259 { $as_echo "$as_me:${as_lineno-$LINENO}: pkg-config: IDN_CPPFLAGS: \"$IDN_CPPFLAGS\"" >&5
27260$as_echo "$as_me: pkg-config: IDN_CPPFLAGS: \"$IDN_CPPFLAGS\"" >&6;}
27261 { $as_echo "$as_me:${as_lineno-$LINENO}: pkg-config: IDN_DIR: \"$IDN_DIR\"" >&5
27262$as_echo "$as_me: pkg-config: IDN_DIR: \"$IDN_DIR\"" >&6;}
27263 else
27264 { $as_echo "$as_me:${as_lineno-$LINENO}: IDN_LIBS: \"$IDN_LIBS\"" >&5
27265$as_echo "$as_me: IDN_LIBS: \"$IDN_LIBS\"" >&6;}
27266 { $as_echo "$as_me:${as_lineno-$LINENO}: IDN_LDFLAGS: \"$IDN_LDFLAGS\"" >&5
27267$as_echo "$as_me: IDN_LDFLAGS: \"$IDN_LDFLAGS\"" >&6;}
27268 { $as_echo "$as_me:${as_lineno-$LINENO}: IDN_CPPFLAGS: \"$IDN_CPPFLAGS\"" >&5
27269$as_echo "$as_me: IDN_CPPFLAGS: \"$IDN_CPPFLAGS\"" >&6;}
27270 { $as_echo "$as_me:${as_lineno-$LINENO}: IDN_DIR: \"$IDN_DIR\"" >&5
27271$as_echo "$as_me: IDN_DIR: \"$IDN_DIR\"" >&6;}
27272 fi
27273 #
27274 CPPFLAGS="$CPPFLAGS $IDN_CPPFLAGS"
27275 LDFLAGS="$LDFLAGS $IDN_LDFLAGS"
27276 LIBS="$IDN_LIBS $LIBS"
27277 #
27278 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if idn2_lookup_ul can be linked" >&5
27279$as_echo_n "checking if idn2_lookup_ul can be linked... " >&6; }
27280 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27281/* end confdefs.h. */
27282
27283
27284#define idn2_lookup_ul innocuous_idn2_lookup_ul
27285#ifdef __STDC__
27286# include <limits.h>
27287#else
27288# include <assert.h>
27289#endif
27290#undef idn2_lookup_ul
27291#ifdef __cplusplus
27292extern "C"
27293#endif
27294char idn2_lookup_ul ();
27295#if defined __stub_idn2_lookup_ul || defined __stub___idn2_lookup_ul
27296choke me
27297#endif
27298
27299int main (void)
27300{
27301return idn2_lookup_ul ();
27302 ;
27303 return 0;
27304}
27305
27306_ACEOF
27307if ac_fn_c_try_link "$LINENO"; then :
27308
27309 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
27310$as_echo "yes" >&6; }
27311 tst_links_libidn="yes"
27312
27313else
27314
27315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27316$as_echo "no" >&6; }
27317 tst_links_libidn="no"
27318
27319fi
27320rm -f core conftest.err conftest.$ac_objext \
27321 conftest$ac_exeext conftest.$ac_ext
27322 #
27323 for ac_header in idn2.h
27324do :
27325 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
27326ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
27327if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
27328 cat >>confdefs.h <<_ACEOF
27329#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
27330_ACEOF
27331
27332fi
27333
27334done
27335
27336
27337 if test "$tst_links_libidn" = "yes"; then
27338
27339$as_echo "#define HAVE_LIBIDN2 1" >>confdefs.h
27340
27341
27342 IDN_ENABLED=1
27343
27344 curl_idn_msg="enabled (libidn2)"
27345 if test -n "$IDN_DIR" -a "x$cross_compiling" != "xyes"; then
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070027346 CURL_LIBRARY_PATH="$CURL_LIBRARY_PATH:$IDN_DIR"
27347 export CURL_LIBRARY_PATH
27348 { $as_echo "$as_me:${as_lineno-$LINENO}: Added $IDN_DIR to CURL_LIBRARY_PATH" >&5
27349$as_echo "$as_me: Added $IDN_DIR to CURL_LIBRARY_PATH" >&6;}
Elliott Hughes82be86d2017-09-20 17:00:17 -070027350 fi
27351 else
27352 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Cannot find libraries for IDN support: IDN disabled" >&5
27353$as_echo "$as_me: WARNING: Cannot find libraries for IDN support: IDN disabled" >&2;}
27354 CPPFLAGS="$clean_CPPFLAGS"
27355 LDFLAGS="$clean_LDFLAGS"
27356 LIBS="$clean_LIBS"
27357 fi
27358fi
27359
27360
27361
27362
27363
27364OPT_H2="yes"
27365
27366if test "x$disable_http" = "xyes"; then
27367 # without HTTP, nghttp2 is no use
27368 OPT_H2="no"
27369fi
27370
27371
27372# Check whether --with-nghttp2 was given.
27373if test "${with_nghttp2+set}" = set; then :
27374 withval=$with_nghttp2; OPT_H2=$withval
27375fi
27376
27377case "$OPT_H2" in
27378 no)
27379 want_h2="no"
27380 ;;
27381 yes)
27382 want_h2="default"
27383 want_h2_path=""
27384 ;;
27385 *)
27386 want_h2="yes"
27387 want_h2_path="$withval/lib/pkgconfig"
27388 ;;
27389esac
27390
27391curl_h2_msg="disabled (--with-nghttp2)"
27392if test X"$want_h2" != Xno; then
27393 CLEANLDFLAGS="$LDFLAGS"
27394 CLEANCPPFLAGS="$CPPFLAGS"
27395 CLEANLIBS="$LIBS"
27396
27397
27398 if test -n "$PKG_CONFIG"; then
27399 PKGCONFIG="$PKG_CONFIG"
27400 else
27401 if test -n "$ac_tool_prefix"; then
27402 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
27403set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
27404{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27405$as_echo_n "checking for $ac_word... " >&6; }
27406if ${ac_cv_path_PKGCONFIG+:} false; then :
27407 $as_echo_n "(cached) " >&6
27408else
27409 case $PKGCONFIG in
27410 [\\/]* | ?:[\\/]*)
27411 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
27412 ;;
27413 *)
27414 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27415as_dummy="$PATH:/usr/bin:/usr/local/bin"
27416for as_dir in $as_dummy
27417do
27418 IFS=$as_save_IFS
27419 test -z "$as_dir" && as_dir=.
27420 for ac_exec_ext in '' $ac_executable_extensions; do
27421 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27422 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
27423 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27424 break 2
27425 fi
27426done
27427 done
27428IFS=$as_save_IFS
27429
27430 ;;
27431esac
27432fi
27433PKGCONFIG=$ac_cv_path_PKGCONFIG
27434if test -n "$PKGCONFIG"; then
27435 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
27436$as_echo "$PKGCONFIG" >&6; }
27437else
27438 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27439$as_echo "no" >&6; }
27440fi
27441
27442
27443fi
27444if test -z "$ac_cv_path_PKGCONFIG"; then
27445 ac_pt_PKGCONFIG=$PKGCONFIG
27446 # Extract the first word of "pkg-config", so it can be a program name with args.
27447set dummy pkg-config; ac_word=$2
27448{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27449$as_echo_n "checking for $ac_word... " >&6; }
27450if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
27451 $as_echo_n "(cached) " >&6
27452else
27453 case $ac_pt_PKGCONFIG in
27454 [\\/]* | ?:[\\/]*)
27455 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
27456 ;;
27457 *)
27458 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27459as_dummy="$PATH:/usr/bin:/usr/local/bin"
27460for as_dir in $as_dummy
27461do
27462 IFS=$as_save_IFS
27463 test -z "$as_dir" && as_dir=.
27464 for ac_exec_ext in '' $ac_executable_extensions; do
27465 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27466 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
27467 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27468 break 2
27469 fi
27470done
27471 done
27472IFS=$as_save_IFS
27473
27474 ;;
27475esac
27476fi
27477ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
27478if test -n "$ac_pt_PKGCONFIG"; then
27479 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
27480$as_echo "$ac_pt_PKGCONFIG" >&6; }
27481else
27482 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27483$as_echo "no" >&6; }
27484fi
27485
27486 if test "x$ac_pt_PKGCONFIG" = x; then
27487 PKGCONFIG="no"
27488 else
27489 case $cross_compiling:$ac_tool_warned in
27490yes:)
27491{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
27492$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
27493ac_tool_warned=yes ;;
27494esac
27495 PKGCONFIG=$ac_pt_PKGCONFIG
27496 fi
27497else
27498 PKGCONFIG="$ac_cv_path_PKGCONFIG"
27499fi
27500
27501 fi
27502
27503 if test "x$PKGCONFIG" != "xno"; then
27504 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libnghttp2 options with pkg-config" >&5
27505$as_echo_n "checking for libnghttp2 options with pkg-config... " >&6; }
27506 itexists=`
27507 if test -n "$want_h2_path"; then
27508 PKG_CONFIG_LIBDIR="$want_h2_path"
27509 export PKG_CONFIG_LIBDIR
27510 fi
27511 $PKGCONFIG --exists libnghttp2 >/dev/null 2>&1 && echo 1`
27512
27513 if test -z "$itexists"; then
27514 PKGCONFIG="no"
27515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27516$as_echo "no" >&6; }
27517 else
27518 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
27519$as_echo "found" >&6; }
27520 fi
27521 fi
27522
27523
27524 if test "$PKGCONFIG" != "no" ; then
27525 LIB_H2=`
27526 if test -n "$want_h2_path"; then
27527 PKG_CONFIG_LIBDIR="$want_h2_path"
27528 export PKG_CONFIG_LIBDIR
27529 fi
27530
27531 $PKGCONFIG --libs-only-l libnghttp2`
27532 { $as_echo "$as_me:${as_lineno-$LINENO}: -l is $LIB_H2" >&5
27533$as_echo "$as_me: -l is $LIB_H2" >&6;}
27534
27535 CPP_H2=`
27536 if test -n "$want_h2_path"; then
27537 PKG_CONFIG_LIBDIR="$want_h2_path"
27538 export PKG_CONFIG_LIBDIR
27539 fi
27540 $PKGCONFIG --cflags-only-I libnghttp2`
27541 { $as_echo "$as_me:${as_lineno-$LINENO}: -I is $CPP_H2" >&5
27542$as_echo "$as_me: -I is $CPP_H2" >&6;}
27543
27544 LD_H2=`
27545 if test -n "$want_h2_path"; then
27546 PKG_CONFIG_LIBDIR="$want_h2_path"
27547 export PKG_CONFIG_LIBDIR
27548 fi
27549
27550 $PKGCONFIG --libs-only-L libnghttp2`
27551 { $as_echo "$as_me:${as_lineno-$LINENO}: -L is $LD_H2" >&5
27552$as_echo "$as_me: -L is $LD_H2" >&6;}
27553
27554 LDFLAGS="$LDFLAGS $LD_H2"
27555 CPPFLAGS="$CPPFLAGS $CPP_H2"
27556 LIBS="$LIB_H2 $LIBS"
27557
27558 # use nghttp2_option_set_no_recv_client_magic to require nghttp2
27559 # >= 1.0.0
27560 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nghttp2_option_set_no_recv_client_magic in -lnghttp2" >&5
27561$as_echo_n "checking for nghttp2_option_set_no_recv_client_magic in -lnghttp2... " >&6; }
27562if ${ac_cv_lib_nghttp2_nghttp2_option_set_no_recv_client_magic+:} false; then :
27563 $as_echo_n "(cached) " >&6
27564else
27565 ac_check_lib_save_LIBS=$LIBS
27566LIBS="-lnghttp2 $LIBS"
27567cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27568/* end confdefs.h. */
27569
27570
27571#ifdef __cplusplus
27572extern "C"
27573#endif
27574char nghttp2_option_set_no_recv_client_magic ();
27575int main (void)
27576{
27577return nghttp2_option_set_no_recv_client_magic ();
27578 ;
27579 return 0;
27580}
27581_ACEOF
27582if ac_fn_c_try_link "$LINENO"; then :
27583 ac_cv_lib_nghttp2_nghttp2_option_set_no_recv_client_magic=yes
27584else
27585 ac_cv_lib_nghttp2_nghttp2_option_set_no_recv_client_magic=no
27586fi
27587rm -f core conftest.err conftest.$ac_objext \
27588 conftest$ac_exeext conftest.$ac_ext
27589LIBS=$ac_check_lib_save_LIBS
27590fi
27591{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nghttp2_nghttp2_option_set_no_recv_client_magic" >&5
27592$as_echo "$ac_cv_lib_nghttp2_nghttp2_option_set_no_recv_client_magic" >&6; }
27593if test "x$ac_cv_lib_nghttp2_nghttp2_option_set_no_recv_client_magic" = xyes; then :
27594
27595 for ac_header in nghttp2/nghttp2.h
27596do :
27597 ac_fn_c_check_header_mongrel "$LINENO" "nghttp2/nghttp2.h" "ac_cv_header_nghttp2_nghttp2_h" "$ac_includes_default"
27598if test "x$ac_cv_header_nghttp2_nghttp2_h" = xyes; then :
27599 cat >>confdefs.h <<_ACEOF
27600#define HAVE_NGHTTP2_NGHTTP2_H 1
27601_ACEOF
27602 curl_h2_msg="enabled (nghttp2)"
27603 NGHTTP2_ENABLED=1
27604
27605$as_echo "#define USE_NGHTTP2 1" >>confdefs.h
27606
27607 USE_NGHTTP2=1
27608
27609
27610fi
27611
27612done
27613
27614
27615else
27616 LDFLAGS=$CLEANLDFLAGS
27617 CPPFLAGS=$CLEANCPPFLAGS
27618 LIBS=$CLEANLIBS
27619
27620fi
27621
27622
27623 else
27624 if test X"$want_h2" != Xdefault; then
27625 as_fn_error $? "--with-nghttp2 was specified but could not find libnghttp2 pkg-config file." "$LINENO" 5
27626 fi
27627 fi
27628
27629fi
27630
27631
27632OPT_ZSH_FPATH=default
27633
27634# Check whether --with-zsh-functions-dir was given.
27635if test "${with_zsh_functions_dir+set}" = set; then :
27636 withval=$with_zsh_functions_dir; OPT_ZSH_FPATH=$withval
27637fi
27638
27639case "$OPT_ZSH_FPATH" in
27640 no)
27641 ;;
27642 default|yes)
27643 ZSH_FUNCTIONS_DIR="$datarootdir/zsh/site-functions"
27644
27645 ;;
27646 *)
27647 ZSH_FUNCTIONS_DIR="$withval"
27648
27649 ;;
27650esac
27651
27652
Haibo Huang65021c72019-03-27 15:37:23 -070027653OPT_FISH_FPATH=default
27654
27655# Check whether --with-fish-functions-dir was given.
27656if test "${with_fish_functions_dir+set}" = set; then :
27657 withval=$with_fish_functions_dir; OPT_FISH_FPATH=$withval
27658fi
27659
27660case "$OPT_FISH_FPATH" in
27661 no)
27662 ;;
27663 default|yes)
Haibo Huang34ab3462019-05-22 00:50:27 -070027664
27665 if test -n "$PKG_CONFIG"; then
27666 PKGCONFIG="$PKG_CONFIG"
27667 else
27668 if test -n "$ac_tool_prefix"; then
27669 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
27670set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
27671{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27672$as_echo_n "checking for $ac_word... " >&6; }
27673if ${ac_cv_path_PKGCONFIG+:} false; then :
27674 $as_echo_n "(cached) " >&6
27675else
27676 case $PKGCONFIG in
27677 [\\/]* | ?:[\\/]*)
27678 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
27679 ;;
27680 *)
27681 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27682as_dummy="$PATH:/usr/bin:/usr/local/bin"
27683for as_dir in $as_dummy
27684do
27685 IFS=$as_save_IFS
27686 test -z "$as_dir" && as_dir=.
27687 for ac_exec_ext in '' $ac_executable_extensions; do
27688 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27689 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
27690 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27691 break 2
27692 fi
27693done
27694 done
27695IFS=$as_save_IFS
27696
27697 ;;
27698esac
27699fi
27700PKGCONFIG=$ac_cv_path_PKGCONFIG
27701if test -n "$PKGCONFIG"; then
27702 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
27703$as_echo "$PKGCONFIG" >&6; }
27704else
27705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27706$as_echo "no" >&6; }
27707fi
27708
27709
27710fi
27711if test -z "$ac_cv_path_PKGCONFIG"; then
27712 ac_pt_PKGCONFIG=$PKGCONFIG
27713 # Extract the first word of "pkg-config", so it can be a program name with args.
27714set dummy pkg-config; ac_word=$2
27715{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27716$as_echo_n "checking for $ac_word... " >&6; }
27717if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
27718 $as_echo_n "(cached) " >&6
27719else
27720 case $ac_pt_PKGCONFIG in
27721 [\\/]* | ?:[\\/]*)
27722 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
27723 ;;
27724 *)
27725 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27726as_dummy="$PATH:/usr/bin:/usr/local/bin"
27727for as_dir in $as_dummy
27728do
27729 IFS=$as_save_IFS
27730 test -z "$as_dir" && as_dir=.
27731 for ac_exec_ext in '' $ac_executable_extensions; do
27732 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27733 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
27734 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27735 break 2
27736 fi
27737done
27738 done
27739IFS=$as_save_IFS
27740
27741 ;;
27742esac
27743fi
27744ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
27745if test -n "$ac_pt_PKGCONFIG"; then
27746 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
27747$as_echo "$ac_pt_PKGCONFIG" >&6; }
27748else
27749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27750$as_echo "no" >&6; }
27751fi
27752
27753 if test "x$ac_pt_PKGCONFIG" = x; then
27754 PKGCONFIG="no"
27755 else
27756 case $cross_compiling:$ac_tool_warned in
27757yes:)
27758{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
27759$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
27760ac_tool_warned=yes ;;
27761esac
27762 PKGCONFIG=$ac_pt_PKGCONFIG
27763 fi
27764else
27765 PKGCONFIG="$ac_cv_path_PKGCONFIG"
27766fi
27767
27768 fi
27769
27770 if test "x$PKGCONFIG" != "xno"; then
27771 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fish options with pkg-config" >&5
27772$as_echo_n "checking for fish options with pkg-config... " >&6; }
27773 itexists=`
27774 if test -n ""; then
27775 PKG_CONFIG_LIBDIR=""
27776 export PKG_CONFIG_LIBDIR
27777 fi
27778 $PKGCONFIG --exists fish >/dev/null 2>&1 && echo 1`
27779
27780 if test -z "$itexists"; then
27781 PKGCONFIG="no"
27782 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27783$as_echo "no" >&6; }
27784 else
27785 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
27786$as_echo "found" >&6; }
27787 fi
27788 fi
27789
27790 if test "$PKGCONFIG" != "no" ; then
27791 FISH_FUNCTIONS_DIR="$($PKGCONFIG --variable completionsdir fish)"
27792 else
27793 FISH_FUNCTIONS_DIR="$datarootdir/fish/vendor_completions.d"
27794 fi
Haibo Huang65021c72019-03-27 15:37:23 -070027795
27796 ;;
27797 *)
27798 FISH_FUNCTIONS_DIR="$withval"
27799
27800 ;;
27801esac
27802
27803
Elliott Hughes82be86d2017-09-20 17:00:17 -070027804{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
27805$as_echo_n "checking for ANSI C header files... " >&6; }
27806if ${ac_cv_header_stdc+:} false; then :
27807 $as_echo_n "(cached) " >&6
27808else
27809 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27810/* end confdefs.h. */
27811#include <stdlib.h>
27812#include <stdarg.h>
27813#include <string.h>
27814#include <float.h>
27815
27816int main (void)
27817{
27818
27819 ;
27820 return 0;
27821}
27822_ACEOF
27823if ac_fn_c_try_compile "$LINENO"; then :
27824 ac_cv_header_stdc=yes
27825else
27826 ac_cv_header_stdc=no
27827fi
27828rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27829
27830if test $ac_cv_header_stdc = yes; then
27831 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
27832 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27833/* end confdefs.h. */
27834#include <string.h>
27835
27836_ACEOF
27837if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27838 $EGREP "memchr" >/dev/null 2>&1; then :
27839
27840else
27841 ac_cv_header_stdc=no
27842fi
27843rm -f conftest*
27844
27845fi
27846
27847if test $ac_cv_header_stdc = yes; then
27848 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
27849 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27850/* end confdefs.h. */
27851#include <stdlib.h>
27852
27853_ACEOF
27854if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27855 $EGREP "free" >/dev/null 2>&1; then :
27856
27857else
27858 ac_cv_header_stdc=no
27859fi
27860rm -f conftest*
27861
27862fi
27863
27864if test $ac_cv_header_stdc = yes; then
27865 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
27866 if test "$cross_compiling" = yes; then :
27867 :
27868else
27869 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27870/* end confdefs.h. */
27871#include <ctype.h>
27872#include <stdlib.h>
27873#if ((' ' & 0x0FF) == 0x020)
27874# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
27875# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
27876#else
27877# define ISLOWER(c) \
27878 (('a' <= (c) && (c) <= 'i') \
27879 || ('j' <= (c) && (c) <= 'r') \
27880 || ('s' <= (c) && (c) <= 'z'))
27881# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
27882#endif
27883
27884#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
27885int
27886main ()
27887{
27888 int i;
27889 for (i = 0; i < 256; i++)
27890 if (XOR (islower (i), ISLOWER (i))
27891 || toupper (i) != TOUPPER (i))
27892 return 2;
27893 return 0;
27894}
27895_ACEOF
27896if ac_fn_c_try_run "$LINENO"; then :
27897
27898else
27899 ac_cv_header_stdc=no
27900fi
27901rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27902 conftest.$ac_objext conftest.beam conftest.$ac_ext
27903fi
27904
27905fi
27906fi
27907{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
27908$as_echo "$ac_cv_header_stdc" >&6; }
27909if test $ac_cv_header_stdc = yes; then
27910
27911$as_echo "#define STDC_HEADERS 1" >>confdefs.h
27912
27913fi
27914
27915
27916
27917 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for malloc.h" >&5
27918$as_echo_n "checking for malloc.h... " >&6; }
27919if ${curl_cv_header_malloc_h+:} false; then :
27920 $as_echo_n "(cached) " >&6
27921else
27922
27923 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27924/* end confdefs.h. */
27925
27926
27927#include <malloc.h>
27928
27929int main (void)
27930{
27931
27932 void *p = malloc(10);
27933 void *q = calloc(10,10);
27934 free(p);
27935 free(q);
27936
27937 ;
27938 return 0;
27939}
27940
27941_ACEOF
27942if ac_fn_c_try_compile "$LINENO"; then :
27943
27944 curl_cv_header_malloc_h="yes"
27945
27946else
27947
27948 curl_cv_header_malloc_h="no"
27949
27950fi
27951rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27952
27953fi
27954{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_malloc_h" >&5
27955$as_echo "$curl_cv_header_malloc_h" >&6; }
27956 if test "$curl_cv_header_malloc_h" = "yes"; then
27957
27958cat >>confdefs.h <<_ACEOF
27959#define HAVE_MALLOC_H 1
27960_ACEOF
27961
27962 #
27963 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27964/* end confdefs.h. */
27965
27966
27967#include <stdlib.h>
27968
27969int main (void)
27970{
27971
27972 void *p = malloc(10);
27973 void *q = calloc(10,10);
27974 free(p);
27975 free(q);
27976
27977 ;
27978 return 0;
27979}
27980
27981_ACEOF
27982if ac_fn_c_try_compile "$LINENO"; then :
27983
27984 curl_cv_need_header_malloc_h="no"
27985
27986else
27987
27988 curl_cv_need_header_malloc_h="yes"
27989
27990fi
27991rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27992 #
27993 case "$curl_cv_need_header_malloc_h" in
27994 yes)
27995
27996cat >>confdefs.h <<_ACEOF
27997#define NEED_MALLOC_H 1
27998_ACEOF
27999
28000 ;;
28001 esac
28002 fi
28003
28004
28005 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for memory.h" >&5
28006$as_echo_n "checking for memory.h... " >&6; }
28007if ${curl_cv_header_memory_h+:} false; then :
28008 $as_echo_n "(cached) " >&6
28009else
28010
28011 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28012/* end confdefs.h. */
28013
28014
28015#include <memory.h>
28016
28017int main (void)
28018{
28019
28020 void *p = malloc(10);
28021 void *q = calloc(10,10);
28022 free(p);
28023 free(q);
28024
28025 ;
28026 return 0;
28027}
28028
28029_ACEOF
28030if ac_fn_c_try_compile "$LINENO"; then :
28031
28032 curl_cv_header_memory_h="yes"
28033
28034else
28035
28036 curl_cv_header_memory_h="no"
28037
28038fi
28039rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28040
28041fi
28042{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_memory_h" >&5
28043$as_echo "$curl_cv_header_memory_h" >&6; }
28044 if test "$curl_cv_header_memory_h" = "yes"; then
28045
28046cat >>confdefs.h <<_ACEOF
28047#define HAVE_MEMORY_H 1
28048_ACEOF
28049
28050 #
28051 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28052/* end confdefs.h. */
28053
28054
28055#include <stdlib.h>
28056
28057int main (void)
28058{
28059
28060 void *p = malloc(10);
28061 void *q = calloc(10,10);
28062 free(p);
28063 free(q);
28064
28065 ;
28066 return 0;
28067}
28068
28069_ACEOF
28070if ac_fn_c_try_compile "$LINENO"; then :
28071
28072 curl_cv_need_header_memory_h="no"
28073
28074else
28075
28076 curl_cv_need_header_memory_h="yes"
28077
28078fi
28079rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28080 #
28081 case "$curl_cv_need_header_memory_h" in
28082 yes)
28083
28084cat >>confdefs.h <<_ACEOF
28085#define NEED_MEMORY_H 1
28086_ACEOF
28087
28088 ;;
28089 esac
28090 fi
28091
28092
28093for ac_header in sys/types.h \
28094 sys/time.h \
28095 sys/select.h \
28096 sys/socket.h \
28097 sys/ioctl.h \
28098 sys/uio.h \
28099 assert.h \
28100 unistd.h \
28101 stdlib.h \
Elliott Hughes82be86d2017-09-20 17:00:17 -070028102 arpa/inet.h \
28103 net/if.h \
28104 netinet/in.h \
Elliott Hughes0128fe42018-02-27 14:57:55 -080028105 netinet/in6.h \
Elliott Hughes82be86d2017-09-20 17:00:17 -070028106 sys/un.h \
Alex Deymo486467e2017-12-19 19:04:07 +010028107 linux/tcp.h \
Elliott Hughes82be86d2017-09-20 17:00:17 -070028108 netinet/tcp.h \
28109 netdb.h \
28110 sys/sockio.h \
28111 sys/stat.h \
28112 sys/param.h \
28113 termios.h \
28114 termio.h \
28115 sgtty.h \
28116 fcntl.h \
28117 alloca.h \
28118 time.h \
28119 io.h \
28120 pwd.h \
28121 utime.h \
28122 sys/utime.h \
28123 sys/poll.h \
28124 poll.h \
28125 socket.h \
28126 sys/resource.h \
28127 libgen.h \
28128 locale.h \
28129 errno.h \
28130 stdbool.h \
28131 arpa/tftp.h \
28132 sys/filio.h \
28133 sys/wait.h \
28134 setjmp.h
28135do :
28136 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
28137ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "
28138#ifdef HAVE_SYS_TYPES_H
28139#include <sys/types.h>
28140#endif
28141#ifdef HAVE_SYS_TIME_H
28142#include <sys/time.h>
28143#endif
28144#ifdef HAVE_SYS_SELECT_H
28145#include <sys/select.h>
28146#endif
28147#ifdef HAVE_SYS_SOCKET_H
28148#include <sys/socket.h>
28149#endif
28150#ifdef HAVE_NETINET_IN_H
28151#include <netinet/in.h>
28152#endif
Elliott Hughes0128fe42018-02-27 14:57:55 -080028153#ifdef HAVE_NETINET_IN6_H
28154#include <netinet/in6.h>
28155#endif
Elliott Hughes82be86d2017-09-20 17:00:17 -070028156#ifdef HAVE_SYS_UN_H
28157#include <sys/un.h>
28158#endif
28159
28160
28161"
28162if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
28163 cat >>confdefs.h <<_ACEOF
28164#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
28165_ACEOF
28166
28167fi
28168
28169done
28170
28171
Haibo Huang65021c72019-03-27 15:37:23 -070028172
Elliott Hughes82be86d2017-09-20 17:00:17 -070028173{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
28174$as_echo_n "checking for an ANSI C-conforming const... " >&6; }
28175if ${ac_cv_c_const+:} false; then :
28176 $as_echo_n "(cached) " >&6
28177else
28178 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28179/* end confdefs.h. */
28180
28181int main (void)
28182{
28183
28184#ifndef __cplusplus
28185 /* Ultrix mips cc rejects this sort of thing. */
28186 typedef int charset[2];
28187 const charset cs = { 0, 0 };
28188 /* SunOS 4.1.1 cc rejects this. */
28189 char const *const *pcpcc;
28190 char **ppc;
28191 /* NEC SVR4.0.2 mips cc rejects this. */
28192 struct point {int x, y;};
28193 static struct point const zero = {0,0};
28194 /* AIX XL C 1.02.0.0 rejects this.
28195 It does not let you subtract one const X* pointer from another in
28196 an arm of an if-expression whose if-part is not a constant
28197 expression */
28198 const char *g = "string";
28199 pcpcc = &g + (g ? g-g : 0);
28200 /* HPUX 7.0 cc rejects these. */
28201 ++pcpcc;
28202 ppc = (char**) pcpcc;
28203 pcpcc = (char const *const *) ppc;
28204 { /* SCO 3.2v4 cc rejects this sort of thing. */
28205 char tx;
28206 char *t = &tx;
28207 char const *s = 0 ? (char *) 0 : (char const *) 0;
28208
28209 *t++ = 0;
28210 if (s) return 0;
28211 }
28212 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
28213 int x[] = {25, 17};
28214 const int *foo = &x[0];
28215 ++foo;
28216 }
28217 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
28218 typedef const int *iptr;
28219 iptr p = 0;
28220 ++p;
28221 }
28222 { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying
28223 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
28224 struct s { int j; const int *ap[3]; } bx;
28225 struct s *b = &bx; b->j = 5;
28226 }
28227 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
28228 const int foo = 10;
28229 if (!foo) return 0;
28230 }
28231 return !cs[0] && !zero.x;
28232#endif
28233
28234 ;
28235 return 0;
28236}
28237_ACEOF
28238if ac_fn_c_try_compile "$LINENO"; then :
28239 ac_cv_c_const=yes
28240else
28241 ac_cv_c_const=no
28242fi
28243rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28244fi
28245{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
28246$as_echo "$ac_cv_c_const" >&6; }
28247if test $ac_cv_c_const = no; then
28248
28249$as_echo "#define const /**/" >>confdefs.h
28250
28251fi
28252
28253
28254 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compiler support of C99 variadic macro style" >&5
28255$as_echo_n "checking for compiler support of C99 variadic macro style... " >&6; }
28256if ${curl_cv_variadic_macros_c99+:} false; then :
28257 $as_echo_n "(cached) " >&6
28258else
28259
28260 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28261/* end confdefs.h. */
28262
28263
28264#define c99_vmacro3(first, ...) fun3(first, __VA_ARGS__)
28265#define c99_vmacro2(first, ...) fun2(first, __VA_ARGS__)
28266 int fun3(int arg1, int arg2, int arg3);
28267 int fun2(int arg1, int arg2);
28268 int fun3(int arg1, int arg2, int arg3)
28269 { return arg1 + arg2 + arg3; }
28270 int fun2(int arg1, int arg2)
28271 { return arg1 + arg2; }
28272
28273int main (void)
28274{
28275
28276 int res3 = c99_vmacro3(1, 2, 3);
28277 int res2 = c99_vmacro2(1, 2);
28278
28279 ;
28280 return 0;
28281}
28282
28283_ACEOF
28284if ac_fn_c_try_compile "$LINENO"; then :
28285
28286 curl_cv_variadic_macros_c99="yes"
28287
28288else
28289
28290 curl_cv_variadic_macros_c99="no"
28291
28292fi
28293rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28294
28295fi
28296{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_variadic_macros_c99" >&5
28297$as_echo "$curl_cv_variadic_macros_c99" >&6; }
28298 case "$curl_cv_variadic_macros_c99" in
28299 yes)
28300
28301cat >>confdefs.h <<_ACEOF
28302#define HAVE_VARIADIC_MACROS_C99 1
28303_ACEOF
28304
28305 ;;
28306 esac
28307 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compiler support of old gcc variadic macro style" >&5
28308$as_echo_n "checking for compiler support of old gcc variadic macro style... " >&6; }
28309if ${curl_cv_variadic_macros_gcc+:} false; then :
28310 $as_echo_n "(cached) " >&6
28311else
28312
28313 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28314/* end confdefs.h. */
28315
28316
28317#define gcc_vmacro3(first, args...) fun3(first, args)
28318#define gcc_vmacro2(first, args...) fun2(first, args)
28319 int fun3(int arg1, int arg2, int arg3);
28320 int fun2(int arg1, int arg2);
28321 int fun3(int arg1, int arg2, int arg3)
28322 { return arg1 + arg2 + arg3; }
28323 int fun2(int arg1, int arg2)
28324 { return arg1 + arg2; }
28325
28326int main (void)
28327{
28328
28329 int res3 = gcc_vmacro3(1, 2, 3);
28330 int res2 = gcc_vmacro2(1, 2);
28331
28332 ;
28333 return 0;
28334}
28335
28336_ACEOF
28337if ac_fn_c_try_compile "$LINENO"; then :
28338
28339 curl_cv_variadic_macros_gcc="yes"
28340
28341else
28342
28343 curl_cv_variadic_macros_gcc="no"
28344
28345fi
28346rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28347
28348fi
28349{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_variadic_macros_gcc" >&5
28350$as_echo "$curl_cv_variadic_macros_gcc" >&6; }
28351 case "$curl_cv_variadic_macros_gcc" in
28352 yes)
28353
28354cat >>confdefs.h <<_ACEOF
28355#define HAVE_VARIADIC_MACROS_GCC 1
28356_ACEOF
28357
28358 ;;
28359 esac
28360
28361ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
28362if test "x$ac_cv_type_size_t" = xyes; then :
28363
28364else
28365
28366cat >>confdefs.h <<_ACEOF
28367#define size_t unsigned int
28368_ACEOF
28369
28370fi
28371
28372{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
28373$as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
28374if ${ac_cv_header_time+:} false; then :
28375 $as_echo_n "(cached) " >&6
28376else
28377 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28378/* end confdefs.h. */
28379#include <sys/types.h>
28380#include <sys/time.h>
28381#include <time.h>
28382
28383int main (void)
28384{
28385if ((struct tm *) 0)
28386return 0;
28387 ;
28388 return 0;
28389}
28390_ACEOF
28391if ac_fn_c_try_compile "$LINENO"; then :
28392 ac_cv_header_time=yes
28393else
28394 ac_cv_header_time=no
28395fi
28396rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28397fi
28398{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
28399$as_echo "$ac_cv_header_time" >&6; }
28400if test $ac_cv_header_time = yes; then
28401
28402$as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
28403
28404fi
28405
28406
28407 for ac_header in sys/types.h sys/time.h time.h sys/socket.h
28408do :
28409 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
28410ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
28411if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
28412 cat >>confdefs.h <<_ACEOF
28413#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
28414_ACEOF
28415
28416fi
28417
28418done
28419
28420 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
28421$as_echo_n "checking for struct timeval... " >&6; }
28422if ${curl_cv_struct_timeval+:} false; then :
28423 $as_echo_n "(cached) " >&6
28424else
28425
28426 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28427/* end confdefs.h. */
28428
28429
28430#undef inline
28431#ifdef HAVE_WINDOWS_H
28432#ifndef WIN32_LEAN_AND_MEAN
28433#define WIN32_LEAN_AND_MEAN
28434#endif
28435#include <windows.h>
28436#ifdef HAVE_WINSOCK2_H
28437#include <winsock2.h>
28438#else
28439#ifdef HAVE_WINSOCK_H
28440#include <winsock.h>
28441#endif
28442#endif
28443#endif
28444#ifdef HAVE_SYS_TYPES_H
28445#include <sys/types.h>
28446#endif
28447#ifdef HAVE_SYS_TIME_H
28448#include <sys/time.h>
28449#ifdef TIME_WITH_SYS_TIME
28450#include <time.h>
28451#endif
28452#else
28453#ifdef HAVE_TIME_H
28454#include <time.h>
28455#endif
28456#endif
28457#ifdef HAVE_SYS_SOCKET_H
28458#include <sys/socket.h>
28459#endif
28460
28461int main (void)
28462{
28463
28464 struct timeval ts;
28465 ts.tv_sec = 0;
28466 ts.tv_usec = 0;
28467
28468 ;
28469 return 0;
28470}
28471
28472_ACEOF
28473if ac_fn_c_try_compile "$LINENO"; then :
28474
28475 curl_cv_struct_timeval="yes"
28476
28477else
28478
28479 curl_cv_struct_timeval="no"
28480
28481fi
28482rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28483
28484fi
28485{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_struct_timeval" >&5
28486$as_echo "$curl_cv_struct_timeval" >&6; }
28487 case "$curl_cv_struct_timeval" in
28488 yes)
28489
28490cat >>confdefs.h <<_ACEOF
28491#define HAVE_STRUCT_TIMEVAL 1
28492_ACEOF
28493
28494 ;;
28495 esac
28496
28497
28498
28499 if test "x$cross_compiling" != xyes; then
28500
28501 { $as_echo "$as_me:${as_lineno-$LINENO}: checking run-time libs availability" >&5
28502$as_echo_n "checking run-time libs availability... " >&6; }
Elliott Hughes72d948d2018-08-03 14:37:21 -070028503
28504
28505 old=$LD_LIBRARY_PATH
28506 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
28507 export LD_LIBRARY_PATH
28508 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070028509 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
28510$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
28511as_fn_error $? "cannot run test program while cross compiling
28512See \`config.log' for more details" "$LINENO" 5; }
28513else
28514 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28515/* end confdefs.h. */
28516
Elliott Hughesb1ef70f2018-10-30 11:28:38 -070028517int main()
Elliott Hughes82be86d2017-09-20 17:00:17 -070028518{
28519 return 0;
28520}
28521
28522_ACEOF
28523if ac_fn_c_try_run "$LINENO"; then :
28524 { $as_echo "$as_me:${as_lineno-$LINENO}: result: fine" >&5
28525$as_echo "fine" >&6; }
28526else
28527 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
28528$as_echo "failed" >&6; }
28529 as_fn_error $? "one or more libs available at link-time are not available run-time. Libs used at link-time: $LIBS" "$LINENO" 5
28530
28531fi
28532rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28533 conftest.$ac_objext conftest.beam conftest.$ac_ext
28534fi
28535
Elliott Hughes72d948d2018-08-03 14:37:21 -070028536 LD_LIBRARY_PATH=$old # restore
28537
Elliott Hughes82be86d2017-09-20 17:00:17 -070028538
28539 fi
28540
28541
Elliott Hughes82be86d2017-09-20 17:00:17 -070028542{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of size_t" >&5
28543$as_echo_n "checking size of size_t... " >&6; }
28544if ${ac_cv_sizeof_size_t+:} false; then :
28545 $as_echo_n "(cached) " >&6
28546else
Elliott Hughes72d948d2018-08-03 14:37:21 -070028547 for ac_size in 4 8 1 2 16 ; do # List sizes in rough order of prevalence.
28548 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28549/* end confdefs.h. */
Elliott Hughes82be86d2017-09-20 17:00:17 -070028550
Elliott Hughes72d948d2018-08-03 14:37:21 -070028551#include <sys/types.h>
28552
28553
28554int main (void)
28555{
28556switch (0) case 0: case (sizeof (size_t) == $ac_size):;
28557 ;
28558 return 0;
28559}
28560_ACEOF
28561if ac_fn_c_try_compile "$LINENO"; then :
28562 ac_cv_sizeof_size_t=$ac_size
28563fi
28564rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28565 if test x$ac_cv_sizeof_size_t != x ; then break; fi
28566done
28567
Elliott Hughes82be86d2017-09-20 17:00:17 -070028568fi
28569
Elliott Hughes72d948d2018-08-03 14:37:21 -070028570if test x$ac_cv_sizeof_size_t = x ; then
28571 as_fn_error $? "cannot determine a size for size_t" "$LINENO" 5
Elliott Hughes82be86d2017-09-20 17:00:17 -070028572fi
28573{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_size_t" >&5
28574$as_echo "$ac_cv_sizeof_size_t" >&6; }
28575
Elliott Hughes82be86d2017-09-20 17:00:17 -070028576cat >>confdefs.h <<_ACEOF
28577#define SIZEOF_SIZE_T $ac_cv_sizeof_size_t
28578_ACEOF
28579
28580
Elliott Hughes82be86d2017-09-20 17:00:17 -070028581{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
28582$as_echo_n "checking size of long... " >&6; }
28583if ${ac_cv_sizeof_long+:} false; then :
28584 $as_echo_n "(cached) " >&6
28585else
Elliott Hughes72d948d2018-08-03 14:37:21 -070028586 for ac_size in 4 8 1 2 16 ; do # List sizes in rough order of prevalence.
28587 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28588/* end confdefs.h. */
Elliott Hughes82be86d2017-09-20 17:00:17 -070028589
Elliott Hughes72d948d2018-08-03 14:37:21 -070028590#include <sys/types.h>
28591
28592
28593int main (void)
28594{
28595switch (0) case 0: case (sizeof (long) == $ac_size):;
28596 ;
28597 return 0;
28598}
28599_ACEOF
28600if ac_fn_c_try_compile "$LINENO"; then :
28601 ac_cv_sizeof_long=$ac_size
28602fi
28603rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28604 if test x$ac_cv_sizeof_long != x ; then break; fi
28605done
28606
Elliott Hughes82be86d2017-09-20 17:00:17 -070028607fi
28608
Elliott Hughes72d948d2018-08-03 14:37:21 -070028609if test x$ac_cv_sizeof_long = x ; then
28610 as_fn_error $? "cannot determine a size for long" "$LINENO" 5
Elliott Hughes82be86d2017-09-20 17:00:17 -070028611fi
28612{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
28613$as_echo "$ac_cv_sizeof_long" >&6; }
28614
Elliott Hughes82be86d2017-09-20 17:00:17 -070028615cat >>confdefs.h <<_ACEOF
28616#define SIZEOF_LONG $ac_cv_sizeof_long
28617_ACEOF
28618
28619
Elliott Hughes82be86d2017-09-20 17:00:17 -070028620{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5
28621$as_echo_n "checking size of int... " >&6; }
28622if ${ac_cv_sizeof_int+:} false; then :
28623 $as_echo_n "(cached) " >&6
28624else
Elliott Hughes72d948d2018-08-03 14:37:21 -070028625 for ac_size in 4 8 1 2 16 ; do # List sizes in rough order of prevalence.
28626 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28627/* end confdefs.h. */
Elliott Hughes82be86d2017-09-20 17:00:17 -070028628
Elliott Hughes72d948d2018-08-03 14:37:21 -070028629#include <sys/types.h>
28630
28631
28632int main (void)
28633{
28634switch (0) case 0: case (sizeof (int) == $ac_size):;
28635 ;
28636 return 0;
28637}
28638_ACEOF
28639if ac_fn_c_try_compile "$LINENO"; then :
28640 ac_cv_sizeof_int=$ac_size
28641fi
28642rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28643 if test x$ac_cv_sizeof_int != x ; then break; fi
28644done
28645
Elliott Hughes82be86d2017-09-20 17:00:17 -070028646fi
28647
Elliott Hughes72d948d2018-08-03 14:37:21 -070028648if test x$ac_cv_sizeof_int = x ; then
28649 as_fn_error $? "cannot determine a size for int" "$LINENO" 5
Elliott Hughes82be86d2017-09-20 17:00:17 -070028650fi
28651{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5
28652$as_echo "$ac_cv_sizeof_int" >&6; }
28653
Elliott Hughes82be86d2017-09-20 17:00:17 -070028654cat >>confdefs.h <<_ACEOF
28655#define SIZEOF_INT $ac_cv_sizeof_int
28656_ACEOF
28657
28658
Elliott Hughes82be86d2017-09-20 17:00:17 -070028659{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5
28660$as_echo_n "checking size of short... " >&6; }
28661if ${ac_cv_sizeof_short+:} false; then :
28662 $as_echo_n "(cached) " >&6
28663else
Elliott Hughes72d948d2018-08-03 14:37:21 -070028664 for ac_size in 4 8 1 2 16 ; do # List sizes in rough order of prevalence.
28665 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28666/* end confdefs.h. */
Elliott Hughes82be86d2017-09-20 17:00:17 -070028667
Elliott Hughes72d948d2018-08-03 14:37:21 -070028668#include <sys/types.h>
28669
28670
28671int main (void)
28672{
28673switch (0) case 0: case (sizeof (short) == $ac_size):;
28674 ;
28675 return 0;
28676}
28677_ACEOF
28678if ac_fn_c_try_compile "$LINENO"; then :
28679 ac_cv_sizeof_short=$ac_size
28680fi
28681rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28682 if test x$ac_cv_sizeof_short != x ; then break; fi
28683done
28684
Elliott Hughes82be86d2017-09-20 17:00:17 -070028685fi
28686
Elliott Hughes72d948d2018-08-03 14:37:21 -070028687if test x$ac_cv_sizeof_short = x ; then
28688 as_fn_error $? "cannot determine a size for short" "$LINENO" 5
Elliott Hughes82be86d2017-09-20 17:00:17 -070028689fi
28690{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5
28691$as_echo "$ac_cv_sizeof_short" >&6; }
28692
Elliott Hughes82be86d2017-09-20 17:00:17 -070028693cat >>confdefs.h <<_ACEOF
28694#define SIZEOF_SHORT $ac_cv_sizeof_short
28695_ACEOF
28696
28697
Elliott Hughes82be86d2017-09-20 17:00:17 -070028698{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of time_t" >&5
28699$as_echo_n "checking size of time_t... " >&6; }
28700if ${ac_cv_sizeof_time_t+:} false; then :
28701 $as_echo_n "(cached) " >&6
28702else
Elliott Hughes72d948d2018-08-03 14:37:21 -070028703 for ac_size in 4 8 1 2 16 ; do # List sizes in rough order of prevalence.
28704 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28705/* end confdefs.h. */
Elliott Hughes82be86d2017-09-20 17:00:17 -070028706
Elliott Hughes72d948d2018-08-03 14:37:21 -070028707#include <sys/types.h>
28708
28709
28710int main (void)
28711{
28712switch (0) case 0: case (sizeof (time_t) == $ac_size):;
28713 ;
28714 return 0;
28715}
28716_ACEOF
28717if ac_fn_c_try_compile "$LINENO"; then :
28718 ac_cv_sizeof_time_t=$ac_size
28719fi
28720rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28721 if test x$ac_cv_sizeof_time_t != x ; then break; fi
28722done
28723
Elliott Hughes82be86d2017-09-20 17:00:17 -070028724fi
28725
Elliott Hughes72d948d2018-08-03 14:37:21 -070028726if test x$ac_cv_sizeof_time_t = x ; then
28727 as_fn_error $? "cannot determine a size for time_t" "$LINENO" 5
Elliott Hughes82be86d2017-09-20 17:00:17 -070028728fi
28729{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_time_t" >&5
28730$as_echo "$ac_cv_sizeof_time_t" >&6; }
28731
Elliott Hughes82be86d2017-09-20 17:00:17 -070028732cat >>confdefs.h <<_ACEOF
28733#define SIZEOF_TIME_T $ac_cv_sizeof_time_t
28734_ACEOF
28735
28736
Elliott Hughes82be86d2017-09-20 17:00:17 -070028737{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of off_t" >&5
28738$as_echo_n "checking size of off_t... " >&6; }
28739if ${ac_cv_sizeof_off_t+:} false; then :
28740 $as_echo_n "(cached) " >&6
28741else
Elliott Hughes72d948d2018-08-03 14:37:21 -070028742 for ac_size in 4 8 1 2 16 ; do # List sizes in rough order of prevalence.
28743 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28744/* end confdefs.h. */
Elliott Hughes82be86d2017-09-20 17:00:17 -070028745
Elliott Hughes72d948d2018-08-03 14:37:21 -070028746#include <sys/types.h>
28747
28748
28749int main (void)
28750{
28751switch (0) case 0: case (sizeof (off_t) == $ac_size):;
28752 ;
28753 return 0;
28754}
28755_ACEOF
28756if ac_fn_c_try_compile "$LINENO"; then :
28757 ac_cv_sizeof_off_t=$ac_size
28758fi
28759rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28760 if test x$ac_cv_sizeof_off_t != x ; then break; fi
28761done
28762
Elliott Hughes82be86d2017-09-20 17:00:17 -070028763fi
28764
Elliott Hughes72d948d2018-08-03 14:37:21 -070028765if test x$ac_cv_sizeof_off_t = x ; then
28766 as_fn_error $? "cannot determine a size for off_t" "$LINENO" 5
Elliott Hughes82be86d2017-09-20 17:00:17 -070028767fi
28768{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_off_t" >&5
28769$as_echo "$ac_cv_sizeof_off_t" >&6; }
28770
Elliott Hughes82be86d2017-09-20 17:00:17 -070028771cat >>confdefs.h <<_ACEOF
28772#define SIZEOF_OFF_T $ac_cv_sizeof_off_t
28773_ACEOF
28774
28775
28776
Alex Deymo486467e2017-12-19 19:04:07 +010028777o=$CPPFLAGS
28778CPPFLAGS="-I$srcdir/include $CPPFLAGS"
Alex Deymo486467e2017-12-19 19:04:07 +010028779{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of curl_off_t" >&5
28780$as_echo_n "checking size of curl_off_t... " >&6; }
28781if ${ac_cv_sizeof_curl_off_t+:} false; then :
28782 $as_echo_n "(cached) " >&6
28783else
Elliott Hughes72d948d2018-08-03 14:37:21 -070028784 for ac_size in 4 8 1 2 16 ; do # List sizes in rough order of prevalence.
28785 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28786/* end confdefs.h. */
28787
28788#include <sys/types.h>
28789
Alex Deymo486467e2017-12-19 19:04:07 +010028790#include <curl/system.h>
28791
Alex Deymo486467e2017-12-19 19:04:07 +010028792
Elliott Hughes72d948d2018-08-03 14:37:21 -070028793int main (void)
28794{
28795switch (0) case 0: case (sizeof (curl_off_t) == $ac_size):;
28796 ;
28797 return 0;
28798}
28799_ACEOF
28800if ac_fn_c_try_compile "$LINENO"; then :
28801 ac_cv_sizeof_curl_off_t=$ac_size
28802fi
28803rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28804 if test x$ac_cv_sizeof_curl_off_t != x ; then break; fi
28805done
28806
Elliott Hughes82be86d2017-09-20 17:00:17 -070028807fi
28808
Elliott Hughes72d948d2018-08-03 14:37:21 -070028809if test x$ac_cv_sizeof_curl_off_t = x ; then
28810 as_fn_error $? "cannot determine a size for curl_off_t" "$LINENO" 5
Alex Deymo486467e2017-12-19 19:04:07 +010028811fi
28812{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_curl_off_t" >&5
28813$as_echo "$ac_cv_sizeof_curl_off_t" >&6; }
28814
Alex Deymo486467e2017-12-19 19:04:07 +010028815cat >>confdefs.h <<_ACEOF
28816#define SIZEOF_CURL_OFF_T $ac_cv_sizeof_curl_off_t
28817_ACEOF
28818
28819
28820CPPFLAGS=$o
Elliott Hughes82be86d2017-09-20 17:00:17 -070028821
28822ac_fn_c_check_type "$LINENO" "long long" "ac_cv_type_long_long" "$ac_includes_default"
28823if test "x$ac_cv_type_long_long" = xyes; then :
28824
28825$as_echo "#define HAVE_LONGLONG 1" >>confdefs.h
28826
28827 longlong="yes"
28828
28829fi
28830
28831
28832if test "xyes" = "x$longlong"; then
28833 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if numberLL works" >&5
28834$as_echo_n "checking if numberLL works... " >&6; }
28835 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28836/* end confdefs.h. */
28837
28838
28839
28840int main (void)
28841{
28842
28843 long long val = 1000LL;
28844
28845 ;
28846 return 0;
28847}
28848
28849_ACEOF
28850if ac_fn_c_try_compile "$LINENO"; then :
28851
28852 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
28853$as_echo "yes" >&6; }
28854
28855$as_echo "#define HAVE_LL 1" >>confdefs.h
28856
28857
28858else
28859
28860 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28861$as_echo "no" >&6; }
28862
28863fi
28864rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28865fi
28866
28867
28868# check for ssize_t
28869ac_fn_c_check_type "$LINENO" "ssize_t" "ac_cv_type_ssize_t" "$ac_includes_default"
28870if test "x$ac_cv_type_ssize_t" = xyes; then :
28871
28872else
28873
28874$as_echo "#define ssize_t int" >>confdefs.h
28875
28876fi
28877
28878
28879# check for bool type
28880ac_fn_c_check_type "$LINENO" "bool" "ac_cv_type_bool" "
28881#ifdef HAVE_SYS_TYPES_H
28882#include <sys/types.h>
28883#endif
28884#ifdef HAVE_STDBOOL_H
28885#include <stdbool.h>
28886#endif
28887
28888"
28889if test "x$ac_cv_type_bool" = xyes; then :
28890
28891
28892$as_echo "#define HAVE_BOOL_T 1" >>confdefs.h
28893
28894
28895fi
28896
28897
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070028898# check for sa_family_t
28899ac_fn_c_check_type "$LINENO" "sa_family_t" "ac_cv_type_sa_family_t" "
28900#ifdef HAVE_SYS_SOCKET_H
28901#include <sys/socket.h>
28902#endif
28903
28904"
28905if test "x$ac_cv_type_sa_family_t" = xyes; then :
28906
28907$as_echo "#define CURL_SA_FAMILY_T sa_family_t" >>confdefs.h
28908
28909else
28910
28911 # The windows name?
28912 ac_fn_c_check_type "$LINENO" "ADDRESS_FAMILY" "ac_cv_type_ADDRESS_FAMILY" "
28913#ifdef HAVE_SYS_SOCKET_H
28914#include <sys/socket.h>
28915#endif
28916
28917"
28918if test "x$ac_cv_type_ADDRESS_FAMILY" = xyes; then :
28919
28920$as_echo "#define CURL_SA_FAMILY_T ADDRESS_FAMILY" >>confdefs.h
28921
28922else
28923
28924$as_echo "#define CURL_SA_FAMILY_T unsigned short" >>confdefs.h
28925
28926fi
28927
28928
28929fi
28930
28931
Elliott Hughescac39802018-04-27 16:19:43 -070028932{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if time_t is unsigned" >&5
28933$as_echo_n "checking if time_t is unsigned... " >&6; }
Elliott Hughescac39802018-04-27 16:19:43 -070028934
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070028935
28936 old=$LD_LIBRARY_PATH
Elliott Hughes72d948d2018-08-03 14:37:21 -070028937 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
28938 export LD_LIBRARY_PATH
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070028939 if test "$cross_compiling" = yes; then :
Elliott Hughescac39802018-04-27 16:19:43 -070028940 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28941$as_echo "no" >&6; }
28942
28943else
28944 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28945/* end confdefs.h. */
28946
Elliott Hughescac39802018-04-27 16:19:43 -070028947 #include <time.h>
28948 #include <limits.h>
28949 time_t t = -1;
28950 return (t > 0);
28951
28952_ACEOF
28953if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughescac39802018-04-27 16:19:43 -070028954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
28955$as_echo "yes" >&6; }
28956
28957$as_echo "#define HAVE_TIME_T_UNSIGNED 1" >>confdefs.h
28958
28959
28960else
Elliott Hughescac39802018-04-27 16:19:43 -070028961 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
28962$as_echo "no" >&6; }
28963
28964fi
28965rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28966 conftest.$ac_objext conftest.beam conftest.$ac_ext
28967fi
28968
Elliott Hughes1ef06ba2018-05-30 15:43:58 -070028969 LD_LIBRARY_PATH=$old # restore
28970
Elliott Hughescac39802018-04-27 16:19:43 -070028971
Elliott Hughes82be86d2017-09-20 17:00:17 -070028972
Elliott Hughes82be86d2017-09-20 17:00:17 -070028973curl_includes_poll="\
28974/* includes start */
28975#ifdef HAVE_SYS_TYPES_H
28976# include <sys/types.h>
28977#endif
28978#ifdef HAVE_POLL_H
28979# include <poll.h>
28980#endif
28981#ifdef HAVE_SYS_POLL_H
28982# include <sys/poll.h>
28983#endif
28984/* includes end */"
28985 for ac_header in sys/types.h poll.h sys/poll.h
28986do :
28987 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
28988ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_poll
28989"
28990if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
28991 cat >>confdefs.h <<_ACEOF
28992#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
28993_ACEOF
28994
28995fi
28996
28997done
28998
28999
29000
29001 #
29002 tst_poll_events_macro_defined="unknown"
29003 #
29004 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29005/* end confdefs.h. */
29006
29007
29008 $curl_includes_poll
29009
29010int main (void)
29011{
29012
29013#if defined(events) || defined(revents)
29014 return 0;
29015#else
29016 force compilation error
29017#endif
29018
29019 ;
29020 return 0;
29021}
29022
29023_ACEOF
29024if ac_fn_c_try_compile "$LINENO"; then :
29025
29026 tst_poll_events_macro_defined="yes"
29027
29028else
29029
29030 tst_poll_events_macro_defined="no"
29031
29032fi
29033rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29034 #
29035 if test "$tst_poll_events_macro_defined" = "yes"; then
29036 if test "x$ac_cv_header_sys_poll_h" = "xyes"; then
29037
29038cat >>confdefs.h <<_EOF
29039#define CURL_PULL_SYS_POLL_H 1
29040_EOF
29041
29042 fi
29043 fi
29044 #
29045
29046
29047
29048 ac_fn_c_check_type "$LINENO" "in_addr_t" "ac_cv_type_in_addr_t" "
29049#undef inline
29050#ifdef HAVE_WINDOWS_H
29051#ifndef WIN32_LEAN_AND_MEAN
29052#define WIN32_LEAN_AND_MEAN
29053#endif
29054#include <windows.h>
29055#ifdef HAVE_WINSOCK2_H
29056#include <winsock2.h>
29057#else
29058#ifdef HAVE_WINSOCK_H
29059#include <winsock.h>
29060#endif
29061#endif
29062#else
29063#ifdef HAVE_SYS_TYPES_H
29064#include <sys/types.h>
29065#endif
29066#ifdef HAVE_SYS_SOCKET_H
29067#include <sys/socket.h>
29068#endif
29069#ifdef HAVE_NETINET_IN_H
29070#include <netinet/in.h>
29071#endif
29072#ifdef HAVE_ARPA_INET_H
29073#include <arpa/inet.h>
29074#endif
29075#endif
29076
29077"
29078if test "x$ac_cv_type_in_addr_t" = xyes; then :
29079
29080else
29081
29082 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for in_addr_t equivalent" >&5
29083$as_echo_n "checking for in_addr_t equivalent... " >&6; }
29084if ${curl_cv_in_addr_t_equiv+:} false; then :
29085 $as_echo_n "(cached) " >&6
29086else
29087
29088 curl_cv_in_addr_t_equiv="unknown"
29089 for t in "unsigned long" int size_t unsigned long; do
29090 if test "$curl_cv_in_addr_t_equiv" = "unknown"; then
29091 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29092/* end confdefs.h. */
29093
29094
29095#undef inline
29096#ifdef HAVE_WINDOWS_H
29097#ifndef WIN32_LEAN_AND_MEAN
29098#define WIN32_LEAN_AND_MEAN
29099#endif
29100#include <windows.h>
29101#ifdef HAVE_WINSOCK2_H
29102#include <winsock2.h>
29103#else
29104#ifdef HAVE_WINSOCK_H
29105#include <winsock.h>
29106#endif
29107#endif
29108#else
29109#ifdef HAVE_SYS_TYPES_H
29110#include <sys/types.h>
29111#endif
29112#ifdef HAVE_SYS_SOCKET_H
29113#include <sys/socket.h>
29114#endif
29115#ifdef HAVE_NETINET_IN_H
29116#include <netinet/in.h>
29117#endif
29118#ifdef HAVE_ARPA_INET_H
29119#include <arpa/inet.h>
29120#endif
29121#endif
29122
29123int main (void)
29124{
29125
29126 $t data = inet_addr ("1.2.3.4");
29127
29128 ;
29129 return 0;
29130}
29131
29132_ACEOF
29133if ac_fn_c_try_link "$LINENO"; then :
29134
29135 curl_cv_in_addr_t_equiv="$t"
29136
29137fi
29138rm -f core conftest.err conftest.$ac_objext \
29139 conftest$ac_exeext conftest.$ac_ext
29140 fi
29141 done
29142
29143fi
29144{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_in_addr_t_equiv" >&5
29145$as_echo "$curl_cv_in_addr_t_equiv" >&6; }
29146 case "$curl_cv_in_addr_t_equiv" in
29147 unknown)
29148 as_fn_error $? "Cannot find a type to use in place of in_addr_t" "$LINENO" 5
29149 ;;
29150 *)
29151
29152cat >>confdefs.h <<_ACEOF
29153#define in_addr_t $curl_cv_in_addr_t_equiv
29154_ACEOF
29155
29156 ;;
29157 esac
29158
29159fi
29160
29161
29162
29163
29164 ac_fn_c_check_type "$LINENO" "struct sockaddr_storage" "ac_cv_type_struct_sockaddr_storage" "
29165#undef inline
29166#ifdef HAVE_WINDOWS_H
29167#ifndef WIN32_LEAN_AND_MEAN
29168#define WIN32_LEAN_AND_MEAN
29169#endif
29170#include <windows.h>
29171#ifdef HAVE_WINSOCK2_H
29172#include <winsock2.h>
29173#endif
29174#else
29175#ifdef HAVE_SYS_TYPES_H
29176#include <sys/types.h>
29177#endif
29178#ifdef HAVE_SYS_SOCKET_H
29179#include <sys/socket.h>
29180#endif
29181#ifdef HAVE_NETINET_IN_H
29182#include <netinet/in.h>
29183#endif
29184#ifdef HAVE_ARPA_INET_H
29185#include <arpa/inet.h>
29186#endif
29187#endif
29188
29189"
29190if test "x$ac_cv_type_struct_sockaddr_storage" = xyes; then :
29191
29192$as_echo "#define HAVE_STRUCT_SOCKADDR_STORAGE 1" >>confdefs.h
29193
29194fi
29195
29196
29197
29198
29199 for ac_header in signal.h
29200do :
29201 ac_fn_c_check_header_mongrel "$LINENO" "signal.h" "ac_cv_header_signal_h" "$ac_includes_default"
29202if test "x$ac_cv_header_signal_h" = xyes; then :
29203 cat >>confdefs.h <<_ACEOF
29204#define HAVE_SIGNAL_H 1
29205_ACEOF
29206
29207fi
29208
29209done
29210
29211 ac_fn_c_check_type "$LINENO" "sig_atomic_t" "ac_cv_type_sig_atomic_t" "
29212#ifdef HAVE_SIGNAL_H
29213#include <signal.h>
29214#endif
29215
29216"
29217if test "x$ac_cv_type_sig_atomic_t" = xyes; then :
29218
29219
29220$as_echo "#define HAVE_SIG_ATOMIC_T 1" >>confdefs.h
29221
29222
29223fi
29224
29225 case "$ac_cv_type_sig_atomic_t" in
29226 yes)
29227 #
29228 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sig_atomic_t is already defined as volatile" >&5
29229$as_echo_n "checking if sig_atomic_t is already defined as volatile... " >&6; }
29230 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29231/* end confdefs.h. */
29232
29233
29234#ifdef HAVE_SIGNAL_H
29235#include <signal.h>
29236#endif
29237
29238int main (void)
29239{
29240
29241 static volatile sig_atomic_t dummy = 0;
29242
29243 ;
29244 return 0;
29245}
29246
29247_ACEOF
29248if ac_fn_c_try_link "$LINENO"; then :
29249
29250 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29251$as_echo "no" >&6; }
29252 curl_cv_sig_atomic_t_volatile="no"
29253
29254else
29255
29256 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
29257$as_echo "yes" >&6; }
29258 curl_cv_sig_atomic_t_volatile="yes"
29259
29260fi
29261rm -f core conftest.err conftest.$ac_objext \
29262 conftest$ac_exeext conftest.$ac_ext
29263 #
29264 if test "$curl_cv_sig_atomic_t_volatile" = "yes"; then
29265
29266$as_echo "#define HAVE_SIG_ATOMIC_T_VOLATILE 1" >>confdefs.h
29267
29268 fi
29269 ;;
29270 esac
29271
29272
29273{ $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5
29274$as_echo_n "checking return type of signal handlers... " >&6; }
29275if ${ac_cv_type_signal+:} false; then :
29276 $as_echo_n "(cached) " >&6
29277else
29278 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29279/* end confdefs.h. */
29280#include <sys/types.h>
29281#include <signal.h>
29282
29283int main (void)
29284{
29285return *(signal (0, 0)) (0) == 1;
29286 ;
29287 return 0;
29288}
29289_ACEOF
29290if ac_fn_c_try_compile "$LINENO"; then :
29291 ac_cv_type_signal=int
29292else
29293 ac_cv_type_signal=void
29294fi
29295rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29296fi
29297{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5
29298$as_echo "$ac_cv_type_signal" >&6; }
29299
29300cat >>confdefs.h <<_ACEOF
29301#define RETSIGTYPE $ac_cv_type_signal
29302_ACEOF
29303
29304
29305
29306
29307 for ac_header in sys/select.h sys/socket.h
29308do :
29309 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
29310ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
29311if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
29312 cat >>confdefs.h <<_ACEOF
29313#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
29314_ACEOF
29315
29316fi
29317
29318done
29319
29320 #
29321 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for select" >&5
29322$as_echo_n "checking for select... " >&6; }
29323 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29324/* end confdefs.h. */
29325
29326
29327#undef inline
29328#ifdef HAVE_WINDOWS_H
29329#ifndef WIN32_LEAN_AND_MEAN
29330#define WIN32_LEAN_AND_MEAN
29331#endif
29332#include <windows.h>
29333#ifdef HAVE_WINSOCK2_H
29334#include <winsock2.h>
29335#else
29336#ifdef HAVE_WINSOCK_H
29337#include <winsock.h>
29338#endif
29339#endif
29340#endif
29341#ifdef HAVE_SYS_TYPES_H
29342#include <sys/types.h>
29343#endif
29344#ifdef HAVE_SYS_TIME_H
29345#include <sys/time.h>
29346#ifdef TIME_WITH_SYS_TIME
29347#include <time.h>
29348#endif
29349#else
29350#ifdef HAVE_TIME_H
29351#include <time.h>
29352#endif
29353#endif
29354#ifndef HAVE_WINDOWS_H
Haibo Huang65021c72019-03-27 15:37:23 -070029355#ifdef HAVE_PROTO_BSDSOCKET_H
29356#include <proto/bsdsocket.h>
29357struct Library *SocketBase = NULL;
29358#define select(a,b,c,d,e) WaitSelect(a,b,c,d,e,0)
29359#endif
Elliott Hughes82be86d2017-09-20 17:00:17 -070029360#ifdef HAVE_SYS_SELECT_H
29361#include <sys/select.h>
29362#endif
29363#ifdef HAVE_SYS_SOCKET_H
29364#include <sys/socket.h>
29365#endif
29366#endif
29367
29368int main (void)
29369{
29370
29371 select(0, 0, 0, 0, 0);
29372
29373 ;
29374 return 0;
29375}
29376
29377_ACEOF
29378if ac_fn_c_try_link "$LINENO"; then :
29379
29380 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
29381$as_echo "yes" >&6; }
29382 curl_cv_select="yes"
29383
29384else
29385
29386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29387$as_echo "no" >&6; }
29388 curl_cv_select="no"
29389
29390fi
29391rm -f core conftest.err conftest.$ac_objext \
29392 conftest$ac_exeext conftest.$ac_ext
29393 #
29394 if test "$curl_cv_select" = "yes"; then
29395 { $as_echo "$as_me:${as_lineno-$LINENO}: checking types of args and return type for select" >&5
29396$as_echo_n "checking types of args and return type for select... " >&6; }
29397if ${curl_cv_func_select_args+:} false; then :
29398 $as_echo_n "(cached) " >&6
29399else
29400
29401 curl_cv_func_select_args="unknown"
29402 for sel_retv in 'int' 'ssize_t'; do
29403 for sel_arg1 in 'int' 'ssize_t' 'size_t' 'unsigned long int' 'unsigned int'; do
29404 for sel_arg234 in 'fd_set *' 'int *' 'void *'; do
29405 for sel_arg5 in 'struct timeval *' 'const struct timeval *'; do
29406 if test "$curl_cv_func_select_args" = "unknown"; then
29407 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29408/* end confdefs.h. */
29409
29410
29411#undef inline
29412#ifdef HAVE_WINDOWS_H
29413#ifndef WIN32_LEAN_AND_MEAN
29414#define WIN32_LEAN_AND_MEAN
29415#endif
29416#include <windows.h>
29417#ifdef HAVE_WINSOCK2_H
29418#include <winsock2.h>
29419#else
29420#ifdef HAVE_WINSOCK_H
29421#include <winsock.h>
29422#endif
29423#endif
29424#define SELECTCALLCONV PASCAL
29425#endif
29426#ifdef HAVE_SYS_TYPES_H
29427#include <sys/types.h>
29428#endif
29429#ifdef HAVE_SYS_TIME_H
29430#include <sys/time.h>
29431#ifdef TIME_WITH_SYS_TIME
29432#include <time.h>
29433#endif
29434#else
29435#ifdef HAVE_TIME_H
29436#include <time.h>
29437#endif
29438#endif
29439#ifndef HAVE_WINDOWS_H
Haibo Huang65021c72019-03-27 15:37:23 -070029440#ifdef HAVE_PROTO_BSDSOCKET_H
29441#include <proto/bsdsocket.h>
29442struct Library *SocketBase = NULL;
29443#define select(a,b,c,d,e) WaitSelect(a,b,c,d,e,0)
29444#endif
Elliott Hughes82be86d2017-09-20 17:00:17 -070029445#ifdef HAVE_SYS_SELECT_H
29446#include <sys/select.h>
29447#endif
29448#ifdef HAVE_SYS_SOCKET_H
29449#include <sys/socket.h>
29450#endif
29451#define SELECTCALLCONV
29452#endif
29453#ifndef HAVE_STRUCT_TIMEVAL
29454 struct timeval {
29455 long tv_sec;
29456 long tv_usec;
29457 };
29458#endif
Haibo Huang65021c72019-03-27 15:37:23 -070029459#ifndef HAVE_PROTO_BSDSOCKET_H
Elliott Hughes82be86d2017-09-20 17:00:17 -070029460 extern $sel_retv SELECTCALLCONV
Haibo Huang51d9d882019-02-06 01:36:06 -080029461 select($sel_arg1,
Elliott Hughes82be86d2017-09-20 17:00:17 -070029462 $sel_arg234,
29463 $sel_arg234,
29464 $sel_arg234,
29465 $sel_arg5);
Haibo Huang65021c72019-03-27 15:37:23 -070029466#endif
Elliott Hughes82be86d2017-09-20 17:00:17 -070029467
29468int main (void)
29469{
29470
29471 $sel_arg1 nfds=0;
29472 $sel_arg234 rfds=0;
29473 $sel_arg234 wfds=0;
29474 $sel_arg234 efds=0;
29475 $sel_retv res = select(nfds, rfds, wfds, efds, 0);
29476
29477 ;
29478 return 0;
29479}
29480
29481_ACEOF
29482if ac_fn_c_try_compile "$LINENO"; then :
29483
29484 curl_cv_func_select_args="$sel_arg1,$sel_arg234,$sel_arg5,$sel_retv"
29485
29486fi
29487rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29488 fi
29489 done
29490 done
29491 done
29492 done
29493
29494fi
29495{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_func_select_args" >&5
29496$as_echo "$curl_cv_func_select_args" >&6; } # AC-CACHE-CHECK
29497 if test "$curl_cv_func_select_args" = "unknown"; then
29498 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Cannot find proper types to use for select args" >&5
29499$as_echo "$as_me: WARNING: Cannot find proper types to use for select args" >&2;}
29500 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: HAVE_SELECT will not be defined" >&5
29501$as_echo "$as_me: WARNING: HAVE_SELECT will not be defined" >&2;}
29502 else
29503 select_prev_IFS=$IFS; IFS=','
29504 set dummy `echo "$curl_cv_func_select_args" | sed 's/\*/\*/g'`
29505 IFS=$select_prev_IFS
29506 shift
29507 #
29508 sel_qual_type_arg5=$3
29509 #
29510
29511cat >>confdefs.h <<_ACEOF
29512#define SELECT_TYPE_ARG1 $1
29513_ACEOF
29514
29515
29516cat >>confdefs.h <<_ACEOF
29517#define SELECT_TYPE_ARG234 $2
29518_ACEOF
29519
29520
29521cat >>confdefs.h <<_ACEOF
29522#define SELECT_TYPE_RETV $4
29523_ACEOF
29524
29525 #
29526 prev_sh_opts=$-
29527 #
29528 case $prev_sh_opts in
29529 *f*)
29530 ;;
29531 *)
29532 set -f
29533 ;;
29534 esac
29535 #
29536 case "$sel_qual_type_arg5" in
29537 const*)
29538 sel_qual_arg5=const
29539 sel_type_arg5=`echo $sel_qual_type_arg5 | sed 's/^const //'`
29540 ;;
29541 *)
29542 sel_qual_arg5=
29543 sel_type_arg5=$sel_qual_type_arg5
29544 ;;
29545 esac
29546 #
29547
29548cat >>confdefs.h <<_ACEOF
29549#define SELECT_QUAL_ARG5 $sel_qual_arg5
29550_ACEOF
29551
29552
29553cat >>confdefs.h <<_ACEOF
29554#define SELECT_TYPE_ARG5 $sel_type_arg5
29555_ACEOF
29556
29557 #
29558 case $prev_sh_opts in
29559 *f*)
29560 ;;
29561 *)
29562 set +f
29563 ;;
29564 esac
29565 #
29566
29567cat >>confdefs.h <<_ACEOF
29568#define HAVE_SELECT 1
29569_ACEOF
29570
29571 curl_cv_func_select="yes"
29572 fi
29573 fi
29574
29575
29576
29577 for ac_header in sys/types.h sys/socket.h
29578do :
29579 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
29580ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
29581if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
29582 cat >>confdefs.h <<_ACEOF
29583#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
29584_ACEOF
29585
29586fi
29587
29588done
29589
29590 #
29591 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for recv" >&5
29592$as_echo_n "checking for recv... " >&6; }
29593 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29594/* end confdefs.h. */
29595
29596
29597#undef inline
29598#ifdef HAVE_WINDOWS_H
29599#ifndef WIN32_LEAN_AND_MEAN
29600#define WIN32_LEAN_AND_MEAN
29601#endif
29602#include <windows.h>
29603#ifdef HAVE_WINSOCK2_H
29604#include <winsock2.h>
29605#else
29606#ifdef HAVE_WINSOCK_H
29607#include <winsock.h>
29608#endif
29609#endif
29610#else
Haibo Huang65021c72019-03-27 15:37:23 -070029611#ifdef HAVE_PROTO_BSDSOCKET_H
29612#include <proto/bsdsocket.h>
29613struct Library *SocketBase = NULL;
29614#endif
Elliott Hughes82be86d2017-09-20 17:00:17 -070029615#ifdef HAVE_SYS_TYPES_H
29616#include <sys/types.h>
29617#endif
29618#ifdef HAVE_SYS_SOCKET_H
29619#include <sys/socket.h>
29620#endif
29621#endif
29622
29623int main (void)
29624{
29625
29626 recv(0, 0, 0, 0);
29627
29628 ;
29629 return 0;
29630}
29631
29632_ACEOF
29633if ac_fn_c_try_link "$LINENO"; then :
29634
29635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
29636$as_echo "yes" >&6; }
29637 curl_cv_recv="yes"
29638
29639else
29640
29641 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29642$as_echo "no" >&6; }
29643 curl_cv_recv="no"
29644
29645fi
29646rm -f core conftest.err conftest.$ac_objext \
29647 conftest$ac_exeext conftest.$ac_ext
29648 #
29649 if test "$curl_cv_recv" = "yes"; then
29650 { $as_echo "$as_me:${as_lineno-$LINENO}: checking types of args and return type for recv" >&5
29651$as_echo_n "checking types of args and return type for recv... " >&6; }
29652if ${curl_cv_func_recv_args+:} false; then :
29653 $as_echo_n "(cached) " >&6
29654else
29655
29656 curl_cv_func_recv_args="unknown"
29657 for recv_retv in 'int' 'ssize_t'; do
29658 for recv_arg1 in 'int' 'ssize_t' 'SOCKET'; do
29659 for recv_arg2 in 'char *' 'void *'; do
29660 for recv_arg3 in 'size_t' 'int' 'socklen_t' 'unsigned int'; do
29661 for recv_arg4 in 'int' 'unsigned int'; do
29662 if test "$curl_cv_func_recv_args" = "unknown"; then
29663 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29664/* end confdefs.h. */
29665
29666
29667#undef inline
29668#ifdef HAVE_WINDOWS_H
29669#ifndef WIN32_LEAN_AND_MEAN
29670#define WIN32_LEAN_AND_MEAN
29671#endif
29672#include <windows.h>
29673#ifdef HAVE_WINSOCK2_H
29674#include <winsock2.h>
29675#else
29676#ifdef HAVE_WINSOCK_H
29677#include <winsock.h>
29678#endif
29679#endif
29680#define RECVCALLCONV PASCAL
29681#else
Haibo Huang65021c72019-03-27 15:37:23 -070029682#ifdef HAVE_PROTO_BSDSOCKET_H
29683#include <proto/bsdsocket.h>
29684struct Library *SocketBase = NULL;
29685#endif
Elliott Hughes82be86d2017-09-20 17:00:17 -070029686#ifdef HAVE_SYS_TYPES_H
29687#include <sys/types.h>
29688#endif
29689#ifdef HAVE_SYS_SOCKET_H
29690#include <sys/socket.h>
29691#endif
29692#define RECVCALLCONV
29693#endif
Haibo Huang65021c72019-03-27 15:37:23 -070029694#ifndef HAVE_PROTO_BSDSOCKET_H
Elliott Hughes82be86d2017-09-20 17:00:17 -070029695 extern $recv_retv RECVCALLCONV
Elliott Hughes82be86d2017-09-20 17:00:17 -070029696 recv($recv_arg1, $recv_arg2, $recv_arg3, $recv_arg4);
Haibo Huang65021c72019-03-27 15:37:23 -070029697#endif
Elliott Hughes82be86d2017-09-20 17:00:17 -070029698
29699int main (void)
29700{
29701
29702 $recv_arg1 s=0;
29703 $recv_arg2 buf=0;
29704 $recv_arg3 len=0;
29705 $recv_arg4 flags=0;
29706 $recv_retv res = recv(s, buf, len, flags);
29707
29708 ;
29709 return 0;
29710}
29711
29712_ACEOF
29713if ac_fn_c_try_compile "$LINENO"; then :
29714
29715 curl_cv_func_recv_args="$recv_arg1,$recv_arg2,$recv_arg3,$recv_arg4,$recv_retv"
29716
29717fi
29718rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29719 fi
29720 done
29721 done
29722 done
29723 done
29724 done
29725
29726fi
29727{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_func_recv_args" >&5
29728$as_echo "$curl_cv_func_recv_args" >&6; } # AC-CACHE-CHECK
29729 if test "$curl_cv_func_recv_args" = "unknown"; then
29730 as_fn_error $? "Cannot find proper types to use for recv args" "$LINENO" 5
29731 else
29732 recv_prev_IFS=$IFS; IFS=','
29733 set dummy `echo "$curl_cv_func_recv_args" | sed 's/\*/\*/g'`
29734 IFS=$recv_prev_IFS
29735 shift
29736 #
29737
29738cat >>confdefs.h <<_ACEOF
29739#define RECV_TYPE_ARG1 $1
29740_ACEOF
29741
29742
29743cat >>confdefs.h <<_ACEOF
29744#define RECV_TYPE_ARG2 $2
29745_ACEOF
29746
29747
29748cat >>confdefs.h <<_ACEOF
29749#define RECV_TYPE_ARG3 $3
29750_ACEOF
29751
29752
29753cat >>confdefs.h <<_ACEOF
29754#define RECV_TYPE_ARG4 $4
29755_ACEOF
29756
29757
29758cat >>confdefs.h <<_ACEOF
29759#define RECV_TYPE_RETV $5
29760_ACEOF
29761
29762 #
29763
29764cat >>confdefs.h <<_ACEOF
29765#define HAVE_RECV 1
29766_ACEOF
29767
29768 curl_cv_func_recv="yes"
29769 fi
29770 else
29771 as_fn_error $? "Unable to link function recv" "$LINENO" 5
29772 fi
29773
29774
29775 for ac_header in sys/types.h sys/socket.h
29776do :
29777 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
29778ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
29779if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
29780 cat >>confdefs.h <<_ACEOF
29781#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
29782_ACEOF
29783
29784fi
29785
29786done
29787
29788 #
29789 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for send" >&5
29790$as_echo_n "checking for send... " >&6; }
29791 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29792/* end confdefs.h. */
29793
29794
29795#undef inline
29796#ifdef HAVE_WINDOWS_H
29797#ifndef WIN32_LEAN_AND_MEAN
29798#define WIN32_LEAN_AND_MEAN
29799#endif
29800#include <windows.h>
29801#ifdef HAVE_WINSOCK2_H
29802#include <winsock2.h>
29803#else
29804#ifdef HAVE_WINSOCK_H
29805#include <winsock.h>
29806#endif
29807#endif
29808#else
Haibo Huang65021c72019-03-27 15:37:23 -070029809#ifdef HAVE_PROTO_BSDSOCKET_H
29810#include <proto/bsdsocket.h>
29811struct Library *SocketBase = NULL;
29812#endif
Elliott Hughes82be86d2017-09-20 17:00:17 -070029813#ifdef HAVE_SYS_TYPES_H
29814#include <sys/types.h>
29815#endif
29816#ifdef HAVE_SYS_SOCKET_H
29817#include <sys/socket.h>
29818#endif
29819#endif
29820
29821int main (void)
29822{
29823
29824 send(0, 0, 0, 0);
29825
29826 ;
29827 return 0;
29828}
29829
29830_ACEOF
29831if ac_fn_c_try_link "$LINENO"; then :
29832
29833 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
29834$as_echo "yes" >&6; }
29835 curl_cv_send="yes"
29836
29837else
29838
29839 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29840$as_echo "no" >&6; }
29841 curl_cv_send="no"
29842
29843fi
29844rm -f core conftest.err conftest.$ac_objext \
29845 conftest$ac_exeext conftest.$ac_ext
29846 #
29847 if test "$curl_cv_send" = "yes"; then
29848 { $as_echo "$as_me:${as_lineno-$LINENO}: checking types of args and return type for send" >&5
29849$as_echo_n "checking types of args and return type for send... " >&6; }
29850if ${curl_cv_func_send_args+:} false; then :
29851 $as_echo_n "(cached) " >&6
29852else
29853
29854 curl_cv_func_send_args="unknown"
29855 for send_retv in 'int' 'ssize_t'; do
29856 for send_arg1 in 'int' 'ssize_t' 'SOCKET'; do
29857 for send_arg2 in 'char *' 'void *' 'const char *' 'const void *'; do
29858 for send_arg3 in 'size_t' 'int' 'socklen_t' 'unsigned int'; do
29859 for send_arg4 in 'int' 'unsigned int'; do
29860 if test "$curl_cv_func_send_args" = "unknown"; then
29861 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29862/* end confdefs.h. */
29863
29864
29865#undef inline
29866#ifdef HAVE_WINDOWS_H
29867#ifndef WIN32_LEAN_AND_MEAN
29868#define WIN32_LEAN_AND_MEAN
29869#endif
29870#include <windows.h>
29871#ifdef HAVE_WINSOCK2_H
29872#include <winsock2.h>
29873#else
29874#ifdef HAVE_WINSOCK_H
29875#include <winsock.h>
29876#endif
29877#endif
29878#define SENDCALLCONV PASCAL
29879#else
Haibo Huang65021c72019-03-27 15:37:23 -070029880#ifdef HAVE_PROTO_BSDSOCKET_H
29881#include <proto/bsdsocket.h>
29882struct Library *SocketBase = NULL;
29883#endif
Elliott Hughes82be86d2017-09-20 17:00:17 -070029884#ifdef HAVE_SYS_TYPES_H
29885#include <sys/types.h>
29886#endif
29887#ifdef HAVE_SYS_SOCKET_H
29888#include <sys/socket.h>
29889#endif
29890#define SENDCALLCONV
29891#endif
Haibo Huang65021c72019-03-27 15:37:23 -070029892#ifndef HAVE_PROTO_BSDSOCKET_H
Elliott Hughes82be86d2017-09-20 17:00:17 -070029893 extern $send_retv SENDCALLCONV
Elliott Hughes82be86d2017-09-20 17:00:17 -070029894 send($send_arg1, $send_arg2, $send_arg3, $send_arg4);
Haibo Huang65021c72019-03-27 15:37:23 -070029895#endif
Elliott Hughes82be86d2017-09-20 17:00:17 -070029896
29897int main (void)
29898{
29899
29900 $send_arg1 s=0;
29901 $send_arg3 len=0;
29902 $send_arg4 flags=0;
29903 $send_retv res = send(s, 0, len, flags);
29904
29905 ;
29906 return 0;
29907}
29908
29909_ACEOF
29910if ac_fn_c_try_compile "$LINENO"; then :
29911
29912 curl_cv_func_send_args="$send_arg1,$send_arg2,$send_arg3,$send_arg4,$send_retv"
29913
29914fi
29915rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29916 fi
29917 done
29918 done
29919 done
29920 done
29921 done
29922
29923fi
29924{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_func_send_args" >&5
29925$as_echo "$curl_cv_func_send_args" >&6; } # AC-CACHE-CHECK
29926 if test "$curl_cv_func_send_args" = "unknown"; then
29927 as_fn_error $? "Cannot find proper types to use for send args" "$LINENO" 5
29928 else
29929 send_prev_IFS=$IFS; IFS=','
29930 set dummy `echo "$curl_cv_func_send_args" | sed 's/\*/\*/g'`
29931 IFS=$send_prev_IFS
29932 shift
29933 #
29934 send_qual_type_arg2=$2
29935 #
29936
29937cat >>confdefs.h <<_ACEOF
29938#define SEND_TYPE_ARG1 $1
29939_ACEOF
29940
29941
29942cat >>confdefs.h <<_ACEOF
29943#define SEND_TYPE_ARG3 $3
29944_ACEOF
29945
29946
29947cat >>confdefs.h <<_ACEOF
29948#define SEND_TYPE_ARG4 $4
29949_ACEOF
29950
29951
29952cat >>confdefs.h <<_ACEOF
29953#define SEND_TYPE_RETV $5
29954_ACEOF
29955
29956 #
29957 prev_sh_opts=$-
29958 #
29959 case $prev_sh_opts in
29960 *f*)
29961 ;;
29962 *)
29963 set -f
29964 ;;
29965 esac
29966 #
29967 case "$send_qual_type_arg2" in
29968 const*)
29969 send_qual_arg2=const
29970 send_type_arg2=`echo $send_qual_type_arg2 | sed 's/^const //'`
29971 ;;
29972 *)
29973 send_qual_arg2=
29974 send_type_arg2=$send_qual_type_arg2
29975 ;;
29976 esac
29977 #
29978
29979cat >>confdefs.h <<_ACEOF
29980#define SEND_QUAL_ARG2 $send_qual_arg2
29981_ACEOF
29982
29983
29984cat >>confdefs.h <<_ACEOF
29985#define SEND_TYPE_ARG2 $send_type_arg2
29986_ACEOF
29987
29988 #
29989 case $prev_sh_opts in
29990 *f*)
29991 ;;
29992 *)
29993 set +f
29994 ;;
29995 esac
29996 #
29997
29998cat >>confdefs.h <<_ACEOF
29999#define HAVE_SEND 1
30000_ACEOF
30001
30002 curl_cv_func_send="yes"
30003 fi
30004 else
30005 as_fn_error $? "Unable to link function send" "$LINENO" 5
30006 fi
30007
30008
30009 for ac_header in sys/types.h sys/socket.h
30010do :
30011 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
30012ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
30013if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
30014 cat >>confdefs.h <<_ACEOF
30015#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
30016_ACEOF
30017
30018fi
30019
30020done
30021
30022 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MSG_NOSIGNAL" >&5
30023$as_echo_n "checking for MSG_NOSIGNAL... " >&6; }
30024if ${curl_cv_msg_nosignal+:} false; then :
30025 $as_echo_n "(cached) " >&6
30026else
30027
30028 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30029/* end confdefs.h. */
30030
30031
30032#undef inline
30033#ifdef HAVE_WINDOWS_H
30034#ifndef WIN32_LEAN_AND_MEAN
30035#define WIN32_LEAN_AND_MEAN
30036#endif
30037#include <windows.h>
30038#ifdef HAVE_WINSOCK2_H
30039#include <winsock2.h>
30040#else
30041#ifdef HAVE_WINSOCK_H
30042#include <winsock.h>
30043#endif
30044#endif
30045#else
Haibo Huang65021c72019-03-27 15:37:23 -070030046#ifdef HAVE_PROTO_BSDSOCKET_H
30047#include <proto/bsdsocket.h>
30048struct Library *SocketBase = NULL;
30049#endif
Elliott Hughes82be86d2017-09-20 17:00:17 -070030050#ifdef HAVE_SYS_TYPES_H
30051#include <sys/types.h>
30052#endif
30053#ifdef HAVE_SYS_SOCKET_H
30054#include <sys/socket.h>
30055#endif
30056#endif
30057
30058int main (void)
30059{
30060
30061 int flag=MSG_NOSIGNAL;
30062
30063 ;
30064 return 0;
30065}
30066
30067_ACEOF
30068if ac_fn_c_try_compile "$LINENO"; then :
30069
30070 curl_cv_msg_nosignal="yes"
30071
30072else
30073
30074 curl_cv_msg_nosignal="no"
30075
30076fi
30077rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30078
30079fi
30080{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_msg_nosignal" >&5
30081$as_echo "$curl_cv_msg_nosignal" >&6; }
30082 case "$curl_cv_msg_nosignal" in
30083 yes)
30084
30085cat >>confdefs.h <<_ACEOF
30086#define HAVE_MSG_NOSIGNAL 1
30087_ACEOF
30088
30089 ;;
30090 esac
30091
30092
30093
30094curl_includes_unistd="\
30095/* includes start */
30096#ifdef HAVE_SYS_TYPES_H
30097# include <sys/types.h>
30098#endif
30099#ifdef HAVE_UNISTD_H
30100# include <unistd.h>
30101#endif
30102/* includes end */"
30103 for ac_header in sys/types.h unistd.h
30104do :
30105 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
30106ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_unistd
30107"
30108if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
30109 cat >>confdefs.h <<_ACEOF
30110#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
30111_ACEOF
30112
30113fi
30114
30115done
30116
30117
30118
30119 #
30120 tst_links_alarm="unknown"
30121 tst_proto_alarm="unknown"
30122 tst_compi_alarm="unknown"
30123 tst_allow_alarm="unknown"
30124 #
30125 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if alarm can be linked" >&5
30126$as_echo_n "checking if alarm can be linked... " >&6; }
30127 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30128/* end confdefs.h. */
30129
30130
30131#define alarm innocuous_alarm
30132#ifdef __STDC__
30133# include <limits.h>
30134#else
30135# include <assert.h>
30136#endif
30137#undef alarm
30138#ifdef __cplusplus
30139extern "C"
30140#endif
30141char alarm ();
30142#if defined __stub_alarm || defined __stub___alarm
30143choke me
30144#endif
30145
30146int main (void)
30147{
30148return alarm ();
30149 ;
30150 return 0;
30151}
30152
30153_ACEOF
30154if ac_fn_c_try_link "$LINENO"; then :
30155
30156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30157$as_echo "yes" >&6; }
30158 tst_links_alarm="yes"
30159
30160else
30161
30162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30163$as_echo "no" >&6; }
30164 tst_links_alarm="no"
30165
30166fi
30167rm -f core conftest.err conftest.$ac_objext \
30168 conftest$ac_exeext conftest.$ac_ext
30169 #
30170 if test "$tst_links_alarm" = "yes"; then
30171 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if alarm is prototyped" >&5
30172$as_echo_n "checking if alarm is prototyped... " >&6; }
30173 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30174/* end confdefs.h. */
30175
30176 $curl_includes_unistd
30177
30178_ACEOF
30179if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
30180 $EGREP "alarm" >/dev/null 2>&1; then :
30181
30182 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30183$as_echo "yes" >&6; }
30184 tst_proto_alarm="yes"
30185
30186else
30187
30188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30189$as_echo "no" >&6; }
30190 tst_proto_alarm="no"
30191
30192fi
30193rm -f conftest*
30194
30195 fi
30196 #
30197 if test "$tst_proto_alarm" = "yes"; then
30198 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if alarm is compilable" >&5
30199$as_echo_n "checking if alarm is compilable... " >&6; }
30200 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30201/* end confdefs.h. */
30202
30203
30204 $curl_includes_unistd
30205
30206int main (void)
30207{
30208
30209 if(0 != alarm(0))
30210 return 1;
30211
30212 ;
30213 return 0;
30214}
30215
30216_ACEOF
30217if ac_fn_c_try_compile "$LINENO"; then :
30218
30219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30220$as_echo "yes" >&6; }
30221 tst_compi_alarm="yes"
30222
30223else
30224
30225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30226$as_echo "no" >&6; }
30227 tst_compi_alarm="no"
30228
30229fi
30230rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30231 fi
30232 #
30233 if test "$tst_compi_alarm" = "yes"; then
30234 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if alarm usage allowed" >&5
30235$as_echo_n "checking if alarm usage allowed... " >&6; }
30236 if test "x$curl_disallow_alarm" != "xyes"; then
30237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30238$as_echo "yes" >&6; }
30239 tst_allow_alarm="yes"
30240 else
30241 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30242$as_echo "no" >&6; }
30243 tst_allow_alarm="no"
30244 fi
30245 fi
30246 #
30247 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if alarm might be used" >&5
30248$as_echo_n "checking if alarm might be used... " >&6; }
30249 if test "$tst_links_alarm" = "yes" &&
30250 test "$tst_proto_alarm" = "yes" &&
30251 test "$tst_compi_alarm" = "yes" &&
30252 test "$tst_allow_alarm" = "yes"; then
30253 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30254$as_echo "yes" >&6; }
30255
30256cat >>confdefs.h <<_ACEOF
30257#define HAVE_ALARM 1
30258_ACEOF
30259
30260 curl_cv_func_alarm="yes"
30261 else
30262 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30263$as_echo "no" >&6; }
30264 curl_cv_func_alarm="no"
30265 fi
30266
30267
30268curl_includes_string="\
30269/* includes start */
30270#ifdef HAVE_SYS_TYPES_H
30271# include <sys/types.h>
30272#endif
30273#ifdef HAVE_STRING_H
30274# include <string.h>
30275#endif
30276#ifdef HAVE_STRINGS_H
30277# include <strings.h>
30278#endif
30279/* includes end */"
30280 for ac_header in sys/types.h string.h strings.h
30281do :
30282 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
30283ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_string
30284"
30285if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
30286 cat >>confdefs.h <<_ACEOF
30287#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
30288_ACEOF
30289
30290fi
30291
30292done
30293
30294
30295
30296curl_includes_libgen="\
30297/* includes start */
30298#ifdef HAVE_SYS_TYPES_H
30299# include <sys/types.h>
30300#endif
30301#ifdef HAVE_LIBGEN_H
30302# include <libgen.h>
30303#endif
30304/* includes end */"
30305 for ac_header in sys/types.h libgen.h
30306do :
30307 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
30308ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_libgen
30309"
30310if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
30311 cat >>confdefs.h <<_ACEOF
30312#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
30313_ACEOF
30314
30315fi
30316
30317done
30318
30319
30320
30321 #
30322 tst_links_basename="unknown"
30323 tst_proto_basename="unknown"
30324 tst_compi_basename="unknown"
30325 tst_allow_basename="unknown"
30326 #
30327 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if basename can be linked" >&5
30328$as_echo_n "checking if basename can be linked... " >&6; }
30329 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30330/* end confdefs.h. */
30331
30332
30333#define basename innocuous_basename
30334#ifdef __STDC__
30335# include <limits.h>
30336#else
30337# include <assert.h>
30338#endif
30339#undef basename
30340#ifdef __cplusplus
30341extern "C"
30342#endif
30343char basename ();
30344#if defined __stub_basename || defined __stub___basename
30345choke me
30346#endif
30347
30348int main (void)
30349{
30350return basename ();
30351 ;
30352 return 0;
30353}
30354
30355_ACEOF
30356if ac_fn_c_try_link "$LINENO"; then :
30357
30358 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30359$as_echo "yes" >&6; }
30360 tst_links_basename="yes"
30361
30362else
30363
30364 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30365$as_echo "no" >&6; }
30366 tst_links_basename="no"
30367
30368fi
30369rm -f core conftest.err conftest.$ac_objext \
30370 conftest$ac_exeext conftest.$ac_ext
30371 #
30372 if test "$tst_links_basename" = "yes"; then
30373 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if basename is prototyped" >&5
30374$as_echo_n "checking if basename is prototyped... " >&6; }
30375 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30376/* end confdefs.h. */
30377
30378 $curl_includes_string
30379 $curl_includes_libgen
30380 $curl_includes_unistd
30381
30382_ACEOF
30383if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
30384 $EGREP "basename" >/dev/null 2>&1; then :
30385
30386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30387$as_echo "yes" >&6; }
30388 tst_proto_basename="yes"
30389
30390else
30391
30392 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30393$as_echo "no" >&6; }
30394 tst_proto_basename="no"
30395
30396fi
30397rm -f conftest*
30398
30399 fi
30400 #
30401 if test "$tst_proto_basename" = "yes"; then
30402 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if basename is compilable" >&5
30403$as_echo_n "checking if basename is compilable... " >&6; }
30404 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30405/* end confdefs.h. */
30406
30407
30408 $curl_includes_string
30409 $curl_includes_libgen
30410 $curl_includes_unistd
30411
30412int main (void)
30413{
30414
30415 if(0 != basename(0))
30416 return 1;
30417
30418 ;
30419 return 0;
30420}
30421
30422_ACEOF
30423if ac_fn_c_try_compile "$LINENO"; then :
30424
30425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30426$as_echo "yes" >&6; }
30427 tst_compi_basename="yes"
30428
30429else
30430
30431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30432$as_echo "no" >&6; }
30433 tst_compi_basename="no"
30434
30435fi
30436rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30437 fi
30438 #
30439 if test "$tst_compi_basename" = "yes"; then
30440 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if basename usage allowed" >&5
30441$as_echo_n "checking if basename usage allowed... " >&6; }
30442 if test "x$curl_disallow_basename" != "xyes"; then
30443 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30444$as_echo "yes" >&6; }
30445 tst_allow_basename="yes"
30446 else
30447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30448$as_echo "no" >&6; }
30449 tst_allow_basename="no"
30450 fi
30451 fi
30452 #
30453 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if basename might be used" >&5
30454$as_echo_n "checking if basename might be used... " >&6; }
30455 if test "$tst_links_basename" = "yes" &&
30456 test "$tst_proto_basename" = "yes" &&
30457 test "$tst_compi_basename" = "yes" &&
30458 test "$tst_allow_basename" = "yes"; then
30459 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30460$as_echo "yes" >&6; }
30461
30462cat >>confdefs.h <<_ACEOF
30463#define HAVE_BASENAME 1
30464_ACEOF
30465
30466 curl_cv_func_basename="yes"
30467 else
30468 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30469$as_echo "no" >&6; }
30470 curl_cv_func_basename="no"
30471 fi
30472
30473
30474curl_includes_socket="\
30475/* includes start */
30476#ifdef HAVE_SYS_TYPES_H
30477# include <sys/types.h>
30478#endif
30479#ifdef HAVE_SOCKET_H
30480# include <socket.h>
30481#endif
30482/* includes end */"
30483 for ac_header in sys/types.h socket.h
30484do :
30485 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
30486ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_socket
30487"
30488if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
30489 cat >>confdefs.h <<_ACEOF
30490#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
30491_ACEOF
30492
30493fi
30494
30495done
30496
30497
30498
30499 #
30500 tst_links_closesocket="unknown"
30501 tst_proto_closesocket="unknown"
30502 tst_compi_closesocket="unknown"
30503 tst_allow_closesocket="unknown"
30504 #
30505 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if closesocket can be linked" >&5
30506$as_echo_n "checking if closesocket can be linked... " >&6; }
30507 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30508/* end confdefs.h. */
30509
30510
30511 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070030512 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070030513 $curl_includes_socket
30514
30515int main (void)
30516{
30517
30518 if(0 != closesocket(0))
30519 return 1;
30520
30521 ;
30522 return 0;
30523}
30524
30525_ACEOF
30526if ac_fn_c_try_link "$LINENO"; then :
30527
30528 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30529$as_echo "yes" >&6; }
30530 tst_links_closesocket="yes"
30531
30532else
30533
30534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30535$as_echo "no" >&6; }
30536 tst_links_closesocket="no"
30537
30538fi
30539rm -f core conftest.err conftest.$ac_objext \
30540 conftest$ac_exeext conftest.$ac_ext
30541 #
30542 if test "$tst_links_closesocket" = "yes"; then
30543 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if closesocket is prototyped" >&5
30544$as_echo_n "checking if closesocket is prototyped... " >&6; }
30545 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30546/* end confdefs.h. */
30547
30548 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070030549 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070030550 $curl_includes_socket
30551
30552_ACEOF
30553if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
30554 $EGREP "closesocket" >/dev/null 2>&1; then :
30555
30556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30557$as_echo "yes" >&6; }
30558 tst_proto_closesocket="yes"
30559
30560else
30561
30562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30563$as_echo "no" >&6; }
30564 tst_proto_closesocket="no"
30565
30566fi
30567rm -f conftest*
30568
30569 fi
30570 #
30571 if test "$tst_proto_closesocket" = "yes"; then
30572 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if closesocket is compilable" >&5
30573$as_echo_n "checking if closesocket is compilable... " >&6; }
30574 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30575/* end confdefs.h. */
30576
30577
30578 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070030579 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070030580 $curl_includes_socket
30581
30582int main (void)
30583{
30584
30585 if(0 != closesocket(0))
30586 return 1;
30587
30588 ;
30589 return 0;
30590}
30591
30592_ACEOF
30593if ac_fn_c_try_compile "$LINENO"; then :
30594
30595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30596$as_echo "yes" >&6; }
30597 tst_compi_closesocket="yes"
30598
30599else
30600
30601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30602$as_echo "no" >&6; }
30603 tst_compi_closesocket="no"
30604
30605fi
30606rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30607 fi
30608 #
30609 if test "$tst_compi_closesocket" = "yes"; then
30610 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if closesocket usage allowed" >&5
30611$as_echo_n "checking if closesocket usage allowed... " >&6; }
30612 if test "x$curl_disallow_closesocket" != "xyes"; then
30613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30614$as_echo "yes" >&6; }
30615 tst_allow_closesocket="yes"
30616 else
30617 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30618$as_echo "no" >&6; }
30619 tst_allow_closesocket="no"
30620 fi
30621 fi
30622 #
30623 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if closesocket might be used" >&5
30624$as_echo_n "checking if closesocket might be used... " >&6; }
30625 if test "$tst_links_closesocket" = "yes" &&
30626 test "$tst_proto_closesocket" = "yes" &&
30627 test "$tst_compi_closesocket" = "yes" &&
30628 test "$tst_allow_closesocket" = "yes"; then
30629 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30630$as_echo "yes" >&6; }
30631
30632cat >>confdefs.h <<_ACEOF
30633#define HAVE_CLOSESOCKET 1
30634_ACEOF
30635
30636 curl_cv_func_closesocket="yes"
30637 else
30638 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30639$as_echo "no" >&6; }
30640 curl_cv_func_closesocket="no"
30641 fi
30642
30643
Elliott Hughesa93fb052018-12-12 14:22:48 -080030644curl_includes_sys_socket="\
30645/* includes start */
30646#ifdef HAVE_SYS_TYPES_H
30647# include <sys/types.h>
30648#endif
30649#ifdef HAVE_SYS_SOCKET_H
30650# include <sys/socket.h>
30651#endif
30652/* includes end */"
30653 for ac_header in sys/types.h sys/socket.h
30654do :
30655 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
30656ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_sys_socket
30657"
30658if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
30659 cat >>confdefs.h <<_ACEOF
30660#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
30661_ACEOF
30662
30663fi
30664
30665done
30666
30667
30668
Elliott Hughes82be86d2017-09-20 17:00:17 -070030669 #
30670 tst_links_closesocket_camel="unknown"
30671 tst_proto_closesocket_camel="unknown"
30672 tst_compi_closesocket_camel="unknown"
30673 tst_allow_closesocket_camel="unknown"
30674 #
30675 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if CloseSocket can be linked" >&5
30676$as_echo_n "checking if CloseSocket can be linked... " >&6; }
30677 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30678/* end confdefs.h. */
30679
30680
30681 $curl_includes_sys_socket
30682
30683int main (void)
30684{
30685
30686 if(0 != CloseSocket(0))
30687 return 1;
30688
30689 ;
30690 return 0;
30691}
30692
30693_ACEOF
30694if ac_fn_c_try_link "$LINENO"; then :
30695
30696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30697$as_echo "yes" >&6; }
30698 tst_links_closesocket_camel="yes"
30699
30700else
30701
30702 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30703$as_echo "no" >&6; }
30704 tst_links_closesocket_camel="no"
30705
30706fi
30707rm -f core conftest.err conftest.$ac_objext \
30708 conftest$ac_exeext conftest.$ac_ext
30709 #
30710 if test "$tst_links_closesocket_camel" = "yes"; then
30711 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if CloseSocket is prototyped" >&5
30712$as_echo_n "checking if CloseSocket is prototyped... " >&6; }
30713 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30714/* end confdefs.h. */
30715
30716 $curl_includes_sys_socket
30717
30718_ACEOF
30719if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
30720 $EGREP "CloseSocket" >/dev/null 2>&1; then :
30721
30722 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30723$as_echo "yes" >&6; }
30724 tst_proto_closesocket_camel="yes"
30725
30726else
30727
30728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30729$as_echo "no" >&6; }
30730 tst_proto_closesocket_camel="no"
30731
30732fi
30733rm -f conftest*
30734
30735 fi
30736 #
30737 if test "$tst_proto_closesocket_camel" = "yes"; then
30738 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if CloseSocket is compilable" >&5
30739$as_echo_n "checking if CloseSocket is compilable... " >&6; }
30740 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30741/* end confdefs.h. */
30742
30743
30744 $curl_includes_sys_socket
30745
30746int main (void)
30747{
30748
30749 if(0 != CloseSocket(0))
30750 return 1;
30751
30752 ;
30753 return 0;
30754}
30755
30756_ACEOF
30757if ac_fn_c_try_compile "$LINENO"; then :
30758
30759 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30760$as_echo "yes" >&6; }
30761 tst_compi_closesocket_camel="yes"
30762
30763else
30764
30765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30766$as_echo "no" >&6; }
30767 tst_compi_closesocket_camel="no"
30768
30769fi
30770rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30771 fi
30772 #
30773 if test "$tst_compi_closesocket_camel" = "yes"; then
30774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if CloseSocket usage allowed" >&5
30775$as_echo_n "checking if CloseSocket usage allowed... " >&6; }
30776 if test "x$curl_disallow_closesocket_camel" != "xyes"; then
30777 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30778$as_echo "yes" >&6; }
30779 tst_allow_closesocket_camel="yes"
30780 else
30781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30782$as_echo "no" >&6; }
30783 tst_allow_closesocket_camel="no"
30784 fi
30785 fi
30786 #
30787 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if CloseSocket might be used" >&5
30788$as_echo_n "checking if CloseSocket might be used... " >&6; }
30789 if test "$tst_links_closesocket_camel" = "yes" &&
30790 test "$tst_proto_closesocket_camel" = "yes" &&
30791 test "$tst_compi_closesocket_camel" = "yes" &&
30792 test "$tst_allow_closesocket_camel" = "yes"; then
30793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30794$as_echo "yes" >&6; }
30795
30796cat >>confdefs.h <<_ACEOF
30797#define HAVE_CLOSESOCKET_CAMEL 1
30798_ACEOF
30799
30800 curl_cv_func_closesocket_camel="yes"
30801 else
30802 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30803$as_echo "no" >&6; }
30804 curl_cv_func_closesocket_camel="no"
30805 fi
30806
30807
30808 #
30809 tst_links_connect="unknown"
30810 tst_proto_connect="unknown"
30811 tst_compi_connect="unknown"
30812 tst_allow_connect="unknown"
30813 #
30814 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if connect can be linked" >&5
30815$as_echo_n "checking if connect can be linked... " >&6; }
30816 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30817/* end confdefs.h. */
30818
30819
30820 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070030821 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070030822 $curl_includes_sys_socket
30823 $curl_includes_socket
30824
30825int main (void)
30826{
30827
30828 if(0 != connect(0, 0, 0))
30829 return 1;
30830
30831 ;
30832 return 0;
30833}
30834
30835_ACEOF
30836if ac_fn_c_try_link "$LINENO"; then :
30837
30838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30839$as_echo "yes" >&6; }
30840 tst_links_connect="yes"
30841
30842else
30843
30844 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30845$as_echo "no" >&6; }
30846 tst_links_connect="no"
30847
30848fi
30849rm -f core conftest.err conftest.$ac_objext \
30850 conftest$ac_exeext conftest.$ac_ext
30851 #
30852 if test "$tst_links_connect" = "yes"; then
30853 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if connect is prototyped" >&5
30854$as_echo_n "checking if connect is prototyped... " >&6; }
30855 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30856/* end confdefs.h. */
30857
30858 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070030859 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070030860 $curl_includes_sys_socket
30861 $curl_includes_socket
30862
30863_ACEOF
30864if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
30865 $EGREP "connect" >/dev/null 2>&1; then :
30866
30867 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30868$as_echo "yes" >&6; }
30869 tst_proto_connect="yes"
30870
30871else
30872
30873 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30874$as_echo "no" >&6; }
30875 tst_proto_connect="no"
30876
30877fi
30878rm -f conftest*
30879
30880 fi
30881 #
30882 if test "$tst_proto_connect" = "yes"; then
30883 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if connect is compilable" >&5
30884$as_echo_n "checking if connect is compilable... " >&6; }
30885 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30886/* end confdefs.h. */
30887
30888
30889 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070030890 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070030891 $curl_includes_sys_socket
30892 $curl_includes_socket
30893
30894int main (void)
30895{
30896
30897 if(0 != connect(0, 0, 0))
30898 return 1;
30899
30900 ;
30901 return 0;
30902}
30903
30904_ACEOF
30905if ac_fn_c_try_compile "$LINENO"; then :
30906
30907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30908$as_echo "yes" >&6; }
30909 tst_compi_connect="yes"
30910
30911else
30912
30913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30914$as_echo "no" >&6; }
30915 tst_compi_connect="no"
30916
30917fi
30918rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30919 fi
30920 #
30921 if test "$tst_compi_connect" = "yes"; then
30922 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if connect usage allowed" >&5
30923$as_echo_n "checking if connect usage allowed... " >&6; }
30924 if test "x$curl_disallow_connect" != "xyes"; then
30925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30926$as_echo "yes" >&6; }
30927 tst_allow_connect="yes"
30928 else
30929 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30930$as_echo "no" >&6; }
30931 tst_allow_connect="no"
30932 fi
30933 fi
30934 #
30935 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if connect might be used" >&5
30936$as_echo_n "checking if connect might be used... " >&6; }
30937 if test "$tst_links_connect" = "yes" &&
30938 test "$tst_proto_connect" = "yes" &&
30939 test "$tst_compi_connect" = "yes" &&
30940 test "$tst_allow_connect" = "yes"; then
30941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
30942$as_echo "yes" >&6; }
30943
30944cat >>confdefs.h <<_ACEOF
30945#define HAVE_CONNECT 1
30946_ACEOF
30947
30948 curl_cv_func_connect="yes"
30949 else
30950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30951$as_echo "no" >&6; }
30952 curl_cv_func_connect="no"
30953 fi
30954
30955
30956curl_includes_fcntl="\
30957/* includes start */
30958#ifdef HAVE_SYS_TYPES_H
30959# include <sys/types.h>
30960#endif
30961#ifdef HAVE_UNISTD_H
30962# include <unistd.h>
30963#endif
30964#ifdef HAVE_FCNTL_H
30965# include <fcntl.h>
30966#endif
30967/* includes end */"
30968 for ac_header in sys/types.h unistd.h fcntl.h
30969do :
30970 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
30971ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_fcntl
30972"
30973if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
30974 cat >>confdefs.h <<_ACEOF
30975#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
30976_ACEOF
30977
30978fi
30979
30980done
30981
30982
30983
30984 #
30985 tst_links_fcntl="unknown"
30986 tst_proto_fcntl="unknown"
30987 tst_compi_fcntl="unknown"
30988 tst_allow_fcntl="unknown"
30989 #
30990 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fcntl can be linked" >&5
30991$as_echo_n "checking if fcntl can be linked... " >&6; }
30992 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30993/* end confdefs.h. */
30994
30995
30996#define fcntl innocuous_fcntl
30997#ifdef __STDC__
30998# include <limits.h>
30999#else
31000# include <assert.h>
31001#endif
31002#undef fcntl
31003#ifdef __cplusplus
31004extern "C"
31005#endif
31006char fcntl ();
31007#if defined __stub_fcntl || defined __stub___fcntl
31008choke me
31009#endif
31010
31011int main (void)
31012{
31013return fcntl ();
31014 ;
31015 return 0;
31016}
31017
31018_ACEOF
31019if ac_fn_c_try_link "$LINENO"; then :
31020
31021 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31022$as_echo "yes" >&6; }
31023 tst_links_fcntl="yes"
31024
31025else
31026
31027 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31028$as_echo "no" >&6; }
31029 tst_links_fcntl="no"
31030
31031fi
31032rm -f core conftest.err conftest.$ac_objext \
31033 conftest$ac_exeext conftest.$ac_ext
31034 #
31035 if test "$tst_links_fcntl" = "yes"; then
31036 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fcntl is prototyped" >&5
31037$as_echo_n "checking if fcntl is prototyped... " >&6; }
31038 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31039/* end confdefs.h. */
31040
31041 $curl_includes_fcntl
31042
31043_ACEOF
31044if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
31045 $EGREP "fcntl" >/dev/null 2>&1; then :
31046
31047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31048$as_echo "yes" >&6; }
31049 tst_proto_fcntl="yes"
31050
31051else
31052
31053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31054$as_echo "no" >&6; }
31055 tst_proto_fcntl="no"
31056
31057fi
31058rm -f conftest*
31059
31060 fi
31061 #
31062 if test "$tst_proto_fcntl" = "yes"; then
31063 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fcntl is compilable" >&5
31064$as_echo_n "checking if fcntl is compilable... " >&6; }
31065 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31066/* end confdefs.h. */
31067
31068
31069 $curl_includes_fcntl
31070
31071int main (void)
31072{
31073
31074 if(0 != fcntl(0, 0, 0))
31075 return 1;
31076
31077 ;
31078 return 0;
31079}
31080
31081_ACEOF
31082if ac_fn_c_try_compile "$LINENO"; then :
31083
31084 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31085$as_echo "yes" >&6; }
31086 tst_compi_fcntl="yes"
31087
31088else
31089
31090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31091$as_echo "no" >&6; }
31092 tst_compi_fcntl="no"
31093
31094fi
31095rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31096 fi
31097 #
31098 if test "$tst_compi_fcntl" = "yes"; then
31099 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fcntl usage allowed" >&5
31100$as_echo_n "checking if fcntl usage allowed... " >&6; }
31101 if test "x$curl_disallow_fcntl" != "xyes"; then
31102 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31103$as_echo "yes" >&6; }
31104 tst_allow_fcntl="yes"
31105 else
31106 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31107$as_echo "no" >&6; }
31108 tst_allow_fcntl="no"
31109 fi
31110 fi
31111 #
31112 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fcntl might be used" >&5
31113$as_echo_n "checking if fcntl might be used... " >&6; }
31114 if test "$tst_links_fcntl" = "yes" &&
31115 test "$tst_proto_fcntl" = "yes" &&
31116 test "$tst_compi_fcntl" = "yes" &&
31117 test "$tst_allow_fcntl" = "yes"; then
31118 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31119$as_echo "yes" >&6; }
31120
31121cat >>confdefs.h <<_ACEOF
31122#define HAVE_FCNTL 1
31123_ACEOF
31124
31125 curl_cv_func_fcntl="yes"
31126
31127 #
31128 tst_compi_fcntl_o_nonblock="unknown"
31129 tst_allow_fcntl_o_nonblock="unknown"
31130 #
31131 case $host_os in
31132 sunos4* | aix3* | beos*)
31133 curl_disallow_fcntl_o_nonblock="yes"
31134 ;;
31135 esac
31136 #
31137 if test "$curl_cv_func_fcntl" = "yes"; then
31138 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fcntl O_NONBLOCK is compilable" >&5
31139$as_echo_n "checking if fcntl O_NONBLOCK is compilable... " >&6; }
31140 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31141/* end confdefs.h. */
31142
31143
31144 $curl_includes_fcntl
31145
31146int main (void)
31147{
31148
31149 int flags = 0;
31150 if(0 != fcntl(0, F_SETFL, flags | O_NONBLOCK))
31151 return 1;
31152
31153 ;
31154 return 0;
31155}
31156
31157_ACEOF
31158if ac_fn_c_try_compile "$LINENO"; then :
31159
31160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31161$as_echo "yes" >&6; }
31162 tst_compi_fcntl_o_nonblock="yes"
31163
31164else
31165
31166 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31167$as_echo "no" >&6; }
31168 tst_compi_fcntl_o_nonblock="no"
31169
31170fi
31171rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31172 fi
31173 #
31174 if test "$tst_compi_fcntl_o_nonblock" = "yes"; then
31175 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fcntl O_NONBLOCK usage allowed" >&5
31176$as_echo_n "checking if fcntl O_NONBLOCK usage allowed... " >&6; }
31177 if test "x$curl_disallow_fcntl_o_nonblock" != "xyes"; then
31178 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31179$as_echo "yes" >&6; }
31180 tst_allow_fcntl_o_nonblock="yes"
31181 else
31182 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31183$as_echo "no" >&6; }
31184 tst_allow_fcntl_o_nonblock="no"
31185 fi
31186 fi
31187 #
31188 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fcntl O_NONBLOCK might be used" >&5
31189$as_echo_n "checking if fcntl O_NONBLOCK might be used... " >&6; }
31190 if test "$tst_compi_fcntl_o_nonblock" = "yes" &&
31191 test "$tst_allow_fcntl_o_nonblock" = "yes"; then
31192 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31193$as_echo "yes" >&6; }
31194
31195cat >>confdefs.h <<_ACEOF
31196#define HAVE_FCNTL_O_NONBLOCK 1
31197_ACEOF
31198
31199 curl_cv_func_fcntl_o_nonblock="yes"
31200 else
31201 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31202$as_echo "no" >&6; }
31203 curl_cv_func_fcntl_o_nonblock="no"
31204 fi
31205
31206 else
31207 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31208$as_echo "no" >&6; }
31209 curl_cv_func_fcntl="no"
31210 fi
31211
31212
Elliott Hughesa93fb052018-12-12 14:22:48 -080031213curl_includes_ws2tcpip="\
31214/* includes start */
31215#ifdef HAVE_WINDOWS_H
31216# ifndef WIN32_LEAN_AND_MEAN
31217# define WIN32_LEAN_AND_MEAN
31218# endif
31219# include <windows.h>
31220# ifdef HAVE_WINSOCK2_H
31221# include <winsock2.h>
31222# ifdef HAVE_WS2TCPIP_H
31223# include <ws2tcpip.h>
31224# endif
31225# endif
31226#endif
31227/* includes end */"
31228
31229 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for windows.h" >&5
31230$as_echo_n "checking for windows.h... " >&6; }
31231if ${curl_cv_header_windows_h+:} false; then :
31232 $as_echo_n "(cached) " >&6
31233else
31234
31235 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31236/* end confdefs.h. */
31237
31238
31239#undef inline
31240#ifndef WIN32_LEAN_AND_MEAN
31241#define WIN32_LEAN_AND_MEAN
31242#endif
31243#include <windows.h>
31244
31245int main (void)
31246{
31247
31248#if defined(__CYGWIN__) || defined(__CEGCC__)
31249 HAVE_WINDOWS_H shall not be defined.
31250#else
31251 int dummy=2*WINVER;
31252#endif
31253
31254 ;
31255 return 0;
31256}
31257
31258_ACEOF
31259if ac_fn_c_try_compile "$LINENO"; then :
31260
31261 curl_cv_header_windows_h="yes"
31262
31263else
31264
31265 curl_cv_header_windows_h="no"
31266
31267fi
31268rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31269
31270fi
31271{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_windows_h" >&5
31272$as_echo "$curl_cv_header_windows_h" >&6; }
31273 case "$curl_cv_header_windows_h" in
31274 yes)
31275
31276cat >>confdefs.h <<_ACEOF
31277#define HAVE_WINDOWS_H 1
31278_ACEOF
31279
31280 ;;
31281 esac
31282
31283
31284 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for winsock2.h" >&5
31285$as_echo_n "checking for winsock2.h... " >&6; }
31286if ${curl_cv_header_winsock2_h+:} false; then :
31287 $as_echo_n "(cached) " >&6
31288else
31289
31290 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31291/* end confdefs.h. */
31292
31293
31294#undef inline
31295#ifndef WIN32_LEAN_AND_MEAN
31296#define WIN32_LEAN_AND_MEAN
31297#endif
31298#include <windows.h>
31299#include <winsock2.h>
31300
31301int main (void)
31302{
31303
31304#if defined(__CYGWIN__) || defined(__CEGCC__) || defined(__MINGW32CE__)
31305 HAVE_WINSOCK2_H shall not be defined.
31306#else
31307 int dummy=2*IPPROTO_ESP;
31308#endif
31309
31310 ;
31311 return 0;
31312}
31313
31314_ACEOF
31315if ac_fn_c_try_compile "$LINENO"; then :
31316
31317 curl_cv_header_winsock2_h="yes"
31318
31319else
31320
31321 curl_cv_header_winsock2_h="no"
31322
31323fi
31324rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31325
31326fi
31327{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_winsock2_h" >&5
31328$as_echo "$curl_cv_header_winsock2_h" >&6; }
31329 case "$curl_cv_header_winsock2_h" in
31330 yes)
31331
31332cat >>confdefs.h <<_ACEOF
31333#define HAVE_WINSOCK2_H 1
31334_ACEOF
31335
31336 ;;
31337 esac
31338
31339
31340 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ws2tcpip.h" >&5
31341$as_echo_n "checking for ws2tcpip.h... " >&6; }
31342if ${curl_cv_header_ws2tcpip_h+:} false; then :
31343 $as_echo_n "(cached) " >&6
31344else
31345
31346 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31347/* end confdefs.h. */
31348
31349
31350#undef inline
31351#ifndef WIN32_LEAN_AND_MEAN
31352#define WIN32_LEAN_AND_MEAN
31353#endif
31354#include <windows.h>
31355#include <winsock2.h>
31356#include <ws2tcpip.h>
31357
31358int main (void)
31359{
31360
31361#if defined(__CYGWIN__) || defined(__CEGCC__) || defined(__MINGW32CE__)
31362 HAVE_WS2TCPIP_H shall not be defined.
31363#else
31364 int dummy=2*IP_PKTINFO;
31365#endif
31366
31367 ;
31368 return 0;
31369}
31370
31371_ACEOF
31372if ac_fn_c_try_compile "$LINENO"; then :
31373
31374 curl_cv_header_ws2tcpip_h="yes"
31375
31376else
31377
31378 curl_cv_header_ws2tcpip_h="no"
31379
31380fi
31381rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31382
31383fi
31384{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_header_ws2tcpip_h" >&5
31385$as_echo "$curl_cv_header_ws2tcpip_h" >&6; }
31386 case "$curl_cv_header_ws2tcpip_h" in
31387 yes)
31388
31389cat >>confdefs.h <<_ACEOF
31390#define HAVE_WS2TCPIP_H 1
31391_ACEOF
31392
31393 ;;
31394 esac
31395
31396
31397
Elliott Hughes82be86d2017-09-20 17:00:17 -070031398curl_includes_netdb="\
31399/* includes start */
31400#ifdef HAVE_SYS_TYPES_H
31401# include <sys/types.h>
31402#endif
31403#ifdef HAVE_NETDB_H
31404# include <netdb.h>
31405#endif
31406/* includes end */"
31407 for ac_header in sys/types.h netdb.h
31408do :
31409 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
31410ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_netdb
31411"
31412if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
31413 cat >>confdefs.h <<_ACEOF
31414#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
31415_ACEOF
31416
31417fi
31418
31419done
31420
31421
31422
31423 #
31424 tst_links_freeaddrinfo="unknown"
31425 tst_proto_freeaddrinfo="unknown"
31426 tst_compi_freeaddrinfo="unknown"
31427 tst_allow_freeaddrinfo="unknown"
31428 #
31429 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if freeaddrinfo can be linked" >&5
31430$as_echo_n "checking if freeaddrinfo can be linked... " >&6; }
31431 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31432/* end confdefs.h. */
31433
31434
31435 $curl_includes_ws2tcpip
31436 $curl_includes_sys_socket
31437 $curl_includes_netdb
31438
31439int main (void)
31440{
31441
31442 freeaddrinfo(0);
31443
31444 ;
31445 return 0;
31446}
31447
31448_ACEOF
31449if ac_fn_c_try_link "$LINENO"; then :
31450
31451 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31452$as_echo "yes" >&6; }
31453 tst_links_freeaddrinfo="yes"
31454
31455else
31456
31457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31458$as_echo "no" >&6; }
31459 tst_links_freeaddrinfo="no"
31460
31461fi
31462rm -f core conftest.err conftest.$ac_objext \
31463 conftest$ac_exeext conftest.$ac_ext
31464 #
31465 if test "$tst_links_freeaddrinfo" = "yes"; then
31466 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if freeaddrinfo is prototyped" >&5
31467$as_echo_n "checking if freeaddrinfo is prototyped... " >&6; }
31468 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31469/* end confdefs.h. */
31470
31471 $curl_includes_ws2tcpip
31472 $curl_includes_sys_socket
31473 $curl_includes_netdb
31474
31475_ACEOF
31476if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
31477 $EGREP "freeaddrinfo" >/dev/null 2>&1; then :
31478
31479 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31480$as_echo "yes" >&6; }
31481 tst_proto_freeaddrinfo="yes"
31482
31483else
31484
31485 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31486$as_echo "no" >&6; }
31487 tst_proto_freeaddrinfo="no"
31488
31489fi
31490rm -f conftest*
31491
31492 fi
31493 #
31494 if test "$tst_proto_freeaddrinfo" = "yes"; then
31495 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if freeaddrinfo is compilable" >&5
31496$as_echo_n "checking if freeaddrinfo is compilable... " >&6; }
31497 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31498/* end confdefs.h. */
31499
31500
31501 $curl_includes_ws2tcpip
31502 $curl_includes_sys_socket
31503 $curl_includes_netdb
31504
31505int main (void)
31506{
31507
31508 freeaddrinfo(0);
31509
31510 ;
31511 return 0;
31512}
31513
31514_ACEOF
31515if ac_fn_c_try_compile "$LINENO"; then :
31516
31517 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31518$as_echo "yes" >&6; }
31519 tst_compi_freeaddrinfo="yes"
31520
31521else
31522
31523 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31524$as_echo "no" >&6; }
31525 tst_compi_freeaddrinfo="no"
31526
31527fi
31528rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31529 fi
31530 #
31531 if test "$tst_compi_freeaddrinfo" = "yes"; then
31532 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if freeaddrinfo usage allowed" >&5
31533$as_echo_n "checking if freeaddrinfo usage allowed... " >&6; }
31534 if test "x$curl_disallow_freeaddrinfo" != "xyes"; then
31535 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31536$as_echo "yes" >&6; }
31537 tst_allow_freeaddrinfo="yes"
31538 else
31539 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31540$as_echo "no" >&6; }
31541 tst_allow_freeaddrinfo="no"
31542 fi
31543 fi
31544 #
31545 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if freeaddrinfo might be used" >&5
31546$as_echo_n "checking if freeaddrinfo might be used... " >&6; }
31547 if test "$tst_links_freeaddrinfo" = "yes" &&
31548 test "$tst_proto_freeaddrinfo" = "yes" &&
31549 test "$tst_compi_freeaddrinfo" = "yes" &&
31550 test "$tst_allow_freeaddrinfo" = "yes"; then
31551 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31552$as_echo "yes" >&6; }
31553
31554cat >>confdefs.h <<_ACEOF
31555#define HAVE_FREEADDRINFO 1
31556_ACEOF
31557
31558 curl_cv_func_freeaddrinfo="yes"
31559 else
31560 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31561$as_echo "no" >&6; }
31562 curl_cv_func_freeaddrinfo="no"
31563 fi
31564
31565
31566curl_includes_ifaddrs="\
31567/* includes start */
31568#ifdef HAVE_SYS_TYPES_H
31569# include <sys/types.h>
31570#endif
31571#ifdef HAVE_SYS_SOCKET_H
31572# include <sys/socket.h>
31573#endif
31574#ifdef HAVE_NETINET_IN_H
31575# include <netinet/in.h>
31576#endif
31577#ifdef HAVE_IFADDRS_H
31578# include <ifaddrs.h>
31579#endif
31580/* includes end */"
31581 for ac_header in sys/types.h sys/socket.h netinet/in.h ifaddrs.h
31582do :
31583 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
31584ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_ifaddrs
31585"
31586if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
31587 cat >>confdefs.h <<_ACEOF
31588#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
31589_ACEOF
31590
31591fi
31592
31593done
31594
31595
31596
31597 #
31598 tst_links_freeifaddrs="unknown"
31599 tst_proto_freeifaddrs="unknown"
31600 tst_compi_freeifaddrs="unknown"
31601 tst_allow_freeifaddrs="unknown"
31602 #
31603 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if freeifaddrs can be linked" >&5
31604$as_echo_n "checking if freeifaddrs can be linked... " >&6; }
31605 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31606/* end confdefs.h. */
31607
31608
31609#define freeifaddrs innocuous_freeifaddrs
31610#ifdef __STDC__
31611# include <limits.h>
31612#else
31613# include <assert.h>
31614#endif
31615#undef freeifaddrs
31616#ifdef __cplusplus
31617extern "C"
31618#endif
31619char freeifaddrs ();
31620#if defined __stub_freeifaddrs || defined __stub___freeifaddrs
31621choke me
31622#endif
31623
31624int main (void)
31625{
31626return freeifaddrs ();
31627 ;
31628 return 0;
31629}
31630
31631_ACEOF
31632if ac_fn_c_try_link "$LINENO"; then :
31633
31634 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31635$as_echo "yes" >&6; }
31636 tst_links_freeifaddrs="yes"
31637
31638else
31639
31640 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31641$as_echo "no" >&6; }
31642 tst_links_freeifaddrs="no"
31643
31644fi
31645rm -f core conftest.err conftest.$ac_objext \
31646 conftest$ac_exeext conftest.$ac_ext
31647 #
31648 if test "$tst_links_freeifaddrs" = "yes"; then
31649 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if freeifaddrs is prototyped" >&5
31650$as_echo_n "checking if freeifaddrs is prototyped... " >&6; }
31651 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31652/* end confdefs.h. */
31653
31654 $curl_includes_ifaddrs
31655
31656_ACEOF
31657if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
31658 $EGREP "freeifaddrs" >/dev/null 2>&1; then :
31659
31660 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31661$as_echo "yes" >&6; }
31662 tst_proto_freeifaddrs="yes"
31663
31664else
31665
31666 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31667$as_echo "no" >&6; }
31668 tst_proto_freeifaddrs="no"
31669
31670fi
31671rm -f conftest*
31672
31673 fi
31674 #
31675 if test "$tst_proto_freeifaddrs" = "yes"; then
31676 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if freeifaddrs is compilable" >&5
31677$as_echo_n "checking if freeifaddrs is compilable... " >&6; }
31678 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31679/* end confdefs.h. */
31680
31681
31682 $curl_includes_ifaddrs
31683
31684int main (void)
31685{
31686
31687 freeifaddrs(0);
31688
31689 ;
31690 return 0;
31691}
31692
31693_ACEOF
31694if ac_fn_c_try_compile "$LINENO"; then :
31695
31696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31697$as_echo "yes" >&6; }
31698 tst_compi_freeifaddrs="yes"
31699
31700else
31701
31702 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31703$as_echo "no" >&6; }
31704 tst_compi_freeifaddrs="no"
31705
31706fi
31707rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31708 fi
31709 #
31710 if test "$tst_compi_freeifaddrs" = "yes"; then
31711 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if freeifaddrs usage allowed" >&5
31712$as_echo_n "checking if freeifaddrs usage allowed... " >&6; }
31713 if test "x$curl_disallow_freeifaddrs" != "xyes"; then
31714 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31715$as_echo "yes" >&6; }
31716 tst_allow_freeifaddrs="yes"
31717 else
31718 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31719$as_echo "no" >&6; }
31720 tst_allow_freeifaddrs="no"
31721 fi
31722 fi
31723 #
31724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if freeifaddrs might be used" >&5
31725$as_echo_n "checking if freeifaddrs might be used... " >&6; }
31726 if test "$tst_links_freeifaddrs" = "yes" &&
31727 test "$tst_proto_freeifaddrs" = "yes" &&
31728 test "$tst_compi_freeifaddrs" = "yes" &&
31729 test "$tst_allow_freeifaddrs" = "yes"; then
31730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31731$as_echo "yes" >&6; }
31732
31733cat >>confdefs.h <<_ACEOF
31734#define HAVE_FREEIFADDRS 1
31735_ACEOF
31736
31737 curl_cv_func_freeifaddrs="yes"
31738 else
31739 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31740$as_echo "no" >&6; }
31741 curl_cv_func_freeifaddrs="no"
31742 fi
31743
31744
31745curl_includes_sys_xattr="\
31746/* includes start */
31747#ifdef HAVE_SYS_TYPES_H
31748# include <sys/types.h>
31749#endif
31750#ifdef HAVE_SYS_XATTR_H
31751# include <sys/xattr.h>
31752#endif
31753/* includes end */"
31754 for ac_header in sys/types.h sys/xattr.h
31755do :
31756 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
31757ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_sys_xattr
31758"
31759if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
31760 cat >>confdefs.h <<_ACEOF
31761#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
31762_ACEOF
31763
31764fi
31765
31766done
31767
31768
31769
31770 #
31771 tst_links_fsetxattr="unknown"
31772 tst_proto_fsetxattr="unknown"
31773 tst_compi_fsetxattr="unknown"
31774 tst_allow_fsetxattr="unknown"
31775 tst_nargs_fsetxattr="unknown"
31776 #
31777 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fsetxattr can be linked" >&5
31778$as_echo_n "checking if fsetxattr can be linked... " >&6; }
31779 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31780/* end confdefs.h. */
31781
31782
31783#define fsetxattr innocuous_fsetxattr
31784#ifdef __STDC__
31785# include <limits.h>
31786#else
31787# include <assert.h>
31788#endif
31789#undef fsetxattr
31790#ifdef __cplusplus
31791extern "C"
31792#endif
31793char fsetxattr ();
31794#if defined __stub_fsetxattr || defined __stub___fsetxattr
31795choke me
31796#endif
31797
31798int main (void)
31799{
31800return fsetxattr ();
31801 ;
31802 return 0;
31803}
31804
31805_ACEOF
31806if ac_fn_c_try_link "$LINENO"; then :
31807
31808 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31809$as_echo "yes" >&6; }
31810 tst_links_fsetxattr="yes"
31811
31812else
31813
31814 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31815$as_echo "no" >&6; }
31816 tst_links_fsetxattr="no"
31817
31818fi
31819rm -f core conftest.err conftest.$ac_objext \
31820 conftest$ac_exeext conftest.$ac_ext
31821 #
31822 if test "$tst_links_fsetxattr" = "yes"; then
31823 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fsetxattr is prototyped" >&5
31824$as_echo_n "checking if fsetxattr is prototyped... " >&6; }
31825 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31826/* end confdefs.h. */
31827
31828 $curl_includes_sys_xattr
31829
31830_ACEOF
31831if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
31832 $EGREP "fsetxattr" >/dev/null 2>&1; then :
31833
31834 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31835$as_echo "yes" >&6; }
31836 tst_proto_fsetxattr="yes"
31837
31838else
31839
31840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31841$as_echo "no" >&6; }
31842 tst_proto_fsetxattr="no"
31843
31844fi
31845rm -f conftest*
31846
31847 fi
31848 #
31849 if test "$tst_proto_fsetxattr" = "yes"; then
31850 if test "$tst_nargs_fsetxattr" = "unknown"; then
31851 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fsetxattr takes 5 args." >&5
31852$as_echo_n "checking if fsetxattr takes 5 args.... " >&6; }
31853 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31854/* end confdefs.h. */
31855
31856
31857 $curl_includes_sys_xattr
31858
31859int main (void)
31860{
31861
31862 if(0 != fsetxattr(0, 0, 0, 0, 0))
31863 return 1;
31864
31865 ;
31866 return 0;
31867}
31868
31869_ACEOF
31870if ac_fn_c_try_compile "$LINENO"; then :
31871
31872 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31873$as_echo "yes" >&6; }
31874 tst_compi_fsetxattr="yes"
31875 tst_nargs_fsetxattr="5"
31876
31877else
31878
31879 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31880$as_echo "no" >&6; }
31881 tst_compi_fsetxattr="no"
31882
31883fi
31884rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31885 fi
31886 if test "$tst_nargs_fsetxattr" = "unknown"; then
31887 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fsetxattr takes 6 args." >&5
31888$as_echo_n "checking if fsetxattr takes 6 args.... " >&6; }
31889 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31890/* end confdefs.h. */
31891
31892
31893 $curl_includes_sys_xattr
31894
31895int main (void)
31896{
31897
31898 if(0 != fsetxattr(0, 0, 0, 0, 0, 0))
31899 return 1;
31900
31901 ;
31902 return 0;
31903}
31904
31905_ACEOF
31906if ac_fn_c_try_compile "$LINENO"; then :
31907
31908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31909$as_echo "yes" >&6; }
31910 tst_compi_fsetxattr="yes"
31911 tst_nargs_fsetxattr="6"
31912
31913else
31914
31915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31916$as_echo "no" >&6; }
31917 tst_compi_fsetxattr="no"
31918
31919fi
31920rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31921 fi
31922 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fsetxattr is compilable" >&5
31923$as_echo_n "checking if fsetxattr is compilable... " >&6; }
31924 if test "$tst_compi_fsetxattr" = "yes"; then
31925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31926$as_echo "yes" >&6; }
31927 else
31928 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31929$as_echo "no" >&6; }
31930 fi
31931 fi
31932 #
31933 if test "$tst_compi_fsetxattr" = "yes"; then
31934 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fsetxattr usage allowed" >&5
31935$as_echo_n "checking if fsetxattr usage allowed... " >&6; }
31936 if test "x$curl_disallow_fsetxattr" != "xyes"; then
31937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31938$as_echo "yes" >&6; }
31939 tst_allow_fsetxattr="yes"
31940 else
31941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31942$as_echo "no" >&6; }
31943 tst_allow_fsetxattr="no"
31944 fi
31945 fi
31946 #
31947 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fsetxattr might be used" >&5
31948$as_echo_n "checking if fsetxattr might be used... " >&6; }
31949 if test "$tst_links_fsetxattr" = "yes" &&
31950 test "$tst_proto_fsetxattr" = "yes" &&
31951 test "$tst_compi_fsetxattr" = "yes" &&
31952 test "$tst_allow_fsetxattr" = "yes"; then
31953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
31954$as_echo "yes" >&6; }
31955
31956cat >>confdefs.h <<_ACEOF
31957#define HAVE_FSETXATTR 1
31958_ACEOF
31959
31960 #
31961 if test "$tst_nargs_fsetxattr" -eq "5"; then
31962
31963$as_echo "#define HAVE_FSETXATTR_5 1" >>confdefs.h
31964
31965 elif test "$tst_nargs_fsetxattr" -eq "6"; then
31966
31967$as_echo "#define HAVE_FSETXATTR_6 1" >>confdefs.h
31968
31969 fi
31970 #
31971 curl_cv_func_fsetxattr="yes"
31972 else
31973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
31974$as_echo "no" >&6; }
31975 curl_cv_func_fsetxattr="no"
31976 fi
31977
31978
31979 #
31980 tst_links_ftruncate="unknown"
31981 tst_proto_ftruncate="unknown"
31982 tst_compi_ftruncate="unknown"
31983 tst_allow_ftruncate="unknown"
31984 #
31985 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ftruncate can be linked" >&5
31986$as_echo_n "checking if ftruncate can be linked... " >&6; }
31987 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31988/* end confdefs.h. */
31989
31990
31991#define ftruncate innocuous_ftruncate
31992#ifdef __STDC__
31993# include <limits.h>
31994#else
31995# include <assert.h>
31996#endif
31997#undef ftruncate
31998#ifdef __cplusplus
31999extern "C"
32000#endif
32001char ftruncate ();
32002#if defined __stub_ftruncate || defined __stub___ftruncate
32003choke me
32004#endif
32005
32006int main (void)
32007{
32008return ftruncate ();
32009 ;
32010 return 0;
32011}
32012
32013_ACEOF
32014if ac_fn_c_try_link "$LINENO"; then :
32015
32016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32017$as_echo "yes" >&6; }
32018 tst_links_ftruncate="yes"
32019
32020else
32021
32022 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32023$as_echo "no" >&6; }
32024 tst_links_ftruncate="no"
32025
32026fi
32027rm -f core conftest.err conftest.$ac_objext \
32028 conftest$ac_exeext conftest.$ac_ext
32029 #
32030 if test "$tst_links_ftruncate" = "yes"; then
32031 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ftruncate is prototyped" >&5
32032$as_echo_n "checking if ftruncate is prototyped... " >&6; }
32033 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32034/* end confdefs.h. */
32035
32036 $curl_includes_unistd
32037
32038_ACEOF
32039if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
32040 $EGREP "ftruncate" >/dev/null 2>&1; then :
32041
32042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32043$as_echo "yes" >&6; }
32044 tst_proto_ftruncate="yes"
32045
32046else
32047
32048 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32049$as_echo "no" >&6; }
32050 tst_proto_ftruncate="no"
32051
32052fi
32053rm -f conftest*
32054
32055 fi
32056 #
32057 if test "$tst_proto_ftruncate" = "yes"; then
32058 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ftruncate is compilable" >&5
32059$as_echo_n "checking if ftruncate is compilable... " >&6; }
32060 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32061/* end confdefs.h. */
32062
32063
32064 $curl_includes_unistd
32065
32066int main (void)
32067{
32068
32069 if(0 != ftruncate(0, 0))
32070 return 1;
32071
32072 ;
32073 return 0;
32074}
32075
32076_ACEOF
32077if ac_fn_c_try_compile "$LINENO"; then :
32078
32079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32080$as_echo "yes" >&6; }
32081 tst_compi_ftruncate="yes"
32082
32083else
32084
32085 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32086$as_echo "no" >&6; }
32087 tst_compi_ftruncate="no"
32088
32089fi
32090rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32091 fi
32092 #
32093 if test "$tst_compi_ftruncate" = "yes"; then
32094 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ftruncate usage allowed" >&5
32095$as_echo_n "checking if ftruncate usage allowed... " >&6; }
32096 if test "x$curl_disallow_ftruncate" != "xyes"; then
32097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32098$as_echo "yes" >&6; }
32099 tst_allow_ftruncate="yes"
32100 else
32101 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32102$as_echo "no" >&6; }
32103 tst_allow_ftruncate="no"
32104 fi
32105 fi
32106 #
32107 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ftruncate might be used" >&5
32108$as_echo_n "checking if ftruncate might be used... " >&6; }
32109 if test "$tst_links_ftruncate" = "yes" &&
32110 test "$tst_proto_ftruncate" = "yes" &&
32111 test "$tst_compi_ftruncate" = "yes" &&
32112 test "$tst_allow_ftruncate" = "yes"; then
32113 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32114$as_echo "yes" >&6; }
32115
32116cat >>confdefs.h <<_ACEOF
32117#define HAVE_FTRUNCATE 1
32118_ACEOF
32119
32120 curl_cv_func_ftruncate="yes"
32121 else
32122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32123$as_echo "no" >&6; }
32124 curl_cv_func_ftruncate="no"
32125 fi
32126
32127
32128curl_includes_stdlib="\
32129/* includes start */
32130#ifdef HAVE_SYS_TYPES_H
32131# include <sys/types.h>
32132#endif
32133#ifdef HAVE_STDLIB_H
32134# include <stdlib.h>
32135#endif
32136/* includes end */"
32137 for ac_header in sys/types.h stdlib.h
32138do :
32139 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
32140ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_stdlib
32141"
32142if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
32143 cat >>confdefs.h <<_ACEOF
32144#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
32145_ACEOF
32146
32147fi
32148
32149done
32150
32151
32152
32153 #
32154 tst_links_getaddrinfo="unknown"
32155 tst_proto_getaddrinfo="unknown"
32156 tst_compi_getaddrinfo="unknown"
32157 tst_works_getaddrinfo="unknown"
32158 tst_allow_getaddrinfo="unknown"
32159 tst_tsafe_getaddrinfo="unknown"
32160 #
32161 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getaddrinfo can be linked" >&5
32162$as_echo_n "checking if getaddrinfo can be linked... " >&6; }
32163 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32164/* end confdefs.h. */
32165
32166
32167 $curl_includes_ws2tcpip
32168 $curl_includes_sys_socket
32169 $curl_includes_netdb
32170
32171int main (void)
32172{
32173
32174 if(0 != getaddrinfo(0, 0, 0, 0))
32175 return 1;
32176
32177 ;
32178 return 0;
32179}
32180
32181_ACEOF
32182if ac_fn_c_try_link "$LINENO"; then :
32183
32184 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32185$as_echo "yes" >&6; }
32186 tst_links_getaddrinfo="yes"
32187
32188else
32189
32190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32191$as_echo "no" >&6; }
32192 tst_links_getaddrinfo="no"
32193
32194fi
32195rm -f core conftest.err conftest.$ac_objext \
32196 conftest$ac_exeext conftest.$ac_ext
32197 #
32198 if test "$tst_links_getaddrinfo" = "yes"; then
32199 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getaddrinfo is prototyped" >&5
32200$as_echo_n "checking if getaddrinfo is prototyped... " >&6; }
32201 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32202/* end confdefs.h. */
32203
32204 $curl_includes_ws2tcpip
32205 $curl_includes_sys_socket
32206 $curl_includes_netdb
32207
32208_ACEOF
32209if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
32210 $EGREP "getaddrinfo" >/dev/null 2>&1; then :
32211
32212 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32213$as_echo "yes" >&6; }
32214 tst_proto_getaddrinfo="yes"
32215
32216else
32217
32218 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32219$as_echo "no" >&6; }
32220 tst_proto_getaddrinfo="no"
32221
32222fi
32223rm -f conftest*
32224
32225 fi
32226 #
32227 if test "$tst_proto_getaddrinfo" = "yes"; then
32228 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getaddrinfo is compilable" >&5
32229$as_echo_n "checking if getaddrinfo is compilable... " >&6; }
32230 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32231/* end confdefs.h. */
32232
32233
32234 $curl_includes_ws2tcpip
32235 $curl_includes_sys_socket
32236 $curl_includes_netdb
32237
32238int main (void)
32239{
32240
32241 if(0 != getaddrinfo(0, 0, 0, 0))
32242 return 1;
32243
32244 ;
32245 return 0;
32246}
32247
32248_ACEOF
32249if ac_fn_c_try_compile "$LINENO"; then :
32250
32251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32252$as_echo "yes" >&6; }
32253 tst_compi_getaddrinfo="yes"
32254
32255else
32256
32257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32258$as_echo "no" >&6; }
32259 tst_compi_getaddrinfo="no"
32260
32261fi
32262rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32263 fi
32264 #
32265 if test "x$cross_compiling" != "xyes" &&
32266 test "$tst_compi_getaddrinfo" = "yes"; then
32267 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getaddrinfo seems to work" >&5
32268$as_echo_n "checking if getaddrinfo seems to work... " >&6; }
Elliott Hughesa93fb052018-12-12 14:22:48 -080032269
32270
32271 old=$LD_LIBRARY_PATH
32272 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
32273 export LD_LIBRARY_PATH
32274 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070032275 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
32276$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
32277as_fn_error $? "cannot run test program while cross compiling
32278See \`config.log' for more details" "$LINENO" 5; }
32279else
32280 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32281/* end confdefs.h. */
32282
32283
32284 $curl_includes_ws2tcpip
32285 $curl_includes_stdlib
32286 $curl_includes_string
32287 $curl_includes_sys_socket
32288 $curl_includes_netdb
32289
32290int main (void)
32291{
32292
32293 struct addrinfo hints;
32294 struct addrinfo *ai = 0;
32295 int error;
32296
32297 #ifdef HAVE_WINSOCK2_H
32298 WSADATA wsa;
32299 if (WSAStartup(MAKEWORD(2,2), &wsa))
32300 exit(2);
32301 #endif
32302
32303 memset(&hints, 0, sizeof(hints));
32304 hints.ai_flags = AI_NUMERICHOST;
32305 hints.ai_family = AF_UNSPEC;
32306 hints.ai_socktype = SOCK_STREAM;
32307 error = getaddrinfo("127.0.0.1", 0, &hints, &ai);
32308 if(error || !ai)
32309 exit(1); /* fail */
32310 else
32311 exit(0);
32312
32313 ;
32314 return 0;
32315}
32316
32317_ACEOF
32318if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughesa93fb052018-12-12 14:22:48 -080032319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070032320$as_echo "yes" >&6; }
32321 tst_works_getaddrinfo="yes"
32322
32323else
Elliott Hughesa93fb052018-12-12 14:22:48 -080032324 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070032325$as_echo "no" >&6; }
32326 tst_works_getaddrinfo="no"
32327
32328fi
32329rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
32330 conftest.$ac_objext conftest.beam conftest.$ac_ext
32331fi
32332
Elliott Hughesa93fb052018-12-12 14:22:48 -080032333 LD_LIBRARY_PATH=$old # restore
32334
Elliott Hughes82be86d2017-09-20 17:00:17 -070032335 fi
32336 #
32337 if test "$tst_compi_getaddrinfo" = "yes" &&
32338 test "$tst_works_getaddrinfo" != "no"; then
32339 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getaddrinfo usage allowed" >&5
32340$as_echo_n "checking if getaddrinfo usage allowed... " >&6; }
32341 if test "x$curl_disallow_getaddrinfo" != "xyes"; then
32342 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32343$as_echo "yes" >&6; }
32344 tst_allow_getaddrinfo="yes"
32345 else
32346 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32347$as_echo "no" >&6; }
32348 tst_allow_getaddrinfo="no"
32349 fi
32350 fi
32351 #
32352 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getaddrinfo might be used" >&5
32353$as_echo_n "checking if getaddrinfo might be used... " >&6; }
32354 if test "$tst_links_getaddrinfo" = "yes" &&
32355 test "$tst_proto_getaddrinfo" = "yes" &&
32356 test "$tst_compi_getaddrinfo" = "yes" &&
32357 test "$tst_allow_getaddrinfo" = "yes" &&
32358 test "$tst_works_getaddrinfo" != "no"; then
32359 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32360$as_echo "yes" >&6; }
32361
32362cat >>confdefs.h <<_ACEOF
32363#define HAVE_GETADDRINFO 1
32364_ACEOF
32365
32366 curl_cv_func_getaddrinfo="yes"
32367 else
32368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32369$as_echo "no" >&6; }
32370 curl_cv_func_getaddrinfo="no"
32371 curl_cv_func_getaddrinfo_threadsafe="no"
32372 fi
32373 #
32374 if test "$curl_cv_func_getaddrinfo" = "yes"; then
32375 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getaddrinfo is threadsafe" >&5
32376$as_echo_n "checking if getaddrinfo is threadsafe... " >&6; }
32377 case $host_os in
32378 aix[1234].* | aix5.[01].*)
32379 tst_tsafe_getaddrinfo="no"
32380 ;;
32381 aix*)
32382 tst_tsafe_getaddrinfo="yes"
32383 ;;
32384 darwin[12345].*)
32385 tst_tsafe_getaddrinfo="no"
32386 ;;
32387 darwin*)
32388 tst_tsafe_getaddrinfo="yes"
32389 ;;
32390 freebsd[1234].* | freebsd5.[1234]*)
32391 tst_tsafe_getaddrinfo="no"
32392 ;;
32393 freebsd*)
32394 tst_tsafe_getaddrinfo="yes"
32395 ;;
32396 hpux[123456789].* | hpux10.* | hpux11.0* | hpux11.10*)
32397 tst_tsafe_getaddrinfo="no"
32398 ;;
32399 hpux*)
32400 tst_tsafe_getaddrinfo="yes"
32401 ;;
32402 netbsd[123].*)
32403 tst_tsafe_getaddrinfo="no"
32404 ;;
32405 netbsd*)
32406 tst_tsafe_getaddrinfo="yes"
32407 ;;
32408 *bsd*)
32409 tst_tsafe_getaddrinfo="no"
32410 ;;
32411 solaris2*)
32412 tst_tsafe_getaddrinfo="yes"
32413 ;;
32414 esac
32415 if test "$tst_tsafe_getaddrinfo" = "unknown" &&
32416 test "$curl_cv_native_windows" = "yes"; then
32417 tst_tsafe_getaddrinfo="yes"
32418 fi
32419 if test "$tst_tsafe_getaddrinfo" = "unknown"; then
32420
32421
32422 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32423/* end confdefs.h. */
32424
32425
32426 $curl_includes_sys_socket
32427 $curl_includes_netdb
32428
32429int main (void)
32430{
32431#ifdef h_errno
32432 return 0;
32433#else
32434 force compilation error
32435#endif
32436}
32437
32438
32439_ACEOF
32440if ac_fn_c_try_compile "$LINENO"; then :
32441
32442 tst_symbol_defined="yes"
32443
32444else
32445
32446 tst_symbol_defined="no"
32447
32448fi
32449rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32450 if test "$tst_symbol_defined" = "yes"; then
32451 curl_cv_have_def_h_errno=yes
32452
32453 else
32454 curl_cv_have_def_h_errno=no
32455
32456 fi
32457
32458 if test "$curl_cv_have_def_h_errno" = "yes"; then
32459 tst_h_errno_macro="yes"
32460 else
32461 tst_h_errno_macro="no"
32462 fi
32463 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32464/* end confdefs.h. */
32465
32466
32467 $curl_includes_sys_socket
32468 $curl_includes_netdb
32469
32470int main (void)
32471{
32472
32473 h_errno = 2;
32474 if(0 != h_errno)
32475 return 1;
32476
32477 ;
32478 return 0;
32479}
32480
32481_ACEOF
32482if ac_fn_c_try_compile "$LINENO"; then :
32483
32484 tst_h_errno_modifiable_lvalue="yes"
32485
32486else
32487
32488 tst_h_errno_modifiable_lvalue="no"
32489
32490fi
32491rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32492 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32493/* end confdefs.h. */
32494
32495
32496
32497int main (void)
32498{
32499
32500#if defined(_POSIX_C_SOURCE) && (_POSIX_C_SOURCE >= 200809L)
32501 return 0;
32502#elif defined(_XOPEN_SOURCE) && (_XOPEN_SOURCE >= 700)
32503 return 0;
32504#else
32505 force compilation error
32506#endif
32507
32508 ;
32509 return 0;
32510}
32511
32512_ACEOF
32513if ac_fn_c_try_compile "$LINENO"; then :
32514
32515 tst_h_errno_sbs_issue_7="yes"
32516
32517else
32518
32519 tst_h_errno_sbs_issue_7="no"
32520
32521fi
32522rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32523 if test "$tst_h_errno_macro" = "no" &&
32524 test "$tst_h_errno_modifiable_lvalue" = "no" &&
32525 test "$tst_h_errno_sbs_issue_7" = "no"; then
32526 tst_tsafe_getaddrinfo="no"
32527 else
32528 tst_tsafe_getaddrinfo="yes"
32529 fi
32530 fi
32531 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tst_tsafe_getaddrinfo" >&5
32532$as_echo "$tst_tsafe_getaddrinfo" >&6; }
32533 if test "$tst_tsafe_getaddrinfo" = "yes"; then
32534
32535cat >>confdefs.h <<_ACEOF
32536#define HAVE_GETADDRINFO_THREADSAFE 1
32537_ACEOF
32538
32539 curl_cv_func_getaddrinfo_threadsafe="yes"
32540 else
32541 curl_cv_func_getaddrinfo_threadsafe="no"
32542 fi
32543 fi
32544
32545
32546 #
32547 tst_links_gai_strerror="unknown"
32548 tst_proto_gai_strerror="unknown"
32549 tst_compi_gai_strerror="unknown"
32550 tst_allow_gai_strerror="unknown"
32551 #
32552 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gai_strerror can be linked" >&5
32553$as_echo_n "checking if gai_strerror can be linked... " >&6; }
32554 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32555/* end confdefs.h. */
32556
32557
32558 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070032559 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070032560 $curl_includes_netdb
32561
32562int main (void)
32563{
32564
32565 if(0 != gai_strerror(0))
32566 return 1;
32567
32568 ;
32569 return 0;
32570}
32571
32572_ACEOF
32573if ac_fn_c_try_link "$LINENO"; then :
32574
32575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32576$as_echo "yes" >&6; }
32577 tst_links_gai_strerror="yes"
32578
32579else
32580
32581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32582$as_echo "no" >&6; }
32583 tst_links_gai_strerror="no"
32584
32585fi
32586rm -f core conftest.err conftest.$ac_objext \
32587 conftest$ac_exeext conftest.$ac_ext
32588 #
32589 if test "$tst_links_gai_strerror" = "yes"; then
32590 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gai_strerror is prototyped" >&5
32591$as_echo_n "checking if gai_strerror is prototyped... " >&6; }
32592 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32593/* end confdefs.h. */
32594
32595 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070032596 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070032597 $curl_includes_netdb
32598
32599_ACEOF
32600if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
32601 $EGREP "gai_strerror" >/dev/null 2>&1; then :
32602
32603 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32604$as_echo "yes" >&6; }
32605 tst_proto_gai_strerror="yes"
32606
32607else
32608
32609 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32610$as_echo "no" >&6; }
32611 tst_proto_gai_strerror="no"
32612
32613fi
32614rm -f conftest*
32615
32616 fi
32617 #
32618 if test "$tst_proto_gai_strerror" = "yes"; then
32619 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gai_strerror is compilable" >&5
32620$as_echo_n "checking if gai_strerror is compilable... " >&6; }
32621 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32622/* end confdefs.h. */
32623
32624
32625 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070032626 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070032627 $curl_includes_netdb
32628
32629int main (void)
32630{
32631
32632 if(0 != gai_strerror(0))
32633 return 1;
32634
32635 ;
32636 return 0;
32637}
32638
32639_ACEOF
32640if ac_fn_c_try_compile "$LINENO"; then :
32641
32642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32643$as_echo "yes" >&6; }
32644 tst_compi_gai_strerror="yes"
32645
32646else
32647
32648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32649$as_echo "no" >&6; }
32650 tst_compi_gai_strerror="no"
32651
32652fi
32653rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32654 fi
32655 #
32656 if test "$tst_compi_gai_strerror" = "yes"; then
32657 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gai_strerror usage allowed" >&5
32658$as_echo_n "checking if gai_strerror usage allowed... " >&6; }
32659 if test "x$curl_disallow_gai_strerror" != "xyes"; then
32660 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32661$as_echo "yes" >&6; }
32662 tst_allow_gai_strerror="yes"
32663 else
32664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32665$as_echo "no" >&6; }
32666 tst_allow_gai_strerror="no"
32667 fi
32668 fi
32669 #
32670 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gai_strerror might be used" >&5
32671$as_echo_n "checking if gai_strerror might be used... " >&6; }
32672 if test "$tst_links_gai_strerror" = "yes" &&
32673 test "$tst_proto_gai_strerror" = "yes" &&
32674 test "$tst_compi_gai_strerror" = "yes" &&
32675 test "$tst_allow_gai_strerror" = "yes"; then
32676 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32677$as_echo "yes" >&6; }
32678
32679cat >>confdefs.h <<_ACEOF
32680#define HAVE_GAI_STRERROR 1
32681_ACEOF
32682
32683 curl_cv_func_gai_strerror="yes"
32684 else
32685 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32686$as_echo "no" >&6; }
32687 curl_cv_func_gai_strerror="no"
32688 fi
32689
32690
32691 #
32692 tst_links_gethostbyaddr="unknown"
32693 tst_proto_gethostbyaddr="unknown"
32694 tst_compi_gethostbyaddr="unknown"
32695 tst_allow_gethostbyaddr="unknown"
32696 #
32697 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyaddr can be linked" >&5
32698$as_echo_n "checking if gethostbyaddr can be linked... " >&6; }
32699 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32700/* end confdefs.h. */
32701
32702
32703 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070032704 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070032705 $curl_includes_netdb
32706
32707int main (void)
32708{
32709
32710 if(0 != gethostbyaddr(0, 0, 0))
32711 return 1;
32712
32713 ;
32714 return 0;
32715}
32716
32717_ACEOF
32718if ac_fn_c_try_link "$LINENO"; then :
32719
32720 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32721$as_echo "yes" >&6; }
32722 tst_links_gethostbyaddr="yes"
32723
32724else
32725
32726 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32727$as_echo "no" >&6; }
32728 tst_links_gethostbyaddr="no"
32729
32730fi
32731rm -f core conftest.err conftest.$ac_objext \
32732 conftest$ac_exeext conftest.$ac_ext
32733 #
32734 if test "$tst_links_gethostbyaddr" = "yes"; then
32735 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyaddr is prototyped" >&5
32736$as_echo_n "checking if gethostbyaddr is prototyped... " >&6; }
32737 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32738/* end confdefs.h. */
32739
32740 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070032741 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070032742 $curl_includes_netdb
32743
32744_ACEOF
32745if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
32746 $EGREP "gethostbyaddr" >/dev/null 2>&1; then :
32747
32748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32749$as_echo "yes" >&6; }
32750 tst_proto_gethostbyaddr="yes"
32751
32752else
32753
32754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32755$as_echo "no" >&6; }
32756 tst_proto_gethostbyaddr="no"
32757
32758fi
32759rm -f conftest*
32760
32761 fi
32762 #
32763 if test "$tst_proto_gethostbyaddr" = "yes"; then
32764 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyaddr is compilable" >&5
32765$as_echo_n "checking if gethostbyaddr is compilable... " >&6; }
32766 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32767/* end confdefs.h. */
32768
32769
32770 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070032771 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070032772 $curl_includes_netdb
32773
32774int main (void)
32775{
32776
32777 if(0 != gethostbyaddr(0, 0, 0))
32778 return 1;
32779
32780 ;
32781 return 0;
32782}
32783
32784_ACEOF
32785if ac_fn_c_try_compile "$LINENO"; then :
32786
32787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32788$as_echo "yes" >&6; }
32789 tst_compi_gethostbyaddr="yes"
32790
32791else
32792
32793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32794$as_echo "no" >&6; }
32795 tst_compi_gethostbyaddr="no"
32796
32797fi
32798rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32799 fi
32800 #
32801 if test "$tst_compi_gethostbyaddr" = "yes"; then
32802 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyaddr usage allowed" >&5
32803$as_echo_n "checking if gethostbyaddr usage allowed... " >&6; }
32804 if test "x$curl_disallow_gethostbyaddr" != "xyes"; then
32805 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32806$as_echo "yes" >&6; }
32807 tst_allow_gethostbyaddr="yes"
32808 else
32809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32810$as_echo "no" >&6; }
32811 tst_allow_gethostbyaddr="no"
32812 fi
32813 fi
32814 #
32815 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyaddr might be used" >&5
32816$as_echo_n "checking if gethostbyaddr might be used... " >&6; }
32817 if test "$tst_links_gethostbyaddr" = "yes" &&
32818 test "$tst_proto_gethostbyaddr" = "yes" &&
32819 test "$tst_compi_gethostbyaddr" = "yes" &&
32820 test "$tst_allow_gethostbyaddr" = "yes"; then
32821 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32822$as_echo "yes" >&6; }
32823
32824cat >>confdefs.h <<_ACEOF
32825#define HAVE_GETHOSTBYADDR 1
32826_ACEOF
32827
32828 curl_cv_func_gethostbyaddr="yes"
32829 else
32830 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32831$as_echo "no" >&6; }
32832 curl_cv_func_gethostbyaddr="no"
32833 fi
32834
32835
32836 #
32837 tst_links_gethostbyaddr_r="unknown"
32838 tst_proto_gethostbyaddr_r="unknown"
32839 tst_compi_gethostbyaddr_r="unknown"
32840 tst_allow_gethostbyaddr_r="unknown"
32841 tst_nargs_gethostbyaddr_r="unknown"
32842 #
32843 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyaddr_r can be linked" >&5
32844$as_echo_n "checking if gethostbyaddr_r can be linked... " >&6; }
32845 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32846/* end confdefs.h. */
32847
32848
32849#define gethostbyaddr_r innocuous_gethostbyaddr_r
32850#ifdef __STDC__
32851# include <limits.h>
32852#else
32853# include <assert.h>
32854#endif
32855#undef gethostbyaddr_r
32856#ifdef __cplusplus
32857extern "C"
32858#endif
32859char gethostbyaddr_r ();
32860#if defined __stub_gethostbyaddr_r || defined __stub___gethostbyaddr_r
32861choke me
32862#endif
32863
32864int main (void)
32865{
32866return gethostbyaddr_r ();
32867 ;
32868 return 0;
32869}
32870
32871_ACEOF
32872if ac_fn_c_try_link "$LINENO"; then :
32873
32874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32875$as_echo "yes" >&6; }
32876 tst_links_gethostbyaddr_r="yes"
32877
32878else
32879
32880 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32881$as_echo "no" >&6; }
32882 tst_links_gethostbyaddr_r="no"
32883
32884fi
32885rm -f core conftest.err conftest.$ac_objext \
32886 conftest$ac_exeext conftest.$ac_ext
32887 #
32888 if test "$tst_links_gethostbyaddr_r" = "yes"; then
32889 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyaddr_r is prototyped" >&5
32890$as_echo_n "checking if gethostbyaddr_r is prototyped... " >&6; }
32891 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32892/* end confdefs.h. */
32893
32894 $curl_includes_netdb
32895
32896_ACEOF
32897if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
32898 $EGREP "gethostbyaddr_r" >/dev/null 2>&1; then :
32899
32900 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32901$as_echo "yes" >&6; }
32902 tst_proto_gethostbyaddr_r="yes"
32903
32904else
32905
32906 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32907$as_echo "no" >&6; }
32908 tst_proto_gethostbyaddr_r="no"
32909
32910fi
32911rm -f conftest*
32912
32913 fi
32914 #
32915 if test "$tst_proto_gethostbyaddr_r" = "yes"; then
32916 if test "$tst_nargs_gethostbyaddr_r" = "unknown"; then
32917 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyaddr_r takes 5 args." >&5
32918$as_echo_n "checking if gethostbyaddr_r takes 5 args.... " >&6; }
32919 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32920/* end confdefs.h. */
32921
32922
32923 $curl_includes_netdb
32924
32925int main (void)
32926{
32927
32928 if(0 != gethostbyaddr_r(0, 0, 0, 0, 0))
32929 return 1;
32930
32931 ;
32932 return 0;
32933}
32934
32935_ACEOF
32936if ac_fn_c_try_compile "$LINENO"; then :
32937
32938 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32939$as_echo "yes" >&6; }
32940 tst_compi_gethostbyaddr_r="yes"
32941 tst_nargs_gethostbyaddr_r="5"
32942
32943else
32944
32945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32946$as_echo "no" >&6; }
32947 tst_compi_gethostbyaddr_r="no"
32948
32949fi
32950rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32951 fi
32952 if test "$tst_nargs_gethostbyaddr_r" = "unknown"; then
32953 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyaddr_r takes 7 args." >&5
32954$as_echo_n "checking if gethostbyaddr_r takes 7 args.... " >&6; }
32955 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32956/* end confdefs.h. */
32957
32958
32959 $curl_includes_netdb
32960
32961int main (void)
32962{
32963
32964 if(0 != gethostbyaddr_r(0, 0, 0, 0, 0, 0, 0))
32965 return 1;
32966
32967 ;
32968 return 0;
32969}
32970
32971_ACEOF
32972if ac_fn_c_try_compile "$LINENO"; then :
32973
32974 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
32975$as_echo "yes" >&6; }
32976 tst_compi_gethostbyaddr_r="yes"
32977 tst_nargs_gethostbyaddr_r="7"
32978
32979else
32980
32981 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
32982$as_echo "no" >&6; }
32983 tst_compi_gethostbyaddr_r="no"
32984
32985fi
32986rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32987 fi
32988 if test "$tst_nargs_gethostbyaddr_r" = "unknown"; then
32989 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyaddr_r takes 8 args." >&5
32990$as_echo_n "checking if gethostbyaddr_r takes 8 args.... " >&6; }
32991 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32992/* end confdefs.h. */
32993
32994
32995 $curl_includes_netdb
32996
32997int main (void)
32998{
32999
33000 if(0 != gethostbyaddr_r(0, 0, 0, 0, 0, 0, 0, 0))
33001 return 1;
33002
33003 ;
33004 return 0;
33005}
33006
33007_ACEOF
33008if ac_fn_c_try_compile "$LINENO"; then :
33009
33010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33011$as_echo "yes" >&6; }
33012 tst_compi_gethostbyaddr_r="yes"
33013 tst_nargs_gethostbyaddr_r="8"
33014
33015else
33016
33017 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33018$as_echo "no" >&6; }
33019 tst_compi_gethostbyaddr_r="no"
33020
33021fi
33022rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33023 fi
33024 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyaddr_r is compilable" >&5
33025$as_echo_n "checking if gethostbyaddr_r is compilable... " >&6; }
33026 if test "$tst_compi_gethostbyaddr_r" = "yes"; then
33027 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33028$as_echo "yes" >&6; }
33029 else
33030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33031$as_echo "no" >&6; }
33032 fi
33033 fi
33034 #
33035 if test "$tst_compi_gethostbyaddr_r" = "yes"; then
33036 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyaddr_r usage allowed" >&5
33037$as_echo_n "checking if gethostbyaddr_r usage allowed... " >&6; }
33038 if test "x$curl_disallow_gethostbyaddr_r" != "xyes"; then
33039 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33040$as_echo "yes" >&6; }
33041 tst_allow_gethostbyaddr_r="yes"
33042 else
33043 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33044$as_echo "no" >&6; }
33045 tst_allow_gethostbyaddr_r="no"
33046 fi
33047 fi
33048 #
33049 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyaddr_r might be used" >&5
33050$as_echo_n "checking if gethostbyaddr_r might be used... " >&6; }
33051 if test "$tst_links_gethostbyaddr_r" = "yes" &&
33052 test "$tst_proto_gethostbyaddr_r" = "yes" &&
33053 test "$tst_compi_gethostbyaddr_r" = "yes" &&
33054 test "$tst_allow_gethostbyaddr_r" = "yes"; then
33055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33056$as_echo "yes" >&6; }
33057
33058cat >>confdefs.h <<_ACEOF
33059#define HAVE_GETHOSTBYADDR_R 1
33060_ACEOF
33061
33062 #
33063 if test "$tst_nargs_gethostbyaddr_r" -eq "5"; then
33064
33065$as_echo "#define HAVE_GETHOSTBYADDR_R_5 1" >>confdefs.h
33066
33067 elif test "$tst_nargs_gethostbyaddr_r" -eq "7"; then
33068
33069$as_echo "#define HAVE_GETHOSTBYADDR_R_7 1" >>confdefs.h
33070
33071 elif test "$tst_nargs_gethostbyaddr_r" -eq "8"; then
33072
33073$as_echo "#define HAVE_GETHOSTBYADDR_R_8 1" >>confdefs.h
33074
33075 fi
33076 #
33077 curl_cv_func_gethostbyaddr_r="yes"
33078 else
33079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33080$as_echo "no" >&6; }
33081 curl_cv_func_gethostbyaddr_r="no"
33082 fi
33083
33084
33085 #
33086 tst_links_gethostbyname="unknown"
33087 tst_proto_gethostbyname="unknown"
33088 tst_compi_gethostbyname="unknown"
33089 tst_allow_gethostbyname="unknown"
33090 #
33091 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyname can be linked" >&5
33092$as_echo_n "checking if gethostbyname can be linked... " >&6; }
33093 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33094/* end confdefs.h. */
33095
33096
33097 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070033098 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070033099 $curl_includes_netdb
33100
33101int main (void)
33102{
33103
33104 if(0 != gethostbyname(0))
33105 return 1;
33106
33107 ;
33108 return 0;
33109}
33110
33111_ACEOF
33112if ac_fn_c_try_link "$LINENO"; then :
33113
33114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33115$as_echo "yes" >&6; }
33116 tst_links_gethostbyname="yes"
33117
33118else
33119
33120 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33121$as_echo "no" >&6; }
33122 tst_links_gethostbyname="no"
33123
33124fi
33125rm -f core conftest.err conftest.$ac_objext \
33126 conftest$ac_exeext conftest.$ac_ext
33127 #
33128 if test "$tst_links_gethostbyname" = "yes"; then
33129 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyname is prototyped" >&5
33130$as_echo_n "checking if gethostbyname is prototyped... " >&6; }
33131 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33132/* end confdefs.h. */
33133
33134 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070033135 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070033136 $curl_includes_netdb
33137
33138_ACEOF
33139if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
33140 $EGREP "gethostbyname" >/dev/null 2>&1; then :
33141
33142 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33143$as_echo "yes" >&6; }
33144 tst_proto_gethostbyname="yes"
33145
33146else
33147
33148 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33149$as_echo "no" >&6; }
33150 tst_proto_gethostbyname="no"
33151
33152fi
33153rm -f conftest*
33154
33155 fi
33156 #
33157 if test "$tst_proto_gethostbyname" = "yes"; then
33158 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyname is compilable" >&5
33159$as_echo_n "checking if gethostbyname is compilable... " >&6; }
33160 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33161/* end confdefs.h. */
33162
33163
33164 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070033165 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070033166 $curl_includes_netdb
33167
33168int main (void)
33169{
33170
33171 if(0 != gethostbyname(0))
33172 return 1;
33173
33174 ;
33175 return 0;
33176}
33177
33178_ACEOF
33179if ac_fn_c_try_compile "$LINENO"; then :
33180
33181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33182$as_echo "yes" >&6; }
33183 tst_compi_gethostbyname="yes"
33184
33185else
33186
33187 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33188$as_echo "no" >&6; }
33189 tst_compi_gethostbyname="no"
33190
33191fi
33192rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33193 fi
33194 #
33195 if test "$tst_compi_gethostbyname" = "yes"; then
33196 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyname usage allowed" >&5
33197$as_echo_n "checking if gethostbyname usage allowed... " >&6; }
33198 if test "x$curl_disallow_gethostbyname" != "xyes"; then
33199 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33200$as_echo "yes" >&6; }
33201 tst_allow_gethostbyname="yes"
33202 else
33203 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33204$as_echo "no" >&6; }
33205 tst_allow_gethostbyname="no"
33206 fi
33207 fi
33208 #
33209 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyname might be used" >&5
33210$as_echo_n "checking if gethostbyname might be used... " >&6; }
33211 if test "$tst_links_gethostbyname" = "yes" &&
33212 test "$tst_proto_gethostbyname" = "yes" &&
33213 test "$tst_compi_gethostbyname" = "yes" &&
33214 test "$tst_allow_gethostbyname" = "yes"; then
33215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33216$as_echo "yes" >&6; }
33217
33218cat >>confdefs.h <<_ACEOF
33219#define HAVE_GETHOSTBYNAME 1
33220_ACEOF
33221
33222 curl_cv_func_gethostbyname="yes"
33223 else
33224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33225$as_echo "no" >&6; }
33226 curl_cv_func_gethostbyname="no"
33227 fi
33228
33229
33230 #
33231 tst_links_gethostbyname_r="unknown"
33232 tst_proto_gethostbyname_r="unknown"
33233 tst_compi_gethostbyname_r="unknown"
33234 tst_allow_gethostbyname_r="unknown"
33235 tst_nargs_gethostbyname_r="unknown"
33236 #
33237 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyname_r can be linked" >&5
33238$as_echo_n "checking if gethostbyname_r can be linked... " >&6; }
33239 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33240/* end confdefs.h. */
33241
33242
33243#define gethostbyname_r innocuous_gethostbyname_r
33244#ifdef __STDC__
33245# include <limits.h>
33246#else
33247# include <assert.h>
33248#endif
33249#undef gethostbyname_r
33250#ifdef __cplusplus
33251extern "C"
33252#endif
33253char gethostbyname_r ();
33254#if defined __stub_gethostbyname_r || defined __stub___gethostbyname_r
33255choke me
33256#endif
33257
33258int main (void)
33259{
33260return gethostbyname_r ();
33261 ;
33262 return 0;
33263}
33264
33265_ACEOF
33266if ac_fn_c_try_link "$LINENO"; then :
33267
33268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33269$as_echo "yes" >&6; }
33270 tst_links_gethostbyname_r="yes"
33271
33272else
33273
33274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33275$as_echo "no" >&6; }
33276 tst_links_gethostbyname_r="no"
33277
33278fi
33279rm -f core conftest.err conftest.$ac_objext \
33280 conftest$ac_exeext conftest.$ac_ext
33281 #
33282 if test "$tst_links_gethostbyname_r" = "yes"; then
33283 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyname_r is prototyped" >&5
33284$as_echo_n "checking if gethostbyname_r is prototyped... " >&6; }
33285 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33286/* end confdefs.h. */
33287
33288 $curl_includes_netdb
33289
33290_ACEOF
33291if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
33292 $EGREP "gethostbyname_r" >/dev/null 2>&1; then :
33293
33294 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33295$as_echo "yes" >&6; }
33296 tst_proto_gethostbyname_r="yes"
33297
33298else
33299
33300 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33301$as_echo "no" >&6; }
33302 tst_proto_gethostbyname_r="no"
33303
33304fi
33305rm -f conftest*
33306
33307 fi
33308 #
33309 if test "$tst_proto_gethostbyname_r" = "yes"; then
33310 if test "$tst_nargs_gethostbyname_r" = "unknown"; then
33311 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyname_r takes 3 args." >&5
33312$as_echo_n "checking if gethostbyname_r takes 3 args.... " >&6; }
33313 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33314/* end confdefs.h. */
33315
33316
33317 $curl_includes_netdb
33318
33319int main (void)
33320{
33321
33322 if(0 != gethostbyname_r(0, 0, 0))
33323 return 1;
33324
33325 ;
33326 return 0;
33327}
33328
33329_ACEOF
33330if ac_fn_c_try_compile "$LINENO"; then :
33331
33332 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33333$as_echo "yes" >&6; }
33334 tst_compi_gethostbyname_r="yes"
33335 tst_nargs_gethostbyname_r="3"
33336
33337else
33338
33339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33340$as_echo "no" >&6; }
33341 tst_compi_gethostbyname_r="no"
33342
33343fi
33344rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33345 fi
33346 if test "$tst_nargs_gethostbyname_r" = "unknown"; then
33347 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyname_r takes 5 args." >&5
33348$as_echo_n "checking if gethostbyname_r takes 5 args.... " >&6; }
33349 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33350/* end confdefs.h. */
33351
33352
33353 $curl_includes_netdb
33354
33355int main (void)
33356{
33357
33358 if(0 != gethostbyname_r(0, 0, 0, 0, 0))
33359 return 1;
33360
33361 ;
33362 return 0;
33363}
33364
33365_ACEOF
33366if ac_fn_c_try_compile "$LINENO"; then :
33367
33368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33369$as_echo "yes" >&6; }
33370 tst_compi_gethostbyname_r="yes"
33371 tst_nargs_gethostbyname_r="5"
33372
33373else
33374
33375 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33376$as_echo "no" >&6; }
33377 tst_compi_gethostbyname_r="no"
33378
33379fi
33380rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33381 fi
33382 if test "$tst_nargs_gethostbyname_r" = "unknown"; then
33383 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyname_r takes 6 args." >&5
33384$as_echo_n "checking if gethostbyname_r takes 6 args.... " >&6; }
33385 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33386/* end confdefs.h. */
33387
33388
33389 $curl_includes_netdb
33390
33391int main (void)
33392{
33393
33394 if(0 != gethostbyname_r(0, 0, 0, 0, 0, 0))
33395 return 1;
33396
33397 ;
33398 return 0;
33399}
33400
33401_ACEOF
33402if ac_fn_c_try_compile "$LINENO"; then :
33403
33404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33405$as_echo "yes" >&6; }
33406 tst_compi_gethostbyname_r="yes"
33407 tst_nargs_gethostbyname_r="6"
33408
33409else
33410
33411 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33412$as_echo "no" >&6; }
33413 tst_compi_gethostbyname_r="no"
33414
33415fi
33416rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33417 fi
33418 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyname_r is compilable" >&5
33419$as_echo_n "checking if gethostbyname_r is compilable... " >&6; }
33420 if test "$tst_compi_gethostbyname_r" = "yes"; then
33421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33422$as_echo "yes" >&6; }
33423 else
33424 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33425$as_echo "no" >&6; }
33426 fi
33427 fi
33428 #
33429 if test "$tst_compi_gethostbyname_r" = "yes"; then
33430 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyname_r usage allowed" >&5
33431$as_echo_n "checking if gethostbyname_r usage allowed... " >&6; }
33432 if test "x$curl_disallow_gethostbyname_r" != "xyes"; then
33433 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33434$as_echo "yes" >&6; }
33435 tst_allow_gethostbyname_r="yes"
33436 else
33437 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33438$as_echo "no" >&6; }
33439 tst_allow_gethostbyname_r="no"
33440 fi
33441 fi
33442 #
33443 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostbyname_r might be used" >&5
33444$as_echo_n "checking if gethostbyname_r might be used... " >&6; }
33445 if test "$tst_links_gethostbyname_r" = "yes" &&
33446 test "$tst_proto_gethostbyname_r" = "yes" &&
33447 test "$tst_compi_gethostbyname_r" = "yes" &&
33448 test "$tst_allow_gethostbyname_r" = "yes"; then
33449 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33450$as_echo "yes" >&6; }
33451
33452cat >>confdefs.h <<_ACEOF
33453#define HAVE_GETHOSTBYNAME_R 1
33454_ACEOF
33455
33456 #
33457 if test "$tst_nargs_gethostbyname_r" -eq "3"; then
33458
33459$as_echo "#define HAVE_GETHOSTBYNAME_R_3 1" >>confdefs.h
33460
33461 elif test "$tst_nargs_gethostbyname_r" -eq "5"; then
33462
33463$as_echo "#define HAVE_GETHOSTBYNAME_R_5 1" >>confdefs.h
33464
33465 elif test "$tst_nargs_gethostbyname_r" -eq "6"; then
33466
33467$as_echo "#define HAVE_GETHOSTBYNAME_R_6 1" >>confdefs.h
33468
33469 fi
33470 #
33471 curl_cv_func_gethostbyname_r="yes"
33472 else
33473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33474$as_echo "no" >&6; }
33475 curl_cv_func_gethostbyname_r="no"
33476 fi
33477
33478
Elliott Hughesa93fb052018-12-12 14:22:48 -080033479curl_preprocess_callconv="\
33480/* preprocess start */
33481#ifdef HAVE_WINDOWS_H
33482# define FUNCALLCONV __stdcall
33483#else
33484# define FUNCALLCONV
33485#endif
33486/* preprocess end */"
33487
33488
Haibo Huang65021c72019-03-27 15:37:23 -070033489 #
Elliott Hughes82be86d2017-09-20 17:00:17 -070033490 tst_links_gethostname="unknown"
33491 tst_proto_gethostname="unknown"
33492 tst_compi_gethostname="unknown"
33493 tst_allow_gethostname="unknown"
33494 #
33495 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostname can be linked" >&5
33496$as_echo_n "checking if gethostname can be linked... " >&6; }
33497 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33498/* end confdefs.h. */
33499
33500
33501 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070033502 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070033503 $curl_includes_unistd
33504
33505int main (void)
33506{
33507
33508 if(0 != gethostname(0, 0))
33509 return 1;
33510
33511 ;
33512 return 0;
33513}
33514
33515_ACEOF
33516if ac_fn_c_try_link "$LINENO"; then :
33517
33518 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33519$as_echo "yes" >&6; }
33520 tst_links_gethostname="yes"
33521
33522else
33523
33524 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33525$as_echo "no" >&6; }
33526 tst_links_gethostname="no"
33527
33528fi
33529rm -f core conftest.err conftest.$ac_objext \
33530 conftest$ac_exeext conftest.$ac_ext
33531 #
33532 if test "$tst_links_gethostname" = "yes"; then
33533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostname is prototyped" >&5
33534$as_echo_n "checking if gethostname is prototyped... " >&6; }
33535 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33536/* end confdefs.h. */
33537
33538 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070033539 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070033540 $curl_includes_unistd
33541
33542_ACEOF
33543if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
33544 $EGREP "gethostname" >/dev/null 2>&1; then :
33545
33546 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33547$as_echo "yes" >&6; }
33548 tst_proto_gethostname="yes"
33549
33550else
33551
33552 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33553$as_echo "no" >&6; }
33554 tst_proto_gethostname="no"
33555
33556fi
33557rm -f conftest*
33558
33559 fi
33560 #
33561 if test "$tst_proto_gethostname" = "yes"; then
33562 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostname is compilable" >&5
33563$as_echo_n "checking if gethostname is compilable... " >&6; }
33564 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33565/* end confdefs.h. */
33566
33567
33568 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070033569 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070033570 $curl_includes_unistd
33571
33572int main (void)
33573{
33574
33575 if(0 != gethostname(0, 0))
33576 return 1;
33577
33578 ;
33579 return 0;
33580}
33581
33582_ACEOF
33583if ac_fn_c_try_compile "$LINENO"; then :
33584
33585 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33586$as_echo "yes" >&6; }
33587 tst_compi_gethostname="yes"
33588
33589else
33590
33591 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33592$as_echo "no" >&6; }
33593 tst_compi_gethostname="no"
33594
33595fi
33596rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33597 fi
33598 #
33599 if test "$tst_compi_gethostname" = "yes"; then
33600 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostname arg 2 data type" >&5
33601$as_echo_n "checking for gethostname arg 2 data type... " >&6; }
33602 tst_gethostname_type_arg2="unknown"
33603 for tst_arg1 in 'char *' 'unsigned char *' 'void *'; do
33604 for tst_arg2 in 'int' 'unsigned int' 'size_t'; do
33605 if test "$tst_gethostname_type_arg2" = "unknown"; then
33606 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33607/* end confdefs.h. */
33608
33609
33610 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070033611 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070033612 $curl_includes_unistd
33613 $curl_preprocess_callconv
33614 extern int FUNCALLCONV gethostname($tst_arg1, $tst_arg2);
33615
33616int main (void)
33617{
33618
33619 if(0 != gethostname(0, 0))
33620 return 1;
33621
33622 ;
33623 return 0;
33624}
33625
33626_ACEOF
33627if ac_fn_c_try_compile "$LINENO"; then :
33628
33629 tst_gethostname_type_arg2="$tst_arg2"
33630
33631fi
33632rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33633 fi
33634 done
33635 done
33636 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tst_gethostname_type_arg2" >&5
33637$as_echo "$tst_gethostname_type_arg2" >&6; }
33638 if test "$tst_gethostname_type_arg2" != "unknown"; then
33639
33640cat >>confdefs.h <<_ACEOF
33641#define GETHOSTNAME_TYPE_ARG2 $tst_gethostname_type_arg2
33642_ACEOF
33643
33644 fi
33645 fi
33646 #
33647 if test "$tst_compi_gethostname" = "yes"; then
33648 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostname usage allowed" >&5
33649$as_echo_n "checking if gethostname usage allowed... " >&6; }
33650 if test "x$curl_disallow_gethostname" != "xyes"; then
33651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33652$as_echo "yes" >&6; }
33653 tst_allow_gethostname="yes"
33654 else
33655 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33656$as_echo "no" >&6; }
33657 tst_allow_gethostname="no"
33658 fi
33659 fi
33660 #
33661 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gethostname might be used" >&5
33662$as_echo_n "checking if gethostname might be used... " >&6; }
33663 if test "$tst_links_gethostname" = "yes" &&
33664 test "$tst_proto_gethostname" = "yes" &&
33665 test "$tst_compi_gethostname" = "yes" &&
33666 test "$tst_allow_gethostname" = "yes"; then
33667 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33668$as_echo "yes" >&6; }
33669
33670cat >>confdefs.h <<_ACEOF
33671#define HAVE_GETHOSTNAME 1
33672_ACEOF
33673
33674 curl_cv_func_gethostname="yes"
33675 else
33676 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33677$as_echo "no" >&6; }
33678 curl_cv_func_gethostname="no"
33679 fi
33680
33681
Haibo Huang34ab3462019-05-22 00:50:27 -070033682 #
33683 tst_links_getpeername="unknown"
33684 tst_proto_getpeername="unknown"
33685 tst_compi_getpeername="unknown"
33686 tst_allow_getpeername="unknown"
33687 #
33688 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getpeername can be linked" >&5
33689$as_echo_n "checking if getpeername can be linked... " >&6; }
33690 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33691/* end confdefs.h. */
33692
33693
33694 $curl_includes_winsock2
33695 $curl_includes_bsdsocket
33696 $curl_includes_sys_socket
33697
33698int main (void)
33699{
33700
33701 if(0 != getpeername(0, (void *)0, (void *)0))
33702 return 1;
33703
33704 ;
33705 return 0;
33706}
33707
33708_ACEOF
33709if ac_fn_c_try_link "$LINENO"; then :
33710
33711 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33712$as_echo "yes" >&6; }
33713 tst_links_getpeername="yes"
33714
33715else
33716
33717 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33718$as_echo "no" >&6; }
33719 tst_links_getpeername="no"
33720
33721fi
33722rm -f core conftest.err conftest.$ac_objext \
33723 conftest$ac_exeext conftest.$ac_ext
33724 #
33725 if test "$tst_links_getpeername" = "yes"; then
33726 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getpeername is prototyped" >&5
33727$as_echo_n "checking if getpeername is prototyped... " >&6; }
33728 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33729/* end confdefs.h. */
33730
33731 $curl_includes_winsock2
33732 $curl_includes_bsdsocket
33733 $curl_includes_sys_socket
33734
33735_ACEOF
33736if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
33737 $EGREP "getpeername" >/dev/null 2>&1; then :
33738
33739 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33740$as_echo "yes" >&6; }
33741 tst_proto_getpeername="yes"
33742
33743else
33744
33745 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33746$as_echo "no" >&6; }
33747 tst_proto_getpeername="no"
33748
33749fi
33750rm -f conftest*
33751
33752 fi
33753 #
33754 if test "$tst_proto_getpeername" = "yes"; then
33755 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getpeername is compilable" >&5
33756$as_echo_n "checking if getpeername is compilable... " >&6; }
33757 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33758/* end confdefs.h. */
33759
33760
33761 $curl_includes_winsock2
33762 $curl_includes_bsdsocket
33763 $curl_includes_sys_socket
33764
33765int main (void)
33766{
33767
33768 if(0 != getpeername(0, (void *)0, (void *)0))
33769 return 1;
33770
33771 ;
33772 return 0;
33773}
33774
33775_ACEOF
33776if ac_fn_c_try_compile "$LINENO"; then :
33777
33778 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33779$as_echo "yes" >&6; }
33780 tst_compi_getpeername="yes"
33781
33782else
33783
33784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33785$as_echo "no" >&6; }
33786 tst_compi_getpeername="no"
33787
33788fi
33789rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33790 fi
33791 #
33792 if test "$tst_compi_getpeername" = "yes"; then
33793 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getpeername usage allowed" >&5
33794$as_echo_n "checking if getpeername usage allowed... " >&6; }
33795 if test "x$curl_disallow_getpeername" != "xyes"; then
33796 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33797$as_echo "yes" >&6; }
33798 tst_allow_getpeername="yes"
33799 else
33800 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33801$as_echo "no" >&6; }
33802 tst_allow_getpeername="no"
33803 fi
33804 fi
33805 #
33806 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getpeername might be used" >&5
33807$as_echo_n "checking if getpeername might be used... " >&6; }
33808 if test "$tst_links_getpeername" = "yes" &&
33809 test "$tst_proto_getpeername" = "yes" &&
33810 test "$tst_compi_getpeername" = "yes" &&
33811 test "$tst_allow_getpeername" = "yes"; then
33812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33813$as_echo "yes" >&6; }
33814
33815cat >>confdefs.h <<_ACEOF
33816#define HAVE_GETPEERNAME 1
33817_ACEOF
33818
33819 curl_cv_func_getpeername="yes"
33820 else
33821 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33822$as_echo "no" >&6; }
33823 curl_cv_func_getpeername="no"
33824 fi
33825
33826
33827 #
33828 tst_links_getsockname="unknown"
33829 tst_proto_getsockname="unknown"
33830 tst_compi_getsockname="unknown"
33831 tst_allow_getsockname="unknown"
33832 #
33833 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getsockname can be linked" >&5
33834$as_echo_n "checking if getsockname can be linked... " >&6; }
33835 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33836/* end confdefs.h. */
33837
33838
33839 $curl_includes_winsock2
33840 $curl_includes_bsdsocket
33841 $curl_includes_sys_socket
33842
33843int main (void)
33844{
33845
33846 if(0 != getsockname(0, (void *)0, (void *)0))
33847 return 1;
33848
33849 ;
33850 return 0;
33851}
33852
33853_ACEOF
33854if ac_fn_c_try_link "$LINENO"; then :
33855
33856 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33857$as_echo "yes" >&6; }
33858 tst_links_getsockname="yes"
33859
33860else
33861
33862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33863$as_echo "no" >&6; }
33864 tst_links_getsockname="no"
33865
33866fi
33867rm -f core conftest.err conftest.$ac_objext \
33868 conftest$ac_exeext conftest.$ac_ext
33869 #
33870 if test "$tst_links_getsockname" = "yes"; then
33871 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getsockname is prototyped" >&5
33872$as_echo_n "checking if getsockname is prototyped... " >&6; }
33873 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33874/* end confdefs.h. */
33875
33876 $curl_includes_winsock2
33877 $curl_includes_bsdsocket
33878 $curl_includes_sys_socket
33879
33880_ACEOF
33881if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
33882 $EGREP "getsockname" >/dev/null 2>&1; then :
33883
33884 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33885$as_echo "yes" >&6; }
33886 tst_proto_getsockname="yes"
33887
33888else
33889
33890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33891$as_echo "no" >&6; }
33892 tst_proto_getsockname="no"
33893
33894fi
33895rm -f conftest*
33896
33897 fi
33898 #
33899 if test "$tst_proto_getsockname" = "yes"; then
33900 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getsockname is compilable" >&5
33901$as_echo_n "checking if getsockname is compilable... " >&6; }
33902 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33903/* end confdefs.h. */
33904
33905
33906 $curl_includes_winsock2
33907 $curl_includes_bsdsocket
33908 $curl_includes_sys_socket
33909
33910int main (void)
33911{
33912
33913 if(0 != getsockname(0, (void *)0, (void *)0))
33914 return 1;
33915
33916 ;
33917 return 0;
33918}
33919
33920_ACEOF
33921if ac_fn_c_try_compile "$LINENO"; then :
33922
33923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33924$as_echo "yes" >&6; }
33925 tst_compi_getsockname="yes"
33926
33927else
33928
33929 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33930$as_echo "no" >&6; }
33931 tst_compi_getsockname="no"
33932
33933fi
33934rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33935 fi
33936 #
33937 if test "$tst_compi_getsockname" = "yes"; then
33938 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getsockname usage allowed" >&5
33939$as_echo_n "checking if getsockname usage allowed... " >&6; }
33940 if test "x$curl_disallow_getsockname" != "xyes"; then
33941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33942$as_echo "yes" >&6; }
33943 tst_allow_getsockname="yes"
33944 else
33945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33946$as_echo "no" >&6; }
33947 tst_allow_getsockname="no"
33948 fi
33949 fi
33950 #
33951 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getsockname might be used" >&5
33952$as_echo_n "checking if getsockname might be used... " >&6; }
33953 if test "$tst_links_getsockname" = "yes" &&
33954 test "$tst_proto_getsockname" = "yes" &&
33955 test "$tst_compi_getsockname" = "yes" &&
33956 test "$tst_allow_getsockname" = "yes"; then
33957 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
33958$as_echo "yes" >&6; }
33959
33960cat >>confdefs.h <<_ACEOF
33961#define HAVE_GETSOCKNAME 1
33962_ACEOF
33963
33964 curl_cv_func_getsockname="yes"
33965 else
33966 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
33967$as_echo "no" >&6; }
33968 curl_cv_func_getsockname="no"
33969 fi
33970
33971
Haibo Huangb6336c12019-06-05 01:34:44 -070033972curl_includes_netif="\
33973/* includes start */
33974#ifdef HAVE_NET_IF_H
33975# include <net/if.h>
33976#endif
33977/* includes end */"
33978 for ac_header in net/if.h
33979do :
33980 ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "$curl_includes_netif
33981"
33982if test "x$ac_cv_header_net_if_h" = xyes; then :
33983 cat >>confdefs.h <<_ACEOF
33984#define HAVE_NET_IF_H 1
33985_ACEOF
33986
33987fi
33988
33989done
33990
33991
33992
33993 #
33994 tst_links_if_nametoindex="unknown"
33995 tst_proto_if_nametoindex="unknown"
33996 tst_compi_if_nametoindex="unknown"
33997 tst_allow_if_nametoindex="unknown"
33998 #
33999 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if if_nametoindex can be linked" >&5
34000$as_echo_n "checking if if_nametoindex can be linked... " >&6; }
34001 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34002/* end confdefs.h. */
34003
34004
34005 $curl_includes_winsock2
34006 $curl_includes_bsdsocket
34007 #include <net/if.h>
34008
34009int main (void)
34010{
34011
34012 if(0 != if_nametoindex(""))
34013 return 1;
34014
34015 ;
34016 return 0;
34017}
34018
34019_ACEOF
34020if ac_fn_c_try_link "$LINENO"; then :
34021
34022 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34023$as_echo "yes" >&6; }
34024 tst_links_if_nametoindex="yes"
34025
34026else
34027
34028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34029$as_echo "no" >&6; }
34030 tst_links_if_nametoindex="no"
34031
34032fi
34033rm -f core conftest.err conftest.$ac_objext \
34034 conftest$ac_exeext conftest.$ac_ext
34035 #
34036 if test "$tst_links_if_nametoindex" = "yes"; then
34037 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if if_nametoindex is prototyped" >&5
34038$as_echo_n "checking if if_nametoindex is prototyped... " >&6; }
34039 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34040/* end confdefs.h. */
34041
34042 $curl_includes_winsock2
34043 $curl_includes_netif
34044
34045_ACEOF
34046if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
34047 $EGREP "if_nametoindex" >/dev/null 2>&1; then :
34048
34049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34050$as_echo "yes" >&6; }
34051 tst_proto_if_nametoindex="yes"
34052
34053else
34054
34055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34056$as_echo "no" >&6; }
34057 tst_proto_if_nametoindex="no"
34058
34059fi
34060rm -f conftest*
34061
34062 fi
34063 #
34064 if test "$tst_proto_if_nametoindex" = "yes"; then
34065 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if if_nametoindex is compilable" >&5
34066$as_echo_n "checking if if_nametoindex is compilable... " >&6; }
34067 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34068/* end confdefs.h. */
34069
34070
34071 $curl_includes_winsock2
34072 $curl_includes_netif
34073
34074int main (void)
34075{
34076
34077 if(0 != if_nametoindex(""))
34078 return 1;
34079
34080 ;
34081 return 0;
34082}
34083
34084_ACEOF
34085if ac_fn_c_try_compile "$LINENO"; then :
34086
34087 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34088$as_echo "yes" >&6; }
34089 tst_compi_if_nametoindex="yes"
34090
34091else
34092
34093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34094$as_echo "no" >&6; }
34095 tst_compi_if_nametoindex="no"
34096
34097fi
34098rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
34099 fi
34100 #
34101 if test "$tst_compi_if_nametoindex" = "yes"; then
34102 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if if_nametoindex usage allowed" >&5
34103$as_echo_n "checking if if_nametoindex usage allowed... " >&6; }
34104 if test "x$curl_disallow_if_nametoindex" != "xyes"; then
34105 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34106$as_echo "yes" >&6; }
34107 tst_allow_if_nametoindex="yes"
34108 else
34109 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34110$as_echo "no" >&6; }
34111 tst_allow_if_nametoindex="no"
34112 fi
34113 fi
34114 #
34115 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if if_nametoindex might be used" >&5
34116$as_echo_n "checking if if_nametoindex might be used... " >&6; }
34117 if test "$tst_links_if_nametoindex" = "yes" &&
34118 test "$tst_proto_if_nametoindex" = "yes" &&
34119 test "$tst_compi_if_nametoindex" = "yes" &&
34120 test "$tst_allow_if_nametoindex" = "yes"; then
34121 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34122$as_echo "yes" >&6; }
34123
34124cat >>confdefs.h <<_ACEOF
34125#define HAVE_IF_NAMETOINDEX 1
34126_ACEOF
34127
34128 curl_cv_func_if_nametoindex="yes"
34129 else
34130 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34131$as_echo "no" >&6; }
34132 curl_cv_func_if_nametoindex="no"
34133 fi
34134
34135
Elliott Hughes82be86d2017-09-20 17:00:17 -070034136 #
34137 tst_links_getifaddrs="unknown"
34138 tst_proto_getifaddrs="unknown"
34139 tst_compi_getifaddrs="unknown"
34140 tst_works_getifaddrs="unknown"
34141 tst_allow_getifaddrs="unknown"
34142 #
34143 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getifaddrs can be linked" >&5
34144$as_echo_n "checking if getifaddrs can be linked... " >&6; }
34145 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34146/* end confdefs.h. */
34147
34148
34149#define getifaddrs innocuous_getifaddrs
34150#ifdef __STDC__
34151# include <limits.h>
34152#else
34153# include <assert.h>
34154#endif
34155#undef getifaddrs
34156#ifdef __cplusplus
34157extern "C"
34158#endif
34159char getifaddrs ();
34160#if defined __stub_getifaddrs || defined __stub___getifaddrs
34161choke me
34162#endif
34163
34164int main (void)
34165{
34166return getifaddrs ();
34167 ;
34168 return 0;
34169}
34170
34171_ACEOF
34172if ac_fn_c_try_link "$LINENO"; then :
34173
34174 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34175$as_echo "yes" >&6; }
34176 tst_links_getifaddrs="yes"
34177
34178else
34179
34180 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34181$as_echo "no" >&6; }
34182 tst_links_getifaddrs="no"
34183
34184fi
34185rm -f core conftest.err conftest.$ac_objext \
34186 conftest$ac_exeext conftest.$ac_ext
34187 #
34188 if test "$tst_links_getifaddrs" = "yes"; then
34189 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getifaddrs is prototyped" >&5
34190$as_echo_n "checking if getifaddrs is prototyped... " >&6; }
34191 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34192/* end confdefs.h. */
34193
34194 $curl_includes_ifaddrs
34195
34196_ACEOF
34197if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
34198 $EGREP "getifaddrs" >/dev/null 2>&1; then :
34199
34200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34201$as_echo "yes" >&6; }
34202 tst_proto_getifaddrs="yes"
34203
34204else
34205
34206 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34207$as_echo "no" >&6; }
34208 tst_proto_getifaddrs="no"
34209
34210fi
34211rm -f conftest*
34212
34213 fi
34214 #
34215 if test "$tst_proto_getifaddrs" = "yes"; then
34216 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getifaddrs is compilable" >&5
34217$as_echo_n "checking if getifaddrs is compilable... " >&6; }
34218 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34219/* end confdefs.h. */
34220
34221
34222 $curl_includes_ifaddrs
34223
34224int main (void)
34225{
34226
34227 if(0 != getifaddrs(0))
34228 return 1;
34229
34230 ;
34231 return 0;
34232}
34233
34234_ACEOF
34235if ac_fn_c_try_compile "$LINENO"; then :
34236
34237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34238$as_echo "yes" >&6; }
34239 tst_compi_getifaddrs="yes"
34240
34241else
34242
34243 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34244$as_echo "no" >&6; }
34245 tst_compi_getifaddrs="no"
34246
34247fi
34248rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
34249 fi
34250 #
34251 if test "x$cross_compiling" != "xyes" &&
34252 test "$tst_compi_getifaddrs" = "yes"; then
34253 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getifaddrs seems to work" >&5
34254$as_echo_n "checking if getifaddrs seems to work... " >&6; }
Elliott Hughesa93fb052018-12-12 14:22:48 -080034255
34256
34257 old=$LD_LIBRARY_PATH
34258 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
34259 export LD_LIBRARY_PATH
34260 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070034261 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
34262$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
34263as_fn_error $? "cannot run test program while cross compiling
34264See \`config.log' for more details" "$LINENO" 5; }
34265else
34266 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34267/* end confdefs.h. */
34268
34269
34270 $curl_includes_stdlib
34271 $curl_includes_ifaddrs
34272
34273int main (void)
34274{
34275
34276 struct ifaddrs *ifa = 0;
34277 int error;
34278
34279 error = getifaddrs(&ifa);
34280 if(error || !ifa)
34281 exit(1); /* fail */
34282 else
34283 exit(0);
34284
34285 ;
34286 return 0;
34287}
34288
34289_ACEOF
34290if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughesa93fb052018-12-12 14:22:48 -080034291 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070034292$as_echo "yes" >&6; }
34293 tst_works_getifaddrs="yes"
34294
34295else
Elliott Hughesa93fb052018-12-12 14:22:48 -080034296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070034297$as_echo "no" >&6; }
34298 tst_works_getifaddrs="no"
34299
34300fi
34301rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
34302 conftest.$ac_objext conftest.beam conftest.$ac_ext
34303fi
34304
Elliott Hughesa93fb052018-12-12 14:22:48 -080034305 LD_LIBRARY_PATH=$old # restore
34306
Elliott Hughes82be86d2017-09-20 17:00:17 -070034307 fi
34308 #
34309 if test "$tst_compi_getifaddrs" = "yes" &&
34310 test "$tst_works_getifaddrs" != "no"; then
34311 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getifaddrs usage allowed" >&5
34312$as_echo_n "checking if getifaddrs usage allowed... " >&6; }
34313 if test "x$curl_disallow_getifaddrs" != "xyes"; then
34314 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34315$as_echo "yes" >&6; }
34316 tst_allow_getifaddrs="yes"
34317 else
34318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34319$as_echo "no" >&6; }
34320 tst_allow_getifaddrs="no"
34321 fi
34322 fi
34323 #
34324 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getifaddrs might be used" >&5
34325$as_echo_n "checking if getifaddrs might be used... " >&6; }
34326 if test "$tst_links_getifaddrs" = "yes" &&
34327 test "$tst_proto_getifaddrs" = "yes" &&
34328 test "$tst_compi_getifaddrs" = "yes" &&
34329 test "$tst_allow_getifaddrs" = "yes" &&
34330 test "$tst_works_getifaddrs" != "no"; then
34331 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34332$as_echo "yes" >&6; }
34333
34334cat >>confdefs.h <<_ACEOF
34335#define HAVE_GETIFADDRS 1
34336_ACEOF
34337
34338 curl_cv_func_getifaddrs="yes"
34339 else
34340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34341$as_echo "no" >&6; }
34342 curl_cv_func_getifaddrs="no"
34343 fi
34344
34345
34346 #
34347 tst_links_getservbyport_r="unknown"
34348 tst_proto_getservbyport_r="unknown"
34349 tst_compi_getservbyport_r="unknown"
34350 tst_allow_getservbyport_r="unknown"
34351 tst_nargs_getservbyport_r="unknown"
34352 #
34353 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getservbyport_r can be linked" >&5
34354$as_echo_n "checking if getservbyport_r can be linked... " >&6; }
34355 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34356/* end confdefs.h. */
34357
34358
34359#define getservbyport_r innocuous_getservbyport_r
34360#ifdef __STDC__
34361# include <limits.h>
34362#else
34363# include <assert.h>
34364#endif
34365#undef getservbyport_r
34366#ifdef __cplusplus
34367extern "C"
34368#endif
34369char getservbyport_r ();
34370#if defined __stub_getservbyport_r || defined __stub___getservbyport_r
34371choke me
34372#endif
34373
34374int main (void)
34375{
34376return getservbyport_r ();
34377 ;
34378 return 0;
34379}
34380
34381_ACEOF
34382if ac_fn_c_try_link "$LINENO"; then :
34383
34384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34385$as_echo "yes" >&6; }
34386 tst_links_getservbyport_r="yes"
34387
34388else
34389
34390 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34391$as_echo "no" >&6; }
34392 tst_links_getservbyport_r="no"
34393
34394fi
34395rm -f core conftest.err conftest.$ac_objext \
34396 conftest$ac_exeext conftest.$ac_ext
34397 #
34398 if test "$tst_links_getservbyport_r" = "yes"; then
34399 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getservbyport_r is prototyped" >&5
34400$as_echo_n "checking if getservbyport_r is prototyped... " >&6; }
34401 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34402/* end confdefs.h. */
34403
34404 $curl_includes_netdb
34405
34406_ACEOF
34407if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
34408 $EGREP "getservbyport_r" >/dev/null 2>&1; then :
34409
34410 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34411$as_echo "yes" >&6; }
34412 tst_proto_getservbyport_r="yes"
34413
34414else
34415
34416 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34417$as_echo "no" >&6; }
34418 tst_proto_getservbyport_r="no"
34419
34420fi
34421rm -f conftest*
34422
34423 fi
34424 #
34425 if test "$tst_proto_getservbyport_r" = "yes"; then
34426 if test "$tst_nargs_getservbyport_r" = "unknown"; then
34427 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getservbyport_r takes 4 args." >&5
34428$as_echo_n "checking if getservbyport_r takes 4 args.... " >&6; }
34429 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34430/* end confdefs.h. */
34431
34432
34433 $curl_includes_netdb
34434
34435int main (void)
34436{
34437
34438 if(0 != getservbyport_r(0, 0, 0, 0))
34439 return 1;
34440
34441 ;
34442 return 0;
34443}
34444
34445_ACEOF
34446if ac_fn_c_try_compile "$LINENO"; then :
34447
34448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34449$as_echo "yes" >&6; }
34450 tst_compi_getservbyport_r="yes"
34451 tst_nargs_getservbyport_r="4"
34452
34453else
34454
34455 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34456$as_echo "no" >&6; }
34457 tst_compi_getservbyport_r="no"
34458
34459fi
34460rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
34461 fi
34462 if test "$tst_nargs_getservbyport_r" = "unknown"; then
34463 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getservbyport_r takes 5 args." >&5
34464$as_echo_n "checking if getservbyport_r takes 5 args.... " >&6; }
34465 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34466/* end confdefs.h. */
34467
34468
34469 $curl_includes_netdb
34470
34471int main (void)
34472{
34473
34474 if(0 != getservbyport_r(0, 0, 0, 0, 0))
34475 return 1;
34476
34477 ;
34478 return 0;
34479}
34480
34481_ACEOF
34482if ac_fn_c_try_compile "$LINENO"; then :
34483
34484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34485$as_echo "yes" >&6; }
34486 tst_compi_getservbyport_r="yes"
34487 tst_nargs_getservbyport_r="5"
34488
34489else
34490
34491 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34492$as_echo "no" >&6; }
34493 tst_compi_getservbyport_r="no"
34494
34495fi
34496rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
34497 fi
34498 if test "$tst_nargs_getservbyport_r" = "unknown"; then
34499 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getservbyport_r takes 6 args." >&5
34500$as_echo_n "checking if getservbyport_r takes 6 args.... " >&6; }
34501 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34502/* end confdefs.h. */
34503
34504
34505 $curl_includes_netdb
34506
34507int main (void)
34508{
34509
34510 if(0 != getservbyport_r(0, 0, 0, 0, 0, 0))
34511 return 1;
34512
34513 ;
34514 return 0;
34515}
34516
34517_ACEOF
34518if ac_fn_c_try_compile "$LINENO"; then :
34519
34520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34521$as_echo "yes" >&6; }
34522 tst_compi_getservbyport_r="yes"
34523 tst_nargs_getservbyport_r="6"
34524
34525else
34526
34527 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34528$as_echo "no" >&6; }
34529 tst_compi_getservbyport_r="no"
34530
34531fi
34532rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
34533 fi
34534 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getservbyport_r is compilable" >&5
34535$as_echo_n "checking if getservbyport_r is compilable... " >&6; }
34536 if test "$tst_compi_getservbyport_r" = "yes"; then
34537 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34538$as_echo "yes" >&6; }
34539 else
34540 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34541$as_echo "no" >&6; }
34542 fi
34543 fi
34544 #
34545 if test "$tst_compi_getservbyport_r" = "yes"; then
34546 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getservbyport_r usage allowed" >&5
34547$as_echo_n "checking if getservbyport_r usage allowed... " >&6; }
34548 if test "x$curl_disallow_getservbyport_r" != "xyes"; then
34549 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34550$as_echo "yes" >&6; }
34551 tst_allow_getservbyport_r="yes"
34552 else
34553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34554$as_echo "no" >&6; }
34555 tst_allow_getservbyport_r="no"
34556 fi
34557 fi
34558 #
34559 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getservbyport_r might be used" >&5
34560$as_echo_n "checking if getservbyport_r might be used... " >&6; }
34561 if test "$tst_links_getservbyport_r" = "yes" &&
34562 test "$tst_proto_getservbyport_r" = "yes" &&
34563 test "$tst_compi_getservbyport_r" = "yes" &&
34564 test "$tst_allow_getservbyport_r" = "yes"; then
34565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34566$as_echo "yes" >&6; }
34567
34568cat >>confdefs.h <<_ACEOF
34569#define HAVE_GETSERVBYPORT_R 1
34570_ACEOF
34571
34572
34573cat >>confdefs.h <<_ACEOF
34574#define GETSERVBYPORT_R_ARGS $tst_nargs_getservbyport_r
34575_ACEOF
34576
34577 if test "$tst_nargs_getservbyport_r" -eq "4"; then
34578
34579$as_echo "#define GETSERVBYPORT_R_BUFSIZE sizeof(struct servent_data)" >>confdefs.h
34580
34581 else
34582
34583$as_echo "#define GETSERVBYPORT_R_BUFSIZE 4096" >>confdefs.h
34584
34585 fi
34586 curl_cv_func_getservbyport_r="yes"
34587 else
34588 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34589$as_echo "no" >&6; }
34590 curl_cv_func_getservbyport_r="no"
34591 fi
34592
34593
34594curl_includes_time="\
34595/* includes start */
34596#ifdef HAVE_SYS_TYPES_H
34597# include <sys/types.h>
34598#endif
34599#ifdef HAVE_SYS_TIME_H
34600# include <sys/time.h>
34601# ifdef TIME_WITH_SYS_TIME
34602# include <time.h>
34603# endif
34604#else
34605# ifdef HAVE_TIME_H
34606# include <time.h>
34607# endif
34608#endif
34609/* includes end */"
34610 for ac_header in sys/types.h sys/time.h time.h
34611do :
34612 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
34613ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_time
34614"
34615if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
34616 cat >>confdefs.h <<_ACEOF
34617#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
34618_ACEOF
34619
34620fi
34621
34622done
34623
34624
34625
34626 #
34627 tst_links_gmtime_r="unknown"
34628 tst_proto_gmtime_r="unknown"
34629 tst_compi_gmtime_r="unknown"
34630 tst_works_gmtime_r="unknown"
34631 tst_allow_gmtime_r="unknown"
34632 #
34633 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gmtime_r can be linked" >&5
34634$as_echo_n "checking if gmtime_r can be linked... " >&6; }
34635 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34636/* end confdefs.h. */
34637
34638
34639#define gmtime_r innocuous_gmtime_r
34640#ifdef __STDC__
34641# include <limits.h>
34642#else
34643# include <assert.h>
34644#endif
34645#undef gmtime_r
34646#ifdef __cplusplus
34647extern "C"
34648#endif
34649char gmtime_r ();
34650#if defined __stub_gmtime_r || defined __stub___gmtime_r
34651choke me
34652#endif
34653
34654int main (void)
34655{
34656return gmtime_r ();
34657 ;
34658 return 0;
34659}
34660
34661_ACEOF
34662if ac_fn_c_try_link "$LINENO"; then :
34663
34664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34665$as_echo "yes" >&6; }
34666 tst_links_gmtime_r="yes"
34667
34668else
34669
34670 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34671$as_echo "no" >&6; }
34672 tst_links_gmtime_r="no"
34673
34674fi
34675rm -f core conftest.err conftest.$ac_objext \
34676 conftest$ac_exeext conftest.$ac_ext
34677 #
34678 if test "$tst_links_gmtime_r" = "yes"; then
34679 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gmtime_r is prototyped" >&5
34680$as_echo_n "checking if gmtime_r is prototyped... " >&6; }
34681 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34682/* end confdefs.h. */
34683
34684 $curl_includes_time
34685
34686_ACEOF
34687if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
34688 $EGREP "gmtime_r" >/dev/null 2>&1; then :
34689
34690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34691$as_echo "yes" >&6; }
34692 tst_proto_gmtime_r="yes"
34693
34694else
34695
34696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34697$as_echo "no" >&6; }
34698 tst_proto_gmtime_r="no"
34699
34700fi
34701rm -f conftest*
34702
34703 fi
34704 #
34705 if test "$tst_proto_gmtime_r" = "yes"; then
34706 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gmtime_r is compilable" >&5
34707$as_echo_n "checking if gmtime_r is compilable... " >&6; }
34708 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34709/* end confdefs.h. */
34710
34711
34712 $curl_includes_time
34713
34714int main (void)
34715{
34716
34717 if(0 != gmtime_r(0, 0))
34718 return 1;
34719
34720 ;
34721 return 0;
34722}
34723
34724_ACEOF
34725if ac_fn_c_try_compile "$LINENO"; then :
34726
34727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34728$as_echo "yes" >&6; }
34729 tst_compi_gmtime_r="yes"
34730
34731else
34732
34733 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34734$as_echo "no" >&6; }
34735 tst_compi_gmtime_r="no"
34736
34737fi
34738rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
34739 fi
34740 #
34741 if test "x$cross_compiling" != "xyes" &&
34742 test "$tst_compi_gmtime_r" = "yes"; then
34743 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gmtime_r seems to work" >&5
34744$as_echo_n "checking if gmtime_r seems to work... " >&6; }
Elliott Hughesa93fb052018-12-12 14:22:48 -080034745
34746
34747 old=$LD_LIBRARY_PATH
34748 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
34749 export LD_LIBRARY_PATH
34750 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070034751 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
34752$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
34753as_fn_error $? "cannot run test program while cross compiling
34754See \`config.log' for more details" "$LINENO" 5; }
34755else
34756 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34757/* end confdefs.h. */
34758
34759
34760 $curl_includes_stdlib
34761 $curl_includes_time
34762
34763int main (void)
34764{
34765
34766 time_t local = 1170352587;
34767 struct tm *gmt = 0;
34768 struct tm result;
34769 gmt = gmtime_r(&local, &result);
34770 if(gmt)
34771 exit(0);
34772 else
34773 exit(1);
34774
34775 ;
34776 return 0;
34777}
34778
34779_ACEOF
34780if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughesa93fb052018-12-12 14:22:48 -080034781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070034782$as_echo "yes" >&6; }
34783 tst_works_gmtime_r="yes"
34784
34785else
Elliott Hughesa93fb052018-12-12 14:22:48 -080034786 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070034787$as_echo "no" >&6; }
34788 tst_works_gmtime_r="no"
34789
34790fi
34791rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
34792 conftest.$ac_objext conftest.beam conftest.$ac_ext
34793fi
34794
Elliott Hughesa93fb052018-12-12 14:22:48 -080034795 LD_LIBRARY_PATH=$old # restore
34796
Elliott Hughes82be86d2017-09-20 17:00:17 -070034797 fi
34798 #
34799 if test "$tst_compi_gmtime_r" = "yes" &&
34800 test "$tst_works_gmtime_r" != "no"; then
34801 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gmtime_r usage allowed" >&5
34802$as_echo_n "checking if gmtime_r usage allowed... " >&6; }
34803 if test "x$curl_disallow_gmtime_r" != "xyes"; then
34804 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34805$as_echo "yes" >&6; }
34806 tst_allow_gmtime_r="yes"
34807 else
34808 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34809$as_echo "no" >&6; }
34810 tst_allow_gmtime_r="no"
34811 fi
34812 fi
34813 #
34814 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if gmtime_r might be used" >&5
34815$as_echo_n "checking if gmtime_r might be used... " >&6; }
34816 if test "$tst_links_gmtime_r" = "yes" &&
34817 test "$tst_proto_gmtime_r" = "yes" &&
34818 test "$tst_compi_gmtime_r" = "yes" &&
34819 test "$tst_allow_gmtime_r" = "yes" &&
34820 test "$tst_works_gmtime_r" != "no"; then
34821 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34822$as_echo "yes" >&6; }
34823
34824cat >>confdefs.h <<_ACEOF
34825#define HAVE_GMTIME_R 1
34826_ACEOF
34827
34828 curl_cv_func_gmtime_r="yes"
34829 else
34830 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34831$as_echo "no" >&6; }
34832 curl_cv_func_gmtime_r="no"
34833 fi
34834
34835
34836curl_includes_arpa_inet="\
34837/* includes start */
34838#ifdef HAVE_SYS_TYPES_H
34839# include <sys/types.h>
34840#endif
34841#ifdef HAVE_SYS_SOCKET_H
34842# include <sys/socket.h>
34843#endif
34844#ifdef HAVE_NETINET_IN_H
34845# include <netinet/in.h>
34846#endif
34847#ifdef HAVE_ARPA_INET_H
34848# include <arpa/inet.h>
34849#endif
34850#ifdef HAVE_WINSOCK2_H
34851#include <winsock2.h>
34852#include <ws2tcpip.h>
34853#endif
34854/* includes end */"
34855 for ac_header in sys/types.h sys/socket.h netinet/in.h arpa/inet.h
34856do :
34857 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
34858ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_arpa_inet
34859"
34860if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
34861 cat >>confdefs.h <<_ACEOF
34862#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
34863_ACEOF
34864
34865fi
34866
34867done
34868
34869
34870
34871 #
34872 tst_links_inet_ntoa_r="unknown"
34873 tst_proto_inet_ntoa_r="unknown"
34874 tst_compi_inet_ntoa_r="unknown"
34875 tst_allow_inet_ntoa_r="unknown"
34876 tst_nargs_inet_ntoa_r="unknown"
34877 #
34878 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_ntoa_r can be linked" >&5
34879$as_echo_n "checking if inet_ntoa_r can be linked... " >&6; }
34880 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34881/* end confdefs.h. */
34882
34883
34884#define inet_ntoa_r innocuous_inet_ntoa_r
34885#ifdef __STDC__
34886# include <limits.h>
34887#else
34888# include <assert.h>
34889#endif
34890#undef inet_ntoa_r
34891#ifdef __cplusplus
34892extern "C"
34893#endif
34894char inet_ntoa_r ();
34895#if defined __stub_inet_ntoa_r || defined __stub___inet_ntoa_r
34896choke me
34897#endif
34898
34899int main (void)
34900{
34901return inet_ntoa_r ();
34902 ;
34903 return 0;
34904}
34905
34906_ACEOF
34907if ac_fn_c_try_link "$LINENO"; then :
34908
34909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34910$as_echo "yes" >&6; }
34911 tst_links_inet_ntoa_r="yes"
34912
34913else
34914
34915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34916$as_echo "no" >&6; }
34917 tst_links_inet_ntoa_r="no"
34918
34919fi
34920rm -f core conftest.err conftest.$ac_objext \
34921 conftest$ac_exeext conftest.$ac_ext
34922 #
34923 if test "$tst_links_inet_ntoa_r" = "yes"; then
34924 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_ntoa_r is prototyped" >&5
34925$as_echo_n "checking if inet_ntoa_r is prototyped... " >&6; }
34926 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34927/* end confdefs.h. */
34928
34929 $curl_includes_arpa_inet
34930
34931_ACEOF
34932if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
34933 $EGREP "inet_ntoa_r" >/dev/null 2>&1; then :
34934
34935 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34936$as_echo "yes" >&6; }
34937 tst_proto_inet_ntoa_r="yes"
34938
34939else
34940
34941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34942$as_echo "no" >&6; }
34943 tst_proto_inet_ntoa_r="no"
34944
34945fi
34946rm -f conftest*
34947
34948 fi
34949 #
34950 if test "$tst_proto_inet_ntoa_r" = "yes"; then
34951 if test "$tst_nargs_inet_ntoa_r" = "unknown"; then
34952 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_ntoa_r takes 2 args." >&5
34953$as_echo_n "checking if inet_ntoa_r takes 2 args.... " >&6; }
34954 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34955/* end confdefs.h. */
34956
34957
34958 $curl_includes_arpa_inet
34959
34960int main (void)
34961{
34962
34963 struct in_addr addr;
34964 if(0 != inet_ntoa_r(addr, 0))
34965 return 1;
34966
34967 ;
34968 return 0;
34969}
34970
34971_ACEOF
34972if ac_fn_c_try_compile "$LINENO"; then :
34973
34974 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
34975$as_echo "yes" >&6; }
34976 tst_compi_inet_ntoa_r="yes"
34977 tst_nargs_inet_ntoa_r="2"
34978
34979else
34980
34981 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
34982$as_echo "no" >&6; }
34983 tst_compi_inet_ntoa_r="no"
34984
34985fi
34986rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
34987 fi
34988 if test "$tst_nargs_inet_ntoa_r" = "unknown"; then
34989 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_ntoa_r takes 3 args." >&5
34990$as_echo_n "checking if inet_ntoa_r takes 3 args.... " >&6; }
34991 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34992/* end confdefs.h. */
34993
34994
34995 $curl_includes_arpa_inet
34996
34997int main (void)
34998{
34999
35000 struct in_addr addr;
35001 if(0 != inet_ntoa_r(addr, 0, 0))
35002 return 1;
35003
35004 ;
35005 return 0;
35006}
35007
35008_ACEOF
35009if ac_fn_c_try_compile "$LINENO"; then :
35010
35011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35012$as_echo "yes" >&6; }
35013 tst_compi_inet_ntoa_r="yes"
35014 tst_nargs_inet_ntoa_r="3"
35015
35016else
35017
35018 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35019$as_echo "no" >&6; }
35020 tst_compi_inet_ntoa_r="no"
35021
35022fi
35023rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
35024 fi
35025 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_ntoa_r is compilable" >&5
35026$as_echo_n "checking if inet_ntoa_r is compilable... " >&6; }
35027 if test "$tst_compi_inet_ntoa_r" = "yes"; then
35028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35029$as_echo "yes" >&6; }
35030 else
35031 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35032$as_echo "no" >&6; }
35033 fi
35034 fi
35035 #
35036 if test "$tst_compi_inet_ntoa_r" = "yes"; then
35037 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_ntoa_r usage allowed" >&5
35038$as_echo_n "checking if inet_ntoa_r usage allowed... " >&6; }
35039 if test "x$curl_disallow_inet_ntoa_r" != "xyes"; then
35040 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35041$as_echo "yes" >&6; }
35042 tst_allow_inet_ntoa_r="yes"
35043 else
35044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35045$as_echo "no" >&6; }
35046 tst_allow_inet_ntoa_r="no"
35047 fi
35048 fi
35049 #
35050 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_ntoa_r might be used" >&5
35051$as_echo_n "checking if inet_ntoa_r might be used... " >&6; }
35052 if test "$tst_links_inet_ntoa_r" = "yes" &&
35053 test "$tst_proto_inet_ntoa_r" = "yes" &&
35054 test "$tst_compi_inet_ntoa_r" = "yes" &&
35055 test "$tst_allow_inet_ntoa_r" = "yes"; then
35056 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35057$as_echo "yes" >&6; }
35058
35059cat >>confdefs.h <<_ACEOF
35060#define HAVE_INET_NTOA_R 1
35061_ACEOF
35062
35063 #
35064 if test "$tst_nargs_inet_ntoa_r" -eq "2"; then
35065
35066$as_echo "#define HAVE_INET_NTOA_R_2 1" >>confdefs.h
35067
35068 elif test "$tst_nargs_inet_ntoa_r" -eq "3"; then
35069
35070$as_echo "#define HAVE_INET_NTOA_R_3 1" >>confdefs.h
35071
35072 fi
35073 #
35074 curl_cv_func_inet_ntoa_r="yes"
35075 else
35076 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35077$as_echo "no" >&6; }
35078 curl_cv_func_inet_ntoa_r="no"
35079 fi
35080
35081
35082 #
35083 tst_links_inet_ntop="unknown"
35084 tst_proto_inet_ntop="unknown"
35085 tst_compi_inet_ntop="unknown"
35086 tst_works_inet_ntop="unknown"
35087 tst_allow_inet_ntop="unknown"
35088 #
35089 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_ntop can be linked" >&5
35090$as_echo_n "checking if inet_ntop can be linked... " >&6; }
35091 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35092/* end confdefs.h. */
35093
35094
35095#define inet_ntop innocuous_inet_ntop
35096#ifdef __STDC__
35097# include <limits.h>
35098#else
35099# include <assert.h>
35100#endif
35101#undef inet_ntop
35102#ifdef __cplusplus
35103extern "C"
35104#endif
35105char inet_ntop ();
35106#if defined __stub_inet_ntop || defined __stub___inet_ntop
35107choke me
35108#endif
35109
35110int main (void)
35111{
35112return inet_ntop ();
35113 ;
35114 return 0;
35115}
35116
35117_ACEOF
35118if ac_fn_c_try_link "$LINENO"; then :
35119
35120 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35121$as_echo "yes" >&6; }
35122 tst_links_inet_ntop="yes"
35123
35124else
35125
35126 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35127$as_echo "no" >&6; }
35128 tst_links_inet_ntop="no"
35129
35130fi
35131rm -f core conftest.err conftest.$ac_objext \
35132 conftest$ac_exeext conftest.$ac_ext
35133 #
35134 if test "$tst_links_inet_ntop" = "yes"; then
35135 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_ntop is prototyped" >&5
35136$as_echo_n "checking if inet_ntop is prototyped... " >&6; }
35137 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35138/* end confdefs.h. */
35139
35140 $curl_includes_arpa_inet
35141
35142_ACEOF
35143if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
35144 $EGREP "inet_ntop" >/dev/null 2>&1; then :
35145
35146 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35147$as_echo "yes" >&6; }
35148 tst_proto_inet_ntop="yes"
35149
35150else
35151
35152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35153$as_echo "no" >&6; }
35154 tst_proto_inet_ntop="no"
35155
35156fi
35157rm -f conftest*
35158
35159 fi
35160 #
35161 if test "$tst_proto_inet_ntop" = "yes"; then
35162 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_ntop is compilable" >&5
35163$as_echo_n "checking if inet_ntop is compilable... " >&6; }
35164 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35165/* end confdefs.h. */
35166
35167
35168 $curl_includes_arpa_inet
35169
35170int main (void)
35171{
35172
35173 if(0 != inet_ntop(0, 0, 0, 0))
35174 return 1;
35175
35176 ;
35177 return 0;
35178}
35179
35180_ACEOF
35181if ac_fn_c_try_compile "$LINENO"; then :
35182
35183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35184$as_echo "yes" >&6; }
35185 tst_compi_inet_ntop="yes"
35186
35187else
35188
35189 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35190$as_echo "no" >&6; }
35191 tst_compi_inet_ntop="no"
35192
35193fi
35194rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
35195 fi
35196 #
35197 if test "x$cross_compiling" != "xyes" &&
35198 test "$tst_compi_inet_ntop" = "yes"; then
35199 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_ntop seems to work" >&5
35200$as_echo_n "checking if inet_ntop seems to work... " >&6; }
Elliott Hughesa93fb052018-12-12 14:22:48 -080035201
35202
35203 old=$LD_LIBRARY_PATH
35204 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
35205 export LD_LIBRARY_PATH
35206 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070035207 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
35208$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
35209as_fn_error $? "cannot run test program while cross compiling
35210See \`config.log' for more details" "$LINENO" 5; }
35211else
35212 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35213/* end confdefs.h. */
35214
35215
35216 $curl_includes_stdlib
35217 $curl_includes_arpa_inet
35218 $curl_includes_string
35219
35220int main (void)
35221{
35222
35223 char ipv6res[sizeof("ffff:ffff:ffff:ffff:ffff:ffff:255.255.255.255")];
35224 char ipv4res[sizeof "255.255.255.255"];
35225 unsigned char ipv6a[26];
35226 unsigned char ipv4a[5];
35227 char *ipv6ptr = 0;
35228 char *ipv4ptr = 0;
35229 /* - */
35230 ipv4res[0] = '\0';
35231 ipv4a[0] = 0xc0;
35232 ipv4a[1] = 0xa8;
35233 ipv4a[2] = 0x64;
35234 ipv4a[3] = 0x01;
35235 ipv4a[4] = 0x01;
35236 /* - */
35237 ipv4ptr = inet_ntop(AF_INET, ipv4a, ipv4res, sizeof(ipv4res));
35238 if(!ipv4ptr)
35239 exit(1); /* fail */
35240 if(ipv4ptr != ipv4res)
35241 exit(1); /* fail */
35242 if(!ipv4ptr[0])
35243 exit(1); /* fail */
35244 if(memcmp(ipv4res, "192.168.100.1", 13) != 0)
35245 exit(1); /* fail */
35246 /* - */
35247 ipv6res[0] = '\0';
35248 memset(ipv6a, 0, sizeof(ipv6a));
35249 ipv6a[0] = 0xfe;
35250 ipv6a[1] = 0x80;
35251 ipv6a[8] = 0x02;
35252 ipv6a[9] = 0x14;
35253 ipv6a[10] = 0x4f;
35254 ipv6a[11] = 0xff;
35255 ipv6a[12] = 0xfe;
35256 ipv6a[13] = 0x0b;
35257 ipv6a[14] = 0x76;
35258 ipv6a[15] = 0xc8;
35259 ipv6a[25] = 0x01;
35260 /* - */
35261 ipv6ptr = inet_ntop(AF_INET6, ipv6a, ipv6res, sizeof(ipv6res));
35262 if(!ipv6ptr)
35263 exit(1); /* fail */
35264 if(ipv6ptr != ipv6res)
35265 exit(1); /* fail */
35266 if(!ipv6ptr[0])
35267 exit(1); /* fail */
35268 if(memcmp(ipv6res, "fe80::214:4fff:fe0b:76c8", 24) != 0)
35269 exit(1); /* fail */
35270 /* - */
35271 exit(0);
35272
35273 ;
35274 return 0;
35275}
35276
35277_ACEOF
35278if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughesa93fb052018-12-12 14:22:48 -080035279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070035280$as_echo "yes" >&6; }
35281 tst_works_inet_ntop="yes"
35282
35283else
Elliott Hughesa93fb052018-12-12 14:22:48 -080035284 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070035285$as_echo "no" >&6; }
35286 tst_works_inet_ntop="no"
35287
35288fi
35289rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
35290 conftest.$ac_objext conftest.beam conftest.$ac_ext
35291fi
35292
Elliott Hughesa93fb052018-12-12 14:22:48 -080035293 LD_LIBRARY_PATH=$old # restore
35294
Elliott Hughes82be86d2017-09-20 17:00:17 -070035295 fi
35296 #
35297 if test "$tst_compi_inet_ntop" = "yes" &&
35298 test "$tst_works_inet_ntop" != "no"; then
35299 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_ntop usage allowed" >&5
35300$as_echo_n "checking if inet_ntop usage allowed... " >&6; }
35301 if test "x$curl_disallow_inet_ntop" != "xyes"; then
35302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35303$as_echo "yes" >&6; }
35304 tst_allow_inet_ntop="yes"
35305 else
35306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35307$as_echo "no" >&6; }
35308 tst_allow_inet_ntop="no"
35309 fi
35310 fi
35311 #
35312 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_ntop might be used" >&5
35313$as_echo_n "checking if inet_ntop might be used... " >&6; }
35314 if test "$tst_links_inet_ntop" = "yes" &&
35315 test "$tst_proto_inet_ntop" = "yes" &&
35316 test "$tst_compi_inet_ntop" = "yes" &&
35317 test "$tst_allow_inet_ntop" = "yes" &&
35318 test "$tst_works_inet_ntop" != "no"; then
35319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35320$as_echo "yes" >&6; }
35321
35322cat >>confdefs.h <<_ACEOF
35323#define HAVE_INET_NTOP 1
35324_ACEOF
35325
35326 curl_cv_func_inet_ntop="yes"
35327 else
35328 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35329$as_echo "no" >&6; }
35330 curl_cv_func_inet_ntop="no"
35331 fi
35332
35333
35334 #
35335 tst_links_inet_pton="unknown"
35336 tst_proto_inet_pton="unknown"
35337 tst_compi_inet_pton="unknown"
35338 tst_works_inet_pton="unknown"
35339 tst_allow_inet_pton="unknown"
35340 #
35341 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_pton can be linked" >&5
35342$as_echo_n "checking if inet_pton can be linked... " >&6; }
35343 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35344/* end confdefs.h. */
35345
35346
35347#define inet_pton innocuous_inet_pton
35348#ifdef __STDC__
35349# include <limits.h>
35350#else
35351# include <assert.h>
35352#endif
35353#undef inet_pton
35354#ifdef __cplusplus
35355extern "C"
35356#endif
35357char inet_pton ();
35358#if defined __stub_inet_pton || defined __stub___inet_pton
35359choke me
35360#endif
35361
35362int main (void)
35363{
35364return inet_pton ();
35365 ;
35366 return 0;
35367}
35368
35369_ACEOF
35370if ac_fn_c_try_link "$LINENO"; then :
35371
35372 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35373$as_echo "yes" >&6; }
35374 tst_links_inet_pton="yes"
35375
35376else
35377
35378 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35379$as_echo "no" >&6; }
35380 tst_links_inet_pton="no"
35381
35382fi
35383rm -f core conftest.err conftest.$ac_objext \
35384 conftest$ac_exeext conftest.$ac_ext
35385 #
35386 if test "$tst_links_inet_pton" = "yes"; then
35387 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_pton is prototyped" >&5
35388$as_echo_n "checking if inet_pton is prototyped... " >&6; }
35389 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35390/* end confdefs.h. */
35391
35392 $curl_includes_arpa_inet
35393
35394_ACEOF
35395if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
35396 $EGREP "inet_pton" >/dev/null 2>&1; then :
35397
35398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35399$as_echo "yes" >&6; }
35400 tst_proto_inet_pton="yes"
35401
35402else
35403
35404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35405$as_echo "no" >&6; }
35406 tst_proto_inet_pton="no"
35407
35408fi
35409rm -f conftest*
35410
35411 fi
35412 #
35413 if test "$tst_proto_inet_pton" = "yes"; then
35414 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_pton is compilable" >&5
35415$as_echo_n "checking if inet_pton is compilable... " >&6; }
35416 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35417/* end confdefs.h. */
35418
35419
35420 $curl_includes_arpa_inet
35421
35422int main (void)
35423{
35424
35425 if(0 != inet_pton(0, 0, 0))
35426 return 1;
35427
35428 ;
35429 return 0;
35430}
35431
35432_ACEOF
35433if ac_fn_c_try_compile "$LINENO"; then :
35434
35435 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35436$as_echo "yes" >&6; }
35437 tst_compi_inet_pton="yes"
35438
35439else
35440
35441 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35442$as_echo "no" >&6; }
35443 tst_compi_inet_pton="no"
35444
35445fi
35446rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
35447 fi
35448 #
35449 if test "x$cross_compiling" != "xyes" &&
35450 test "$tst_compi_inet_pton" = "yes"; then
35451 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_pton seems to work" >&5
35452$as_echo_n "checking if inet_pton seems to work... " >&6; }
Elliott Hughesa93fb052018-12-12 14:22:48 -080035453
35454
35455 old=$LD_LIBRARY_PATH
35456 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
35457 export LD_LIBRARY_PATH
35458 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070035459 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
35460$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
35461as_fn_error $? "cannot run test program while cross compiling
35462See \`config.log' for more details" "$LINENO" 5; }
35463else
35464 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35465/* end confdefs.h. */
35466
35467
35468 $curl_includes_stdlib
35469 $curl_includes_arpa_inet
35470 $curl_includes_string
35471
35472int main (void)
35473{
35474
35475 unsigned char ipv6a[16+1];
35476 unsigned char ipv4a[4+1];
35477 const char *ipv6src = "fe80::214:4fff:fe0b:76c8";
35478 const char *ipv4src = "192.168.100.1";
35479 /* - */
35480 memset(ipv4a, 1, sizeof(ipv4a));
35481 if(1 != inet_pton(AF_INET, ipv4src, ipv4a))
35482 exit(1); /* fail */
35483 /* - */
35484 if( (ipv4a[0] != 0xc0) ||
35485 (ipv4a[1] != 0xa8) ||
35486 (ipv4a[2] != 0x64) ||
35487 (ipv4a[3] != 0x01) ||
35488 (ipv4a[4] != 0x01) )
35489 exit(1); /* fail */
35490 /* - */
35491 memset(ipv6a, 1, sizeof(ipv6a));
35492 if(1 != inet_pton(AF_INET6, ipv6src, ipv6a))
35493 exit(1); /* fail */
35494 /* - */
35495 if( (ipv6a[0] != 0xfe) ||
35496 (ipv6a[1] != 0x80) ||
35497 (ipv6a[8] != 0x02) ||
35498 (ipv6a[9] != 0x14) ||
35499 (ipv6a[10] != 0x4f) ||
35500 (ipv6a[11] != 0xff) ||
35501 (ipv6a[12] != 0xfe) ||
35502 (ipv6a[13] != 0x0b) ||
35503 (ipv6a[14] != 0x76) ||
35504 (ipv6a[15] != 0xc8) ||
35505 (ipv6a[16] != 0x01) )
35506 exit(1); /* fail */
35507 /* - */
35508 if( (ipv6a[2] != 0x0) ||
35509 (ipv6a[3] != 0x0) ||
35510 (ipv6a[4] != 0x0) ||
35511 (ipv6a[5] != 0x0) ||
35512 (ipv6a[6] != 0x0) ||
35513 (ipv6a[7] != 0x0) )
35514 exit(1); /* fail */
35515 /* - */
35516 exit(0);
35517
35518 ;
35519 return 0;
35520}
35521
35522_ACEOF
35523if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughesa93fb052018-12-12 14:22:48 -080035524 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070035525$as_echo "yes" >&6; }
35526 tst_works_inet_pton="yes"
35527
35528else
Elliott Hughesa93fb052018-12-12 14:22:48 -080035529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070035530$as_echo "no" >&6; }
35531 tst_works_inet_pton="no"
35532
35533fi
35534rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
35535 conftest.$ac_objext conftest.beam conftest.$ac_ext
35536fi
35537
Elliott Hughesa93fb052018-12-12 14:22:48 -080035538 LD_LIBRARY_PATH=$old # restore
35539
Elliott Hughes82be86d2017-09-20 17:00:17 -070035540 fi
35541 #
35542 if test "$tst_compi_inet_pton" = "yes" &&
35543 test "$tst_works_inet_pton" != "no"; then
35544 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_pton usage allowed" >&5
35545$as_echo_n "checking if inet_pton usage allowed... " >&6; }
35546 if test "x$curl_disallow_inet_pton" != "xyes"; then
35547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35548$as_echo "yes" >&6; }
35549 tst_allow_inet_pton="yes"
35550 else
35551 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35552$as_echo "no" >&6; }
35553 tst_allow_inet_pton="no"
35554 fi
35555 fi
35556 #
35557 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if inet_pton might be used" >&5
35558$as_echo_n "checking if inet_pton might be used... " >&6; }
35559 if test "$tst_links_inet_pton" = "yes" &&
35560 test "$tst_proto_inet_pton" = "yes" &&
35561 test "$tst_compi_inet_pton" = "yes" &&
35562 test "$tst_allow_inet_pton" = "yes" &&
35563 test "$tst_works_inet_pton" != "no"; then
35564 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35565$as_echo "yes" >&6; }
35566
35567cat >>confdefs.h <<_ACEOF
35568#define HAVE_INET_PTON 1
35569_ACEOF
35570
35571 curl_cv_func_inet_pton="yes"
35572 else
35573 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35574$as_echo "no" >&6; }
35575 curl_cv_func_inet_pton="no"
35576 fi
35577
35578
35579curl_includes_stropts="\
35580/* includes start */
35581#ifdef HAVE_SYS_TYPES_H
35582# include <sys/types.h>
35583#endif
35584#ifdef HAVE_UNISTD_H
35585# include <unistd.h>
35586#endif
35587#ifdef HAVE_SYS_SOCKET_H
35588# include <sys/socket.h>
35589#endif
35590#ifdef HAVE_SYS_IOCTL_H
35591# include <sys/ioctl.h>
35592#endif
35593#ifdef HAVE_STROPTS_H
35594# include <stropts.h>
35595#endif
35596/* includes end */"
35597 for ac_header in sys/types.h unistd.h sys/socket.h sys/ioctl.h stropts.h
35598do :
35599 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
35600ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_stropts
35601"
35602if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
35603 cat >>confdefs.h <<_ACEOF
35604#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
35605_ACEOF
35606
35607fi
35608
35609done
35610
35611
35612
35613 #
35614 tst_links_ioctl="unknown"
35615 tst_proto_ioctl="unknown"
35616 tst_compi_ioctl="unknown"
35617 tst_allow_ioctl="unknown"
35618 #
35619 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctl can be linked" >&5
35620$as_echo_n "checking if ioctl can be linked... " >&6; }
35621 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35622/* end confdefs.h. */
35623
35624
35625#define ioctl innocuous_ioctl
35626#ifdef __STDC__
35627# include <limits.h>
35628#else
35629# include <assert.h>
35630#endif
35631#undef ioctl
35632#ifdef __cplusplus
35633extern "C"
35634#endif
35635char ioctl ();
35636#if defined __stub_ioctl || defined __stub___ioctl
35637choke me
35638#endif
35639
35640int main (void)
35641{
35642return ioctl ();
35643 ;
35644 return 0;
35645}
35646
35647_ACEOF
35648if ac_fn_c_try_link "$LINENO"; then :
35649
35650 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35651$as_echo "yes" >&6; }
35652 tst_links_ioctl="yes"
35653
35654else
35655
35656 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35657$as_echo "no" >&6; }
35658 tst_links_ioctl="no"
35659
35660fi
35661rm -f core conftest.err conftest.$ac_objext \
35662 conftest$ac_exeext conftest.$ac_ext
35663 #
35664 if test "$tst_links_ioctl" = "yes"; then
35665 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctl is prototyped" >&5
35666$as_echo_n "checking if ioctl is prototyped... " >&6; }
35667 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35668/* end confdefs.h. */
35669
35670 $curl_includes_stropts
35671
35672_ACEOF
35673if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
35674 $EGREP "ioctl" >/dev/null 2>&1; then :
35675
35676 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35677$as_echo "yes" >&6; }
35678 tst_proto_ioctl="yes"
35679
35680else
35681
35682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35683$as_echo "no" >&6; }
35684 tst_proto_ioctl="no"
35685
35686fi
35687rm -f conftest*
35688
35689 fi
35690 #
35691 if test "$tst_proto_ioctl" = "yes"; then
35692 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctl is compilable" >&5
35693$as_echo_n "checking if ioctl is compilable... " >&6; }
35694 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35695/* end confdefs.h. */
35696
35697
35698 $curl_includes_stropts
35699
35700int main (void)
35701{
35702
35703 if(0 != ioctl(0, 0, 0))
35704 return 1;
35705
35706 ;
35707 return 0;
35708}
35709
35710_ACEOF
35711if ac_fn_c_try_compile "$LINENO"; then :
35712
35713 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35714$as_echo "yes" >&6; }
35715 tst_compi_ioctl="yes"
35716
35717else
35718
35719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35720$as_echo "no" >&6; }
35721 tst_compi_ioctl="no"
35722
35723fi
35724rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
35725 fi
35726 #
35727 if test "$tst_compi_ioctl" = "yes"; then
35728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctl usage allowed" >&5
35729$as_echo_n "checking if ioctl usage allowed... " >&6; }
35730 if test "x$curl_disallow_ioctl" != "xyes"; then
35731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35732$as_echo "yes" >&6; }
35733 tst_allow_ioctl="yes"
35734 else
35735 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35736$as_echo "no" >&6; }
35737 tst_allow_ioctl="no"
35738 fi
35739 fi
35740 #
35741 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctl might be used" >&5
35742$as_echo_n "checking if ioctl might be used... " >&6; }
35743 if test "$tst_links_ioctl" = "yes" &&
35744 test "$tst_proto_ioctl" = "yes" &&
35745 test "$tst_compi_ioctl" = "yes" &&
35746 test "$tst_allow_ioctl" = "yes"; then
35747 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35748$as_echo "yes" >&6; }
35749
35750cat >>confdefs.h <<_ACEOF
35751#define HAVE_IOCTL 1
35752_ACEOF
35753
35754 curl_cv_func_ioctl="yes"
35755
35756 #
35757 tst_compi_ioctl_fionbio="unknown"
35758 tst_allow_ioctl_fionbio="unknown"
35759 #
35760 if test "$curl_cv_func_ioctl" = "yes"; then
35761 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctl FIONBIO is compilable" >&5
35762$as_echo_n "checking if ioctl FIONBIO is compilable... " >&6; }
35763 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35764/* end confdefs.h. */
35765
35766
35767 $curl_includes_stropts
35768
35769int main (void)
35770{
35771
35772 int flags = 0;
35773 if(0 != ioctl(0, FIONBIO, &flags))
35774 return 1;
35775
35776 ;
35777 return 0;
35778}
35779
35780_ACEOF
35781if ac_fn_c_try_compile "$LINENO"; then :
35782
35783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35784$as_echo "yes" >&6; }
35785 tst_compi_ioctl_fionbio="yes"
35786
35787else
35788
35789 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35790$as_echo "no" >&6; }
35791 tst_compi_ioctl_fionbio="no"
35792
35793fi
35794rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
35795 fi
35796 #
35797 if test "$tst_compi_ioctl_fionbio" = "yes"; then
35798 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctl FIONBIO usage allowed" >&5
35799$as_echo_n "checking if ioctl FIONBIO usage allowed... " >&6; }
35800 if test "x$curl_disallow_ioctl_fionbio" != "xyes"; then
35801 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35802$as_echo "yes" >&6; }
35803 tst_allow_ioctl_fionbio="yes"
35804 else
35805 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35806$as_echo "no" >&6; }
35807 tst_allow_ioctl_fionbio="no"
35808 fi
35809 fi
35810 #
35811 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctl FIONBIO might be used" >&5
35812$as_echo_n "checking if ioctl FIONBIO might be used... " >&6; }
35813 if test "$tst_compi_ioctl_fionbio" = "yes" &&
35814 test "$tst_allow_ioctl_fionbio" = "yes"; then
35815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35816$as_echo "yes" >&6; }
35817
35818cat >>confdefs.h <<_ACEOF
35819#define HAVE_IOCTL_FIONBIO 1
35820_ACEOF
35821
35822 curl_cv_func_ioctl_fionbio="yes"
35823 else
35824 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35825$as_echo "no" >&6; }
35826 curl_cv_func_ioctl_fionbio="no"
35827 fi
35828
35829
35830 #
35831 tst_compi_ioctl_siocgifaddr="unknown"
35832 tst_allow_ioctl_siocgifaddr="unknown"
35833 #
35834 if test "$curl_cv_func_ioctl" = "yes"; then
35835 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctl SIOCGIFADDR is compilable" >&5
35836$as_echo_n "checking if ioctl SIOCGIFADDR is compilable... " >&6; }
35837 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35838/* end confdefs.h. */
35839
35840
35841 $curl_includes_stropts
35842 #include <net/if.h>
35843
35844int main (void)
35845{
35846
35847 struct ifreq ifr;
35848 if(0 != ioctl(0, SIOCGIFADDR, &ifr))
35849 return 1;
35850
35851 ;
35852 return 0;
35853}
35854
35855_ACEOF
35856if ac_fn_c_try_compile "$LINENO"; then :
35857
35858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35859$as_echo "yes" >&6; }
35860 tst_compi_ioctl_siocgifaddr="yes"
35861
35862else
35863
35864 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35865$as_echo "no" >&6; }
35866 tst_compi_ioctl_siocgifaddr="no"
35867
35868fi
35869rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
35870 fi
35871 #
35872 if test "$tst_compi_ioctl_siocgifaddr" = "yes"; then
35873 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctl SIOCGIFADDR usage allowed" >&5
35874$as_echo_n "checking if ioctl SIOCGIFADDR usage allowed... " >&6; }
35875 if test "x$curl_disallow_ioctl_siocgifaddr" != "xyes"; then
35876 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35877$as_echo "yes" >&6; }
35878 tst_allow_ioctl_siocgifaddr="yes"
35879 else
35880 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35881$as_echo "no" >&6; }
35882 tst_allow_ioctl_siocgifaddr="no"
35883 fi
35884 fi
35885 #
35886 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctl SIOCGIFADDR might be used" >&5
35887$as_echo_n "checking if ioctl SIOCGIFADDR might be used... " >&6; }
35888 if test "$tst_compi_ioctl_siocgifaddr" = "yes" &&
35889 test "$tst_allow_ioctl_siocgifaddr" = "yes"; then
35890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35891$as_echo "yes" >&6; }
35892
35893cat >>confdefs.h <<_ACEOF
35894#define HAVE_IOCTL_SIOCGIFADDR 1
35895_ACEOF
35896
35897 curl_cv_func_ioctl_siocgifaddr="yes"
35898 else
35899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35900$as_echo "no" >&6; }
35901 curl_cv_func_ioctl_siocgifaddr="no"
35902 fi
35903
35904 else
35905 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35906$as_echo "no" >&6; }
35907 curl_cv_func_ioctl="no"
35908 fi
35909
35910
35911 #
35912 tst_links_ioctlsocket="unknown"
35913 tst_proto_ioctlsocket="unknown"
35914 tst_compi_ioctlsocket="unknown"
35915 tst_allow_ioctlsocket="unknown"
35916 #
35917 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctlsocket can be linked" >&5
35918$as_echo_n "checking if ioctlsocket can be linked... " >&6; }
35919 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35920/* end confdefs.h. */
35921
35922
35923 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070035924 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070035925
35926int main (void)
35927{
35928
35929 if(0 != ioctlsocket(0, 0, 0))
35930 return 1;
35931
35932 ;
35933 return 0;
35934}
35935
35936_ACEOF
35937if ac_fn_c_try_link "$LINENO"; then :
35938
35939 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35940$as_echo "yes" >&6; }
35941 tst_links_ioctlsocket="yes"
35942
35943else
35944
35945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35946$as_echo "no" >&6; }
35947 tst_links_ioctlsocket="no"
35948
35949fi
35950rm -f core conftest.err conftest.$ac_objext \
35951 conftest$ac_exeext conftest.$ac_ext
35952 #
35953 if test "$tst_links_ioctlsocket" = "yes"; then
35954 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctlsocket is prototyped" >&5
35955$as_echo_n "checking if ioctlsocket is prototyped... " >&6; }
35956 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35957/* end confdefs.h. */
35958
35959 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070035960 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070035961
35962_ACEOF
35963if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
35964 $EGREP "ioctlsocket" >/dev/null 2>&1; then :
35965
35966 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
35967$as_echo "yes" >&6; }
35968 tst_proto_ioctlsocket="yes"
35969
35970else
35971
35972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
35973$as_echo "no" >&6; }
35974 tst_proto_ioctlsocket="no"
35975
35976fi
35977rm -f conftest*
35978
35979 fi
35980 #
35981 if test "$tst_proto_ioctlsocket" = "yes"; then
35982 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctlsocket is compilable" >&5
35983$as_echo_n "checking if ioctlsocket is compilable... " >&6; }
35984 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35985/* end confdefs.h. */
35986
35987
35988 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070035989 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070035990
35991int main (void)
35992{
35993
35994 if(0 != ioctlsocket(0, 0, 0))
35995 return 1;
35996
35997 ;
35998 return 0;
35999}
36000
36001_ACEOF
36002if ac_fn_c_try_compile "$LINENO"; then :
36003
36004 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36005$as_echo "yes" >&6; }
36006 tst_compi_ioctlsocket="yes"
36007
36008else
36009
36010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36011$as_echo "no" >&6; }
36012 tst_compi_ioctlsocket="no"
36013
36014fi
36015rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
36016 fi
36017 #
36018 if test "$tst_compi_ioctlsocket" = "yes"; then
36019 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctlsocket usage allowed" >&5
36020$as_echo_n "checking if ioctlsocket usage allowed... " >&6; }
36021 if test "x$curl_disallow_ioctlsocket" != "xyes"; then
36022 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36023$as_echo "yes" >&6; }
36024 tst_allow_ioctlsocket="yes"
36025 else
36026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36027$as_echo "no" >&6; }
36028 tst_allow_ioctlsocket="no"
36029 fi
36030 fi
36031 #
36032 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctlsocket might be used" >&5
36033$as_echo_n "checking if ioctlsocket might be used... " >&6; }
36034 if test "$tst_links_ioctlsocket" = "yes" &&
36035 test "$tst_proto_ioctlsocket" = "yes" &&
36036 test "$tst_compi_ioctlsocket" = "yes" &&
36037 test "$tst_allow_ioctlsocket" = "yes"; then
36038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36039$as_echo "yes" >&6; }
36040
36041cat >>confdefs.h <<_ACEOF
36042#define HAVE_IOCTLSOCKET 1
36043_ACEOF
36044
36045 curl_cv_func_ioctlsocket="yes"
36046
36047 #
36048 tst_compi_ioctlsocket_fionbio="unknown"
36049 tst_allow_ioctlsocket_fionbio="unknown"
36050 #
36051 if test "$curl_cv_func_ioctlsocket" = "yes"; then
36052 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctlsocket FIONBIO is compilable" >&5
36053$as_echo_n "checking if ioctlsocket FIONBIO is compilable... " >&6; }
36054 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36055/* end confdefs.h. */
36056
36057
36058 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070036059 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070036060
36061int main (void)
36062{
36063
36064 int flags = 0;
36065 if(0 != ioctlsocket(0, FIONBIO, &flags))
36066 return 1;
36067
36068 ;
36069 return 0;
36070}
36071
36072_ACEOF
36073if ac_fn_c_try_compile "$LINENO"; then :
36074
36075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36076$as_echo "yes" >&6; }
36077 tst_compi_ioctlsocket_fionbio="yes"
36078
36079else
36080
36081 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36082$as_echo "no" >&6; }
36083 tst_compi_ioctlsocket_fionbio="no"
36084
36085fi
36086rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
36087 fi
36088 #
36089 if test "$tst_compi_ioctlsocket_fionbio" = "yes"; then
36090 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctlsocket FIONBIO usage allowed" >&5
36091$as_echo_n "checking if ioctlsocket FIONBIO usage allowed... " >&6; }
36092 if test "x$curl_disallow_ioctlsocket_fionbio" != "xyes"; then
36093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36094$as_echo "yes" >&6; }
36095 tst_allow_ioctlsocket_fionbio="yes"
36096 else
36097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36098$as_echo "no" >&6; }
36099 tst_allow_ioctlsocket_fionbio="no"
36100 fi
36101 fi
36102 #
36103 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ioctlsocket FIONBIO might be used" >&5
36104$as_echo_n "checking if ioctlsocket FIONBIO might be used... " >&6; }
36105 if test "$tst_compi_ioctlsocket_fionbio" = "yes" &&
36106 test "$tst_allow_ioctlsocket_fionbio" = "yes"; then
36107 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36108$as_echo "yes" >&6; }
36109
36110cat >>confdefs.h <<_ACEOF
36111#define HAVE_IOCTLSOCKET_FIONBIO 1
36112_ACEOF
36113
36114 curl_cv_func_ioctlsocket_fionbio="yes"
36115 else
36116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36117$as_echo "no" >&6; }
36118 curl_cv_func_ioctlsocket_fionbio="no"
36119 fi
36120
36121 else
36122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36123$as_echo "no" >&6; }
36124 curl_cv_func_ioctlsocket="no"
36125 fi
36126
36127
36128 #
36129 tst_links_ioctlsocket_camel="unknown"
36130 tst_proto_ioctlsocket_camel="unknown"
36131 tst_compi_ioctlsocket_camel="unknown"
36132 tst_allow_ioctlsocket_camel="unknown"
36133 #
36134 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if IoctlSocket can be linked" >&5
36135$as_echo_n "checking if IoctlSocket can be linked... " >&6; }
36136 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36137/* end confdefs.h. */
36138
36139
36140#define IoctlSocket innocuous_IoctlSocket
36141#ifdef __STDC__
36142# include <limits.h>
36143#else
36144# include <assert.h>
36145#endif
36146#undef IoctlSocket
36147#ifdef __cplusplus
36148extern "C"
36149#endif
36150char IoctlSocket ();
36151#if defined __stub_IoctlSocket || defined __stub___IoctlSocket
36152choke me
36153#endif
36154
36155int main (void)
36156{
36157return IoctlSocket ();
36158 ;
36159 return 0;
36160}
36161
36162_ACEOF
36163if ac_fn_c_try_link "$LINENO"; then :
36164
36165 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36166$as_echo "yes" >&6; }
36167 tst_links_ioctlsocket_camel="yes"
36168
36169else
36170
36171 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36172$as_echo "no" >&6; }
36173 tst_links_ioctlsocket_camel="no"
36174
36175fi
36176rm -f core conftest.err conftest.$ac_objext \
36177 conftest$ac_exeext conftest.$ac_ext
36178 #
36179 if test "$tst_links_ioctlsocket_camel" = "yes"; then
36180 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if IoctlSocket is prototyped" >&5
36181$as_echo_n "checking if IoctlSocket is prototyped... " >&6; }
36182 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36183/* end confdefs.h. */
36184
36185 $curl_includes_stropts
36186
36187_ACEOF
36188if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
36189 $EGREP "IoctlSocket" >/dev/null 2>&1; then :
36190
36191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36192$as_echo "yes" >&6; }
36193 tst_proto_ioctlsocket_camel="yes"
36194
36195else
36196
36197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36198$as_echo "no" >&6; }
36199 tst_proto_ioctlsocket_camel="no"
36200
36201fi
36202rm -f conftest*
36203
36204 fi
36205 #
36206 if test "$tst_proto_ioctlsocket_camel" = "yes"; then
36207 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if IoctlSocket is compilable" >&5
36208$as_echo_n "checking if IoctlSocket is compilable... " >&6; }
36209 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36210/* end confdefs.h. */
36211
36212
36213 $curl_includes_stropts
36214
36215int main (void)
36216{
36217
36218 if(0 != IoctlSocket(0, 0, 0))
36219 return 1;
36220
36221 ;
36222 return 0;
36223}
36224
36225_ACEOF
36226if ac_fn_c_try_compile "$LINENO"; then :
36227
36228 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36229$as_echo "yes" >&6; }
36230 tst_compi_ioctlsocket_camel="yes"
36231
36232else
36233
36234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36235$as_echo "no" >&6; }
36236 tst_compi_ioctlsocket_camel="no"
36237
36238fi
36239rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
36240 fi
36241 #
36242 if test "$tst_compi_ioctlsocket_camel" = "yes"; then
36243 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if IoctlSocket usage allowed" >&5
36244$as_echo_n "checking if IoctlSocket usage allowed... " >&6; }
36245 if test "x$curl_disallow_ioctlsocket_camel" != "xyes"; then
36246 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36247$as_echo "yes" >&6; }
36248 tst_allow_ioctlsocket_camel="yes"
36249 else
36250 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36251$as_echo "no" >&6; }
36252 tst_allow_ioctlsocket_camel="no"
36253 fi
36254 fi
36255 #
36256 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if IoctlSocket might be used" >&5
36257$as_echo_n "checking if IoctlSocket might be used... " >&6; }
36258 if test "$tst_links_ioctlsocket_camel" = "yes" &&
36259 test "$tst_proto_ioctlsocket_camel" = "yes" &&
36260 test "$tst_compi_ioctlsocket_camel" = "yes" &&
36261 test "$tst_allow_ioctlsocket_camel" = "yes"; then
36262 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36263$as_echo "yes" >&6; }
36264
36265cat >>confdefs.h <<_ACEOF
36266#define HAVE_IOCTLSOCKET_CAMEL 1
36267_ACEOF
36268
36269 curl_cv_func_ioctlsocket_camel="yes"
36270
36271 #
36272 tst_compi_ioctlsocket_camel_fionbio="unknown"
36273 tst_allow_ioctlsocket_camel_fionbio="unknown"
36274 #
36275 if test "$curl_cv_func_ioctlsocket_camel" = "yes"; then
36276 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if IoctlSocket FIONBIO is compilable" >&5
36277$as_echo_n "checking if IoctlSocket FIONBIO is compilable... " >&6; }
36278 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36279/* end confdefs.h. */
36280
36281
36282 $curl_includes_stropts
36283
36284int main (void)
36285{
36286
36287 long flags = 0;
36288 if(0 != ioctlsocket(0, FIONBIO, &flags))
36289 return 1;
36290
36291 ;
36292 return 0;
36293}
36294
36295_ACEOF
36296if ac_fn_c_try_compile "$LINENO"; then :
36297
36298 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36299$as_echo "yes" >&6; }
36300 tst_compi_ioctlsocket_camel_fionbio="yes"
36301
36302else
36303
36304 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36305$as_echo "no" >&6; }
36306 tst_compi_ioctlsocket_camel_fionbio="no"
36307
36308fi
36309rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
36310 fi
36311 #
36312 if test "$tst_compi_ioctlsocket_camel_fionbio" = "yes"; then
36313 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if IoctlSocket FIONBIO usage allowed" >&5
36314$as_echo_n "checking if IoctlSocket FIONBIO usage allowed... " >&6; }
36315 if test "x$curl_disallow_ioctlsocket_camel_fionbio" != "xyes"; then
36316 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36317$as_echo "yes" >&6; }
36318 tst_allow_ioctlsocket_camel_fionbio="yes"
36319 else
36320 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36321$as_echo "no" >&6; }
36322 tst_allow_ioctlsocket_camel_fionbio="no"
36323 fi
36324 fi
36325 #
36326 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if IoctlSocket FIONBIO might be used" >&5
36327$as_echo_n "checking if IoctlSocket FIONBIO might be used... " >&6; }
36328 if test "$tst_compi_ioctlsocket_camel_fionbio" = "yes" &&
36329 test "$tst_allow_ioctlsocket_camel_fionbio" = "yes"; then
36330 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36331$as_echo "yes" >&6; }
36332
36333cat >>confdefs.h <<_ACEOF
36334#define HAVE_IOCTLSOCKET_CAMEL_FIONBIO 1
36335_ACEOF
36336
36337 curl_cv_func_ioctlsocket_camel_fionbio="yes"
36338 else
36339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36340$as_echo "no" >&6; }
36341 curl_cv_func_ioctlsocket_camel_fionbio="no"
36342 fi
36343
36344 else
36345 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36346$as_echo "no" >&6; }
36347 curl_cv_func_ioctlsocket_camel="no"
36348 fi
36349
36350
36351 #
36352 tst_links_localtime_r="unknown"
36353 tst_proto_localtime_r="unknown"
36354 tst_compi_localtime_r="unknown"
36355 tst_works_localtime_r="unknown"
36356 tst_allow_localtime_r="unknown"
36357 #
36358 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if localtime_r can be linked" >&5
36359$as_echo_n "checking if localtime_r can be linked... " >&6; }
36360 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36361/* end confdefs.h. */
36362
36363
36364#define localtime_r innocuous_localtime_r
36365#ifdef __STDC__
36366# include <limits.h>
36367#else
36368# include <assert.h>
36369#endif
36370#undef localtime_r
36371#ifdef __cplusplus
36372extern "C"
36373#endif
36374char localtime_r ();
36375#if defined __stub_localtime_r || defined __stub___localtime_r
36376choke me
36377#endif
36378
36379int main (void)
36380{
36381return localtime_r ();
36382 ;
36383 return 0;
36384}
36385
36386_ACEOF
36387if ac_fn_c_try_link "$LINENO"; then :
36388
36389 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36390$as_echo "yes" >&6; }
36391 tst_links_localtime_r="yes"
36392
36393else
36394
36395 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36396$as_echo "no" >&6; }
36397 tst_links_localtime_r="no"
36398
36399fi
36400rm -f core conftest.err conftest.$ac_objext \
36401 conftest$ac_exeext conftest.$ac_ext
36402 #
36403 if test "$tst_links_localtime_r" = "yes"; then
36404 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if localtime_r is prototyped" >&5
36405$as_echo_n "checking if localtime_r is prototyped... " >&6; }
36406 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36407/* end confdefs.h. */
36408
36409 $curl_includes_time
36410
36411_ACEOF
36412if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
36413 $EGREP "localtime_r" >/dev/null 2>&1; then :
36414
36415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36416$as_echo "yes" >&6; }
36417 tst_proto_localtime_r="yes"
36418
36419else
36420
36421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36422$as_echo "no" >&6; }
36423 tst_proto_localtime_r="no"
36424
36425fi
36426rm -f conftest*
36427
36428 fi
36429 #
36430 if test "$tst_proto_localtime_r" = "yes"; then
36431 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if localtime_r is compilable" >&5
36432$as_echo_n "checking if localtime_r is compilable... " >&6; }
36433 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36434/* end confdefs.h. */
36435
36436
36437 $curl_includes_time
36438
36439int main (void)
36440{
36441
36442 if(0 != localtime_r(0, 0))
36443 return 1;
36444
36445 ;
36446 return 0;
36447}
36448
36449_ACEOF
36450if ac_fn_c_try_compile "$LINENO"; then :
36451
36452 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36453$as_echo "yes" >&6; }
36454 tst_compi_localtime_r="yes"
36455
36456else
36457
36458 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36459$as_echo "no" >&6; }
36460 tst_compi_localtime_r="no"
36461
36462fi
36463rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
36464 fi
36465 #
36466 if test "x$cross_compiling" != "xyes" &&
36467 test "$tst_compi_localtime_r" = "yes"; then
36468 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if localtime_r seems to work" >&5
36469$as_echo_n "checking if localtime_r seems to work... " >&6; }
Elliott Hughesa93fb052018-12-12 14:22:48 -080036470
36471
36472 old=$LD_LIBRARY_PATH
36473 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
36474 export LD_LIBRARY_PATH
36475 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070036476 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
36477$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
36478as_fn_error $? "cannot run test program while cross compiling
36479See \`config.log' for more details" "$LINENO" 5; }
36480else
36481 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36482/* end confdefs.h. */
36483
36484
36485 $curl_includes_stdlib
36486 $curl_includes_time
36487
36488int main (void)
36489{
36490
36491 time_t clock = 1170352587;
36492 struct tm *tmp = 0;
36493 struct tm result;
36494 tmp = localtime_r(&clock, &result);
36495 if(tmp)
36496 exit(0);
36497 else
36498 exit(1);
36499
36500 ;
36501 return 0;
36502}
36503
36504_ACEOF
36505if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughesa93fb052018-12-12 14:22:48 -080036506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070036507$as_echo "yes" >&6; }
36508 tst_works_localtime_r="yes"
36509
36510else
Elliott Hughesa93fb052018-12-12 14:22:48 -080036511 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070036512$as_echo "no" >&6; }
36513 tst_works_localtime_r="no"
36514
36515fi
36516rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
36517 conftest.$ac_objext conftest.beam conftest.$ac_ext
36518fi
36519
Elliott Hughesa93fb052018-12-12 14:22:48 -080036520 LD_LIBRARY_PATH=$old # restore
36521
Elliott Hughes82be86d2017-09-20 17:00:17 -070036522 fi
36523 #
36524 if test "$tst_compi_localtime_r" = "yes" &&
36525 test "$tst_works_localtime_r" != "no"; then
36526 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if localtime_r usage allowed" >&5
36527$as_echo_n "checking if localtime_r usage allowed... " >&6; }
36528 if test "x$curl_disallow_localtime_r" != "xyes"; then
36529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36530$as_echo "yes" >&6; }
36531 tst_allow_localtime_r="yes"
36532 else
36533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36534$as_echo "no" >&6; }
36535 tst_allow_localtime_r="no"
36536 fi
36537 fi
36538 #
36539 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if localtime_r might be used" >&5
36540$as_echo_n "checking if localtime_r might be used... " >&6; }
36541 if test "$tst_links_localtime_r" = "yes" &&
36542 test "$tst_proto_localtime_r" = "yes" &&
36543 test "$tst_compi_localtime_r" = "yes" &&
36544 test "$tst_allow_localtime_r" = "yes" &&
36545 test "$tst_works_localtime_r" != "no"; then
36546 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36547$as_echo "yes" >&6; }
36548
36549cat >>confdefs.h <<_ACEOF
36550#define HAVE_LOCALTIME_R 1
36551_ACEOF
36552
36553 curl_cv_func_localtime_r="yes"
36554 else
36555 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36556$as_echo "no" >&6; }
36557 curl_cv_func_localtime_r="no"
36558 fi
36559
36560
36561 #
36562 tst_links_memrchr="unknown"
36563 tst_macro_memrchr="unknown"
36564 tst_proto_memrchr="unknown"
36565 tst_compi_memrchr="unknown"
36566 tst_allow_memrchr="unknown"
36567 #
36568 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if memrchr can be linked" >&5
36569$as_echo_n "checking if memrchr can be linked... " >&6; }
36570 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36571/* end confdefs.h. */
36572
36573
36574#define memrchr innocuous_memrchr
36575#ifdef __STDC__
36576# include <limits.h>
36577#else
36578# include <assert.h>
36579#endif
36580#undef memrchr
36581#ifdef __cplusplus
36582extern "C"
36583#endif
36584char memrchr ();
36585#if defined __stub_memrchr || defined __stub___memrchr
36586choke me
36587#endif
36588
36589int main (void)
36590{
36591return memrchr ();
36592 ;
36593 return 0;
36594}
36595
36596_ACEOF
36597if ac_fn_c_try_link "$LINENO"; then :
36598
36599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36600$as_echo "yes" >&6; }
36601 tst_links_memrchr="yes"
36602
36603else
36604
36605 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36606$as_echo "no" >&6; }
36607 tst_links_memrchr="no"
36608
36609fi
36610rm -f core conftest.err conftest.$ac_objext \
36611 conftest$ac_exeext conftest.$ac_ext
36612 #
36613 if test "$tst_links_memrchr" = "no"; then
36614 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if memrchr seems a macro" >&5
36615$as_echo_n "checking if memrchr seems a macro... " >&6; }
36616 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36617/* end confdefs.h. */
36618
36619
36620 $curl_includes_string
36621
36622int main (void)
36623{
36624
36625 if(0 != memrchr(0, 0, 0))
36626 return 1;
36627
36628 ;
36629 return 0;
36630}
36631
36632_ACEOF
36633if ac_fn_c_try_link "$LINENO"; then :
36634
36635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36636$as_echo "yes" >&6; }
36637 tst_macro_memrchr="yes"
36638
36639else
36640
36641 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36642$as_echo "no" >&6; }
36643 tst_macro_memrchr="no"
36644
36645fi
36646rm -f core conftest.err conftest.$ac_objext \
36647 conftest$ac_exeext conftest.$ac_ext
36648 fi
36649 #
36650 if test "$tst_links_memrchr" = "yes"; then
36651 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if memrchr is prototyped" >&5
36652$as_echo_n "checking if memrchr is prototyped... " >&6; }
36653 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36654/* end confdefs.h. */
36655
36656 $curl_includes_string
36657
36658_ACEOF
36659if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
36660 $EGREP "memrchr" >/dev/null 2>&1; then :
36661
36662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36663$as_echo "yes" >&6; }
36664 tst_proto_memrchr="yes"
36665
36666else
36667
36668 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36669$as_echo "no" >&6; }
36670 tst_proto_memrchr="no"
36671
36672fi
36673rm -f conftest*
36674
36675 fi
36676 #
36677 if test "$tst_proto_memrchr" = "yes" ||
36678 test "$tst_macro_memrchr" = "yes"; then
36679 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if memrchr is compilable" >&5
36680$as_echo_n "checking if memrchr is compilable... " >&6; }
36681 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36682/* end confdefs.h. */
36683
36684
36685 $curl_includes_string
36686
36687int main (void)
36688{
36689
36690 if(0 != memrchr(0, 0, 0))
36691 return 1;
36692
36693 ;
36694 return 0;
36695}
36696
36697_ACEOF
36698if ac_fn_c_try_compile "$LINENO"; then :
36699
36700 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36701$as_echo "yes" >&6; }
36702 tst_compi_memrchr="yes"
36703
36704else
36705
36706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36707$as_echo "no" >&6; }
36708 tst_compi_memrchr="no"
36709
36710fi
36711rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
36712 fi
36713 #
36714 if test "$tst_compi_memrchr" = "yes"; then
36715 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if memrchr usage allowed" >&5
36716$as_echo_n "checking if memrchr usage allowed... " >&6; }
36717 if test "x$curl_disallow_memrchr" != "xyes"; then
36718 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36719$as_echo "yes" >&6; }
36720 tst_allow_memrchr="yes"
36721 else
36722 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36723$as_echo "no" >&6; }
36724 tst_allow_memrchr="no"
36725 fi
36726 fi
36727 #
36728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if memrchr might be used" >&5
36729$as_echo_n "checking if memrchr might be used... " >&6; }
36730 if (test "$tst_proto_memrchr" = "yes" ||
36731 test "$tst_macro_memrchr" = "yes") &&
36732 test "$tst_compi_memrchr" = "yes" &&
36733 test "$tst_allow_memrchr" = "yes"; then
36734 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36735$as_echo "yes" >&6; }
36736
36737cat >>confdefs.h <<_ACEOF
36738#define HAVE_MEMRCHR 1
36739_ACEOF
36740
36741 curl_cv_func_memrchr="yes"
36742 else
36743 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36744$as_echo "no" >&6; }
36745 curl_cv_func_memrchr="no"
36746 fi
36747
36748
36749 #
36750 tst_links_poll="unknown"
36751 tst_proto_poll="unknown"
36752 tst_compi_poll="unknown"
36753 tst_works_poll="unknown"
36754 tst_allow_poll="unknown"
36755 #
36756 case $host_os in
36757 darwin*|interix*)
36758 curl_disallow_poll="yes"
36759 tst_compi_poll="no"
36760 ;;
36761 esac
36762 #
36763 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if poll can be linked" >&5
36764$as_echo_n "checking if poll can be linked... " >&6; }
36765 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36766/* end confdefs.h. */
36767
36768
36769 $curl_includes_poll
36770
36771int main (void)
36772{
36773
36774 if(0 != poll(0, 0, 0))
36775 return 1;
36776
36777 ;
36778 return 0;
36779}
36780
36781_ACEOF
36782if ac_fn_c_try_link "$LINENO"; then :
36783
36784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36785$as_echo "yes" >&6; }
36786 tst_links_poll="yes"
36787
36788else
36789
36790 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36791$as_echo "no" >&6; }
36792 tst_links_poll="no"
36793
36794fi
36795rm -f core conftest.err conftest.$ac_objext \
36796 conftest$ac_exeext conftest.$ac_ext
36797 #
36798 if test "$tst_links_poll" = "yes"; then
36799 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if poll is prototyped" >&5
36800$as_echo_n "checking if poll is prototyped... " >&6; }
36801 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36802/* end confdefs.h. */
36803
36804 $curl_includes_poll
36805
36806_ACEOF
36807if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
36808 $EGREP "poll" >/dev/null 2>&1; then :
36809
36810 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36811$as_echo "yes" >&6; }
36812 tst_proto_poll="yes"
36813
36814else
36815
36816 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36817$as_echo "no" >&6; }
36818 tst_proto_poll="no"
36819
36820fi
36821rm -f conftest*
36822
36823 fi
36824 #
36825 if test "$tst_proto_poll" = "yes"; then
36826 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if poll is compilable" >&5
36827$as_echo_n "checking if poll is compilable... " >&6; }
36828 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36829/* end confdefs.h. */
36830
36831
36832 $curl_includes_poll
36833
36834int main (void)
36835{
36836
36837 if(0 != poll(0, 0, 0))
36838 return 1;
36839
36840 ;
36841 return 0;
36842}
36843
36844_ACEOF
36845if ac_fn_c_try_compile "$LINENO"; then :
36846
36847 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36848$as_echo "yes" >&6; }
36849 tst_compi_poll="yes"
36850
36851else
36852
36853 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36854$as_echo "no" >&6; }
36855 tst_compi_poll="no"
36856
36857fi
36858rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
36859 fi
36860 #
36861 if test "x$cross_compiling" != "xyes" &&
36862 test "$tst_compi_poll" = "yes"; then
36863 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if poll seems to work" >&5
36864$as_echo_n "checking if poll seems to work... " >&6; }
Elliott Hughesa93fb052018-12-12 14:22:48 -080036865
36866
36867 old=$LD_LIBRARY_PATH
36868 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
36869 export LD_LIBRARY_PATH
36870 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070036871 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
36872$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
36873as_fn_error $? "cannot run test program while cross compiling
36874See \`config.log' for more details" "$LINENO" 5; }
36875else
36876 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36877/* end confdefs.h. */
36878
36879
36880 $curl_includes_stdlib
36881 $curl_includes_poll
36882 $curl_includes_time
36883
36884int main (void)
36885{
36886
36887 /* detect the original poll() breakage */
36888 if(0 != poll(0, 0, 10))
36889 exit(1); /* fail */
36890 else {
36891 /* detect the 10.12 poll() breakage */
36892 struct timeval before, after;
36893 int rc;
36894 size_t us;
36895
36896 gettimeofday(&before, NULL);
36897 rc = poll(NULL, 0, 500);
36898 gettimeofday(&after, NULL);
36899
36900 us = (after.tv_sec - before.tv_sec) * 1000000 +
36901 (after.tv_usec - before.tv_usec);
36902
36903 if(us < 400000)
36904 exit(1);
36905 }
36906
36907 ;
36908 return 0;
36909}
36910
36911_ACEOF
36912if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughesa93fb052018-12-12 14:22:48 -080036913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070036914$as_echo "yes" >&6; }
36915 tst_works_poll="yes"
36916
36917else
Elliott Hughesa93fb052018-12-12 14:22:48 -080036918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070036919$as_echo "no" >&6; }
36920 tst_works_poll="no"
36921
36922fi
36923rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
36924 conftest.$ac_objext conftest.beam conftest.$ac_ext
36925fi
36926
Elliott Hughesa93fb052018-12-12 14:22:48 -080036927 LD_LIBRARY_PATH=$old # restore
36928
Elliott Hughes82be86d2017-09-20 17:00:17 -070036929 fi
36930 #
36931 if test "$tst_compi_poll" = "yes" &&
36932 test "$tst_works_poll" != "no"; then
36933 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if poll usage allowed" >&5
36934$as_echo_n "checking if poll usage allowed... " >&6; }
36935 if test "x$curl_disallow_poll" != "xyes"; then
36936 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36937$as_echo "yes" >&6; }
36938 tst_allow_poll="yes"
36939 else
36940 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36941$as_echo "no" >&6; }
36942 tst_allow_poll="no"
36943 fi
36944 fi
36945 #
36946 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if poll might be used" >&5
36947$as_echo_n "checking if poll might be used... " >&6; }
36948 if test "$tst_links_poll" = "yes" &&
36949 test "$tst_proto_poll" = "yes" &&
36950 test "$tst_compi_poll" = "yes" &&
36951 test "$tst_allow_poll" = "yes" &&
36952 test "$tst_works_poll" != "no"; then
36953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
36954$as_echo "yes" >&6; }
36955
36956cat >>confdefs.h <<_ACEOF
36957#define HAVE_POLL 1
36958_ACEOF
36959
36960
36961cat >>confdefs.h <<_ACEOF
36962#define HAVE_POLL_FINE 1
36963_ACEOF
36964
36965 curl_cv_func_poll="yes"
36966 else
36967 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
36968$as_echo "no" >&6; }
36969 curl_cv_func_poll="no"
36970 fi
36971
36972
36973 #
36974 tst_links_setsockopt="unknown"
36975 tst_proto_setsockopt="unknown"
36976 tst_compi_setsockopt="unknown"
36977 tst_allow_setsockopt="unknown"
36978 #
36979 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if setsockopt can be linked" >&5
36980$as_echo_n "checking if setsockopt can be linked... " >&6; }
36981 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36982/* end confdefs.h. */
36983
36984
36985 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070036986 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070036987 $curl_includes_sys_socket
36988
36989int main (void)
36990{
36991
36992 if(0 != setsockopt(0, 0, 0, 0, 0))
36993 return 1;
36994
36995 ;
36996 return 0;
36997}
36998
36999_ACEOF
37000if ac_fn_c_try_link "$LINENO"; then :
37001
37002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37003$as_echo "yes" >&6; }
37004 tst_links_setsockopt="yes"
37005
37006else
37007
37008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37009$as_echo "no" >&6; }
37010 tst_links_setsockopt="no"
37011
37012fi
37013rm -f core conftest.err conftest.$ac_objext \
37014 conftest$ac_exeext conftest.$ac_ext
37015 #
37016 if test "$tst_links_setsockopt" = "yes"; then
37017 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if setsockopt is prototyped" >&5
37018$as_echo_n "checking if setsockopt is prototyped... " >&6; }
37019 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37020/* end confdefs.h. */
37021
37022 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070037023 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070037024 $curl_includes_sys_socket
37025
37026_ACEOF
37027if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
37028 $EGREP "setsockopt" >/dev/null 2>&1; then :
37029
37030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37031$as_echo "yes" >&6; }
37032 tst_proto_setsockopt="yes"
37033
37034else
37035
37036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37037$as_echo "no" >&6; }
37038 tst_proto_setsockopt="no"
37039
37040fi
37041rm -f conftest*
37042
37043 fi
37044 #
37045 if test "$tst_proto_setsockopt" = "yes"; then
37046 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if setsockopt is compilable" >&5
37047$as_echo_n "checking if setsockopt is compilable... " >&6; }
37048 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37049/* end confdefs.h. */
37050
37051
37052 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070037053 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070037054 $curl_includes_sys_socket
37055
37056int main (void)
37057{
37058
37059 if(0 != setsockopt(0, 0, 0, 0, 0))
37060 return 1;
37061
37062 ;
37063 return 0;
37064}
37065
37066_ACEOF
37067if ac_fn_c_try_compile "$LINENO"; then :
37068
37069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37070$as_echo "yes" >&6; }
37071 tst_compi_setsockopt="yes"
37072
37073else
37074
37075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37076$as_echo "no" >&6; }
37077 tst_compi_setsockopt="no"
37078
37079fi
37080rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
37081 fi
37082 #
37083 if test "$tst_compi_setsockopt" = "yes"; then
37084 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if setsockopt usage allowed" >&5
37085$as_echo_n "checking if setsockopt usage allowed... " >&6; }
37086 if test "x$curl_disallow_setsockopt" != "xyes"; then
37087 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37088$as_echo "yes" >&6; }
37089 tst_allow_setsockopt="yes"
37090 else
37091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37092$as_echo "no" >&6; }
37093 tst_allow_setsockopt="no"
37094 fi
37095 fi
37096 #
37097 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if setsockopt might be used" >&5
37098$as_echo_n "checking if setsockopt might be used... " >&6; }
37099 if test "$tst_links_setsockopt" = "yes" &&
37100 test "$tst_proto_setsockopt" = "yes" &&
37101 test "$tst_compi_setsockopt" = "yes" &&
37102 test "$tst_allow_setsockopt" = "yes"; then
37103 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37104$as_echo "yes" >&6; }
37105
37106cat >>confdefs.h <<_ACEOF
37107#define HAVE_SETSOCKOPT 1
37108_ACEOF
37109
37110 curl_cv_func_setsockopt="yes"
37111
37112 #
37113 tst_compi_setsockopt_so_nonblock="unknown"
37114 tst_allow_setsockopt_so_nonblock="unknown"
37115 #
37116 if test "$curl_cv_func_setsockopt" = "yes"; then
37117 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if setsockopt SO_NONBLOCK is compilable" >&5
37118$as_echo_n "checking if setsockopt SO_NONBLOCK is compilable... " >&6; }
37119 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37120/* end confdefs.h. */
37121
37122
37123 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070037124 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070037125 $curl_includes_sys_socket
37126
37127int main (void)
37128{
37129
37130 if(0 != setsockopt(0, SOL_SOCKET, SO_NONBLOCK, 0, 0))
37131 return 1;
37132
37133 ;
37134 return 0;
37135}
37136
37137_ACEOF
37138if ac_fn_c_try_compile "$LINENO"; then :
37139
37140 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37141$as_echo "yes" >&6; }
37142 tst_compi_setsockopt_so_nonblock="yes"
37143
37144else
37145
37146 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37147$as_echo "no" >&6; }
37148 tst_compi_setsockopt_so_nonblock="no"
37149
37150fi
37151rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
37152 fi
37153 #
37154 if test "$tst_compi_setsockopt_so_nonblock" = "yes"; then
37155 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if setsockopt SO_NONBLOCK usage allowed" >&5
37156$as_echo_n "checking if setsockopt SO_NONBLOCK usage allowed... " >&6; }
37157 if test "x$curl_disallow_setsockopt_so_nonblock" != "xyes"; then
37158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37159$as_echo "yes" >&6; }
37160 tst_allow_setsockopt_so_nonblock="yes"
37161 else
37162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37163$as_echo "no" >&6; }
37164 tst_allow_setsockopt_so_nonblock="no"
37165 fi
37166 fi
37167 #
37168 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if setsockopt SO_NONBLOCK might be used" >&5
37169$as_echo_n "checking if setsockopt SO_NONBLOCK might be used... " >&6; }
37170 if test "$tst_compi_setsockopt_so_nonblock" = "yes" &&
37171 test "$tst_allow_setsockopt_so_nonblock" = "yes"; then
37172 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37173$as_echo "yes" >&6; }
37174
37175cat >>confdefs.h <<_ACEOF
37176#define HAVE_SETSOCKOPT_SO_NONBLOCK 1
37177_ACEOF
37178
37179 curl_cv_func_setsockopt_so_nonblock="yes"
37180 else
37181 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37182$as_echo "no" >&6; }
37183 curl_cv_func_setsockopt_so_nonblock="no"
37184 fi
37185
37186 else
37187 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37188$as_echo "no" >&6; }
37189 curl_cv_func_setsockopt="no"
37190 fi
37191
37192
37193curl_includes_signal="\
37194/* includes start */
37195#ifdef HAVE_SYS_TYPES_H
37196# include <sys/types.h>
37197#endif
37198#ifdef HAVE_SIGNAL_H
37199# include <signal.h>
37200#endif
37201/* includes end */"
37202 for ac_header in sys/types.h signal.h
37203do :
37204 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
37205ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_signal
37206"
37207if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
37208 cat >>confdefs.h <<_ACEOF
37209#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
37210_ACEOF
37211
37212fi
37213
37214done
37215
37216
37217
37218 #
37219 tst_links_sigaction="unknown"
37220 tst_proto_sigaction="unknown"
37221 tst_compi_sigaction="unknown"
37222 tst_allow_sigaction="unknown"
37223 #
37224 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sigaction can be linked" >&5
37225$as_echo_n "checking if sigaction can be linked... " >&6; }
37226 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37227/* end confdefs.h. */
37228
37229
37230#define sigaction innocuous_sigaction
37231#ifdef __STDC__
37232# include <limits.h>
37233#else
37234# include <assert.h>
37235#endif
37236#undef sigaction
37237#ifdef __cplusplus
37238extern "C"
37239#endif
37240char sigaction ();
37241#if defined __stub_sigaction || defined __stub___sigaction
37242choke me
37243#endif
37244
37245int main (void)
37246{
37247return sigaction ();
37248 ;
37249 return 0;
37250}
37251
37252_ACEOF
37253if ac_fn_c_try_link "$LINENO"; then :
37254
37255 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37256$as_echo "yes" >&6; }
37257 tst_links_sigaction="yes"
37258
37259else
37260
37261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37262$as_echo "no" >&6; }
37263 tst_links_sigaction="no"
37264
37265fi
37266rm -f core conftest.err conftest.$ac_objext \
37267 conftest$ac_exeext conftest.$ac_ext
37268 #
37269 if test "$tst_links_sigaction" = "yes"; then
37270 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sigaction is prototyped" >&5
37271$as_echo_n "checking if sigaction is prototyped... " >&6; }
37272 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37273/* end confdefs.h. */
37274
37275 $curl_includes_signal
37276
37277_ACEOF
37278if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
37279 $EGREP "sigaction" >/dev/null 2>&1; then :
37280
37281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37282$as_echo "yes" >&6; }
37283 tst_proto_sigaction="yes"
37284
37285else
37286
37287 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37288$as_echo "no" >&6; }
37289 tst_proto_sigaction="no"
37290
37291fi
37292rm -f conftest*
37293
37294 fi
37295 #
37296 if test "$tst_proto_sigaction" = "yes"; then
37297 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sigaction is compilable" >&5
37298$as_echo_n "checking if sigaction is compilable... " >&6; }
37299 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37300/* end confdefs.h. */
37301
37302
37303 $curl_includes_signal
37304
37305int main (void)
37306{
37307
37308 if(0 != sigaction(0, 0, 0))
37309 return 1;
37310
37311 ;
37312 return 0;
37313}
37314
37315_ACEOF
37316if ac_fn_c_try_compile "$LINENO"; then :
37317
37318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37319$as_echo "yes" >&6; }
37320 tst_compi_sigaction="yes"
37321
37322else
37323
37324 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37325$as_echo "no" >&6; }
37326 tst_compi_sigaction="no"
37327
37328fi
37329rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
37330 fi
37331 #
37332 if test "$tst_compi_sigaction" = "yes"; then
37333 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sigaction usage allowed" >&5
37334$as_echo_n "checking if sigaction usage allowed... " >&6; }
37335 if test "x$curl_disallow_sigaction" != "xyes"; then
37336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37337$as_echo "yes" >&6; }
37338 tst_allow_sigaction="yes"
37339 else
37340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37341$as_echo "no" >&6; }
37342 tst_allow_sigaction="no"
37343 fi
37344 fi
37345 #
37346 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sigaction might be used" >&5
37347$as_echo_n "checking if sigaction might be used... " >&6; }
37348 if test "$tst_links_sigaction" = "yes" &&
37349 test "$tst_proto_sigaction" = "yes" &&
37350 test "$tst_compi_sigaction" = "yes" &&
37351 test "$tst_allow_sigaction" = "yes"; then
37352 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37353$as_echo "yes" >&6; }
37354
37355cat >>confdefs.h <<_ACEOF
37356#define HAVE_SIGACTION 1
37357_ACEOF
37358
37359 curl_cv_func_sigaction="yes"
37360 else
37361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37362$as_echo "no" >&6; }
37363 curl_cv_func_sigaction="no"
37364 fi
37365
37366
37367 #
37368 tst_links_siginterrupt="unknown"
37369 tst_proto_siginterrupt="unknown"
37370 tst_compi_siginterrupt="unknown"
37371 tst_allow_siginterrupt="unknown"
37372 #
37373 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if siginterrupt can be linked" >&5
37374$as_echo_n "checking if siginterrupt can be linked... " >&6; }
37375 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37376/* end confdefs.h. */
37377
37378
37379#define siginterrupt innocuous_siginterrupt
37380#ifdef __STDC__
37381# include <limits.h>
37382#else
37383# include <assert.h>
37384#endif
37385#undef siginterrupt
37386#ifdef __cplusplus
37387extern "C"
37388#endif
37389char siginterrupt ();
37390#if defined __stub_siginterrupt || defined __stub___siginterrupt
37391choke me
37392#endif
37393
37394int main (void)
37395{
37396return siginterrupt ();
37397 ;
37398 return 0;
37399}
37400
37401_ACEOF
37402if ac_fn_c_try_link "$LINENO"; then :
37403
37404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37405$as_echo "yes" >&6; }
37406 tst_links_siginterrupt="yes"
37407
37408else
37409
37410 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37411$as_echo "no" >&6; }
37412 tst_links_siginterrupt="no"
37413
37414fi
37415rm -f core conftest.err conftest.$ac_objext \
37416 conftest$ac_exeext conftest.$ac_ext
37417 #
37418 if test "$tst_links_siginterrupt" = "yes"; then
37419 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if siginterrupt is prototyped" >&5
37420$as_echo_n "checking if siginterrupt is prototyped... " >&6; }
37421 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37422/* end confdefs.h. */
37423
37424 $curl_includes_signal
37425
37426_ACEOF
37427if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
37428 $EGREP "siginterrupt" >/dev/null 2>&1; then :
37429
37430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37431$as_echo "yes" >&6; }
37432 tst_proto_siginterrupt="yes"
37433
37434else
37435
37436 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37437$as_echo "no" >&6; }
37438 tst_proto_siginterrupt="no"
37439
37440fi
37441rm -f conftest*
37442
37443 fi
37444 #
37445 if test "$tst_proto_siginterrupt" = "yes"; then
37446 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if siginterrupt is compilable" >&5
37447$as_echo_n "checking if siginterrupt is compilable... " >&6; }
37448 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37449/* end confdefs.h. */
37450
37451
37452 $curl_includes_signal
37453
37454int main (void)
37455{
37456
37457 if(0 != siginterrupt(0, 0))
37458 return 1;
37459
37460 ;
37461 return 0;
37462}
37463
37464_ACEOF
37465if ac_fn_c_try_compile "$LINENO"; then :
37466
37467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37468$as_echo "yes" >&6; }
37469 tst_compi_siginterrupt="yes"
37470
37471else
37472
37473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37474$as_echo "no" >&6; }
37475 tst_compi_siginterrupt="no"
37476
37477fi
37478rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
37479 fi
37480 #
37481 if test "$tst_compi_siginterrupt" = "yes"; then
37482 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if siginterrupt usage allowed" >&5
37483$as_echo_n "checking if siginterrupt usage allowed... " >&6; }
37484 if test "x$curl_disallow_siginterrupt" != "xyes"; then
37485 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37486$as_echo "yes" >&6; }
37487 tst_allow_siginterrupt="yes"
37488 else
37489 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37490$as_echo "no" >&6; }
37491 tst_allow_siginterrupt="no"
37492 fi
37493 fi
37494 #
37495 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if siginterrupt might be used" >&5
37496$as_echo_n "checking if siginterrupt might be used... " >&6; }
37497 if test "$tst_links_siginterrupt" = "yes" &&
37498 test "$tst_proto_siginterrupt" = "yes" &&
37499 test "$tst_compi_siginterrupt" = "yes" &&
37500 test "$tst_allow_siginterrupt" = "yes"; then
37501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37502$as_echo "yes" >&6; }
37503
37504cat >>confdefs.h <<_ACEOF
37505#define HAVE_SIGINTERRUPT 1
37506_ACEOF
37507
37508 curl_cv_func_siginterrupt="yes"
37509 else
37510 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37511$as_echo "no" >&6; }
37512 curl_cv_func_siginterrupt="no"
37513 fi
37514
37515
37516 #
37517 tst_links_signal="unknown"
37518 tst_proto_signal="unknown"
37519 tst_compi_signal="unknown"
37520 tst_allow_signal="unknown"
37521 #
37522 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if signal can be linked" >&5
37523$as_echo_n "checking if signal can be linked... " >&6; }
37524 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37525/* end confdefs.h. */
37526
37527
37528#define signal innocuous_signal
37529#ifdef __STDC__
37530# include <limits.h>
37531#else
37532# include <assert.h>
37533#endif
37534#undef signal
37535#ifdef __cplusplus
37536extern "C"
37537#endif
37538char signal ();
37539#if defined __stub_signal || defined __stub___signal
37540choke me
37541#endif
37542
37543int main (void)
37544{
37545return signal ();
37546 ;
37547 return 0;
37548}
37549
37550_ACEOF
37551if ac_fn_c_try_link "$LINENO"; then :
37552
37553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37554$as_echo "yes" >&6; }
37555 tst_links_signal="yes"
37556
37557else
37558
37559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37560$as_echo "no" >&6; }
37561 tst_links_signal="no"
37562
37563fi
37564rm -f core conftest.err conftest.$ac_objext \
37565 conftest$ac_exeext conftest.$ac_ext
37566 #
37567 if test "$tst_links_signal" = "yes"; then
37568 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if signal is prototyped" >&5
37569$as_echo_n "checking if signal is prototyped... " >&6; }
37570 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37571/* end confdefs.h. */
37572
37573 $curl_includes_signal
37574
37575_ACEOF
37576if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
37577 $EGREP "signal" >/dev/null 2>&1; then :
37578
37579 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37580$as_echo "yes" >&6; }
37581 tst_proto_signal="yes"
37582
37583else
37584
37585 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37586$as_echo "no" >&6; }
37587 tst_proto_signal="no"
37588
37589fi
37590rm -f conftest*
37591
37592 fi
37593 #
37594 if test "$tst_proto_signal" = "yes"; then
37595 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if signal is compilable" >&5
37596$as_echo_n "checking if signal is compilable... " >&6; }
37597 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37598/* end confdefs.h. */
37599
37600
37601 $curl_includes_signal
37602
37603int main (void)
37604{
37605
37606 if(0 != signal(0, 0))
37607 return 1;
37608
37609 ;
37610 return 0;
37611}
37612
37613_ACEOF
37614if ac_fn_c_try_compile "$LINENO"; then :
37615
37616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37617$as_echo "yes" >&6; }
37618 tst_compi_signal="yes"
37619
37620else
37621
37622 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37623$as_echo "no" >&6; }
37624 tst_compi_signal="no"
37625
37626fi
37627rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
37628 fi
37629 #
37630 if test "$tst_compi_signal" = "yes"; then
37631 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if signal usage allowed" >&5
37632$as_echo_n "checking if signal usage allowed... " >&6; }
37633 if test "x$curl_disallow_signal" != "xyes"; then
37634 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37635$as_echo "yes" >&6; }
37636 tst_allow_signal="yes"
37637 else
37638 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37639$as_echo "no" >&6; }
37640 tst_allow_signal="no"
37641 fi
37642 fi
37643 #
37644 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if signal might be used" >&5
37645$as_echo_n "checking if signal might be used... " >&6; }
37646 if test "$tst_links_signal" = "yes" &&
37647 test "$tst_proto_signal" = "yes" &&
37648 test "$tst_compi_signal" = "yes" &&
37649 test "$tst_allow_signal" = "yes"; then
37650 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37651$as_echo "yes" >&6; }
37652
37653cat >>confdefs.h <<_ACEOF
37654#define HAVE_SIGNAL 1
37655_ACEOF
37656
37657 curl_cv_func_signal="yes"
37658 else
37659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37660$as_echo "no" >&6; }
37661 curl_cv_func_signal="no"
37662 fi
37663
37664
37665curl_includes_setjmp="\
37666/* includes start */
37667#ifdef HAVE_SYS_TYPES_H
37668# include <sys/types.h>
37669#endif
37670#ifdef HAVE_SETJMP_H
37671# include <setjmp.h>
37672#endif
37673/* includes end */"
37674 for ac_header in sys/types.h setjmp.h
37675do :
37676 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
37677ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_setjmp
37678"
37679if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
37680 cat >>confdefs.h <<_ACEOF
37681#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
37682_ACEOF
37683
37684fi
37685
37686done
37687
37688
37689
37690 #
37691 tst_links_sigsetjmp="unknown"
37692 tst_macro_sigsetjmp="unknown"
37693 tst_proto_sigsetjmp="unknown"
37694 tst_compi_sigsetjmp="unknown"
37695 tst_allow_sigsetjmp="unknown"
37696 #
37697 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sigsetjmp can be linked" >&5
37698$as_echo_n "checking if sigsetjmp can be linked... " >&6; }
37699 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37700/* end confdefs.h. */
37701
37702
37703#define sigsetjmp innocuous_sigsetjmp
37704#ifdef __STDC__
37705# include <limits.h>
37706#else
37707# include <assert.h>
37708#endif
37709#undef sigsetjmp
37710#ifdef __cplusplus
37711extern "C"
37712#endif
37713char sigsetjmp ();
37714#if defined __stub_sigsetjmp || defined __stub___sigsetjmp
37715choke me
37716#endif
37717
37718int main (void)
37719{
37720return sigsetjmp ();
37721 ;
37722 return 0;
37723}
37724
37725_ACEOF
37726if ac_fn_c_try_link "$LINENO"; then :
37727
37728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37729$as_echo "yes" >&6; }
37730 tst_links_sigsetjmp="yes"
37731
37732else
37733
37734 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37735$as_echo "no" >&6; }
37736 tst_links_sigsetjmp="no"
37737
37738fi
37739rm -f core conftest.err conftest.$ac_objext \
37740 conftest$ac_exeext conftest.$ac_ext
37741 #
37742 if test "$tst_links_sigsetjmp" = "no"; then
37743 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sigsetjmp seems a macro" >&5
37744$as_echo_n "checking if sigsetjmp seems a macro... " >&6; }
37745 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37746/* end confdefs.h. */
37747
37748
37749 $curl_includes_setjmp
37750
37751int main (void)
37752{
37753
37754 sigjmp_buf env;
37755 if(0 != sigsetjmp(env, 0))
37756 return 1;
37757
37758 ;
37759 return 0;
37760}
37761
37762_ACEOF
37763if ac_fn_c_try_link "$LINENO"; then :
37764
37765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37766$as_echo "yes" >&6; }
37767 tst_macro_sigsetjmp="yes"
37768
37769else
37770
37771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37772$as_echo "no" >&6; }
37773 tst_macro_sigsetjmp="no"
37774
37775fi
37776rm -f core conftest.err conftest.$ac_objext \
37777 conftest$ac_exeext conftest.$ac_ext
37778 fi
37779 #
37780 if test "$tst_links_sigsetjmp" = "yes"; then
37781 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sigsetjmp is prototyped" >&5
37782$as_echo_n "checking if sigsetjmp is prototyped... " >&6; }
37783 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37784/* end confdefs.h. */
37785
37786 $curl_includes_setjmp
37787
37788_ACEOF
37789if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
37790 $EGREP "sigsetjmp" >/dev/null 2>&1; then :
37791
37792 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37793$as_echo "yes" >&6; }
37794 tst_proto_sigsetjmp="yes"
37795
37796else
37797
37798 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37799$as_echo "no" >&6; }
37800 tst_proto_sigsetjmp="no"
37801
37802fi
37803rm -f conftest*
37804
37805 fi
37806 #
37807 if test "$tst_proto_sigsetjmp" = "yes" ||
37808 test "$tst_macro_sigsetjmp" = "yes"; then
37809 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sigsetjmp is compilable" >&5
37810$as_echo_n "checking if sigsetjmp is compilable... " >&6; }
37811 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37812/* end confdefs.h. */
37813
37814
37815 $curl_includes_setjmp
37816
37817int main (void)
37818{
37819
37820 sigjmp_buf env;
37821 if(0 != sigsetjmp(env, 0))
37822 return 1;
37823
37824 ;
37825 return 0;
37826}
37827
37828_ACEOF
37829if ac_fn_c_try_compile "$LINENO"; then :
37830
37831 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37832$as_echo "yes" >&6; }
37833 tst_compi_sigsetjmp="yes"
37834
37835else
37836
37837 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37838$as_echo "no" >&6; }
37839 tst_compi_sigsetjmp="no"
37840
37841fi
37842rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
37843 fi
37844 #
37845 if test "$tst_compi_sigsetjmp" = "yes"; then
37846 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sigsetjmp usage allowed" >&5
37847$as_echo_n "checking if sigsetjmp usage allowed... " >&6; }
37848 if test "x$curl_disallow_sigsetjmp" != "xyes"; then
37849 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37850$as_echo "yes" >&6; }
37851 tst_allow_sigsetjmp="yes"
37852 else
37853 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37854$as_echo "no" >&6; }
37855 tst_allow_sigsetjmp="no"
37856 fi
37857 fi
37858 #
37859 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sigsetjmp might be used" >&5
37860$as_echo_n "checking if sigsetjmp might be used... " >&6; }
37861 if (test "$tst_proto_sigsetjmp" = "yes" ||
37862 test "$tst_macro_sigsetjmp" = "yes") &&
37863 test "$tst_compi_sigsetjmp" = "yes" &&
37864 test "$tst_allow_sigsetjmp" = "yes"; then
37865 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37866$as_echo "yes" >&6; }
37867
37868cat >>confdefs.h <<_ACEOF
37869#define HAVE_SIGSETJMP 1
37870_ACEOF
37871
37872 curl_cv_func_sigsetjmp="yes"
37873 else
37874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37875$as_echo "no" >&6; }
37876 curl_cv_func_sigsetjmp="no"
37877 fi
37878
37879
37880 #
37881 tst_links_socket="unknown"
37882 tst_proto_socket="unknown"
37883 tst_compi_socket="unknown"
37884 tst_allow_socket="unknown"
37885 #
37886 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if socket can be linked" >&5
37887$as_echo_n "checking if socket can be linked... " >&6; }
37888 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37889/* end confdefs.h. */
37890
37891
37892 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070037893 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070037894 $curl_includes_sys_socket
37895 $curl_includes_socket
37896
37897int main (void)
37898{
37899
37900 if(0 != socket(0, 0, 0))
37901 return 1;
37902
37903 ;
37904 return 0;
37905}
37906
37907_ACEOF
37908if ac_fn_c_try_link "$LINENO"; then :
37909
37910 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37911$as_echo "yes" >&6; }
37912 tst_links_socket="yes"
37913
37914else
37915
37916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37917$as_echo "no" >&6; }
37918 tst_links_socket="no"
37919
37920fi
37921rm -f core conftest.err conftest.$ac_objext \
37922 conftest$ac_exeext conftest.$ac_ext
37923 #
37924 if test "$tst_links_socket" = "yes"; then
37925 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if socket is prototyped" >&5
37926$as_echo_n "checking if socket is prototyped... " >&6; }
37927 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37928/* end confdefs.h. */
37929
37930 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070037931 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070037932 $curl_includes_sys_socket
37933 $curl_includes_socket
37934
37935_ACEOF
37936if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
37937 $EGREP "socket" >/dev/null 2>&1; then :
37938
37939 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37940$as_echo "yes" >&6; }
37941 tst_proto_socket="yes"
37942
37943else
37944
37945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37946$as_echo "no" >&6; }
37947 tst_proto_socket="no"
37948
37949fi
37950rm -f conftest*
37951
37952 fi
37953 #
37954 if test "$tst_proto_socket" = "yes"; then
37955 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if socket is compilable" >&5
37956$as_echo_n "checking if socket is compilable... " >&6; }
37957 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37958/* end confdefs.h. */
37959
37960
37961 $curl_includes_winsock2
Haibo Huang65021c72019-03-27 15:37:23 -070037962 $curl_includes_bsdsocket
Elliott Hughes82be86d2017-09-20 17:00:17 -070037963 $curl_includes_sys_socket
37964 $curl_includes_socket
37965
37966int main (void)
37967{
37968
37969 if(0 != socket(0, 0, 0))
37970 return 1;
37971
37972 ;
37973 return 0;
37974}
37975
37976_ACEOF
37977if ac_fn_c_try_compile "$LINENO"; then :
37978
37979 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37980$as_echo "yes" >&6; }
37981 tst_compi_socket="yes"
37982
37983else
37984
37985 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
37986$as_echo "no" >&6; }
37987 tst_compi_socket="no"
37988
37989fi
37990rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
37991 fi
37992 #
37993 if test "$tst_compi_socket" = "yes"; then
37994 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if socket usage allowed" >&5
37995$as_echo_n "checking if socket usage allowed... " >&6; }
37996 if test "x$curl_disallow_socket" != "xyes"; then
37997 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
37998$as_echo "yes" >&6; }
37999 tst_allow_socket="yes"
38000 else
38001 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38002$as_echo "no" >&6; }
38003 tst_allow_socket="no"
38004 fi
38005 fi
38006 #
38007 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if socket might be used" >&5
38008$as_echo_n "checking if socket might be used... " >&6; }
38009 if test "$tst_links_socket" = "yes" &&
38010 test "$tst_proto_socket" = "yes" &&
38011 test "$tst_compi_socket" = "yes" &&
38012 test "$tst_allow_socket" = "yes"; then
38013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38014$as_echo "yes" >&6; }
38015
38016cat >>confdefs.h <<_ACEOF
38017#define HAVE_SOCKET 1
38018_ACEOF
38019
38020 curl_cv_func_socket="yes"
38021 else
38022 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38023$as_echo "no" >&6; }
38024 curl_cv_func_socket="no"
38025 fi
38026
38027
38028 #
38029 tst_links_socketpair="unknown"
38030 tst_proto_socketpair="unknown"
38031 tst_compi_socketpair="unknown"
38032 tst_allow_socketpair="unknown"
38033 #
38034 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if socketpair can be linked" >&5
38035$as_echo_n "checking if socketpair can be linked... " >&6; }
38036 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38037/* end confdefs.h. */
38038
38039
38040#define socketpair innocuous_socketpair
38041#ifdef __STDC__
38042# include <limits.h>
38043#else
38044# include <assert.h>
38045#endif
38046#undef socketpair
38047#ifdef __cplusplus
38048extern "C"
38049#endif
38050char socketpair ();
38051#if defined __stub_socketpair || defined __stub___socketpair
38052choke me
38053#endif
38054
38055int main (void)
38056{
38057return socketpair ();
38058 ;
38059 return 0;
38060}
38061
38062_ACEOF
38063if ac_fn_c_try_link "$LINENO"; then :
38064
38065 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38066$as_echo "yes" >&6; }
38067 tst_links_socketpair="yes"
38068
38069else
38070
38071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38072$as_echo "no" >&6; }
38073 tst_links_socketpair="no"
38074
38075fi
38076rm -f core conftest.err conftest.$ac_objext \
38077 conftest$ac_exeext conftest.$ac_ext
38078 #
38079 if test "$tst_links_socketpair" = "yes"; then
38080 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if socketpair is prototyped" >&5
38081$as_echo_n "checking if socketpair is prototyped... " >&6; }
38082 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38083/* end confdefs.h. */
38084
38085 $curl_includes_sys_socket
38086 $curl_includes_socket
38087
38088_ACEOF
38089if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
38090 $EGREP "socketpair" >/dev/null 2>&1; then :
38091
38092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38093$as_echo "yes" >&6; }
38094 tst_proto_socketpair="yes"
38095
38096else
38097
38098 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38099$as_echo "no" >&6; }
38100 tst_proto_socketpair="no"
38101
38102fi
38103rm -f conftest*
38104
38105 fi
38106 #
38107 if test "$tst_proto_socketpair" = "yes"; then
38108 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if socketpair is compilable" >&5
38109$as_echo_n "checking if socketpair is compilable... " >&6; }
38110 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38111/* end confdefs.h. */
38112
38113
38114 $curl_includes_sys_socket
38115 $curl_includes_socket
38116
38117int main (void)
38118{
38119
38120 int sv[2];
38121 if(0 != socketpair(0, 0, 0, sv))
38122 return 1;
38123
38124 ;
38125 return 0;
38126}
38127
38128_ACEOF
38129if ac_fn_c_try_compile "$LINENO"; then :
38130
38131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38132$as_echo "yes" >&6; }
38133 tst_compi_socketpair="yes"
38134
38135else
38136
38137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38138$as_echo "no" >&6; }
38139 tst_compi_socketpair="no"
38140
38141fi
38142rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
38143 fi
38144 #
38145 if test "$tst_compi_socketpair" = "yes"; then
38146 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if socketpair usage allowed" >&5
38147$as_echo_n "checking if socketpair usage allowed... " >&6; }
38148 if test "x$curl_disallow_socketpair" != "xyes"; then
38149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38150$as_echo "yes" >&6; }
38151 tst_allow_socketpair="yes"
38152 else
38153 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38154$as_echo "no" >&6; }
38155 tst_allow_socketpair="no"
38156 fi
38157 fi
38158 #
38159 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if socketpair might be used" >&5
38160$as_echo_n "checking if socketpair might be used... " >&6; }
38161 if test "$tst_links_socketpair" = "yes" &&
38162 test "$tst_proto_socketpair" = "yes" &&
38163 test "$tst_compi_socketpair" = "yes" &&
38164 test "$tst_allow_socketpair" = "yes"; then
38165 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38166$as_echo "yes" >&6; }
38167
38168cat >>confdefs.h <<_ACEOF
38169#define HAVE_SOCKETPAIR 1
38170_ACEOF
38171
38172 curl_cv_func_socketpair="yes"
38173 else
38174 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38175$as_echo "no" >&6; }
38176 curl_cv_func_socketpair="no"
38177 fi
38178
38179
38180 #
38181 tst_links_strcasecmp="unknown"
38182 tst_proto_strcasecmp="unknown"
38183 tst_compi_strcasecmp="unknown"
38184 tst_allow_strcasecmp="unknown"
38185 #
38186 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strcasecmp can be linked" >&5
38187$as_echo_n "checking if strcasecmp can be linked... " >&6; }
38188 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38189/* end confdefs.h. */
38190
38191
38192#define strcasecmp innocuous_strcasecmp
38193#ifdef __STDC__
38194# include <limits.h>
38195#else
38196# include <assert.h>
38197#endif
38198#undef strcasecmp
38199#ifdef __cplusplus
38200extern "C"
38201#endif
38202char strcasecmp ();
38203#if defined __stub_strcasecmp || defined __stub___strcasecmp
38204choke me
38205#endif
38206
38207int main (void)
38208{
38209return strcasecmp ();
38210 ;
38211 return 0;
38212}
38213
38214_ACEOF
38215if ac_fn_c_try_link "$LINENO"; then :
38216
38217 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38218$as_echo "yes" >&6; }
38219 tst_links_strcasecmp="yes"
38220
38221else
38222
38223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38224$as_echo "no" >&6; }
38225 tst_links_strcasecmp="no"
38226
38227fi
38228rm -f core conftest.err conftest.$ac_objext \
38229 conftest$ac_exeext conftest.$ac_ext
38230 #
38231 if test "$tst_links_strcasecmp" = "yes"; then
38232 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strcasecmp is prototyped" >&5
38233$as_echo_n "checking if strcasecmp is prototyped... " >&6; }
38234 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38235/* end confdefs.h. */
38236
38237 $curl_includes_string
38238
38239_ACEOF
38240if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
38241 $EGREP "strcasecmp" >/dev/null 2>&1; then :
38242
38243 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38244$as_echo "yes" >&6; }
38245 tst_proto_strcasecmp="yes"
38246
38247else
38248
38249 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38250$as_echo "no" >&6; }
38251 tst_proto_strcasecmp="no"
38252
38253fi
38254rm -f conftest*
38255
38256 fi
38257 #
38258 if test "$tst_proto_strcasecmp" = "yes"; then
38259 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strcasecmp is compilable" >&5
38260$as_echo_n "checking if strcasecmp is compilable... " >&6; }
38261 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38262/* end confdefs.h. */
38263
38264
38265 $curl_includes_string
38266
38267int main (void)
38268{
38269
38270 if(0 != strcasecmp(0, 0))
38271 return 1;
38272
38273 ;
38274 return 0;
38275}
38276
38277_ACEOF
38278if ac_fn_c_try_compile "$LINENO"; then :
38279
38280 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38281$as_echo "yes" >&6; }
38282 tst_compi_strcasecmp="yes"
38283
38284else
38285
38286 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38287$as_echo "no" >&6; }
38288 tst_compi_strcasecmp="no"
38289
38290fi
38291rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
38292 fi
38293 #
38294 if test "$tst_compi_strcasecmp" = "yes"; then
38295 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strcasecmp usage allowed" >&5
38296$as_echo_n "checking if strcasecmp usage allowed... " >&6; }
38297 if test "x$curl_disallow_strcasecmp" != "xyes"; then
38298 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38299$as_echo "yes" >&6; }
38300 tst_allow_strcasecmp="yes"
38301 else
38302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38303$as_echo "no" >&6; }
38304 tst_allow_strcasecmp="no"
38305 fi
38306 fi
38307 #
38308 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strcasecmp might be used" >&5
38309$as_echo_n "checking if strcasecmp might be used... " >&6; }
38310 if test "$tst_links_strcasecmp" = "yes" &&
38311 test "$tst_proto_strcasecmp" = "yes" &&
38312 test "$tst_compi_strcasecmp" = "yes" &&
38313 test "$tst_allow_strcasecmp" = "yes"; then
38314 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38315$as_echo "yes" >&6; }
38316
38317cat >>confdefs.h <<_ACEOF
38318#define HAVE_STRCASECMP 1
38319_ACEOF
38320
38321 curl_cv_func_strcasecmp="yes"
38322 else
38323 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38324$as_echo "no" >&6; }
38325 curl_cv_func_strcasecmp="no"
38326 fi
38327
38328
38329 #
38330 tst_links_strcmpi="unknown"
38331 tst_proto_strcmpi="unknown"
38332 tst_compi_strcmpi="unknown"
38333 tst_allow_strcmpi="unknown"
38334 #
38335 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strcmpi can be linked" >&5
38336$as_echo_n "checking if strcmpi can be linked... " >&6; }
38337 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38338/* end confdefs.h. */
38339
38340
38341#define strcmpi innocuous_strcmpi
38342#ifdef __STDC__
38343# include <limits.h>
38344#else
38345# include <assert.h>
38346#endif
38347#undef strcmpi
38348#ifdef __cplusplus
38349extern "C"
38350#endif
38351char strcmpi ();
38352#if defined __stub_strcmpi || defined __stub___strcmpi
38353choke me
38354#endif
38355
38356int main (void)
38357{
38358return strcmpi ();
38359 ;
38360 return 0;
38361}
38362
38363_ACEOF
38364if ac_fn_c_try_link "$LINENO"; then :
38365
38366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38367$as_echo "yes" >&6; }
38368 tst_links_strcmpi="yes"
38369
38370else
38371
38372 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38373$as_echo "no" >&6; }
38374 tst_links_strcmpi="no"
38375
38376fi
38377rm -f core conftest.err conftest.$ac_objext \
38378 conftest$ac_exeext conftest.$ac_ext
38379 #
38380 if test "$tst_links_strcmpi" = "yes"; then
38381 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strcmpi is prototyped" >&5
38382$as_echo_n "checking if strcmpi is prototyped... " >&6; }
38383 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38384/* end confdefs.h. */
38385
38386 $curl_includes_string
38387
38388_ACEOF
38389if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
38390 $EGREP "strcmpi" >/dev/null 2>&1; then :
38391
38392 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38393$as_echo "yes" >&6; }
38394 tst_proto_strcmpi="yes"
38395
38396else
38397
38398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38399$as_echo "no" >&6; }
38400 tst_proto_strcmpi="no"
38401
38402fi
38403rm -f conftest*
38404
38405 fi
38406 #
38407 if test "$tst_proto_strcmpi" = "yes"; then
38408 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strcmpi is compilable" >&5
38409$as_echo_n "checking if strcmpi is compilable... " >&6; }
38410 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38411/* end confdefs.h. */
38412
38413
38414 $curl_includes_string
38415
38416int main (void)
38417{
38418
38419 if(0 != strcmpi(0, 0))
38420 return 1;
38421
38422 ;
38423 return 0;
38424}
38425
38426_ACEOF
38427if ac_fn_c_try_compile "$LINENO"; then :
38428
38429 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38430$as_echo "yes" >&6; }
38431 tst_compi_strcmpi="yes"
38432
38433else
38434
38435 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38436$as_echo "no" >&6; }
38437 tst_compi_strcmpi="no"
38438
38439fi
38440rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
38441 fi
38442 #
38443 if test "$tst_compi_strcmpi" = "yes"; then
38444 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strcmpi usage allowed" >&5
38445$as_echo_n "checking if strcmpi usage allowed... " >&6; }
38446 if test "x$curl_disallow_strcmpi" != "xyes"; then
38447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38448$as_echo "yes" >&6; }
38449 tst_allow_strcmpi="yes"
38450 else
38451 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38452$as_echo "no" >&6; }
38453 tst_allow_strcmpi="no"
38454 fi
38455 fi
38456 #
38457 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strcmpi might be used" >&5
38458$as_echo_n "checking if strcmpi might be used... " >&6; }
38459 if test "$tst_links_strcmpi" = "yes" &&
38460 test "$tst_proto_strcmpi" = "yes" &&
38461 test "$tst_compi_strcmpi" = "yes" &&
38462 test "$tst_allow_strcmpi" = "yes"; then
38463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38464$as_echo "yes" >&6; }
38465
38466cat >>confdefs.h <<_ACEOF
38467#define HAVE_STRCMPI 1
38468_ACEOF
38469
38470 curl_cv_func_strcmpi="yes"
38471 else
38472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38473$as_echo "no" >&6; }
38474 curl_cv_func_strcmpi="no"
38475 fi
38476
38477
38478 #
38479 tst_links_strdup="unknown"
38480 tst_proto_strdup="unknown"
38481 tst_compi_strdup="unknown"
38482 tst_allow_strdup="unknown"
38483 #
38484 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strdup can be linked" >&5
38485$as_echo_n "checking if strdup can be linked... " >&6; }
38486 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38487/* end confdefs.h. */
38488
38489
38490#define strdup innocuous_strdup
38491#ifdef __STDC__
38492# include <limits.h>
38493#else
38494# include <assert.h>
38495#endif
38496#undef strdup
38497#ifdef __cplusplus
38498extern "C"
38499#endif
38500char strdup ();
38501#if defined __stub_strdup || defined __stub___strdup
38502choke me
38503#endif
38504
38505int main (void)
38506{
38507return strdup ();
38508 ;
38509 return 0;
38510}
38511
38512_ACEOF
38513if ac_fn_c_try_link "$LINENO"; then :
38514
38515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38516$as_echo "yes" >&6; }
38517 tst_links_strdup="yes"
38518
38519else
38520
38521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38522$as_echo "no" >&6; }
38523 tst_links_strdup="no"
38524
38525fi
38526rm -f core conftest.err conftest.$ac_objext \
38527 conftest$ac_exeext conftest.$ac_ext
38528 #
38529 if test "$tst_links_strdup" = "yes"; then
38530 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strdup is prototyped" >&5
38531$as_echo_n "checking if strdup is prototyped... " >&6; }
38532 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38533/* end confdefs.h. */
38534
38535 $curl_includes_string
38536
38537_ACEOF
38538if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
38539 $EGREP "strdup" >/dev/null 2>&1; then :
38540
38541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38542$as_echo "yes" >&6; }
38543 tst_proto_strdup="yes"
38544
38545else
38546
38547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38548$as_echo "no" >&6; }
38549 tst_proto_strdup="no"
38550
38551fi
38552rm -f conftest*
38553
38554 fi
38555 #
38556 if test "$tst_proto_strdup" = "yes"; then
38557 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strdup is compilable" >&5
38558$as_echo_n "checking if strdup is compilable... " >&6; }
38559 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38560/* end confdefs.h. */
38561
38562
38563 $curl_includes_string
38564
38565int main (void)
38566{
38567
38568 if(0 != strdup(0))
38569 return 1;
38570
38571 ;
38572 return 0;
38573}
38574
38575_ACEOF
38576if ac_fn_c_try_compile "$LINENO"; then :
38577
38578 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38579$as_echo "yes" >&6; }
38580 tst_compi_strdup="yes"
38581
38582else
38583
38584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38585$as_echo "no" >&6; }
38586 tst_compi_strdup="no"
38587
38588fi
38589rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
38590 fi
38591 #
38592 if test "$tst_compi_strdup" = "yes"; then
38593 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strdup usage allowed" >&5
38594$as_echo_n "checking if strdup usage allowed... " >&6; }
38595 if test "x$curl_disallow_strdup" != "xyes"; then
38596 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38597$as_echo "yes" >&6; }
38598 tst_allow_strdup="yes"
38599 else
38600 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38601$as_echo "no" >&6; }
38602 tst_allow_strdup="no"
38603 fi
38604 fi
38605 #
38606 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strdup might be used" >&5
38607$as_echo_n "checking if strdup might be used... " >&6; }
38608 if test "$tst_links_strdup" = "yes" &&
38609 test "$tst_proto_strdup" = "yes" &&
38610 test "$tst_compi_strdup" = "yes" &&
38611 test "$tst_allow_strdup" = "yes"; then
38612 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38613$as_echo "yes" >&6; }
38614
38615cat >>confdefs.h <<_ACEOF
38616#define HAVE_STRDUP 1
38617_ACEOF
38618
38619 curl_cv_func_strdup="yes"
38620 else
38621 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38622$as_echo "no" >&6; }
38623 curl_cv_func_strdup="no"
38624 fi
38625
38626
38627 #
38628 tst_links_strerror_r="unknown"
38629 tst_proto_strerror_r="unknown"
38630 tst_compi_strerror_r="unknown"
38631 tst_glibc_strerror_r="unknown"
38632 tst_posix_strerror_r="unknown"
38633 tst_allow_strerror_r="unknown"
38634 tst_works_glibc_strerror_r="unknown"
38635 tst_works_posix_strerror_r="unknown"
38636 tst_glibc_strerror_r_type_arg3="unknown"
38637 tst_posix_strerror_r_type_arg3="unknown"
38638 #
38639 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strerror_r can be linked" >&5
38640$as_echo_n "checking if strerror_r can be linked... " >&6; }
38641 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38642/* end confdefs.h. */
38643
38644
38645#define strerror_r innocuous_strerror_r
38646#ifdef __STDC__
38647# include <limits.h>
38648#else
38649# include <assert.h>
38650#endif
38651#undef strerror_r
38652#ifdef __cplusplus
38653extern "C"
38654#endif
38655char strerror_r ();
38656#if defined __stub_strerror_r || defined __stub___strerror_r
38657choke me
38658#endif
38659
38660int main (void)
38661{
38662return strerror_r ();
38663 ;
38664 return 0;
38665}
38666
38667_ACEOF
38668if ac_fn_c_try_link "$LINENO"; then :
38669
38670 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38671$as_echo "yes" >&6; }
38672 tst_links_strerror_r="yes"
38673
38674else
38675
38676 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38677$as_echo "no" >&6; }
38678 tst_links_strerror_r="no"
38679
38680fi
38681rm -f core conftest.err conftest.$ac_objext \
38682 conftest$ac_exeext conftest.$ac_ext
38683 #
38684 if test "$tst_links_strerror_r" = "yes"; then
38685 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strerror_r is prototyped" >&5
38686$as_echo_n "checking if strerror_r is prototyped... " >&6; }
38687 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38688/* end confdefs.h. */
38689
38690 $curl_includes_string
38691
38692_ACEOF
38693if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
38694 $EGREP "strerror_r" >/dev/null 2>&1; then :
38695
38696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38697$as_echo "yes" >&6; }
38698 tst_proto_strerror_r="yes"
38699
38700else
38701
38702 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38703$as_echo "no" >&6; }
38704 tst_proto_strerror_r="no"
38705
38706fi
38707rm -f conftest*
38708
38709 fi
38710 #
38711 if test "$tst_proto_strerror_r" = "yes"; then
38712 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strerror_r is compilable" >&5
38713$as_echo_n "checking if strerror_r is compilable... " >&6; }
38714 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38715/* end confdefs.h. */
38716
38717
38718 $curl_includes_string
38719
38720int main (void)
38721{
38722
38723 if(0 != strerror_r(0, 0, 0))
38724 return 1;
38725
38726 ;
38727 return 0;
38728}
38729
38730_ACEOF
38731if ac_fn_c_try_compile "$LINENO"; then :
38732
38733 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38734$as_echo "yes" >&6; }
38735 tst_compi_strerror_r="yes"
38736
38737else
38738
38739 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38740$as_echo "no" >&6; }
38741 tst_compi_strerror_r="no"
38742
38743fi
38744rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
38745 fi
38746 #
38747 if test "$tst_compi_strerror_r" = "yes"; then
38748 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strerror_r is glibc like" >&5
38749$as_echo_n "checking if strerror_r is glibc like... " >&6; }
38750 tst_glibc_strerror_r_type_arg3="unknown"
38751 for arg3 in 'size_t' 'int' 'unsigned int'; do
38752 if test "$tst_glibc_strerror_r_type_arg3" = "unknown"; then
38753 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38754/* end confdefs.h. */
38755
38756
38757 $curl_includes_string
38758 char *strerror_r(int errnum, char *workbuf, $arg3 bufsize);
38759
38760int main (void)
38761{
38762
38763 if(0 != strerror_r(0, 0, 0))
38764 return 1;
38765
38766 ;
38767 return 0;
38768}
38769
38770_ACEOF
38771if ac_fn_c_try_compile "$LINENO"; then :
38772
38773 tst_glibc_strerror_r_type_arg3="$arg3"
38774
38775fi
38776rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
38777 fi
38778 done
38779 case "$tst_glibc_strerror_r_type_arg3" in
38780 unknown)
38781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38782$as_echo "no" >&6; }
38783 tst_glibc_strerror_r="no"
38784 ;;
38785 *)
38786 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38787$as_echo "yes" >&6; }
38788 tst_glibc_strerror_r="yes"
38789 ;;
38790 esac
38791 fi
38792 #
38793 if test "x$cross_compiling" != "xyes" &&
38794 test "$tst_glibc_strerror_r" = "yes"; then
38795 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strerror_r seems to work" >&5
38796$as_echo_n "checking if strerror_r seems to work... " >&6; }
Elliott Hughesa93fb052018-12-12 14:22:48 -080038797
38798
38799 old=$LD_LIBRARY_PATH
38800 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
38801 export LD_LIBRARY_PATH
38802 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070038803 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
38804$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
38805as_fn_error $? "cannot run test program while cross compiling
38806See \`config.log' for more details" "$LINENO" 5; }
38807else
38808 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38809/* end confdefs.h. */
38810
38811
38812 $curl_includes_stdlib
38813 $curl_includes_string
38814# include <errno.h>
38815
38816int main (void)
38817{
38818
38819 char buffer[1024];
38820 char *string = 0;
38821 buffer[0] = '\0';
38822 string = strerror_r(EACCES, buffer, sizeof(buffer));
38823 if(!string)
38824 exit(1); /* fail */
38825 if(!string[0])
38826 exit(1); /* fail */
38827 else
38828 exit(0);
38829
38830 ;
38831 return 0;
38832}
38833
38834_ACEOF
38835if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughesa93fb052018-12-12 14:22:48 -080038836 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070038837$as_echo "yes" >&6; }
38838 tst_works_glibc_strerror_r="yes"
38839
38840else
Elliott Hughesa93fb052018-12-12 14:22:48 -080038841 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070038842$as_echo "no" >&6; }
38843 tst_works_glibc_strerror_r="no"
38844
38845fi
38846rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
38847 conftest.$ac_objext conftest.beam conftest.$ac_ext
38848fi
38849
Elliott Hughesa93fb052018-12-12 14:22:48 -080038850 LD_LIBRARY_PATH=$old # restore
38851
Elliott Hughes82be86d2017-09-20 17:00:17 -070038852 fi
38853 #
38854 if test "$tst_compi_strerror_r" = "yes" &&
38855 test "$tst_works_glibc_strerror_r" != "yes"; then
38856 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strerror_r is POSIX like" >&5
38857$as_echo_n "checking if strerror_r is POSIX like... " >&6; }
38858 tst_posix_strerror_r_type_arg3="unknown"
38859 for arg3 in 'size_t' 'int' 'unsigned int'; do
38860 if test "$tst_posix_strerror_r_type_arg3" = "unknown"; then
38861 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38862/* end confdefs.h. */
38863
38864
38865 $curl_includes_string
38866 int strerror_r(int errnum, char *resultbuf, $arg3 bufsize);
38867
38868int main (void)
38869{
38870
38871 if(0 != strerror_r(0, 0, 0))
38872 return 1;
38873
38874 ;
38875 return 0;
38876}
38877
38878_ACEOF
38879if ac_fn_c_try_compile "$LINENO"; then :
38880
38881 tst_posix_strerror_r_type_arg3="$arg3"
38882
38883fi
38884rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
38885 fi
38886 done
38887 case "$tst_posix_strerror_r_type_arg3" in
38888 unknown)
38889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38890$as_echo "no" >&6; }
38891 tst_posix_strerror_r="no"
38892 ;;
38893 *)
38894 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38895$as_echo "yes" >&6; }
38896 tst_posix_strerror_r="yes"
38897 ;;
38898 esac
38899 fi
38900 #
38901 if test "x$cross_compiling" != "xyes" &&
38902 test "$tst_posix_strerror_r" = "yes"; then
38903 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strerror_r seems to work" >&5
38904$as_echo_n "checking if strerror_r seems to work... " >&6; }
Elliott Hughesa93fb052018-12-12 14:22:48 -080038905
38906
38907 old=$LD_LIBRARY_PATH
38908 LD_LIBRARY_PATH=$CURL_LIBRARY_PATH:$old
38909 export LD_LIBRARY_PATH
38910 if test "$cross_compiling" = yes; then :
Elliott Hughes82be86d2017-09-20 17:00:17 -070038911 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
38912$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
38913as_fn_error $? "cannot run test program while cross compiling
38914See \`config.log' for more details" "$LINENO" 5; }
38915else
38916 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38917/* end confdefs.h. */
38918
38919
38920 $curl_includes_stdlib
38921 $curl_includes_string
38922# include <errno.h>
38923
38924int main (void)
38925{
38926
38927 char buffer[1024];
38928 int error = 1;
38929 buffer[0] = '\0';
38930 error = strerror_r(EACCES, buffer, sizeof(buffer));
38931 if(error)
38932 exit(1); /* fail */
38933 if(buffer[0] == '\0')
38934 exit(1); /* fail */
38935 else
38936 exit(0);
38937
38938 ;
38939 return 0;
38940}
38941
38942_ACEOF
38943if ac_fn_c_try_run "$LINENO"; then :
Elliott Hughesa93fb052018-12-12 14:22:48 -080038944 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070038945$as_echo "yes" >&6; }
38946 tst_works_posix_strerror_r="yes"
38947
38948else
Elliott Hughesa93fb052018-12-12 14:22:48 -080038949 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
Elliott Hughes82be86d2017-09-20 17:00:17 -070038950$as_echo "no" >&6; }
38951 tst_works_posix_strerror_r="no"
38952
38953fi
38954rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
38955 conftest.$ac_objext conftest.beam conftest.$ac_ext
38956fi
38957
Elliott Hughesa93fb052018-12-12 14:22:48 -080038958 LD_LIBRARY_PATH=$old # restore
38959
Elliott Hughes82be86d2017-09-20 17:00:17 -070038960 fi
38961 #
38962 if test "$tst_works_glibc_strerror_r" = "yes"; then
38963 tst_posix_strerror_r="no"
38964 fi
38965 if test "$tst_works_posix_strerror_r" = "yes"; then
38966 tst_glibc_strerror_r="no"
38967 fi
38968 if test "$tst_glibc_strerror_r" = "yes" &&
38969 test "$tst_works_glibc_strerror_r" != "no" &&
38970 test "$tst_posix_strerror_r" != "yes"; then
38971 tst_allow_strerror_r="check"
38972 fi
38973 if test "$tst_posix_strerror_r" = "yes" &&
38974 test "$tst_works_posix_strerror_r" != "no" &&
38975 test "$tst_glibc_strerror_r" != "yes"; then
38976 tst_allow_strerror_r="check"
38977 fi
38978 if test "$tst_allow_strerror_r" = "check"; then
38979 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strerror_r usage allowed" >&5
38980$as_echo_n "checking if strerror_r usage allowed... " >&6; }
38981 if test "x$curl_disallow_strerror_r" != "xyes"; then
38982 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38983$as_echo "yes" >&6; }
38984 tst_allow_strerror_r="yes"
38985 else
38986 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
38987$as_echo "no" >&6; }
38988 tst_allow_strerror_r="no"
38989 fi
38990 fi
38991 #
38992 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strerror_r might be used" >&5
38993$as_echo_n "checking if strerror_r might be used... " >&6; }
38994 if test "$tst_links_strerror_r" = "yes" &&
38995 test "$tst_proto_strerror_r" = "yes" &&
38996 test "$tst_compi_strerror_r" = "yes" &&
38997 test "$tst_allow_strerror_r" = "yes"; then
38998 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
38999$as_echo "yes" >&6; }
39000 if test "$tst_glibc_strerror_r" = "yes"; then
39001
39002cat >>confdefs.h <<_ACEOF
39003#define HAVE_STRERROR_R 1
39004_ACEOF
39005
39006
39007cat >>confdefs.h <<_ACEOF
39008#define HAVE_GLIBC_STRERROR_R 1
39009_ACEOF
39010
39011
39012cat >>confdefs.h <<_ACEOF
39013#define STRERROR_R_TYPE_ARG3 $tst_glibc_strerror_r_type_arg3
39014_ACEOF
39015
39016 fi
39017 if test "$tst_posix_strerror_r" = "yes"; then
39018
39019cat >>confdefs.h <<_ACEOF
39020#define HAVE_STRERROR_R 1
39021_ACEOF
39022
39023
39024cat >>confdefs.h <<_ACEOF
39025#define HAVE_POSIX_STRERROR_R 1
39026_ACEOF
39027
39028
39029cat >>confdefs.h <<_ACEOF
39030#define STRERROR_R_TYPE_ARG3 $tst_posix_strerror_r_type_arg3
39031_ACEOF
39032
39033 fi
39034 curl_cv_func_strerror_r="yes"
39035 else
39036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39037$as_echo "no" >&6; }
39038 curl_cv_func_strerror_r="no"
39039 fi
39040 #
39041 if test "$tst_compi_strerror_r" = "yes" &&
39042 test "$tst_allow_strerror_r" = "unknown"; then
39043 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot determine strerror_r() style: edit lib/curl_config.h manually." >&5
39044$as_echo "$as_me: WARNING: cannot determine strerror_r() style: edit lib/curl_config.h manually." >&2;}
39045 fi
39046 #
39047
39048
39049 #
39050 tst_links_stricmp="unknown"
39051 tst_proto_stricmp="unknown"
39052 tst_compi_stricmp="unknown"
39053 tst_allow_stricmp="unknown"
39054 #
39055 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if stricmp can be linked" >&5
39056$as_echo_n "checking if stricmp can be linked... " >&6; }
39057 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39058/* end confdefs.h. */
39059
39060
39061#define stricmp innocuous_stricmp
39062#ifdef __STDC__
39063# include <limits.h>
39064#else
39065# include <assert.h>
39066#endif
39067#undef stricmp
39068#ifdef __cplusplus
39069extern "C"
39070#endif
39071char stricmp ();
39072#if defined __stub_stricmp || defined __stub___stricmp
39073choke me
39074#endif
39075
39076int main (void)
39077{
39078return stricmp ();
39079 ;
39080 return 0;
39081}
39082
39083_ACEOF
39084if ac_fn_c_try_link "$LINENO"; then :
39085
39086 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39087$as_echo "yes" >&6; }
39088 tst_links_stricmp="yes"
39089
39090else
39091
39092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39093$as_echo "no" >&6; }
39094 tst_links_stricmp="no"
39095
39096fi
39097rm -f core conftest.err conftest.$ac_objext \
39098 conftest$ac_exeext conftest.$ac_ext
39099 #
39100 if test "$tst_links_stricmp" = "yes"; then
39101 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if stricmp is prototyped" >&5
39102$as_echo_n "checking if stricmp is prototyped... " >&6; }
39103 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39104/* end confdefs.h. */
39105
39106 $curl_includes_string
39107
39108_ACEOF
39109if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
39110 $EGREP "stricmp" >/dev/null 2>&1; then :
39111
39112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39113$as_echo "yes" >&6; }
39114 tst_proto_stricmp="yes"
39115
39116else
39117
39118 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39119$as_echo "no" >&6; }
39120 tst_proto_stricmp="no"
39121
39122fi
39123rm -f conftest*
39124
39125 fi
39126 #
39127 if test "$tst_proto_stricmp" = "yes"; then
39128 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if stricmp is compilable" >&5
39129$as_echo_n "checking if stricmp is compilable... " >&6; }
39130 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39131/* end confdefs.h. */
39132
39133
39134 $curl_includes_string
39135
39136int main (void)
39137{
39138
39139 if(0 != stricmp(0, 0))
39140 return 1;
39141
39142 ;
39143 return 0;
39144}
39145
39146_ACEOF
39147if ac_fn_c_try_compile "$LINENO"; then :
39148
39149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39150$as_echo "yes" >&6; }
39151 tst_compi_stricmp="yes"
39152
39153else
39154
39155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39156$as_echo "no" >&6; }
39157 tst_compi_stricmp="no"
39158
39159fi
39160rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
39161 fi
39162 #
39163 if test "$tst_compi_stricmp" = "yes"; then
39164 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if stricmp usage allowed" >&5
39165$as_echo_n "checking if stricmp usage allowed... " >&6; }
39166 if test "x$curl_disallow_stricmp" != "xyes"; then
39167 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39168$as_echo "yes" >&6; }
39169 tst_allow_stricmp="yes"
39170 else
39171 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39172$as_echo "no" >&6; }
39173 tst_allow_stricmp="no"
39174 fi
39175 fi
39176 #
39177 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if stricmp might be used" >&5
39178$as_echo_n "checking if stricmp might be used... " >&6; }
39179 if test "$tst_links_stricmp" = "yes" &&
39180 test "$tst_proto_stricmp" = "yes" &&
39181 test "$tst_compi_stricmp" = "yes" &&
39182 test "$tst_allow_stricmp" = "yes"; then
39183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39184$as_echo "yes" >&6; }
39185
39186cat >>confdefs.h <<_ACEOF
39187#define HAVE_STRICMP 1
39188_ACEOF
39189
39190 curl_cv_func_stricmp="yes"
39191 else
39192 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39193$as_echo "no" >&6; }
39194 curl_cv_func_stricmp="no"
39195 fi
39196
39197
39198 #
39199 tst_links_strncasecmp="unknown"
39200 tst_proto_strncasecmp="unknown"
39201 tst_compi_strncasecmp="unknown"
39202 tst_allow_strncasecmp="unknown"
39203 #
39204 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strncasecmp can be linked" >&5
39205$as_echo_n "checking if strncasecmp can be linked... " >&6; }
39206 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39207/* end confdefs.h. */
39208
39209
39210#define strncasecmp innocuous_strncasecmp
39211#ifdef __STDC__
39212# include <limits.h>
39213#else
39214# include <assert.h>
39215#endif
39216#undef strncasecmp
39217#ifdef __cplusplus
39218extern "C"
39219#endif
39220char strncasecmp ();
39221#if defined __stub_strncasecmp || defined __stub___strncasecmp
39222choke me
39223#endif
39224
39225int main (void)
39226{
39227return strncasecmp ();
39228 ;
39229 return 0;
39230}
39231
39232_ACEOF
39233if ac_fn_c_try_link "$LINENO"; then :
39234
39235 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39236$as_echo "yes" >&6; }
39237 tst_links_strncasecmp="yes"
39238
39239else
39240
39241 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39242$as_echo "no" >&6; }
39243 tst_links_strncasecmp="no"
39244
39245fi
39246rm -f core conftest.err conftest.$ac_objext \
39247 conftest$ac_exeext conftest.$ac_ext
39248 #
39249 if test "$tst_links_strncasecmp" = "yes"; then
39250 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strncasecmp is prototyped" >&5
39251$as_echo_n "checking if strncasecmp is prototyped... " >&6; }
39252 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39253/* end confdefs.h. */
39254
39255 $curl_includes_string
39256
39257_ACEOF
39258if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
39259 $EGREP "strncasecmp" >/dev/null 2>&1; then :
39260
39261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39262$as_echo "yes" >&6; }
39263 tst_proto_strncasecmp="yes"
39264
39265else
39266
39267 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39268$as_echo "no" >&6; }
39269 tst_proto_strncasecmp="no"
39270
39271fi
39272rm -f conftest*
39273
39274 fi
39275 #
39276 if test "$tst_proto_strncasecmp" = "yes"; then
39277 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strncasecmp is compilable" >&5
39278$as_echo_n "checking if strncasecmp is compilable... " >&6; }
39279 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39280/* end confdefs.h. */
39281
39282
39283 $curl_includes_string
39284
39285int main (void)
39286{
39287
39288 if(0 != strncasecmp(0, 0, 0))
39289 return 1;
39290
39291 ;
39292 return 0;
39293}
39294
39295_ACEOF
39296if ac_fn_c_try_compile "$LINENO"; then :
39297
39298 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39299$as_echo "yes" >&6; }
39300 tst_compi_strncasecmp="yes"
39301
39302else
39303
39304 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39305$as_echo "no" >&6; }
39306 tst_compi_strncasecmp="no"
39307
39308fi
39309rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
39310 fi
39311 #
39312 if test "$tst_compi_strncasecmp" = "yes"; then
39313 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strncasecmp usage allowed" >&5
39314$as_echo_n "checking if strncasecmp usage allowed... " >&6; }
39315 if test "x$curl_disallow_strncasecmp" != "xyes"; then
39316 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39317$as_echo "yes" >&6; }
39318 tst_allow_strncasecmp="yes"
39319 else
39320 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39321$as_echo "no" >&6; }
39322 tst_allow_strncasecmp="no"
39323 fi
39324 fi
39325 #
39326 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strncasecmp might be used" >&5
39327$as_echo_n "checking if strncasecmp might be used... " >&6; }
39328 if test "$tst_links_strncasecmp" = "yes" &&
39329 test "$tst_proto_strncasecmp" = "yes" &&
39330 test "$tst_compi_strncasecmp" = "yes" &&
39331 test "$tst_allow_strncasecmp" = "yes"; then
39332 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39333$as_echo "yes" >&6; }
39334
39335cat >>confdefs.h <<_ACEOF
39336#define HAVE_STRNCASECMP 1
39337_ACEOF
39338
39339 curl_cv_func_strncasecmp="yes"
39340 else
39341 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39342$as_echo "no" >&6; }
39343 curl_cv_func_strncasecmp="no"
39344 fi
39345
39346
39347 #
39348 tst_links_strncmpi="unknown"
39349 tst_proto_strncmpi="unknown"
39350 tst_compi_strncmpi="unknown"
39351 tst_allow_strncmpi="unknown"
39352 #
39353 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strncmpi can be linked" >&5
39354$as_echo_n "checking if strncmpi can be linked... " >&6; }
39355 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39356/* end confdefs.h. */
39357
39358
39359#define strncmpi innocuous_strncmpi
39360#ifdef __STDC__
39361# include <limits.h>
39362#else
39363# include <assert.h>
39364#endif
39365#undef strncmpi
39366#ifdef __cplusplus
39367extern "C"
39368#endif
39369char strncmpi ();
39370#if defined __stub_strncmpi || defined __stub___strncmpi
39371choke me
39372#endif
39373
39374int main (void)
39375{
39376return strncmpi ();
39377 ;
39378 return 0;
39379}
39380
39381_ACEOF
39382if ac_fn_c_try_link "$LINENO"; then :
39383
39384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39385$as_echo "yes" >&6; }
39386 tst_links_strncmpi="yes"
39387
39388else
39389
39390 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39391$as_echo "no" >&6; }
39392 tst_links_strncmpi="no"
39393
39394fi
39395rm -f core conftest.err conftest.$ac_objext \
39396 conftest$ac_exeext conftest.$ac_ext
39397 #
39398 if test "$tst_links_strncmpi" = "yes"; then
39399 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strncmpi is prototyped" >&5
39400$as_echo_n "checking if strncmpi is prototyped... " >&6; }
39401 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39402/* end confdefs.h. */
39403
39404 $curl_includes_string
39405
39406_ACEOF
39407if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
39408 $EGREP "strncmpi" >/dev/null 2>&1; then :
39409
39410 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39411$as_echo "yes" >&6; }
39412 tst_proto_strncmpi="yes"
39413
39414else
39415
39416 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39417$as_echo "no" >&6; }
39418 tst_proto_strncmpi="no"
39419
39420fi
39421rm -f conftest*
39422
39423 fi
39424 #
39425 if test "$tst_proto_strncmpi" = "yes"; then
39426 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strncmpi is compilable" >&5
39427$as_echo_n "checking if strncmpi is compilable... " >&6; }
39428 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39429/* end confdefs.h. */
39430
39431
39432 $curl_includes_string
39433
39434int main (void)
39435{
39436
39437 if(0 != strncmpi(0, 0))
39438 return 1;
39439
39440 ;
39441 return 0;
39442}
39443
39444_ACEOF
39445if ac_fn_c_try_compile "$LINENO"; then :
39446
39447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39448$as_echo "yes" >&6; }
39449 tst_compi_strncmpi="yes"
39450
39451else
39452
39453 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39454$as_echo "no" >&6; }
39455 tst_compi_strncmpi="no"
39456
39457fi
39458rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
39459 fi
39460 #
39461 if test "$tst_compi_strncmpi" = "yes"; then
39462 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strncmpi usage allowed" >&5
39463$as_echo_n "checking if strncmpi usage allowed... " >&6; }
39464 if test "x$curl_disallow_strncmpi" != "xyes"; then
39465 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39466$as_echo "yes" >&6; }
39467 tst_allow_strncmpi="yes"
39468 else
39469 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39470$as_echo "no" >&6; }
39471 tst_allow_strncmpi="no"
39472 fi
39473 fi
39474 #
39475 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strncmpi might be used" >&5
39476$as_echo_n "checking if strncmpi might be used... " >&6; }
39477 if test "$tst_links_strncmpi" = "yes" &&
39478 test "$tst_proto_strncmpi" = "yes" &&
39479 test "$tst_compi_strncmpi" = "yes" &&
39480 test "$tst_allow_strncmpi" = "yes"; then
39481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39482$as_echo "yes" >&6; }
39483
39484cat >>confdefs.h <<_ACEOF
39485#define HAVE_STRNCMPI 1
39486_ACEOF
39487
39488 curl_cv_func_strncmpi="yes"
39489 else
39490 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39491$as_echo "no" >&6; }
39492 curl_cv_func_strncmpi="no"
39493 fi
39494
39495
39496 #
39497 tst_links_strnicmp="unknown"
39498 tst_proto_strnicmp="unknown"
39499 tst_compi_strnicmp="unknown"
39500 tst_allow_strnicmp="unknown"
39501 #
39502 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strnicmp can be linked" >&5
39503$as_echo_n "checking if strnicmp can be linked... " >&6; }
39504 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39505/* end confdefs.h. */
39506
39507
39508#define strnicmp innocuous_strnicmp
39509#ifdef __STDC__
39510# include <limits.h>
39511#else
39512# include <assert.h>
39513#endif
39514#undef strnicmp
39515#ifdef __cplusplus
39516extern "C"
39517#endif
39518char strnicmp ();
39519#if defined __stub_strnicmp || defined __stub___strnicmp
39520choke me
39521#endif
39522
39523int main (void)
39524{
39525return strnicmp ();
39526 ;
39527 return 0;
39528}
39529
39530_ACEOF
39531if ac_fn_c_try_link "$LINENO"; then :
39532
39533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39534$as_echo "yes" >&6; }
39535 tst_links_strnicmp="yes"
39536
39537else
39538
39539 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39540$as_echo "no" >&6; }
39541 tst_links_strnicmp="no"
39542
39543fi
39544rm -f core conftest.err conftest.$ac_objext \
39545 conftest$ac_exeext conftest.$ac_ext
39546 #
39547 if test "$tst_links_strnicmp" = "yes"; then
39548 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strnicmp is prototyped" >&5
39549$as_echo_n "checking if strnicmp is prototyped... " >&6; }
39550 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39551/* end confdefs.h. */
39552
39553 $curl_includes_string
39554
39555_ACEOF
39556if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
39557 $EGREP "strnicmp" >/dev/null 2>&1; then :
39558
39559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39560$as_echo "yes" >&6; }
39561 tst_proto_strnicmp="yes"
39562
39563else
39564
39565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39566$as_echo "no" >&6; }
39567 tst_proto_strnicmp="no"
39568
39569fi
39570rm -f conftest*
39571
39572 fi
39573 #
39574 if test "$tst_proto_strnicmp" = "yes"; then
39575 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strnicmp is compilable" >&5
39576$as_echo_n "checking if strnicmp is compilable... " >&6; }
39577 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39578/* end confdefs.h. */
39579
39580
39581 $curl_includes_string
39582
39583int main (void)
39584{
39585
39586 if(0 != strnicmp(0, 0))
39587 return 1;
39588
39589 ;
39590 return 0;
39591}
39592
39593_ACEOF
39594if ac_fn_c_try_compile "$LINENO"; then :
39595
39596 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39597$as_echo "yes" >&6; }
39598 tst_compi_strnicmp="yes"
39599
39600else
39601
39602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39603$as_echo "no" >&6; }
39604 tst_compi_strnicmp="no"
39605
39606fi
39607rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
39608 fi
39609 #
39610 if test "$tst_compi_strnicmp" = "yes"; then
39611 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strnicmp usage allowed" >&5
39612$as_echo_n "checking if strnicmp usage allowed... " >&6; }
39613 if test "x$curl_disallow_strnicmp" != "xyes"; then
39614 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39615$as_echo "yes" >&6; }
39616 tst_allow_strnicmp="yes"
39617 else
39618 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39619$as_echo "no" >&6; }
39620 tst_allow_strnicmp="no"
39621 fi
39622 fi
39623 #
39624 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strnicmp might be used" >&5
39625$as_echo_n "checking if strnicmp might be used... " >&6; }
39626 if test "$tst_links_strnicmp" = "yes" &&
39627 test "$tst_proto_strnicmp" = "yes" &&
39628 test "$tst_compi_strnicmp" = "yes" &&
39629 test "$tst_allow_strnicmp" = "yes"; then
39630 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39631$as_echo "yes" >&6; }
39632
39633cat >>confdefs.h <<_ACEOF
39634#define HAVE_STRNICMP 1
39635_ACEOF
39636
39637 curl_cv_func_strnicmp="yes"
39638 else
39639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39640$as_echo "no" >&6; }
39641 curl_cv_func_strnicmp="no"
39642 fi
39643
39644
39645 #
39646 tst_links_strstr="unknown"
39647 tst_proto_strstr="unknown"
39648 tst_compi_strstr="unknown"
39649 tst_allow_strstr="unknown"
39650 #
39651 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strstr can be linked" >&5
39652$as_echo_n "checking if strstr can be linked... " >&6; }
39653 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39654/* end confdefs.h. */
39655
39656
39657#define strstr innocuous_strstr
39658#ifdef __STDC__
39659# include <limits.h>
39660#else
39661# include <assert.h>
39662#endif
39663#undef strstr
39664#ifdef __cplusplus
39665extern "C"
39666#endif
39667char strstr ();
39668#if defined __stub_strstr || defined __stub___strstr
39669choke me
39670#endif
39671
39672int main (void)
39673{
39674return strstr ();
39675 ;
39676 return 0;
39677}
39678
39679_ACEOF
39680if ac_fn_c_try_link "$LINENO"; then :
39681
39682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39683$as_echo "yes" >&6; }
39684 tst_links_strstr="yes"
39685
39686else
39687
39688 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39689$as_echo "no" >&6; }
39690 tst_links_strstr="no"
39691
39692fi
39693rm -f core conftest.err conftest.$ac_objext \
39694 conftest$ac_exeext conftest.$ac_ext
39695 #
39696 if test "$tst_links_strstr" = "yes"; then
39697 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strstr is prototyped" >&5
39698$as_echo_n "checking if strstr is prototyped... " >&6; }
39699 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39700/* end confdefs.h. */
39701
39702 $curl_includes_string
39703
39704_ACEOF
39705if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
39706 $EGREP "strstr" >/dev/null 2>&1; then :
39707
39708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39709$as_echo "yes" >&6; }
39710 tst_proto_strstr="yes"
39711
39712else
39713
39714 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39715$as_echo "no" >&6; }
39716 tst_proto_strstr="no"
39717
39718fi
39719rm -f conftest*
39720
39721 fi
39722 #
39723 if test "$tst_proto_strstr" = "yes"; then
39724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strstr is compilable" >&5
39725$as_echo_n "checking if strstr is compilable... " >&6; }
39726 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39727/* end confdefs.h. */
39728
39729
39730 $curl_includes_string
39731
39732int main (void)
39733{
39734
39735 if(0 != strstr(0, 0))
39736 return 1;
39737
39738 ;
39739 return 0;
39740}
39741
39742_ACEOF
39743if ac_fn_c_try_compile "$LINENO"; then :
39744
39745 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39746$as_echo "yes" >&6; }
39747 tst_compi_strstr="yes"
39748
39749else
39750
39751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39752$as_echo "no" >&6; }
39753 tst_compi_strstr="no"
39754
39755fi
39756rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
39757 fi
39758 #
39759 if test "$tst_compi_strstr" = "yes"; then
39760 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strstr usage allowed" >&5
39761$as_echo_n "checking if strstr usage allowed... " >&6; }
39762 if test "x$curl_disallow_strstr" != "xyes"; then
39763 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39764$as_echo "yes" >&6; }
39765 tst_allow_strstr="yes"
39766 else
39767 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39768$as_echo "no" >&6; }
39769 tst_allow_strstr="no"
39770 fi
39771 fi
39772 #
39773 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strstr might be used" >&5
39774$as_echo_n "checking if strstr might be used... " >&6; }
39775 if test "$tst_links_strstr" = "yes" &&
39776 test "$tst_proto_strstr" = "yes" &&
39777 test "$tst_compi_strstr" = "yes" &&
39778 test "$tst_allow_strstr" = "yes"; then
39779 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39780$as_echo "yes" >&6; }
39781
39782cat >>confdefs.h <<_ACEOF
39783#define HAVE_STRSTR 1
39784_ACEOF
39785
39786 curl_cv_func_strstr="yes"
39787 else
39788 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39789$as_echo "no" >&6; }
39790 curl_cv_func_strstr="no"
39791 fi
39792
39793
39794 #
39795 tst_links_strtok_r="unknown"
39796 tst_proto_strtok_r="unknown"
39797 tst_compi_strtok_r="unknown"
39798 tst_allow_strtok_r="unknown"
39799 #
39800 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strtok_r can be linked" >&5
39801$as_echo_n "checking if strtok_r can be linked... " >&6; }
39802 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39803/* end confdefs.h. */
39804
39805
39806#define strtok_r innocuous_strtok_r
39807#ifdef __STDC__
39808# include <limits.h>
39809#else
39810# include <assert.h>
39811#endif
39812#undef strtok_r
39813#ifdef __cplusplus
39814extern "C"
39815#endif
39816char strtok_r ();
39817#if defined __stub_strtok_r || defined __stub___strtok_r
39818choke me
39819#endif
39820
39821int main (void)
39822{
39823return strtok_r ();
39824 ;
39825 return 0;
39826}
39827
39828_ACEOF
39829if ac_fn_c_try_link "$LINENO"; then :
39830
39831 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39832$as_echo "yes" >&6; }
39833 tst_links_strtok_r="yes"
39834
39835else
39836
39837 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39838$as_echo "no" >&6; }
39839 tst_links_strtok_r="no"
39840
39841fi
39842rm -f core conftest.err conftest.$ac_objext \
39843 conftest$ac_exeext conftest.$ac_ext
39844 #
39845 if test "$tst_links_strtok_r" = "yes"; then
39846 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strtok_r is prototyped" >&5
39847$as_echo_n "checking if strtok_r is prototyped... " >&6; }
39848 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39849/* end confdefs.h. */
39850
39851 $curl_includes_string
39852
39853_ACEOF
39854if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
39855 $EGREP "strtok_r" >/dev/null 2>&1; then :
39856
39857 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39858$as_echo "yes" >&6; }
39859 tst_proto_strtok_r="yes"
39860
39861else
39862
39863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39864$as_echo "no" >&6; }
39865 tst_proto_strtok_r="no"
39866
39867fi
39868rm -f conftest*
39869
39870 fi
39871 #
39872 if test "$tst_proto_strtok_r" = "yes"; then
39873 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strtok_r is compilable" >&5
39874$as_echo_n "checking if strtok_r is compilable... " >&6; }
39875 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39876/* end confdefs.h. */
39877
39878
39879 $curl_includes_string
39880
39881int main (void)
39882{
39883
39884 if(0 != strtok_r(0, 0, 0))
39885 return 1;
39886
39887 ;
39888 return 0;
39889}
39890
39891_ACEOF
39892if ac_fn_c_try_compile "$LINENO"; then :
39893
39894 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39895$as_echo "yes" >&6; }
39896 tst_compi_strtok_r="yes"
39897
39898else
39899
39900 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39901$as_echo "no" >&6; }
39902 tst_compi_strtok_r="no"
39903
39904fi
39905rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
39906 fi
39907 #
39908 if test "$tst_compi_strtok_r" = "yes"; then
39909 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strtok_r usage allowed" >&5
39910$as_echo_n "checking if strtok_r usage allowed... " >&6; }
39911 if test "x$curl_disallow_strtok_r" != "xyes"; then
39912 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39913$as_echo "yes" >&6; }
39914 tst_allow_strtok_r="yes"
39915 else
39916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39917$as_echo "no" >&6; }
39918 tst_allow_strtok_r="no"
39919 fi
39920 fi
39921 #
39922 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strtok_r might be used" >&5
39923$as_echo_n "checking if strtok_r might be used... " >&6; }
39924 if test "$tst_links_strtok_r" = "yes" &&
39925 test "$tst_proto_strtok_r" = "yes" &&
39926 test "$tst_compi_strtok_r" = "yes" &&
39927 test "$tst_allow_strtok_r" = "yes"; then
39928 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39929$as_echo "yes" >&6; }
39930
39931cat >>confdefs.h <<_ACEOF
39932#define HAVE_STRTOK_R 1
39933_ACEOF
39934
39935 curl_cv_func_strtok_r="yes"
39936 else
39937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39938$as_echo "no" >&6; }
39939 curl_cv_func_strtok_r="no"
39940 fi
39941
39942
39943 #
39944 tst_links_strtoll="unknown"
39945 tst_proto_strtoll="unknown"
39946 tst_compi_strtoll="unknown"
39947 tst_allow_strtoll="unknown"
39948 #
39949 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strtoll can be linked" >&5
39950$as_echo_n "checking if strtoll can be linked... " >&6; }
39951 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39952/* end confdefs.h. */
39953
39954
39955#define strtoll innocuous_strtoll
39956#ifdef __STDC__
39957# include <limits.h>
39958#else
39959# include <assert.h>
39960#endif
39961#undef strtoll
39962#ifdef __cplusplus
39963extern "C"
39964#endif
39965char strtoll ();
39966#if defined __stub_strtoll || defined __stub___strtoll
39967choke me
39968#endif
39969
39970int main (void)
39971{
39972return strtoll ();
39973 ;
39974 return 0;
39975}
39976
39977_ACEOF
39978if ac_fn_c_try_link "$LINENO"; then :
39979
39980 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
39981$as_echo "yes" >&6; }
39982 tst_links_strtoll="yes"
39983
39984else
39985
39986 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
39987$as_echo "no" >&6; }
39988 tst_links_strtoll="no"
39989
39990fi
39991rm -f core conftest.err conftest.$ac_objext \
39992 conftest$ac_exeext conftest.$ac_ext
39993 #
39994 if test "$tst_links_strtoll" = "yes"; then
39995 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strtoll is prototyped" >&5
39996$as_echo_n "checking if strtoll is prototyped... " >&6; }
39997 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39998/* end confdefs.h. */
39999
40000 $curl_includes_stdlib
40001
40002_ACEOF
40003if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
40004 $EGREP "strtoll" >/dev/null 2>&1; then :
40005
40006 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40007$as_echo "yes" >&6; }
40008 tst_proto_strtoll="yes"
40009
40010else
40011
40012 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40013$as_echo "no" >&6; }
40014 tst_proto_strtoll="no"
40015
40016fi
40017rm -f conftest*
40018
40019 fi
40020 #
40021 if test "$tst_proto_strtoll" = "yes"; then
40022 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strtoll is compilable" >&5
40023$as_echo_n "checking if strtoll is compilable... " >&6; }
40024 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40025/* end confdefs.h. */
40026
40027
40028 $curl_includes_stdlib
40029
40030int main (void)
40031{
40032
40033 if(0 != strtoll(0, 0, 0))
40034 return 1;
40035
40036 ;
40037 return 0;
40038}
40039
40040_ACEOF
40041if ac_fn_c_try_compile "$LINENO"; then :
40042
40043 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40044$as_echo "yes" >&6; }
40045 tst_compi_strtoll="yes"
40046
40047else
40048
40049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40050$as_echo "no" >&6; }
40051 tst_compi_strtoll="no"
40052
40053fi
40054rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
40055 fi
40056 #
40057 if test "$tst_compi_strtoll" = "yes"; then
40058 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strtoll usage allowed" >&5
40059$as_echo_n "checking if strtoll usage allowed... " >&6; }
40060 if test "x$curl_disallow_strtoll" != "xyes"; then
40061 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40062$as_echo "yes" >&6; }
40063 tst_allow_strtoll="yes"
40064 else
40065 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40066$as_echo "no" >&6; }
40067 tst_allow_strtoll="no"
40068 fi
40069 fi
40070 #
40071 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if strtoll might be used" >&5
40072$as_echo_n "checking if strtoll might be used... " >&6; }
40073 if test "$tst_links_strtoll" = "yes" &&
40074 test "$tst_proto_strtoll" = "yes" &&
40075 test "$tst_compi_strtoll" = "yes" &&
40076 test "$tst_allow_strtoll" = "yes"; then
40077 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40078$as_echo "yes" >&6; }
40079
40080cat >>confdefs.h <<_ACEOF
40081#define HAVE_STRTOLL 1
40082_ACEOF
40083
40084 curl_cv_func_strtoll="yes"
40085 else
40086 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40087$as_echo "no" >&6; }
40088 curl_cv_func_strtoll="no"
40089 fi
40090
40091
40092curl_includes_sys_uio="\
40093/* includes start */
40094#ifdef HAVE_SYS_TYPES_H
40095# include <sys/types.h>
40096#endif
40097#ifdef HAVE_SYS_UIO_H
40098# include <sys/uio.h>
40099#endif
40100/* includes end */"
40101 for ac_header in sys/types.h sys/uio.h
40102do :
40103 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
40104ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$curl_includes_sys_uio
40105"
40106if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
40107 cat >>confdefs.h <<_ACEOF
40108#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
40109_ACEOF
40110
40111fi
40112
40113done
40114
40115
40116
40117 #
40118 tst_links_writev="unknown"
40119 tst_proto_writev="unknown"
40120 tst_compi_writev="unknown"
40121 tst_allow_writev="unknown"
40122 #
40123 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if writev can be linked" >&5
40124$as_echo_n "checking if writev can be linked... " >&6; }
40125 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40126/* end confdefs.h. */
40127
40128
40129#define writev innocuous_writev
40130#ifdef __STDC__
40131# include <limits.h>
40132#else
40133# include <assert.h>
40134#endif
40135#undef writev
40136#ifdef __cplusplus
40137extern "C"
40138#endif
40139char writev ();
40140#if defined __stub_writev || defined __stub___writev
40141choke me
40142#endif
40143
40144int main (void)
40145{
40146return writev ();
40147 ;
40148 return 0;
40149}
40150
40151_ACEOF
40152if ac_fn_c_try_link "$LINENO"; then :
40153
40154 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40155$as_echo "yes" >&6; }
40156 tst_links_writev="yes"
40157
40158else
40159
40160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40161$as_echo "no" >&6; }
40162 tst_links_writev="no"
40163
40164fi
40165rm -f core conftest.err conftest.$ac_objext \
40166 conftest$ac_exeext conftest.$ac_ext
40167 #
40168 if test "$tst_links_writev" = "yes"; then
40169 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if writev is prototyped" >&5
40170$as_echo_n "checking if writev is prototyped... " >&6; }
40171 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40172/* end confdefs.h. */
40173
40174 $curl_includes_sys_uio
40175
40176_ACEOF
40177if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
40178 $EGREP "writev" >/dev/null 2>&1; then :
40179
40180 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40181$as_echo "yes" >&6; }
40182 tst_proto_writev="yes"
40183
40184else
40185
40186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40187$as_echo "no" >&6; }
40188 tst_proto_writev="no"
40189
40190fi
40191rm -f conftest*
40192
40193 fi
40194 #
40195 if test "$tst_proto_writev" = "yes"; then
40196 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if writev is compilable" >&5
40197$as_echo_n "checking if writev is compilable... " >&6; }
40198 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40199/* end confdefs.h. */
40200
40201
40202 $curl_includes_sys_uio
40203
40204int main (void)
40205{
40206
40207 if(0 != writev(0, 0, 0))
40208 return 1;
40209
40210 ;
40211 return 0;
40212}
40213
40214_ACEOF
40215if ac_fn_c_try_compile "$LINENO"; then :
40216
40217 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40218$as_echo "yes" >&6; }
40219 tst_compi_writev="yes"
40220
40221else
40222
40223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40224$as_echo "no" >&6; }
40225 tst_compi_writev="no"
40226
40227fi
40228rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
40229 fi
40230 #
40231 if test "$tst_compi_writev" = "yes"; then
40232 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if writev usage allowed" >&5
40233$as_echo_n "checking if writev usage allowed... " >&6; }
40234 if test "x$curl_disallow_writev" != "xyes"; then
40235 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40236$as_echo "yes" >&6; }
40237 tst_allow_writev="yes"
40238 else
40239 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40240$as_echo "no" >&6; }
40241 tst_allow_writev="no"
40242 fi
40243 fi
40244 #
40245 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if writev might be used" >&5
40246$as_echo_n "checking if writev might be used... " >&6; }
40247 if test "$tst_links_writev" = "yes" &&
40248 test "$tst_proto_writev" = "yes" &&
40249 test "$tst_compi_writev" = "yes" &&
40250 test "$tst_allow_writev" = "yes"; then
40251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40252$as_echo "yes" >&6; }
40253
40254cat >>confdefs.h <<_ACEOF
40255#define HAVE_WRITEV 1
40256_ACEOF
40257
40258 curl_cv_func_writev="yes"
40259 else
40260 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40261$as_echo "no" >&6; }
40262 curl_cv_func_writev="no"
40263 fi
40264
40265
40266case $host in
40267 *msdosdjgpp)
40268 ac_cv_func_pipe=no
40269 skipcheck_pipe=yes
40270 { $as_echo "$as_me:${as_lineno-$LINENO}: skip check for pipe on msdosdjgpp" >&5
40271$as_echo "$as_me: skip check for pipe on msdosdjgpp" >&6;}
40272 ;;
40273esac
40274
Elliott Hughes72d948d2018-08-03 14:37:21 -070040275ac_fn_c_check_decl "$LINENO" "getpwuid_r" "ac_cv_have_decl_getpwuid_r" "#include <pwd.h>
40276 #include <sys/types.h>
40277"
40278if test "x$ac_cv_have_decl_getpwuid_r" = xyes; then :
40279 ac_have_decl=1
40280else
40281 ac_have_decl=0
40282fi
40283
40284cat >>confdefs.h <<_ACEOF
40285#define HAVE_DECL_GETPWUID_R $ac_have_decl
40286_ACEOF
40287if test $ac_have_decl = 1; then :
40288
40289else
40290
40291$as_echo "#define HAVE_DECL_GETPWUID_R_MISSING 1" >>confdefs.h
40292
40293fi
40294
40295
40296
40297for ac_func in fnmatch \
40298 geteuid \
Elliott Hughes82be86d2017-09-20 17:00:17 -070040299 getpass_r \
40300 getppid \
40301 getpwuid \
40302 getpwuid_r \
40303 getrlimit \
40304 gettimeofday \
40305 if_nametoindex \
Alex Deymo486467e2017-12-19 19:04:07 +010040306 mach_absolute_time \
Elliott Hughes82be86d2017-09-20 17:00:17 -070040307 pipe \
40308 setlocale \
40309 setmode \
40310 setrlimit \
40311 utime \
40312 utimes
40313
40314do :
40315 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
40316ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
40317if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
40318 cat >>confdefs.h <<_ACEOF
40319#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
40320_ACEOF
40321
40322
40323else
40324
40325 func="$ac_func"
40326 eval skipcheck=\$skipcheck_$func
40327 if test "x$skipcheck" != "xyes"; then
40328 { $as_echo "$as_me:${as_lineno-$LINENO}: checking deeper for $func" >&5
40329$as_echo_n "checking deeper for $func... " >&6; }
40330 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40331/* end confdefs.h. */
40332
40333
40334
40335int main (void)
40336{
40337
40338 $func ();
40339
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 eval "ac_cv_func_$func=yes"
40350
40351cat >>confdefs.h <<_ACEOF
40352#define `echo "HAVE_$func" | sed 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/' | sed 's/^A-Z0-9_/_/g'` 1
40353_ACEOF
40354
40355
40356else
40357
40358 { $as_echo "$as_me:${as_lineno-$LINENO}: result: but still no" >&5
40359$as_echo "but still no" >&6; }
40360
40361fi
40362rm -f core conftest.err conftest.$ac_objext \
40363 conftest$ac_exeext conftest.$ac_ext
40364 fi
40365
40366fi
40367done
40368
40369
Elliott Hughes82be86d2017-09-20 17:00:17 -070040370if test "$ipv6" = "yes"; then
40371 if test "$curl_cv_func_getaddrinfo" = "yes"; then
40372
40373$as_echo "#define ENABLE_IPV6 1" >>confdefs.h
40374
40375 IPV6_ENABLED=1
40376
40377 fi
Elliott Hughes82be86d2017-09-20 17:00:17 -070040378fi
40379
40380
40381 #
40382 tst_method="unknown"
40383
40384 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to set a socket into non-blocking mode" >&5
40385$as_echo_n "checking how to set a socket into non-blocking mode... " >&6; }
40386 if test "x$curl_cv_func_fcntl_o_nonblock" = "xyes"; then
40387 tst_method="fcntl O_NONBLOCK"
40388 elif test "x$curl_cv_func_ioctl_fionbio" = "xyes"; then
40389 tst_method="ioctl FIONBIO"
40390 elif test "x$curl_cv_func_ioctlsocket_fionbio" = "xyes"; then
40391 tst_method="ioctlsocket FIONBIO"
40392 elif test "x$curl_cv_func_ioctlsocket_camel_fionbio" = "xyes"; then
40393 tst_method="IoctlSocket FIONBIO"
40394 elif test "x$curl_cv_func_setsockopt_so_nonblock" = "xyes"; then
40395 tst_method="setsockopt SO_NONBLOCK"
40396 fi
40397 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tst_method" >&5
40398$as_echo "$tst_method" >&6; }
40399 if test "$tst_method" = "unknown"; then
40400 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot determine non-blocking socket method." >&5
40401$as_echo "$as_me: WARNING: cannot determine non-blocking socket method." >&2;}
40402 fi
40403
40404
40405
40406# Extract the first word of "perl", so it can be a program name with args.
40407set dummy perl; ac_word=$2
40408{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
40409$as_echo_n "checking for $ac_word... " >&6; }
40410if ${ac_cv_path_PERL+:} false; then :
40411 $as_echo_n "(cached) " >&6
40412else
40413 case $PERL in
40414 [\\/]* | ?:[\\/]*)
40415 ac_cv_path_PERL="$PERL" # Let the user override the test with a path.
40416 ;;
40417 *)
40418 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
40419as_dummy="$PATH:/usr/local/bin/perl:/usr/bin/:/usr/local/bin "
40420for as_dir in $as_dummy
40421do
40422 IFS=$as_save_IFS
40423 test -z "$as_dir" && as_dir=.
40424 for ac_exec_ext in '' $ac_executable_extensions; do
40425 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
40426 ac_cv_path_PERL="$as_dir/$ac_word$ac_exec_ext"
40427 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
40428 break 2
40429 fi
40430done
40431 done
40432IFS=$as_save_IFS
40433
40434 ;;
40435esac
40436fi
40437PERL=$ac_cv_path_PERL
40438if test -n "$PERL"; then
40439 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PERL" >&5
40440$as_echo "$PERL" >&6; }
40441else
40442 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40443$as_echo "no" >&6; }
40444fi
40445
40446
40447
40448
40449for ac_prog in gnroff nroff
40450do
40451 # Extract the first word of "$ac_prog", so it can be a program name with args.
40452set dummy $ac_prog; ac_word=$2
40453{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
40454$as_echo_n "checking for $ac_word... " >&6; }
40455if ${ac_cv_path_NROFF+:} false; then :
40456 $as_echo_n "(cached) " >&6
40457else
40458 case $NROFF in
40459 [\\/]* | ?:[\\/]*)
40460 ac_cv_path_NROFF="$NROFF" # Let the user override the test with a path.
40461 ;;
40462 *)
40463 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
40464as_dummy="$PATH:/usr/bin/:/usr/local/bin "
40465for as_dir in $as_dummy
40466do
40467 IFS=$as_save_IFS
40468 test -z "$as_dir" && as_dir=.
40469 for ac_exec_ext in '' $ac_executable_extensions; do
40470 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
40471 ac_cv_path_NROFF="$as_dir/$ac_word$ac_exec_ext"
40472 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
40473 break 2
40474 fi
40475done
40476 done
40477IFS=$as_save_IFS
40478
40479 ;;
40480esac
40481fi
40482NROFF=$ac_cv_path_NROFF
40483if test -n "$NROFF"; then
40484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NROFF" >&5
40485$as_echo "$NROFF" >&6; }
40486else
40487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40488$as_echo "no" >&6; }
40489fi
40490
40491
40492 test -n "$NROFF" && break
40493done
40494
40495
40496
40497if test -n "$NROFF"; then
40498
40499 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to use *nroff to get plain text from man pages" >&5
40500$as_echo_n "checking how to use *nroff to get plain text from man pages... " >&6; }
40501 MANOPT="-man"
40502 mancheck=`echo foo | $NROFF $MANOPT 2>/dev/null`
40503 if test -z "$mancheck"; then
40504 MANOPT="-mandoc"
40505 mancheck=`echo foo | $NROFF $MANOPT 2>/dev/null`
40506 if test -z "$mancheck"; then
40507 MANOPT=""
40508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
40509$as_echo "failed" >&6; }
40510 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: found no *nroff option to get plaintext from man pages" >&5
40511$as_echo "$as_me: WARNING: found no *nroff option to get plaintext from man pages" >&2;}
40512 else
40513 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANOPT" >&5
40514$as_echo "$MANOPT" >&6; }
40515 fi
40516 else
40517 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANOPT" >&5
40518$as_echo "$MANOPT" >&6; }
40519 fi
40520
40521fi
40522
40523if test -z "$MANOPT"
40524then
40525 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: disabling built-in manual" >&5
40526$as_echo "$as_me: WARNING: disabling built-in manual" >&2;}
40527 USE_MANUAL="no";
40528fi
40529
40530
40531if test "$USE_MANUAL" = "1"; then
40532
40533$as_echo "#define USE_MANUAL 1" >>confdefs.h
40534
40535 curl_manual_msg="enabled"
40536fi
40537
40538 if test x"$USE_MANUAL" = x1; then
40539 USE_MANUAL_TRUE=
40540 USE_MANUAL_FALSE='#'
40541else
40542 USE_MANUAL_TRUE='#'
40543 USE_MANUAL_FALSE=
40544fi
40545
40546
40547
40548
40549
40550 #
40551 if test "$want_ares" = "yes"; then
40552 clean_CPPFLAGS="$CPPFLAGS"
40553 clean_LDFLAGS="$LDFLAGS"
40554 clean_LIBS="$LIBS"
40555 embedded_ares="unknown"
40556 configure_runpath=`pwd`
40557 embedded_ares_builddir="$configure_runpath/ares"
40558 if test -n "$want_ares_path"; then
Elliott Hughes72d948d2018-08-03 14:37:21 -070040559 ARES_PCDIR="$want_ares_path/lib/pkgconfig"
40560
40561 if test -n "$PKG_CONFIG"; then
40562 PKGCONFIG="$PKG_CONFIG"
40563 else
40564 if test -n "$ac_tool_prefix"; then
40565 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
40566set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
40567{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
40568$as_echo_n "checking for $ac_word... " >&6; }
40569if ${ac_cv_path_PKGCONFIG+:} false; then :
40570 $as_echo_n "(cached) " >&6
40571else
40572 case $PKGCONFIG in
40573 [\\/]* | ?:[\\/]*)
40574 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
40575 ;;
40576 *)
40577 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
40578as_dummy="$PATH:/usr/bin:/usr/local/bin"
40579for as_dir in $as_dummy
40580do
40581 IFS=$as_save_IFS
40582 test -z "$as_dir" && as_dir=.
40583 for ac_exec_ext in '' $ac_executable_extensions; do
40584 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
40585 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
40586 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
40587 break 2
40588 fi
40589done
40590 done
40591IFS=$as_save_IFS
40592
40593 ;;
40594esac
40595fi
40596PKGCONFIG=$ac_cv_path_PKGCONFIG
40597if test -n "$PKGCONFIG"; then
40598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
40599$as_echo "$PKGCONFIG" >&6; }
40600else
40601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40602$as_echo "no" >&6; }
40603fi
40604
40605
40606fi
40607if test -z "$ac_cv_path_PKGCONFIG"; then
40608 ac_pt_PKGCONFIG=$PKGCONFIG
40609 # Extract the first word of "pkg-config", so it can be a program name with args.
40610set dummy pkg-config; ac_word=$2
40611{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
40612$as_echo_n "checking for $ac_word... " >&6; }
40613if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
40614 $as_echo_n "(cached) " >&6
40615else
40616 case $ac_pt_PKGCONFIG in
40617 [\\/]* | ?:[\\/]*)
40618 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
40619 ;;
40620 *)
40621 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
40622as_dummy="$PATH:/usr/bin:/usr/local/bin"
40623for as_dir in $as_dummy
40624do
40625 IFS=$as_save_IFS
40626 test -z "$as_dir" && as_dir=.
40627 for ac_exec_ext in '' $ac_executable_extensions; do
40628 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
40629 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
40630 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
40631 break 2
40632 fi
40633done
40634 done
40635IFS=$as_save_IFS
40636
40637 ;;
40638esac
40639fi
40640ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
40641if test -n "$ac_pt_PKGCONFIG"; then
40642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
40643$as_echo "$ac_pt_PKGCONFIG" >&6; }
40644else
40645 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40646$as_echo "no" >&6; }
40647fi
40648
40649 if test "x$ac_pt_PKGCONFIG" = x; then
40650 PKGCONFIG="no"
40651 else
40652 case $cross_compiling:$ac_tool_warned in
40653yes:)
40654{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
40655$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
40656ac_tool_warned=yes ;;
40657esac
40658 PKGCONFIG=$ac_pt_PKGCONFIG
40659 fi
40660else
40661 PKGCONFIG="$ac_cv_path_PKGCONFIG"
40662fi
40663
40664 fi
40665
40666 if test "x$PKGCONFIG" != "xno"; then
40667 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libcares options with pkg-config" >&5
40668$as_echo_n "checking for libcares options with pkg-config... " >&6; }
40669 itexists=`
40670 if test -n "$ARES_PCDIR"; then
40671 PKG_CONFIG_LIBDIR="$ARES_PCDIR"
40672 export PKG_CONFIG_LIBDIR
40673 fi
40674 $PKGCONFIG --exists libcares >/dev/null 2>&1 && echo 1`
40675
40676 if test -z "$itexists"; then
40677 PKGCONFIG="no"
40678 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40679$as_echo "no" >&6; }
40680 else
40681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
40682$as_echo "found" >&6; }
40683 fi
40684 fi
40685
40686 if test "$PKGCONFIG" != "no" ; then
40687 ares_LIBS=`
40688 if test -n "$ARES_PCDIR"; then
40689 PKG_CONFIG_LIBDIR="$ARES_PCDIR"
40690 export PKG_CONFIG_LIBDIR
40691 fi
40692
40693 $PKGCONFIG --libs-only-l libcares`
40694 ares_LDFLAGS=`
40695 if test -n "$ARES_PCDIR"; then
40696 PKG_CONFIG_LIBDIR="$ARES_PCDIR"
40697 export PKG_CONFIG_LIBDIR
40698 fi
40699
40700 $PKGCONFIG --libs-only-L libcares`
40701 ares_CPPFLAGS=`
40702 if test -n "$ARES_PCDIR"; then
40703 PKG_CONFIG_LIBDIR="$ARES_PCDIR"
40704 export PKG_CONFIG_LIBDIR
40705 fi
40706
40707 $PKGCONFIG --cflags-only-I libcares`
40708 { $as_echo "$as_me:${as_lineno-$LINENO}: pkg-config: ares LIBS: \"$ares_LIBS\"" >&5
40709$as_echo "$as_me: pkg-config: ares LIBS: \"$ares_LIBS\"" >&6;}
40710 { $as_echo "$as_me:${as_lineno-$LINENO}: pkg-config: ares LDFLAGS: \"$ares_LDFLAGS\"" >&5
40711$as_echo "$as_me: pkg-config: ares LDFLAGS: \"$ares_LDFLAGS\"" >&6;}
40712 { $as_echo "$as_me:${as_lineno-$LINENO}: pkg-config: ares CPPFLAGS: \"$ares_CPPFLAGS\"" >&5
40713$as_echo "$as_me: pkg-config: ares CPPFLAGS: \"$ares_CPPFLAGS\"" >&6;}
40714 else
40715 ares_CPPFLAGS="-I$want_ares_path/include"
40716 ares_LDFLAGS="-L$want_ares_path/lib"
40717 ares_LIBS="-lcares"
40718 fi
Elliott Hughes82be86d2017-09-20 17:00:17 -070040719 else
40720 if test -d "$srcdir/ares"; then
40721 embedded_ares="yes"
40722 subdirs="$subdirs ares"
40723
40724 ares_CPPFLAGS=""
40725 ares_LDFLAGS="-L$embedded_ares_builddir"
40726 ares_LIBS="-lcares"
40727 else
Elliott Hughes72d948d2018-08-03 14:37:21 -070040728
40729 if test -n "$PKG_CONFIG"; then
40730 PKGCONFIG="$PKG_CONFIG"
40731 else
40732 if test -n "$ac_tool_prefix"; then
40733 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
40734set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
40735{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
40736$as_echo_n "checking for $ac_word... " >&6; }
40737if ${ac_cv_path_PKGCONFIG+:} false; then :
40738 $as_echo_n "(cached) " >&6
40739else
40740 case $PKGCONFIG in
40741 [\\/]* | ?:[\\/]*)
40742 ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
40743 ;;
40744 *)
40745 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
40746as_dummy="$PATH:/usr/bin:/usr/local/bin"
40747for as_dir in $as_dummy
40748do
40749 IFS=$as_save_IFS
40750 test -z "$as_dir" && as_dir=.
40751 for ac_exec_ext in '' $ac_executable_extensions; do
40752 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
40753 ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
40754 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
40755 break 2
40756 fi
40757done
40758 done
40759IFS=$as_save_IFS
40760
40761 ;;
40762esac
40763fi
40764PKGCONFIG=$ac_cv_path_PKGCONFIG
40765if test -n "$PKGCONFIG"; then
40766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
40767$as_echo "$PKGCONFIG" >&6; }
40768else
40769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40770$as_echo "no" >&6; }
40771fi
40772
40773
40774fi
40775if test -z "$ac_cv_path_PKGCONFIG"; then
40776 ac_pt_PKGCONFIG=$PKGCONFIG
40777 # Extract the first word of "pkg-config", so it can be a program name with args.
40778set dummy pkg-config; ac_word=$2
40779{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
40780$as_echo_n "checking for $ac_word... " >&6; }
40781if ${ac_cv_path_ac_pt_PKGCONFIG+:} false; then :
40782 $as_echo_n "(cached) " >&6
40783else
40784 case $ac_pt_PKGCONFIG in
40785 [\\/]* | ?:[\\/]*)
40786 ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
40787 ;;
40788 *)
40789 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
40790as_dummy="$PATH:/usr/bin:/usr/local/bin"
40791for as_dir in $as_dummy
40792do
40793 IFS=$as_save_IFS
40794 test -z "$as_dir" && as_dir=.
40795 for ac_exec_ext in '' $ac_executable_extensions; do
40796 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
40797 ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
40798 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
40799 break 2
40800 fi
40801done
40802 done
40803IFS=$as_save_IFS
40804
40805 ;;
40806esac
40807fi
40808ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
40809if test -n "$ac_pt_PKGCONFIG"; then
40810 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKGCONFIG" >&5
40811$as_echo "$ac_pt_PKGCONFIG" >&6; }
40812else
40813 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40814$as_echo "no" >&6; }
40815fi
40816
40817 if test "x$ac_pt_PKGCONFIG" = x; then
40818 PKGCONFIG="no"
40819 else
40820 case $cross_compiling:$ac_tool_warned in
40821yes:)
40822{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
40823$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
40824ac_tool_warned=yes ;;
40825esac
40826 PKGCONFIG=$ac_pt_PKGCONFIG
40827 fi
40828else
40829 PKGCONFIG="$ac_cv_path_PKGCONFIG"
40830fi
40831
40832 fi
40833
40834 if test "x$PKGCONFIG" != "xno"; then
40835 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libcares options with pkg-config" >&5
40836$as_echo_n "checking for libcares options with pkg-config... " >&6; }
40837 itexists=`
40838 if test -n ""; then
40839 PKG_CONFIG_LIBDIR=""
40840 export PKG_CONFIG_LIBDIR
40841 fi
40842 $PKGCONFIG --exists libcares >/dev/null 2>&1 && echo 1`
40843
40844 if test -z "$itexists"; then
40845 PKGCONFIG="no"
40846 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40847$as_echo "no" >&6; }
40848 else
40849 { $as_echo "$as_me:${as_lineno-$LINENO}: result: found" >&5
40850$as_echo "found" >&6; }
40851 fi
40852 fi
40853
40854 if test "$PKGCONFIG" != "no" ; then
40855 ares_LIBS=`$PKGCONFIG --libs-only-l libcares`
40856 ares_LDFLAGS=`$PKGCONFIG --libs-only-L libcares`
40857 ares_CPPFLAGS=`$PKGCONFIG --cflags-only-I libcares`
40858 { $as_echo "$as_me:${as_lineno-$LINENO}: pkg-config: ares_LIBS: \"$ares_LIBS\"" >&5
40859$as_echo "$as_me: pkg-config: ares_LIBS: \"$ares_LIBS\"" >&6;}
40860 { $as_echo "$as_me:${as_lineno-$LINENO}: pkg-config: ares_LDFLAGS: \"$ares_LDFLAGS\"" >&5
40861$as_echo "$as_me: pkg-config: ares_LDFLAGS: \"$ares_LDFLAGS\"" >&6;}
40862 { $as_echo "$as_me:${as_lineno-$LINENO}: pkg-config: ares_CPPFLAGS: \"$ares_CPPFLAGS\"" >&5
40863$as_echo "$as_me: pkg-config: ares_CPPFLAGS: \"$ares_CPPFLAGS\"" >&6;}
40864 else
40865 ares_CPPFLAGS=""
40866 ares_LDFLAGS=""
40867 ares_LIBS="-lcares"
40868 fi
Elliott Hughes82be86d2017-09-20 17:00:17 -070040869 fi
40870 fi
40871 #
40872 CPPFLAGS="$clean_CPPFLAGS $ares_CPPFLAGS"
40873 LDFLAGS="$clean_LDFLAGS $ares_LDFLAGS"
40874 LIBS="$ares_LIBS $clean_LIBS"
40875 #
40876 if test "$embedded_ares" != "yes"; then
40877 { $as_echo "$as_me:${as_lineno-$LINENO}: checking that c-ares is good and recent enough" >&5
40878$as_echo_n "checking that c-ares is good and recent enough... " >&6; }
40879 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40880/* end confdefs.h. */
40881
40882
40883#include <ares.h>
40884 /* set of dummy functions in case c-ares was built with debug */
40885 void curl_dofree() { }
40886 void curl_sclose() { }
40887 void curl_domalloc() { }
40888 void curl_docalloc() { }
40889 void curl_socket() { }
40890
40891int main (void)
40892{
40893
40894 ares_channel channel;
40895 ares_cancel(channel); /* added in 1.2.0 */
40896 ares_process_fd(channel, 0, 0); /* added in 1.4.0 */
40897 ares_dup(&channel, channel); /* added in 1.6.0 */
40898
40899 ;
40900 return 0;
40901}
40902
40903_ACEOF
40904if ac_fn_c_try_link "$LINENO"; then :
40905
40906 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40907$as_echo "yes" >&6; }
40908
40909else
40910
40911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40912$as_echo "no" >&6; }
40913 as_fn_error $? "c-ares library defective or too old" "$LINENO" 5
40914 CPPFLAGS="$clean_CPPFLAGS"
40915 LDFLAGS="$clean_LDFLAGS"
40916 LIBS="$clean_LIBS"
40917 # prevent usage
40918 want_ares="no"
40919
40920fi
40921rm -f core conftest.err conftest.$ac_objext \
40922 conftest$ac_exeext conftest.$ac_ext
40923 fi
40924 if test "$want_ares" = "yes"; then
40925
40926$as_echo "#define USE_ARES 1" >>confdefs.h
40927
40928 USE_ARES=1
40929
40930 curl_res_msg="c-ares"
40931 fi
40932 fi
40933
40934 if test x$embedded_ares = xyes; then
40935 USE_EMBEDDED_ARES_TRUE=
40936 USE_EMBEDDED_ARES_FALSE='#'
40937else
40938 USE_EMBEDDED_ARES_TRUE='#'
40939 USE_EMBEDDED_ARES_FALSE=
40940fi
40941
40942
40943if test "x$curl_cv_native_windows" != "xyes" &&
40944 test "x$enable_shared" = "xyes"; then
40945 build_libhostname=yes
40946else
40947 build_libhostname=no
40948fi
40949 if test x$build_libhostname = xyes; then
40950 BUILD_LIBHOSTNAME_TRUE=
40951 BUILD_LIBHOSTNAME_FALSE='#'
40952else
40953 BUILD_LIBHOSTNAME_TRUE='#'
40954 BUILD_LIBHOSTNAME_FALSE=
40955fi
40956
40957
40958if test "x$want_ares" != xyes; then
40959
40960 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable the threaded resolver" >&5
40961$as_echo_n "checking whether to enable the threaded resolver... " >&6; }
40962 OPT_THRES="default"
40963 # Check whether --enable-threaded_resolver was given.
40964if test "${enable_threaded_resolver+set}" = set; then :
40965 enableval=$enable_threaded_resolver; OPT_THRES=$enableval
40966fi
40967
40968 case "$OPT_THRES" in
Elliott Hughes82be86d2017-09-20 17:00:17 -070040969 no)
40970 want_thres="no"
40971 ;;
Alex Deymo486467e2017-12-19 19:04:07 +010040972 *)
40973 want_thres="yes"
40974 ;;
Elliott Hughes82be86d2017-09-20 17:00:17 -070040975 esac
40976 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $want_thres" >&5
40977$as_echo "$want_thres" >&6; }
40978
40979fi
40980
40981{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use POSIX threads for threaded resolver" >&5
40982$as_echo_n "checking whether to use POSIX threads for threaded resolver... " >&6; }
40983# Check whether --enable-pthreads was given.
40984if test "${enable_pthreads+set}" = set; then :
40985 enableval=$enable_pthreads; case "$enableval" in
40986 no) { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
40987$as_echo "no" >&6; }
40988 want_pthreads=no
40989 ;;
40990 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
40991$as_echo "yes" >&6; }
40992 want_pthreads=yes
40993 ;;
40994 esac
40995else
40996
40997 { $as_echo "$as_me:${as_lineno-$LINENO}: result: auto" >&5
40998$as_echo "auto" >&6; }
40999 want_pthreads=auto
41000
41001
41002fi
41003
41004
41005if test "$want_pthreads" != "no"; then
41006 if test "$want_pthreads" = "yes" && test "$dontwant_rt" = "yes"; then
41007 as_fn_error $? "options --enable-pthreads and --disable-rt are mutually exclusive" "$LINENO" 5
41008 fi
41009 if test "$dontwant_rt" != "no"; then
41010 if test "$want_pthreads" = "yes"; then
41011 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --enable-pthreads Ignored since librt is disabled." >&5
41012$as_echo "$as_me: WARNING: --enable-pthreads Ignored since librt is disabled." >&2;}
41013 fi
41014 want_pthreads=no
41015 fi
41016fi
41017
41018if test "$want_pthreads" != "no" && test "$want_thres" != "yes"; then
41019 want_pthreads=no
41020fi
41021
41022if test "$want_pthreads" != "no"; then
41023 ac_fn_c_check_header_mongrel "$LINENO" "pthread.h" "ac_cv_header_pthread_h" "$ac_includes_default"
41024if test "x$ac_cv_header_pthread_h" = xyes; then :
41025
41026$as_echo "#define HAVE_PTHREAD_H 1" >>confdefs.h
41027
41028 save_CFLAGS="$CFLAGS"
41029
41030 ac_fn_c_check_func "$LINENO" "pthread_create" "ac_cv_func_pthread_create"
41031if test "x$ac_cv_func_pthread_create" = xyes; then :
41032 USE_THREADS_POSIX=1
41033fi
41034
41035
Elliott Hughesa93fb052018-12-12 14:22:48 -080041036 case $host in
41037 *-hp-hpux*)
41038 USE_THREADS_POSIX=""
41039 ;;
41040 *)
41041 ;;
41042 esac
41043
Elliott Hughes82be86d2017-09-20 17:00:17 -070041044 if test "$USE_THREADS_POSIX" != "1"
41045 then
41046 CFLAGS="$CFLAGS -pthread"
41047 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in -lpthread" >&5
41048$as_echo_n "checking for pthread_create in -lpthread... " >&6; }
41049if ${ac_cv_lib_pthread_pthread_create+:} false; then :
41050 $as_echo_n "(cached) " >&6
41051else
41052 ac_check_lib_save_LIBS=$LIBS
41053LIBS="-lpthread $LIBS"
41054cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41055/* end confdefs.h. */
41056
41057
41058#ifdef __cplusplus
41059extern "C"
41060#endif
41061char pthread_create ();
41062int main (void)
41063{
41064return pthread_create ();
41065 ;
41066 return 0;
41067}
41068_ACEOF
41069if ac_fn_c_try_link "$LINENO"; then :
41070 ac_cv_lib_pthread_pthread_create=yes
41071else
41072 ac_cv_lib_pthread_pthread_create=no
41073fi
41074rm -f core conftest.err conftest.$ac_objext \
41075 conftest$ac_exeext conftest.$ac_ext
41076LIBS=$ac_check_lib_save_LIBS
41077fi
41078{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_create" >&5
41079$as_echo "$ac_cv_lib_pthread_pthread_create" >&6; }
41080if test "x$ac_cv_lib_pthread_pthread_create" = xyes; then :
41081 USE_THREADS_POSIX=1
41082else
41083 CFLAGS="$save_CFLAGS"
41084fi
41085
41086 fi
41087
41088 if test "x$USE_THREADS_POSIX" = "x1"
41089 then
41090
41091$as_echo "#define USE_THREADS_POSIX 1" >>confdefs.h
41092
41093 curl_res_msg="POSIX threaded"
41094 fi
41095
41096fi
41097
41098
41099fi
41100
41101if test "$want_thres" = "yes" && test "x$USE_THREADS_POSIX" != "x1"; then
41102 if test "$want_pthreads" = "yes"; then
41103 as_fn_error $? "--enable-pthreads but pthreads was not found" "$LINENO" 5
41104 fi
41105 if test "$curl_cv_native_windows" = "yes"; then
41106 USE_THREADS_WIN32=1
41107
41108$as_echo "#define USE_THREADS_WIN32 1" >>confdefs.h
41109
41110 curl_res_msg="Win32 threaded"
41111 else
41112 as_fn_error $? "Threaded resolver enabled but no thread library found" "$LINENO" 5
41113 fi
41114fi
41115
41116{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable verbose strings" >&5
41117$as_echo_n "checking whether to enable verbose strings... " >&6; }
41118# Check whether --enable-verbose was given.
41119if test "${enable_verbose+set}" = set; then :
41120 enableval=$enable_verbose; case "$enableval" in
41121 no)
41122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41123$as_echo "no" >&6; }
41124
41125$as_echo "#define CURL_DISABLE_VERBOSE_STRINGS 1" >>confdefs.h
41126
41127 curl_verbose_msg="no"
41128 ;;
41129 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41130$as_echo "yes" >&6; }
41131 ;;
41132 esac
41133else
41134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41135$as_echo "yes" >&6; }
41136
41137fi
41138
41139
41140{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable SSPI support (Windows native builds only)" >&5
41141$as_echo_n "checking whether to enable SSPI support (Windows native builds only)... " >&6; }
41142# Check whether --enable-sspi was given.
41143if test "${enable_sspi+set}" = set; then :
41144 enableval=$enable_sspi; case "$enableval" in
41145 yes)
41146 if test "$curl_cv_native_windows" = "yes"; then
41147 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41148$as_echo "yes" >&6; }
41149
41150$as_echo "#define USE_WINDOWS_SSPI 1" >>confdefs.h
41151
41152 USE_WINDOWS_SSPI=1
41153
41154 curl_sspi_msg="enabled"
41155 else
41156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41157$as_echo "no" >&6; }
41158 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --enable-sspi Ignored. Only supported on native Windows builds." >&5
41159$as_echo "$as_me: WARNING: --enable-sspi Ignored. Only supported on native Windows builds." >&2;}
41160 fi
41161 ;;
41162 *)
41163 if test "x$WINSSL_ENABLED" = "x1"; then
41164 # --with-winssl implies --enable-sspi
41165 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41166$as_echo "yes" >&6; }
41167 else
41168 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41169$as_echo "no" >&6; }
41170 fi
41171 ;;
41172 esac
41173else
41174 if test "x$WINSSL_ENABLED" = "x1"; then
41175 # --with-winssl implies --enable-sspi
41176 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41177$as_echo "yes" >&6; }
41178 else
41179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41180$as_echo "no" >&6; }
41181 fi
41182
41183fi
41184
41185
41186{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable cryptographic authentication methods" >&5
41187$as_echo_n "checking whether to enable cryptographic authentication methods... " >&6; }
41188# Check whether --enable-crypto-auth was given.
41189if test "${enable_crypto_auth+set}" = set; then :
41190 enableval=$enable_crypto_auth; case "$enableval" in
41191 no)
41192 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41193$as_echo "no" >&6; }
41194
41195$as_echo "#define CURL_DISABLE_CRYPTO_AUTH 1" >>confdefs.h
41196
41197 CURL_DISABLE_CRYPTO_AUTH=1
41198 ;;
41199 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41200$as_echo "yes" >&6; }
41201 ;;
41202 esac
41203else
41204 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41205$as_echo "yes" >&6; }
41206
41207fi
41208
41209
41210
41211 OPT_NTLM_WB="default"
41212 # Check whether --enable-ntlm-wb was given.
41213if test "${enable_ntlm_wb+set}" = set; then :
41214 enableval=$enable_ntlm_wb; OPT_NTLM_WB=$enableval
41215fi
41216
41217 want_ntlm_wb_file="/usr/bin/ntlm_auth"
41218 case "$OPT_NTLM_WB" in
41219 no)
41220 want_ntlm_wb="no"
41221 ;;
41222 default)
41223 want_ntlm_wb="yes"
41224 ;;
41225 *)
41226 want_ntlm_wb="yes"
41227 if test -n "$enableval" && test "$enableval" != "yes"; then
41228 want_ntlm_wb_file="$enableval"
41229 fi
41230 ;;
41231 esac
41232
41233
41234
41235 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable NTLM delegation to winbind's helper" >&5
41236$as_echo_n "checking whether to enable NTLM delegation to winbind's helper... " >&6; }
41237 if test "$curl_cv_native_windows" = "yes" ||
41238 test "x$SSL_ENABLED" = "x"; then
41239 want_ntlm_wb_file=""
41240 want_ntlm_wb="no"
41241 fi
41242 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $want_ntlm_wb" >&5
41243$as_echo "$want_ntlm_wb" >&6; }
41244 if test "$want_ntlm_wb" = "yes"; then
41245
41246$as_echo "#define NTLM_WB_ENABLED 1" >>confdefs.h
41247
41248
41249cat >>confdefs.h <<_ACEOF
41250#define NTLM_WB_FILE "$want_ntlm_wb_file"
41251_ACEOF
41252
41253 NTLM_WB_ENABLED=1
41254 fi
41255
41256
41257{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable TLS-SRP authentication" >&5
41258$as_echo_n "checking whether to enable TLS-SRP authentication... " >&6; }
41259# Check whether --enable-tls-srp was given.
41260if test "${enable_tls_srp+set}" = set; then :
41261 enableval=$enable_tls_srp; case "$enableval" in
41262 no)
41263 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41264$as_echo "no" >&6; }
Elliott Hughes82be86d2017-09-20 17:00:17 -070041265 want_tls_srp=no
41266 ;;
41267 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41268$as_echo "yes" >&6; }
41269 want_tls_srp=yes
41270 ;;
41271 esac
41272else
41273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41274$as_echo "yes" >&6; }
41275 want_tls_srp=yes
41276
41277fi
41278
41279
41280if test "$want_tls_srp" = "yes" && ( test "x$HAVE_GNUTLS_SRP" = "x1" || test "x$HAVE_OPENSSL_SRP" = "x1") ; then
41281
41282$as_echo "#define USE_TLS_SRP 1" >>confdefs.h
41283
41284 USE_TLS_SRP=1
41285 curl_tls_srp_msg="enabled"
41286fi
41287
41288{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable Unix domain sockets" >&5
41289$as_echo_n "checking whether to enable Unix domain sockets... " >&6; }
41290# Check whether --enable-unix-sockets was given.
41291if test "${enable_unix_sockets+set}" = set; then :
41292 enableval=$enable_unix_sockets; case "$enableval" in
41293 no) { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41294$as_echo "no" >&6; }
41295 want_unix_sockets=no
41296 ;;
41297 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41298$as_echo "yes" >&6; }
41299 want_unix_sockets=yes
41300 ;;
41301 esac
41302else
41303
41304 { $as_echo "$as_me:${as_lineno-$LINENO}: result: auto" >&5
41305$as_echo "auto" >&6; }
41306 want_unix_sockets=auto
41307
41308
41309fi
41310
41311if test "x$want_unix_sockets" != "xno"; then
41312 ac_fn_c_check_member "$LINENO" "struct sockaddr_un" "sun_path" "ac_cv_member_struct_sockaddr_un_sun_path" "
41313 #include <sys/un.h>
41314
41315"
41316if test "x$ac_cv_member_struct_sockaddr_un_sun_path" = xyes; then :
41317
41318
41319$as_echo "#define USE_UNIX_SOCKETS 1" >>confdefs.h
41320
41321 USE_UNIX_SOCKETS=1
41322
41323 curl_unix_sockets_msg="enabled"
41324
41325else
41326
41327 if test "x$want_unix_sockets" = "xyes"; then
41328 as_fn_error $? "--enable-unix-sockets is not available on this platform!" "$LINENO" 5
41329 fi
41330
41331fi
41332
41333fi
41334
Haibo Huang001784b2019-07-19 05:27:28 -070041335{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support cookies" >&5
41336$as_echo_n "checking whether to support cookies... " >&6; }
Elliott Hughes82be86d2017-09-20 17:00:17 -070041337# Check whether --enable-cookies was given.
41338if test "${enable_cookies+set}" = set; then :
41339 enableval=$enable_cookies; case "$enableval" in
41340 no)
41341 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41342$as_echo "no" >&6; }
41343
41344$as_echo "#define CURL_DISABLE_COOKIES 1" >>confdefs.h
41345
41346 ;;
41347 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41348$as_echo "yes" >&6; }
41349 ;;
41350 esac
41351else
41352 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41353$as_echo "yes" >&6; }
41354
41355fi
41356
41357
Haibo Huang001784b2019-07-19 05:27:28 -070041358{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support HTTP authentication" >&5
41359$as_echo_n "checking whether to support HTTP authentication... " >&6; }
41360# Check whether --enable-http-auth was given.
41361if test "${enable_http_auth+set}" = set; then :
41362 enableval=$enable_http_auth; case "$enableval" in
41363 no)
41364 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41365$as_echo "no" >&6; }
41366
41367$as_echo "#define CURL_DISABLE_HTTP_AUTH 1" >>confdefs.h
41368
41369 ;;
41370 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41371$as_echo "yes" >&6; }
41372 ;;
41373 esac
41374else
41375 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41376$as_echo "yes" >&6; }
41377
41378fi
41379
41380
41381{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support DoH" >&5
41382$as_echo_n "checking whether to support DoH... " >&6; }
41383# Check whether --enable-doh was given.
41384if test "${enable_doh+set}" = set; then :
41385 enableval=$enable_doh; case "$enableval" in
41386 no)
41387 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41388$as_echo "no" >&6; }
41389
41390$as_echo "#define CURL_DISABLE_DOH 1" >>confdefs.h
41391
41392 ;;
41393 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41394$as_echo "yes" >&6; }
41395 ;;
41396 esac
41397else
41398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41399$as_echo "yes" >&6; }
41400
41401fi
41402
41403
41404{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support the MIME API" >&5
41405$as_echo_n "checking whether to support the MIME API... " >&6; }
41406# Check whether --enable-mime was given.
41407if test "${enable_mime+set}" = set; then :
41408 enableval=$enable_mime; case "$enableval" in
41409 no)
41410 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41411$as_echo "no" >&6; }
41412
41413$as_echo "#define CURL_DISABLE_MIME 1" >>confdefs.h
41414
41415 ;;
41416 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41417$as_echo "yes" >&6; }
41418 ;;
41419 esac
41420else
41421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41422$as_echo "yes" >&6; }
41423
41424fi
41425
41426
41427{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support date parsing" >&5
41428$as_echo_n "checking whether to support date parsing... " >&6; }
41429# Check whether --enable-dateparse was given.
41430if test "${enable_dateparse+set}" = set; then :
41431 enableval=$enable_dateparse; case "$enableval" in
41432 no)
41433 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41434$as_echo "no" >&6; }
41435
41436$as_echo "#define CURL_DISABLE_PARSEDATE 1" >>confdefs.h
41437
41438 ;;
41439 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41440$as_echo "yes" >&6; }
41441 ;;
41442 esac
41443else
41444 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41445$as_echo "yes" >&6; }
41446
41447fi
41448
41449
41450{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support netrc parsing" >&5
41451$as_echo_n "checking whether to support netrc parsing... " >&6; }
41452# Check whether --enable-netrc was given.
41453if test "${enable_netrc+set}" = set; then :
41454 enableval=$enable_netrc; case "$enableval" in
41455 no)
41456 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41457$as_echo "no" >&6; }
41458
41459$as_echo "#define CURL_DISABLE_NETRC 1" >>confdefs.h
41460
41461 ;;
41462 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41463$as_echo "yes" >&6; }
41464 ;;
41465 esac
41466else
41467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41468$as_echo "yes" >&6; }
41469
41470fi
41471
41472
41473{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support progress-meter" >&5
41474$as_echo_n "checking whether to support progress-meter... " >&6; }
41475# Check whether --enable-progress-meter was given.
41476if test "${enable_progress_meter+set}" = set; then :
41477 enableval=$enable_progress_meter; case "$enableval" in
41478 no)
41479 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41480$as_echo "no" >&6; }
41481
41482$as_echo "#define CURL_DISABLE_PROGRESS_METER 1" >>confdefs.h
41483
41484 ;;
41485 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41486$as_echo "yes" >&6; }
41487 ;;
41488 esac
41489else
41490 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41491$as_echo "yes" >&6; }
41492
41493fi
41494
41495
41496{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support DNS shuffling" >&5
41497$as_echo_n "checking whether to support DNS shuffling... " >&6; }
41498# Check whether --enable-dnsshuffle was given.
41499if test "${enable_dnsshuffle+set}" = set; then :
41500 enableval=$enable_dnsshuffle; case "$enableval" in
41501 no)
41502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41503$as_echo "no" >&6; }
41504
41505$as_echo "#define CURL_DISABLE_SHUFFLE_DNS 1" >>confdefs.h
41506
41507 ;;
41508 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41509$as_echo "yes" >&6; }
41510 ;;
41511 esac
41512else
41513 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41514$as_echo "yes" >&6; }
41515
41516fi
41517
41518
Haibo Huang65021c72019-03-27 15:37:23 -070041519curl_altsvc_msg="no (--enable-alt-svc)";
41520{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to support alt-svc" >&5
41521$as_echo_n "checking whether to support alt-svc... " >&6; }
41522# Check whether --enable-alt-svc was given.
41523if test "${enable_alt_svc+set}" = set; then :
41524 enableval=$enable_alt_svc; case "$enableval" in
41525 no)
41526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41527$as_echo "no" >&6; }
41528 ;;
41529 *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41530$as_echo "yes" >&6; }
41531 curl_altsvc_msg="enabled";
41532 enable_altsvc="yes"
41533 experimental="alt-svc"
41534 ;;
41535 esac
41536else
41537 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41538$as_echo "no" >&6; }
41539
41540fi
41541
41542
41543if test "$enable_altsvc" = "yes"; then
41544
41545$as_echo "#define USE_ALTSVC 1" >>confdefs.h
41546
41547 experimental="alt-svc"
41548fi
41549
Elliott Hughes82be86d2017-09-20 17:00:17 -070041550
41551 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether hiding of library internal symbols will actually happen" >&5
41552$as_echo_n "checking whether hiding of library internal symbols will actually happen... " >&6; }
41553 CFLAG_CURL_SYMBOL_HIDING=""
41554 doing_symbol_hiding="no"
41555 if test x"$curl_cv_native_windows" != "xyes" &&
41556 test "$want_symbol_hiding" = "yes" &&
41557 test "$supports_symbol_hiding" = "yes"; then
41558 doing_symbol_hiding="yes"
41559 CFLAG_CURL_SYMBOL_HIDING="$symbol_hiding_CFLAGS"
41560
41561cat >>confdefs.h <<_ACEOF
41562#define CURL_EXTERN_SYMBOL $symbol_hiding_EXTERN
41563_ACEOF
41564
41565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
41566$as_echo "yes" >&6; }
41567 else
41568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
41569$as_echo "no" >&6; }
41570 fi
41571 if test x$doing_symbol_hiding = xyes; then
41572 DOING_CURL_SYMBOL_HIDING_TRUE=
41573 DOING_CURL_SYMBOL_HIDING_FALSE='#'
41574else
41575 DOING_CURL_SYMBOL_HIDING_TRUE='#'
41576 DOING_CURL_SYMBOL_HIDING_FALSE=
41577fi
41578
41579
41580
41581
Elliott Hughes82be86d2017-09-20 17:00:17 -070041582LIBCURL_LIBS=$LIBS
41583
41584
41585
41586
41587
41588BLANK_AT_MAKETIME=
41589
41590
41591 if test x$cross_compiling = xyes; then
41592 CROSSCOMPILING_TRUE=
41593 CROSSCOMPILING_FALSE='#'
41594else
41595 CROSSCOMPILING_TRUE='#'
41596 CROSSCOMPILING_FALSE=
41597fi
41598
41599
41600ENABLE_SHARED="$enable_shared"
41601
41602
41603ENABLE_STATIC="$enable_static"
41604
41605
41606
41607
41608if test "x$OPENSSL_ENABLED" = "x1"; then
41609 SUPPORT_FEATURES="$SUPPORT_FEATURES SSL"
41610elif test -n "$SSL_ENABLED"; then
41611 SUPPORT_FEATURES="$SUPPORT_FEATURES SSL"
41612fi
41613if test "x$IPV6_ENABLED" = "x1"; then
41614 SUPPORT_FEATURES="$SUPPORT_FEATURES IPv6"
41615fi
41616if test "x$USE_UNIX_SOCKETS" = "x1"; then
41617 SUPPORT_FEATURES="$SUPPORT_FEATURES UnixSockets"
41618fi
41619if test "x$HAVE_LIBZ" = "x1"; then
41620 SUPPORT_FEATURES="$SUPPORT_FEATURES libz"
41621fi
Alex Deymo486467e2017-12-19 19:04:07 +010041622if test "x$HAVE_BROTLI" = "x1"; then
41623 SUPPORT_FEATURES="$SUPPORT_FEATURES brotli"
41624fi
Elliott Hughes82be86d2017-09-20 17:00:17 -070041625if test "x$USE_ARES" = "x1" -o "x$USE_THREADS_POSIX" = "x1" \
41626 -o "x$USE_THREADS_WIN32" = "x1"; then
41627 SUPPORT_FEATURES="$SUPPORT_FEATURES AsynchDNS"
41628fi
41629if test "x$IDN_ENABLED" = "x1"; then
41630 SUPPORT_FEATURES="$SUPPORT_FEATURES IDN"
41631fi
41632if test "x$USE_WINDOWS_SSPI" = "x1"; then
41633 SUPPORT_FEATURES="$SUPPORT_FEATURES SSPI"
41634fi
41635
41636if test "x$HAVE_GSSAPI" = "x1"; then
41637 SUPPORT_FEATURES="$SUPPORT_FEATURES GSS-API"
41638fi
41639
Haibo Huang65021c72019-03-27 15:37:23 -070041640if test "x$curl_psl_msg" = "xenabled"; then
Elliott Hughes82be86d2017-09-20 17:00:17 -070041641 SUPPORT_FEATURES="$SUPPORT_FEATURES PSL"
41642fi
41643
Haibo Huang65021c72019-03-27 15:37:23 -070041644if test "x$enable_altsvc" = "xyes"; then
41645 SUPPORT_FEATURES="$SUPPORT_FEATURES alt-svc"
41646fi
41647
Elliott Hughes82be86d2017-09-20 17:00:17 -070041648if test "x$CURL_DISABLE_CRYPTO_AUTH" != "x1" -a \
41649 \( "x$HAVE_GSSAPI" = "x1" -o "x$USE_WINDOWS_SSPI" = "x1" \); then
41650 SUPPORT_FEATURES="$SUPPORT_FEATURES SPNEGO"
41651fi
41652
41653if test "x$CURL_DISABLE_CRYPTO_AUTH" != "x1" -a \
41654 \( "x$HAVE_GSSAPI" = "x1" -o "x$USE_WINDOWS_SSPI" = "x1" \); then
41655 SUPPORT_FEATURES="$SUPPORT_FEATURES Kerberos"
41656fi
41657
41658if test "x$CURL_DISABLE_CRYPTO_AUTH" != "x1"; then
41659 if test "x$OPENSSL_ENABLED" = "x1" -o "x$USE_WINDOWS_SSPI" = "x1" \
41660 -o "x$GNUTLS_ENABLED" = "x1" -o "x$MBEDTLS_ENABLED" = "x1" \
Haibo Huang65021c72019-03-27 15:37:23 -070041661 -o "x$NSS_ENABLED" = "x1" -o "x$SECURETRANSPORT_ENABLED" = "x1"; then
Elliott Hughes82be86d2017-09-20 17:00:17 -070041662 SUPPORT_FEATURES="$SUPPORT_FEATURES NTLM"
41663
41664 if test "x$CURL_DISABLE_HTTP" != "x1" -a \
41665 "x$NTLM_WB_ENABLED" = "x1"; then
41666 SUPPORT_FEATURES="$SUPPORT_FEATURES NTLM_WB"
41667 fi
41668 fi
41669fi
41670
41671if test "x$USE_TLS_SRP" = "x1"; then
41672 SUPPORT_FEATURES="$SUPPORT_FEATURES TLS-SRP"
41673fi
41674
41675if test "x$USE_NGHTTP2" = "x1"; then
41676 SUPPORT_FEATURES="$SUPPORT_FEATURES HTTP2"
41677fi
41678
Alex Deymo486467e2017-12-19 19:04:07 +010041679if test "x$CURL_WITH_MULTI_SSL" = "x1"; then
41680 SUPPORT_FEATURES="$SUPPORT_FEATURES MultiSSL"
41681fi
41682
Elliott Hughes82be86d2017-09-20 17:00:17 -070041683if test "x$OPENSSL_ENABLED" = "x1" -o "x$GNUTLS_ENABLED" = "x1" \
41684 -o "x$NSS_ENABLED" = "x1"; then
41685 SUPPORT_FEATURES="$SUPPORT_FEATURES HTTPS-proxy"
41686fi
41687
41688
41689
41690if test "x$CURL_DISABLE_HTTP" != "x1"; then
41691 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS HTTP"
41692 if test "x$SSL_ENABLED" = "x1"; then
41693 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS HTTPS"
41694 fi
41695fi
41696if test "x$CURL_DISABLE_FTP" != "x1"; then
41697 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS FTP"
41698 if test "x$SSL_ENABLED" = "x1"; then
41699 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS FTPS"
41700 fi
41701fi
41702if test "x$CURL_DISABLE_FILE" != "x1"; then
41703 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS FILE"
41704fi
41705if test "x$CURL_DISABLE_TELNET" != "x1"; then
41706 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS TELNET"
41707fi
41708if test "x$CURL_DISABLE_LDAP" != "x1"; then
41709 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS LDAP"
41710 if test "x$CURL_DISABLE_LDAPS" != "x1"; then
41711 if (test "x$USE_OPENLDAP" = "x1" && test "x$SSL_ENABLED" = "x1") ||
41712 (test "x$USE_OPENLDAP" != "x1" && test "x$HAVE_LDAP_SSL" = "x1"); then
41713 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS LDAPS"
41714 fi
41715 fi
41716fi
41717if test "x$CURL_DISABLE_DICT" != "x1"; then
41718 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS DICT"
41719fi
41720if test "x$CURL_DISABLE_TFTP" != "x1"; then
41721 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS TFTP"
41722fi
41723if test "x$CURL_DISABLE_GOPHER" != "x1"; then
41724 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS GOPHER"
41725fi
41726if test "x$CURL_DISABLE_POP3" != "x1"; then
41727 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS POP3"
41728 if test "x$SSL_ENABLED" = "x1"; then
41729 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS POP3S"
41730 fi
41731fi
41732if test "x$CURL_DISABLE_IMAP" != "x1"; then
41733 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS IMAP"
41734 if test "x$SSL_ENABLED" = "x1"; then
41735 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS IMAPS"
41736 fi
41737fi
41738if test "x$CURL_DISABLE_SMB" != "x1" \
41739 -a "x$CURL_DISABLE_CRYPTO_AUTH" != "x1" \
41740 -a \( "x$OPENSSL_ENABLED" = "x1" -o "x$USE_WINDOWS_SSPI" = "x1" \
41741 -o "x$GNUTLS_ENABLED" = "x1" -o "x$MBEDTLS_ENABLED" = "x1" \
Haibo Huang65021c72019-03-27 15:37:23 -070041742 -o "x$NSS_ENABLED" = "x1" -o "x$SECURETRANSPORT_ENABLED" = "x1" \); then
Elliott Hughes82be86d2017-09-20 17:00:17 -070041743 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS SMB"
41744 if test "x$SSL_ENABLED" = "x1"; then
41745 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS SMBS"
41746 fi
41747fi
41748if test "x$CURL_DISABLE_SMTP" != "x1"; then
41749 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS SMTP"
41750 if test "x$SSL_ENABLED" = "x1"; then
41751 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS SMTPS"
41752 fi
41753fi
41754if test "x$USE_LIBSSH2" = "x1"; then
41755 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS SCP"
41756 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS SFTP"
41757fi
Elliott Hughes0128fe42018-02-27 14:57:55 -080041758if test "x$USE_LIBSSH" = "x1"; then
41759 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS SCP"
41760 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS SFTP"
41761fi
Elliott Hughes82be86d2017-09-20 17:00:17 -070041762if test "x$CURL_DISABLE_RTSP" != "x1"; then
41763 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS RTSP"
41764fi
41765if test "x$USE_LIBRTMP" = "x1"; then
41766 SUPPORT_PROTOCOLS="$SUPPORT_PROTOCOLS RTMP"
41767fi
41768
41769SUPPORT_PROTOCOLS=`echo $SUPPORT_PROTOCOLS | tr ' ' '\012' | sort | tr '\012' ' '`
41770
41771
41772
41773
41774squeeze CFLAGS
41775squeeze CPPFLAGS
41776squeeze DEFS
41777squeeze LDFLAGS
41778squeeze LIBS
41779
41780squeeze LIBCURL_LIBS
41781squeeze CURL_NETWORK_LIBS
41782squeeze CURL_NETWORK_AND_TIME_LIBS
41783
41784squeeze SUPPORT_FEATURES
41785squeeze SUPPORT_PROTOCOLS
41786
41787
41788
41789 xc_bad_var_libs=no
41790 for xc_word in $LIBS; do
41791 case "$xc_word" in
41792 -l* | --library=*)
41793 :
41794 ;;
41795 *)
41796 xc_bad_var_libs=yes
41797 ;;
41798 esac
41799 done
41800 if test $xc_bad_var_libs = yes; then
41801 { $as_echo "$as_me:${as_lineno-$LINENO}: using LIBS: $LIBS" >&5
41802$as_echo "$as_me: using LIBS: $LIBS" >&6;}
41803 { $as_echo "$as_me:${as_lineno-$LINENO}: LIBS note: LIBS should only be used to specify libraries (-lname)." >&5
41804$as_echo "$as_me: LIBS note: LIBS should only be used to specify libraries (-lname)." >&6;}
41805 fi
41806
41807
41808 xc_bad_var_ldflags=no
41809 for xc_word in $LDFLAGS; do
41810 case "$xc_word" in
41811 -D*)
41812 xc_bad_var_ldflags=yes
41813 ;;
41814 -U*)
41815 xc_bad_var_ldflags=yes
41816 ;;
41817 -I*)
41818 xc_bad_var_ldflags=yes
41819 ;;
41820 -l* | --library=*)
41821 xc_bad_var_ldflags=yes
41822 ;;
41823 esac
41824 done
41825 if test $xc_bad_var_ldflags = yes; then
41826 { $as_echo "$as_me:${as_lineno-$LINENO}: using LDFLAGS: $LDFLAGS" >&5
41827$as_echo "$as_me: using LDFLAGS: $LDFLAGS" >&6;}
41828 xc_bad_var_msg="LDFLAGS note: LDFLAGS should only be used to specify linker flags, not"
41829 for xc_word in $LDFLAGS; do
41830 case "$xc_word" in
41831 -D*)
41832 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg macro definitions. Use CPPFLAGS for: $xc_word" >&5
41833$as_echo "$as_me: $xc_bad_var_msg macro definitions. Use CPPFLAGS for: $xc_word" >&6;}
41834 ;;
41835 -U*)
41836 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg macro suppressions. Use CPPFLAGS for: $xc_word" >&5
41837$as_echo "$as_me: $xc_bad_var_msg macro suppressions. Use CPPFLAGS for: $xc_word" >&6;}
41838 ;;
41839 -I*)
41840 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg include directories. Use CPPFLAGS for: $xc_word" >&5
41841$as_echo "$as_me: $xc_bad_var_msg include directories. Use CPPFLAGS for: $xc_word" >&6;}
41842 ;;
41843 -l* | --library=*)
41844 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg libraries. Use LIBS for: $xc_word" >&5
41845$as_echo "$as_me: $xc_bad_var_msg libraries. Use LIBS for: $xc_word" >&6;}
41846 ;;
41847 esac
41848 done
41849 fi
41850
41851
41852 xc_bad_var_cppflags=no
41853 for xc_word in $CPPFLAGS; do
41854 case "$xc_word" in
41855 -rpath*)
41856 xc_bad_var_cppflags=yes
41857 ;;
41858 -L* | --library-path=*)
41859 xc_bad_var_cppflags=yes
41860 ;;
41861 -l* | --library=*)
41862 xc_bad_var_cppflags=yes
41863 ;;
41864 esac
41865 done
41866 if test $xc_bad_var_cppflags = yes; then
41867 { $as_echo "$as_me:${as_lineno-$LINENO}: using CPPFLAGS: $CPPFLAGS" >&5
41868$as_echo "$as_me: using CPPFLAGS: $CPPFLAGS" >&6;}
41869 xc_bad_var_msg="CPPFLAGS note: CPPFLAGS should only be used to specify C preprocessor flags, not"
41870 for xc_word in $CPPFLAGS; do
41871 case "$xc_word" in
41872 -rpath*)
41873 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg library runtime directories. Use LDFLAGS for: $xc_word" >&5
41874$as_echo "$as_me: $xc_bad_var_msg library runtime directories. Use LDFLAGS for: $xc_word" >&6;}
41875 ;;
41876 -L* | --library-path=*)
41877 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg library directories. Use LDFLAGS for: $xc_word" >&5
41878$as_echo "$as_me: $xc_bad_var_msg library directories. Use LDFLAGS for: $xc_word" >&6;}
41879 ;;
41880 -l* | --library=*)
41881 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg libraries. Use LIBS for: $xc_word" >&5
41882$as_echo "$as_me: $xc_bad_var_msg libraries. Use LIBS for: $xc_word" >&6;}
41883 ;;
41884 esac
41885 done
41886 fi
41887
41888
41889 xc_bad_var_cflags=no
41890 for xc_word in $CFLAGS; do
41891 case "$xc_word" in
41892 -D*)
41893 xc_bad_var_cflags=yes
41894 ;;
41895 -U*)
41896 xc_bad_var_cflags=yes
41897 ;;
41898 -I*)
41899 xc_bad_var_cflags=yes
41900 ;;
41901 -rpath*)
41902 xc_bad_var_cflags=yes
41903 ;;
41904 -L* | --library-path=*)
41905 xc_bad_var_cflags=yes
41906 ;;
41907 -l* | --library=*)
41908 xc_bad_var_cflags=yes
41909 ;;
41910 esac
41911 done
41912 if test $xc_bad_var_cflags = yes; then
41913 { $as_echo "$as_me:${as_lineno-$LINENO}: using CFLAGS: $CFLAGS" >&5
41914$as_echo "$as_me: using CFLAGS: $CFLAGS" >&6;}
41915 xc_bad_var_msg="CFLAGS note: CFLAGS should only be used to specify C compiler flags, not"
41916 for xc_word in $CFLAGS; do
41917 case "$xc_word" in
41918 -D*)
41919 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg macro definitions. Use CPPFLAGS for: $xc_word" >&5
41920$as_echo "$as_me: $xc_bad_var_msg macro definitions. Use CPPFLAGS for: $xc_word" >&6;}
41921 ;;
41922 -U*)
41923 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg macro suppressions. Use CPPFLAGS for: $xc_word" >&5
41924$as_echo "$as_me: $xc_bad_var_msg macro suppressions. Use CPPFLAGS for: $xc_word" >&6;}
41925 ;;
41926 -I*)
41927 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg include directories. Use CPPFLAGS for: $xc_word" >&5
41928$as_echo "$as_me: $xc_bad_var_msg include directories. Use CPPFLAGS for: $xc_word" >&6;}
41929 ;;
41930 -rpath*)
41931 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg library runtime directories. Use LDFLAGS for: $xc_word" >&5
41932$as_echo "$as_me: $xc_bad_var_msg library runtime directories. Use LDFLAGS for: $xc_word" >&6;}
41933 ;;
41934 -L* | --library-path=*)
41935 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg library directories. Use LDFLAGS for: $xc_word" >&5
41936$as_echo "$as_me: $xc_bad_var_msg library directories. Use LDFLAGS for: $xc_word" >&6;}
41937 ;;
41938 -l* | --library=*)
41939 { $as_echo "$as_me:${as_lineno-$LINENO}: $xc_bad_var_msg libraries. Use LIBS for: $xc_word" >&5
41940$as_echo "$as_me: $xc_bad_var_msg libraries. Use LIBS for: $xc_word" >&6;}
41941 ;;
41942 esac
41943 done
41944 fi
41945
41946 if test $xc_bad_var_libs = yes ||
41947 test $xc_bad_var_cflags = yes ||
41948 test $xc_bad_var_ldflags = yes ||
41949 test $xc_bad_var_cppflags = yes; then
41950 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Continuing even with errors mentioned immediately above this line." >&5
41951$as_echo "$as_me: WARNING: Continuing even with errors mentioned immediately above this line." >&2;}
41952 fi
41953
41954
Elliott Hughes0128fe42018-02-27 14:57:55 -080041955SSL_BACKENDS=${ssl_backends}
41956
41957
Elliott Hughes82be86d2017-09-20 17:00:17 -070041958if test "x$want_curldebug_assumed" = "xyes" &&
41959 test "x$want_curldebug" = "xyes" && test "x$USE_ARES" = "x1"; then
41960 ac_configure_args="$ac_configure_args --enable-curldebug"
41961fi
41962
Haibo Huang21926d52019-01-08 14:27:10 -080041963ac_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 -070041964
41965cat >confcache <<\_ACEOF
41966# This file is a shell script that caches the results of configure
41967# tests run on this system so they can be shared between configure
41968# scripts and configure runs, see configure's option --config-cache.
41969# It is not useful on other systems. If it contains results you don't
41970# want to keep, you may remove or edit it.
41971#
41972# config.status only pays attention to the cache file if you give it
41973# the --recheck option to rerun configure.
41974#
41975# `ac_cv_env_foo' variables (set or unset) will be overridden when
41976# loading this file, other *unset* `ac_cv_foo' will be assigned the
41977# following values.
41978
41979_ACEOF
41980
41981# The following way of writing the cache mishandles newlines in values,
41982# but we know of no workaround that is simple, portable, and efficient.
41983# So, we kill variables containing newlines.
41984# Ultrix sh set writes to stderr and can't be redirected directly,
41985# and sets the high bit in the cache file unless we assign to the vars.
41986(
41987 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
41988 eval ac_val=\$$ac_var
41989 case $ac_val in #(
41990 *${as_nl}*)
41991 case $ac_var in #(
41992 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
41993$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
41994 esac
41995 case $ac_var in #(
41996 _ | IFS | as_nl) ;; #(
41997 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
41998 *) { eval $ac_var=; unset $ac_var;} ;;
41999 esac ;;
42000 esac
42001 done
42002
42003 (set) 2>&1 |
42004 case $as_nl`(ac_space=' '; set) 2>&1` in #(
42005 *${as_nl}ac_space=\ *)
42006 # `set' does not quote correctly, so add quotes: double-quote
42007 # substitution turns \\\\ into \\, and sed turns \\ into \.
42008 sed -n \
42009 "s/'/'\\\\''/g;
42010 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
42011 ;; #(
42012 *)
42013 # `set' quotes correctly as required by POSIX, so do not add quotes.
42014 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
42015 ;;
42016 esac |
42017 sort
42018) |
42019 sed '
42020 /^ac_cv_env_/b end
42021 t clear
42022 :clear
42023 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
42024 t end
42025 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
42026 :end' >>confcache
42027if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
42028 if test -w "$cache_file"; then
42029 if test "x$cache_file" != "x/dev/null"; then
42030 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
42031$as_echo "$as_me: updating cache $cache_file" >&6;}
42032 if test ! -f "$cache_file" || test -h "$cache_file"; then
42033 cat confcache >"$cache_file"
42034 else
42035 case $cache_file in #(
42036 */* | ?:*)
42037 mv -f confcache "$cache_file"$$ &&
42038 mv -f "$cache_file"$$ "$cache_file" ;; #(
42039 *)
42040 mv -f confcache "$cache_file" ;;
42041 esac
42042 fi
42043 fi
42044 else
42045 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
42046$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
42047 fi
42048fi
42049rm -f confcache
42050
42051test "x$prefix" = xNONE && prefix=$ac_default_prefix
42052# Let make expand exec_prefix.
42053test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
42054
42055DEFS=-DHAVE_CONFIG_H
42056
42057ac_libobjs=
42058ac_ltlibobjs=
42059U=
42060for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
42061 # 1. Remove the extension, and $U if already installed.
42062 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
42063 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
42064 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
42065 # will be set to the directory where LIBOBJS objects are built.
42066 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
42067 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
42068done
42069LIBOBJS=$ac_libobjs
42070
42071LTLIBOBJS=$ac_ltlibobjs
42072
42073
42074if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
42075 as_fn_error $? "conditional \"MAINTAINER_MODE\" was never defined.
42076Usually this means the macro was only invoked conditionally." "$LINENO" 5
42077fi
Elliott Hughes82be86d2017-09-20 17:00:17 -070042078{ $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5
42079$as_echo_n "checking that generated files are newer than configure... " >&6; }
42080 if test -n "$am_sleep_pid"; then
42081 # Hide warnings about reused PIDs.
42082 wait $am_sleep_pid 2>/dev/null
42083 fi
42084 { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5
42085$as_echo "done" >&6; }
42086if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
42087 as_fn_error $? "conditional \"AMDEP\" was never defined.
42088Usually this means the macro was only invoked conditionally." "$LINENO" 5
42089fi
42090if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
42091 as_fn_error $? "conditional \"am__fastdepCC\" was never defined.
42092Usually this means the macro was only invoked conditionally." "$LINENO" 5
42093fi
42094 if test -n "$EXEEXT"; then
42095 am__EXEEXT_TRUE=
42096 am__EXEEXT_FALSE='#'
42097else
42098 am__EXEEXT_TRUE='#'
42099 am__EXEEXT_FALSE=
42100fi
42101
42102if test -z "${CURL_LT_SHLIB_USE_VERSION_INFO_TRUE}" && test -z "${CURL_LT_SHLIB_USE_VERSION_INFO_FALSE}"; then
42103 as_fn_error $? "conditional \"CURL_LT_SHLIB_USE_VERSION_INFO\" was never defined.
42104Usually this means the macro was only invoked conditionally." "$LINENO" 5
42105fi
42106if test -z "${CURL_LT_SHLIB_USE_NO_UNDEFINED_TRUE}" && test -z "${CURL_LT_SHLIB_USE_NO_UNDEFINED_FALSE}"; then
42107 as_fn_error $? "conditional \"CURL_LT_SHLIB_USE_NO_UNDEFINED\" was never defined.
42108Usually this means the macro was only invoked conditionally." "$LINENO" 5
42109fi
42110if test -z "${CURL_LT_SHLIB_USE_MIMPURE_TEXT_TRUE}" && test -z "${CURL_LT_SHLIB_USE_MIMPURE_TEXT_FALSE}"; then
42111 as_fn_error $? "conditional \"CURL_LT_SHLIB_USE_MIMPURE_TEXT\" was never defined.
42112Usually this means the macro was only invoked conditionally." "$LINENO" 5
42113fi
42114if test -z "${USE_CPPFLAG_CURL_STATICLIB_TRUE}" && test -z "${USE_CPPFLAG_CURL_STATICLIB_FALSE}"; then
42115 as_fn_error $? "conditional \"USE_CPPFLAG_CURL_STATICLIB\" was never defined.
42116Usually this means the macro was only invoked conditionally." "$LINENO" 5
42117fi
42118if test -z "${USE_EXPLICIT_LIB_DEPS_TRUE}" && test -z "${USE_EXPLICIT_LIB_DEPS_FALSE}"; then
42119 as_fn_error $? "conditional \"USE_EXPLICIT_LIB_DEPS\" was never defined.
42120Usually this means the macro was only invoked conditionally." "$LINENO" 5
42121fi
42122if test -z "${CURLDEBUG_TRUE}" && test -z "${CURLDEBUG_FALSE}"; then
42123 as_fn_error $? "conditional \"CURLDEBUG\" was never defined.
42124Usually this means the macro was only invoked conditionally." "$LINENO" 5
42125fi
42126if test -z "${BUILD_UNITTESTS_TRUE}" && test -z "${BUILD_UNITTESTS_FALSE}"; then
42127 as_fn_error $? "conditional \"BUILD_UNITTESTS\" was never defined.
42128Usually this means the macro was only invoked conditionally." "$LINENO" 5
42129fi
42130if test -z "${DOING_NATIVE_WINDOWS_TRUE}" && test -z "${DOING_NATIVE_WINDOWS_FALSE}"; then
42131 as_fn_error $? "conditional \"DOING_NATIVE_WINDOWS\" was never defined.
42132Usually this means the macro was only invoked conditionally." "$LINENO" 5
42133fi
42134if test -z "${HAVE_LIBZ_TRUE}" && test -z "${HAVE_LIBZ_FALSE}"; then
42135 as_fn_error $? "conditional \"HAVE_LIBZ\" was never defined.
42136Usually this means the macro was only invoked conditionally." "$LINENO" 5
42137fi
Alex Deymo486467e2017-12-19 19:04:07 +010042138if test -z "${BUILD_STUB_GSS_TRUE}" && test -z "${BUILD_STUB_GSS_FALSE}"; then
42139 as_fn_error $? "conditional \"BUILD_STUB_GSS\" was never defined.
42140Usually this means the macro was only invoked conditionally." "$LINENO" 5
42141fi
Elliott Hughes82be86d2017-09-20 17:00:17 -070042142if test -z "${USE_LIBPSL_TRUE}" && test -z "${USE_LIBPSL_FALSE}"; then
42143 as_fn_error $? "conditional \"USE_LIBPSL\" was never defined.
42144Usually this means the macro was only invoked conditionally." "$LINENO" 5
42145fi
42146if test -z "${CURL_LT_SHLIB_USE_VERSIONED_SYMBOLS_TRUE}" && test -z "${CURL_LT_SHLIB_USE_VERSIONED_SYMBOLS_FALSE}"; then
42147 as_fn_error $? "conditional \"CURL_LT_SHLIB_USE_VERSIONED_SYMBOLS\" was never defined.
42148Usually this means the macro was only invoked conditionally." "$LINENO" 5
42149fi
42150if test -z "${USE_MANUAL_TRUE}" && test -z "${USE_MANUAL_FALSE}"; then
42151 as_fn_error $? "conditional \"USE_MANUAL\" was never defined.
42152Usually this means the macro was only invoked conditionally." "$LINENO" 5
42153fi
42154if test -z "${USE_EMBEDDED_ARES_TRUE}" && test -z "${USE_EMBEDDED_ARES_FALSE}"; then
42155 as_fn_error $? "conditional \"USE_EMBEDDED_ARES\" was never defined.
42156Usually this means the macro was only invoked conditionally." "$LINENO" 5
42157fi
42158if test -z "${BUILD_LIBHOSTNAME_TRUE}" && test -z "${BUILD_LIBHOSTNAME_FALSE}"; then
42159 as_fn_error $? "conditional \"BUILD_LIBHOSTNAME\" was never defined.
42160Usually this means the macro was only invoked conditionally." "$LINENO" 5
42161fi
42162if test -z "${DOING_CURL_SYMBOL_HIDING_TRUE}" && test -z "${DOING_CURL_SYMBOL_HIDING_FALSE}"; then
42163 as_fn_error $? "conditional \"DOING_CURL_SYMBOL_HIDING\" was never defined.
42164Usually this means the macro was only invoked conditionally." "$LINENO" 5
42165fi
Elliott Hughes82be86d2017-09-20 17:00:17 -070042166if test -z "${CROSSCOMPILING_TRUE}" && test -z "${CROSSCOMPILING_FALSE}"; then
42167 as_fn_error $? "conditional \"CROSSCOMPILING\" was never defined.
42168Usually this means the macro was only invoked conditionally." "$LINENO" 5
42169fi
42170
42171: "${CONFIG_STATUS=./config.status}"
42172ac_write_fail=0
42173ac_clean_files_save=$ac_clean_files
42174ac_clean_files="$ac_clean_files $CONFIG_STATUS"
42175{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
42176$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
42177as_write_fail=0
42178cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
42179#! $SHELL
42180# Generated by $as_me.
42181# Run this file to recreate the current configuration.
42182# Compiler output produced by configure, useful for debugging
42183# configure, is in config.log if it exists.
42184
42185debug=false
42186ac_cs_recheck=false
42187ac_cs_silent=false
42188
42189SHELL=\${CONFIG_SHELL-$SHELL}
42190export SHELL
42191_ASEOF
42192cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
42193## -------------------- ##
42194## M4sh Initialization. ##
42195## -------------------- ##
42196
42197# Be more Bourne compatible
42198DUALCASE=1; export DUALCASE # for MKS sh
42199if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
42200 emulate sh
42201 NULLCMD=:
42202 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
42203 # is contrary to our usage. Disable this feature.
42204 alias -g '${1+"$@"}'='"$@"'
42205 setopt NO_GLOB_SUBST
42206else
42207 case `(set -o) 2>/dev/null` in #(
42208 *posix*) :
42209 set -o posix ;; #(
42210 *) :
42211 ;;
42212esac
42213fi
42214
42215
42216as_nl='
42217'
42218export as_nl
42219# Printing a long string crashes Solaris 7 /usr/bin/printf.
42220as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
42221as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
42222as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
42223# Prefer a ksh shell builtin over an external printf program on Solaris,
42224# but without wasting forks for bash or zsh.
42225if test -z "$BASH_VERSION$ZSH_VERSION" \
42226 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
42227 as_echo='print -r --'
42228 as_echo_n='print -rn --'
42229elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
42230 as_echo='printf %s\n'
42231 as_echo_n='printf %s'
42232else
42233 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
42234 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
42235 as_echo_n='/usr/ucb/echo -n'
42236 else
42237 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
42238 as_echo_n_body='eval
42239 arg=$1;
42240 case $arg in #(
42241 *"$as_nl"*)
42242 expr "X$arg" : "X\\(.*\\)$as_nl";
42243 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
42244 esac;
42245 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
42246 '
42247 export as_echo_n_body
42248 as_echo_n='sh -c $as_echo_n_body as_echo'
42249 fi
42250 export as_echo_body
42251 as_echo='sh -c $as_echo_body as_echo'
42252fi
42253
42254
42255
42256# IFS
42257# We need space, tab and new line, in precisely that order. Quoting is
42258# there to prevent editors from complaining about space-tab.
42259# (If _AS_PATH_WALK were called with IFS unset, it would disable word
42260# splitting by setting IFS to empty value.)
42261IFS=" "" $as_nl"
42262
42263# Find who we are. Look in the path if we contain no directory separator.
42264as_myself=
42265case $0 in #((
42266 *[\\/]* ) as_myself=$0 ;;
42267 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
42268for as_dir in $PATH
42269do
42270 IFS=$as_save_IFS
42271 test -z "$as_dir" && as_dir=.
42272 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
42273 done
42274IFS=$as_save_IFS
42275
42276 ;;
42277esac
42278# We did not find ourselves, most probably we were run as `sh COMMAND'
42279# in which case we are not to be found in the path.
42280if test "x$as_myself" = x; then
42281 as_myself=$0
42282fi
42283if test ! -f "$as_myself"; then
42284 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
42285 exit 1
42286fi
42287
42288# Unset variables that we do not need and which cause bugs (e.g. in
42289# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
42290# suppresses any "Segmentation fault" message there. '((' could
42291# trigger a bug in pdksh 5.2.14.
42292for as_var in BASH_ENV ENV MAIL MAILPATH
42293do eval test x\${$as_var+set} = xset \
42294 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
42295done
42296PS1='$ '
42297PS2='> '
42298PS4='+ '
42299
42300# NLS nuisances.
42301LC_ALL=C
42302export LC_ALL
42303LANGUAGE=C
42304export LANGUAGE
42305
42306# CDPATH.
42307(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
42308
42309
42310# as_fn_error STATUS ERROR [LINENO LOG_FD]
42311# ----------------------------------------
42312# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
42313# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
42314# script with STATUS, using 1 if that was 0.
42315as_fn_error ()
42316{
42317 as_status=$1; test $as_status -eq 0 && as_status=1
42318 if test "$4"; then
42319 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
42320 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
42321 fi
42322 $as_echo "$as_me: error: $2" >&2
42323 as_fn_exit $as_status
42324} # as_fn_error
42325
42326
42327# as_fn_set_status STATUS
42328# -----------------------
42329# Set $? to STATUS, without forking.
42330as_fn_set_status ()
42331{
42332 return $1
42333} # as_fn_set_status
42334
42335# as_fn_exit STATUS
42336# -----------------
42337# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
42338as_fn_exit ()
42339{
42340 set +e
42341 as_fn_set_status $1
42342 exit $1
42343} # as_fn_exit
42344
42345# as_fn_unset VAR
42346# ---------------
42347# Portably unset VAR.
42348as_fn_unset ()
42349{
42350 { eval $1=; unset $1;}
42351}
42352as_unset=as_fn_unset
42353# as_fn_append VAR VALUE
42354# ----------------------
42355# Append the text in VALUE to the end of the definition contained in VAR. Take
42356# advantage of any shell optimizations that allow amortized linear growth over
42357# repeated appends, instead of the typical quadratic growth present in naive
42358# implementations.
42359if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
42360 eval 'as_fn_append ()
42361 {
42362 eval $1+=\$2
42363 }'
42364else
42365 as_fn_append ()
42366 {
42367 eval $1=\$$1\$2
42368 }
42369fi # as_fn_append
42370
42371# as_fn_arith ARG...
42372# ------------------
42373# Perform arithmetic evaluation on the ARGs, and store the result in the
42374# global $as_val. Take advantage of shells that can avoid forks. The arguments
42375# must be portable across $(()) and expr.
42376if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
42377 eval 'as_fn_arith ()
42378 {
42379 as_val=$(( $* ))
42380 }'
42381else
42382 as_fn_arith ()
42383 {
42384 as_val=`expr "$@" || test $? -eq 1`
42385 }
42386fi # as_fn_arith
42387
42388
42389if expr a : '\(a\)' >/dev/null 2>&1 &&
42390 test "X`expr 00001 : '.*\(...\)'`" = X001; then
42391 as_expr=expr
42392else
42393 as_expr=false
42394fi
42395
42396if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
42397 as_basename=basename
42398else
42399 as_basename=false
42400fi
42401
42402if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
42403 as_dirname=dirname
42404else
42405 as_dirname=false
42406fi
42407
42408as_me=`$as_basename -- "$0" ||
42409$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
42410 X"$0" : 'X\(//\)$' \| \
42411 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
42412$as_echo X/"$0" |
42413 sed '/^.*\/\([^/][^/]*\)\/*$/{
42414 s//\1/
42415 q
42416 }
42417 /^X\/\(\/\/\)$/{
42418 s//\1/
42419 q
42420 }
42421 /^X\/\(\/\).*/{
42422 s//\1/
42423 q
42424 }
42425 s/.*/./; q'`
42426
42427# Avoid depending upon Character Ranges.
42428as_cr_letters='abcdefghijklmnopqrstuvwxyz'
42429as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
42430as_cr_Letters=$as_cr_letters$as_cr_LETTERS
42431as_cr_digits='0123456789'
42432as_cr_alnum=$as_cr_Letters$as_cr_digits
42433
42434ECHO_C= ECHO_N= ECHO_T=
42435case `echo -n x` in #(((((
42436-n*)
42437 case `echo 'xy\c'` in
42438 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
42439 xy) ECHO_C='\c';;
42440 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
42441 ECHO_T=' ';;
42442 esac;;
42443*)
42444 ECHO_N='-n';;
42445esac
42446
42447rm -f conf$$ conf$$.exe conf$$.file
42448if test -d conf$$.dir; then
42449 rm -f conf$$.dir/conf$$.file
42450else
42451 rm -f conf$$.dir
42452 mkdir conf$$.dir 2>/dev/null
42453fi
42454if (echo >conf$$.file) 2>/dev/null; then
42455 if ln -s conf$$.file conf$$ 2>/dev/null; then
42456 as_ln_s='ln -s'
42457 # ... but there are two gotchas:
42458 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
42459 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
42460 # In both cases, we have to default to `cp -pR'.
42461 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
42462 as_ln_s='cp -pR'
42463 elif ln conf$$.file conf$$ 2>/dev/null; then
42464 as_ln_s=ln
42465 else
42466 as_ln_s='cp -pR'
42467 fi
42468else
42469 as_ln_s='cp -pR'
42470fi
42471rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
42472rmdir conf$$.dir 2>/dev/null
42473
42474
42475# as_fn_mkdir_p
42476# -------------
42477# Create "$as_dir" as a directory, including parents if necessary.
42478as_fn_mkdir_p ()
42479{
42480
42481 case $as_dir in #(
42482 -*) as_dir=./$as_dir;;
42483 esac
42484 test -d "$as_dir" || eval $as_mkdir_p || {
42485 as_dirs=
42486 while :; do
42487 case $as_dir in #(
42488 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
42489 *) as_qdir=$as_dir;;
42490 esac
42491 as_dirs="'$as_qdir' $as_dirs"
42492 as_dir=`$as_dirname -- "$as_dir" ||
42493$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
42494 X"$as_dir" : 'X\(//\)[^/]' \| \
42495 X"$as_dir" : 'X\(//\)$' \| \
42496 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
42497$as_echo X"$as_dir" |
42498 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
42499 s//\1/
42500 q
42501 }
42502 /^X\(\/\/\)[^/].*/{
42503 s//\1/
42504 q
42505 }
42506 /^X\(\/\/\)$/{
42507 s//\1/
42508 q
42509 }
42510 /^X\(\/\).*/{
42511 s//\1/
42512 q
42513 }
42514 s/.*/./; q'`
42515 test -d "$as_dir" && break
42516 done
42517 test -z "$as_dirs" || eval "mkdir $as_dirs"
42518 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
42519
42520
42521} # as_fn_mkdir_p
42522if mkdir -p . 2>/dev/null; then
42523 as_mkdir_p='mkdir -p "$as_dir"'
42524else
42525 test -d ./-p && rmdir ./-p
42526 as_mkdir_p=false
42527fi
42528
42529
42530# as_fn_executable_p FILE
42531# -----------------------
42532# Test if FILE is an executable regular file.
42533as_fn_executable_p ()
42534{
42535 test -f "$1" && test -x "$1"
42536} # as_fn_executable_p
42537as_test_x='test -x'
42538as_executable_p=as_fn_executable_p
42539
42540# Sed expression to map a string onto a valid CPP name.
42541as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
42542
42543# Sed expression to map a string onto a valid variable name.
42544as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
42545
42546
42547exec 6>&1
42548## ----------------------------------- ##
42549## Main body of $CONFIG_STATUS script. ##
42550## ----------------------------------- ##
42551_ASEOF
42552test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
42553
42554cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
42555# Save the log message, to keep $0 and so on meaningful, and to
42556# report actual input values of CONFIG_FILES etc. instead of their
42557# values after options handling.
42558ac_log="
42559This file was extended by curl $as_me -, which was
42560generated by GNU Autoconf 2.69. Invocation command line was
42561
42562 CONFIG_FILES = $CONFIG_FILES
42563 CONFIG_HEADERS = $CONFIG_HEADERS
42564 CONFIG_LINKS = $CONFIG_LINKS
42565 CONFIG_COMMANDS = $CONFIG_COMMANDS
42566 $ $0 $@
42567
42568on `(hostname || uname -n) 2>/dev/null | sed 1q`
42569"
42570
42571_ACEOF
42572
42573case $ac_config_files in *"
42574"*) set x $ac_config_files; shift; ac_config_files=$*;;
42575esac
42576
42577case $ac_config_headers in *"
42578"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
42579esac
42580
42581
42582cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
42583# Files that config.status was made for.
42584config_files="$ac_config_files"
42585config_headers="$ac_config_headers"
42586config_commands="$ac_config_commands"
42587
42588_ACEOF
42589
42590cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
42591ac_cs_usage="\
42592\`$as_me' instantiates files and other configuration actions
42593from templates according to the current configuration. Unless the files
42594and actions are specified as TAGs, all are instantiated by default.
42595
42596Usage: $0 [OPTION]... [TAG]...
42597
42598 -h, --help print this help, then exit
42599 -V, --version print version number and configuration settings, then exit
42600 --config print configuration, then exit
42601 -q, --quiet, --silent
42602 do not print progress messages
42603 -d, --debug don't remove temporary files
42604 --recheck update $as_me by reconfiguring in the same conditions
42605 --file=FILE[:TEMPLATE]
42606 instantiate the configuration file FILE
42607 --header=FILE[:TEMPLATE]
42608 instantiate the configuration header FILE
42609
42610Configuration files:
42611$config_files
42612
42613Configuration headers:
42614$config_headers
42615
42616Configuration commands:
42617$config_commands
42618
42619Report bugs to <a suitable curl mailing list: https://curl.haxx.se/mail/>."
42620
42621_ACEOF
42622cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
42623ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
42624ac_cs_version="\\
42625curl config.status -
42626configured by $0, generated by GNU Autoconf 2.69,
42627 with options \\"\$ac_cs_config\\"
42628
42629Copyright (C) 2012 Free Software Foundation, Inc.
42630This config.status script is free software; the Free Software Foundation
42631gives unlimited permission to copy, distribute and modify it."
42632
42633ac_pwd='$ac_pwd'
42634srcdir='$srcdir'
42635INSTALL='$INSTALL'
42636MKDIR_P='$MKDIR_P'
42637AWK='$AWK'
42638test -n "\$AWK" || AWK=awk
42639_ACEOF
42640
42641cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
42642# The default lists apply if the user does not specify any file.
42643ac_need_defaults=:
42644while test $# != 0
42645do
42646 case $1 in
42647 --*=?*)
42648 ac_option=`expr "X$1" : 'X\([^=]*\)='`
42649 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
42650 ac_shift=:
42651 ;;
42652 --*=)
42653 ac_option=`expr "X$1" : 'X\([^=]*\)='`
42654 ac_optarg=
42655 ac_shift=:
42656 ;;
42657 *)
42658 ac_option=$1
42659 ac_optarg=$2
42660 ac_shift=shift
42661 ;;
42662 esac
42663
42664 case $ac_option in
42665 # Handling of the options.
42666 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
42667 ac_cs_recheck=: ;;
42668 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
42669 $as_echo "$ac_cs_version"; exit ;;
42670 --config | --confi | --conf | --con | --co | --c )
42671 $as_echo "$ac_cs_config"; exit ;;
42672 --debug | --debu | --deb | --de | --d | -d )
42673 debug=: ;;
42674 --file | --fil | --fi | --f )
42675 $ac_shift
42676 case $ac_optarg in
42677 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
42678 '') as_fn_error $? "missing file argument" ;;
42679 esac
42680 as_fn_append CONFIG_FILES " '$ac_optarg'"
42681 ac_need_defaults=false;;
42682 --header | --heade | --head | --hea )
42683 $ac_shift
42684 case $ac_optarg in
42685 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
42686 esac
42687 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
42688 ac_need_defaults=false;;
42689 --he | --h)
42690 # Conflict between --help and --header
42691 as_fn_error $? "ambiguous option: \`$1'
42692Try \`$0 --help' for more information.";;
42693 --help | --hel | -h )
42694 $as_echo "$ac_cs_usage"; exit ;;
42695 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
42696 | -silent | --silent | --silen | --sile | --sil | --si | --s)
42697 ac_cs_silent=: ;;
42698
42699 # This is an error.
42700 -*) as_fn_error $? "unrecognized option: \`$1'
42701Try \`$0 --help' for more information." ;;
42702
42703 *) as_fn_append ac_config_targets " $1"
42704 ac_need_defaults=false ;;
42705
42706 esac
42707 shift
42708done
42709
42710ac_configure_extra_args=
42711
42712if $ac_cs_silent; then
42713 exec 6>/dev/null
42714 ac_configure_extra_args="$ac_configure_extra_args --silent"
42715fi
42716
42717_ACEOF
42718cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
42719if \$ac_cs_recheck; then
42720 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
42721 shift
42722 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
42723 CONFIG_SHELL='$SHELL'
42724 export CONFIG_SHELL
42725 exec "\$@"
42726fi
42727
42728_ACEOF
42729cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
42730exec 5>>config.log
42731{
42732 echo
42733 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
42734## Running $as_me. ##
42735_ASBOX
42736 $as_echo "$ac_log"
42737} >&5
42738
42739_ACEOF
42740cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
42741#
42742# INIT-COMMANDS
42743#
Haibo Huang001784b2019-07-19 05:27:28 -070042744AMDEP_TRUE="$AMDEP_TRUE" MAKE="${MAKE-make}"
Elliott Hughes82be86d2017-09-20 17:00:17 -070042745
42746
42747# The HP-UX ksh and POSIX shell print the target directory to stdout
42748# if CDPATH is set.
42749(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
42750
42751sed_quote_subst='$sed_quote_subst'
42752double_quote_subst='$double_quote_subst'
42753delay_variable_subst='$delay_variable_subst'
42754macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`'
42755macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`'
42756AS='`$ECHO "$AS" | $SED "$delay_single_quote_subst"`'
42757DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`'
42758OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`'
42759enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`'
42760enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`'
42761pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`'
42762enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`'
42763shared_archive_member_spec='`$ECHO "$shared_archive_member_spec" | $SED "$delay_single_quote_subst"`'
42764SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`'
42765ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`'
42766PATH_SEPARATOR='`$ECHO "$PATH_SEPARATOR" | $SED "$delay_single_quote_subst"`'
42767host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`'
42768host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`'
42769host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`'
42770build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`'
42771build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`'
42772build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`'
42773SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`'
42774Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`'
42775GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`'
42776EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`'
42777FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`'
42778LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`'
42779NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`'
42780LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`'
42781max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`'
42782ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`'
42783exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
42784lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
42785lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
42786lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
42787lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`'
42788lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`'
42789reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`'
42790reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`'
42791deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`'
42792file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`'
42793file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`'
42794want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`'
42795sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`'
42796AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`'
42797AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`'
42798archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`'
42799STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
42800RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
42801old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
42802old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
42803old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`'
42804lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`'
42805CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`'
42806CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`'
42807compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`'
42808GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`'
42809lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`'
42810lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
42811lt_cv_sys_global_symbol_to_import='`$ECHO "$lt_cv_sys_global_symbol_to_import" | $SED "$delay_single_quote_subst"`'
42812lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
42813lt_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"`'
42814lt_cv_nm_interface='`$ECHO "$lt_cv_nm_interface" | $SED "$delay_single_quote_subst"`'
42815nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`'
42816lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`'
42817lt_cv_truncate_bin='`$ECHO "$lt_cv_truncate_bin" | $SED "$delay_single_quote_subst"`'
42818objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`'
42819MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`'
42820lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`'
42821lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`'
42822lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
42823lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`'
42824lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`'
42825need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`'
42826MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`'
42827DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
42828NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
42829LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
42830OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`'
42831OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`'
42832libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`'
42833shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`'
42834extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
42835archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`'
42836enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`'
42837export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`'
42838whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`'
42839compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`'
42840old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`'
42841old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
42842archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`'
42843archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`'
42844module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`'
42845module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`'
42846with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`'
42847allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`'
42848no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`'
42849hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`'
42850hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`'
42851hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`'
42852hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`'
42853hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`'
42854hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`'
42855hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
42856inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
42857link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
42858always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`'
42859export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`'
42860exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`'
42861include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`'
42862prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`'
42863postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`'
42864file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
42865variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
42866need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
42867need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`'
42868version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`'
42869runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`'
42870shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`'
42871shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`'
42872libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`'
42873library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`'
42874soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`'
42875install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`'
42876postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`'
42877postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
42878finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`'
42879finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`'
42880hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`'
42881sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`'
42882configure_time_dlsearch_path='`$ECHO "$configure_time_dlsearch_path" | $SED "$delay_single_quote_subst"`'
42883configure_time_lt_sys_library_path='`$ECHO "$configure_time_lt_sys_library_path" | $SED "$delay_single_quote_subst"`'
42884hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`'
42885enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`'
42886enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`'
42887enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`'
42888old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`'
42889striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`'
42890
42891LTCC='$LTCC'
42892LTCFLAGS='$LTCFLAGS'
42893compiler='$compiler_DEFAULT'
42894
42895# A function that is used when there is no print builtin or printf.
42896func_fallback_echo ()
42897{
42898 eval 'cat <<_LTECHO_EOF
42899\$1
42900_LTECHO_EOF'
42901}
42902
42903# Quote evaled strings.
42904for var in AS \
42905DLLTOOL \
42906OBJDUMP \
42907SHELL \
42908ECHO \
42909PATH_SEPARATOR \
42910SED \
42911GREP \
42912EGREP \
42913FGREP \
42914LD \
42915NM \
42916LN_S \
42917lt_SP2NL \
42918lt_NL2SP \
42919reload_flag \
42920deplibs_check_method \
42921file_magic_cmd \
42922file_magic_glob \
42923want_nocaseglob \
42924sharedlib_from_linklib_cmd \
42925AR \
42926AR_FLAGS \
42927archiver_list_spec \
42928STRIP \
42929RANLIB \
42930CC \
42931CFLAGS \
42932compiler \
42933lt_cv_sys_global_symbol_pipe \
42934lt_cv_sys_global_symbol_to_cdecl \
42935lt_cv_sys_global_symbol_to_import \
42936lt_cv_sys_global_symbol_to_c_name_address \
42937lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
42938lt_cv_nm_interface \
42939nm_file_list_spec \
42940lt_cv_truncate_bin \
42941lt_prog_compiler_no_builtin_flag \
42942lt_prog_compiler_pic \
42943lt_prog_compiler_wl \
42944lt_prog_compiler_static \
42945lt_cv_prog_compiler_c_o \
42946need_locks \
42947MANIFEST_TOOL \
42948DSYMUTIL \
42949NMEDIT \
42950LIPO \
42951OTOOL \
42952OTOOL64 \
42953shrext_cmds \
42954export_dynamic_flag_spec \
42955whole_archive_flag_spec \
42956compiler_needs_object \
42957with_gnu_ld \
42958allow_undefined_flag \
42959no_undefined_flag \
42960hardcode_libdir_flag_spec \
42961hardcode_libdir_separator \
42962exclude_expsyms \
42963include_expsyms \
42964file_list_spec \
42965variables_saved_for_relink \
42966libname_spec \
42967library_names_spec \
42968soname_spec \
42969install_override_mode \
42970finish_eval \
42971old_striplib \
42972striplib; do
42973 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
42974 *[\\\\\\\`\\"\\\$]*)
42975 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes
42976 ;;
42977 *)
42978 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
42979 ;;
42980 esac
42981done
42982
42983# Double-quote double-evaled strings.
42984for var in reload_cmds \
42985old_postinstall_cmds \
42986old_postuninstall_cmds \
42987old_archive_cmds \
42988extract_expsyms_cmds \
42989old_archive_from_new_cmds \
42990old_archive_from_expsyms_cmds \
42991archive_cmds \
42992archive_expsym_cmds \
42993module_cmds \
42994module_expsym_cmds \
42995export_symbols_cmds \
42996prelink_cmds \
42997postlink_cmds \
42998postinstall_cmds \
42999postuninstall_cmds \
43000finish_cmds \
43001sys_lib_search_path_spec \
43002configure_time_dlsearch_path \
43003configure_time_lt_sys_library_path; do
43004 case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
43005 *[\\\\\\\`\\"\\\$]*)
43006 eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes
43007 ;;
43008 *)
43009 eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
43010 ;;
43011 esac
43012done
43013
43014ac_aux_dir='$ac_aux_dir'
43015
43016# See if we are running on zsh, and set the options that allow our
43017# commands through without removal of \ escapes INIT.
43018if test -n "\${ZSH_VERSION+set}"; then
43019 setopt NO_GLOB_SUBST
43020fi
43021
43022
43023 PACKAGE='$PACKAGE'
43024 VERSION='$VERSION'
43025 RM='$RM'
43026 ofile='$ofile'
43027
43028
43029
43030
43031_ACEOF
43032
43033cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
43034
43035# Handling of arguments.
43036for ac_config_target in $ac_config_targets
43037do
43038 case $ac_config_target in
43039 "lib/curl_config.h") CONFIG_HEADERS="$CONFIG_HEADERS lib/curl_config.h" ;;
43040 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
43041 "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;;
43042 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
43043 "docs/Makefile") CONFIG_FILES="$CONFIG_FILES docs/Makefile" ;;
43044 "docs/examples/Makefile") CONFIG_FILES="$CONFIG_FILES docs/examples/Makefile" ;;
43045 "docs/libcurl/Makefile") CONFIG_FILES="$CONFIG_FILES docs/libcurl/Makefile" ;;
43046 "docs/libcurl/opts/Makefile") CONFIG_FILES="$CONFIG_FILES docs/libcurl/opts/Makefile" ;;
43047 "docs/cmdline-opts/Makefile") CONFIG_FILES="$CONFIG_FILES docs/cmdline-opts/Makefile" ;;
43048 "include/Makefile") CONFIG_FILES="$CONFIG_FILES include/Makefile" ;;
43049 "include/curl/Makefile") CONFIG_FILES="$CONFIG_FILES include/curl/Makefile" ;;
43050 "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
43051 "lib/Makefile") CONFIG_FILES="$CONFIG_FILES lib/Makefile" ;;
43052 "scripts/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/Makefile" ;;
43053 "lib/libcurl.vers") CONFIG_FILES="$CONFIG_FILES lib/libcurl.vers" ;;
43054 "tests/Makefile") CONFIG_FILES="$CONFIG_FILES tests/Makefile" ;;
43055 "tests/certs/Makefile") CONFIG_FILES="$CONFIG_FILES tests/certs/Makefile" ;;
43056 "tests/certs/scripts/Makefile") CONFIG_FILES="$CONFIG_FILES tests/certs/scripts/Makefile" ;;
43057 "tests/data/Makefile") CONFIG_FILES="$CONFIG_FILES tests/data/Makefile" ;;
43058 "tests/server/Makefile") CONFIG_FILES="$CONFIG_FILES tests/server/Makefile" ;;
43059 "tests/libtest/Makefile") CONFIG_FILES="$CONFIG_FILES tests/libtest/Makefile" ;;
43060 "tests/unit/Makefile") CONFIG_FILES="$CONFIG_FILES tests/unit/Makefile" ;;
Elliott Hughes82be86d2017-09-20 17:00:17 -070043061 "packages/Makefile") CONFIG_FILES="$CONFIG_FILES packages/Makefile" ;;
Elliott Hughes82be86d2017-09-20 17:00:17 -070043062 "packages/vms/Makefile") CONFIG_FILES="$CONFIG_FILES packages/vms/Makefile" ;;
Elliott Hughes82be86d2017-09-20 17:00:17 -070043063 "curl-config") CONFIG_FILES="$CONFIG_FILES curl-config" ;;
43064 "libcurl.pc") CONFIG_FILES="$CONFIG_FILES libcurl.pc" ;;
43065
43066 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
43067 esac
43068done
43069
43070
43071# If the user did not use the arguments to specify the items to instantiate,
43072# then the envvar interface is used. Set only those that are not.
43073# We use the long form for the default assignment because of an extremely
43074# bizarre bug on SunOS 4.1.3.
43075if $ac_need_defaults; then
43076 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
43077 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
43078 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
43079fi
43080
43081# Have a temporary directory for convenience. Make it in the build tree
43082# simply because there is no reason against having it here, and in addition,
43083# creating and moving files from /tmp can sometimes cause problems.
43084# Hook for its removal unless debugging.
43085# Note that there is a small window in which the directory will not be cleaned:
43086# after its creation but before its name has been assigned to `$tmp'.
43087$debug ||
43088{
43089 tmp= ac_tmp=
43090 trap 'exit_status=$?
43091 : "${ac_tmp:=$tmp}"
43092 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
43093' 0
43094 trap 'as_fn_exit 1' 1 2 13 15
43095}
43096# Create a (secure) tmp directory for tmp files.
43097
43098{
43099 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
43100 test -d "$tmp"
43101} ||
43102{
43103 tmp=./conf$$-$RANDOM
43104 (umask 077 && mkdir "$tmp")
43105} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
43106ac_tmp=$tmp
43107
43108# Set up the scripts for CONFIG_FILES section.
43109# No need to generate them if there are no CONFIG_FILES.
43110# This happens for instance with `./config.status config.h'.
43111if test -n "$CONFIG_FILES"; then
43112
43113
43114ac_cr=`echo X | tr X '\015'`
43115# On cygwin, bash can eat \r inside `` if the user requested igncr.
43116# But we know of no other shell where ac_cr would be empty at this
43117# point, so we can use a bashism as a fallback.
43118if test "x$ac_cr" = x; then
43119 eval ac_cr=\$\'\\r\'
43120fi
43121ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
43122if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
43123 ac_cs_awk_cr='\\r'
43124else
43125 ac_cs_awk_cr=$ac_cr
43126fi
43127
43128echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
43129_ACEOF
43130
43131
43132{
43133 echo "cat >conf$$subs.awk <<_ACEOF" &&
43134 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
43135 echo "_ACEOF"
43136} >conf$$subs.sh ||
43137 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
43138ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
43139ac_delim='%!_!# '
43140for ac_last_try in false false false false false :; do
43141 . ./conf$$subs.sh ||
43142 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
43143
43144 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
43145 if test $ac_delim_n = $ac_delim_num; then
43146 break
43147 elif $ac_last_try; then
43148 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
43149 else
43150 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
43151 fi
43152done
43153rm -f conf$$subs.sh
43154
43155cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
43156cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
43157_ACEOF
43158sed -n '
43159h
43160s/^/S["/; s/!.*/"]=/
43161p
43162g
43163s/^[^!]*!//
43164:repl
43165t repl
43166s/'"$ac_delim"'$//
43167t delim
43168:nl
43169h
43170s/\(.\{148\}\)..*/\1/
43171t more1
43172s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
43173p
43174n
43175b repl
43176:more1
43177s/["\\]/\\&/g; s/^/"/; s/$/"\\/
43178p
43179g
43180s/.\{148\}//
43181t nl
43182:delim
43183h
43184s/\(.\{148\}\)..*/\1/
43185t more2
43186s/["\\]/\\&/g; s/^/"/; s/$/"/
43187p
43188b
43189:more2
43190s/["\\]/\\&/g; s/^/"/; s/$/"\\/
43191p
43192g
43193s/.\{148\}//
43194t delim
43195' <conf$$subs.awk | sed '
43196/^[^""]/{
43197 N
43198 s/\n//
43199}
43200' >>$CONFIG_STATUS || ac_write_fail=1
43201rm -f conf$$subs.awk
43202cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
43203_ACAWK
43204cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
43205 for (key in S) S_is_set[key] = 1
43206 FS = ""
43207
43208}
43209{
43210 line = $ 0
43211 nfields = split(line, field, "@")
43212 substed = 0
43213 len = length(field[1])
43214 for (i = 2; i < nfields; i++) {
43215 key = field[i]
43216 keylen = length(key)
43217 if (S_is_set[key]) {
43218 value = S[key]
43219 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
43220 len += length(value) + length(field[++i])
43221 substed = 1
43222 } else
43223 len += 1 + keylen
43224 }
43225
43226 print line
43227}
43228
43229_ACAWK
43230_ACEOF
43231cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
43232if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
43233 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
43234else
43235 cat
43236fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
43237 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
43238_ACEOF
43239
43240# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
43241# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
43242# trailing colons and then remove the whole line if VPATH becomes empty
43243# (actually we leave an empty line to preserve line numbers).
43244if test "x$srcdir" = x.; then
43245 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
43246h
43247s///
43248s/^/:/
43249s/[ ]*$/:/
43250s/:\$(srcdir):/:/g
43251s/:\${srcdir}:/:/g
43252s/:@srcdir@:/:/g
43253s/^:*//
43254s/:*$//
43255x
43256s/\(=[ ]*\).*/\1/
43257G
43258s/\n//
43259s/^[^=]*=[ ]*$//
43260}'
43261fi
43262
43263cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
43264fi # test -n "$CONFIG_FILES"
43265
43266# Set up the scripts for CONFIG_HEADERS section.
43267# No need to generate them if there are no CONFIG_HEADERS.
43268# This happens for instance with `./config.status Makefile'.
43269if test -n "$CONFIG_HEADERS"; then
43270cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
43271BEGIN {
43272_ACEOF
43273
43274# Transform confdefs.h into an awk script `defines.awk', embedded as
43275# here-document in config.status, that substitutes the proper values into
43276# config.h.in to produce config.h.
43277
43278# Create a delimiter string that does not exist in confdefs.h, to ease
43279# handling of long lines.
43280ac_delim='%!_!# '
43281for ac_last_try in false false :; do
43282 ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
43283 if test -z "$ac_tt"; then
43284 break
43285 elif $ac_last_try; then
43286 as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
43287 else
43288 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
43289 fi
43290done
43291
43292# For the awk script, D is an array of macro values keyed by name,
43293# likewise P contains macro parameters if any. Preserve backslash
43294# newline sequences.
43295
43296ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
43297sed -n '
43298s/.\{148\}/&'"$ac_delim"'/g
43299t rset
43300:rset
43301s/^[ ]*#[ ]*define[ ][ ]*/ /
43302t def
43303d
43304:def
43305s/\\$//
43306t bsnl
43307s/["\\]/\\&/g
43308s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
43309D["\1"]=" \3"/p
43310s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
43311d
43312:bsnl
43313s/["\\]/\\&/g
43314s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
43315D["\1"]=" \3\\\\\\n"\\/p
43316t cont
43317s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
43318t cont
43319d
43320:cont
43321n
43322s/.\{148\}/&'"$ac_delim"'/g
43323t clear
43324:clear
43325s/\\$//
43326t bsnlc
43327s/["\\]/\\&/g; s/^/"/; s/$/"/p
43328d
43329:bsnlc
43330s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
43331b cont
43332' <confdefs.h | sed '
43333s/'"$ac_delim"'/"\\\
43334"/g' >>$CONFIG_STATUS || ac_write_fail=1
43335
43336cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
43337 for (key in D) D_is_set[key] = 1
43338 FS = ""
43339}
43340/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
43341 line = \$ 0
43342 split(line, arg, " ")
43343 if (arg[1] == "#") {
43344 defundef = arg[2]
43345 mac1 = arg[3]
43346 } else {
43347 defundef = substr(arg[1], 2)
43348 mac1 = arg[2]
43349 }
43350 split(mac1, mac2, "(") #)
43351 macro = mac2[1]
43352 prefix = substr(line, 1, index(line, defundef) - 1)
43353 if (D_is_set[macro]) {
43354 # Preserve the white space surrounding the "#".
43355 print prefix "define", macro P[macro] D[macro]
43356 next
43357 } else {
43358 # Replace #undef with comments. This is necessary, for example,
43359 # in the case of _POSIX_SOURCE, which is predefined and required
43360 # on some systems where configure will not decide to define it.
43361 if (defundef == "undef") {
43362 print "/*", prefix defundef, macro, "*/"
43363 next
43364 }
43365 }
43366}
43367{ print }
43368_ACAWK
43369_ACEOF
43370cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
43371 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
43372fi # test -n "$CONFIG_HEADERS"
43373
43374
43375eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
43376shift
43377for ac_tag
43378do
43379 case $ac_tag in
43380 :[FHLC]) ac_mode=$ac_tag; continue;;
43381 esac
43382 case $ac_mode$ac_tag in
43383 :[FHL]*:*);;
43384 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
43385 :[FH]-) ac_tag=-:-;;
43386 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
43387 esac
43388 ac_save_IFS=$IFS
43389 IFS=:
43390 set x $ac_tag
43391 IFS=$ac_save_IFS
43392 shift
43393 ac_file=$1
43394 shift
43395
43396 case $ac_mode in
43397 :L) ac_source=$1;;
43398 :[FH])
43399 ac_file_inputs=
43400 for ac_f
43401 do
43402 case $ac_f in
43403 -) ac_f="$ac_tmp/stdin";;
43404 *) # Look for the file first in the build tree, then in the source tree
43405 # (if the path is not absolute). The absolute path cannot be DOS-style,
43406 # because $ac_f cannot contain `:'.
43407 test -f "$ac_f" ||
43408 case $ac_f in
43409 [\\/$]*) false;;
43410 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
43411 esac ||
43412 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
43413 esac
43414 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
43415 as_fn_append ac_file_inputs " '$ac_f'"
43416 done
43417
43418 # Let's still pretend it is `configure' which instantiates (i.e., don't
43419 # use $as_me), people would be surprised to read:
43420 # /* config.h. Generated by config.status. */
43421 configure_input='Generated from '`
43422 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
43423 `' by configure.'
43424 if test x"$ac_file" != x-; then
43425 configure_input="$ac_file. $configure_input"
43426 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
43427$as_echo "$as_me: creating $ac_file" >&6;}
43428 fi
43429 # Neutralize special characters interpreted by sed in replacement strings.
43430 case $configure_input in #(
43431 *\&* | *\|* | *\\* )
43432 ac_sed_conf_input=`$as_echo "$configure_input" |
43433 sed 's/[\\\\&|]/\\\\&/g'`;; #(
43434 *) ac_sed_conf_input=$configure_input;;
43435 esac
43436
43437 case $ac_tag in
43438 *:-:* | *:-) cat >"$ac_tmp/stdin" \
43439 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
43440 esac
43441 ;;
43442 esac
43443
43444 ac_dir=`$as_dirname -- "$ac_file" ||
43445$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
43446 X"$ac_file" : 'X\(//\)[^/]' \| \
43447 X"$ac_file" : 'X\(//\)$' \| \
43448 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
43449$as_echo X"$ac_file" |
43450 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
43451 s//\1/
43452 q
43453 }
43454 /^X\(\/\/\)[^/].*/{
43455 s//\1/
43456 q
43457 }
43458 /^X\(\/\/\)$/{
43459 s//\1/
43460 q
43461 }
43462 /^X\(\/\).*/{
43463 s//\1/
43464 q
43465 }
43466 s/.*/./; q'`
43467 as_dir="$ac_dir"; as_fn_mkdir_p
43468 ac_builddir=.
43469
43470case "$ac_dir" in
43471.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
43472*)
43473 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
43474 # A ".." for each directory in $ac_dir_suffix.
43475 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
43476 case $ac_top_builddir_sub in
43477 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
43478 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
43479 esac ;;
43480esac
43481ac_abs_top_builddir=$ac_pwd
43482ac_abs_builddir=$ac_pwd$ac_dir_suffix
43483# for backward compatibility:
43484ac_top_builddir=$ac_top_build_prefix
43485
43486case $srcdir in
43487 .) # We are building in place.
43488 ac_srcdir=.
43489 ac_top_srcdir=$ac_top_builddir_sub
43490 ac_abs_top_srcdir=$ac_pwd ;;
43491 [\\/]* | ?:[\\/]* ) # Absolute name.
43492 ac_srcdir=$srcdir$ac_dir_suffix;
43493 ac_top_srcdir=$srcdir
43494 ac_abs_top_srcdir=$srcdir ;;
43495 *) # Relative name.
43496 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
43497 ac_top_srcdir=$ac_top_build_prefix$srcdir
43498 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
43499esac
43500ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
43501
43502
43503 case $ac_mode in
43504 :F)
43505 #
43506 # CONFIG_FILE
43507 #
43508
43509 case $INSTALL in
43510 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
43511 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
43512 esac
43513 ac_MKDIR_P=$MKDIR_P
43514 case $MKDIR_P in
43515 [\\/$]* | ?:[\\/]* ) ;;
43516 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
43517 esac
43518_ACEOF
43519
43520cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
43521# If the template does not know about datarootdir, expand it.
43522# FIXME: This hack should be removed a few years after 2.60.
43523ac_datarootdir_hack=; ac_datarootdir_seen=
43524ac_sed_dataroot='
43525/datarootdir/ {
43526 p
43527 q
43528}
43529/@datadir@/p
43530/@docdir@/p
43531/@infodir@/p
43532/@localedir@/p
43533/@mandir@/p'
43534case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
43535*datarootdir*) ac_datarootdir_seen=yes;;
43536*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
43537 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
43538$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
43539_ACEOF
43540cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
43541 ac_datarootdir_hack='
43542 s&@datadir@&$datadir&g
43543 s&@docdir@&$docdir&g
43544 s&@infodir@&$infodir&g
43545 s&@localedir@&$localedir&g
43546 s&@mandir@&$mandir&g
43547 s&\\\${datarootdir}&$datarootdir&g' ;;
43548esac
43549_ACEOF
43550
43551# Neutralize VPATH when `$srcdir' = `.'.
43552# Shell code in configure.ac might set extrasub.
43553# FIXME: do we really want to maintain this feature?
43554cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
43555ac_sed_extra="$ac_vpsub
43556$extrasub
43557_ACEOF
43558cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
43559:t
43560/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
43561s|@configure_input@|$ac_sed_conf_input|;t t
43562s&@top_builddir@&$ac_top_builddir_sub&;t t
43563s&@top_build_prefix@&$ac_top_build_prefix&;t t
43564s&@srcdir@&$ac_srcdir&;t t
43565s&@abs_srcdir@&$ac_abs_srcdir&;t t
43566s&@top_srcdir@&$ac_top_srcdir&;t t
43567s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
43568s&@builddir@&$ac_builddir&;t t
43569s&@abs_builddir@&$ac_abs_builddir&;t t
43570s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
43571s&@INSTALL@&$ac_INSTALL&;t t
43572s&@MKDIR_P@&$ac_MKDIR_P&;t t
43573$ac_datarootdir_hack
43574"
43575eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
43576 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
43577
43578test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
43579 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
43580 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
43581 "$ac_tmp/out"`; test -z "$ac_out"; } &&
43582 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
43583which seems to be undefined. Please make sure it is defined" >&5
43584$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
43585which seems to be undefined. Please make sure it is defined" >&2;}
43586
43587 rm -f "$ac_tmp/stdin"
43588 case $ac_file in
43589 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
43590 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
43591 esac \
43592 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
43593 ;;
43594 :H)
43595 #
43596 # CONFIG_HEADER
43597 #
43598 if test x"$ac_file" != x-; then
43599 {
43600 $as_echo "/* $configure_input */" \
43601 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
43602 } >"$ac_tmp/config.h" \
43603 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
43604 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
43605 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
43606$as_echo "$as_me: $ac_file is unchanged" >&6;}
43607 else
43608 rm -f "$ac_file"
43609 mv "$ac_tmp/config.h" "$ac_file" \
43610 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
43611 fi
43612 else
43613 $as_echo "/* $configure_input */" \
43614 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
43615 || as_fn_error $? "could not create -" "$LINENO" 5
43616 fi
43617# Compute "$ac_file"'s index in $config_headers.
43618_am_arg="$ac_file"
43619_am_stamp_count=1
43620for _am_header in $config_headers :; do
43621 case $_am_header in
43622 $_am_arg | $_am_arg:* )
43623 break ;;
43624 * )
43625 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
43626 esac
43627done
43628echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
43629$as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
43630 X"$_am_arg" : 'X\(//\)[^/]' \| \
43631 X"$_am_arg" : 'X\(//\)$' \| \
43632 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
43633$as_echo X"$_am_arg" |
43634 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
43635 s//\1/
43636 q
43637 }
43638 /^X\(\/\/\)[^/].*/{
43639 s//\1/
43640 q
43641 }
43642 /^X\(\/\/\)$/{
43643 s//\1/
43644 q
43645 }
43646 /^X\(\/\).*/{
43647 s//\1/
43648 q
43649 }
43650 s/.*/./; q'`/stamp-h$_am_stamp_count
43651 ;;
43652
43653 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
43654$as_echo "$as_me: executing $ac_file commands" >&6;}
43655 ;;
43656 esac
43657
43658
43659 case $ac_file$ac_mode in
43660 "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
43661 # Older Autoconf quotes --file arguments for eval, but not when files
43662 # are listed without --file. Let's play safe and only enable the eval
43663 # if we detect the quoting.
Haibo Huang001784b2019-07-19 05:27:28 -070043664 # TODO: see whether this extra hack can be removed once we start
43665 # requiring Autoconf 2.70 or later.
43666 case $CONFIG_FILES in #(
43667 *\'*) :
43668 eval set x "$CONFIG_FILES" ;; #(
43669 *) :
43670 set x $CONFIG_FILES ;; #(
43671 *) :
43672 ;;
43673esac
Elliott Hughes82be86d2017-09-20 17:00:17 -070043674 shift
Haibo Huang001784b2019-07-19 05:27:28 -070043675 # Used to flag and report bootstrapping failures.
43676 am_rc=0
43677 for am_mf
Elliott Hughes82be86d2017-09-20 17:00:17 -070043678 do
43679 # Strip MF so we end up with the name of the file.
Haibo Huang001784b2019-07-19 05:27:28 -070043680 am_mf=`$as_echo "$am_mf" | sed -e 's/:.*$//'`
43681 # Check whether this is an Automake generated Makefile which includes
43682 # dependency-tracking related rules and includes.
43683 # Grep'ing the whole file directly is not great: AIX grep has a line
Elliott Hughes82be86d2017-09-20 17:00:17 -070043684 # limit of 2048, but all sed's we know have understand at least 4000.
Haibo Huang001784b2019-07-19 05:27:28 -070043685 sed -n 's,^am--depfiles:.*,X,p' "$am_mf" | grep X >/dev/null 2>&1 \
43686 || continue
43687 am_dirpart=`$as_dirname -- "$am_mf" ||
43688$as_expr X"$am_mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
43689 X"$am_mf" : 'X\(//\)[^/]' \| \
43690 X"$am_mf" : 'X\(//\)$' \| \
43691 X"$am_mf" : 'X\(/\)' \| . 2>/dev/null ||
43692$as_echo X"$am_mf" |
Elliott Hughes82be86d2017-09-20 17:00:17 -070043693 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
43694 s//\1/
43695 q
43696 }
43697 /^X\(\/\/\)[^/].*/{
43698 s//\1/
43699 q
43700 }
43701 /^X\(\/\/\)$/{
43702 s//\1/
43703 q
43704 }
43705 /^X\(\/\).*/{
43706 s//\1/
43707 q
43708 }
43709 s/.*/./; q'`
Haibo Huang001784b2019-07-19 05:27:28 -070043710 am_filepart=`$as_basename -- "$am_mf" ||
43711$as_expr X/"$am_mf" : '.*/\([^/][^/]*\)/*$' \| \
43712 X"$am_mf" : 'X\(//\)$' \| \
43713 X"$am_mf" : 'X\(/\)' \| . 2>/dev/null ||
43714$as_echo X/"$am_mf" |
43715 sed '/^.*\/\([^/][^/]*\)\/*$/{
Elliott Hughes82be86d2017-09-20 17:00:17 -070043716 s//\1/
43717 q
43718 }
Haibo Huang001784b2019-07-19 05:27:28 -070043719 /^X\/\(\/\/\)$/{
Elliott Hughes82be86d2017-09-20 17:00:17 -070043720 s//\1/
43721 q
43722 }
Haibo Huang001784b2019-07-19 05:27:28 -070043723 /^X\/\(\/\).*/{
Elliott Hughes82be86d2017-09-20 17:00:17 -070043724 s//\1/
43725 q
43726 }
43727 s/.*/./; q'`
Haibo Huang001784b2019-07-19 05:27:28 -070043728 { echo "$as_me:$LINENO: cd "$am_dirpart" \
43729 && sed -e '/# am--include-marker/d' "$am_filepart" \
43730 | $MAKE -f - am--depfiles" >&5
43731 (cd "$am_dirpart" \
43732 && sed -e '/# am--include-marker/d' "$am_filepart" \
43733 | $MAKE -f - am--depfiles) >&5 2>&5
43734 ac_status=$?
43735 echo "$as_me:$LINENO: \$? = $ac_status" >&5
43736 (exit $ac_status); } || am_rc=$?
Elliott Hughes82be86d2017-09-20 17:00:17 -070043737 done
Haibo Huang001784b2019-07-19 05:27:28 -070043738 if test $am_rc -ne 0; then
43739 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
43740$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
43741as_fn_error $? "Something went wrong bootstrapping makefile fragments
43742 for automatic dependency tracking. Try re-running configure with the
43743 '--disable-dependency-tracking' option to at least be able to build
43744 the package (albeit without support for automatic dependency tracking).
43745See \`config.log' for more details" "$LINENO" 5; }
43746 fi
43747 { am_dirpart=; unset am_dirpart;}
43748 { am_filepart=; unset am_filepart;}
43749 { am_mf=; unset am_mf;}
43750 { am_rc=; unset am_rc;}
43751 rm -f conftest-deps.mk
Elliott Hughes82be86d2017-09-20 17:00:17 -070043752}
43753 ;;
43754 "libtool":C)
43755
43756 # See if we are running on zsh, and set the options that allow our
43757 # commands through without removal of \ escapes.
43758 if test -n "${ZSH_VERSION+set}"; then
43759 setopt NO_GLOB_SUBST
43760 fi
43761
43762 cfgfile=${ofile}T
43763 trap "$RM \"$cfgfile\"; exit 1" 1 2 15
43764 $RM "$cfgfile"
43765
43766 cat <<_LT_EOF >> "$cfgfile"
43767#! $SHELL
43768# Generated automatically by $as_me ($PACKAGE) $VERSION
43769# NOTE: Changes made to this file will be lost: look at ltmain.sh.
43770
43771# Provide generalized library-building support services.
43772# Written by Gordon Matzigkeit, 1996
43773
43774# Copyright (C) 2014 Free Software Foundation, Inc.
43775# This is free software; see the source for copying conditions. There is NO
43776# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
43777
43778# GNU Libtool is free software; you can redistribute it and/or modify
43779# it under the terms of the GNU General Public License as published by
43780# the Free Software Foundation; either version 2 of of the License, or
43781# (at your option) any later version.
43782#
43783# As a special exception to the GNU General Public License, if you
43784# distribute this file as part of a program or library that is built
43785# using GNU Libtool, you may include this file under the same
43786# distribution terms that you use for the rest of that program.
43787#
43788# GNU Libtool is distributed in the hope that it will be useful, but
43789# WITHOUT ANY WARRANTY; without even the implied warranty of
43790# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
43791# GNU General Public License for more details.
43792#
43793# You should have received a copy of the GNU General Public License
43794# along with this program. If not, see <http://www.gnu.org/licenses/>.
43795
43796
43797# The names of the tagged configurations supported by this script.
43798available_tags=''
43799
43800# Configured defaults for sys_lib_dlsearch_path munging.
43801: \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"}
43802
43803# ### BEGIN LIBTOOL CONFIG
43804
43805# Which release of libtool.m4 was used?
43806macro_version=$macro_version
43807macro_revision=$macro_revision
43808
43809# Assembler program.
43810AS=$lt_AS
43811
43812# DLL creation program.
43813DLLTOOL=$lt_DLLTOOL
43814
43815# Object dumper program.
43816OBJDUMP=$lt_OBJDUMP
43817
43818# Whether or not to build shared libraries.
43819build_libtool_libs=$enable_shared
43820
43821# Whether or not to build static libraries.
43822build_old_libs=$enable_static
43823
43824# What type of objects to build.
43825pic_mode=$pic_mode
43826
43827# Whether or not to optimize for fast installation.
43828fast_install=$enable_fast_install
43829
43830# Shared archive member basename,for filename based shared library versioning on AIX.
43831shared_archive_member_spec=$shared_archive_member_spec
43832
43833# Shell to use when invoking shell scripts.
43834SHELL=$lt_SHELL
43835
43836# An echo program that protects backslashes.
43837ECHO=$lt_ECHO
43838
43839# The PATH separator for the build system.
43840PATH_SEPARATOR=$lt_PATH_SEPARATOR
43841
43842# The host system.
43843host_alias=$host_alias
43844host=$host
43845host_os=$host_os
43846
43847# The build system.
43848build_alias=$build_alias
43849build=$build
43850build_os=$build_os
43851
43852# A sed program that does not truncate output.
43853SED=$lt_SED
43854
43855# Sed that helps us avoid accidentally triggering echo(1) options like -n.
43856Xsed="\$SED -e 1s/^X//"
43857
43858# A grep program that handles long lines.
43859GREP=$lt_GREP
43860
43861# An ERE matcher.
43862EGREP=$lt_EGREP
43863
43864# A literal string matcher.
43865FGREP=$lt_FGREP
43866
43867# A BSD- or MS-compatible name lister.
43868NM=$lt_NM
43869
43870# Whether we need soft or hard links.
43871LN_S=$lt_LN_S
43872
43873# What is the maximum length of a command?
43874max_cmd_len=$max_cmd_len
43875
43876# Object file suffix (normally "o").
43877objext=$ac_objext
43878
43879# Executable file suffix (normally "").
43880exeext=$exeext
43881
43882# whether the shell understands "unset".
43883lt_unset=$lt_unset
43884
43885# turn spaces into newlines.
43886SP2NL=$lt_lt_SP2NL
43887
43888# turn newlines into spaces.
43889NL2SP=$lt_lt_NL2SP
43890
43891# convert \$build file names to \$host format.
43892to_host_file_cmd=$lt_cv_to_host_file_cmd
43893
43894# convert \$build files to toolchain format.
43895to_tool_file_cmd=$lt_cv_to_tool_file_cmd
43896
43897# Method to check whether dependent libraries are shared objects.
43898deplibs_check_method=$lt_deplibs_check_method
43899
43900# Command to use when deplibs_check_method = "file_magic".
43901file_magic_cmd=$lt_file_magic_cmd
43902
43903# How to find potential files when deplibs_check_method = "file_magic".
43904file_magic_glob=$lt_file_magic_glob
43905
43906# Find potential files using nocaseglob when deplibs_check_method = "file_magic".
43907want_nocaseglob=$lt_want_nocaseglob
43908
43909# Command to associate shared and link libraries.
43910sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd
43911
43912# The archiver.
43913AR=$lt_AR
43914
43915# Flags to create an archive.
43916AR_FLAGS=$lt_AR_FLAGS
43917
43918# How to feed a file listing to the archiver.
43919archiver_list_spec=$lt_archiver_list_spec
43920
43921# A symbol stripping program.
43922STRIP=$lt_STRIP
43923
43924# Commands used to install an old-style archive.
43925RANLIB=$lt_RANLIB
43926old_postinstall_cmds=$lt_old_postinstall_cmds
43927old_postuninstall_cmds=$lt_old_postuninstall_cmds
43928
43929# Whether to use a lock for old archive extraction.
43930lock_old_archive_extraction=$lock_old_archive_extraction
43931
43932# A C compiler.
43933LTCC=$lt_CC
43934
43935# LTCC compiler flags.
43936LTCFLAGS=$lt_CFLAGS
43937
43938# Take the output of nm and produce a listing of raw symbols and C names.
43939global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
43940
43941# Transform the output of nm in a proper C declaration.
43942global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
43943
43944# Transform the output of nm into a list of symbols to manually relocate.
43945global_symbol_to_import=$lt_lt_cv_sys_global_symbol_to_import
43946
43947# Transform the output of nm in a C name address pair.
43948global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
43949
43950# Transform the output of nm in a C name address pair when lib prefix is needed.
43951global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
43952
43953# The name lister interface.
43954nm_interface=$lt_lt_cv_nm_interface
43955
43956# Specify filename containing input files for \$NM.
43957nm_file_list_spec=$lt_nm_file_list_spec
43958
43959# The root where to search for dependent libraries,and where our libraries should be installed.
43960lt_sysroot=$lt_sysroot
43961
43962# Command to truncate a binary pipe.
43963lt_truncate_bin=$lt_lt_cv_truncate_bin
43964
43965# The name of the directory that contains temporary libtool files.
43966objdir=$objdir
43967
43968# Used to examine libraries when file_magic_cmd begins with "file".
43969MAGIC_CMD=$MAGIC_CMD
43970
43971# Must we lock files when doing compilation?
43972need_locks=$lt_need_locks
43973
43974# Manifest tool.
43975MANIFEST_TOOL=$lt_MANIFEST_TOOL
43976
43977# Tool to manipulate archived DWARF debug symbol files on Mac OS X.
43978DSYMUTIL=$lt_DSYMUTIL
43979
43980# Tool to change global to local symbols on Mac OS X.
43981NMEDIT=$lt_NMEDIT
43982
43983# Tool to manipulate fat objects and archives on Mac OS X.
43984LIPO=$lt_LIPO
43985
43986# ldd/readelf like tool for Mach-O binaries on Mac OS X.
43987OTOOL=$lt_OTOOL
43988
43989# ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4.
43990OTOOL64=$lt_OTOOL64
43991
43992# Old archive suffix (normally "a").
43993libext=$libext
43994
43995# Shared library suffix (normally ".so").
43996shrext_cmds=$lt_shrext_cmds
43997
43998# The commands to extract the exported symbol list from a shared archive.
43999extract_expsyms_cmds=$lt_extract_expsyms_cmds
44000
44001# Variables whose values should be saved in libtool wrapper scripts and
44002# restored at link time.
44003variables_saved_for_relink=$lt_variables_saved_for_relink
44004
44005# Do we need the "lib" prefix for modules?
44006need_lib_prefix=$need_lib_prefix
44007
44008# Do we need a version for libraries?
44009need_version=$need_version
44010
44011# Library versioning type.
44012version_type=$version_type
44013
44014# Shared library runtime path variable.
44015runpath_var=$runpath_var
44016
44017# Shared library path variable.
44018shlibpath_var=$shlibpath_var
44019
44020# Is shlibpath searched before the hard-coded library search path?
44021shlibpath_overrides_runpath=$shlibpath_overrides_runpath
44022
44023# Format of library name prefix.
44024libname_spec=$lt_libname_spec
44025
44026# List of archive names. First name is the real one, the rest are links.
44027# The last name is the one that the linker finds with -lNAME
44028library_names_spec=$lt_library_names_spec
44029
44030# The coded name of the library, if different from the real name.
44031soname_spec=$lt_soname_spec
44032
44033# Permission mode override for installation of shared libraries.
44034install_override_mode=$lt_install_override_mode
44035
44036# Command to use after installation of a shared archive.
44037postinstall_cmds=$lt_postinstall_cmds
44038
44039# Command to use after uninstallation of a shared archive.
44040postuninstall_cmds=$lt_postuninstall_cmds
44041
44042# Commands used to finish a libtool library installation in a directory.
44043finish_cmds=$lt_finish_cmds
44044
44045# As "finish_cmds", except a single script fragment to be evaled but
44046# not shown.
44047finish_eval=$lt_finish_eval
44048
44049# Whether we should hardcode library paths into libraries.
44050hardcode_into_libs=$hardcode_into_libs
44051
44052# Compile-time system search path for libraries.
44053sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
44054
44055# Detected run-time system search path for libraries.
44056sys_lib_dlsearch_path_spec=$lt_configure_time_dlsearch_path
44057
44058# Explicit LT_SYS_LIBRARY_PATH set during ./configure time.
44059configure_time_lt_sys_library_path=$lt_configure_time_lt_sys_library_path
44060
44061# Whether dlopen is supported.
44062dlopen_support=$enable_dlopen
44063
44064# Whether dlopen of programs is supported.
44065dlopen_self=$enable_dlopen_self
44066
44067# Whether dlopen of statically linked programs is supported.
44068dlopen_self_static=$enable_dlopen_self_static
44069
44070# Commands to strip libraries.
44071old_striplib=$lt_old_striplib
44072striplib=$lt_striplib
44073
44074
44075# The linker used to build libraries.
44076LD=$lt_LD
44077
44078# How to create reloadable object files.
44079reload_flag=$lt_reload_flag
44080reload_cmds=$lt_reload_cmds
44081
44082# Commands used to build an old-style archive.
44083old_archive_cmds=$lt_old_archive_cmds
44084
44085# A language specific compiler.
44086CC=$lt_compiler
44087
44088# Is the compiler the GNU compiler?
44089with_gcc=$GCC
44090
44091# Compiler flag to turn off builtin functions.
44092no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
44093
44094# Additional compiler flags for building library objects.
44095pic_flag=$lt_lt_prog_compiler_pic
44096
44097# How to pass a linker flag through the compiler.
44098wl=$lt_lt_prog_compiler_wl
44099
44100# Compiler flag to prevent dynamic linking.
44101link_static_flag=$lt_lt_prog_compiler_static
44102
44103# Does compiler simultaneously support -c and -o options?
44104compiler_c_o=$lt_lt_cv_prog_compiler_c_o
44105
44106# Whether or not to add -lc for building shared libraries.
44107build_libtool_need_lc=$archive_cmds_need_lc
44108
44109# Whether or not to disallow shared libs when runtime libs are static.
44110allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes
44111
44112# Compiler flag to allow reflexive dlopens.
44113export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
44114
44115# Compiler flag to generate shared objects directly from archives.
44116whole_archive_flag_spec=$lt_whole_archive_flag_spec
44117
44118# Whether the compiler copes with passing no objects directly.
44119compiler_needs_object=$lt_compiler_needs_object
44120
44121# Create an old-style archive from a shared archive.
44122old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
44123
44124# Create a temporary old-style archive to link instead of a shared archive.
44125old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
44126
44127# Commands used to build a shared archive.
44128archive_cmds=$lt_archive_cmds
44129archive_expsym_cmds=$lt_archive_expsym_cmds
44130
44131# Commands used to build a loadable module if different from building
44132# a shared archive.
44133module_cmds=$lt_module_cmds
44134module_expsym_cmds=$lt_module_expsym_cmds
44135
44136# Whether we are building with GNU ld or not.
44137with_gnu_ld=$lt_with_gnu_ld
44138
44139# Flag that allows shared libraries with undefined symbols to be built.
44140allow_undefined_flag=$lt_allow_undefined_flag
44141
44142# Flag that enforces no undefined symbols.
44143no_undefined_flag=$lt_no_undefined_flag
44144
44145# Flag to hardcode \$libdir into a binary during linking.
44146# This must work even if \$libdir does not exist
44147hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
44148
44149# Whether we need a single "-rpath" flag with a separated argument.
44150hardcode_libdir_separator=$lt_hardcode_libdir_separator
44151
44152# Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes
44153# DIR into the resulting binary.
44154hardcode_direct=$hardcode_direct
44155
44156# Set to "yes" if using DIR/libNAME\$shared_ext during linking hardcodes
44157# DIR into the resulting binary and the resulting library dependency is
44158# "absolute",i.e impossible to change by setting \$shlibpath_var if the
44159# library is relocated.
44160hardcode_direct_absolute=$hardcode_direct_absolute
44161
44162# Set to "yes" if using the -LDIR flag during linking hardcodes DIR
44163# into the resulting binary.
44164hardcode_minus_L=$hardcode_minus_L
44165
44166# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
44167# into the resulting binary.
44168hardcode_shlibpath_var=$hardcode_shlibpath_var
44169
44170# Set to "yes" if building a shared library automatically hardcodes DIR
44171# into the library and all subsequent libraries and executables linked
44172# against it.
44173hardcode_automatic=$hardcode_automatic
44174
44175# Set to yes if linker adds runtime paths of dependent libraries
44176# to runtime path list.
44177inherit_rpath=$inherit_rpath
44178
44179# Whether libtool must link a program against all its dependency libraries.
44180link_all_deplibs=$link_all_deplibs
44181
44182# Set to "yes" if exported symbols are required.
44183always_export_symbols=$always_export_symbols
44184
44185# The commands to list exported symbols.
44186export_symbols_cmds=$lt_export_symbols_cmds
44187
44188# Symbols that should not be listed in the preloaded symbols.
44189exclude_expsyms=$lt_exclude_expsyms
44190
44191# Symbols that must always be exported.
44192include_expsyms=$lt_include_expsyms
44193
44194# Commands necessary for linking programs (against libraries) with templates.
44195prelink_cmds=$lt_prelink_cmds
44196
44197# Commands necessary for finishing linking programs.
44198postlink_cmds=$lt_postlink_cmds
44199
44200# Specify filename containing input files.
44201file_list_spec=$lt_file_list_spec
44202
44203# How to hardcode a shared library path into an executable.
44204hardcode_action=$hardcode_action
44205
44206# ### END LIBTOOL CONFIG
44207
44208_LT_EOF
44209
44210 cat <<'_LT_EOF' >> "$cfgfile"
44211
44212# ### BEGIN FUNCTIONS SHARED WITH CONFIGURE
44213
44214# func_munge_path_list VARIABLE PATH
44215# -----------------------------------
44216# VARIABLE is name of variable containing _space_ separated list of
44217# directories to be munged by the contents of PATH, which is string
44218# having a format:
44219# "DIR[:DIR]:"
44220# string "DIR[ DIR]" will be prepended to VARIABLE
44221# ":DIR[:DIR]"
44222# string "DIR[ DIR]" will be appended to VARIABLE
44223# "DIRP[:DIRP]::[DIRA:]DIRA"
44224# string "DIRP[ DIRP]" will be prepended to VARIABLE and string
44225# "DIRA[ DIRA]" will be appended to VARIABLE
44226# "DIR[:DIR]"
44227# VARIABLE will be replaced by "DIR[ DIR]"
44228func_munge_path_list ()
44229{
44230 case x$2 in
44231 x)
44232 ;;
44233 *:)
44234 eval $1=\"`$ECHO $2 | $SED 's/:/ /g'` \$$1\"
44235 ;;
44236 x:*)
44237 eval $1=\"\$$1 `$ECHO $2 | $SED 's/:/ /g'`\"
44238 ;;
44239 *::*)
44240 eval $1=\"\$$1\ `$ECHO $2 | $SED -e 's/.*:://' -e 's/:/ /g'`\"
44241 eval $1=\"`$ECHO $2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \$$1\"
44242 ;;
44243 *)
44244 eval $1=\"`$ECHO $2 | $SED 's/:/ /g'`\"
44245 ;;
44246 esac
44247}
44248
44249
44250# Calculate cc_basename. Skip known compiler wrappers and cross-prefix.
44251func_cc_basename ()
44252{
44253 for cc_temp in $*""; do
44254 case $cc_temp in
44255 compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
44256 distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
44257 \-*) ;;
44258 *) break;;
44259 esac
44260 done
44261 func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
44262}
44263
44264
44265# ### END FUNCTIONS SHARED WITH CONFIGURE
44266
44267_LT_EOF
44268
44269 case $host_os in
44270 aix3*)
44271 cat <<\_LT_EOF >> "$cfgfile"
44272# AIX sometimes has problems with the GCC collect2 program. For some
44273# reason, if we set the COLLECT_NAMES environment variable, the problems
44274# vanish in a puff of smoke.
44275if test set != "${COLLECT_NAMES+set}"; then
44276 COLLECT_NAMES=
44277 export COLLECT_NAMES
44278fi
44279_LT_EOF
44280 ;;
44281 esac
44282
44283
44284ltmain=$ac_aux_dir/ltmain.sh
44285
44286
44287 # We use sed instead of cat because bash on DJGPP gets confused if
44288 # if finds mixed CR/LF and LF-only lines. Since sed operates in
44289 # text mode, it properly converts lines to CR/LF. This bash problem
44290 # is reportedly fixed, but why not run on old versions too?
44291 sed '$q' "$ltmain" >> "$cfgfile" \
44292 || (rm -f "$cfgfile"; exit 1)
44293
44294 mv -f "$cfgfile" "$ofile" ||
44295 (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
44296 chmod +x "$ofile"
44297
44298 ;;
44299
44300 esac
44301done # for ac_tag
44302
44303
44304as_fn_exit 0
44305_ACEOF
44306ac_clean_files=$ac_clean_files_save
44307
44308test $ac_write_fail = 0 ||
44309 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
44310
44311
44312# configure is writing to config.log, and then calls config.status.
44313# config.status does its own redirection, appending to config.log.
44314# Unfortunately, on DOS this fails, as config.log is still kept open
44315# by configure, so config.status won't be able to write to it; its
44316# output is simply discarded. So we exec the FD to /dev/null,
44317# effectively closing config.log, so it can be properly (re)opened and
44318# appended to by config.status. When coming back to configure, we
44319# need to make the FD available again.
44320if test "$no_create" != yes; then
44321 ac_cs_success=:
44322 ac_config_status_args=
44323 test "$silent" = yes &&
44324 ac_config_status_args="$ac_config_status_args --quiet"
44325 exec 5>/dev/null
44326 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
44327 exec 5>>config.log
44328 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
44329 # would make configure fail if this is the last instruction.
44330 $ac_cs_success || as_fn_exit 1
44331fi
44332
44333#
44334# CONFIG_SUBDIRS section.
44335#
44336if test "$no_recursion" != yes; then
44337
44338 # Remove --cache-file, --srcdir, and --disable-option-checking arguments
44339 # so they do not pile up.
44340 ac_sub_configure_args=
44341 ac_prev=
44342 eval "set x $ac_configure_args"
44343 shift
44344 for ac_arg
44345 do
44346 if test -n "$ac_prev"; then
44347 ac_prev=
44348 continue
44349 fi
44350 case $ac_arg in
44351 -cache-file | --cache-file | --cache-fil | --cache-fi \
44352 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
44353 ac_prev=cache_file ;;
44354 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
44355 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* \
44356 | --c=*)
44357 ;;
44358 --config-cache | -C)
44359 ;;
44360 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
44361 ac_prev=srcdir ;;
44362 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
44363 ;;
44364 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
44365 ac_prev=prefix ;;
44366 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
44367 ;;
44368 --disable-option-checking)
44369 ;;
44370 *)
44371 case $ac_arg in
44372 *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
44373 esac
44374 as_fn_append ac_sub_configure_args " '$ac_arg'" ;;
44375 esac
44376 done
44377
44378 # Always prepend --prefix to ensure using the same prefix
44379 # in subdir configurations.
44380 ac_arg="--prefix=$prefix"
44381 case $ac_arg in
44382 *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
44383 esac
44384 ac_sub_configure_args="'$ac_arg' $ac_sub_configure_args"
44385
44386 # Pass --silent
44387 if test "$silent" = yes; then
44388 ac_sub_configure_args="--silent $ac_sub_configure_args"
44389 fi
44390
44391 # Always prepend --disable-option-checking to silence warnings, since
44392 # different subdirs can have different --enable and --with options.
44393 ac_sub_configure_args="--disable-option-checking $ac_sub_configure_args"
44394
44395 ac_popdir=`pwd`
44396 for ac_dir in : $subdirs; do test "x$ac_dir" = x: && continue
44397
44398 # Do not complain, so a configure script can configure whichever
44399 # parts of a large source tree are present.
44400 test -d "$srcdir/$ac_dir" || continue
44401
44402 ac_msg="=== configuring in $ac_dir (`pwd`/$ac_dir)"
44403 $as_echo "$as_me:${as_lineno-$LINENO}: $ac_msg" >&5
44404 $as_echo "$ac_msg" >&6
44405 as_dir="$ac_dir"; as_fn_mkdir_p
44406 ac_builddir=.
44407
44408case "$ac_dir" in
44409.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
44410*)
44411 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
44412 # A ".." for each directory in $ac_dir_suffix.
44413 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
44414 case $ac_top_builddir_sub in
44415 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
44416 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
44417 esac ;;
44418esac
44419ac_abs_top_builddir=$ac_pwd
44420ac_abs_builddir=$ac_pwd$ac_dir_suffix
44421# for backward compatibility:
44422ac_top_builddir=$ac_top_build_prefix
44423
44424case $srcdir in
44425 .) # We are building in place.
44426 ac_srcdir=.
44427 ac_top_srcdir=$ac_top_builddir_sub
44428 ac_abs_top_srcdir=$ac_pwd ;;
44429 [\\/]* | ?:[\\/]* ) # Absolute name.
44430 ac_srcdir=$srcdir$ac_dir_suffix;
44431 ac_top_srcdir=$srcdir
44432 ac_abs_top_srcdir=$srcdir ;;
44433 *) # Relative name.
44434 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
44435 ac_top_srcdir=$ac_top_build_prefix$srcdir
44436 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
44437esac
44438ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
44439
44440
44441 cd "$ac_dir"
44442
44443 # Check for guested configure; otherwise get Cygnus style configure.
44444 if test -f "$ac_srcdir/configure.gnu"; then
44445 ac_sub_configure=$ac_srcdir/configure.gnu
44446 elif test -f "$ac_srcdir/configure"; then
44447 ac_sub_configure=$ac_srcdir/configure
44448 elif test -f "$ac_srcdir/configure.in"; then
44449 # This should be Cygnus configure.
44450 ac_sub_configure=$ac_aux_dir/configure
44451 else
44452 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no configuration information is in $ac_dir" >&5
44453$as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2;}
44454 ac_sub_configure=
44455 fi
44456
44457 # The recursion is here.
44458 if test -n "$ac_sub_configure"; then
44459 # Make the cache file name correct relative to the subdirectory.
44460 case $cache_file in
44461 [\\/]* | ?:[\\/]* ) ac_sub_cache_file=$cache_file ;;
44462 *) # Relative name.
44463 ac_sub_cache_file=$ac_top_build_prefix$cache_file ;;
44464 esac
44465
44466 { $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
44467$as_echo "$as_me: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&6;}
44468 # The eval makes quoting arguments work.
44469 eval "\$SHELL \"\$ac_sub_configure\" $ac_sub_configure_args \
44470 --cache-file=\"\$ac_sub_cache_file\" --srcdir=\"\$ac_srcdir\"" ||
44471 as_fn_error $? "$ac_sub_configure failed for $ac_dir" "$LINENO" 5
44472 fi
44473
44474 cd "$ac_popdir"
44475 done
44476fi
44477if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
44478 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
44479$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
44480fi
44481
44482
44483
44484 tmp_cpp=`eval echo "$ac_cpp" 2>/dev/null`
44485 if test -z "$tmp_cpp"; then
44486 tmp_cpp='cpp'
44487 fi
44488 cat >./tests/configurehelp.pm <<_EOF
44489# This is a generated file. Do not edit.
44490
44491package configurehelp;
44492
44493use strict;
44494use warnings;
44495use Exporter;
44496
44497use vars qw(
44498 @ISA
44499 @EXPORT_OK
44500 \$Cpreprocessor
44501 );
44502
44503@ISA = qw(Exporter);
44504
44505@EXPORT_OK = qw(
44506 \$Cpreprocessor
44507 );
44508
44509\$Cpreprocessor = '$tmp_cpp';
44510
445111;
44512_EOF
44513
44514
44515
44516## ---------------------------------- ##
44517## Start of distclean amending code ##
44518## ---------------------------------- ##
44519
44520for xc_subdir in lib src tests/unit tests/server tests/libtest docs/examples
44521do
44522
44523if test ! -f "$xc_subdir/Makefile"; then
44524 echo "$xc_msg_err $xc_subdir/Makefile file not found. $xc_msg_abrt" >&2
44525 exit 1
44526fi
44527
44528# Fetch dependency tracking file list from Makefile include lines.
44529
44530xc_inc_lines=`grep '^include .*(DEPDIR)' "$xc_subdir/Makefile" 2>/dev/null`
44531xc_cnt_words=`echo "$xc_inc_lines" | wc -w | tr -d "$xc_space$xc_tab"`
44532
44533# --disable-dependency-tracking might have been used, consequently
44534# there is nothing to amend without a dependency tracking file list.
44535
44536if test $xc_cnt_words -gt 0; then
44537
44538{ $as_echo "$as_me:${as_lineno-$LINENO}: amending $xc_subdir/Makefile" >&5
44539$as_echo "$as_me: amending $xc_subdir/Makefile" >&6;}
44540
44541# Build Makefile specific patch hunk.
44542
44543xc_p="$xc_subdir/xc_patch.tmp"
44544
44545xc_rm_depfiles=`echo "$xc_inc_lines" \
44546 | $SED 's%include% -rm -f%' 2>/dev/null`
44547
44548xc_dep_subdirs=`echo "$xc_inc_lines" \
44549 | $SED 's%include[ ][ ]*%%' 2>/dev/null \
44550 | $SED 's%(DEPDIR)/.*%(DEPDIR)%' 2>/dev/null \
44551 | sort | uniq`
44552
44553echo "$xc_rm_depfiles" >$xc_p
44554
44555for xc_dep_dir in $xc_dep_subdirs; do
44556 echo "${xc_tab}@xm_dep_cnt=\`ls $xc_dep_dir | wc -l 2>/dev/null\`; \\" >>$xc_p
44557 echo "${xc_tab}if test \$\$xm_dep_cnt -eq 0 && test -d $xc_dep_dir; then \\" >>$xc_p
44558 echo "${xc_tab} rm -rf $xc_dep_dir; \\" >>$xc_p
44559 echo "${xc_tab}fi" >>$xc_p
44560done
44561
44562# Build Makefile patching sed scripts.
44563
44564xc_s1="$xc_subdir/xc_script_1.tmp"
44565xc_s2="$xc_subdir/xc_script_2.tmp"
44566xc_s3="$xc_subdir/xc_script_3.tmp"
44567
44568cat >$xc_s1 <<\_EOT
44569/^distclean[ ]*:/,/^[^ ][^ ]*:/{
44570 s/^.*(DEPDIR)/___xc_depdir_line___/
44571}
44572/^maintainer-clean[ ]*:/,/^[^ ][^ ]*:/{
44573 s/^.*(DEPDIR)/___xc_depdir_line___/
44574}
44575_EOT
44576
44577cat >$xc_s2 <<\_EOT
44578/___xc_depdir_line___$/{
44579 N
44580 /___xc_depdir_line___$/D
44581}
44582_EOT
44583
44584cat >$xc_s3 <<_EOT
44585/^___xc_depdir_line___/{
44586 r $xc_p
44587 d
44588}
44589_EOT
44590
44591# Apply patch to Makefile and cleanup.
44592
44593$SED -f "$xc_s1" "$xc_subdir/Makefile" >"$xc_subdir/Makefile.tmp1"
44594$SED -f "$xc_s2" "$xc_subdir/Makefile.tmp1" >"$xc_subdir/Makefile.tmp2"
44595$SED -f "$xc_s3" "$xc_subdir/Makefile.tmp2" >"$xc_subdir/Makefile.tmp3"
44596
44597if test -f "$xc_subdir/Makefile.tmp3"; then
44598 mv -f "$xc_subdir/Makefile.tmp3" "$xc_subdir/Makefile"
44599fi
44600
44601test -f "$xc_subdir/Makefile.tmp1" && rm -f "$xc_subdir/Makefile.tmp1"
44602test -f "$xc_subdir/Makefile.tmp2" && rm -f "$xc_subdir/Makefile.tmp2"
44603test -f "$xc_subdir/Makefile.tmp3" && rm -f "$xc_subdir/Makefile.tmp3"
44604
44605test -f "$xc_p" && rm -f "$xc_p"
44606test -f "$xc_s1" && rm -f "$xc_s1"
44607test -f "$xc_s2" && rm -f "$xc_s2"
44608test -f "$xc_s3" && rm -f "$xc_s3"
44609
44610fi
44611
44612done
44613
44614## -------------------------------- ##
44615## End of distclean amending code ##
44616## -------------------------------- ##
44617
44618
44619
44620{ $as_echo "$as_me:${as_lineno-$LINENO}: Configured to build curl/libcurl:
44621
Elliott Hughes82be86d2017-09-20 17:00:17 -070044622 Host setup: ${host}
44623 Install prefix: ${prefix}
44624 Compiler: ${CC}
Haibo Huang21926d52019-01-08 14:27:10 -080044625 CFLAGS: ${CFLAGS}
44626 CPPFLAGS: ${CPPFLAGS}
44627 LDFLAGS: ${LDFLAGS}
44628 LIBS: ${LIBS}
44629
44630 curl version: ${CURLVERSION}
Haibo Huang65021c72019-03-27 15:37:23 -070044631 SSL: ${curl_ssl_msg}
44632 SSH: ${curl_ssh_msg}
44633 zlib: ${curl_zlib_msg}
44634 brotli: ${curl_brotli_msg}
44635 GSS-API: ${curl_gss_msg}
44636 TLS-SRP: ${curl_tls_srp_msg}
Elliott Hughes82be86d2017-09-20 17:00:17 -070044637 resolver: ${curl_res_msg}
Haibo Huang65021c72019-03-27 15:37:23 -070044638 IPv6: ${curl_ipv6_msg}
44639 Unix sockets: ${curl_unix_sockets_msg}
44640 IDN: ${curl_idn_msg}
Elliott Hughes82be86d2017-09-20 17:00:17 -070044641 Build libcurl: Shared=${enable_shared}, Static=${enable_static}
44642 Built-in manual: ${curl_manual_msg}
44643 --libcurl option: ${curl_libcurl_msg}
44644 Verbose errors: ${curl_verbose_msg}
Haibo Huang51d9d882019-02-06 01:36:06 -080044645 Code coverage: ${curl_coverage_msg}
Haibo Huang65021c72019-03-27 15:37:23 -070044646 SSPI: ${curl_sspi_msg}
Elliott Hughes82be86d2017-09-20 17:00:17 -070044647 ca cert bundle: ${ca}${ca_warning}
44648 ca cert path: ${capath}${capath_warning}
44649 ca fallback: ${with_ca_fallback}
Haibo Huang65021c72019-03-27 15:37:23 -070044650 LDAP: ${curl_ldap_msg}
44651 LDAPS: ${curl_ldaps_msg}
44652 RTSP: ${curl_rtsp_msg}
44653 RTMP: ${curl_rtmp_msg}
44654 Metalink: ${curl_mtlnk_msg}
44655 PSL: ${curl_psl_msg}
44656 Alt-svc: ${curl_altsvc_msg}
44657 HTTP2: ${curl_h2_msg}
Elliott Hughes82be86d2017-09-20 17:00:17 -070044658 Protocols: ${SUPPORT_PROTOCOLS}
Haibo Huang65021c72019-03-27 15:37:23 -070044659 Features: ${SUPPORT_FEATURES}
Elliott Hughes82be86d2017-09-20 17:00:17 -070044660" >&5
44661$as_echo "$as_me: Configured to build curl/libcurl:
44662
Elliott Hughes82be86d2017-09-20 17:00:17 -070044663 Host setup: ${host}
44664 Install prefix: ${prefix}
44665 Compiler: ${CC}
Haibo Huang21926d52019-01-08 14:27:10 -080044666 CFLAGS: ${CFLAGS}
44667 CPPFLAGS: ${CPPFLAGS}
44668 LDFLAGS: ${LDFLAGS}
44669 LIBS: ${LIBS}
44670
44671 curl version: ${CURLVERSION}
Haibo Huang65021c72019-03-27 15:37:23 -070044672 SSL: ${curl_ssl_msg}
44673 SSH: ${curl_ssh_msg}
44674 zlib: ${curl_zlib_msg}
44675 brotli: ${curl_brotli_msg}
44676 GSS-API: ${curl_gss_msg}
44677 TLS-SRP: ${curl_tls_srp_msg}
Elliott Hughes82be86d2017-09-20 17:00:17 -070044678 resolver: ${curl_res_msg}
Haibo Huang65021c72019-03-27 15:37:23 -070044679 IPv6: ${curl_ipv6_msg}
44680 Unix sockets: ${curl_unix_sockets_msg}
44681 IDN: ${curl_idn_msg}
Elliott Hughes82be86d2017-09-20 17:00:17 -070044682 Build libcurl: Shared=${enable_shared}, Static=${enable_static}
44683 Built-in manual: ${curl_manual_msg}
44684 --libcurl option: ${curl_libcurl_msg}
44685 Verbose errors: ${curl_verbose_msg}
Haibo Huang51d9d882019-02-06 01:36:06 -080044686 Code coverage: ${curl_coverage_msg}
Haibo Huang65021c72019-03-27 15:37:23 -070044687 SSPI: ${curl_sspi_msg}
Elliott Hughes82be86d2017-09-20 17:00:17 -070044688 ca cert bundle: ${ca}${ca_warning}
44689 ca cert path: ${capath}${capath_warning}
44690 ca fallback: ${with_ca_fallback}
Haibo Huang65021c72019-03-27 15:37:23 -070044691 LDAP: ${curl_ldap_msg}
44692 LDAPS: ${curl_ldaps_msg}
44693 RTSP: ${curl_rtsp_msg}
44694 RTMP: ${curl_rtmp_msg}
44695 Metalink: ${curl_mtlnk_msg}
44696 PSL: ${curl_psl_msg}
44697 Alt-svc: ${curl_altsvc_msg}
44698 HTTP2: ${curl_h2_msg}
Elliott Hughes82be86d2017-09-20 17:00:17 -070044699 Protocols: ${SUPPORT_PROTOCOLS}
Haibo Huang65021c72019-03-27 15:37:23 -070044700 Features: ${SUPPORT_FEATURES}
Elliott Hughes82be86d2017-09-20 17:00:17 -070044701" >&6;}
Haibo Huang65021c72019-03-27 15:37:23 -070044702if test -n "$experimental"; then
44703 cat >&2 << _EOF
44704 WARNING: $experimental is enabled but marked EXPERIMENTAL. Use with caution!
44705_EOF
44706fi