Update spec to 1.2.5
[archive/platform/upstream/libvirt.git] / configure
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.69 for libvirt 1.2.5.
4 #
5 # Report bugs to <libvir-list@redhat.com>.
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 ## -------------------- ##
14 ## M4sh Initialization. ##
15 ## -------------------- ##
16
17 # Be more Bourne compatible
18 DUALCASE=1; export DUALCASE # for MKS sh
19 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
20   emulate sh
21   NULLCMD=:
22   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
23   # is contrary to our usage.  Disable this feature.
24   alias -g '${1+"$@"}'='"$@"'
25   setopt NO_GLOB_SUBST
26 else
27   case `(set -o) 2>/dev/null` in #(
28   *posix*) :
29     set -o posix ;; #(
30   *) :
31      ;;
32 esac
33 fi
34
35
36 as_nl='
37 '
38 export as_nl
39 # Printing a long string crashes Solaris 7 /usr/bin/printf.
40 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
41 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
42 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
43 # Prefer a ksh shell builtin over an external printf program on Solaris,
44 # but without wasting forks for bash or zsh.
45 if test -z "$BASH_VERSION$ZSH_VERSION" \
46     && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
47   as_echo='print -r --'
48   as_echo_n='print -rn --'
49 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
50   as_echo='printf %s\n'
51   as_echo_n='printf %s'
52 else
53   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
54     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
55     as_echo_n='/usr/ucb/echo -n'
56   else
57     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
58     as_echo_n_body='eval
59       arg=$1;
60       case $arg in #(
61       *"$as_nl"*)
62         expr "X$arg" : "X\\(.*\\)$as_nl";
63         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
64       esac;
65       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
66     '
67     export as_echo_n_body
68     as_echo_n='sh -c $as_echo_n_body as_echo'
69   fi
70   export as_echo_body
71   as_echo='sh -c $as_echo_body as_echo'
72 fi
73
74 # The user is always right.
75 if test "${PATH_SEPARATOR+set}" != set; then
76   PATH_SEPARATOR=:
77   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
78     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
79       PATH_SEPARATOR=';'
80   }
81 fi
82
83
84 # IFS
85 # We need space, tab and new line, in precisely that order.  Quoting is
86 # there to prevent editors from complaining about space-tab.
87 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
88 # splitting by setting IFS to empty value.)
89 IFS=" ""        $as_nl"
90
91 # Find who we are.  Look in the path if we contain no directory separator.
92 as_myself=
93 case $0 in #((
94   *[\\/]* ) as_myself=$0 ;;
95   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
96 for as_dir in $PATH
97 do
98   IFS=$as_save_IFS
99   test -z "$as_dir" && as_dir=.
100     test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
101   done
102 IFS=$as_save_IFS
103
104      ;;
105 esac
106 # We did not find ourselves, most probably we were run as `sh COMMAND'
107 # in which case we are not to be found in the path.
108 if test "x$as_myself" = x; then
109   as_myself=$0
110 fi
111 if test ! -f "$as_myself"; then
112   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
113   exit 1
114 fi
115
116 # Unset variables that we do not need and which cause bugs (e.g. in
117 # pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
118 # suppresses any "Segmentation fault" message there.  '((' could
119 # trigger a bug in pdksh 5.2.14.
120 for as_var in BASH_ENV ENV MAIL MAILPATH
121 do eval test x\${$as_var+set} = xset \
122   && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
123 done
124 PS1='$ '
125 PS2='> '
126 PS4='+ '
127
128 # NLS nuisances.
129 LC_ALL=C
130 export LC_ALL
131 LANGUAGE=C
132 export LANGUAGE
133
134 # CDPATH.
135 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
136
137 # Use a proper internal environment variable to ensure we don't fall
138   # into an infinite loop, continuously re-executing ourselves.
139   if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
140     _as_can_reexec=no; export _as_can_reexec;
141     # We cannot yet assume a decent shell, so we have to provide a
142 # neutralization value for shells without unset; and this also
143 # works around shells that cannot unset nonexistent variables.
144 # Preserve -v and -x to the replacement shell.
145 BASH_ENV=/dev/null
146 ENV=/dev/null
147 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
148 case $- in # ((((
149   *v*x* | *x*v* ) as_opts=-vx ;;
150   *v* ) as_opts=-v ;;
151   *x* ) as_opts=-x ;;
152   * ) as_opts= ;;
153 esac
154 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
155 # Admittedly, this is quite paranoid, since all the known shells bail
156 # out after a failed `exec'.
157 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
158 as_fn_exit 255
159   fi
160   # We don't want this to propagate to other subprocesses.
161           { _as_can_reexec=; unset _as_can_reexec;}
162 if test "x$CONFIG_SHELL" = x; then
163   as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
164   emulate sh
165   NULLCMD=:
166   # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
167   # is contrary to our usage.  Disable this feature.
168   alias -g '\${1+\"\$@\"}'='\"\$@\"'
169   setopt NO_GLOB_SUBST
170 else
171   case \`(set -o) 2>/dev/null\` in #(
172   *posix*) :
173     set -o posix ;; #(
174   *) :
175      ;;
176 esac
177 fi
178 "
179   as_required="as_fn_return () { (exit \$1); }
180 as_fn_success () { as_fn_return 0; }
181 as_fn_failure () { as_fn_return 1; }
182 as_fn_ret_success () { return 0; }
183 as_fn_ret_failure () { return 1; }
184
185 exitcode=0
186 as_fn_success || { exitcode=1; echo as_fn_success failed.; }
187 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
188 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
189 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
190 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
191
192 else
193   exitcode=1; echo positional parameters were not saved.
194 fi
195 test x\$exitcode = x0 || exit 1
196 test -x / || exit 1"
197   as_suggested="  as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
198   as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
199   eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
200   test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
201 test \$(( 1 + 1 )) = 2 || exit 1
202
203   test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || (
204     ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
205     ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
206     ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
207     PATH=/empty FPATH=/empty; export PATH FPATH
208     test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\
209       || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1"
210   if (eval "$as_required") 2>/dev/null; then :
211   as_have_required=yes
212 else
213   as_have_required=no
214 fi
215   if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
216
217 else
218   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
219 as_found=false
220 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
221 do
222   IFS=$as_save_IFS
223   test -z "$as_dir" && as_dir=.
224   as_found=:
225   case $as_dir in #(
226          /*)
227            for as_base in sh bash ksh sh5; do
228              # Try only shells that exist, to save several forks.
229              as_shell=$as_dir/$as_base
230              if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
231                     { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
232   CONFIG_SHELL=$as_shell as_have_required=yes
233                    if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
234   break 2
235 fi
236 fi
237            done;;
238        esac
239   as_found=false
240 done
241 $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
242               { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
243   CONFIG_SHELL=$SHELL as_have_required=yes
244 fi; }
245 IFS=$as_save_IFS
246
247
248       if test "x$CONFIG_SHELL" != x; then :
249   export CONFIG_SHELL
250              # We cannot yet assume a decent shell, so we have to provide a
251 # neutralization value for shells without unset; and this also
252 # works around shells that cannot unset nonexistent variables.
253 # Preserve -v and -x to the replacement shell.
254 BASH_ENV=/dev/null
255 ENV=/dev/null
256 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
257 case $- in # ((((
258   *v*x* | *x*v* ) as_opts=-vx ;;
259   *v* ) as_opts=-v ;;
260   *x* ) as_opts=-x ;;
261   * ) as_opts= ;;
262 esac
263 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
264 # Admittedly, this is quite paranoid, since all the known shells bail
265 # out after a failed `exec'.
266 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
267 exit 255
268 fi
269
270     if test x$as_have_required = xno; then :
271   $as_echo "$0: This script requires a shell more modern than all"
272   $as_echo "$0: the shells that I found on your system."
273   if test x${ZSH_VERSION+set} = xset ; then
274     $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
275     $as_echo "$0: be upgraded to zsh 4.3.4 or later."
276   else
277     $as_echo "$0: Please tell bug-autoconf@gnu.org and
278 $0: libvir-list@redhat.com about your system, including any
279 $0: error possibly output before this message. Then install
280 $0: a modern shell, or manually run the script under such a
281 $0: shell if you do have one."
282   fi
283   exit 1
284 fi
285 fi
286 fi
287 SHELL=${CONFIG_SHELL-/bin/sh}
288 export SHELL
289 # Unset more variables known to interfere with behavior of common tools.
290 CLICOLOR_FORCE= GREP_OPTIONS=
291 unset CLICOLOR_FORCE GREP_OPTIONS
292
293 ## --------------------- ##
294 ## M4sh Shell Functions. ##
295 ## --------------------- ##
296 # as_fn_unset VAR
297 # ---------------
298 # Portably unset VAR.
299 as_fn_unset ()
300 {
301   { eval $1=; unset $1;}
302 }
303 as_unset=as_fn_unset
304
305 # as_fn_set_status STATUS
306 # -----------------------
307 # Set $? to STATUS, without forking.
308 as_fn_set_status ()
309 {
310   return $1
311 } # as_fn_set_status
312
313 # as_fn_exit STATUS
314 # -----------------
315 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
316 as_fn_exit ()
317 {
318   set +e
319   as_fn_set_status $1
320   exit $1
321 } # as_fn_exit
322
323 # as_fn_mkdir_p
324 # -------------
325 # Create "$as_dir" as a directory, including parents if necessary.
326 as_fn_mkdir_p ()
327 {
328
329   case $as_dir in #(
330   -*) as_dir=./$as_dir;;
331   esac
332   test -d "$as_dir" || eval $as_mkdir_p || {
333     as_dirs=
334     while :; do
335       case $as_dir in #(
336       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
337       *) as_qdir=$as_dir;;
338       esac
339       as_dirs="'$as_qdir' $as_dirs"
340       as_dir=`$as_dirname -- "$as_dir" ||
341 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
342          X"$as_dir" : 'X\(//\)[^/]' \| \
343          X"$as_dir" : 'X\(//\)$' \| \
344          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
345 $as_echo X"$as_dir" |
346     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
347             s//\1/
348             q
349           }
350           /^X\(\/\/\)[^/].*/{
351             s//\1/
352             q
353           }
354           /^X\(\/\/\)$/{
355             s//\1/
356             q
357           }
358           /^X\(\/\).*/{
359             s//\1/
360             q
361           }
362           s/.*/./; q'`
363       test -d "$as_dir" && break
364     done
365     test -z "$as_dirs" || eval "mkdir $as_dirs"
366   } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
367
368
369 } # as_fn_mkdir_p
370
371 # as_fn_executable_p FILE
372 # -----------------------
373 # Test if FILE is an executable regular file.
374 as_fn_executable_p ()
375 {
376   test -f "$1" && test -x "$1"
377 } # as_fn_executable_p
378 # as_fn_append VAR VALUE
379 # ----------------------
380 # Append the text in VALUE to the end of the definition contained in VAR. Take
381 # advantage of any shell optimizations that allow amortized linear growth over
382 # repeated appends, instead of the typical quadratic growth present in naive
383 # implementations.
384 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
385   eval 'as_fn_append ()
386   {
387     eval $1+=\$2
388   }'
389 else
390   as_fn_append ()
391   {
392     eval $1=\$$1\$2
393   }
394 fi # as_fn_append
395
396 # as_fn_arith ARG...
397 # ------------------
398 # Perform arithmetic evaluation on the ARGs, and store the result in the
399 # global $as_val. Take advantage of shells that can avoid forks. The arguments
400 # must be portable across $(()) and expr.
401 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
402   eval 'as_fn_arith ()
403   {
404     as_val=$(( $* ))
405   }'
406 else
407   as_fn_arith ()
408   {
409     as_val=`expr "$@" || test $? -eq 1`
410   }
411 fi # as_fn_arith
412
413
414 # as_fn_error STATUS ERROR [LINENO LOG_FD]
415 # ----------------------------------------
416 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
417 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
418 # script with STATUS, using 1 if that was 0.
419 as_fn_error ()
420 {
421   as_status=$1; test $as_status -eq 0 && as_status=1
422   if test "$4"; then
423     as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
424     $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
425   fi
426   $as_echo "$as_me: error: $2" >&2
427   as_fn_exit $as_status
428 } # as_fn_error
429
430 if expr a : '\(a\)' >/dev/null 2>&1 &&
431    test "X`expr 00001 : '.*\(...\)'`" = X001; then
432   as_expr=expr
433 else
434   as_expr=false
435 fi
436
437 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
438   as_basename=basename
439 else
440   as_basename=false
441 fi
442
443 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
444   as_dirname=dirname
445 else
446   as_dirname=false
447 fi
448
449 as_me=`$as_basename -- "$0" ||
450 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
451          X"$0" : 'X\(//\)$' \| \
452          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
453 $as_echo X/"$0" |
454     sed '/^.*\/\([^/][^/]*\)\/*$/{
455             s//\1/
456             q
457           }
458           /^X\/\(\/\/\)$/{
459             s//\1/
460             q
461           }
462           /^X\/\(\/\).*/{
463             s//\1/
464             q
465           }
466           s/.*/./; q'`
467
468 # Avoid depending upon Character Ranges.
469 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
470 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
471 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
472 as_cr_digits='0123456789'
473 as_cr_alnum=$as_cr_Letters$as_cr_digits
474
475
476   as_lineno_1=$LINENO as_lineno_1a=$LINENO
477   as_lineno_2=$LINENO as_lineno_2a=$LINENO
478   eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
479   test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
480   # Blame Lee E. McMahon (1931-1989) for sed's syntax.  :-)
481   sed -n '
482     p
483     /[$]LINENO/=
484   ' <$as_myself |
485     sed '
486       s/[$]LINENO.*/&-/
487       t lineno
488       b
489       :lineno
490       N
491       :loop
492       s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
493       t loop
494       s/-\n.*//
495     ' >$as_me.lineno &&
496   chmod +x "$as_me.lineno" ||
497     { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
498
499   # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
500   # already done that, so ensure we don't try to do so again and fall
501   # in an infinite loop.  This has already happened in practice.
502   _as_can_reexec=no; export _as_can_reexec
503   # Don't try to exec as it changes $[0], causing all sort of problems
504   # (the dirname of $[0] is not the place where we might find the
505   # original and so on.  Autoconf is especially sensitive to this).
506   . "./$as_me.lineno"
507   # Exit status is that of the last command.
508   exit
509 }
510
511 ECHO_C= ECHO_N= ECHO_T=
512 case `echo -n x` in #(((((
513 -n*)
514   case `echo 'xy\c'` in
515   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
516   xy)  ECHO_C='\c';;
517   *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
518        ECHO_T=' ';;
519   esac;;
520 *)
521   ECHO_N='-n';;
522 esac
523
524 rm -f conf$$ conf$$.exe conf$$.file
525 if test -d conf$$.dir; then
526   rm -f conf$$.dir/conf$$.file
527 else
528   rm -f conf$$.dir
529   mkdir conf$$.dir 2>/dev/null
530 fi
531 if (echo >conf$$.file) 2>/dev/null; then
532   if ln -s conf$$.file conf$$ 2>/dev/null; then
533     as_ln_s='ln -s'
534     # ... but there are two gotchas:
535     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
536     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
537     # In both cases, we have to default to `cp -pR'.
538     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
539       as_ln_s='cp -pR'
540   elif ln conf$$.file conf$$ 2>/dev/null; then
541     as_ln_s=ln
542   else
543     as_ln_s='cp -pR'
544   fi
545 else
546   as_ln_s='cp -pR'
547 fi
548 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
549 rmdir conf$$.dir 2>/dev/null
550
551 if mkdir -p . 2>/dev/null; then
552   as_mkdir_p='mkdir -p "$as_dir"'
553 else
554   test -d ./-p && rmdir ./-p
555   as_mkdir_p=false
556 fi
557
558 as_test_x='test -x'
559 as_executable_p=as_fn_executable_p
560
561 # Sed expression to map a string onto a valid CPP name.
562 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
563
564 # Sed expression to map a string onto a valid variable name.
565 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
566
567 SHELL=${CONFIG_SHELL-/bin/sh}
568
569
570 test -n "$DJDIR" || exec 7<&0 </dev/null
571 exec 6>&1
572
573 # Name of the host.
574 # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
575 # so uname gets run too.
576 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
577
578 #
579 # Initializations.
580 #
581 ac_default_prefix=/usr/local
582 ac_clean_files=
583 ac_config_libobj_dir=.
584 LIBOBJS=
585 cross_compiling=no
586 subdirs=
587 MFLAGS=
588 MAKEFLAGS=
589
590 # Identity of this package.
591 PACKAGE_NAME='libvirt'
592 PACKAGE_TARNAME='libvirt'
593 PACKAGE_VERSION='1.2.5'
594 PACKAGE_STRING='libvirt 1.2.5'
595 PACKAGE_BUGREPORT='libvir-list@redhat.com'
596 PACKAGE_URL='http://libvirt.org'
597
598 ac_unique_file="src/libvirt.c"
599 # Factoring default headers for most tests.
600 ac_includes_default="\
601 #include <stdio.h>
602 #ifdef HAVE_SYS_TYPES_H
603 # include <sys/types.h>
604 #endif
605 #ifdef HAVE_SYS_STAT_H
606 # include <sys/stat.h>
607 #endif
608 #ifdef STDC_HEADERS
609 # include <stdlib.h>
610 # include <stddef.h>
611 #else
612 # ifdef HAVE_STDLIB_H
613 #  include <stdlib.h>
614 # endif
615 #endif
616 #ifdef HAVE_STRING_H
617 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
618 #  include <memory.h>
619 # endif
620 # include <string.h>
621 #endif
622 #ifdef HAVE_STRINGS_H
623 # include <strings.h>
624 #endif
625 #ifdef HAVE_INTTYPES_H
626 # include <inttypes.h>
627 #endif
628 #ifdef HAVE_STDINT_H
629 # include <stdint.h>
630 #endif
631 #ifdef HAVE_UNISTD_H
632 # include <unistd.h>
633 #endif"
634
635 gl_use_threads_default=
636 gl_header_list=
637 gl_func_list=
638 with_openssl_default='no'
639 LIB_CRYPTO=
640 gl_fnmatch_required=POSIX
641 with_apparmor=check
642 with_attr=check
643 with_audit=check
644 with_avahi=check
645 with_blkid=check
646 with_capng=check
647 with_curl=check
648 with_dbus=check
649 with_fuse=check
650 with_glusterfs=check
651 with_hal=check
652 with_netcf=check
653 with_numactl=check
654 with_openwsman=check
655 with_pciaccess=check
656 with_readline=check
657 with_sanlock=check
658 with_sasl=check
659 with_selinux=check
660 with_ssh2=check
661 with_systemd_daemon=check
662 with_udev=check
663 with_yajl=check
664 with_xen=check
665 with_xen_inotify=check
666 with_qemu=yes
667 with_uml=check
668 with_openvz=check
669 with_vmware=yes
670 with_phyp=check
671 with_xenapi=check
672 with_libxl=check
673 with_vbox=yes
674 with_lxc=check
675 with_esx=check
676 with_hyperv=check
677 with_parallels=check
678 with_test=yes
679 with_remote=yes
680 with_libvirtd=yes
681 with_chrdev_lock_files=auto
682 with_pm_utils=check
683 with_bhyve=check
684 gt_needs=
685 ac_subst_vars='gltests_LTLIBOBJS
686 gltests_LIBOBJS
687 gl_LTLIBOBJS
688 gl_LIBOBJS
689 CONFIG_INCLUDE
690 am__EXEEXT_FALSE
691 am__EXEEXT_TRUE
692 LTLIBOBJS
693 LIBOBJS
694 IFCONFIG_PATH
695 ws_plugindir
696 WITH_WIRESHARK_DISSECTOR_FALSE
697 WITH_WIRESHARK_DISSECTOR_TRUE
698 WS_DISSECTOR_CPPFLAGS
699 WIRESHARK
700 GLIB_LIBS
701 GLIB_CFLAGS
702 HAVE_LIBNL_FALSE
703 HAVE_LIBNL_TRUE
704 LIBNL_ROUTE3_LIBS
705 LIBNL_ROUTE3_CFLAGS
706 LIBNL_LIBS
707 LIBNL_CFLAGS
708 WITH_VIRTUALPORT_FALSE
709 WITH_VIRTUALPORT_TRUE
710 WITH_MACVTAP_FALSE
711 WITH_MACVTAP_TRUE
712 WITH_INTERFACE_FALSE
713 WITH_INTERFACE_TRUE
714 WITH_NWFILTER_FALSE
715 WITH_NWFILTER_TRUE
716 WITH_NODE_DEVICES_FALSE
717 WITH_NODE_DEVICES_TRUE
718 LV_LIBTOOL_OBJDIR
719 DRIVER_MODULE_LIBS
720 DRIVER_MODULE_LDFLAGS
721 WITH_DRIVER_MODULES_FALSE
722 WITH_DRIVER_MODULES_TRUE
723 WITH_WIN_ICON_FALSE
724 WITH_WIN_ICON_TRUE
725 WINDRES
726 MSCOM_LIBS
727 VERSION_SCRIPT_FLAGS
728 LIBVIRT_QEMU_SYMBOL_FILE
729 LIBVIRT_LXC_SYMBOL_FILE
730 LIBVIRT_SYMBOL_FILE
731 WIN32_EXTRA_CFLAGS
732 MINGW_EXTRA_LDFLAGS
733 CYGWIN_EXTRA_LIBADD
734 CYGWIN_EXTRA_LDFLAGS
735 GETTEXT_CPPFLAGS
736 POSUB
737 INTLLIBS
738 LTLIBICONV
739 LIBICONV
740 XGETTEXT_EXTRA_OPTIONS
741 MSGMERGE
742 XGETTEXT_015
743 XGETTEXT
744 GMSGFMT_015
745 MSGFMT_015
746 GMSGFMT
747 MSGFMT
748 GETTEXT_MACRO_VERSION
749 USE_NLS
750 WITH_CIL_FALSE
751 WITH_CIL_TRUE
752 LOCK_CHECKING_CFLAGS
753 COVERAGE_LDFLAGS
754 COVERAGE_CFLAGS
755 WITH_EXPENSIVE_TESTS_FALSE
756 WITH_EXPENSIVE_TESTS_TRUE
757 VIR_TEST_EXPENSIVE_DEFAULT
758 WITH_TESTS_FALSE
759 WITH_TESTS_TRUE
760 PERL
761 PYTHON
762 WITH_HYPERV_FALSE
763 WITH_HYPERV_TRUE
764 WITH_XENAPI_FALSE
765 WITH_XENAPI_TRUE
766 WITH_VMX_FALSE
767 WITH_VMX_TRUE
768 WITH_ESX_FALSE
769 WITH_ESX_TRUE
770 WITH_STORAGE_FALSE
771 WITH_STORAGE_TRUE
772 DEVMAPPER_LIBS
773 DEVMAPPER_CFLAGS
774 WITH_STORAGE_DISK_FALSE
775 WITH_STORAGE_DISK_TRUE
776 LIBPARTED_LIBS
777 LIBPARTED_CFLAGS
778 DMSETUP
779 PARTED
780 GLUSTER_CLI
781 WITH_STORAGE_GLUSTER_FALSE
782 WITH_STORAGE_GLUSTER_TRUE
783 WITH_STORAGE_SHEEPDOG_FALSE
784 WITH_STORAGE_SHEEPDOG_TRUE
785 COLLIE
786 LIBRBD_LIBS
787 WITH_STORAGE_RBD_FALSE
788 WITH_STORAGE_RBD_TRUE
789 WITH_STORAGE_MPATH_FALSE
790 WITH_STORAGE_MPATH_TRUE
791 WITH_STORAGE_SCSI_FALSE
792 WITH_STORAGE_SCSI_TRUE
793 WITH_STORAGE_ISCSI_FALSE
794 WITH_STORAGE_ISCSI_TRUE
795 ISCSIADM
796 WITH_STORAGE_LVM_FALSE
797 WITH_STORAGE_LVM_TRUE
798 LVS
799 VGS
800 PVS
801 VGSCAN
802 VGCHANGE
803 LVCHANGE
804 LVREMOVE
805 VGREMOVE
806 PVREMOVE
807 LVCREATE
808 VGCREATE
809 PVCREATE
810 SHOWMOUNT
811 WITH_STORAGE_FS_FALSE
812 WITH_STORAGE_FS_TRUE
813 MKFS
814 UMOUNT
815 MOUNT
816 WITH_STORAGE_DIR_FALSE
817 WITH_STORAGE_DIR_TRUE
818 WITH_SECRETS_FALSE
819 WITH_SECRETS_TRUE
820 WITH_BRIDGE_FALSE
821 WITH_BRIDGE_TRUE
822 WITH_NETWORK_FALSE
823 WITH_NETWORK_TRUE
824 VIRSH_LIBS
825 WITH_PM_UTILS_FALSE
826 WITH_PM_UTILS_TRUE
827 WITH_PHYP_FALSE
828 WITH_PHYP_TRUE
829 WITH_UML_FALSE
830 WITH_UML_TRUE
831 LIBPCAP_LIBS
832 LIBPCAP_CFLAGS
833 HAVE_NUMAD_FALSE
834 HAVE_NUMAD_TRUE
835 NUMAD
836 WITH_DTRACE_PROBES_FALSE
837 WITH_DTRACE_PROBES_TRUE
838 DTRACE
839 WITH_APPARMOR_PROFILES_FALSE
840 WITH_APPARMOR_PROFILES_TRUE
841 WITH_SECDRIVER_APPARMOR_FALSE
842 WITH_SECDRIVER_APPARMOR_TRUE
843 WITH_SECDRIVER_SELINUX_FALSE
844 WITH_SECDRIVER_SELINUX_TRUE
845 VIR_CHRDEV_LOCK_FILE_PATH_FALSE
846 VIR_CHRDEV_LOCK_FILE_PATH_TRUE
847 HAVE_FIREWALLD_FALSE
848 HAVE_FIREWALLD_TRUE
849 WITH_POLKIT1_FALSE
850 WITH_POLKIT1_TRUE
851 WITH_POLKIT0_FALSE
852 WITH_POLKIT0_TRUE
853 WITH_POLKIT_FALSE
854 WITH_POLKIT_TRUE
855 POLKIT_AUTH
856 POLKIT_LIBS
857 POLKIT_CFLAGS
858 PKCHECK_PATH
859 WITH_GNUTLS_FALSE
860 WITH_GNUTLS_TRUE
861 GNUTLS_LIBS
862 GNUTLS_CFLAGS
863 LIBXML_LIBS
864 LIBXML_CFLAGS
865 WITH_BHYVE_FALSE
866 WITH_BHYVE_TRUE
867 BHYVELOAD
868 BHYVECTL
869 BHYVE
870 WITH_PARALLELS_FALSE
871 WITH_PARALLELS_TRUE
872 WITH_LXC_FALSE
873 WITH_LXC_TRUE
874 WITH_XEN_INOTIFY_FALSE
875 WITH_XEN_INOTIFY_TRUE
876 WITH_XENXS_FALSE
877 WITH_XENXS_TRUE
878 XEN_LIBS
879 XEN_CFLAGS
880 WITH_XEN_FALSE
881 WITH_XEN_TRUE
882 LIBXL_LIBS
883 LIBXL_CFLAGS
884 WITH_LIBXL_FALSE
885 WITH_LIBXL_TRUE
886 LIBXENSERVER_LIBS
887 LIBXENSERVER_CFLAGS
888 WITH_LIBVIRTD_FALSE
889 WITH_LIBVIRTD_TRUE
890 WITH_REMOTE_FALSE
891 WITH_REMOTE_TRUE
892 WITH_TEST_FALSE
893 WITH_TEST_TRUE
894 WITH_QEMU_FALSE
895 WITH_QEMU_TRUE
896 WITH_VBOX_FALSE
897 WITH_VBOX_TRUE
898 DLOPEN_LIBS
899 XDR_CFLAGS
900 WITH_VMWARE_FALSE
901 WITH_VMWARE_TRUE
902 WITH_OPENVZ_FALSE
903 WITH_OPENVZ_TRUE
904 EBTABLES_PATH
905 IP6TABLES_PATH
906 IPTABLES_PATH
907 IP_PATH
908 WITH_SYSCTL_FALSE
909 WITH_SYSCTL_TRUE
910 LIBVIRT_INIT_SCRIPT_SYSTEMD_FALSE
911 LIBVIRT_INIT_SCRIPT_SYSTEMD_TRUE
912 LIBVIRT_INIT_SCRIPT_UPSTART_FALSE
913 LIBVIRT_INIT_SCRIPT_UPSTART_TRUE
914 LIBVIRT_INIT_SCRIPT_RED_HAT_FALSE
915 LIBVIRT_INIT_SCRIPT_RED_HAT_TRUE
916 ENABLE_DEBUG_FALSE
917 ENABLE_DEBUG_TRUE
918 STATIC_BINARIES
919 XML_CATALOG_FILE
920 HTML_DIR
921 ADDR2LINE
922 SCRUB
923 OVSVSCTL
924 RMMOD
925 MODPROBE
926 UDEVSETTLE
927 UDEVADM
928 TC
929 RADVD
930 DNSMASQ
931 DMIDECODE
932 AUGPARSE
933 XSLTPROC
934 XMLCATALOG
935 XMLLINT
936 HAVE_GLIBC_RPCGEN_FALSE
937 HAVE_GLIBC_RPCGEN_TRUE
938 HAVE_RPCGEN_FALSE
939 HAVE_RPCGEN_TRUE
940 RPCGEN
941 HAVE_LIBTASN1_FALSE
942 HAVE_LIBTASN1_TRUE
943 WITH_ATOMIC_OPS_PTHREAD_FALSE
944 WITH_ATOMIC_OPS_PTHREAD_TRUE
945 YAJL_LIBS
946 YAJL_CFLAGS
947 WITH_YAJL2_FALSE
948 WITH_YAJL2_TRUE
949 WITH_YAJL_FALSE
950 WITH_YAJL_TRUE
951 QEMU
952 WITH_UDEV_FALSE
953 WITH_UDEV_TRUE
954 UDEV_LIBS
955 UDEV_CFLAGS
956 WITH_SYSTEMD_DAEMON_FALSE
957 WITH_SYSTEMD_DAEMON_TRUE
958 SYSTEMD_DAEMON_LIBS
959 SYSTEMD_DAEMON_CFLAGS
960 WITH_SSH2_FALSE
961 WITH_SSH2_TRUE
962 SSH2_LIBS
963 SSH2_CFLAGS
964 SELINUX_LIBS
965 SELINUX_CFLAGS
966 WITH_SELINUX_FALSE
967 WITH_SELINUX_TRUE
968 SASL_LIBS
969 SASL_CFLAGS
970 WITH_SASL1_FALSE
971 WITH_SASL1_TRUE
972 WITH_SASL_FALSE
973 WITH_SASL_TRUE
974 SANLOCK_LIBS
975 SANLOCK_CFLAGS
976 WITH_SANLOCK_FALSE
977 WITH_SANLOCK_TRUE
978 READLINE_LIBS
979 READLINE_CFLAGS
980 WITH_READLINE_FALSE
981 WITH_READLINE_TRUE
982 WITH_PCIACCESS_FALSE
983 WITH_PCIACCESS_TRUE
984 PCIACCESS_LIBS
985 PCIACCESS_CFLAGS
986 WITH_OPENWSMAN_FALSE
987 WITH_OPENWSMAN_TRUE
988 OPENWSMAN_LIBS
989 OPENWSMAN_CFLAGS
990 NUMACTL_LIBS
991 NUMACTL_CFLAGS
992 WITH_NUMACTL_FALSE
993 WITH_NUMACTL_TRUE
994 WITH_NETCF_FALSE
995 WITH_NETCF_TRUE
996 NETCF_LIBS
997 NETCF_CFLAGS
998 WITH_HAL_FALSE
999 WITH_HAL_TRUE
1000 HAL_LIBS
1001 HAL_CFLAGS
1002 WITH_GLUSTERFS_FALSE
1003 WITH_GLUSTERFS_TRUE
1004 GLUSTERFS_LIBS
1005 GLUSTERFS_CFLAGS
1006 WITH_FUSE_FALSE
1007 WITH_FUSE_TRUE
1008 FUSE_LIBS
1009 FUSE_CFLAGS
1010 WITH_DBUS_FALSE
1011 WITH_DBUS_TRUE
1012 DBUS_LIBS
1013 DBUS_CFLAGS
1014 WITH_CURL_FALSE
1015 WITH_CURL_TRUE
1016 CURL_LIBS
1017 CURL_CFLAGS
1018 CAPNG_LIBS
1019 CAPNG_CFLAGS
1020 WITH_CAPNG_FALSE
1021 WITH_CAPNG_TRUE
1022 WITH_BLKID_FALSE
1023 WITH_BLKID_TRUE
1024 BLKID_LIBS
1025 BLKID_CFLAGS
1026 WITH_AVAHI_FALSE
1027 WITH_AVAHI_TRUE
1028 AVAHI_LIBS
1029 AVAHI_CFLAGS
1030 PKG_CONFIG_LIBDIR
1031 PKG_CONFIG_PATH
1032 PKG_CONFIG
1033 AUDIT_LIBS
1034 AUDIT_CFLAGS
1035 WITH_AUDIT_FALSE
1036 WITH_AUDIT_TRUE
1037 ATTR_LIBS
1038 ATTR_CFLAGS
1039 WITH_ATTR_FALSE
1040 WITH_ATTR_TRUE
1041 APPARMOR_LIBS
1042 APPARMOR_CFLAGS
1043 WITH_APPARMOR_FALSE
1044 WITH_APPARMOR_TRUE
1045 NO_INDIRECT_LDFLAGS
1046 RELRO_LDFLAGS
1047 PIE_LDFLAGS
1048 PIE_CFLAGS
1049 WARN_CFLAGS
1050 WITH_FREEBSD_FALSE
1051 WITH_FREEBSD_TRUE
1052 WITH_LINUX_FALSE
1053 WITH_LINUX_TRUE
1054 LIBVIRT_NODELETE
1055 OTOOL64
1056 OTOOL
1057 LIPO
1058 NMEDIT
1059 DSYMUTIL
1060 MANIFEST_TOOL
1061 ac_ct_AR
1062 LN_S
1063 NM
1064 ac_ct_DUMPBIN
1065 DUMPBIN
1066 LD
1067 FGREP
1068 LIBTOOL
1069 OBJDUMP
1070 DLLTOOL
1071 AS
1072 LIBTESTS_LIBDEPS
1073 abs_aux_dir
1074 HAVE_SPAWN_H
1075 NEXT_AS_FIRST_DIRECTIVE_SPAWN_H
1076 NEXT_SPAWN_H
1077 POSIX_SPAWN_PORTED_FALSE
1078 POSIX_SPAWN_PORTED_TRUE
1079 LIB_POSIX_SPAWN
1080 REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN
1081 REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2
1082 REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE
1083 REPLACE_POSIX_SPAWN
1084 HAVE_POSIX_SPAWN_FILE_ACTIONS_T
1085 HAVE_POSIX_SPAWNATTR_T
1086 HAVE_POSIX_SPAWN
1087 GNULIB_POSIX_SPAWNATTR_DESTROY
1088 GNULIB_POSIX_SPAWNATTR_SETSIGMASK
1089 GNULIB_POSIX_SPAWNATTR_GETSIGMASK
1090 GNULIB_POSIX_SPAWNATTR_SETSIGDEFAULT
1091 GNULIB_POSIX_SPAWNATTR_GETSIGDEFAULT
1092 GNULIB_POSIX_SPAWNATTR_SETSCHEDPOLICY
1093 GNULIB_POSIX_SPAWNATTR_GETSCHEDPOLICY
1094 GNULIB_POSIX_SPAWNATTR_SETSCHEDPARAM
1095 GNULIB_POSIX_SPAWNATTR_GETSCHEDPARAM
1096 GNULIB_POSIX_SPAWNATTR_SETPGROUP
1097 GNULIB_POSIX_SPAWNATTR_GETPGROUP
1098 GNULIB_POSIX_SPAWNATTR_SETFLAGS
1099 GNULIB_POSIX_SPAWNATTR_GETFLAGS
1100 GNULIB_POSIX_SPAWNATTR_INIT
1101 GNULIB_POSIX_SPAWN_FILE_ACTIONS_DESTROY
1102 GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN
1103 GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2
1104 GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE
1105 GNULIB_POSIX_SPAWN_FILE_ACTIONS_INIT
1106 GNULIB_POSIX_SPAWNP
1107 GNULIB_POSIX_SPAWN
1108 NET_IF_LIB
1109 LIB_NANOSLEEP
1110 NEXT_AS_FIRST_DIRECTIVE_MATH_H
1111 NEXT_MATH_H
1112 REPLACE_TRUNCL
1113 REPLACE_TRUNCF
1114 REPLACE_TRUNC
1115 REPLACE_SQRTL
1116 REPLACE_SIGNBIT_USING_GCC
1117 REPLACE_SIGNBIT
1118 REPLACE_ROUNDL
1119 REPLACE_ROUNDF
1120 REPLACE_ROUND
1121 REPLACE_REMAINDERL
1122 REPLACE_REMAINDERF
1123 REPLACE_REMAINDER
1124 REPLACE_NAN
1125 REPLACE_MODFL
1126 REPLACE_MODFF
1127 REPLACE_MODF
1128 REPLACE_LOGBL
1129 REPLACE_LOGBF
1130 REPLACE_LOGB
1131 REPLACE_LOG2L
1132 REPLACE_LOG2F
1133 REPLACE_LOG2
1134 REPLACE_LOG1PL
1135 REPLACE_LOG1PF
1136 REPLACE_LOG1P
1137 REPLACE_LOG10L
1138 REPLACE_LOG10F
1139 REPLACE_LOG10
1140 REPLACE_LOGL
1141 REPLACE_LOGF
1142 REPLACE_LOG
1143 REPLACE_LDEXPL
1144 REPLACE_ISNAN
1145 REPLACE_ISINF
1146 REPLACE_ISFINITE
1147 REPLACE_ILOGBF
1148 REPLACE_ILOGB
1149 REPLACE_HYPOTL
1150 REPLACE_HYPOTF
1151 REPLACE_HYPOT
1152 REPLACE_HUGE_VAL
1153 REPLACE_FREXPL
1154 REPLACE_FREXP
1155 REPLACE_FREXPF
1156 REPLACE_FMODL
1157 REPLACE_FMODF
1158 REPLACE_FMOD
1159 REPLACE_FMAL
1160 REPLACE_FMAF
1161 REPLACE_FMA
1162 REPLACE_FLOORL
1163 REPLACE_FLOORF
1164 REPLACE_FLOOR
1165 REPLACE_FABSL
1166 REPLACE_EXP2L
1167 REPLACE_EXP2
1168 REPLACE_EXPM1F
1169 REPLACE_EXPM1
1170 REPLACE_CEILL
1171 REPLACE_CEILF
1172 REPLACE_CEIL
1173 REPLACE_CBRTL
1174 REPLACE_CBRTF
1175 HAVE_DECL_TRUNCL
1176 HAVE_DECL_TRUNCF
1177 HAVE_DECL_TRUNC
1178 HAVE_DECL_TANL
1179 HAVE_DECL_SQRTL
1180 HAVE_DECL_SINL
1181 HAVE_DECL_ROUNDL
1182 HAVE_DECL_ROUNDF
1183 HAVE_DECL_ROUND
1184 HAVE_DECL_RINTF
1185 HAVE_DECL_REMAINDERL
1186 HAVE_DECL_REMAINDER
1187 HAVE_DECL_LOGB
1188 HAVE_DECL_LOG2L
1189 HAVE_DECL_LOG2F
1190 HAVE_DECL_LOG2
1191 HAVE_DECL_LOG10L
1192 HAVE_DECL_LOGL
1193 HAVE_DECL_LDEXPL
1194 HAVE_DECL_FREXPL
1195 HAVE_DECL_FLOORL
1196 HAVE_DECL_FLOORF
1197 HAVE_DECL_EXPM1L
1198 HAVE_DECL_EXP2L
1199 HAVE_DECL_EXP2F
1200 HAVE_DECL_EXP2
1201 HAVE_DECL_EXPL
1202 HAVE_DECL_COSL
1203 HAVE_DECL_COPYSIGNF
1204 HAVE_DECL_CEILL
1205 HAVE_DECL_CEILF
1206 HAVE_DECL_CBRTL
1207 HAVE_DECL_CBRTF
1208 HAVE_DECL_ATANL
1209 HAVE_DECL_ASINL
1210 HAVE_DECL_ACOSL
1211 HAVE_TANHF
1212 HAVE_TANL
1213 HAVE_TANF
1214 HAVE_SQRTL
1215 HAVE_SQRTF
1216 HAVE_SINHF
1217 HAVE_SINL
1218 HAVE_SINF
1219 HAVE_RINTL
1220 HAVE_RINT
1221 HAVE_REMAINDERF
1222 HAVE_REMAINDER
1223 HAVE_POWF
1224 HAVE_MODFL
1225 HAVE_MODFF
1226 HAVE_LOGBL
1227 HAVE_LOGBF
1228 HAVE_LOG1PL
1229 HAVE_LOG1PF
1230 HAVE_LOG1P
1231 HAVE_LOG10L
1232 HAVE_LOG10F
1233 HAVE_LOGL
1234 HAVE_LOGF
1235 HAVE_LDEXPF
1236 HAVE_ISNANL
1237 HAVE_ISNAND
1238 HAVE_ISNANF
1239 HAVE_ILOGBL
1240 HAVE_ILOGBF
1241 HAVE_ILOGB
1242 HAVE_HYPOTL
1243 HAVE_HYPOTF
1244 HAVE_FREXPF
1245 HAVE_FMODL
1246 HAVE_FMODF
1247 HAVE_FMAL
1248 HAVE_FMAF
1249 HAVE_FMA
1250 HAVE_FABSL
1251 HAVE_FABSF
1252 HAVE_EXPM1F
1253 HAVE_EXPM1
1254 HAVE_EXPL
1255 HAVE_EXPF
1256 HAVE_COSHF
1257 HAVE_COSL
1258 HAVE_COSF
1259 HAVE_COPYSIGNL
1260 HAVE_COPYSIGN
1261 HAVE_CBRTL
1262 HAVE_CBRTF
1263 HAVE_CBRT
1264 HAVE_ATAN2F
1265 HAVE_ATANL
1266 HAVE_ATANF
1267 HAVE_ASINL
1268 HAVE_ASINF
1269 HAVE_ACOSL
1270 HAVE_ACOSF
1271 GNULIB_TRUNCL
1272 GNULIB_TRUNCF
1273 GNULIB_TRUNC
1274 GNULIB_TANHF
1275 GNULIB_TANL
1276 GNULIB_TANF
1277 GNULIB_SQRTL
1278 GNULIB_SQRTF
1279 GNULIB_SINHF
1280 GNULIB_SINL
1281 GNULIB_SINF
1282 GNULIB_SIGNBIT
1283 GNULIB_ROUNDL
1284 GNULIB_ROUNDF
1285 GNULIB_ROUND
1286 GNULIB_RINTL
1287 GNULIB_RINTF
1288 GNULIB_RINT
1289 GNULIB_REMAINDERL
1290 GNULIB_REMAINDERF
1291 GNULIB_REMAINDER
1292 GNULIB_POWF
1293 GNULIB_MODFL
1294 GNULIB_MODFF
1295 GNULIB_MODF
1296 GNULIB_LOGBL
1297 GNULIB_LOGBF
1298 GNULIB_LOGB
1299 GNULIB_LOG2L
1300 GNULIB_LOG2F
1301 GNULIB_LOG2
1302 GNULIB_LOG1PL
1303 GNULIB_LOG1PF
1304 GNULIB_LOG1P
1305 GNULIB_LOG10L
1306 GNULIB_LOG10F
1307 GNULIB_LOG10
1308 GNULIB_LOGL
1309 GNULIB_LOGF
1310 GNULIB_LOG
1311 GNULIB_LDEXPL
1312 GNULIB_LDEXPF
1313 GNULIB_ISNANL
1314 GNULIB_ISNAND
1315 GNULIB_ISNANF
1316 GNULIB_ISNAN
1317 GNULIB_ISINF
1318 GNULIB_ISFINITE
1319 GNULIB_ILOGBL
1320 GNULIB_ILOGBF
1321 GNULIB_ILOGB
1322 GNULIB_HYPOTL
1323 GNULIB_HYPOTF
1324 GNULIB_HYPOT
1325 GNULIB_FREXPL
1326 GNULIB_FREXP
1327 GNULIB_FREXPF
1328 GNULIB_FMODL
1329 GNULIB_FMODF
1330 GNULIB_FMOD
1331 GNULIB_FMAL
1332 GNULIB_FMAF
1333 GNULIB_FMA
1334 GNULIB_FLOORL
1335 GNULIB_FLOORF
1336 GNULIB_FLOOR
1337 GNULIB_FABSL
1338 GNULIB_FABSF
1339 GNULIB_EXPM1L
1340 GNULIB_EXPM1F
1341 GNULIB_EXPM1
1342 GNULIB_EXP2L
1343 GNULIB_EXP2F
1344 GNULIB_EXP2
1345 GNULIB_EXPL
1346 GNULIB_EXPF
1347 GNULIB_COSHF
1348 GNULIB_COSL
1349 GNULIB_COSF
1350 GNULIB_COPYSIGNL
1351 GNULIB_COPYSIGNF
1352 GNULIB_COPYSIGN
1353 GNULIB_CEILL
1354 GNULIB_CEILF
1355 GNULIB_CEIL
1356 GNULIB_CBRTL
1357 GNULIB_CBRTF
1358 GNULIB_CBRT
1359 GNULIB_ATAN2F
1360 GNULIB_ATANL
1361 GNULIB_ATANF
1362 GNULIB_ASINL
1363 GNULIB_ASINF
1364 GNULIB_ACOSL
1365 GNULIB_ACOSF
1366 INTL_MACOSX_LIBS
1367 HAVE_SAME_LONG_DOUBLE_AS_DOUBLE
1368 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H
1369 NEXT_INTTYPES_H
1370 UINT64_MAX_EQ_ULONG_MAX
1371 UINT32_MAX_LT_UINTMAX_MAX
1372 PRIPTR_PREFIX
1373 PRI_MACROS_BROKEN
1374 INT64_MAX_EQ_LONG_MAX
1375 INT32_MAX_LT_INTMAX_MAX
1376 REPLACE_STRTOUMAX
1377 REPLACE_STRTOIMAX
1378 HAVE_DECL_STRTOUMAX
1379 HAVE_DECL_STRTOIMAX
1380 HAVE_DECL_IMAXDIV
1381 HAVE_DECL_IMAXABS
1382 GNULIB_STRTOUMAX
1383 GNULIB_STRTOIMAX
1384 GNULIB_IMAXDIV
1385 GNULIB_IMAXABS
1386 LOCALE_TR_UTF8
1387 gltests_WITNESS
1388 REPLACE_TOWLOWER
1389 REPLACE_ISWCNTRL
1390 HAVE_WCTYPE_H
1391 NEXT_AS_FIRST_DIRECTIVE_WCTYPE_H
1392 NEXT_WCTYPE_H
1393 HAVE_ISWCNTRL
1394 REPLACE_ISWBLANK
1395 HAVE_WCTRANS_T
1396 HAVE_WCTYPE_T
1397 HAVE_ISWBLANK
1398 GNULIB_TOWCTRANS
1399 GNULIB_WCTRANS
1400 GNULIB_ISWCTYPE
1401 GNULIB_WCTYPE
1402 GNULIB_ISWBLANK
1403 HAVE_WINT_T
1404 NEXT_AS_FIRST_DIRECTIVE_WCHAR_H
1405 NEXT_WCHAR_H
1406 HAVE_UNISTD_H
1407 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H
1408 NEXT_UNISTD_H
1409 PTHREAD_H_DEFINES_STRUCT_TIMESPEC
1410 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC
1411 TIME_H_DEFINES_STRUCT_TIMESPEC
1412 NEXT_AS_FIRST_DIRECTIVE_TIME_H
1413 NEXT_TIME_H
1414 NEXT_AS_FIRST_DIRECTIVE_TERMIOS_H
1415 NEXT_TERMIOS_H
1416 HAVE_TERMIOS_H
1417 HAVE_DECL_TCGETSID
1418 GNULIB_TCGETSID
1419 NEXT_AS_FIRST_DIRECTIVE_SYS_WAIT_H
1420 NEXT_SYS_WAIT_H
1421 GNULIB_WAITPID
1422 HAVE_SYS_UTSNAME_H
1423 NEXT_AS_FIRST_DIRECTIVE_SYS_UTSNAME_H
1424 NEXT_SYS_UTSNAME_H
1425 HAVE_STRUCT_UTSNAME
1426 HAVE_UNAME
1427 GNULIB_UNAME
1428 HAVE_SYS_UIO_H
1429 NEXT_AS_FIRST_DIRECTIVE_SYS_UIO_H
1430 NEXT_SYS_UIO_H
1431 NEXT_AS_FIRST_DIRECTIVE_SYS_IOCTL_H
1432 NEXT_SYS_IOCTL_H
1433 HAVE_SYS_IOCTL_H
1434 HAVE_STRINGS_H
1435 NEXT_AS_FIRST_DIRECTIVE_STRINGS_H
1436 NEXT_STRINGS_H
1437 NEXT_AS_FIRST_DIRECTIVE_STRING_H
1438 NEXT_STRING_H
1439 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H
1440 NEXT_STDLIB_H
1441 NEXT_AS_FIRST_DIRECTIVE_STDIO_H
1442 NEXT_STDIO_H
1443 GL_GENERATE_STDINT_H_FALSE
1444 GL_GENERATE_STDINT_H_TRUE
1445 STDINT_H
1446 WINT_T_SUFFIX
1447 WCHAR_T_SUFFIX
1448 SIG_ATOMIC_T_SUFFIX
1449 SIZE_T_SUFFIX
1450 PTRDIFF_T_SUFFIX
1451 HAVE_SIGNED_WINT_T
1452 HAVE_SIGNED_WCHAR_T
1453 HAVE_SIGNED_SIG_ATOMIC_T
1454 BITSIZEOF_WINT_T
1455 BITSIZEOF_WCHAR_T
1456 BITSIZEOF_SIG_ATOMIC_T
1457 BITSIZEOF_SIZE_T
1458 BITSIZEOF_PTRDIFF_T
1459 HAVE_SYS_BITYPES_H
1460 HAVE_SYS_INTTYPES_H
1461 HAVE_STDINT_H
1462 NEXT_AS_FIRST_DIRECTIVE_STDINT_H
1463 NEXT_STDINT_H
1464 HAVE_SYS_TYPES_H
1465 HAVE_INTTYPES_H
1466 HAVE_WCHAR_H
1467 HAVE_UNSIGNED_LONG_LONG_INT
1468 HAVE_LONG_LONG_INT
1469 HAVE__BOOL
1470 GL_GENERATE_STDBOOL_H_FALSE
1471 GL_GENERATE_STDBOOL_H_TRUE
1472 STDBOOL_H
1473 GL_GENERATE_STDARG_H_FALSE
1474 GL_GENERATE_STDARG_H_TRUE
1475 STDARG_H
1476 NEXT_AS_FIRST_DIRECTIVE_STDARG_H
1477 NEXT_STDARG_H
1478 GL_GENERATE_STDALIGN_H_FALSE
1479 GL_GENERATE_STDALIGN_H_TRUE
1480 STDALIGN_H
1481 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H
1482 NEXT_SIGNAL_H
1483 LIB_SELECT
1484 HAVE_SYS_SELECT_H
1485 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H
1486 NEXT_SYS_SELECT_H
1487 REPLACE_SELECT
1488 REPLACE_PSELECT
1489 HAVE_PSELECT
1490 GNULIB_SELECT
1491 GNULIB_PSELECT
1492 GL_GENERATE_SCHED_H_FALSE
1493 GL_GENERATE_SCHED_H_TRUE
1494 SCHED_H
1495 HAVE_STRUCT_SCHED_PARAM
1496 HAVE_SCHED_H
1497 NEXT_AS_FIRST_DIRECTIVE_SCHED_H
1498 NEXT_SCHED_H
1499 LIB_PTHREAD_SIGMASK
1500 REPLACE_RAISE
1501 REPLACE_PTHREAD_SIGMASK
1502 HAVE_SIGHANDLER_T
1503 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T
1504 HAVE_STRUCT_SIGACTION_SA_SIGACTION
1505 HAVE_SIGACTION
1506 HAVE_SIGINFO_T
1507 HAVE_SIGSET_T
1508 HAVE_RAISE
1509 HAVE_PTHREAD_SIGMASK
1510 HAVE_POSIX_SIGNALBLOCKING
1511 GNULIB_SIGACTION
1512 GNULIB_SIGPROCMASK
1513 GNULIB_SIGNAL_H_SIGPIPE
1514 GNULIB_RAISE
1515 GNULIB_PTHREAD_SIGMASK
1516 LIB_PTHREAD
1517 GL_GENERATE_PTHREAD_H_FALSE
1518 GL_GENERATE_PTHREAD_H_TRUE
1519 PTHREAD_H
1520 NEXT_AS_FIRST_DIRECTIVE_PTHREAD_H
1521 NEXT_PTHREAD_H
1522 HAVE_PTHREAD_SPINLOCK_T
1523 HAVE_PTHREAD_T
1524 HAVE_PTHREAD_H
1525 PREFERABLY_POSIX_SHELL
1526 POSIX_SHELL
1527 LIB_POLL
1528 LIBSOCKET
1529 NEXT_AS_FIRST_DIRECTIVE_POLL_H
1530 NEXT_POLL_H
1531 HAVE_POLL_H
1532 REPLACE_POLL
1533 HAVE_POLL
1534 GNULIB_POLL
1535 NEXT_AS_FIRST_DIRECTIVE_PTY_H
1536 NEXT_PTY_H
1537 HAVE_PTY_H
1538 REPLACE_OPENPTY
1539 REPLACE_FORKPTY
1540 HAVE_OPENPTY
1541 HAVE_FORKPTY
1542 HAVE_LIBUTIL_H
1543 HAVE_UTIL_H
1544 GNULIB_OPENPTY
1545 GNULIB_FORKPTY
1546 PTY_LIB
1547 ASM_SYMBOL_PREFIX
1548 GL_GENERATE_NETINET_IN_H_FALSE
1549 GL_GENERATE_NETINET_IN_H_TRUE
1550 NETINET_IN_H
1551 HAVE_NETINET_IN_H
1552 NEXT_AS_FIRST_DIRECTIVE_NETINET_IN_H
1553 NEXT_NETINET_IN_H
1554 GL_GENERATE_NET_IF_H_FALSE
1555 GL_GENERATE_NET_IF_H_TRUE
1556 NET_IF_H
1557 HAVE_NET_IF_H
1558 NEXT_AS_FIRST_DIRECTIVE_NET_IF_H
1559 NEXT_NET_IF_H
1560 APPLE_UNIVERSAL_BUILD
1561 REPLACE_LOCALTIME
1562 REPLACE_GMTIME
1563 REPLACE_TIMEGM
1564 REPLACE_NANOSLEEP
1565 REPLACE_MKTIME
1566 REPLACE_LOCALTIME_R
1567 HAVE_TIMEGM
1568 HAVE_STRPTIME
1569 HAVE_NANOSLEEP
1570 HAVE_DECL_LOCALTIME_R
1571 GNULIB_TIME_R
1572 GNULIB_TIMEGM
1573 GNULIB_STRPTIME
1574 GNULIB_NANOSLEEP
1575 GNULIB_MKTIME
1576 LOCALE_FR_UTF8
1577 LOCALE_ZH_CN
1578 LOCALE_JA
1579 SED
1580 LTLIBMULTITHREAD
1581 LIBMULTITHREAD
1582 LTLIBTHREAD
1583 LIBTHREAD
1584 LIBPTH_PREFIX
1585 LTLIBPTH
1586 LIBPTH
1587 NEXT_AS_FIRST_DIRECTIVE_LOCALE_H
1588 NEXT_LOCALE_H
1589 HAVE_XLOCALE_H
1590 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H
1591 NEXT_STDDEF_H
1592 GL_GENERATE_STDDEF_H_FALSE
1593 GL_GENERATE_STDDEF_H_TRUE
1594 STDDEF_H
1595 HAVE_WCHAR_T
1596 REPLACE_NULL
1597 REPLACE_STRUCT_LCONV
1598 REPLACE_DUPLOCALE
1599 REPLACE_SETLOCALE
1600 REPLACE_LOCALECONV
1601 HAVE_DUPLOCALE
1602 GNULIB_DUPLOCALE
1603 GNULIB_SETLOCALE
1604 GNULIB_LOCALECONV
1605 LOCALCHARSET_TESTS_ENVIRONMENT
1606 GLIBC21
1607 LDEXP_LIBM
1608 HAVE_LANGINFO_YESEXPR
1609 HAVE_LANGINFO_ERA
1610 HAVE_LANGINFO_T_FMT_AMPM
1611 HAVE_LANGINFO_CODESET
1612 HAVE_LANGINFO_H
1613 NEXT_AS_FIRST_DIRECTIVE_LANGINFO_H
1614 NEXT_LANGINFO_H
1615 REPLACE_NL_LANGINFO
1616 HAVE_NL_LANGINFO
1617 GNULIB_NL_LANGINFO
1618 INET_PTON_LIB
1619 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H
1620 NEXT_SYS_TIME_H
1621 REPLACE_STRUCT_TIMEVAL
1622 REPLACE_GETTIMEOFDAY
1623 HAVE_SYS_TIME_H
1624 HAVE_STRUCT_TIMEVAL
1625 HAVE_GETTIMEOFDAY
1626 GNULIB_GETTIMEOFDAY
1627 LTLIBINTL
1628 LIBINTL
1629 GETHOSTNAME_LIB
1630 GETADDRINFO_LIB
1631 INET_NTOP_LIB
1632 SERVENT_LIB
1633 HOSTENT_LIB
1634 HAVE_NETDB_H
1635 NEXT_AS_FIRST_DIRECTIVE_NETDB_H
1636 NEXT_NETDB_H
1637 REPLACE_GAI_STRERROR
1638 HAVE_DECL_GETNAMEINFO
1639 HAVE_DECL_GETADDRINFO
1640 HAVE_DECL_GAI_STRERROR
1641 HAVE_DECL_FREEADDRINFO
1642 HAVE_STRUCT_ADDRINFO
1643 GNULIB_GETADDRINFO
1644 WINDOWS_64_BIT_ST_SIZE
1645 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H
1646 NEXT_SYS_STAT_H
1647 REPLACE_UTIMENSAT
1648 REPLACE_STAT
1649 REPLACE_MKNOD
1650 REPLACE_MKFIFO
1651 REPLACE_MKDIR
1652 REPLACE_LSTAT
1653 REPLACE_FUTIMENS
1654 REPLACE_FSTATAT
1655 REPLACE_FSTAT
1656 HAVE_UTIMENSAT
1657 HAVE_MKNODAT
1658 HAVE_MKNOD
1659 HAVE_MKFIFOAT
1660 HAVE_MKFIFO
1661 HAVE_MKDIRAT
1662 HAVE_LSTAT
1663 HAVE_LCHMOD
1664 HAVE_FUTIMENS
1665 HAVE_FSTATAT
1666 HAVE_FCHMODAT
1667 GNULIB_UTIMENSAT
1668 GNULIB_STAT
1669 GNULIB_MKNODAT
1670 GNULIB_MKNOD
1671 GNULIB_MKFIFOAT
1672 GNULIB_MKFIFO
1673 GNULIB_MKDIRAT
1674 GNULIB_LSTAT
1675 GNULIB_LCHMOD
1676 GNULIB_FUTIMENS
1677 GNULIB_FSTATAT
1678 GNULIB_FSTAT
1679 GNULIB_FCHMODAT
1680 WINDOWS_64_BIT_OFF_T
1681 NEXT_AS_FIRST_DIRECTIVE_SYS_TYPES_H
1682 NEXT_SYS_TYPES_H
1683 GL_GENERATE_FNMATCH_H_FALSE
1684 GL_GENERATE_FNMATCH_H_TRUE
1685 FNMATCH_H
1686 REPLACE_ITOLD
1687 GL_GENERATE_FLOAT_H_FALSE
1688 GL_GENERATE_FLOAT_H_TRUE
1689 FLOAT_H
1690 NEXT_AS_FIRST_DIRECTIVE_FLOAT_H
1691 NEXT_FLOAT_H
1692 UNDEFINE_STRTOK_R
1693 REPLACE_STRTOK_R
1694 REPLACE_STRSIGNAL
1695 REPLACE_STRNLEN
1696 REPLACE_STRNDUP
1697 REPLACE_STRNCAT
1698 REPLACE_STRERROR_R
1699 REPLACE_STRERROR
1700 REPLACE_STRCHRNUL
1701 REPLACE_STRCASESTR
1702 REPLACE_STRSTR
1703 REPLACE_STRDUP
1704 REPLACE_STPNCPY
1705 REPLACE_MEMMEM
1706 REPLACE_MEMCHR
1707 HAVE_STRVERSCMP
1708 HAVE_DECL_STRSIGNAL
1709 HAVE_DECL_STRERROR_R
1710 HAVE_DECL_STRTOK_R
1711 HAVE_STRCASESTR
1712 HAVE_STRSEP
1713 HAVE_STRPBRK
1714 HAVE_DECL_STRNLEN
1715 HAVE_DECL_STRNDUP
1716 HAVE_DECL_STRDUP
1717 HAVE_STRCHRNUL
1718 HAVE_STPNCPY
1719 HAVE_STPCPY
1720 HAVE_RAWMEMCHR
1721 HAVE_DECL_MEMRCHR
1722 HAVE_MEMPCPY
1723 HAVE_DECL_MEMMEM
1724 HAVE_MEMCHR
1725 HAVE_FFSLL
1726 HAVE_FFSL
1727 HAVE_MBSLEN
1728 GNULIB_STRVERSCMP
1729 GNULIB_STRSIGNAL
1730 GNULIB_STRERROR_R
1731 GNULIB_STRERROR
1732 GNULIB_MBSTOK_R
1733 GNULIB_MBSSEP
1734 GNULIB_MBSSPN
1735 GNULIB_MBSPBRK
1736 GNULIB_MBSCSPN
1737 GNULIB_MBSCASESTR
1738 GNULIB_MBSPCASECMP
1739 GNULIB_MBSNCASECMP
1740 GNULIB_MBSCASECMP
1741 GNULIB_MBSSTR
1742 GNULIB_MBSRCHR
1743 GNULIB_MBSCHR
1744 GNULIB_MBSNLEN
1745 GNULIB_MBSLEN
1746 GNULIB_STRTOK_R
1747 GNULIB_STRCASESTR
1748 GNULIB_STRSTR
1749 GNULIB_STRSEP
1750 GNULIB_STRPBRK
1751 GNULIB_STRNLEN
1752 GNULIB_STRNDUP
1753 GNULIB_STRNCAT
1754 GNULIB_STRDUP
1755 GNULIB_STRCHRNUL
1756 GNULIB_STPNCPY
1757 GNULIB_STPCPY
1758 GNULIB_RAWMEMCHR
1759 GNULIB_MEMRCHR
1760 GNULIB_MEMPCPY
1761 GNULIB_MEMMEM
1762 GNULIB_MEMCHR
1763 GNULIB_FFSLL
1764 GNULIB_FFSL
1765 HAVE_DECL_STRNCASECMP
1766 HAVE_STRCASECMP
1767 HAVE_FFS
1768 GNULIB_FFS
1769 LIB_FDATASYNC
1770 NEXT_AS_FIRST_DIRECTIVE_FCNTL_H
1771 NEXT_FCNTL_H
1772 REPLACE_OPENAT
1773 REPLACE_OPEN
1774 REPLACE_FCNTL
1775 HAVE_OPENAT
1776 HAVE_FCNTL
1777 GNULIB_OPENAT
1778 GNULIB_OPEN
1779 GNULIB_NONBLOCKING
1780 GNULIB_FCNTL
1781 REPLACE_VSPRINTF
1782 REPLACE_VSNPRINTF
1783 REPLACE_VPRINTF
1784 REPLACE_VFPRINTF
1785 REPLACE_VDPRINTF
1786 REPLACE_VASPRINTF
1787 REPLACE_TMPFILE
1788 REPLACE_STDIO_WRITE_FUNCS
1789 REPLACE_STDIO_READ_FUNCS
1790 REPLACE_SPRINTF
1791 REPLACE_SNPRINTF
1792 REPLACE_RENAMEAT
1793 REPLACE_RENAME
1794 REPLACE_REMOVE
1795 REPLACE_PRINTF
1796 REPLACE_POPEN
1797 REPLACE_PERROR
1798 REPLACE_OBSTACK_PRINTF
1799 REPLACE_GETLINE
1800 REPLACE_GETDELIM
1801 REPLACE_FTELLO
1802 REPLACE_FTELL
1803 REPLACE_FSEEKO
1804 REPLACE_FSEEK
1805 REPLACE_FREOPEN
1806 REPLACE_FPURGE
1807 REPLACE_FPRINTF
1808 REPLACE_FOPEN
1809 REPLACE_FFLUSH
1810 REPLACE_FDOPEN
1811 REPLACE_FCLOSE
1812 REPLACE_DPRINTF
1813 HAVE_VDPRINTF
1814 HAVE_VASPRINTF
1815 HAVE_RENAMEAT
1816 HAVE_POPEN
1817 HAVE_PCLOSE
1818 HAVE_FTELLO
1819 HAVE_FSEEKO
1820 HAVE_DPRINTF
1821 HAVE_DECL_VSNPRINTF
1822 HAVE_DECL_SNPRINTF
1823 HAVE_DECL_OBSTACK_PRINTF
1824 HAVE_DECL_GETLINE
1825 HAVE_DECL_GETDELIM
1826 HAVE_DECL_FTELLO
1827 HAVE_DECL_FSEEKO
1828 HAVE_DECL_FPURGE
1829 GNULIB_VSPRINTF_POSIX
1830 GNULIB_VSNPRINTF
1831 GNULIB_VPRINTF_POSIX
1832 GNULIB_VPRINTF
1833 GNULIB_VFPRINTF_POSIX
1834 GNULIB_VFPRINTF
1835 GNULIB_VDPRINTF
1836 GNULIB_VSCANF
1837 GNULIB_VFSCANF
1838 GNULIB_VASPRINTF
1839 GNULIB_TMPFILE
1840 GNULIB_STDIO_H_SIGPIPE
1841 GNULIB_STDIO_H_NONBLOCKING
1842 GNULIB_SPRINTF_POSIX
1843 GNULIB_SNPRINTF
1844 GNULIB_SCANF
1845 GNULIB_RENAMEAT
1846 GNULIB_RENAME
1847 GNULIB_REMOVE
1848 GNULIB_PUTS
1849 GNULIB_PUTCHAR
1850 GNULIB_PUTC
1851 GNULIB_PRINTF_POSIX
1852 GNULIB_PRINTF
1853 GNULIB_POPEN
1854 GNULIB_PERROR
1855 GNULIB_PCLOSE
1856 GNULIB_OBSTACK_PRINTF_POSIX
1857 GNULIB_OBSTACK_PRINTF
1858 GNULIB_GETLINE
1859 GNULIB_GETDELIM
1860 GNULIB_GETCHAR
1861 GNULIB_GETC
1862 GNULIB_FWRITE
1863 GNULIB_FTELLO
1864 GNULIB_FTELL
1865 GNULIB_FSEEKO
1866 GNULIB_FSEEK
1867 GNULIB_FSCANF
1868 GNULIB_FREOPEN
1869 GNULIB_FREAD
1870 GNULIB_FPUTS
1871 GNULIB_FPUTC
1872 GNULIB_FPURGE
1873 GNULIB_FPRINTF_POSIX
1874 GNULIB_FPRINTF
1875 GNULIB_FOPEN
1876 GNULIB_FGETS
1877 GNULIB_FGETC
1878 GNULIB_FFLUSH
1879 GNULIB_FDOPEN
1880 GNULIB_FCLOSE
1881 GNULIB_DPRINTF
1882 GL_GENERATE_EXECINFO_H_FALSE
1883 GL_GENERATE_EXECINFO_H_TRUE
1884 LIB_EXECINFO
1885 EXECINFO_H
1886 EOVERFLOW_VALUE
1887 EOVERFLOW_HIDDEN
1888 ENOLINK_VALUE
1889 ENOLINK_HIDDEN
1890 EMULTIHOP_VALUE
1891 EMULTIHOP_HIDDEN
1892 GL_GENERATE_ERRNO_H_FALSE
1893 GL_GENERATE_ERRNO_H_TRUE
1894 ERRNO_H
1895 NEXT_AS_FIRST_DIRECTIVE_ERRNO_H
1896 NEXT_ERRNO_H
1897 LIB_CRYPTO
1898 pkglibexecdir
1899 runstatedir
1900 lispdir
1901 HAVE_MSVC_INVALID_PARAMETER_HANDLER
1902 LIB_CLOCK_GETTIME
1903 REPLACE_WCTOMB
1904 REPLACE_UNSETENV
1905 REPLACE_STRTOD
1906 REPLACE_SETENV
1907 REPLACE_REALPATH
1908 REPLACE_REALLOC
1909 REPLACE_RANDOM_R
1910 REPLACE_PUTENV
1911 REPLACE_PTSNAME_R
1912 REPLACE_PTSNAME
1913 REPLACE_MKSTEMP
1914 REPLACE_MBTOWC
1915 REPLACE_MALLOC
1916 REPLACE_CANONICALIZE_FILE_NAME
1917 REPLACE_CALLOC
1918 HAVE_DECL_UNSETENV
1919 HAVE_UNLOCKPT
1920 HAVE_SYS_LOADAVG_H
1921 HAVE_STRUCT_RANDOM_DATA
1922 HAVE_STRTOULL
1923 HAVE_STRTOLL
1924 HAVE_STRTOD
1925 HAVE_DECL_SETENV
1926 HAVE_SETENV
1927 HAVE_SECURE_GETENV
1928 HAVE_RPMATCH
1929 HAVE_REALPATH
1930 HAVE_RANDOM_R
1931 HAVE_RANDOM_H
1932 HAVE_RANDOM
1933 HAVE_PTSNAME_R
1934 HAVE_PTSNAME
1935 HAVE_POSIX_OPENPT
1936 HAVE_MKSTEMPS
1937 HAVE_MKSTEMP
1938 HAVE_MKOSTEMPS
1939 HAVE_MKOSTEMP
1940 HAVE_MKDTEMP
1941 HAVE_GRANTPT
1942 HAVE_GETSUBOPT
1943 HAVE_DECL_GETLOADAVG
1944 HAVE_CANONICALIZE_FILE_NAME
1945 HAVE_ATOLL
1946 HAVE__EXIT
1947 GNULIB_WCTOMB
1948 GNULIB_UNSETENV
1949 GNULIB_UNLOCKPT
1950 GNULIB_SYSTEM_POSIX
1951 GNULIB_STRTOULL
1952 GNULIB_STRTOLL
1953 GNULIB_STRTOD
1954 GNULIB_SETENV
1955 GNULIB_SECURE_GETENV
1956 GNULIB_RPMATCH
1957 GNULIB_REALPATH
1958 GNULIB_REALLOC_POSIX
1959 GNULIB_RANDOM_R
1960 GNULIB_RANDOM
1961 GNULIB_PUTENV
1962 GNULIB_PTSNAME_R
1963 GNULIB_PTSNAME
1964 GNULIB_POSIX_OPENPT
1965 GNULIB_MKSTEMPS
1966 GNULIB_MKSTEMP
1967 GNULIB_MKOSTEMPS
1968 GNULIB_MKOSTEMP
1969 GNULIB_MKDTEMP
1970 GNULIB_MBTOWC
1971 GNULIB_MALLOC_POSIX
1972 GNULIB_GRANTPT
1973 GNULIB_GETSUBOPT
1974 GNULIB_GETLOADAVG
1975 GNULIB_CANONICALIZE_FILE_NAME
1976 GNULIB_CALLOC_POSIX
1977 GNULIB_ATOLL
1978 GNULIB__EXIT
1979 GL_GENERATE_BYTESWAP_H_FALSE
1980 GL_GENERATE_BYTESWAP_H_TRUE
1981 BYTESWAP_H
1982 LOCALE_FR
1983 REPLACE_WCSWIDTH
1984 REPLACE_WCWIDTH
1985 REPLACE_WCSNRTOMBS
1986 REPLACE_WCSRTOMBS
1987 REPLACE_WCRTOMB
1988 REPLACE_MBSNRTOWCS
1989 REPLACE_MBSRTOWCS
1990 REPLACE_MBRLEN
1991 REPLACE_MBRTOWC
1992 REPLACE_MBSINIT
1993 REPLACE_WCTOB
1994 REPLACE_BTOWC
1995 REPLACE_MBSTATE_T
1996 HAVE_DECL_WCWIDTH
1997 HAVE_DECL_WCTOB
1998 HAVE_WCSWIDTH
1999 HAVE_WCSTOK
2000 HAVE_WCSSTR
2001 HAVE_WCSPBRK
2002 HAVE_WCSSPN
2003 HAVE_WCSCSPN
2004 HAVE_WCSRCHR
2005 HAVE_WCSCHR
2006 HAVE_WCSDUP
2007 HAVE_WCSXFRM
2008 HAVE_WCSCOLL
2009 HAVE_WCSNCASECMP
2010 HAVE_WCSCASECMP
2011 HAVE_WCSNCMP
2012 HAVE_WCSCMP
2013 HAVE_WCSNCAT
2014 HAVE_WCSCAT
2015 HAVE_WCPNCPY
2016 HAVE_WCSNCPY
2017 HAVE_WCPCPY
2018 HAVE_WCSCPY
2019 HAVE_WCSNLEN
2020 HAVE_WCSLEN
2021 HAVE_WMEMSET
2022 HAVE_WMEMMOVE
2023 HAVE_WMEMCPY
2024 HAVE_WMEMCMP
2025 HAVE_WMEMCHR
2026 HAVE_WCSNRTOMBS
2027 HAVE_WCSRTOMBS
2028 HAVE_WCRTOMB
2029 HAVE_MBSNRTOWCS
2030 HAVE_MBSRTOWCS
2031 HAVE_MBRLEN
2032 HAVE_MBRTOWC
2033 HAVE_MBSINIT
2034 HAVE_BTOWC
2035 GNULIB_WCSWIDTH
2036 GNULIB_WCSTOK
2037 GNULIB_WCSSTR
2038 GNULIB_WCSPBRK
2039 GNULIB_WCSSPN
2040 GNULIB_WCSCSPN
2041 GNULIB_WCSRCHR
2042 GNULIB_WCSCHR
2043 GNULIB_WCSDUP
2044 GNULIB_WCSXFRM
2045 GNULIB_WCSCOLL
2046 GNULIB_WCSNCASECMP
2047 GNULIB_WCSCASECMP
2048 GNULIB_WCSNCMP
2049 GNULIB_WCSCMP
2050 GNULIB_WCSNCAT
2051 GNULIB_WCSCAT
2052 GNULIB_WCPNCPY
2053 GNULIB_WCSNCPY
2054 GNULIB_WCPCPY
2055 GNULIB_WCSCPY
2056 GNULIB_WCSNLEN
2057 GNULIB_WCSLEN
2058 GNULIB_WMEMSET
2059 GNULIB_WMEMMOVE
2060 GNULIB_WMEMCPY
2061 GNULIB_WMEMCMP
2062 GNULIB_WMEMCHR
2063 GNULIB_WCWIDTH
2064 GNULIB_WCSNRTOMBS
2065 GNULIB_WCSRTOMBS
2066 GNULIB_WCRTOMB
2067 GNULIB_MBSNRTOWCS
2068 GNULIB_MBSRTOWCS
2069 GNULIB_MBRLEN
2070 GNULIB_MBRTOWC
2071 GNULIB_MBSINIT
2072 GNULIB_WCTOB
2073 GNULIB_BTOWC
2074 HAVE_FEATURES_H
2075 NEXT_AS_FIRST_DIRECTIVE_ARPA_INET_H
2076 NEXT_ARPA_INET_H
2077 HAVE_ARPA_INET_H
2078 REPLACE_INET_PTON
2079 REPLACE_INET_NTOP
2080 HAVE_DECL_INET_PTON
2081 HAVE_DECL_INET_NTOP
2082 GNULIB_INET_PTON
2083 GNULIB_INET_NTOP
2084 GL_GENERATE_ALLOCA_H_FALSE
2085 GL_GENERATE_ALLOCA_H_TRUE
2086 ALLOCA_H
2087 ALLOCA
2088 LTALLOCA
2089 HAVE_WINSOCK2_H
2090 REPLACE_IOCTL
2091 SYS_IOCTL_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS
2092 SYS_IOCTL_H_HAVE_WINSOCK2_H
2093 GNULIB_IOCTL
2094 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS
2095 UNISTD_H_HAVE_WINSOCK2_H
2096 REPLACE_WRITE
2097 REPLACE_USLEEP
2098 REPLACE_UNLINKAT
2099 REPLACE_UNLINK
2100 REPLACE_TTYNAME_R
2101 REPLACE_SYMLINK
2102 REPLACE_SLEEP
2103 REPLACE_RMDIR
2104 REPLACE_READLINK
2105 REPLACE_READ
2106 REPLACE_PWRITE
2107 REPLACE_PREAD
2108 REPLACE_LSEEK
2109 REPLACE_LINKAT
2110 REPLACE_LINK
2111 REPLACE_LCHOWN
2112 REPLACE_ISATTY
2113 REPLACE_GETPAGESIZE
2114 REPLACE_GETGROUPS
2115 REPLACE_GETLOGIN_R
2116 REPLACE_GETDTABLESIZE
2117 REPLACE_GETDOMAINNAME
2118 REPLACE_GETCWD
2119 REPLACE_FTRUNCATE
2120 REPLACE_FCHOWNAT
2121 REPLACE_DUP2
2122 REPLACE_DUP
2123 REPLACE_CLOSE
2124 REPLACE_CHOWN
2125 HAVE_SYS_PARAM_H
2126 HAVE_OS_H
2127 HAVE_DECL_TTYNAME_R
2128 HAVE_DECL_SETHOSTNAME
2129 HAVE_DECL_GETUSERSHELL
2130 HAVE_DECL_GETPAGESIZE
2131 HAVE_DECL_GETLOGIN_R
2132 HAVE_DECL_GETDOMAINNAME
2133 HAVE_DECL_FDATASYNC
2134 HAVE_DECL_FCHDIR
2135 HAVE_DECL_ENVIRON
2136 HAVE_USLEEP
2137 HAVE_UNLINKAT
2138 HAVE_SYMLINKAT
2139 HAVE_SYMLINK
2140 HAVE_SLEEP
2141 HAVE_SETHOSTNAME
2142 HAVE_READLINKAT
2143 HAVE_READLINK
2144 HAVE_PWRITE
2145 HAVE_PREAD
2146 HAVE_PIPE2
2147 HAVE_PIPE
2148 HAVE_LINKAT
2149 HAVE_LINK
2150 HAVE_LCHOWN
2151 HAVE_GROUP_MEMBER
2152 HAVE_GETPAGESIZE
2153 HAVE_GETLOGIN
2154 HAVE_GETHOSTNAME
2155 HAVE_GETGROUPS
2156 HAVE_GETDTABLESIZE
2157 HAVE_FTRUNCATE
2158 HAVE_FSYNC
2159 HAVE_FDATASYNC
2160 HAVE_FCHOWNAT
2161 HAVE_FCHDIR
2162 HAVE_FACCESSAT
2163 HAVE_EUIDACCESS
2164 HAVE_DUP3
2165 HAVE_DUP2
2166 HAVE_CHOWN
2167 GNULIB_WRITE
2168 GNULIB_USLEEP
2169 GNULIB_UNLINKAT
2170 GNULIB_UNLINK
2171 GNULIB_UNISTD_H_SIGPIPE
2172 GNULIB_UNISTD_H_NONBLOCKING
2173 GNULIB_TTYNAME_R
2174 GNULIB_SYMLINKAT
2175 GNULIB_SYMLINK
2176 GNULIB_SLEEP
2177 GNULIB_SETHOSTNAME
2178 GNULIB_RMDIR
2179 GNULIB_READLINKAT
2180 GNULIB_READLINK
2181 GNULIB_READ
2182 GNULIB_PWRITE
2183 GNULIB_PREAD
2184 GNULIB_PIPE2
2185 GNULIB_PIPE
2186 GNULIB_LSEEK
2187 GNULIB_LINKAT
2188 GNULIB_LINK
2189 GNULIB_LCHOWN
2190 GNULIB_ISATTY
2191 GNULIB_GROUP_MEMBER
2192 GNULIB_GETUSERSHELL
2193 GNULIB_GETPAGESIZE
2194 GNULIB_GETLOGIN_R
2195 GNULIB_GETLOGIN
2196 GNULIB_GETHOSTNAME
2197 GNULIB_GETGROUPS
2198 GNULIB_GETDTABLESIZE
2199 GNULIB_GETDOMAINNAME
2200 GNULIB_GETCWD
2201 GNULIB_FTRUNCATE
2202 GNULIB_FSYNC
2203 GNULIB_FDATASYNC
2204 GNULIB_FCHOWNAT
2205 GNULIB_FCHDIR
2206 GNULIB_FACCESSAT
2207 GNULIB_EUIDACCESS
2208 GNULIB_ENVIRON
2209 GNULIB_DUP3
2210 GNULIB_DUP2
2211 GNULIB_DUP
2212 GNULIB_CLOSE
2213 GNULIB_CHOWN
2214 GNULIB_CHDIR
2215 HAVE_WS2TCPIP_H
2216 HAVE_SYS_SOCKET_H
2217 NEXT_AS_FIRST_DIRECTIVE_SYS_SOCKET_H
2218 NEXT_SYS_SOCKET_H
2219 PRAGMA_COLUMNS
2220 PRAGMA_SYSTEM_HEADER
2221 INCLUDE_NEXT_AS_FIRST_DIRECTIVE
2222 INCLUDE_NEXT
2223 HAVE_ACCEPT4
2224 HAVE_SA_FAMILY_T
2225 HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY
2226 HAVE_STRUCT_SOCKADDR_STORAGE
2227 GNULIB_ACCEPT4
2228 GNULIB_SHUTDOWN
2229 GNULIB_SETSOCKOPT
2230 GNULIB_SENDTO
2231 GNULIB_RECVFROM
2232 GNULIB_SEND
2233 GNULIB_RECV
2234 GNULIB_LISTEN
2235 GNULIB_GETSOCKOPT
2236 GNULIB_GETSOCKNAME
2237 GNULIB_GETPEERNAME
2238 GNULIB_BIND
2239 GNULIB_ACCEPT
2240 GNULIB_CONNECT
2241 GNULIB_SOCKET
2242 GL_COND_LIBTOOL_FALSE
2243 GL_COND_LIBTOOL_TRUE
2244 RANLIB
2245 ARFLAGS
2246 AR
2247 EGREP
2248 GREP
2249 CPP
2250 am__fastdepCC_FALSE
2251 am__fastdepCC_TRUE
2252 CCDEPMODE
2253 am__nodep
2254 AMDEPBACKSLASH
2255 AMDEP_FALSE
2256 AMDEP_TRUE
2257 am__quote
2258 am__include
2259 DEPDIR
2260 OBJEXT
2261 EXEEXT
2262 ac_ct_CC
2263 CPPFLAGS
2264 LDFLAGS
2265 CFLAGS
2266 CC
2267 LIBVIRT_VERSION_NUMBER
2268 LIBVIRT_VERSION_INFO
2269 LIBVIRT_VERSION
2270 LIBVIRT_SONUM
2271 LIBVIRT_MICRO_VERSION
2272 LIBVIRT_MINOR_VERSION
2273 LIBVIRT_MAJOR_VERSION
2274 host_os
2275 host_vendor
2276 host_cpu
2277 host
2278 build_os
2279 build_vendor
2280 build_cpu
2281 build
2282 AM_BACKSLASH
2283 AM_DEFAULT_VERBOSITY
2284 AM_DEFAULT_V
2285 AM_V
2286 am__untar
2287 am__tar
2288 AMTAR
2289 am__leading_dot
2290 SET_MAKE
2291 AWK
2292 mkdir_p
2293 MKDIR_P
2294 INSTALL_STRIP_PROGRAM
2295 STRIP
2296 install_sh
2297 MAKEINFO
2298 AUTOHEADER
2299 AUTOMAKE
2300 AUTOCONF
2301 ACLOCAL
2302 VERSION
2303 PACKAGE
2304 CYGPATH_W
2305 am__isrc
2306 INSTALL_DATA
2307 INSTALL_SCRIPT
2308 INSTALL_PROGRAM
2309 target_alias
2310 host_alias
2311 build_alias
2312 LIBS
2313 ECHO_T
2314 ECHO_N
2315 ECHO_C
2316 DEFS
2317 mandir
2318 localedir
2319 libdir
2320 psdir
2321 pdfdir
2322 dvidir
2323 htmldir
2324 infodir
2325 docdir
2326 oldincludedir
2327 includedir
2328 localstatedir
2329 sharedstatedir
2330 sysconfdir
2331 datadir
2332 datarootdir
2333 libexecdir
2334 sbindir
2335 bindir
2336 program_transform_name
2337 prefix
2338 exec_prefix
2339 PACKAGE_URL
2340 PACKAGE_BUGREPORT
2341 PACKAGE_STRING
2342 PACKAGE_VERSION
2343 PACKAGE_TARNAME
2344 PACKAGE_NAME
2345 PATH_SEPARATOR
2346 SHELL'
2347 ac_subst_files=''
2348 ac_user_opts='
2349 enable_option_checking
2350 enable_silent_rules
2351 with_packager
2352 with_packager_version
2353 enable_dependency_tracking
2354 enable_largefile
2355 enable_threads
2356 with_openssl
2357 with_gnu_ld
2358 enable_rpath
2359 with_libpth_prefix
2360 with_included_regex
2361 enable_shared
2362 enable_static
2363 with_pic
2364 enable_fast_install
2365 with_sysroot
2366 enable_libtool_lock
2367 enable_werror
2368 with_apparmor
2369 with_apparmor_mount
2370 with_attr
2371 with_audit
2372 with_avahi
2373 with_blkid
2374 with_capng
2375 with_curl
2376 with_dbus
2377 with_fuse
2378 with_glusterfs
2379 with_hal
2380 with_netcf
2381 with_numactl
2382 with_openwsman
2383 with_pciaccess
2384 with_readline
2385 with_sanlock
2386 with_sasl
2387 with_selinux
2388 with_selinux_mount
2389 with_ssh2
2390 with_systemd_daemon
2391 with_udev
2392 with_yajl
2393 with_html_dir
2394 with_html_subdir
2395 with_xml_catalog_file
2396 with_xen
2397 with_xen_inotify
2398 with_qemu
2399 with_uml
2400 with_openvz
2401 with_vmware
2402 with_phyp
2403 with_xenapi
2404 with_libxl
2405 with_vbox
2406 with_lxc
2407 with_esx
2408 with_hyperv
2409 with_parallels
2410 with_test
2411 with_remote
2412 with_libvirtd
2413 with_chrdev_lock_files
2414 with_pm_utils
2415 enable_debug
2416 with_init_script
2417 with_sysctl
2418 with_rhel5_api
2419 with_bhyve
2420 with_libxml
2421 with_gnutls
2422 with_polkit
2423 with_firewalld
2424 with_secdriver_selinux
2425 with_secdriver_apparmor
2426 with_apparmor_profiles
2427 with_dtrace
2428 with_numad
2429 with_libpcap
2430 with_network
2431 with_secrets
2432 with_storage_dir
2433 with_storage_fs
2434 with_storage_lvm
2435 with_storage_iscsi
2436 with_storage_scsi
2437 with_storage_mpath
2438 with_storage_disk
2439 with_storage_rbd
2440 with_storage_sheepdog
2441 with_storage_gluster
2442 with_test_suite
2443 enable_expensive_tests
2444 enable_test_coverage
2445 enable_test_oom
2446 enable_test_locking
2447 enable_nls
2448 with_libiconv_prefix
2449 with_libintl_prefix
2450 with_driver_modules
2451 with_interface
2452 with_qemu_user
2453 with_qemu_group
2454 with_macvtap
2455 with_virtualport
2456 with_wireshark_dissector
2457 with_ws_plugindir
2458 '
2459       ac_precious_vars='build_alias
2460 host_alias
2461 target_alias
2462 CC
2463 CFLAGS
2464 LDFLAGS
2465 LIBS
2466 CPPFLAGS
2467 CPP
2468 PKG_CONFIG
2469 PKG_CONFIG_PATH
2470 PKG_CONFIG_LIBDIR
2471 AVAHI_CFLAGS
2472 AVAHI_LIBS
2473 BLKID_CFLAGS
2474 BLKID_LIBS
2475 CURL_CFLAGS
2476 CURL_LIBS
2477 DBUS_CFLAGS
2478 DBUS_LIBS
2479 FUSE_CFLAGS
2480 FUSE_LIBS
2481 GLUSTERFS_CFLAGS
2482 GLUSTERFS_LIBS
2483 HAL_CFLAGS
2484 HAL_LIBS
2485 NETCF_CFLAGS
2486 NETCF_LIBS
2487 OPENWSMAN_CFLAGS
2488 OPENWSMAN_LIBS
2489 PCIACCESS_CFLAGS
2490 PCIACCESS_LIBS
2491 SSH2_CFLAGS
2492 SSH2_LIBS
2493 SYSTEMD_DAEMON_CFLAGS
2494 SYSTEMD_DAEMON_LIBS
2495 UDEV_CFLAGS
2496 UDEV_LIBS
2497 LIBXML_CFLAGS
2498 LIBXML_LIBS
2499 GNUTLS_CFLAGS
2500 GNUTLS_LIBS
2501 POLKIT_CFLAGS
2502 POLKIT_LIBS
2503 LIBPARTED_CFLAGS
2504 LIBPARTED_LIBS
2505 DEVMAPPER_CFLAGS
2506 DEVMAPPER_LIBS
2507 LIBNL_CFLAGS
2508 LIBNL_LIBS
2509 LIBNL_ROUTE3_CFLAGS
2510 LIBNL_ROUTE3_LIBS
2511 GLIB_CFLAGS
2512 GLIB_LIBS'
2513
2514
2515 # Initialize some variables set by options.
2516 ac_init_help=
2517 ac_init_version=false
2518 ac_unrecognized_opts=
2519 ac_unrecognized_sep=
2520 # The variables have the same names as the options, with
2521 # dashes changed to underlines.
2522 cache_file=/dev/null
2523 exec_prefix=NONE
2524 no_create=
2525 no_recursion=
2526 prefix=NONE
2527 program_prefix=NONE
2528 program_suffix=NONE
2529 program_transform_name=s,x,x,
2530 silent=
2531 site=
2532 srcdir=
2533 verbose=
2534 x_includes=NONE
2535 x_libraries=NONE
2536
2537 # Installation directory options.
2538 # These are left unexpanded so users can "make install exec_prefix=/foo"
2539 # and all the variables that are supposed to be based on exec_prefix
2540 # by default will actually change.
2541 # Use braces instead of parens because sh, perl, etc. also accept them.
2542 # (The list follows the same order as the GNU Coding Standards.)
2543 bindir='${exec_prefix}/bin'
2544 sbindir='${exec_prefix}/sbin'
2545 libexecdir='${exec_prefix}/libexec'
2546 datarootdir='${prefix}/share'
2547 datadir='${datarootdir}'
2548 sysconfdir='${prefix}/etc'
2549 sharedstatedir='${prefix}/com'
2550 localstatedir='${prefix}/var'
2551 includedir='${prefix}/include'
2552 oldincludedir='/usr/include'
2553 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
2554 infodir='${datarootdir}/info'
2555 htmldir='${docdir}'
2556 dvidir='${docdir}'
2557 pdfdir='${docdir}'
2558 psdir='${docdir}'
2559 libdir='${exec_prefix}/lib'
2560 localedir='${datarootdir}/locale'
2561 mandir='${datarootdir}/man'
2562
2563 ac_prev=
2564 ac_dashdash=
2565 for ac_option
2566 do
2567   # If the previous option needs an argument, assign it.
2568   if test -n "$ac_prev"; then
2569     eval $ac_prev=\$ac_option
2570     ac_prev=
2571     continue
2572   fi
2573
2574   case $ac_option in
2575   *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
2576   *=)   ac_optarg= ;;
2577   *)    ac_optarg=yes ;;
2578   esac
2579
2580   # Accept the important Cygnus configure options, so we can diagnose typos.
2581
2582   case $ac_dashdash$ac_option in
2583   --)
2584     ac_dashdash=yes ;;
2585
2586   -bindir | --bindir | --bindi | --bind | --bin | --bi)
2587     ac_prev=bindir ;;
2588   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
2589     bindir=$ac_optarg ;;
2590
2591   -build | --build | --buil | --bui | --bu)
2592     ac_prev=build_alias ;;
2593   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
2594     build_alias=$ac_optarg ;;
2595
2596   -cache-file | --cache-file | --cache-fil | --cache-fi \
2597   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
2598     ac_prev=cache_file ;;
2599   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
2600   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
2601     cache_file=$ac_optarg ;;
2602
2603   --config-cache | -C)
2604     cache_file=config.cache ;;
2605
2606   -datadir | --datadir | --datadi | --datad)
2607     ac_prev=datadir ;;
2608   -datadir=* | --datadir=* | --datadi=* | --datad=*)
2609     datadir=$ac_optarg ;;
2610
2611   -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
2612   | --dataroo | --dataro | --datar)
2613     ac_prev=datarootdir ;;
2614   -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
2615   | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
2616     datarootdir=$ac_optarg ;;
2617
2618   -disable-* | --disable-*)
2619     ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
2620     # Reject names that are not valid shell variable names.
2621     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
2622       as_fn_error $? "invalid feature name: $ac_useropt"
2623     ac_useropt_orig=$ac_useropt
2624     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
2625     case $ac_user_opts in
2626       *"
2627 "enable_$ac_useropt"
2628 "*) ;;
2629       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
2630          ac_unrecognized_sep=', ';;
2631     esac
2632     eval enable_$ac_useropt=no ;;
2633
2634   -docdir | --docdir | --docdi | --doc | --do)
2635     ac_prev=docdir ;;
2636   -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
2637     docdir=$ac_optarg ;;
2638
2639   -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
2640     ac_prev=dvidir ;;
2641   -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
2642     dvidir=$ac_optarg ;;
2643
2644   -enable-* | --enable-*)
2645     ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
2646     # Reject names that are not valid shell variable names.
2647     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
2648       as_fn_error $? "invalid feature name: $ac_useropt"
2649     ac_useropt_orig=$ac_useropt
2650     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
2651     case $ac_user_opts in
2652       *"
2653 "enable_$ac_useropt"
2654 "*) ;;
2655       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
2656          ac_unrecognized_sep=', ';;
2657     esac
2658     eval enable_$ac_useropt=\$ac_optarg ;;
2659
2660   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
2661   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
2662   | --exec | --exe | --ex)
2663     ac_prev=exec_prefix ;;
2664   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
2665   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
2666   | --exec=* | --exe=* | --ex=*)
2667     exec_prefix=$ac_optarg ;;
2668
2669   -gas | --gas | --ga | --g)
2670     # Obsolete; use --with-gas.
2671     with_gas=yes ;;
2672
2673   -help | --help | --hel | --he | -h)
2674     ac_init_help=long ;;
2675   -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
2676     ac_init_help=recursive ;;
2677   -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
2678     ac_init_help=short ;;
2679
2680   -host | --host | --hos | --ho)
2681     ac_prev=host_alias ;;
2682   -host=* | --host=* | --hos=* | --ho=*)
2683     host_alias=$ac_optarg ;;
2684
2685   -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
2686     ac_prev=htmldir ;;
2687   -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
2688   | --ht=*)
2689     htmldir=$ac_optarg ;;
2690
2691   -includedir | --includedir | --includedi | --included | --include \
2692   | --includ | --inclu | --incl | --inc)
2693     ac_prev=includedir ;;
2694   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
2695   | --includ=* | --inclu=* | --incl=* | --inc=*)
2696     includedir=$ac_optarg ;;
2697
2698   -infodir | --infodir | --infodi | --infod | --info | --inf)
2699     ac_prev=infodir ;;
2700   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
2701     infodir=$ac_optarg ;;
2702
2703   -libdir | --libdir | --libdi | --libd)
2704     ac_prev=libdir ;;
2705   -libdir=* | --libdir=* | --libdi=* | --libd=*)
2706     libdir=$ac_optarg ;;
2707
2708   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
2709   | --libexe | --libex | --libe)
2710     ac_prev=libexecdir ;;
2711   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
2712   | --libexe=* | --libex=* | --libe=*)
2713     libexecdir=$ac_optarg ;;
2714
2715   -localedir | --localedir | --localedi | --localed | --locale)
2716     ac_prev=localedir ;;
2717   -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
2718     localedir=$ac_optarg ;;
2719
2720   -localstatedir | --localstatedir | --localstatedi | --localstated \
2721   | --localstate | --localstat | --localsta | --localst | --locals)
2722     ac_prev=localstatedir ;;
2723   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
2724   | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
2725     localstatedir=$ac_optarg ;;
2726
2727   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
2728     ac_prev=mandir ;;
2729   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
2730     mandir=$ac_optarg ;;
2731
2732   -nfp | --nfp | --nf)
2733     # Obsolete; use --without-fp.
2734     with_fp=no ;;
2735
2736   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
2737   | --no-cr | --no-c | -n)
2738     no_create=yes ;;
2739
2740   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
2741   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
2742     no_recursion=yes ;;
2743
2744   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
2745   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
2746   | --oldin | --oldi | --old | --ol | --o)
2747     ac_prev=oldincludedir ;;
2748   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
2749   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
2750   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
2751     oldincludedir=$ac_optarg ;;
2752
2753   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
2754     ac_prev=prefix ;;
2755   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
2756     prefix=$ac_optarg ;;
2757
2758   -program-prefix | --program-prefix | --program-prefi | --program-pref \
2759   | --program-pre | --program-pr | --program-p)
2760     ac_prev=program_prefix ;;
2761   -program-prefix=* | --program-prefix=* | --program-prefi=* \
2762   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
2763     program_prefix=$ac_optarg ;;
2764
2765   -program-suffix | --program-suffix | --program-suffi | --program-suff \
2766   | --program-suf | --program-su | --program-s)
2767     ac_prev=program_suffix ;;
2768   -program-suffix=* | --program-suffix=* | --program-suffi=* \
2769   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
2770     program_suffix=$ac_optarg ;;
2771
2772   -program-transform-name | --program-transform-name \
2773   | --program-transform-nam | --program-transform-na \
2774   | --program-transform-n | --program-transform- \
2775   | --program-transform | --program-transfor \
2776   | --program-transfo | --program-transf \
2777   | --program-trans | --program-tran \
2778   | --progr-tra | --program-tr | --program-t)
2779     ac_prev=program_transform_name ;;
2780   -program-transform-name=* | --program-transform-name=* \
2781   | --program-transform-nam=* | --program-transform-na=* \
2782   | --program-transform-n=* | --program-transform-=* \
2783   | --program-transform=* | --program-transfor=* \
2784   | --program-transfo=* | --program-transf=* \
2785   | --program-trans=* | --program-tran=* \
2786   | --progr-tra=* | --program-tr=* | --program-t=*)
2787     program_transform_name=$ac_optarg ;;
2788
2789   -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
2790     ac_prev=pdfdir ;;
2791   -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
2792     pdfdir=$ac_optarg ;;
2793
2794   -psdir | --psdir | --psdi | --psd | --ps)
2795     ac_prev=psdir ;;
2796   -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
2797     psdir=$ac_optarg ;;
2798
2799   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2800   | -silent | --silent | --silen | --sile | --sil)
2801     silent=yes ;;
2802
2803   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
2804     ac_prev=sbindir ;;
2805   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
2806   | --sbi=* | --sb=*)
2807     sbindir=$ac_optarg ;;
2808
2809   -sharedstatedir | --sharedstatedir | --sharedstatedi \
2810   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
2811   | --sharedst | --shareds | --shared | --share | --shar \
2812   | --sha | --sh)
2813     ac_prev=sharedstatedir ;;
2814   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
2815   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
2816   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
2817   | --sha=* | --sh=*)
2818     sharedstatedir=$ac_optarg ;;
2819
2820   -site | --site | --sit)
2821     ac_prev=site ;;
2822   -site=* | --site=* | --sit=*)
2823     site=$ac_optarg ;;
2824
2825   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
2826     ac_prev=srcdir ;;
2827   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
2828     srcdir=$ac_optarg ;;
2829
2830   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
2831   | --syscon | --sysco | --sysc | --sys | --sy)
2832     ac_prev=sysconfdir ;;
2833   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
2834   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
2835     sysconfdir=$ac_optarg ;;
2836
2837   -target | --target | --targe | --targ | --tar | --ta | --t)
2838     ac_prev=target_alias ;;
2839   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
2840     target_alias=$ac_optarg ;;
2841
2842   -v | -verbose | --verbose | --verbos | --verbo | --verb)
2843     verbose=yes ;;
2844
2845   -version | --version | --versio | --versi | --vers | -V)
2846     ac_init_version=: ;;
2847
2848   -with-* | --with-*)
2849     ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
2850     # Reject names that are not valid shell variable names.
2851     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
2852       as_fn_error $? "invalid package name: $ac_useropt"
2853     ac_useropt_orig=$ac_useropt
2854     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
2855     case $ac_user_opts in
2856       *"
2857 "with_$ac_useropt"
2858 "*) ;;
2859       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
2860          ac_unrecognized_sep=', ';;
2861     esac
2862     eval with_$ac_useropt=\$ac_optarg ;;
2863
2864   -without-* | --without-*)
2865     ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
2866     # Reject names that are not valid shell variable names.
2867     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
2868       as_fn_error $? "invalid package name: $ac_useropt"
2869     ac_useropt_orig=$ac_useropt
2870     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
2871     case $ac_user_opts in
2872       *"
2873 "with_$ac_useropt"
2874 "*) ;;
2875       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
2876          ac_unrecognized_sep=', ';;
2877     esac
2878     eval with_$ac_useropt=no ;;
2879
2880   --x)
2881     # Obsolete; use --with-x.
2882     with_x=yes ;;
2883
2884   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
2885   | --x-incl | --x-inc | --x-in | --x-i)
2886     ac_prev=x_includes ;;
2887   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
2888   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
2889     x_includes=$ac_optarg ;;
2890
2891   -x-libraries | --x-libraries | --x-librarie | --x-librari \
2892   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
2893     ac_prev=x_libraries ;;
2894   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
2895   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
2896     x_libraries=$ac_optarg ;;
2897
2898   -*) as_fn_error $? "unrecognized option: \`$ac_option'
2899 Try \`$0 --help' for more information"
2900     ;;
2901
2902   *=*)
2903     ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
2904     # Reject names that are not valid shell variable names.
2905     case $ac_envvar in #(
2906       '' | [0-9]* | *[!_$as_cr_alnum]* )
2907       as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
2908     esac
2909     eval $ac_envvar=\$ac_optarg
2910     export $ac_envvar ;;
2911
2912   *)
2913     # FIXME: should be removed in autoconf 3.0.
2914     $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
2915     expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
2916       $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
2917     : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
2918     ;;
2919
2920   esac
2921 done
2922
2923 if test -n "$ac_prev"; then
2924   ac_option=--`echo $ac_prev | sed 's/_/-/g'`
2925   as_fn_error $? "missing argument to $ac_option"
2926 fi
2927
2928 if test -n "$ac_unrecognized_opts"; then
2929   case $enable_option_checking in
2930     no) ;;
2931     fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
2932     *)     $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
2933   esac
2934 fi
2935
2936 # Check all directory arguments for consistency.
2937 for ac_var in   exec_prefix prefix bindir sbindir libexecdir datarootdir \
2938                 datadir sysconfdir sharedstatedir localstatedir includedir \
2939                 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
2940                 libdir localedir mandir
2941 do
2942   eval ac_val=\$$ac_var
2943   # Remove trailing slashes.
2944   case $ac_val in
2945     */ )
2946       ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
2947       eval $ac_var=\$ac_val;;
2948   esac
2949   # Be sure to have absolute directory names.
2950   case $ac_val in
2951     [\\/$]* | ?:[\\/]* )  continue;;
2952     NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
2953   esac
2954   as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
2955 done
2956
2957 # There might be people who depend on the old broken behavior: `$host'
2958 # used to hold the argument of --host etc.
2959 # FIXME: To remove some day.
2960 build=$build_alias
2961 host=$host_alias
2962 target=$target_alias
2963
2964 # FIXME: To remove some day.
2965 if test "x$host_alias" != x; then
2966   if test "x$build_alias" = x; then
2967     cross_compiling=maybe
2968   elif test "x$build_alias" != "x$host_alias"; then
2969     cross_compiling=yes
2970   fi
2971 fi
2972
2973 ac_tool_prefix=
2974 test -n "$host_alias" && ac_tool_prefix=$host_alias-
2975
2976 test "$silent" = yes && exec 6>/dev/null
2977
2978
2979 ac_pwd=`pwd` && test -n "$ac_pwd" &&
2980 ac_ls_di=`ls -di .` &&
2981 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
2982   as_fn_error $? "working directory cannot be determined"
2983 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
2984   as_fn_error $? "pwd does not report name of working directory"
2985
2986
2987 # Find the source files, if location was not specified.
2988 if test -z "$srcdir"; then
2989   ac_srcdir_defaulted=yes
2990   # Try the directory containing this script, then the parent directory.
2991   ac_confdir=`$as_dirname -- "$as_myself" ||
2992 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
2993          X"$as_myself" : 'X\(//\)[^/]' \| \
2994          X"$as_myself" : 'X\(//\)$' \| \
2995          X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
2996 $as_echo X"$as_myself" |
2997     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
2998             s//\1/
2999             q
3000           }
3001           /^X\(\/\/\)[^/].*/{
3002             s//\1/
3003             q
3004           }
3005           /^X\(\/\/\)$/{
3006             s//\1/
3007             q
3008           }
3009           /^X\(\/\).*/{
3010             s//\1/
3011             q
3012           }
3013           s/.*/./; q'`
3014   srcdir=$ac_confdir
3015   if test ! -r "$srcdir/$ac_unique_file"; then
3016     srcdir=..
3017   fi
3018 else
3019   ac_srcdir_defaulted=no
3020 fi
3021 if test ! -r "$srcdir/$ac_unique_file"; then
3022   test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
3023   as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
3024 fi
3025 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
3026 ac_abs_confdir=`(
3027         cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
3028         pwd)`
3029 # When building in place, set srcdir=.
3030 if test "$ac_abs_confdir" = "$ac_pwd"; then
3031   srcdir=.
3032 fi
3033 # Remove unnecessary trailing slashes from srcdir.
3034 # Double slashes in file names in object file debugging info
3035 # mess up M-x gdb in Emacs.
3036 case $srcdir in
3037 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
3038 esac
3039 for ac_var in $ac_precious_vars; do
3040   eval ac_env_${ac_var}_set=\${${ac_var}+set}
3041   eval ac_env_${ac_var}_value=\$${ac_var}
3042   eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
3043   eval ac_cv_env_${ac_var}_value=\$${ac_var}
3044 done
3045
3046 #
3047 # Report the --help message.
3048 #
3049 if test "$ac_init_help" = "long"; then
3050   # Omit some internal or obsolete options to make the list less imposing.
3051   # This message is too long to be a string in the A/UX 3.1 sh.
3052   cat <<_ACEOF
3053 \`configure' configures libvirt 1.2.5 to adapt to many kinds of systems.
3054
3055 Usage: $0 [OPTION]... [VAR=VALUE]...
3056
3057 To assign environment variables (e.g., CC, CFLAGS...), specify them as
3058 VAR=VALUE.  See below for descriptions of some of the useful variables.
3059
3060 Defaults for the options are specified in brackets.
3061
3062 Configuration:
3063   -h, --help              display this help and exit
3064       --help=short        display options specific to this package
3065       --help=recursive    display the short help of all the included packages
3066   -V, --version           display version information and exit
3067   -q, --quiet, --silent   do not print \`checking ...' messages
3068       --cache-file=FILE   cache test results in FILE [disabled]
3069   -C, --config-cache      alias for \`--cache-file=config.cache'
3070   -n, --no-create         do not create output files
3071       --srcdir=DIR        find the sources in DIR [configure dir or \`..']
3072
3073 Installation directories:
3074   --prefix=PREFIX         install architecture-independent files in PREFIX
3075                           [$ac_default_prefix]
3076   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
3077                           [PREFIX]
3078
3079 By default, \`make install' will install all the files in
3080 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
3081 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
3082 for instance \`--prefix=\$HOME'.
3083
3084 For better control, use the options below.
3085
3086 Fine tuning of the installation directories:
3087   --bindir=DIR            user executables [EPREFIX/bin]
3088   --sbindir=DIR           system admin executables [EPREFIX/sbin]
3089   --libexecdir=DIR        program executables [EPREFIX/libexec]
3090   --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
3091   --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
3092   --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
3093   --libdir=DIR            object code libraries [EPREFIX/lib]
3094   --includedir=DIR        C header files [PREFIX/include]
3095   --oldincludedir=DIR     C header files for non-gcc [/usr/include]
3096   --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
3097   --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
3098   --infodir=DIR           info documentation [DATAROOTDIR/info]
3099   --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
3100   --mandir=DIR            man documentation [DATAROOTDIR/man]
3101   --docdir=DIR            documentation root [DATAROOTDIR/doc/libvirt]
3102   --htmldir=DIR           html documentation [DOCDIR]
3103   --dvidir=DIR            dvi documentation [DOCDIR]
3104   --pdfdir=DIR            pdf documentation [DOCDIR]
3105   --psdir=DIR             ps documentation [DOCDIR]
3106 _ACEOF
3107
3108   cat <<\_ACEOF
3109
3110 Program names:
3111   --program-prefix=PREFIX            prepend PREFIX to installed program names
3112   --program-suffix=SUFFIX            append SUFFIX to installed program names
3113   --program-transform-name=PROGRAM   run sed PROGRAM on installed program names
3114
3115 System types:
3116   --build=BUILD     configure for building on BUILD [guessed]
3117   --host=HOST       cross-compile to build programs to run on HOST [BUILD]
3118 _ACEOF
3119 fi
3120
3121 if test -n "$ac_init_help"; then
3122   case $ac_init_help in
3123      short | recursive ) echo "Configuration of libvirt 1.2.5:";;
3124    esac
3125   cat <<\_ACEOF
3126
3127 Optional Features:
3128   --disable-option-checking  ignore unrecognized --enable/--with options
3129   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
3130   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
3131   --enable-silent-rules   less verbose build output (undo: "make V=1")
3132   --disable-silent-rules  verbose build output (undo: "make V=0")
3133   --enable-dependency-tracking
3134                           do not reject slow dependency extractors
3135   --disable-dependency-tracking
3136                           speeds up one-time build
3137   --disable-largefile     omit support for large files
3138   --enable-threads={posix|solaris|pth|windows}
3139                           specify multithreading API
3140   --disable-threads       build without multithread safety
3141   --disable-rpath         do not hardcode runtime library paths
3142   --enable-shared[=PKGS]  build shared libraries [default=yes]
3143   --enable-static[=PKGS]  build static libraries [default=no]
3144   --enable-fast-install[=PKGS]
3145                           optimize for fast installation [default=yes]
3146   --disable-libtool-lock  avoid locking (might break parallel builds)
3147   --enable-werror         Use -Werror (if supported)
3148   --enable-debug=[no|yes] enable debugging output [default=yes]
3149   --enable-expensive-tests
3150                           set the default for enabling expensive tests (gnulib
3151                           and long timeouts) [default=check]; use
3152                           VIR_TEST_EXPENSIVE to override during make
3153   --enable-test-coverage  turn on code coverage instrumentation [default=no]
3154   --enable-test-oom       memory allocation failure checking [default=no]
3155   --enable-test-locking   thread locking tests using CIL [default=no]
3156   --disable-nls           do not use Native Language Support
3157
3158 Optional Packages:
3159   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
3160   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
3161   --with-packager         Extra packager name
3162   --with-packager-version Extra packager version
3163   --with-openssl          use libcrypto hash routines. Valid ARGs are: 'yes',
3164                           'no', 'auto' => use if available, 'optional' => use
3165                           if available and warn if not available; default is
3166                           'no'
3167   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
3168   --with-libpth-prefix[=DIR]  search for libpth in DIR/include and DIR/lib
3169   --without-libpth-prefix     don't search for libpth in includedir and libdir
3170   --without-included-regex
3171                           don't compile regex; this is the default on systems
3172                           with recent-enough versions of the GNU C Library
3173                           (use with caution on other systems).
3174   --with-pic[=PKGS]       try to use only PIC/non-PIC objects [default=use
3175                           both]
3176   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
3177   --with-sysroot=DIR Search for dependent libraries within DIR
3178                         (or the compiler's sysroot if not specified).
3179   --with-apparmor         with libapparmor support [default=check]
3180   --with-apparmor-mount   set AppArmor mount point [default=check]
3181   --with-attr             with libattr support [default=check]
3182   --with-audit            with libaudit support [default=check]
3183   --with-avahi            with avahi-client (>= 0.6.0) support [default=check]
3184   --with-blkid            with blkid (>= 2.17) support [default=check]
3185   --with-capng            with libcap-ng support [default=check]
3186   --with-curl             with libcurl (>= 7.18.0) support [default=check]
3187   --with-dbus             with dbus-1 (>= 1.0.0) support [default=check]
3188   --with-fuse             with fuse (>= 2.8.6) support [default=check]
3189   --with-glusterfs        with glusterfs-api (>= 3.4.1) support
3190                           [default=check]
3191   --with-hal              with hal (>= 0.5.0) support [default=check]
3192   --with-netcf            with netcf (>= 0.1.4) support [default=check]
3193   --with-numactl          with libnuma support [default=check]
3194   --with-openwsman        with openwsman (>= 2.2.3) support [default=check]
3195   --with-pciaccess        with pciaccess (>= 0.10.0) support [default=check]
3196   --with-readline         with libreadline support [default=check]
3197   --with-sanlock          with libsanlock_client support [default=check]
3198   --with-sasl             with libsasl2 support [default=check]
3199   --with-selinux          with libselinux support [default=check]
3200   --with-selinux-mount    set SELinux mount point [default=check]
3201   --with-ssh2             with libssh2 (>= 1.3) support [default=check]
3202   --with-systemd-daemon   with libsystemd-daemon (>= 0.27.1) support
3203                           [default=check]
3204   --with-udev             with libudev (>= 145) support [default=check]
3205   --with-yajl             with libyajl support [default=check]
3206   --with-html-dir=path    path to base html directory, default
3207                           $datadir/doc/html
3208   --with-html-subdir=path directory used under html-dir, default
3209                           $PACKAGE-$VERSION/html
3210   --with-xml-catalog-file=path
3211                           path to XML catalog file for validating generated
3212                           html, default /etc/xml/catalog
3213   --with-xen              add XEN support [default=check]
3214   --with-xen-inotify      add XEN inotify support [default=check]
3215   --with-qemu             add QEMU/KVM support [default=yes]
3216   --with-uml              add UML support [default=check]
3217   --with-openvz           add OpenVZ support [default=check]
3218   --with-vmware           add VMware support [default=yes]
3219   --with-phyp             add PHYP support [default=check]
3220   --with-xenapi           add XenAPI support [default=check]
3221   --with-libxl            add libxenlight support [default=check]
3222   --with-vbox=[PFX]       VirtualBox XPCOMC location [default=yes]
3223   --with-lxc              add Linux Container support [default=check]
3224   --with-esx              add ESX support [default=check]
3225   --with-hyperv           add Hyper-V support [default=check]
3226   --with-parallels        add Parallels Cloud Server support [default=check]
3227   --with-test             add test driver support [default=yes]
3228   --with-remote           add remote driver support [default=yes]
3229   --with-libvirtd         add libvirtd support [default=yes]
3230   --with-chrdev-lock-files
3231                           location for UUCP style lock files for character
3232                           devices (use auto for default paths on some
3233                           platforms) [default=auto]
3234   --with-pm-utils         use pm-utils for power management [default=yes]
3235   --with-init-script[=STYLE]
3236                           Style of init script to install: redhat, systemd,
3237                           systemd+redhat, upstart, check, none [default=check]
3238   --with-sysctl[=yes/no]  Whether to install sysctl configs [default=check]
3239   --with-rhel5-api=[ARG]  build for the RHEL-5 API [default=no]
3240   --with-bhyve            add BHyVe support [default=check]
3241   --with-libxml=[PFX]     libxml2 location
3242   --with-gnutls           use GNUTLS for encryption [default=check]
3243   --with-polkit           use PolicyKit for UNIX socket access checks
3244                           [default=check]
3245   --with-firewalld        enable firewalld support [default=check]
3246   --with-secdriver-selinux
3247                           use SELinux security driver [default=check]
3248   --with-secdriver-apparmor
3249                           use AppArmor security driver [default=check]
3250   --with-apparmor-profiles
3251                           install apparmor profiles [default=no]
3252   --with-dtrace           use dtrace for static probing [default=check]
3253   --with-numad            use numad to manage CPU placement dynamically
3254                           [default=check]
3255   --with-libpcap=[PFX]    libpcap location
3256   --with-network          with virtual network driver [default=yes]
3257   --with-secrets          with local secrets management driver [default=yes]
3258   --with-storage-dir      with directory backend for the storage driver
3259                           [default=yes]
3260   --with-storage-fs       with FileSystem backend for the storage driver
3261                           [default=check]
3262   --with-storage-lvm      with LVM backend for the storage driver
3263                           [default=check]
3264   --with-storage-iscsi    with iSCSI backend for the storage driver
3265                           [default=check]
3266   --with-storage-scsi     with SCSI backend for the storage driver
3267                           [default=check]
3268   --with-storage-mpath    with mpath backend for the storage driver
3269                           [default=check]
3270   --with-storage-disk     with GPartd Disk backend for the storage driver
3271                           [default=check]
3272   --with-storage-rbd      with RADOS Block Device backend for the storage
3273                           driver [default=check]
3274   --with-storage-sheepdog with Sheepdog backend for the storage driver
3275                           [default=check]
3276   --with-storage-gluster  with Gluster backend for the storage driver
3277                           [default=check]
3278   --with-test-suite       build test suite by default [default=check]
3279   --with-libiconv-prefix[=DIR]  search for libiconv in DIR/include and DIR/lib
3280   --without-libiconv-prefix     don't search for libiconv in includedir and libdir
3281   --with-libintl-prefix[=DIR]  search for libintl in DIR/include and DIR/lib
3282   --without-libintl-prefix     don't search for libintl in includedir and libdir
3283   --with-driver-modules   build drivers as loadable modules [default=check]
3284   --with-interface        with host interface driver [default=check]
3285   --with-qemu-user        username to run QEMU system instance as
3286                           [default=platform dependent]
3287   --with-qemu-group       groupname to run QEMU system instance as
3288                           [default=platform dependent]
3289   --with-macvtap          enable macvtap device [default=check]
3290   --with-virtualport      enable virtual port support [default=check]
3291   --with-wireshark-dissector
3292                           enable wireshark dissector plugin support
3293                           [default=check]
3294   --with-ws-plugindir     wireshark plugins directory for use when installing
3295                           wireshark plugin
3296
3297 Some influential environment variables:
3298   CC          C compiler command
3299   CFLAGS      C compiler flags
3300   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
3301               nonstandard directory <lib dir>
3302   LIBS        libraries to pass to the linker, e.g. -l<library>
3303   CPPFLAGS    (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
3304               you have headers in a nonstandard directory <include dir>
3305   CPP         C preprocessor
3306   PKG_CONFIG  path to pkg-config utility
3307   PKG_CONFIG_PATH
3308               directories to add to pkg-config's search path
3309   PKG_CONFIG_LIBDIR
3310               path overriding pkg-config's built-in search path
3311   AVAHI_CFLAGS
3312               C compiler flags for AVAHI, overriding pkg-config
3313   AVAHI_LIBS  linker flags for AVAHI, overriding pkg-config
3314   BLKID_CFLAGS
3315               C compiler flags for BLKID, overriding pkg-config
3316   BLKID_LIBS  linker flags for BLKID, overriding pkg-config
3317   CURL_CFLAGS C compiler flags for CURL, overriding pkg-config
3318   CURL_LIBS   linker flags for CURL, overriding pkg-config
3319   DBUS_CFLAGS C compiler flags for DBUS, overriding pkg-config
3320   DBUS_LIBS   linker flags for DBUS, overriding pkg-config
3321   FUSE_CFLAGS C compiler flags for FUSE, overriding pkg-config
3322   FUSE_LIBS   linker flags for FUSE, overriding pkg-config
3323   GLUSTERFS_CFLAGS
3324               C compiler flags for GLUSTERFS, overriding pkg-config
3325   GLUSTERFS_LIBS
3326               linker flags for GLUSTERFS, overriding pkg-config
3327   HAL_CFLAGS  C compiler flags for HAL, overriding pkg-config
3328   HAL_LIBS    linker flags for HAL, overriding pkg-config
3329   NETCF_CFLAGS
3330               C compiler flags for NETCF, overriding pkg-config
3331   NETCF_LIBS  linker flags for NETCF, overriding pkg-config
3332   OPENWSMAN_CFLAGS
3333               C compiler flags for OPENWSMAN, overriding pkg-config
3334   OPENWSMAN_LIBS
3335               linker flags for OPENWSMAN, overriding pkg-config
3336   PCIACCESS_CFLAGS
3337               C compiler flags for PCIACCESS, overriding pkg-config
3338   PCIACCESS_LIBS
3339               linker flags for PCIACCESS, overriding pkg-config
3340   SSH2_CFLAGS C compiler flags for SSH2, overriding pkg-config
3341   SSH2_LIBS   linker flags for SSH2, overriding pkg-config
3342   SYSTEMD_DAEMON_CFLAGS
3343               C compiler flags for SYSTEMD_DAEMON, overriding pkg-config
3344   SYSTEMD_DAEMON_LIBS
3345               linker flags for SYSTEMD_DAEMON, overriding pkg-config
3346   UDEV_CFLAGS C compiler flags for UDEV, overriding pkg-config
3347   UDEV_LIBS   linker flags for UDEV, overriding pkg-config
3348   LIBXML_CFLAGS
3349               C compiler flags for LIBXML, overriding pkg-config
3350   LIBXML_LIBS linker flags for LIBXML, overriding pkg-config
3351   GNUTLS_CFLAGS
3352               C compiler flags for GNUTLS, overriding pkg-config
3353   GNUTLS_LIBS linker flags for GNUTLS, overriding pkg-config
3354   POLKIT_CFLAGS
3355               C compiler flags for POLKIT, overriding pkg-config
3356   POLKIT_LIBS linker flags for POLKIT, overriding pkg-config
3357   LIBPARTED_CFLAGS
3358               C compiler flags for LIBPARTED, overriding pkg-config
3359   LIBPARTED_LIBS
3360               linker flags for LIBPARTED, overriding pkg-config
3361   DEVMAPPER_CFLAGS
3362               C compiler flags for DEVMAPPER, overriding pkg-config
3363   DEVMAPPER_LIBS
3364               linker flags for DEVMAPPER, overriding pkg-config
3365   LIBNL_CFLAGS
3366               C compiler flags for LIBNL, overriding pkg-config
3367   LIBNL_LIBS  linker flags for LIBNL, overriding pkg-config
3368   LIBNL_ROUTE3_CFLAGS
3369               C compiler flags for LIBNL_ROUTE3, overriding pkg-config
3370   LIBNL_ROUTE3_LIBS
3371               linker flags for LIBNL_ROUTE3, overriding pkg-config
3372   GLIB_CFLAGS C compiler flags for GLIB, overriding pkg-config
3373   GLIB_LIBS   linker flags for GLIB, overriding pkg-config
3374
3375 Use these variables to override the choices made by `configure' or to help
3376 it to find libraries and programs with nonstandard names/locations.
3377
3378 Report bugs to <libvir-list@redhat.com>.
3379 libvirt home page: <http://libvirt.org>.
3380 _ACEOF
3381 ac_status=$?
3382 fi
3383
3384 if test "$ac_init_help" = "recursive"; then
3385   # If there are subdirs, report their specific --help.
3386   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
3387     test -d "$ac_dir" ||
3388       { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
3389       continue
3390     ac_builddir=.
3391
3392 case "$ac_dir" in
3393 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
3394 *)
3395   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
3396   # A ".." for each directory in $ac_dir_suffix.
3397   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
3398   case $ac_top_builddir_sub in
3399   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
3400   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
3401   esac ;;
3402 esac
3403 ac_abs_top_builddir=$ac_pwd
3404 ac_abs_builddir=$ac_pwd$ac_dir_suffix
3405 # for backward compatibility:
3406 ac_top_builddir=$ac_top_build_prefix
3407
3408 case $srcdir in
3409   .)  # We are building in place.
3410     ac_srcdir=.
3411     ac_top_srcdir=$ac_top_builddir_sub
3412     ac_abs_top_srcdir=$ac_pwd ;;
3413   [\\/]* | ?:[\\/]* )  # Absolute name.
3414     ac_srcdir=$srcdir$ac_dir_suffix;
3415     ac_top_srcdir=$srcdir
3416     ac_abs_top_srcdir=$srcdir ;;
3417   *) # Relative name.
3418     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
3419     ac_top_srcdir=$ac_top_build_prefix$srcdir
3420     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
3421 esac
3422 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
3423
3424     cd "$ac_dir" || { ac_status=$?; continue; }
3425     # Check for guested configure.
3426     if test -f "$ac_srcdir/configure.gnu"; then
3427       echo &&
3428       $SHELL "$ac_srcdir/configure.gnu" --help=recursive
3429     elif test -f "$ac_srcdir/configure"; then
3430       echo &&
3431       $SHELL "$ac_srcdir/configure" --help=recursive
3432     else
3433       $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
3434     fi || ac_status=$?
3435     cd "$ac_pwd" || { ac_status=$?; break; }
3436   done
3437 fi
3438
3439 test -n "$ac_init_help" && exit $ac_status
3440 if $ac_init_version; then
3441   cat <<\_ACEOF
3442 libvirt configure 1.2.5
3443 generated by GNU Autoconf 2.69
3444
3445 Copyright (C) 2012 Free Software Foundation, Inc.
3446 This configure script is free software; the Free Software Foundation
3447 gives unlimited permission to copy, distribute and modify it.
3448 _ACEOF
3449   exit
3450 fi
3451
3452 ## ------------------------ ##
3453 ## Autoconf initialization. ##
3454 ## ------------------------ ##
3455
3456 # ac_fn_c_try_compile LINENO
3457 # --------------------------
3458 # Try to compile conftest.$ac_ext, and return whether this succeeded.
3459 ac_fn_c_try_compile ()
3460 {
3461   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
3462   rm -f conftest.$ac_objext
3463   if { { ac_try="$ac_compile"
3464 case "(($ac_try" in
3465   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3466   *) ac_try_echo=$ac_try;;
3467 esac
3468 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3469 $as_echo "$ac_try_echo"; } >&5
3470   (eval "$ac_compile") 2>conftest.err
3471   ac_status=$?
3472   if test -s conftest.err; then
3473     grep -v '^ *+' conftest.err >conftest.er1
3474     cat conftest.er1 >&5
3475     mv -f conftest.er1 conftest.err
3476   fi
3477   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3478   test $ac_status = 0; } && {
3479          test -z "$ac_c_werror_flag" ||
3480          test ! -s conftest.err
3481        } && test -s conftest.$ac_objext; then :
3482   ac_retval=0
3483 else
3484   $as_echo "$as_me: failed program was:" >&5
3485 sed 's/^/| /' conftest.$ac_ext >&5
3486
3487         ac_retval=1
3488 fi
3489   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
3490   as_fn_set_status $ac_retval
3491
3492 } # ac_fn_c_try_compile
3493
3494 # ac_fn_c_try_cpp LINENO
3495 # ----------------------
3496 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
3497 ac_fn_c_try_cpp ()
3498 {
3499   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
3500   if { { ac_try="$ac_cpp conftest.$ac_ext"
3501 case "(($ac_try" in
3502   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3503   *) ac_try_echo=$ac_try;;
3504 esac
3505 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3506 $as_echo "$ac_try_echo"; } >&5
3507   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
3508   ac_status=$?
3509   if test -s conftest.err; then
3510     grep -v '^ *+' conftest.err >conftest.er1
3511     cat conftest.er1 >&5
3512     mv -f conftest.er1 conftest.err
3513   fi
3514   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3515   test $ac_status = 0; } > conftest.i && {
3516          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
3517          test ! -s conftest.err
3518        }; then :
3519   ac_retval=0
3520 else
3521   $as_echo "$as_me: failed program was:" >&5
3522 sed 's/^/| /' conftest.$ac_ext >&5
3523
3524     ac_retval=1
3525 fi
3526   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
3527   as_fn_set_status $ac_retval
3528
3529 } # ac_fn_c_try_cpp
3530
3531 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
3532 # -------------------------------------------------------
3533 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
3534 # the include files in INCLUDES and setting the cache variable VAR
3535 # accordingly.
3536 ac_fn_c_check_header_mongrel ()
3537 {
3538   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
3539   if eval \${$3+:} false; then :
3540   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
3541 $as_echo_n "checking for $2... " >&6; }
3542 if eval \${$3+:} false; then :
3543   $as_echo_n "(cached) " >&6
3544 fi
3545 eval ac_res=\$$3
3546                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
3547 $as_echo "$ac_res" >&6; }
3548 else
3549   # Is the header compilable?
3550 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
3551 $as_echo_n "checking $2 usability... " >&6; }
3552 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3553 /* end confdefs.h.  */
3554 $4
3555 #include <$2>
3556 _ACEOF
3557 if ac_fn_c_try_compile "$LINENO"; then :
3558   ac_header_compiler=yes
3559 else
3560   ac_header_compiler=no
3561 fi
3562 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
3564 $as_echo "$ac_header_compiler" >&6; }
3565
3566 # Is the header present?
3567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
3568 $as_echo_n "checking $2 presence... " >&6; }
3569 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3570 /* end confdefs.h.  */
3571 #include <$2>
3572 _ACEOF
3573 if ac_fn_c_try_cpp "$LINENO"; then :
3574   ac_header_preproc=yes
3575 else
3576   ac_header_preproc=no
3577 fi
3578 rm -f conftest.err conftest.i conftest.$ac_ext
3579 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
3580 $as_echo "$ac_header_preproc" >&6; }
3581
3582 # So?  What about this header?
3583 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
3584   yes:no: )
3585     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
3586 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
3587     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
3588 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
3589     ;;
3590   no:yes:* )
3591     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
3592 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
3593     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     check for missing prerequisite headers?" >&5
3594 $as_echo "$as_me: WARNING: $2:     check for missing prerequisite headers?" >&2;}
3595     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
3596 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
3597     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&5
3598 $as_echo "$as_me: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&2;}
3599     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
3600 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
3601 ( $as_echo "## ------------------------------------- ##
3602 ## Report this to libvir-list@redhat.com ##
3603 ## ------------------------------------- ##"
3604      ) | sed "s/^/$as_me: WARNING:     /" >&2
3605     ;;
3606 esac
3607   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
3608 $as_echo_n "checking for $2... " >&6; }
3609 if eval \${$3+:} false; then :
3610   $as_echo_n "(cached) " >&6
3611 else
3612   eval "$3=\$ac_header_compiler"
3613 fi
3614 eval ac_res=\$$3
3615                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
3616 $as_echo "$ac_res" >&6; }
3617 fi
3618   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
3619
3620 } # ac_fn_c_check_header_mongrel
3621
3622 # ac_fn_c_try_run LINENO
3623 # ----------------------
3624 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
3625 # that executables *can* be run.
3626 ac_fn_c_try_run ()
3627 {
3628   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
3629   if { { ac_try="$ac_link"
3630 case "(($ac_try" in
3631   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3632   *) ac_try_echo=$ac_try;;
3633 esac
3634 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3635 $as_echo "$ac_try_echo"; } >&5
3636   (eval "$ac_link") 2>&5
3637   ac_status=$?
3638   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3639   test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
3640   { { case "(($ac_try" in
3641   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3642   *) ac_try_echo=$ac_try;;
3643 esac
3644 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3645 $as_echo "$ac_try_echo"; } >&5
3646   (eval "$ac_try") 2>&5
3647   ac_status=$?
3648   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3649   test $ac_status = 0; }; }; then :
3650   ac_retval=0
3651 else
3652   $as_echo "$as_me: program exited with status $ac_status" >&5
3653        $as_echo "$as_me: failed program was:" >&5
3654 sed 's/^/| /' conftest.$ac_ext >&5
3655
3656        ac_retval=$ac_status
3657 fi
3658   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
3659   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
3660   as_fn_set_status $ac_retval
3661
3662 } # ac_fn_c_try_run
3663
3664 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
3665 # -------------------------------------------------------
3666 # Tests whether HEADER exists and can be compiled using the include files in
3667 # INCLUDES, setting the cache variable VAR accordingly.
3668 ac_fn_c_check_header_compile ()
3669 {
3670   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
3671   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
3672 $as_echo_n "checking for $2... " >&6; }
3673 if eval \${$3+:} false; then :
3674   $as_echo_n "(cached) " >&6
3675 else
3676   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3677 /* end confdefs.h.  */
3678 $4
3679 #include <$2>
3680 _ACEOF
3681 if ac_fn_c_try_compile "$LINENO"; then :
3682   eval "$3=yes"
3683 else
3684   eval "$3=no"
3685 fi
3686 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3687 fi
3688 eval ac_res=\$$3
3689                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
3690 $as_echo "$ac_res" >&6; }
3691   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
3692
3693 } # ac_fn_c_check_header_compile
3694
3695 # ac_fn_c_try_link LINENO
3696 # -----------------------
3697 # Try to link conftest.$ac_ext, and return whether this succeeded.
3698 ac_fn_c_try_link ()
3699 {
3700   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
3701   rm -f conftest.$ac_objext conftest$ac_exeext
3702   if { { ac_try="$ac_link"
3703 case "(($ac_try" in
3704   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3705   *) ac_try_echo=$ac_try;;
3706 esac
3707 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3708 $as_echo "$ac_try_echo"; } >&5
3709   (eval "$ac_link") 2>conftest.err
3710   ac_status=$?
3711   if test -s conftest.err; then
3712     grep -v '^ *+' conftest.err >conftest.er1
3713     cat conftest.er1 >&5
3714     mv -f conftest.er1 conftest.err
3715   fi
3716   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3717   test $ac_status = 0; } && {
3718          test -z "$ac_c_werror_flag" ||
3719          test ! -s conftest.err
3720        } && test -s conftest$ac_exeext && {
3721          test "$cross_compiling" = yes ||
3722          test -x conftest$ac_exeext
3723        }; then :
3724   ac_retval=0
3725 else
3726   $as_echo "$as_me: failed program was:" >&5
3727 sed 's/^/| /' conftest.$ac_ext >&5
3728
3729         ac_retval=1
3730 fi
3731   # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
3732   # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
3733   # interfere with the next link command; also delete a directory that is
3734   # left behind by Apple's compiler.  We do this before executing the actions.
3735   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
3736   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
3737   as_fn_set_status $ac_retval
3738
3739 } # ac_fn_c_try_link
3740
3741 # ac_fn_c_check_func LINENO FUNC VAR
3742 # ----------------------------------
3743 # Tests whether FUNC exists, setting the cache variable VAR accordingly
3744 ac_fn_c_check_func ()
3745 {
3746   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
3747   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
3748 $as_echo_n "checking for $2... " >&6; }
3749 if eval \${$3+:} false; then :
3750   $as_echo_n "(cached) " >&6
3751 else
3752   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3753 /* end confdefs.h.  */
3754 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
3755    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
3756 #define $2 innocuous_$2
3757
3758 /* System header to define __stub macros and hopefully few prototypes,
3759     which can conflict with char $2 (); below.
3760     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3761     <limits.h> exists even on freestanding compilers.  */
3762
3763 #ifdef __STDC__
3764 # include <limits.h>
3765 #else
3766 # include <assert.h>
3767 #endif
3768
3769 #undef $2
3770
3771 /* Override any GCC internal prototype to avoid an error.
3772    Use char because int might match the return type of a GCC
3773    builtin and then its argument prototype would still apply.  */
3774 #ifdef __cplusplus
3775 extern "C"
3776 #endif
3777 char $2 ();
3778 /* The GNU C library defines this for functions which it implements
3779     to always fail with ENOSYS.  Some functions are actually named
3780     something starting with __ and the normal name is an alias.  */
3781 #if defined __stub_$2 || defined __stub___$2
3782 choke me
3783 #endif
3784
3785 int
3786 main ()
3787 {
3788 return $2 ();
3789   ;
3790   return 0;
3791 }
3792 _ACEOF
3793 if ac_fn_c_try_link "$LINENO"; then :
3794   eval "$3=yes"
3795 else
3796   eval "$3=no"
3797 fi
3798 rm -f core conftest.err conftest.$ac_objext \
3799     conftest$ac_exeext conftest.$ac_ext
3800 fi
3801 eval ac_res=\$$3
3802                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
3803 $as_echo "$ac_res" >&6; }
3804   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
3805
3806 } # ac_fn_c_check_func
3807
3808 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
3809 # -------------------------------------------
3810 # Tests whether TYPE exists after having included INCLUDES, setting cache
3811 # variable VAR accordingly.
3812 ac_fn_c_check_type ()
3813 {
3814   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
3815   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
3816 $as_echo_n "checking for $2... " >&6; }
3817 if eval \${$3+:} false; then :
3818   $as_echo_n "(cached) " >&6
3819 else
3820   eval "$3=no"
3821   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3822 /* end confdefs.h.  */
3823 $4
3824 int
3825 main ()
3826 {
3827 if (sizeof ($2))
3828          return 0;
3829   ;
3830   return 0;
3831 }
3832 _ACEOF
3833 if ac_fn_c_try_compile "$LINENO"; then :
3834   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3835 /* end confdefs.h.  */
3836 $4
3837 int
3838 main ()
3839 {
3840 if (sizeof (($2)))
3841             return 0;
3842   ;
3843   return 0;
3844 }
3845 _ACEOF
3846 if ac_fn_c_try_compile "$LINENO"; then :
3847
3848 else
3849   eval "$3=yes"
3850 fi
3851 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3852 fi
3853 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3854 fi
3855 eval ac_res=\$$3
3856                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
3857 $as_echo "$ac_res" >&6; }
3858   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
3859
3860 } # ac_fn_c_check_type
3861
3862 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
3863 # ----------------------------------------------------
3864 # Tries to find if the field MEMBER exists in type AGGR, after including
3865 # INCLUDES, setting cache variable VAR accordingly.
3866 ac_fn_c_check_member ()
3867 {
3868   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
3869   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
3870 $as_echo_n "checking for $2.$3... " >&6; }
3871 if eval \${$4+:} false; then :
3872   $as_echo_n "(cached) " >&6
3873 else
3874   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3875 /* end confdefs.h.  */
3876 $5
3877 int
3878 main ()
3879 {
3880 static $2 ac_aggr;
3881 if (ac_aggr.$3)
3882 return 0;
3883   ;
3884   return 0;
3885 }
3886 _ACEOF
3887 if ac_fn_c_try_compile "$LINENO"; then :
3888   eval "$4=yes"
3889 else
3890   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3891 /* end confdefs.h.  */
3892 $5
3893 int
3894 main ()
3895 {
3896 static $2 ac_aggr;
3897 if (sizeof ac_aggr.$3)
3898 return 0;
3899   ;
3900   return 0;
3901 }
3902 _ACEOF
3903 if ac_fn_c_try_compile "$LINENO"; then :
3904   eval "$4=yes"
3905 else
3906   eval "$4=no"
3907 fi
3908 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3909 fi
3910 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3911 fi
3912 eval ac_res=\$$4
3913                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
3914 $as_echo "$ac_res" >&6; }
3915   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
3916
3917 } # ac_fn_c_check_member
3918
3919 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
3920 # --------------------------------------------
3921 # Tries to find the compile-time value of EXPR in a program that includes
3922 # INCLUDES, setting VAR accordingly. Returns whether the value could be
3923 # computed
3924 ac_fn_c_compute_int ()
3925 {
3926   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
3927   if test "$cross_compiling" = yes; then
3928     # Depending upon the size, compute the lo and hi bounds.
3929 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3930 /* end confdefs.h.  */
3931 $4
3932 int
3933 main ()
3934 {
3935 static int test_array [1 - 2 * !(($2) >= 0)];
3936 test_array [0] = 0;
3937 return test_array [0];
3938
3939   ;
3940   return 0;
3941 }
3942 _ACEOF
3943 if ac_fn_c_try_compile "$LINENO"; then :
3944   ac_lo=0 ac_mid=0
3945   while :; do
3946     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3947 /* end confdefs.h.  */
3948 $4
3949 int
3950 main ()
3951 {
3952 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
3953 test_array [0] = 0;
3954 return test_array [0];
3955
3956   ;
3957   return 0;
3958 }
3959 _ACEOF
3960 if ac_fn_c_try_compile "$LINENO"; then :
3961   ac_hi=$ac_mid; break
3962 else
3963   as_fn_arith $ac_mid + 1 && ac_lo=$as_val
3964                         if test $ac_lo -le $ac_mid; then
3965                           ac_lo= ac_hi=
3966                           break
3967                         fi
3968                         as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
3969 fi
3970 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3971   done
3972 else
3973   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3974 /* end confdefs.h.  */
3975 $4
3976 int
3977 main ()
3978 {
3979 static int test_array [1 - 2 * !(($2) < 0)];
3980 test_array [0] = 0;
3981 return test_array [0];
3982
3983   ;
3984   return 0;
3985 }
3986 _ACEOF
3987 if ac_fn_c_try_compile "$LINENO"; then :
3988   ac_hi=-1 ac_mid=-1
3989   while :; do
3990     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3991 /* end confdefs.h.  */
3992 $4
3993 int
3994 main ()
3995 {
3996 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
3997 test_array [0] = 0;
3998 return test_array [0];
3999
4000   ;
4001   return 0;
4002 }
4003 _ACEOF
4004 if ac_fn_c_try_compile "$LINENO"; then :
4005   ac_lo=$ac_mid; break
4006 else
4007   as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
4008                         if test $ac_mid -le $ac_hi; then
4009                           ac_lo= ac_hi=
4010                           break
4011                         fi
4012                         as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
4013 fi
4014 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4015   done
4016 else
4017   ac_lo= ac_hi=
4018 fi
4019 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4020 fi
4021 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4022 # Binary search between lo and hi bounds.
4023 while test "x$ac_lo" != "x$ac_hi"; do
4024   as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
4025   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4026 /* end confdefs.h.  */
4027 $4
4028 int
4029 main ()
4030 {
4031 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
4032 test_array [0] = 0;
4033 return test_array [0];
4034
4035   ;
4036   return 0;
4037 }
4038 _ACEOF
4039 if ac_fn_c_try_compile "$LINENO"; then :
4040   ac_hi=$ac_mid
4041 else
4042   as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
4043 fi
4044 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4045 done
4046 case $ac_lo in #((
4047 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
4048 '') ac_retval=1 ;;
4049 esac
4050   else
4051     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4052 /* end confdefs.h.  */
4053 $4
4054 static long int longval () { return $2; }
4055 static unsigned long int ulongval () { return $2; }
4056 #include <stdio.h>
4057 #include <stdlib.h>
4058 int
4059 main ()
4060 {
4061
4062   FILE *f = fopen ("conftest.val", "w");
4063   if (! f)
4064     return 1;
4065   if (($2) < 0)
4066     {
4067       long int i = longval ();
4068       if (i != ($2))
4069         return 1;
4070       fprintf (f, "%ld", i);
4071     }
4072   else
4073     {
4074       unsigned long int i = ulongval ();
4075       if (i != ($2))
4076         return 1;
4077       fprintf (f, "%lu", i);
4078     }
4079   /* Do not output a trailing newline, as this causes \r\n confusion
4080      on some platforms.  */
4081   return ferror (f) || fclose (f) != 0;
4082
4083   ;
4084   return 0;
4085 }
4086 _ACEOF
4087 if ac_fn_c_try_run "$LINENO"; then :
4088   echo >>conftest.val; read $3 <conftest.val; ac_retval=0
4089 else
4090   ac_retval=1
4091 fi
4092 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4093   conftest.$ac_objext conftest.beam conftest.$ac_ext
4094 rm -f conftest.val
4095
4096   fi
4097   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
4098   as_fn_set_status $ac_retval
4099
4100 } # ac_fn_c_compute_int
4101
4102 # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
4103 # ---------------------------------------------
4104 # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
4105 # accordingly.
4106 ac_fn_c_check_decl ()
4107 {
4108   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
4109   as_decl_name=`echo $2|sed 's/ *(.*//'`
4110   as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
4111   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
4112 $as_echo_n "checking whether $as_decl_name is declared... " >&6; }
4113 if eval \${$3+:} false; then :
4114   $as_echo_n "(cached) " >&6
4115 else
4116   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4117 /* end confdefs.h.  */
4118 $4
4119 int
4120 main ()
4121 {
4122 #ifndef $as_decl_name
4123 #ifdef __cplusplus
4124   (void) $as_decl_use;
4125 #else
4126   (void) $as_decl_name;
4127 #endif
4128 #endif
4129
4130   ;
4131   return 0;
4132 }
4133 _ACEOF
4134 if ac_fn_c_try_compile "$LINENO"; then :
4135   eval "$3=yes"
4136 else
4137   eval "$3=no"
4138 fi
4139 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4140 fi
4141 eval ac_res=\$$3
4142                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
4143 $as_echo "$ac_res" >&6; }
4144   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
4145
4146 } # ac_fn_c_check_decl
4147 cat >config.log <<_ACEOF
4148 This file contains any messages produced by compilers while
4149 running configure, to aid debugging if configure makes a mistake.
4150
4151 It was created by libvirt $as_me 1.2.5, which was
4152 generated by GNU Autoconf 2.69.  Invocation command line was
4153
4154   $ $0 $@
4155
4156 _ACEOF
4157 exec 5>>config.log
4158 {
4159 cat <<_ASUNAME
4160 ## --------- ##
4161 ## Platform. ##
4162 ## --------- ##
4163
4164 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
4165 uname -m = `(uname -m) 2>/dev/null || echo unknown`
4166 uname -r = `(uname -r) 2>/dev/null || echo unknown`
4167 uname -s = `(uname -s) 2>/dev/null || echo unknown`
4168 uname -v = `(uname -v) 2>/dev/null || echo unknown`
4169
4170 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
4171 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
4172
4173 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
4174 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
4175 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
4176 /usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
4177 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
4178 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
4179 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
4180
4181 _ASUNAME
4182
4183 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4184 for as_dir in $PATH
4185 do
4186   IFS=$as_save_IFS
4187   test -z "$as_dir" && as_dir=.
4188     $as_echo "PATH: $as_dir"
4189   done
4190 IFS=$as_save_IFS
4191
4192 } >&5
4193
4194 cat >&5 <<_ACEOF
4195
4196
4197 ## ----------- ##
4198 ## Core tests. ##
4199 ## ----------- ##
4200
4201 _ACEOF
4202
4203
4204 # Keep a trace of the command line.
4205 # Strip out --no-create and --no-recursion so they do not pile up.
4206 # Strip out --silent because we don't want to record it for future runs.
4207 # Also quote any args containing shell meta-characters.
4208 # Make two passes to allow for proper duplicate-argument suppression.
4209 ac_configure_args=
4210 ac_configure_args0=
4211 ac_configure_args1=
4212 ac_must_keep_next=false
4213 for ac_pass in 1 2
4214 do
4215   for ac_arg
4216   do
4217     case $ac_arg in
4218     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
4219     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
4220     | -silent | --silent | --silen | --sile | --sil)
4221       continue ;;
4222     *\'*)
4223       ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
4224     esac
4225     case $ac_pass in
4226     1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
4227     2)
4228       as_fn_append ac_configure_args1 " '$ac_arg'"
4229       if test $ac_must_keep_next = true; then
4230         ac_must_keep_next=false # Got value, back to normal.
4231       else
4232         case $ac_arg in
4233           *=* | --config-cache | -C | -disable-* | --disable-* \
4234           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
4235           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
4236           | -with-* | --with-* | -without-* | --without-* | --x)
4237             case "$ac_configure_args0 " in
4238               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
4239             esac
4240             ;;
4241           -* ) ac_must_keep_next=true ;;
4242         esac
4243       fi
4244       as_fn_append ac_configure_args " '$ac_arg'"
4245       ;;
4246     esac
4247   done
4248 done
4249 { ac_configure_args0=; unset ac_configure_args0;}
4250 { ac_configure_args1=; unset ac_configure_args1;}
4251
4252 # When interrupted or exit'd, cleanup temporary files, and complete
4253 # config.log.  We remove comments because anyway the quotes in there
4254 # would cause problems or look ugly.
4255 # WARNING: Use '\'' to represent an apostrophe within the trap.
4256 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
4257 trap 'exit_status=$?
4258   # Save into config.log some information that might help in debugging.
4259   {
4260     echo
4261
4262     $as_echo "## ---------------- ##
4263 ## Cache variables. ##
4264 ## ---------------- ##"
4265     echo
4266     # The following way of writing the cache mishandles newlines in values,
4267 (
4268   for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
4269     eval ac_val=\$$ac_var
4270     case $ac_val in #(
4271     *${as_nl}*)
4272       case $ac_var in #(
4273       *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
4274 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
4275       esac
4276       case $ac_var in #(
4277       _ | IFS | as_nl) ;; #(
4278       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
4279       *) { eval $ac_var=; unset $ac_var;} ;;
4280       esac ;;
4281     esac
4282   done
4283   (set) 2>&1 |
4284     case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
4285     *${as_nl}ac_space=\ *)
4286       sed -n \
4287         "s/'\''/'\''\\\\'\'''\''/g;
4288           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
4289       ;; #(
4290     *)
4291       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
4292       ;;
4293     esac |
4294     sort
4295 )
4296     echo
4297
4298     $as_echo "## ----------------- ##
4299 ## Output variables. ##
4300 ## ----------------- ##"
4301     echo
4302     for ac_var in $ac_subst_vars
4303     do
4304       eval ac_val=\$$ac_var
4305       case $ac_val in
4306       *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
4307       esac
4308       $as_echo "$ac_var='\''$ac_val'\''"
4309     done | sort
4310     echo
4311
4312     if test -n "$ac_subst_files"; then
4313       $as_echo "## ------------------- ##
4314 ## File substitutions. ##
4315 ## ------------------- ##"
4316       echo
4317       for ac_var in $ac_subst_files
4318       do
4319         eval ac_val=\$$ac_var
4320         case $ac_val in
4321         *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
4322         esac
4323         $as_echo "$ac_var='\''$ac_val'\''"
4324       done | sort
4325       echo
4326     fi
4327
4328     if test -s confdefs.h; then
4329       $as_echo "## ----------- ##
4330 ## confdefs.h. ##
4331 ## ----------- ##"
4332       echo
4333       cat confdefs.h
4334       echo
4335     fi
4336     test "$ac_signal" != 0 &&
4337       $as_echo "$as_me: caught signal $ac_signal"
4338     $as_echo "$as_me: exit $exit_status"
4339   } >&5
4340   rm -f core *.core core.conftest.* &&
4341     rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
4342     exit $exit_status
4343 ' 0
4344 for ac_signal in 1 2 13 15; do
4345   trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
4346 done
4347 ac_signal=0
4348
4349 # confdefs.h avoids OS command line length limits that DEFS can exceed.
4350 rm -f -r conftest* confdefs.h
4351
4352 $as_echo "/* confdefs.h */" > confdefs.h
4353
4354 # Predefined preprocessor variables.
4355
4356 cat >>confdefs.h <<_ACEOF
4357 #define PACKAGE_NAME "$PACKAGE_NAME"
4358 _ACEOF
4359
4360 cat >>confdefs.h <<_ACEOF
4361 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
4362 _ACEOF
4363
4364 cat >>confdefs.h <<_ACEOF
4365 #define PACKAGE_VERSION "$PACKAGE_VERSION"
4366 _ACEOF
4367
4368 cat >>confdefs.h <<_ACEOF
4369 #define PACKAGE_STRING "$PACKAGE_STRING"
4370 _ACEOF
4371
4372 cat >>confdefs.h <<_ACEOF
4373 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
4374 _ACEOF
4375
4376 cat >>confdefs.h <<_ACEOF
4377 #define PACKAGE_URL "$PACKAGE_URL"
4378 _ACEOF
4379
4380
4381 # Let the site file select an alternate cache file if it wants to.
4382 # Prefer an explicitly selected file to automatically selected ones.
4383 ac_site_file1=NONE
4384 ac_site_file2=NONE
4385 if test -n "$CONFIG_SITE"; then
4386   # We do not want a PATH search for config.site.
4387   case $CONFIG_SITE in #((
4388     -*)  ac_site_file1=./$CONFIG_SITE;;
4389     */*) ac_site_file1=$CONFIG_SITE;;
4390     *)   ac_site_file1=./$CONFIG_SITE;;
4391   esac
4392 elif test "x$prefix" != xNONE; then
4393   ac_site_file1=$prefix/share/config.site
4394   ac_site_file2=$prefix/etc/config.site
4395 else
4396   ac_site_file1=$ac_default_prefix/share/config.site
4397   ac_site_file2=$ac_default_prefix/etc/config.site
4398 fi
4399 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
4400 do
4401   test "x$ac_site_file" = xNONE && continue
4402   if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
4403     { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
4404 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
4405     sed 's/^/| /' "$ac_site_file" >&5
4406     . "$ac_site_file" \
4407       || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4408 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4409 as_fn_error $? "failed to load site script $ac_site_file
4410 See \`config.log' for more details" "$LINENO" 5; }
4411   fi
4412 done
4413
4414 if test -r "$cache_file"; then
4415   # Some versions of bash will fail to source /dev/null (special files
4416   # actually), so we avoid doing that.  DJGPP emulates it as a regular file.
4417   if test /dev/null != "$cache_file" && test -f "$cache_file"; then
4418     { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
4419 $as_echo "$as_me: loading cache $cache_file" >&6;}
4420     case $cache_file in
4421       [\\/]* | ?:[\\/]* ) . "$cache_file";;
4422       *)                      . "./$cache_file";;
4423     esac
4424   fi
4425 else
4426   { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
4427 $as_echo "$as_me: creating cache $cache_file" >&6;}
4428   >$cache_file
4429 fi
4430
4431 gl_header_list="$gl_header_list sys/socket.h"
4432 gl_header_list="$gl_header_list arpa/inet.h"
4433 gl_header_list="$gl_header_list features.h"
4434 gl_func_list="$gl_func_list btowc"
4435 gl_func_list="$gl_func_list canonicalize_file_name"
4436 gl_func_list="$gl_func_list getcwd"
4437 gl_func_list="$gl_func_list readlink"
4438 gl_func_list="$gl_func_list realpath"
4439 gl_header_list="$gl_header_list sys/param.h"
4440 gl_func_list="$gl_func_list readlinkat"
4441 gl_func_list="$gl_func_list chown"
4442 gl_func_list="$gl_func_list fchown"
4443 gl_func_list="$gl_func_list _set_invalid_parameter_handler"
4444 gl_header_list="$gl_header_list unistd.h"
4445 gl_header_list="$gl_header_list execinfo.h"
4446 gl_func_list="$gl_func_list fcntl"
4447 gl_func_list="$gl_func_list symlink"
4448 gl_func_list="$gl_func_list ffs"
4449 gl_func_list="$gl_func_list ffsl"
4450 gl_func_list="$gl_func_list isblank"
4451 gl_func_list="$gl_func_list iswctype"
4452 gl_func_list="$gl_func_list mbsrtowcs"
4453 gl_func_list="$gl_func_list mempcpy"
4454 gl_func_list="$gl_func_list wmemchr"
4455 gl_func_list="$gl_func_list wmemcpy"
4456 gl_func_list="$gl_func_list wmempcpy"
4457 gl_header_list="$gl_header_list wctype.h"
4458 gl_func_list="$gl_func_list fpurge"
4459 gl_func_list="$gl_func_list __fpurge"
4460 gl_func_list="$gl_func_list __freading"
4461 gl_header_list="$gl_header_list sys/stat.h"
4462 gl_func_list="$gl_func_list fsync"
4463 gl_header_list="$gl_header_list netdb.h"
4464 gl_header_list="$gl_header_list netinet/in.h"
4465 gl_func_list="$gl_func_list getdelim"
4466 gl_func_list="$gl_func_list getdtablesize"
4467 gl_header_list="$gl_header_list stdio_ext.h"
4468 gl_header_list="$gl_header_list termios.h"
4469 gl_func_list="$gl_func_list __fsetlocking"
4470 gl_func_list="$gl_func_list tcgetattr"
4471 gl_func_list="$gl_func_list tcsetattr"
4472 gl_header_list="$gl_header_list sys/time.h"
4473 gl_func_list="$gl_func_list gettimeofday"
4474 gl_header_list="$gl_header_list grp.h"
4475 gl_header_list="$gl_header_list langinfo.h"
4476 gl_header_list="$gl_header_list xlocale.h"
4477 gl_func_list="$gl_func_list lstat"
4478 gl_func_list="$gl_func_list mbsinit"
4479 gl_func_list="$gl_func_list mbrtowc"
4480 gl_header_list="$gl_header_list sys/mman.h"
4481 gl_func_list="$gl_func_list mprotect"
4482 gl_func_list="$gl_func_list getgrouplist"
4483 gl_func_list="$gl_func_list mkostemp"
4484 gl_func_list="$gl_func_list mkostemps"
4485 gl_func_list="$gl_func_list nl_langinfo"
4486 gl_header_list="$gl_header_list pty.h"
4487 gl_func_list="$gl_func_list recvmsg"
4488 gl_func_list="$gl_func_list sendmsg"
4489 gl_func_list="$gl_func_list strerror_r"
4490 gl_func_list="$gl_func_list __xpg_strerror_r"
4491 gl_func_list="$gl_func_list pipe"
4492 gl_func_list="$gl_func_list pipe2"
4493 gl_header_list="$gl_header_list poll.h"
4494 gl_header_list="$gl_header_list sys/ioctl.h"
4495 gl_header_list="$gl_header_list sys/filio.h"
4496 gl_func_list="$gl_func_list posix_openpt"
4497 gl_header_list="$gl_header_list pthread.h"
4498 gl_func_list="$gl_func_list pthread_sigmask"
4499 gl_header_list="$gl_header_list malloc.h"
4500 gl_header_list="$gl_header_list sched.h"
4501 gl_func_list="$gl_func_list secure_getenv"
4502 gl_header_list="$gl_header_list sys/select.h"
4503 gl_func_list="$gl_func_list setenv"
4504 gl_func_list="$gl_func_list sigaction"
4505 gl_func_list="$gl_func_list sigaltstack"
4506 gl_func_list="$gl_func_list siginterrupt"
4507 gl_func_list="$gl_func_list sleep"
4508 gl_func_list="$gl_func_list snprintf"
4509 gl_header_list="$gl_header_list wchar.h"
4510 gl_header_list="$gl_header_list stdint.h"
4511 gl_func_list="$gl_func_list strdup"
4512 gl_func_list="$gl_func_list catgets"
4513 gl_header_list="$gl_header_list strings.h"
4514 gl_func_list="$gl_func_list strndup"
4515 gl_func_list="$gl_func_list strptime"
4516 gl_header_list="$gl_header_list sys/uio.h"
4517 gl_header_list="$gl_header_list sys/utsname.h"
4518 gl_header_list="$gl_header_list sys/wait.h"
4519 gl_func_list="$gl_func_list localtime_r"
4520 gl_func_list="$gl_func_list timegm"
4521 gl_func_list="$gl_func_list usleep"
4522 gl_func_list="$gl_func_list vasnprintf"
4523 gl_func_list="$gl_func_list wcrtomb"
4524 gl_func_list="$gl_func_list iswcntrl"
4525 gl_func_list="$gl_func_list getegid"
4526 gl_func_list="$gl_func_list ftruncate"
4527 gl_header_list="$gl_header_list inttypes.h"
4528 gl_func_list="$gl_func_list newlocale"
4529 gl_header_list="$gl_header_list math.h"
4530 gl_func_list="$gl_func_list socketpair"
4531 gl_func_list="$gl_func_list ptsname_r"
4532 gl_header_list="$gl_header_list spawn.h"
4533 gl_func_list="$gl_func_list shutdown"
4534 gl_func_list="$gl_func_list wctob"
4535 gl_func_list="$gl_func_list cfmakeraw"
4536 gl_func_list="$gl_func_list fallocate"
4537 gl_func_list="$gl_func_list geteuid"
4538 gl_func_list="$gl_func_list getgid"
4539 gl_func_list="$gl_func_list getgrnam_r"
4540 gl_func_list="$gl_func_list getmntent_r"
4541 gl_func_list="$gl_func_list getpwuid_r"
4542 gl_func_list="$gl_func_list getuid"
4543 gl_func_list="$gl_func_list kill"
4544 gl_func_list="$gl_func_list mmap"
4545 gl_func_list="$gl_func_list posix_fallocate"
4546 gl_func_list="$gl_func_list posix_memalign"
4547 gl_func_list="$gl_func_list prlimit"
4548 gl_func_list="$gl_func_list regexec"
4549 gl_func_list="$gl_func_list sched_getaffinity"
4550 gl_func_list="$gl_func_list setgroups"
4551 gl_func_list="$gl_func_list setns"
4552 gl_func_list="$gl_func_list setrlimit"
4553 gl_func_list="$gl_func_list sysctlbyname"
4554 gt_needs="$gt_needs "
4555 # Check that the precious variables saved in the cache have kept the same
4556 # value.
4557 ac_cache_corrupted=false
4558 for ac_var in $ac_precious_vars; do
4559   eval ac_old_set=\$ac_cv_env_${ac_var}_set
4560   eval ac_new_set=\$ac_env_${ac_var}_set
4561   eval ac_old_val=\$ac_cv_env_${ac_var}_value
4562   eval ac_new_val=\$ac_env_${ac_var}_value
4563   case $ac_old_set,$ac_new_set in
4564     set,)
4565       { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
4566 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
4567       ac_cache_corrupted=: ;;
4568     ,set)
4569       { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
4570 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
4571       ac_cache_corrupted=: ;;
4572     ,);;
4573     *)
4574       if test "x$ac_old_val" != "x$ac_new_val"; then
4575         # differences in whitespace do not lead to failure.
4576         ac_old_val_w=`echo x $ac_old_val`
4577         ac_new_val_w=`echo x $ac_new_val`
4578         if test "$ac_old_val_w" != "$ac_new_val_w"; then
4579           { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
4580 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
4581           ac_cache_corrupted=:
4582         else
4583           { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
4584 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
4585           eval $ac_var=\$ac_old_val
4586         fi
4587         { $as_echo "$as_me:${as_lineno-$LINENO}:   former value:  \`$ac_old_val'" >&5
4588 $as_echo "$as_me:   former value:  \`$ac_old_val'" >&2;}
4589         { $as_echo "$as_me:${as_lineno-$LINENO}:   current value: \`$ac_new_val'" >&5
4590 $as_echo "$as_me:   current value: \`$ac_new_val'" >&2;}
4591       fi;;
4592   esac
4593   # Pass precious variables to config.status.
4594   if test "$ac_new_set" = set; then
4595     case $ac_new_val in
4596     *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
4597     *) ac_arg=$ac_var=$ac_new_val ;;
4598     esac
4599     case " $ac_configure_args " in
4600       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
4601       *) as_fn_append ac_configure_args " '$ac_arg'" ;;
4602     esac
4603   fi
4604 done
4605 if $ac_cache_corrupted; then
4606   { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4607 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4608   { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
4609 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
4610   as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
4611 fi
4612 ## -------------------- ##
4613 ## Main body of script. ##
4614 ## -------------------- ##
4615
4616 ac_ext=c
4617 ac_cpp='$CPP $CPPFLAGS'
4618 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4619 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4620 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4621
4622
4623
4624 ac_aux_dir=
4625 for ac_dir in build-aux "$srcdir"/build-aux; do
4626   if test -f "$ac_dir/install-sh"; then
4627     ac_aux_dir=$ac_dir
4628     ac_install_sh="$ac_aux_dir/install-sh -c"
4629     break
4630   elif test -f "$ac_dir/install.sh"; then
4631     ac_aux_dir=$ac_dir
4632     ac_install_sh="$ac_aux_dir/install.sh -c"
4633     break
4634   elif test -f "$ac_dir/shtool"; then
4635     ac_aux_dir=$ac_dir
4636     ac_install_sh="$ac_aux_dir/shtool install -c"
4637     break
4638   fi
4639 done
4640 if test -z "$ac_aux_dir"; then
4641   as_fn_error $? "cannot find install-sh, install.sh, or shtool in build-aux \"$srcdir\"/build-aux" "$LINENO" 5
4642 fi
4643
4644 # These three variables are undocumented and unsupported,
4645 # and are intended to be withdrawn in a future Autoconf release.
4646 # They can cause serious problems if a builder's source tree is in a directory
4647 # whose full name contains unusual characters.
4648 ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
4649 ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
4650 ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
4651
4652
4653 ac_config_headers="$ac_config_headers config.h"
4654
4655
4656
4657 am__api_version='1.13'
4658
4659 # Find a good install program.  We prefer a C program (faster),
4660 # so one script is as good as another.  But avoid the broken or
4661 # incompatible versions:
4662 # SysV /etc/install, /usr/sbin/install
4663 # SunOS /usr/etc/install
4664 # IRIX /sbin/install
4665 # AIX /bin/install
4666 # AmigaOS /C/install, which installs bootblocks on floppy discs
4667 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
4668 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
4669 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
4670 # OS/2's system install, which has a completely different semantic
4671 # ./install, which can be erroneously created by make from ./install.sh.
4672 # Reject install programs that cannot install multiple files.
4673 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
4674 $as_echo_n "checking for a BSD-compatible install... " >&6; }
4675 if test -z "$INSTALL"; then
4676 if ${ac_cv_path_install+:} false; then :
4677   $as_echo_n "(cached) " >&6
4678 else
4679   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4680 for as_dir in $PATH
4681 do
4682   IFS=$as_save_IFS
4683   test -z "$as_dir" && as_dir=.
4684     # Account for people who put trailing slashes in PATH elements.
4685 case $as_dir/ in #((
4686   ./ | .// | /[cC]/* | \
4687   /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
4688   ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
4689   /usr/ucb/* ) ;;
4690   *)
4691     # OSF1 and SCO ODT 3.0 have their own names for install.
4692     # Don't use installbsd from OSF since it installs stuff as root
4693     # by default.
4694     for ac_prog in ginstall scoinst install; do
4695       for ac_exec_ext in '' $ac_executable_extensions; do
4696         if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
4697           if test $ac_prog = install &&
4698             grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
4699             # AIX install.  It has an incompatible calling convention.
4700             :
4701           elif test $ac_prog = install &&
4702             grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
4703             # program-specific install script used by HP pwplus--don't use.
4704             :
4705           else
4706             rm -rf conftest.one conftest.two conftest.dir
4707             echo one > conftest.one
4708             echo two > conftest.two
4709             mkdir conftest.dir
4710             if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
4711               test -s conftest.one && test -s conftest.two &&
4712               test -s conftest.dir/conftest.one &&
4713               test -s conftest.dir/conftest.two
4714             then
4715               ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
4716               break 3
4717             fi
4718           fi
4719         fi
4720       done
4721     done
4722     ;;
4723 esac
4724
4725   done
4726 IFS=$as_save_IFS
4727
4728 rm -rf conftest.one conftest.two conftest.dir
4729
4730 fi
4731   if test "${ac_cv_path_install+set}" = set; then
4732     INSTALL=$ac_cv_path_install
4733   else
4734     # As a last resort, use the slow shell script.  Don't cache a
4735     # value for INSTALL within a source directory, because that will
4736     # break other packages using the cache if that directory is
4737     # removed, or if the value is a relative name.
4738     INSTALL=$ac_install_sh
4739   fi
4740 fi
4741 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
4742 $as_echo "$INSTALL" >&6; }
4743
4744 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
4745 # It thinks the first close brace ends the variable substitution.
4746 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
4747
4748 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
4749
4750 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
4751
4752 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
4753 $as_echo_n "checking whether build environment is sane... " >&6; }
4754 # Reject unsafe characters in $srcdir or the absolute working directory
4755 # name.  Accept space and tab only in the latter.
4756 am_lf='
4757 '
4758 case `pwd` in
4759   *[\\\"\#\$\&\'\`$am_lf]*)
4760     as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;;
4761 esac
4762 case $srcdir in
4763   *[\\\"\#\$\&\'\`$am_lf\ \     ]*)
4764     as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;;
4765 esac
4766
4767 # Do 'set' in a subshell so we don't clobber the current shell's
4768 # arguments.  Must try -L first in case configure is actually a
4769 # symlink; some systems play weird games with the mod time of symlinks
4770 # (eg FreeBSD returns the mod time of the symlink's containing
4771 # directory).
4772 if (
4773    am_has_slept=no
4774    for am_try in 1 2; do
4775      echo "timestamp, slept: $am_has_slept" > conftest.file
4776      set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
4777      if test "$*" = "X"; then
4778         # -L didn't work.
4779         set X `ls -t "$srcdir/configure" conftest.file`
4780      fi
4781      if test "$*" != "X $srcdir/configure conftest.file" \
4782         && test "$*" != "X conftest.file $srcdir/configure"; then
4783
4784         # If neither matched, then we have a broken ls.  This can happen
4785         # if, for instance, CONFIG_SHELL is bash and it inherits a
4786         # broken ls alias from the environment.  This has actually
4787         # happened.  Such a system could not be considered "sane".
4788         as_fn_error $? "ls -t appears to fail.  Make sure there is not a broken
4789   alias in your environment" "$LINENO" 5
4790      fi
4791      if test "$2" = conftest.file || test $am_try -eq 2; then
4792        break
4793      fi
4794      # Just in case.
4795      sleep 1
4796      am_has_slept=yes
4797    done
4798    test "$2" = conftest.file
4799    )
4800 then
4801    # Ok.
4802    :
4803 else
4804    as_fn_error $? "newly created file is older than distributed files!
4805 Check your system clock" "$LINENO" 5
4806 fi
4807 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4808 $as_echo "yes" >&6; }
4809 # If we didn't sleep, we still need to ensure time stamps of config.status and
4810 # generated files are strictly newer.
4811 am_sleep_pid=
4812 if grep 'slept: no' conftest.file >/dev/null 2>&1; then
4813   ( sleep 1 ) &
4814   am_sleep_pid=$!
4815 fi
4816
4817 rm -f conftest.file
4818
4819 test "$program_prefix" != NONE &&
4820   program_transform_name="s&^&$program_prefix&;$program_transform_name"
4821 # Use a double $ so make ignores it.
4822 test "$program_suffix" != NONE &&
4823   program_transform_name="s&\$&$program_suffix&;$program_transform_name"
4824 # Double any \ or $.
4825 # By default was `s,x,x', remove it if useless.
4826 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
4827 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
4828
4829 # expand $ac_aux_dir to an absolute path
4830 am_aux_dir=`cd $ac_aux_dir && pwd`
4831
4832 if test x"${MISSING+set}" != xset; then
4833   case $am_aux_dir in
4834   *\ * | *\     *)
4835     MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
4836   *)
4837     MISSING="\${SHELL} $am_aux_dir/missing" ;;
4838   esac
4839 fi
4840 # Use eval to expand $SHELL
4841 if eval "$MISSING --is-lightweight"; then
4842   am_missing_run="$MISSING "
4843 else
4844   am_missing_run=
4845   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5
4846 $as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;}
4847 fi
4848
4849 if test x"${install_sh}" != xset; then
4850   case $am_aux_dir in
4851   *\ * | *\     *)
4852     install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
4853   *)
4854     install_sh="\${SHELL} $am_aux_dir/install-sh"
4855   esac
4856 fi
4857
4858 # Installed binaries are usually stripped using 'strip' when the user
4859 # run "make install-strip".  However 'strip' might not be the right
4860 # tool to use in cross-compilation environments, therefore Automake
4861 # will honor the 'STRIP' environment variable to overrule this program.
4862 if test "$cross_compiling" != no; then
4863   if test -n "$ac_tool_prefix"; then
4864   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
4865 set dummy ${ac_tool_prefix}strip; ac_word=$2
4866 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4867 $as_echo_n "checking for $ac_word... " >&6; }
4868 if ${ac_cv_prog_STRIP+:} false; then :
4869   $as_echo_n "(cached) " >&6
4870 else
4871   if test -n "$STRIP"; then
4872   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
4873 else
4874 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4875 for as_dir in $PATH
4876 do
4877   IFS=$as_save_IFS
4878   test -z "$as_dir" && as_dir=.
4879     for ac_exec_ext in '' $ac_executable_extensions; do
4880   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4881     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
4882     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4883     break 2
4884   fi
4885 done
4886   done
4887 IFS=$as_save_IFS
4888
4889 fi
4890 fi
4891 STRIP=$ac_cv_prog_STRIP
4892 if test -n "$STRIP"; then
4893   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
4894 $as_echo "$STRIP" >&6; }
4895 else
4896   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4897 $as_echo "no" >&6; }
4898 fi
4899
4900
4901 fi
4902 if test -z "$ac_cv_prog_STRIP"; then
4903   ac_ct_STRIP=$STRIP
4904   # Extract the first word of "strip", so it can be a program name with args.
4905 set dummy strip; ac_word=$2
4906 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4907 $as_echo_n "checking for $ac_word... " >&6; }
4908 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
4909   $as_echo_n "(cached) " >&6
4910 else
4911   if test -n "$ac_ct_STRIP"; then
4912   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
4913 else
4914 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4915 for as_dir in $PATH
4916 do
4917   IFS=$as_save_IFS
4918   test -z "$as_dir" && as_dir=.
4919     for ac_exec_ext in '' $ac_executable_extensions; do
4920   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4921     ac_cv_prog_ac_ct_STRIP="strip"
4922     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4923     break 2
4924   fi
4925 done
4926   done
4927 IFS=$as_save_IFS
4928
4929 fi
4930 fi
4931 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
4932 if test -n "$ac_ct_STRIP"; then
4933   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
4934 $as_echo "$ac_ct_STRIP" >&6; }
4935 else
4936   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4937 $as_echo "no" >&6; }
4938 fi
4939
4940   if test "x$ac_ct_STRIP" = x; then
4941     STRIP=":"
4942   else
4943     case $cross_compiling:$ac_tool_warned in
4944 yes:)
4945 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4946 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4947 ac_tool_warned=yes ;;
4948 esac
4949     STRIP=$ac_ct_STRIP
4950   fi
4951 else
4952   STRIP="$ac_cv_prog_STRIP"
4953 fi
4954
4955 fi
4956 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
4957
4958 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
4959 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
4960 if test -z "$MKDIR_P"; then
4961   if ${ac_cv_path_mkdir+:} false; then :
4962   $as_echo_n "(cached) " >&6
4963 else
4964   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4965 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
4966 do
4967   IFS=$as_save_IFS
4968   test -z "$as_dir" && as_dir=.
4969     for ac_prog in mkdir gmkdir; do
4970          for ac_exec_ext in '' $ac_executable_extensions; do
4971            as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue
4972            case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
4973              'mkdir (GNU coreutils) '* | \
4974              'mkdir (coreutils) '* | \
4975              'mkdir (fileutils) '4.1*)
4976                ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
4977                break 3;;
4978            esac
4979          done
4980        done
4981   done
4982 IFS=$as_save_IFS
4983
4984 fi
4985
4986   test -d ./--version && rmdir ./--version
4987   if test "${ac_cv_path_mkdir+set}" = set; then
4988     MKDIR_P="$ac_cv_path_mkdir -p"
4989   else
4990     # As a last resort, use the slow shell script.  Don't cache a
4991     # value for MKDIR_P within a source directory, because that will
4992     # break other packages using the cache if that directory is
4993     # removed, or if the value is a relative name.
4994     MKDIR_P="$ac_install_sh -d"
4995   fi
4996 fi
4997 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
4998 $as_echo "$MKDIR_P" >&6; }
4999
5000 for ac_prog in gawk mawk nawk awk
5001 do
5002   # Extract the first word of "$ac_prog", so it can be a program name with args.
5003 set dummy $ac_prog; ac_word=$2
5004 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5005 $as_echo_n "checking for $ac_word... " >&6; }
5006 if ${ac_cv_prog_AWK+:} false; then :
5007   $as_echo_n "(cached) " >&6
5008 else
5009   if test -n "$AWK"; then
5010   ac_cv_prog_AWK="$AWK" # Let the user override the test.
5011 else
5012 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5013 for as_dir in $PATH
5014 do
5015   IFS=$as_save_IFS
5016   test -z "$as_dir" && as_dir=.
5017     for ac_exec_ext in '' $ac_executable_extensions; do
5018   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5019     ac_cv_prog_AWK="$ac_prog"
5020     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5021     break 2
5022   fi
5023 done
5024   done
5025 IFS=$as_save_IFS
5026
5027 fi
5028 fi
5029 AWK=$ac_cv_prog_AWK
5030 if test -n "$AWK"; then
5031   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
5032 $as_echo "$AWK" >&6; }
5033 else
5034   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5035 $as_echo "no" >&6; }
5036 fi
5037
5038
5039   test -n "$AWK" && break
5040 done
5041
5042 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
5043 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
5044 set x ${MAKE-make}
5045 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
5046 if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then :
5047   $as_echo_n "(cached) " >&6
5048 else
5049   cat >conftest.make <<\_ACEOF
5050 SHELL = /bin/sh
5051 all:
5052         @echo '@@@%%%=$(MAKE)=@@@%%%'
5053 _ACEOF
5054 # GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
5055 case `${MAKE-make} -f conftest.make 2>/dev/null` in
5056   *@@@%%%=?*=@@@%%%*)
5057     eval ac_cv_prog_make_${ac_make}_set=yes;;
5058   *)
5059     eval ac_cv_prog_make_${ac_make}_set=no;;
5060 esac
5061 rm -f conftest.make
5062 fi
5063 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
5064   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5065 $as_echo "yes" >&6; }
5066   SET_MAKE=
5067 else
5068   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5069 $as_echo "no" >&6; }
5070   SET_MAKE="MAKE=${MAKE-make}"
5071 fi
5072
5073 rm -rf .tst 2>/dev/null
5074 mkdir .tst 2>/dev/null
5075 if test -d .tst; then
5076   am__leading_dot=.
5077 else
5078   am__leading_dot=_
5079 fi
5080 rmdir .tst 2>/dev/null
5081
5082 # Check whether --enable-silent-rules was given.
5083 if test "${enable_silent_rules+set}" = set; then :
5084   enableval=$enable_silent_rules;
5085 fi
5086
5087 case $enable_silent_rules in # (((
5088   yes) AM_DEFAULT_VERBOSITY=0;;
5089    no) AM_DEFAULT_VERBOSITY=1;;
5090     *) AM_DEFAULT_VERBOSITY=1;;
5091 esac
5092 am_make=${MAKE-make}
5093 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
5094 $as_echo_n "checking whether $am_make supports nested variables... " >&6; }
5095 if ${am_cv_make_support_nested_variables+:} false; then :
5096   $as_echo_n "(cached) " >&6
5097 else
5098   if $as_echo 'TRUE=$(BAR$(V))
5099 BAR0=false
5100 BAR1=true
5101 V=1
5102 am__doit:
5103         @$(TRUE)
5104 .PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
5105   am_cv_make_support_nested_variables=yes
5106 else
5107   am_cv_make_support_nested_variables=no
5108 fi
5109 fi
5110 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
5111 $as_echo "$am_cv_make_support_nested_variables" >&6; }
5112 if test $am_cv_make_support_nested_variables = yes; then
5113     AM_V='$(V)'
5114   AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
5115 else
5116   AM_V=$AM_DEFAULT_VERBOSITY
5117   AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
5118 fi
5119 AM_BACKSLASH='\'
5120
5121 if test "`cd $srcdir && pwd`" != "`pwd`"; then
5122   # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
5123   # is not polluted with repeated "-I."
5124   am__isrc=' -I$(srcdir)'
5125   # test to see if srcdir already configured
5126   if test -f $srcdir/config.status; then
5127     as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
5128   fi
5129 fi
5130
5131 # test whether we have cygpath
5132 if test -z "$CYGPATH_W"; then
5133   if (cygpath --version) >/dev/null 2>/dev/null; then
5134     CYGPATH_W='cygpath -w'
5135   else
5136     CYGPATH_W=echo
5137   fi
5138 fi
5139
5140
5141 # Define the identity of the package.
5142  PACKAGE='libvirt'
5143  VERSION='1.2.5'
5144
5145
5146 cat >>confdefs.h <<_ACEOF
5147 #define PACKAGE "$PACKAGE"
5148 _ACEOF
5149
5150
5151 cat >>confdefs.h <<_ACEOF
5152 #define VERSION "$VERSION"
5153 _ACEOF
5154
5155 # Some tools Automake needs.
5156
5157 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
5158
5159
5160 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
5161
5162
5163 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
5164
5165
5166 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
5167
5168
5169 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
5170
5171 # For better backward compatibility.  To be removed once Automake 1.9.x
5172 # dies out for good.  For more background, see:
5173 # <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
5174 # <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
5175 mkdir_p='$(MKDIR_P)'
5176
5177 # We need awk for the "check" target.  The system "awk" is bad on
5178 # some platforms.
5179 # Always define AMTAR for backward compatibility.  Yes, it's still used
5180 # in the wild :-(  We should find a proper way to deprecate it ...
5181 AMTAR='$${TAR-tar}'
5182
5183
5184 # We'll loop over all known methods to create a tar archive until one works.
5185 _am_tools='gnutar plaintar pax cpio none'
5186
5187 # The POSIX 1988 'ustar' format is defined with fixed-size fields.
5188       # There is notably a 21 bits limit for the UID and the GID.  In fact,
5189       # the 'pax' utility can hang on bigger UID/GID (see automake bug#8343
5190       # and bug#13588).
5191       am_max_uid=2097151 # 2^21 - 1
5192       am_max_gid=$am_max_uid
5193       # The $UID and $GID variables are not portable, so we need to resort
5194       # to the POSIX-mandated id(1) utility.  Errors in the 'id' calls
5195       # below are definitely unexpected, so allow the users to see them
5196       # (that is, avoid stderr redirection).
5197       am_uid=`id -u || echo unknown`
5198       am_gid=`id -g || echo unknown`
5199       { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether UID '$am_uid' is supported by ustar format" >&5
5200 $as_echo_n "checking whether UID '$am_uid' is supported by ustar format... " >&6; }
5201       if test $am_uid -le $am_max_uid; then
5202          { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5203 $as_echo "yes" >&6; }
5204       else
5205          { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5206 $as_echo "no" >&6; }
5207          _am_tools=none
5208       fi
5209       { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether GID '$am_gid' is supported by ustar format" >&5
5210 $as_echo_n "checking whether GID '$am_gid' is supported by ustar format... " >&6; }
5211       if test $am_gid -le $am_max_gid; then
5212          { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5213 $as_echo "yes" >&6; }
5214       else
5215         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5216 $as_echo "no" >&6; }
5217         _am_tools=none
5218       fi
5219
5220   { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to create a ustar tar archive" >&5
5221 $as_echo_n "checking how to create a ustar tar archive... " >&6; }
5222
5223   # Go ahead even if we have the value already cached.  We do so because we
5224   # need to set the values for the 'am__tar' and 'am__untar' variables.
5225   _am_tools=${am_cv_prog_tar_ustar-$_am_tools}
5226
5227   for _am_tool in $_am_tools; do
5228     case $_am_tool in
5229     gnutar)
5230       for _am_tar in tar gnutar gtar; do
5231         { echo "$as_me:$LINENO: $_am_tar --version" >&5
5232    ($_am_tar --version) >&5 2>&5
5233    ac_status=$?
5234    echo "$as_me:$LINENO: \$? = $ac_status" >&5
5235    (exit $ac_status); } && break
5236       done
5237       am__tar="$_am_tar --format=ustar -chf - "'"$$tardir"'
5238       am__tar_="$_am_tar --format=ustar -chf - "'"$tardir"'
5239       am__untar="$_am_tar -xf -"
5240       ;;
5241     plaintar)
5242       # Must skip GNU tar: if it does not support --format= it doesn't create
5243       # ustar tarball either.
5244       (tar --version) >/dev/null 2>&1 && continue
5245       am__tar='tar chf - "$$tardir"'
5246       am__tar_='tar chf - "$tardir"'
5247       am__untar='tar xf -'
5248       ;;
5249     pax)
5250       am__tar='pax -L -x ustar -w "$$tardir"'
5251       am__tar_='pax -L -x ustar -w "$tardir"'
5252       am__untar='pax -r'
5253       ;;
5254     cpio)
5255       am__tar='find "$$tardir" -print | cpio -o -H ustar -L'
5256       am__tar_='find "$tardir" -print | cpio -o -H ustar -L'
5257       am__untar='cpio -i -H ustar -d'
5258       ;;
5259     none)
5260       am__tar=false
5261       am__tar_=false
5262       am__untar=false
5263       ;;
5264     esac
5265
5266     # If the value was cached, stop now.  We just wanted to have am__tar
5267     # and am__untar set.
5268     test -n "${am_cv_prog_tar_ustar}" && break
5269
5270     # tar/untar a dummy directory, and stop if the command works.
5271     rm -rf conftest.dir
5272     mkdir conftest.dir
5273     echo GrepMe > conftest.dir/file
5274     { echo "$as_me:$LINENO: tardir=conftest.dir && eval $am__tar_ >conftest.tar" >&5
5275    (tardir=conftest.dir && eval $am__tar_ >conftest.tar) >&5 2>&5
5276    ac_status=$?
5277    echo "$as_me:$LINENO: \$? = $ac_status" >&5
5278    (exit $ac_status); }
5279     rm -rf conftest.dir
5280     if test -s conftest.tar; then
5281       { echo "$as_me:$LINENO: $am__untar <conftest.tar" >&5
5282    ($am__untar <conftest.tar) >&5 2>&5
5283    ac_status=$?
5284    echo "$as_me:$LINENO: \$? = $ac_status" >&5
5285    (exit $ac_status); }
5286       { echo "$as_me:$LINENO: cat conftest.dir/file" >&5
5287    (cat conftest.dir/file) >&5 2>&5
5288    ac_status=$?
5289    echo "$as_me:$LINENO: \$? = $ac_status" >&5
5290    (exit $ac_status); }
5291       grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
5292     fi
5293   done
5294   rm -rf conftest.dir
5295
5296   if ${am_cv_prog_tar_ustar+:} false; then :
5297   $as_echo_n "(cached) " >&6
5298 else
5299   am_cv_prog_tar_ustar=$_am_tool
5300 fi
5301
5302   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_tar_ustar" >&5
5303 $as_echo "$am_cv_prog_tar_ustar" >&6; }
5304
5305
5306
5307
5308
5309
5310
5311 # Maintainer note - comment this line out if you plan to rerun
5312 # GNULIB_POSIXCHECK testing to see if libvirt should be using more modules.
5313 # Leave it uncommented for normal releases, for faster ./configure.
5314
5315
5316
5317
5318 # Default to using the silent-rules feature when possible.  Formatting
5319 # chosen to bypass 'grep' checks that cause older automake to warn.
5320 # Users (include rpm) can still change the default at configure time.
5321 # Check whether --enable-silent-rules was given.
5322 if test "${enable_silent_rules+set}" = set; then :
5323   enableval=$enable_silent_rules;
5324 fi
5325
5326 case $enable_silent_rules in # (((
5327   yes) AM_DEFAULT_VERBOSITY=0;;
5328    no) AM_DEFAULT_VERBOSITY=1;;
5329     *) AM_DEFAULT_VERBOSITY=0;;
5330 esac
5331 am_make=${MAKE-make}
5332 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
5333 $as_echo_n "checking whether $am_make supports nested variables... " >&6; }
5334 if ${am_cv_make_support_nested_variables+:} false; then :
5335   $as_echo_n "(cached) " >&6
5336 else
5337   if $as_echo 'TRUE=$(BAR$(V))
5338 BAR0=false
5339 BAR1=true
5340 V=1
5341 am__doit:
5342         @$(TRUE)
5343 .PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
5344   am_cv_make_support_nested_variables=yes
5345 else
5346   am_cv_make_support_nested_variables=no
5347 fi
5348 fi
5349 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
5350 $as_echo "$am_cv_make_support_nested_variables" >&6; }
5351 if test $am_cv_make_support_nested_variables = yes; then
5352     AM_V='$(V)'
5353   AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
5354 else
5355   AM_V=$AM_DEFAULT_VERBOSITY
5356   AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
5357 fi
5358 AM_BACKSLASH='\'
5359
5360
5361 # Make sure we can run config.sub.
5362 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
5363   as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
5364
5365 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
5366 $as_echo_n "checking build system type... " >&6; }
5367 if ${ac_cv_build+:} false; then :
5368   $as_echo_n "(cached) " >&6
5369 else
5370   ac_build_alias=$build_alias
5371 test "x$ac_build_alias" = x &&
5372   ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
5373 test "x$ac_build_alias" = x &&
5374   as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
5375 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
5376   as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
5377
5378 fi
5379 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
5380 $as_echo "$ac_cv_build" >&6; }
5381 case $ac_cv_build in
5382 *-*-*) ;;
5383 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
5384 esac
5385 build=$ac_cv_build
5386 ac_save_IFS=$IFS; IFS='-'
5387 set x $ac_cv_build
5388 shift
5389 build_cpu=$1
5390 build_vendor=$2
5391 shift; shift
5392 # Remember, the first character of IFS is used to create $*,
5393 # except with old shells:
5394 build_os=$*
5395 IFS=$ac_save_IFS
5396 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
5397
5398
5399 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
5400 $as_echo_n "checking host system type... " >&6; }
5401 if ${ac_cv_host+:} false; then :
5402   $as_echo_n "(cached) " >&6
5403 else
5404   if test "x$host_alias" = x; then
5405   ac_cv_host=$ac_cv_build
5406 else
5407   ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
5408     as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
5409 fi
5410
5411 fi
5412 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
5413 $as_echo "$ac_cv_host" >&6; }
5414 case $ac_cv_host in
5415 *-*-*) ;;
5416 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
5417 esac
5418 host=$ac_cv_host
5419 ac_save_IFS=$IFS; IFS='-'
5420 set x $ac_cv_host
5421 shift
5422 host_cpu=$1
5423 host_vendor=$2
5424 shift; shift
5425 # Remember, the first character of IFS is used to create $*,
5426 # except with old shells:
5427 host_os=$*
5428 IFS=$ac_save_IFS
5429 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
5430
5431
5432
5433 # First extract pieces from the version number string
5434 LIBVIRT_MAJOR_VERSION=`echo $VERSION | awk -F. '{print $1}'`
5435 LIBVIRT_MINOR_VERSION=`echo $VERSION | awk -F. '{print $2}'`
5436 LIBVIRT_MICRO_VERSION=`echo $VERSION | awk -F. '{print $3}'`
5437 LIBVIRT_VERSION=$LIBVIRT_MAJOR_VERSION.$LIBVIRT_MINOR_VERSION.$LIBVIRT_MICRO_VERSION$LIBVIRT_MICRO_VERSION_SUFFIX
5438 LIBVIRT_VERSION_NUMBER=`expr $LIBVIRT_MAJOR_VERSION \* 1000000 + $LIBVIRT_MINOR_VERSION \* 1000 + $LIBVIRT_MICRO_VERSION`
5439
5440 # In libtool terminology we need to figure out:
5441 #
5442 # CURRENT
5443 #     The most recent interface number that this library implements.
5444 #
5445 # REVISION
5446 #     The implementation number of the CURRENT interface.
5447 #
5448 # AGE
5449 #     The difference between the newest and oldest interfaces that this
5450 #     library implements.
5451 #
5452 # In other words, the library implements all the interface numbers
5453 # in the range from number `CURRENT - AGE' to `CURRENT'.
5454 #
5455 # Libtool assigns the soname version from `CURRENT - AGE', and we
5456 # don't want that to ever change in libvirt. ie it must always be
5457 # zero, to produce libvirt.so.0.
5458 #
5459 # We would, however, like the libvirt version number reflected
5460 # in the so version'd symlinks, and this is based on AGE.REVISION
5461 # eg  libvirt.so.0.AGE.REVISION
5462 #
5463 # Assuming we do ever want to break soname version, this can
5464 # toggled. But seriously, don't ever touch this.
5465 LIBVIRT_SONUM=0
5466
5467 # The following examples show what libtool will do
5468 #
5469 # Input: 0.9.14 ->   libvirt.so.0.9.14
5470 # Input: 1.0.0  ->   libvirt.so.0.1000.0
5471 # Input: 2.5.8  ->   libvirt.so.0.2005.8
5472 #
5473 AGE=`expr $LIBVIRT_MAJOR_VERSION '*' 1000 + $LIBVIRT_MINOR_VERSION`
5474 REVISION=$LIBVIRT_MICRO_VERSION
5475 CURRENT=`expr $LIBVIRT_SONUM + $AGE`
5476 LIBVIRT_VERSION_INFO=$CURRENT:$REVISION:$AGE
5477
5478
5479
5480
5481
5482
5483
5484
5485
5486
5487 # Check whether --with-packager was given.
5488 if test "${with_packager+set}" = set; then :
5489   withval=$with_packager;
5490 else
5491   with_packager=no
5492 fi
5493
5494
5495 # Check whether --with-packager-version was given.
5496 if test "${with_packager_version+set}" = set; then :
5497   withval=$with_packager_version;
5498 else
5499   with_packager_version=no
5500 fi
5501
5502 if test "x$with_packager" != "xno"
5503 then
5504
5505 cat >>confdefs.h <<_ACEOF
5506 #define PACKAGER "$with_packager"
5507 _ACEOF
5508
5509 fi
5510 if test "x$with_packager_version" != "xno"
5511 then
5512
5513 cat >>confdefs.h <<_ACEOF
5514 #define PACKAGER_VERSION "$with_packager_version"
5515 _ACEOF
5516
5517 fi
5518
5519 LIBXML_REQUIRED="2.6.0"
5520 GNUTLS_REQUIRED="1.0.25"
5521 POLKIT_REQUIRED="0.6"
5522 PARTED_REQUIRED="1.8.0"
5523 DEVMAPPER_REQUIRED=1.0.0
5524 LIBPCAP_REQUIRED="1.0.0"
5525 LIBNL_REQUIRED="1.1"
5526
5527 ac_ext=c
5528 ac_cpp='$CPP $CPPFLAGS'
5529 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5530 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5531 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5532 if test -n "$ac_tool_prefix"; then
5533   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
5534 set dummy ${ac_tool_prefix}gcc; ac_word=$2
5535 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5536 $as_echo_n "checking for $ac_word... " >&6; }
5537 if ${ac_cv_prog_CC+:} false; then :
5538   $as_echo_n "(cached) " >&6
5539 else
5540   if test -n "$CC"; then
5541   ac_cv_prog_CC="$CC" # Let the user override the test.
5542 else
5543 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5544 for as_dir in $PATH
5545 do
5546   IFS=$as_save_IFS
5547   test -z "$as_dir" && as_dir=.
5548     for ac_exec_ext in '' $ac_executable_extensions; do
5549   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5550     ac_cv_prog_CC="${ac_tool_prefix}gcc"
5551     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5552     break 2
5553   fi
5554 done
5555   done
5556 IFS=$as_save_IFS
5557
5558 fi
5559 fi
5560 CC=$ac_cv_prog_CC
5561 if test -n "$CC"; then
5562   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5563 $as_echo "$CC" >&6; }
5564 else
5565   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5566 $as_echo "no" >&6; }
5567 fi
5568
5569
5570 fi
5571 if test -z "$ac_cv_prog_CC"; then
5572   ac_ct_CC=$CC
5573   # Extract the first word of "gcc", so it can be a program name with args.
5574 set dummy gcc; ac_word=$2
5575 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5576 $as_echo_n "checking for $ac_word... " >&6; }
5577 if ${ac_cv_prog_ac_ct_CC+:} false; then :
5578   $as_echo_n "(cached) " >&6
5579 else
5580   if test -n "$ac_ct_CC"; then
5581   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
5582 else
5583 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5584 for as_dir in $PATH
5585 do
5586   IFS=$as_save_IFS
5587   test -z "$as_dir" && as_dir=.
5588     for ac_exec_ext in '' $ac_executable_extensions; do
5589   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5590     ac_cv_prog_ac_ct_CC="gcc"
5591     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5592     break 2
5593   fi
5594 done
5595   done
5596 IFS=$as_save_IFS
5597
5598 fi
5599 fi
5600 ac_ct_CC=$ac_cv_prog_ac_ct_CC
5601 if test -n "$ac_ct_CC"; then
5602   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
5603 $as_echo "$ac_ct_CC" >&6; }
5604 else
5605   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5606 $as_echo "no" >&6; }
5607 fi
5608
5609   if test "x$ac_ct_CC" = x; then
5610     CC=""
5611   else
5612     case $cross_compiling:$ac_tool_warned in
5613 yes:)
5614 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5615 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5616 ac_tool_warned=yes ;;
5617 esac
5618     CC=$ac_ct_CC
5619   fi
5620 else
5621   CC="$ac_cv_prog_CC"
5622 fi
5623
5624 if test -z "$CC"; then
5625           if test -n "$ac_tool_prefix"; then
5626     # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
5627 set dummy ${ac_tool_prefix}cc; ac_word=$2
5628 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5629 $as_echo_n "checking for $ac_word... " >&6; }
5630 if ${ac_cv_prog_CC+:} false; then :
5631   $as_echo_n "(cached) " >&6
5632 else
5633   if test -n "$CC"; then
5634   ac_cv_prog_CC="$CC" # Let the user override the test.
5635 else
5636 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5637 for as_dir in $PATH
5638 do
5639   IFS=$as_save_IFS
5640   test -z "$as_dir" && as_dir=.
5641     for ac_exec_ext in '' $ac_executable_extensions; do
5642   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5643     ac_cv_prog_CC="${ac_tool_prefix}cc"
5644     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5645     break 2
5646   fi
5647 done
5648   done
5649 IFS=$as_save_IFS
5650
5651 fi
5652 fi
5653 CC=$ac_cv_prog_CC
5654 if test -n "$CC"; then
5655   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5656 $as_echo "$CC" >&6; }
5657 else
5658   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5659 $as_echo "no" >&6; }
5660 fi
5661
5662
5663   fi
5664 fi
5665 if test -z "$CC"; then
5666   # Extract the first word of "cc", so it can be a program name with args.
5667 set dummy cc; ac_word=$2
5668 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5669 $as_echo_n "checking for $ac_word... " >&6; }
5670 if ${ac_cv_prog_CC+:} false; then :
5671   $as_echo_n "(cached) " >&6
5672 else
5673   if test -n "$CC"; then
5674   ac_cv_prog_CC="$CC" # Let the user override the test.
5675 else
5676   ac_prog_rejected=no
5677 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5678 for as_dir in $PATH
5679 do
5680   IFS=$as_save_IFS
5681   test -z "$as_dir" && as_dir=.
5682     for ac_exec_ext in '' $ac_executable_extensions; do
5683   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5684     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
5685        ac_prog_rejected=yes
5686        continue
5687      fi
5688     ac_cv_prog_CC="cc"
5689     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5690     break 2
5691   fi
5692 done
5693   done
5694 IFS=$as_save_IFS
5695
5696 if test $ac_prog_rejected = yes; then
5697   # We found a bogon in the path, so make sure we never use it.
5698   set dummy $ac_cv_prog_CC
5699   shift
5700   if test $# != 0; then
5701     # We chose a different compiler from the bogus one.
5702     # However, it has the same basename, so the bogon will be chosen
5703     # first if we set CC to just the basename; use the full file name.
5704     shift
5705     ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
5706   fi
5707 fi
5708 fi
5709 fi
5710 CC=$ac_cv_prog_CC
5711 if test -n "$CC"; then
5712   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5713 $as_echo "$CC" >&6; }
5714 else
5715   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5716 $as_echo "no" >&6; }
5717 fi
5718
5719
5720 fi
5721 if test -z "$CC"; then
5722   if test -n "$ac_tool_prefix"; then
5723   for ac_prog in cl.exe
5724   do
5725     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
5726 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
5727 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5728 $as_echo_n "checking for $ac_word... " >&6; }
5729 if ${ac_cv_prog_CC+:} false; then :
5730   $as_echo_n "(cached) " >&6
5731 else
5732   if test -n "$CC"; then
5733   ac_cv_prog_CC="$CC" # Let the user override the test.
5734 else
5735 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5736 for as_dir in $PATH
5737 do
5738   IFS=$as_save_IFS
5739   test -z "$as_dir" && as_dir=.
5740     for ac_exec_ext in '' $ac_executable_extensions; do
5741   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5742     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
5743     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5744     break 2
5745   fi
5746 done
5747   done
5748 IFS=$as_save_IFS
5749
5750 fi
5751 fi
5752 CC=$ac_cv_prog_CC
5753 if test -n "$CC"; then
5754   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5755 $as_echo "$CC" >&6; }
5756 else
5757   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5758 $as_echo "no" >&6; }
5759 fi
5760
5761
5762     test -n "$CC" && break
5763   done
5764 fi
5765 if test -z "$CC"; then
5766   ac_ct_CC=$CC
5767   for ac_prog in cl.exe
5768 do
5769   # Extract the first word of "$ac_prog", so it can be a program name with args.
5770 set dummy $ac_prog; ac_word=$2
5771 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5772 $as_echo_n "checking for $ac_word... " >&6; }
5773 if ${ac_cv_prog_ac_ct_CC+:} false; then :
5774   $as_echo_n "(cached) " >&6
5775 else
5776   if test -n "$ac_ct_CC"; then
5777   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
5778 else
5779 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5780 for as_dir in $PATH
5781 do
5782   IFS=$as_save_IFS
5783   test -z "$as_dir" && as_dir=.
5784     for ac_exec_ext in '' $ac_executable_extensions; do
5785   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
5786     ac_cv_prog_ac_ct_CC="$ac_prog"
5787     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5788     break 2
5789   fi
5790 done
5791   done
5792 IFS=$as_save_IFS
5793
5794 fi
5795 fi
5796 ac_ct_CC=$ac_cv_prog_ac_ct_CC
5797 if test -n "$ac_ct_CC"; then
5798   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
5799 $as_echo "$ac_ct_CC" >&6; }
5800 else
5801   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5802 $as_echo "no" >&6; }
5803 fi
5804
5805
5806   test -n "$ac_ct_CC" && break
5807 done
5808
5809   if test "x$ac_ct_CC" = x; then
5810     CC=""
5811   else
5812     case $cross_compiling:$ac_tool_warned in
5813 yes:)
5814 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5815 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5816 ac_tool_warned=yes ;;
5817 esac
5818     CC=$ac_ct_CC
5819   fi
5820 fi
5821
5822 fi
5823
5824
5825 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5826 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5827 as_fn_error $? "no acceptable C compiler found in \$PATH
5828 See \`config.log' for more details" "$LINENO" 5; }
5829
5830 # Provide some information about the compiler.
5831 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
5832 set X $ac_compile
5833 ac_compiler=$2
5834 for ac_option in --version -v -V -qversion; do
5835   { { ac_try="$ac_compiler $ac_option >&5"
5836 case "(($ac_try" in
5837   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5838   *) ac_try_echo=$ac_try;;
5839 esac
5840 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5841 $as_echo "$ac_try_echo"; } >&5
5842   (eval "$ac_compiler $ac_option >&5") 2>conftest.err
5843   ac_status=$?
5844   if test -s conftest.err; then
5845     sed '10a\
5846 ... rest of stderr output deleted ...
5847          10q' conftest.err >conftest.er1
5848     cat conftest.er1 >&5
5849   fi
5850   rm -f conftest.er1 conftest.err
5851   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5852   test $ac_status = 0; }
5853 done
5854
5855 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5856 /* end confdefs.h.  */
5857
5858 int
5859 main ()
5860 {
5861
5862   ;
5863   return 0;
5864 }
5865 _ACEOF
5866 ac_clean_files_save=$ac_clean_files
5867 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
5868 # Try to create an executable without -o first, disregard a.out.
5869 # It will help us diagnose broken compilers, and finding out an intuition
5870 # of exeext.
5871 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
5872 $as_echo_n "checking whether the C compiler works... " >&6; }
5873 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
5874
5875 # The possible output files:
5876 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
5877
5878 ac_rmfiles=
5879 for ac_file in $ac_files
5880 do
5881   case $ac_file in
5882     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
5883     * ) ac_rmfiles="$ac_rmfiles $ac_file";;
5884   esac
5885 done
5886 rm -f $ac_rmfiles
5887
5888 if { { ac_try="$ac_link_default"
5889 case "(($ac_try" in
5890   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5891   *) ac_try_echo=$ac_try;;
5892 esac
5893 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5894 $as_echo "$ac_try_echo"; } >&5
5895   (eval "$ac_link_default") 2>&5
5896   ac_status=$?
5897   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5898   test $ac_status = 0; }; then :
5899   # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
5900 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
5901 # in a Makefile.  We should not override ac_cv_exeext if it was cached,
5902 # so that the user can short-circuit this test for compilers unknown to
5903 # Autoconf.
5904 for ac_file in $ac_files ''
5905 do
5906   test -f "$ac_file" || continue
5907   case $ac_file in
5908     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
5909         ;;
5910     [ab].out )
5911         # We found the default executable, but exeext='' is most
5912         # certainly right.
5913         break;;
5914     *.* )
5915         if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
5916         then :; else
5917            ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5918         fi
5919         # We set ac_cv_exeext here because the later test for it is not
5920         # safe: cross compilers may not add the suffix if given an `-o'
5921         # argument, so we may need to know it at that point already.
5922         # Even if this section looks crufty: it has the advantage of
5923         # actually working.
5924         break;;
5925     * )
5926         break;;
5927   esac
5928 done
5929 test "$ac_cv_exeext" = no && ac_cv_exeext=
5930
5931 else
5932   ac_file=''
5933 fi
5934 if test -z "$ac_file"; then :
5935   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5936 $as_echo "no" >&6; }
5937 $as_echo "$as_me: failed program was:" >&5
5938 sed 's/^/| /' conftest.$ac_ext >&5
5939
5940 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5941 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5942 as_fn_error 77 "C compiler cannot create executables
5943 See \`config.log' for more details" "$LINENO" 5; }
5944 else
5945   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5946 $as_echo "yes" >&6; }
5947 fi
5948 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
5949 $as_echo_n "checking for C compiler default output file name... " >&6; }
5950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
5951 $as_echo "$ac_file" >&6; }
5952 ac_exeext=$ac_cv_exeext
5953
5954 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
5955 ac_clean_files=$ac_clean_files_save
5956 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
5957 $as_echo_n "checking for suffix of executables... " >&6; }
5958 if { { ac_try="$ac_link"
5959 case "(($ac_try" in
5960   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5961   *) ac_try_echo=$ac_try;;
5962 esac
5963 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5964 $as_echo "$ac_try_echo"; } >&5
5965   (eval "$ac_link") 2>&5
5966   ac_status=$?
5967   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5968   test $ac_status = 0; }; then :
5969   # If both `conftest.exe' and `conftest' are `present' (well, observable)
5970 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
5971 # work properly (i.e., refer to `conftest.exe'), while it won't with
5972 # `rm'.
5973 for ac_file in conftest.exe conftest conftest.*; do
5974   test -f "$ac_file" || continue
5975   case $ac_file in
5976     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
5977     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5978           break;;
5979     * ) break;;
5980   esac
5981 done
5982 else
5983   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5984 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5985 as_fn_error $? "cannot compute suffix of executables: cannot compile and link
5986 See \`config.log' for more details" "$LINENO" 5; }
5987 fi
5988 rm -f conftest conftest$ac_cv_exeext
5989 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
5990 $as_echo "$ac_cv_exeext" >&6; }
5991
5992 rm -f conftest.$ac_ext
5993 EXEEXT=$ac_cv_exeext
5994 ac_exeext=$EXEEXT
5995 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5996 /* end confdefs.h.  */
5997 #include <stdio.h>
5998 int
5999 main ()
6000 {
6001 FILE *f = fopen ("conftest.out", "w");
6002  return ferror (f) || fclose (f) != 0;
6003
6004   ;
6005   return 0;
6006 }
6007 _ACEOF
6008 ac_clean_files="$ac_clean_files conftest.out"
6009 # Check that the compiler produces executables we can run.  If not, either
6010 # the compiler is broken, or we cross compile.
6011 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
6012 $as_echo_n "checking whether we are cross compiling... " >&6; }
6013 if test "$cross_compiling" != yes; then
6014   { { ac_try="$ac_link"
6015 case "(($ac_try" in
6016   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6017   *) ac_try_echo=$ac_try;;
6018 esac
6019 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
6020 $as_echo "$ac_try_echo"; } >&5
6021   (eval "$ac_link") 2>&5
6022   ac_status=$?
6023   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
6024   test $ac_status = 0; }
6025   if { ac_try='./conftest$ac_cv_exeext'
6026   { { case "(($ac_try" in
6027   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6028   *) ac_try_echo=$ac_try;;
6029 esac
6030 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
6031 $as_echo "$ac_try_echo"; } >&5
6032   (eval "$ac_try") 2>&5
6033   ac_status=$?
6034   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
6035   test $ac_status = 0; }; }; then
6036     cross_compiling=no
6037   else
6038     if test "$cross_compiling" = maybe; then
6039         cross_compiling=yes
6040     else
6041         { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
6042 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
6043 as_fn_error $? "cannot run C compiled programs.
6044 If you meant to cross compile, use \`--host'.
6045 See \`config.log' for more details" "$LINENO" 5; }
6046     fi
6047   fi
6048 fi
6049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
6050 $as_echo "$cross_compiling" >&6; }
6051
6052 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
6053 ac_clean_files=$ac_clean_files_save
6054 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
6055 $as_echo_n "checking for suffix of object files... " >&6; }
6056 if ${ac_cv_objext+:} false; then :
6057   $as_echo_n "(cached) " >&6
6058 else
6059   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6060 /* end confdefs.h.  */
6061
6062 int
6063 main ()
6064 {
6065
6066   ;
6067   return 0;
6068 }
6069 _ACEOF
6070 rm -f conftest.o conftest.obj
6071 if { { ac_try="$ac_compile"
6072 case "(($ac_try" in
6073   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6074   *) ac_try_echo=$ac_try;;
6075 esac
6076 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
6077 $as_echo "$ac_try_echo"; } >&5
6078   (eval "$ac_compile") 2>&5
6079   ac_status=$?
6080   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
6081   test $ac_status = 0; }; then :
6082   for ac_file in conftest.o conftest.obj conftest.*; do
6083   test -f "$ac_file" || continue;
6084   case $ac_file in
6085     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
6086     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
6087        break;;
6088   esac
6089 done
6090 else
6091   $as_echo "$as_me: failed program was:" >&5
6092 sed 's/^/| /' conftest.$ac_ext >&5
6093
6094 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
6095 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
6096 as_fn_error $? "cannot compute suffix of object files: cannot compile
6097 See \`config.log' for more details" "$LINENO" 5; }
6098 fi
6099 rm -f conftest.$ac_cv_objext conftest.$ac_ext
6100 fi
6101 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
6102 $as_echo "$ac_cv_objext" >&6; }
6103 OBJEXT=$ac_cv_objext
6104 ac_objext=$OBJEXT
6105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
6106 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
6107 if ${ac_cv_c_compiler_gnu+:} false; then :
6108   $as_echo_n "(cached) " >&6
6109 else
6110   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6111 /* end confdefs.h.  */
6112
6113 int
6114 main ()
6115 {
6116 #ifndef __GNUC__
6117        choke me
6118 #endif
6119
6120   ;
6121   return 0;
6122 }
6123 _ACEOF
6124 if ac_fn_c_try_compile "$LINENO"; then :
6125   ac_compiler_gnu=yes
6126 else
6127   ac_compiler_gnu=no
6128 fi
6129 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6130 ac_cv_c_compiler_gnu=$ac_compiler_gnu
6131
6132 fi
6133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
6134 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
6135 if test $ac_compiler_gnu = yes; then
6136   GCC=yes
6137 else
6138   GCC=
6139 fi
6140 ac_test_CFLAGS=${CFLAGS+set}
6141 ac_save_CFLAGS=$CFLAGS
6142 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
6143 $as_echo_n "checking whether $CC accepts -g... " >&6; }
6144 if ${ac_cv_prog_cc_g+:} false; then :
6145   $as_echo_n "(cached) " >&6
6146 else
6147   ac_save_c_werror_flag=$ac_c_werror_flag
6148    ac_c_werror_flag=yes
6149    ac_cv_prog_cc_g=no
6150    CFLAGS="-g"
6151    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6152 /* end confdefs.h.  */
6153
6154 int
6155 main ()
6156 {
6157
6158   ;
6159   return 0;
6160 }
6161 _ACEOF
6162 if ac_fn_c_try_compile "$LINENO"; then :
6163   ac_cv_prog_cc_g=yes
6164 else
6165   CFLAGS=""
6166       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6167 /* end confdefs.h.  */
6168
6169 int
6170 main ()
6171 {
6172
6173   ;
6174   return 0;
6175 }
6176 _ACEOF
6177 if ac_fn_c_try_compile "$LINENO"; then :
6178
6179 else
6180   ac_c_werror_flag=$ac_save_c_werror_flag
6181          CFLAGS="-g"
6182          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6183 /* end confdefs.h.  */
6184
6185 int
6186 main ()
6187 {
6188
6189   ;
6190   return 0;
6191 }
6192 _ACEOF
6193 if ac_fn_c_try_compile "$LINENO"; then :
6194   ac_cv_prog_cc_g=yes
6195 fi
6196 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6197 fi
6198 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6199 fi
6200 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6201    ac_c_werror_flag=$ac_save_c_werror_flag
6202 fi
6203 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
6204 $as_echo "$ac_cv_prog_cc_g" >&6; }
6205 if test "$ac_test_CFLAGS" = set; then
6206   CFLAGS=$ac_save_CFLAGS
6207 elif test $ac_cv_prog_cc_g = yes; then
6208   if test "$GCC" = yes; then
6209     CFLAGS="-g -O2"
6210   else
6211     CFLAGS="-g"
6212   fi
6213 else
6214   if test "$GCC" = yes; then
6215     CFLAGS="-O2"
6216   else
6217     CFLAGS=
6218   fi
6219 fi
6220 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
6221 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
6222 if ${ac_cv_prog_cc_c89+:} false; then :
6223   $as_echo_n "(cached) " >&6
6224 else
6225   ac_cv_prog_cc_c89=no
6226 ac_save_CC=$CC
6227 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6228 /* end confdefs.h.  */
6229 #include <stdarg.h>
6230 #include <stdio.h>
6231 struct stat;
6232 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
6233 struct buf { int x; };
6234 FILE * (*rcsopen) (struct buf *, struct stat *, int);
6235 static char *e (p, i)
6236      char **p;
6237      int i;
6238 {
6239   return p[i];
6240 }
6241 static char *f (char * (*g) (char **, int), char **p, ...)
6242 {
6243   char *s;
6244   va_list v;
6245   va_start (v,p);
6246   s = g (p, va_arg (v,int));
6247   va_end (v);
6248   return s;
6249 }
6250
6251 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
6252    function prototypes and stuff, but not '\xHH' hex character constants.
6253    These don't provoke an error unfortunately, instead are silently treated
6254    as 'x'.  The following induces an error, until -std is added to get
6255    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
6256    array size at least.  It's necessary to write '\x00'==0 to get something
6257    that's true only with -std.  */
6258 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
6259
6260 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
6261    inside strings and character constants.  */
6262 #define FOO(x) 'x'
6263 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
6264
6265 int test (int i, double x);
6266 struct s1 {int (*f) (int a);};
6267 struct s2 {int (*f) (double a);};
6268 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
6269 int argc;
6270 char **argv;
6271 int
6272 main ()
6273 {
6274 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
6275   ;
6276   return 0;
6277 }
6278 _ACEOF
6279 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
6280         -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
6281 do
6282   CC="$ac_save_CC $ac_arg"
6283   if ac_fn_c_try_compile "$LINENO"; then :
6284   ac_cv_prog_cc_c89=$ac_arg
6285 fi
6286 rm -f core conftest.err conftest.$ac_objext
6287   test "x$ac_cv_prog_cc_c89" != "xno" && break
6288 done
6289 rm -f conftest.$ac_ext
6290 CC=$ac_save_CC
6291
6292 fi
6293 # AC_CACHE_VAL
6294 case "x$ac_cv_prog_cc_c89" in
6295   x)
6296     { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6297 $as_echo "none needed" >&6; } ;;
6298   xno)
6299     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6300 $as_echo "unsupported" >&6; } ;;
6301   *)
6302     CC="$CC $ac_cv_prog_cc_c89"
6303     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
6304 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
6305 esac
6306 if test "x$ac_cv_prog_cc_c89" != xno; then :
6307
6308 fi
6309
6310 ac_ext=c
6311 ac_cpp='$CPP $CPPFLAGS'
6312 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6313 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6314 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6315 DEPDIR="${am__leading_dot}deps"
6316
6317 ac_config_commands="$ac_config_commands depfiles"
6318
6319
6320 am_make=${MAKE-make}
6321 cat > confinc << 'END'
6322 am__doit:
6323         @echo this is the am__doit target
6324 .PHONY: am__doit
6325 END
6326 # If we don't find an include directive, just comment out the code.
6327 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
6328 $as_echo_n "checking for style of include used by $am_make... " >&6; }
6329 am__include="#"
6330 am__quote=
6331 _am_result=none
6332 # First try GNU make style include.
6333 echo "include confinc" > confmf
6334 # Ignore all kinds of additional output from 'make'.
6335 case `$am_make -s -f confmf 2> /dev/null` in #(
6336 *the\ am__doit\ target*)
6337   am__include=include
6338   am__quote=
6339   _am_result=GNU
6340   ;;
6341 esac
6342 # Now try BSD make style include.
6343 if test "$am__include" = "#"; then
6344    echo '.include "confinc"' > confmf
6345    case `$am_make -s -f confmf 2> /dev/null` in #(
6346    *the\ am__doit\ target*)
6347      am__include=.include
6348      am__quote="\""
6349      _am_result=BSD
6350      ;;
6351    esac
6352 fi
6353
6354
6355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
6356 $as_echo "$_am_result" >&6; }
6357 rm -f confinc confmf
6358
6359 # Check whether --enable-dependency-tracking was given.
6360 if test "${enable_dependency_tracking+set}" = set; then :
6361   enableval=$enable_dependency_tracking;
6362 fi
6363
6364 if test "x$enable_dependency_tracking" != xno; then
6365   am_depcomp="$ac_aux_dir/depcomp"
6366   AMDEPBACKSLASH='\'
6367   am__nodep='_no'
6368 fi
6369  if test "x$enable_dependency_tracking" != xno; then
6370   AMDEP_TRUE=
6371   AMDEP_FALSE='#'
6372 else
6373   AMDEP_TRUE='#'
6374   AMDEP_FALSE=
6375 fi
6376
6377
6378
6379 depcc="$CC"   am_compiler_list=
6380
6381 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
6382 $as_echo_n "checking dependency style of $depcc... " >&6; }
6383 if ${am_cv_CC_dependencies_compiler_type+:} false; then :
6384   $as_echo_n "(cached) " >&6
6385 else
6386   if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
6387   # We make a subdir and do the tests there.  Otherwise we can end up
6388   # making bogus files that we don't know about and never remove.  For
6389   # instance it was reported that on HP-UX the gcc test will end up
6390   # making a dummy file named 'D' -- because '-MD' means "put the output
6391   # in D".
6392   rm -rf conftest.dir
6393   mkdir conftest.dir
6394   # Copy depcomp to subdir because otherwise we won't find it if we're
6395   # using a relative directory.
6396   cp "$am_depcomp" conftest.dir
6397   cd conftest.dir
6398   # We will build objects and dependencies in a subdirectory because
6399   # it helps to detect inapplicable dependency modes.  For instance
6400   # both Tru64's cc and ICC support -MD to output dependencies as a
6401   # side effect of compilation, but ICC will put the dependencies in
6402   # the current directory while Tru64 will put them in the object
6403   # directory.
6404   mkdir sub
6405
6406   am_cv_CC_dependencies_compiler_type=none
6407   if test "$am_compiler_list" = ""; then
6408      am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
6409   fi
6410   am__universal=false
6411   case " $depcc " in #(
6412      *\ -arch\ *\ -arch\ *) am__universal=true ;;
6413      esac
6414
6415   for depmode in $am_compiler_list; do
6416     # Setup a source with many dependencies, because some compilers
6417     # like to wrap large dependency lists on column 80 (with \), and
6418     # we should not choose a depcomp mode which is confused by this.
6419     #
6420     # We need to recreate these files for each test, as the compiler may
6421     # overwrite some of them when testing with obscure command lines.
6422     # This happens at least with the AIX C compiler.
6423     : > sub/conftest.c
6424     for i in 1 2 3 4 5 6; do
6425       echo '#include "conftst'$i'.h"' >> sub/conftest.c
6426       # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
6427       # Solaris 10 /bin/sh.
6428       echo '/* dummy */' > sub/conftst$i.h
6429     done
6430     echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
6431
6432     # We check with '-c' and '-o' for the sake of the "dashmstdout"
6433     # mode.  It turns out that the SunPro C++ compiler does not properly
6434     # handle '-M -o', and we need to detect this.  Also, some Intel
6435     # versions had trouble with output in subdirs.
6436     am__obj=sub/conftest.${OBJEXT-o}
6437     am__minus_obj="-o $am__obj"
6438     case $depmode in
6439     gcc)
6440       # This depmode causes a compiler race in universal mode.
6441       test "$am__universal" = false || continue
6442       ;;
6443     nosideeffect)
6444       # After this tag, mechanisms are not by side-effect, so they'll
6445       # only be used when explicitly requested.
6446       if test "x$enable_dependency_tracking" = xyes; then
6447         continue
6448       else
6449         break
6450       fi
6451       ;;
6452     msvc7 | msvc7msys | msvisualcpp | msvcmsys)
6453       # This compiler won't grok '-c -o', but also, the minuso test has
6454       # not run yet.  These depmodes are late enough in the game, and
6455       # so weak that their functioning should not be impacted.
6456       am__obj=conftest.${OBJEXT-o}
6457       am__minus_obj=
6458       ;;
6459     none) break ;;
6460     esac
6461     if depmode=$depmode \
6462        source=sub/conftest.c object=$am__obj \
6463        depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
6464        $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
6465          >/dev/null 2>conftest.err &&
6466        grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
6467        grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
6468        grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
6469        ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
6470       # icc doesn't choke on unknown options, it will just issue warnings
6471       # or remarks (even with -Werror).  So we grep stderr for any message
6472       # that says an option was ignored or not supported.
6473       # When given -MP, icc 7.0 and 7.1 complain thusly:
6474       #   icc: Command line warning: ignoring option '-M'; no argument required
6475       # The diagnosis changed in icc 8.0:
6476       #   icc: Command line remark: option '-MP' not supported
6477       if (grep 'ignoring option' conftest.err ||
6478           grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
6479         am_cv_CC_dependencies_compiler_type=$depmode
6480         break
6481       fi
6482     fi
6483   done
6484
6485   cd ..
6486   rm -rf conftest.dir
6487 else
6488   am_cv_CC_dependencies_compiler_type=none
6489 fi
6490
6491 fi
6492 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
6493 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
6494 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
6495
6496  if
6497   test "x$enable_dependency_tracking" != xno \
6498   && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
6499   am__fastdepCC_TRUE=
6500   am__fastdepCC_FALSE='#'
6501 else
6502   am__fastdepCC_TRUE='#'
6503   am__fastdepCC_FALSE=
6504 fi
6505
6506
6507
6508 ac_ext=c
6509 ac_cpp='$CPP $CPPFLAGS'
6510 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6511 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6512 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6513 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
6514 $as_echo_n "checking how to run the C preprocessor... " >&6; }
6515 # On Suns, sometimes $CPP names a directory.
6516 if test -n "$CPP" && test -d "$CPP"; then
6517   CPP=
6518 fi
6519 if test -z "$CPP"; then
6520   if ${ac_cv_prog_CPP+:} false; then :
6521   $as_echo_n "(cached) " >&6
6522 else
6523       # Double quotes because CPP needs to be expanded
6524     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
6525     do
6526       ac_preproc_ok=false
6527 for ac_c_preproc_warn_flag in '' yes
6528 do
6529   # Use a header file that comes with gcc, so configuring glibc
6530   # with a fresh cross-compiler works.
6531   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6532   # <limits.h> exists even on freestanding compilers.
6533   # On the NeXT, cc -E runs the code through the compiler's parser,
6534   # not just through cpp. "Syntax error" is here to catch this case.
6535   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6536 /* end confdefs.h.  */
6537 #ifdef __STDC__
6538 # include <limits.h>
6539 #else
6540 # include <assert.h>
6541 #endif
6542                      Syntax error
6543 _ACEOF
6544 if ac_fn_c_try_cpp "$LINENO"; then :
6545
6546 else
6547   # Broken: fails on valid input.
6548 continue
6549 fi
6550 rm -f conftest.err conftest.i conftest.$ac_ext
6551
6552   # OK, works on sane cases.  Now check whether nonexistent headers
6553   # can be detected and how.
6554   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6555 /* end confdefs.h.  */
6556 #include <ac_nonexistent.h>
6557 _ACEOF
6558 if ac_fn_c_try_cpp "$LINENO"; then :
6559   # Broken: success on invalid input.
6560 continue
6561 else
6562   # Passes both tests.
6563 ac_preproc_ok=:
6564 break
6565 fi
6566 rm -f conftest.err conftest.i conftest.$ac_ext
6567
6568 done
6569 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6570 rm -f conftest.i conftest.err conftest.$ac_ext
6571 if $ac_preproc_ok; then :
6572   break
6573 fi
6574
6575     done
6576     ac_cv_prog_CPP=$CPP
6577
6578 fi
6579   CPP=$ac_cv_prog_CPP
6580 else
6581   ac_cv_prog_CPP=$CPP
6582 fi
6583 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
6584 $as_echo "$CPP" >&6; }
6585 ac_preproc_ok=false
6586 for ac_c_preproc_warn_flag in '' yes
6587 do
6588   # Use a header file that comes with gcc, so configuring glibc
6589   # with a fresh cross-compiler works.
6590   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6591   # <limits.h> exists even on freestanding compilers.
6592   # On the NeXT, cc -E runs the code through the compiler's parser,
6593   # not just through cpp. "Syntax error" is here to catch this case.
6594   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6595 /* end confdefs.h.  */
6596 #ifdef __STDC__
6597 # include <limits.h>
6598 #else
6599 # include <assert.h>
6600 #endif
6601                      Syntax error
6602 _ACEOF
6603 if ac_fn_c_try_cpp "$LINENO"; then :
6604
6605 else
6606   # Broken: fails on valid input.
6607 continue
6608 fi
6609 rm -f conftest.err conftest.i conftest.$ac_ext
6610
6611   # OK, works on sane cases.  Now check whether nonexistent headers
6612   # can be detected and how.
6613   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6614 /* end confdefs.h.  */
6615 #include <ac_nonexistent.h>
6616 _ACEOF
6617 if ac_fn_c_try_cpp "$LINENO"; then :
6618   # Broken: success on invalid input.
6619 continue
6620 else
6621   # Passes both tests.
6622 ac_preproc_ok=:
6623 break
6624 fi
6625 rm -f conftest.err conftest.i conftest.$ac_ext
6626
6627 done
6628 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6629 rm -f conftest.i conftest.err conftest.$ac_ext
6630 if $ac_preproc_ok; then :
6631
6632 else
6633   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
6634 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
6635 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
6636 See \`config.log' for more details" "$LINENO" 5; }
6637 fi
6638
6639 ac_ext=c
6640 ac_cpp='$CPP $CPPFLAGS'
6641 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6642 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6643 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6644
6645
6646 if test -d $srcdir/.git && git --version >/dev/null 2>&1 ; then
6647   AB_VERSION=`cd $srcdir && git describe --match 'v[0-9]*' 2>/dev/null`
6648 fi
6649
6650
6651
6652 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
6653 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
6654 if ${ac_cv_path_GREP+:} false; then :
6655   $as_echo_n "(cached) " >&6
6656 else
6657   if test -z "$GREP"; then
6658   ac_path_GREP_found=false
6659   # Loop through the user's path and test for each of PROGNAME-LIST
6660   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6661 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
6662 do
6663   IFS=$as_save_IFS
6664   test -z "$as_dir" && as_dir=.
6665     for ac_prog in grep ggrep; do
6666     for ac_exec_ext in '' $ac_executable_extensions; do
6667       ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
6668       as_fn_executable_p "$ac_path_GREP" || continue
6669 # Check for GNU ac_path_GREP and select it if it is found.
6670   # Check for GNU $ac_path_GREP
6671 case `"$ac_path_GREP" --version 2>&1` in
6672 *GNU*)
6673   ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
6674 *)
6675   ac_count=0
6676   $as_echo_n 0123456789 >"conftest.in"
6677   while :
6678   do
6679     cat "conftest.in" "conftest.in" >"conftest.tmp"
6680     mv "conftest.tmp" "conftest.in"
6681     cp "conftest.in" "conftest.nl"
6682     $as_echo 'GREP' >> "conftest.nl"
6683     "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
6684     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
6685     as_fn_arith $ac_count + 1 && ac_count=$as_val
6686     if test $ac_count -gt ${ac_path_GREP_max-0}; then
6687       # Best one so far, save it but keep looking for a better one
6688       ac_cv_path_GREP="$ac_path_GREP"
6689       ac_path_GREP_max=$ac_count
6690     fi
6691     # 10*(2^10) chars as input seems more than enough
6692     test $ac_count -gt 10 && break
6693   done
6694   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
6695 esac
6696
6697       $ac_path_GREP_found && break 3
6698     done
6699   done
6700   done
6701 IFS=$as_save_IFS
6702   if test -z "$ac_cv_path_GREP"; then
6703     as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
6704   fi
6705 else
6706   ac_cv_path_GREP=$GREP
6707 fi
6708
6709 fi
6710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
6711 $as_echo "$ac_cv_path_GREP" >&6; }
6712  GREP="$ac_cv_path_GREP"
6713
6714
6715 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
6716 $as_echo_n "checking for egrep... " >&6; }
6717 if ${ac_cv_path_EGREP+:} false; then :
6718   $as_echo_n "(cached) " >&6
6719 else
6720   if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
6721    then ac_cv_path_EGREP="$GREP -E"
6722    else
6723      if test -z "$EGREP"; then
6724   ac_path_EGREP_found=false
6725   # Loop through the user's path and test for each of PROGNAME-LIST
6726   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6727 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
6728 do
6729   IFS=$as_save_IFS
6730   test -z "$as_dir" && as_dir=.
6731     for ac_prog in egrep; do
6732     for ac_exec_ext in '' $ac_executable_extensions; do
6733       ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
6734       as_fn_executable_p "$ac_path_EGREP" || continue
6735 # Check for GNU ac_path_EGREP and select it if it is found.
6736   # Check for GNU $ac_path_EGREP
6737 case `"$ac_path_EGREP" --version 2>&1` in
6738 *GNU*)
6739   ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
6740 *)
6741   ac_count=0
6742   $as_echo_n 0123456789 >"conftest.in"
6743   while :
6744   do
6745     cat "conftest.in" "conftest.in" >"conftest.tmp"
6746     mv "conftest.tmp" "conftest.in"
6747     cp "conftest.in" "conftest.nl"
6748     $as_echo 'EGREP' >> "conftest.nl"
6749     "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
6750     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
6751     as_fn_arith $ac_count + 1 && ac_count=$as_val
6752     if test $ac_count -gt ${ac_path_EGREP_max-0}; then
6753       # Best one so far, save it but keep looking for a better one
6754       ac_cv_path_EGREP="$ac_path_EGREP"
6755       ac_path_EGREP_max=$ac_count
6756     fi
6757     # 10*(2^10) chars as input seems more than enough
6758     test $ac_count -gt 10 && break
6759   done
6760   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
6761 esac
6762
6763       $ac_path_EGREP_found && break 3
6764     done
6765   done
6766   done
6767 IFS=$as_save_IFS
6768   if test -z "$ac_cv_path_EGREP"; then
6769     as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
6770   fi
6771 else
6772   ac_cv_path_EGREP=$EGREP
6773 fi
6774
6775    fi
6776 fi
6777 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
6778 $as_echo "$ac_cv_path_EGREP" >&6; }
6779  EGREP="$ac_cv_path_EGREP"
6780
6781
6782
6783
6784   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Minix Amsterdam compiler" >&5
6785 $as_echo_n "checking for Minix Amsterdam compiler... " >&6; }
6786 if ${gl_cv_c_amsterdam_compiler+:} false; then :
6787   $as_echo_n "(cached) " >&6
6788 else
6789
6790       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6791 /* end confdefs.h.  */
6792
6793 #ifdef __ACK__
6794 Amsterdam
6795 #endif
6796
6797 _ACEOF
6798 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6799   $EGREP "Amsterdam" >/dev/null 2>&1; then :
6800   gl_cv_c_amsterdam_compiler=yes
6801 else
6802   gl_cv_c_amsterdam_compiler=no
6803 fi
6804 rm -f conftest*
6805
6806
6807 fi
6808 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_c_amsterdam_compiler" >&5
6809 $as_echo "$gl_cv_c_amsterdam_compiler" >&6; }
6810   if test -z "$AR"; then
6811     if test $gl_cv_c_amsterdam_compiler = yes; then
6812       AR='cc -c.a'
6813       if test -z "$ARFLAGS"; then
6814         ARFLAGS='-o'
6815       fi
6816     else
6817                   if test -n "$ac_tool_prefix"; then
6818   # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6819 set dummy ${ac_tool_prefix}ar; ac_word=$2
6820 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6821 $as_echo_n "checking for $ac_word... " >&6; }
6822 if ${ac_cv_prog_AR+:} false; then :
6823   $as_echo_n "(cached) " >&6
6824 else
6825   if test -n "$AR"; then
6826   ac_cv_prog_AR="$AR" # Let the user override the test.
6827 else
6828 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6829 for as_dir in $PATH
6830 do
6831   IFS=$as_save_IFS
6832   test -z "$as_dir" && as_dir=.
6833     for ac_exec_ext in '' $ac_executable_extensions; do
6834   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6835     ac_cv_prog_AR="${ac_tool_prefix}ar"
6836     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6837     break 2
6838   fi
6839 done
6840   done
6841 IFS=$as_save_IFS
6842
6843 fi
6844 fi
6845 AR=$ac_cv_prog_AR
6846 if test -n "$AR"; then
6847   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
6848 $as_echo "$AR" >&6; }
6849 else
6850   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6851 $as_echo "no" >&6; }
6852 fi
6853
6854
6855 fi
6856 if test -z "$ac_cv_prog_AR"; then
6857   ac_ct_AR=$AR
6858   # Extract the first word of "ar", so it can be a program name with args.
6859 set dummy ar; ac_word=$2
6860 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6861 $as_echo_n "checking for $ac_word... " >&6; }
6862 if ${ac_cv_prog_ac_ct_AR+:} false; then :
6863   $as_echo_n "(cached) " >&6
6864 else
6865   if test -n "$ac_ct_AR"; then
6866   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6867 else
6868 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6869 for as_dir in $PATH
6870 do
6871   IFS=$as_save_IFS
6872   test -z "$as_dir" && as_dir=.
6873     for ac_exec_ext in '' $ac_executable_extensions; do
6874   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6875     ac_cv_prog_ac_ct_AR="ar"
6876     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6877     break 2
6878   fi
6879 done
6880   done
6881 IFS=$as_save_IFS
6882
6883 fi
6884 fi
6885 ac_ct_AR=$ac_cv_prog_ac_ct_AR
6886 if test -n "$ac_ct_AR"; then
6887   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
6888 $as_echo "$ac_ct_AR" >&6; }
6889 else
6890   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6891 $as_echo "no" >&6; }
6892 fi
6893
6894   if test "x$ac_ct_AR" = x; then
6895     AR="ar"
6896   else
6897     case $cross_compiling:$ac_tool_warned in
6898 yes:)
6899 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6900 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6901 ac_tool_warned=yes ;;
6902 esac
6903     AR=$ac_ct_AR
6904   fi
6905 else
6906   AR="$ac_cv_prog_AR"
6907 fi
6908
6909       if test -z "$ARFLAGS"; then
6910         ARFLAGS='cru'
6911       fi
6912     fi
6913   else
6914     if test -z "$ARFLAGS"; then
6915       ARFLAGS='cru'
6916     fi
6917   fi
6918
6919
6920   if test -z "$RANLIB"; then
6921     if test $gl_cv_c_amsterdam_compiler = yes; then
6922       RANLIB=':'
6923     else
6924             if test -n "$ac_tool_prefix"; then
6925   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6926 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6927 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6928 $as_echo_n "checking for $ac_word... " >&6; }
6929 if ${ac_cv_prog_RANLIB+:} false; then :
6930   $as_echo_n "(cached) " >&6
6931 else
6932   if test -n "$RANLIB"; then
6933   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6934 else
6935 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6936 for as_dir in $PATH
6937 do
6938   IFS=$as_save_IFS
6939   test -z "$as_dir" && as_dir=.
6940     for ac_exec_ext in '' $ac_executable_extensions; do
6941   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6942     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6943     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6944     break 2
6945   fi
6946 done
6947   done
6948 IFS=$as_save_IFS
6949
6950 fi
6951 fi
6952 RANLIB=$ac_cv_prog_RANLIB
6953 if test -n "$RANLIB"; then
6954   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
6955 $as_echo "$RANLIB" >&6; }
6956 else
6957   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6958 $as_echo "no" >&6; }
6959 fi
6960
6961
6962 fi
6963 if test -z "$ac_cv_prog_RANLIB"; then
6964   ac_ct_RANLIB=$RANLIB
6965   # Extract the first word of "ranlib", so it can be a program name with args.
6966 set dummy ranlib; ac_word=$2
6967 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6968 $as_echo_n "checking for $ac_word... " >&6; }
6969 if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
6970   $as_echo_n "(cached) " >&6
6971 else
6972   if test -n "$ac_ct_RANLIB"; then
6973   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6974 else
6975 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6976 for as_dir in $PATH
6977 do
6978   IFS=$as_save_IFS
6979   test -z "$as_dir" && as_dir=.
6980     for ac_exec_ext in '' $ac_executable_extensions; do
6981   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
6982     ac_cv_prog_ac_ct_RANLIB="ranlib"
6983     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6984     break 2
6985   fi
6986 done
6987   done
6988 IFS=$as_save_IFS
6989
6990 fi
6991 fi
6992 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6993 if test -n "$ac_ct_RANLIB"; then
6994   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
6995 $as_echo "$ac_ct_RANLIB" >&6; }
6996 else
6997   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6998 $as_echo "no" >&6; }
6999 fi
7000
7001   if test "x$ac_ct_RANLIB" = x; then
7002     RANLIB=":"
7003   else
7004     case $cross_compiling:$ac_tool_warned in
7005 yes:)
7006 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7007 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7008 ac_tool_warned=yes ;;
7009 esac
7010     RANLIB=$ac_ct_RANLIB
7011   fi
7012 else
7013   RANLIB="$ac_cv_prog_RANLIB"
7014 fi
7015
7016     fi
7017   fi
7018
7019
7020 if test "x$CC" != xcc; then
7021   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC and cc understand -c and -o together" >&5
7022 $as_echo_n "checking whether $CC and cc understand -c and -o together... " >&6; }
7023 else
7024   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cc understands -c and -o together" >&5
7025 $as_echo_n "checking whether cc understands -c and -o together... " >&6; }
7026 fi
7027 set dummy $CC; ac_cc=`$as_echo "$2" |
7028                       sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
7029 if eval \${ac_cv_prog_cc_${ac_cc}_c_o+:} false; then :
7030   $as_echo_n "(cached) " >&6
7031 else
7032   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7033 /* end confdefs.h.  */
7034
7035 int
7036 main ()
7037 {
7038
7039   ;
7040   return 0;
7041 }
7042 _ACEOF
7043 # Make sure it works both with $CC and with simple cc.
7044 # We do the test twice because some compilers refuse to overwrite an
7045 # existing .o file with -o, though they will create one.
7046 ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
7047 rm -f conftest2.*
7048 if { { case "(($ac_try" in
7049   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7050   *) ac_try_echo=$ac_try;;
7051 esac
7052 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
7053 $as_echo "$ac_try_echo"; } >&5
7054   (eval "$ac_try") 2>&5
7055   ac_status=$?
7056   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
7057   test $ac_status = 0; } &&
7058    test -f conftest2.$ac_objext && { { case "(($ac_try" in
7059   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7060   *) ac_try_echo=$ac_try;;
7061 esac
7062 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
7063 $as_echo "$ac_try_echo"; } >&5
7064   (eval "$ac_try") 2>&5
7065   ac_status=$?
7066   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
7067   test $ac_status = 0; };
7068 then
7069   eval ac_cv_prog_cc_${ac_cc}_c_o=yes
7070   if test "x$CC" != xcc; then
7071     # Test first that cc exists at all.
7072     if { ac_try='cc -c conftest.$ac_ext >&5'
7073   { { case "(($ac_try" in
7074   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7075   *) ac_try_echo=$ac_try;;
7076 esac
7077 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
7078 $as_echo "$ac_try_echo"; } >&5
7079   (eval "$ac_try") 2>&5
7080   ac_status=$?
7081   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
7082   test $ac_status = 0; }; }; then
7083       ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
7084       rm -f conftest2.*
7085       if { { case "(($ac_try" in
7086   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7087   *) ac_try_echo=$ac_try;;
7088 esac
7089 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
7090 $as_echo "$ac_try_echo"; } >&5
7091   (eval "$ac_try") 2>&5
7092   ac_status=$?
7093   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
7094   test $ac_status = 0; } &&
7095          test -f conftest2.$ac_objext && { { case "(($ac_try" in
7096   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7097   *) ac_try_echo=$ac_try;;
7098 esac
7099 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
7100 $as_echo "$ac_try_echo"; } >&5
7101   (eval "$ac_try") 2>&5
7102   ac_status=$?
7103   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
7104   test $ac_status = 0; };
7105       then
7106         # cc works too.
7107         :
7108       else
7109         # cc exists but doesn't like -o.
7110         eval ac_cv_prog_cc_${ac_cc}_c_o=no
7111       fi
7112     fi
7113   fi
7114 else
7115   eval ac_cv_prog_cc_${ac_cc}_c_o=no
7116 fi
7117 rm -f core conftest*
7118
7119 fi
7120 if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then
7121   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7122 $as_echo "yes" >&6; }
7123 else
7124   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7125 $as_echo "no" >&6; }
7126
7127 $as_echo "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h
7128
7129 fi
7130
7131 # FIXME: we rely on the cache variable name because
7132 # there is no other way.
7133 set dummy $CC
7134 am_cc=`echo $2 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
7135 eval am_t=\$ac_cv_prog_cc_${am_cc}_c_o
7136 if test "$am_t" != yes; then
7137    # Losing compiler, so override with the script.
7138    # FIXME: It is wrong to rewrite CC.
7139    # But if we don't then we get into trouble of one sort or another.
7140    # A longer-term fix would be to have automake use am__CC in this case,
7141    # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
7142    CC="$am_aux_dir/compile $CC"
7143 fi
7144
7145
7146 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
7147 $as_echo_n "checking for ANSI C header files... " >&6; }
7148 if ${ac_cv_header_stdc+:} false; then :
7149   $as_echo_n "(cached) " >&6
7150 else
7151   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7152 /* end confdefs.h.  */
7153 #include <stdlib.h>
7154 #include <stdarg.h>
7155 #include <string.h>
7156 #include <float.h>
7157
7158 int
7159 main ()
7160 {
7161
7162   ;
7163   return 0;
7164 }
7165 _ACEOF
7166 if ac_fn_c_try_compile "$LINENO"; then :
7167   ac_cv_header_stdc=yes
7168 else
7169   ac_cv_header_stdc=no
7170 fi
7171 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7172
7173 if test $ac_cv_header_stdc = yes; then
7174   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
7175   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7176 /* end confdefs.h.  */
7177 #include <string.h>
7178
7179 _ACEOF
7180 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7181   $EGREP "memchr" >/dev/null 2>&1; then :
7182
7183 else
7184   ac_cv_header_stdc=no
7185 fi
7186 rm -f conftest*
7187
7188 fi
7189
7190 if test $ac_cv_header_stdc = yes; then
7191   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
7192   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7193 /* end confdefs.h.  */
7194 #include <stdlib.h>
7195
7196 _ACEOF
7197 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7198   $EGREP "free" >/dev/null 2>&1; then :
7199
7200 else
7201   ac_cv_header_stdc=no
7202 fi
7203 rm -f conftest*
7204
7205 fi
7206
7207 if test $ac_cv_header_stdc = yes; then
7208   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
7209   if test "$cross_compiling" = yes; then :
7210   :
7211 else
7212   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7213 /* end confdefs.h.  */
7214 #include <ctype.h>
7215 #include <stdlib.h>
7216 #if ((' ' & 0x0FF) == 0x020)
7217 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
7218 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
7219 #else
7220 # define ISLOWER(c) \
7221                    (('a' <= (c) && (c) <= 'i') \
7222                      || ('j' <= (c) && (c) <= 'r') \
7223                      || ('s' <= (c) && (c) <= 'z'))
7224 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
7225 #endif
7226
7227 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
7228 int
7229 main ()
7230 {
7231   int i;
7232   for (i = 0; i < 256; i++)
7233     if (XOR (islower (i), ISLOWER (i))
7234         || toupper (i) != TOUPPER (i))
7235       return 2;
7236   return 0;
7237 }
7238 _ACEOF
7239 if ac_fn_c_try_run "$LINENO"; then :
7240
7241 else
7242   ac_cv_header_stdc=no
7243 fi
7244 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7245   conftest.$ac_objext conftest.beam conftest.$ac_ext
7246 fi
7247
7248 fi
7249 fi
7250 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
7251 $as_echo "$ac_cv_header_stdc" >&6; }
7252 if test $ac_cv_header_stdc = yes; then
7253
7254 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
7255
7256 fi
7257
7258 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
7259 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
7260                   inttypes.h stdint.h unistd.h
7261 do :
7262   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
7263 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
7264 "
7265 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
7266   cat >>confdefs.h <<_ACEOF
7267 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
7268 _ACEOF
7269
7270 fi
7271
7272 done
7273
7274
7275
7276   ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
7277 if test "x$ac_cv_header_minix_config_h" = xyes; then :
7278   MINIX=yes
7279 else
7280   MINIX=
7281 fi
7282
7283
7284   if test "$MINIX" = yes; then
7285
7286 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
7287
7288
7289 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
7290
7291
7292 $as_echo "#define _MINIX 1" >>confdefs.h
7293
7294
7295 $as_echo "#define _NETBSD_SOURCE 1" >>confdefs.h
7296
7297   fi
7298
7299
7300   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
7301 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
7302 if ${ac_cv_safe_to_define___extensions__+:} false; then :
7303   $as_echo_n "(cached) " >&6
7304 else
7305   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7306 /* end confdefs.h.  */
7307
7308 #         define __EXTENSIONS__ 1
7309           $ac_includes_default
7310 int
7311 main ()
7312 {
7313
7314   ;
7315   return 0;
7316 }
7317 _ACEOF
7318 if ac_fn_c_try_compile "$LINENO"; then :
7319   ac_cv_safe_to_define___extensions__=yes
7320 else
7321   ac_cv_safe_to_define___extensions__=no
7322 fi
7323 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7324 fi
7325 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
7326 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
7327   test $ac_cv_safe_to_define___extensions__ = yes &&
7328     $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
7329
7330   $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
7331
7332   $as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h
7333
7334   $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
7335
7336   $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
7337
7338   $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
7339
7340   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether _XOPEN_SOURCE should be defined" >&5
7341 $as_echo_n "checking whether _XOPEN_SOURCE should be defined... " >&6; }
7342 if ${ac_cv_should_define__xopen_source+:} false; then :
7343   $as_echo_n "(cached) " >&6
7344 else
7345   ac_cv_should_define__xopen_source=no
7346      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7347 /* end confdefs.h.  */
7348
7349           #include <wchar.h>
7350           mbstate_t x;
7351 int
7352 main ()
7353 {
7354
7355   ;
7356   return 0;
7357 }
7358 _ACEOF
7359 if ac_fn_c_try_compile "$LINENO"; then :
7360
7361 else
7362   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7363 /* end confdefs.h.  */
7364
7365              #define _XOPEN_SOURCE 500
7366              #include <wchar.h>
7367              mbstate_t x;
7368 int
7369 main ()
7370 {
7371
7372   ;
7373   return 0;
7374 }
7375 _ACEOF
7376 if ac_fn_c_try_compile "$LINENO"; then :
7377   ac_cv_should_define__xopen_source=yes
7378 fi
7379 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7380 fi
7381 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7382 fi
7383 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_should_define__xopen_source" >&5
7384 $as_echo "$ac_cv_should_define__xopen_source" >&6; }
7385   test $ac_cv_should_define__xopen_source = yes &&
7386     $as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
7387
7388
7389
7390
7391
7392
7393
7394
7395 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
7396 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
7397 if ${ac_cv_sys_largefile_source+:} false; then :
7398   $as_echo_n "(cached) " >&6
7399 else
7400   while :; do
7401   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7402 /* end confdefs.h.  */
7403 #include <sys/types.h> /* for off_t */
7404      #include <stdio.h>
7405 int
7406 main ()
7407 {
7408 int (*fp) (FILE *, off_t, int) = fseeko;
7409      return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
7410   ;
7411   return 0;
7412 }
7413 _ACEOF
7414 if ac_fn_c_try_link "$LINENO"; then :
7415   ac_cv_sys_largefile_source=no; break
7416 fi
7417 rm -f core conftest.err conftest.$ac_objext \
7418     conftest$ac_exeext conftest.$ac_ext
7419   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7420 /* end confdefs.h.  */
7421 #define _LARGEFILE_SOURCE 1
7422 #include <sys/types.h> /* for off_t */
7423      #include <stdio.h>
7424 int
7425 main ()
7426 {
7427 int (*fp) (FILE *, off_t, int) = fseeko;
7428      return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
7429   ;
7430   return 0;
7431 }
7432 _ACEOF
7433 if ac_fn_c_try_link "$LINENO"; then :
7434   ac_cv_sys_largefile_source=1; break
7435 fi
7436 rm -f core conftest.err conftest.$ac_objext \
7437     conftest$ac_exeext conftest.$ac_ext
7438   ac_cv_sys_largefile_source=unknown
7439   break
7440 done
7441 fi
7442 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
7443 $as_echo "$ac_cv_sys_largefile_source" >&6; }
7444 case $ac_cv_sys_largefile_source in #(
7445   no | unknown) ;;
7446   *)
7447 cat >>confdefs.h <<_ACEOF
7448 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
7449 _ACEOF
7450 ;;
7451 esac
7452 rm -rf conftest*
7453
7454 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
7455 # in glibc 2.1.3, but that breaks too many other things.
7456 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
7457 if test $ac_cv_sys_largefile_source != unknown; then
7458
7459 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
7460
7461 fi
7462
7463
7464
7465
7466   # IEEE behaviour is the default on all CPUs except Alpha and SH
7467   # (according to the test results of Bruno Haible's ieeefp/fenv_default.m4
7468   # and the GCC 4.1.2 manual).
7469   case "$host_cpu" in
7470     alpha*)
7471       # On Alpha systems, a compiler option provides the behaviour.
7472       # See the ieee(3) manual page, also available at
7473       # <http://h30097.www3.hp.com/docs/base_doc/DOCUMENTATION/V51B_HTML/MAN/MAN3/0600____.HTM>
7474       if test -n "$GCC"; then
7475         # GCC has the option -mieee.
7476         # For full IEEE compliance (rarely needed), use option -mieee-with-inexact.
7477         CPPFLAGS="$CPPFLAGS -mieee"
7478       else
7479         # Compaq (ex-DEC) C has the option -ieee, equivalent to -ieee_with_no_inexact.
7480         # For full IEEE compliance (rarely needed), use option -ieee_with_inexact.
7481         CPPFLAGS="$CPPFLAGS -ieee"
7482       fi
7483       ;;
7484     sh*)
7485       if test -n "$GCC"; then
7486         # GCC has the option -mieee.
7487         CPPFLAGS="$CPPFLAGS -mieee"
7488       fi
7489       ;;
7490   esac
7491
7492 # Check whether --enable-largefile was given.
7493 if test "${enable_largefile+set}" = set; then :
7494   enableval=$enable_largefile;
7495 fi
7496
7497 if test "$enable_largefile" != no; then
7498
7499   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
7500 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
7501 if ${ac_cv_sys_largefile_CC+:} false; then :
7502   $as_echo_n "(cached) " >&6
7503 else
7504   ac_cv_sys_largefile_CC=no
7505      if test "$GCC" != yes; then
7506        ac_save_CC=$CC
7507        while :; do
7508          # IRIX 6.2 and later do not support large files by default,
7509          # so use the C compiler's -n32 option if that helps.
7510          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7511 /* end confdefs.h.  */
7512 #include <sys/types.h>
7513  /* Check that off_t can represent 2**63 - 1 correctly.
7514     We can't simply define LARGE_OFF_T to be 9223372036854775807,
7515     since some C++ compilers masquerading as C compilers
7516     incorrectly reject 9223372036854775807.  */
7517 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
7518   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7519                        && LARGE_OFF_T % 2147483647 == 1)
7520                       ? 1 : -1];
7521 int
7522 main ()
7523 {
7524
7525   ;
7526   return 0;
7527 }
7528 _ACEOF
7529          if ac_fn_c_try_compile "$LINENO"; then :
7530   break
7531 fi
7532 rm -f core conftest.err conftest.$ac_objext
7533          CC="$CC -n32"
7534          if ac_fn_c_try_compile "$LINENO"; then :
7535   ac_cv_sys_largefile_CC=' -n32'; break
7536 fi
7537 rm -f core conftest.err conftest.$ac_objext
7538          break
7539        done
7540        CC=$ac_save_CC
7541        rm -f conftest.$ac_ext
7542     fi
7543 fi
7544 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
7545 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
7546   if test "$ac_cv_sys_largefile_CC" != no; then
7547     CC=$CC$ac_cv_sys_largefile_CC
7548   fi
7549
7550   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
7551 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
7552 if ${ac_cv_sys_file_offset_bits+:} false; then :
7553   $as_echo_n "(cached) " >&6
7554 else
7555   while :; do
7556   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7557 /* end confdefs.h.  */
7558 #include <sys/types.h>
7559  /* Check that off_t can represent 2**63 - 1 correctly.
7560     We can't simply define LARGE_OFF_T to be 9223372036854775807,
7561     since some C++ compilers masquerading as C compilers
7562     incorrectly reject 9223372036854775807.  */
7563 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
7564   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7565                        && LARGE_OFF_T % 2147483647 == 1)
7566                       ? 1 : -1];
7567 int
7568 main ()
7569 {
7570
7571   ;
7572   return 0;
7573 }
7574 _ACEOF
7575 if ac_fn_c_try_compile "$LINENO"; then :
7576   ac_cv_sys_file_offset_bits=no; break
7577 fi
7578 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7579   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7580 /* end confdefs.h.  */
7581 #define _FILE_OFFSET_BITS 64
7582 #include <sys/types.h>
7583  /* Check that off_t can represent 2**63 - 1 correctly.
7584     We can't simply define LARGE_OFF_T to be 9223372036854775807,
7585     since some C++ compilers masquerading as C compilers
7586     incorrectly reject 9223372036854775807.  */
7587 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
7588   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7589                        && LARGE_OFF_T % 2147483647 == 1)
7590                       ? 1 : -1];
7591 int
7592 main ()
7593 {
7594
7595   ;
7596   return 0;
7597 }
7598 _ACEOF
7599 if ac_fn_c_try_compile "$LINENO"; then :
7600   ac_cv_sys_file_offset_bits=64; break
7601 fi
7602 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7603   ac_cv_sys_file_offset_bits=unknown
7604   break
7605 done
7606 fi
7607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
7608 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
7609 case $ac_cv_sys_file_offset_bits in #(
7610   no | unknown) ;;
7611   *)
7612 cat >>confdefs.h <<_ACEOF
7613 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
7614 _ACEOF
7615 ;;
7616 esac
7617 rm -rf conftest*
7618   if test $ac_cv_sys_file_offset_bits = unknown; then
7619     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
7620 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
7621 if ${ac_cv_sys_large_files+:} false; then :
7622   $as_echo_n "(cached) " >&6
7623 else
7624   while :; do
7625   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7626 /* end confdefs.h.  */
7627 #include <sys/types.h>
7628  /* Check that off_t can represent 2**63 - 1 correctly.
7629     We can't simply define LARGE_OFF_T to be 9223372036854775807,
7630     since some C++ compilers masquerading as C compilers
7631     incorrectly reject 9223372036854775807.  */
7632 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
7633   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7634                        && LARGE_OFF_T % 2147483647 == 1)
7635                       ? 1 : -1];
7636 int
7637 main ()
7638 {
7639
7640   ;
7641   return 0;
7642 }
7643 _ACEOF
7644 if ac_fn_c_try_compile "$LINENO"; then :
7645   ac_cv_sys_large_files=no; break
7646 fi
7647 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7648   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7649 /* end confdefs.h.  */
7650 #define _LARGE_FILES 1
7651 #include <sys/types.h>
7652  /* Check that off_t can represent 2**63 - 1 correctly.
7653     We can't simply define LARGE_OFF_T to be 9223372036854775807,
7654     since some C++ compilers masquerading as C compilers
7655     incorrectly reject 9223372036854775807.  */
7656 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
7657   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7658                        && LARGE_OFF_T % 2147483647 == 1)
7659                       ? 1 : -1];
7660 int
7661 main ()
7662 {
7663
7664   ;
7665   return 0;
7666 }
7667 _ACEOF
7668 if ac_fn_c_try_compile "$LINENO"; then :
7669   ac_cv_sys_large_files=1; break
7670 fi
7671 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7672   ac_cv_sys_large_files=unknown
7673   break
7674 done
7675 fi
7676 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
7677 $as_echo "$ac_cv_sys_large_files" >&6; }
7678 case $ac_cv_sys_large_files in #(
7679   no | unknown) ;;
7680   *)
7681 cat >>confdefs.h <<_ACEOF
7682 #define _LARGE_FILES $ac_cv_sys_large_files
7683 _ACEOF
7684 ;;
7685 esac
7686 rm -rf conftest*
7687   fi
7688
7689
7690 $as_echo "#define _DARWIN_USE_64_BIT_INODE 1" >>confdefs.h
7691
7692 fi
7693
7694    case $ac_cv_prog_cc_stdc in #(
7695   no) :
7696     ac_cv_prog_cc_c99=no; ac_cv_prog_cc_c89=no ;; #(
7697   *) :
7698     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5
7699 $as_echo_n "checking for $CC option to accept ISO C99... " >&6; }
7700 if ${ac_cv_prog_cc_c99+:} false; then :
7701   $as_echo_n "(cached) " >&6
7702 else
7703   ac_cv_prog_cc_c99=no
7704 ac_save_CC=$CC
7705 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7706 /* end confdefs.h.  */
7707 #include <stdarg.h>
7708 #include <stdbool.h>
7709 #include <stdlib.h>
7710 #include <wchar.h>
7711 #include <stdio.h>
7712
7713 // Check varargs macros.  These examples are taken from C99 6.10.3.5.
7714 #define debug(...) fprintf (stderr, __VA_ARGS__)
7715 #define showlist(...) puts (#__VA_ARGS__)
7716 #define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
7717 static void
7718 test_varargs_macros (void)
7719 {
7720   int x = 1234;
7721   int y = 5678;
7722   debug ("Flag");
7723   debug ("X = %d\n", x);
7724   showlist (The first, second, and third items.);
7725   report (x>y, "x is %d but y is %d", x, y);
7726 }
7727
7728 // Check long long types.
7729 #define BIG64 18446744073709551615ull
7730 #define BIG32 4294967295ul
7731 #define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
7732 #if !BIG_OK
7733   your preprocessor is broken;
7734 #endif
7735 #if BIG_OK
7736 #else
7737   your preprocessor is broken;
7738 #endif
7739 static long long int bignum = -9223372036854775807LL;
7740 static unsigned long long int ubignum = BIG64;
7741
7742 struct incomplete_array
7743 {
7744   int datasize;
7745   double data[];
7746 };
7747
7748 struct named_init {
7749   int number;
7750   const wchar_t *name;
7751   double average;
7752 };
7753
7754 typedef const char *ccp;
7755
7756 static inline int
7757 test_restrict (ccp restrict text)
7758 {
7759   // See if C++-style comments work.
7760   // Iterate through items via the restricted pointer.
7761   // Also check for declarations in for loops.
7762   for (unsigned int i = 0; *(text+i) != '\0'; ++i)
7763     continue;
7764   return 0;
7765 }
7766
7767 // Check varargs and va_copy.
7768 static void
7769 test_varargs (const char *format, ...)
7770 {
7771   va_list args;
7772   va_start (args, format);
7773   va_list args_copy;
7774   va_copy (args_copy, args);
7775
7776   const char *str;
7777   int number;
7778   float fnumber;
7779
7780   while (*format)
7781     {
7782       switch (*format++)
7783         {
7784         case 's': // string
7785           str = va_arg (args_copy, const char *);
7786           break;
7787         case 'd': // int
7788           number = va_arg (args_copy, int);
7789           break;
7790         case 'f': // float
7791           fnumber = va_arg (args_copy, double);
7792           break;
7793         default:
7794           break;
7795         }
7796     }
7797   va_end (args_copy);
7798   va_end (args);
7799 }
7800
7801 int
7802 main ()
7803 {
7804
7805   // Check bool.
7806   _Bool success = false;
7807
7808   // Check restrict.
7809   if (test_restrict ("String literal") == 0)
7810     success = true;
7811   char *restrict newvar = "Another string";
7812
7813   // Check varargs.
7814   test_varargs ("s, d' f .", "string", 65, 34.234);
7815   test_varargs_macros ();
7816
7817   // Check flexible array members.
7818   struct incomplete_array *ia =
7819     malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
7820   ia->datasize = 10;
7821   for (int i = 0; i < ia->datasize; ++i)
7822     ia->data[i] = i * 1.234;
7823
7824   // Check named initializers.
7825   struct named_init ni = {
7826     .number = 34,
7827     .name = L"Test wide string",
7828     .average = 543.34343,
7829   };
7830
7831   ni.number = 58;
7832
7833   int dynamic_array[ni.number];
7834   dynamic_array[ni.number - 1] = 543;
7835
7836   // work around unused variable warnings
7837   return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
7838           || dynamic_array[ni.number - 1] != 543);
7839
7840   ;
7841   return 0;
7842 }
7843 _ACEOF
7844 for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -D_STDC_C99= -qlanglvl=extc99
7845 do
7846   CC="$ac_save_CC $ac_arg"
7847   if ac_fn_c_try_compile "$LINENO"; then :
7848   ac_cv_prog_cc_c99=$ac_arg
7849 fi
7850 rm -f core conftest.err conftest.$ac_objext
7851   test "x$ac_cv_prog_cc_c99" != "xno" && break
7852 done
7853 rm -f conftest.$ac_ext
7854 CC=$ac_save_CC
7855
7856 fi
7857 # AC_CACHE_VAL
7858 case "x$ac_cv_prog_cc_c99" in
7859   x)
7860     { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
7861 $as_echo "none needed" >&6; } ;;
7862   xno)
7863     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
7864 $as_echo "unsupported" >&6; } ;;
7865   *)
7866     CC="$CC $ac_cv_prog_cc_c99"
7867     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
7868 $as_echo "$ac_cv_prog_cc_c99" >&6; } ;;
7869 esac
7870 if test "x$ac_cv_prog_cc_c99" != xno; then :
7871   ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
7872 else
7873   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
7874 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
7875 if ${ac_cv_prog_cc_c89+:} false; then :
7876   $as_echo_n "(cached) " >&6
7877 else
7878   ac_cv_prog_cc_c89=no
7879 ac_save_CC=$CC
7880 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7881 /* end confdefs.h.  */
7882 #include <stdarg.h>
7883 #include <stdio.h>
7884 struct stat;
7885 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
7886 struct buf { int x; };
7887 FILE * (*rcsopen) (struct buf *, struct stat *, int);
7888 static char *e (p, i)
7889      char **p;
7890      int i;
7891 {
7892   return p[i];
7893 }
7894 static char *f (char * (*g) (char **, int), char **p, ...)
7895 {
7896   char *s;
7897   va_list v;
7898   va_start (v,p);
7899   s = g (p, va_arg (v,int));
7900   va_end (v);
7901   return s;
7902 }
7903
7904 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
7905    function prototypes and stuff, but not '\xHH' hex character constants.
7906    These don't provoke an error unfortunately, instead are silently treated
7907    as 'x'.  The following induces an error, until -std is added to get
7908    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
7909    array size at least.  It's necessary to write '\x00'==0 to get something
7910    that's true only with -std.  */
7911 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
7912
7913 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
7914    inside strings and character constants.  */
7915 #define FOO(x) 'x'
7916 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
7917
7918 int test (int i, double x);
7919 struct s1 {int (*f) (int a);};
7920 struct s2 {int (*f) (double a);};
7921 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
7922 int argc;
7923 char **argv;
7924 int
7925 main ()
7926 {
7927 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
7928   ;
7929   return 0;
7930 }
7931 _ACEOF
7932 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
7933         -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
7934 do
7935   CC="$ac_save_CC $ac_arg"
7936   if ac_fn_c_try_compile "$LINENO"; then :
7937   ac_cv_prog_cc_c89=$ac_arg
7938 fi
7939 rm -f core conftest.err conftest.$ac_objext
7940   test "x$ac_cv_prog_cc_c89" != "xno" && break
7941 done
7942 rm -f conftest.$ac_ext
7943 CC=$ac_save_CC
7944
7945 fi
7946 # AC_CACHE_VAL
7947 case "x$ac_cv_prog_cc_c89" in
7948   x)
7949     { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
7950 $as_echo "none needed" >&6; } ;;
7951   xno)
7952     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
7953 $as_echo "unsupported" >&6; } ;;
7954   *)
7955     CC="$CC $ac_cv_prog_cc_c89"
7956     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
7957 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
7958 esac
7959 if test "x$ac_cv_prog_cc_c89" != xno; then :
7960   ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
7961 else
7962   ac_cv_prog_cc_stdc=no
7963 fi
7964
7965 fi
7966  ;;
7967 esac
7968   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO Standard C" >&5
7969 $as_echo_n "checking for $CC option to accept ISO Standard C... " >&6; }
7970   if ${ac_cv_prog_cc_stdc+:} false; then :
7971   $as_echo_n "(cached) " >&6
7972 fi
7973
7974   case $ac_cv_prog_cc_stdc in #(
7975   no) :
7976     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
7977 $as_echo "unsupported" >&6; } ;; #(
7978   '') :
7979     { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
7980 $as_echo "none needed" >&6; } ;; #(
7981   *) :
7982     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_stdc" >&5
7983 $as_echo "$ac_cv_prog_cc_stdc" >&6; } ;;
7984 esac
7985
7986
7987
7988
7989
7990
7991   # Check whether --enable-threads was given.
7992 if test "${enable_threads+set}" = set; then :
7993   enableval=$enable_threads; gl_use_threads=$enableval
7994 else
7995   if test -n "$gl_use_threads_default"; then
7996        gl_use_threads="$gl_use_threads_default"
7997      else
7998        case "$host_os" in
7999                                                                osf*) gl_use_threads=no ;;
8000          cygwin*)
8001                case `uname -r` in
8002                  1.[0-5].*) gl_use_threads=no ;;
8003                  *)         gl_use_threads=yes ;;
8004                esac
8005                ;;
8006          *)    gl_use_threads=yes ;;
8007        esac
8008      fi
8009
8010 fi
8011
8012   if test "$gl_use_threads" = yes || test "$gl_use_threads" = posix; then
8013     # For using <pthread.h>:
8014     case "$host_os" in
8015       osf*)
8016         # On OSF/1, the compiler needs the flag -D_REENTRANT so that it
8017         # groks <pthread.h>. cc also understands the flag -pthread, but
8018         # we don't use it because 1. gcc-2.95 doesn't understand -pthread,
8019         # 2. putting a flag into CPPFLAGS that has an effect on the linker
8020         # causes the AC_LINK_IFELSE test below to succeed unexpectedly,
8021         # leading to wrong values of LIBTHREAD and LTLIBTHREAD.
8022         CPPFLAGS="$CPPFLAGS -D_REENTRANT"
8023         ;;
8024     esac
8025     # Some systems optimize for single-threaded programs by default, and
8026     # need special flags to disable these optimizations. For example, the
8027     # definition of 'errno' in <errno.h>.
8028     case "$host_os" in
8029       aix* | freebsd*) CPPFLAGS="$CPPFLAGS -D_THREAD_SAFE" ;;
8030       solaris*) CPPFLAGS="$CPPFLAGS -D_REENTRANT" ;;
8031     esac
8032   fi
8033
8034
8035
8036
8037   # Code from module absolute-header:
8038   # Code from module accept:
8039   # Code from module accept-tests:
8040   # Code from module alloca:
8041   # Code from module alloca-opt:
8042   # Code from module alloca-opt-tests:
8043   # Code from module allocator:
8044   # Code from module areadlink:
8045   # Code from module areadlink-tests:
8046   # Code from module arpa_inet:
8047   # Code from module arpa_inet-tests:
8048   # Code from module autobuild:
8049
8050
8051
8052
8053   if test -z "$AB_PACKAGE"; then
8054     AB_PACKAGE=${PACKAGE_NAME:-$PACKAGE}
8055   fi
8056   { $as_echo "$as_me:${as_lineno-$LINENO}: autobuild project... $AB_PACKAGE" >&5
8057 $as_echo "$as_me: autobuild project... $AB_PACKAGE" >&6;}
8058
8059   if test -z "$AB_VERSION"; then
8060     AB_VERSION=${PACKAGE_VERSION:-$VERSION}
8061   fi
8062   { $as_echo "$as_me:${as_lineno-$LINENO}: autobuild revision... $AB_VERSION" >&5
8063 $as_echo "$as_me: autobuild revision... $AB_VERSION" >&6;}
8064
8065   hostname=`hostname`
8066   if test "$hostname"; then
8067     { $as_echo "$as_me:${as_lineno-$LINENO}: autobuild hostname... $hostname" >&5
8068 $as_echo "$as_me: autobuild hostname... $hostname" >&6;}
8069   fi
8070
8071
8072
8073   date=`TZ=UTC0 date +%Y%m%dT%H%M%SZ`
8074   if test "$?" != 0; then
8075     date=`date`
8076   fi
8077   if test "$date"; then
8078     { $as_echo "$as_me:${as_lineno-$LINENO}: autobuild timestamp... $date" >&5
8079 $as_echo "$as_me: autobuild timestamp... $date" >&6;}
8080   fi
8081
8082   # Code from module base64:
8083   # Code from module base64-tests:
8084   # Code from module binary-io:
8085   # Code from module binary-io-tests:
8086   # Code from module bind:
8087   # Code from module bind-tests:
8088   # Code from module bitrotate:
8089   # Code from module bitrotate-tests:
8090   # Code from module btowc:
8091   # Code from module btowc-tests:
8092   # Code from module byteswap:
8093   # Code from module byteswap-tests:
8094   # Code from module c-ctype:
8095   # Code from module c-ctype-tests:
8096   # Code from module c-strcase:
8097   # Code from module c-strcase-tests:
8098   # Code from module c-strcasestr:
8099   # Code from module c-strcasestr-tests:
8100   # Code from module calloc-posix:
8101   # Code from module canonicalize-lgpl:
8102   # Code from module canonicalize-lgpl-tests:
8103   # Code from module careadlinkat:
8104   # Code from module chown:
8105   # Code from module chown-tests:
8106   # Code from module clock-time:
8107   # Code from module cloexec:
8108   # Code from module cloexec-tests:
8109   # Code from module close:
8110   # Code from module close-tests:
8111   # Code from module configmake:
8112   # Code from module connect:
8113   # Code from module connect-tests:
8114   # Code from module count-one-bits:
8115   # Code from module count-one-bits-tests:
8116   # Code from module crypto/md5:
8117   # Code from module crypto/md5-tests:
8118   # Code from module crypto/sha256:
8119   # Code from module dirname-lgpl:
8120   # Code from module dosname:
8121   # Code from module double-slash-root:
8122   # Code from module dup:
8123   # Code from module dup-tests:
8124   # Code from module dup2:
8125   # Code from module dup2-tests:
8126   # Code from module environ:
8127   # Code from module environ-tests:
8128   # Code from module errno:
8129   # Code from module errno-tests:
8130   # Code from module error:
8131   # Code from module execinfo:
8132   # Code from module exitfail:
8133   # Code from module extensions:
8134
8135   # Code from module extern-inline:
8136   # Code from module fatal-signal:
8137   # Code from module fclose:
8138   # Code from module fclose-tests:
8139   # Code from module fcntl:
8140   # Code from module fcntl-h:
8141   # Code from module fcntl-h-tests:
8142   # Code from module fcntl-tests:
8143   # Code from module fd-hook:
8144   # Code from module fdatasync:
8145   # Code from module fdatasync-tests:
8146   # Code from module fdopen:
8147   # Code from module fdopen-tests:
8148   # Code from module fflush:
8149
8150   # Code from module fflush-tests:
8151   # Code from module ffs:
8152   # Code from module ffs-tests:
8153   # Code from module ffsl:
8154   # Code from module ffsl-tests:
8155   # Code from module fgetc-tests:
8156   # Code from module float:
8157   # Code from module float-tests:
8158   # Code from module fnmatch:
8159   # Code from module fnmatch-tests:
8160   # Code from module fpieee:
8161
8162   # Code from module fpucw:
8163   # Code from module fpurge:
8164   # Code from module fpurge-tests:
8165   # Code from module fputc-tests:
8166   # Code from module fread-tests:
8167   # Code from module freading:
8168   # Code from module freading-tests:
8169   # Code from module fseek:
8170   # Code from module fseek-tests:
8171   # Code from module fseeko:
8172
8173   # Code from module fseeko-tests:
8174   # Code from module fstat:
8175   # Code from module fstat-tests:
8176   # Code from module fsync:
8177   # Code from module fsync-tests:
8178   # Code from module ftell:
8179   # Code from module ftell-tests:
8180   # Code from module ftello:
8181
8182   # Code from module ftello-tests:
8183   # Code from module ftruncate:
8184   # Code from module ftruncate-tests:
8185   # Code from module func:
8186   # Code from module func-tests:
8187   # Code from module fwrite-tests:
8188   # Code from module getaddrinfo:
8189   # Code from module getaddrinfo-tests:
8190   # Code from module getcwd-lgpl:
8191   # Code from module getcwd-lgpl-tests:
8192   # Code from module getdelim:
8193   # Code from module getdelim-tests:
8194   # Code from module getdtablesize:
8195   # Code from module getdtablesize-tests:
8196   # Code from module getgroups:
8197   # Code from module getgroups-tests:
8198   # Code from module gethostname:
8199   # Code from module gethostname-tests:
8200   # Code from module getline:
8201   # Code from module getline-tests:
8202   # Code from module getpagesize:
8203   # Code from module getpass:
8204   # Code from module getpeername:
8205   # Code from module getpeername-tests:
8206   # Code from module getsockname:
8207   # Code from module getsockname-tests:
8208   # Code from module getsockopt:
8209   # Code from module getsockopt-tests:
8210   # Code from module gettext-h:
8211   # Code from module gettimeofday:
8212   # Code from module gettimeofday-tests:
8213   # Code from module getugroups:
8214   # Code from module gitlog-to-changelog:
8215   # Code from module gnumakefile:
8216   # Code from module grantpt:
8217   # Code from module grantpt-tests:
8218   # Code from module havelib:
8219   # Code from module hostent:
8220   # Code from module ignore-value:
8221   # Code from module ignore-value-tests:
8222   # Code from module include_next:
8223   # Code from module inet_ntop:
8224   # Code from module inet_ntop-tests:
8225   # Code from module inet_pton:
8226   # Code from module inet_pton-tests:
8227   # Code from module intprops:
8228   # Code from module intprops-tests:
8229   # Code from module inttypes:
8230   # Code from module inttypes-incomplete:
8231   # Code from module inttypes-tests:
8232   # Code from module ioctl:
8233   # Code from module ioctl-tests:
8234   # Code from module isatty:
8235   # Code from module isatty-tests:
8236   # Code from module isnand-nolibm:
8237   # Code from module isnand-nolibm-tests:
8238   # Code from module isnanf-nolibm:
8239   # Code from module isnanf-nolibm-tests:
8240   # Code from module isnanl-nolibm:
8241   # Code from module isnanl-nolibm-tests:
8242   # Code from module langinfo:
8243   # Code from module langinfo-tests:
8244   # Code from module largefile:
8245
8246   # Code from module ldexp:
8247   # Code from module ldexp-tests:
8248   # Code from module listen:
8249   # Code from module listen-tests:
8250   # Code from module localcharset:
8251   # Code from module locale:
8252   # Code from module locale-tests:
8253   # Code from module localeconv:
8254   # Code from module localeconv-tests:
8255   # Code from module localename:
8256   # Code from module localename-tests:
8257   # Code from module lock:
8258   # Code from module lseek:
8259   # Code from module lseek-tests:
8260   # Code from module lstat:
8261   # Code from module lstat-tests:
8262   # Code from module maintainer-makefile:
8263   # Code from module malloc-posix:
8264   # Code from module malloca:
8265   # Code from module malloca-tests:
8266   # Code from module manywarnings:
8267   # Code from module math:
8268   # Code from module math-tests:
8269   # Code from module mbrtowc:
8270   # Code from module mbrtowc-tests:
8271   # Code from module mbsinit:
8272   # Code from module mbsinit-tests:
8273   # Code from module mbsrtowcs:
8274   # Code from module mbsrtowcs-tests:
8275   # Code from module mbtowc:
8276   # Code from module memchr:
8277   # Code from module memchr-tests:
8278   # Code from module mgetgroups:
8279   # Code from module mkdtemp:
8280   # Code from module mkostemp:
8281   # Code from module mkostemps:
8282   # Code from module mktempd:
8283   # Code from module mktime:
8284   # Code from module mktime-internal:
8285   # Code from module msvc-inval:
8286   # Code from module msvc-nothrow:
8287   # Code from module multiarch:
8288   # Code from module nanosleep:
8289   # Code from module nanosleep-tests:
8290   # Code from module net_if:
8291   # Code from module net_if-tests:
8292   # Code from module netdb:
8293   # Code from module netdb-tests:
8294   # Code from module netinet_in:
8295   # Code from module netinet_in-tests:
8296   # Code from module nl_langinfo:
8297   # Code from module nl_langinfo-tests:
8298   # Code from module nocrash:
8299   # Code from module nonblocking:
8300   # Code from module nonblocking-pipe-tests:
8301   # Code from module nonblocking-socket-tests:
8302   # Code from module nonblocking-tests:
8303   # Code from module open:
8304   # Code from module open-tests:
8305   # Code from module openpty:
8306   # Code from module openpty-tests:
8307   # Code from module passfd:
8308   # Code from module passfd-tests:
8309   # Code from module pathmax:
8310   # Code from module pathmax-tests:
8311   # Code from module perror:
8312   # Code from module perror-tests:
8313   # Code from module physmem:
8314   # Code from module pipe-posix:
8315   # Code from module pipe-posix-tests:
8316   # Code from module pipe2:
8317   # Code from module pipe2-tests:
8318   # Code from module poll:
8319   # Code from module poll-h:
8320   # Code from module poll-h-tests:
8321   # Code from module poll-tests:
8322   # Code from module posix-shell:
8323   # Code from module posix_openpt:
8324   # Code from module posix_openpt-tests:
8325   # Code from module posix_spawn-internal:
8326   # Code from module posix_spawn_file_actions_addclose:
8327   # Code from module posix_spawn_file_actions_addclose-tests:
8328   # Code from module posix_spawn_file_actions_adddup2:
8329   # Code from module posix_spawn_file_actions_adddup2-tests:
8330   # Code from module posix_spawn_file_actions_addopen:
8331   # Code from module posix_spawn_file_actions_addopen-tests:
8332   # Code from module posix_spawn_file_actions_destroy:
8333   # Code from module posix_spawn_file_actions_init:
8334   # Code from module posix_spawnattr_destroy:
8335   # Code from module posix_spawnattr_init:
8336   # Code from module posix_spawnattr_setflags:
8337   # Code from module posix_spawnattr_setsigmask:
8338   # Code from module posix_spawnp:
8339   # Code from module posix_spawnp-tests:
8340   # Code from module progname:
8341   # Code from module pthread:
8342   # Code from module pthread_sigmask:
8343   # Code from module pthread_sigmask-tests:
8344   # Code from module ptsname:
8345   # Code from module ptsname-tests:
8346   # Code from module ptsname_r:
8347   # Code from module ptsname_r-tests:
8348   # Code from module pty:
8349   # Code from module pty-tests:
8350   # Code from module putenv:
8351   # Code from module raise:
8352   # Code from module raise-tests:
8353   # Code from module random_r:
8354   # Code from module random_r-tests:
8355   # Code from module rawmemchr:
8356   # Code from module rawmemchr-tests:
8357   # Code from module read:
8358   # Code from module read-tests:
8359   # Code from module readlink:
8360   # Code from module readlink-tests:
8361   # Code from module realloc-posix:
8362   # Code from module recv:
8363   # Code from module recv-tests:
8364   # Code from module regex:
8365   # Code from module regex-tests:
8366   # Code from module same-inode:
8367   # Code from module sched:
8368   # Code from module sched-tests:
8369   # Code from module secure_getenv:
8370   # Code from module select:
8371   # Code from module select-tests:
8372   # Code from module send:
8373   # Code from module send-tests:
8374   # Code from module servent:
8375   # Code from module setenv:
8376   # Code from module setenv-tests:
8377   # Code from module setlocale:
8378   # Code from module setlocale-tests:
8379   # Code from module setsockopt:
8380   # Code from module setsockopt-tests:
8381   # Code from module sigaction:
8382   # Code from module sigaction-tests:
8383   # Code from module signal-h:
8384   # Code from module signal-h-tests:
8385   # Code from module signbit:
8386   # Code from module signbit-tests:
8387   # Code from module sigpipe:
8388   # Code from module sigpipe-tests:
8389   # Code from module sigprocmask:
8390   # Code from module sigprocmask-tests:
8391   # Code from module size_max:
8392   # Code from module sleep:
8393   # Code from module sleep-tests:
8394   # Code from module snippet/_Noreturn:
8395   # Code from module snippet/arg-nonnull:
8396   # Code from module snippet/c++defs:
8397   # Code from module snippet/unused-parameter:
8398   # Code from module snippet/warn-on-use:
8399   # Code from module snprintf:
8400   # Code from module snprintf-tests:
8401   # Code from module socket:
8402   # Code from module socketlib:
8403   # Code from module sockets:
8404   # Code from module sockets-tests:
8405   # Code from module socklen:
8406   # Code from module spawn:
8407   # Code from module spawn-tests:
8408   # Code from module ssize_t:
8409   # Code from module stat:
8410   # Code from module stat-tests:
8411   # Code from module stat-time:
8412   # Code from module stat-time-tests:
8413   # Code from module stdalign:
8414   # Code from module stdalign-tests:
8415   # Code from module stdarg:
8416
8417
8418
8419   # Code from module stdbool:
8420   # Code from module stdbool-tests:
8421   # Code from module stddef:
8422   # Code from module stddef-tests:
8423   # Code from module stdint:
8424   # Code from module stdint-tests:
8425   # Code from module stdio:
8426   # Code from module stdio-tests:
8427   # Code from module stdlib:
8428   # Code from module stdlib-tests:
8429   # Code from module stpcpy:
8430   # Code from module strcase:
8431   # Code from module strchrnul:
8432   # Code from module strchrnul-tests:
8433   # Code from module strdup-posix:
8434   # Code from module streq:
8435   # Code from module strerror:
8436   # Code from module strerror-override:
8437   # Code from module strerror-tests:
8438   # Code from module strerror_r-posix:
8439   # Code from module strerror_r-posix-tests:
8440   # Code from module string:
8441   # Code from module string-tests:
8442   # Code from module strings:
8443   # Code from module strings-tests:
8444   # Code from module strndup:
8445   # Code from module strnlen:
8446   # Code from module strnlen-tests:
8447   # Code from module strnlen1:
8448   # Code from module strptime:
8449   # Code from module strsep:
8450   # Code from module strtok_r:
8451   # Code from module symlink:
8452   # Code from module symlink-tests:
8453   # Code from module sys_ioctl:
8454   # Code from module sys_ioctl-tests:
8455   # Code from module sys_select:
8456   # Code from module sys_select-tests:
8457   # Code from module sys_socket:
8458   # Code from module sys_socket-tests:
8459   # Code from module sys_stat:
8460   # Code from module sys_stat-tests:
8461   # Code from module sys_time:
8462   # Code from module sys_time-tests:
8463   # Code from module sys_types:
8464   # Code from module sys_types-tests:
8465   # Code from module sys_uio:
8466   # Code from module sys_uio-tests:
8467   # Code from module sys_utsname:
8468   # Code from module sys_utsname-tests:
8469   # Code from module sys_wait:
8470   # Code from module sys_wait-tests:
8471   # Code from module tempname:
8472   # Code from module termios:
8473   # Code from module termios-tests:
8474   # Code from module test-framework-sh:
8475   # Code from module test-framework-sh-tests:
8476   # Code from module thread:
8477   # Code from module thread-tests:
8478   # Code from module threadlib:
8479
8480
8481
8482   # Code from module time:
8483   # Code from module time-tests:
8484   # Code from module time_r:
8485   # Code from module timegm:
8486   # Code from module ttyname_r:
8487   # Code from module ttyname_r-tests:
8488   # Code from module uname:
8489   # Code from module uname-tests:
8490   # Code from module unistd:
8491   # Code from module unistd-tests:
8492   # Code from module unlockpt:
8493   # Code from module unlockpt-tests:
8494   # Code from module unsetenv:
8495   # Code from module unsetenv-tests:
8496   # Code from module useless-if-before-free:
8497   # Code from module usleep:
8498   # Code from module usleep-tests:
8499   # Code from module vasnprintf:
8500   # Code from module vasnprintf-tests:
8501   # Code from module vasprintf:
8502   # Code from module vasprintf-tests:
8503   # Code from module vc-list-files:
8504   # Code from module vc-list-files-tests:
8505   # Code from module verify:
8506   # Code from module verify-tests:
8507   # Code from module vsnprintf:
8508   # Code from module vsnprintf-tests:
8509   # Code from module wait-process:
8510   # Code from module waitpid:
8511   # Code from module warnings:
8512   # Code from module wchar:
8513   # Code from module wchar-tests:
8514   # Code from module wcrtomb:
8515   # Code from module wcrtomb-tests:
8516   # Code from module wctob:
8517   # Code from module wctomb:
8518   # Code from module wctype-h:
8519   # Code from module wctype-h-tests:
8520   # Code from module write:
8521   # Code from module write-tests:
8522   # Code from module xalloc:
8523   # Code from module xalloc-die:
8524   # Code from module xalloc-die-tests:
8525   # Code from module xalloc-oversized:
8526   # Code from module xsize:
8527
8528
8529
8530
8531
8532
8533           LIBC_FATAL_STDERR_=1
8534   export LIBC_FATAL_STDERR_
8535
8536
8537   GNULIB_SOCKET=0;
8538   GNULIB_CONNECT=0;
8539   GNULIB_ACCEPT=0;
8540   GNULIB_BIND=0;
8541   GNULIB_GETPEERNAME=0;
8542   GNULIB_GETSOCKNAME=0;
8543   GNULIB_GETSOCKOPT=0;
8544   GNULIB_LISTEN=0;
8545   GNULIB_RECV=0;
8546   GNULIB_SEND=0;
8547   GNULIB_RECVFROM=0;
8548   GNULIB_SENDTO=0;
8549   GNULIB_SETSOCKOPT=0;
8550   GNULIB_SHUTDOWN=0;
8551   GNULIB_ACCEPT4=0;
8552   HAVE_STRUCT_SOCKADDR_STORAGE=1;
8553   HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY=1;
8554
8555   HAVE_SA_FAMILY_T=1;
8556   HAVE_ACCEPT4=1;
8557
8558
8559
8560
8561
8562   for ac_header in $gl_header_list
8563 do :
8564   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8565 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
8566 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
8567   cat >>confdefs.h <<_ACEOF
8568 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8569 _ACEOF
8570
8571 fi
8572
8573 done
8574
8575
8576
8577
8578
8579
8580   :
8581
8582
8583
8584
8585
8586    if test $ac_cv_header_sys_socket_h = no; then
8587                          for ac_header in ws2tcpip.h
8588 do :
8589   ac_fn_c_check_header_mongrel "$LINENO" "ws2tcpip.h" "ac_cv_header_ws2tcpip_h" "$ac_includes_default"
8590 if test "x$ac_cv_header_ws2tcpip_h" = xyes; then :
8591   cat >>confdefs.h <<_ACEOF
8592 #define HAVE_WS2TCPIP_H 1
8593 _ACEOF
8594
8595 fi
8596
8597 done
8598
8599    fi
8600
8601
8602
8603   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the preprocessor supports include_next" >&5
8604 $as_echo_n "checking whether the preprocessor supports include_next... " >&6; }
8605 if ${gl_cv_have_include_next+:} false; then :
8606   $as_echo_n "(cached) " >&6
8607 else
8608   rm -rf conftestd1a conftestd1b conftestd2
8609      mkdir conftestd1a conftestd1b conftestd2
8610                                                   cat <<EOF > conftestd1a/conftest.h
8611 #define DEFINED_IN_CONFTESTD1
8612 #include_next <conftest.h>
8613 #ifdef DEFINED_IN_CONFTESTD2
8614 int foo;
8615 #else
8616 #error "include_next doesn't work"
8617 #endif
8618 EOF
8619      cat <<EOF > conftestd1b/conftest.h
8620 #define DEFINED_IN_CONFTESTD1
8621 #include <stdio.h>
8622 #include_next <conftest.h>
8623 #ifdef DEFINED_IN_CONFTESTD2
8624 int foo;
8625 #else
8626 #error "include_next doesn't work"
8627 #endif
8628 EOF
8629      cat <<EOF > conftestd2/conftest.h
8630 #ifndef DEFINED_IN_CONFTESTD1
8631 #error "include_next test doesn't work"
8632 #endif
8633 #define DEFINED_IN_CONFTESTD2
8634 EOF
8635      gl_save_CPPFLAGS="$CPPFLAGS"
8636      CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1b -Iconftestd2"
8637      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8638 /* end confdefs.h.  */
8639 #include <conftest.h>
8640 _ACEOF
8641 if ac_fn_c_try_compile "$LINENO"; then :
8642   gl_cv_have_include_next=yes
8643 else
8644   CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2"
8645         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8646 /* end confdefs.h.  */
8647 #include <conftest.h>
8648 _ACEOF
8649 if ac_fn_c_try_compile "$LINENO"; then :
8650   gl_cv_have_include_next=buggy
8651 else
8652   gl_cv_have_include_next=no
8653 fi
8654 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8655
8656 fi
8657 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8658      CPPFLAGS="$gl_save_CPPFLAGS"
8659      rm -rf conftestd1a conftestd1b conftestd2
8660
8661 fi
8662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_include_next" >&5
8663 $as_echo "$gl_cv_have_include_next" >&6; }
8664   PRAGMA_SYSTEM_HEADER=
8665   if test $gl_cv_have_include_next = yes; then
8666     INCLUDE_NEXT=include_next
8667     INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
8668     if test -n "$GCC"; then
8669       PRAGMA_SYSTEM_HEADER='#pragma GCC system_header'
8670     fi
8671   else
8672     if test $gl_cv_have_include_next = buggy; then
8673       INCLUDE_NEXT=include
8674       INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
8675     else
8676       INCLUDE_NEXT=include
8677       INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include
8678     fi
8679   fi
8680
8681
8682
8683   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system header files limit the line length" >&5
8684 $as_echo_n "checking whether system header files limit the line length... " >&6; }
8685 if ${gl_cv_pragma_columns+:} false; then :
8686   $as_echo_n "(cached) " >&6
8687 else
8688        cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8689 /* end confdefs.h.  */
8690
8691 #ifdef __TANDEM
8692 choke me
8693 #endif
8694
8695 _ACEOF
8696 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8697   $EGREP "choke me" >/dev/null 2>&1; then :
8698   gl_cv_pragma_columns=yes
8699 else
8700   gl_cv_pragma_columns=no
8701 fi
8702 rm -f conftest*
8703
8704
8705 fi
8706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_pragma_columns" >&5
8707 $as_echo "$gl_cv_pragma_columns" >&6; }
8708   if test $gl_cv_pragma_columns = yes; then
8709     PRAGMA_COLUMNS="#pragma COLUMNS 10000"
8710   else
8711     PRAGMA_COLUMNS=
8712   fi
8713
8714
8715
8716   GNULIB_CHDIR=0;
8717   GNULIB_CHOWN=0;
8718   GNULIB_CLOSE=0;
8719   GNULIB_DUP=0;
8720   GNULIB_DUP2=0;
8721   GNULIB_DUP3=0;
8722   GNULIB_ENVIRON=0;
8723   GNULIB_EUIDACCESS=0;
8724   GNULIB_FACCESSAT=0;
8725   GNULIB_FCHDIR=0;
8726   GNULIB_FCHOWNAT=0;
8727   GNULIB_FDATASYNC=0;
8728   GNULIB_FSYNC=0;
8729   GNULIB_FTRUNCATE=0;
8730   GNULIB_GETCWD=0;
8731   GNULIB_GETDOMAINNAME=0;
8732   GNULIB_GETDTABLESIZE=0;
8733   GNULIB_GETGROUPS=0;
8734   GNULIB_GETHOSTNAME=0;
8735   GNULIB_GETLOGIN=0;
8736   GNULIB_GETLOGIN_R=0;
8737   GNULIB_GETPAGESIZE=0;
8738   GNULIB_GETUSERSHELL=0;
8739   GNULIB_GROUP_MEMBER=0;
8740   GNULIB_ISATTY=0;
8741   GNULIB_LCHOWN=0;
8742   GNULIB_LINK=0;
8743   GNULIB_LINKAT=0;
8744   GNULIB_LSEEK=0;
8745   GNULIB_PIPE=0;
8746   GNULIB_PIPE2=0;
8747   GNULIB_PREAD=0;
8748   GNULIB_PWRITE=0;
8749   GNULIB_READ=0;
8750   GNULIB_READLINK=0;
8751   GNULIB_READLINKAT=0;
8752   GNULIB_RMDIR=0;
8753   GNULIB_SETHOSTNAME=0;
8754   GNULIB_SLEEP=0;
8755   GNULIB_SYMLINK=0;
8756   GNULIB_SYMLINKAT=0;
8757   GNULIB_TTYNAME_R=0;
8758   GNULIB_UNISTD_H_NONBLOCKING=0;
8759   GNULIB_UNISTD_H_SIGPIPE=0;
8760   GNULIB_UNLINK=0;
8761   GNULIB_UNLINKAT=0;
8762   GNULIB_USLEEP=0;
8763   GNULIB_WRITE=0;
8764     HAVE_CHOWN=1;
8765   HAVE_DUP2=1;
8766   HAVE_DUP3=1;
8767   HAVE_EUIDACCESS=1;
8768   HAVE_FACCESSAT=1;
8769   HAVE_FCHDIR=1;
8770   HAVE_FCHOWNAT=1;
8771   HAVE_FDATASYNC=1;
8772   HAVE_FSYNC=1;
8773   HAVE_FTRUNCATE=1;
8774   HAVE_GETDTABLESIZE=1;
8775   HAVE_GETGROUPS=1;
8776   HAVE_GETHOSTNAME=1;
8777   HAVE_GETLOGIN=1;
8778   HAVE_GETPAGESIZE=1;
8779   HAVE_GROUP_MEMBER=1;
8780   HAVE_LCHOWN=1;
8781   HAVE_LINK=1;
8782   HAVE_LINKAT=1;
8783   HAVE_PIPE=1;
8784   HAVE_PIPE2=1;
8785   HAVE_PREAD=1;
8786   HAVE_PWRITE=1;
8787   HAVE_READLINK=1;
8788   HAVE_READLINKAT=1;
8789   HAVE_SETHOSTNAME=1;
8790   HAVE_SLEEP=1;
8791   HAVE_SYMLINK=1;
8792   HAVE_SYMLINKAT=1;
8793   HAVE_UNLINKAT=1;
8794   HAVE_USLEEP=1;
8795   HAVE_DECL_ENVIRON=1;
8796   HAVE_DECL_FCHDIR=1;
8797   HAVE_DECL_FDATASYNC=1;
8798   HAVE_DECL_GETDOMAINNAME=1;
8799   HAVE_DECL_GETLOGIN_R=1;
8800   HAVE_DECL_GETPAGESIZE=1;
8801   HAVE_DECL_GETUSERSHELL=1;
8802   HAVE_DECL_SETHOSTNAME=1;
8803   HAVE_DECL_TTYNAME_R=1;
8804   HAVE_OS_H=0;
8805   HAVE_SYS_PARAM_H=0;
8806   REPLACE_CHOWN=0;
8807   REPLACE_CLOSE=0;
8808   REPLACE_DUP=0;
8809   REPLACE_DUP2=0;
8810   REPLACE_FCHOWNAT=0;
8811   REPLACE_FTRUNCATE=0;
8812   REPLACE_GETCWD=0;
8813   REPLACE_GETDOMAINNAME=0;
8814   REPLACE_GETDTABLESIZE=0;
8815   REPLACE_GETLOGIN_R=0;
8816   REPLACE_GETGROUPS=0;
8817   REPLACE_GETPAGESIZE=0;
8818   REPLACE_ISATTY=0;
8819   REPLACE_LCHOWN=0;
8820   REPLACE_LINK=0;
8821   REPLACE_LINKAT=0;
8822   REPLACE_LSEEK=0;
8823   REPLACE_PREAD=0;
8824   REPLACE_PWRITE=0;
8825   REPLACE_READ=0;
8826   REPLACE_READLINK=0;
8827   REPLACE_RMDIR=0;
8828   REPLACE_SLEEP=0;
8829   REPLACE_SYMLINK=0;
8830   REPLACE_TTYNAME_R=0;
8831   REPLACE_UNLINK=0;
8832   REPLACE_UNLINKAT=0;
8833   REPLACE_USLEEP=0;
8834   REPLACE_WRITE=0;
8835   UNISTD_H_HAVE_WINSOCK2_H=0;
8836   UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS=0;
8837
8838
8839
8840   GNULIB_IOCTL=0;
8841     SYS_IOCTL_H_HAVE_WINSOCK2_H=0;
8842   SYS_IOCTL_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS=0;
8843
8844   REPLACE_IOCTL=0;
8845
8846
8847
8848
8849
8850         case "$host_os" in
8851     osf*)
8852
8853 $as_echo "#define _POSIX_PII_SOCKET 1" >>confdefs.h
8854
8855       ;;
8856   esac
8857
8858   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/socket.h> is self-contained" >&5
8859 $as_echo_n "checking whether <sys/socket.h> is self-contained... " >&6; }
8860 if ${gl_cv_header_sys_socket_h_selfcontained+:} false; then :
8861   $as_echo_n "(cached) " >&6
8862 else
8863
8864       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8865 /* end confdefs.h.  */
8866 #include <sys/socket.h>
8867 int
8868 main ()
8869 {
8870
8871   ;
8872   return 0;
8873 }
8874 _ACEOF
8875 if ac_fn_c_try_compile "$LINENO"; then :
8876   gl_cv_header_sys_socket_h_selfcontained=yes
8877 else
8878   gl_cv_header_sys_socket_h_selfcontained=no
8879 fi
8880 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8881
8882 fi
8883 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_socket_h_selfcontained" >&5
8884 $as_echo "$gl_cv_header_sys_socket_h_selfcontained" >&6; }
8885   if test $gl_cv_header_sys_socket_h_selfcontained = yes; then
8886             for ac_func in shutdown
8887 do :
8888   ac_fn_c_check_func "$LINENO" "shutdown" "ac_cv_func_shutdown"
8889 if test "x$ac_cv_func_shutdown" = xyes; then :
8890   cat >>confdefs.h <<_ACEOF
8891 #define HAVE_SHUTDOWN 1
8892 _ACEOF
8893
8894 fi
8895 done
8896
8897     if test $ac_cv_func_shutdown = yes; then
8898       { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/socket.h> defines the SHUT_* macros" >&5
8899 $as_echo_n "checking whether <sys/socket.h> defines the SHUT_* macros... " >&6; }
8900 if ${gl_cv_header_sys_socket_h_shut+:} false; then :
8901   $as_echo_n "(cached) " >&6
8902 else
8903
8904           cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8905 /* end confdefs.h.  */
8906 #include <sys/socket.h>
8907 int
8908 main ()
8909 {
8910 int a[] = { SHUT_RD, SHUT_WR, SHUT_RDWR };
8911   ;
8912   return 0;
8913 }
8914 _ACEOF
8915 if ac_fn_c_try_compile "$LINENO"; then :
8916   gl_cv_header_sys_socket_h_shut=yes
8917 else
8918   gl_cv_header_sys_socket_h_shut=no
8919 fi
8920 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8921
8922 fi
8923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_socket_h_shut" >&5
8924 $as_echo "$gl_cv_header_sys_socket_h_shut" >&6; }
8925       if test $gl_cv_header_sys_socket_h_shut = no; then
8926         SYS_SOCKET_H='sys/socket.h'
8927       fi
8928     fi
8929   fi
8930   # We need to check for ws2tcpip.h now.
8931
8932
8933
8934
8935
8936
8937
8938
8939   :
8940
8941
8942
8943
8944
8945
8946
8947
8948      if test $gl_cv_have_include_next = yes; then
8949        gl_cv_next_sys_socket_h='<'sys/socket.h'>'
8950      else
8951        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/socket.h>" >&5
8952 $as_echo_n "checking absolute name of <sys/socket.h>... " >&6; }
8953 if ${gl_cv_next_sys_socket_h+:} false; then :
8954   $as_echo_n "(cached) " >&6
8955 else
8956
8957              if test $ac_cv_header_sys_socket_h = yes; then
8958
8959
8960
8961
8962   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8963 /* end confdefs.h.  */
8964 #include <sys/socket.h>
8965 _ACEOF
8966                 case "$host_os" in
8967     aix*) gl_absname_cpp="$ac_cpp -C" ;;
8968     *)    gl_absname_cpp="$ac_cpp" ;;
8969   esac
8970
8971   case "$host_os" in
8972     mingw*)
8973                                           gl_dirsep_regex='[/\\]'
8974       ;;
8975     *)
8976       gl_dirsep_regex='\/'
8977       ;;
8978   esac
8979       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
8980   gl_header_literal_regex=`echo 'sys/socket.h' \
8981                            | sed -e "$gl_make_literal_regex_sed"`
8982   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
8983       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
8984       s|^/[^/]|//&|
8985       p
8986       q
8987     }'
8988
8989         gl_cv_absolute_sys_socket_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
8990   sed -n "$gl_absolute_header_sed"`
8991
8992            gl_header=$gl_cv_absolute_sys_socket_h
8993            gl_cv_next_sys_socket_h='"'$gl_header'"'
8994           else
8995                gl_cv_next_sys_socket_h='<'sys/socket.h'>'
8996              fi
8997
8998
8999 fi
9000 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_socket_h" >&5
9001 $as_echo "$gl_cv_next_sys_socket_h" >&6; }
9002      fi
9003      NEXT_SYS_SOCKET_H=$gl_cv_next_sys_socket_h
9004
9005      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
9006        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
9007        gl_next_as_first_directive='<'sys/socket.h'>'
9008      else
9009        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
9010        gl_next_as_first_directive=$gl_cv_next_sys_socket_h
9011      fi
9012      NEXT_AS_FIRST_DIRECTIVE_SYS_SOCKET_H=$gl_next_as_first_directive
9013
9014
9015
9016
9017   if test $ac_cv_header_sys_socket_h = yes; then
9018     HAVE_SYS_SOCKET_H=1
9019     HAVE_WS2TCPIP_H=0
9020   else
9021     HAVE_SYS_SOCKET_H=0
9022     if test $ac_cv_header_ws2tcpip_h = yes; then
9023       HAVE_WS2TCPIP_H=1
9024     else
9025       HAVE_WS2TCPIP_H=0
9026     fi
9027   fi
9028
9029
9030
9031   ac_fn_c_check_type "$LINENO" "struct sockaddr_storage" "ac_cv_type_struct_sockaddr_storage" "
9032   /* sys/types.h is not needed according to POSIX, but the
9033      sys/socket.h in i386-unknown-freebsd4.10 and
9034      powerpc-apple-darwin5.5 required it. */
9035 #include <sys/types.h>
9036 #ifdef HAVE_SYS_SOCKET_H
9037 #include <sys/socket.h>
9038 #endif
9039 #ifdef HAVE_WS2TCPIP_H
9040 #include <ws2tcpip.h>
9041 #endif
9042
9043 "
9044 if test "x$ac_cv_type_struct_sockaddr_storage" = xyes; then :
9045
9046 cat >>confdefs.h <<_ACEOF
9047 #define HAVE_STRUCT_SOCKADDR_STORAGE 1
9048 _ACEOF
9049
9050
9051 fi
9052 ac_fn_c_check_type "$LINENO" "sa_family_t" "ac_cv_type_sa_family_t" "
9053   /* sys/types.h is not needed according to POSIX, but the
9054      sys/socket.h in i386-unknown-freebsd4.10 and
9055      powerpc-apple-darwin5.5 required it. */
9056 #include <sys/types.h>
9057 #ifdef HAVE_SYS_SOCKET_H
9058 #include <sys/socket.h>
9059 #endif
9060 #ifdef HAVE_WS2TCPIP_H
9061 #include <ws2tcpip.h>
9062 #endif
9063
9064 "
9065 if test "x$ac_cv_type_sa_family_t" = xyes; then :
9066
9067 cat >>confdefs.h <<_ACEOF
9068 #define HAVE_SA_FAMILY_T 1
9069 _ACEOF
9070
9071
9072 fi
9073
9074   if test $ac_cv_type_struct_sockaddr_storage = no; then
9075     HAVE_STRUCT_SOCKADDR_STORAGE=0
9076   fi
9077   if test $ac_cv_type_sa_family_t = no; then
9078     HAVE_SA_FAMILY_T=0
9079   fi
9080   if test $ac_cv_type_struct_sockaddr_storage != no; then
9081     ac_fn_c_check_member "$LINENO" "struct sockaddr_storage" "ss_family" "ac_cv_member_struct_sockaddr_storage_ss_family" "#include <sys/types.h>
9082        #ifdef HAVE_SYS_SOCKET_H
9083        #include <sys/socket.h>
9084        #endif
9085        #ifdef HAVE_WS2TCPIP_H
9086        #include <ws2tcpip.h>
9087        #endif
9088
9089 "
9090 if test "x$ac_cv_member_struct_sockaddr_storage_ss_family" = xyes; then :
9091
9092 cat >>confdefs.h <<_ACEOF
9093 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY 1
9094 _ACEOF
9095
9096
9097 else
9098   HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY=0
9099 fi
9100
9101   fi
9102   if test $HAVE_STRUCT_SOCKADDR_STORAGE = 0 || test $HAVE_SA_FAMILY_T = 0 \
9103      || test $HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY = 0; then
9104     SYS_SOCKET_H='sys/socket.h'
9105   fi
9106
9107
9108
9109
9110   :
9111
9112
9113
9114
9115
9116   if test $ac_cv_header_sys_socket_h != yes; then
9117                     for ac_header in winsock2.h
9118 do :
9119   ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
9120 if test "x$ac_cv_header_winsock2_h" = xyes; then :
9121   cat >>confdefs.h <<_ACEOF
9122 #define HAVE_WINSOCK2_H 1
9123 _ACEOF
9124
9125 fi
9126
9127 done
9128
9129   fi
9130   if test "$ac_cv_header_winsock2_h" = yes; then
9131     HAVE_WINSOCK2_H=1
9132     UNISTD_H_HAVE_WINSOCK2_H=1
9133     SYS_IOCTL_H_HAVE_WINSOCK2_H=1
9134   else
9135     HAVE_WINSOCK2_H=0
9136   fi
9137
9138
9139
9140
9141
9142 ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
9143 if test "x$ac_cv_type_size_t" = xyes; then :
9144
9145 else
9146
9147 cat >>confdefs.h <<_ACEOF
9148 #define size_t unsigned int
9149 _ACEOF
9150
9151 fi
9152
9153 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
9154 # for constant arguments.  Useless!
9155 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
9156 $as_echo_n "checking for working alloca.h... " >&6; }
9157 if ${ac_cv_working_alloca_h+:} false; then :
9158   $as_echo_n "(cached) " >&6
9159 else
9160   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9161 /* end confdefs.h.  */
9162 #include <alloca.h>
9163 int
9164 main ()
9165 {
9166 char *p = (char *) alloca (2 * sizeof (int));
9167                           if (p) return 0;
9168   ;
9169   return 0;
9170 }
9171 _ACEOF
9172 if ac_fn_c_try_link "$LINENO"; then :
9173   ac_cv_working_alloca_h=yes
9174 else
9175   ac_cv_working_alloca_h=no
9176 fi
9177 rm -f core conftest.err conftest.$ac_objext \
9178     conftest$ac_exeext conftest.$ac_ext
9179 fi
9180 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
9181 $as_echo "$ac_cv_working_alloca_h" >&6; }
9182 if test $ac_cv_working_alloca_h = yes; then
9183
9184 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
9185
9186 fi
9187
9188 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
9189 $as_echo_n "checking for alloca... " >&6; }
9190 if ${ac_cv_func_alloca_works+:} false; then :
9191   $as_echo_n "(cached) " >&6
9192 else
9193   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9194 /* end confdefs.h.  */
9195 #ifdef __GNUC__
9196 # define alloca __builtin_alloca
9197 #else
9198 # ifdef _MSC_VER
9199 #  include <malloc.h>
9200 #  define alloca _alloca
9201 # else
9202 #  ifdef HAVE_ALLOCA_H
9203 #   include <alloca.h>
9204 #  else
9205 #   ifdef _AIX
9206  #pragma alloca
9207 #   else
9208 #    ifndef alloca /* predefined by HP cc +Olibcalls */
9209 void *alloca (size_t);
9210 #    endif
9211 #   endif
9212 #  endif
9213 # endif
9214 #endif
9215
9216 int
9217 main ()
9218 {
9219 char *p = (char *) alloca (1);
9220                                     if (p) return 0;
9221   ;
9222   return 0;
9223 }
9224 _ACEOF
9225 if ac_fn_c_try_link "$LINENO"; then :
9226   ac_cv_func_alloca_works=yes
9227 else
9228   ac_cv_func_alloca_works=no
9229 fi
9230 rm -f core conftest.err conftest.$ac_objext \
9231     conftest$ac_exeext conftest.$ac_ext
9232 fi
9233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
9234 $as_echo "$ac_cv_func_alloca_works" >&6; }
9235
9236 if test $ac_cv_func_alloca_works = yes; then
9237
9238 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
9239
9240 else
9241   # The SVR3 libPW and SVR4 libucb both contain incompatible functions
9242 # that cause trouble.  Some versions do not even contain alloca or
9243 # contain a buggy version.  If you still want to use their alloca,
9244 # use ar to extract alloca.o from them instead of compiling alloca.c.
9245
9246
9247
9248
9249
9250 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
9251
9252 $as_echo "#define C_ALLOCA 1" >>confdefs.h
9253
9254
9255 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5
9256 $as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; }
9257 if ${ac_cv_os_cray+:} false; then :
9258   $as_echo_n "(cached) " >&6
9259 else
9260   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9261 /* end confdefs.h.  */
9262 #if defined CRAY && ! defined CRAY2
9263 webecray
9264 #else
9265 wenotbecray
9266 #endif
9267
9268 _ACEOF
9269 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9270   $EGREP "webecray" >/dev/null 2>&1; then :
9271   ac_cv_os_cray=yes
9272 else
9273   ac_cv_os_cray=no
9274 fi
9275 rm -f conftest*
9276
9277 fi
9278 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
9279 $as_echo "$ac_cv_os_cray" >&6; }
9280 if test $ac_cv_os_cray = yes; then
9281   for ac_func in _getb67 GETB67 getb67; do
9282     as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
9283 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
9284 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
9285
9286 cat >>confdefs.h <<_ACEOF
9287 #define CRAY_STACKSEG_END $ac_func
9288 _ACEOF
9289
9290     break
9291 fi
9292
9293   done
9294 fi
9295
9296 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
9297 $as_echo_n "checking stack direction for C alloca... " >&6; }
9298 if ${ac_cv_c_stack_direction+:} false; then :
9299   $as_echo_n "(cached) " >&6
9300 else
9301   if test "$cross_compiling" = yes; then :
9302   ac_cv_c_stack_direction=0
9303 else
9304   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9305 /* end confdefs.h.  */
9306 $ac_includes_default
9307 int
9308 find_stack_direction (int *addr, int depth)
9309 {
9310   int dir, dummy = 0;
9311   if (! addr)
9312     addr = &dummy;
9313   *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
9314   dir = depth ? find_stack_direction (addr, depth - 1) : 0;
9315   return dir + dummy;
9316 }
9317
9318 int
9319 main (int argc, char **argv)
9320 {
9321   return find_stack_direction (0, argc + !argv + 20) < 0;
9322 }
9323 _ACEOF
9324 if ac_fn_c_try_run "$LINENO"; then :
9325   ac_cv_c_stack_direction=1
9326 else
9327   ac_cv_c_stack_direction=-1
9328 fi
9329 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9330   conftest.$ac_objext conftest.beam conftest.$ac_ext
9331 fi
9332
9333 fi
9334 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
9335 $as_echo "$ac_cv_c_stack_direction" >&6; }
9336 cat >>confdefs.h <<_ACEOF
9337 #define STACK_DIRECTION $ac_cv_c_stack_direction
9338 _ACEOF
9339
9340
9341 fi
9342
9343
9344   GNULIB_INET_NTOP=0;
9345   GNULIB_INET_PTON=0;
9346     HAVE_DECL_INET_NTOP=1;
9347   HAVE_DECL_INET_PTON=1;
9348   REPLACE_INET_NTOP=0;
9349   REPLACE_INET_PTON=0;
9350
9351
9352
9353
9354
9355
9356
9357
9358
9359
9360
9361
9362
9363   :
9364
9365
9366
9367
9368
9369   if test $ac_cv_header_features_h = yes; then
9370     HAVE_FEATURES_H=1
9371   else
9372     HAVE_FEATURES_H=0
9373   fi
9374
9375
9376 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
9377 $as_echo_n "checking for C/C++ restrict keyword... " >&6; }
9378 if ${ac_cv_c_restrict+:} false; then :
9379   $as_echo_n "(cached) " >&6
9380 else
9381   ac_cv_c_restrict=no
9382    # The order here caters to the fact that C++ does not require restrict.
9383    for ac_kw in __restrict __restrict__ _Restrict restrict; do
9384      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9385 /* end confdefs.h.  */
9386 typedef int * int_ptr;
9387         int foo (int_ptr $ac_kw ip) {
9388         return ip[0];
9389        }
9390 int
9391 main ()
9392 {
9393 int s[1];
9394         int * $ac_kw t = s;
9395         t[0] = 0;
9396         return foo(t)
9397   ;
9398   return 0;
9399 }
9400 _ACEOF
9401 if ac_fn_c_try_compile "$LINENO"; then :
9402   ac_cv_c_restrict=$ac_kw
9403 fi
9404 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9405      test "$ac_cv_c_restrict" != no && break
9406    done
9407
9408 fi
9409 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
9410 $as_echo "$ac_cv_c_restrict" >&6; }
9411
9412  case $ac_cv_c_restrict in
9413    restrict) ;;
9414    no) $as_echo "#define restrict /**/" >>confdefs.h
9415  ;;
9416    *)  cat >>confdefs.h <<_ACEOF
9417 #define restrict $ac_cv_c_restrict
9418 _ACEOF
9419  ;;
9420  esac
9421
9422
9423   GNULIB_BTOWC=0;
9424   GNULIB_WCTOB=0;
9425   GNULIB_MBSINIT=0;
9426   GNULIB_MBRTOWC=0;
9427   GNULIB_MBRLEN=0;
9428   GNULIB_MBSRTOWCS=0;
9429   GNULIB_MBSNRTOWCS=0;
9430   GNULIB_WCRTOMB=0;
9431   GNULIB_WCSRTOMBS=0;
9432   GNULIB_WCSNRTOMBS=0;
9433   GNULIB_WCWIDTH=0;
9434   GNULIB_WMEMCHR=0;
9435   GNULIB_WMEMCMP=0;
9436   GNULIB_WMEMCPY=0;
9437   GNULIB_WMEMMOVE=0;
9438   GNULIB_WMEMSET=0;
9439   GNULIB_WCSLEN=0;
9440   GNULIB_WCSNLEN=0;
9441   GNULIB_WCSCPY=0;
9442   GNULIB_WCPCPY=0;
9443   GNULIB_WCSNCPY=0;
9444   GNULIB_WCPNCPY=0;
9445   GNULIB_WCSCAT=0;
9446   GNULIB_WCSNCAT=0;
9447   GNULIB_WCSCMP=0;
9448   GNULIB_WCSNCMP=0;
9449   GNULIB_WCSCASECMP=0;
9450   GNULIB_WCSNCASECMP=0;
9451   GNULIB_WCSCOLL=0;
9452   GNULIB_WCSXFRM=0;
9453   GNULIB_WCSDUP=0;
9454   GNULIB_WCSCHR=0;
9455   GNULIB_WCSRCHR=0;
9456   GNULIB_WCSCSPN=0;
9457   GNULIB_WCSSPN=0;
9458   GNULIB_WCSPBRK=0;
9459   GNULIB_WCSSTR=0;
9460   GNULIB_WCSTOK=0;
9461   GNULIB_WCSWIDTH=0;
9462     HAVE_BTOWC=1;
9463   HAVE_MBSINIT=1;
9464   HAVE_MBRTOWC=1;
9465   HAVE_MBRLEN=1;
9466   HAVE_MBSRTOWCS=1;
9467   HAVE_MBSNRTOWCS=1;
9468   HAVE_WCRTOMB=1;
9469   HAVE_WCSRTOMBS=1;
9470   HAVE_WCSNRTOMBS=1;
9471   HAVE_WMEMCHR=1;
9472   HAVE_WMEMCMP=1;
9473   HAVE_WMEMCPY=1;
9474   HAVE_WMEMMOVE=1;
9475   HAVE_WMEMSET=1;
9476   HAVE_WCSLEN=1;
9477   HAVE_WCSNLEN=1;
9478   HAVE_WCSCPY=1;
9479   HAVE_WCPCPY=1;
9480   HAVE_WCSNCPY=1;
9481   HAVE_WCPNCPY=1;
9482   HAVE_WCSCAT=1;
9483   HAVE_WCSNCAT=1;
9484   HAVE_WCSCMP=1;
9485   HAVE_WCSNCMP=1;
9486   HAVE_WCSCASECMP=1;
9487   HAVE_WCSNCASECMP=1;
9488   HAVE_WCSCOLL=1;
9489   HAVE_WCSXFRM=1;
9490   HAVE_WCSDUP=1;
9491   HAVE_WCSCHR=1;
9492   HAVE_WCSRCHR=1;
9493   HAVE_WCSCSPN=1;
9494   HAVE_WCSSPN=1;
9495   HAVE_WCSPBRK=1;
9496   HAVE_WCSSTR=1;
9497   HAVE_WCSTOK=1;
9498   HAVE_WCSWIDTH=1;
9499   HAVE_DECL_WCTOB=1;
9500   HAVE_DECL_WCWIDTH=1;
9501   REPLACE_MBSTATE_T=0;
9502   REPLACE_BTOWC=0;
9503   REPLACE_WCTOB=0;
9504   REPLACE_MBSINIT=0;
9505   REPLACE_MBRTOWC=0;
9506   REPLACE_MBRLEN=0;
9507   REPLACE_MBSRTOWCS=0;
9508   REPLACE_MBSNRTOWCS=0;
9509   REPLACE_WCRTOMB=0;
9510   REPLACE_WCSRTOMBS=0;
9511   REPLACE_WCSNRTOMBS=0;
9512   REPLACE_WCWIDTH=0;
9513   REPLACE_WCSWIDTH=0;
9514
9515
9516             { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <wchar.h> uses 'inline' correctly" >&5
9517 $as_echo_n "checking whether <wchar.h> uses 'inline' correctly... " >&6; }
9518 if ${gl_cv_header_wchar_h_correct_inline+:} false; then :
9519   $as_echo_n "(cached) " >&6
9520 else
9521   gl_cv_header_wchar_h_correct_inline=yes
9522      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9523 /* end confdefs.h.  */
9524
9525        #define wcstod renamed_wcstod
9526 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
9527    <wchar.h>.
9528    BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
9529    included before <wchar.h>.  */
9530 #include <stddef.h>
9531 #include <stdio.h>
9532 #include <time.h>
9533 #include <wchar.h>
9534 extern int zero (void);
9535 int main () { return zero(); }
9536
9537 _ACEOF
9538      if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9539   (eval $ac_compile) 2>&5
9540   ac_status=$?
9541   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9542   test $ac_status = 0; }; then
9543        mv conftest.$ac_objext conftest1.$ac_objext
9544        cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9545 /* end confdefs.h.  */
9546
9547          #define wcstod renamed_wcstod
9548 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
9549    <wchar.h>.
9550    BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
9551    included before <wchar.h>.  */
9552 #include <stddef.h>
9553 #include <stdio.h>
9554 #include <time.h>
9555 #include <wchar.h>
9556 int zero (void) { return 0; }
9557
9558 _ACEOF
9559        if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
9560   (eval $ac_compile) 2>&5
9561   ac_status=$?
9562   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9563   test $ac_status = 0; }; then
9564          mv conftest.$ac_objext conftest2.$ac_objext
9565          if $CC -o conftest$ac_exeext $CFLAGS $LDFLAGS conftest1.$ac_objext conftest2.$ac_objext $LIBS >&5 2>&1; then
9566            :
9567          else
9568            gl_cv_header_wchar_h_correct_inline=no
9569          fi
9570        fi
9571      fi
9572      rm -f conftest1.$ac_objext conftest2.$ac_objext conftest$ac_exeext
9573
9574 fi
9575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_wchar_h_correct_inline" >&5
9576 $as_echo "$gl_cv_header_wchar_h_correct_inline" >&6; }
9577   if test $gl_cv_header_wchar_h_correct_inline = no; then
9578     as_fn_error $? "<wchar.h> cannot be used with this compiler ($CC $CFLAGS $CPPFLAGS).
9579 This is a known interoperability problem of glibc <= 2.5 with gcc >= 4.3 in
9580 C99 mode. You have four options:
9581   - Add the flag -fgnu89-inline to CC and reconfigure, or
9582   - Fix your include files, using parts of
9583     <http://sourceware.org/git/?p=glibc.git;a=commitdiff;h=b037a293a48718af30d706c2e18c929d0e69a621>, or
9584   - Use a gcc version older than 4.3, or
9585   - Don't use the flags -std=c99 or -std=gnu99.
9586 Configuration aborted." "$LINENO" 5
9587   fi
9588
9589
9590
9591
9592
9593   for ac_func in $gl_func_list
9594 do :
9595   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
9596 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
9597 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
9598   cat >>confdefs.h <<_ACEOF
9599 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
9600 _ACEOF
9601
9602 fi
9603 done
9604
9605
9606
9607
9608
9609
9610   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
9611 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
9612 if ${am_cv_langinfo_codeset+:} false; then :
9613   $as_echo_n "(cached) " >&6
9614 else
9615   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9616 /* end confdefs.h.  */
9617 #include <langinfo.h>
9618 int
9619 main ()
9620 {
9621 char* cs = nl_langinfo(CODESET); return !cs;
9622   ;
9623   return 0;
9624 }
9625 _ACEOF
9626 if ac_fn_c_try_link "$LINENO"; then :
9627   am_cv_langinfo_codeset=yes
9628 else
9629   am_cv_langinfo_codeset=no
9630 fi
9631 rm -f core conftest.err conftest.$ac_objext \
9632     conftest$ac_exeext conftest.$ac_ext
9633
9634 fi
9635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_langinfo_codeset" >&5
9636 $as_echo "$am_cv_langinfo_codeset" >&6; }
9637   if test $am_cv_langinfo_codeset = yes; then
9638
9639 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
9640
9641   fi
9642
9643
9644
9645
9646   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a traditional french locale" >&5
9647 $as_echo_n "checking for a traditional french locale... " >&6; }
9648 if ${gt_cv_locale_fr+:} false; then :
9649   $as_echo_n "(cached) " >&6
9650 else
9651
9652     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9653 /* end confdefs.h.  */
9654
9655 #include <locale.h>
9656 #include <time.h>
9657 #if HAVE_LANGINFO_CODESET
9658 # include <langinfo.h>
9659 #endif
9660 #include <stdlib.h>
9661 #include <string.h>
9662 struct tm t;
9663 char buf[16];
9664 int main () {
9665   /* Check whether the given locale name is recognized by the system.  */
9666 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
9667   /* On native Windows, setlocale(category, "") looks at the system settings,
9668      not at the environment variables.  Also, when an encoding suffix such
9669      as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
9670      category of the locale to "C".  */
9671   if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
9672       || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
9673     return 1;
9674 #else
9675   if (setlocale (LC_ALL, "") == NULL) return 1;
9676 #endif
9677   /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
9678      On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
9679      is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
9680      On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
9681      succeeds but then nl_langinfo(CODESET) is "646". In this situation,
9682      some unit tests fail.
9683      On MirBSD 10, when an unsupported locale is specified, setlocale()
9684      succeeds but then nl_langinfo(CODESET) is "UTF-8".  */
9685 #if HAVE_LANGINFO_CODESET
9686   {
9687     const char *cs = nl_langinfo (CODESET);
9688     if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
9689         || strcmp (cs, "UTF-8") == 0)
9690       return 1;
9691   }
9692 #endif
9693 #ifdef __CYGWIN__
9694   /* On Cygwin, avoid locale names without encoding suffix, because the
9695      locale_charset() function relies on the encoding suffix.  Note that
9696      LC_ALL is set on the command line.  */
9697   if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
9698 #endif
9699   /* Check whether in the abbreviation of the second month, the second
9700      character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is only
9701      one byte long. This excludes the UTF-8 encoding.  */
9702   t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
9703   if (strftime (buf, sizeof (buf), "%b", &t) < 3 || buf[2] != 'v') return 1;
9704 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy.  */
9705   /* Check whether the decimal separator is a comma.
9706      On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
9707      are nl_langinfo(RADIXCHAR) are both ".".  */
9708   if (localeconv () ->decimal_point[0] != ',') return 1;
9709 #endif
9710   return 0;
9711 }
9712
9713 _ACEOF
9714     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
9715   (eval $ac_link) 2>&5
9716   ac_status=$?
9717   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
9718   test $ac_status = 0; } && test -s conftest$ac_exeext; then
9719       case "$host_os" in
9720         # Handle native Windows specially, because there setlocale() interprets
9721         # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
9722         # "fr" or "fra" as "French" or "French_France.1252",
9723         # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
9724         # "ja" as "Japanese" or "Japanese_Japan.932",
9725         # and similar.
9726         mingw*)
9727           # Test for the native Windows locale name.
9728           if (LC_ALL=French_France.1252 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
9729             gt_cv_locale_fr=French_France.1252
9730           else
9731             # None found.
9732             gt_cv_locale_fr=none
9733           fi
9734           ;;
9735         *)
9736           # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
9737           # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
9738           # configure script would override the LC_ALL setting. Likewise for
9739           # LC_CTYPE, which is also set at the beginning of the configure script.
9740           # Test for the usual locale name.
9741           if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
9742             gt_cv_locale_fr=fr_FR
9743           else
9744             # Test for the locale name with explicit encoding suffix.
9745             if (LC_ALL=fr_FR.ISO-8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
9746               gt_cv_locale_fr=fr_FR.ISO-8859-1
9747             else
9748               # Test for the AIX, OSF/1, FreeBSD, NetBSD, OpenBSD locale name.
9749               if (LC_ALL=fr_FR.ISO8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
9750                 gt_cv_locale_fr=fr_FR.ISO8859-1
9751               else
9752                 # Test for the HP-UX locale name.
9753                 if (LC_ALL=fr_FR.iso88591 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
9754                   gt_cv_locale_fr=fr_FR.iso88591
9755                 else
9756                   # Test for the Solaris 7 locale name.
9757                   if (LC_ALL=fr LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
9758                     gt_cv_locale_fr=fr
9759                   else
9760                     # None found.
9761                     gt_cv_locale_fr=none
9762                   fi
9763                 fi
9764               fi
9765             fi
9766           fi
9767           ;;
9768       esac
9769     fi
9770     rm -fr conftest*
9771
9772 fi
9773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr" >&5
9774 $as_echo "$gt_cv_locale_fr" >&6; }
9775   LOCALE_FR=$gt_cv_locale_fr
9776
9777
9778
9779   GNULIB__EXIT=0;
9780   GNULIB_ATOLL=0;
9781   GNULIB_CALLOC_POSIX=0;
9782   GNULIB_CANONICALIZE_FILE_NAME=0;
9783   GNULIB_GETLOADAVG=0;
9784   GNULIB_GETSUBOPT=0;
9785   GNULIB_GRANTPT=0;
9786   GNULIB_MALLOC_POSIX=0;
9787   GNULIB_MBTOWC=0;
9788   GNULIB_MKDTEMP=0;
9789   GNULIB_MKOSTEMP=0;
9790   GNULIB_MKOSTEMPS=0;
9791   GNULIB_MKSTEMP=0;
9792   GNULIB_MKSTEMPS=0;
9793   GNULIB_POSIX_OPENPT=0;
9794   GNULIB_PTSNAME=0;
9795   GNULIB_PTSNAME_R=0;
9796   GNULIB_PUTENV=0;
9797   GNULIB_RANDOM=0;
9798   GNULIB_RANDOM_R=0;
9799   GNULIB_REALLOC_POSIX=0;
9800   GNULIB_REALPATH=0;
9801   GNULIB_RPMATCH=0;
9802   GNULIB_SECURE_GETENV=0;
9803   GNULIB_SETENV=0;
9804   GNULIB_STRTOD=0;
9805   GNULIB_STRTOLL=0;
9806   GNULIB_STRTOULL=0;
9807   GNULIB_SYSTEM_POSIX=0;
9808   GNULIB_UNLOCKPT=0;
9809   GNULIB_UNSETENV=0;
9810   GNULIB_WCTOMB=0;
9811     HAVE__EXIT=1;
9812   HAVE_ATOLL=1;
9813   HAVE_CANONICALIZE_FILE_NAME=1;
9814   HAVE_DECL_GETLOADAVG=1;
9815   HAVE_GETSUBOPT=1;
9816   HAVE_GRANTPT=1;
9817   HAVE_MKDTEMP=1;
9818   HAVE_MKOSTEMP=1;
9819   HAVE_MKOSTEMPS=1;
9820   HAVE_MKSTEMP=1;
9821   HAVE_MKSTEMPS=1;
9822   HAVE_POSIX_OPENPT=1;
9823   HAVE_PTSNAME=1;
9824   HAVE_PTSNAME_R=1;
9825   HAVE_RANDOM=1;
9826   HAVE_RANDOM_H=1;
9827   HAVE_RANDOM_R=1;
9828   HAVE_REALPATH=1;
9829   HAVE_RPMATCH=1;
9830   HAVE_SECURE_GETENV=1;
9831   HAVE_SETENV=1;
9832   HAVE_DECL_SETENV=1;
9833   HAVE_STRTOD=1;
9834   HAVE_STRTOLL=1;
9835   HAVE_STRTOULL=1;
9836   HAVE_STRUCT_RANDOM_DATA=1;
9837   HAVE_SYS_LOADAVG_H=0;
9838   HAVE_UNLOCKPT=1;
9839   HAVE_DECL_UNSETENV=1;
9840   REPLACE_CALLOC=0;
9841   REPLACE_CANONICALIZE_FILE_NAME=0;
9842   REPLACE_MALLOC=0;
9843   REPLACE_MBTOWC=0;
9844   REPLACE_MKSTEMP=0;
9845   REPLACE_PTSNAME=0;
9846   REPLACE_PTSNAME_R=0;
9847   REPLACE_PUTENV=0;
9848   REPLACE_RANDOM_R=0;
9849   REPLACE_REALLOC=0;
9850   REPLACE_REALPATH=0;
9851   REPLACE_SETENV=0;
9852   REPLACE_STRTOD=0;
9853   REPLACE_UNSETENV=0;
9854   REPLACE_WCTOMB=0;
9855
9856
9857   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether malloc, realloc, calloc are POSIX compliant" >&5
9858 $as_echo_n "checking whether malloc, realloc, calloc are POSIX compliant... " >&6; }
9859 if ${gl_cv_func_malloc_posix+:} false; then :
9860   $as_echo_n "(cached) " >&6
9861 else
9862
9863                         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9864 /* end confdefs.h.  */
9865
9866 int
9867 main ()
9868 {
9869 #if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
9870              choke me
9871              #endif
9872
9873   ;
9874   return 0;
9875 }
9876 _ACEOF
9877 if ac_fn_c_try_compile "$LINENO"; then :
9878   gl_cv_func_malloc_posix=yes
9879 else
9880   gl_cv_func_malloc_posix=no
9881 fi
9882 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9883
9884 fi
9885 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_malloc_posix" >&5
9886 $as_echo "$gl_cv_func_malloc_posix" >&6; }
9887
9888
9889
9890
9891
9892
9893
9894
9895
9896
9897
9898
9899
9900
9901
9902
9903
9904
9905   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether // is distinct from /" >&5
9906 $as_echo_n "checking whether // is distinct from /... " >&6; }
9907 if ${gl_cv_double_slash_root+:} false; then :
9908   $as_echo_n "(cached) " >&6
9909 else
9910    if test x"$cross_compiling" = xyes ; then
9911         # When cross-compiling, there is no way to tell whether // is special
9912         # short of a list of hosts.  However, the only known hosts to date
9913         # that have a distinct // are Apollo DomainOS (too old to port to),
9914         # Cygwin, and z/OS.  If anyone knows of another system for which // has
9915         # special semantics and is distinct from /, please report it to
9916         # <bug-gnulib@gnu.org>.
9917         case $host in
9918           *-cygwin | i370-ibm-openedition)
9919             gl_cv_double_slash_root=yes ;;
9920           *)
9921             # Be optimistic and assume that / and // are the same when we
9922             # don't know.
9923             gl_cv_double_slash_root='unknown, assuming no' ;;
9924         esac
9925       else
9926         set x `ls -di / // 2>/dev/null`
9927         if test "$2" = "$4" && wc //dev/null >/dev/null 2>&1; then
9928           gl_cv_double_slash_root=no
9929         else
9930           gl_cv_double_slash_root=yes
9931         fi
9932       fi
9933 fi
9934 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_double_slash_root" >&5
9935 $as_echo "$gl_cv_double_slash_root" >&6; }
9936   if test "$gl_cv_double_slash_root" = yes; then
9937
9938 $as_echo "#define DOUBLE_SLASH_IS_DISTINCT_ROOT 1" >>confdefs.h
9939
9940   fi
9941
9942
9943
9944
9945
9946
9947
9948
9949   :
9950
9951
9952
9953
9954
9955      { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether realpath works" >&5
9956 $as_echo_n "checking whether realpath works... " >&6; }
9957 if ${gl_cv_func_realpath_works+:} false; then :
9958   $as_echo_n "(cached) " >&6
9959 else
9960
9961     touch conftest.a
9962     mkdir conftest.d
9963     if test "$cross_compiling" = yes; then :
9964   case "$host_os" in
9965                        # Guess yes on glibc systems.
9966         *-gnu* | gnu*) gl_cv_func_realpath_works="guessing yes" ;;
9967                        # If we don't know, assume the worst.
9968         *)             gl_cv_func_realpath_works="guessing no" ;;
9969       esac
9970
9971 else
9972   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9973 /* end confdefs.h.  */
9974
9975
9976
9977 #include <stdlib.h>
9978 #if defined __MACH__ && defined __APPLE__
9979 /* Avoid a crash on Mac OS X.  */
9980 #include <mach/mach.h>
9981 #include <mach/mach_error.h>
9982 #include <mach/thread_status.h>
9983 #include <mach/exception.h>
9984 #include <mach/task.h>
9985 #include <pthread.h>
9986 /* The exception port on which our thread listens.  */
9987 static mach_port_t our_exception_port;
9988 /* The main function of the thread listening for exceptions of type
9989    EXC_BAD_ACCESS.  */
9990 static void *
9991 mach_exception_thread (void *arg)
9992 {
9993   /* Buffer for a message to be received.  */
9994   struct {
9995     mach_msg_header_t head;
9996     mach_msg_body_t msgh_body;
9997     char data[1024];
9998   } msg;
9999   mach_msg_return_t retval;
10000   /* Wait for a message on the exception port.  */
10001   retval = mach_msg (&msg.head, MACH_RCV_MSG | MACH_RCV_LARGE, 0, sizeof (msg),
10002                      our_exception_port, MACH_MSG_TIMEOUT_NONE, MACH_PORT_NULL);
10003   if (retval != MACH_MSG_SUCCESS)
10004     abort ();
10005   exit (1);
10006 }
10007 static void
10008 nocrash_init (void)
10009 {
10010   mach_port_t self = mach_task_self ();
10011   /* Allocate a port on which the thread shall listen for exceptions.  */
10012   if (mach_port_allocate (self, MACH_PORT_RIGHT_RECEIVE, &our_exception_port)
10013       == KERN_SUCCESS) {
10014     /* See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/mach_port_insert_right.html.  */
10015     if (mach_port_insert_right (self, our_exception_port, our_exception_port,
10016                                 MACH_MSG_TYPE_MAKE_SEND)
10017         == KERN_SUCCESS) {
10018       /* The exceptions we want to catch.  Only EXC_BAD_ACCESS is interesting
10019          for us.  */
10020       exception_mask_t mask = EXC_MASK_BAD_ACCESS;
10021       /* Create the thread listening on the exception port.  */
10022       pthread_attr_t attr;
10023       pthread_t thread;
10024       if (pthread_attr_init (&attr) == 0
10025           && pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED) == 0
10026           && pthread_create (&thread, &attr, mach_exception_thread, NULL) == 0) {
10027         pthread_attr_destroy (&attr);
10028         /* Replace the exception port info for these exceptions with our own.
10029            Note that we replace the exception port for the entire task, not only
10030            for a particular thread.  This has the effect that when our exception
10031            port gets the message, the thread specific exception port has already
10032            been asked, and we don't need to bother about it.
10033            See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/task_set_exception_ports.html.  */
10034         task_set_exception_ports (self, mask, our_exception_port,
10035                                   EXCEPTION_DEFAULT, MACHINE_THREAD_STATE);
10036       }
10037     }
10038   }
10039 }
10040 #elif (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
10041 /* Avoid a crash on native Windows.  */
10042 #define WIN32_LEAN_AND_MEAN
10043 #include <windows.h>
10044 #include <winerror.h>
10045 static LONG WINAPI
10046 exception_filter (EXCEPTION_POINTERS *ExceptionInfo)
10047 {
10048   switch (ExceptionInfo->ExceptionRecord->ExceptionCode)
10049     {
10050     case EXCEPTION_ACCESS_VIOLATION:
10051     case EXCEPTION_IN_PAGE_ERROR:
10052     case EXCEPTION_STACK_OVERFLOW:
10053     case EXCEPTION_GUARD_PAGE:
10054     case EXCEPTION_PRIV_INSTRUCTION:
10055     case EXCEPTION_ILLEGAL_INSTRUCTION:
10056     case EXCEPTION_DATATYPE_MISALIGNMENT:
10057     case EXCEPTION_ARRAY_BOUNDS_EXCEEDED:
10058     case EXCEPTION_NONCONTINUABLE_EXCEPTION:
10059       exit (1);
10060     }
10061   return EXCEPTION_CONTINUE_SEARCH;
10062 }
10063 static void
10064 nocrash_init (void)
10065 {
10066   SetUnhandledExceptionFilter ((LPTOP_LEVEL_EXCEPTION_FILTER) exception_filter);
10067 }
10068 #else
10069 /* Avoid a crash on POSIX systems.  */
10070 #include <signal.h>
10071 /* A POSIX signal handler.  */
10072 static void
10073 exception_handler (int sig)
10074 {
10075   exit (1);
10076 }
10077 static void
10078 nocrash_init (void)
10079 {
10080 #ifdef SIGSEGV
10081   signal (SIGSEGV, exception_handler);
10082 #endif
10083 #ifdef SIGBUS
10084   signal (SIGBUS, exception_handler);
10085 #endif
10086 }
10087 #endif
10088
10089         #include <stdlib.h>
10090         #include <string.h>
10091
10092 int
10093 main ()
10094 {
10095
10096         int result = 0;
10097         {
10098           char *name = realpath ("conftest.a", NULL);
10099           if (!(name && *name == '/'))
10100             result |= 1;
10101         }
10102         {
10103           char *name = realpath ("conftest.b/../conftest.a", NULL);
10104           if (name != NULL)
10105             result |= 2;
10106         }
10107         {
10108           char *name = realpath ("conftest.a/", NULL);
10109           if (name != NULL)
10110             result |= 4;
10111         }
10112         {
10113           char *name1 = realpath (".", NULL);
10114           char *name2 = realpath ("conftest.d//./..", NULL);
10115           if (strcmp (name1, name2) != 0)
10116             result |= 8;
10117         }
10118         return result;
10119
10120   ;
10121   return 0;
10122 }
10123
10124 _ACEOF
10125 if ac_fn_c_try_run "$LINENO"; then :
10126   gl_cv_func_realpath_works=yes
10127 else
10128   gl_cv_func_realpath_works=no
10129 fi
10130 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10131   conftest.$ac_objext conftest.beam conftest.$ac_ext
10132 fi
10133
10134     rm -rf conftest.a conftest.d
10135
10136 fi
10137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_realpath_works" >&5
10138 $as_echo "$gl_cv_func_realpath_works" >&6; }
10139   case "$gl_cv_func_realpath_works" in
10140     *yes)
10141
10142 $as_echo "#define FUNC_REALPATH_WORKS 1" >>confdefs.h
10143
10144       ;;
10145   esac
10146
10147
10148
10149
10150
10151
10152
10153
10154
10155   :
10156
10157
10158
10159
10160
10161
10162
10163
10164
10165
10166
10167
10168
10169
10170   :
10171
10172
10173
10174
10175
10176
10177
10178
10179
10180
10181
10182 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5
10183 $as_echo_n "checking for uid_t in sys/types.h... " >&6; }
10184 if ${ac_cv_type_uid_t+:} false; then :
10185   $as_echo_n "(cached) " >&6
10186 else
10187   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10188 /* end confdefs.h.  */
10189 #include <sys/types.h>
10190
10191 _ACEOF
10192 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10193   $EGREP "uid_t" >/dev/null 2>&1; then :
10194   ac_cv_type_uid_t=yes
10195 else
10196   ac_cv_type_uid_t=no
10197 fi
10198 rm -f conftest*
10199
10200 fi
10201 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5
10202 $as_echo "$ac_cv_type_uid_t" >&6; }
10203 if test $ac_cv_type_uid_t = no; then
10204
10205 $as_echo "#define uid_t int" >>confdefs.h
10206
10207
10208 $as_echo "#define gid_t int" >>confdefs.h
10209
10210 fi
10211
10212
10213       for ac_header in unistd.h
10214 do :
10215   ac_fn_c_check_header_mongrel "$LINENO" "unistd.h" "ac_cv_header_unistd_h" "$ac_includes_default"
10216 if test "x$ac_cv_header_unistd_h" = xyes; then :
10217   cat >>confdefs.h <<_ACEOF
10218 #define HAVE_UNISTD_H 1
10219 _ACEOF
10220
10221 fi
10222
10223 done
10224
10225   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working chown" >&5
10226 $as_echo_n "checking for working chown... " >&6; }
10227 if ${ac_cv_func_chown_works+:} false; then :
10228   $as_echo_n "(cached) " >&6
10229 else
10230   if test "$cross_compiling" = yes; then :
10231   case "$host_os" in # ((
10232                   # Guess yes on glibc systems.
10233           *-gnu*) ac_cv_func_chown_works=yes ;;
10234                   # If we don't know, assume the worst.
10235           *)      ac_cv_func_chown_works=no ;;
10236         esac
10237
10238 else
10239   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10240 /* end confdefs.h.  */
10241 $ac_includes_default
10242            #include <fcntl.h>
10243
10244 int
10245 main ()
10246 {
10247
10248             char *f = "conftest.chown";
10249             struct stat before, after;
10250
10251             if (creat (f, 0600) < 0)
10252               return 1;
10253             if (stat (f, &before) < 0)
10254               return 1;
10255             if (chown (f, (uid_t) -1, (gid_t) -1) == -1)
10256               return 1;
10257             if (stat (f, &after) < 0)
10258               return 1;
10259             return ! (before.st_uid == after.st_uid && before.st_gid == after.st_gid);
10260
10261   ;
10262   return 0;
10263 }
10264
10265 _ACEOF
10266 if ac_fn_c_try_run "$LINENO"; then :
10267   ac_cv_func_chown_works=yes
10268 else
10269   ac_cv_func_chown_works=no
10270 fi
10271 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10272   conftest.$ac_objext conftest.beam conftest.$ac_ext
10273 fi
10274
10275      rm -f conftest.chown
10276
10277 fi
10278 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_chown_works" >&5
10279 $as_echo "$ac_cv_func_chown_works" >&6; }
10280   if test $ac_cv_func_chown_works = yes; then
10281
10282 $as_echo "#define HAVE_CHOWN 1" >>confdefs.h
10283
10284   fi
10285
10286
10287   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether chown dereferences symlinks" >&5
10288 $as_echo_n "checking whether chown dereferences symlinks... " >&6; }
10289 if ${gl_cv_func_chown_follows_symlink+:} false; then :
10290   $as_echo_n "(cached) " >&6
10291 else
10292
10293       if test "$cross_compiling" = yes; then :
10294   gl_cv_func_chown_follows_symlink=yes
10295
10296 else
10297   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10298 /* end confdefs.h.  */
10299
10300 #include <unistd.h>
10301 #include <stdlib.h>
10302 #include <errno.h>
10303
10304         int
10305         main ()
10306         {
10307           int result = 0;
10308           char const *dangling_symlink = "conftest.dangle";
10309
10310           unlink (dangling_symlink);
10311           if (symlink ("conftest.no-such", dangling_symlink))
10312             abort ();
10313
10314           /* Exit successfully on a conforming system,
10315              i.e., where chown must fail with ENOENT.  */
10316           if (chown (dangling_symlink, getuid (), getgid ()) == 0)
10317             result |= 1;
10318           if (errno != ENOENT)
10319             result |= 2;
10320           return result;
10321         }
10322
10323 _ACEOF
10324 if ac_fn_c_try_run "$LINENO"; then :
10325   gl_cv_func_chown_follows_symlink=yes
10326 else
10327   gl_cv_func_chown_follows_symlink=no
10328 fi
10329 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10330   conftest.$ac_objext conftest.beam conftest.$ac_ext
10331 fi
10332
10333
10334
10335 fi
10336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_chown_follows_symlink" >&5
10337 $as_echo "$gl_cv_func_chown_follows_symlink" >&6; }
10338
10339   if test $gl_cv_func_chown_follows_symlink = no; then
10340
10341 $as_echo "#define CHOWN_MODIFIES_SYMLINK 1" >>confdefs.h
10342
10343   fi
10344
10345
10346
10347
10348
10349
10350
10351
10352
10353
10354
10355
10356
10357
10358
10359
10360
10361   :
10362
10363
10364
10365
10366
10367
10368
10369
10370
10371     if test $ac_cv_func_chown = no; then
10372     HAVE_CHOWN=0
10373   else
10374         if test $gl_cv_func_chown_follows_symlink = no; then
10375       REPLACE_CHOWN=1
10376     fi
10377
10378         if test $ac_cv_func_chown_works = no; then
10379
10380 $as_echo "#define CHOWN_FAILS_TO_HONOR_ID_OF_NEGATIVE_ONE 1" >>confdefs.h
10381
10382       REPLACE_CHOWN=1
10383     fi
10384
10385                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether chown honors trailing slash" >&5
10386 $as_echo_n "checking whether chown honors trailing slash... " >&6; }
10387 if ${gl_cv_func_chown_slash_works+:} false; then :
10388   $as_echo_n "(cached) " >&6
10389 else
10390   touch conftest.file && rm -f conftest.link
10391        if test "$cross_compiling" = yes; then :
10392   case "$host_os" in
10393                    # Guess yes on glibc systems.
10394            *-gnu*) gl_cv_func_chown_slash_works="guessing yes" ;;
10395                    # If we don't know, assume the worst.
10396            *)      gl_cv_func_chown_slash_works="guessing no" ;;
10397          esac
10398
10399 else
10400   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10401 /* end confdefs.h.  */
10402
10403 #include <unistd.h>
10404 #include <stdlib.h>
10405 #include <errno.h>
10406
10407 int
10408 main ()
10409 {
10410     if (symlink ("conftest.file", "conftest.link")) return 1;
10411           if (chown ("conftest.link/", getuid (), getgid ()) == 0) return 2;
10412
10413   ;
10414   return 0;
10415 }
10416 _ACEOF
10417 if ac_fn_c_try_run "$LINENO"; then :
10418   gl_cv_func_chown_slash_works=yes
10419 else
10420   gl_cv_func_chown_slash_works=no
10421 fi
10422 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10423   conftest.$ac_objext conftest.beam conftest.$ac_ext
10424 fi
10425
10426       rm -f conftest.link conftest.file
10427 fi
10428 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_chown_slash_works" >&5
10429 $as_echo "$gl_cv_func_chown_slash_works" >&6; }
10430     case "$gl_cv_func_chown_slash_works" in
10431       *yes) ;;
10432       *)
10433
10434 $as_echo "#define CHOWN_TRAILING_SLASH_BUG 1" >>confdefs.h
10435
10436         REPLACE_CHOWN=1
10437         ;;
10438     esac
10439
10440         { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether chown always updates ctime" >&5
10441 $as_echo_n "checking whether chown always updates ctime... " >&6; }
10442 if ${gl_cv_func_chown_ctime_works+:} false; then :
10443   $as_echo_n "(cached) " >&6
10444 else
10445   if test "$cross_compiling" = yes; then :
10446   case "$host_os" in
10447                    # Guess yes on glibc systems.
10448            *-gnu*) gl_cv_func_chown_ctime_works="guessing yes" ;;
10449                    # If we don't know, assume the worst.
10450            *)      gl_cv_func_chown_ctime_works="guessing no" ;;
10451          esac
10452
10453 else
10454   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10455 /* end confdefs.h.  */
10456
10457 #include <unistd.h>
10458 #include <stdlib.h>
10459 #include <errno.h>
10460 #include <fcntl.h>
10461 #include <sys/stat.h>
10462
10463 int
10464 main ()
10465 {
10466     struct stat st1, st2;
10467           if (close (creat ("conftest.file", 0600))) return 1;
10468           if (stat ("conftest.file", &st1)) return 2;
10469           sleep (1);
10470           if (chown ("conftest.file", st1.st_uid, st1.st_gid)) return 3;
10471           if (stat ("conftest.file", &st2)) return 4;
10472           if (st2.st_ctime <= st1.st_ctime) return 5;
10473
10474   ;
10475   return 0;
10476 }
10477 _ACEOF
10478 if ac_fn_c_try_run "$LINENO"; then :
10479   gl_cv_func_chown_ctime_works=yes
10480 else
10481   gl_cv_func_chown_ctime_works=no
10482 fi
10483 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10484   conftest.$ac_objext conftest.beam conftest.$ac_ext
10485 fi
10486
10487       rm -f conftest.file
10488 fi
10489 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_chown_ctime_works" >&5
10490 $as_echo "$gl_cv_func_chown_ctime_works" >&6; }
10491     case "$gl_cv_func_chown_ctime_works" in
10492       *yes) ;;
10493       *)
10494
10495 $as_echo "#define CHOWN_CHANGE_TIME_BUG 1" >>confdefs.h
10496
10497         REPLACE_CHOWN=1
10498         ;;
10499     esac
10500   fi
10501
10502
10503
10504
10505
10506
10507
10508
10509   :
10510
10511
10512
10513
10514
10515   if test $ac_cv_func__set_invalid_parameter_handler = yes; then
10516     HAVE_MSVC_INVALID_PARAMETER_HANDLER=1
10517
10518 $as_echo "#define HAVE_MSVC_INVALID_PARAMETER_HANDLER 1" >>confdefs.h
10519
10520   else
10521     HAVE_MSVC_INVALID_PARAMETER_HANDLER=0
10522   fi
10523
10524
10525
10526   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
10527 $as_echo_n "checking for unsigned long long int... " >&6; }
10528 if ${ac_cv_type_unsigned_long_long_int+:} false; then :
10529   $as_echo_n "(cached) " >&6
10530 else
10531   ac_cv_type_unsigned_long_long_int=yes
10532      if test "x${ac_cv_prog_cc_c99-no}" = xno; then
10533        cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10534 /* end confdefs.h.  */
10535
10536   /* For now, do not test the preprocessor; as of 2007 there are too many
10537          implementations with broken preprocessors.  Perhaps this can
10538          be revisited in 2012.  In the meantime, code should not expect
10539          #if to work with literals wider than 32 bits.  */
10540       /* Test literals.  */
10541       long long int ll = 9223372036854775807ll;
10542       long long int nll = -9223372036854775807LL;
10543       unsigned long long int ull = 18446744073709551615ULL;
10544       /* Test constant expressions.   */
10545       typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
10546                      ? 1 : -1)];
10547       typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
10548                      ? 1 : -1)];
10549       int i = 63;
10550 int
10551 main ()
10552 {
10553 /* Test availability of runtime routines for shift and division.  */
10554       long long int llmax = 9223372036854775807ll;
10555       unsigned long long int ullmax = 18446744073709551615ull;
10556       return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
10557               | (llmax / ll) | (llmax % ll)
10558               | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
10559               | (ullmax / ull) | (ullmax % ull));
10560   ;
10561   return 0;
10562 }
10563
10564 _ACEOF
10565 if ac_fn_c_try_link "$LINENO"; then :
10566
10567 else
10568   ac_cv_type_unsigned_long_long_int=no
10569 fi
10570 rm -f core conftest.err conftest.$ac_objext \
10571     conftest$ac_exeext conftest.$ac_ext
10572      fi
10573 fi
10574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
10575 $as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
10576   if test $ac_cv_type_unsigned_long_long_int = yes; then
10577
10578 $as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
10579
10580   fi
10581
10582
10583    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
10584 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
10585 if ${ac_cv_c_bigendian+:} false; then :
10586   $as_echo_n "(cached) " >&6
10587 else
10588   ac_cv_c_bigendian=unknown
10589     # See if we're dealing with a universal compiler.
10590     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10591 /* end confdefs.h.  */
10592 #ifndef __APPLE_CC__
10593                not a universal capable compiler
10594              #endif
10595              typedef int dummy;
10596
10597 _ACEOF
10598 if ac_fn_c_try_compile "$LINENO"; then :
10599
10600         # Check for potential -arch flags.  It is not universal unless
10601         # there are at least two -arch flags with different values.
10602         ac_arch=
10603         ac_prev=
10604         for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
10605          if test -n "$ac_prev"; then
10606            case $ac_word in
10607              i?86 | x86_64 | ppc | ppc64)
10608                if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
10609                  ac_arch=$ac_word
10610                else
10611                  ac_cv_c_bigendian=universal
10612                  break
10613                fi
10614                ;;
10615            esac
10616            ac_prev=
10617          elif test "x$ac_word" = "x-arch"; then
10618            ac_prev=arch
10619          fi
10620        done
10621 fi
10622 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10623     if test $ac_cv_c_bigendian = unknown; then
10624       # See if sys/param.h defines the BYTE_ORDER macro.
10625       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10626 /* end confdefs.h.  */
10627 #include <sys/types.h>
10628              #include <sys/param.h>
10629
10630 int
10631 main ()
10632 {
10633 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
10634                      && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
10635                      && LITTLE_ENDIAN)
10636               bogus endian macros
10637              #endif
10638
10639   ;
10640   return 0;
10641 }
10642 _ACEOF
10643 if ac_fn_c_try_compile "$LINENO"; then :
10644   # It does; now see whether it defined to BIG_ENDIAN or not.
10645          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10646 /* end confdefs.h.  */
10647 #include <sys/types.h>
10648                 #include <sys/param.h>
10649
10650 int
10651 main ()
10652 {
10653 #if BYTE_ORDER != BIG_ENDIAN
10654                  not big endian
10655                 #endif
10656
10657   ;
10658   return 0;
10659 }
10660 _ACEOF
10661 if ac_fn_c_try_compile "$LINENO"; then :
10662   ac_cv_c_bigendian=yes
10663 else
10664   ac_cv_c_bigendian=no
10665 fi
10666 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10667 fi
10668 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10669     fi
10670     if test $ac_cv_c_bigendian = unknown; then
10671       # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
10672       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10673 /* end confdefs.h.  */
10674 #include <limits.h>
10675
10676 int
10677 main ()
10678 {
10679 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
10680               bogus endian macros
10681              #endif
10682
10683   ;
10684   return 0;
10685 }
10686 _ACEOF
10687 if ac_fn_c_try_compile "$LINENO"; then :
10688   # It does; now see whether it defined to _BIG_ENDIAN or not.
10689          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10690 /* end confdefs.h.  */
10691 #include <limits.h>
10692
10693 int
10694 main ()
10695 {
10696 #ifndef _BIG_ENDIAN
10697                  not big endian
10698                 #endif
10699
10700   ;
10701   return 0;
10702 }
10703 _ACEOF
10704 if ac_fn_c_try_compile "$LINENO"; then :
10705   ac_cv_c_bigendian=yes
10706 else
10707   ac_cv_c_bigendian=no
10708 fi
10709 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10710 fi
10711 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10712     fi
10713     if test $ac_cv_c_bigendian = unknown; then
10714       # Compile a test program.
10715       if test "$cross_compiling" = yes; then :
10716   # Try to guess by grepping values from an object file.
10717          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10718 /* end confdefs.h.  */
10719 short int ascii_mm[] =
10720                   { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
10721                 short int ascii_ii[] =
10722                   { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
10723                 int use_ascii (int i) {
10724                   return ascii_mm[i] + ascii_ii[i];
10725                 }
10726                 short int ebcdic_ii[] =
10727                   { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
10728                 short int ebcdic_mm[] =
10729                   { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
10730                 int use_ebcdic (int i) {
10731                   return ebcdic_mm[i] + ebcdic_ii[i];
10732                 }
10733                 extern int foo;
10734
10735 int
10736 main ()
10737 {
10738 return use_ascii (foo) == use_ebcdic (foo);
10739   ;
10740   return 0;
10741 }
10742 _ACEOF
10743 if ac_fn_c_try_compile "$LINENO"; then :
10744   if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
10745               ac_cv_c_bigendian=yes
10746             fi
10747             if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
10748               if test "$ac_cv_c_bigendian" = unknown; then
10749                 ac_cv_c_bigendian=no
10750               else
10751                 # finding both strings is unlikely to happen, but who knows?
10752                 ac_cv_c_bigendian=unknown
10753               fi
10754             fi
10755 fi
10756 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10757 else
10758   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10759 /* end confdefs.h.  */
10760 $ac_includes_default
10761 int
10762 main ()
10763 {
10764
10765              /* Are we little or big endian?  From Harbison&Steele.  */
10766              union
10767              {
10768                long int l;
10769                char c[sizeof (long int)];
10770              } u;
10771              u.l = 1;
10772              return u.c[sizeof (long int) - 1] == 1;
10773
10774   ;
10775   return 0;
10776 }
10777 _ACEOF
10778 if ac_fn_c_try_run "$LINENO"; then :
10779   ac_cv_c_bigendian=no
10780 else
10781   ac_cv_c_bigendian=yes
10782 fi
10783 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10784   conftest.$ac_objext conftest.beam conftest.$ac_ext
10785 fi
10786
10787     fi
10788 fi
10789 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
10790 $as_echo "$ac_cv_c_bigendian" >&6; }
10791  case $ac_cv_c_bigendian in #(
10792    yes)
10793      $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
10794 ;; #(
10795    no)
10796       ;; #(
10797    universal)
10798
10799 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
10800
10801      ;; #(
10802    *)
10803      as_fn_error $? "unknown endianness
10804  presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
10805  esac
10806
10807
10808
10809
10810
10811
10812
10813
10814
10815
10816
10817
10818   :
10819
10820
10821
10822
10823
10824
10825
10826   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if environ is properly declared" >&5
10827 $as_echo_n "checking if environ is properly declared... " >&6; }
10828   if ${gt_cv_var_environ_declaration+:} false; then :
10829   $as_echo_n "(cached) " >&6
10830 else
10831
10832     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10833 /* end confdefs.h.  */
10834 #if HAVE_UNISTD_H
10835      #include <unistd.h>
10836      #endif
10837      /* mingw, BeOS, Haiku declare environ in <stdlib.h>, not in <unistd.h>.  */
10838      #include <stdlib.h>
10839
10840            extern struct { int foo; } environ;
10841 int
10842 main ()
10843 {
10844 environ.foo = 1;
10845   ;
10846   return 0;
10847 }
10848 _ACEOF
10849 if ac_fn_c_try_compile "$LINENO"; then :
10850   gt_cv_var_environ_declaration=no
10851 else
10852   gt_cv_var_environ_declaration=yes
10853 fi
10854 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10855 fi
10856
10857   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_var_environ_declaration" >&5
10858 $as_echo "$gt_cv_var_environ_declaration" >&6; }
10859   if test $gt_cv_var_environ_declaration = yes; then
10860
10861 $as_echo "#define HAVE_ENVIRON_DECL 1" >>confdefs.h
10862
10863   fi
10864
10865
10866   if test $gt_cv_var_environ_declaration != yes; then
10867     HAVE_DECL_ENVIRON=0
10868   fi
10869
10870
10871
10872   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for complete errno.h" >&5
10873 $as_echo_n "checking for complete errno.h... " >&6; }
10874 if ${gl_cv_header_errno_h_complete+:} false; then :
10875   $as_echo_n "(cached) " >&6
10876 else
10877
10878     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10879 /* end confdefs.h.  */
10880
10881 #include <errno.h>
10882 #if !defined ETXTBSY
10883 booboo
10884 #endif
10885 #if !defined ENOMSG
10886 booboo
10887 #endif
10888 #if !defined EIDRM
10889 booboo
10890 #endif
10891 #if !defined ENOLINK
10892 booboo
10893 #endif
10894 #if !defined EPROTO
10895 booboo
10896 #endif
10897 #if !defined EMULTIHOP
10898 booboo
10899 #endif
10900 #if !defined EBADMSG
10901 booboo
10902 #endif
10903 #if !defined EOVERFLOW
10904 booboo
10905 #endif
10906 #if !defined ENOTSUP
10907 booboo
10908 #endif
10909 #if !defined ENETRESET
10910 booboo
10911 #endif
10912 #if !defined ECONNABORTED
10913 booboo
10914 #endif
10915 #if !defined ESTALE
10916 booboo
10917 #endif
10918 #if !defined EDQUOT
10919 booboo
10920 #endif
10921 #if !defined ECANCELED
10922 booboo
10923 #endif
10924 #if !defined EOWNERDEAD
10925 booboo
10926 #endif
10927 #if !defined ENOTRECOVERABLE
10928 booboo
10929 #endif
10930 #if !defined EILSEQ
10931 booboo
10932 #endif
10933
10934 _ACEOF
10935 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10936   $EGREP "booboo" >/dev/null 2>&1; then :
10937   gl_cv_header_errno_h_complete=no
10938 else
10939   gl_cv_header_errno_h_complete=yes
10940 fi
10941 rm -f conftest*
10942
10943
10944 fi
10945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_complete" >&5
10946 $as_echo "$gl_cv_header_errno_h_complete" >&6; }
10947   if test $gl_cv_header_errno_h_complete = yes; then
10948     ERRNO_H=''
10949   else
10950
10951
10952
10953
10954
10955
10956
10957
10958      if test $gl_cv_have_include_next = yes; then
10959        gl_cv_next_errno_h='<'errno.h'>'
10960      else
10961        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <errno.h>" >&5
10962 $as_echo_n "checking absolute name of <errno.h>... " >&6; }
10963 if ${gl_cv_next_errno_h+:} false; then :
10964   $as_echo_n "(cached) " >&6
10965 else
10966
10967
10968
10969   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10970 /* end confdefs.h.  */
10971 #include <errno.h>
10972 _ACEOF
10973                 case "$host_os" in
10974     aix*) gl_absname_cpp="$ac_cpp -C" ;;
10975     *)    gl_absname_cpp="$ac_cpp" ;;
10976   esac
10977
10978   case "$host_os" in
10979     mingw*)
10980                                           gl_dirsep_regex='[/\\]'
10981       ;;
10982     *)
10983       gl_dirsep_regex='\/'
10984       ;;
10985   esac
10986       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
10987   gl_header_literal_regex=`echo 'errno.h' \
10988                            | sed -e "$gl_make_literal_regex_sed"`
10989   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
10990       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
10991       s|^/[^/]|//&|
10992       p
10993       q
10994     }'
10995
10996         gl_cv_absolute_errno_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
10997   sed -n "$gl_absolute_header_sed"`
10998
10999            gl_header=$gl_cv_absolute_errno_h
11000            gl_cv_next_errno_h='"'$gl_header'"'
11001
11002
11003 fi
11004 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_errno_h" >&5
11005 $as_echo "$gl_cv_next_errno_h" >&6; }
11006      fi
11007      NEXT_ERRNO_H=$gl_cv_next_errno_h
11008
11009      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
11010        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
11011        gl_next_as_first_directive='<'errno.h'>'
11012      else
11013        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
11014        gl_next_as_first_directive=$gl_cv_next_errno_h
11015      fi
11016      NEXT_AS_FIRST_DIRECTIVE_ERRNO_H=$gl_next_as_first_directive
11017
11018
11019
11020
11021     ERRNO_H='errno.h'
11022   fi
11023
11024    if test -n "$ERRNO_H"; then
11025   GL_GENERATE_ERRNO_H_TRUE=
11026   GL_GENERATE_ERRNO_H_FALSE='#'
11027 else
11028   GL_GENERATE_ERRNO_H_TRUE='#'
11029   GL_GENERATE_ERRNO_H_FALSE=
11030 fi
11031
11032
11033   if test -n "$ERRNO_H"; then
11034     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EMULTIHOP value" >&5
11035 $as_echo_n "checking for EMULTIHOP value... " >&6; }
11036 if ${gl_cv_header_errno_h_EMULTIHOP+:} false; then :
11037   $as_echo_n "(cached) " >&6
11038 else
11039
11040       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11041 /* end confdefs.h.  */
11042
11043 #include <errno.h>
11044 #ifdef EMULTIHOP
11045 yes
11046 #endif
11047
11048 _ACEOF
11049 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11050   $EGREP "yes" >/dev/null 2>&1; then :
11051   gl_cv_header_errno_h_EMULTIHOP=yes
11052 else
11053   gl_cv_header_errno_h_EMULTIHOP=no
11054 fi
11055 rm -f conftest*
11056
11057       if test $gl_cv_header_errno_h_EMULTIHOP = no; then
11058         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11059 /* end confdefs.h.  */
11060
11061 #define _XOPEN_SOURCE_EXTENDED 1
11062 #include <errno.h>
11063 #ifdef EMULTIHOP
11064 yes
11065 #endif
11066
11067 _ACEOF
11068 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11069   $EGREP "yes" >/dev/null 2>&1; then :
11070   gl_cv_header_errno_h_EMULTIHOP=hidden
11071 fi
11072 rm -f conftest*
11073
11074         if test $gl_cv_header_errno_h_EMULTIHOP = hidden; then
11075                               if ac_fn_c_compute_int "$LINENO" "EMULTIHOP" "gl_cv_header_errno_h_EMULTIHOP"        "
11076 #define _XOPEN_SOURCE_EXTENDED 1
11077 #include <errno.h>
11078 /* The following two lines are a workaround against an autoconf-2.52 bug.  */
11079 #include <stdio.h>
11080 #include <stdlib.h>
11081 "; then :
11082
11083 fi
11084
11085         fi
11086       fi
11087
11088 fi
11089 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EMULTIHOP" >&5
11090 $as_echo "$gl_cv_header_errno_h_EMULTIHOP" >&6; }
11091     case $gl_cv_header_errno_h_EMULTIHOP in
11092       yes | no)
11093         EMULTIHOP_HIDDEN=0; EMULTIHOP_VALUE=
11094         ;;
11095       *)
11096         EMULTIHOP_HIDDEN=1; EMULTIHOP_VALUE="$gl_cv_header_errno_h_EMULTIHOP"
11097         ;;
11098     esac
11099
11100
11101   fi
11102
11103
11104   if test -n "$ERRNO_H"; then
11105     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ENOLINK value" >&5
11106 $as_echo_n "checking for ENOLINK value... " >&6; }
11107 if ${gl_cv_header_errno_h_ENOLINK+:} false; then :
11108   $as_echo_n "(cached) " >&6
11109 else
11110
11111       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11112 /* end confdefs.h.  */
11113
11114 #include <errno.h>
11115 #ifdef ENOLINK
11116 yes
11117 #endif
11118
11119 _ACEOF
11120 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11121   $EGREP "yes" >/dev/null 2>&1; then :
11122   gl_cv_header_errno_h_ENOLINK=yes
11123 else
11124   gl_cv_header_errno_h_ENOLINK=no
11125 fi
11126 rm -f conftest*
11127
11128       if test $gl_cv_header_errno_h_ENOLINK = no; then
11129         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11130 /* end confdefs.h.  */
11131
11132 #define _XOPEN_SOURCE_EXTENDED 1
11133 #include <errno.h>
11134 #ifdef ENOLINK
11135 yes
11136 #endif
11137
11138 _ACEOF
11139 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11140   $EGREP "yes" >/dev/null 2>&1; then :
11141   gl_cv_header_errno_h_ENOLINK=hidden
11142 fi
11143 rm -f conftest*
11144
11145         if test $gl_cv_header_errno_h_ENOLINK = hidden; then
11146                               if ac_fn_c_compute_int "$LINENO" "ENOLINK" "gl_cv_header_errno_h_ENOLINK"        "
11147 #define _XOPEN_SOURCE_EXTENDED 1
11148 #include <errno.h>
11149 /* The following two lines are a workaround against an autoconf-2.52 bug.  */
11150 #include <stdio.h>
11151 #include <stdlib.h>
11152 "; then :
11153
11154 fi
11155
11156         fi
11157       fi
11158
11159 fi
11160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_ENOLINK" >&5
11161 $as_echo "$gl_cv_header_errno_h_ENOLINK" >&6; }
11162     case $gl_cv_header_errno_h_ENOLINK in
11163       yes | no)
11164         ENOLINK_HIDDEN=0; ENOLINK_VALUE=
11165         ;;
11166       *)
11167         ENOLINK_HIDDEN=1; ENOLINK_VALUE="$gl_cv_header_errno_h_ENOLINK"
11168         ;;
11169     esac
11170
11171
11172   fi
11173
11174
11175   if test -n "$ERRNO_H"; then
11176     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EOVERFLOW value" >&5
11177 $as_echo_n "checking for EOVERFLOW value... " >&6; }
11178 if ${gl_cv_header_errno_h_EOVERFLOW+:} false; then :
11179   $as_echo_n "(cached) " >&6
11180 else
11181
11182       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11183 /* end confdefs.h.  */
11184
11185 #include <errno.h>
11186 #ifdef EOVERFLOW
11187 yes
11188 #endif
11189
11190 _ACEOF
11191 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11192   $EGREP "yes" >/dev/null 2>&1; then :
11193   gl_cv_header_errno_h_EOVERFLOW=yes
11194 else
11195   gl_cv_header_errno_h_EOVERFLOW=no
11196 fi
11197 rm -f conftest*
11198
11199       if test $gl_cv_header_errno_h_EOVERFLOW = no; then
11200         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11201 /* end confdefs.h.  */
11202
11203 #define _XOPEN_SOURCE_EXTENDED 1
11204 #include <errno.h>
11205 #ifdef EOVERFLOW
11206 yes
11207 #endif
11208
11209 _ACEOF
11210 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11211   $EGREP "yes" >/dev/null 2>&1; then :
11212   gl_cv_header_errno_h_EOVERFLOW=hidden
11213 fi
11214 rm -f conftest*
11215
11216         if test $gl_cv_header_errno_h_EOVERFLOW = hidden; then
11217                               if ac_fn_c_compute_int "$LINENO" "EOVERFLOW" "gl_cv_header_errno_h_EOVERFLOW"        "
11218 #define _XOPEN_SOURCE_EXTENDED 1
11219 #include <errno.h>
11220 /* The following two lines are a workaround against an autoconf-2.52 bug.  */
11221 #include <stdio.h>
11222 #include <stdlib.h>
11223 "; then :
11224
11225 fi
11226
11227         fi
11228       fi
11229
11230 fi
11231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EOVERFLOW" >&5
11232 $as_echo "$gl_cv_header_errno_h_EOVERFLOW" >&6; }
11233     case $gl_cv_header_errno_h_EOVERFLOW in
11234       yes | no)
11235         EOVERFLOW_HIDDEN=0; EOVERFLOW_VALUE=
11236         ;;
11237       *)
11238         EOVERFLOW_HIDDEN=1; EOVERFLOW_VALUE="$gl_cv_header_errno_h_EOVERFLOW"
11239         ;;
11240     esac
11241
11242
11243   fi
11244
11245
11246
11247
11248
11249
11250
11251
11252
11253
11254
11255   GNULIB_DPRINTF=0;
11256   GNULIB_FCLOSE=0;
11257   GNULIB_FDOPEN=0;
11258   GNULIB_FFLUSH=0;
11259   GNULIB_FGETC=0;
11260   GNULIB_FGETS=0;
11261   GNULIB_FOPEN=0;
11262   GNULIB_FPRINTF=0;
11263   GNULIB_FPRINTF_POSIX=0;
11264   GNULIB_FPURGE=0;
11265   GNULIB_FPUTC=0;
11266   GNULIB_FPUTS=0;
11267   GNULIB_FREAD=0;
11268   GNULIB_FREOPEN=0;
11269   GNULIB_FSCANF=0;
11270   GNULIB_FSEEK=0;
11271   GNULIB_FSEEKO=0;
11272   GNULIB_FTELL=0;
11273   GNULIB_FTELLO=0;
11274   GNULIB_FWRITE=0;
11275   GNULIB_GETC=0;
11276   GNULIB_GETCHAR=0;
11277   GNULIB_GETDELIM=0;
11278   GNULIB_GETLINE=0;
11279   GNULIB_OBSTACK_PRINTF=0;
11280   GNULIB_OBSTACK_PRINTF_POSIX=0;
11281   GNULIB_PCLOSE=0;
11282   GNULIB_PERROR=0;
11283   GNULIB_POPEN=0;
11284   GNULIB_PRINTF=0;
11285   GNULIB_PRINTF_POSIX=0;
11286   GNULIB_PUTC=0;
11287   GNULIB_PUTCHAR=0;
11288   GNULIB_PUTS=0;
11289   GNULIB_REMOVE=0;
11290   GNULIB_RENAME=0;
11291   GNULIB_RENAMEAT=0;
11292   GNULIB_SCANF=0;
11293   GNULIB_SNPRINTF=0;
11294   GNULIB_SPRINTF_POSIX=0;
11295   GNULIB_STDIO_H_NONBLOCKING=0;
11296   GNULIB_STDIO_H_SIGPIPE=0;
11297   GNULIB_TMPFILE=0;
11298   GNULIB_VASPRINTF=0;
11299   GNULIB_VFSCANF=0;
11300   GNULIB_VSCANF=0;
11301   GNULIB_VDPRINTF=0;
11302   GNULIB_VFPRINTF=0;
11303   GNULIB_VFPRINTF_POSIX=0;
11304   GNULIB_VPRINTF=0;
11305   GNULIB_VPRINTF_POSIX=0;
11306   GNULIB_VSNPRINTF=0;
11307   GNULIB_VSPRINTF_POSIX=0;
11308     HAVE_DECL_FPURGE=1;
11309   HAVE_DECL_FSEEKO=1;
11310   HAVE_DECL_FTELLO=1;
11311   HAVE_DECL_GETDELIM=1;
11312   HAVE_DECL_GETLINE=1;
11313   HAVE_DECL_OBSTACK_PRINTF=1;
11314   HAVE_DECL_SNPRINTF=1;
11315   HAVE_DECL_VSNPRINTF=1;
11316   HAVE_DPRINTF=1;
11317   HAVE_FSEEKO=1;
11318   HAVE_FTELLO=1;
11319   HAVE_PCLOSE=1;
11320   HAVE_POPEN=1;
11321   HAVE_RENAMEAT=1;
11322   HAVE_VASPRINTF=1;
11323   HAVE_VDPRINTF=1;
11324   REPLACE_DPRINTF=0;
11325   REPLACE_FCLOSE=0;
11326   REPLACE_FDOPEN=0;
11327   REPLACE_FFLUSH=0;
11328   REPLACE_FOPEN=0;
11329   REPLACE_FPRINTF=0;
11330   REPLACE_FPURGE=0;
11331   REPLACE_FREOPEN=0;
11332   REPLACE_FSEEK=0;
11333   REPLACE_FSEEKO=0;
11334   REPLACE_FTELL=0;
11335   REPLACE_FTELLO=0;
11336   REPLACE_GETDELIM=0;
11337   REPLACE_GETLINE=0;
11338   REPLACE_OBSTACK_PRINTF=0;
11339   REPLACE_PERROR=0;
11340   REPLACE_POPEN=0;
11341   REPLACE_PRINTF=0;
11342   REPLACE_REMOVE=0;
11343   REPLACE_RENAME=0;
11344   REPLACE_RENAMEAT=0;
11345   REPLACE_SNPRINTF=0;
11346   REPLACE_SPRINTF=0;
11347   REPLACE_STDIO_READ_FUNCS=0;
11348   REPLACE_STDIO_WRITE_FUNCS=0;
11349   REPLACE_TMPFILE=0;
11350   REPLACE_VASPRINTF=0;
11351   REPLACE_VDPRINTF=0;
11352   REPLACE_VFPRINTF=0;
11353   REPLACE_VPRINTF=0;
11354   REPLACE_VSNPRINTF=0;
11355   REPLACE_VSPRINTF=0;
11356
11357
11358   GNULIB_FCNTL=0;
11359   GNULIB_NONBLOCKING=0;
11360   GNULIB_OPEN=0;
11361   GNULIB_OPENAT=0;
11362     HAVE_FCNTL=1;
11363   HAVE_OPENAT=1;
11364   REPLACE_FCNTL=0;
11365   REPLACE_OPEN=0;
11366   REPLACE_OPENAT=0;
11367
11368
11369
11370
11371
11372
11373
11374
11375
11376
11377
11378
11379
11380
11381
11382   :
11383
11384
11385
11386
11387
11388
11389   :
11390
11391
11392
11393
11394
11395   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fcntl.h" >&5
11396 $as_echo_n "checking for working fcntl.h... " >&6; }
11397 if ${gl_cv_header_working_fcntl_h+:} false; then :
11398   $as_echo_n "(cached) " >&6
11399 else
11400   if test "$cross_compiling" = yes; then :
11401   gl_cv_header_working_fcntl_h=cross-compiling
11402 else
11403   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11404 /* end confdefs.h.  */
11405 #include <sys/types.h>
11406            #include <sys/stat.h>
11407            #if HAVE_UNISTD_H
11408            # include <unistd.h>
11409            #else /* on Windows with MSVC */
11410            # include <io.h>
11411            # include <stdlib.h>
11412            # defined sleep(n) _sleep ((n) * 1000)
11413            #endif
11414            #include <fcntl.h>
11415            #ifndef O_NOATIME
11416             #define O_NOATIME 0
11417            #endif
11418            #ifndef O_NOFOLLOW
11419             #define O_NOFOLLOW 0
11420            #endif
11421            static int const constants[] =
11422             {
11423               O_CREAT, O_EXCL, O_NOCTTY, O_TRUNC, O_APPEND,
11424               O_NONBLOCK, O_SYNC, O_ACCMODE, O_RDONLY, O_RDWR, O_WRONLY
11425             };
11426
11427 int
11428 main ()
11429 {
11430
11431             int result = !constants;
11432             #if HAVE_SYMLINK
11433             {
11434               static char const sym[] = "conftest.sym";
11435               if (symlink ("/dev/null", sym) != 0)
11436                 result |= 2;
11437               else
11438                 {
11439                   int fd = open (sym, O_WRONLY | O_NOFOLLOW | O_CREAT, 0);
11440                   if (fd >= 0)
11441                     {
11442                       close (fd);
11443                       result |= 4;
11444                     }
11445                 }
11446               if (unlink (sym) != 0 || symlink (".", sym) != 0)
11447                 result |= 2;
11448               else
11449                 {
11450                   int fd = open (sym, O_RDONLY | O_NOFOLLOW);
11451                   if (fd >= 0)
11452                     {
11453                       close (fd);
11454                       result |= 4;
11455                     }
11456                 }
11457               unlink (sym);
11458             }
11459             #endif
11460             {
11461               static char const file[] = "confdefs.h";
11462               int fd = open (file, O_RDONLY | O_NOATIME);
11463               if (fd < 0)
11464                 result |= 8;
11465               else
11466                 {
11467                   struct stat st0;
11468                   if (fstat (fd, &st0) != 0)
11469                     result |= 16;
11470                   else
11471                     {
11472                       char c;
11473                       sleep (1);
11474                       if (read (fd, &c, 1) != 1)
11475                         result |= 24;
11476                       else
11477                         {
11478                           if (close (fd) != 0)
11479                             result |= 32;
11480                           else
11481                             {
11482                               struct stat st1;
11483                               if (stat (file, &st1) != 0)
11484                                 result |= 40;
11485                               else
11486                                 if (st0.st_atime != st1.st_atime)
11487                                   result |= 64;
11488                             }
11489                         }
11490                     }
11491                 }
11492             }
11493             return result;
11494   ;
11495   return 0;
11496 }
11497 _ACEOF
11498 if ac_fn_c_try_run "$LINENO"; then :
11499   gl_cv_header_working_fcntl_h=yes
11500 else
11501   case $? in #(
11502         4) gl_cv_header_working_fcntl_h='no (bad O_NOFOLLOW)';; #(
11503         64) gl_cv_header_working_fcntl_h='no (bad O_NOATIME)';; #(
11504         68) gl_cv_header_working_fcntl_h='no (bad O_NOATIME, O_NOFOLLOW)';; #(
11505          *) gl_cv_header_working_fcntl_h='no';;
11506         esac
11507 fi
11508 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11509   conftest.$ac_objext conftest.beam conftest.$ac_ext
11510 fi
11511
11512 fi
11513 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_fcntl_h" >&5
11514 $as_echo "$gl_cv_header_working_fcntl_h" >&6; }
11515
11516   case $gl_cv_header_working_fcntl_h in #(
11517   *O_NOATIME* | no | cross-compiling) ac_val=0;; #(
11518   *) ac_val=1;;
11519   esac
11520
11521 cat >>confdefs.h <<_ACEOF
11522 #define HAVE_WORKING_O_NOATIME $ac_val
11523 _ACEOF
11524
11525
11526   case $gl_cv_header_working_fcntl_h in #(
11527   *O_NOFOLLOW* | no | cross-compiling) ac_val=0;; #(
11528   *) ac_val=1;;
11529   esac
11530
11531 cat >>confdefs.h <<_ACEOF
11532 #define HAVE_WORKING_O_NOFOLLOW $ac_val
11533 _ACEOF
11534
11535
11536 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
11537 if test "x$ac_cv_type_pid_t" = xyes; then :
11538
11539 else
11540
11541 cat >>confdefs.h <<_ACEOF
11542 #define pid_t int
11543 _ACEOF
11544
11545 fi
11546
11547 ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
11548 if test "x$ac_cv_type_mode_t" = xyes; then :
11549
11550 else
11551
11552 cat >>confdefs.h <<_ACEOF
11553 #define mode_t int
11554 _ACEOF
11555
11556 fi
11557
11558
11559       ac_fn_c_check_decl "$LINENO" "fdatasync" "ac_cv_have_decl_fdatasync" "$ac_includes_default"
11560 if test "x$ac_cv_have_decl_fdatasync" = xyes; then :
11561   ac_have_decl=1
11562 else
11563   ac_have_decl=0
11564 fi
11565
11566 cat >>confdefs.h <<_ACEOF
11567 #define HAVE_DECL_FDATASYNC $ac_have_decl
11568 _ACEOF
11569
11570
11571
11572   GNULIB_FFS=0;
11573     HAVE_FFS=1;
11574   HAVE_STRCASECMP=1;
11575   HAVE_DECL_STRNCASECMP=1;
11576
11577
11578
11579
11580
11581
11582
11583   GNULIB_FFSL=0;
11584   GNULIB_FFSLL=0;
11585   GNULIB_MEMCHR=0;
11586   GNULIB_MEMMEM=0;
11587   GNULIB_MEMPCPY=0;
11588   GNULIB_MEMRCHR=0;
11589   GNULIB_RAWMEMCHR=0;
11590   GNULIB_STPCPY=0;
11591   GNULIB_STPNCPY=0;
11592   GNULIB_STRCHRNUL=0;
11593   GNULIB_STRDUP=0;
11594   GNULIB_STRNCAT=0;
11595   GNULIB_STRNDUP=0;
11596   GNULIB_STRNLEN=0;
11597   GNULIB_STRPBRK=0;
11598   GNULIB_STRSEP=0;
11599   GNULIB_STRSTR=0;
11600   GNULIB_STRCASESTR=0;
11601   GNULIB_STRTOK_R=0;
11602   GNULIB_MBSLEN=0;
11603   GNULIB_MBSNLEN=0;
11604   GNULIB_MBSCHR=0;
11605   GNULIB_MBSRCHR=0;
11606   GNULIB_MBSSTR=0;
11607   GNULIB_MBSCASECMP=0;
11608   GNULIB_MBSNCASECMP=0;
11609   GNULIB_MBSPCASECMP=0;
11610   GNULIB_MBSCASESTR=0;
11611   GNULIB_MBSCSPN=0;
11612   GNULIB_MBSPBRK=0;
11613   GNULIB_MBSSPN=0;
11614   GNULIB_MBSSEP=0;
11615   GNULIB_MBSTOK_R=0;
11616   GNULIB_STRERROR=0;
11617   GNULIB_STRERROR_R=0;
11618   GNULIB_STRSIGNAL=0;
11619   GNULIB_STRVERSCMP=0;
11620   HAVE_MBSLEN=0;
11621     HAVE_FFSL=1;
11622   HAVE_FFSLL=1;
11623   HAVE_MEMCHR=1;
11624   HAVE_DECL_MEMMEM=1;
11625   HAVE_MEMPCPY=1;
11626   HAVE_DECL_MEMRCHR=1;
11627   HAVE_RAWMEMCHR=1;
11628   HAVE_STPCPY=1;
11629   HAVE_STPNCPY=1;
11630   HAVE_STRCHRNUL=1;
11631   HAVE_DECL_STRDUP=1;
11632   HAVE_DECL_STRNDUP=1;
11633   HAVE_DECL_STRNLEN=1;
11634   HAVE_STRPBRK=1;
11635   HAVE_STRSEP=1;
11636   HAVE_STRCASESTR=1;
11637   HAVE_DECL_STRTOK_R=1;
11638   HAVE_DECL_STRERROR_R=1;
11639   HAVE_DECL_STRSIGNAL=1;
11640   HAVE_STRVERSCMP=1;
11641   REPLACE_MEMCHR=0;
11642   REPLACE_MEMMEM=0;
11643   REPLACE_STPNCPY=0;
11644   REPLACE_STRDUP=0;
11645   REPLACE_STRSTR=0;
11646   REPLACE_STRCASESTR=0;
11647   REPLACE_STRCHRNUL=0;
11648   REPLACE_STRERROR=0;
11649   REPLACE_STRERROR_R=0;
11650   REPLACE_STRNCAT=0;
11651   REPLACE_STRNDUP=0;
11652   REPLACE_STRNLEN=0;
11653   REPLACE_STRSIGNAL=0;
11654   REPLACE_STRTOK_R=0;
11655   UNDEFINE_STRTOK_R=0;
11656
11657
11658
11659
11660
11661
11662
11663
11664    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
11665 $as_echo_n "checking for mbstate_t... " >&6; }
11666 if ${ac_cv_type_mbstate_t+:} false; then :
11667   $as_echo_n "(cached) " >&6
11668 else
11669   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11670 /* end confdefs.h.  */
11671 $ac_includes_default
11672 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
11673    <wchar.h>.
11674    BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
11675    included before <wchar.h>.  */
11676 #include <stddef.h>
11677 #include <stdio.h>
11678 #include <time.h>
11679 #include <wchar.h>
11680 int
11681 main ()
11682 {
11683 mbstate_t x; return sizeof x;
11684   ;
11685   return 0;
11686 }
11687 _ACEOF
11688 if ac_fn_c_try_compile "$LINENO"; then :
11689   ac_cv_type_mbstate_t=yes
11690 else
11691   ac_cv_type_mbstate_t=no
11692 fi
11693 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11694 fi
11695 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5
11696 $as_echo "$ac_cv_type_mbstate_t" >&6; }
11697    if test $ac_cv_type_mbstate_t = yes; then
11698
11699 $as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h
11700
11701    else
11702
11703 $as_echo "#define mbstate_t int" >>confdefs.h
11704
11705    fi
11706
11707
11708
11709
11710
11711
11712
11713
11714
11715
11716
11717
11718
11719
11720
11721
11722
11723
11724
11725
11726
11727
11728
11729
11730
11731
11732
11733
11734
11735
11736
11737
11738
11739
11740
11741
11742
11743
11744
11745
11746
11747
11748
11749
11750
11751
11752
11753
11754
11755
11756
11757
11758
11759
11760
11761
11762
11763     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdin defaults to large file offsets" >&5
11764 $as_echo_n "checking whether stdin defaults to large file offsets... " >&6; }
11765 if ${gl_cv_var_stdin_large_offset+:} false; then :
11766   $as_echo_n "(cached) " >&6
11767 else
11768   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11769 /* end confdefs.h.  */
11770 #include <stdio.h>
11771 int
11772 main ()
11773 {
11774 #if defined __SL64 && defined __SCLE /* cygwin */
11775   /* Cygwin 1.5.24 and earlier fail to put stdin in 64-bit mode, making
11776      fseeko/ftello needlessly fail.  This bug was fixed in 1.5.25, and
11777      it is easier to do a version check than building a runtime test.  */
11778 # include <cygwin/version.h>
11779 # if CYGWIN_VERSION_DLL_COMBINED < CYGWIN_VERSION_DLL_MAKE_COMBINED (1005, 25)
11780   choke me
11781 # endif
11782 #endif
11783   ;
11784   return 0;
11785 }
11786 _ACEOF
11787 if ac_fn_c_try_link "$LINENO"; then :
11788   gl_cv_var_stdin_large_offset=yes
11789 else
11790   gl_cv_var_stdin_large_offset=no
11791 fi
11792 rm -f core conftest.err conftest.$ac_objext \
11793     conftest$ac_exeext conftest.$ac_ext
11794 fi
11795 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_var_stdin_large_offset" >&5
11796 $as_echo "$gl_cv_var_stdin_large_offset" >&6; }
11797
11798
11799
11800
11801
11802   case "$host_os" in
11803     mingw*)
11804                         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for 64-bit off_t" >&5
11805 $as_echo_n "checking for 64-bit off_t... " >&6; }
11806 if ${gl_cv_type_off_t_64+:} false; then :
11807   $as_echo_n "(cached) " >&6
11808 else
11809   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11810 /* end confdefs.h.  */
11811 #include <sys/types.h>
11812                 int verify_off_t_size[sizeof (off_t) >= 8 ? 1 : -1];
11813
11814 int
11815 main ()
11816 {
11817
11818   ;
11819   return 0;
11820 }
11821 _ACEOF
11822 if ac_fn_c_try_compile "$LINENO"; then :
11823   gl_cv_type_off_t_64=yes
11824 else
11825   gl_cv_type_off_t_64=no
11826 fi
11827 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11828
11829 fi
11830 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_off_t_64" >&5
11831 $as_echo "$gl_cv_type_off_t_64" >&6; }
11832       if test $gl_cv_type_off_t_64 = no; then
11833         WINDOWS_64_BIT_OFF_T=1
11834       else
11835         WINDOWS_64_BIT_OFF_T=0
11836       fi
11837                   WINDOWS_64_BIT_ST_SIZE=1
11838       ;;
11839     *)
11840                                                       WINDOWS_64_BIT_OFF_T=0
11841       WINDOWS_64_BIT_ST_SIZE=0
11842       ;;
11843   esac
11844
11845
11846
11847
11848
11849
11850
11851
11852
11853
11854
11855
11856
11857
11858
11859
11860
11861      if test $gl_cv_have_include_next = yes; then
11862        gl_cv_next_sys_types_h='<'sys/types.h'>'
11863      else
11864        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/types.h>" >&5
11865 $as_echo_n "checking absolute name of <sys/types.h>... " >&6; }
11866 if ${gl_cv_next_sys_types_h+:} false; then :
11867   $as_echo_n "(cached) " >&6
11868 else
11869
11870
11871
11872   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11873 /* end confdefs.h.  */
11874 #include <sys/types.h>
11875 _ACEOF
11876                 case "$host_os" in
11877     aix*) gl_absname_cpp="$ac_cpp -C" ;;
11878     *)    gl_absname_cpp="$ac_cpp" ;;
11879   esac
11880
11881   case "$host_os" in
11882     mingw*)
11883                                           gl_dirsep_regex='[/\\]'
11884       ;;
11885     *)
11886       gl_dirsep_regex='\/'
11887       ;;
11888   esac
11889       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
11890   gl_header_literal_regex=`echo 'sys/types.h' \
11891                            | sed -e "$gl_make_literal_regex_sed"`
11892   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
11893       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
11894       s|^/[^/]|//&|
11895       p
11896       q
11897     }'
11898
11899         gl_cv_absolute_sys_types_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
11900   sed -n "$gl_absolute_header_sed"`
11901
11902            gl_header=$gl_cv_absolute_sys_types_h
11903            gl_cv_next_sys_types_h='"'$gl_header'"'
11904
11905
11906 fi
11907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_types_h" >&5
11908 $as_echo "$gl_cv_next_sys_types_h" >&6; }
11909      fi
11910      NEXT_SYS_TYPES_H=$gl_cv_next_sys_types_h
11911
11912      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
11913        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
11914        gl_next_as_first_directive='<'sys/types.h'>'
11915      else
11916        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
11917        gl_next_as_first_directive=$gl_cv_next_sys_types_h
11918      fi
11919      NEXT_AS_FIRST_DIRECTIVE_SYS_TYPES_H=$gl_next_as_first_directive
11920
11921
11922
11923
11924
11925
11926
11927
11928
11929
11930
11931
11932       ac_fn_c_check_decl "$LINENO" "fseeko" "ac_cv_have_decl_fseeko" "$ac_includes_default"
11933 if test "x$ac_cv_have_decl_fseeko" = xyes; then :
11934   ac_have_decl=1
11935 else
11936   ac_have_decl=0
11937 fi
11938
11939 cat >>confdefs.h <<_ACEOF
11940 #define HAVE_DECL_FSEEKO $ac_have_decl
11941 _ACEOF
11942
11943
11944
11945
11946
11947
11948
11949
11950
11951
11952   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fseeko" >&5
11953 $as_echo_n "checking for fseeko... " >&6; }
11954 if ${gl_cv_func_fseeko+:} false; then :
11955   $as_echo_n "(cached) " >&6
11956 else
11957
11958       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11959 /* end confdefs.h.  */
11960 #include <stdio.h>
11961
11962 int
11963 main ()
11964 {
11965 fseeko (stdin, 0, 0);
11966   ;
11967   return 0;
11968 }
11969 _ACEOF
11970 if ac_fn_c_try_link "$LINENO"; then :
11971   gl_cv_func_fseeko=yes
11972 else
11973   gl_cv_func_fseeko=no
11974 fi
11975 rm -f core conftest.err conftest.$ac_objext \
11976     conftest$ac_exeext conftest.$ac_ext
11977
11978 fi
11979 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fseeko" >&5
11980 $as_echo "$gl_cv_func_fseeko" >&6; }
11981
11982
11983   :
11984
11985
11986
11987
11988
11989   if test $ac_cv_have_decl_fseeko = no; then
11990     HAVE_DECL_FSEEKO=0
11991   fi
11992
11993   if test $gl_cv_func_fseeko = no; then
11994     HAVE_FSEEKO=0
11995   else
11996     if test $WINDOWS_64_BIT_OFF_T = 1; then
11997       REPLACE_FSEEKO=1
11998     fi
11999     if test $gl_cv_var_stdin_large_offset = no; then
12000       REPLACE_FSEEKO=1
12001     fi
12002
12003
12004
12005   :
12006
12007
12008
12009
12010
12011   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fflush works on input streams" >&5
12012 $as_echo_n "checking whether fflush works on input streams... " >&6; }
12013 if ${gl_cv_func_fflush_stdin+:} false; then :
12014   $as_echo_n "(cached) " >&6
12015 else
12016   echo hello world > conftest.txt
12017      if test "$cross_compiling" = yes; then :
12018   gl_cv_func_fflush_stdin=cross
12019 else
12020   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12021 /* end confdefs.h.  */
12022
12023 #include <stdio.h>
12024 #if HAVE_UNISTD_H
12025 # include <unistd.h>
12026 #else /* on Windows with MSVC */
12027 # include <io.h>
12028 #endif
12029
12030 int
12031 main ()
12032 {
12033 FILE *f = fopen ("conftest.txt", "r");
12034          char buffer[10];
12035          int fd;
12036          int c;
12037          if (f == NULL)
12038            return 1;
12039          fd = fileno (f);
12040          if (fd < 0 || fread (buffer, 1, 5, f) != 5)
12041            return 2;
12042          /* For deterministic results, ensure f read a bigger buffer.  */
12043          if (lseek (fd, 0, SEEK_CUR) == 5)
12044            return 3;
12045          /* POSIX requires fflush-fseek to set file offset of fd.  This fails
12046             on BSD systems and on mingw.  */
12047          if (fflush (f) != 0 || fseek (f, 0, SEEK_CUR) != 0)
12048            return 4;
12049          if (lseek (fd, 0, SEEK_CUR) != 5)
12050            return 5;
12051          /* Verify behaviour of fflush after ungetc. See
12052             <http://www.opengroup.org/austin/aardvark/latest/xshbug3.txt>  */
12053          /* Verify behaviour of fflush after a backup ungetc.  This fails on
12054             mingw.  */
12055          c = fgetc (f);
12056          ungetc (c, f);
12057          fflush (f);
12058          if (fgetc (f) != c)
12059            return 6;
12060          /* Verify behaviour of fflush after a non-backup ungetc.  This fails
12061             on glibc 2.8 and on BSD systems.  */
12062          c = fgetc (f);
12063          ungetc ('@', f);
12064          fflush (f);
12065          if (fgetc (f) != c)
12066            return 7;
12067          return 0;
12068
12069   ;
12070   return 0;
12071 }
12072 _ACEOF
12073 if ac_fn_c_try_run "$LINENO"; then :
12074   gl_cv_func_fflush_stdin=yes
12075 else
12076   gl_cv_func_fflush_stdin=no
12077 fi
12078 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12079   conftest.$ac_objext conftest.beam conftest.$ac_ext
12080 fi
12081
12082      rm conftest.txt
12083
12084 fi
12085 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fflush_stdin" >&5
12086 $as_echo "$gl_cv_func_fflush_stdin" >&6; }
12087   case $gl_cv_func_fflush_stdin in
12088     yes) gl_func_fflush_stdin=1 ;;
12089     no)  gl_func_fflush_stdin=0 ;;
12090     *)   gl_func_fflush_stdin='(-1)' ;;
12091   esac
12092
12093 cat >>confdefs.h <<_ACEOF
12094 #define FUNC_FFLUSH_STDIN $gl_func_fflush_stdin
12095 _ACEOF
12096
12097
12098       if test $gl_cv_func_fflush_stdin != yes; then
12099         REPLACE_FSEEKO=1
12100       fi
12101
12102   fi
12103
12104
12105      GNULIB_FCHMODAT=0;
12106   GNULIB_FSTAT=0;
12107   GNULIB_FSTATAT=0;
12108   GNULIB_FUTIMENS=0;
12109   GNULIB_LCHMOD=0;
12110   GNULIB_LSTAT=0;
12111   GNULIB_MKDIRAT=0;
12112   GNULIB_MKFIFO=0;
12113   GNULIB_MKFIFOAT=0;
12114   GNULIB_MKNOD=0;
12115   GNULIB_MKNODAT=0;
12116   GNULIB_STAT=0;
12117   GNULIB_UTIMENSAT=0;
12118     HAVE_FCHMODAT=1;
12119   HAVE_FSTATAT=1;
12120   HAVE_FUTIMENS=1;
12121   HAVE_LCHMOD=1;
12122   HAVE_LSTAT=1;
12123   HAVE_MKDIRAT=1;
12124   HAVE_MKFIFO=1;
12125   HAVE_MKFIFOAT=1;
12126   HAVE_MKNOD=1;
12127   HAVE_MKNODAT=1;
12128   HAVE_UTIMENSAT=1;
12129   REPLACE_FSTAT=0;
12130   REPLACE_FSTATAT=0;
12131   REPLACE_FUTIMENS=0;
12132   REPLACE_LSTAT=0;
12133   REPLACE_MKDIR=0;
12134   REPLACE_MKFIFO=0;
12135   REPLACE_MKNOD=0;
12136   REPLACE_STAT=0;
12137   REPLACE_UTIMENSAT=0;
12138
12139 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5
12140 $as_echo_n "checking whether stat file-mode macros are broken... " >&6; }
12141 if ${ac_cv_header_stat_broken+:} false; then :
12142   $as_echo_n "(cached) " >&6
12143 else
12144   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12145 /* end confdefs.h.  */
12146 #include <sys/types.h>
12147 #include <sys/stat.h>
12148
12149 #if defined S_ISBLK && defined S_IFDIR
12150 extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1];
12151 #endif
12152
12153 #if defined S_ISBLK && defined S_IFCHR
12154 extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1];
12155 #endif
12156
12157 #if defined S_ISLNK && defined S_IFREG
12158 extern char c3[S_ISLNK (S_IFREG) ? -1 : 1];
12159 #endif
12160
12161 #if defined S_ISSOCK && defined S_IFREG
12162 extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1];
12163 #endif
12164
12165 _ACEOF
12166 if ac_fn_c_try_compile "$LINENO"; then :
12167   ac_cv_header_stat_broken=no
12168 else
12169   ac_cv_header_stat_broken=yes
12170 fi
12171 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12172 fi
12173 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5
12174 $as_echo "$ac_cv_header_stat_broken" >&6; }
12175 if test $ac_cv_header_stat_broken = yes; then
12176
12177 $as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h
12178
12179 fi
12180
12181
12182
12183
12184
12185
12186
12187
12188
12189
12190
12191
12192
12193
12194
12195
12196
12197   :
12198
12199
12200
12201
12202
12203
12204
12205
12206      if test $gl_cv_have_include_next = yes; then
12207        gl_cv_next_sys_stat_h='<'sys/stat.h'>'
12208      else
12209        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
12210 $as_echo_n "checking absolute name of <sys/stat.h>... " >&6; }
12211 if ${gl_cv_next_sys_stat_h+:} false; then :
12212   $as_echo_n "(cached) " >&6
12213 else
12214
12215              if test $ac_cv_header_sys_stat_h = yes; then
12216
12217
12218
12219
12220   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12221 /* end confdefs.h.  */
12222 #include <sys/stat.h>
12223 _ACEOF
12224                 case "$host_os" in
12225     aix*) gl_absname_cpp="$ac_cpp -C" ;;
12226     *)    gl_absname_cpp="$ac_cpp" ;;
12227   esac
12228
12229   case "$host_os" in
12230     mingw*)
12231                                           gl_dirsep_regex='[/\\]'
12232       ;;
12233     *)
12234       gl_dirsep_regex='\/'
12235       ;;
12236   esac
12237       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
12238   gl_header_literal_regex=`echo 'sys/stat.h' \
12239                            | sed -e "$gl_make_literal_regex_sed"`
12240   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
12241       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
12242       s|^/[^/]|//&|
12243       p
12244       q
12245     }'
12246
12247         gl_cv_absolute_sys_stat_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
12248   sed -n "$gl_absolute_header_sed"`
12249
12250            gl_header=$gl_cv_absolute_sys_stat_h
12251            gl_cv_next_sys_stat_h='"'$gl_header'"'
12252           else
12253                gl_cv_next_sys_stat_h='<'sys/stat.h'>'
12254              fi
12255
12256
12257 fi
12258 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
12259 $as_echo "$gl_cv_next_sys_stat_h" >&6; }
12260      fi
12261      NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h
12262
12263      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
12264        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
12265        gl_next_as_first_directive='<'sys/stat.h'>'
12266      else
12267        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
12268        gl_next_as_first_directive=$gl_cv_next_sys_stat_h
12269      fi
12270      NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive
12271
12272
12273
12274
12275
12276
12277
12278
12279
12280
12281
12282   if test $WINDOWS_64_BIT_ST_SIZE = 1; then
12283
12284 $as_echo "#define _GL_WINDOWS_64_BIT_ST_SIZE 1" >>confdefs.h
12285
12286   fi
12287
12288       ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
12289      #include <sys/stat.h>
12290 "
12291 if test "x$ac_cv_type_nlink_t" = xyes; then :
12292
12293 else
12294
12295 $as_echo "#define nlink_t int" >>confdefs.h
12296
12297 fi
12298
12299
12300
12301
12302
12303
12304
12305
12306
12307
12308       ac_fn_c_check_decl "$LINENO" "ftello" "ac_cv_have_decl_ftello" "$ac_includes_default"
12309 if test "x$ac_cv_have_decl_ftello" = xyes; then :
12310   ac_have_decl=1
12311 else
12312   ac_have_decl=0
12313 fi
12314
12315 cat >>confdefs.h <<_ACEOF
12316 #define HAVE_DECL_FTELLO $ac_have_decl
12317 _ACEOF
12318
12319
12320
12321
12322
12323
12324
12325
12326
12327
12328
12329   :
12330
12331
12332
12333
12334
12335   if test $ac_cv_have_decl_ftello = no; then
12336     HAVE_DECL_FTELLO=0
12337   fi
12338
12339   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ftello" >&5
12340 $as_echo_n "checking for ftello... " >&6; }
12341 if ${gl_cv_func_ftello+:} false; then :
12342   $as_echo_n "(cached) " >&6
12343 else
12344
12345       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12346 /* end confdefs.h.  */
12347 #include <stdio.h>
12348 int
12349 main ()
12350 {
12351 ftello (stdin);
12352   ;
12353   return 0;
12354 }
12355 _ACEOF
12356 if ac_fn_c_try_link "$LINENO"; then :
12357   gl_cv_func_ftello=yes
12358 else
12359   gl_cv_func_ftello=no
12360 fi
12361 rm -f core conftest.err conftest.$ac_objext \
12362     conftest$ac_exeext conftest.$ac_ext
12363
12364 fi
12365 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_ftello" >&5
12366 $as_echo "$gl_cv_func_ftello" >&6; }
12367   if test $gl_cv_func_ftello = no; then
12368     HAVE_FTELLO=0
12369   else
12370     if test $WINDOWS_64_BIT_OFF_T = 1; then
12371       REPLACE_FTELLO=1
12372     fi
12373     if test $gl_cv_var_stdin_large_offset = no; then
12374       REPLACE_FTELLO=1
12375     fi
12376     if test $REPLACE_FTELLO = 0; then
12377
12378       { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ftello works" >&5
12379 $as_echo_n "checking whether ftello works... " >&6; }
12380 if ${gl_cv_func_ftello_works+:} false; then :
12381   $as_echo_n "(cached) " >&6
12382 else
12383
12384                               case "$host_os" in
12385                       # Guess no on Solaris.
12386             solaris*) gl_cv_func_ftello_works="guessing no" ;;
12387                       # Guess yes otherwise.
12388             *)        gl_cv_func_ftello_works="guessing yes" ;;
12389           esac
12390           if test "$cross_compiling" = yes; then :
12391   :
12392 else
12393   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12394 /* end confdefs.h.  */
12395
12396 #include <stdio.h>
12397 #include <stdlib.h>
12398 #include <string.h>
12399 #define TESTFILE "conftest.tmp"
12400 int
12401 main (void)
12402 {
12403   FILE *fp;
12404
12405   /* Create a file with some contents.  */
12406   fp = fopen (TESTFILE, "w");
12407   if (fp == NULL)
12408     return 70;
12409   if (fwrite ("foogarsh", 1, 8, fp) < 8)
12410     return 71;
12411   if (fclose (fp))
12412     return 72;
12413
12414   /* The file's contents is now "foogarsh".  */
12415
12416   /* Try writing after reading to EOF.  */
12417   fp = fopen (TESTFILE, "r+");
12418   if (fp == NULL)
12419     return 73;
12420   if (fseek (fp, -1, SEEK_END))
12421     return 74;
12422   if (!(getc (fp) == 'h'))
12423     return 1;
12424   if (!(getc (fp) == EOF))
12425     return 2;
12426   if (!(ftell (fp) == 8))
12427     return 3;
12428   if (!(ftell (fp) == 8))
12429     return 4;
12430   if (!(putc ('!', fp) == '!'))
12431     return 5;
12432   if (!(ftell (fp) == 9))
12433     return 6;
12434   if (!(fclose (fp) == 0))
12435     return 7;
12436   fp = fopen (TESTFILE, "r");
12437   if (fp == NULL)
12438     return 75;
12439   {
12440     char buf[10];
12441     if (!(fread (buf, 1, 10, fp) == 9))
12442       return 10;
12443     if (!(memcmp (buf, "foogarsh!", 9) == 0))
12444       return 11;
12445   }
12446   if (!(fclose (fp) == 0))
12447     return 12;
12448
12449   /* The file's contents is now "foogarsh!".  */
12450
12451   return 0;
12452 }
12453 _ACEOF
12454 if ac_fn_c_try_run "$LINENO"; then :
12455   gl_cv_func_ftello_works=yes
12456 else
12457   gl_cv_func_ftello_works=no
12458 fi
12459 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12460   conftest.$ac_objext conftest.beam conftest.$ac_ext
12461 fi
12462
12463
12464 fi
12465 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_ftello_works" >&5
12466 $as_echo "$gl_cv_func_ftello_works" >&6; }
12467       case "$gl_cv_func_ftello_works" in
12468         *yes) ;;
12469         *)
12470           REPLACE_FTELLO=1
12471
12472 $as_echo "#define FTELLO_BROKEN_AFTER_SWITCHING_FROM_READ_TO_WRITE 1" >>confdefs.h
12473
12474           ;;
12475       esac
12476     fi
12477   fi
12478
12479
12480   GNULIB_GETADDRINFO=0;
12481     HAVE_STRUCT_ADDRINFO=1;
12482   HAVE_DECL_FREEADDRINFO=1;
12483   HAVE_DECL_GAI_STRERROR=1;
12484   HAVE_DECL_GETADDRINFO=1;
12485   HAVE_DECL_GETNAMEINFO=1;
12486   REPLACE_GAI_STRERROR=0;
12487
12488
12489
12490
12491
12492
12493
12494
12495
12496
12497
12498
12499
12500
12501   :
12502
12503
12504
12505
12506
12507
12508
12509
12510      if test $gl_cv_have_include_next = yes; then
12511        gl_cv_next_netdb_h='<'netdb.h'>'
12512      else
12513        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <netdb.h>" >&5
12514 $as_echo_n "checking absolute name of <netdb.h>... " >&6; }
12515 if ${gl_cv_next_netdb_h+:} false; then :
12516   $as_echo_n "(cached) " >&6
12517 else
12518
12519              if test $ac_cv_header_netdb_h = yes; then
12520
12521
12522
12523
12524   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12525 /* end confdefs.h.  */
12526 #include <netdb.h>
12527 _ACEOF
12528                 case "$host_os" in
12529     aix*) gl_absname_cpp="$ac_cpp -C" ;;
12530     *)    gl_absname_cpp="$ac_cpp" ;;
12531   esac
12532
12533   case "$host_os" in
12534     mingw*)
12535                                           gl_dirsep_regex='[/\\]'
12536       ;;
12537     *)
12538       gl_dirsep_regex='\/'
12539       ;;
12540   esac
12541       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
12542   gl_header_literal_regex=`echo 'netdb.h' \
12543                            | sed -e "$gl_make_literal_regex_sed"`
12544   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
12545       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
12546       s|^/[^/]|//&|
12547       p
12548       q
12549     }'
12550
12551         gl_cv_absolute_netdb_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
12552   sed -n "$gl_absolute_header_sed"`
12553
12554            gl_header=$gl_cv_absolute_netdb_h
12555            gl_cv_next_netdb_h='"'$gl_header'"'
12556           else
12557                gl_cv_next_netdb_h='<'netdb.h'>'
12558              fi
12559
12560
12561 fi
12562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_netdb_h" >&5
12563 $as_echo "$gl_cv_next_netdb_h" >&6; }
12564      fi
12565      NEXT_NETDB_H=$gl_cv_next_netdb_h
12566
12567      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
12568        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
12569        gl_next_as_first_directive='<'netdb.h'>'
12570      else
12571        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
12572        gl_next_as_first_directive=$gl_cv_next_netdb_h
12573      fi
12574      NEXT_AS_FIRST_DIRECTIVE_NETDB_H=$gl_next_as_first_directive
12575
12576
12577
12578
12579   if test $ac_cv_header_netdb_h = yes; then
12580     HAVE_NETDB_H=1
12581   else
12582     HAVE_NETDB_H=0
12583   fi
12584
12585
12586
12587
12588
12589                   HOSTENT_LIB=
12590   gl_saved_libs="$LIBS"
12591   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing gethostbyname" >&5
12592 $as_echo_n "checking for library containing gethostbyname... " >&6; }
12593 if ${ac_cv_search_gethostbyname+:} false; then :
12594   $as_echo_n "(cached) " >&6
12595 else
12596   ac_func_search_save_LIBS=$LIBS
12597 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12598 /* end confdefs.h.  */
12599
12600 /* Override any GCC internal prototype to avoid an error.
12601    Use char because int might match the return type of a GCC
12602    builtin and then its argument prototype would still apply.  */
12603 #ifdef __cplusplus
12604 extern "C"
12605 #endif
12606 char gethostbyname ();
12607 int
12608 main ()
12609 {
12610 return gethostbyname ();
12611   ;
12612   return 0;
12613 }
12614 _ACEOF
12615 for ac_lib in '' nsl network net; do
12616   if test -z "$ac_lib"; then
12617     ac_res="none required"
12618   else
12619     ac_res=-l$ac_lib
12620     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
12621   fi
12622   if ac_fn_c_try_link "$LINENO"; then :
12623   ac_cv_search_gethostbyname=$ac_res
12624 fi
12625 rm -f core conftest.err conftest.$ac_objext \
12626     conftest$ac_exeext
12627   if ${ac_cv_search_gethostbyname+:} false; then :
12628   break
12629 fi
12630 done
12631 if ${ac_cv_search_gethostbyname+:} false; then :
12632
12633 else
12634   ac_cv_search_gethostbyname=no
12635 fi
12636 rm conftest.$ac_ext
12637 LIBS=$ac_func_search_save_LIBS
12638 fi
12639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_gethostbyname" >&5
12640 $as_echo "$ac_cv_search_gethostbyname" >&6; }
12641 ac_res=$ac_cv_search_gethostbyname
12642 if test "$ac_res" != no; then :
12643   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
12644   if test "$ac_cv_search_gethostbyname" != "none required"; then
12645        HOSTENT_LIB="$ac_cv_search_gethostbyname"
12646      fi
12647 fi
12648
12649   LIBS="$gl_saved_libs"
12650   if test -z "$HOSTENT_LIB"; then
12651     for ac_func in gethostbyname
12652 do :
12653   ac_fn_c_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname"
12654 if test "x$ac_cv_func_gethostbyname" = xyes; then :
12655   cat >>confdefs.h <<_ACEOF
12656 #define HAVE_GETHOSTBYNAME 1
12657 _ACEOF
12658
12659 else
12660
12661       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in winsock2.h and -lws2_32" >&5
12662 $as_echo_n "checking for gethostbyname in winsock2.h and -lws2_32... " >&6; }
12663 if ${gl_cv_w32_gethostbyname+:} false; then :
12664   $as_echo_n "(cached) " >&6
12665 else
12666   gl_cv_w32_gethostbyname=no
12667          gl_save_LIBS="$LIBS"
12668          LIBS="$LIBS -lws2_32"
12669          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12670 /* end confdefs.h.  */
12671
12672 #ifdef HAVE_WINSOCK2_H
12673 #include <winsock2.h>
12674 #endif
12675 #include <stddef.h>
12676
12677 int
12678 main ()
12679 {
12680 gethostbyname(NULL);
12681   ;
12682   return 0;
12683 }
12684 _ACEOF
12685 if ac_fn_c_try_link "$LINENO"; then :
12686   gl_cv_w32_gethostbyname=yes
12687 fi
12688 rm -f core conftest.err conftest.$ac_objext \
12689     conftest$ac_exeext conftest.$ac_ext
12690          LIBS="$gl_save_LIBS"
12691
12692 fi
12693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_w32_gethostbyname" >&5
12694 $as_echo "$gl_cv_w32_gethostbyname" >&6; }
12695       if test "$gl_cv_w32_gethostbyname" = "yes"; then
12696         HOSTENT_LIB="-lws2_32"
12697       fi
12698
12699 fi
12700 done
12701
12702   fi
12703
12704
12705
12706                       SERVENT_LIB=
12707   gl_saved_libs="$LIBS"
12708   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing getservbyname" >&5
12709 $as_echo_n "checking for library containing getservbyname... " >&6; }
12710 if ${ac_cv_search_getservbyname+:} false; then :
12711   $as_echo_n "(cached) " >&6
12712 else
12713   ac_func_search_save_LIBS=$LIBS
12714 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12715 /* end confdefs.h.  */
12716
12717 /* Override any GCC internal prototype to avoid an error.
12718    Use char because int might match the return type of a GCC
12719    builtin and then its argument prototype would still apply.  */
12720 #ifdef __cplusplus
12721 extern "C"
12722 #endif
12723 char getservbyname ();
12724 int
12725 main ()
12726 {
12727 return getservbyname ();
12728   ;
12729   return 0;
12730 }
12731 _ACEOF
12732 for ac_lib in '' socket network net; do
12733   if test -z "$ac_lib"; then
12734     ac_res="none required"
12735   else
12736     ac_res=-l$ac_lib
12737     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
12738   fi
12739   if ac_fn_c_try_link "$LINENO"; then :
12740   ac_cv_search_getservbyname=$ac_res
12741 fi
12742 rm -f core conftest.err conftest.$ac_objext \
12743     conftest$ac_exeext
12744   if ${ac_cv_search_getservbyname+:} false; then :
12745   break
12746 fi
12747 done
12748 if ${ac_cv_search_getservbyname+:} false; then :
12749
12750 else
12751   ac_cv_search_getservbyname=no
12752 fi
12753 rm conftest.$ac_ext
12754 LIBS=$ac_func_search_save_LIBS
12755 fi
12756 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_getservbyname" >&5
12757 $as_echo "$ac_cv_search_getservbyname" >&6; }
12758 ac_res=$ac_cv_search_getservbyname
12759 if test "$ac_res" != no; then :
12760   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
12761   if test "$ac_cv_search_getservbyname" != "none required"; then
12762        SERVENT_LIB="$ac_cv_search_getservbyname"
12763      fi
12764 fi
12765
12766   LIBS="$gl_saved_libs"
12767   if test -z "$SERVENT_LIB"; then
12768     for ac_func in getservbyname
12769 do :
12770   ac_fn_c_check_func "$LINENO" "getservbyname" "ac_cv_func_getservbyname"
12771 if test "x$ac_cv_func_getservbyname" = xyes; then :
12772   cat >>confdefs.h <<_ACEOF
12773 #define HAVE_GETSERVBYNAME 1
12774 _ACEOF
12775
12776 else
12777
12778       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getservbyname in winsock2.h and -lws2_32" >&5
12779 $as_echo_n "checking for getservbyname in winsock2.h and -lws2_32... " >&6; }
12780 if ${gl_cv_w32_getservbyname+:} false; then :
12781   $as_echo_n "(cached) " >&6
12782 else
12783   gl_cv_w32_getservbyname=no
12784          gl_save_LIBS="$LIBS"
12785          LIBS="$LIBS -lws2_32"
12786          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12787 /* end confdefs.h.  */
12788
12789 #ifdef HAVE_WINSOCK2_H
12790 #include <winsock2.h>
12791 #endif
12792 #include <stddef.h>
12793
12794 int
12795 main ()
12796 {
12797 getservbyname(NULL,NULL);
12798   ;
12799   return 0;
12800 }
12801 _ACEOF
12802 if ac_fn_c_try_link "$LINENO"; then :
12803   gl_cv_w32_getservbyname=yes
12804 fi
12805 rm -f core conftest.err conftest.$ac_objext \
12806     conftest$ac_exeext conftest.$ac_ext
12807          LIBS="$gl_save_LIBS"
12808
12809 fi
12810 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_w32_getservbyname" >&5
12811 $as_echo "$gl_cv_w32_getservbyname" >&6; }
12812       if test "$gl_cv_w32_getservbyname" = "yes"; then
12813         SERVENT_LIB="-lws2_32"
12814       fi
12815
12816 fi
12817 done
12818
12819   fi
12820
12821
12822
12823
12824
12825
12826
12827
12828
12829               HAVE_INET_NTOP=1
12830   INET_NTOP_LIB=
12831
12832
12833
12834
12835   :
12836
12837
12838
12839
12840
12841   if test $ac_cv_header_sys_socket_h != yes; then
12842                     for ac_header in winsock2.h
12843 do :
12844   ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
12845 if test "x$ac_cv_header_winsock2_h" = xyes; then :
12846   cat >>confdefs.h <<_ACEOF
12847 #define HAVE_WINSOCK2_H 1
12848 _ACEOF
12849
12850 fi
12851
12852 done
12853
12854   fi
12855   if test "$ac_cv_header_winsock2_h" = yes; then
12856     HAVE_WINSOCK2_H=1
12857     UNISTD_H_HAVE_WINSOCK2_H=1
12858     SYS_IOCTL_H_HAVE_WINSOCK2_H=1
12859   else
12860     HAVE_WINSOCK2_H=0
12861   fi
12862
12863
12864   if test $HAVE_WINSOCK2_H = 1; then
12865     ac_fn_c_check_decl "$LINENO" "inet_ntop" "ac_cv_have_decl_inet_ntop" "#include <ws2tcpip.h>
12866 "
12867 if test "x$ac_cv_have_decl_inet_ntop" = xyes; then :
12868   ac_have_decl=1
12869 else
12870   ac_have_decl=0
12871 fi
12872
12873 cat >>confdefs.h <<_ACEOF
12874 #define HAVE_DECL_INET_NTOP $ac_have_decl
12875 _ACEOF
12876
12877     if test $ac_cv_have_decl_inet_ntop = yes; then
12878                   REPLACE_INET_NTOP=1
12879       INET_NTOP_LIB="-lws2_32"
12880     else
12881       HAVE_DECL_INET_NTOP=0
12882       HAVE_INET_NTOP=0
12883     fi
12884   else
12885     gl_save_LIBS=$LIBS
12886     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing inet_ntop" >&5
12887 $as_echo_n "checking for library containing inet_ntop... " >&6; }
12888 if ${ac_cv_search_inet_ntop+:} false; then :
12889   $as_echo_n "(cached) " >&6
12890 else
12891   ac_func_search_save_LIBS=$LIBS
12892 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12893 /* end confdefs.h.  */
12894
12895 /* Override any GCC internal prototype to avoid an error.
12896    Use char because int might match the return type of a GCC
12897    builtin and then its argument prototype would still apply.  */
12898 #ifdef __cplusplus
12899 extern "C"
12900 #endif
12901 char inet_ntop ();
12902 int
12903 main ()
12904 {
12905 return inet_ntop ();
12906   ;
12907   return 0;
12908 }
12909 _ACEOF
12910 for ac_lib in '' nsl resolv; do
12911   if test -z "$ac_lib"; then
12912     ac_res="none required"
12913   else
12914     ac_res=-l$ac_lib
12915     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
12916   fi
12917   if ac_fn_c_try_link "$LINENO"; then :
12918   ac_cv_search_inet_ntop=$ac_res
12919 fi
12920 rm -f core conftest.err conftest.$ac_objext \
12921     conftest$ac_exeext
12922   if ${ac_cv_search_inet_ntop+:} false; then :
12923   break
12924 fi
12925 done
12926 if ${ac_cv_search_inet_ntop+:} false; then :
12927
12928 else
12929   ac_cv_search_inet_ntop=no
12930 fi
12931 rm conftest.$ac_ext
12932 LIBS=$ac_func_search_save_LIBS
12933 fi
12934 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inet_ntop" >&5
12935 $as_echo "$ac_cv_search_inet_ntop" >&6; }
12936 ac_res=$ac_cv_search_inet_ntop
12937 if test "$ac_res" != no; then :
12938   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
12939
12940 else
12941   for ac_func in inet_ntop
12942 do :
12943   ac_fn_c_check_func "$LINENO" "inet_ntop" "ac_cv_func_inet_ntop"
12944 if test "x$ac_cv_func_inet_ntop" = xyes; then :
12945   cat >>confdefs.h <<_ACEOF
12946 #define HAVE_INET_NTOP 1
12947 _ACEOF
12948
12949 fi
12950 done
12951
12952        if test $ac_cv_func_inet_ntop = no; then
12953          HAVE_INET_NTOP=0
12954        fi
12955
12956 fi
12957
12958     LIBS=$gl_save_LIBS
12959
12960     if test "$ac_cv_search_inet_ntop" != "no" \
12961        && test "$ac_cv_search_inet_ntop" != "none required"; then
12962       INET_NTOP_LIB="$ac_cv_search_inet_ntop"
12963     fi
12964
12965
12966   :
12967
12968
12969
12970
12971
12972     ac_fn_c_check_decl "$LINENO" "inet_ntop" "ac_cv_have_decl_inet_ntop" "#include <arpa/inet.h>
12973         #if HAVE_NETDB_H
12974         # include <netdb.h>
12975         #endif
12976
12977 "
12978 if test "x$ac_cv_have_decl_inet_ntop" = xyes; then :
12979   ac_have_decl=1
12980 else
12981   ac_have_decl=0
12982 fi
12983
12984 cat >>confdefs.h <<_ACEOF
12985 #define HAVE_DECL_INET_NTOP $ac_have_decl
12986 _ACEOF
12987
12988     if test $ac_cv_have_decl_inet_ntop = no; then
12989       HAVE_DECL_INET_NTOP=0
12990     fi
12991   fi
12992
12993
12994
12995
12996
12997
12998
12999
13000
13001
13002   :
13003
13004
13005
13006
13007
13008
13009   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IPv4 sockets" >&5
13010 $as_echo_n "checking for IPv4 sockets... " >&6; }
13011   if ${gl_cv_socket_ipv4+:} false; then :
13012   $as_echo_n "(cached) " >&6
13013 else
13014   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13015 /* end confdefs.h.  */
13016 #include <sys/types.h>
13017 #ifdef HAVE_SYS_SOCKET_H
13018 #include <sys/socket.h>
13019 #endif
13020 #ifdef HAVE_NETINET_IN_H
13021 #include <netinet/in.h>
13022 #endif
13023 #ifdef HAVE_WINSOCK2_H
13024 #include <winsock2.h>
13025 #endif
13026 int
13027 main ()
13028 {
13029 int x = AF_INET; struct in_addr y; struct sockaddr_in z;
13030  if (&x && &y && &z) return 0;
13031   ;
13032   return 0;
13033 }
13034 _ACEOF
13035 if ac_fn_c_try_compile "$LINENO"; then :
13036   gl_cv_socket_ipv4=yes
13037 else
13038   gl_cv_socket_ipv4=no
13039 fi
13040 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13041 fi
13042
13043   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_socket_ipv4" >&5
13044 $as_echo "$gl_cv_socket_ipv4" >&6; }
13045   if test $gl_cv_socket_ipv4 = yes; then
13046
13047 $as_echo "#define HAVE_IPV4 1" >>confdefs.h
13048
13049   fi
13050
13051   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IPv6 sockets" >&5
13052 $as_echo_n "checking for IPv6 sockets... " >&6; }
13053   if ${gl_cv_socket_ipv6+:} false; then :
13054   $as_echo_n "(cached) " >&6
13055 else
13056   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13057 /* end confdefs.h.  */
13058 #include <sys/types.h>
13059 #ifdef HAVE_SYS_SOCKET_H
13060 #include <sys/socket.h>
13061 #endif
13062 #ifdef HAVE_NETINET_IN_H
13063 #include <netinet/in.h>
13064 #endif
13065 #ifdef HAVE_WINSOCK2_H
13066 #include <winsock2.h>
13067 #endif
13068 #ifdef HAVE_WS2TCPIP_H
13069 #include <ws2tcpip.h>
13070 #endif
13071 int
13072 main ()
13073 {
13074 int x = AF_INET6; struct in6_addr y; struct sockaddr_in6 z;
13075  if (&x && &y && &z) return 0;
13076   ;
13077   return 0;
13078 }
13079 _ACEOF
13080 if ac_fn_c_try_compile "$LINENO"; then :
13081   gl_cv_socket_ipv6=yes
13082 else
13083   gl_cv_socket_ipv6=no
13084 fi
13085 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13086 fi
13087
13088   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_socket_ipv6" >&5
13089 $as_echo "$gl_cv_socket_ipv6" >&6; }
13090   if test $gl_cv_socket_ipv6 = yes; then
13091
13092 $as_echo "#define HAVE_IPV6 1" >>confdefs.h
13093
13094   fi
13095
13096
13097
13098   :
13099
13100
13101
13102
13103
13104    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getcwd (NULL, 0) allocates memory for result" >&5
13105 $as_echo_n "checking whether getcwd (NULL, 0) allocates memory for result... " >&6; }
13106 if ${gl_cv_func_getcwd_null+:} false; then :
13107   $as_echo_n "(cached) " >&6
13108 else
13109   if test "$cross_compiling" = yes; then :
13110   case "$host_os" in
13111                      # Guess yes on glibc systems.
13112             *-gnu*)  gl_cv_func_getcwd_null="guessing yes";;
13113                      # Guess yes on Cygwin.
13114             cygwin*) gl_cv_func_getcwd_null="guessing yes";;
13115                      # If we don't know, assume the worst.
13116             *)       gl_cv_func_getcwd_null="guessing no";;
13117           esac
13118
13119 else
13120   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13121 /* end confdefs.h.  */
13122
13123 #        if HAVE_UNISTD_H
13124 #         include <unistd.h>
13125 #        else /* on Windows with MSVC */
13126 #         include <direct.h>
13127 #        endif
13128 #        ifndef getcwd
13129          char *getcwd ();
13130 #        endif
13131
13132 int
13133 main ()
13134 {
13135
13136 #if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
13137 /* mingw cwd does not start with '/', but getcwd does allocate.
13138    However, mingw fails to honor non-zero size.  */
13139 #else
13140            if (chdir ("/") != 0)
13141              return 1;
13142            else
13143              {
13144                char *f = getcwd (NULL, 0);
13145                if (! f)
13146                  return 2;
13147                if (f[0] != '/')
13148                  return 3;
13149                if (f[1] != '\0')
13150                  return 4;
13151                return 0;
13152              }
13153 #endif
13154
13155   ;
13156   return 0;
13157 }
13158 _ACEOF
13159 if ac_fn_c_try_run "$LINENO"; then :
13160   gl_cv_func_getcwd_null=yes
13161 else
13162   gl_cv_func_getcwd_null=no
13163 fi
13164 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13165   conftest.$ac_objext conftest.beam conftest.$ac_ext
13166 fi
13167
13168 fi
13169 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getcwd_null" >&5
13170 $as_echo "$gl_cv_func_getcwd_null" >&6; }
13171
13172
13173   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getcwd with POSIX signature" >&5
13174 $as_echo_n "checking for getcwd with POSIX signature... " >&6; }
13175 if ${gl_cv_func_getcwd_posix_signature+:} false; then :
13176   $as_echo_n "(cached) " >&6
13177 else
13178   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13179 /* end confdefs.h.  */
13180 #include <unistd.h>
13181 int
13182 main ()
13183 {
13184 extern
13185            #ifdef __cplusplus
13186            "C"
13187            #endif
13188            char *getcwd (char *, size_t);
13189
13190   ;
13191   return 0;
13192 }
13193
13194 _ACEOF
13195 if ac_fn_c_try_compile "$LINENO"; then :
13196   gl_cv_func_getcwd_posix_signature=yes
13197 else
13198   gl_cv_func_getcwd_posix_signature=no
13199 fi
13200 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13201
13202 fi
13203 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getcwd_posix_signature" >&5
13204 $as_echo "$gl_cv_func_getcwd_posix_signature" >&6; }
13205
13206
13207       ac_fn_c_check_decl "$LINENO" "getdelim" "ac_cv_have_decl_getdelim" "$ac_includes_default"
13208 if test "x$ac_cv_have_decl_getdelim" = xyes; then :
13209   ac_have_decl=1
13210 else
13211   ac_have_decl=0
13212 fi
13213
13214 cat >>confdefs.h <<_ACEOF
13215 #define HAVE_DECL_GETDELIM $ac_have_decl
13216 _ACEOF
13217
13218
13219
13220
13221
13222
13223
13224
13225
13226
13227
13228
13229 { $as_echo "$as_me:${as_lineno-$LINENO}: checking type of array argument to getgroups" >&5
13230 $as_echo_n "checking type of array argument to getgroups... " >&6; }
13231 if ${ac_cv_type_getgroups+:} false; then :
13232   $as_echo_n "(cached) " >&6
13233 else
13234   if test "$cross_compiling" = yes; then :
13235   ac_cv_type_getgroups=cross
13236 else
13237   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13238 /* end confdefs.h.  */
13239 /* Thanks to Mike Rendell for this test.  */
13240 $ac_includes_default
13241 #define NGID 256
13242 #undef MAX
13243 #define MAX(x, y) ((x) > (y) ? (x) : (y))
13244
13245 int
13246 main ()
13247 {
13248   gid_t gidset[NGID];
13249   int i, n;
13250   union { gid_t gval; long int lval; }  val;
13251
13252   val.lval = -1;
13253   for (i = 0; i < NGID; i++)
13254     gidset[i] = val.gval;
13255   n = getgroups (sizeof (gidset) / MAX (sizeof (int), sizeof (gid_t)) - 1,
13256                  gidset);
13257   /* Exit non-zero if getgroups seems to require an array of ints.  This
13258      happens when gid_t is short int but getgroups modifies an array
13259      of ints.  */
13260   return n > 0 && gidset[n] != val.gval;
13261 }
13262 _ACEOF
13263 if ac_fn_c_try_run "$LINENO"; then :
13264   ac_cv_type_getgroups=gid_t
13265 else
13266   ac_cv_type_getgroups=int
13267 fi
13268 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13269   conftest.$ac_objext conftest.beam conftest.$ac_ext
13270 fi
13271
13272 if test $ac_cv_type_getgroups = cross; then
13273         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13274 /* end confdefs.h.  */
13275 #include <unistd.h>
13276
13277 _ACEOF
13278 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13279   $EGREP "getgroups.*int.*gid_t" >/dev/null 2>&1; then :
13280   ac_cv_type_getgroups=gid_t
13281 else
13282   ac_cv_type_getgroups=int
13283 fi
13284 rm -f conftest*
13285
13286 fi
13287 fi
13288 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_getgroups" >&5
13289 $as_echo "$ac_cv_type_getgroups" >&6; }
13290
13291 cat >>confdefs.h <<_ACEOF
13292 #define GETGROUPS_T $ac_cv_type_getgroups
13293 _ACEOF
13294
13295
13296
13297       ac_fn_c_check_decl "$LINENO" "getline" "ac_cv_have_decl_getline" "$ac_includes_default"
13298 if test "x$ac_cv_have_decl_getline" = xyes; then :
13299   ac_have_decl=1
13300 else
13301   ac_have_decl=0
13302 fi
13303
13304 cat >>confdefs.h <<_ACEOF
13305 #define HAVE_DECL_GETLINE $ac_have_decl
13306 _ACEOF
13307
13308
13309
13310       ac_fn_c_check_decl "$LINENO" "getpass" "ac_cv_have_decl_getpass" "$ac_includes_default"
13311 if test "x$ac_cv_have_decl_getpass" = xyes; then :
13312   ac_have_decl=1
13313 else
13314   ac_have_decl=0
13315 fi
13316
13317 cat >>confdefs.h <<_ACEOF
13318 #define HAVE_DECL_GETPASS $ac_have_decl
13319 _ACEOF
13320
13321
13322
13323
13324
13325
13326
13327
13328
13329
13330
13331
13332
13333
13334
13335
13336
13337
13338
13339
13340
13341
13342
13343
13344
13345
13346
13347
13348       ac_fn_c_check_decl "$LINENO" "fflush_unlocked" "ac_cv_have_decl_fflush_unlocked" "$ac_includes_default"
13349 if test "x$ac_cv_have_decl_fflush_unlocked" = xyes; then :
13350   ac_have_decl=1
13351 else
13352   ac_have_decl=0
13353 fi
13354
13355 cat >>confdefs.h <<_ACEOF
13356 #define HAVE_DECL_FFLUSH_UNLOCKED $ac_have_decl
13357 _ACEOF
13358
13359
13360
13361       ac_fn_c_check_decl "$LINENO" "flockfile" "ac_cv_have_decl_flockfile" "$ac_includes_default"
13362 if test "x$ac_cv_have_decl_flockfile" = xyes; then :
13363   ac_have_decl=1
13364 else
13365   ac_have_decl=0
13366 fi
13367
13368 cat >>confdefs.h <<_ACEOF
13369 #define HAVE_DECL_FLOCKFILE $ac_have_decl
13370 _ACEOF
13371
13372
13373
13374       ac_fn_c_check_decl "$LINENO" "fputs_unlocked" "ac_cv_have_decl_fputs_unlocked" "$ac_includes_default"
13375 if test "x$ac_cv_have_decl_fputs_unlocked" = xyes; then :
13376   ac_have_decl=1
13377 else
13378   ac_have_decl=0
13379 fi
13380
13381 cat >>confdefs.h <<_ACEOF
13382 #define HAVE_DECL_FPUTS_UNLOCKED $ac_have_decl
13383 _ACEOF
13384
13385
13386
13387       ac_fn_c_check_decl "$LINENO" "funlockfile" "ac_cv_have_decl_funlockfile" "$ac_includes_default"
13388 if test "x$ac_cv_have_decl_funlockfile" = xyes; then :
13389   ac_have_decl=1
13390 else
13391   ac_have_decl=0
13392 fi
13393
13394 cat >>confdefs.h <<_ACEOF
13395 #define HAVE_DECL_FUNLOCKFILE $ac_have_decl
13396 _ACEOF
13397
13398
13399
13400       ac_fn_c_check_decl "$LINENO" "putc_unlocked" "ac_cv_have_decl_putc_unlocked" "$ac_includes_default"
13401 if test "x$ac_cv_have_decl_putc_unlocked" = xyes; then :
13402   ac_have_decl=1
13403 else
13404   ac_have_decl=0
13405 fi
13406
13407 cat >>confdefs.h <<_ACEOF
13408 #define HAVE_DECL_PUTC_UNLOCKED $ac_have_decl
13409 _ACEOF
13410
13411
13412
13413   GNULIB_GETTIMEOFDAY=0;
13414     HAVE_GETTIMEOFDAY=1;
13415   HAVE_STRUCT_TIMEVAL=1;
13416   HAVE_SYS_TIME_H=1;
13417   REPLACE_GETTIMEOFDAY=0;
13418   REPLACE_STRUCT_TIMEVAL=0;
13419
13420
13421
13422
13423
13424
13425
13426
13427
13428
13429   :
13430
13431
13432
13433
13434
13435
13436
13437
13438
13439
13440
13441   :
13442
13443
13444
13445
13446
13447
13448
13449
13450      if test $gl_cv_have_include_next = yes; then
13451        gl_cv_next_sys_time_h='<'sys/time.h'>'
13452      else
13453        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/time.h>" >&5
13454 $as_echo_n "checking absolute name of <sys/time.h>... " >&6; }
13455 if ${gl_cv_next_sys_time_h+:} false; then :
13456   $as_echo_n "(cached) " >&6
13457 else
13458
13459              if test $ac_cv_header_sys_time_h = yes; then
13460
13461
13462
13463
13464   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13465 /* end confdefs.h.  */
13466 #include <sys/time.h>
13467 _ACEOF
13468                 case "$host_os" in
13469     aix*) gl_absname_cpp="$ac_cpp -C" ;;
13470     *)    gl_absname_cpp="$ac_cpp" ;;
13471   esac
13472
13473   case "$host_os" in
13474     mingw*)
13475                                           gl_dirsep_regex='[/\\]'
13476       ;;
13477     *)
13478       gl_dirsep_regex='\/'
13479       ;;
13480   esac
13481       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
13482   gl_header_literal_regex=`echo 'sys/time.h' \
13483                            | sed -e "$gl_make_literal_regex_sed"`
13484   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
13485       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
13486       s|^/[^/]|//&|
13487       p
13488       q
13489     }'
13490
13491         gl_cv_absolute_sys_time_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
13492   sed -n "$gl_absolute_header_sed"`
13493
13494            gl_header=$gl_cv_absolute_sys_time_h
13495            gl_cv_next_sys_time_h='"'$gl_header'"'
13496           else
13497                gl_cv_next_sys_time_h='<'sys/time.h'>'
13498              fi
13499
13500
13501 fi
13502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_time_h" >&5
13503 $as_echo "$gl_cv_next_sys_time_h" >&6; }
13504      fi
13505      NEXT_SYS_TIME_H=$gl_cv_next_sys_time_h
13506
13507      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
13508        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
13509        gl_next_as_first_directive='<'sys/time.h'>'
13510      else
13511        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
13512        gl_next_as_first_directive=$gl_cv_next_sys_time_h
13513      fi
13514      NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H=$gl_next_as_first_directive
13515
13516
13517
13518
13519
13520   if test $ac_cv_header_sys_time_h != yes; then
13521     HAVE_SYS_TIME_H=0
13522   fi
13523
13524
13525
13526
13527
13528   :
13529
13530
13531
13532
13533
13534   if test $ac_cv_header_sys_socket_h != yes; then
13535                     for ac_header in winsock2.h
13536 do :
13537   ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
13538 if test "x$ac_cv_header_winsock2_h" = xyes; then :
13539   cat >>confdefs.h <<_ACEOF
13540 #define HAVE_WINSOCK2_H 1
13541 _ACEOF
13542
13543 fi
13544
13545 done
13546
13547   fi
13548   if test "$ac_cv_header_winsock2_h" = yes; then
13549     HAVE_WINSOCK2_H=1
13550     UNISTD_H_HAVE_WINSOCK2_H=1
13551     SYS_IOCTL_H_HAVE_WINSOCK2_H=1
13552   else
13553     HAVE_WINSOCK2_H=0
13554   fi
13555
13556
13557   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
13558 $as_echo_n "checking for struct timeval... " >&6; }
13559 if ${gl_cv_sys_struct_timeval+:} false; then :
13560   $as_echo_n "(cached) " >&6
13561 else
13562   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13563 /* end confdefs.h.  */
13564 #if HAVE_SYS_TIME_H
13565              #include <sys/time.h>
13566             #endif
13567             #include <time.h>
13568             #if HAVE_WINSOCK2_H
13569             # include <winsock2.h>
13570             #endif
13571
13572 int
13573 main ()
13574 {
13575 static struct timeval x; x.tv_sec = x.tv_usec;
13576   ;
13577   return 0;
13578 }
13579 _ACEOF
13580 if ac_fn_c_try_compile "$LINENO"; then :
13581   gl_cv_sys_struct_timeval=yes
13582 else
13583   gl_cv_sys_struct_timeval=no
13584 fi
13585 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13586
13587 fi
13588 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval" >&5
13589 $as_echo "$gl_cv_sys_struct_timeval" >&6; }
13590   if test $gl_cv_sys_struct_timeval != yes; then
13591     HAVE_STRUCT_TIMEVAL=0
13592   else
13593                             { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wide-enough struct timeval.tv_sec member" >&5
13594 $as_echo_n "checking for wide-enough struct timeval.tv_sec member... " >&6; }
13595 if ${gl_cv_sys_struct_timeval_tv_sec+:} false; then :
13596   $as_echo_n "(cached) " >&6
13597 else
13598   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13599 /* end confdefs.h.  */
13600 #if HAVE_SYS_TIME_H
13601                #include <sys/time.h>
13602               #endif
13603               #include <time.h>
13604               #if HAVE_WINSOCK2_H
13605               # include <winsock2.h>
13606               #endif
13607
13608 int
13609 main ()
13610 {
13611 static struct timeval x;
13612               typedef int verify_tv_sec_type[
13613                 sizeof (time_t) <= sizeof x.tv_sec ? 1 : -1
13614               ];
13615
13616   ;
13617   return 0;
13618 }
13619 _ACEOF
13620 if ac_fn_c_try_compile "$LINENO"; then :
13621   gl_cv_sys_struct_timeval_tv_sec=yes
13622 else
13623   gl_cv_sys_struct_timeval_tv_sec=no
13624 fi
13625 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13626
13627 fi
13628 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval_tv_sec" >&5
13629 $as_echo "$gl_cv_sys_struct_timeval_tv_sec" >&6; }
13630     if test $gl_cv_sys_struct_timeval_tv_sec != yes; then
13631       REPLACE_STRUCT_TIMEVAL=1
13632     fi
13633   fi
13634
13635
13636
13637
13638
13639
13640
13641
13642
13643
13644
13645
13646
13647
13648
13649
13650
13651   GNULIB_NL_LANGINFO=0;
13652     HAVE_NL_LANGINFO=1;
13653   REPLACE_NL_LANGINFO=0;
13654
13655
13656
13657
13658
13659
13660
13661   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ldexp() can be used without linking with libm" >&5
13662 $as_echo_n "checking whether ldexp() can be used without linking with libm... " >&6; }
13663 if ${gl_cv_func_ldexp_no_libm+:} false; then :
13664   $as_echo_n "(cached) " >&6
13665 else
13666
13667       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13668 /* end confdefs.h.  */
13669 #ifndef __NO_MATH_INLINES
13670                            # define __NO_MATH_INLINES 1 /* for glibc */
13671                            #endif
13672                            #include <math.h>
13673                            double (*funcptr) (double, int) = ldexp;
13674                            double x;
13675 int
13676 main ()
13677 {
13678 return ldexp (x, -1) > 0;
13679   ;
13680   return 0;
13681 }
13682 _ACEOF
13683 if ac_fn_c_try_link "$LINENO"; then :
13684   gl_cv_func_ldexp_no_libm=yes
13685 else
13686   gl_cv_func_ldexp_no_libm=no
13687 fi
13688 rm -f core conftest.err conftest.$ac_objext \
13689     conftest$ac_exeext conftest.$ac_ext
13690
13691 fi
13692 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_ldexp_no_libm" >&5
13693 $as_echo "$gl_cv_func_ldexp_no_libm" >&6; }
13694
13695
13696       ac_fn_c_check_decl "$LINENO" "getc_unlocked" "ac_cv_have_decl_getc_unlocked" "$ac_includes_default"
13697 if test "x$ac_cv_have_decl_getc_unlocked" = xyes; then :
13698   ac_have_decl=1
13699 else
13700   ac_have_decl=0
13701 fi
13702
13703 cat >>confdefs.h <<_ACEOF
13704 #define HAVE_DECL_GETC_UNLOCKED $ac_have_decl
13705 _ACEOF
13706
13707
13708
13709     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C Library >= 2.1 or uClibc" >&5
13710 $as_echo_n "checking whether we are using the GNU C Library >= 2.1 or uClibc... " >&6; }
13711 if ${ac_cv_gnu_library_2_1+:} false; then :
13712   $as_echo_n "(cached) " >&6
13713 else
13714   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13715 /* end confdefs.h.  */
13716
13717 #include <features.h>
13718 #ifdef __GNU_LIBRARY__
13719  #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2)
13720   Lucky GNU user
13721  #endif
13722 #endif
13723 #ifdef __UCLIBC__
13724  Lucky user
13725 #endif
13726
13727 _ACEOF
13728 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13729   $EGREP "Lucky" >/dev/null 2>&1; then :
13730   ac_cv_gnu_library_2_1=yes
13731 else
13732   ac_cv_gnu_library_2_1=no
13733 fi
13734 rm -f conftest*
13735
13736
13737
13738 fi
13739 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gnu_library_2_1" >&5
13740 $as_echo "$ac_cv_gnu_library_2_1" >&6; }
13741
13742     GLIBC21="$ac_cv_gnu_library_2_1"
13743
13744
13745
13746   GNULIB_LOCALECONV=0;
13747   GNULIB_SETLOCALE=0;
13748   GNULIB_DUPLOCALE=0;
13749     HAVE_DUPLOCALE=1;
13750   REPLACE_LOCALECONV=0;
13751   REPLACE_SETLOCALE=0;
13752   REPLACE_DUPLOCALE=0;
13753   REPLACE_STRUCT_LCONV=0;
13754
13755
13756     REPLACE_NULL=0;
13757   HAVE_WCHAR_T=1;
13758
13759
13760   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5
13761 $as_echo_n "checking for wchar_t... " >&6; }
13762 if ${gt_cv_c_wchar_t+:} false; then :
13763   $as_echo_n "(cached) " >&6
13764 else
13765   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13766 /* end confdefs.h.  */
13767 #include <stddef.h>
13768             wchar_t foo = (wchar_t)'\0';
13769 int
13770 main ()
13771 {
13772
13773   ;
13774   return 0;
13775 }
13776 _ACEOF
13777 if ac_fn_c_try_compile "$LINENO"; then :
13778   gt_cv_c_wchar_t=yes
13779 else
13780   gt_cv_c_wchar_t=no
13781 fi
13782 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13783 fi
13784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5
13785 $as_echo "$gt_cv_c_wchar_t" >&6; }
13786   if test $gt_cv_c_wchar_t = yes; then
13787
13788 $as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h
13789
13790   fi
13791
13792
13793
13794
13795   STDDEF_H=
13796   if test $gt_cv_c_wchar_t = no; then
13797     HAVE_WCHAR_T=0
13798     STDDEF_H=stddef.h
13799   fi
13800   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
13801 $as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
13802 if ${gl_cv_decl_null_works+:} false; then :
13803   $as_echo_n "(cached) " >&6
13804 else
13805   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13806 /* end confdefs.h.  */
13807 #include <stddef.h>
13808       int test[2 * (sizeof NULL == sizeof (void *)) -1];
13809
13810 int
13811 main ()
13812 {
13813
13814   ;
13815   return 0;
13816 }
13817 _ACEOF
13818 if ac_fn_c_try_compile "$LINENO"; then :
13819   gl_cv_decl_null_works=yes
13820 else
13821   gl_cv_decl_null_works=no
13822 fi
13823 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13824 fi
13825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
13826 $as_echo "$gl_cv_decl_null_works" >&6; }
13827   if test $gl_cv_decl_null_works = no; then
13828     REPLACE_NULL=1
13829     STDDEF_H=stddef.h
13830   fi
13831
13832    if test -n "$STDDEF_H"; then
13833   GL_GENERATE_STDDEF_H_TRUE=
13834   GL_GENERATE_STDDEF_H_FALSE='#'
13835 else
13836   GL_GENERATE_STDDEF_H_TRUE='#'
13837   GL_GENERATE_STDDEF_H_FALSE=
13838 fi
13839
13840   if test -n "$STDDEF_H"; then
13841
13842
13843
13844
13845
13846
13847
13848
13849      if test $gl_cv_have_include_next = yes; then
13850        gl_cv_next_stddef_h='<'stddef.h'>'
13851      else
13852        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
13853 $as_echo_n "checking absolute name of <stddef.h>... " >&6; }
13854 if ${gl_cv_next_stddef_h+:} false; then :
13855   $as_echo_n "(cached) " >&6
13856 else
13857
13858
13859
13860   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13861 /* end confdefs.h.  */
13862 #include <stddef.h>
13863 _ACEOF
13864                 case "$host_os" in
13865     aix*) gl_absname_cpp="$ac_cpp -C" ;;
13866     *)    gl_absname_cpp="$ac_cpp" ;;
13867   esac
13868
13869   case "$host_os" in
13870     mingw*)
13871                                           gl_dirsep_regex='[/\\]'
13872       ;;
13873     *)
13874       gl_dirsep_regex='\/'
13875       ;;
13876   esac
13877       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
13878   gl_header_literal_regex=`echo 'stddef.h' \
13879                            | sed -e "$gl_make_literal_regex_sed"`
13880   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
13881       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
13882       s|^/[^/]|//&|
13883       p
13884       q
13885     }'
13886
13887         gl_cv_absolute_stddef_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
13888   sed -n "$gl_absolute_header_sed"`
13889
13890            gl_header=$gl_cv_absolute_stddef_h
13891            gl_cv_next_stddef_h='"'$gl_header'"'
13892
13893
13894 fi
13895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
13896 $as_echo "$gl_cv_next_stddef_h" >&6; }
13897      fi
13898      NEXT_STDDEF_H=$gl_cv_next_stddef_h
13899
13900      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
13901        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
13902        gl_next_as_first_directive='<'stddef.h'>'
13903      else
13904        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
13905        gl_next_as_first_directive=$gl_cv_next_stddef_h
13906      fi
13907      NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
13908
13909
13910
13911
13912   fi
13913
13914
13915
13916
13917
13918
13919
13920       if test "X$prefix" = "XNONE"; then
13921     acl_final_prefix="$ac_default_prefix"
13922   else
13923     acl_final_prefix="$prefix"
13924   fi
13925   if test "X$exec_prefix" = "XNONE"; then
13926     acl_final_exec_prefix='${prefix}'
13927   else
13928     acl_final_exec_prefix="$exec_prefix"
13929   fi
13930   acl_save_prefix="$prefix"
13931   prefix="$acl_final_prefix"
13932   eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
13933   prefix="$acl_save_prefix"
13934
13935
13936
13937 # Check whether --with-gnu-ld was given.
13938 if test "${with_gnu_ld+set}" = set; then :
13939   withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
13940 else
13941   with_gnu_ld=no
13942 fi
13943
13944 # Prepare PATH_SEPARATOR.
13945 # The user is always right.
13946 if test "${PATH_SEPARATOR+set}" != set; then
13947   # Determine PATH_SEPARATOR by trying to find /bin/sh in a PATH which
13948   # contains only /bin. Note that ksh looks also at the FPATH variable,
13949   # so we have to set that as well for the test.
13950   PATH_SEPARATOR=:
13951   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
13952     && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
13953            || PATH_SEPARATOR=';'
13954        }
13955 fi
13956
13957 ac_prog=ld
13958 if test "$GCC" = yes; then
13959   # Check if gcc -print-prog-name=ld gives a path.
13960   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
13961 $as_echo_n "checking for ld used by $CC... " >&6; }
13962   case $host in
13963   *-*-mingw*)
13964     # gcc leaves a trailing carriage return which upsets mingw
13965     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
13966   *)
13967     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
13968   esac
13969   case $ac_prog in
13970     # Accept absolute paths.
13971     [\\/]* | ?:[\\/]*)
13972       re_direlt='/[^/][^/]*/\.\./'
13973       # Canonicalize the pathname of ld
13974       ac_prog=`echo "$ac_prog"| sed 's%\\\\%/%g'`
13975       while echo "$ac_prog" | grep "$re_direlt" > /dev/null 2>&1; do
13976         ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
13977       done
13978       test -z "$LD" && LD="$ac_prog"
13979       ;;
13980   "")
13981     # If it fails, then pretend we aren't using GCC.
13982     ac_prog=ld
13983     ;;
13984   *)
13985     # If it is relative, then search for the first ld in PATH.
13986     with_gnu_ld=unknown
13987     ;;
13988   esac
13989 elif test "$with_gnu_ld" = yes; then
13990   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
13991 $as_echo_n "checking for GNU ld... " >&6; }
13992 else
13993   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
13994 $as_echo_n "checking for non-GNU ld... " >&6; }
13995 fi
13996 if ${acl_cv_path_LD+:} false; then :
13997   $as_echo_n "(cached) " >&6
13998 else
13999   if test -z "$LD"; then
14000   acl_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
14001   for ac_dir in $PATH; do
14002     IFS="$acl_save_ifs"
14003     test -z "$ac_dir" && ac_dir=.
14004     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
14005       acl_cv_path_LD="$ac_dir/$ac_prog"
14006       # Check to see if the program is GNU ld.  I'd rather use --version,
14007       # but apparently some variants of GNU ld only accept -v.
14008       # Break only if it was the GNU/non-GNU ld that we prefer.
14009       case `"$acl_cv_path_LD" -v 2>&1 </dev/null` in
14010       *GNU* | *'with BFD'*)
14011         test "$with_gnu_ld" != no && break
14012         ;;
14013       *)
14014         test "$with_gnu_ld" != yes && break
14015         ;;
14016       esac
14017     fi
14018   done
14019   IFS="$acl_save_ifs"
14020 else
14021   acl_cv_path_LD="$LD" # Let the user override the test with a path.
14022 fi
14023 fi
14024
14025 LD="$acl_cv_path_LD"
14026 if test -n "$LD"; then
14027   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
14028 $as_echo "$LD" >&6; }
14029 else
14030   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14031 $as_echo "no" >&6; }
14032 fi
14033 test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
14034 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
14035 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
14036 if ${acl_cv_prog_gnu_ld+:} false; then :
14037   $as_echo_n "(cached) " >&6
14038 else
14039   # I'd rather use --version here, but apparently some GNU lds only accept -v.
14040 case `$LD -v 2>&1 </dev/null` in
14041 *GNU* | *'with BFD'*)
14042   acl_cv_prog_gnu_ld=yes
14043   ;;
14044 *)
14045   acl_cv_prog_gnu_ld=no
14046   ;;
14047 esac
14048 fi
14049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_prog_gnu_ld" >&5
14050 $as_echo "$acl_cv_prog_gnu_ld" >&6; }
14051 with_gnu_ld=$acl_cv_prog_gnu_ld
14052
14053
14054
14055
14056                                                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5
14057 $as_echo_n "checking for shared library run path origin... " >&6; }
14058 if ${acl_cv_rpath+:} false; then :
14059   $as_echo_n "(cached) " >&6
14060 else
14061
14062     CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
14063     ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
14064     . ./conftest.sh
14065     rm -f ./conftest.sh
14066     acl_cv_rpath=done
14067
14068 fi
14069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_rpath" >&5
14070 $as_echo "$acl_cv_rpath" >&6; }
14071   wl="$acl_cv_wl"
14072   acl_libext="$acl_cv_libext"
14073   acl_shlibext="$acl_cv_shlibext"
14074   acl_libname_spec="$acl_cv_libname_spec"
14075   acl_library_names_spec="$acl_cv_library_names_spec"
14076   acl_hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
14077   acl_hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
14078   acl_hardcode_direct="$acl_cv_hardcode_direct"
14079   acl_hardcode_minus_L="$acl_cv_hardcode_minus_L"
14080     # Check whether --enable-rpath was given.
14081 if test "${enable_rpath+set}" = set; then :
14082   enableval=$enable_rpath; :
14083 else
14084   enable_rpath=yes
14085 fi
14086
14087
14088
14089
14090   acl_libdirstem=lib
14091   acl_libdirstem2=
14092   case "$host_os" in
14093     solaris*)
14094                                     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for 64-bit host" >&5
14095 $as_echo_n "checking for 64-bit host... " >&6; }
14096 if ${gl_cv_solaris_64bit+:} false; then :
14097   $as_echo_n "(cached) " >&6
14098 else
14099   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14100 /* end confdefs.h.  */
14101
14102 #ifdef _LP64
14103 sixtyfour bits
14104 #endif
14105
14106 _ACEOF
14107 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14108   $EGREP "sixtyfour bits" >/dev/null 2>&1; then :
14109   gl_cv_solaris_64bit=yes
14110 else
14111   gl_cv_solaris_64bit=no
14112 fi
14113 rm -f conftest*
14114
14115
14116 fi
14117 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_solaris_64bit" >&5
14118 $as_echo "$gl_cv_solaris_64bit" >&6; }
14119       if test $gl_cv_solaris_64bit = yes; then
14120         acl_libdirstem=lib/64
14121         case "$host_cpu" in
14122           sparc*)        acl_libdirstem2=lib/sparcv9 ;;
14123           i*86 | x86_64) acl_libdirstem2=lib/amd64 ;;
14124         esac
14125       fi
14126       ;;
14127     *)
14128       searchpath=`(LC_ALL=C $CC -print-search-dirs) 2>/dev/null | sed -n -e 's,^libraries: ,,p' | sed -e 's,^=,,'`
14129       if test -n "$searchpath"; then
14130         acl_save_IFS="${IFS=    }"; IFS=":"
14131         for searchdir in $searchpath; do
14132           if test -d "$searchdir"; then
14133             case "$searchdir" in
14134               */lib64/ | */lib64 ) acl_libdirstem=lib64 ;;
14135               */../ | */.. )
14136                 # Better ignore directories of this form. They are misleading.
14137                 ;;
14138               *) searchdir=`cd "$searchdir" && pwd`
14139                  case "$searchdir" in
14140                    */lib64 ) acl_libdirstem=lib64 ;;
14141                  esac ;;
14142             esac
14143           fi
14144         done
14145         IFS="$acl_save_IFS"
14146       fi
14147       ;;
14148   esac
14149   test -n "$acl_libdirstem2" || acl_libdirstem2="$acl_libdirstem"
14150
14151
14152
14153   gl_threads_api=none
14154   LIBTHREAD=
14155   LTLIBTHREAD=
14156   LIBMULTITHREAD=
14157   LTLIBMULTITHREAD=
14158   if test "$gl_use_threads" != no; then
14159         { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether imported symbols can be declared weak" >&5
14160 $as_echo_n "checking whether imported symbols can be declared weak... " >&6; }
14161 if ${gl_cv_have_weak+:} false; then :
14162   $as_echo_n "(cached) " >&6
14163 else
14164   gl_cv_have_weak=no
14165               cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14166 /* end confdefs.h.  */
14167 extern void xyzzy ();
14168 #pragma weak xyzzy
14169 int
14170 main ()
14171 {
14172 xyzzy();
14173   ;
14174   return 0;
14175 }
14176 _ACEOF
14177 if ac_fn_c_try_link "$LINENO"; then :
14178   gl_cv_have_weak=maybe
14179 fi
14180 rm -f core conftest.err conftest.$ac_objext \
14181     conftest$ac_exeext conftest.$ac_ext
14182        if test $gl_cv_have_weak = maybe; then
14183                            if test "$cross_compiling" = yes; then :
14184                           cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14185 /* end confdefs.h.  */
14186 #ifdef __ELF__
14187                Extensible Linking Format
14188                #endif
14189
14190 _ACEOF
14191 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14192   $EGREP "Extensible Linking Format" >/dev/null 2>&1; then :
14193   gl_cv_have_weak="guessing yes"
14194 else
14195   gl_cv_have_weak="guessing no"
14196 fi
14197 rm -f conftest*
14198
14199
14200 else
14201   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14202 /* end confdefs.h.  */
14203
14204 #include <stdio.h>
14205 #pragma weak fputs
14206 int main ()
14207 {
14208   return (fputs == NULL);
14209 }
14210 _ACEOF
14211 if ac_fn_c_try_run "$LINENO"; then :
14212   gl_cv_have_weak=yes
14213 else
14214   gl_cv_have_weak=no
14215 fi
14216 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14217   conftest.$ac_objext conftest.beam conftest.$ac_ext
14218 fi
14219
14220        fi
14221
14222 fi
14223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_weak" >&5
14224 $as_echo "$gl_cv_have_weak" >&6; }
14225     if test "$gl_use_threads" = yes || test "$gl_use_threads" = posix; then
14226       # On OSF/1, the compiler needs the flag -pthread or -D_REENTRANT so that
14227       # it groks <pthread.h>. It's added above, in gl_THREADLIB_EARLY_BODY.
14228       ac_fn_c_check_header_mongrel "$LINENO" "pthread.h" "ac_cv_header_pthread_h" "$ac_includes_default"
14229 if test "x$ac_cv_header_pthread_h" = xyes; then :
14230   gl_have_pthread_h=yes
14231 else
14232   gl_have_pthread_h=no
14233 fi
14234
14235
14236       if test "$gl_have_pthread_h" = yes; then
14237         # Other possible tests:
14238         #   -lpthreads (FSU threads, PCthreads)
14239         #   -lgthreads
14240         gl_have_pthread=
14241         # Test whether both pthread_mutex_lock and pthread_mutexattr_init exist
14242         # in libc. IRIX 6.5 has the first one in both libc and libpthread, but
14243         # the second one only in libpthread, and lock.c needs it.
14244         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14245 /* end confdefs.h.  */
14246 #include <pthread.h>
14247 int
14248 main ()
14249 {
14250 pthread_mutex_lock((pthread_mutex_t*)0);
14251                pthread_mutexattr_init((pthread_mutexattr_t*)0);
14252   ;
14253   return 0;
14254 }
14255 _ACEOF
14256 if ac_fn_c_try_link "$LINENO"; then :
14257   gl_have_pthread=yes
14258 fi
14259 rm -f core conftest.err conftest.$ac_objext \
14260     conftest$ac_exeext conftest.$ac_ext
14261         # Test for libpthread by looking for pthread_kill. (Not pthread_self,
14262         # since it is defined as a macro on OSF/1.)
14263         if test -n "$gl_have_pthread"; then
14264           # The program links fine without libpthread. But it may actually
14265           # need to link with libpthread in order to create multiple threads.
14266           { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_kill in -lpthread" >&5
14267 $as_echo_n "checking for pthread_kill in -lpthread... " >&6; }
14268 if ${ac_cv_lib_pthread_pthread_kill+:} false; then :
14269   $as_echo_n "(cached) " >&6
14270 else
14271   ac_check_lib_save_LIBS=$LIBS
14272 LIBS="-lpthread  $LIBS"
14273 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14274 /* end confdefs.h.  */
14275
14276 /* Override any GCC internal prototype to avoid an error.
14277    Use char because int might match the return type of a GCC
14278    builtin and then its argument prototype would still apply.  */
14279 #ifdef __cplusplus
14280 extern "C"
14281 #endif
14282 char pthread_kill ();
14283 int
14284 main ()
14285 {
14286 return pthread_kill ();
14287   ;
14288   return 0;
14289 }
14290 _ACEOF
14291 if ac_fn_c_try_link "$LINENO"; then :
14292   ac_cv_lib_pthread_pthread_kill=yes
14293 else
14294   ac_cv_lib_pthread_pthread_kill=no
14295 fi
14296 rm -f core conftest.err conftest.$ac_objext \
14297     conftest$ac_exeext conftest.$ac_ext
14298 LIBS=$ac_check_lib_save_LIBS
14299 fi
14300 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_kill" >&5
14301 $as_echo "$ac_cv_lib_pthread_pthread_kill" >&6; }
14302 if test "x$ac_cv_lib_pthread_pthread_kill" = xyes; then :
14303   LIBMULTITHREAD=-lpthread LTLIBMULTITHREAD=-lpthread
14304              # On Solaris and HP-UX, most pthread functions exist also in libc.
14305              # Therefore pthread_in_use() needs to actually try to create a
14306              # thread: pthread_create from libc will fail, whereas
14307              # pthread_create will actually create a thread.
14308              case "$host_os" in
14309                solaris* | hpux*)
14310
14311 $as_echo "#define PTHREAD_IN_USE_DETECTION_HARD 1" >>confdefs.h
14312
14313              esac
14314
14315 fi
14316
14317         else
14318           # Some library is needed. Try libpthread and libc_r.
14319           { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_kill in -lpthread" >&5
14320 $as_echo_n "checking for pthread_kill in -lpthread... " >&6; }
14321 if ${ac_cv_lib_pthread_pthread_kill+:} false; then :
14322   $as_echo_n "(cached) " >&6
14323 else
14324   ac_check_lib_save_LIBS=$LIBS
14325 LIBS="-lpthread  $LIBS"
14326 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14327 /* end confdefs.h.  */
14328
14329 /* Override any GCC internal prototype to avoid an error.
14330    Use char because int might match the return type of a GCC
14331    builtin and then its argument prototype would still apply.  */
14332 #ifdef __cplusplus
14333 extern "C"
14334 #endif
14335 char pthread_kill ();
14336 int
14337 main ()
14338 {
14339 return pthread_kill ();
14340   ;
14341   return 0;
14342 }
14343 _ACEOF
14344 if ac_fn_c_try_link "$LINENO"; then :
14345   ac_cv_lib_pthread_pthread_kill=yes
14346 else
14347   ac_cv_lib_pthread_pthread_kill=no
14348 fi
14349 rm -f core conftest.err conftest.$ac_objext \
14350     conftest$ac_exeext conftest.$ac_ext
14351 LIBS=$ac_check_lib_save_LIBS
14352 fi
14353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_kill" >&5
14354 $as_echo "$ac_cv_lib_pthread_pthread_kill" >&6; }
14355 if test "x$ac_cv_lib_pthread_pthread_kill" = xyes; then :
14356   gl_have_pthread=yes
14357              LIBTHREAD=-lpthread LTLIBTHREAD=-lpthread
14358              LIBMULTITHREAD=-lpthread LTLIBMULTITHREAD=-lpthread
14359 fi
14360
14361           if test -z "$gl_have_pthread"; then
14362             # For FreeBSD 4.
14363             { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_kill in -lc_r" >&5
14364 $as_echo_n "checking for pthread_kill in -lc_r... " >&6; }
14365 if ${ac_cv_lib_c_r_pthread_kill+:} false; then :
14366   $as_echo_n "(cached) " >&6
14367 else
14368   ac_check_lib_save_LIBS=$LIBS
14369 LIBS="-lc_r  $LIBS"
14370 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14371 /* end confdefs.h.  */
14372
14373 /* Override any GCC internal prototype to avoid an error.
14374    Use char because int might match the return type of a GCC
14375    builtin and then its argument prototype would still apply.  */
14376 #ifdef __cplusplus
14377 extern "C"
14378 #endif
14379 char pthread_kill ();
14380 int
14381 main ()
14382 {
14383 return pthread_kill ();
14384   ;
14385   return 0;
14386 }
14387 _ACEOF
14388 if ac_fn_c_try_link "$LINENO"; then :
14389   ac_cv_lib_c_r_pthread_kill=yes
14390 else
14391   ac_cv_lib_c_r_pthread_kill=no
14392 fi
14393 rm -f core conftest.err conftest.$ac_objext \
14394     conftest$ac_exeext conftest.$ac_ext
14395 LIBS=$ac_check_lib_save_LIBS
14396 fi
14397 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_r_pthread_kill" >&5
14398 $as_echo "$ac_cv_lib_c_r_pthread_kill" >&6; }
14399 if test "x$ac_cv_lib_c_r_pthread_kill" = xyes; then :
14400   gl_have_pthread=yes
14401                LIBTHREAD=-lc_r LTLIBTHREAD=-lc_r
14402                LIBMULTITHREAD=-lc_r LTLIBMULTITHREAD=-lc_r
14403 fi
14404
14405           fi
14406         fi
14407         if test -n "$gl_have_pthread"; then
14408           gl_threads_api=posix
14409
14410 $as_echo "#define USE_POSIX_THREADS 1" >>confdefs.h
14411
14412           if test -n "$LIBMULTITHREAD" || test -n "$LTLIBMULTITHREAD"; then
14413             if case "$gl_cv_have_weak" in *yes) true;; *) false;; esac; then
14414
14415 $as_echo "#define USE_POSIX_THREADS_WEAK 1" >>confdefs.h
14416
14417               LIBTHREAD=
14418               LTLIBTHREAD=
14419             fi
14420           fi
14421         fi
14422       fi
14423     fi
14424     if test -z "$gl_have_pthread"; then
14425       if test "$gl_use_threads" = yes || test "$gl_use_threads" = solaris; then
14426         gl_have_solaristhread=
14427         gl_save_LIBS="$LIBS"
14428         LIBS="$LIBS -lthread"
14429         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14430 /* end confdefs.h.  */
14431
14432 #include <thread.h>
14433 #include <synch.h>
14434
14435 int
14436 main ()
14437 {
14438 thr_self();
14439   ;
14440   return 0;
14441 }
14442 _ACEOF
14443 if ac_fn_c_try_link "$LINENO"; then :
14444   gl_have_solaristhread=yes
14445 fi
14446 rm -f core conftest.err conftest.$ac_objext \
14447     conftest$ac_exeext conftest.$ac_ext
14448         LIBS="$gl_save_LIBS"
14449         if test -n "$gl_have_solaristhread"; then
14450           gl_threads_api=solaris
14451           LIBTHREAD=-lthread
14452           LTLIBTHREAD=-lthread
14453           LIBMULTITHREAD="$LIBTHREAD"
14454           LTLIBMULTITHREAD="$LTLIBTHREAD"
14455
14456 $as_echo "#define USE_SOLARIS_THREADS 1" >>confdefs.h
14457
14458           if case "$gl_cv_have_weak" in *yes) true;; *) false;; esac; then
14459
14460 $as_echo "#define USE_SOLARIS_THREADS_WEAK 1" >>confdefs.h
14461
14462             LIBTHREAD=
14463             LTLIBTHREAD=
14464           fi
14465         fi
14466       fi
14467     fi
14468     if test "$gl_use_threads" = pth; then
14469       gl_save_CPPFLAGS="$CPPFLAGS"
14470
14471
14472
14473
14474
14475   { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libpth" >&5
14476 $as_echo_n "checking how to link with libpth... " >&6; }
14477 if ${ac_cv_libpth_libs+:} false; then :
14478   $as_echo_n "(cached) " >&6
14479 else
14480
14481
14482
14483
14484
14485
14486
14487
14488     use_additional=yes
14489
14490   acl_save_prefix="$prefix"
14491   prefix="$acl_final_prefix"
14492   acl_save_exec_prefix="$exec_prefix"
14493   exec_prefix="$acl_final_exec_prefix"
14494
14495     eval additional_includedir=\"$includedir\"
14496     eval additional_libdir=\"$libdir\"
14497
14498   exec_prefix="$acl_save_exec_prefix"
14499   prefix="$acl_save_prefix"
14500
14501
14502 # Check whether --with-libpth-prefix was given.
14503 if test "${with_libpth_prefix+set}" = set; then :
14504   withval=$with_libpth_prefix;
14505     if test "X$withval" = "Xno"; then
14506       use_additional=no
14507     else
14508       if test "X$withval" = "X"; then
14509
14510   acl_save_prefix="$prefix"
14511   prefix="$acl_final_prefix"
14512   acl_save_exec_prefix="$exec_prefix"
14513   exec_prefix="$acl_final_exec_prefix"
14514
14515           eval additional_includedir=\"$includedir\"
14516           eval additional_libdir=\"$libdir\"
14517
14518   exec_prefix="$acl_save_exec_prefix"
14519   prefix="$acl_save_prefix"
14520
14521       else
14522         additional_includedir="$withval/include"
14523         additional_libdir="$withval/$acl_libdirstem"
14524         if test "$acl_libdirstem2" != "$acl_libdirstem" \
14525            && ! test -d "$withval/$acl_libdirstem"; then
14526           additional_libdir="$withval/$acl_libdirstem2"
14527         fi
14528       fi
14529     fi
14530
14531 fi
14532
14533       LIBPTH=
14534   LTLIBPTH=
14535   INCPTH=
14536   LIBPTH_PREFIX=
14537       HAVE_LIBPTH=
14538   rpathdirs=
14539   ltrpathdirs=
14540   names_already_handled=
14541   names_next_round='pth '
14542   while test -n "$names_next_round"; do
14543     names_this_round="$names_next_round"
14544     names_next_round=
14545     for name in $names_this_round; do
14546       already_handled=
14547       for n in $names_already_handled; do
14548         if test "$n" = "$name"; then
14549           already_handled=yes
14550           break
14551         fi
14552       done
14553       if test -z "$already_handled"; then
14554         names_already_handled="$names_already_handled $name"
14555                         uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./+-|ABCDEFGHIJKLMNOPQRSTUVWXYZ____|'`
14556         eval value=\"\$HAVE_LIB$uppername\"
14557         if test -n "$value"; then
14558           if test "$value" = yes; then
14559             eval value=\"\$LIB$uppername\"
14560             test -z "$value" || LIBPTH="${LIBPTH}${LIBPTH:+ }$value"
14561             eval value=\"\$LTLIB$uppername\"
14562             test -z "$value" || LTLIBPTH="${LTLIBPTH}${LTLIBPTH:+ }$value"
14563           else
14564                                     :
14565           fi
14566         else
14567                               found_dir=
14568           found_la=
14569           found_so=
14570           found_a=
14571           eval libname=\"$acl_libname_spec\"    # typically: libname=lib$name
14572           if test -n "$acl_shlibext"; then
14573             shrext=".$acl_shlibext"             # typically: shrext=.so
14574           else
14575             shrext=
14576           fi
14577           if test $use_additional = yes; then
14578             dir="$additional_libdir"
14579                                     if test -n "$acl_shlibext"; then
14580               if test -f "$dir/$libname$shrext"; then
14581                 found_dir="$dir"
14582                 found_so="$dir/$libname$shrext"
14583               else
14584                 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
14585                   ver=`(cd "$dir" && \
14586                         for f in "$libname$shrext".*; do echo "$f"; done \
14587                         | sed -e "s,^$libname$shrext\\\\.,," \
14588                         | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
14589                         | sed 1q ) 2>/dev/null`
14590                   if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then
14591                     found_dir="$dir"
14592                     found_so="$dir/$libname$shrext.$ver"
14593                   fi
14594                 else
14595                   eval library_names=\"$acl_library_names_spec\"
14596                   for f in $library_names; do
14597                     if test -f "$dir/$f"; then
14598                       found_dir="$dir"
14599                       found_so="$dir/$f"
14600                       break
14601                     fi
14602                   done
14603                 fi
14604               fi
14605             fi
14606                         if test "X$found_dir" = "X"; then
14607               if test -f "$dir/$libname.$acl_libext"; then
14608                 found_dir="$dir"
14609                 found_a="$dir/$libname.$acl_libext"
14610               fi
14611             fi
14612             if test "X$found_dir" != "X"; then
14613               if test -f "$dir/$libname.la"; then
14614                 found_la="$dir/$libname.la"
14615               fi
14616             fi
14617           fi
14618           if test "X$found_dir" = "X"; then
14619             for x in $LDFLAGS $LTLIBPTH; do
14620
14621   acl_save_prefix="$prefix"
14622   prefix="$acl_final_prefix"
14623   acl_save_exec_prefix="$exec_prefix"
14624   exec_prefix="$acl_final_exec_prefix"
14625   eval x=\"$x\"
14626   exec_prefix="$acl_save_exec_prefix"
14627   prefix="$acl_save_prefix"
14628
14629               case "$x" in
14630                 -L*)
14631                   dir=`echo "X$x" | sed -e 's/^X-L//'`
14632                                     if test -n "$acl_shlibext"; then
14633                     if test -f "$dir/$libname$shrext"; then
14634                       found_dir="$dir"
14635                       found_so="$dir/$libname$shrext"
14636                     else
14637                       if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
14638                         ver=`(cd "$dir" && \
14639                               for f in "$libname$shrext".*; do echo "$f"; done \
14640                               | sed -e "s,^$libname$shrext\\\\.,," \
14641                               | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
14642                               | sed 1q ) 2>/dev/null`
14643                         if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then
14644                           found_dir="$dir"
14645                           found_so="$dir/$libname$shrext.$ver"
14646                         fi
14647                       else
14648                         eval library_names=\"$acl_library_names_spec\"
14649                         for f in $library_names; do
14650                           if test -f "$dir/$f"; then
14651                             found_dir="$dir"
14652                             found_so="$dir/$f"
14653                             break
14654                           fi
14655                         done
14656                       fi
14657                     fi
14658                   fi
14659                                     if test "X$found_dir" = "X"; then
14660                     if test -f "$dir/$libname.$acl_libext"; then
14661                       found_dir="$dir"
14662                       found_a="$dir/$libname.$acl_libext"
14663                     fi
14664                   fi
14665                   if test "X$found_dir" != "X"; then
14666                     if test -f "$dir/$libname.la"; then
14667                       found_la="$dir/$libname.la"
14668                     fi
14669                   fi
14670                   ;;
14671               esac
14672               if test "X$found_dir" != "X"; then
14673                 break
14674               fi
14675             done
14676           fi
14677           if test "X$found_dir" != "X"; then
14678                         LTLIBPTH="${LTLIBPTH}${LTLIBPTH:+ }-L$found_dir -l$name"
14679             if test "X$found_so" != "X"; then
14680                                                         if test "$enable_rpath" = no \
14681                  || test "X$found_dir" = "X/usr/$acl_libdirstem" \
14682                  || test "X$found_dir" = "X/usr/$acl_libdirstem2"; then
14683                                 LIBPTH="${LIBPTH}${LIBPTH:+ }$found_so"
14684               else
14685                                                                                 haveit=
14686                 for x in $ltrpathdirs; do
14687                   if test "X$x" = "X$found_dir"; then
14688                     haveit=yes
14689                     break
14690                   fi
14691                 done
14692                 if test -z "$haveit"; then
14693                   ltrpathdirs="$ltrpathdirs $found_dir"
14694                 fi
14695                                 if test "$acl_hardcode_direct" = yes; then
14696                                                       LIBPTH="${LIBPTH}${LIBPTH:+ }$found_so"
14697                 else
14698                   if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then
14699                                                             LIBPTH="${LIBPTH}${LIBPTH:+ }$found_so"
14700                                                             haveit=
14701                     for x in $rpathdirs; do
14702                       if test "X$x" = "X$found_dir"; then
14703                         haveit=yes
14704                         break
14705                       fi
14706                     done
14707                     if test -z "$haveit"; then
14708                       rpathdirs="$rpathdirs $found_dir"
14709                     fi
14710                   else
14711                                                                                 haveit=
14712                     for x in $LDFLAGS $LIBPTH; do
14713
14714   acl_save_prefix="$prefix"
14715   prefix="$acl_final_prefix"
14716   acl_save_exec_prefix="$exec_prefix"
14717   exec_prefix="$acl_final_exec_prefix"
14718   eval x=\"$x\"
14719   exec_prefix="$acl_save_exec_prefix"
14720   prefix="$acl_save_prefix"
14721
14722                       if test "X$x" = "X-L$found_dir"; then
14723                         haveit=yes
14724                         break
14725                       fi
14726                     done
14727                     if test -z "$haveit"; then
14728                       LIBPTH="${LIBPTH}${LIBPTH:+ }-L$found_dir"
14729                     fi
14730                     if test "$acl_hardcode_minus_L" != no; then
14731                                                                                         LIBPTH="${LIBPTH}${LIBPTH:+ }$found_so"
14732                     else
14733                                                                                                                                                                                 LIBPTH="${LIBPTH}${LIBPTH:+ }-l$name"
14734                     fi
14735                   fi
14736                 fi
14737               fi
14738             else
14739               if test "X$found_a" != "X"; then
14740                                 LIBPTH="${LIBPTH}${LIBPTH:+ }$found_a"
14741               else
14742                                                 LIBPTH="${LIBPTH}${LIBPTH:+ }-L$found_dir -l$name"
14743               fi
14744             fi
14745                         additional_includedir=
14746             case "$found_dir" in
14747               */$acl_libdirstem | */$acl_libdirstem/)
14748                 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'`
14749                 if test "$name" = 'pth'; then
14750                   LIBPTH_PREFIX="$basedir"
14751                 fi
14752                 additional_includedir="$basedir/include"
14753                 ;;
14754               */$acl_libdirstem2 | */$acl_libdirstem2/)
14755                 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem2/"'*$,,'`
14756                 if test "$name" = 'pth'; then
14757                   LIBPTH_PREFIX="$basedir"
14758                 fi
14759                 additional_includedir="$basedir/include"
14760                 ;;
14761             esac
14762             if test "X$additional_includedir" != "X"; then
14763                                                                                                                 if test "X$additional_includedir" != "X/usr/include"; then
14764                 haveit=
14765                 if test "X$additional_includedir" = "X/usr/local/include"; then
14766                   if test -n "$GCC"; then
14767                     case $host_os in
14768                       linux* | gnu* | k*bsd*-gnu) haveit=yes;;
14769                     esac
14770                   fi
14771                 fi
14772                 if test -z "$haveit"; then
14773                   for x in $CPPFLAGS $INCPTH; do
14774
14775   acl_save_prefix="$prefix"
14776   prefix="$acl_final_prefix"
14777   acl_save_exec_prefix="$exec_prefix"
14778   exec_prefix="$acl_final_exec_prefix"
14779   eval x=\"$x\"
14780   exec_prefix="$acl_save_exec_prefix"
14781   prefix="$acl_save_prefix"
14782
14783                     if test "X$x" = "X-I$additional_includedir"; then
14784                       haveit=yes
14785                       break
14786                     fi
14787                   done
14788                   if test -z "$haveit"; then
14789                     if test -d "$additional_includedir"; then
14790                                             INCPTH="${INCPTH}${INCPTH:+ }-I$additional_includedir"
14791                     fi
14792                   fi
14793                 fi
14794               fi
14795             fi
14796                         if test -n "$found_la"; then
14797                                                         save_libdir="$libdir"
14798               case "$found_la" in
14799                 */* | *\\*) . "$found_la" ;;
14800                 *) . "./$found_la" ;;
14801               esac
14802               libdir="$save_libdir"
14803                             for dep in $dependency_libs; do
14804                 case "$dep" in
14805                   -L*)
14806                     additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
14807                                                                                                                                                                 if test "X$additional_libdir" != "X/usr/$acl_libdirstem" \
14808                        && test "X$additional_libdir" != "X/usr/$acl_libdirstem2"; then
14809                       haveit=
14810                       if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem" \
14811                          || test "X$additional_libdir" = "X/usr/local/$acl_libdirstem2"; then
14812                         if test -n "$GCC"; then
14813                           case $host_os in
14814                             linux* | gnu* | k*bsd*-gnu) haveit=yes;;
14815                           esac
14816                         fi
14817                       fi
14818                       if test -z "$haveit"; then
14819                         haveit=
14820                         for x in $LDFLAGS $LIBPTH; do
14821
14822   acl_save_prefix="$prefix"
14823   prefix="$acl_final_prefix"
14824   acl_save_exec_prefix="$exec_prefix"
14825   exec_prefix="$acl_final_exec_prefix"
14826   eval x=\"$x\"
14827   exec_prefix="$acl_save_exec_prefix"
14828   prefix="$acl_save_prefix"
14829
14830                           if test "X$x" = "X-L$additional_libdir"; then
14831                             haveit=yes
14832                             break
14833                           fi
14834                         done
14835                         if test -z "$haveit"; then
14836                           if test -d "$additional_libdir"; then
14837                                                         LIBPTH="${LIBPTH}${LIBPTH:+ }-L$additional_libdir"
14838                           fi
14839                         fi
14840                         haveit=
14841                         for x in $LDFLAGS $LTLIBPTH; do
14842
14843   acl_save_prefix="$prefix"
14844   prefix="$acl_final_prefix"
14845   acl_save_exec_prefix="$exec_prefix"
14846   exec_prefix="$acl_final_exec_prefix"
14847   eval x=\"$x\"
14848   exec_prefix="$acl_save_exec_prefix"
14849   prefix="$acl_save_prefix"
14850
14851                           if test "X$x" = "X-L$additional_libdir"; then
14852                             haveit=yes
14853                             break
14854                           fi
14855                         done
14856                         if test -z "$haveit"; then
14857                           if test -d "$additional_libdir"; then
14858                                                         LTLIBPTH="${LTLIBPTH}${LTLIBPTH:+ }-L$additional_libdir"
14859                           fi
14860                         fi
14861                       fi
14862                     fi
14863                     ;;
14864                   -R*)
14865                     dir=`echo "X$dep" | sed -e 's/^X-R//'`
14866                     if test "$enable_rpath" != no; then
14867                                                                   haveit=
14868                       for x in $rpathdirs; do
14869                         if test "X$x" = "X$dir"; then
14870                           haveit=yes
14871                           break
14872                         fi
14873                       done
14874                       if test -z "$haveit"; then
14875                         rpathdirs="$rpathdirs $dir"
14876                       fi
14877                                                                   haveit=
14878                       for x in $ltrpathdirs; do
14879                         if test "X$x" = "X$dir"; then
14880                           haveit=yes
14881                           break
14882                         fi
14883                       done
14884                       if test -z "$haveit"; then
14885                         ltrpathdirs="$ltrpathdirs $dir"
14886                       fi
14887                     fi
14888                     ;;
14889                   -l*)
14890                                         names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
14891                     ;;
14892                   *.la)
14893                                                                                 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
14894                     ;;
14895                   *)
14896                                         LIBPTH="${LIBPTH}${LIBPTH:+ }$dep"
14897                     LTLIBPTH="${LTLIBPTH}${LTLIBPTH:+ }$dep"
14898                     ;;
14899                 esac
14900               done
14901             fi
14902           else
14903                                                             LIBPTH="${LIBPTH}${LIBPTH:+ }-l$name"
14904             LTLIBPTH="${LTLIBPTH}${LTLIBPTH:+ }-l$name"
14905           fi
14906         fi
14907       fi
14908     done
14909   done
14910   if test "X$rpathdirs" != "X"; then
14911     if test -n "$acl_hardcode_libdir_separator"; then
14912                         alldirs=
14913       for found_dir in $rpathdirs; do
14914         alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$found_dir"
14915       done
14916             acl_save_libdir="$libdir"
14917       libdir="$alldirs"
14918       eval flag=\"$acl_hardcode_libdir_flag_spec\"
14919       libdir="$acl_save_libdir"
14920       LIBPTH="${LIBPTH}${LIBPTH:+ }$flag"
14921     else
14922             for found_dir in $rpathdirs; do
14923         acl_save_libdir="$libdir"
14924         libdir="$found_dir"
14925         eval flag=\"$acl_hardcode_libdir_flag_spec\"
14926         libdir="$acl_save_libdir"
14927         LIBPTH="${LIBPTH}${LIBPTH:+ }$flag"
14928       done
14929     fi
14930   fi
14931   if test "X$ltrpathdirs" != "X"; then
14932             for found_dir in $ltrpathdirs; do
14933       LTLIBPTH="${LTLIBPTH}${LTLIBPTH:+ }-R$found_dir"
14934     done
14935   fi
14936
14937
14938
14939
14940
14941
14942     ac_cv_libpth_libs="$LIBPTH"
14943     ac_cv_libpth_ltlibs="$LTLIBPTH"
14944     ac_cv_libpth_cppflags="$INCPTH"
14945     ac_cv_libpth_prefix="$LIBPTH_PREFIX"
14946
14947 fi
14948 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libpth_libs" >&5
14949 $as_echo "$ac_cv_libpth_libs" >&6; }
14950   LIBPTH="$ac_cv_libpth_libs"
14951   LTLIBPTH="$ac_cv_libpth_ltlibs"
14952   INCPTH="$ac_cv_libpth_cppflags"
14953   LIBPTH_PREFIX="$ac_cv_libpth_prefix"
14954
14955   for element in $INCPTH; do
14956     haveit=
14957     for x in $CPPFLAGS; do
14958
14959   acl_save_prefix="$prefix"
14960   prefix="$acl_final_prefix"
14961   acl_save_exec_prefix="$exec_prefix"
14962   exec_prefix="$acl_final_exec_prefix"
14963   eval x=\"$x\"
14964   exec_prefix="$acl_save_exec_prefix"
14965   prefix="$acl_save_prefix"
14966
14967       if test "X$x" = "X$element"; then
14968         haveit=yes
14969         break
14970       fi
14971     done
14972     if test -z "$haveit"; then
14973       CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
14974     fi
14975   done
14976
14977
14978
14979
14980       HAVE_LIBPTH=yes
14981
14982
14983
14984       gl_have_pth=
14985       gl_save_LIBS="$LIBS"
14986       LIBS="$LIBS $LIBPTH"
14987       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14988 /* end confdefs.h.  */
14989 #include <pth.h>
14990 int
14991 main ()
14992 {
14993 pth_self();
14994   ;
14995   return 0;
14996 }
14997 _ACEOF
14998 if ac_fn_c_try_link "$LINENO"; then :
14999   gl_have_pth=yes
15000 fi
15001 rm -f core conftest.err conftest.$ac_objext \
15002     conftest$ac_exeext conftest.$ac_ext
15003       LIBS="$gl_save_LIBS"
15004       if test -n "$gl_have_pth"; then
15005         gl_threads_api=pth
15006         LIBTHREAD="$LIBPTH"
15007         LTLIBTHREAD="$LTLIBPTH"
15008         LIBMULTITHREAD="$LIBTHREAD"
15009         LTLIBMULTITHREAD="$LTLIBTHREAD"
15010
15011 $as_echo "#define USE_PTH_THREADS 1" >>confdefs.h
15012
15013         if test -n "$LIBMULTITHREAD" || test -n "$LTLIBMULTITHREAD"; then
15014           if case "$gl_cv_have_weak" in *yes) true;; *) false;; esac; then
15015
15016 $as_echo "#define USE_PTH_THREADS_WEAK 1" >>confdefs.h
15017
15018             LIBTHREAD=
15019             LTLIBTHREAD=
15020           fi
15021         fi
15022       else
15023         CPPFLAGS="$gl_save_CPPFLAGS"
15024       fi
15025     fi
15026     if test -z "$gl_have_pthread"; then
15027       case "$gl_use_threads" in
15028         yes | windows | win32) # The 'win32' is for backward compatibility.
15029           if { case "$host_os" in
15030                  mingw*) true;;
15031                  *) false;;
15032                esac
15033              }; then
15034             gl_threads_api=windows
15035
15036 $as_echo "#define USE_WINDOWS_THREADS 1" >>confdefs.h
15037
15038           fi
15039           ;;
15040       esac
15041     fi
15042   fi
15043   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for multithread API to use" >&5
15044 $as_echo_n "checking for multithread API to use... " >&6; }
15045   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_threads_api" >&5
15046 $as_echo "$gl_threads_api" >&6; }
15047
15048
15049
15050
15051
15052
15053
15054
15055
15056
15057
15058
15059
15060
15061
15062       { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lstat correctly handles trailing slash" >&5
15063 $as_echo_n "checking whether lstat correctly handles trailing slash... " >&6; }
15064 if ${gl_cv_func_lstat_dereferences_slashed_symlink+:} false; then :
15065   $as_echo_n "(cached) " >&6
15066 else
15067   rm -f conftest.sym conftest.file
15068      echo >conftest.file
15069      if test "$as_ln_s" = "ln -s" && ln -s conftest.file conftest.sym; then
15070        if test "$cross_compiling" = yes; then :
15071   case "$host_os" in
15072                     # Guess yes on glibc systems.
15073             *-gnu*) gl_cv_func_lstat_dereferences_slashed_symlink="guessing yes" ;;
15074                     # If we don't know, assume the worst.
15075             *)      gl_cv_func_lstat_dereferences_slashed_symlink="guessing no" ;;
15076           esac
15077
15078 else
15079   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15080 /* end confdefs.h.  */
15081 $ac_includes_default
15082 int
15083 main ()
15084 {
15085 struct stat sbuf;
15086               /* Linux will dereference the symlink and fail, as required by
15087                  POSIX.  That is better in the sense that it means we will not
15088                  have to compile and use the lstat wrapper.  */
15089               return lstat ("conftest.sym/", &sbuf) == 0;
15090
15091   ;
15092   return 0;
15093 }
15094 _ACEOF
15095 if ac_fn_c_try_run "$LINENO"; then :
15096   gl_cv_func_lstat_dereferences_slashed_symlink=yes
15097 else
15098   gl_cv_func_lstat_dereferences_slashed_symlink=no
15099 fi
15100 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15101   conftest.$ac_objext conftest.beam conftest.$ac_ext
15102 fi
15103
15104      else
15105        # If the 'ln -s' command failed, then we probably don't even
15106        # have an lstat function.
15107        gl_cv_func_lstat_dereferences_slashed_symlink="guessing no"
15108      fi
15109      rm -f conftest.sym conftest.file
15110
15111 fi
15112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_lstat_dereferences_slashed_symlink" >&5
15113 $as_echo "$gl_cv_func_lstat_dereferences_slashed_symlink" >&6; }
15114   case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
15115     *yes)
15116
15117 cat >>confdefs.h <<_ACEOF
15118 #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1
15119 _ACEOF
15120
15121       ;;
15122   esac
15123
15124 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
15125 $as_echo_n "checking for a sed that does not truncate output... " >&6; }
15126 if ${ac_cv_path_SED+:} false; then :
15127   $as_echo_n "(cached) " >&6
15128 else
15129             ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
15130      for ac_i in 1 2 3 4 5 6 7; do
15131        ac_script="$ac_script$as_nl$ac_script"
15132      done
15133      echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
15134      { ac_script=; unset ac_script;}
15135      if test -z "$SED"; then
15136   ac_path_SED_found=false
15137   # Loop through the user's path and test for each of PROGNAME-LIST
15138   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15139 for as_dir in $PATH
15140 do
15141   IFS=$as_save_IFS
15142   test -z "$as_dir" && as_dir=.
15143     for ac_prog in sed gsed; do
15144     for ac_exec_ext in '' $ac_executable_extensions; do
15145       ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
15146       as_fn_executable_p "$ac_path_SED" || continue
15147 # Check for GNU ac_path_SED and select it if it is found.
15148   # Check for GNU $ac_path_SED
15149 case `"$ac_path_SED" --version 2>&1` in
15150 *GNU*)
15151   ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
15152 *)
15153   ac_count=0
15154   $as_echo_n 0123456789 >"conftest.in"
15155   while :
15156   do
15157     cat "conftest.in" "conftest.in" >"conftest.tmp"
15158     mv "conftest.tmp" "conftest.in"
15159     cp "conftest.in" "conftest.nl"
15160     $as_echo '' >> "conftest.nl"
15161     "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
15162     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
15163     as_fn_arith $ac_count + 1 && ac_count=$as_val
15164     if test $ac_count -gt ${ac_path_SED_max-0}; then
15165       # Best one so far, save it but keep looking for a better one
15166       ac_cv_path_SED="$ac_path_SED"
15167       ac_path_SED_max=$ac_count
15168     fi
15169     # 10*(2^10) chars as input seems more than enough
15170     test $ac_count -gt 10 && break
15171   done
15172   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
15173 esac
15174
15175       $ac_path_SED_found && break 3
15176     done
15177   done
15178   done
15179 IFS=$as_save_IFS
15180   if test -z "$ac_cv_path_SED"; then
15181     as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
15182   fi
15183 else
15184   ac_cv_path_SED=$SED
15185 fi
15186
15187 fi
15188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
15189 $as_echo "$ac_cv_path_SED" >&6; }
15190  SED="$ac_cv_path_SED"
15191   rm -f conftest.sed
15192
15193
15194
15195       for ac_header in stdlib.h
15196 do :
15197   ac_fn_c_check_header_mongrel "$LINENO" "stdlib.h" "ac_cv_header_stdlib_h" "$ac_includes_default"
15198 if test "x$ac_cv_header_stdlib_h" = xyes; then :
15199   cat >>confdefs.h <<_ACEOF
15200 #define HAVE_STDLIB_H 1
15201 _ACEOF
15202
15203 fi
15204
15205 done
15206
15207   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU libc compatible malloc" >&5
15208 $as_echo_n "checking for GNU libc compatible malloc... " >&6; }
15209 if ${ac_cv_func_malloc_0_nonnull+:} false; then :
15210   $as_echo_n "(cached) " >&6
15211 else
15212   if test "$cross_compiling" = yes; then :
15213   case "$host_os" in
15214           # Guess yes on platforms where we know the result.
15215           *-gnu* | freebsd* | netbsd* | openbsd* \
15216           | hpux* | solaris* | cygwin* | mingw*)
15217             ac_cv_func_malloc_0_nonnull=yes ;;
15218           # If we don't know, assume the worst.
15219           *) ac_cv_func_malloc_0_nonnull=no ;;
15220         esac
15221
15222 else
15223   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15224 /* end confdefs.h.  */
15225 #if defined STDC_HEADERS || defined HAVE_STDLIB_H
15226             # include <stdlib.h>
15227             #else
15228             char *malloc ();
15229             #endif
15230
15231 int
15232 main ()
15233 {
15234 return ! malloc (0);
15235   ;
15236   return 0;
15237 }
15238
15239 _ACEOF
15240 if ac_fn_c_try_run "$LINENO"; then :
15241   ac_cv_func_malloc_0_nonnull=yes
15242 else
15243   ac_cv_func_malloc_0_nonnull=no
15244 fi
15245 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15246   conftest.$ac_objext conftest.beam conftest.$ac_ext
15247 fi
15248
15249
15250 fi
15251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_malloc_0_nonnull" >&5
15252 $as_echo "$ac_cv_func_malloc_0_nonnull" >&6; }
15253   if test $ac_cv_func_malloc_0_nonnull = yes; then :
15254   gl_cv_func_malloc_0_nonnull=1
15255 else
15256   gl_cv_func_malloc_0_nonnull=0
15257 fi
15258
15259
15260 cat >>confdefs.h <<_ACEOF
15261 #define MALLOC_0_IS_NONNULL $gl_cv_func_malloc_0_nonnull
15262 _ACEOF
15263
15264
15265
15266
15267   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
15268 $as_echo_n "checking for long long int... " >&6; }
15269 if ${ac_cv_type_long_long_int+:} false; then :
15270   $as_echo_n "(cached) " >&6
15271 else
15272   ac_cv_type_long_long_int=yes
15273       if test "x${ac_cv_prog_cc_c99-no}" = xno; then
15274         ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
15275         if test $ac_cv_type_long_long_int = yes; then
15276                                         if test "$cross_compiling" = yes; then :
15277   :
15278 else
15279   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15280 /* end confdefs.h.  */
15281 #include <limits.h>
15282                  #ifndef LLONG_MAX
15283                  # define HALF \
15284                           (1LL << (sizeof (long long int) * CHAR_BIT - 2))
15285                  # define LLONG_MAX (HALF - 1 + HALF)
15286                  #endif
15287 int
15288 main ()
15289 {
15290 long long int n = 1;
15291                  int i;
15292                  for (i = 0; ; i++)
15293                    {
15294                      long long int m = n << i;
15295                      if (m >> i != n)
15296                        return 1;
15297                      if (LLONG_MAX / 2 < m)
15298                        break;
15299                    }
15300                  return 0;
15301   ;
15302   return 0;
15303 }
15304 _ACEOF
15305 if ac_fn_c_try_run "$LINENO"; then :
15306
15307 else
15308   ac_cv_type_long_long_int=no
15309 fi
15310 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15311   conftest.$ac_objext conftest.beam conftest.$ac_ext
15312 fi
15313
15314         fi
15315       fi
15316 fi
15317 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
15318 $as_echo "$ac_cv_type_long_long_int" >&6; }
15319   if test $ac_cv_type_long_long_int = yes; then
15320
15321 $as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
15322
15323   fi
15324
15325
15326
15327
15328
15329
15330
15331
15332
15333
15334
15335
15336
15337
15338   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a traditional japanese locale" >&5
15339 $as_echo_n "checking for a traditional japanese locale... " >&6; }
15340 if ${gt_cv_locale_ja+:} false; then :
15341   $as_echo_n "(cached) " >&6
15342 else
15343
15344     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15345 /* end confdefs.h.  */
15346
15347 #include <locale.h>
15348 #include <time.h>
15349 #if HAVE_LANGINFO_CODESET
15350 # include <langinfo.h>
15351 #endif
15352 #include <stdlib.h>
15353 #include <string.h>
15354 struct tm t;
15355 char buf[16];
15356 int main ()
15357 {
15358   const char *p;
15359   /* Check whether the given locale name is recognized by the system.  */
15360 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
15361   /* On native Windows, setlocale(category, "") looks at the system settings,
15362      not at the environment variables.  Also, when an encoding suffix such
15363      as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
15364      category of the locale to "C".  */
15365   if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
15366       || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
15367     return 1;
15368 #else
15369   if (setlocale (LC_ALL, "") == NULL) return 1;
15370 #endif
15371   /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
15372      On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
15373      is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
15374      On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
15375      succeeds but then nl_langinfo(CODESET) is "646". In this situation,
15376      some unit tests fail.
15377      On MirBSD 10, when an unsupported locale is specified, setlocale()
15378      succeeds but then nl_langinfo(CODESET) is "UTF-8".  */
15379 #if HAVE_LANGINFO_CODESET
15380   {
15381     const char *cs = nl_langinfo (CODESET);
15382     if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
15383         || strcmp (cs, "UTF-8") == 0)
15384       return 1;
15385   }
15386 #endif
15387 #ifdef __CYGWIN__
15388   /* On Cygwin, avoid locale names without encoding suffix, because the
15389      locale_charset() function relies on the encoding suffix.  Note that
15390      LC_ALL is set on the command line.  */
15391   if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
15392 #endif
15393   /* Check whether MB_CUR_MAX is > 1.  This excludes the dysfunctional locales
15394      on Cygwin 1.5.x.  */
15395   if (MB_CUR_MAX == 1)
15396     return 1;
15397   /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
15398      This excludes the UTF-8 encoding (except on MirBSD).  */
15399   t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
15400   if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
15401   for (p = buf; *p != '\0'; p++)
15402     if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
15403       return 1;
15404   return 0;
15405 }
15406
15407 _ACEOF
15408     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
15409   (eval $ac_link) 2>&5
15410   ac_status=$?
15411   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
15412   test $ac_status = 0; } && test -s conftest$ac_exeext; then
15413       case "$host_os" in
15414         # Handle native Windows specially, because there setlocale() interprets
15415         # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
15416         # "fr" or "fra" as "French" or "French_France.1252",
15417         # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
15418         # "ja" as "Japanese" or "Japanese_Japan.932",
15419         # and similar.
15420         mingw*)
15421           # Note that on native Windows, the Japanese locale is
15422           # Japanese_Japan.932, and CP932 is very different from EUC-JP, so we
15423           # cannot use it here.
15424           gt_cv_locale_ja=none
15425           ;;
15426         *)
15427           # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
15428           # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
15429           # configure script would override the LC_ALL setting. Likewise for
15430           # LC_CTYPE, which is also set at the beginning of the configure script.
15431           # Test for the AIX locale name.
15432           if (LC_ALL=ja_JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
15433             gt_cv_locale_ja=ja_JP
15434           else
15435             # Test for the locale name with explicit encoding suffix.
15436             if (LC_ALL=ja_JP.EUC-JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
15437               gt_cv_locale_ja=ja_JP.EUC-JP
15438             else
15439               # Test for the HP-UX, OSF/1, NetBSD locale name.
15440               if (LC_ALL=ja_JP.eucJP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
15441                 gt_cv_locale_ja=ja_JP.eucJP
15442               else
15443                 # Test for the IRIX, FreeBSD locale name.
15444                 if (LC_ALL=ja_JP.EUC LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
15445                   gt_cv_locale_ja=ja_JP.EUC
15446                 else
15447                   # Test for the Solaris 7 locale name.
15448                   if (LC_ALL=ja LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
15449                     gt_cv_locale_ja=ja
15450                   else
15451                     # Special test for NetBSD 1.6.
15452                     if test -f /usr/share/locale/ja_JP.eucJP/LC_CTYPE; then
15453                       gt_cv_locale_ja=ja_JP.eucJP
15454                     else
15455                       # None found.
15456                       gt_cv_locale_ja=none
15457                     fi
15458                   fi
15459                 fi
15460               fi
15461             fi
15462           fi
15463           ;;
15464       esac
15465     fi
15466     rm -fr conftest*
15467
15468 fi
15469 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_ja" >&5
15470 $as_echo "$gt_cv_locale_ja" >&6; }
15471   LOCALE_JA=$gt_cv_locale_ja
15472
15473
15474
15475
15476
15477   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a transitional chinese locale" >&5
15478 $as_echo_n "checking for a transitional chinese locale... " >&6; }
15479 if ${gt_cv_locale_zh_CN+:} false; then :
15480   $as_echo_n "(cached) " >&6
15481 else
15482
15483     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15484 /* end confdefs.h.  */
15485
15486 #include <locale.h>
15487 #include <stdlib.h>
15488 #include <time.h>
15489 #if HAVE_LANGINFO_CODESET
15490 # include <langinfo.h>
15491 #endif
15492 #include <stdlib.h>
15493 #include <string.h>
15494 struct tm t;
15495 char buf[16];
15496 int main ()
15497 {
15498   const char *p;
15499   /* Check whether the given locale name is recognized by the system.  */
15500 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
15501   /* On native Windows, setlocale(category, "") looks at the system settings,
15502      not at the environment variables.  Also, when an encoding suffix such
15503      as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
15504      category of the locale to "C".  */
15505   if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
15506       || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
15507     return 1;
15508 #else
15509   if (setlocale (LC_ALL, "") == NULL) return 1;
15510 #endif
15511   /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
15512      On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
15513      is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
15514      On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
15515      succeeds but then nl_langinfo(CODESET) is "646". In this situation,
15516      some unit tests fail.
15517      On MirBSD 10, when an unsupported locale is specified, setlocale()
15518      succeeds but then nl_langinfo(CODESET) is "UTF-8".  */
15519 #if HAVE_LANGINFO_CODESET
15520   {
15521     const char *cs = nl_langinfo (CODESET);
15522     if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
15523         || strcmp (cs, "UTF-8") == 0)
15524       return 1;
15525   }
15526 #endif
15527 #ifdef __CYGWIN__
15528   /* On Cygwin, avoid locale names without encoding suffix, because the
15529      locale_charset() function relies on the encoding suffix.  Note that
15530      LC_ALL is set on the command line.  */
15531   if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
15532 #endif
15533   /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
15534      This excludes the UTF-8 encoding (except on MirBSD).  */
15535   t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
15536   if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
15537   for (p = buf; *p != '\0'; p++)
15538     if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
15539       return 1;
15540   /* Check whether a typical GB18030 multibyte sequence is recognized as a
15541      single wide character.  This excludes the GB2312 and GBK encodings.  */
15542   if (mblen ("\203\062\332\066", 5) != 4)
15543     return 1;
15544   return 0;
15545 }
15546
15547 _ACEOF
15548     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
15549   (eval $ac_link) 2>&5
15550   ac_status=$?
15551   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
15552   test $ac_status = 0; } && test -s conftest$ac_exeext; then
15553       case "$host_os" in
15554         # Handle native Windows specially, because there setlocale() interprets
15555         # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
15556         # "fr" or "fra" as "French" or "French_France.1252",
15557         # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
15558         # "ja" as "Japanese" or "Japanese_Japan.932",
15559         # and similar.
15560         mingw*)
15561           # Test for the hypothetical native Windows locale name.
15562           if (LC_ALL=Chinese_China.54936 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
15563             gt_cv_locale_zh_CN=Chinese_China.54936
15564           else
15565             # None found.
15566             gt_cv_locale_zh_CN=none
15567           fi
15568           ;;
15569         solaris2.8)
15570           # On Solaris 8, the locales zh_CN.GB18030, zh_CN.GBK, zh.GBK are
15571           # broken. One witness is the test case in gl_MBRTOWC_SANITYCHECK.
15572           # Another witness is that "LC_ALL=zh_CN.GB18030 bash -c true" dumps core.
15573           gt_cv_locale_zh_CN=none
15574           ;;
15575         *)
15576           # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
15577           # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
15578           # configure script would override the LC_ALL setting. Likewise for
15579           # LC_CTYPE, which is also set at the beginning of the configure script.
15580           # Test for the locale name without encoding suffix.
15581           if (LC_ALL=zh_CN LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
15582             gt_cv_locale_zh_CN=zh_CN
15583           else
15584             # Test for the locale name with explicit encoding suffix.
15585             if (LC_ALL=zh_CN.GB18030 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
15586               gt_cv_locale_zh_CN=zh_CN.GB18030
15587             else
15588               # None found.
15589               gt_cv_locale_zh_CN=none
15590             fi
15591           fi
15592           ;;
15593       esac
15594     else
15595       # If there was a link error, due to mblen(), the system is so old that
15596       # it certainly doesn't have a chinese locale.
15597       gt_cv_locale_zh_CN=none
15598     fi
15599     rm -fr conftest*
15600
15601 fi
15602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_zh_CN" >&5
15603 $as_echo "$gt_cv_locale_zh_CN" >&6; }
15604   LOCALE_ZH_CN=$gt_cv_locale_zh_CN
15605
15606
15607
15608
15609   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a french Unicode locale" >&5
15610 $as_echo_n "checking for a french Unicode locale... " >&6; }
15611 if ${gt_cv_locale_fr_utf8+:} false; then :
15612   $as_echo_n "(cached) " >&6
15613 else
15614
15615     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15616 /* end confdefs.h.  */
15617
15618 #include <locale.h>
15619 #include <time.h>
15620 #if HAVE_LANGINFO_CODESET
15621 # include <langinfo.h>
15622 #endif
15623 #include <stdlib.h>
15624 #include <string.h>
15625 struct tm t;
15626 char buf[16];
15627 int main () {
15628   /* On BeOS and Haiku, locales are not implemented in libc.  Rather, libintl
15629      imitates locale dependent behaviour by looking at the environment
15630      variables, and all locales use the UTF-8 encoding.  */
15631 #if !(defined __BEOS__ || defined __HAIKU__)
15632   /* Check whether the given locale name is recognized by the system.  */
15633 # if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
15634   /* On native Windows, setlocale(category, "") looks at the system settings,
15635      not at the environment variables.  Also, when an encoding suffix such
15636      as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
15637      category of the locale to "C".  */
15638   if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
15639       || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
15640     return 1;
15641 # else
15642   if (setlocale (LC_ALL, "") == NULL) return 1;
15643 # endif
15644   /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
15645      On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
15646      is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
15647      On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
15648      succeeds but then nl_langinfo(CODESET) is "646". In this situation,
15649      some unit tests fail.  */
15650 # if HAVE_LANGINFO_CODESET
15651   {
15652     const char *cs = nl_langinfo (CODESET);
15653     if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0)
15654       return 1;
15655   }
15656 # endif
15657 # ifdef __CYGWIN__
15658   /* On Cygwin, avoid locale names without encoding suffix, because the
15659      locale_charset() function relies on the encoding suffix.  Note that
15660      LC_ALL is set on the command line.  */
15661   if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
15662 # endif
15663   /* Check whether in the abbreviation of the second month, the second
15664      character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is
15665      two bytes long, with UTF-8 encoding.  */
15666   t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
15667   if (strftime (buf, sizeof (buf), "%b", &t) < 4
15668       || buf[1] != (char) 0xc3 || buf[2] != (char) 0xa9 || buf[3] != 'v')
15669     return 1;
15670 #endif
15671 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy.  */
15672   /* Check whether the decimal separator is a comma.
15673      On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
15674      are nl_langinfo(RADIXCHAR) are both ".".  */
15675   if (localeconv () ->decimal_point[0] != ',') return 1;
15676 #endif
15677   return 0;
15678 }
15679
15680 _ACEOF
15681     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
15682   (eval $ac_link) 2>&5
15683   ac_status=$?
15684   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
15685   test $ac_status = 0; } && test -s conftest$ac_exeext; then
15686       case "$host_os" in
15687         # Handle native Windows specially, because there setlocale() interprets
15688         # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
15689         # "fr" or "fra" as "French" or "French_France.1252",
15690         # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
15691         # "ja" as "Japanese" or "Japanese_Japan.932",
15692         # and similar.
15693         mingw*)
15694           # Test for the hypothetical native Windows locale name.
15695           if (LC_ALL=French_France.65001 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
15696             gt_cv_locale_fr_utf8=French_France.65001
15697           else
15698             # None found.
15699             gt_cv_locale_fr_utf8=none
15700           fi
15701           ;;
15702         *)
15703           # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
15704           # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
15705           # configure script would override the LC_ALL setting. Likewise for
15706           # LC_CTYPE, which is also set at the beginning of the configure script.
15707           # Test for the usual locale name.
15708           if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
15709             gt_cv_locale_fr_utf8=fr_FR
15710           else
15711             # Test for the locale name with explicit encoding suffix.
15712             if (LC_ALL=fr_FR.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
15713               gt_cv_locale_fr_utf8=fr_FR.UTF-8
15714             else
15715               # Test for the Solaris 7 locale name.
15716               if (LC_ALL=fr.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
15717                 gt_cv_locale_fr_utf8=fr.UTF-8
15718               else
15719                 # None found.
15720                 gt_cv_locale_fr_utf8=none
15721               fi
15722             fi
15723           fi
15724           ;;
15725       esac
15726     fi
15727     rm -fr conftest*
15728
15729 fi
15730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr_utf8" >&5
15731 $as_echo "$gt_cv_locale_fr_utf8" >&6; }
15732   LOCALE_FR_UTF8=$gt_cv_locale_fr_utf8
15733
15734
15735
15736
15737
15738
15739
15740
15741
15742
15743
15744
15745
15746
15747
15748
15749   # Check for mmap(). Don't use AC_FUNC_MMAP, because it checks too much: it
15750   # fails on HP-UX 11, because MAP_FIXED mappings do not work. But this is
15751   # irrelevant for anonymous mappings.
15752   ac_fn_c_check_func "$LINENO" "mmap" "ac_cv_func_mmap"
15753 if test "x$ac_cv_func_mmap" = xyes; then :
15754   gl_have_mmap=yes
15755 else
15756   gl_have_mmap=no
15757 fi
15758
15759
15760   # Try to allow MAP_ANONYMOUS.
15761   gl_have_mmap_anonymous=no
15762   if test $gl_have_mmap = yes; then
15763     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MAP_ANONYMOUS" >&5
15764 $as_echo_n "checking for MAP_ANONYMOUS... " >&6; }
15765     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15766 /* end confdefs.h.  */
15767
15768 #include <sys/mman.h>
15769 #ifdef MAP_ANONYMOUS
15770     I cannot identify this map
15771 #endif
15772
15773 _ACEOF
15774 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15775   $EGREP "I cannot identify this map" >/dev/null 2>&1; then :
15776   gl_have_mmap_anonymous=yes
15777 fi
15778 rm -f conftest*
15779
15780     if test $gl_have_mmap_anonymous != yes; then
15781       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15782 /* end confdefs.h.  */
15783
15784 #include <sys/mman.h>
15785 #ifdef MAP_ANON
15786     I cannot identify this map
15787 #endif
15788
15789 _ACEOF
15790 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15791   $EGREP "I cannot identify this map" >/dev/null 2>&1; then :
15792
15793 $as_echo "#define MAP_ANONYMOUS MAP_ANON" >>confdefs.h
15794
15795          gl_have_mmap_anonymous=yes
15796 fi
15797 rm -f conftest*
15798
15799     fi
15800     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_have_mmap_anonymous" >&5
15801 $as_echo "$gl_have_mmap_anonymous" >&6; }
15802     if test $gl_have_mmap_anonymous = yes; then
15803
15804 $as_echo "#define HAVE_MAP_ANONYMOUS 1" >>confdefs.h
15805
15806     fi
15807   fi
15808
15809
15810   :
15811
15812
15813
15814
15815
15816
15817   :
15818
15819
15820
15821
15822
15823
15824
15825
15826   if test $HAVE_MEMCHR = 1; then
15827     # Detect platform-specific bugs in some versions of glibc:
15828     # memchr should not dereference anything with length 0
15829     #   http://bugzilla.redhat.com/499689
15830     # memchr should not dereference overestimated length after a match
15831     #   http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=521737
15832     #   http://sourceware.org/bugzilla/show_bug.cgi?id=10162
15833     # Assume that memchr works on platforms that lack mprotect.
15834     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether memchr works" >&5
15835 $as_echo_n "checking whether memchr works... " >&6; }
15836 if ${gl_cv_func_memchr_works+:} false; then :
15837   $as_echo_n "(cached) " >&6
15838 else
15839   if test "$cross_compiling" = yes; then :
15840          gl_cv_func_memchr_works="guessing no"
15841 else
15842   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15843 /* end confdefs.h.  */
15844
15845 #include <string.h>
15846 #if HAVE_SYS_MMAN_H
15847 # include <fcntl.h>
15848 # include <unistd.h>
15849 # include <sys/types.h>
15850 # include <sys/mman.h>
15851 # ifndef MAP_FILE
15852 #  define MAP_FILE 0
15853 # endif
15854 #endif
15855
15856 int
15857 main ()
15858 {
15859
15860   int result = 0;
15861   char *fence = NULL;
15862 #if HAVE_SYS_MMAN_H && HAVE_MPROTECT
15863 # if HAVE_MAP_ANONYMOUS
15864   const int flags = MAP_ANONYMOUS | MAP_PRIVATE;
15865   const int fd = -1;
15866 # else /* !HAVE_MAP_ANONYMOUS */
15867   const int flags = MAP_FILE | MAP_PRIVATE;
15868   int fd = open ("/dev/zero", O_RDONLY, 0666);
15869   if (fd >= 0)
15870 # endif
15871     {
15872       int pagesize = getpagesize ();
15873       char *two_pages =
15874         (char *) mmap (NULL, 2 * pagesize, PROT_READ | PROT_WRITE,
15875                        flags, fd, 0);
15876       if (two_pages != (char *)(-1)
15877           && mprotect (two_pages + pagesize, pagesize, PROT_NONE) == 0)
15878         fence = two_pages + pagesize;
15879     }
15880 #endif
15881   if (fence)
15882     {
15883       if (memchr (fence, 0, 0))
15884         result |= 1;
15885       strcpy (fence - 9, "12345678");
15886       if (memchr (fence - 9, 0, 79) != fence - 1)
15887         result |= 2;
15888       if (memchr (fence - 1, 0, 3) != fence - 1)
15889         result |= 4;
15890     }
15891   return result;
15892
15893   ;
15894   return 0;
15895 }
15896 _ACEOF
15897 if ac_fn_c_try_run "$LINENO"; then :
15898   gl_cv_func_memchr_works=yes
15899 else
15900   gl_cv_func_memchr_works=no
15901 fi
15902 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15903   conftest.$ac_objext conftest.beam conftest.$ac_ext
15904 fi
15905
15906 fi
15907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_memchr_works" >&5
15908 $as_echo "$gl_cv_func_memchr_works" >&6; }
15909     if test "$gl_cv_func_memchr_works" != yes; then
15910       REPLACE_MEMCHR=1
15911     fi
15912   fi
15913
15914
15915
15916
15917
15918
15919
15920
15921
15922
15923
15924
15925
15926
15927
15928
15929
15930   GNULIB_MKTIME=0;
15931   GNULIB_NANOSLEEP=0;
15932   GNULIB_STRPTIME=0;
15933   GNULIB_TIMEGM=0;
15934   GNULIB_TIME_R=0;
15935     HAVE_DECL_LOCALTIME_R=1;
15936   HAVE_NANOSLEEP=1;
15937   HAVE_STRPTIME=1;
15938   HAVE_TIMEGM=1;
15939         REPLACE_LOCALTIME_R=GNULIB_PORTCHECK;
15940   REPLACE_MKTIME=GNULIB_PORTCHECK;
15941   REPLACE_NANOSLEEP=GNULIB_PORTCHECK;
15942   REPLACE_TIMEGM=GNULIB_PORTCHECK;
15943
15944       : ${GNULIB_GETTIMEOFDAY=0};
15945         REPLACE_GMTIME=0;
15946   REPLACE_LOCALTIME=0;
15947
15948
15949       ac_fn_c_check_decl "$LINENO" "alarm" "ac_cv_have_decl_alarm" "$ac_includes_default"
15950 if test "x$ac_cv_have_decl_alarm" = xyes; then :
15951   ac_have_decl=1
15952 else
15953   ac_have_decl=0
15954 fi
15955
15956 cat >>confdefs.h <<_ACEOF
15957 #define HAVE_DECL_ALARM $ac_have_decl
15958 _ACEOF
15959
15960
15961
15962     gl_cv_c_multiarch=no
15963   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15964 /* end confdefs.h.  */
15965 #ifndef __APPLE_CC__
15966          not a universal capable compiler
15967         #endif
15968         typedef int dummy;
15969
15970 _ACEOF
15971 if ac_fn_c_try_compile "$LINENO"; then :
15972
15973                arch=
15974      prev=
15975      for word in ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do
15976        if test -n "$prev"; then
15977          case $word in
15978            i?86 | x86_64 | ppc | ppc64)
15979              if test -z "$arch" || test "$arch" = "$word"; then
15980                arch="$word"
15981              else
15982                gl_cv_c_multiarch=yes
15983              fi
15984              ;;
15985          esac
15986          prev=
15987        else
15988          if test "x$word" = "x-arch"; then
15989            prev=arch
15990          fi
15991        fi
15992      done
15993
15994 fi
15995 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15996   if test $gl_cv_c_multiarch = yes; then
15997     APPLE_UNIVERSAL_BUILD=1
15998   else
15999     APPLE_UNIVERSAL_BUILD=0
16000   fi
16001
16002
16003
16004
16005
16006
16007
16008
16009
16010   case "$host_os" in
16011     mingw*) gl_cv_have_nonblocking=no ;;
16012     *)      gl_cv_have_nonblocking=yes ;;
16013   esac
16014   case "$host_os" in
16015     mingw*) gl_cv_have_open_O_NONBLOCK=no ;;
16016     *)      gl_cv_have_open_O_NONBLOCK=yes ;;
16017   esac
16018
16019
16020   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16021 /* end confdefs.h.  */
16022
16023 #ifdef _MSC_VER
16024 MicrosoftCompiler
16025 #endif
16026
16027 _ACEOF
16028 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16029   $EGREP "MicrosoftCompiler" >/dev/null 2>&1; then :
16030   gl_asmext='asm'
16031      gl_c_asm_opt='-c -Fa'
16032
16033 else
16034   gl_asmext='s'
16035      gl_c_asm_opt='-S'
16036
16037 fi
16038 rm -f conftest*
16039
16040
16041
16042
16043   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C symbols are prefixed with underscore at the linker level" >&5
16044 $as_echo_n "checking whether C symbols are prefixed with underscore at the linker level... " >&6; }
16045 if ${gl_cv_prog_as_underscore+:} false; then :
16046   $as_echo_n "(cached) " >&6
16047 else
16048   cat > conftest.c <<EOF
16049 #ifdef __cplusplus
16050 extern "C" int foo (void);
16051 #endif
16052 int foo(void) { return 0; }
16053 EOF
16054      # Look for the assembly language name in the .s file.
16055      { ac_try='${CC-cc} $CFLAGS $CPPFLAGS $gl_c_asm_opt conftest.c'
16056   { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5
16057   (eval $ac_try) 2>&5
16058   ac_status=$?
16059   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
16060   test $ac_status = 0; }; } >/dev/null 2>&1
16061      if grep _foo conftest.$gl_asmext >/dev/null ; then
16062        gl_cv_prog_as_underscore=yes
16063      else
16064        gl_cv_prog_as_underscore=no
16065      fi
16066      rm -f conftest*
16067
16068 fi
16069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_prog_as_underscore" >&5
16070 $as_echo "$gl_cv_prog_as_underscore" >&6; }
16071   if test $gl_cv_prog_as_underscore = yes; then
16072     USER_LABEL_PREFIX=_
16073   else
16074     USER_LABEL_PREFIX=
16075   fi
16076
16077 cat >>confdefs.h <<_ACEOF
16078 #define USER_LABEL_PREFIX $USER_LABEL_PREFIX
16079 _ACEOF
16080
16081   ASM_SYMBOL_PREFIX='"'${USER_LABEL_PREFIX}'"'
16082
16083
16084
16085
16086   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for promoted mode_t type" >&5
16087 $as_echo_n "checking for promoted mode_t type... " >&6; }
16088 if ${gl_cv_promoted_mode_t+:} false; then :
16089   $as_echo_n "(cached) " >&6
16090 else
16091
16092                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16093 /* end confdefs.h.  */
16094 #include <sys/types.h>
16095 int
16096 main ()
16097 {
16098 typedef int array[2 * (sizeof (mode_t) < sizeof (int)) - 1];
16099   ;
16100   return 0;
16101 }
16102 _ACEOF
16103 if ac_fn_c_try_compile "$LINENO"; then :
16104   gl_cv_promoted_mode_t='int'
16105 else
16106   gl_cv_promoted_mode_t='mode_t'
16107 fi
16108 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16109
16110 fi
16111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_promoted_mode_t" >&5
16112 $as_echo "$gl_cv_promoted_mode_t" >&6; }
16113
16114 cat >>confdefs.h <<_ACEOF
16115 #define PROMOTED_MODE_T $gl_cv_promoted_mode_t
16116 _ACEOF
16117
16118
16119
16120   # Check for the library required for forkpty.
16121   PTY_LIB=
16122   save_LIBS="$LIBS"
16123   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing forkpty" >&5
16124 $as_echo_n "checking for library containing forkpty... " >&6; }
16125 if ${ac_cv_search_forkpty+:} false; then :
16126   $as_echo_n "(cached) " >&6
16127 else
16128   ac_func_search_save_LIBS=$LIBS
16129 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16130 /* end confdefs.h.  */
16131
16132 /* Override any GCC internal prototype to avoid an error.
16133    Use char because int might match the return type of a GCC
16134    builtin and then its argument prototype would still apply.  */
16135 #ifdef __cplusplus
16136 extern "C"
16137 #endif
16138 char forkpty ();
16139 int
16140 main ()
16141 {
16142 return forkpty ();
16143   ;
16144   return 0;
16145 }
16146 _ACEOF
16147 for ac_lib in '' util; do
16148   if test -z "$ac_lib"; then
16149     ac_res="none required"
16150   else
16151     ac_res=-l$ac_lib
16152     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
16153   fi
16154   if ac_fn_c_try_link "$LINENO"; then :
16155   ac_cv_search_forkpty=$ac_res
16156 fi
16157 rm -f core conftest.err conftest.$ac_objext \
16158     conftest$ac_exeext
16159   if ${ac_cv_search_forkpty+:} false; then :
16160   break
16161 fi
16162 done
16163 if ${ac_cv_search_forkpty+:} false; then :
16164
16165 else
16166   ac_cv_search_forkpty=no
16167 fi
16168 rm conftest.$ac_ext
16169 LIBS=$ac_func_search_save_LIBS
16170 fi
16171 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_forkpty" >&5
16172 $as_echo "$ac_cv_search_forkpty" >&6; }
16173 ac_res=$ac_cv_search_forkpty
16174 if test "$ac_res" != no; then :
16175   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
16176   if test "$ac_cv_search_forkpty" != "none required"; then
16177        PTY_LIB="$ac_cv_search_forkpty"
16178      fi
16179 fi
16180
16181   LIBS="$save_LIBS"
16182
16183
16184
16185   GNULIB_FORKPTY=0;
16186   GNULIB_OPENPTY=0;
16187     HAVE_UTIL_H=0;
16188   HAVE_LIBUTIL_H=0;
16189   HAVE_FORKPTY=1;
16190   HAVE_OPENPTY=1;
16191   REPLACE_FORKPTY=0;
16192   REPLACE_OPENPTY=0;
16193
16194
16195
16196
16197
16198
16199
16200
16201
16202   # Make sure that pty.h provides forkpty, or setup the replacement.
16203
16204   :
16205
16206
16207
16208
16209
16210   if test $ac_cv_header_pty_h != yes; then
16211     HAVE_PTY_H=0
16212     for ac_header in util.h libutil.h
16213 do :
16214   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
16215 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
16216 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
16217   cat >>confdefs.h <<_ACEOF
16218 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
16219 _ACEOF
16220
16221 fi
16222
16223 done
16224
16225     if test $ac_cv_header_util_h = yes; then
16226       HAVE_UTIL_H=1
16227     fi
16228     if test $ac_cv_header_libutil_h = yes; then
16229       HAVE_LIBUTIL_H=1
16230     fi
16231   else # Have <pty.h>, assume forkpty is declared there.
16232     HAVE_PTY_H=1
16233   fi
16234
16235
16236
16237
16238
16239
16240
16241   :
16242
16243
16244
16245
16246
16247
16248
16249
16250      if test $gl_cv_have_include_next = yes; then
16251        gl_cv_next_pty_h='<'pty.h'>'
16252      else
16253        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <pty.h>" >&5
16254 $as_echo_n "checking absolute name of <pty.h>... " >&6; }
16255 if ${gl_cv_next_pty_h+:} false; then :
16256   $as_echo_n "(cached) " >&6
16257 else
16258
16259              if test $ac_cv_header_pty_h = yes; then
16260
16261
16262
16263
16264   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16265 /* end confdefs.h.  */
16266 #include <pty.h>
16267 _ACEOF
16268                 case "$host_os" in
16269     aix*) gl_absname_cpp="$ac_cpp -C" ;;
16270     *)    gl_absname_cpp="$ac_cpp" ;;
16271   esac
16272
16273   case "$host_os" in
16274     mingw*)
16275                                           gl_dirsep_regex='[/\\]'
16276       ;;
16277     *)
16278       gl_dirsep_regex='\/'
16279       ;;
16280   esac
16281       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
16282   gl_header_literal_regex=`echo 'pty.h' \
16283                            | sed -e "$gl_make_literal_regex_sed"`
16284   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
16285       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
16286       s|^/[^/]|//&|
16287       p
16288       q
16289     }'
16290
16291         gl_cv_absolute_pty_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
16292   sed -n "$gl_absolute_header_sed"`
16293
16294            gl_header=$gl_cv_absolute_pty_h
16295            gl_cv_next_pty_h='"'$gl_header'"'
16296           else
16297                gl_cv_next_pty_h='<'pty.h'>'
16298              fi
16299
16300
16301 fi
16302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_pty_h" >&5
16303 $as_echo "$gl_cv_next_pty_h" >&6; }
16304      fi
16305      NEXT_PTY_H=$gl_cv_next_pty_h
16306
16307      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
16308        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
16309        gl_next_as_first_directive='<'pty.h'>'
16310      else
16311        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
16312        gl_next_as_first_directive=$gl_cv_next_pty_h
16313      fi
16314      NEXT_AS_FIRST_DIRECTIVE_PTY_H=$gl_next_as_first_directive
16315
16316
16317
16318
16319
16320
16321
16322
16323
16324
16325
16326
16327
16328
16329
16330
16331
16332
16333      REPLACE_STRERROR_0=0
16334   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strerror(0) succeeds" >&5
16335 $as_echo_n "checking whether strerror(0) succeeds... " >&6; }
16336 if ${gl_cv_func_strerror_0_works+:} false; then :
16337   $as_echo_n "(cached) " >&6
16338 else
16339   if test "$cross_compiling" = yes; then :
16340   case "$host_os" in
16341                  # Guess yes on glibc systems.
16342          *-gnu*) gl_cv_func_strerror_0_works="guessing yes" ;;
16343                  # If we don't know, assume the worst.
16344          *)      gl_cv_func_strerror_0_works="guessing no" ;;
16345        esac
16346
16347 else
16348   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16349 /* end confdefs.h.  */
16350 #include <string.h>
16351            #include <errno.h>
16352
16353 int
16354 main ()
16355 {
16356 int result = 0;
16357            char *str;
16358            errno = 0;
16359            str = strerror (0);
16360            if (!*str) result |= 1;
16361            if (errno) result |= 2;
16362            if (strstr (str, "nknown") || strstr (str, "ndefined"))
16363              result |= 4;
16364            return result;
16365   ;
16366   return 0;
16367 }
16368 _ACEOF
16369 if ac_fn_c_try_run "$LINENO"; then :
16370   gl_cv_func_strerror_0_works=yes
16371 else
16372   gl_cv_func_strerror_0_works=no
16373 fi
16374 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16375   conftest.$ac_objext conftest.beam conftest.$ac_ext
16376 fi
16377
16378
16379 fi
16380 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strerror_0_works" >&5
16381 $as_echo "$gl_cv_func_strerror_0_works" >&6; }
16382   case "$gl_cv_func_strerror_0_works" in
16383     *yes) ;;
16384     *)
16385       REPLACE_STRERROR_0=1
16386
16387 $as_echo "#define REPLACE_STRERROR_0 1" >>confdefs.h
16388
16389       ;;
16390   esac
16391
16392
16393
16394
16395
16396
16397
16398
16399
16400
16401
16402
16403
16404
16405
16406
16407   :
16408
16409
16410
16411
16412
16413   if test $ac_cv_func_strerror_r = yes; then
16414     if test "$ERRNO_H:$REPLACE_STRERROR_0" = :0; then
16415                         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for strerror_r with POSIX signature" >&5
16416 $as_echo_n "checking for strerror_r with POSIX signature... " >&6; }
16417 if ${gl_cv_func_strerror_r_posix_signature+:} false; then :
16418   $as_echo_n "(cached) " >&6
16419 else
16420   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16421 /* end confdefs.h.  */
16422 #include <string.h>
16423                 int strerror_r (int, char *, size_t);
16424
16425 int
16426 main ()
16427 {
16428
16429   ;
16430   return 0;
16431 }
16432 _ACEOF
16433 if ac_fn_c_try_compile "$LINENO"; then :
16434   gl_cv_func_strerror_r_posix_signature=yes
16435 else
16436   gl_cv_func_strerror_r_posix_signature=no
16437 fi
16438 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16439
16440 fi
16441 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strerror_r_posix_signature" >&5
16442 $as_echo "$gl_cv_func_strerror_r_posix_signature" >&6; }
16443       if test $gl_cv_func_strerror_r_posix_signature = yes; then
16444                                                         { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strerror_r works" >&5
16445 $as_echo_n "checking whether strerror_r works... " >&6; }
16446 if ${gl_cv_func_strerror_r_works+:} false; then :
16447   $as_echo_n "(cached) " >&6
16448 else
16449   if test "$cross_compiling" = yes; then :
16450
16451               case "$host_os" in
16452                        # Guess no on AIX.
16453                 aix*)  gl_cv_func_strerror_r_works="guessing no";;
16454                        # Guess no on HP-UX.
16455                 hpux*) gl_cv_func_strerror_r_works="guessing no";;
16456                        # Guess no on BSD variants.
16457                 *bsd*)  gl_cv_func_strerror_r_works="guessing no";;
16458                        # Guess yes otherwise.
16459                 *)     gl_cv_func_strerror_r_works="guessing yes";;
16460               esac
16461
16462 else
16463   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16464 /* end confdefs.h.  */
16465 #include <errno.h>
16466                   #include <string.h>
16467
16468 int
16469 main ()
16470 {
16471 int result = 0;
16472                   char buf[79];
16473                   if (strerror_r (EACCES, buf, 0) < 0)
16474                     result |= 1;
16475                   errno = 0;
16476                   if (strerror_r (EACCES, buf, sizeof buf) != 0)
16477                     result |= 2;
16478                   strcpy (buf, "Unknown");
16479                   if (strerror_r (0, buf, sizeof buf) != 0)
16480                     result |= 4;
16481                   if (errno)
16482                     result |= 8;
16483                   if (strstr (buf, "nknown") || strstr (buf, "ndefined"))
16484                     result |= 0x10;
16485                   errno = 0;
16486                   *buf = 0;
16487                   if (strerror_r (-3, buf, sizeof buf) < 0)
16488                     result |= 0x20;
16489                   if (errno)
16490                     result |= 0x40;
16491                   if (!*buf)
16492                     result |= 0x80;
16493                   return result;
16494
16495   ;
16496   return 0;
16497 }
16498 _ACEOF
16499 if ac_fn_c_try_run "$LINENO"; then :
16500   gl_cv_func_strerror_r_works=yes
16501 else
16502   gl_cv_func_strerror_r_works=no
16503 fi
16504 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16505   conftest.$ac_objext conftest.beam conftest.$ac_ext
16506 fi
16507
16508
16509 fi
16510 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strerror_r_works" >&5
16511 $as_echo "$gl_cv_func_strerror_r_works" >&6; }
16512       else
16513
16514   :
16515
16516
16517
16518
16519
16520                         if test $ac_cv_func___xpg_strerror_r = yes; then
16521           { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether __xpg_strerror_r works" >&5
16522 $as_echo_n "checking whether __xpg_strerror_r works... " >&6; }
16523 if ${gl_cv_func_strerror_r_works+:} false; then :
16524   $as_echo_n "(cached) " >&6
16525 else
16526   if test "$cross_compiling" = yes; then :
16527                                   gl_cv_func_strerror_r_works="guessing no"
16528
16529 else
16530   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16531 /* end confdefs.h.  */
16532 #include <errno.h>
16533                     #include <string.h>
16534                     extern
16535                     #ifdef __cplusplus
16536                     "C"
16537                     #endif
16538                     int __xpg_strerror_r(int, char *, size_t);
16539
16540 int
16541 main ()
16542 {
16543 int result = 0;
16544                     char buf[256] = "^";
16545                     char copy[256];
16546                     char *str = strerror (-1);
16547                     strcpy (copy, str);
16548                     if (__xpg_strerror_r (-2, buf, 1) == 0)
16549                       result |= 1;
16550                     if (*buf)
16551                       result |= 2;
16552                     __xpg_strerror_r (-2, buf, 256);
16553                     if (strcmp (str, copy))
16554                       result |= 4;
16555                     return result;
16556
16557   ;
16558   return 0;
16559 }
16560 _ACEOF
16561 if ac_fn_c_try_run "$LINENO"; then :
16562   gl_cv_func_strerror_r_works=yes
16563 else
16564   gl_cv_func_strerror_r_works=no
16565 fi
16566 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16567   conftest.$ac_objext conftest.beam conftest.$ac_ext
16568 fi
16569
16570
16571 fi
16572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strerror_r_works" >&5
16573 $as_echo "$gl_cv_func_strerror_r_works" >&6; }
16574         fi
16575       fi
16576     fi
16577   fi
16578
16579
16580       ac_fn_c_check_decl "$LINENO" "strerror_r" "ac_cv_have_decl_strerror_r" "$ac_includes_default"
16581 if test "x$ac_cv_have_decl_strerror_r" = xyes; then :
16582   ac_have_decl=1
16583 else
16584   ac_have_decl=0
16585 fi
16586
16587 cat >>confdefs.h <<_ACEOF
16588 #define HAVE_DECL_STRERROR_R $ac_have_decl
16589 _ACEOF
16590
16591
16592
16593
16594
16595
16596
16597
16598
16599   :
16600
16601
16602
16603
16604
16605   if test $ac_cv_have_decl_strerror_r = no; then
16606     HAVE_DECL_STRERROR_R=0
16607   fi
16608
16609   if test $ac_cv_func_strerror_r = yes; then
16610     if test "$ERRNO_H:$REPLACE_STRERROR_0" = :0; then
16611       if test $gl_cv_func_strerror_r_posix_signature = yes; then
16612         case "$gl_cv_func_strerror_r_works" in
16613                     *no) REPLACE_STRERROR_R=1 ;;
16614         esac
16615       else
16616                 REPLACE_STRERROR_R=1
16617       fi
16618     else
16619                   REPLACE_STRERROR_R=1
16620     fi
16621   fi
16622
16623 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for external symbol _system_configuration" >&5
16624 $as_echo_n "checking for external symbol _system_configuration... " >&6; }
16625 if ${gl_cv_var__system_configuration+:} false; then :
16626   $as_echo_n "(cached) " >&6
16627 else
16628   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16629 /* end confdefs.h.  */
16630 #include <sys/systemcfg.h>
16631
16632 int
16633 main ()
16634 {
16635 double x = _system_configuration.physmem;
16636                         if (x > 0.0) return 0;
16637   ;
16638   return 0;
16639 }
16640 _ACEOF
16641 if ac_fn_c_try_link "$LINENO"; then :
16642   gl_cv_var__system_configuration=yes
16643 else
16644   gl_cv_var__system_configuration=no
16645 fi
16646 rm -f core conftest.err conftest.$ac_objext \
16647     conftest$ac_exeext conftest.$ac_ext
16648 fi
16649 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_var__system_configuration" >&5
16650 $as_echo "$gl_cv_var__system_configuration" >&6; }
16651
16652     if test $gl_cv_var__system_configuration = yes; then
16653
16654 $as_echo "#define HAVE__SYSTEM_CONFIGURATION 1" >>confdefs.h
16655
16656     fi
16657
16658
16659
16660
16661
16662
16663
16664
16665
16666
16667
16668
16669
16670   GNULIB_POLL=0;
16671     HAVE_POLL=1;
16672   REPLACE_POLL=0;
16673
16674
16675
16676
16677
16678
16679
16680
16681
16682
16683   :
16684
16685
16686
16687
16688
16689   if test $ac_cv_header_poll_h = yes; then
16690     HAVE_POLL_H=1
16691   else
16692     HAVE_POLL_H=0
16693   fi
16694
16695
16696
16697
16698
16699
16700
16701
16702   :
16703
16704
16705
16706
16707
16708
16709
16710
16711      if test $gl_cv_have_include_next = yes; then
16712        gl_cv_next_poll_h='<'poll.h'>'
16713      else
16714        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <poll.h>" >&5
16715 $as_echo_n "checking absolute name of <poll.h>... " >&6; }
16716 if ${gl_cv_next_poll_h+:} false; then :
16717   $as_echo_n "(cached) " >&6
16718 else
16719
16720              if test $ac_cv_header_poll_h = yes; then
16721
16722
16723
16724
16725   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16726 /* end confdefs.h.  */
16727 #include <poll.h>
16728 _ACEOF
16729                 case "$host_os" in
16730     aix*) gl_absname_cpp="$ac_cpp -C" ;;
16731     *)    gl_absname_cpp="$ac_cpp" ;;
16732   esac
16733
16734   case "$host_os" in
16735     mingw*)
16736                                           gl_dirsep_regex='[/\\]'
16737       ;;
16738     *)
16739       gl_dirsep_regex='\/'
16740       ;;
16741   esac
16742       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
16743   gl_header_literal_regex=`echo 'poll.h' \
16744                            | sed -e "$gl_make_literal_regex_sed"`
16745   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
16746       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
16747       s|^/[^/]|//&|
16748       p
16749       q
16750     }'
16751
16752         gl_cv_absolute_poll_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
16753   sed -n "$gl_absolute_header_sed"`
16754
16755            gl_header=$gl_cv_absolute_poll_h
16756            gl_cv_next_poll_h='"'$gl_header'"'
16757           else
16758                gl_cv_next_poll_h='<'poll.h'>'
16759              fi
16760
16761
16762 fi
16763 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_poll_h" >&5
16764 $as_echo "$gl_cv_next_poll_h" >&6; }
16765      fi
16766      NEXT_POLL_H=$gl_cv_next_poll_h
16767
16768      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
16769        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
16770        gl_next_as_first_directive='<'poll.h'>'
16771      else
16772        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
16773        gl_next_as_first_directive=$gl_cv_next_poll_h
16774      fi
16775      NEXT_AS_FIRST_DIRECTIVE_POLL_H=$gl_next_as_first_directive
16776
16777
16778
16779
16780
16781
16782
16783 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
16784 $as_echo_n "checking for inline... " >&6; }
16785 if ${ac_cv_c_inline+:} false; then :
16786   $as_echo_n "(cached) " >&6
16787 else
16788   ac_cv_c_inline=no
16789 for ac_kw in inline __inline__ __inline; do
16790   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16791 /* end confdefs.h.  */
16792 #ifndef __cplusplus
16793 typedef int foo_t;
16794 static $ac_kw foo_t static_foo () {return 0; }
16795 $ac_kw foo_t foo () {return 0; }
16796 #endif
16797
16798 _ACEOF
16799 if ac_fn_c_try_compile "$LINENO"; then :
16800   ac_cv_c_inline=$ac_kw
16801 fi
16802 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16803   test "$ac_cv_c_inline" != no && break
16804 done
16805
16806 fi
16807 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
16808 $as_echo "$ac_cv_c_inline" >&6; }
16809
16810 case $ac_cv_c_inline in
16811   inline | yes) ;;
16812   *)
16813     case $ac_cv_c_inline in
16814       no) ac_val=;;
16815       *) ac_val=$ac_cv_c_inline;;
16816     esac
16817     cat >>confdefs.h <<_ACEOF
16818 #ifndef __cplusplus
16819 #define inline $ac_val
16820 #endif
16821 _ACEOF
16822     ;;
16823 esac
16824
16825
16826
16827
16828
16829
16830   :
16831
16832
16833
16834
16835
16836   if test $ac_cv_header_sys_socket_h != yes; then
16837                     for ac_header in winsock2.h
16838 do :
16839   ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
16840 if test "x$ac_cv_header_winsock2_h" = xyes; then :
16841   cat >>confdefs.h <<_ACEOF
16842 #define HAVE_WINSOCK2_H 1
16843 _ACEOF
16844
16845 fi
16846
16847 done
16848
16849   fi
16850   if test "$ac_cv_header_winsock2_h" = yes; then
16851     HAVE_WINSOCK2_H=1
16852     UNISTD_H_HAVE_WINSOCK2_H=1
16853     SYS_IOCTL_H_HAVE_WINSOCK2_H=1
16854   else
16855     HAVE_WINSOCK2_H=0
16856   fi
16857
16858    LIBSOCKET=
16859   if test $HAVE_WINSOCK2_H = 1; then
16860         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we need to call WSAStartup in winsock2.h and -lws2_32" >&5
16861 $as_echo_n "checking if we need to call WSAStartup in winsock2.h and -lws2_32... " >&6; }
16862 if ${gl_cv_func_wsastartup+:} false; then :
16863   $as_echo_n "(cached) " >&6
16864 else
16865
16866       gl_save_LIBS="$LIBS"
16867       LIBS="$LIBS -lws2_32"
16868       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16869 /* end confdefs.h.  */
16870
16871 #ifdef HAVE_WINSOCK2_H
16872 # include <winsock2.h>
16873 #endif
16874 int
16875 main ()
16876 {
16877
16878           WORD wVersionRequested = MAKEWORD(1, 1);
16879           WSADATA wsaData;
16880           int err = WSAStartup(wVersionRequested, &wsaData);
16881           WSACleanup ();
16882   ;
16883   return 0;
16884 }
16885 _ACEOF
16886 if ac_fn_c_try_link "$LINENO"; then :
16887   gl_cv_func_wsastartup=yes
16888 else
16889   gl_cv_func_wsastartup=no
16890 fi
16891 rm -f core conftest.err conftest.$ac_objext \
16892     conftest$ac_exeext conftest.$ac_ext
16893       LIBS="$gl_save_LIBS"
16894
16895 fi
16896 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_wsastartup" >&5
16897 $as_echo "$gl_cv_func_wsastartup" >&6; }
16898     if test "$gl_cv_func_wsastartup" = "yes"; then
16899
16900 $as_echo "#define WINDOWS_SOCKETS 1" >>confdefs.h
16901
16902       LIBSOCKET='-lws2_32'
16903     fi
16904   else
16905                     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing setsockopt" >&5
16906 $as_echo_n "checking for library containing setsockopt... " >&6; }
16907 if ${gl_cv_lib_socket+:} false; then :
16908   $as_echo_n "(cached) " >&6
16909 else
16910
16911       gl_cv_lib_socket=
16912       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16913 /* end confdefs.h.  */
16914 extern
16915 #ifdef __cplusplus
16916 "C"
16917 #endif
16918 char setsockopt();
16919 int
16920 main ()
16921 {
16922 setsockopt();
16923   ;
16924   return 0;
16925 }
16926 _ACEOF
16927 if ac_fn_c_try_link "$LINENO"; then :
16928
16929 else
16930   gl_save_LIBS="$LIBS"
16931          LIBS="$gl_save_LIBS -lsocket"
16932          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16933 /* end confdefs.h.  */
16934 extern
16935 #ifdef __cplusplus
16936 "C"
16937 #endif
16938 char setsockopt();
16939 int
16940 main ()
16941 {
16942 setsockopt();
16943   ;
16944   return 0;
16945 }
16946 _ACEOF
16947 if ac_fn_c_try_link "$LINENO"; then :
16948   gl_cv_lib_socket="-lsocket"
16949 fi
16950 rm -f core conftest.err conftest.$ac_objext \
16951     conftest$ac_exeext conftest.$ac_ext
16952          if test -z "$gl_cv_lib_socket"; then
16953            LIBS="$gl_save_LIBS -lnetwork"
16954            cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16955 /* end confdefs.h.  */
16956 extern
16957 #ifdef __cplusplus
16958 "C"
16959 #endif
16960 char setsockopt();
16961 int
16962 main ()
16963 {
16964 setsockopt();
16965   ;
16966   return 0;
16967 }
16968 _ACEOF
16969 if ac_fn_c_try_link "$LINENO"; then :
16970   gl_cv_lib_socket="-lnetwork"
16971 fi
16972 rm -f core conftest.err conftest.$ac_objext \
16973     conftest$ac_exeext conftest.$ac_ext
16974            if test -z "$gl_cv_lib_socket"; then
16975              LIBS="$gl_save_LIBS -lnet"
16976              cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16977 /* end confdefs.h.  */
16978 extern
16979 #ifdef __cplusplus
16980 "C"
16981 #endif
16982 char setsockopt();
16983 int
16984 main ()
16985 {
16986 setsockopt();
16987   ;
16988   return 0;
16989 }
16990 _ACEOF
16991 if ac_fn_c_try_link "$LINENO"; then :
16992   gl_cv_lib_socket="-lnet"
16993 fi
16994 rm -f core conftest.err conftest.$ac_objext \
16995     conftest$ac_exeext conftest.$ac_ext
16996            fi
16997          fi
16998          LIBS="$gl_save_LIBS"
16999
17000 fi
17001 rm -f core conftest.err conftest.$ac_objext \
17002     conftest$ac_exeext conftest.$ac_ext
17003       if test -z "$gl_cv_lib_socket"; then
17004         gl_cv_lib_socket="none needed"
17005       fi
17006
17007 fi
17008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_lib_socket" >&5
17009 $as_echo "$gl_cv_lib_socket" >&6; }
17010     if test "$gl_cv_lib_socket" != "none needed"; then
17011       LIBSOCKET="$gl_cv_lib_socket"
17012     fi
17013   fi
17014
17015
17016
17017
17018
17019
17020   :
17021
17022
17023
17024
17025
17026
17027
17028
17029
17030
17031
17032
17033
17034
17035
17036
17037
17038
17039     HAVE_PTHREAD_H=1;
17040   HAVE_PTHREAD_T=1;
17041   HAVE_PTHREAD_SPINLOCK_T=1;
17042
17043
17044
17045
17046
17047
17048
17049   GNULIB_PTHREAD_SIGMASK=0;
17050   GNULIB_RAISE=0;
17051   GNULIB_SIGNAL_H_SIGPIPE=0;
17052   GNULIB_SIGPROCMASK=0;
17053   GNULIB_SIGACTION=0;
17054     HAVE_POSIX_SIGNALBLOCKING=1;
17055   HAVE_PTHREAD_SIGMASK=1;
17056   HAVE_RAISE=1;
17057   HAVE_SIGSET_T=1;
17058   HAVE_SIGINFO_T=1;
17059   HAVE_SIGACTION=1;
17060   HAVE_STRUCT_SIGACTION_SA_SIGACTION=1;
17061
17062   HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=1;
17063
17064   HAVE_SIGHANDLER_T=1;
17065   REPLACE_PTHREAD_SIGMASK=0;
17066   REPLACE_RAISE=0;
17067
17068
17069
17070
17071
17072
17073
17074   ac_fn_c_check_type "$LINENO" "sigset_t" "ac_cv_type_sigset_t" "
17075       #include <signal.h>
17076       /* Mingw defines sigset_t not in <signal.h>, but in <sys/types.h>.  */
17077       #include <sys/types.h>
17078
17079 "
17080 if test "x$ac_cv_type_sigset_t" = xyes; then :
17081
17082 cat >>confdefs.h <<_ACEOF
17083 #define HAVE_SIGSET_T 1
17084 _ACEOF
17085
17086 gl_cv_type_sigset_t=yes
17087 else
17088   gl_cv_type_sigset_t=no
17089 fi
17090
17091   if test $gl_cv_type_sigset_t != yes; then
17092     HAVE_SIGSET_T=0
17093   fi
17094
17095
17096
17097   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SIGPIPE" >&5
17098 $as_echo_n "checking for SIGPIPE... " >&6; }
17099 if ${gl_cv_header_signal_h_SIGPIPE+:} false; then :
17100   $as_echo_n "(cached) " >&6
17101 else
17102
17103     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17104 /* end confdefs.h.  */
17105
17106 #include <signal.h>
17107 #if !defined SIGPIPE
17108 booboo
17109 #endif
17110
17111 _ACEOF
17112 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17113   $EGREP "booboo" >/dev/null 2>&1; then :
17114   gl_cv_header_signal_h_SIGPIPE=no
17115 else
17116   gl_cv_header_signal_h_SIGPIPE=yes
17117 fi
17118 rm -f conftest*
17119
17120
17121 fi
17122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_signal_h_SIGPIPE" >&5
17123 $as_echo "$gl_cv_header_signal_h_SIGPIPE" >&6; }
17124
17125
17126
17127
17128
17129
17130
17131
17132
17133
17134
17135
17136
17137
17138
17139
17140
17141   GNULIB_PSELECT=0;
17142   GNULIB_SELECT=0;
17143     HAVE_PSELECT=1;
17144   REPLACE_PSELECT=0;
17145   REPLACE_SELECT=0;
17146
17147
17148
17149
17150
17151
17152
17153
17154
17155   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
17156 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
17157 if ${gl_cv_header_sys_select_h_selfcontained+:} false; then :
17158   $as_echo_n "(cached) " >&6
17159 else
17160
17161                                     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17162 /* end confdefs.h.  */
17163 #include <sys/select.h>
17164 int
17165 main ()
17166 {
17167 struct timeval b;
17168   ;
17169   return 0;
17170 }
17171 _ACEOF
17172 if ac_fn_c_try_compile "$LINENO"; then :
17173   gl_cv_header_sys_select_h_selfcontained=yes
17174 else
17175   gl_cv_header_sys_select_h_selfcontained=no
17176 fi
17177 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17178                         if test $gl_cv_header_sys_select_h_selfcontained = yes; then
17179         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17180 /* end confdefs.h.  */
17181 #include <sys/select.h>
17182 int
17183 main ()
17184 {
17185 int memset; int bzero;
17186   ;
17187   return 0;
17188 }
17189
17190 _ACEOF
17191 if ac_fn_c_try_compile "$LINENO"; then :
17192   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17193 /* end confdefs.h.  */
17194 #include <sys/select.h>
17195 int
17196 main ()
17197 {
17198
17199                   #undef memset
17200                   #define memset nonexistent_memset
17201                   extern
17202                   #ifdef __cplusplus
17203                   "C"
17204                   #endif
17205                   void *memset (void *, int, unsigned long);
17206                   #undef bzero
17207                   #define bzero nonexistent_bzero
17208                   extern
17209                   #ifdef __cplusplus
17210                   "C"
17211                   #endif
17212                   void bzero (void *, unsigned long);
17213                   fd_set fds;
17214                   FD_ZERO (&fds);
17215
17216   ;
17217   return 0;
17218 }
17219
17220 _ACEOF
17221 if ac_fn_c_try_link "$LINENO"; then :
17222
17223 else
17224   gl_cv_header_sys_select_h_selfcontained=no
17225 fi
17226 rm -f core conftest.err conftest.$ac_objext \
17227     conftest$ac_exeext conftest.$ac_ext
17228
17229 fi
17230 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17231       fi
17232
17233 fi
17234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
17235 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
17236
17237
17238
17239
17240
17241
17242   :
17243
17244
17245
17246
17247
17248
17249
17250
17251      if test $gl_cv_have_include_next = yes; then
17252        gl_cv_next_sys_select_h='<'sys/select.h'>'
17253      else
17254        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
17255 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
17256 if ${gl_cv_next_sys_select_h+:} false; then :
17257   $as_echo_n "(cached) " >&6
17258 else
17259
17260              if test $ac_cv_header_sys_select_h = yes; then
17261
17262
17263
17264
17265   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17266 /* end confdefs.h.  */
17267 #include <sys/select.h>
17268 _ACEOF
17269                 case "$host_os" in
17270     aix*) gl_absname_cpp="$ac_cpp -C" ;;
17271     *)    gl_absname_cpp="$ac_cpp" ;;
17272   esac
17273
17274   case "$host_os" in
17275     mingw*)
17276                                           gl_dirsep_regex='[/\\]'
17277       ;;
17278     *)
17279       gl_dirsep_regex='\/'
17280       ;;
17281   esac
17282       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
17283   gl_header_literal_regex=`echo 'sys/select.h' \
17284                            | sed -e "$gl_make_literal_regex_sed"`
17285   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
17286       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
17287       s|^/[^/]|//&|
17288       p
17289       q
17290     }'
17291
17292         gl_cv_absolute_sys_select_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17293   sed -n "$gl_absolute_header_sed"`
17294
17295            gl_header=$gl_cv_absolute_sys_select_h
17296            gl_cv_next_sys_select_h='"'$gl_header'"'
17297           else
17298                gl_cv_next_sys_select_h='<'sys/select.h'>'
17299              fi
17300
17301
17302 fi
17303 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
17304 $as_echo "$gl_cv_next_sys_select_h" >&6; }
17305      fi
17306      NEXT_SYS_SELECT_H=$gl_cv_next_sys_select_h
17307
17308      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
17309        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17310        gl_next_as_first_directive='<'sys/select.h'>'
17311      else
17312        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17313        gl_next_as_first_directive=$gl_cv_next_sys_select_h
17314      fi
17315      NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H=$gl_next_as_first_directive
17316
17317
17318
17319
17320   if test $ac_cv_header_sys_select_h = yes; then
17321     HAVE_SYS_SELECT_H=1
17322   else
17323     HAVE_SYS_SELECT_H=0
17324   fi
17325
17326
17327
17328
17329
17330   :
17331
17332
17333
17334
17335
17336   if test $ac_cv_header_sys_socket_h != yes; then
17337                     for ac_header in winsock2.h
17338 do :
17339   ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
17340 if test "x$ac_cv_header_winsock2_h" = xyes; then :
17341   cat >>confdefs.h <<_ACEOF
17342 #define HAVE_WINSOCK2_H 1
17343 _ACEOF
17344
17345 fi
17346
17347 done
17348
17349   fi
17350   if test "$ac_cv_header_winsock2_h" = yes; then
17351     HAVE_WINSOCK2_H=1
17352     UNISTD_H_HAVE_WINSOCK2_H=1
17353     SYS_IOCTL_H_HAVE_WINSOCK2_H=1
17354   else
17355     HAVE_WINSOCK2_H=0
17356   fi
17357
17358
17359
17360
17361
17362
17363       ac_fn_c_check_decl "$LINENO" "setenv" "ac_cv_have_decl_setenv" "$ac_includes_default"
17364 if test "x$ac_cv_have_decl_setenv" = xyes; then :
17365   ac_have_decl=1
17366 else
17367   ac_have_decl=0
17368 fi
17369
17370 cat >>confdefs.h <<_ACEOF
17371 #define HAVE_DECL_SETENV $ac_have_decl
17372 _ACEOF
17373
17374
17375
17376
17377
17378
17379
17380
17381
17382
17383   :
17384
17385
17386
17387
17388
17389   if test $ac_cv_have_decl_setenv = no; then
17390     HAVE_DECL_SETENV=0
17391   fi
17392
17393   :
17394
17395
17396
17397
17398
17399
17400
17401
17402
17403   :
17404
17405
17406
17407
17408
17409   for ac_header in search.h
17410 do :
17411   ac_fn_c_check_header_mongrel "$LINENO" "search.h" "ac_cv_header_search_h" "$ac_includes_default"
17412 if test "x$ac_cv_header_search_h" = xyes; then :
17413   cat >>confdefs.h <<_ACEOF
17414 #define HAVE_SEARCH_H 1
17415 _ACEOF
17416
17417 fi
17418
17419 done
17420
17421   for ac_func in tsearch
17422 do :
17423   ac_fn_c_check_func "$LINENO" "tsearch" "ac_cv_func_tsearch"
17424 if test "x$ac_cv_func_tsearch" = xyes; then :
17425   cat >>confdefs.h <<_ACEOF
17426 #define HAVE_TSEARCH 1
17427 _ACEOF
17428
17429 fi
17430 done
17431
17432
17433
17434
17435
17436
17437
17438
17439 :
17440
17441
17442
17443
17444
17445
17446
17447
17448
17449
17450
17451
17452
17453
17454
17455
17456
17457
17458
17459
17460
17461
17462   :
17463
17464
17465
17466
17467
17468
17469
17470
17471
17472   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether snprintf returns a byte count as in C99" >&5
17473 $as_echo_n "checking whether snprintf returns a byte count as in C99... " >&6; }
17474 if ${gl_cv_func_snprintf_retval_c99+:} false; then :
17475   $as_echo_n "(cached) " >&6
17476 else
17477
17478       if test "$cross_compiling" = yes; then :
17479
17480          case "$host_os" in
17481                                  # Guess yes on glibc systems.
17482            *-gnu*)               gl_cv_func_snprintf_retval_c99="guessing yes";;
17483                                  # Guess yes on FreeBSD >= 5.
17484            freebsd[1-4]*)        gl_cv_func_snprintf_retval_c99="guessing no";;
17485            freebsd* | kfreebsd*) gl_cv_func_snprintf_retval_c99="guessing yes";;
17486                                  # Guess yes on Mac OS X >= 10.3.
17487            darwin[1-6].*)        gl_cv_func_snprintf_retval_c99="guessing no";;
17488            darwin*)              gl_cv_func_snprintf_retval_c99="guessing yes";;
17489                                  # Guess yes on OpenBSD >= 3.9.
17490            openbsd[1-2].* | openbsd3.[0-8] | openbsd3.[0-8].*)
17491                                  gl_cv_func_snprintf_retval_c99="guessing no";;
17492            openbsd*)             gl_cv_func_snprintf_retval_c99="guessing yes";;
17493                                  # Guess yes on Solaris >= 2.10.
17494            solaris2.[1-9][0-9]*) gl_cv_func_printf_sizes_c99="guessing yes";;
17495            solaris*)             gl_cv_func_printf_sizes_c99="guessing no";;
17496                                  # Guess yes on AIX >= 4.
17497            aix[1-3]*)            gl_cv_func_snprintf_retval_c99="guessing no";;
17498            aix*)                 gl_cv_func_snprintf_retval_c99="guessing yes";;
17499                                  # Guess yes on NetBSD >= 3.
17500            netbsd[1-2]* | netbsdelf[1-2]* | netbsdaout[1-2]* | netbsdcoff[1-2]*)
17501                                  gl_cv_func_snprintf_retval_c99="guessing no";;
17502            netbsd*)              gl_cv_func_snprintf_retval_c99="guessing yes";;
17503                                  # Guess yes on BeOS.
17504            beos*)                gl_cv_func_snprintf_retval_c99="guessing yes";;
17505                                  # If we don't know, assume the worst.
17506            *)                    gl_cv_func_snprintf_retval_c99="guessing no";;
17507          esac
17508
17509 else
17510   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17511 /* end confdefs.h.  */
17512
17513 #include <stdio.h>
17514 #include <string.h>
17515 #if HAVE_SNPRINTF
17516 # define my_snprintf snprintf
17517 #else
17518 # include <stdarg.h>
17519 static int my_snprintf (char *buf, int size, const char *format, ...)
17520 {
17521   va_list args;
17522   int ret;
17523   va_start (args, format);
17524   ret = vsnprintf (buf, size, format, args);
17525   va_end (args);
17526   return ret;
17527 }
17528 #endif
17529 static char buf[100];
17530 int main ()
17531 {
17532   strcpy (buf, "ABCDEF");
17533   if (my_snprintf (buf, 3, "%d %d", 4567, 89) != 7)
17534     return 1;
17535   if (my_snprintf (buf, 0, "%d %d", 4567, 89) != 7)
17536     return 2;
17537   if (my_snprintf (NULL, 0, "%d %d", 4567, 89) != 7)
17538     return 3;
17539   return 0;
17540 }
17541 _ACEOF
17542 if ac_fn_c_try_run "$LINENO"; then :
17543   gl_cv_func_snprintf_retval_c99=yes
17544 else
17545   gl_cv_func_snprintf_retval_c99=no
17546 fi
17547 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17548   conftest.$ac_objext conftest.beam conftest.$ac_ext
17549 fi
17550
17551
17552 fi
17553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_snprintf_retval_c99" >&5
17554 $as_echo "$gl_cv_func_snprintf_retval_c99" >&6; }
17555
17556
17557       ac_fn_c_check_decl "$LINENO" "snprintf" "ac_cv_have_decl_snprintf" "$ac_includes_default"
17558 if test "x$ac_cv_have_decl_snprintf" = xyes; then :
17559   ac_have_decl=1
17560 else
17561   ac_have_decl=0
17562 fi
17563
17564 cat >>confdefs.h <<_ACEOF
17565 #define HAVE_DECL_SNPRINTF $ac_have_decl
17566 _ACEOF
17567
17568
17569 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
17570 $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
17571 if ${ac_cv_header_stdbool_h+:} false; then :
17572   $as_echo_n "(cached) " >&6
17573 else
17574   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17575 /* end confdefs.h.  */
17576
17577              #include <stdbool.h>
17578              #ifndef bool
17579               "error: bool is not defined"
17580              #endif
17581              #ifndef false
17582               "error: false is not defined"
17583              #endif
17584              #if false
17585               "error: false is not 0"
17586              #endif
17587              #ifndef true
17588               "error: true is not defined"
17589              #endif
17590              #if true != 1
17591               "error: true is not 1"
17592              #endif
17593              #ifndef __bool_true_false_are_defined
17594               "error: __bool_true_false_are_defined is not defined"
17595              #endif
17596
17597              struct s { _Bool s: 1; _Bool t; } s;
17598
17599              char a[true == 1 ? 1 : -1];
17600              char b[false == 0 ? 1 : -1];
17601              char c[__bool_true_false_are_defined == 1 ? 1 : -1];
17602              char d[(bool) 0.5 == true ? 1 : -1];
17603              /* See body of main program for 'e'.  */
17604              char f[(_Bool) 0.0 == false ? 1 : -1];
17605              char g[true];
17606              char h[sizeof (_Bool)];
17607              char i[sizeof s.t];
17608              enum { j = false, k = true, l = false * true, m = true * 256 };
17609              /* The following fails for
17610                 HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
17611              _Bool n[m];
17612              char o[sizeof n == m * sizeof n[0] ? 1 : -1];
17613              char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
17614              /* Catch a bug in an HP-UX C compiler.  See
17615                 http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
17616                 http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
17617               */
17618              _Bool q = true;
17619              _Bool *pq = &q;
17620
17621 int
17622 main ()
17623 {
17624
17625              bool e = &s;
17626              *pq |= q;
17627              *pq |= ! q;
17628              /* Refer to every declared value, to avoid compiler optimizations.  */
17629              return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
17630                      + !m + !n + !o + !p + !q + !pq);
17631
17632   ;
17633   return 0;
17634 }
17635 _ACEOF
17636 if ac_fn_c_try_compile "$LINENO"; then :
17637   ac_cv_header_stdbool_h=yes
17638 else
17639   ac_cv_header_stdbool_h=no
17640 fi
17641 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17642 fi
17643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
17644 $as_echo "$ac_cv_header_stdbool_h" >&6; }
17645    ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
17646 if test "x$ac_cv_type__Bool" = xyes; then :
17647
17648 cat >>confdefs.h <<_ACEOF
17649 #define HAVE__BOOL 1
17650 _ACEOF
17651
17652
17653 fi
17654
17655
17656
17657
17658
17659
17660
17661
17662
17663
17664
17665
17666
17667
17668
17669   if test $ac_cv_type_long_long_int = yes; then
17670     HAVE_LONG_LONG_INT=1
17671   else
17672     HAVE_LONG_LONG_INT=0
17673   fi
17674
17675
17676   if test $ac_cv_type_unsigned_long_long_int = yes; then
17677     HAVE_UNSIGNED_LONG_LONG_INT=1
17678   else
17679     HAVE_UNSIGNED_LONG_LONG_INT=0
17680   fi
17681
17682
17683
17684   :
17685
17686
17687
17688
17689
17690   if test $ac_cv_header_wchar_h = yes; then
17691     HAVE_WCHAR_H=1
17692   else
17693     HAVE_WCHAR_H=0
17694   fi
17695
17696
17697       if test $ac_cv_header_inttypes_h = yes; then
17698     HAVE_INTTYPES_H=1
17699   else
17700     HAVE_INTTYPES_H=0
17701   fi
17702
17703
17704       if test $ac_cv_header_sys_types_h = yes; then
17705     HAVE_SYS_TYPES_H=1
17706   else
17707     HAVE_SYS_TYPES_H=0
17708   fi
17709
17710
17711
17712
17713
17714
17715
17716
17717   :
17718
17719
17720
17721
17722
17723
17724
17725
17726      if test $gl_cv_have_include_next = yes; then
17727        gl_cv_next_stdint_h='<'stdint.h'>'
17728      else
17729        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdint.h>" >&5
17730 $as_echo_n "checking absolute name of <stdint.h>... " >&6; }
17731 if ${gl_cv_next_stdint_h+:} false; then :
17732   $as_echo_n "(cached) " >&6
17733 else
17734
17735              if test $ac_cv_header_stdint_h = yes; then
17736
17737
17738
17739
17740   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17741 /* end confdefs.h.  */
17742 #include <stdint.h>
17743 _ACEOF
17744                 case "$host_os" in
17745     aix*) gl_absname_cpp="$ac_cpp -C" ;;
17746     *)    gl_absname_cpp="$ac_cpp" ;;
17747   esac
17748
17749   case "$host_os" in
17750     mingw*)
17751                                           gl_dirsep_regex='[/\\]'
17752       ;;
17753     *)
17754       gl_dirsep_regex='\/'
17755       ;;
17756   esac
17757       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
17758   gl_header_literal_regex=`echo 'stdint.h' \
17759                            | sed -e "$gl_make_literal_regex_sed"`
17760   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
17761       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
17762       s|^/[^/]|//&|
17763       p
17764       q
17765     }'
17766
17767         gl_cv_absolute_stdint_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17768   sed -n "$gl_absolute_header_sed"`
17769
17770            gl_header=$gl_cv_absolute_stdint_h
17771            gl_cv_next_stdint_h='"'$gl_header'"'
17772           else
17773                gl_cv_next_stdint_h='<'stdint.h'>'
17774              fi
17775
17776
17777 fi
17778 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdint_h" >&5
17779 $as_echo "$gl_cv_next_stdint_h" >&6; }
17780      fi
17781      NEXT_STDINT_H=$gl_cv_next_stdint_h
17782
17783      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
17784        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17785        gl_next_as_first_directive='<'stdint.h'>'
17786      else
17787        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17788        gl_next_as_first_directive=$gl_cv_next_stdint_h
17789      fi
17790      NEXT_AS_FIRST_DIRECTIVE_STDINT_H=$gl_next_as_first_directive
17791
17792
17793
17794
17795   if test $ac_cv_header_stdint_h = yes; then
17796     HAVE_STDINT_H=1
17797   else
17798     HAVE_STDINT_H=0
17799   fi
17800
17801
17802     if test $ac_cv_header_stdint_h = yes; then
17803     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h conforms to C99" >&5
17804 $as_echo_n "checking whether stdint.h conforms to C99... " >&6; }
17805 if ${gl_cv_header_working_stdint_h+:} false; then :
17806   $as_echo_n "(cached) " >&6
17807 else
17808   gl_cv_header_working_stdint_h=no
17809        cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17810 /* end confdefs.h.  */
17811
17812
17813 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
17814 #include <stdint.h>
17815 /* Dragonfly defines WCHAR_MIN, WCHAR_MAX only in <wchar.h>.  */
17816 #if !(defined WCHAR_MIN && defined WCHAR_MAX)
17817 #error "WCHAR_MIN, WCHAR_MAX not defined in <stdint.h>"
17818 #endif
17819
17820
17821   /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
17822      included before <wchar.h>.  */
17823   #include <stddef.h>
17824   #include <signal.h>
17825   #if HAVE_WCHAR_H
17826   # include <stdio.h>
17827   # include <time.h>
17828   # include <wchar.h>
17829   #endif
17830
17831
17832 #ifdef INT8_MAX
17833 int8_t a1 = INT8_MAX;
17834 int8_t a1min = INT8_MIN;
17835 #endif
17836 #ifdef INT16_MAX
17837 int16_t a2 = INT16_MAX;
17838 int16_t a2min = INT16_MIN;
17839 #endif
17840 #ifdef INT32_MAX
17841 int32_t a3 = INT32_MAX;
17842 int32_t a3min = INT32_MIN;
17843 #endif
17844 #ifdef INT64_MAX
17845 int64_t a4 = INT64_MAX;
17846 int64_t a4min = INT64_MIN;
17847 #endif
17848 #ifdef UINT8_MAX
17849 uint8_t b1 = UINT8_MAX;
17850 #else
17851 typedef int b1[(unsigned char) -1 != 255 ? 1 : -1];
17852 #endif
17853 #ifdef UINT16_MAX
17854 uint16_t b2 = UINT16_MAX;
17855 #endif
17856 #ifdef UINT32_MAX
17857 uint32_t b3 = UINT32_MAX;
17858 #endif
17859 #ifdef UINT64_MAX
17860 uint64_t b4 = UINT64_MAX;
17861 #endif
17862 int_least8_t c1 = INT8_C (0x7f);
17863 int_least8_t c1max = INT_LEAST8_MAX;
17864 int_least8_t c1min = INT_LEAST8_MIN;
17865 int_least16_t c2 = INT16_C (0x7fff);
17866 int_least16_t c2max = INT_LEAST16_MAX;
17867 int_least16_t c2min = INT_LEAST16_MIN;
17868 int_least32_t c3 = INT32_C (0x7fffffff);
17869 int_least32_t c3max = INT_LEAST32_MAX;
17870 int_least32_t c3min = INT_LEAST32_MIN;
17871 int_least64_t c4 = INT64_C (0x7fffffffffffffff);
17872 int_least64_t c4max = INT_LEAST64_MAX;
17873 int_least64_t c4min = INT_LEAST64_MIN;
17874 uint_least8_t d1 = UINT8_C (0xff);
17875 uint_least8_t d1max = UINT_LEAST8_MAX;
17876 uint_least16_t d2 = UINT16_C (0xffff);
17877 uint_least16_t d2max = UINT_LEAST16_MAX;
17878 uint_least32_t d3 = UINT32_C (0xffffffff);
17879 uint_least32_t d3max = UINT_LEAST32_MAX;
17880 uint_least64_t d4 = UINT64_C (0xffffffffffffffff);
17881 uint_least64_t d4max = UINT_LEAST64_MAX;
17882 int_fast8_t e1 = INT_FAST8_MAX;
17883 int_fast8_t e1min = INT_FAST8_MIN;
17884 int_fast16_t e2 = INT_FAST16_MAX;
17885 int_fast16_t e2min = INT_FAST16_MIN;
17886 int_fast32_t e3 = INT_FAST32_MAX;
17887 int_fast32_t e3min = INT_FAST32_MIN;
17888 int_fast64_t e4 = INT_FAST64_MAX;
17889 int_fast64_t e4min = INT_FAST64_MIN;
17890 uint_fast8_t f1 = UINT_FAST8_MAX;
17891 uint_fast16_t f2 = UINT_FAST16_MAX;
17892 uint_fast32_t f3 = UINT_FAST32_MAX;
17893 uint_fast64_t f4 = UINT_FAST64_MAX;
17894 #ifdef INTPTR_MAX
17895 intptr_t g = INTPTR_MAX;
17896 intptr_t gmin = INTPTR_MIN;
17897 #endif
17898 #ifdef UINTPTR_MAX
17899 uintptr_t h = UINTPTR_MAX;
17900 #endif
17901 intmax_t i = INTMAX_MAX;
17902 uintmax_t j = UINTMAX_MAX;
17903
17904 #include <limits.h> /* for CHAR_BIT */
17905 #define TYPE_MINIMUM(t) \
17906   ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ TYPE_MAXIMUM (t)))
17907 #define TYPE_MAXIMUM(t) \
17908   ((t) ((t) 0 < (t) -1 \
17909         ? (t) -1 \
17910         : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1)))
17911 struct s {
17912   int check_PTRDIFF:
17913       PTRDIFF_MIN == TYPE_MINIMUM (ptrdiff_t)
17914       && PTRDIFF_MAX == TYPE_MAXIMUM (ptrdiff_t)
17915       ? 1 : -1;
17916   /* Detect bug in FreeBSD 6.0 / ia64.  */
17917   int check_SIG_ATOMIC:
17918       SIG_ATOMIC_MIN == TYPE_MINIMUM (sig_atomic_t)
17919       && SIG_ATOMIC_MAX == TYPE_MAXIMUM (sig_atomic_t)
17920       ? 1 : -1;
17921   int check_SIZE: SIZE_MAX == TYPE_MAXIMUM (size_t) ? 1 : -1;
17922   int check_WCHAR:
17923       WCHAR_MIN == TYPE_MINIMUM (wchar_t)
17924       && WCHAR_MAX == TYPE_MAXIMUM (wchar_t)
17925       ? 1 : -1;
17926   /* Detect bug in mingw.  */
17927   int check_WINT:
17928       WINT_MIN == TYPE_MINIMUM (wint_t)
17929       && WINT_MAX == TYPE_MAXIMUM (wint_t)
17930       ? 1 : -1;
17931
17932   /* Detect bugs in glibc 2.4 and Solaris 10 stdint.h, among others.  */
17933   int check_UINT8_C:
17934         (-1 < UINT8_C (0)) == (-1 < (uint_least8_t) 0) ? 1 : -1;
17935   int check_UINT16_C:
17936         (-1 < UINT16_C (0)) == (-1 < (uint_least16_t) 0) ? 1 : -1;
17937
17938   /* Detect bugs in OpenBSD 3.9 stdint.h.  */
17939 #ifdef UINT8_MAX
17940   int check_uint8: (uint8_t) -1 == UINT8_MAX ? 1 : -1;
17941 #endif
17942 #ifdef UINT16_MAX
17943   int check_uint16: (uint16_t) -1 == UINT16_MAX ? 1 : -1;
17944 #endif
17945 #ifdef UINT32_MAX
17946   int check_uint32: (uint32_t) -1 == UINT32_MAX ? 1 : -1;
17947 #endif
17948 #ifdef UINT64_MAX
17949   int check_uint64: (uint64_t) -1 == UINT64_MAX ? 1 : -1;
17950 #endif
17951   int check_uint_least8: (uint_least8_t) -1 == UINT_LEAST8_MAX ? 1 : -1;
17952   int check_uint_least16: (uint_least16_t) -1 == UINT_LEAST16_MAX ? 1 : -1;
17953   int check_uint_least32: (uint_least32_t) -1 == UINT_LEAST32_MAX ? 1 : -1;
17954   int check_uint_least64: (uint_least64_t) -1 == UINT_LEAST64_MAX ? 1 : -1;
17955   int check_uint_fast8: (uint_fast8_t) -1 == UINT_FAST8_MAX ? 1 : -1;
17956   int check_uint_fast16: (uint_fast16_t) -1 == UINT_FAST16_MAX ? 1 : -1;
17957   int check_uint_fast32: (uint_fast32_t) -1 == UINT_FAST32_MAX ? 1 : -1;
17958   int check_uint_fast64: (uint_fast64_t) -1 == UINT_FAST64_MAX ? 1 : -1;
17959   int check_uintptr: (uintptr_t) -1 == UINTPTR_MAX ? 1 : -1;
17960   int check_uintmax: (uintmax_t) -1 == UINTMAX_MAX ? 1 : -1;
17961   int check_size: (size_t) -1 == SIZE_MAX ? 1 : -1;
17962 };
17963
17964 int
17965 main ()
17966 {
17967
17968   ;
17969   return 0;
17970 }
17971 _ACEOF
17972 if ac_fn_c_try_compile "$LINENO"; then :
17973                                                     if test "$cross_compiling" = yes; then :
17974                  gl_cv_header_working_stdint_h=yes
17975
17976 else
17977   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17978 /* end confdefs.h.  */
17979
17980
17981 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
17982 #include <stdint.h>
17983
17984
17985   /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
17986      included before <wchar.h>.  */
17987   #include <stddef.h>
17988   #include <signal.h>
17989   #if HAVE_WCHAR_H
17990   # include <stdio.h>
17991   # include <time.h>
17992   # include <wchar.h>
17993   #endif
17994
17995
17996 #include <stdio.h>
17997 #include <string.h>
17998 #define MVAL(macro) MVAL1(macro)
17999 #define MVAL1(expression) #expression
18000 static const char *macro_values[] =
18001   {
18002 #ifdef INT8_MAX
18003     MVAL (INT8_MAX),
18004 #endif
18005 #ifdef INT16_MAX
18006     MVAL (INT16_MAX),
18007 #endif
18008 #ifdef INT32_MAX
18009     MVAL (INT32_MAX),
18010 #endif
18011 #ifdef INT64_MAX
18012     MVAL (INT64_MAX),
18013 #endif
18014 #ifdef UINT8_MAX
18015     MVAL (UINT8_MAX),
18016 #endif
18017 #ifdef UINT16_MAX
18018     MVAL (UINT16_MAX),
18019 #endif
18020 #ifdef UINT32_MAX
18021     MVAL (UINT32_MAX),
18022 #endif
18023 #ifdef UINT64_MAX
18024     MVAL (UINT64_MAX),
18025 #endif
18026     NULL
18027   };
18028
18029 int
18030 main ()
18031 {
18032
18033   const char **mv;
18034   for (mv = macro_values; *mv != NULL; mv++)
18035     {
18036       const char *value = *mv;
18037       /* Test whether it looks like a cast expression.  */
18038       if (strncmp (value, "((unsigned int)"/*)*/, 15) == 0
18039           || strncmp (value, "((unsigned short)"/*)*/, 17) == 0
18040           || strncmp (value, "((unsigned char)"/*)*/, 16) == 0
18041           || strncmp (value, "((int)"/*)*/, 6) == 0
18042           || strncmp (value, "((signed short)"/*)*/, 15) == 0
18043           || strncmp (value, "((signed char)"/*)*/, 14) == 0)
18044         return mv - macro_values + 1;
18045     }
18046   return 0;
18047
18048   ;
18049   return 0;
18050 }
18051 _ACEOF
18052 if ac_fn_c_try_run "$LINENO"; then :
18053   gl_cv_header_working_stdint_h=yes
18054 fi
18055 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18056   conftest.$ac_objext conftest.beam conftest.$ac_ext
18057 fi
18058
18059
18060 fi
18061 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18062
18063 fi
18064 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdint_h" >&5
18065 $as_echo "$gl_cv_header_working_stdint_h" >&6; }
18066   fi
18067   if test "$gl_cv_header_working_stdint_h" = yes; then
18068     STDINT_H=
18069   else
18070             for ac_header in sys/inttypes.h sys/bitypes.h
18071 do :
18072   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
18073 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
18074 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
18075   cat >>confdefs.h <<_ACEOF
18076 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
18077 _ACEOF
18078
18079 fi
18080
18081 done
18082
18083     if test $ac_cv_header_sys_inttypes_h = yes; then
18084       HAVE_SYS_INTTYPES_H=1
18085     else
18086       HAVE_SYS_INTTYPES_H=0
18087     fi
18088
18089     if test $ac_cv_header_sys_bitypes_h = yes; then
18090       HAVE_SYS_BITYPES_H=1
18091     else
18092       HAVE_SYS_BITYPES_H=0
18093     fi
18094
18095
18096
18097
18098   if test $APPLE_UNIVERSAL_BUILD = 0; then
18099
18100
18101   for gltype in ptrdiff_t size_t ; do
18102     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
18103 $as_echo_n "checking for bit size of $gltype... " >&6; }
18104 if eval \${gl_cv_bitsizeof_${gltype}+:} false; then :
18105   $as_echo_n "(cached) " >&6
18106 else
18107   if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result"        "
18108   /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18109      included before <wchar.h>.  */
18110   #include <stddef.h>
18111   #include <signal.h>
18112   #if HAVE_WCHAR_H
18113   # include <stdio.h>
18114   # include <time.h>
18115   # include <wchar.h>
18116   #endif
18117
18118 #include <limits.h>"; then :
18119
18120 else
18121   result=unknown
18122 fi
18123
18124        eval gl_cv_bitsizeof_${gltype}=\$result
18125
18126 fi
18127 eval ac_res=\$gl_cv_bitsizeof_${gltype}
18128                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18129 $as_echo "$ac_res" >&6; }
18130     eval result=\$gl_cv_bitsizeof_${gltype}
18131     if test $result = unknown; then
18132                                                 result=0
18133     fi
18134     GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18135     cat >>confdefs.h <<_ACEOF
18136 #define BITSIZEOF_${GLTYPE} $result
18137 _ACEOF
18138
18139     eval BITSIZEOF_${GLTYPE}=\$result
18140   done
18141
18142
18143   fi
18144
18145
18146   for gltype in sig_atomic_t wchar_t wint_t ; do
18147     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
18148 $as_echo_n "checking for bit size of $gltype... " >&6; }
18149 if eval \${gl_cv_bitsizeof_${gltype}+:} false; then :
18150   $as_echo_n "(cached) " >&6
18151 else
18152   if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result"        "
18153   /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18154      included before <wchar.h>.  */
18155   #include <stddef.h>
18156   #include <signal.h>
18157   #if HAVE_WCHAR_H
18158   # include <stdio.h>
18159   # include <time.h>
18160   # include <wchar.h>
18161   #endif
18162
18163 #include <limits.h>"; then :
18164
18165 else
18166   result=unknown
18167 fi
18168
18169        eval gl_cv_bitsizeof_${gltype}=\$result
18170
18171 fi
18172 eval ac_res=\$gl_cv_bitsizeof_${gltype}
18173                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18174 $as_echo "$ac_res" >&6; }
18175     eval result=\$gl_cv_bitsizeof_${gltype}
18176     if test $result = unknown; then
18177                                                 result=0
18178     fi
18179     GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18180     cat >>confdefs.h <<_ACEOF
18181 #define BITSIZEOF_${GLTYPE} $result
18182 _ACEOF
18183
18184     eval BITSIZEOF_${GLTYPE}=\$result
18185   done
18186
18187
18188
18189
18190   for gltype in sig_atomic_t wchar_t wint_t ; do
18191     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gltype is signed" >&5
18192 $as_echo_n "checking whether $gltype is signed... " >&6; }
18193 if eval \${gl_cv_type_${gltype}_signed+:} false; then :
18194   $as_echo_n "(cached) " >&6
18195 else
18196   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18197 /* end confdefs.h.  */
18198
18199   /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18200      included before <wchar.h>.  */
18201   #include <stddef.h>
18202   #include <signal.h>
18203   #if HAVE_WCHAR_H
18204   # include <stdio.h>
18205   # include <time.h>
18206   # include <wchar.h>
18207   #endif
18208
18209             int verify[2 * (($gltype) -1 < ($gltype) 0) - 1];
18210 int
18211 main ()
18212 {
18213
18214   ;
18215   return 0;
18216 }
18217 _ACEOF
18218 if ac_fn_c_try_compile "$LINENO"; then :
18219   result=yes
18220 else
18221   result=no
18222 fi
18223 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18224        eval gl_cv_type_${gltype}_signed=\$result
18225
18226 fi
18227 eval ac_res=\$gl_cv_type_${gltype}_signed
18228                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18229 $as_echo "$ac_res" >&6; }
18230     eval result=\$gl_cv_type_${gltype}_signed
18231     GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18232     if test "$result" = yes; then
18233       cat >>confdefs.h <<_ACEOF
18234 #define HAVE_SIGNED_${GLTYPE} 1
18235 _ACEOF
18236
18237       eval HAVE_SIGNED_${GLTYPE}=1
18238     else
18239       eval HAVE_SIGNED_${GLTYPE}=0
18240     fi
18241   done
18242
18243
18244   gl_cv_type_ptrdiff_t_signed=yes
18245   gl_cv_type_size_t_signed=no
18246   if test $APPLE_UNIVERSAL_BUILD = 0; then
18247
18248
18249   for gltype in ptrdiff_t size_t ; do
18250     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
18251 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
18252 if eval \${gl_cv_type_${gltype}_suffix+:} false; then :
18253   $as_echo_n "(cached) " >&6
18254 else
18255   eval gl_cv_type_${gltype}_suffix=no
18256        eval result=\$gl_cv_type_${gltype}_signed
18257        if test "$result" = yes; then
18258          glsufu=
18259        else
18260          glsufu=u
18261        fi
18262        for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
18263          case $glsuf in
18264            '')  gltype1='int';;
18265            l)   gltype1='long int';;
18266            ll)  gltype1='long long int';;
18267            i64) gltype1='__int64';;
18268            u)   gltype1='unsigned int';;
18269            ul)  gltype1='unsigned long int';;
18270            ull) gltype1='unsigned long long int';;
18271            ui64)gltype1='unsigned __int64';;
18272          esac
18273          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18274 /* end confdefs.h.  */
18275
18276   /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18277      included before <wchar.h>.  */
18278   #include <stddef.h>
18279   #include <signal.h>
18280   #if HAVE_WCHAR_H
18281   # include <stdio.h>
18282   # include <time.h>
18283   # include <wchar.h>
18284   #endif
18285
18286               extern $gltype foo;
18287               extern $gltype1 foo;
18288 int
18289 main ()
18290 {
18291
18292   ;
18293   return 0;
18294 }
18295 _ACEOF
18296 if ac_fn_c_try_compile "$LINENO"; then :
18297   eval gl_cv_type_${gltype}_suffix=\$glsuf
18298 fi
18299 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18300          eval result=\$gl_cv_type_${gltype}_suffix
18301          test "$result" != no && break
18302        done
18303 fi
18304 eval ac_res=\$gl_cv_type_${gltype}_suffix
18305                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18306 $as_echo "$ac_res" >&6; }
18307     GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18308     eval result=\$gl_cv_type_${gltype}_suffix
18309     test "$result" = no && result=
18310     eval ${GLTYPE}_SUFFIX=\$result
18311     cat >>confdefs.h <<_ACEOF
18312 #define ${GLTYPE}_SUFFIX $result
18313 _ACEOF
18314
18315   done
18316
18317
18318   fi
18319
18320
18321   for gltype in sig_atomic_t wchar_t wint_t ; do
18322     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
18323 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
18324 if eval \${gl_cv_type_${gltype}_suffix+:} false; then :
18325   $as_echo_n "(cached) " >&6
18326 else
18327   eval gl_cv_type_${gltype}_suffix=no
18328        eval result=\$gl_cv_type_${gltype}_signed
18329        if test "$result" = yes; then
18330          glsufu=
18331        else
18332          glsufu=u
18333        fi
18334        for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
18335          case $glsuf in
18336            '')  gltype1='int';;
18337            l)   gltype1='long int';;
18338            ll)  gltype1='long long int';;
18339            i64) gltype1='__int64';;
18340            u)   gltype1='unsigned int';;
18341            ul)  gltype1='unsigned long int';;
18342            ull) gltype1='unsigned long long int';;
18343            ui64)gltype1='unsigned __int64';;
18344          esac
18345          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18346 /* end confdefs.h.  */
18347
18348   /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18349      included before <wchar.h>.  */
18350   #include <stddef.h>
18351   #include <signal.h>
18352   #if HAVE_WCHAR_H
18353   # include <stdio.h>
18354   # include <time.h>
18355   # include <wchar.h>
18356   #endif
18357
18358               extern $gltype foo;
18359               extern $gltype1 foo;
18360 int
18361 main ()
18362 {
18363
18364   ;
18365   return 0;
18366 }
18367 _ACEOF
18368 if ac_fn_c_try_compile "$LINENO"; then :
18369   eval gl_cv_type_${gltype}_suffix=\$glsuf
18370 fi
18371 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18372          eval result=\$gl_cv_type_${gltype}_suffix
18373          test "$result" != no && break
18374        done
18375 fi
18376 eval ac_res=\$gl_cv_type_${gltype}_suffix
18377                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18378 $as_echo "$ac_res" >&6; }
18379     GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18380     eval result=\$gl_cv_type_${gltype}_suffix
18381     test "$result" = no && result=
18382     eval ${GLTYPE}_SUFFIX=\$result
18383     cat >>confdefs.h <<_ACEOF
18384 #define ${GLTYPE}_SUFFIX $result
18385 _ACEOF
18386
18387   done
18388
18389
18390
18391           if test $BITSIZEOF_WINT_T -lt 32; then
18392     BITSIZEOF_WINT_T=32
18393   fi
18394
18395     STDINT_H=stdint.h
18396   fi
18397
18398    if test -n "$STDINT_H"; then
18399   GL_GENERATE_STDINT_H_TRUE=
18400   GL_GENERATE_STDINT_H_FALSE='#'
18401 else
18402   GL_GENERATE_STDINT_H_TRUE='#'
18403   GL_GENERATE_STDINT_H_FALSE=
18404 fi
18405
18406
18407
18408
18409
18410
18411
18412
18413       ac_fn_c_check_decl "$LINENO" "strdup" "ac_cv_have_decl_strdup" "$ac_includes_default"
18414 if test "x$ac_cv_have_decl_strdup" = xyes; then :
18415   ac_have_decl=1
18416 else
18417   ac_have_decl=0
18418 fi
18419
18420 cat >>confdefs.h <<_ACEOF
18421 #define HAVE_DECL_STRDUP $ac_have_decl
18422 _ACEOF
18423
18424
18425
18426
18427
18428
18429
18430
18431
18432
18433
18434
18435
18436
18437
18438
18439
18440
18441      if test $gl_cv_have_include_next = yes; then
18442        gl_cv_next_string_h='<'string.h'>'
18443      else
18444        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <string.h>" >&5
18445 $as_echo_n "checking absolute name of <string.h>... " >&6; }
18446 if ${gl_cv_next_string_h+:} false; then :
18447   $as_echo_n "(cached) " >&6
18448 else
18449
18450
18451
18452   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18453 /* end confdefs.h.  */
18454 #include <string.h>
18455 _ACEOF
18456                 case "$host_os" in
18457     aix*) gl_absname_cpp="$ac_cpp -C" ;;
18458     *)    gl_absname_cpp="$ac_cpp" ;;
18459   esac
18460
18461   case "$host_os" in
18462     mingw*)
18463                                           gl_dirsep_regex='[/\\]'
18464       ;;
18465     *)
18466       gl_dirsep_regex='\/'
18467       ;;
18468   esac
18469       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18470   gl_header_literal_regex=`echo 'string.h' \
18471                            | sed -e "$gl_make_literal_regex_sed"`
18472   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18473       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18474       s|^/[^/]|//&|
18475       p
18476       q
18477     }'
18478
18479         gl_cv_absolute_string_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18480   sed -n "$gl_absolute_header_sed"`
18481
18482            gl_header=$gl_cv_absolute_string_h
18483            gl_cv_next_string_h='"'$gl_header'"'
18484
18485
18486 fi
18487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_string_h" >&5
18488 $as_echo "$gl_cv_next_string_h" >&6; }
18489      fi
18490      NEXT_STRING_H=$gl_cv_next_string_h
18491
18492      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18493        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18494        gl_next_as_first_directive='<'string.h'>'
18495      else
18496        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18497        gl_next_as_first_directive=$gl_cv_next_string_h
18498      fi
18499      NEXT_AS_FIRST_DIRECTIVE_STRING_H=$gl_next_as_first_directive
18500
18501
18502
18503
18504
18505
18506
18507
18508
18509
18510
18511
18512
18513
18514
18515
18516
18517
18518
18519
18520
18521   :
18522
18523
18524
18525
18526
18527
18528
18529
18530      if test $gl_cv_have_include_next = yes; then
18531        gl_cv_next_strings_h='<'strings.h'>'
18532      else
18533        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <strings.h>" >&5
18534 $as_echo_n "checking absolute name of <strings.h>... " >&6; }
18535 if ${gl_cv_next_strings_h+:} false; then :
18536   $as_echo_n "(cached) " >&6
18537 else
18538
18539              if test $ac_cv_header_strings_h = yes; then
18540
18541
18542
18543
18544   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18545 /* end confdefs.h.  */
18546 #include <strings.h>
18547 _ACEOF
18548                 case "$host_os" in
18549     aix*) gl_absname_cpp="$ac_cpp -C" ;;
18550     *)    gl_absname_cpp="$ac_cpp" ;;
18551   esac
18552
18553   case "$host_os" in
18554     mingw*)
18555                                           gl_dirsep_regex='[/\\]'
18556       ;;
18557     *)
18558       gl_dirsep_regex='\/'
18559       ;;
18560   esac
18561       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18562   gl_header_literal_regex=`echo 'strings.h' \
18563                            | sed -e "$gl_make_literal_regex_sed"`
18564   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18565       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18566       s|^/[^/]|//&|
18567       p
18568       q
18569     }'
18570
18571         gl_cv_absolute_strings_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18572   sed -n "$gl_absolute_header_sed"`
18573
18574            gl_header=$gl_cv_absolute_strings_h
18575            gl_cv_next_strings_h='"'$gl_header'"'
18576           else
18577                gl_cv_next_strings_h='<'strings.h'>'
18578              fi
18579
18580
18581 fi
18582 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_strings_h" >&5
18583 $as_echo "$gl_cv_next_strings_h" >&6; }
18584      fi
18585      NEXT_STRINGS_H=$gl_cv_next_strings_h
18586
18587      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18588        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18589        gl_next_as_first_directive='<'strings.h'>'
18590      else
18591        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18592        gl_next_as_first_directive=$gl_cv_next_strings_h
18593      fi
18594      NEXT_AS_FIRST_DIRECTIVE_STRINGS_H=$gl_next_as_first_directive
18595
18596
18597
18598
18599   if test $ac_cv_header_strings_h = yes; then
18600     HAVE_STRINGS_H=1
18601   else
18602     HAVE_STRINGS_H=0
18603   fi
18604
18605
18606
18607
18608
18609       ac_fn_c_check_decl "$LINENO" "strndup" "ac_cv_have_decl_strndup" "$ac_includes_default"
18610 if test "x$ac_cv_have_decl_strndup" = xyes; then :
18611   ac_have_decl=1
18612 else
18613   ac_have_decl=0
18614 fi
18615
18616 cat >>confdefs.h <<_ACEOF
18617 #define HAVE_DECL_STRNDUP $ac_have_decl
18618 _ACEOF
18619
18620
18621
18622
18623
18624
18625
18626
18627       ac_fn_c_check_decl "$LINENO" "strnlen" "ac_cv_have_decl_strnlen" "$ac_includes_default"
18628 if test "x$ac_cv_have_decl_strnlen" = xyes; then :
18629   ac_have_decl=1
18630 else
18631   ac_have_decl=0
18632 fi
18633
18634 cat >>confdefs.h <<_ACEOF
18635 #define HAVE_DECL_STRNLEN $ac_have_decl
18636 _ACEOF
18637
18638
18639
18640
18641
18642
18643
18644
18645  ac_fn_c_check_member "$LINENO" "struct tm" "tm_gmtoff" "ac_cv_member_struct_tm_tm_gmtoff" "#include <time.h>
18646 "
18647 if test "x$ac_cv_member_struct_tm_tm_gmtoff" = xyes; then :
18648
18649 $as_echo "#define HAVE_TM_GMTOFF 1" >>confdefs.h
18650
18651 fi
18652
18653
18654
18655       ac_fn_c_check_decl "$LINENO" "strtok_r" "ac_cv_have_decl_strtok_r" "$ac_includes_default"
18656 if test "x$ac_cv_have_decl_strtok_r" = xyes; then :
18657   ac_have_decl=1
18658 else
18659   ac_have_decl=0
18660 fi
18661
18662 cat >>confdefs.h <<_ACEOF
18663 #define HAVE_DECL_STRTOK_R $ac_have_decl
18664 _ACEOF
18665
18666
18667
18668
18669
18670
18671
18672
18673
18674
18675   GNULIB_UNAME=0;
18676     HAVE_UNAME=1;
18677   HAVE_STRUCT_UTSNAME=1;
18678
18679
18680
18681
18682
18683
18684
18685   GNULIB_WAITPID=0;
18686
18687
18688
18689
18690
18691
18692
18693   GNULIB_TCGETSID=0;
18694     HAVE_DECL_TCGETSID=1;
18695   HAVE_TERMIOS_H=1;
18696
18697
18698
18699   :
18700
18701
18702
18703
18704
18705   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5
18706 $as_echo_n "checking for struct timespec in <time.h>... " >&6; }
18707 if ${gl_cv_sys_struct_timespec_in_time_h+:} false; then :
18708   $as_echo_n "(cached) " >&6
18709 else
18710   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18711 /* end confdefs.h.  */
18712 #include <time.h>
18713
18714 int
18715 main ()
18716 {
18717 static struct timespec x; x.tv_sec = x.tv_nsec;
18718   ;
18719   return 0;
18720 }
18721 _ACEOF
18722 if ac_fn_c_try_compile "$LINENO"; then :
18723   gl_cv_sys_struct_timespec_in_time_h=yes
18724 else
18725   gl_cv_sys_struct_timespec_in_time_h=no
18726 fi
18727 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18728 fi
18729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_time_h" >&5
18730 $as_echo "$gl_cv_sys_struct_timespec_in_time_h" >&6; }
18731
18732   TIME_H_DEFINES_STRUCT_TIMESPEC=0
18733   SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0
18734   PTHREAD_H_DEFINES_STRUCT_TIMESPEC=0
18735   if test $gl_cv_sys_struct_timespec_in_time_h = yes; then
18736     TIME_H_DEFINES_STRUCT_TIMESPEC=1
18737   else
18738     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5
18739 $as_echo_n "checking for struct timespec in <sys/time.h>... " >&6; }
18740 if ${gl_cv_sys_struct_timespec_in_sys_time_h+:} false; then :
18741   $as_echo_n "(cached) " >&6
18742 else
18743   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18744 /* end confdefs.h.  */
18745 #include <sys/time.h>
18746
18747 int
18748 main ()
18749 {
18750 static struct timespec x; x.tv_sec = x.tv_nsec;
18751   ;
18752   return 0;
18753 }
18754 _ACEOF
18755 if ac_fn_c_try_compile "$LINENO"; then :
18756   gl_cv_sys_struct_timespec_in_sys_time_h=yes
18757 else
18758   gl_cv_sys_struct_timespec_in_sys_time_h=no
18759 fi
18760 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18761 fi
18762 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_sys_time_h" >&5
18763 $as_echo "$gl_cv_sys_struct_timespec_in_sys_time_h" >&6; }
18764     if test $gl_cv_sys_struct_timespec_in_sys_time_h = yes; then
18765       SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1
18766     else
18767       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <pthread.h>" >&5
18768 $as_echo_n "checking for struct timespec in <pthread.h>... " >&6; }
18769 if ${gl_cv_sys_struct_timespec_in_pthread_h+:} false; then :
18770   $as_echo_n "(cached) " >&6
18771 else
18772   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18773 /* end confdefs.h.  */
18774 #include <pthread.h>
18775
18776 int
18777 main ()
18778 {
18779 static struct timespec x; x.tv_sec = x.tv_nsec;
18780   ;
18781   return 0;
18782 }
18783 _ACEOF
18784 if ac_fn_c_try_compile "$LINENO"; then :
18785   gl_cv_sys_struct_timespec_in_pthread_h=yes
18786 else
18787   gl_cv_sys_struct_timespec_in_pthread_h=no
18788 fi
18789 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18790 fi
18791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_pthread_h" >&5
18792 $as_echo "$gl_cv_sys_struct_timespec_in_pthread_h" >&6; }
18793       if test $gl_cv_sys_struct_timespec_in_pthread_h = yes; then
18794         PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1
18795       fi
18796     fi
18797   fi
18798
18799
18800
18801
18802
18803
18804
18805
18806
18807
18808
18809
18810
18811
18812
18813      if test $gl_cv_have_include_next = yes; then
18814        gl_cv_next_time_h='<'time.h'>'
18815      else
18816        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <time.h>" >&5
18817 $as_echo_n "checking absolute name of <time.h>... " >&6; }
18818 if ${gl_cv_next_time_h+:} false; then :
18819   $as_echo_n "(cached) " >&6
18820 else
18821
18822
18823
18824   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18825 /* end confdefs.h.  */
18826 #include <time.h>
18827 _ACEOF
18828                 case "$host_os" in
18829     aix*) gl_absname_cpp="$ac_cpp -C" ;;
18830     *)    gl_absname_cpp="$ac_cpp" ;;
18831   esac
18832
18833   case "$host_os" in
18834     mingw*)
18835                                           gl_dirsep_regex='[/\\]'
18836       ;;
18837     *)
18838       gl_dirsep_regex='\/'
18839       ;;
18840   esac
18841       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18842   gl_header_literal_regex=`echo 'time.h' \
18843                            | sed -e "$gl_make_literal_regex_sed"`
18844   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18845       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18846       s|^/[^/]|//&|
18847       p
18848       q
18849     }'
18850
18851         gl_cv_absolute_time_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18852   sed -n "$gl_absolute_header_sed"`
18853
18854            gl_header=$gl_cv_absolute_time_h
18855            gl_cv_next_time_h='"'$gl_header'"'
18856
18857
18858 fi
18859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_time_h" >&5
18860 $as_echo "$gl_cv_next_time_h" >&6; }
18861      fi
18862      NEXT_TIME_H=$gl_cv_next_time_h
18863
18864      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18865        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18866        gl_next_as_first_directive='<'time.h'>'
18867      else
18868        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18869        gl_next_as_first_directive=$gl_cv_next_time_h
18870      fi
18871      NEXT_AS_FIRST_DIRECTIVE_TIME_H=$gl_next_as_first_directive
18872
18873
18874
18875
18876
18877
18878
18879
18880
18881
18882
18883
18884
18885
18886
18887
18888
18889       ac_fn_c_check_decl "$LINENO" "ttyname_r" "ac_cv_have_decl_ttyname_r" "$ac_includes_default"
18890 if test "x$ac_cv_have_decl_ttyname_r" = xyes; then :
18891   ac_have_decl=1
18892 else
18893   ac_have_decl=0
18894 fi
18895
18896 cat >>confdefs.h <<_ACEOF
18897 #define HAVE_DECL_TTYNAME_R $ac_have_decl
18898 _ACEOF
18899
18900
18901
18902
18903
18904
18905
18906
18907
18908
18909
18910
18911
18912   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wint_t" >&5
18913 $as_echo_n "checking for wint_t... " >&6; }
18914 if ${gt_cv_c_wint_t+:} false; then :
18915   $as_echo_n "(cached) " >&6
18916 else
18917   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18918 /* end confdefs.h.  */
18919
18920 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
18921    <wchar.h>.
18922    BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be included
18923    before <wchar.h>.  */
18924 #include <stddef.h>
18925 #include <stdio.h>
18926 #include <time.h>
18927 #include <wchar.h>
18928             wint_t foo = (wchar_t)'\0';
18929 int
18930 main ()
18931 {
18932
18933   ;
18934   return 0;
18935 }
18936 _ACEOF
18937 if ac_fn_c_try_compile "$LINENO"; then :
18938   gt_cv_c_wint_t=yes
18939 else
18940   gt_cv_c_wint_t=no
18941 fi
18942 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18943 fi
18944 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wint_t" >&5
18945 $as_echo "$gt_cv_c_wint_t" >&6; }
18946   if test $gt_cv_c_wint_t = yes; then
18947
18948 $as_echo "#define HAVE_WINT_T 1" >>confdefs.h
18949
18950   fi
18951
18952
18953   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inttypes.h" >&5
18954 $as_echo_n "checking for inttypes.h... " >&6; }
18955 if ${gl_cv_header_inttypes_h+:} false; then :
18956   $as_echo_n "(cached) " >&6
18957 else
18958   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18959 /* end confdefs.h.  */
18960
18961 #include <sys/types.h>
18962 #include <inttypes.h>
18963
18964 int
18965 main ()
18966 {
18967 uintmax_t i = (uintmax_t) -1; return !i;
18968   ;
18969   return 0;
18970 }
18971 _ACEOF
18972 if ac_fn_c_try_compile "$LINENO"; then :
18973   gl_cv_header_inttypes_h=yes
18974 else
18975   gl_cv_header_inttypes_h=no
18976 fi
18977 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18978 fi
18979 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_inttypes_h" >&5
18980 $as_echo "$gl_cv_header_inttypes_h" >&6; }
18981   if test $gl_cv_header_inttypes_h = yes; then
18982
18983 cat >>confdefs.h <<_ACEOF
18984 #define HAVE_INTTYPES_H_WITH_UINTMAX 1
18985 _ACEOF
18986
18987   fi
18988
18989
18990   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdint.h" >&5
18991 $as_echo_n "checking for stdint.h... " >&6; }
18992 if ${gl_cv_header_stdint_h+:} false; then :
18993   $as_echo_n "(cached) " >&6
18994 else
18995   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18996 /* end confdefs.h.  */
18997 #include <sys/types.h>
18998             #include <stdint.h>
18999 int
19000 main ()
19001 {
19002 uintmax_t i = (uintmax_t) -1; return !i;
19003   ;
19004   return 0;
19005 }
19006 _ACEOF
19007 if ac_fn_c_try_compile "$LINENO"; then :
19008   gl_cv_header_stdint_h=yes
19009 else
19010   gl_cv_header_stdint_h=no
19011 fi
19012 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19013 fi
19014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_stdint_h" >&5
19015 $as_echo "$gl_cv_header_stdint_h" >&6; }
19016   if test $gl_cv_header_stdint_h = yes; then
19017
19018 cat >>confdefs.h <<_ACEOF
19019 #define HAVE_STDINT_H_WITH_UINTMAX 1
19020 _ACEOF
19021
19022   fi
19023
19024
19025
19026
19027   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for intmax_t" >&5
19028 $as_echo_n "checking for intmax_t... " >&6; }
19029 if ${gt_cv_c_intmax_t+:} false; then :
19030   $as_echo_n "(cached) " >&6
19031 else
19032   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19033 /* end confdefs.h.  */
19034
19035 #include <stddef.h>
19036 #include <stdlib.h>
19037 #if HAVE_STDINT_H_WITH_UINTMAX
19038 #include <stdint.h>
19039 #endif
19040 #if HAVE_INTTYPES_H_WITH_UINTMAX
19041 #include <inttypes.h>
19042 #endif
19043
19044 int
19045 main ()
19046 {
19047 intmax_t x = -1; return !x;
19048   ;
19049   return 0;
19050 }
19051 _ACEOF
19052 if ac_fn_c_try_compile "$LINENO"; then :
19053   gt_cv_c_intmax_t=yes
19054 else
19055   gt_cv_c_intmax_t=no
19056 fi
19057 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19058 fi
19059 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_intmax_t" >&5
19060 $as_echo "$gt_cv_c_intmax_t" >&6; }
19061   if test $gt_cv_c_intmax_t = yes; then
19062
19063 $as_echo "#define HAVE_INTMAX_T 1" >>confdefs.h
19064
19065   else
19066
19067     test $ac_cv_type_long_long_int = yes \
19068       && ac_type='long long' \
19069       || ac_type='long'
19070
19071 cat >>confdefs.h <<_ACEOF
19072 #define intmax_t $ac_type
19073 _ACEOF
19074
19075   fi
19076
19077
19078   { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the exponent in a 'double'" >&5
19079 $as_echo_n "checking where to find the exponent in a 'double'... " >&6; }
19080 if ${gl_cv_cc_double_expbit0+:} false; then :
19081   $as_echo_n "(cached) " >&6
19082 else
19083
19084       if test "$cross_compiling" = yes; then :
19085
19086                                                                       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19087 /* end confdefs.h.  */
19088
19089 #if defined arm || defined __arm || defined __arm__
19090   mixed_endianness
19091 #endif
19092
19093 _ACEOF
19094 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19095   $EGREP "mixed_endianness" >/dev/null 2>&1; then :
19096   gl_cv_cc_double_expbit0="unknown"
19097 else
19098
19099                                                          :
19100 if ${ac_cv_c_bigendian+:} false; then :
19101   $as_echo_n "(cached) " >&6
19102 else
19103   ac_cv_c_bigendian=unknown
19104     # See if we're dealing with a universal compiler.
19105     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19106 /* end confdefs.h.  */
19107 #ifndef __APPLE_CC__
19108                not a universal capable compiler
19109              #endif
19110              typedef int dummy;
19111
19112 _ACEOF
19113 if ac_fn_c_try_compile "$LINENO"; then :
19114
19115         # Check for potential -arch flags.  It is not universal unless
19116         # there are at least two -arch flags with different values.
19117         ac_arch=
19118         ac_prev=
19119         for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
19120          if test -n "$ac_prev"; then
19121            case $ac_word in
19122              i?86 | x86_64 | ppc | ppc64)
19123                if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
19124                  ac_arch=$ac_word
19125                else
19126                  ac_cv_c_bigendian=universal
19127                  break
19128                fi
19129                ;;
19130            esac
19131            ac_prev=
19132          elif test "x$ac_word" = "x-arch"; then
19133            ac_prev=arch
19134          fi
19135        done
19136 fi
19137 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19138     if test $ac_cv_c_bigendian = unknown; then
19139       # See if sys/param.h defines the BYTE_ORDER macro.
19140       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19141 /* end confdefs.h.  */
19142 #include <sys/types.h>
19143              #include <sys/param.h>
19144
19145 int
19146 main ()
19147 {
19148 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
19149                      && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
19150                      && LITTLE_ENDIAN)
19151               bogus endian macros
19152              #endif
19153
19154   ;
19155   return 0;
19156 }
19157 _ACEOF
19158 if ac_fn_c_try_compile "$LINENO"; then :
19159   # It does; now see whether it defined to BIG_ENDIAN or not.
19160          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19161 /* end confdefs.h.  */
19162 #include <sys/types.h>
19163                 #include <sys/param.h>
19164
19165 int
19166 main ()
19167 {
19168 #if BYTE_ORDER != BIG_ENDIAN
19169                  not big endian
19170                 #endif
19171
19172   ;
19173   return 0;
19174 }
19175 _ACEOF
19176 if ac_fn_c_try_compile "$LINENO"; then :
19177   ac_cv_c_bigendian=yes
19178 else
19179   ac_cv_c_bigendian=no
19180 fi
19181 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19182 fi
19183 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19184     fi
19185     if test $ac_cv_c_bigendian = unknown; then
19186       # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
19187       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19188 /* end confdefs.h.  */
19189 #include <limits.h>
19190
19191 int
19192 main ()
19193 {
19194 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
19195               bogus endian macros
19196              #endif
19197
19198   ;
19199   return 0;
19200 }
19201 _ACEOF
19202 if ac_fn_c_try_compile "$LINENO"; then :
19203   # It does; now see whether it defined to _BIG_ENDIAN or not.
19204          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19205 /* end confdefs.h.  */
19206 #include <limits.h>
19207
19208 int
19209 main ()
19210 {
19211 #ifndef _BIG_ENDIAN
19212                  not big endian
19213                 #endif
19214
19215   ;
19216   return 0;
19217 }
19218 _ACEOF
19219 if ac_fn_c_try_compile "$LINENO"; then :
19220   ac_cv_c_bigendian=yes
19221 else
19222   ac_cv_c_bigendian=no
19223 fi
19224 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19225 fi
19226 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19227     fi
19228     if test $ac_cv_c_bigendian = unknown; then
19229       # Compile a test program.
19230       if test "$cross_compiling" = yes; then :
19231   # Try to guess by grepping values from an object file.
19232          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19233 /* end confdefs.h.  */
19234 short int ascii_mm[] =
19235                   { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
19236                 short int ascii_ii[] =
19237                   { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
19238                 int use_ascii (int i) {
19239                   return ascii_mm[i] + ascii_ii[i];
19240                 }
19241                 short int ebcdic_ii[] =
19242                   { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
19243                 short int ebcdic_mm[] =
19244                   { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
19245                 int use_ebcdic (int i) {
19246                   return ebcdic_mm[i] + ebcdic_ii[i];
19247                 }
19248                 extern int foo;
19249
19250 int
19251 main ()
19252 {
19253 return use_ascii (foo) == use_ebcdic (foo);
19254   ;
19255   return 0;
19256 }
19257 _ACEOF
19258 if ac_fn_c_try_compile "$LINENO"; then :
19259   if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
19260               ac_cv_c_bigendian=yes
19261             fi
19262             if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
19263               if test "$ac_cv_c_bigendian" = unknown; then
19264                 ac_cv_c_bigendian=no
19265               else
19266                 # finding both strings is unlikely to happen, but who knows?
19267                 ac_cv_c_bigendian=unknown
19268               fi
19269             fi
19270 fi
19271 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19272 else
19273   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19274 /* end confdefs.h.  */
19275 $ac_includes_default
19276 int
19277 main ()
19278 {
19279
19280              /* Are we little or big endian?  From Harbison&Steele.  */
19281              union
19282              {
19283                long int l;
19284                char c[sizeof (long int)];
19285              } u;
19286              u.l = 1;
19287              return u.c[sizeof (long int) - 1] == 1;
19288
19289   ;
19290   return 0;
19291 }
19292 _ACEOF
19293 if ac_fn_c_try_run "$LINENO"; then :
19294   ac_cv_c_bigendian=no
19295 else
19296   ac_cv_c_bigendian=yes
19297 fi
19298 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19299   conftest.$ac_objext conftest.beam conftest.$ac_ext
19300 fi
19301
19302     fi
19303 fi
19304 :
19305  case $ac_cv_c_bigendian in #(
19306    yes)
19307      gl_cv_cc_double_expbit0="word 0 bit 20";; #(
19308    no)
19309      gl_cv_cc_double_expbit0="word 1 bit 20" ;; #(
19310    universal)
19311
19312 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
19313
19314      ;; #(
19315    *)
19316      gl_cv_cc_double_expbit0="unknown" ;;
19317  esac
19318
19319
19320 fi
19321 rm -f conftest*
19322
19323
19324 else
19325   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19326 /* end confdefs.h.  */
19327
19328 #include <float.h>
19329 #include <stddef.h>
19330 #include <stdio.h>
19331 #include <string.h>
19332 #define NWORDS \
19333   ((sizeof (double) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
19334 typedef union { double value; unsigned int word[NWORDS]; } memory_double;
19335 static unsigned int ored_words[NWORDS];
19336 static unsigned int anded_words[NWORDS];
19337 static void add_to_ored_words (double x)
19338 {
19339   memory_double m;
19340   size_t i;
19341   /* Clear it first, in case sizeof (double) < sizeof (memory_double).  */
19342   memset (&m, 0, sizeof (memory_double));
19343   m.value = x;
19344   for (i = 0; i < NWORDS; i++)
19345     {
19346       ored_words[i] |= m.word[i];
19347       anded_words[i] &= m.word[i];
19348     }
19349 }
19350 int main ()
19351 {
19352   size_t j;
19353   FILE *fp = fopen ("conftest.out", "w");
19354   if (fp == NULL)
19355     return 1;
19356   for (j = 0; j < NWORDS; j++)
19357     anded_words[j] = ~ (unsigned int) 0;
19358   add_to_ored_words (0.25);
19359   add_to_ored_words (0.5);
19360   add_to_ored_words (1.0);
19361   add_to_ored_words (2.0);
19362   add_to_ored_words (4.0);
19363   /* Remove bits that are common (e.g. if representation of the first mantissa
19364      bit is explicit).  */
19365   for (j = 0; j < NWORDS; j++)
19366     ored_words[j] &= ~anded_words[j];
19367   /* Now find the nonzero word.  */
19368   for (j = 0; j < NWORDS; j++)
19369     if (ored_words[j] != 0)
19370       break;
19371   if (j < NWORDS)
19372     {
19373       size_t i;
19374       for (i = j + 1; i < NWORDS; i++)
19375         if (ored_words[i] != 0)
19376           {
19377             fprintf (fp, "unknown");
19378             return (fclose (fp) != 0);
19379           }
19380       for (i = 0; ; i++)
19381         if ((ored_words[j] >> i) & 1)
19382           {
19383             fprintf (fp, "word %d bit %d", (int) j, (int) i);
19384             return (fclose (fp) != 0);
19385           }
19386     }
19387   fprintf (fp, "unknown");
19388   return (fclose (fp) != 0);
19389 }
19390
19391 _ACEOF
19392 if ac_fn_c_try_run "$LINENO"; then :
19393   gl_cv_cc_double_expbit0=`cat conftest.out`
19394 else
19395   gl_cv_cc_double_expbit0="unknown"
19396 fi
19397 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19398   conftest.$ac_objext conftest.beam conftest.$ac_ext
19399 fi
19400
19401       rm -f conftest.out
19402
19403 fi
19404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_double_expbit0" >&5
19405 $as_echo "$gl_cv_cc_double_expbit0" >&6; }
19406   case "$gl_cv_cc_double_expbit0" in
19407     word*bit*)
19408       word=`echo "$gl_cv_cc_double_expbit0" | sed -e 's/word //' -e 's/ bit.*//'`
19409       bit=`echo "$gl_cv_cc_double_expbit0" | sed -e 's/word.*bit //'`
19410
19411 cat >>confdefs.h <<_ACEOF
19412 #define DBL_EXPBIT0_WORD $word
19413 _ACEOF
19414
19415
19416 cat >>confdefs.h <<_ACEOF
19417 #define DBL_EXPBIT0_BIT $bit
19418 _ACEOF
19419
19420       ;;
19421   esac
19422
19423
19424
19425
19426
19427
19428   for ac_func in snprintf strnlen wcslen wcsnlen mbrtowc wcrtomb
19429 do :
19430   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
19431 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
19432 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
19433   cat >>confdefs.h <<_ACEOF
19434 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
19435 _ACEOF
19436
19437 fi
19438 done
19439
19440       ac_fn_c_check_decl "$LINENO" "_snprintf" "ac_cv_have_decl__snprintf" "#include <stdio.h>
19441 "
19442 if test "x$ac_cv_have_decl__snprintf" = xyes; then :
19443   ac_have_decl=1
19444 else
19445   ac_have_decl=0
19446 fi
19447
19448 cat >>confdefs.h <<_ACEOF
19449 #define HAVE_DECL__SNPRINTF $ac_have_decl
19450 _ACEOF
19451
19452
19453
19454   case "$gl_cv_func_snprintf_retval_c99" in
19455     *yes)
19456
19457 $as_echo "#define HAVE_SNPRINTF_RETVAL_C99 1" >>confdefs.h
19458
19459       ;;
19460   esac
19461
19462
19463   XGETTEXT_EXTRA_OPTIONS=
19464
19465
19466       ac_fn_c_check_decl "$LINENO" "vsnprintf" "ac_cv_have_decl_vsnprintf" "$ac_includes_default"
19467 if test "x$ac_cv_have_decl_vsnprintf" = xyes; then :
19468   ac_have_decl=1
19469 else
19470   ac_have_decl=0
19471 fi
19472
19473 cat >>confdefs.h <<_ACEOF
19474 #define HAVE_DECL_VSNPRINTF $ac_have_decl
19475 _ACEOF
19476
19477
19478
19479
19480
19481
19482
19483
19484   GNULIB_ISWBLANK=0;
19485   GNULIB_WCTYPE=0;
19486   GNULIB_ISWCTYPE=0;
19487   GNULIB_WCTRANS=0;
19488   GNULIB_TOWCTRANS=0;
19489     HAVE_ISWBLANK=1;
19490   HAVE_WCTYPE_T=1;
19491   HAVE_WCTRANS_T=1;
19492   REPLACE_ISWBLANK=0;
19493
19494
19495
19496
19497
19498
19499
19500
19501
19502
19503
19504 ac_fn_c_check_decl "$LINENO" "strerror_r" "ac_cv_have_decl_strerror_r" "$ac_includes_default"
19505 if test "x$ac_cv_have_decl_strerror_r" = xyes; then :
19506   ac_have_decl=1
19507 else
19508   ac_have_decl=0
19509 fi
19510
19511 cat >>confdefs.h <<_ACEOF
19512 #define HAVE_DECL_STRERROR_R $ac_have_decl
19513 _ACEOF
19514
19515 for ac_func in strerror_r
19516 do :
19517   ac_fn_c_check_func "$LINENO" "strerror_r" "ac_cv_func_strerror_r"
19518 if test "x$ac_cv_func_strerror_r" = xyes; then :
19519   cat >>confdefs.h <<_ACEOF
19520 #define HAVE_STRERROR_R 1
19521 _ACEOF
19522
19523 fi
19524 done
19525
19526 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strerror_r returns char *" >&5
19527 $as_echo_n "checking whether strerror_r returns char *... " >&6; }
19528 if ${ac_cv_func_strerror_r_char_p+:} false; then :
19529   $as_echo_n "(cached) " >&6
19530 else
19531
19532     ac_cv_func_strerror_r_char_p=no
19533     if test $ac_cv_have_decl_strerror_r = yes; then
19534       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19535 /* end confdefs.h.  */
19536 $ac_includes_default
19537 int
19538 main ()
19539 {
19540
19541           char buf[100];
19542           char x = *strerror_r (0, buf, sizeof buf);
19543           char *p = strerror_r (0, buf, sizeof buf);
19544           return !p || x;
19545
19546   ;
19547   return 0;
19548 }
19549 _ACEOF
19550 if ac_fn_c_try_compile "$LINENO"; then :
19551   ac_cv_func_strerror_r_char_p=yes
19552 fi
19553 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19554     else
19555       # strerror_r is not declared.  Choose between
19556       # systems that have relatively inaccessible declarations for the
19557       # function.  BeOS and DEC UNIX 4.0 fall in this category, but the
19558       # former has a strerror_r that returns char*, while the latter
19559       # has a strerror_r that returns `int'.
19560       # This test should segfault on the DEC system.
19561       if test "$cross_compiling" = yes; then :
19562   :
19563 else
19564   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19565 /* end confdefs.h.  */
19566 $ac_includes_default
19567         extern char *strerror_r ();
19568 int
19569 main ()
19570 {
19571 char buf[100];
19572           char x = *strerror_r (0, buf, sizeof buf);
19573           return ! isalpha (x);
19574   ;
19575   return 0;
19576 }
19577 _ACEOF
19578 if ac_fn_c_try_run "$LINENO"; then :
19579   ac_cv_func_strerror_r_char_p=yes
19580 fi
19581 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19582   conftest.$ac_objext conftest.beam conftest.$ac_ext
19583 fi
19584
19585     fi
19586
19587 fi
19588 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strerror_r_char_p" >&5
19589 $as_echo "$ac_cv_func_strerror_r_char_p" >&6; }
19590 if test $ac_cv_func_strerror_r_char_p = yes; then
19591
19592 $as_echo "#define STRERROR_R_CHAR_P 1" >>confdefs.h
19593
19594 fi
19595
19596
19597   ac_fn_c_check_type "$LINENO" "sig_atomic_t" "ac_cv_type_sig_atomic_t" "#include <signal.h>
19598 "
19599 if test "x$ac_cv_type_sig_atomic_t" = xyes; then :
19600
19601 cat >>confdefs.h <<_ACEOF
19602 #define HAVE_SIG_ATOMIC_T 1
19603 _ACEOF
19604
19605
19606 else
19607
19608 $as_echo "#define sig_atomic_t int" >>confdefs.h
19609
19610 fi
19611
19612
19613
19614
19615
19616   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ungetc works on arbitrary bytes" >&5
19617 $as_echo_n "checking whether ungetc works on arbitrary bytes... " >&6; }
19618 if ${gl_cv_func_ungetc_works+:} false; then :
19619   $as_echo_n "(cached) " >&6
19620 else
19621   if test "$cross_compiling" = yes; then :
19622   case "$host_os" in
19623                    # Guess yes on glibc systems.
19624            *-gnu*) gl_cv_func_ungetc_works="guessing yes" ;;
19625                    # If we don't know, assume the worst.
19626            *)      gl_cv_func_ungetc_works="guessing no" ;;
19627          esac
19628
19629 else
19630   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19631 /* end confdefs.h.  */
19632
19633 #include <stdio.h>
19634
19635 int
19636 main ()
19637 {
19638 FILE *f;
19639            if (!(f = fopen ("conftest.tmp", "w+"))) return 1;
19640            if (fputs ("abc", f) < 0) return 2;
19641            rewind (f);
19642            if (fgetc (f) != 'a') return 3;
19643            if (fgetc (f) != 'b') return 4;
19644            if (ungetc ('d', f) != 'd') return 5;
19645            if (ftell (f) != 1) return 6;
19646            if (fgetc (f) != 'd') return 7;
19647            if (ftell (f) != 2) return 8;
19648            if (fseek (f, 0, SEEK_CUR) != 0) return 9;
19649            if (ftell (f) != 2) return 10;
19650            if (fgetc (f) != 'c') return 11;
19651            fclose (f); remove ("conftest.tmp");
19652   ;
19653   return 0;
19654 }
19655 _ACEOF
19656 if ac_fn_c_try_run "$LINENO"; then :
19657   gl_cv_func_ungetc_works=yes
19658 else
19659   gl_cv_func_ungetc_works=no
19660 fi
19661 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19662   conftest.$ac_objext conftest.beam conftest.$ac_ext
19663 fi
19664
19665
19666 fi
19667 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_ungetc_works" >&5
19668 $as_echo "$gl_cv_func_ungetc_works" >&6; }
19669   case "$gl_cv_func_ungetc_works" in
19670     *yes) ;;
19671     *)
19672
19673 $as_echo "#define FUNC_UNGETC_BROKEN 1" >>confdefs.h
19674
19675       ;;
19676   esac
19677
19678
19679
19680
19681
19682
19683
19684
19685
19686
19687
19688
19689   GNULIB_IMAXABS=0;
19690   GNULIB_IMAXDIV=0;
19691   GNULIB_STRTOIMAX=0;
19692   GNULIB_STRTOUMAX=0;
19693     HAVE_DECL_IMAXABS=1;
19694   HAVE_DECL_IMAXDIV=1;
19695   HAVE_DECL_STRTOIMAX=1;
19696   HAVE_DECL_STRTOUMAX=1;
19697   REPLACE_STRTOIMAX=0;
19698   REPLACE_STRTOUMAX=0;
19699   INT32_MAX_LT_INTMAX_MAX=1;
19700   INT64_MAX_EQ_LONG_MAX='defined _LP64';
19701   PRI_MACROS_BROKEN=0;
19702   PRIPTR_PREFIX=__PRIPTR_PREFIX;
19703   UINT32_MAX_LT_UINTMAX_MAX=1;
19704   UINT64_MAX_EQ_ULONG_MAX='defined _LP64';
19705
19706
19707
19708
19709   :
19710
19711
19712
19713
19714
19715
19716
19717
19718
19719
19720
19721
19722
19723   :
19724
19725
19726
19727
19728
19729
19730
19731
19732      if test $gl_cv_have_include_next = yes; then
19733        gl_cv_next_inttypes_h='<'inttypes.h'>'
19734      else
19735        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <inttypes.h>" >&5
19736 $as_echo_n "checking absolute name of <inttypes.h>... " >&6; }
19737 if ${gl_cv_next_inttypes_h+:} false; then :
19738   $as_echo_n "(cached) " >&6
19739 else
19740
19741              if test $ac_cv_header_inttypes_h = yes; then
19742
19743
19744
19745
19746   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19747 /* end confdefs.h.  */
19748 #include <inttypes.h>
19749 _ACEOF
19750                 case "$host_os" in
19751     aix*) gl_absname_cpp="$ac_cpp -C" ;;
19752     *)    gl_absname_cpp="$ac_cpp" ;;
19753   esac
19754
19755   case "$host_os" in
19756     mingw*)
19757                                           gl_dirsep_regex='[/\\]'
19758       ;;
19759     *)
19760       gl_dirsep_regex='\/'
19761       ;;
19762   esac
19763       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
19764   gl_header_literal_regex=`echo 'inttypes.h' \
19765                            | sed -e "$gl_make_literal_regex_sed"`
19766   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19767       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19768       s|^/[^/]|//&|
19769       p
19770       q
19771     }'
19772
19773         gl_cv_absolute_inttypes_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19774   sed -n "$gl_absolute_header_sed"`
19775
19776            gl_header=$gl_cv_absolute_inttypes_h
19777            gl_cv_next_inttypes_h='"'$gl_header'"'
19778           else
19779                gl_cv_next_inttypes_h='<'inttypes.h'>'
19780              fi
19781
19782
19783 fi
19784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_inttypes_h" >&5
19785 $as_echo "$gl_cv_next_inttypes_h" >&6; }
19786      fi
19787      NEXT_INTTYPES_H=$gl_cv_next_inttypes_h
19788
19789      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19790        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19791        gl_next_as_first_directive='<'inttypes.h'>'
19792      else
19793        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19794        gl_next_as_first_directive=$gl_cv_next_inttypes_h
19795      fi
19796      NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H=$gl_next_as_first_directive
19797
19798
19799
19800
19801
19802
19803
19804
19805
19806
19807   for ac_header in inttypes.h
19808 do :
19809   ac_fn_c_check_header_mongrel "$LINENO" "inttypes.h" "ac_cv_header_inttypes_h" "$ac_includes_default"
19810 if test "x$ac_cv_header_inttypes_h" = xyes; then :
19811   cat >>confdefs.h <<_ACEOF
19812 #define HAVE_INTTYPES_H 1
19813 _ACEOF
19814
19815 fi
19816
19817 done
19818
19819   if test $ac_cv_header_inttypes_h = yes; then
19820     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the inttypes.h PRIxNN macros are broken" >&5
19821 $as_echo_n "checking whether the inttypes.h PRIxNN macros are broken... " >&6; }
19822 if ${gt_cv_inttypes_pri_broken+:} false; then :
19823   $as_echo_n "(cached) " >&6
19824 else
19825
19826         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19827 /* end confdefs.h.  */
19828
19829 #include <inttypes.h>
19830 #ifdef PRId32
19831 char *p = PRId32;
19832 #endif
19833
19834 int
19835 main ()
19836 {
19837
19838   ;
19839   return 0;
19840 }
19841 _ACEOF
19842 if ac_fn_c_try_compile "$LINENO"; then :
19843   gt_cv_inttypes_pri_broken=no
19844 else
19845   gt_cv_inttypes_pri_broken=yes
19846 fi
19847 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19848
19849 fi
19850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_inttypes_pri_broken" >&5
19851 $as_echo "$gt_cv_inttypes_pri_broken" >&6; }
19852   fi
19853   if test "$gt_cv_inttypes_pri_broken" = yes; then
19854
19855 cat >>confdefs.h <<_ACEOF
19856 #define PRI_MACROS_BROKEN 1
19857 _ACEOF
19858
19859     PRI_MACROS_BROKEN=1
19860   else
19861     PRI_MACROS_BROKEN=0
19862   fi
19863
19864
19865
19866   { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the exponent in a 'float'" >&5
19867 $as_echo_n "checking where to find the exponent in a 'float'... " >&6; }
19868 if ${gl_cv_cc_float_expbit0+:} false; then :
19869   $as_echo_n "(cached) " >&6
19870 else
19871
19872       if test "$cross_compiling" = yes; then :
19873   gl_cv_cc_float_expbit0="word 0 bit 23"
19874 else
19875   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19876 /* end confdefs.h.  */
19877
19878 #include <float.h>
19879 #include <stddef.h>
19880 #include <stdio.h>
19881 #include <string.h>
19882 #define NWORDS \
19883   ((sizeof (float) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
19884 typedef union { float value; unsigned int word[NWORDS]; } memory_float;
19885 static unsigned int ored_words[NWORDS];
19886 static unsigned int anded_words[NWORDS];
19887 static void add_to_ored_words (float x)
19888 {
19889   memory_float m;
19890   size_t i;
19891   /* Clear it first, in case
19892      sizeof (float) < sizeof (memory_float).  */
19893   memset (&m, 0, sizeof (memory_float));
19894   m.value = x;
19895   for (i = 0; i < NWORDS; i++)
19896     {
19897       ored_words[i] |= m.word[i];
19898       anded_words[i] &= m.word[i];
19899     }
19900 }
19901 int main ()
19902 {
19903   size_t j;
19904   FILE *fp = fopen ("conftest.out", "w");
19905   if (fp == NULL)
19906     return 1;
19907   for (j = 0; j < NWORDS; j++)
19908     anded_words[j] = ~ (unsigned int) 0;
19909   add_to_ored_words (0.25f);
19910   add_to_ored_words (0.5f);
19911   add_to_ored_words (1.0f);
19912   add_to_ored_words (2.0f);
19913   add_to_ored_words (4.0f);
19914   /* Remove bits that are common (e.g. if representation of the first mantissa
19915      bit is explicit).  */
19916   for (j = 0; j < NWORDS; j++)
19917     ored_words[j] &= ~anded_words[j];
19918   /* Now find the nonzero word.  */
19919   for (j = 0; j < NWORDS; j++)
19920     if (ored_words[j] != 0)
19921       break;
19922   if (j < NWORDS)
19923     {
19924       size_t i;
19925       for (i = j + 1; i < NWORDS; i++)
19926         if (ored_words[i] != 0)
19927           {
19928             fprintf (fp, "unknown");
19929             return (fclose (fp) != 0);
19930           }
19931       for (i = 0; ; i++)
19932         if ((ored_words[j] >> i) & 1)
19933           {
19934             fprintf (fp, "word %d bit %d", (int) j, (int) i);
19935             return (fclose (fp) != 0);
19936           }
19937     }
19938   fprintf (fp, "unknown");
19939   return (fclose (fp) != 0);
19940 }
19941
19942 _ACEOF
19943 if ac_fn_c_try_run "$LINENO"; then :
19944   gl_cv_cc_float_expbit0=`cat conftest.out`
19945 else
19946   gl_cv_cc_float_expbit0="unknown"
19947 fi
19948 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19949   conftest.$ac_objext conftest.beam conftest.$ac_ext
19950 fi
19951
19952       rm -f conftest.out
19953
19954 fi
19955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_float_expbit0" >&5
19956 $as_echo "$gl_cv_cc_float_expbit0" >&6; }
19957   case "$gl_cv_cc_float_expbit0" in
19958     word*bit*)
19959       word=`echo "$gl_cv_cc_float_expbit0" | sed -e 's/word //' -e 's/ bit.*//'`
19960       bit=`echo "$gl_cv_cc_float_expbit0" | sed -e 's/word.*bit //'`
19961
19962 cat >>confdefs.h <<_ACEOF
19963 #define FLT_EXPBIT0_WORD $word
19964 _ACEOF
19965
19966
19967 cat >>confdefs.h <<_ACEOF
19968 #define FLT_EXPBIT0_BIT $bit
19969 _ACEOF
19970
19971       ;;
19972   esac
19973
19974
19975   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether long double and double are the same" >&5
19976 $as_echo_n "checking whether long double and double are the same... " >&6; }
19977 if ${gl_cv_long_double_equals_double+:} false; then :
19978   $as_echo_n "(cached) " >&6
19979 else
19980   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19981 /* end confdefs.h.  */
19982 #include <float.h>
19983 int
19984 main ()
19985 {
19986 typedef int check[sizeof (long double) == sizeof (double)
19987                               && LDBL_MANT_DIG == DBL_MANT_DIG
19988                               && LDBL_MAX_EXP == DBL_MAX_EXP
19989                               && LDBL_MIN_EXP == DBL_MIN_EXP
19990                               ? 1 : -1];
19991
19992   ;
19993   return 0;
19994 }
19995 _ACEOF
19996 if ac_fn_c_try_compile "$LINENO"; then :
19997   gl_cv_long_double_equals_double=yes
19998 else
19999   gl_cv_long_double_equals_double=no
20000 fi
20001 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20002
20003 fi
20004 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_long_double_equals_double" >&5
20005 $as_echo "$gl_cv_long_double_equals_double" >&6; }
20006   if test $gl_cv_long_double_equals_double = yes; then
20007
20008 $as_echo "#define HAVE_SAME_LONG_DOUBLE_AS_DOUBLE 1" >>confdefs.h
20009
20010     HAVE_SAME_LONG_DOUBLE_AS_DOUBLE=1
20011   else
20012     HAVE_SAME_LONG_DOUBLE_AS_DOUBLE=0
20013   fi
20014
20015
20016
20017
20018
20019
20020
20021
20022   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LC_MESSAGES" >&5
20023 $as_echo_n "checking for LC_MESSAGES... " >&6; }
20024 if ${gt_cv_val_LC_MESSAGES+:} false; then :
20025   $as_echo_n "(cached) " >&6
20026 else
20027   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20028 /* end confdefs.h.  */
20029 #include <locale.h>
20030 int
20031 main ()
20032 {
20033 return LC_MESSAGES
20034   ;
20035   return 0;
20036 }
20037 _ACEOF
20038 if ac_fn_c_try_link "$LINENO"; then :
20039   gt_cv_val_LC_MESSAGES=yes
20040 else
20041   gt_cv_val_LC_MESSAGES=no
20042 fi
20043 rm -f core conftest.err conftest.$ac_objext \
20044     conftest$ac_exeext conftest.$ac_ext
20045 fi
20046 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_val_LC_MESSAGES" >&5
20047 $as_echo "$gt_cv_val_LC_MESSAGES" >&6; }
20048   if test $gt_cv_val_LC_MESSAGES = yes; then
20049
20050 $as_echo "#define HAVE_LC_MESSAGES 1" >>confdefs.h
20051
20052   fi
20053
20054
20055     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFPreferencesCopyAppValue" >&5
20056 $as_echo_n "checking for CFPreferencesCopyAppValue... " >&6; }
20057 if ${gt_cv_func_CFPreferencesCopyAppValue+:} false; then :
20058   $as_echo_n "(cached) " >&6
20059 else
20060   gt_save_LIBS="$LIBS"
20061      LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
20062      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20063 /* end confdefs.h.  */
20064 #include <CoreFoundation/CFPreferences.h>
20065 int
20066 main ()
20067 {
20068 CFPreferencesCopyAppValue(NULL, NULL)
20069   ;
20070   return 0;
20071 }
20072 _ACEOF
20073 if ac_fn_c_try_link "$LINENO"; then :
20074   gt_cv_func_CFPreferencesCopyAppValue=yes
20075 else
20076   gt_cv_func_CFPreferencesCopyAppValue=no
20077 fi
20078 rm -f core conftest.err conftest.$ac_objext \
20079     conftest$ac_exeext conftest.$ac_ext
20080      LIBS="$gt_save_LIBS"
20081 fi
20082 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFPreferencesCopyAppValue" >&5
20083 $as_echo "$gt_cv_func_CFPreferencesCopyAppValue" >&6; }
20084   if test $gt_cv_func_CFPreferencesCopyAppValue = yes; then
20085
20086 $as_echo "#define HAVE_CFPREFERENCESCOPYAPPVALUE 1" >>confdefs.h
20087
20088   fi
20089     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFLocaleCopyCurrent" >&5
20090 $as_echo_n "checking for CFLocaleCopyCurrent... " >&6; }
20091 if ${gt_cv_func_CFLocaleCopyCurrent+:} false; then :
20092   $as_echo_n "(cached) " >&6
20093 else
20094   gt_save_LIBS="$LIBS"
20095      LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
20096      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20097 /* end confdefs.h.  */
20098 #include <CoreFoundation/CFLocale.h>
20099 int
20100 main ()
20101 {
20102 CFLocaleCopyCurrent();
20103   ;
20104   return 0;
20105 }
20106 _ACEOF
20107 if ac_fn_c_try_link "$LINENO"; then :
20108   gt_cv_func_CFLocaleCopyCurrent=yes
20109 else
20110   gt_cv_func_CFLocaleCopyCurrent=no
20111 fi
20112 rm -f core conftest.err conftest.$ac_objext \
20113     conftest$ac_exeext conftest.$ac_ext
20114      LIBS="$gt_save_LIBS"
20115 fi
20116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFLocaleCopyCurrent" >&5
20117 $as_echo "$gt_cv_func_CFLocaleCopyCurrent" >&6; }
20118   if test $gt_cv_func_CFLocaleCopyCurrent = yes; then
20119
20120 $as_echo "#define HAVE_CFLOCALECOPYCURRENT 1" >>confdefs.h
20121
20122   fi
20123   INTL_MACOSX_LIBS=
20124   if test $gt_cv_func_CFPreferencesCopyAppValue = yes || test $gt_cv_func_CFLocaleCopyCurrent = yes; then
20125     INTL_MACOSX_LIBS="-Wl,-framework -Wl,CoreFoundation"
20126   fi
20127
20128
20129
20130   GNULIB_ACOSF=0;
20131   GNULIB_ACOSL=0;
20132   GNULIB_ASINF=0;
20133   GNULIB_ASINL=0;
20134   GNULIB_ATANF=0;
20135   GNULIB_ATANL=0;
20136   GNULIB_ATAN2F=0;
20137   GNULIB_CBRT=0;
20138   GNULIB_CBRTF=0;
20139   GNULIB_CBRTL=0;
20140   GNULIB_CEIL=0;
20141   GNULIB_CEILF=0;
20142   GNULIB_CEILL=0;
20143   GNULIB_COPYSIGN=0;
20144   GNULIB_COPYSIGNF=0;
20145   GNULIB_COPYSIGNL=0;
20146   GNULIB_COSF=0;
20147   GNULIB_COSL=0;
20148   GNULIB_COSHF=0;
20149   GNULIB_EXPF=0;
20150   GNULIB_EXPL=0;
20151   GNULIB_EXP2=0;
20152   GNULIB_EXP2F=0;
20153   GNULIB_EXP2L=0;
20154   GNULIB_EXPM1=0;
20155   GNULIB_EXPM1F=0;
20156   GNULIB_EXPM1L=0;
20157   GNULIB_FABSF=0;
20158   GNULIB_FABSL=0;
20159   GNULIB_FLOOR=0;
20160   GNULIB_FLOORF=0;
20161   GNULIB_FLOORL=0;
20162   GNULIB_FMA=0;
20163   GNULIB_FMAF=0;
20164   GNULIB_FMAL=0;
20165   GNULIB_FMOD=0;
20166   GNULIB_FMODF=0;
20167   GNULIB_FMODL=0;
20168   GNULIB_FREXPF=0;
20169   GNULIB_FREXP=0;
20170   GNULIB_FREXPL=0;
20171   GNULIB_HYPOT=0;
20172   GNULIB_HYPOTF=0;
20173   GNULIB_HYPOTL=0;
20174   GNULIB_ILOGB=0;
20175   GNULIB_ILOGBF=0;
20176   GNULIB_ILOGBL=0;
20177   GNULIB_ISFINITE=0;
20178   GNULIB_ISINF=0;
20179   GNULIB_ISNAN=0;
20180   GNULIB_ISNANF=0;
20181   GNULIB_ISNAND=0;
20182   GNULIB_ISNANL=0;
20183   GNULIB_LDEXPF=0;
20184   GNULIB_LDEXPL=0;
20185   GNULIB_LOG=0;
20186   GNULIB_LOGF=0;
20187   GNULIB_LOGL=0;
20188   GNULIB_LOG10=0;
20189   GNULIB_LOG10F=0;
20190   GNULIB_LOG10L=0;
20191   GNULIB_LOG1P=0;
20192   GNULIB_LOG1PF=0;
20193   GNULIB_LOG1PL=0;
20194   GNULIB_LOG2=0;
20195   GNULIB_LOG2F=0;
20196   GNULIB_LOG2L=0;
20197   GNULIB_LOGB=0;
20198   GNULIB_LOGBF=0;
20199   GNULIB_LOGBL=0;
20200   GNULIB_MODF=0;
20201   GNULIB_MODFF=0;
20202   GNULIB_MODFL=0;
20203   GNULIB_POWF=0;
20204   GNULIB_REMAINDER=0;
20205   GNULIB_REMAINDERF=0;
20206   GNULIB_REMAINDERL=0;
20207   GNULIB_RINT=0;
20208   GNULIB_RINTF=0;
20209   GNULIB_RINTL=0;
20210   GNULIB_ROUND=0;
20211   GNULIB_ROUNDF=0;
20212   GNULIB_ROUNDL=0;
20213   GNULIB_SIGNBIT=0;
20214   GNULIB_SINF=0;
20215   GNULIB_SINL=0;
20216   GNULIB_SINHF=0;
20217   GNULIB_SQRTF=0;
20218   GNULIB_SQRTL=0;
20219   GNULIB_TANF=0;
20220   GNULIB_TANL=0;
20221   GNULIB_TANHF=0;
20222   GNULIB_TRUNC=0;
20223   GNULIB_TRUNCF=0;
20224   GNULIB_TRUNCL=0;
20225     HAVE_ACOSF=1;
20226   HAVE_ACOSL=1;
20227   HAVE_ASINF=1;
20228   HAVE_ASINL=1;
20229   HAVE_ATANF=1;
20230   HAVE_ATANL=1;
20231   HAVE_ATAN2F=1;
20232   HAVE_CBRT=1;
20233   HAVE_CBRTF=1;
20234   HAVE_CBRTL=1;
20235   HAVE_COPYSIGN=1;
20236   HAVE_COPYSIGNL=1;
20237   HAVE_COSF=1;
20238   HAVE_COSL=1;
20239   HAVE_COSHF=1;
20240   HAVE_EXPF=1;
20241   HAVE_EXPL=1;
20242   HAVE_EXPM1=1;
20243   HAVE_EXPM1F=1;
20244   HAVE_FABSF=1;
20245   HAVE_FABSL=1;
20246   HAVE_FMA=1;
20247   HAVE_FMAF=1;
20248   HAVE_FMAL=1;
20249   HAVE_FMODF=1;
20250   HAVE_FMODL=1;
20251   HAVE_FREXPF=1;
20252   HAVE_HYPOTF=1;
20253   HAVE_HYPOTL=1;
20254   HAVE_ILOGB=1;
20255   HAVE_ILOGBF=1;
20256   HAVE_ILOGBL=1;
20257   HAVE_ISNANF=1;
20258   HAVE_ISNAND=1;
20259   HAVE_ISNANL=1;
20260   HAVE_LDEXPF=1;
20261   HAVE_LOGF=1;
20262   HAVE_LOGL=1;
20263   HAVE_LOG10F=1;
20264   HAVE_LOG10L=1;
20265   HAVE_LOG1P=1;
20266   HAVE_LOG1PF=1;
20267   HAVE_LOG1PL=1;
20268   HAVE_LOGBF=1;
20269   HAVE_LOGBL=1;
20270   HAVE_MODFF=1;
20271   HAVE_MODFL=1;
20272   HAVE_POWF=1;
20273   HAVE_REMAINDER=1;
20274   HAVE_REMAINDERF=1;
20275   HAVE_RINT=1;
20276   HAVE_RINTL=1;
20277   HAVE_SINF=1;
20278   HAVE_SINL=1;
20279   HAVE_SINHF=1;
20280   HAVE_SQRTF=1;
20281   HAVE_SQRTL=1;
20282   HAVE_TANF=1;
20283   HAVE_TANL=1;
20284   HAVE_TANHF=1;
20285   HAVE_DECL_ACOSL=1;
20286   HAVE_DECL_ASINL=1;
20287   HAVE_DECL_ATANL=1;
20288   HAVE_DECL_CBRTF=1;
20289   HAVE_DECL_CBRTL=1;
20290   HAVE_DECL_CEILF=1;
20291   HAVE_DECL_CEILL=1;
20292   HAVE_DECL_COPYSIGNF=1;
20293   HAVE_DECL_COSL=1;
20294   HAVE_DECL_EXPL=1;
20295   HAVE_DECL_EXP2=1;
20296   HAVE_DECL_EXP2F=1;
20297   HAVE_DECL_EXP2L=1;
20298   HAVE_DECL_EXPM1L=1;
20299   HAVE_DECL_FLOORF=1;
20300   HAVE_DECL_FLOORL=1;
20301   HAVE_DECL_FREXPL=1;
20302   HAVE_DECL_LDEXPL=1;
20303   HAVE_DECL_LOGL=1;
20304   HAVE_DECL_LOG10L=1;
20305   HAVE_DECL_LOG2=1;
20306   HAVE_DECL_LOG2F=1;
20307   HAVE_DECL_LOG2L=1;
20308   HAVE_DECL_LOGB=1;
20309   HAVE_DECL_REMAINDER=1;
20310   HAVE_DECL_REMAINDERL=1;
20311   HAVE_DECL_RINTF=1;
20312   HAVE_DECL_ROUND=1;
20313   HAVE_DECL_ROUNDF=1;
20314   HAVE_DECL_ROUNDL=1;
20315   HAVE_DECL_SINL=1;
20316   HAVE_DECL_SQRTL=1;
20317   HAVE_DECL_TANL=1;
20318   HAVE_DECL_TRUNC=1;
20319   HAVE_DECL_TRUNCF=1;
20320   HAVE_DECL_TRUNCL=1;
20321   REPLACE_CBRTF=0;
20322   REPLACE_CBRTL=0;
20323   REPLACE_CEIL=0;
20324   REPLACE_CEILF=0;
20325   REPLACE_CEILL=0;
20326   REPLACE_EXPM1=0;
20327   REPLACE_EXPM1F=0;
20328   REPLACE_EXP2=0;
20329   REPLACE_EXP2L=0;
20330   REPLACE_FABSL=0;
20331   REPLACE_FLOOR=0;
20332   REPLACE_FLOORF=0;
20333   REPLACE_FLOORL=0;
20334   REPLACE_FMA=0;
20335   REPLACE_FMAF=0;
20336   REPLACE_FMAL=0;
20337   REPLACE_FMOD=0;
20338   REPLACE_FMODF=0;
20339   REPLACE_FMODL=0;
20340   REPLACE_FREXPF=0;
20341   REPLACE_FREXP=0;
20342   REPLACE_FREXPL=0;
20343   REPLACE_HUGE_VAL=0;
20344   REPLACE_HYPOT=0;
20345   REPLACE_HYPOTF=0;
20346   REPLACE_HYPOTL=0;
20347   REPLACE_ILOGB=0;
20348   REPLACE_ILOGBF=0;
20349   REPLACE_ISFINITE=0;
20350   REPLACE_ISINF=0;
20351   REPLACE_ISNAN=0;
20352   REPLACE_LDEXPL=0;
20353   REPLACE_LOG=0;
20354   REPLACE_LOGF=0;
20355   REPLACE_LOGL=0;
20356   REPLACE_LOG10=0;
20357   REPLACE_LOG10F=0;
20358   REPLACE_LOG10L=0;
20359   REPLACE_LOG1P=0;
20360   REPLACE_LOG1PF=0;
20361   REPLACE_LOG1PL=0;
20362   REPLACE_LOG2=0;
20363   REPLACE_LOG2F=0;
20364   REPLACE_LOG2L=0;
20365   REPLACE_LOGB=0;
20366   REPLACE_LOGBF=0;
20367   REPLACE_LOGBL=0;
20368   REPLACE_MODF=0;
20369   REPLACE_MODFF=0;
20370   REPLACE_MODFL=0;
20371   REPLACE_NAN=0;
20372   REPLACE_REMAINDER=0;
20373   REPLACE_REMAINDERF=0;
20374   REPLACE_REMAINDERL=0;
20375   REPLACE_ROUND=0;
20376   REPLACE_ROUNDF=0;
20377   REPLACE_ROUNDL=0;
20378   REPLACE_SIGNBIT=0;
20379   REPLACE_SIGNBIT_USING_GCC=0;
20380   REPLACE_SQRTL=0;
20381   REPLACE_TRUNC=0;
20382   REPLACE_TRUNCF=0;
20383   REPLACE_TRUNCL=0;
20384
20385
20386
20387
20388
20389
20390
20391
20392
20393
20394
20395
20396   GNULIB_POSIX_SPAWN=0;
20397   GNULIB_POSIX_SPAWNP=0;
20398   GNULIB_POSIX_SPAWN_FILE_ACTIONS_INIT=0;
20399   GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE=0;
20400   GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2=0;
20401   GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN=0;
20402   GNULIB_POSIX_SPAWN_FILE_ACTIONS_DESTROY=0;
20403   GNULIB_POSIX_SPAWNATTR_INIT=0;
20404   GNULIB_POSIX_SPAWNATTR_GETFLAGS=0;
20405   GNULIB_POSIX_SPAWNATTR_SETFLAGS=0;
20406   GNULIB_POSIX_SPAWNATTR_GETPGROUP=0;
20407   GNULIB_POSIX_SPAWNATTR_SETPGROUP=0;
20408   GNULIB_POSIX_SPAWNATTR_GETSCHEDPARAM=0;
20409   GNULIB_POSIX_SPAWNATTR_SETSCHEDPARAM=0;
20410   GNULIB_POSIX_SPAWNATTR_GETSCHEDPOLICY=0;
20411   GNULIB_POSIX_SPAWNATTR_SETSCHEDPOLICY=0;
20412   GNULIB_POSIX_SPAWNATTR_GETSIGDEFAULT=0;
20413   GNULIB_POSIX_SPAWNATTR_SETSIGDEFAULT=0;
20414   GNULIB_POSIX_SPAWNATTR_GETSIGMASK=0;
20415   GNULIB_POSIX_SPAWNATTR_SETSIGMASK=0;
20416   GNULIB_POSIX_SPAWNATTR_DESTROY=0;
20417     HAVE_POSIX_SPAWN=1;
20418   HAVE_POSIX_SPAWNATTR_T=1;
20419   HAVE_POSIX_SPAWN_FILE_ACTIONS_T=1;
20420
20421   REPLACE_POSIX_SPAWN=0;
20422   REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE=0;
20423
20424   REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2=0;
20425
20426   REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN=0;
20427
20428
20429
20430
20431
20432   LIB_POSIX_SPAWN=
20433
20434   gl_saved_libs=$LIBS
20435     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing posix_spawn" >&5
20436 $as_echo_n "checking for library containing posix_spawn... " >&6; }
20437 if ${ac_cv_search_posix_spawn+:} false; then :
20438   $as_echo_n "(cached) " >&6
20439 else
20440   ac_func_search_save_LIBS=$LIBS
20441 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20442 /* end confdefs.h.  */
20443
20444 /* Override any GCC internal prototype to avoid an error.
20445    Use char because int might match the return type of a GCC
20446    builtin and then its argument prototype would still apply.  */
20447 #ifdef __cplusplus
20448 extern "C"
20449 #endif
20450 char posix_spawn ();
20451 int
20452 main ()
20453 {
20454 return posix_spawn ();
20455   ;
20456   return 0;
20457 }
20458 _ACEOF
20459 for ac_lib in '' rt; do
20460   if test -z "$ac_lib"; then
20461     ac_res="none required"
20462   else
20463     ac_res=-l$ac_lib
20464     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
20465   fi
20466   if ac_fn_c_try_link "$LINENO"; then :
20467   ac_cv_search_posix_spawn=$ac_res
20468 fi
20469 rm -f core conftest.err conftest.$ac_objext \
20470     conftest$ac_exeext
20471   if ${ac_cv_search_posix_spawn+:} false; then :
20472   break
20473 fi
20474 done
20475 if ${ac_cv_search_posix_spawn+:} false; then :
20476
20477 else
20478   ac_cv_search_posix_spawn=no
20479 fi
20480 rm conftest.$ac_ext
20481 LIBS=$ac_func_search_save_LIBS
20482 fi
20483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_posix_spawn" >&5
20484 $as_echo "$ac_cv_search_posix_spawn" >&6; }
20485 ac_res=$ac_cv_search_posix_spawn
20486 if test "$ac_res" != no; then :
20487   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
20488   test "$ac_cv_search_posix_spawn" = "none required" ||
20489                     LIB_POSIX_SPAWN=$ac_cv_search_posix_spawn
20490 fi
20491
20492     for ac_func in posix_spawn
20493 do :
20494   ac_fn_c_check_func "$LINENO" "posix_spawn" "ac_cv_func_posix_spawn"
20495 if test "x$ac_cv_func_posix_spawn" = xyes; then :
20496   cat >>confdefs.h <<_ACEOF
20497 #define HAVE_POSIX_SPAWN 1
20498 _ACEOF
20499
20500 fi
20501 done
20502
20503   LIBS=$gl_saved_libs
20504
20505   if test $ac_cv_func_posix_spawn != yes; then
20506     HAVE_POSIX_SPAWN=0
20507   fi
20508
20509
20510
20511
20512                                       if test $ac_cv_func_posix_spawn = yes; then
20513
20514
20515      { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether posix_spawn works" >&5
20516 $as_echo_n "checking whether posix_spawn works... " >&6; }
20517 if ${gl_cv_func_posix_spawn_works+:} false; then :
20518   $as_echo_n "(cached) " >&6
20519 else
20520   if test $cross_compiling = no; then
20521        cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20522 /* end confdefs.h.  */
20523
20524 #include <errno.h>
20525 #include <fcntl.h>
20526 #include <signal.h>
20527 #include <spawn.h>
20528 #include <stdbool.h>
20529 #include <stdio.h>
20530 #include <stdlib.h>
20531 #include <string.h>
20532 #include <unistd.h>
20533 #include <sys/types.h>
20534 #include <sys/wait.h>
20535
20536 extern char **environ;
20537
20538 #ifndef STDIN_FILENO
20539 # define STDIN_FILENO 0
20540 #endif
20541 #ifndef STDOUT_FILENO
20542 # define STDOUT_FILENO 1
20543 #endif
20544 #ifndef STDERR_FILENO
20545 # define STDERR_FILENO 2
20546 #endif
20547
20548 #ifndef WTERMSIG
20549 # define WTERMSIG(x) ((x) & 0x7f)
20550 #endif
20551 #ifndef WIFEXITED
20552 # define WIFEXITED(x) (WTERMSIG (x) == 0)
20553 #endif
20554 #ifndef WEXITSTATUS
20555 # define WEXITSTATUS(x) (((x) >> 8) & 0xff)
20556 #endif
20557
20558 #define CHILD_PROGRAM_FILENAME "/non/exist/ent"
20559
20560 static int
20561 fd_safer (int fd)
20562 {
20563   if (0 <= fd && fd <= 2)
20564     {
20565       int f = fd_safer (dup (fd));
20566       int e = errno;
20567       close (fd);
20568       errno = e;
20569       fd = f;
20570     }
20571
20572   return fd;
20573 }
20574
20575 int
20576 main ()
20577 {
20578   char *argv[2] = { CHILD_PROGRAM_FILENAME, NULL };
20579   int ofd[2];
20580   sigset_t blocked_signals;
20581   sigset_t fatal_signal_set;
20582   posix_spawn_file_actions_t actions;
20583   bool actions_allocated;
20584   posix_spawnattr_t attrs;
20585   bool attrs_allocated;
20586   int err;
20587   pid_t child;
20588   int status;
20589   int exitstatus;
20590
20591   setvbuf (stdout, NULL, _IOFBF, 0);
20592   puts ("This should be seen only once.");
20593   if (pipe (ofd) < 0 || (ofd[1] = fd_safer (ofd[1])) < 0)
20594     {
20595       perror ("cannot create pipe");
20596       exit (1);
20597     }
20598   sigprocmask (SIG_SETMASK, NULL, &blocked_signals);
20599   sigemptyset (&fatal_signal_set);
20600   sigaddset (&fatal_signal_set, SIGINT);
20601   sigaddset (&fatal_signal_set, SIGTERM);
20602   sigaddset (&fatal_signal_set, SIGHUP);
20603   sigaddset (&fatal_signal_set, SIGPIPE);
20604   sigprocmask (SIG_BLOCK, &fatal_signal_set, NULL);
20605   actions_allocated = false;
20606   attrs_allocated = false;
20607   if ((err = posix_spawn_file_actions_init (&actions)) != 0
20608       || (actions_allocated = true,
20609           (err = posix_spawn_file_actions_adddup2 (&actions, ofd[0], STDIN_FILENO)) != 0
20610           || (err = posix_spawn_file_actions_addclose (&actions, ofd[0])) != 0
20611           || (err = posix_spawn_file_actions_addclose (&actions, ofd[1])) != 0
20612           || (err = posix_spawnattr_init (&attrs)) != 0
20613           || (attrs_allocated = true,
20614               (err = posix_spawnattr_setsigmask (&attrs, &blocked_signals)) != 0
20615               || (err = posix_spawnattr_setflags (&attrs, POSIX_SPAWN_SETSIGMASK)) != 0)
20616           || (err = posix_spawnp (&child, CHILD_PROGRAM_FILENAME, &actions, &attrs, argv, environ)) != 0))
20617     {
20618       if (actions_allocated)
20619         posix_spawn_file_actions_destroy (&actions);
20620       if (attrs_allocated)
20621         posix_spawnattr_destroy (&attrs);
20622       sigprocmask (SIG_UNBLOCK, &fatal_signal_set, NULL);
20623       if (err == ENOENT)
20624         return 0;
20625       else
20626         {
20627           errno = err;
20628           perror ("subprocess failed");
20629           exit (1);
20630         }
20631     }
20632   posix_spawn_file_actions_destroy (&actions);
20633   posix_spawnattr_destroy (&attrs);
20634   sigprocmask (SIG_UNBLOCK, &fatal_signal_set, NULL);
20635   close (ofd[0]);
20636   close (ofd[1]);
20637   status = 0;
20638   while (waitpid (child, &status, 0) != child)
20639     ;
20640   if (!WIFEXITED (status))
20641     {
20642       fprintf (stderr, "subprocess terminated with unexpected wait status %d\n", status);
20643       exit (1);
20644     }
20645   exitstatus = WEXITSTATUS (status);
20646   if (exitstatus != 127)
20647     {
20648       fprintf (stderr, "subprocess terminated with unexpected exit status %d\n", exitstatus);
20649       exit (1);
20650     }
20651   return 0;
20652 }
20653
20654 _ACEOF
20655 if ac_fn_c_try_link "$LINENO"; then :
20656   if test -s conftest$ac_exeext \
20657              && ./conftest$ac_exeext > conftest.out \
20658              && echo 'This should be seen only once.' > conftest.ok \
20659              && cmp conftest.out conftest.ok > /dev/null; then
20660             gl_cv_func_posix_spawn_works=yes
20661           else
20662             gl_cv_func_posix_spawn_works=no
20663           fi
20664 else
20665   gl_cv_func_posix_spawn_works=no
20666 fi
20667 rm -f core conftest.err conftest.$ac_objext \
20668     conftest$ac_exeext conftest.$ac_ext
20669        if test $gl_cv_func_posix_spawn_works = yes; then
20670          if test "$cross_compiling" = yes; then :
20671   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
20672 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
20673 as_fn_error $? "cannot run test program while cross compiling
20674 See \`config.log' for more details" "$LINENO" 5; }
20675 else
20676   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20677 /* end confdefs.h.  */
20678
20679 /* Test whether posix_spawn_file_actions_addopen supports filename arguments
20680    that contain special characters such as '*'.  */
20681
20682 #include <errno.h>
20683 #include <fcntl.h>
20684 #include <signal.h>
20685 #include <spawn.h>
20686 #include <stdbool.h>
20687 #include <stdio.h>
20688 #include <string.h>
20689 #include <unistd.h>
20690 #include <sys/types.h>
20691 #include <sys/wait.h>
20692
20693 extern char **environ;
20694
20695 #ifndef STDIN_FILENO
20696 # define STDIN_FILENO 0
20697 #endif
20698 #ifndef STDOUT_FILENO
20699 # define STDOUT_FILENO 1
20700 #endif
20701 #ifndef STDERR_FILENO
20702 # define STDERR_FILENO 2
20703 #endif
20704
20705 #ifndef WTERMSIG
20706 # define WTERMSIG(x) ((x) & 0x7f)
20707 #endif
20708 #ifndef WIFEXITED
20709 # define WIFEXITED(x) (WTERMSIG (x) == 0)
20710 #endif
20711 #ifndef WEXITSTATUS
20712 # define WEXITSTATUS(x) (((x) >> 8) & 0xff)
20713 #endif
20714
20715 #define CHILD_PROGRAM_FILENAME "conftest"
20716 #define DATA_FILENAME "conftest%=*#?"
20717
20718 static int
20719 parent_main (void)
20720 {
20721   FILE *fp;
20722   char *argv[3] = { CHILD_PROGRAM_FILENAME, "-child", NULL };
20723   posix_spawn_file_actions_t actions;
20724   bool actions_allocated;
20725   int err;
20726   pid_t child;
20727   int status;
20728   int exitstatus;
20729
20730   /* Create a data file with specific contents.  */
20731   fp = fopen (DATA_FILENAME, "wb");
20732   if (fp == NULL)
20733     {
20734       perror ("cannot create data file");
20735       return 1;
20736     }
20737   fwrite ("Halle Potta", 1, 11, fp);
20738   if (fflush (fp) || fclose (fp))
20739     {
20740       perror ("cannot prepare data file");
20741       return 2;
20742     }
20743
20744   /* Avoid reading from our stdin, as it could block.  */
20745   freopen ("/dev/null", "rb", stdin);
20746
20747   /* Test whether posix_spawn_file_actions_addopen with this file name
20748      actually works, but spawning a child that reads from this file.  */
20749   actions_allocated = false;
20750   if ((err = posix_spawn_file_actions_init (&actions)) != 0
20751       || (actions_allocated = true,
20752           (err = posix_spawn_file_actions_addopen (&actions, STDIN_FILENO, DATA_FILENAME, O_RDONLY, 0600)) != 0
20753           || (err = posix_spawn (&child, CHILD_PROGRAM_FILENAME, &actions, NULL, argv, environ)) != 0))
20754     {
20755       if (actions_allocated)
20756         posix_spawn_file_actions_destroy (&actions);
20757       errno = err;
20758       perror ("subprocess failed");
20759       return 3;
20760     }
20761   posix_spawn_file_actions_destroy (&actions);
20762   status = 0;
20763   while (waitpid (child, &status, 0) != child)
20764     ;
20765   if (!WIFEXITED (status))
20766     {
20767       fprintf (stderr, "subprocess terminated with unexpected wait status %d\n", status);
20768       return 4;
20769     }
20770   exitstatus = WEXITSTATUS (status);
20771   if (exitstatus != 0)
20772     {
20773       fprintf (stderr, "subprocess terminated with unexpected exit status %d\n", exitstatus);
20774       return 5;
20775     }
20776   return 0;
20777 }
20778
20779 static int
20780 child_main (void)
20781 {
20782   char buf[1024];
20783
20784   /* See if reading from STDIN_FILENO yields the expected contents.  */
20785   if (fread (buf, 1, sizeof (buf), stdin) == 11
20786       && memcmp (buf, "Halle Potta", 11) == 0)
20787     return 0;
20788   else
20789     return 8;
20790 }
20791
20792 static void
20793 cleanup_then_die (int sig)
20794 {
20795   /* Clean up data file.  */
20796   unlink (DATA_FILENAME);
20797
20798   /* Re-raise the signal and die from it.  */
20799   signal (sig, SIG_DFL);
20800   raise (sig);
20801 }
20802
20803 int
20804 main (int argc, char *argv[])
20805 {
20806   int exitstatus;
20807
20808   if (!(argc > 1 && strcmp (argv[1], "-child") == 0))
20809     {
20810       /* This is the parent process.  */
20811       signal (SIGINT, cleanup_then_die);
20812       signal (SIGTERM, cleanup_then_die);
20813       #ifdef SIGHUP
20814       signal (SIGHUP, cleanup_then_die);
20815       #endif
20816
20817       exitstatus = parent_main ();
20818     }
20819   else
20820     {
20821       /* This is the child process.  */
20822
20823       exitstatus = child_main ();
20824     }
20825   unlink (DATA_FILENAME);
20826   return exitstatus;
20827 }
20828
20829 _ACEOF
20830 if ac_fn_c_try_run "$LINENO"; then :
20831
20832 else
20833   gl_cv_func_posix_spawn_works=no
20834 fi
20835 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20836   conftest.$ac_objext conftest.beam conftest.$ac_ext
20837 fi
20838
20839        fi
20840      else
20841        case "$host_os" in
20842          aix*) gl_cv_func_posix_spawn_works="guessing no";;
20843          *)    gl_cv_func_posix_spawn_works="guessing yes";;
20844        esac
20845      fi
20846
20847 fi
20848 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_posix_spawn_works" >&5
20849 $as_echo "$gl_cv_func_posix_spawn_works" >&6; }
20850
20851     case "$gl_cv_func_posix_spawn_works" in
20852       *yes)
20853
20854 $as_echo "#define HAVE_WORKING_POSIX_SPAWN 1" >>confdefs.h
20855
20856                                         { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether posix_spawnattr_setschedpolicy is supported" >&5
20857 $as_echo_n "checking whether posix_spawnattr_setschedpolicy is supported... " >&6; }
20858 if ${gl_cv_func_spawnattr_setschedpolicy+:} false; then :
20859   $as_echo_n "(cached) " >&6
20860 else
20861   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20862 /* end confdefs.h.  */
20863
20864 #include <spawn.h>
20865 #if POSIX_SPAWN_SETSCHEDULER
20866  POSIX scheduling supported
20867 #endif
20868
20869 _ACEOF
20870 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
20871   $EGREP "POSIX scheduling supported" >/dev/null 2>&1; then :
20872   gl_cv_func_spawnattr_setschedpolicy=yes
20873 else
20874   gl_cv_func_spawnattr_setschedpolicy=no
20875 fi
20876 rm -f conftest*
20877
20878
20879 fi
20880 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_spawnattr_setschedpolicy" >&5
20881 $as_echo "$gl_cv_func_spawnattr_setschedpolicy" >&6; }
20882                                         { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether posix_spawnattr_setschedparam is supported" >&5
20883 $as_echo_n "checking whether posix_spawnattr_setschedparam is supported... " >&6; }
20884 if ${gl_cv_func_spawnattr_setschedparam+:} false; then :
20885   $as_echo_n "(cached) " >&6
20886 else
20887   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20888 /* end confdefs.h.  */
20889
20890 #include <spawn.h>
20891 #if POSIX_SPAWN_SETSCHEDPARAM
20892  POSIX scheduling supported
20893 #endif
20894
20895 _ACEOF
20896 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
20897   $EGREP "POSIX scheduling supported" >/dev/null 2>&1; then :
20898   gl_cv_func_spawnattr_setschedparam=yes
20899 else
20900   gl_cv_func_spawnattr_setschedparam=no
20901 fi
20902 rm -f conftest*
20903
20904
20905 fi
20906 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_spawnattr_setschedparam" >&5
20907 $as_echo "$gl_cv_func_spawnattr_setschedparam" >&6; }
20908         ;;
20909       *) REPLACE_POSIX_SPAWN=1 ;;
20910     esac
20911   fi
20912
20913
20914
20915
20916
20917
20918
20919
20920
20921
20922
20923
20924
20925
20926
20927
20928
20929       ac_fn_c_check_decl "$LINENO" "unsetenv" "ac_cv_have_decl_unsetenv" "$ac_includes_default"
20930 if test "x$ac_cv_have_decl_unsetenv" = xyes; then :
20931   ac_have_decl=1
20932 else
20933   ac_have_decl=0
20934 fi
20935
20936 cat >>confdefs.h <<_ACEOF
20937 #define HAVE_DECL_UNSETENV $ac_have_decl
20938 _ACEOF
20939
20940
20941
20942
20943
20944
20945
20946
20947    if true; then
20948   GL_COND_LIBTOOL_TRUE=
20949   GL_COND_LIBTOOL_FALSE='#'
20950 else
20951   GL_COND_LIBTOOL_TRUE='#'
20952   GL_COND_LIBTOOL_FALSE=
20953 fi
20954
20955   gl_cond_libtool=true
20956   gl_m4_base='m4'
20957
20958
20959
20960
20961
20962
20963
20964
20965
20966   gl_source_base='gnulib/lib'
20967
20968   if test "$ac_cv_header_winsock2_h" = yes; then
20969
20970
20971
20972
20973
20974
20975
20976
20977   gl_LIBOBJS="$gl_LIBOBJS accept.$ac_objext"
20978
20979   fi
20980
20981
20982
20983
20984
20985           GNULIB_ACCEPT=1
20986
20987
20988
20989
20990
20991 $as_echo "#define GNULIB_TEST_ACCEPT 1" >>confdefs.h
20992
20993
20994
20995 LTALLOCA=`echo "$ALLOCA" | sed -e 's/\.[^.]* /.lo /g;s/\.[^.]*$/.lo/'`
20996
20997
20998
20999   if test $ac_cv_func_alloca_works = no; then
21000     :
21001   fi
21002
21003   # Define an additional variable used in the Makefile substitution.
21004   if test $ac_cv_working_alloca_h = yes; then
21005     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca as a compiler built-in" >&5
21006 $as_echo_n "checking for alloca as a compiler built-in... " >&6; }
21007 if ${gl_cv_rpl_alloca+:} false; then :
21008   $as_echo_n "(cached) " >&6
21009 else
21010
21011       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21012 /* end confdefs.h.  */
21013
21014 #if defined __GNUC__ || defined _AIX || defined _MSC_VER
21015         Need own alloca
21016 #endif
21017
21018 _ACEOF
21019 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
21020   $EGREP "Need own alloca" >/dev/null 2>&1; then :
21021   gl_cv_rpl_alloca=yes
21022 else
21023   gl_cv_rpl_alloca=no
21024 fi
21025 rm -f conftest*
21026
21027
21028 fi
21029 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_rpl_alloca" >&5
21030 $as_echo "$gl_cv_rpl_alloca" >&6; }
21031     if test $gl_cv_rpl_alloca = yes; then
21032
21033 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
21034
21035       ALLOCA_H=alloca.h
21036     else
21037                   ALLOCA_H=
21038     fi
21039   else
21040     ALLOCA_H=alloca.h
21041   fi
21042
21043    if test -n "$ALLOCA_H"; then
21044   GL_GENERATE_ALLOCA_H_TRUE=
21045   GL_GENERATE_ALLOCA_H_FALSE='#'
21046 else
21047   GL_GENERATE_ALLOCA_H_TRUE='#'
21048   GL_GENERATE_ALLOCA_H_FALSE=
21049 fi
21050
21051
21052
21053
21054
21055
21056   :
21057
21058
21059
21060
21061
21062   if test $ac_cv_header_arpa_inet_h = yes; then
21063     HAVE_ARPA_INET_H=1
21064   else
21065     HAVE_ARPA_INET_H=0
21066   fi
21067
21068
21069
21070
21071
21072
21073
21074   :
21075
21076
21077
21078
21079
21080
21081
21082
21083      if test $gl_cv_have_include_next = yes; then
21084        gl_cv_next_arpa_inet_h='<'arpa/inet.h'>'
21085      else
21086        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <arpa/inet.h>" >&5
21087 $as_echo_n "checking absolute name of <arpa/inet.h>... " >&6; }
21088 if ${gl_cv_next_arpa_inet_h+:} false; then :
21089   $as_echo_n "(cached) " >&6
21090 else
21091
21092              if test $ac_cv_header_arpa_inet_h = yes; then
21093
21094
21095
21096
21097   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21098 /* end confdefs.h.  */
21099 #include <arpa/inet.h>
21100 _ACEOF
21101                 case "$host_os" in
21102     aix*) gl_absname_cpp="$ac_cpp -C" ;;
21103     *)    gl_absname_cpp="$ac_cpp" ;;
21104   esac
21105
21106   case "$host_os" in
21107     mingw*)
21108                                           gl_dirsep_regex='[/\\]'
21109       ;;
21110     *)
21111       gl_dirsep_regex='\/'
21112       ;;
21113   esac
21114       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
21115   gl_header_literal_regex=`echo 'arpa/inet.h' \
21116                            | sed -e "$gl_make_literal_regex_sed"`
21117   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
21118       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
21119       s|^/[^/]|//&|
21120       p
21121       q
21122     }'
21123
21124         gl_cv_absolute_arpa_inet_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21125   sed -n "$gl_absolute_header_sed"`
21126
21127            gl_header=$gl_cv_absolute_arpa_inet_h
21128            gl_cv_next_arpa_inet_h='"'$gl_header'"'
21129           else
21130                gl_cv_next_arpa_inet_h='<'arpa/inet.h'>'
21131              fi
21132
21133
21134 fi
21135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_arpa_inet_h" >&5
21136 $as_echo "$gl_cv_next_arpa_inet_h" >&6; }
21137      fi
21138      NEXT_ARPA_INET_H=$gl_cv_next_arpa_inet_h
21139
21140      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21141        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21142        gl_next_as_first_directive='<'arpa/inet.h'>'
21143      else
21144        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21145        gl_next_as_first_directive=$gl_cv_next_arpa_inet_h
21146      fi
21147      NEXT_AS_FIRST_DIRECTIVE_ARPA_INET_H=$gl_next_as_first_directive
21148
21149
21150
21151
21152
21153
21154
21155
21156
21157
21158
21159
21160
21161
21162
21163
21164   if test "$ac_cv_header_winsock2_h" = yes; then
21165
21166
21167
21168
21169
21170
21171
21172
21173   gl_LIBOBJS="$gl_LIBOBJS bind.$ac_objext"
21174
21175   fi
21176
21177
21178
21179
21180
21181           GNULIB_BIND=1
21182
21183
21184
21185
21186
21187 $as_echo "#define GNULIB_TEST_BIND 1" >>confdefs.h
21188
21189
21190
21191
21192
21193
21194
21195
21196
21197   :
21198
21199
21200
21201
21202
21203   if test $ac_cv_func_btowc = no; then
21204     HAVE_BTOWC=0
21205   else
21206
21207
21208
21209
21210         { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether btowc(0) is correct" >&5
21211 $as_echo_n "checking whether btowc(0) is correct... " >&6; }
21212 if ${gl_cv_func_btowc_nul+:} false; then :
21213   $as_echo_n "(cached) " >&6
21214 else
21215
21216         if test "$cross_compiling" = yes; then :
21217
21218            case "$host_os" in
21219                       # Guess no on Cygwin.
21220              cygwin*) gl_cv_func_btowc_nul="guessing no" ;;
21221                       # Guess yes otherwise.
21222              *)       gl_cv_func_btowc_nul="guessing yes" ;;
21223            esac
21224
21225 else
21226   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21227 /* end confdefs.h.  */
21228
21229 #include <string.h>
21230 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
21231    <wchar.h>.
21232    BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
21233    included before <wchar.h>.  */
21234 #include <stddef.h>
21235 #include <stdio.h>
21236 #include <time.h>
21237 #include <wchar.h>
21238 int main ()
21239 {
21240   if (btowc ('\0') != 0)
21241     return 1;
21242   return 0;
21243 }
21244 _ACEOF
21245 if ac_fn_c_try_run "$LINENO"; then :
21246   gl_cv_func_btowc_nul=yes
21247 else
21248   gl_cv_func_btowc_nul=no
21249 fi
21250 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21251   conftest.$ac_objext conftest.beam conftest.$ac_ext
21252 fi
21253
21254
21255 fi
21256 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_btowc_nul" >&5
21257 $as_echo "$gl_cv_func_btowc_nul" >&6; }
21258
21259         { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether btowc(EOF) is correct" >&5
21260 $as_echo_n "checking whether btowc(EOF) is correct... " >&6; }
21261 if ${gl_cv_func_btowc_eof+:} false; then :
21262   $as_echo_n "(cached) " >&6
21263 else
21264
21265                         case "$host_os" in
21266                  # Guess no on IRIX.
21267           irix*) gl_cv_func_btowc_eof="guessing no" ;;
21268                  # Guess yes otherwise.
21269           *)     gl_cv_func_btowc_eof="guessing yes" ;;
21270         esac
21271         if test $LOCALE_FR != none; then
21272           if test "$cross_compiling" = yes; then :
21273   :
21274 else
21275   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21276 /* end confdefs.h.  */
21277
21278 #include <locale.h>
21279 #include <string.h>
21280 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
21281    <wchar.h>.
21282    BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
21283    included before <wchar.h>.  */
21284 #include <stddef.h>
21285 #include <stdio.h>
21286 #include <time.h>
21287 #include <wchar.h>
21288 int main ()
21289 {
21290   if (setlocale (LC_ALL, "$LOCALE_FR") != NULL)
21291     {
21292       if (btowc (EOF) != WEOF)
21293         return 1;
21294     }
21295   return 0;
21296 }
21297 _ACEOF
21298 if ac_fn_c_try_run "$LINENO"; then :
21299   gl_cv_func_btowc_eof=yes
21300 else
21301   gl_cv_func_btowc_eof=no
21302 fi
21303 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21304   conftest.$ac_objext conftest.beam conftest.$ac_ext
21305 fi
21306
21307         fi
21308
21309 fi
21310 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_btowc_eof" >&5
21311 $as_echo "$gl_cv_func_btowc_eof" >&6; }
21312
21313     case "$gl_cv_func_btowc_nul" in
21314       *yes) ;;
21315       *) REPLACE_BTOWC=1 ;;
21316     esac
21317     case "$gl_cv_func_btowc_eof" in
21318       *yes) ;;
21319       *) REPLACE_BTOWC=1 ;;
21320     esac
21321   fi
21322
21323   if test $HAVE_BTOWC = 0 || test $REPLACE_BTOWC = 1; then
21324
21325
21326
21327
21328
21329
21330
21331
21332   gl_LIBOBJS="$gl_LIBOBJS btowc.$ac_objext"
21333
21334
21335   :
21336
21337   fi
21338
21339
21340
21341
21342
21343           GNULIB_BTOWC=1
21344
21345
21346
21347
21348
21349 $as_echo "#define GNULIB_TEST_BTOWC 1" >>confdefs.h
21350
21351
21352
21353
21354     for ac_header in byteswap.h
21355 do :
21356   ac_fn_c_check_header_mongrel "$LINENO" "byteswap.h" "ac_cv_header_byteswap_h" "$ac_includes_default"
21357 if test "x$ac_cv_header_byteswap_h" = xyes; then :
21358   cat >>confdefs.h <<_ACEOF
21359 #define HAVE_BYTESWAP_H 1
21360 _ACEOF
21361
21362     BYTESWAP_H=''
21363
21364 else
21365
21366     BYTESWAP_H='byteswap.h'
21367
21368 fi
21369
21370 done
21371
21372
21373    if test -n "$BYTESWAP_H"; then
21374   GL_GENERATE_BYTESWAP_H_TRUE=
21375   GL_GENERATE_BYTESWAP_H_FALSE='#'
21376 else
21377   GL_GENERATE_BYTESWAP_H_TRUE='#'
21378   GL_GENERATE_BYTESWAP_H_FALSE=
21379 fi
21380
21381
21382
21383
21384
21385   if test $gl_cv_func_malloc_posix = yes; then
21386
21387 $as_echo "#define HAVE_CALLOC_POSIX 1" >>confdefs.h
21388
21389   else
21390     REPLACE_CALLOC=1
21391   fi
21392
21393   if test $REPLACE_CALLOC = 1; then
21394
21395
21396
21397
21398
21399
21400
21401
21402   gl_LIBOBJS="$gl_LIBOBJS calloc.$ac_objext"
21403
21404   fi
21405
21406
21407
21408
21409
21410           GNULIB_CALLOC_POSIX=1
21411
21412
21413
21414
21415
21416 $as_echo "#define GNULIB_TEST_CALLOC_POSIX 1" >>confdefs.h
21417
21418
21419
21420
21421
21422
21423   if test $ac_cv_func_canonicalize_file_name = no; then
21424     HAVE_CANONICALIZE_FILE_NAME=0
21425     if test $ac_cv_func_realpath = no; then
21426       HAVE_REALPATH=0
21427     else
21428       case "$gl_cv_func_realpath_works" in
21429         *yes) ;;
21430         *)    REPLACE_REALPATH=1 ;;
21431       esac
21432     fi
21433   else
21434     case "$gl_cv_func_realpath_works" in
21435       *yes)
21436         ;;
21437       *)
21438         REPLACE_CANONICALIZE_FILE_NAME=1
21439         REPLACE_REALPATH=1
21440         ;;
21441     esac
21442   fi
21443
21444   if test $HAVE_CANONICALIZE_FILE_NAME = 0 || test $REPLACE_CANONICALIZE_FILE_NAME = 1; then
21445
21446
21447
21448
21449
21450
21451
21452
21453   gl_LIBOBJS="$gl_LIBOBJS canonicalize-lgpl.$ac_objext"
21454
21455   fi
21456
21457
21458 cat >>confdefs.h <<_ACEOF
21459 #define GNULIB_CANONICALIZE_LGPL 1
21460 _ACEOF
21461
21462
21463
21464
21465
21466
21467
21468           GNULIB_CANONICALIZE_FILE_NAME=1
21469
21470
21471
21472
21473
21474 $as_echo "#define GNULIB_TEST_CANONICALIZE_FILE_NAME 1" >>confdefs.h
21475
21476
21477
21478
21479
21480
21481
21482
21483           GNULIB_REALPATH=1
21484
21485
21486
21487
21488
21489 $as_echo "#define GNULIB_TEST_REALPATH 1" >>confdefs.h
21490
21491
21492
21493
21494   :
21495
21496
21497
21498
21499
21500
21501   if test $HAVE_CHOWN = 0 || test $REPLACE_CHOWN = 1; then
21502
21503
21504
21505
21506
21507
21508
21509
21510   gl_LIBOBJS="$gl_LIBOBJS chown.$ac_objext"
21511
21512   fi
21513   if test $REPLACE_CHOWN = 1 && test $ac_cv_func_fchown = no; then
21514
21515
21516
21517
21518
21519
21520
21521
21522   gl_LIBOBJS="$gl_LIBOBJS fchown-stub.$ac_objext"
21523
21524   fi
21525
21526
21527
21528
21529
21530           GNULIB_CHOWN=1
21531
21532
21533
21534
21535
21536 $as_echo "#define GNULIB_TEST_CHOWN 1" >>confdefs.h
21537
21538
21539
21540
21541
21542
21543   # Solaris 2.5.1 needs -lposix4 to get the clock_gettime function.
21544   # Solaris 7 prefers the library name -lrt to the obsolescent name -lposix4.
21545
21546   # Save and restore LIBS so e.g., -lrt, isn't added to it.  Otherwise, *all*
21547   # programs in the package would end up linked with that potentially-shared
21548   # library, inducing unnecessary run-time overhead.
21549   LIB_CLOCK_GETTIME=
21550
21551   gl_saved_libs=$LIBS
21552     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
21553 $as_echo_n "checking for library containing clock_gettime... " >&6; }
21554 if ${ac_cv_search_clock_gettime+:} false; then :
21555   $as_echo_n "(cached) " >&6
21556 else
21557   ac_func_search_save_LIBS=$LIBS
21558 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21559 /* end confdefs.h.  */
21560
21561 /* Override any GCC internal prototype to avoid an error.
21562    Use char because int might match the return type of a GCC
21563    builtin and then its argument prototype would still apply.  */
21564 #ifdef __cplusplus
21565 extern "C"
21566 #endif
21567 char clock_gettime ();
21568 int
21569 main ()
21570 {
21571 return clock_gettime ();
21572   ;
21573   return 0;
21574 }
21575 _ACEOF
21576 for ac_lib in '' rt posix4; do
21577   if test -z "$ac_lib"; then
21578     ac_res="none required"
21579   else
21580     ac_res=-l$ac_lib
21581     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
21582   fi
21583   if ac_fn_c_try_link "$LINENO"; then :
21584   ac_cv_search_clock_gettime=$ac_res
21585 fi
21586 rm -f core conftest.err conftest.$ac_objext \
21587     conftest$ac_exeext
21588   if ${ac_cv_search_clock_gettime+:} false; then :
21589   break
21590 fi
21591 done
21592 if ${ac_cv_search_clock_gettime+:} false; then :
21593
21594 else
21595   ac_cv_search_clock_gettime=no
21596 fi
21597 rm conftest.$ac_ext
21598 LIBS=$ac_func_search_save_LIBS
21599 fi
21600 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
21601 $as_echo "$ac_cv_search_clock_gettime" >&6; }
21602 ac_res=$ac_cv_search_clock_gettime
21603 if test "$ac_res" != no; then :
21604   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
21605   test "$ac_cv_search_clock_gettime" = "none required" ||
21606                     LIB_CLOCK_GETTIME=$ac_cv_search_clock_gettime
21607 fi
21608
21609     for ac_func in clock_gettime clock_settime
21610 do :
21611   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21612 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
21613 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
21614   cat >>confdefs.h <<_ACEOF
21615 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21616 _ACEOF
21617
21618 fi
21619 done
21620
21621   LIBS=$gl_saved_libs
21622
21623
21624
21625 $as_echo "#define GNULIB_TEST_CLOEXEC 1" >>confdefs.h
21626
21627
21628
21629
21630
21631   if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
21632     REPLACE_CLOSE=1
21633   fi
21634
21635
21636
21637
21638
21639   :
21640
21641
21642
21643
21644
21645   if test $ac_cv_header_sys_socket_h != yes; then
21646                     for ac_header in winsock2.h
21647 do :
21648   ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
21649 if test "x$ac_cv_header_winsock2_h" = xyes; then :
21650   cat >>confdefs.h <<_ACEOF
21651 #define HAVE_WINSOCK2_H 1
21652 _ACEOF
21653
21654 fi
21655
21656 done
21657
21658   fi
21659   if test "$ac_cv_header_winsock2_h" = yes; then
21660     HAVE_WINSOCK2_H=1
21661     UNISTD_H_HAVE_WINSOCK2_H=1
21662     SYS_IOCTL_H_HAVE_WINSOCK2_H=1
21663   else
21664     HAVE_WINSOCK2_H=0
21665   fi
21666
21667
21668     if test $UNISTD_H_HAVE_WINSOCK2_H = 1; then
21669                         REPLACE_CLOSE=1
21670     fi
21671
21672
21673
21674   if test $REPLACE_CLOSE = 1; then
21675
21676
21677
21678
21679
21680
21681
21682
21683   gl_LIBOBJS="$gl_LIBOBJS close.$ac_objext"
21684
21685   fi
21686
21687
21688
21689
21690
21691           GNULIB_CLOSE=1
21692
21693
21694
21695
21696
21697 $as_echo "#define GNULIB_TEST_CLOSE 1" >>confdefs.h
21698
21699
21700
21701
21702           if test "x$datarootdir" = x; then
21703     datarootdir='${datadir}'
21704
21705   fi
21706     if test "x$docdir" = x; then
21707     docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
21708
21709   fi
21710     if test "x$htmldir" = x; then
21711     htmldir='${docdir}'
21712
21713   fi
21714   if test "x$dvidir" = x; then
21715     dvidir='${docdir}'
21716
21717   fi
21718   if test "x$pdfdir" = x; then
21719     pdfdir='${docdir}'
21720
21721   fi
21722   if test "x$psdir" = x; then
21723     psdir='${docdir}'
21724
21725   fi
21726   if test "x$lispdir" = x; then
21727     lispdir='${datarootdir}/emacs/site-lisp'
21728
21729   fi
21730   if test "x$localedir" = x; then
21731     localedir='${datarootdir}/locale'
21732
21733   fi
21734     if test "x$runstatedir" = x; then
21735     runstatedir='${localstatedir}/run'
21736
21737   fi
21738
21739       pkglibexecdir='${libexecdir}/${PACKAGE}'
21740
21741
21742
21743   if test "$ac_cv_header_winsock2_h" = yes; then
21744
21745
21746
21747
21748
21749
21750
21751
21752   gl_LIBOBJS="$gl_LIBOBJS connect.$ac_objext"
21753
21754   fi
21755
21756
21757
21758
21759
21760           GNULIB_CONNECT=1
21761
21762
21763
21764
21765
21766 $as_echo "#define GNULIB_TEST_CONNECT 1" >>confdefs.h
21767
21768
21769
21770
21771
21772
21773
21774
21775
21776
21777
21778
21779
21780
21781
21782 # Check whether --with-openssl was given.
21783 if test "${with_openssl+set}" = set; then :
21784   withval=$with_openssl;
21785 else
21786   with_openssl=$with_openssl_default
21787 fi
21788
21789
21790   if test "xMD5" = xMD5; then
21791     ALG_header=md5.h
21792   else
21793     ALG_header=sha.h
21794   fi
21795
21796
21797   if test "x$with_openssl" != xno; then
21798     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MD5 in -lcrypto" >&5
21799 $as_echo_n "checking for MD5 in -lcrypto... " >&6; }
21800 if ${ac_cv_lib_crypto_MD5+:} false; then :
21801   $as_echo_n "(cached) " >&6
21802 else
21803   ac_check_lib_save_LIBS=$LIBS
21804 LIBS="-lcrypto  $LIBS"
21805 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21806 /* end confdefs.h.  */
21807
21808 /* Override any GCC internal prototype to avoid an error.
21809    Use char because int might match the return type of a GCC
21810    builtin and then its argument prototype would still apply.  */
21811 #ifdef __cplusplus
21812 extern "C"
21813 #endif
21814 char MD5 ();
21815 int
21816 main ()
21817 {
21818 return MD5 ();
21819   ;
21820   return 0;
21821 }
21822 _ACEOF
21823 if ac_fn_c_try_link "$LINENO"; then :
21824   ac_cv_lib_crypto_MD5=yes
21825 else
21826   ac_cv_lib_crypto_MD5=no
21827 fi
21828 rm -f core conftest.err conftest.$ac_objext \
21829     conftest$ac_exeext conftest.$ac_ext
21830 LIBS=$ac_check_lib_save_LIBS
21831 fi
21832 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_MD5" >&5
21833 $as_echo "$ac_cv_lib_crypto_MD5" >&6; }
21834 if test "x$ac_cv_lib_crypto_MD5" = xyes; then :
21835   for ac_header in openssl/$ALG_header
21836 do :
21837   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
21838 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
21839 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
21840   cat >>confdefs.h <<_ACEOF
21841 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
21842 _ACEOF
21843  LIB_CRYPTO=-lcrypto
21844
21845 $as_echo "#define HAVE_OPENSSL_MD5 1" >>confdefs.h
21846
21847 fi
21848
21849 done
21850
21851 fi
21852
21853     if test "x$LIB_CRYPTO" = x; then
21854       if test "x$with_openssl" = xyes; then
21855         as_fn_error $? "openssl development library not found for MD5" "$LINENO" 5
21856       elif test "x$with_openssl" = xoptional; then
21857         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: openssl development library not found for MD5" >&5
21858 $as_echo "$as_me: WARNING: openssl development library not found for MD5" >&2;}
21859       fi
21860     fi
21861   fi
21862
21863
21864
21865
21866
21867
21868
21869
21870
21871
21872
21873 # Check whether --with-openssl was given.
21874 if test "${with_openssl+set}" = set; then :
21875   withval=$with_openssl;
21876 else
21877   with_openssl=$with_openssl_default
21878 fi
21879
21880
21881   if test "xSHA256" = xMD5; then
21882     ALG_header=md5.h
21883   else
21884     ALG_header=sha.h
21885   fi
21886
21887
21888   if test "x$with_openssl" != xno; then
21889     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SHA256 in -lcrypto" >&5
21890 $as_echo_n "checking for SHA256 in -lcrypto... " >&6; }
21891 if ${ac_cv_lib_crypto_SHA256+:} false; then :
21892   $as_echo_n "(cached) " >&6
21893 else
21894   ac_check_lib_save_LIBS=$LIBS
21895 LIBS="-lcrypto  $LIBS"
21896 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21897 /* end confdefs.h.  */
21898
21899 /* Override any GCC internal prototype to avoid an error.
21900    Use char because int might match the return type of a GCC
21901    builtin and then its argument prototype would still apply.  */
21902 #ifdef __cplusplus
21903 extern "C"
21904 #endif
21905 char SHA256 ();
21906 int
21907 main ()
21908 {
21909 return SHA256 ();
21910   ;
21911   return 0;
21912 }
21913 _ACEOF
21914 if ac_fn_c_try_link "$LINENO"; then :
21915   ac_cv_lib_crypto_SHA256=yes
21916 else
21917   ac_cv_lib_crypto_SHA256=no
21918 fi
21919 rm -f core conftest.err conftest.$ac_objext \
21920     conftest$ac_exeext conftest.$ac_ext
21921 LIBS=$ac_check_lib_save_LIBS
21922 fi
21923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_SHA256" >&5
21924 $as_echo "$ac_cv_lib_crypto_SHA256" >&6; }
21925 if test "x$ac_cv_lib_crypto_SHA256" = xyes; then :
21926   for ac_header in openssl/$ALG_header
21927 do :
21928   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
21929 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
21930 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
21931   cat >>confdefs.h <<_ACEOF
21932 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
21933 _ACEOF
21934  LIB_CRYPTO=-lcrypto
21935
21936 $as_echo "#define HAVE_OPENSSL_SHA256 1" >>confdefs.h
21937
21938 fi
21939
21940 done
21941
21942 fi
21943
21944     if test "x$LIB_CRYPTO" = x; then
21945       if test "x$with_openssl" = xyes; then
21946         as_fn_error $? "openssl development library not found for SHA256" "$LINENO" 5
21947       elif test "x$with_openssl" = xoptional; then
21948         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: openssl development library not found for SHA256" >&5
21949 $as_echo "$as_me: WARNING: openssl development library not found for SHA256" >&2;}
21950       fi
21951     fi
21952   fi
21953
21954
21955
21956
21957
21958
21959
21960
21961   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether // is distinct from /" >&5
21962 $as_echo_n "checking whether // is distinct from /... " >&6; }
21963 if ${gl_cv_double_slash_root+:} false; then :
21964   $as_echo_n "(cached) " >&6
21965 else
21966    if test x"$cross_compiling" = xyes ; then
21967         # When cross-compiling, there is no way to tell whether // is special
21968         # short of a list of hosts.  However, the only known hosts to date
21969         # that have a distinct // are Apollo DomainOS (too old to port to),
21970         # Cygwin, and z/OS.  If anyone knows of another system for which // has
21971         # special semantics and is distinct from /, please report it to
21972         # <bug-gnulib@gnu.org>.
21973         case $host in
21974           *-cygwin | i370-ibm-openedition)
21975             gl_cv_double_slash_root=yes ;;
21976           *)
21977             # Be optimistic and assume that / and // are the same when we
21978             # don't know.
21979             gl_cv_double_slash_root='unknown, assuming no' ;;
21980         esac
21981       else
21982         set x `ls -di / // 2>/dev/null`
21983         if test "$2" = "$4" && wc //dev/null >/dev/null 2>&1; then
21984           gl_cv_double_slash_root=no
21985         else
21986           gl_cv_double_slash_root=yes
21987         fi
21988       fi
21989 fi
21990 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_double_slash_root" >&5
21991 $as_echo "$gl_cv_double_slash_root" >&6; }
21992   if test "$gl_cv_double_slash_root" = yes; then
21993
21994 $as_echo "#define DOUBLE_SLASH_IS_DISTINCT_ROOT 1" >>confdefs.h
21995
21996   fi
21997
21998
21999
22000
22001
22002
22003 $as_echo "#define HAVE_DUP2 1" >>confdefs.h
22004
22005
22006   if test $HAVE_DUP2 = 1; then
22007     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dup2 works" >&5
22008 $as_echo_n "checking whether dup2 works... " >&6; }
22009 if ${gl_cv_func_dup2_works+:} false; then :
22010   $as_echo_n "(cached) " >&6
22011 else
22012   if test "$cross_compiling" = yes; then :
22013   case "$host_os" in
22014            mingw*) # on this platform, dup2 always returns 0 for success
22015              gl_cv_func_dup2_works="guessing no" ;;
22016            cygwin*) # on cygwin 1.5.x, dup2(1,1) returns 0
22017              gl_cv_func_dup2_works="guessing no" ;;
22018            linux*) # On linux between 2008-07-27 and 2009-05-11, dup2 of a
22019                    # closed fd may yield -EBADF instead of -1 / errno=EBADF.
22020              gl_cv_func_dup2_works="guessing no" ;;
22021            freebsd*) # on FreeBSD 6.1, dup2(1,1000000) gives EMFILE, not EBADF.
22022              gl_cv_func_dup2_works="guessing no" ;;
22023            haiku*) # on Haiku alpha 2, dup2(1, 1) resets FD_CLOEXEC.
22024              gl_cv_func_dup2_works="guessing no" ;;
22025            *) gl_cv_func_dup2_works="guessing yes" ;;
22026          esac
22027 else
22028   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22029 /* end confdefs.h.  */
22030
22031          #include <unistd.h>
22032 #include <fcntl.h>
22033 #include <errno.h>
22034 int
22035 main ()
22036 {
22037 int result = 0;
22038 #ifdef FD_CLOEXEC
22039             if (fcntl (1, F_SETFD, FD_CLOEXEC) == -1)
22040               result |= 1;
22041 #endif
22042             if (dup2 (1, 1) == 0)
22043               result |= 2;
22044 #ifdef FD_CLOEXEC
22045             if (fcntl (1, F_GETFD) != FD_CLOEXEC)
22046               result |= 4;
22047 #endif
22048             close (0);
22049             if (dup2 (0, 0) != -1)
22050               result |= 8;
22051             /* Many gnulib modules require POSIX conformance of EBADF.  */
22052             if (dup2 (2, 1000000) == -1 && errno != EBADF)
22053               result |= 16;
22054             /* Flush out some cygwin core dumps.  */
22055             if (dup2 (2, -1) != -1 || errno != EBADF)
22056               result |= 32;
22057             dup2 (2, 255);
22058             dup2 (2, 256);
22059             return result;
22060
22061   ;
22062   return 0;
22063 }
22064
22065 _ACEOF
22066 if ac_fn_c_try_run "$LINENO"; then :
22067   gl_cv_func_dup2_works=yes
22068 else
22069   gl_cv_func_dup2_works=no
22070 fi
22071 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22072   conftest.$ac_objext conftest.beam conftest.$ac_ext
22073 fi
22074
22075
22076 fi
22077 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dup2_works" >&5
22078 $as_echo "$gl_cv_func_dup2_works" >&6; }
22079     case "$gl_cv_func_dup2_works" in
22080       *yes) ;;
22081       *)
22082         REPLACE_DUP2=1
22083         for ac_func in setdtablesize
22084 do :
22085   ac_fn_c_check_func "$LINENO" "setdtablesize" "ac_cv_func_setdtablesize"
22086 if test "x$ac_cv_func_setdtablesize" = xyes; then :
22087   cat >>confdefs.h <<_ACEOF
22088 #define HAVE_SETDTABLESIZE 1
22089 _ACEOF
22090
22091 fi
22092 done
22093
22094         ;;
22095     esac
22096   fi
22097
22098
22099   if test $HAVE_DUP2 = 0 || test $REPLACE_DUP2 = 1; then
22100
22101
22102
22103
22104
22105
22106
22107
22108   gl_LIBOBJS="$gl_LIBOBJS dup2.$ac_objext"
22109
22110
22111   fi
22112
22113
22114
22115
22116
22117           GNULIB_DUP2=1
22118
22119
22120
22121
22122
22123 $as_echo "#define GNULIB_TEST_DUP2 1" >>confdefs.h
22124
22125
22126
22127
22128
22129
22130
22131
22132
22133           GNULIB_ENVIRON=1
22134
22135
22136
22137
22138
22139 $as_echo "#define GNULIB_TEST_ENVIRON 1" >>confdefs.h
22140
22141
22142
22143
22144
22145
22146   :
22147
22148
22149
22150
22151
22152
22153   LIB_EXECINFO=''
22154   EXECINFO_H='execinfo.h'
22155
22156   if test $ac_cv_header_execinfo_h = yes; then
22157     gl_saved_libs=$LIBS
22158       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing backtrace_symbols_fd" >&5
22159 $as_echo_n "checking for library containing backtrace_symbols_fd... " >&6; }
22160 if ${ac_cv_search_backtrace_symbols_fd+:} false; then :
22161   $as_echo_n "(cached) " >&6
22162 else
22163   ac_func_search_save_LIBS=$LIBS
22164 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22165 /* end confdefs.h.  */
22166
22167 /* Override any GCC internal prototype to avoid an error.
22168    Use char because int might match the return type of a GCC
22169    builtin and then its argument prototype would still apply.  */
22170 #ifdef __cplusplus
22171 extern "C"
22172 #endif
22173 char backtrace_symbols_fd ();
22174 int
22175 main ()
22176 {
22177 return backtrace_symbols_fd ();
22178   ;
22179   return 0;
22180 }
22181 _ACEOF
22182 for ac_lib in '' execinfo; do
22183   if test -z "$ac_lib"; then
22184     ac_res="none required"
22185   else
22186     ac_res=-l$ac_lib
22187     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
22188   fi
22189   if ac_fn_c_try_link "$LINENO"; then :
22190   ac_cv_search_backtrace_symbols_fd=$ac_res
22191 fi
22192 rm -f core conftest.err conftest.$ac_objext \
22193     conftest$ac_exeext
22194   if ${ac_cv_search_backtrace_symbols_fd+:} false; then :
22195   break
22196 fi
22197 done
22198 if ${ac_cv_search_backtrace_symbols_fd+:} false; then :
22199
22200 else
22201   ac_cv_search_backtrace_symbols_fd=no
22202 fi
22203 rm conftest.$ac_ext
22204 LIBS=$ac_func_search_save_LIBS
22205 fi
22206 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_backtrace_symbols_fd" >&5
22207 $as_echo "$ac_cv_search_backtrace_symbols_fd" >&6; }
22208 ac_res=$ac_cv_search_backtrace_symbols_fd
22209 if test "$ac_res" != no; then :
22210   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
22211   test "$ac_cv_search_backtrace_symbols_fd" = "none required" ||
22212          LIB_EXECINFO=$ac_cv_search_backtrace_symbols_fd
22213 fi
22214
22215     LIBS=$gl_saved_libs
22216     test "$ac_cv_search_backtrace_symbols_fd" = no || EXECINFO_H=''
22217   fi
22218
22219   if test -n "$EXECINFO_H"; then
22220
22221
22222
22223
22224
22225
22226
22227
22228   gl_LIBOBJS="$gl_LIBOBJS execinfo.$ac_objext"
22229
22230   fi
22231
22232
22233
22234    if test -n "$EXECINFO_H"; then
22235   GL_GENERATE_EXECINFO_H_TRUE=
22236   GL_GENERATE_EXECINFO_H_FALSE='#'
22237 else
22238   GL_GENERATE_EXECINFO_H_TRUE='#'
22239   GL_GENERATE_EXECINFO_H_FALSE=
22240 fi
22241
22242
22243
22244
22245
22246
22247
22248
22249   :
22250
22251
22252
22253
22254
22255   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fflush works on input streams" >&5
22256 $as_echo_n "checking whether fflush works on input streams... " >&6; }
22257 if ${gl_cv_func_fflush_stdin+:} false; then :
22258   $as_echo_n "(cached) " >&6
22259 else
22260   echo hello world > conftest.txt
22261      if test "$cross_compiling" = yes; then :
22262   gl_cv_func_fflush_stdin=cross
22263 else
22264   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22265 /* end confdefs.h.  */
22266
22267 #include <stdio.h>
22268 #if HAVE_UNISTD_H
22269 # include <unistd.h>
22270 #else /* on Windows with MSVC */
22271 # include <io.h>
22272 #endif
22273
22274 int
22275 main ()
22276 {
22277 FILE *f = fopen ("conftest.txt", "r");
22278          char buffer[10];
22279          int fd;
22280          int c;
22281          if (f == NULL)
22282            return 1;
22283          fd = fileno (f);
22284          if (fd < 0 || fread (buffer, 1, 5, f) != 5)
22285            return 2;
22286          /* For deterministic results, ensure f read a bigger buffer.  */
22287          if (lseek (fd, 0, SEEK_CUR) == 5)
22288            return 3;
22289          /* POSIX requires fflush-fseek to set file offset of fd.  This fails
22290             on BSD systems and on mingw.  */
22291          if (fflush (f) != 0 || fseek (f, 0, SEEK_CUR) != 0)
22292            return 4;
22293          if (lseek (fd, 0, SEEK_CUR) != 5)
22294            return 5;
22295          /* Verify behaviour of fflush after ungetc. See
22296             <http://www.opengroup.org/austin/aardvark/latest/xshbug3.txt>  */
22297          /* Verify behaviour of fflush after a backup ungetc.  This fails on
22298             mingw.  */
22299          c = fgetc (f);
22300          ungetc (c, f);
22301          fflush (f);
22302          if (fgetc (f) != c)
22303            return 6;
22304          /* Verify behaviour of fflush after a non-backup ungetc.  This fails
22305             on glibc 2.8 and on BSD systems.  */
22306          c = fgetc (f);
22307          ungetc ('@', f);
22308          fflush (f);
22309          if (fgetc (f) != c)
22310            return 7;
22311          return 0;
22312
22313   ;
22314   return 0;
22315 }
22316 _ACEOF
22317 if ac_fn_c_try_run "$LINENO"; then :
22318   gl_cv_func_fflush_stdin=yes
22319 else
22320   gl_cv_func_fflush_stdin=no
22321 fi
22322 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22323   conftest.$ac_objext conftest.beam conftest.$ac_ext
22324 fi
22325
22326      rm conftest.txt
22327
22328 fi
22329 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fflush_stdin" >&5
22330 $as_echo "$gl_cv_func_fflush_stdin" >&6; }
22331   case $gl_cv_func_fflush_stdin in
22332     yes) gl_func_fflush_stdin=1 ;;
22333     no)  gl_func_fflush_stdin=0 ;;
22334     *)   gl_func_fflush_stdin='(-1)' ;;
22335   esac
22336
22337 cat >>confdefs.h <<_ACEOF
22338 #define FUNC_FFLUSH_STDIN $gl_func_fflush_stdin
22339 _ACEOF
22340
22341
22342   if test $gl_cv_func_fflush_stdin != yes; then
22343     REPLACE_FCLOSE=1
22344   fi
22345
22346
22347   if test $REPLACE_CLOSE = 1; then
22348     REPLACE_FCLOSE=1
22349   fi
22350
22351   if test $REPLACE_FCLOSE = 1; then
22352
22353
22354
22355
22356
22357
22358
22359
22360   gl_LIBOBJS="$gl_LIBOBJS fclose.$ac_objext"
22361
22362   fi
22363
22364
22365
22366
22367
22368           GNULIB_FCLOSE=1
22369
22370
22371
22372
22373
22374 $as_echo "#define GNULIB_TEST_FCLOSE 1" >>confdefs.h
22375
22376
22377
22378
22379
22380
22381
22382
22383   :
22384
22385
22386
22387
22388
22389   if test $ac_cv_func_fcntl = no; then
22390
22391
22392
22393   :
22394
22395
22396
22397
22398
22399   if test $ac_cv_func_fcntl = no; then
22400     HAVE_FCNTL=0
22401   else
22402     REPLACE_FCNTL=1
22403   fi
22404
22405   else
22406             { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fcntl handles F_DUPFD correctly" >&5
22407 $as_echo_n "checking whether fcntl handles F_DUPFD correctly... " >&6; }
22408 if ${gl_cv_func_fcntl_f_dupfd_works+:} false; then :
22409   $as_echo_n "(cached) " >&6
22410 else
22411   if test "$cross_compiling" = yes; then :
22412   # Guess that it works on glibc systems
22413           case $host_os in #((
22414             *-gnu*) gl_cv_func_fcntl_f_dupfd_works="guessing yes";;
22415             *)      gl_cv_func_fcntl_f_dupfd_works="guessing no";;
22416           esac
22417 else
22418   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22419 /* end confdefs.h.  */
22420
22421 #include <fcntl.h>
22422 #include <errno.h>
22423
22424 int
22425 main ()
22426 {
22427 int result = 0;
22428       if (fcntl (0, F_DUPFD, -1) != -1) result |= 1;
22429       if (errno != EINVAL) result |= 2;
22430       return result;
22431
22432   ;
22433   return 0;
22434 }
22435 _ACEOF
22436 if ac_fn_c_try_run "$LINENO"; then :
22437   gl_cv_func_fcntl_f_dupfd_works=yes
22438 else
22439   gl_cv_func_fcntl_f_dupfd_works=no
22440 fi
22441 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22442   conftest.$ac_objext conftest.beam conftest.$ac_ext
22443 fi
22444
22445 fi
22446 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fcntl_f_dupfd_works" >&5
22447 $as_echo "$gl_cv_func_fcntl_f_dupfd_works" >&6; }
22448     case $gl_cv_func_fcntl_f_dupfd_works in
22449       *yes) ;;
22450       *)
22451
22452
22453   :
22454
22455
22456
22457
22458
22459   if test $ac_cv_func_fcntl = no; then
22460     HAVE_FCNTL=0
22461   else
22462     REPLACE_FCNTL=1
22463   fi
22464
22465
22466 $as_echo "#define FCNTL_DUPFD_BUGGY 1" >>confdefs.h
22467  ;;
22468     esac
22469
22470         { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fcntl understands F_DUPFD_CLOEXEC" >&5
22471 $as_echo_n "checking whether fcntl understands F_DUPFD_CLOEXEC... " >&6; }
22472 if ${gl_cv_func_fcntl_f_dupfd_cloexec+:} false; then :
22473   $as_echo_n "(cached) " >&6
22474 else
22475   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22476 /* end confdefs.h.  */
22477
22478 #include <fcntl.h>
22479 #ifndef F_DUPFD_CLOEXEC
22480 choke me
22481 #endif
22482
22483 int
22484 main ()
22485 {
22486
22487   ;
22488   return 0;
22489 }
22490 _ACEOF
22491 if ac_fn_c_try_compile "$LINENO"; then :
22492   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22493 /* end confdefs.h.  */
22494
22495 #ifdef __linux__
22496 /* The Linux kernel only added F_DUPFD_CLOEXEC in 2.6.24, so we always replace
22497    it to support the semantics on older kernels that failed with EINVAL.  */
22498 choke me
22499 #endif
22500
22501 int
22502 main ()
22503 {
22504
22505   ;
22506   return 0;
22507 }
22508 _ACEOF
22509 if ac_fn_c_try_compile "$LINENO"; then :
22510   gl_cv_func_fcntl_f_dupfd_cloexec=yes
22511 else
22512   gl_cv_func_fcntl_f_dupfd_cloexec="needs runtime check"
22513 fi
22514 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22515 else
22516   gl_cv_func_fcntl_f_dupfd_cloexec=no
22517 fi
22518 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22519 fi
22520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fcntl_f_dupfd_cloexec" >&5
22521 $as_echo "$gl_cv_func_fcntl_f_dupfd_cloexec" >&6; }
22522     if test "$gl_cv_func_fcntl_f_dupfd_cloexec" != yes; then
22523
22524
22525
22526   :
22527
22528
22529
22530
22531
22532   if test $ac_cv_func_fcntl = no; then
22533     HAVE_FCNTL=0
22534   else
22535     REPLACE_FCNTL=1
22536   fi
22537
22538           fi
22539   fi
22540
22541
22542   if test $HAVE_FCNTL = 0 || test $REPLACE_FCNTL = 1; then
22543
22544
22545
22546
22547
22548
22549
22550
22551   gl_LIBOBJS="$gl_LIBOBJS fcntl.$ac_objext"
22552
22553   fi
22554
22555
22556
22557
22558
22559           GNULIB_FCNTL=1
22560
22561
22562
22563
22564
22565 $as_echo "#define GNULIB_TEST_FCNTL 1" >>confdefs.h
22566
22567
22568
22569
22570
22571
22572
22573
22574
22575
22576
22577
22578
22579
22580      if test $gl_cv_have_include_next = yes; then
22581        gl_cv_next_fcntl_h='<'fcntl.h'>'
22582      else
22583        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <fcntl.h>" >&5
22584 $as_echo_n "checking absolute name of <fcntl.h>... " >&6; }
22585 if ${gl_cv_next_fcntl_h+:} false; then :
22586   $as_echo_n "(cached) " >&6
22587 else
22588
22589
22590
22591   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22592 /* end confdefs.h.  */
22593 #include <fcntl.h>
22594 _ACEOF
22595                 case "$host_os" in
22596     aix*) gl_absname_cpp="$ac_cpp -C" ;;
22597     *)    gl_absname_cpp="$ac_cpp" ;;
22598   esac
22599
22600   case "$host_os" in
22601     mingw*)
22602                                           gl_dirsep_regex='[/\\]'
22603       ;;
22604     *)
22605       gl_dirsep_regex='\/'
22606       ;;
22607   esac
22608       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22609   gl_header_literal_regex=`echo 'fcntl.h' \
22610                            | sed -e "$gl_make_literal_regex_sed"`
22611   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22612       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22613       s|^/[^/]|//&|
22614       p
22615       q
22616     }'
22617
22618         gl_cv_absolute_fcntl_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22619   sed -n "$gl_absolute_header_sed"`
22620
22621            gl_header=$gl_cv_absolute_fcntl_h
22622            gl_cv_next_fcntl_h='"'$gl_header'"'
22623
22624
22625 fi
22626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_fcntl_h" >&5
22627 $as_echo "$gl_cv_next_fcntl_h" >&6; }
22628      fi
22629      NEXT_FCNTL_H=$gl_cv_next_fcntl_h
22630
22631      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22632        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22633        gl_next_as_first_directive='<'fcntl.h'>'
22634      else
22635        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22636        gl_next_as_first_directive=$gl_cv_next_fcntl_h
22637      fi
22638      NEXT_AS_FIRST_DIRECTIVE_FCNTL_H=$gl_next_as_first_directive
22639
22640
22641
22642
22643
22644
22645
22646
22647
22648
22649
22650
22651
22652
22653
22654   :
22655
22656
22657
22658
22659
22660   LIB_FDATASYNC=
22661
22662
22663   if test $ac_cv_have_decl_fdatasync = no; then
22664     HAVE_DECL_FDATASYNC=0
22665         for ac_func in fdatasync
22666 do :
22667   ac_fn_c_check_func "$LINENO" "fdatasync" "ac_cv_func_fdatasync"
22668 if test "x$ac_cv_func_fdatasync" = xyes; then :
22669   cat >>confdefs.h <<_ACEOF
22670 #define HAVE_FDATASYNC 1
22671 _ACEOF
22672
22673 fi
22674 done
22675
22676     if test $ac_cv_func_fdatasync = no; then
22677       HAVE_FDATASYNC=0
22678     fi
22679   else
22680             gl_saved_libs=$LIBS
22681     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing fdatasync" >&5
22682 $as_echo_n "checking for library containing fdatasync... " >&6; }
22683 if ${ac_cv_search_fdatasync+:} false; then :
22684   $as_echo_n "(cached) " >&6
22685 else
22686   ac_func_search_save_LIBS=$LIBS
22687 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22688 /* end confdefs.h.  */
22689
22690 /* Override any GCC internal prototype to avoid an error.
22691    Use char because int might match the return type of a GCC
22692    builtin and then its argument prototype would still apply.  */
22693 #ifdef __cplusplus
22694 extern "C"
22695 #endif
22696 char fdatasync ();
22697 int
22698 main ()
22699 {
22700 return fdatasync ();
22701   ;
22702   return 0;
22703 }
22704 _ACEOF
22705 for ac_lib in '' rt posix4; do
22706   if test -z "$ac_lib"; then
22707     ac_res="none required"
22708   else
22709     ac_res=-l$ac_lib
22710     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
22711   fi
22712   if ac_fn_c_try_link "$LINENO"; then :
22713   ac_cv_search_fdatasync=$ac_res
22714 fi
22715 rm -f core conftest.err conftest.$ac_objext \
22716     conftest$ac_exeext
22717   if ${ac_cv_search_fdatasync+:} false; then :
22718   break
22719 fi
22720 done
22721 if ${ac_cv_search_fdatasync+:} false; then :
22722
22723 else
22724   ac_cv_search_fdatasync=no
22725 fi
22726 rm conftest.$ac_ext
22727 LIBS=$ac_func_search_save_LIBS
22728 fi
22729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_fdatasync" >&5
22730 $as_echo "$ac_cv_search_fdatasync" >&6; }
22731 ac_res=$ac_cv_search_fdatasync
22732 if test "$ac_res" != no; then :
22733   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
22734   test "$ac_cv_search_fdatasync" = "none required" ||
22735                     LIB_FDATASYNC=$ac_cv_search_fdatasync
22736 fi
22737
22738     LIBS=$gl_saved_libs
22739   fi
22740
22741   if test $HAVE_FDATASYNC = 0; then
22742
22743
22744
22745
22746
22747
22748
22749
22750   gl_LIBOBJS="$gl_LIBOBJS fdatasync.$ac_objext"
22751
22752   fi
22753
22754
22755
22756
22757
22758           GNULIB_FDATASYNC=1
22759
22760
22761
22762
22763
22764 $as_echo "#define GNULIB_TEST_FDATASYNC 1" >>confdefs.h
22765
22766
22767
22768
22769
22770
22771
22772   :
22773
22774
22775
22776
22777
22778   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fflush works on input streams" >&5
22779 $as_echo_n "checking whether fflush works on input streams... " >&6; }
22780 if ${gl_cv_func_fflush_stdin+:} false; then :
22781   $as_echo_n "(cached) " >&6
22782 else
22783   echo hello world > conftest.txt
22784      if test "$cross_compiling" = yes; then :
22785   gl_cv_func_fflush_stdin=cross
22786 else
22787   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22788 /* end confdefs.h.  */
22789
22790 #include <stdio.h>
22791 #if HAVE_UNISTD_H
22792 # include <unistd.h>
22793 #else /* on Windows with MSVC */
22794 # include <io.h>
22795 #endif
22796
22797 int
22798 main ()
22799 {
22800 FILE *f = fopen ("conftest.txt", "r");
22801          char buffer[10];
22802          int fd;
22803          int c;
22804          if (f == NULL)
22805            return 1;
22806          fd = fileno (f);
22807          if (fd < 0 || fread (buffer, 1, 5, f) != 5)
22808            return 2;
22809          /* For deterministic results, ensure f read a bigger buffer.  */
22810          if (lseek (fd, 0, SEEK_CUR) == 5)
22811            return 3;
22812          /* POSIX requires fflush-fseek to set file offset of fd.  This fails
22813             on BSD systems and on mingw.  */
22814          if (fflush (f) != 0 || fseek (f, 0, SEEK_CUR) != 0)
22815            return 4;
22816          if (lseek (fd, 0, SEEK_CUR) != 5)
22817            return 5;
22818          /* Verify behaviour of fflush after ungetc. See
22819             <http://www.opengroup.org/austin/aardvark/latest/xshbug3.txt>  */
22820          /* Verify behaviour of fflush after a backup ungetc.  This fails on
22821             mingw.  */
22822          c = fgetc (f);
22823          ungetc (c, f);
22824          fflush (f);
22825          if (fgetc (f) != c)
22826            return 6;
22827          /* Verify behaviour of fflush after a non-backup ungetc.  This fails
22828             on glibc 2.8 and on BSD systems.  */
22829          c = fgetc (f);
22830          ungetc ('@', f);
22831          fflush (f);
22832          if (fgetc (f) != c)
22833            return 7;
22834          return 0;
22835
22836   ;
22837   return 0;
22838 }
22839 _ACEOF
22840 if ac_fn_c_try_run "$LINENO"; then :
22841   gl_cv_func_fflush_stdin=yes
22842 else
22843   gl_cv_func_fflush_stdin=no
22844 fi
22845 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22846   conftest.$ac_objext conftest.beam conftest.$ac_ext
22847 fi
22848
22849      rm conftest.txt
22850
22851 fi
22852 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fflush_stdin" >&5
22853 $as_echo "$gl_cv_func_fflush_stdin" >&6; }
22854   case $gl_cv_func_fflush_stdin in
22855     yes) gl_func_fflush_stdin=1 ;;
22856     no)  gl_func_fflush_stdin=0 ;;
22857     *)   gl_func_fflush_stdin='(-1)' ;;
22858   esac
22859
22860 cat >>confdefs.h <<_ACEOF
22861 #define FUNC_FFLUSH_STDIN $gl_func_fflush_stdin
22862 _ACEOF
22863
22864
22865   if test $gl_cv_func_fflush_stdin != yes; then
22866     REPLACE_FFLUSH=1
22867   fi
22868
22869   if test $REPLACE_FFLUSH = 1; then
22870
22871
22872
22873
22874
22875
22876
22877
22878   gl_LIBOBJS="$gl_LIBOBJS fflush.$ac_objext"
22879
22880     :
22881   fi
22882
22883
22884 cat >>confdefs.h <<_ACEOF
22885 #define GNULIB_FFLUSH 1
22886 _ACEOF
22887
22888
22889
22890
22891
22892
22893
22894           GNULIB_FFLUSH=1
22895
22896
22897
22898
22899
22900 $as_echo "#define GNULIB_TEST_FFLUSH 1" >>confdefs.h
22901
22902
22903
22904
22905
22906
22907   :
22908
22909
22910
22911
22912
22913   if test $ac_cv_func_ffs = no; then
22914     HAVE_FFS=0
22915   fi
22916
22917   if test $HAVE_FFS = 0; then
22918
22919
22920
22921
22922
22923
22924
22925
22926   gl_LIBOBJS="$gl_LIBOBJS ffs.$ac_objext"
22927
22928   fi
22929
22930
22931
22932
22933
22934           GNULIB_FFS=1
22935
22936
22937
22938
22939
22940
22941
22942
22943
22944
22945   :
22946
22947
22948
22949
22950
22951   if test $ac_cv_func_ffsl = no; then
22952     HAVE_FFSL=0
22953   fi
22954
22955   if test $HAVE_FFSL = 0; then
22956
22957
22958
22959
22960
22961
22962
22963
22964   gl_LIBOBJS="$gl_LIBOBJS ffsl.$ac_objext"
22965
22966   fi
22967
22968
22969
22970
22971
22972           GNULIB_FFSL=1
22973
22974
22975
22976
22977
22978 $as_echo "#define GNULIB_TEST_FFSL 1" >>confdefs.h
22979
22980
22981
22982
22983
22984
22985   FLOAT_H=
22986   REPLACE_FLOAT_LDBL=0
22987   case "$host_os" in
22988     aix* | beos* | openbsd* | mirbsd* | irix*)
22989       FLOAT_H=float.h
22990       ;;
22991     freebsd*)
22992       case "$host_cpu" in
22993         i[34567]86 )
22994           FLOAT_H=float.h
22995           ;;
22996         x86_64 )
22997           # On x86_64 systems, the C compiler may still be generating
22998           # 32-bit code.
22999           cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23000 /* end confdefs.h.  */
23001 #if defined __LP64__ || defined __x86_64__ || defined __amd64__
23002              yes
23003              #endif
23004 _ACEOF
23005 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
23006   $EGREP "yes" >/dev/null 2>&1; then :
23007
23008 else
23009   FLOAT_H=float.h
23010 fi
23011 rm -f conftest*
23012
23013           ;;
23014       esac
23015       ;;
23016     linux*)
23017       case "$host_cpu" in
23018         powerpc*)
23019           FLOAT_H=float.h
23020           ;;
23021       esac
23022       ;;
23023   esac
23024   case "$host_os" in
23025     aix* | freebsd* | linux*)
23026       if test -n "$FLOAT_H"; then
23027         REPLACE_FLOAT_LDBL=1
23028       fi
23029       ;;
23030   esac
23031
23032     REPLACE_ITOLD=0
23033   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether conversion from 'int' to 'long double' works" >&5
23034 $as_echo_n "checking whether conversion from 'int' to 'long double' works... " >&6; }
23035 if ${gl_cv_func_itold_works+:} false; then :
23036   $as_echo_n "(cached) " >&6
23037 else
23038
23039       if test "$cross_compiling" = yes; then :
23040   case "$host" in
23041            sparc*-*-linux*)
23042              cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23043 /* end confdefs.h.  */
23044 #if defined __LP64__ || defined __arch64__
23045                 yes
23046                 #endif
23047 _ACEOF
23048 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
23049   $EGREP "yes" >/dev/null 2>&1; then :
23050   gl_cv_func_itold_works="guessing no"
23051 else
23052   gl_cv_func_itold_works="guessing yes"
23053 fi
23054 rm -f conftest*
23055
23056              ;;
23057            *) gl_cv_func_itold_works="guessing yes" ;;
23058          esac
23059
23060 else
23061   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23062 /* end confdefs.h.  */
23063
23064 int i = -1;
23065 volatile long double ld;
23066 int main ()
23067 {
23068   ld += i * 1.0L;
23069   if (ld > 0)
23070     return 1;
23071   return 0;
23072 }
23073 _ACEOF
23074 if ac_fn_c_try_run "$LINENO"; then :
23075   gl_cv_func_itold_works=yes
23076 else
23077   gl_cv_func_itold_works=no
23078 fi
23079 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23080   conftest.$ac_objext conftest.beam conftest.$ac_ext
23081 fi
23082
23083
23084 fi
23085 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_itold_works" >&5
23086 $as_echo "$gl_cv_func_itold_works" >&6; }
23087   case "$gl_cv_func_itold_works" in
23088     *no)
23089       REPLACE_ITOLD=1
23090                   FLOAT_H=float.h
23091       ;;
23092   esac
23093
23094   if test -n "$FLOAT_H"; then
23095
23096
23097
23098
23099
23100
23101
23102
23103      if test $gl_cv_have_include_next = yes; then
23104        gl_cv_next_float_h='<'float.h'>'
23105      else
23106        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <float.h>" >&5
23107 $as_echo_n "checking absolute name of <float.h>... " >&6; }
23108 if ${gl_cv_next_float_h+:} false; then :
23109   $as_echo_n "(cached) " >&6
23110 else
23111
23112
23113
23114   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23115 /* end confdefs.h.  */
23116 #include <float.h>
23117 _ACEOF
23118                 case "$host_os" in
23119     aix*) gl_absname_cpp="$ac_cpp -C" ;;
23120     *)    gl_absname_cpp="$ac_cpp" ;;
23121   esac
23122
23123   case "$host_os" in
23124     mingw*)
23125                                           gl_dirsep_regex='[/\\]'
23126       ;;
23127     *)
23128       gl_dirsep_regex='\/'
23129       ;;
23130   esac
23131       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23132   gl_header_literal_regex=`echo 'float.h' \
23133                            | sed -e "$gl_make_literal_regex_sed"`
23134   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23135       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23136       s|^/[^/]|//&|
23137       p
23138       q
23139     }'
23140
23141         gl_cv_absolute_float_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23142   sed -n "$gl_absolute_header_sed"`
23143
23144            gl_header=$gl_cv_absolute_float_h
23145            gl_cv_next_float_h='"'$gl_header'"'
23146
23147
23148 fi
23149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_float_h" >&5
23150 $as_echo "$gl_cv_next_float_h" >&6; }
23151      fi
23152      NEXT_FLOAT_H=$gl_cv_next_float_h
23153
23154      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23155        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23156        gl_next_as_first_directive='<'float.h'>'
23157      else
23158        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23159        gl_next_as_first_directive=$gl_cv_next_float_h
23160      fi
23161      NEXT_AS_FIRST_DIRECTIVE_FLOAT_H=$gl_next_as_first_directive
23162
23163
23164
23165
23166   fi
23167
23168    if test -n "$FLOAT_H"; then
23169   GL_GENERATE_FLOAT_H_TRUE=
23170   GL_GENERATE_FLOAT_H_FALSE='#'
23171 else
23172   GL_GENERATE_FLOAT_H_TRUE='#'
23173   GL_GENERATE_FLOAT_H_FALSE=
23174 fi
23175
23176
23177
23178   if test $REPLACE_FLOAT_LDBL = 1; then
23179
23180
23181
23182
23183
23184
23185
23186
23187   gl_LIBOBJS="$gl_LIBOBJS float.$ac_objext"
23188
23189   fi
23190   if test $REPLACE_ITOLD = 1; then
23191
23192
23193
23194
23195
23196
23197
23198
23199   gl_LIBOBJS="$gl_LIBOBJS itold.$ac_objext"
23200
23201   fi
23202
23203
23204
23205
23206
23207   FNMATCH_H=
23208   gl_fnmatch_required_lowercase=`
23209     echo $gl_fnmatch_required | LC_ALL=C tr '[A-Z]' '[a-z]'
23210   `
23211   gl_fnmatch_cache_var="gl_cv_func_fnmatch_${gl_fnmatch_required_lowercase}"
23212   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working $gl_fnmatch_required fnmatch" >&5
23213 $as_echo_n "checking for working $gl_fnmatch_required fnmatch... " >&6; }
23214 if eval \${$gl_fnmatch_cache_var+:} false; then :
23215   $as_echo_n "(cached) " >&6
23216 else
23217                            if test $gl_fnmatch_required = GNU; then
23218        gl_fnmatch_gnu_start=
23219        gl_fnmatch_gnu_end=
23220      else
23221        gl_fnmatch_gnu_start='#if 0'
23222        gl_fnmatch_gnu_end='#endif'
23223      fi
23224      if test "$cross_compiling" = yes; then :
23225   eval "$gl_fnmatch_cache_var=\"guessing no\""
23226 else
23227   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23228 /* end confdefs.h.  */
23229 #include <fnmatch.h>
23230             static int
23231             y (char const *pattern, char const *string, int flags)
23232             {
23233               return fnmatch (pattern, string, flags) == 0;
23234             }
23235             static int
23236             n (char const *pattern, char const *string, int flags)
23237             {
23238               return fnmatch (pattern, string, flags) == FNM_NOMATCH;
23239             }
23240
23241 int
23242 main ()
23243 {
23244 char const *Apat = 'A' < '\\\\' ? "[A-\\\\\\\\]" : "[\\\\\\\\-A]";
23245             char const *apat = 'a' < '\\\\' ? "[a-\\\\\\\\]" : "[\\\\\\\\-a]";
23246             static char const A_1[] = { 'A' - 1, 0 };
23247             static char const A01[] = { 'A' + 1, 0 };
23248             static char const a_1[] = { 'a' - 1, 0 };
23249             static char const a01[] = { 'a' + 1, 0 };
23250             static char const bs_1[] = { '\\\\' - 1, 0 };
23251             static char const bs01[] = { '\\\\' + 1, 0 };
23252             int result = 0;
23253             if (!n ("a*", "", 0))
23254               return 1;
23255             if (!y ("a*", "abc", 0))
23256               return 1;
23257             if (!y ("[/b", "[/b", 0)) /*"]]"*/ /* glibc Bugzilla bug 12378 */
23258               return 1;
23259             if (!n ("d*/*1", "d/s/1", FNM_PATHNAME))
23260               return 2;
23261             if (!y ("a\\\\bc", "abc", 0))
23262               return 3;
23263             if (!n ("a\\\\bc", "abc", FNM_NOESCAPE))
23264               return 3;
23265             if (!y ("*x", ".x", 0))
23266               return 4;
23267             if (!n ("*x", ".x", FNM_PERIOD))
23268               return 4;
23269             if (!y (Apat, "\\\\", 0))
23270               return 5;
23271             if (!y (Apat, "A", 0))
23272               return 5;
23273             if (!y (apat, "\\\\", 0))
23274               return 5;
23275             if (!y (apat, "a", 0))
23276               return 5;
23277             if (!(n (Apat, A_1, 0) == ('A' < '\\\\')))
23278               return 5;
23279             if (!(n (apat, a_1, 0) == ('a' < '\\\\')))
23280               return 5;
23281             if (!(y (Apat, A01, 0) == ('A' < '\\\\')))
23282               return 5;
23283             if (!(y (apat, a01, 0) == ('a' < '\\\\')))
23284               return 5;
23285             if (!(y (Apat, bs_1, 0) == ('A' < '\\\\')))
23286               return 5;
23287             if (!(y (apat, bs_1, 0) == ('a' < '\\\\')))
23288               return 5;
23289             if (!(n (Apat, bs01, 0) == ('A' < '\\\\')))
23290               return 5;
23291             if (!(n (apat, bs01, 0) == ('a' < '\\\\')))
23292               return 5;
23293             $gl_fnmatch_gnu_start
23294             if (!y ("xxXX", "xXxX", FNM_CASEFOLD))
23295               result |= 8;
23296             if (!y ("a++(x|yy)b", "a+xyyyyxb", FNM_EXTMATCH))
23297               result |= 16;
23298             if (!n ("d*/*1", "d/s/1", FNM_FILE_NAME))
23299               result |= 32;
23300             if (!y ("*", "x", FNM_FILE_NAME | FNM_LEADING_DIR))
23301               result |= 64;
23302             if (!y ("x*", "x/y/z", FNM_FILE_NAME | FNM_LEADING_DIR))
23303               result |= 64;
23304             if (!y ("*c*", "c/x", FNM_FILE_NAME | FNM_LEADING_DIR))
23305               result |= 64;
23306             $gl_fnmatch_gnu_end
23307             return result;
23308
23309   ;
23310   return 0;
23311 }
23312 _ACEOF
23313 if ac_fn_c_try_run "$LINENO"; then :
23314   eval "$gl_fnmatch_cache_var=yes"
23315 else
23316   eval "$gl_fnmatch_cache_var=no"
23317 fi
23318 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23319   conftest.$ac_objext conftest.beam conftest.$ac_ext
23320 fi
23321
23322
23323 fi
23324 eval ac_res=\$$gl_fnmatch_cache_var
23325                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
23326 $as_echo "$ac_res" >&6; }
23327   eval "gl_fnmatch_result=\"\$$gl_fnmatch_cache_var\""
23328   if test "$gl_fnmatch_result" = yes; then
23329             rm -f "$gl_source_base/fnmatch.h"
23330   else
23331     FNMATCH_H=fnmatch.h
23332   fi
23333
23334    if test -n "$FNMATCH_H"; then
23335   GL_GENERATE_FNMATCH_H_TRUE=
23336   GL_GENERATE_FNMATCH_H_FALSE='#'
23337 else
23338   GL_GENERATE_FNMATCH_H_TRUE='#'
23339   GL_GENERATE_FNMATCH_H_FALSE=
23340 fi
23341
23342
23343   if test -n "$FNMATCH_H"; then
23344
23345
23346
23347
23348
23349
23350
23351
23352   gl_LIBOBJS="$gl_LIBOBJS fnmatch.$ac_objext"
23353
23354
23355
23356 cat >>confdefs.h <<_ACEOF
23357 #define fnmatch ${gl_fnmatch_required_lowercase}_fnmatch
23358 _ACEOF
23359
23360
23361   ac_fn_c_check_decl "$LINENO" "isblank" "ac_cv_have_decl_isblank" "#include <ctype.h>
23362 "
23363 if test "x$ac_cv_have_decl_isblank" = xyes; then :
23364   ac_have_decl=1
23365 else
23366   ac_have_decl=0
23367 fi
23368
23369 cat >>confdefs.h <<_ACEOF
23370 #define HAVE_DECL_ISBLANK $ac_have_decl
23371 _ACEOF
23372
23373
23374   :
23375
23376
23377
23378
23379
23380
23381
23382
23383
23384
23385
23386
23387
23388
23389
23390
23391
23392
23393
23394
23395
23396
23397
23398
23399
23400
23401
23402   :
23403
23404
23405
23406
23407
23408
23409   fi
23410
23411
23412
23413   :
23414
23415
23416
23417
23418
23419
23420   :
23421
23422
23423
23424
23425
23426   ac_fn_c_check_decl "$LINENO" "fpurge" "ac_cv_have_decl_fpurge" "#include <stdio.h>
23427 "
23428 if test "x$ac_cv_have_decl_fpurge" = xyes; then :
23429   ac_have_decl=1
23430 else
23431   ac_have_decl=0
23432 fi
23433
23434 cat >>confdefs.h <<_ACEOF
23435 #define HAVE_DECL_FPURGE $ac_have_decl
23436 _ACEOF
23437
23438   if test "x$ac_cv_func_fpurge" = xyes; then
23439     HAVE_FPURGE=1
23440     # Detect BSD bug.  Only cygwin 1.7 is known to be immune.
23441     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fpurge works" >&5
23442 $as_echo_n "checking whether fpurge works... " >&6; }
23443 if ${gl_cv_func_fpurge_works+:} false; then :
23444   $as_echo_n "(cached) " >&6
23445 else
23446   if test "$cross_compiling" = yes; then :
23447   gl_cv_func_fpurge_works='guessing no'
23448 else
23449   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23450 /* end confdefs.h.  */
23451 #include <stdio.h>
23452
23453 int
23454 main ()
23455 {
23456 FILE *f = fopen ("conftest.txt", "w+");
23457         if (!f) return 1;
23458         if (fputc ('a', f) != 'a') return 2;
23459         rewind (f);
23460         if (fgetc (f) != 'a') return 3;
23461         if (fgetc (f) != EOF) return 4;
23462         if (fpurge (f) != 0) return 5;
23463         if (putc ('b', f) != 'b') return 6;
23464         if (fclose (f) != 0) return 7;
23465         if ((f = fopen ("conftest.txt", "r")) == NULL) return 8;
23466         if (fgetc (f) != 'a') return 9;
23467         if (fgetc (f) != 'b') return 10;
23468         if (fgetc (f) != EOF) return 11;
23469         if (fclose (f) != 0) return 12;
23470         if (remove ("conftest.txt") != 0) return 13;
23471         return 0;
23472   ;
23473   return 0;
23474 }
23475 _ACEOF
23476 if ac_fn_c_try_run "$LINENO"; then :
23477   gl_cv_func_fpurge_works=yes
23478 else
23479   gl_cv_func_fpurge_works=no
23480 fi
23481 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23482   conftest.$ac_objext conftest.beam conftest.$ac_ext
23483 fi
23484
23485 fi
23486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fpurge_works" >&5
23487 $as_echo "$gl_cv_func_fpurge_works" >&6; }
23488     if test "x$gl_cv_func_fpurge_works" != xyes; then
23489       REPLACE_FPURGE=1
23490     fi
23491   else
23492     HAVE_FPURGE=0
23493   fi
23494   if test "x$ac_cv_have_decl_fpurge" = xno; then
23495     HAVE_DECL_FPURGE=0
23496   fi
23497
23498   if test $HAVE_FPURGE = 0 || test $REPLACE_FPURGE = 1; then
23499
23500
23501
23502
23503
23504
23505
23506
23507   gl_LIBOBJS="$gl_LIBOBJS fpurge.$ac_objext"
23508
23509   fi
23510
23511
23512
23513
23514
23515           GNULIB_FPURGE=1
23516
23517
23518
23519
23520
23521 $as_echo "#define GNULIB_TEST_FPURGE 1" >>confdefs.h
23522
23523
23524
23525
23526
23527   :
23528
23529
23530
23531
23532
23533
23534
23535
23536
23537     if test $HAVE_FSEEKO = 0 || test $REPLACE_FSEEKO = 1; then
23538     REPLACE_FSEEK=1
23539   fi
23540
23541   if test $REPLACE_FSEEK = 1; then
23542
23543
23544
23545
23546
23547
23548
23549
23550   gl_LIBOBJS="$gl_LIBOBJS fseek.$ac_objext"
23551
23552   fi
23553
23554
23555
23556
23557
23558           GNULIB_FSEEK=1
23559
23560
23561
23562
23563
23564 $as_echo "#define GNULIB_TEST_FSEEK 1" >>confdefs.h
23565
23566
23567
23568
23569
23570
23571
23572
23573
23574
23575
23576   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fseeko" >&5
23577 $as_echo_n "checking for fseeko... " >&6; }
23578 if ${gl_cv_func_fseeko+:} false; then :
23579   $as_echo_n "(cached) " >&6
23580 else
23581
23582       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23583 /* end confdefs.h.  */
23584 #include <stdio.h>
23585
23586 int
23587 main ()
23588 {
23589 fseeko (stdin, 0, 0);
23590   ;
23591   return 0;
23592 }
23593 _ACEOF
23594 if ac_fn_c_try_link "$LINENO"; then :
23595   gl_cv_func_fseeko=yes
23596 else
23597   gl_cv_func_fseeko=no
23598 fi
23599 rm -f core conftest.err conftest.$ac_objext \
23600     conftest$ac_exeext conftest.$ac_ext
23601
23602 fi
23603 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fseeko" >&5
23604 $as_echo "$gl_cv_func_fseeko" >&6; }
23605
23606
23607   :
23608
23609
23610
23611
23612
23613   if test $ac_cv_have_decl_fseeko = no; then
23614     HAVE_DECL_FSEEKO=0
23615   fi
23616
23617   if test $gl_cv_func_fseeko = no; then
23618     HAVE_FSEEKO=0
23619   else
23620     if test $WINDOWS_64_BIT_OFF_T = 1; then
23621       REPLACE_FSEEKO=1
23622     fi
23623     if test $gl_cv_var_stdin_large_offset = no; then
23624       REPLACE_FSEEKO=1
23625     fi
23626
23627
23628
23629   :
23630
23631
23632
23633
23634
23635   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fflush works on input streams" >&5
23636 $as_echo_n "checking whether fflush works on input streams... " >&6; }
23637 if ${gl_cv_func_fflush_stdin+:} false; then :
23638   $as_echo_n "(cached) " >&6
23639 else
23640   echo hello world > conftest.txt
23641      if test "$cross_compiling" = yes; then :
23642   gl_cv_func_fflush_stdin=cross
23643 else
23644   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23645 /* end confdefs.h.  */
23646
23647 #include <stdio.h>
23648 #if HAVE_UNISTD_H
23649 # include <unistd.h>
23650 #else /* on Windows with MSVC */
23651 # include <io.h>
23652 #endif
23653
23654 int
23655 main ()
23656 {
23657 FILE *f = fopen ("conftest.txt", "r");
23658          char buffer[10];
23659          int fd;
23660          int c;
23661          if (f == NULL)
23662            return 1;
23663          fd = fileno (f);
23664          if (fd < 0 || fread (buffer, 1, 5, f) != 5)
23665            return 2;
23666          /* For deterministic results, ensure f read a bigger buffer.  */
23667          if (lseek (fd, 0, SEEK_CUR) == 5)
23668            return 3;
23669          /* POSIX requires fflush-fseek to set file offset of fd.  This fails
23670             on BSD systems and on mingw.  */
23671          if (fflush (f) != 0 || fseek (f, 0, SEEK_CUR) != 0)
23672            return 4;
23673          if (lseek (fd, 0, SEEK_CUR) != 5)
23674            return 5;
23675          /* Verify behaviour of fflush after ungetc. See
23676             <http://www.opengroup.org/austin/aardvark/latest/xshbug3.txt>  */
23677          /* Verify behaviour of fflush after a backup ungetc.  This fails on
23678             mingw.  */
23679          c = fgetc (f);
23680          ungetc (c, f);
23681          fflush (f);
23682          if (fgetc (f) != c)
23683            return 6;
23684          /* Verify behaviour of fflush after a non-backup ungetc.  This fails
23685             on glibc 2.8 and on BSD systems.  */
23686          c = fgetc (f);
23687          ungetc ('@', f);
23688          fflush (f);
23689          if (fgetc (f) != c)
23690            return 7;
23691          return 0;
23692
23693   ;
23694   return 0;
23695 }
23696 _ACEOF
23697 if ac_fn_c_try_run "$LINENO"; then :
23698   gl_cv_func_fflush_stdin=yes
23699 else
23700   gl_cv_func_fflush_stdin=no
23701 fi
23702 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23703   conftest.$ac_objext conftest.beam conftest.$ac_ext
23704 fi
23705
23706      rm conftest.txt
23707
23708 fi
23709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fflush_stdin" >&5
23710 $as_echo "$gl_cv_func_fflush_stdin" >&6; }
23711   case $gl_cv_func_fflush_stdin in
23712     yes) gl_func_fflush_stdin=1 ;;
23713     no)  gl_func_fflush_stdin=0 ;;
23714     *)   gl_func_fflush_stdin='(-1)' ;;
23715   esac
23716
23717 cat >>confdefs.h <<_ACEOF
23718 #define FUNC_FFLUSH_STDIN $gl_func_fflush_stdin
23719 _ACEOF
23720
23721
23722       if test $gl_cv_func_fflush_stdin != yes; then
23723         REPLACE_FSEEKO=1
23724       fi
23725
23726   fi
23727
23728   if test $HAVE_FSEEKO = 0 || test $REPLACE_FSEEKO = 1; then
23729
23730
23731
23732
23733
23734
23735
23736
23737   gl_LIBOBJS="$gl_LIBOBJS fseeko.$ac_objext"
23738
23739
23740       for ac_func in _fseeki64
23741 do :
23742   ac_fn_c_check_func "$LINENO" "_fseeki64" "ac_cv_func__fseeki64"
23743 if test "x$ac_cv_func__fseeki64" = xyes; then :
23744   cat >>confdefs.h <<_ACEOF
23745 #define HAVE__FSEEKI64 1
23746 _ACEOF
23747
23748 fi
23749 done
23750
23751
23752   fi
23753
23754
23755
23756
23757
23758           GNULIB_FSEEKO=1
23759
23760
23761
23762
23763
23764 $as_echo "#define GNULIB_TEST_FSEEKO 1" >>confdefs.h
23765
23766
23767
23768
23769
23770
23771
23772   if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
23773     REPLACE_FSTAT=1
23774   fi
23775
23776
23777   if test $WINDOWS_64_BIT_ST_SIZE = 1; then
23778     REPLACE_FSTAT=1
23779   fi
23780
23781
23782
23783   if test $REPLACE_FSTAT = 1; then
23784
23785
23786
23787
23788
23789
23790
23791
23792   gl_LIBOBJS="$gl_LIBOBJS fstat.$ac_objext"
23793
23794     :
23795   fi
23796
23797
23798
23799
23800
23801           GNULIB_FSTAT=1
23802
23803
23804
23805
23806
23807 $as_echo "#define GNULIB_TEST_FSTAT 1" >>confdefs.h
23808
23809
23810
23811
23812
23813
23814   :
23815
23816
23817
23818
23819
23820   if test $ac_cv_func_fsync = no; then
23821     HAVE_FSYNC=0
23822   fi
23823
23824   if test $HAVE_FSYNC = 0; then
23825
23826
23827
23828
23829
23830
23831
23832
23833   gl_LIBOBJS="$gl_LIBOBJS fsync.$ac_objext"
23834
23835     :
23836   fi
23837
23838
23839
23840
23841
23842           GNULIB_FSYNC=1
23843
23844
23845
23846
23847
23848 $as_echo "#define GNULIB_TEST_FSYNC 1" >>confdefs.h
23849
23850
23851
23852
23853
23854
23855     if test $HAVE_FTELLO = 0 || test $REPLACE_FTELLO = 1; then
23856     REPLACE_FTELL=1
23857   fi
23858
23859   if test $REPLACE_FTELL = 1; then
23860
23861
23862
23863
23864
23865
23866
23867
23868   gl_LIBOBJS="$gl_LIBOBJS ftell.$ac_objext"
23869
23870   fi
23871
23872
23873
23874
23875
23876           GNULIB_FTELL=1
23877
23878
23879
23880
23881
23882 $as_echo "#define GNULIB_TEST_FTELL 1" >>confdefs.h
23883
23884
23885
23886
23887
23888
23889
23890
23891
23892
23893
23894
23895   :
23896
23897
23898
23899
23900
23901   if test $ac_cv_have_decl_ftello = no; then
23902     HAVE_DECL_FTELLO=0
23903   fi
23904
23905   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ftello" >&5
23906 $as_echo_n "checking for ftello... " >&6; }
23907 if ${gl_cv_func_ftello+:} false; then :
23908   $as_echo_n "(cached) " >&6
23909 else
23910
23911       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23912 /* end confdefs.h.  */
23913 #include <stdio.h>
23914 int
23915 main ()
23916 {
23917 ftello (stdin);
23918   ;
23919   return 0;
23920 }
23921 _ACEOF
23922 if ac_fn_c_try_link "$LINENO"; then :
23923   gl_cv_func_ftello=yes
23924 else
23925   gl_cv_func_ftello=no
23926 fi
23927 rm -f core conftest.err conftest.$ac_objext \
23928     conftest$ac_exeext conftest.$ac_ext
23929
23930 fi
23931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_ftello" >&5
23932 $as_echo "$gl_cv_func_ftello" >&6; }
23933   if test $gl_cv_func_ftello = no; then
23934     HAVE_FTELLO=0
23935   else
23936     if test $WINDOWS_64_BIT_OFF_T = 1; then
23937       REPLACE_FTELLO=1
23938     fi
23939     if test $gl_cv_var_stdin_large_offset = no; then
23940       REPLACE_FTELLO=1
23941     fi
23942     if test $REPLACE_FTELLO = 0; then
23943
23944       { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ftello works" >&5
23945 $as_echo_n "checking whether ftello works... " >&6; }
23946 if ${gl_cv_func_ftello_works+:} false; then :
23947   $as_echo_n "(cached) " >&6
23948 else
23949
23950                               case "$host_os" in
23951                       # Guess no on Solaris.
23952             solaris*) gl_cv_func_ftello_works="guessing no" ;;
23953                       # Guess yes otherwise.
23954             *)        gl_cv_func_ftello_works="guessing yes" ;;
23955           esac
23956           if test "$cross_compiling" = yes; then :
23957   :
23958 else
23959   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23960 /* end confdefs.h.  */
23961
23962 #include <stdio.h>
23963 #include <stdlib.h>
23964 #include <string.h>
23965 #define TESTFILE "conftest.tmp"
23966 int
23967 main (void)
23968 {
23969   FILE *fp;
23970
23971   /* Create a file with some contents.  */
23972   fp = fopen (TESTFILE, "w");
23973   if (fp == NULL)
23974     return 70;
23975   if (fwrite ("foogarsh", 1, 8, fp) < 8)
23976     return 71;
23977   if (fclose (fp))
23978     return 72;
23979
23980   /* The file's contents is now "foogarsh".  */
23981
23982   /* Try writing after reading to EOF.  */
23983   fp = fopen (TESTFILE, "r+");
23984   if (fp == NULL)
23985     return 73;
23986   if (fseek (fp, -1, SEEK_END))
23987     return 74;
23988   if (!(getc (fp) == 'h'))
23989     return 1;
23990   if (!(getc (fp) == EOF))
23991     return 2;
23992   if (!(ftell (fp) == 8))
23993     return 3;
23994   if (!(ftell (fp) == 8))
23995     return 4;
23996   if (!(putc ('!', fp) == '!'))
23997     return 5;
23998   if (!(ftell (fp) == 9))
23999     return 6;
24000   if (!(fclose (fp) == 0))
24001     return 7;
24002   fp = fopen (TESTFILE, "r");
24003   if (fp == NULL)
24004     return 75;
24005   {
24006     char buf[10];
24007     if (!(fread (buf, 1, 10, fp) == 9))
24008       return 10;
24009     if (!(memcmp (buf, "foogarsh!", 9) == 0))
24010       return 11;
24011   }
24012   if (!(fclose (fp) == 0))
24013     return 12;
24014
24015   /* The file's contents is now "foogarsh!".  */
24016
24017   return 0;
24018 }
24019 _ACEOF
24020 if ac_fn_c_try_run "$LINENO"; then :
24021   gl_cv_func_ftello_works=yes
24022 else
24023   gl_cv_func_ftello_works=no
24024 fi
24025 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24026   conftest.$ac_objext conftest.beam conftest.$ac_ext
24027 fi
24028
24029
24030 fi
24031 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_ftello_works" >&5
24032 $as_echo "$gl_cv_func_ftello_works" >&6; }
24033       case "$gl_cv_func_ftello_works" in
24034         *yes) ;;
24035         *)
24036           REPLACE_FTELLO=1
24037
24038 $as_echo "#define FTELLO_BROKEN_AFTER_SWITCHING_FROM_READ_TO_WRITE 1" >>confdefs.h
24039
24040           ;;
24041       esac
24042     fi
24043   fi
24044
24045   if test $HAVE_FTELLO = 0 || test $REPLACE_FTELLO = 1; then
24046
24047
24048
24049
24050
24051
24052
24053
24054   gl_LIBOBJS="$gl_LIBOBJS ftello.$ac_objext"
24055
24056
24057       for ac_func in _ftelli64
24058 do :
24059   ac_fn_c_check_func "$LINENO" "_ftelli64" "ac_cv_func__ftelli64"
24060 if test "x$ac_cv_func__ftelli64" = xyes; then :
24061   cat >>confdefs.h <<_ACEOF
24062 #define HAVE__FTELLI64 1
24063 _ACEOF
24064
24065 fi
24066 done
24067
24068
24069   fi
24070
24071
24072
24073
24074
24075           GNULIB_FTELLO=1
24076
24077
24078
24079
24080
24081 $as_echo "#define GNULIB_TEST_FTELLO 1" >>confdefs.h
24082
24083
24084
24085
24086   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether __func__ is available" >&5
24087 $as_echo_n "checking whether __func__ is available... " >&6; }
24088 if ${gl_cv_var_func+:} false; then :
24089   $as_echo_n "(cached) " >&6
24090 else
24091   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24092 /* end confdefs.h.  */
24093
24094 int
24095 main ()
24096 {
24097 const char *str = __func__;
24098   ;
24099   return 0;
24100 }
24101 _ACEOF
24102 if ac_fn_c_try_compile "$LINENO"; then :
24103   gl_cv_var_func=yes
24104 else
24105   gl_cv_var_func=no
24106 fi
24107 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24108 fi
24109 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_var_func" >&5
24110 $as_echo "$gl_cv_var_func" >&6; }
24111   if test "$gl_cv_var_func" != yes; then
24112
24113 $as_echo "#define __func__ \"<unknown function>\"" >>confdefs.h
24114
24115   fi
24116
24117
24118       { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to do getaddrinfo, freeaddrinfo and getnameinfo" >&5
24119 $as_echo "$as_me: checking how to do getaddrinfo, freeaddrinfo and getnameinfo" >&6;}
24120   GETADDRINFO_LIB=
24121   gai_saved_LIBS="$LIBS"
24122
24123               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing getaddrinfo" >&5
24124 $as_echo_n "checking for library containing getaddrinfo... " >&6; }
24125 if ${ac_cv_search_getaddrinfo+:} false; then :
24126   $as_echo_n "(cached) " >&6
24127 else
24128   ac_func_search_save_LIBS=$LIBS
24129 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24130 /* end confdefs.h.  */
24131
24132 /* Override any GCC internal prototype to avoid an error.
24133    Use char because int might match the return type of a GCC
24134    builtin and then its argument prototype would still apply.  */
24135 #ifdef __cplusplus
24136 extern "C"
24137 #endif
24138 char getaddrinfo ();
24139 int
24140 main ()
24141 {
24142 return getaddrinfo ();
24143   ;
24144   return 0;
24145 }
24146 _ACEOF
24147 for ac_lib in '' socket network net; do
24148   if test -z "$ac_lib"; then
24149     ac_res="none required"
24150   else
24151     ac_res=-l$ac_lib
24152     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
24153   fi
24154   if ac_fn_c_try_link "$LINENO"; then :
24155   ac_cv_search_getaddrinfo=$ac_res
24156 fi
24157 rm -f core conftest.err conftest.$ac_objext \
24158     conftest$ac_exeext
24159   if ${ac_cv_search_getaddrinfo+:} false; then :
24160   break
24161 fi
24162 done
24163 if ${ac_cv_search_getaddrinfo+:} false; then :
24164
24165 else
24166   ac_cv_search_getaddrinfo=no
24167 fi
24168 rm conftest.$ac_ext
24169 LIBS=$ac_func_search_save_LIBS
24170 fi
24171 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_getaddrinfo" >&5
24172 $as_echo "$ac_cv_search_getaddrinfo" >&6; }
24173 ac_res=$ac_cv_search_getaddrinfo
24174 if test "$ac_res" != no; then :
24175   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
24176   if test "$ac_cv_search_getaddrinfo" != "none required"; then
24177        GETADDRINFO_LIB="$ac_cv_search_getaddrinfo"
24178      fi
24179 fi
24180
24181   LIBS="$gai_saved_LIBS $GETADDRINFO_LIB"
24182
24183   HAVE_GETADDRINFO=1
24184   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getaddrinfo" >&5
24185 $as_echo_n "checking for getaddrinfo... " >&6; }
24186 if ${gl_cv_func_getaddrinfo+:} false; then :
24187   $as_echo_n "(cached) " >&6
24188 else
24189
24190     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24191 /* end confdefs.h.  */
24192
24193 #include <sys/types.h>
24194 #ifdef HAVE_SYS_SOCKET_H
24195 #include <sys/socket.h>
24196 #endif
24197 #ifdef HAVE_NETDB_H
24198 #include <netdb.h>
24199 #endif
24200 #include <stddef.h>
24201
24202 int
24203 main ()
24204 {
24205 getaddrinfo("", "", NULL, NULL);
24206   ;
24207   return 0;
24208 }
24209 _ACEOF
24210 if ac_fn_c_try_link "$LINENO"; then :
24211   gl_cv_func_getaddrinfo=yes
24212 else
24213   gl_cv_func_getaddrinfo=no
24214 fi
24215 rm -f core conftest.err conftest.$ac_objext \
24216     conftest$ac_exeext conftest.$ac_ext
24217 fi
24218 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getaddrinfo" >&5
24219 $as_echo "$gl_cv_func_getaddrinfo" >&6; }
24220   if test $gl_cv_func_getaddrinfo = no; then
24221     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getaddrinfo in ws2tcpip.h and -lws2_32" >&5
24222 $as_echo_n "checking for getaddrinfo in ws2tcpip.h and -lws2_32... " >&6; }
24223 if ${gl_cv_w32_getaddrinfo+:} false; then :
24224   $as_echo_n "(cached) " >&6
24225 else
24226
24227       gl_cv_w32_getaddrinfo=no
24228       am_save_LIBS="$LIBS"
24229       LIBS="$LIBS -lws2_32"
24230       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24231 /* end confdefs.h.  */
24232
24233 #ifdef HAVE_WS2TCPIP_H
24234 #include <ws2tcpip.h>
24235 #endif
24236 #include <stddef.h>
24237
24238 int
24239 main ()
24240 {
24241 getaddrinfo(NULL, NULL, NULL, NULL);
24242   ;
24243   return 0;
24244 }
24245 _ACEOF
24246 if ac_fn_c_try_link "$LINENO"; then :
24247   gl_cv_w32_getaddrinfo=yes
24248 fi
24249 rm -f core conftest.err conftest.$ac_objext \
24250     conftest$ac_exeext conftest.$ac_ext
24251       LIBS="$am_save_LIBS"
24252
24253 fi
24254 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_w32_getaddrinfo" >&5
24255 $as_echo "$gl_cv_w32_getaddrinfo" >&6; }
24256     if test "$gl_cv_w32_getaddrinfo" = "yes"; then
24257       GETADDRINFO_LIB="-lws2_32"
24258       LIBS="$gai_saved_LIBS $GETADDRINFO_LIB"
24259     else
24260       HAVE_GETADDRINFO=0
24261     fi
24262   fi
24263
24264   # We can't use AC_REPLACE_FUNCS here because gai_strerror may be an
24265   # inline function declared in ws2tcpip.h, so we need to get that
24266   # header included somehow.
24267   ac_fn_c_check_decl "$LINENO" "gai_strerror" "ac_cv_have_decl_gai_strerror" "
24268 #include <sys/types.h>
24269 #ifdef HAVE_SYS_SOCKET_H
24270 #include <sys/socket.h>
24271 #endif
24272 #ifdef HAVE_NETDB_H
24273 #include <netdb.h>
24274 #endif
24275 #ifdef HAVE_WS2TCPIP_H
24276 #include <ws2tcpip.h>
24277 #endif
24278 #include <stddef.h>
24279
24280 "
24281 if test "x$ac_cv_have_decl_gai_strerror" = xyes; then :
24282   ac_have_decl=1
24283 else
24284   ac_have_decl=0
24285 fi
24286
24287 cat >>confdefs.h <<_ACEOF
24288 #define HAVE_DECL_GAI_STRERROR $ac_have_decl
24289 _ACEOF
24290
24291   if test $ac_cv_have_decl_gai_strerror = yes; then
24292     ac_fn_c_check_decl "$LINENO" "gai_strerrorA" "ac_cv_have_decl_gai_strerrorA" "
24293 #include <sys/types.h>
24294 #ifdef HAVE_SYS_SOCKET_H
24295 #include <sys/socket.h>
24296 #endif
24297 #ifdef HAVE_NETDB_H
24298 #include <netdb.h>
24299 #endif
24300 #ifdef HAVE_WS2TCPIP_H
24301 #include <ws2tcpip.h>
24302 #endif
24303 #include <stddef.h>
24304
24305 "
24306 if test "x$ac_cv_have_decl_gai_strerrorA" = xyes; then :
24307   ac_have_decl=1
24308 else
24309   ac_have_decl=0
24310 fi
24311
24312 cat >>confdefs.h <<_ACEOF
24313 #define HAVE_DECL_GAI_STRERRORA $ac_have_decl
24314 _ACEOF
24315
24316         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gai_strerror with POSIX signature" >&5
24317 $as_echo_n "checking for gai_strerror with POSIX signature... " >&6; }
24318 if ${gl_cv_func_gai_strerror_posix_signature+:} false; then :
24319   $as_echo_n "(cached) " >&6
24320 else
24321
24322       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24323 /* end confdefs.h.  */
24324
24325 #include <sys/types.h>
24326 #ifdef HAVE_SYS_SOCKET_H
24327 #include <sys/socket.h>
24328 #endif
24329 #ifdef HAVE_NETDB_H
24330 #include <netdb.h>
24331 #endif
24332 #ifdef HAVE_WS2TCPIP_H
24333 #include <ws2tcpip.h>
24334 #endif
24335 #include <stddef.h>
24336 extern
24337 #ifdef __cplusplus
24338 "C"
24339 #endif
24340 const char *gai_strerror(int);
24341 _ACEOF
24342 if ac_fn_c_try_compile "$LINENO"; then :
24343   gl_cv_func_gai_strerror_posix_signature=yes
24344 else
24345   gl_cv_func_gai_strerror_posix_signature=no
24346 fi
24347 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24348 fi
24349 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gai_strerror_posix_signature" >&5
24350 $as_echo "$gl_cv_func_gai_strerror_posix_signature" >&6; }
24351     if test $gl_cv_func_gai_strerror_posix_signature = no; then
24352       REPLACE_GAI_STRERROR=1
24353     fi
24354   fi
24355
24356   LIBS="$gai_saved_LIBS"
24357
24358
24359
24360
24361
24362
24363
24364
24365       ac_fn_c_check_member "$LINENO" "struct sockaddr" "sa_len" "ac_cv_member_struct_sockaddr_sa_len" "
24366 #include <sys/types.h>
24367 #include <sys/socket.h>
24368
24369 "
24370 if test "x$ac_cv_member_struct_sockaddr_sa_len" = xyes; then :
24371
24372 cat >>confdefs.h <<_ACEOF
24373 #define HAVE_STRUCT_SOCKADDR_SA_LEN 1
24374 _ACEOF
24375
24376
24377 fi
24378
24379
24380
24381   :
24382
24383
24384
24385
24386
24387
24388   ac_fn_c_check_decl "$LINENO" "getaddrinfo" "ac_cv_have_decl_getaddrinfo" "
24389   /* sys/types.h is not needed according to POSIX, but the
24390      sys/socket.h in i386-unknown-freebsd4.10 and
24391      powerpc-apple-darwin5.5 required it. */
24392 #include <sys/types.h>
24393 #ifdef HAVE_SYS_SOCKET_H
24394 #include <sys/socket.h>
24395 #endif
24396 #ifdef HAVE_NETDB_H
24397 #include <netdb.h>
24398 #endif
24399 #ifdef HAVE_WS2TCPIP_H
24400 #include <ws2tcpip.h>
24401 #endif
24402
24403 "
24404 if test "x$ac_cv_have_decl_getaddrinfo" = xyes; then :
24405   ac_have_decl=1
24406 else
24407   ac_have_decl=0
24408 fi
24409
24410 cat >>confdefs.h <<_ACEOF
24411 #define HAVE_DECL_GETADDRINFO $ac_have_decl
24412 _ACEOF
24413 ac_fn_c_check_decl "$LINENO" "freeaddrinfo" "ac_cv_have_decl_freeaddrinfo" "
24414   /* sys/types.h is not needed according to POSIX, but the
24415      sys/socket.h in i386-unknown-freebsd4.10 and
24416      powerpc-apple-darwin5.5 required it. */
24417 #include <sys/types.h>
24418 #ifdef HAVE_SYS_SOCKET_H
24419 #include <sys/socket.h>
24420 #endif
24421 #ifdef HAVE_NETDB_H
24422 #include <netdb.h>
24423 #endif
24424 #ifdef HAVE_WS2TCPIP_H
24425 #include <ws2tcpip.h>
24426 #endif
24427
24428 "
24429 if test "x$ac_cv_have_decl_freeaddrinfo" = xyes; then :
24430   ac_have_decl=1
24431 else
24432   ac_have_decl=0
24433 fi
24434
24435 cat >>confdefs.h <<_ACEOF
24436 #define HAVE_DECL_FREEADDRINFO $ac_have_decl
24437 _ACEOF
24438 ac_fn_c_check_decl "$LINENO" "getnameinfo" "ac_cv_have_decl_getnameinfo" "
24439   /* sys/types.h is not needed according to POSIX, but the
24440      sys/socket.h in i386-unknown-freebsd4.10 and
24441      powerpc-apple-darwin5.5 required it. */
24442 #include <sys/types.h>
24443 #ifdef HAVE_SYS_SOCKET_H
24444 #include <sys/socket.h>
24445 #endif
24446 #ifdef HAVE_NETDB_H
24447 #include <netdb.h>
24448 #endif
24449 #ifdef HAVE_WS2TCPIP_H
24450 #include <ws2tcpip.h>
24451 #endif
24452
24453 "
24454 if test "x$ac_cv_have_decl_getnameinfo" = xyes; then :
24455   ac_have_decl=1
24456 else
24457   ac_have_decl=0
24458 fi
24459
24460 cat >>confdefs.h <<_ACEOF
24461 #define HAVE_DECL_GETNAMEINFO $ac_have_decl
24462 _ACEOF
24463
24464   if test $ac_cv_have_decl_getaddrinfo = no; then
24465     HAVE_DECL_GETADDRINFO=0
24466   fi
24467   if test $ac_cv_have_decl_freeaddrinfo = no; then
24468     HAVE_DECL_FREEADDRINFO=0
24469   fi
24470   if test $ac_cv_have_decl_gai_strerror = no; then
24471     HAVE_DECL_GAI_STRERROR=0
24472   fi
24473   if test $ac_cv_have_decl_getnameinfo = no; then
24474     HAVE_DECL_GETNAMEINFO=0
24475   fi
24476
24477   ac_fn_c_check_type "$LINENO" "struct addrinfo" "ac_cv_type_struct_addrinfo" "
24478 #include <sys/types.h>
24479 #ifdef HAVE_SYS_SOCKET_H
24480 #include <sys/socket.h>
24481 #endif
24482 #ifdef HAVE_NETDB_H
24483 #include <netdb.h>
24484 #endif
24485 #ifdef HAVE_WS2TCPIP_H
24486 #include <ws2tcpip.h>
24487 #endif
24488
24489 "
24490 if test "x$ac_cv_type_struct_addrinfo" = xyes; then :
24491
24492 cat >>confdefs.h <<_ACEOF
24493 #define HAVE_STRUCT_ADDRINFO 1
24494 _ACEOF
24495
24496
24497 fi
24498
24499   if test $ac_cv_type_struct_addrinfo = no; then
24500     HAVE_STRUCT_ADDRINFO=0
24501   fi
24502
24503     case " $GETADDRINFO_LIB " in
24504     *" $HOSTENT_LIB "*) ;;
24505     *) GETADDRINFO_LIB="$GETADDRINFO_LIB $HOSTENT_LIB" ;;
24506   esac
24507
24508     case " $GETADDRINFO_LIB " in
24509     *" $SERVENT_LIB "*) ;;
24510     *) GETADDRINFO_LIB="$GETADDRINFO_LIB $SERVENT_LIB" ;;
24511   esac
24512
24513     case " $GETADDRINFO_LIB " in
24514     *" $INET_NTOP_LIB "*) ;;
24515     *) GETADDRINFO_LIB="$GETADDRINFO_LIB $INET_NTOP_LIB" ;;
24516   esac
24517
24518
24519
24520
24521   if test $HAVE_GETADDRINFO = 0; then
24522
24523
24524
24525
24526
24527
24528
24529
24530   gl_LIBOBJS="$gl_LIBOBJS getaddrinfo.$ac_objext"
24531
24532   fi
24533   if test $HAVE_DECL_GAI_STRERROR = 0 || test $REPLACE_GAI_STRERROR = 1; then
24534
24535
24536
24537
24538
24539
24540
24541
24542   gl_LIBOBJS="$gl_LIBOBJS gai_strerror.$ac_objext"
24543
24544   fi
24545
24546
24547
24548
24549
24550           GNULIB_GETADDRINFO=1
24551
24552
24553
24554
24555
24556 $as_echo "#define GNULIB_TEST_GETADDRINFO 1" >>confdefs.h
24557
24558
24559
24560
24561
24562
24563
24564
24565   case $gl_cv_func_getcwd_null,$gl_cv_func_getcwd_posix_signature in
24566   *yes,yes) ;;
24567   *)
24568         REPLACE_GETCWD=1
24569     ;;
24570   esac
24571
24572   if test $REPLACE_GETCWD = 1; then
24573
24574
24575
24576
24577
24578
24579
24580
24581   gl_LIBOBJS="$gl_LIBOBJS getcwd-lgpl.$ac_objext"
24582
24583   fi
24584
24585
24586
24587
24588
24589           GNULIB_GETCWD=1
24590
24591
24592
24593
24594
24595 $as_echo "#define GNULIB_TEST_GETCWD 1" >>confdefs.h
24596
24597
24598
24599
24600
24601
24602
24603
24604
24605   :
24606
24607
24608
24609
24610
24611
24612
24613   :
24614
24615
24616
24617
24618
24619   if test $ac_cv_func_getdelim = yes; then
24620     HAVE_GETDELIM=1
24621         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working getdelim function" >&5
24622 $as_echo_n "checking for working getdelim function... " >&6; }
24623 if ${gl_cv_func_working_getdelim+:} false; then :
24624   $as_echo_n "(cached) " >&6
24625 else
24626   echo fooNbarN | tr -d '\012' | tr N '\012' > conftest.data
24627     if test "$cross_compiling" = yes; then :
24628         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24629 /* end confdefs.h.  */
24630
24631 #include <features.h>
24632 #ifdef __GNU_LIBRARY__
24633  #if (__GLIBC__ >= 2) && !defined __UCLIBC__
24634   Lucky GNU user
24635  #endif
24636 #endif
24637
24638 _ACEOF
24639 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
24640   $EGREP "Lucky GNU user" >/dev/null 2>&1; then :
24641   gl_cv_func_working_getdelim="guessing yes"
24642 else
24643   gl_cv_func_working_getdelim="guessing no"
24644 fi
24645 rm -f conftest*
24646
24647
24648 else
24649   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24650 /* end confdefs.h.  */
24651
24652 #    include <stdio.h>
24653 #    include <stdlib.h>
24654 #    include <string.h>
24655     int main ()
24656     {
24657       FILE *in = fopen ("./conftest.data", "r");
24658       if (!in)
24659         return 1;
24660       {
24661         /* Test result for a NULL buffer and a zero size.
24662            Based on a test program from Karl Heuer.  */
24663         char *line = NULL;
24664         size_t siz = 0;
24665         int len = getdelim (&line, &siz, '\n', in);
24666         if (!(len == 4 && line && strcmp (line, "foo\n") == 0))
24667           return 2;
24668       }
24669       {
24670         /* Test result for a NULL buffer and a non-zero size.
24671            This crashes on FreeBSD 8.0.  */
24672         char *line = NULL;
24673         size_t siz = (size_t)(~0) / 4;
24674         if (getdelim (&line, &siz, '\n', in) == -1)
24675           return 3;
24676       }
24677       return 0;
24678     }
24679
24680 _ACEOF
24681 if ac_fn_c_try_run "$LINENO"; then :
24682   gl_cv_func_working_getdelim=yes
24683 else
24684   gl_cv_func_working_getdelim=no
24685 fi
24686 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24687   conftest.$ac_objext conftest.beam conftest.$ac_ext
24688 fi
24689
24690 fi
24691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_getdelim" >&5
24692 $as_echo "$gl_cv_func_working_getdelim" >&6; }
24693     case "$gl_cv_func_working_getdelim" in
24694       *no)
24695         REPLACE_GETDELIM=1
24696         ;;
24697     esac
24698   else
24699     HAVE_GETDELIM=0
24700   fi
24701
24702   if test $ac_cv_have_decl_getdelim = no; then
24703     HAVE_DECL_GETDELIM=0
24704   fi
24705
24706   if test $HAVE_GETDELIM = 0 || test $REPLACE_GETDELIM = 1; then
24707
24708
24709
24710
24711
24712
24713
24714
24715   gl_LIBOBJS="$gl_LIBOBJS getdelim.$ac_objext"
24716
24717
24718   for ac_func in flockfile funlockfile
24719 do :
24720   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
24721 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
24722 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
24723   cat >>confdefs.h <<_ACEOF
24724 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
24725 _ACEOF
24726
24727 fi
24728 done
24729
24730   ac_fn_c_check_decl "$LINENO" "getc_unlocked" "ac_cv_have_decl_getc_unlocked" "$ac_includes_default"
24731 if test "x$ac_cv_have_decl_getc_unlocked" = xyes; then :
24732   ac_have_decl=1
24733 else
24734   ac_have_decl=0
24735 fi
24736
24737 cat >>confdefs.h <<_ACEOF
24738 #define HAVE_DECL_GETC_UNLOCKED $ac_have_decl
24739 _ACEOF
24740
24741
24742   fi
24743
24744
24745
24746
24747
24748           GNULIB_GETDELIM=1
24749
24750
24751
24752
24753
24754 $as_echo "#define GNULIB_TEST_GETDELIM 1" >>confdefs.h
24755
24756
24757
24758
24759
24760
24761
24762   :
24763
24764
24765
24766
24767
24768   if test $ac_cv_func_getdtablesize = yes; then
24769     # Cygwin 1.7.25 automatically increases the RLIMIT_NOFILE soft limit
24770     # up to an unchangeable hard limit; all other platforms correctly
24771     # require setrlimit before getdtablesize() can report a larger value.
24772     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getdtablesize works" >&5
24773 $as_echo_n "checking whether getdtablesize works... " >&6; }
24774 if ${gl_cv_func_getdtablesize_works+:} false; then :
24775   $as_echo_n "(cached) " >&6
24776 else
24777   if test "$cross_compiling" = yes; then :
24778   case "$host_os" in
24779           cygwin*) # on cygwin 1.5.25, getdtablesize() automatically grows
24780             gl_cv_func_getdtablesize_works="guessing no" ;;
24781           *) gl_cv_func_getdtablesize_works="guessing yes" ;;
24782          esac
24783 else
24784   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24785 /* end confdefs.h.  */
24786
24787         #include <unistd.h>
24788 int
24789 main ()
24790 {
24791 int size = getdtablesize();
24792            if (dup2 (0, getdtablesize()) != -1)
24793              return 1;
24794            if (size != getdtablesize())
24795              return 2;
24796
24797   ;
24798   return 0;
24799 }
24800 _ACEOF
24801 if ac_fn_c_try_run "$LINENO"; then :
24802   gl_cv_func_getdtablesize_works=yes
24803 else
24804   gl_cv_func_getdtablesize_works=no
24805 fi
24806 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24807   conftest.$ac_objext conftest.beam conftest.$ac_ext
24808 fi
24809
24810
24811 fi
24812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getdtablesize_works" >&5
24813 $as_echo "$gl_cv_func_getdtablesize_works" >&6; }
24814     case "$gl_cv_func_getdtablesize_works" in
24815       *yes) ;;
24816       *) REPLACE_GETDTABLESIZE=1 ;;
24817     esac
24818   else
24819     HAVE_GETDTABLESIZE=0
24820   fi
24821
24822   if test $HAVE_GETDTABLESIZE = 0 || test $REPLACE_GETDTABLESIZE = 1; then
24823
24824
24825
24826
24827
24828
24829
24830
24831   gl_LIBOBJS="$gl_LIBOBJS getdtablesize.$ac_objext"
24832
24833     :
24834   fi
24835
24836
24837
24838
24839
24840           GNULIB_GETDTABLESIZE=1
24841
24842
24843
24844
24845
24846 $as_echo "#define GNULIB_TEST_GETDTABLESIZE 1" >>confdefs.h
24847
24848
24849
24850
24851
24852
24853
24854
24855         ac_fn_c_check_func "$LINENO" "getgroups" "ac_cv_func_getgroups"
24856 if test "x$ac_cv_func_getgroups" = xyes; then :
24857
24858 fi
24859
24860
24861   # If we don't yet have getgroups, see if it's in -lbsd.
24862   # This is reported to be necessary on an ITOS 3000WS running SEIUX 3.1.
24863   ac_save_LIBS=$LIBS
24864   if test $ac_cv_func_getgroups = no; then
24865     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getgroups in -lbsd" >&5
24866 $as_echo_n "checking for getgroups in -lbsd... " >&6; }
24867 if ${ac_cv_lib_bsd_getgroups+:} false; then :
24868   $as_echo_n "(cached) " >&6
24869 else
24870   ac_check_lib_save_LIBS=$LIBS
24871 LIBS="-lbsd  $LIBS"
24872 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24873 /* end confdefs.h.  */
24874
24875 /* Override any GCC internal prototype to avoid an error.
24876    Use char because int might match the return type of a GCC
24877    builtin and then its argument prototype would still apply.  */
24878 #ifdef __cplusplus
24879 extern "C"
24880 #endif
24881 char getgroups ();
24882 int
24883 main ()
24884 {
24885 return getgroups ();
24886   ;
24887   return 0;
24888 }
24889 _ACEOF
24890 if ac_fn_c_try_link "$LINENO"; then :
24891   ac_cv_lib_bsd_getgroups=yes
24892 else
24893   ac_cv_lib_bsd_getgroups=no
24894 fi
24895 rm -f core conftest.err conftest.$ac_objext \
24896     conftest$ac_exeext conftest.$ac_ext
24897 LIBS=$ac_check_lib_save_LIBS
24898 fi
24899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_getgroups" >&5
24900 $as_echo "$ac_cv_lib_bsd_getgroups" >&6; }
24901 if test "x$ac_cv_lib_bsd_getgroups" = xyes; then :
24902   GETGROUPS_LIB=-lbsd
24903 fi
24904
24905   fi
24906
24907   # Run the program to test the functionality of the system-supplied
24908   # getgroups function only if there is such a function.
24909   if test $ac_cv_func_getgroups = yes; then
24910     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working getgroups" >&5
24911 $as_echo_n "checking for working getgroups... " >&6; }
24912 if ${ac_cv_func_getgroups_works+:} false; then :
24913   $as_echo_n "(cached) " >&6
24914 else
24915   if test "$cross_compiling" = yes; then :
24916   case "$host_os" in # ((
24917                     # Guess yes on glibc systems.
24918             *-gnu*) ac_cv_func_getgroups_works="guessing yes" ;;
24919                     # If we don't know, assume the worst.
24920             *)      ac_cv_func_getgroups_works="guessing no" ;;
24921           esac
24922
24923 else
24924   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24925 /* end confdefs.h.  */
24926 $ac_includes_default
24927 int
24928 main ()
24929 {
24930 /* On Ultrix 4.3, getgroups (0, 0) always fails.  */
24931               return getgroups (0, 0) == -1;
24932   ;
24933   return 0;
24934 }
24935
24936 _ACEOF
24937 if ac_fn_c_try_run "$LINENO"; then :
24938   ac_cv_func_getgroups_works=yes
24939 else
24940   ac_cv_func_getgroups_works=no
24941 fi
24942 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24943   conftest.$ac_objext conftest.beam conftest.$ac_ext
24944 fi
24945
24946
24947 fi
24948 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getgroups_works" >&5
24949 $as_echo "$ac_cv_func_getgroups_works" >&6; }
24950   else
24951     ac_cv_func_getgroups_works=no
24952   fi
24953   case "$ac_cv_func_getgroups_works" in
24954     *yes)
24955
24956 $as_echo "#define HAVE_GETGROUPS 1" >>confdefs.h
24957
24958       ;;
24959   esac
24960   LIBS=$ac_save_LIBS
24961
24962   if test $ac_cv_func_getgroups != yes; then
24963     HAVE_GETGROUPS=0
24964   else
24965     if test "$ac_cv_type_getgroups" != gid_t \
24966        || { case "$ac_cv_func_getgroups_works" in
24967               *yes) false;;
24968               *) true;;
24969             esac
24970           }; then
24971       REPLACE_GETGROUPS=1
24972
24973 $as_echo "#define GETGROUPS_ZERO_BUG 1" >>confdefs.h
24974
24975     else
24976             { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getgroups handles negative values" >&5
24977 $as_echo_n "checking whether getgroups handles negative values... " >&6; }
24978 if ${gl_cv_func_getgroups_works+:} false; then :
24979   $as_echo_n "(cached) " >&6
24980 else
24981   if test "$cross_compiling" = yes; then :
24982   case "$host_os" in
24983                      # Guess yes on glibc systems.
24984              *-gnu*) gl_cv_func_getgroups_works="guessing yes" ;;
24985                      # If we don't know, assume the worst.
24986              *)      gl_cv_func_getgroups_works="guessing no" ;;
24987            esac
24988
24989 else
24990   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24991 /* end confdefs.h.  */
24992 $ac_includes_default
24993 int
24994 main ()
24995 {
24996 int size = getgroups (0, 0);
24997             gid_t *list = malloc (size * sizeof *list);
24998             return getgroups (-1, list) != -1;
24999   ;
25000   return 0;
25001 }
25002 _ACEOF
25003 if ac_fn_c_try_run "$LINENO"; then :
25004   gl_cv_func_getgroups_works=yes
25005 else
25006   gl_cv_func_getgroups_works=no
25007 fi
25008 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25009   conftest.$ac_objext conftest.beam conftest.$ac_ext
25010 fi
25011
25012 fi
25013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getgroups_works" >&5
25014 $as_echo "$gl_cv_func_getgroups_works" >&6; }
25015       case "$gl_cv_func_getgroups_works" in
25016         *yes) ;;
25017         *) REPLACE_GETGROUPS=1 ;;
25018       esac
25019     fi
25020   fi
25021   test -n "$GETGROUPS_LIB" && LIBS="$GETGROUPS_LIB $LIBS"
25022
25023   if test $HAVE_GETGROUPS = 0 || test $REPLACE_GETGROUPS = 1; then
25024
25025
25026
25027
25028
25029
25030
25031
25032   gl_LIBOBJS="$gl_LIBOBJS getgroups.$ac_objext"
25033
25034   fi
25035
25036
25037
25038
25039
25040           GNULIB_GETGROUPS=1
25041
25042
25043
25044
25045
25046 $as_echo "#define GNULIB_TEST_GETGROUPS 1" >>confdefs.h
25047
25048
25049
25050
25051
25052
25053
25054
25055
25056   :
25057
25058
25059
25060
25061
25062   if test $ac_cv_header_sys_socket_h != yes; then
25063                     for ac_header in winsock2.h
25064 do :
25065   ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
25066 if test "x$ac_cv_header_winsock2_h" = xyes; then :
25067   cat >>confdefs.h <<_ACEOF
25068 #define HAVE_WINSOCK2_H 1
25069 _ACEOF
25070
25071 fi
25072
25073 done
25074
25075   fi
25076   if test "$ac_cv_header_winsock2_h" = yes; then
25077     HAVE_WINSOCK2_H=1
25078     UNISTD_H_HAVE_WINSOCK2_H=1
25079     SYS_IOCTL_H_HAVE_WINSOCK2_H=1
25080   else
25081     HAVE_WINSOCK2_H=0
25082   fi
25083
25084
25085
25086         GETHOSTNAME_LIB=
25087   for ac_func in gethostname
25088 do :
25089   ac_fn_c_check_func "$LINENO" "gethostname" "ac_cv_func_gethostname"
25090 if test "x$ac_cv_func_gethostname" = xyes; then :
25091   cat >>confdefs.h <<_ACEOF
25092 #define HAVE_GETHOSTNAME 1
25093 _ACEOF
25094
25095 else
25096
25097     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostname in winsock2.h and -lws2_32" >&5
25098 $as_echo_n "checking for gethostname in winsock2.h and -lws2_32... " >&6; }
25099 if ${gl_cv_w32_gethostname+:} false; then :
25100   $as_echo_n "(cached) " >&6
25101 else
25102   gl_cv_w32_gethostname=no
25103        gl_save_LIBS="$LIBS"
25104        LIBS="$LIBS -lws2_32"
25105        cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25106 /* end confdefs.h.  */
25107
25108 #ifdef HAVE_WINSOCK2_H
25109 #include <winsock2.h>
25110 #endif
25111 #include <stddef.h>
25112
25113 int
25114 main ()
25115 {
25116 gethostname(NULL, 0);
25117   ;
25118   return 0;
25119 }
25120 _ACEOF
25121 if ac_fn_c_try_link "$LINENO"; then :
25122   gl_cv_w32_gethostname=yes
25123 fi
25124 rm -f core conftest.err conftest.$ac_objext \
25125     conftest$ac_exeext conftest.$ac_ext
25126        LIBS="$gl_save_LIBS"
25127
25128 fi
25129 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_w32_gethostname" >&5
25130 $as_echo "$gl_cv_w32_gethostname" >&6; }
25131     if test "$gl_cv_w32_gethostname" = "yes"; then
25132       GETHOSTNAME_LIB="-lws2_32"
25133     fi
25134
25135 fi
25136 done
25137
25138
25139
25140   if test "$ac_cv_func_gethostname" = no; then
25141     HAVE_GETHOSTNAME=0
25142   fi
25143
25144
25145
25146   :
25147
25148
25149
25150
25151
25152
25153   :
25154
25155
25156
25157
25158
25159
25160   :
25161
25162
25163
25164
25165
25166   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HOST_NAME_MAX" >&5
25167 $as_echo_n "checking for HOST_NAME_MAX... " >&6; }
25168 if ${gl_cv_decl_HOST_NAME_MAX+:} false; then :
25169   $as_echo_n "(cached) " >&6
25170 else
25171
25172     gl_cv_decl_HOST_NAME_MAX=
25173     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25174 /* end confdefs.h.  */
25175
25176 #include <limits.h>
25177 #ifdef HOST_NAME_MAX
25178 lucky
25179 #endif
25180
25181 _ACEOF
25182 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
25183   $EGREP "lucky" >/dev/null 2>&1; then :
25184   gl_cv_decl_HOST_NAME_MAX=yes
25185 fi
25186 rm -f conftest*
25187
25188     if test -z "$gl_cv_decl_HOST_NAME_MAX"; then
25189             if test "$gl_cv_w32_gethostname" = yes; then
25190                 gl_cv_decl_HOST_NAME_MAX=256
25191       else
25192         if ac_fn_c_compute_int "$LINENO" "MAXHOSTNAMELEN" "gl_cv_decl_HOST_NAME_MAX"        "
25193 #include <sys/types.h>
25194 #if HAVE_SYS_PARAM_H
25195 # include <sys/param.h>
25196 #endif
25197 #if HAVE_SYS_SOCKET_H
25198 # include <sys/socket.h>
25199 #endif
25200 #if HAVE_NETDB_H
25201 # include <netdb.h>
25202 #endif
25203 "; then :
25204
25205 else
25206                         gl_cv_decl_HOST_NAME_MAX=256
25207
25208 fi
25209
25210
25211       fi
25212     fi
25213
25214 fi
25215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_HOST_NAME_MAX" >&5
25216 $as_echo "$gl_cv_decl_HOST_NAME_MAX" >&6; }
25217   if test "$gl_cv_decl_HOST_NAME_MAX" != yes; then
25218
25219 cat >>confdefs.h <<_ACEOF
25220 #define HOST_NAME_MAX $gl_cv_decl_HOST_NAME_MAX
25221 _ACEOF
25222
25223   fi
25224
25225
25226   if test $HAVE_GETHOSTNAME = 0; then
25227
25228
25229
25230
25231
25232
25233
25234
25235   gl_LIBOBJS="$gl_LIBOBJS gethostname.$ac_objext"
25236
25237
25238   if test "$gl_cv_w32_gethostname" != "yes"; then
25239     for ac_func in uname
25240 do :
25241   ac_fn_c_check_func "$LINENO" "uname" "ac_cv_func_uname"
25242 if test "x$ac_cv_func_uname" = xyes; then :
25243   cat >>confdefs.h <<_ACEOF
25244 #define HAVE_UNAME 1
25245 _ACEOF
25246
25247 fi
25248 done
25249
25250   fi
25251
25252   fi
25253
25254
25255
25256
25257
25258           GNULIB_GETHOSTNAME=1
25259
25260
25261
25262
25263
25264 $as_echo "#define GNULIB_TEST_GETHOSTNAME 1" >>confdefs.h
25265
25266
25267
25268
25269
25270
25271
25272
25273
25274   :
25275
25276
25277
25278
25279
25280
25281   gl_getline_needs_run_time_check=no
25282   ac_fn_c_check_func "$LINENO" "getline" "ac_cv_func_getline"
25283 if test "x$ac_cv_func_getline" = xyes; then :
25284                    gl_getline_needs_run_time_check=yes
25285 else
25286   am_cv_func_working_getline=no
25287 fi
25288
25289   if test $gl_getline_needs_run_time_check = yes; then
25290     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working getline function" >&5
25291 $as_echo_n "checking for working getline function... " >&6; }
25292 if ${am_cv_func_working_getline+:} false; then :
25293   $as_echo_n "(cached) " >&6
25294 else
25295   echo fooNbarN | tr -d '\012' | tr N '\012' > conftest.data
25296     if test "$cross_compiling" = yes; then :
25297         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25298 /* end confdefs.h.  */
25299
25300 #include <features.h>
25301 #ifdef __GNU_LIBRARY__
25302  #if (__GLIBC__ >= 2) && !defined __UCLIBC__
25303   Lucky GNU user
25304  #endif
25305 #endif
25306
25307 _ACEOF
25308 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
25309   $EGREP "Lucky GNU user" >/dev/null 2>&1; then :
25310   am_cv_func_working_getline="guessing yes"
25311 else
25312   am_cv_func_working_getline="guessing no"
25313 fi
25314 rm -f conftest*
25315
25316
25317 else
25318   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25319 /* end confdefs.h.  */
25320
25321 #    include <stdio.h>
25322 #    include <stdlib.h>
25323 #    include <string.h>
25324     int main ()
25325     {
25326       FILE *in = fopen ("./conftest.data", "r");
25327       if (!in)
25328         return 1;
25329       {
25330         /* Test result for a NULL buffer and a zero size.
25331            Based on a test program from Karl Heuer.  */
25332         char *line = NULL;
25333         size_t siz = 0;
25334         int len = getline (&line, &siz, in);
25335         if (!(len == 4 && line && strcmp (line, "foo\n") == 0))
25336           return 2;
25337       }
25338       {
25339         /* Test result for a NULL buffer and a non-zero size.
25340            This crashes on FreeBSD 8.0.  */
25341         char *line = NULL;
25342         size_t siz = (size_t)(~0) / 4;
25343         if (getline (&line, &siz, in) == -1)
25344           return 3;
25345       }
25346       return 0;
25347     }
25348
25349 _ACEOF
25350 if ac_fn_c_try_run "$LINENO"; then :
25351   am_cv_func_working_getline=yes
25352 else
25353   am_cv_func_working_getline=no
25354 fi
25355 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25356   conftest.$ac_objext conftest.beam conftest.$ac_ext
25357 fi
25358
25359 fi
25360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_working_getline" >&5
25361 $as_echo "$am_cv_func_working_getline" >&6; }
25362   fi
25363
25364   if test $ac_cv_have_decl_getline = no; then
25365     HAVE_DECL_GETLINE=0
25366   fi
25367
25368   case "$am_cv_func_working_getline" in
25369     *no)
25370                         REPLACE_GETLINE=1
25371       ;;
25372   esac
25373
25374   if test $REPLACE_GETLINE = 1; then
25375
25376
25377
25378
25379
25380
25381
25382
25383   gl_LIBOBJS="$gl_LIBOBJS getline.$ac_objext"
25384
25385
25386   :
25387
25388   fi
25389
25390
25391
25392
25393
25394           GNULIB_GETLINE=1
25395
25396
25397
25398
25399
25400 $as_echo "#define GNULIB_TEST_GETLINE 1" >>confdefs.h
25401
25402
25403
25404
25405
25406
25407   for ac_func in getpass
25408 do :
25409   ac_fn_c_check_func "$LINENO" "getpass" "ac_cv_func_getpass"
25410 if test "x$ac_cv_func_getpass" = xyes; then :
25411   cat >>confdefs.h <<_ACEOF
25412 #define HAVE_GETPASS 1
25413 _ACEOF
25414
25415 fi
25416 done
25417
25418
25419   :
25420
25421
25422
25423
25424
25425   if test $ac_cv_func_getpass = yes; then
25426     HAVE_GETPASS=1
25427   else
25428     HAVE_GETPASS=0
25429   fi
25430
25431   if test $HAVE_GETPASS = 0; then
25432
25433
25434
25435
25436
25437
25438
25439
25440   gl_LIBOBJS="$gl_LIBOBJS getpass.$ac_objext"
25441
25442
25443
25444   :
25445
25446
25447
25448
25449
25450
25451
25452
25453
25454   :
25455
25456
25457
25458
25459
25460
25461
25462
25463
25464
25465
25466   ac_fn_c_check_decl "$LINENO" "__fsetlocking" "ac_cv_have_decl___fsetlocking" "#include <stdio.h>
25467       #if HAVE_STDIO_EXT_H
25468        #include <stdio_ext.h>
25469       #endif
25470 "
25471 if test "x$ac_cv_have_decl___fsetlocking" = xyes; then :
25472   ac_have_decl=1
25473 else
25474   ac_have_decl=0
25475 fi
25476
25477 cat >>confdefs.h <<_ACEOF
25478 #define HAVE_DECL___FSETLOCKING $ac_have_decl
25479 _ACEOF
25480
25481
25482   :
25483
25484
25485
25486
25487
25488
25489   :
25490
25491
25492
25493
25494
25495
25496   :
25497
25498
25499
25500
25501
25502
25503   :
25504
25505
25506
25507
25508
25509
25510   :
25511
25512
25513
25514
25515
25516   :
25517
25518   fi
25519
25520   if test "$ac_cv_header_winsock2_h" = yes; then
25521
25522
25523
25524
25525
25526
25527
25528
25529   gl_LIBOBJS="$gl_LIBOBJS getpeername.$ac_objext"
25530
25531   fi
25532
25533
25534
25535
25536
25537           GNULIB_GETPEERNAME=1
25538
25539
25540
25541
25542
25543 $as_echo "#define GNULIB_TEST_GETPEERNAME 1" >>confdefs.h
25544
25545
25546
25547
25548   if test "$ac_cv_header_winsock2_h" = yes; then
25549
25550
25551
25552
25553
25554
25555
25556
25557   gl_LIBOBJS="$gl_LIBOBJS getsockname.$ac_objext"
25558
25559   fi
25560
25561
25562
25563
25564
25565           GNULIB_GETSOCKNAME=1
25566
25567
25568
25569
25570
25571 $as_echo "#define GNULIB_TEST_GETSOCKNAME 1" >>confdefs.h
25572
25573
25574
25575
25576
25577
25578
25579
25580
25581
25582   :
25583
25584
25585
25586
25587
25588
25589   gl_gettimeofday_timezone=void
25590   if test $ac_cv_func_gettimeofday != yes; then
25591     HAVE_GETTIMEOFDAY=0
25592   else
25593
25594
25595
25596  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday clobbers localtime buffer" >&5
25597 $as_echo_n "checking whether gettimeofday clobbers localtime buffer... " >&6; }
25598 if ${gl_cv_func_gettimeofday_clobber+:} false; then :
25599   $as_echo_n "(cached) " >&6
25600 else
25601   if test "$cross_compiling" = yes; then :
25602   # When cross-compiling:
25603       case "$host_os" in
25604                 # Guess all is fine on glibc systems.
25605         *-gnu*) gl_cv_func_gettimeofday_clobber="guessing no" ;;
25606                 # If we don't know, assume the worst.
25607         *)      gl_cv_func_gettimeofday_clobber="guessing yes" ;;
25608       esac
25609
25610 else
25611   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25612 /* end confdefs.h.  */
25613 #include <string.h>
25614           #include <sys/time.h>
25615           #include <time.h>
25616           #include <stdlib.h>
25617
25618 int
25619 main ()
25620 {
25621
25622           time_t t = 0;
25623           struct tm *lt;
25624           struct tm saved_lt;
25625           struct timeval tv;
25626           lt = localtime (&t);
25627           saved_lt = *lt;
25628           gettimeofday (&tv, NULL);
25629           return memcmp (lt, &saved_lt, sizeof (struct tm)) != 0;
25630
25631   ;
25632   return 0;
25633 }
25634 _ACEOF
25635 if ac_fn_c_try_run "$LINENO"; then :
25636   gl_cv_func_gettimeofday_clobber=no
25637 else
25638   gl_cv_func_gettimeofday_clobber=yes
25639 fi
25640 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25641   conftest.$ac_objext conftest.beam conftest.$ac_ext
25642 fi
25643
25644 fi
25645 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_clobber" >&5
25646 $as_echo "$gl_cv_func_gettimeofday_clobber" >&6; }
25647
25648  case "$gl_cv_func_gettimeofday_clobber" in
25649    *yes)
25650      REPLACE_GETTIMEOFDAY=1
25651
25652   REPLACE_GMTIME=1
25653   REPLACE_LOCALTIME=1
25654
25655
25656 $as_echo "#define GETTIMEOFDAY_CLOBBERS_LOCALTIME 1" >>confdefs.h
25657
25658      ;;
25659  esac
25660
25661     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gettimeofday with POSIX signature" >&5
25662 $as_echo_n "checking for gettimeofday with POSIX signature... " >&6; }
25663 if ${gl_cv_func_gettimeofday_posix_signature+:} false; then :
25664   $as_echo_n "(cached) " >&6
25665 else
25666   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25667 /* end confdefs.h.  */
25668 #include <sys/time.h>
25669               struct timeval c;
25670               int gettimeofday (struct timeval *restrict, void *restrict);
25671
25672 int
25673 main ()
25674 {
25675 /* glibc uses struct timezone * rather than the POSIX void *
25676                  if _GNU_SOURCE is defined.  However, since the only portable
25677                  use of gettimeofday uses NULL as the second parameter, and
25678                  since the glibc definition is actually more typesafe, it is
25679                  not worth wrapping this to get a compliant signature.  */
25680               int (*f) (struct timeval *restrict, void *restrict)
25681                 = gettimeofday;
25682               int x = f (&c, 0);
25683               return !(x | c.tv_sec | c.tv_usec);
25684
25685   ;
25686   return 0;
25687 }
25688 _ACEOF
25689 if ac_fn_c_try_compile "$LINENO"; then :
25690   gl_cv_func_gettimeofday_posix_signature=yes
25691 else
25692   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25693 /* end confdefs.h.  */
25694 #include <sys/time.h>
25695 int gettimeofday (struct timeval *restrict, struct timezone *restrict);
25696
25697 int
25698 main ()
25699 {
25700
25701   ;
25702   return 0;
25703 }
25704 _ACEOF
25705 if ac_fn_c_try_compile "$LINENO"; then :
25706   gl_cv_func_gettimeofday_posix_signature=almost
25707 else
25708   gl_cv_func_gettimeofday_posix_signature=no
25709 fi
25710 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25711 fi
25712 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25713 fi
25714 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_posix_signature" >&5
25715 $as_echo "$gl_cv_func_gettimeofday_posix_signature" >&6; }
25716     if test $gl_cv_func_gettimeofday_posix_signature = almost; then
25717       gl_gettimeofday_timezone='struct timezone'
25718     elif test $gl_cv_func_gettimeofday_posix_signature != yes; then
25719       REPLACE_GETTIMEOFDAY=1
25720     fi
25721         if test $REPLACE_STRUCT_TIMEVAL = 1; then
25722       REPLACE_GETTIMEOFDAY=1
25723     fi
25724
25725   fi
25726
25727 cat >>confdefs.h <<_ACEOF
25728 #define GETTIMEOFDAY_TIMEZONE $gl_gettimeofday_timezone
25729 _ACEOF
25730
25731
25732   if test $HAVE_GETTIMEOFDAY = 0 || test $REPLACE_GETTIMEOFDAY = 1; then
25733
25734
25735
25736
25737
25738
25739
25740
25741   gl_LIBOBJS="$gl_LIBOBJS gettimeofday.$ac_objext"
25742
25743
25744   for ac_header in sys/timeb.h
25745 do :
25746   ac_fn_c_check_header_mongrel "$LINENO" "sys/timeb.h" "ac_cv_header_sys_timeb_h" "$ac_includes_default"
25747 if test "x$ac_cv_header_sys_timeb_h" = xyes; then :
25748   cat >>confdefs.h <<_ACEOF
25749 #define HAVE_SYS_TIMEB_H 1
25750 _ACEOF
25751
25752 fi
25753
25754 done
25755
25756   for ac_func in _ftime
25757 do :
25758   ac_fn_c_check_func "$LINENO" "_ftime" "ac_cv_func__ftime"
25759 if test "x$ac_cv_func__ftime" = xyes; then :
25760   cat >>confdefs.h <<_ACEOF
25761 #define HAVE__FTIME 1
25762 _ACEOF
25763
25764 fi
25765 done
25766
25767
25768   fi
25769
25770
25771
25772
25773
25774           GNULIB_GETTIMEOFDAY=1
25775
25776
25777
25778
25779
25780 $as_echo "#define GNULIB_TEST_GETTIMEOFDAY 1" >>confdefs.h
25781
25782
25783
25784
25785
25786   :
25787
25788
25789
25790
25791
25792
25793   # Autoconf 2.61a.99 and earlier don't support linking a file only
25794   # in VPATH builds.  But since GNUmakefile is for maintainer use
25795   # only, it does not matter if we skip the link with older autoconf.
25796   # Automake 1.10.1 and earlier try to remove GNUmakefile in non-VPATH
25797   # builds, so use a shell variable to bypass this.
25798   GNUmakefile=GNUmakefile
25799   ac_config_links="$ac_config_links $GNUmakefile:$GNUmakefile"
25800
25801
25802                   HOSTENT_LIB=
25803   gl_saved_libs="$LIBS"
25804   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing gethostbyname" >&5
25805 $as_echo_n "checking for library containing gethostbyname... " >&6; }
25806 if ${ac_cv_search_gethostbyname+:} false; then :
25807   $as_echo_n "(cached) " >&6
25808 else
25809   ac_func_search_save_LIBS=$LIBS
25810 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25811 /* end confdefs.h.  */
25812
25813 /* Override any GCC internal prototype to avoid an error.
25814    Use char because int might match the return type of a GCC
25815    builtin and then its argument prototype would still apply.  */
25816 #ifdef __cplusplus
25817 extern "C"
25818 #endif
25819 char gethostbyname ();
25820 int
25821 main ()
25822 {
25823 return gethostbyname ();
25824   ;
25825   return 0;
25826 }
25827 _ACEOF
25828 for ac_lib in '' nsl network net; do
25829   if test -z "$ac_lib"; then
25830     ac_res="none required"
25831   else
25832     ac_res=-l$ac_lib
25833     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
25834   fi
25835   if ac_fn_c_try_link "$LINENO"; then :
25836   ac_cv_search_gethostbyname=$ac_res
25837 fi
25838 rm -f core conftest.err conftest.$ac_objext \
25839     conftest$ac_exeext
25840   if ${ac_cv_search_gethostbyname+:} false; then :
25841   break
25842 fi
25843 done
25844 if ${ac_cv_search_gethostbyname+:} false; then :
25845
25846 else
25847   ac_cv_search_gethostbyname=no
25848 fi
25849 rm conftest.$ac_ext
25850 LIBS=$ac_func_search_save_LIBS
25851 fi
25852 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_gethostbyname" >&5
25853 $as_echo "$ac_cv_search_gethostbyname" >&6; }
25854 ac_res=$ac_cv_search_gethostbyname
25855 if test "$ac_res" != no; then :
25856   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
25857   if test "$ac_cv_search_gethostbyname" != "none required"; then
25858        HOSTENT_LIB="$ac_cv_search_gethostbyname"
25859      fi
25860 fi
25861
25862   LIBS="$gl_saved_libs"
25863   if test -z "$HOSTENT_LIB"; then
25864     for ac_func in gethostbyname
25865 do :
25866   ac_fn_c_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname"
25867 if test "x$ac_cv_func_gethostbyname" = xyes; then :
25868   cat >>confdefs.h <<_ACEOF
25869 #define HAVE_GETHOSTBYNAME 1
25870 _ACEOF
25871
25872 else
25873
25874       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in winsock2.h and -lws2_32" >&5
25875 $as_echo_n "checking for gethostbyname in winsock2.h and -lws2_32... " >&6; }
25876 if ${gl_cv_w32_gethostbyname+:} false; then :
25877   $as_echo_n "(cached) " >&6
25878 else
25879   gl_cv_w32_gethostbyname=no
25880          gl_save_LIBS="$LIBS"
25881          LIBS="$LIBS -lws2_32"
25882          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25883 /* end confdefs.h.  */
25884
25885 #ifdef HAVE_WINSOCK2_H
25886 #include <winsock2.h>
25887 #endif
25888 #include <stddef.h>
25889
25890 int
25891 main ()
25892 {
25893 gethostbyname(NULL);
25894   ;
25895   return 0;
25896 }
25897 _ACEOF
25898 if ac_fn_c_try_link "$LINENO"; then :
25899   gl_cv_w32_gethostbyname=yes
25900 fi
25901 rm -f core conftest.err conftest.$ac_objext \
25902     conftest$ac_exeext conftest.$ac_ext
25903          LIBS="$gl_save_LIBS"
25904
25905 fi
25906 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_w32_gethostbyname" >&5
25907 $as_echo "$gl_cv_w32_gethostbyname" >&6; }
25908       if test "$gl_cv_w32_gethostbyname" = "yes"; then
25909         HOSTENT_LIB="-lws2_32"
25910       fi
25911
25912 fi
25913 done
25914
25915   fi
25916
25917
25918
25919
25920
25921
25922
25923
25924
25925               HAVE_INET_NTOP=1
25926   INET_NTOP_LIB=
25927
25928
25929
25930
25931   :
25932
25933
25934
25935
25936
25937   if test $ac_cv_header_sys_socket_h != yes; then
25938                     for ac_header in winsock2.h
25939 do :
25940   ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
25941 if test "x$ac_cv_header_winsock2_h" = xyes; then :
25942   cat >>confdefs.h <<_ACEOF
25943 #define HAVE_WINSOCK2_H 1
25944 _ACEOF
25945
25946 fi
25947
25948 done
25949
25950   fi
25951   if test "$ac_cv_header_winsock2_h" = yes; then
25952     HAVE_WINSOCK2_H=1
25953     UNISTD_H_HAVE_WINSOCK2_H=1
25954     SYS_IOCTL_H_HAVE_WINSOCK2_H=1
25955   else
25956     HAVE_WINSOCK2_H=0
25957   fi
25958
25959
25960   if test $HAVE_WINSOCK2_H = 1; then
25961     ac_fn_c_check_decl "$LINENO" "inet_ntop" "ac_cv_have_decl_inet_ntop" "#include <ws2tcpip.h>
25962 "
25963 if test "x$ac_cv_have_decl_inet_ntop" = xyes; then :
25964   ac_have_decl=1
25965 else
25966   ac_have_decl=0
25967 fi
25968
25969 cat >>confdefs.h <<_ACEOF
25970 #define HAVE_DECL_INET_NTOP $ac_have_decl
25971 _ACEOF
25972
25973     if test $ac_cv_have_decl_inet_ntop = yes; then
25974                   REPLACE_INET_NTOP=1
25975       INET_NTOP_LIB="-lws2_32"
25976     else
25977       HAVE_DECL_INET_NTOP=0
25978       HAVE_INET_NTOP=0
25979     fi
25980   else
25981     gl_save_LIBS=$LIBS
25982     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing inet_ntop" >&5
25983 $as_echo_n "checking for library containing inet_ntop... " >&6; }
25984 if ${ac_cv_search_inet_ntop+:} false; then :
25985   $as_echo_n "(cached) " >&6
25986 else
25987   ac_func_search_save_LIBS=$LIBS
25988 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25989 /* end confdefs.h.  */
25990
25991 /* Override any GCC internal prototype to avoid an error.
25992    Use char because int might match the return type of a GCC
25993    builtin and then its argument prototype would still apply.  */
25994 #ifdef __cplusplus
25995 extern "C"
25996 #endif
25997 char inet_ntop ();
25998 int
25999 main ()
26000 {
26001 return inet_ntop ();
26002   ;
26003   return 0;
26004 }
26005 _ACEOF
26006 for ac_lib in '' nsl resolv; do
26007   if test -z "$ac_lib"; then
26008     ac_res="none required"
26009   else
26010     ac_res=-l$ac_lib
26011     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
26012   fi
26013   if ac_fn_c_try_link "$LINENO"; then :
26014   ac_cv_search_inet_ntop=$ac_res
26015 fi
26016 rm -f core conftest.err conftest.$ac_objext \
26017     conftest$ac_exeext
26018   if ${ac_cv_search_inet_ntop+:} false; then :
26019   break
26020 fi
26021 done
26022 if ${ac_cv_search_inet_ntop+:} false; then :
26023
26024 else
26025   ac_cv_search_inet_ntop=no
26026 fi
26027 rm conftest.$ac_ext
26028 LIBS=$ac_func_search_save_LIBS
26029 fi
26030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inet_ntop" >&5
26031 $as_echo "$ac_cv_search_inet_ntop" >&6; }
26032 ac_res=$ac_cv_search_inet_ntop
26033 if test "$ac_res" != no; then :
26034   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
26035
26036 else
26037   for ac_func in inet_ntop
26038 do :
26039   ac_fn_c_check_func "$LINENO" "inet_ntop" "ac_cv_func_inet_ntop"
26040 if test "x$ac_cv_func_inet_ntop" = xyes; then :
26041   cat >>confdefs.h <<_ACEOF
26042 #define HAVE_INET_NTOP 1
26043 _ACEOF
26044
26045 fi
26046 done
26047
26048        if test $ac_cv_func_inet_ntop = no; then
26049          HAVE_INET_NTOP=0
26050        fi
26051
26052 fi
26053
26054     LIBS=$gl_save_LIBS
26055
26056     if test "$ac_cv_search_inet_ntop" != "no" \
26057        && test "$ac_cv_search_inet_ntop" != "none required"; then
26058       INET_NTOP_LIB="$ac_cv_search_inet_ntop"
26059     fi
26060
26061
26062   :
26063
26064
26065
26066
26067
26068     ac_fn_c_check_decl "$LINENO" "inet_ntop" "ac_cv_have_decl_inet_ntop" "#include <arpa/inet.h>
26069         #if HAVE_NETDB_H
26070         # include <netdb.h>
26071         #endif
26072
26073 "
26074 if test "x$ac_cv_have_decl_inet_ntop" = xyes; then :
26075   ac_have_decl=1
26076 else
26077   ac_have_decl=0
26078 fi
26079
26080 cat >>confdefs.h <<_ACEOF
26081 #define HAVE_DECL_INET_NTOP $ac_have_decl
26082 _ACEOF
26083
26084     if test $ac_cv_have_decl_inet_ntop = no; then
26085       HAVE_DECL_INET_NTOP=0
26086     fi
26087   fi
26088
26089
26090   if test $HAVE_INET_NTOP = 0 || test $REPLACE_INET_NTOP = 1; then
26091
26092
26093
26094
26095
26096
26097
26098
26099   gl_LIBOBJS="$gl_LIBOBJS inet_ntop.$ac_objext"
26100
26101
26102
26103
26104   fi
26105
26106
26107
26108
26109
26110           GNULIB_INET_NTOP=1
26111
26112
26113
26114
26115
26116
26117
26118
26119
26120
26121
26122               HAVE_INET_PTON=1
26123   INET_PTON_LIB=
26124
26125
26126
26127
26128   :
26129
26130
26131
26132
26133
26134   if test $ac_cv_header_sys_socket_h != yes; then
26135                     for ac_header in winsock2.h
26136 do :
26137   ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
26138 if test "x$ac_cv_header_winsock2_h" = xyes; then :
26139   cat >>confdefs.h <<_ACEOF
26140 #define HAVE_WINSOCK2_H 1
26141 _ACEOF
26142
26143 fi
26144
26145 done
26146
26147   fi
26148   if test "$ac_cv_header_winsock2_h" = yes; then
26149     HAVE_WINSOCK2_H=1
26150     UNISTD_H_HAVE_WINSOCK2_H=1
26151     SYS_IOCTL_H_HAVE_WINSOCK2_H=1
26152   else
26153     HAVE_WINSOCK2_H=0
26154   fi
26155
26156
26157   if test $HAVE_WINSOCK2_H = 1; then
26158     ac_fn_c_check_decl "$LINENO" "inet_pton" "ac_cv_have_decl_inet_pton" "#include <ws2tcpip.h>
26159 "
26160 if test "x$ac_cv_have_decl_inet_pton" = xyes; then :
26161   ac_have_decl=1
26162 else
26163   ac_have_decl=0
26164 fi
26165
26166 cat >>confdefs.h <<_ACEOF
26167 #define HAVE_DECL_INET_PTON $ac_have_decl
26168 _ACEOF
26169
26170     if test $ac_cv_have_decl_inet_pton = yes; then
26171                   REPLACE_INET_PTON=1
26172       INET_PTON_LIB="-lws2_32"
26173     else
26174       HAVE_DECL_INET_PTON=0
26175       HAVE_INET_PTON=0
26176     fi
26177   else
26178     gl_save_LIBS=$LIBS
26179     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing inet_pton" >&5
26180 $as_echo_n "checking for library containing inet_pton... " >&6; }
26181 if ${ac_cv_search_inet_pton+:} false; then :
26182   $as_echo_n "(cached) " >&6
26183 else
26184   ac_func_search_save_LIBS=$LIBS
26185 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26186 /* end confdefs.h.  */
26187
26188 /* Override any GCC internal prototype to avoid an error.
26189    Use char because int might match the return type of a GCC
26190    builtin and then its argument prototype would still apply.  */
26191 #ifdef __cplusplus
26192 extern "C"
26193 #endif
26194 char inet_pton ();
26195 int
26196 main ()
26197 {
26198 return inet_pton ();
26199   ;
26200   return 0;
26201 }
26202 _ACEOF
26203 for ac_lib in '' nsl resolv; do
26204   if test -z "$ac_lib"; then
26205     ac_res="none required"
26206   else
26207     ac_res=-l$ac_lib
26208     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
26209   fi
26210   if ac_fn_c_try_link "$LINENO"; then :
26211   ac_cv_search_inet_pton=$ac_res
26212 fi
26213 rm -f core conftest.err conftest.$ac_objext \
26214     conftest$ac_exeext
26215   if ${ac_cv_search_inet_pton+:} false; then :
26216   break
26217 fi
26218 done
26219 if ${ac_cv_search_inet_pton+:} false; then :
26220
26221 else
26222   ac_cv_search_inet_pton=no
26223 fi
26224 rm conftest.$ac_ext
26225 LIBS=$ac_func_search_save_LIBS
26226 fi
26227 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inet_pton" >&5
26228 $as_echo "$ac_cv_search_inet_pton" >&6; }
26229 ac_res=$ac_cv_search_inet_pton
26230 if test "$ac_res" != no; then :
26231   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
26232
26233 else
26234   for ac_func in inet_pton
26235 do :
26236   ac_fn_c_check_func "$LINENO" "inet_pton" "ac_cv_func_inet_pton"
26237 if test "x$ac_cv_func_inet_pton" = xyes; then :
26238   cat >>confdefs.h <<_ACEOF
26239 #define HAVE_INET_PTON 1
26240 _ACEOF
26241
26242 fi
26243 done
26244
26245        if test $ac_cv_func_inet_pton = no; then
26246          HAVE_INET_PTON=0
26247        fi
26248
26249 fi
26250
26251     LIBS=$gl_save_LIBS
26252
26253     if test "$ac_cv_search_inet_pton" != "no" \
26254        && test "$ac_cv_search_inet_pton" != "none required"; then
26255       INET_PTON_LIB="$ac_cv_search_inet_pton"
26256     fi
26257
26258
26259   :
26260
26261
26262
26263
26264
26265     ac_fn_c_check_decl "$LINENO" "inet_pton" "ac_cv_have_decl_inet_pton" "#include <arpa/inet.h>
26266         #if HAVE_NETDB_H
26267         # include <netdb.h>
26268         #endif
26269
26270 "
26271 if test "x$ac_cv_have_decl_inet_pton" = xyes; then :
26272   ac_have_decl=1
26273 else
26274   ac_have_decl=0
26275 fi
26276
26277 cat >>confdefs.h <<_ACEOF
26278 #define HAVE_DECL_INET_PTON $ac_have_decl
26279 _ACEOF
26280
26281     if test $ac_cv_have_decl_inet_pton = no; then
26282       HAVE_DECL_INET_PTON=0
26283     fi
26284   fi
26285
26286
26287   if test $HAVE_INET_PTON = 0 || test $REPLACE_INET_NTOP = 1; then
26288
26289
26290
26291
26292
26293
26294
26295
26296   gl_LIBOBJS="$gl_LIBOBJS inet_pton.$ac_objext"
26297
26298
26299
26300
26301   fi
26302
26303
26304
26305
26306
26307           GNULIB_INET_PTON=1
26308
26309
26310
26311
26312
26313
26314
26315   HAVE_IOCTL=1
26316   if test "$ac_cv_header_winsock2_h" = yes; then
26317                 HAVE_IOCTL=0
26318   else
26319     for ac_func in ioctl
26320 do :
26321   ac_fn_c_check_func "$LINENO" "ioctl" "ac_cv_func_ioctl"
26322 if test "x$ac_cv_func_ioctl" = xyes; then :
26323   cat >>confdefs.h <<_ACEOF
26324 #define HAVE_IOCTL 1
26325 _ACEOF
26326
26327 fi
26328 done
26329
26330                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ioctl with POSIX signature" >&5
26331 $as_echo_n "checking for ioctl with POSIX signature... " >&6; }
26332 if ${gl_cv_func_ioctl_posix_signature+:} false; then :
26333   $as_echo_n "(cached) " >&6
26334 else
26335   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26336 /* end confdefs.h.  */
26337 #include <sys/ioctl.h>
26338 int
26339 main ()
26340 {
26341 extern
26342               #ifdef __cplusplus
26343               "C"
26344               #endif
26345               int ioctl (int, int, ...);
26346
26347   ;
26348   return 0;
26349 }
26350
26351 _ACEOF
26352 if ac_fn_c_try_compile "$LINENO"; then :
26353   gl_cv_func_ioctl_posix_signature=yes
26354 else
26355   gl_cv_func_ioctl_posix_signature=no
26356 fi
26357 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26358
26359 fi
26360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_ioctl_posix_signature" >&5
26361 $as_echo "$gl_cv_func_ioctl_posix_signature" >&6; }
26362     if test $gl_cv_func_ioctl_posix_signature != yes; then
26363       REPLACE_IOCTL=1
26364     fi
26365   fi
26366
26367   if test $HAVE_IOCTL = 0 || test $REPLACE_IOCTL = 1; then
26368
26369
26370
26371
26372
26373
26374
26375
26376   gl_LIBOBJS="$gl_LIBOBJS ioctl.$ac_objext"
26377
26378   fi
26379
26380
26381
26382
26383
26384           GNULIB_IOCTL=1
26385
26386
26387
26388
26389
26390 $as_echo "#define GNULIB_TEST_IOCTL 1" >>confdefs.h
26391
26392
26393
26394
26395
26396          case $host_os in
26397     mingw*) REPLACE_ISATTY=1 ;;
26398   esac
26399
26400   if test $REPLACE_ISATTY = 1; then
26401
26402
26403
26404
26405
26406
26407
26408
26409   gl_LIBOBJS="$gl_LIBOBJS isatty.$ac_objext"
26410
26411     :
26412   fi
26413
26414
26415
26416
26417
26418           GNULIB_ISATTY=1
26419
26420
26421
26422
26423
26424 $as_echo "#define GNULIB_TEST_ISATTY 1" >>confdefs.h
26425
26426
26427
26428
26429
26430
26431
26432
26433
26434
26435
26436
26437
26438
26439   :
26440
26441
26442
26443
26444
26445
26446
26447
26448      if test $gl_cv_have_include_next = yes; then
26449        gl_cv_next_langinfo_h='<'langinfo.h'>'
26450      else
26451        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <langinfo.h>" >&5
26452 $as_echo_n "checking absolute name of <langinfo.h>... " >&6; }
26453 if ${gl_cv_next_langinfo_h+:} false; then :
26454   $as_echo_n "(cached) " >&6
26455 else
26456
26457              if test $ac_cv_header_langinfo_h = yes; then
26458
26459
26460
26461
26462   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26463 /* end confdefs.h.  */
26464 #include <langinfo.h>
26465 _ACEOF
26466                 case "$host_os" in
26467     aix*) gl_absname_cpp="$ac_cpp -C" ;;
26468     *)    gl_absname_cpp="$ac_cpp" ;;
26469   esac
26470
26471   case "$host_os" in
26472     mingw*)
26473                                           gl_dirsep_regex='[/\\]'
26474       ;;
26475     *)
26476       gl_dirsep_regex='\/'
26477       ;;
26478   esac
26479       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26480   gl_header_literal_regex=`echo 'langinfo.h' \
26481                            | sed -e "$gl_make_literal_regex_sed"`
26482   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26483       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26484       s|^/[^/]|//&|
26485       p
26486       q
26487     }'
26488
26489         gl_cv_absolute_langinfo_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26490   sed -n "$gl_absolute_header_sed"`
26491
26492            gl_header=$gl_cv_absolute_langinfo_h
26493            gl_cv_next_langinfo_h='"'$gl_header'"'
26494           else
26495                gl_cv_next_langinfo_h='<'langinfo.h'>'
26496              fi
26497
26498
26499 fi
26500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_langinfo_h" >&5
26501 $as_echo "$gl_cv_next_langinfo_h" >&6; }
26502      fi
26503      NEXT_LANGINFO_H=$gl_cv_next_langinfo_h
26504
26505      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26506        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26507        gl_next_as_first_directive='<'langinfo.h'>'
26508      else
26509        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26510        gl_next_as_first_directive=$gl_cv_next_langinfo_h
26511      fi
26512      NEXT_AS_FIRST_DIRECTIVE_LANGINFO_H=$gl_next_as_first_directive
26513
26514
26515
26516
26517
26518     HAVE_LANGINFO_CODESET=0
26519   HAVE_LANGINFO_T_FMT_AMPM=0
26520   HAVE_LANGINFO_ERA=0
26521   HAVE_LANGINFO_YESEXPR=0
26522
26523   :
26524
26525
26526
26527
26528
26529   if test $ac_cv_header_langinfo_h = yes; then
26530     HAVE_LANGINFO_H=1
26531             { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether langinfo.h defines CODESET" >&5
26532 $as_echo_n "checking whether langinfo.h defines CODESET... " >&6; }
26533 if ${gl_cv_header_langinfo_codeset+:} false; then :
26534   $as_echo_n "(cached) " >&6
26535 else
26536   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26537 /* end confdefs.h.  */
26538 #include <langinfo.h>
26539 int a = CODESET;
26540
26541 int
26542 main ()
26543 {
26544
26545   ;
26546   return 0;
26547 }
26548 _ACEOF
26549 if ac_fn_c_try_compile "$LINENO"; then :
26550   gl_cv_header_langinfo_codeset=yes
26551 else
26552   gl_cv_header_langinfo_codeset=no
26553 fi
26554 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26555
26556 fi
26557 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_langinfo_codeset" >&5
26558 $as_echo "$gl_cv_header_langinfo_codeset" >&6; }
26559     if test $gl_cv_header_langinfo_codeset = yes; then
26560       HAVE_LANGINFO_CODESET=1
26561     fi
26562     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether langinfo.h defines T_FMT_AMPM" >&5
26563 $as_echo_n "checking whether langinfo.h defines T_FMT_AMPM... " >&6; }
26564 if ${gl_cv_header_langinfo_t_fmt_ampm+:} false; then :
26565   $as_echo_n "(cached) " >&6
26566 else
26567   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26568 /* end confdefs.h.  */
26569 #include <langinfo.h>
26570 int a = T_FMT_AMPM;
26571
26572 int
26573 main ()
26574 {
26575
26576   ;
26577   return 0;
26578 }
26579 _ACEOF
26580 if ac_fn_c_try_compile "$LINENO"; then :
26581   gl_cv_header_langinfo_t_fmt_ampm=yes
26582 else
26583   gl_cv_header_langinfo_t_fmt_ampm=no
26584 fi
26585 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26586
26587 fi
26588 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_langinfo_t_fmt_ampm" >&5
26589 $as_echo "$gl_cv_header_langinfo_t_fmt_ampm" >&6; }
26590     if test $gl_cv_header_langinfo_t_fmt_ampm = yes; then
26591       HAVE_LANGINFO_T_FMT_AMPM=1
26592     fi
26593     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether langinfo.h defines ERA" >&5
26594 $as_echo_n "checking whether langinfo.h defines ERA... " >&6; }
26595 if ${gl_cv_header_langinfo_era+:} false; then :
26596   $as_echo_n "(cached) " >&6
26597 else
26598   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26599 /* end confdefs.h.  */
26600 #include <langinfo.h>
26601 int a = ERA;
26602
26603 int
26604 main ()
26605 {
26606
26607   ;
26608   return 0;
26609 }
26610 _ACEOF
26611 if ac_fn_c_try_compile "$LINENO"; then :
26612   gl_cv_header_langinfo_era=yes
26613 else
26614   gl_cv_header_langinfo_era=no
26615 fi
26616 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26617
26618 fi
26619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_langinfo_era" >&5
26620 $as_echo "$gl_cv_header_langinfo_era" >&6; }
26621     if test $gl_cv_header_langinfo_era = yes; then
26622       HAVE_LANGINFO_ERA=1
26623     fi
26624     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether langinfo.h defines YESEXPR" >&5
26625 $as_echo_n "checking whether langinfo.h defines YESEXPR... " >&6; }
26626 if ${gl_cv_header_langinfo_yesexpr+:} false; then :
26627   $as_echo_n "(cached) " >&6
26628 else
26629   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26630 /* end confdefs.h.  */
26631 #include <langinfo.h>
26632 int a = YESEXPR;
26633
26634 int
26635 main ()
26636 {
26637
26638   ;
26639   return 0;
26640 }
26641 _ACEOF
26642 if ac_fn_c_try_compile "$LINENO"; then :
26643   gl_cv_header_langinfo_yesexpr=yes
26644 else
26645   gl_cv_header_langinfo_yesexpr=no
26646 fi
26647 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26648
26649 fi
26650 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_langinfo_yesexpr" >&5
26651 $as_echo "$gl_cv_header_langinfo_yesexpr" >&6; }
26652     if test $gl_cv_header_langinfo_yesexpr = yes; then
26653       HAVE_LANGINFO_YESEXPR=1
26654     fi
26655   else
26656     HAVE_LANGINFO_H=0
26657   fi
26658
26659
26660
26661
26662
26663
26664
26665
26666
26667
26668
26669   LDEXP_LIBM=
26670   if test $gl_cv_func_ldexp_no_libm = no; then
26671     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ldexp() can be used with libm" >&5
26672 $as_echo_n "checking whether ldexp() can be used with libm... " >&6; }
26673 if ${gl_cv_func_ldexp_in_libm+:} false; then :
26674   $as_echo_n "(cached) " >&6
26675 else
26676
26677         save_LIBS="$LIBS"
26678         LIBS="$LIBS -lm"
26679         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26680 /* end confdefs.h.  */
26681 #ifndef __NO_MATH_INLINES
26682                              # define __NO_MATH_INLINES 1 /* for glibc */
26683                              #endif
26684                              #include <math.h>
26685                              double (*funcptr) (double, int) = ldexp;
26686                              double x;
26687 int
26688 main ()
26689 {
26690 return ldexp (x, -1) > 0;
26691   ;
26692   return 0;
26693 }
26694 _ACEOF
26695 if ac_fn_c_try_link "$LINENO"; then :
26696   gl_cv_func_ldexp_in_libm=yes
26697 else
26698   gl_cv_func_ldexp_in_libm=no
26699 fi
26700 rm -f core conftest.err conftest.$ac_objext \
26701     conftest$ac_exeext conftest.$ac_ext
26702         LIBS="$save_LIBS"
26703
26704 fi
26705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_ldexp_in_libm" >&5
26706 $as_echo "$gl_cv_func_ldexp_in_libm" >&6; }
26707     if test $gl_cv_func_ldexp_in_libm = yes; then
26708       LDEXP_LIBM=-lm
26709     fi
26710   fi
26711
26712
26713
26714   if test "$ac_cv_header_winsock2_h" = yes; then
26715
26716
26717
26718
26719
26720
26721
26722
26723   gl_LIBOBJS="$gl_LIBOBJS listen.$ac_objext"
26724
26725   fi
26726
26727
26728
26729
26730
26731           GNULIB_LISTEN=1
26732
26733
26734
26735
26736
26737 $as_echo "#define GNULIB_TEST_LISTEN 1" >>confdefs.h
26738
26739
26740
26741
26742
26743
26744
26745   :
26746
26747
26748
26749
26750
26751
26752
26753
26754
26755   LOCALCHARSET_TESTS_ENVIRONMENT="CHARSETALIASDIR=\"\$(abs_top_builddir)/$gl_source_base\""
26756
26757
26758
26759
26760
26761
26762
26763
26764
26765   case "$host_os" in
26766     solaris*)
26767
26768 $as_echo "#define _LCONV_C99 1" >>confdefs.h
26769
26770       ;;
26771   esac
26772
26773   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether locale.h conforms to POSIX:2001" >&5
26774 $as_echo_n "checking whether locale.h conforms to POSIX:2001... " >&6; }
26775 if ${gl_cv_header_locale_h_posix2001+:} false; then :
26776   $as_echo_n "(cached) " >&6
26777 else
26778   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26779 /* end confdefs.h.  */
26780 #include <locale.h>
26781             int x = LC_MESSAGES;
26782             int y = sizeof (((struct lconv *) 0)->decimal_point);
26783 int
26784 main ()
26785 {
26786
26787   ;
26788   return 0;
26789 }
26790 _ACEOF
26791 if ac_fn_c_try_compile "$LINENO"; then :
26792   gl_cv_header_locale_h_posix2001=yes
26793 else
26794   gl_cv_header_locale_h_posix2001=no
26795 fi
26796 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26797 fi
26798 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_locale_h_posix2001" >&5
26799 $as_echo "$gl_cv_header_locale_h_posix2001" >&6; }
26800
26801
26802   :
26803
26804
26805
26806
26807
26808   if test $ac_cv_header_xlocale_h = yes; then
26809     HAVE_XLOCALE_H=1
26810                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether locale.h defines locale_t" >&5
26811 $as_echo_n "checking whether locale.h defines locale_t... " >&6; }
26812 if ${gl_cv_header_locale_has_locale_t+:} false; then :
26813   $as_echo_n "(cached) " >&6
26814 else
26815   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26816 /* end confdefs.h.  */
26817 #include <locale.h>
26818               locale_t x;
26819 int
26820 main ()
26821 {
26822
26823   ;
26824   return 0;
26825 }
26826 _ACEOF
26827 if ac_fn_c_try_compile "$LINENO"; then :
26828   gl_cv_header_locale_has_locale_t=yes
26829 else
26830   gl_cv_header_locale_has_locale_t=no
26831 fi
26832 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26833
26834 fi
26835 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_locale_has_locale_t" >&5
26836 $as_echo "$gl_cv_header_locale_has_locale_t" >&6; }
26837     if test $gl_cv_header_locale_has_locale_t = yes; then
26838       gl_cv_header_locale_h_needs_xlocale_h=no
26839     else
26840       gl_cv_header_locale_h_needs_xlocale_h=yes
26841     fi
26842   else
26843     HAVE_XLOCALE_H=0
26844     gl_cv_header_locale_h_needs_xlocale_h=no
26845   fi
26846
26847
26848           { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct lconv is properly defined" >&5
26849 $as_echo_n "checking whether struct lconv is properly defined... " >&6; }
26850 if ${gl_cv_sys_struct_lconv_ok+:} false; then :
26851   $as_echo_n "(cached) " >&6
26852 else
26853   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26854 /* end confdefs.h.  */
26855 #include <locale.h>
26856             struct lconv l;
26857             int x = sizeof (l.decimal_point);
26858             int y = sizeof (l.int_p_cs_precedes);
26859 int
26860 main ()
26861 {
26862
26863   ;
26864   return 0;
26865 }
26866 _ACEOF
26867 if ac_fn_c_try_compile "$LINENO"; then :
26868   gl_cv_sys_struct_lconv_ok=yes
26869 else
26870   gl_cv_sys_struct_lconv_ok=no
26871 fi
26872 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26873
26874 fi
26875 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_lconv_ok" >&5
26876 $as_echo "$gl_cv_sys_struct_lconv_ok" >&6; }
26877   if test $gl_cv_sys_struct_lconv_ok = no; then
26878     REPLACE_STRUCT_LCONV=1
26879   fi
26880
26881
26882
26883
26884
26885
26886
26887
26888
26889      if test $gl_cv_have_include_next = yes; then
26890        gl_cv_next_locale_h='<'locale.h'>'
26891      else
26892        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <locale.h>" >&5
26893 $as_echo_n "checking absolute name of <locale.h>... " >&6; }
26894 if ${gl_cv_next_locale_h+:} false; then :
26895   $as_echo_n "(cached) " >&6
26896 else
26897
26898
26899
26900   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26901 /* end confdefs.h.  */
26902 #include <locale.h>
26903 _ACEOF
26904                 case "$host_os" in
26905     aix*) gl_absname_cpp="$ac_cpp -C" ;;
26906     *)    gl_absname_cpp="$ac_cpp" ;;
26907   esac
26908
26909   case "$host_os" in
26910     mingw*)
26911                                           gl_dirsep_regex='[/\\]'
26912       ;;
26913     *)
26914       gl_dirsep_regex='\/'
26915       ;;
26916   esac
26917       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26918   gl_header_literal_regex=`echo 'locale.h' \
26919                            | sed -e "$gl_make_literal_regex_sed"`
26920   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26921       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26922       s|^/[^/]|//&|
26923       p
26924       q
26925     }'
26926
26927         gl_cv_absolute_locale_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26928   sed -n "$gl_absolute_header_sed"`
26929
26930            gl_header=$gl_cv_absolute_locale_h
26931            gl_cv_next_locale_h='"'$gl_header'"'
26932
26933
26934 fi
26935 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_locale_h" >&5
26936 $as_echo "$gl_cv_next_locale_h" >&6; }
26937      fi
26938      NEXT_LOCALE_H=$gl_cv_next_locale_h
26939
26940      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26941        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26942        gl_next_as_first_directive='<'locale.h'>'
26943      else
26944        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26945        gl_next_as_first_directive=$gl_cv_next_locale_h
26946      fi
26947      NEXT_AS_FIRST_DIRECTIVE_LOCALE_H=$gl_next_as_first_directive
26948
26949
26950
26951
26952
26953
26954
26955
26956
26957
26958
26959   if test $REPLACE_STRUCT_LCONV = 1; then
26960     REPLACE_LOCALECONV=1
26961   fi
26962
26963   if test $REPLACE_LOCALECONV = 1; then
26964
26965
26966
26967
26968
26969
26970
26971
26972   gl_LIBOBJS="$gl_LIBOBJS localeconv.$ac_objext"
26973
26974
26975   ac_fn_c_check_member "$LINENO" "struct lconv" "decimal_point" "ac_cv_member_struct_lconv_decimal_point" "#include <locale.h>
26976 "
26977 if test "x$ac_cv_member_struct_lconv_decimal_point" = xyes; then :
26978
26979 cat >>confdefs.h <<_ACEOF
26980 #define HAVE_STRUCT_LCONV_DECIMAL_POINT 1
26981 _ACEOF
26982
26983
26984 fi
26985
26986
26987   fi
26988
26989
26990
26991
26992
26993           GNULIB_LOCALECONV=1
26994
26995
26996
26997
26998
26999 $as_echo "#define GNULIB_TEST_LOCALECONV 1" >>confdefs.h
27000
27001
27002
27003
27004
27005   if test "$gl_threads_api" = posix; then
27006     # OSF/1 4.0 and Mac OS X 10.1 lack the pthread_rwlock_t type and the
27007     # pthread_rwlock_* functions.
27008     ac_fn_c_check_type "$LINENO" "pthread_rwlock_t" "ac_cv_type_pthread_rwlock_t" "#include <pthread.h>
27009 "
27010 if test "x$ac_cv_type_pthread_rwlock_t" = xyes; then :
27011
27012 $as_echo "#define HAVE_PTHREAD_RWLOCK 1" >>confdefs.h
27013
27014 fi
27015
27016     # glibc defines PTHREAD_MUTEX_RECURSIVE as enum, not as a macro.
27017     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27018 /* end confdefs.h.  */
27019
27020       #include <pthread.h>
27021 int
27022 main ()
27023 {
27024
27025 #if __FreeBSD__ == 4
27026 error "No, in FreeBSD 4.0 recursive mutexes actually don't work."
27027 #elif (defined __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ \
27028        && __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ < 1070)
27029 error "No, in Mac OS X < 10.7 recursive mutexes actually don't work."
27030 #else
27031 int x = (int)PTHREAD_MUTEX_RECURSIVE;
27032 return !x;
27033 #endif
27034
27035   ;
27036   return 0;
27037 }
27038 _ACEOF
27039 if ac_fn_c_try_compile "$LINENO"; then :
27040
27041 $as_echo "#define HAVE_PTHREAD_MUTEX_RECURSIVE 1" >>confdefs.h
27042
27043 fi
27044 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27045   fi
27046   :
27047
27048
27049
27050 cat >>confdefs.h <<_ACEOF
27051 #define GNULIB_LOCK 1
27052 _ACEOF
27053
27054
27055
27056
27057
27058
27059
27060
27061   :
27062
27063
27064
27065
27066
27067   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lseek detects pipes" >&5
27068 $as_echo_n "checking whether lseek detects pipes... " >&6; }
27069 if ${gl_cv_func_lseek_pipe+:} false; then :
27070   $as_echo_n "(cached) " >&6
27071 else
27072   case "$host_os" in
27073        mingw*)
27074                                                                gl_cv_func_lseek_pipe=no
27075          ;;
27076        *)
27077          if test $cross_compiling = no; then
27078            cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27079 /* end confdefs.h.  */
27080
27081 #include <sys/types.h> /* for off_t */
27082 #include <stdio.h> /* for SEEK_CUR */
27083 #if HAVE_UNISTD_H
27084 # include <unistd.h>
27085 #else /* on Windows with MSVC */
27086 # include <io.h>
27087 #endif
27088
27089 int
27090 main ()
27091 {
27092
27093   /* Exit with success only if stdin is seekable.  */
27094   return lseek (0, (off_t)0, SEEK_CUR) < 0;
27095
27096   ;
27097   return 0;
27098 }
27099 _ACEOF
27100 if ac_fn_c_try_link "$LINENO"; then :
27101   if test -s conftest$ac_exeext \
27102                  && ./conftest$ac_exeext < conftest.$ac_ext \
27103                  && test 1 = "`echo hi \
27104                    | { ./conftest$ac_exeext; echo $?; cat >/dev/null; }`"; then
27105                 gl_cv_func_lseek_pipe=yes
27106               else
27107                 gl_cv_func_lseek_pipe=no
27108               fi
27109
27110 else
27111   gl_cv_func_lseek_pipe=no
27112 fi
27113 rm -f core conftest.err conftest.$ac_objext \
27114     conftest$ac_exeext conftest.$ac_ext
27115          else
27116            cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27117 /* end confdefs.h.  */
27118
27119 #if defined __BEOS__
27120 /* BeOS mistakenly return 0 when trying to seek on pipes.  */
27121   Choke me.
27122 #endif
27123 _ACEOF
27124 if ac_fn_c_try_compile "$LINENO"; then :
27125   gl_cv_func_lseek_pipe=yes
27126 else
27127   gl_cv_func_lseek_pipe=no
27128 fi
27129 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27130          fi
27131          ;;
27132      esac
27133
27134 fi
27135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_lseek_pipe" >&5
27136 $as_echo "$gl_cv_func_lseek_pipe" >&6; }
27137   if test $gl_cv_func_lseek_pipe = no; then
27138     REPLACE_LSEEK=1
27139
27140 $as_echo "#define LSEEK_PIPE_BROKEN 1" >>confdefs.h
27141
27142   fi
27143
27144
27145   if test $WINDOWS_64_BIT_OFF_T = 1; then
27146     REPLACE_LSEEK=1
27147   fi
27148
27149   if test $REPLACE_LSEEK = 1; then
27150
27151
27152
27153
27154
27155
27156
27157
27158   gl_LIBOBJS="$gl_LIBOBJS lseek.$ac_objext"
27159
27160   fi
27161
27162
27163
27164
27165
27166           GNULIB_LSEEK=1
27167
27168
27169
27170
27171
27172 $as_echo "#define GNULIB_TEST_LSEEK 1" >>confdefs.h
27173
27174
27175
27176
27177
27178
27179   :
27180
27181
27182
27183
27184
27185   if test $ac_cv_func_lstat = yes; then
27186
27187     case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
27188       *no)
27189         REPLACE_LSTAT=1
27190         ;;
27191     esac
27192   else
27193     HAVE_LSTAT=0
27194   fi
27195
27196   if test $REPLACE_LSTAT = 1; then
27197
27198
27199
27200
27201
27202
27203
27204
27205   gl_LIBOBJS="$gl_LIBOBJS lstat.$ac_objext"
27206
27207     :
27208   fi
27209
27210
27211
27212
27213
27214           GNULIB_LSTAT=1
27215
27216
27217
27218
27219
27220 $as_echo "#define GNULIB_TEST_LSTAT 1" >>confdefs.h
27221
27222
27223
27224
27225
27226
27227
27228
27229   if test $gl_cv_func_malloc_posix = yes; then
27230
27231 $as_echo "#define HAVE_MALLOC_POSIX 1" >>confdefs.h
27232
27233   else
27234     REPLACE_MALLOC=1
27235   fi
27236
27237   if test $REPLACE_MALLOC = 1; then
27238
27239
27240
27241
27242
27243
27244
27245
27246   gl_LIBOBJS="$gl_LIBOBJS malloc.$ac_objext"
27247
27248   fi
27249
27250
27251
27252
27253
27254           GNULIB_MALLOC_POSIX=1
27255
27256
27257
27258
27259
27260 $as_echo "#define GNULIB_TEST_MALLOC_POSIX 1" >>confdefs.h
27261
27262
27263
27264
27265
27266
27267
27268
27269
27270
27271
27272
27273
27274
27275
27276
27277   :
27278
27279
27280
27281
27282
27283
27284   :
27285
27286
27287
27288
27289
27290   if test $ac_cv_func_mbsinit = yes && test $ac_cv_func_mbrtowc = yes; then
27291
27292
27293
27294      { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5
27295 $as_echo_n "checking whether mbrtowc handles incomplete characters... " >&6; }
27296 if ${gl_cv_func_mbrtowc_incomplete_state+:} false; then :
27297   $as_echo_n "(cached) " >&6
27298 else
27299
27300                   case "$host_os" in
27301                      # Guess no on AIX and OSF/1.
27302         aix* | osf*) gl_cv_func_mbrtowc_incomplete_state="guessing no" ;;
27303                      # Guess yes otherwise.
27304         *)           gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;;
27305       esac
27306       if test $LOCALE_JA != none; then
27307         if test "$cross_compiling" = yes; then :
27308   :
27309 else
27310   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27311 /* end confdefs.h.  */
27312
27313 #include <locale.h>
27314 #include <string.h>
27315 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
27316    <wchar.h>.
27317    BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
27318    included before <wchar.h>.  */
27319 #include <stddef.h>
27320 #include <stdio.h>
27321 #include <time.h>
27322 #include <wchar.h>
27323 int main ()
27324 {
27325   if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
27326     {
27327       const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
27328       mbstate_t state;
27329       wchar_t wc;
27330
27331       memset (&state, '\0', sizeof (mbstate_t));
27332       if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
27333         if (mbsinit (&state))
27334           return 1;
27335     }
27336   return 0;
27337 }
27338 _ACEOF
27339 if ac_fn_c_try_run "$LINENO"; then :
27340   gl_cv_func_mbrtowc_incomplete_state=yes
27341 else
27342   gl_cv_func_mbrtowc_incomplete_state=no
27343 fi
27344 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27345   conftest.$ac_objext conftest.beam conftest.$ac_ext
27346 fi
27347
27348       fi
27349
27350 fi
27351 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5
27352 $as_echo "$gl_cv_func_mbrtowc_incomplete_state" >&6; }
27353
27354
27355
27356
27357      { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5
27358 $as_echo_n "checking whether mbrtowc works as well as mbtowc... " >&6; }
27359 if ${gl_cv_func_mbrtowc_sanitycheck+:} false; then :
27360   $as_echo_n "(cached) " >&6
27361 else
27362
27363                   case "$host_os" in
27364                     # Guess no on Solaris 8.
27365         solaris2.8) gl_cv_func_mbrtowc_sanitycheck="guessing no" ;;
27366                     # Guess yes otherwise.
27367         *)          gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;;
27368       esac
27369       if test $LOCALE_ZH_CN != none; then
27370         if test "$cross_compiling" = yes; then :
27371   :
27372 else
27373   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27374 /* end confdefs.h.  */
27375
27376 #include <locale.h>
27377 #include <stdlib.h>
27378 #include <string.h>
27379 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
27380    <wchar.h>.
27381    BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
27382    included before <wchar.h>.  */
27383 #include <stddef.h>
27384 #include <stdio.h>
27385 #include <time.h>
27386 #include <wchar.h>
27387 int main ()
27388 {
27389   /* This fails on Solaris 8:
27390      mbrtowc returns 2, and sets wc to 0x00F0.
27391      mbtowc returns 4 (correct) and sets wc to 0x5EDC.  */
27392   if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
27393     {
27394       char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */
27395       mbstate_t state;
27396       wchar_t wc;
27397
27398       memset (&state, '\0', sizeof (mbstate_t));
27399       if (mbrtowc (&wc, input + 3, 6, &state) != 4
27400           && mbtowc (&wc, input + 3, 6) == 4)
27401         return 1;
27402     }
27403   return 0;
27404 }
27405 _ACEOF
27406 if ac_fn_c_try_run "$LINENO"; then :
27407   gl_cv_func_mbrtowc_sanitycheck=yes
27408 else
27409   gl_cv_func_mbrtowc_sanitycheck=no
27410 fi
27411 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27412   conftest.$ac_objext conftest.beam conftest.$ac_ext
27413 fi
27414
27415       fi
27416
27417 fi
27418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5
27419 $as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; }
27420
27421     REPLACE_MBSTATE_T=0
27422     case "$gl_cv_func_mbrtowc_incomplete_state" in
27423       *yes) ;;
27424       *) REPLACE_MBSTATE_T=1 ;;
27425     esac
27426     case "$gl_cv_func_mbrtowc_sanitycheck" in
27427       *yes) ;;
27428       *) REPLACE_MBSTATE_T=1 ;;
27429     esac
27430   else
27431     REPLACE_MBSTATE_T=1
27432   fi
27433
27434
27435
27436   :
27437
27438
27439
27440
27441
27442   if test $ac_cv_func_mbrtowc = no; then
27443     HAVE_MBRTOWC=0
27444     ac_fn_c_check_decl "$LINENO" "mbrtowc" "ac_cv_have_decl_mbrtowc" "
27445 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
27446    <wchar.h>.
27447    BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
27448    included before <wchar.h>.  */
27449 #include <stddef.h>
27450 #include <stdio.h>
27451 #include <time.h>
27452 #include <wchar.h>
27453
27454 "
27455 if test "x$ac_cv_have_decl_mbrtowc" = xyes; then :
27456   ac_have_decl=1
27457 else
27458   ac_have_decl=0
27459 fi
27460
27461 cat >>confdefs.h <<_ACEOF
27462 #define HAVE_DECL_MBRTOWC $ac_have_decl
27463 _ACEOF
27464
27465     if test $ac_cv_have_decl_mbrtowc = yes; then
27466                         REPLACE_MBRTOWC=1
27467     fi
27468   else
27469     if test $REPLACE_MBSTATE_T = 1; then
27470       REPLACE_MBRTOWC=1
27471     else
27472
27473
27474
27475      { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles a NULL pwc argument" >&5
27476 $as_echo_n "checking whether mbrtowc handles a NULL pwc argument... " >&6; }
27477 if ${gl_cv_func_mbrtowc_null_arg1+:} false; then :
27478   $as_echo_n "(cached) " >&6
27479 else
27480
27481                   case "$host_os" in
27482                   # Guess no on Solaris.
27483         solaris*) gl_cv_func_mbrtowc_null_arg1="guessing no" ;;
27484                   # Guess yes otherwise.
27485         *)        gl_cv_func_mbrtowc_null_arg1="guessing yes" ;;
27486       esac
27487       if test $LOCALE_FR_UTF8 != none; then
27488         if test "$cross_compiling" = yes; then :
27489   :
27490 else
27491   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27492 /* end confdefs.h.  */
27493
27494 #include <locale.h>
27495 #include <stdlib.h>
27496 #include <string.h>
27497 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
27498    <wchar.h>.
27499    BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
27500    included before <wchar.h>.  */
27501 #include <stddef.h>
27502 #include <stdio.h>
27503 #include <time.h>
27504 #include <wchar.h>
27505 int main ()
27506 {
27507   int result = 0;
27508
27509   if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
27510     {
27511       char input[] = "\303\237er";
27512       mbstate_t state;
27513       wchar_t wc;
27514       size_t ret;
27515
27516       memset (&state, '\0', sizeof (mbstate_t));
27517       wc = (wchar_t) 0xBADFACE;
27518       ret = mbrtowc (&wc, input, 5, &state);
27519       if (ret != 2)
27520         result |= 1;
27521       if (!mbsinit (&state))
27522         result |= 2;
27523
27524       memset (&state, '\0', sizeof (mbstate_t));
27525       ret = mbrtowc (NULL, input, 5, &state);
27526       if (ret != 2) /* Solaris 7 fails here: ret is -1.  */
27527         result |= 4;
27528       if (!mbsinit (&state))
27529         result |= 8;
27530     }
27531   return result;
27532 }
27533 _ACEOF
27534 if ac_fn_c_try_run "$LINENO"; then :
27535   gl_cv_func_mbrtowc_null_arg1=yes
27536 else
27537   gl_cv_func_mbrtowc_null_arg1=no
27538 fi
27539 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27540   conftest.$ac_objext conftest.beam conftest.$ac_ext
27541 fi
27542
27543       fi
27544
27545 fi
27546 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_null_arg1" >&5
27547 $as_echo "$gl_cv_func_mbrtowc_null_arg1" >&6; }
27548
27549
27550
27551
27552      { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles a NULL string argument" >&5
27553 $as_echo_n "checking whether mbrtowc handles a NULL string argument... " >&6; }
27554 if ${gl_cv_func_mbrtowc_null_arg2+:} false; then :
27555   $as_echo_n "(cached) " >&6
27556 else
27557
27558                   case "$host_os" in
27559               # Guess no on OSF/1.
27560         osf*) gl_cv_func_mbrtowc_null_arg2="guessing no" ;;
27561               # Guess yes otherwise.
27562         *)    gl_cv_func_mbrtowc_null_arg2="guessing yes" ;;
27563       esac
27564       if test $LOCALE_FR_UTF8 != none; then
27565         if test "$cross_compiling" = yes; then :
27566   :
27567 else
27568   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27569 /* end confdefs.h.  */
27570
27571 #include <locale.h>
27572 #include <string.h>
27573 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
27574    <wchar.h>.
27575    BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
27576    included before <wchar.h>.  */
27577 #include <stddef.h>
27578 #include <stdio.h>
27579 #include <time.h>
27580 #include <wchar.h>
27581 int main ()
27582 {
27583   if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
27584     {
27585       mbstate_t state;
27586       wchar_t wc;
27587       int ret;
27588
27589       memset (&state, '\0', sizeof (mbstate_t));
27590       wc = (wchar_t) 0xBADFACE;
27591       mbrtowc (&wc, NULL, 5, &state);
27592       /* Check that wc was not modified.  */
27593       if (wc != (wchar_t) 0xBADFACE)
27594         return 1;
27595     }
27596   return 0;
27597 }
27598 _ACEOF
27599 if ac_fn_c_try_run "$LINENO"; then :
27600   gl_cv_func_mbrtowc_null_arg2=yes
27601 else
27602   gl_cv_func_mbrtowc_null_arg2=no
27603 fi
27604 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27605   conftest.$ac_objext conftest.beam conftest.$ac_ext
27606 fi
27607
27608       fi
27609
27610 fi
27611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_null_arg2" >&5
27612 $as_echo "$gl_cv_func_mbrtowc_null_arg2" >&6; }
27613
27614
27615
27616
27617
27618
27619   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc has a correct return value" >&5
27620 $as_echo_n "checking whether mbrtowc has a correct return value... " >&6; }
27621 if ${gl_cv_func_mbrtowc_retval+:} false; then :
27622   $as_echo_n "(cached) " >&6
27623 else
27624
27625                   case "$host_os" in
27626                                    # Guess no on HP-UX, Solaris, native Windows.
27627         hpux* | solaris* | mingw*) gl_cv_func_mbrtowc_retval="guessing no" ;;
27628                                    # Guess yes otherwise.
27629         *)                         gl_cv_func_mbrtowc_retval="guessing yes" ;;
27630       esac
27631       if test $LOCALE_FR_UTF8 != none || test $LOCALE_JA != none \
27632          || { case "$host_os" in mingw*) true;; *) false;; esac; }; then
27633         if test "$cross_compiling" = yes; then :
27634   :
27635 else
27636   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27637 /* end confdefs.h.  */
27638
27639 #include <locale.h>
27640 #include <string.h>
27641 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
27642    <wchar.h>.
27643    BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
27644    included before <wchar.h>.  */
27645 #include <stddef.h>
27646 #include <stdio.h>
27647 #include <time.h>
27648 #include <wchar.h>
27649 int main ()
27650 {
27651   int result = 0;
27652   int found_some_locale = 0;
27653   /* This fails on Solaris.  */
27654   if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
27655     {
27656       char input[] = "B\303\274\303\237er"; /* "Büßer" */
27657       mbstate_t state;
27658       wchar_t wc;
27659
27660       memset (&state, '\0', sizeof (mbstate_t));
27661       if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
27662         {
27663           input[1] = '\0';
27664           if (mbrtowc (&wc, input + 2, 5, &state) != 1)
27665             result |= 1;
27666         }
27667       found_some_locale = 1;
27668     }
27669   /* This fails on HP-UX 11.11.  */
27670   if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
27671     {
27672       char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
27673       mbstate_t state;
27674       wchar_t wc;
27675
27676       memset (&state, '\0', sizeof (mbstate_t));
27677       if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
27678         {
27679           input[1] = '\0';
27680           if (mbrtowc (&wc, input + 2, 5, &state) != 2)
27681             result |= 2;
27682         }
27683       found_some_locale = 1;
27684     }
27685   /* This fails on native Windows.  */
27686   if (setlocale (LC_ALL, "Japanese_Japan.932") != NULL)
27687     {
27688       char input[] = "<\223\372\226\173\214\352>"; /* "<日本語>" */
27689       mbstate_t state;
27690       wchar_t wc;
27691
27692       memset (&state, '\0', sizeof (mbstate_t));
27693       if (mbrtowc (&wc, input + 3, 1, &state) == (size_t)(-2))
27694         {
27695           input[3] = '\0';
27696           if (mbrtowc (&wc, input + 4, 4, &state) != 1)
27697             result |= 4;
27698         }
27699       found_some_locale = 1;
27700     }
27701   if (setlocale (LC_ALL, "Chinese_Taiwan.950") != NULL)
27702     {
27703       char input[] = "<\244\351\245\273\273\171>"; /* "<日本語>" */
27704       mbstate_t state;
27705       wchar_t wc;
27706
27707       memset (&state, '\0', sizeof (mbstate_t));
27708       if (mbrtowc (&wc, input + 3, 1, &state) == (size_t)(-2))
27709         {
27710           input[3] = '\0';
27711           if (mbrtowc (&wc, input + 4, 4, &state) != 1)
27712             result |= 8;
27713         }
27714       found_some_locale = 1;
27715     }
27716   if (setlocale (LC_ALL, "Chinese_China.936") != NULL)
27717     {
27718       char input[] = "<\310\325\261\276\325\132>"; /* "<日本語>" */
27719       mbstate_t state;
27720       wchar_t wc;
27721
27722       memset (&state, '\0', sizeof (mbstate_t));
27723       if (mbrtowc (&wc, input + 3, 1, &state) == (size_t)(-2))
27724         {
27725           input[3] = '\0';
27726           if (mbrtowc (&wc, input + 4, 4, &state) != 1)
27727             result |= 16;
27728         }
27729       found_some_locale = 1;
27730     }
27731   return (found_some_locale ? result : 77);
27732 }
27733 _ACEOF
27734 if ac_fn_c_try_run "$LINENO"; then :
27735   gl_cv_func_mbrtowc_retval=yes
27736 else
27737   if test $? != 77; then
27738              gl_cv_func_mbrtowc_retval=no
27739            fi
27740
27741 fi
27742 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27743   conftest.$ac_objext conftest.beam conftest.$ac_ext
27744 fi
27745
27746       fi
27747
27748 fi
27749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_retval" >&5
27750 $as_echo "$gl_cv_func_mbrtowc_retval" >&6; }
27751
27752
27753
27754
27755      { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc returns 0 when parsing a NUL character" >&5
27756 $as_echo_n "checking whether mbrtowc returns 0 when parsing a NUL character... " >&6; }
27757 if ${gl_cv_func_mbrtowc_nul_retval+:} false; then :
27758   $as_echo_n "(cached) " >&6
27759 else
27760
27761                   case "$host_os" in
27762                        # Guess no on Solaris 8 and 9.
27763         solaris2.[89]) gl_cv_func_mbrtowc_nul_retval="guessing no" ;;
27764                        # Guess yes otherwise.
27765         *)             gl_cv_func_mbrtowc_nul_retval="guessing yes" ;;
27766       esac
27767       if test $LOCALE_ZH_CN != none; then
27768         if test "$cross_compiling" = yes; then :
27769   :
27770 else
27771   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27772 /* end confdefs.h.  */
27773
27774 #include <locale.h>
27775 #include <string.h>
27776 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
27777    <wchar.h>.
27778    BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
27779    included before <wchar.h>.  */
27780 #include <stddef.h>
27781 #include <stdio.h>
27782 #include <time.h>
27783 #include <wchar.h>
27784 int main ()
27785 {
27786   /* This fails on Solaris 8 and 9.  */
27787   if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
27788     {
27789       mbstate_t state;
27790       wchar_t wc;
27791
27792       memset (&state, '\0', sizeof (mbstate_t));
27793       if (mbrtowc (&wc, "", 1, &state) != 0)
27794         return 1;
27795     }
27796   return 0;
27797 }
27798 _ACEOF
27799 if ac_fn_c_try_run "$LINENO"; then :
27800   gl_cv_func_mbrtowc_nul_retval=yes
27801 else
27802   gl_cv_func_mbrtowc_nul_retval=no
27803 fi
27804 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27805   conftest.$ac_objext conftest.beam conftest.$ac_ext
27806 fi
27807
27808       fi
27809
27810 fi
27811 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_nul_retval" >&5
27812 $as_echo "$gl_cv_func_mbrtowc_nul_retval" >&6; }
27813
27814       case "$gl_cv_func_mbrtowc_null_arg1" in
27815         *yes) ;;
27816         *)
27817 $as_echo "#define MBRTOWC_NULL_ARG1_BUG 1" >>confdefs.h
27818
27819            REPLACE_MBRTOWC=1
27820            ;;
27821       esac
27822       case "$gl_cv_func_mbrtowc_null_arg2" in
27823         *yes) ;;
27824         *)
27825 $as_echo "#define MBRTOWC_NULL_ARG2_BUG 1" >>confdefs.h
27826
27827            REPLACE_MBRTOWC=1
27828            ;;
27829       esac
27830       case "$gl_cv_func_mbrtowc_retval" in
27831         *yes) ;;
27832         *)
27833 $as_echo "#define MBRTOWC_RETVAL_BUG 1" >>confdefs.h
27834
27835            REPLACE_MBRTOWC=1
27836            ;;
27837       esac
27838       case "$gl_cv_func_mbrtowc_nul_retval" in
27839         *yes) ;;
27840         *)
27841 $as_echo "#define MBRTOWC_NUL_RETVAL_BUG 1" >>confdefs.h
27842
27843            REPLACE_MBRTOWC=1
27844            ;;
27845       esac
27846     fi
27847   fi
27848
27849   if test $HAVE_MBRTOWC = 0 || test $REPLACE_MBRTOWC = 1; then
27850
27851
27852
27853
27854
27855
27856
27857
27858   gl_LIBOBJS="$gl_LIBOBJS mbrtowc.$ac_objext"
27859
27860
27861   :
27862
27863   fi
27864
27865
27866
27867
27868
27869           GNULIB_MBRTOWC=1
27870
27871
27872
27873
27874
27875 $as_echo "#define GNULIB_TEST_MBRTOWC 1" >>confdefs.h
27876
27877
27878
27879
27880
27881
27882
27883
27884
27885
27886
27887
27888
27889   :
27890
27891
27892
27893
27894
27895
27896   :
27897
27898
27899
27900
27901
27902   if test $ac_cv_func_mbsinit = yes && test $ac_cv_func_mbrtowc = yes; then
27903
27904
27905
27906      { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5
27907 $as_echo_n "checking whether mbrtowc handles incomplete characters... " >&6; }
27908 if ${gl_cv_func_mbrtowc_incomplete_state+:} false; then :
27909   $as_echo_n "(cached) " >&6
27910 else
27911
27912                   case "$host_os" in
27913                      # Guess no on AIX and OSF/1.
27914         aix* | osf*) gl_cv_func_mbrtowc_incomplete_state="guessing no" ;;
27915                      # Guess yes otherwise.
27916         *)           gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;;
27917       esac
27918       if test $LOCALE_JA != none; then
27919         if test "$cross_compiling" = yes; then :
27920   :
27921 else
27922   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27923 /* end confdefs.h.  */
27924
27925 #include <locale.h>
27926 #include <string.h>
27927 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
27928    <wchar.h>.
27929    BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
27930    included before <wchar.h>.  */
27931 #include <stddef.h>
27932 #include <stdio.h>
27933 #include <time.h>
27934 #include <wchar.h>
27935 int main ()
27936 {
27937   if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
27938     {
27939       const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
27940       mbstate_t state;
27941       wchar_t wc;
27942
27943       memset (&state, '\0', sizeof (mbstate_t));
27944       if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
27945         if (mbsinit (&state))
27946           return 1;
27947     }
27948   return 0;
27949 }
27950 _ACEOF
27951 if ac_fn_c_try_run "$LINENO"; then :
27952   gl_cv_func_mbrtowc_incomplete_state=yes
27953 else
27954   gl_cv_func_mbrtowc_incomplete_state=no
27955 fi
27956 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27957   conftest.$ac_objext conftest.beam conftest.$ac_ext
27958 fi
27959
27960       fi
27961
27962 fi
27963 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5
27964 $as_echo "$gl_cv_func_mbrtowc_incomplete_state" >&6; }
27965
27966
27967
27968
27969      { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5
27970 $as_echo_n "checking whether mbrtowc works as well as mbtowc... " >&6; }
27971 if ${gl_cv_func_mbrtowc_sanitycheck+:} false; then :
27972   $as_echo_n "(cached) " >&6
27973 else
27974
27975                   case "$host_os" in
27976                     # Guess no on Solaris 8.
27977         solaris2.8) gl_cv_func_mbrtowc_sanitycheck="guessing no" ;;
27978                     # Guess yes otherwise.
27979         *)          gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;;
27980       esac
27981       if test $LOCALE_ZH_CN != none; then
27982         if test "$cross_compiling" = yes; then :
27983   :
27984 else
27985   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27986 /* end confdefs.h.  */
27987
27988 #include <locale.h>
27989 #include <stdlib.h>
27990 #include <string.h>
27991 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
27992    <wchar.h>.
27993    BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
27994    included before <wchar.h>.  */
27995 #include <stddef.h>
27996 #include <stdio.h>
27997 #include <time.h>
27998 #include <wchar.h>
27999 int main ()
28000 {
28001   /* This fails on Solaris 8:
28002      mbrtowc returns 2, and sets wc to 0x00F0.
28003      mbtowc returns 4 (correct) and sets wc to 0x5EDC.  */
28004   if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
28005     {
28006       char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */
28007       mbstate_t state;
28008       wchar_t wc;
28009
28010       memset (&state, '\0', sizeof (mbstate_t));
28011       if (mbrtowc (&wc, input + 3, 6, &state) != 4
28012           && mbtowc (&wc, input + 3, 6) == 4)
28013         return 1;
28014     }
28015   return 0;
28016 }
28017 _ACEOF
28018 if ac_fn_c_try_run "$LINENO"; then :
28019   gl_cv_func_mbrtowc_sanitycheck=yes
28020 else
28021   gl_cv_func_mbrtowc_sanitycheck=no
28022 fi
28023 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28024   conftest.$ac_objext conftest.beam conftest.$ac_ext
28025 fi
28026
28027       fi
28028
28029 fi
28030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5
28031 $as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; }
28032
28033     REPLACE_MBSTATE_T=0
28034     case "$gl_cv_func_mbrtowc_incomplete_state" in
28035       *yes) ;;
28036       *) REPLACE_MBSTATE_T=1 ;;
28037     esac
28038     case "$gl_cv_func_mbrtowc_sanitycheck" in
28039       *yes) ;;
28040       *) REPLACE_MBSTATE_T=1 ;;
28041     esac
28042   else
28043     REPLACE_MBSTATE_T=1
28044   fi
28045
28046
28047
28048   :
28049
28050
28051
28052
28053
28054   if test $ac_cv_func_mbsinit = no; then
28055     HAVE_MBSINIT=0
28056     ac_fn_c_check_decl "$LINENO" "mbsinit" "ac_cv_have_decl_mbsinit" "
28057 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
28058    <wchar.h>.
28059    BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
28060    included before <wchar.h>.  */
28061 #include <stddef.h>
28062 #include <stdio.h>
28063 #include <time.h>
28064 #include <wchar.h>
28065
28066 "
28067 if test "x$ac_cv_have_decl_mbsinit" = xyes; then :
28068   ac_have_decl=1
28069 else
28070   ac_have_decl=0
28071 fi
28072
28073 cat >>confdefs.h <<_ACEOF
28074 #define HAVE_DECL_MBSINIT $ac_have_decl
28075 _ACEOF
28076
28077     if test $ac_cv_have_decl_mbsinit = yes; then
28078                         REPLACE_MBSINIT=1
28079     fi
28080   else
28081     if test $REPLACE_MBSTATE_T = 1; then
28082       REPLACE_MBSINIT=1
28083     else
28084                         case "$host_os" in
28085         mingw*) REPLACE_MBSINIT=1 ;;
28086       esac
28087     fi
28088   fi
28089
28090   if test $HAVE_MBSINIT = 0 || test $REPLACE_MBSINIT = 1; then
28091
28092
28093
28094
28095
28096
28097
28098
28099   gl_LIBOBJS="$gl_LIBOBJS mbsinit.$ac_objext"
28100
28101
28102   :
28103
28104   fi
28105
28106
28107
28108
28109
28110           GNULIB_MBSINIT=1
28111
28112
28113
28114
28115
28116 $as_echo "#define GNULIB_TEST_MBSINIT 1" >>confdefs.h
28117
28118
28119
28120
28121
28122
28123
28124
28125
28126
28127
28128
28129   :
28130
28131
28132
28133
28134
28135
28136   :
28137
28138
28139
28140
28141
28142   if test $ac_cv_func_mbsinit = yes && test $ac_cv_func_mbrtowc = yes; then
28143
28144
28145
28146      { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5
28147 $as_echo_n "checking whether mbrtowc handles incomplete characters... " >&6; }
28148 if ${gl_cv_func_mbrtowc_incomplete_state+:} false; then :
28149   $as_echo_n "(cached) " >&6
28150 else
28151
28152                   case "$host_os" in
28153                      # Guess no on AIX and OSF/1.
28154         aix* | osf*) gl_cv_func_mbrtowc_incomplete_state="guessing no" ;;
28155                      # Guess yes otherwise.
28156         *)           gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;;
28157       esac
28158       if test $LOCALE_JA != none; then
28159         if test "$cross_compiling" = yes; then :
28160   :
28161 else
28162   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28163 /* end confdefs.h.  */
28164
28165 #include <locale.h>
28166 #include <string.h>
28167 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
28168    <wchar.h>.
28169    BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
28170    included before <wchar.h>.  */
28171 #include <stddef.h>
28172 #include <stdio.h>
28173 #include <time.h>
28174 #include <wchar.h>
28175 int main ()
28176 {
28177   if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
28178     {
28179       const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
28180       mbstate_t state;
28181       wchar_t wc;
28182
28183       memset (&state, '\0', sizeof (mbstate_t));
28184       if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
28185         if (mbsinit (&state))
28186           return 1;
28187     }
28188   return 0;
28189 }
28190 _ACEOF
28191 if ac_fn_c_try_run "$LINENO"; then :
28192   gl_cv_func_mbrtowc_incomplete_state=yes
28193 else
28194   gl_cv_func_mbrtowc_incomplete_state=no
28195 fi
28196 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28197   conftest.$ac_objext conftest.beam conftest.$ac_ext
28198 fi
28199
28200       fi
28201
28202 fi
28203 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5
28204 $as_echo "$gl_cv_func_mbrtowc_incomplete_state" >&6; }
28205
28206
28207
28208
28209      { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5
28210 $as_echo_n "checking whether mbrtowc works as well as mbtowc... " >&6; }
28211 if ${gl_cv_func_mbrtowc_sanitycheck+:} false; then :
28212   $as_echo_n "(cached) " >&6
28213 else
28214
28215                   case "$host_os" in
28216                     # Guess no on Solaris 8.
28217         solaris2.8) gl_cv_func_mbrtowc_sanitycheck="guessing no" ;;
28218                     # Guess yes otherwise.
28219         *)          gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;;
28220       esac
28221       if test $LOCALE_ZH_CN != none; then
28222         if test "$cross_compiling" = yes; then :
28223   :
28224 else
28225   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28226 /* end confdefs.h.  */
28227
28228 #include <locale.h>
28229 #include <stdlib.h>
28230 #include <string.h>
28231 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
28232    <wchar.h>.
28233    BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
28234    included before <wchar.h>.  */
28235 #include <stddef.h>
28236 #include <stdio.h>
28237 #include <time.h>
28238 #include <wchar.h>
28239 int main ()
28240 {
28241   /* This fails on Solaris 8:
28242      mbrtowc returns 2, and sets wc to 0x00F0.
28243      mbtowc returns 4 (correct) and sets wc to 0x5EDC.  */
28244   if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
28245     {
28246       char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */
28247       mbstate_t state;
28248       wchar_t wc;
28249
28250       memset (&state, '\0', sizeof (mbstate_t));
28251       if (mbrtowc (&wc, input + 3, 6, &state) != 4
28252           && mbtowc (&wc, input + 3, 6) == 4)
28253         return 1;
28254     }
28255   return 0;
28256 }
28257 _ACEOF
28258 if ac_fn_c_try_run "$LINENO"; then :
28259   gl_cv_func_mbrtowc_sanitycheck=yes
28260 else
28261   gl_cv_func_mbrtowc_sanitycheck=no
28262 fi
28263 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28264   conftest.$ac_objext conftest.beam conftest.$ac_ext
28265 fi
28266
28267       fi
28268
28269 fi
28270 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5
28271 $as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; }
28272
28273     REPLACE_MBSTATE_T=0
28274     case "$gl_cv_func_mbrtowc_incomplete_state" in
28275       *yes) ;;
28276       *) REPLACE_MBSTATE_T=1 ;;
28277     esac
28278     case "$gl_cv_func_mbrtowc_sanitycheck" in
28279       *yes) ;;
28280       *) REPLACE_MBSTATE_T=1 ;;
28281     esac
28282   else
28283     REPLACE_MBSTATE_T=1
28284   fi
28285
28286
28287
28288   :
28289
28290
28291
28292
28293
28294   if test $ac_cv_func_mbsrtowcs = no; then
28295     HAVE_MBSRTOWCS=0
28296     ac_fn_c_check_decl "$LINENO" "mbsrtowcs" "ac_cv_have_decl_mbsrtowcs" "
28297 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
28298    <wchar.h>.
28299    BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
28300    included before <wchar.h>.  */
28301 #include <stddef.h>
28302 #include <stdio.h>
28303 #include <time.h>
28304 #include <wchar.h>
28305
28306 "
28307 if test "x$ac_cv_have_decl_mbsrtowcs" = xyes; then :
28308   ac_have_decl=1
28309 else
28310   ac_have_decl=0
28311 fi
28312
28313 cat >>confdefs.h <<_ACEOF
28314 #define HAVE_DECL_MBSRTOWCS $ac_have_decl
28315 _ACEOF
28316
28317     if test $ac_cv_have_decl_mbsrtowcs = yes; then
28318                         REPLACE_MBSRTOWCS=1
28319     fi
28320   else
28321     if test $REPLACE_MBSTATE_T = 1; then
28322       REPLACE_MBSRTOWCS=1
28323     else
28324
28325
28326
28327
28328
28329
28330      { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbsrtowcs works" >&5
28331 $as_echo_n "checking whether mbsrtowcs works... " >&6; }
28332 if ${gl_cv_func_mbsrtowcs_works+:} false; then :
28333   $as_echo_n "(cached) " >&6
28334 else
28335
28336                   case "$host_os" in
28337                                    # Guess no on HP-UX, Solaris, mingw.
28338         hpux* | solaris* | mingw*) gl_cv_func_mbsrtowcs_works="guessing no" ;;
28339                                    # Guess yes otherwise.
28340         *)                         gl_cv_func_mbsrtowcs_works="guessing yes" ;;
28341       esac
28342       if test $LOCALE_FR != none || test $LOCALE_FR_UTF8 != none || test $LOCALE_JA != none || test $LOCALE_ZH_CN != none; then
28343         if test "$cross_compiling" = yes; then :
28344   :
28345 else
28346   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28347 /* end confdefs.h.  */
28348
28349 #include <locale.h>
28350 #include <string.h>
28351 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
28352    <wchar.h>.
28353    BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
28354    included before <wchar.h>.  */
28355 #include <stddef.h>
28356 #include <stdio.h>
28357 #include <time.h>
28358 #include <wchar.h>
28359 int main ()
28360 {
28361   int result = 0;
28362   /* Test whether the function supports a NULL destination argument.
28363      This fails on native Windows.  */
28364   if (setlocale (LC_ALL, "$LOCALE_FR") != NULL)
28365     {
28366       const char input[] = "\337er";
28367       const char *src = input;
28368       mbstate_t state;
28369
28370       memset (&state, '\0', sizeof (mbstate_t));
28371       if (mbsrtowcs (NULL, &src, 1, &state) != 3
28372           || src != input)
28373         result |= 1;
28374     }
28375   /* Test whether the function works when started with a conversion state
28376      in non-initial state.  This fails on HP-UX 11.11 and Solaris 10.  */
28377   if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
28378     {
28379       const char input[] = "B\303\274\303\237er";
28380       mbstate_t state;
28381
28382       memset (&state, '\0', sizeof (mbstate_t));
28383       if (mbrtowc (NULL, input + 1, 1, &state) == (size_t)(-2))
28384         if (!mbsinit (&state))
28385           {
28386             const char *src = input + 2;
28387             if (mbsrtowcs (NULL, &src, 10, &state) != 4)
28388               result |= 2;
28389           }
28390     }
28391   if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
28392     {
28393       const char input[] = "<\306\374\313\334\270\354>";
28394       mbstate_t state;
28395
28396       memset (&state, '\0', sizeof (mbstate_t));
28397       if (mbrtowc (NULL, input + 3, 1, &state) == (size_t)(-2))
28398         if (!mbsinit (&state))
28399           {
28400             const char *src = input + 4;
28401             if (mbsrtowcs (NULL, &src, 10, &state) != 3)
28402               result |= 4;
28403           }
28404     }
28405   if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
28406     {
28407       const char input[] = "B\250\271\201\060\211\070er";
28408       mbstate_t state;
28409
28410       memset (&state, '\0', sizeof (mbstate_t));
28411       if (mbrtowc (NULL, input + 1, 1, &state) == (size_t)(-2))
28412         if (!mbsinit (&state))
28413           {
28414             const char *src = input + 2;
28415             if (mbsrtowcs (NULL, &src, 10, &state) != 4)
28416               result |= 8;
28417           }
28418     }
28419   return result;
28420 }
28421 _ACEOF
28422 if ac_fn_c_try_run "$LINENO"; then :
28423   gl_cv_func_mbsrtowcs_works=yes
28424 else
28425   gl_cv_func_mbsrtowcs_works=no
28426 fi
28427 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28428   conftest.$ac_objext conftest.beam conftest.$ac_ext
28429 fi
28430
28431       fi
28432
28433 fi
28434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbsrtowcs_works" >&5
28435 $as_echo "$gl_cv_func_mbsrtowcs_works" >&6; }
28436
28437       case "$gl_cv_func_mbsrtowcs_works" in
28438         *yes) ;;
28439         *) REPLACE_MBSRTOWCS=1 ;;
28440       esac
28441     fi
28442   fi
28443
28444   if test $HAVE_MBSRTOWCS = 0 || test $REPLACE_MBSRTOWCS = 1; then
28445
28446
28447
28448
28449
28450
28451
28452
28453   gl_LIBOBJS="$gl_LIBOBJS mbsrtowcs.$ac_objext"
28454
28455
28456
28457
28458
28459
28460
28461
28462
28463   gl_LIBOBJS="$gl_LIBOBJS mbsrtowcs-state.$ac_objext"
28464
28465
28466   :
28467
28468   fi
28469
28470
28471
28472
28473
28474           GNULIB_MBSRTOWCS=1
28475
28476
28477
28478
28479
28480 $as_echo "#define GNULIB_TEST_MBSRTOWCS 1" >>confdefs.h
28481
28482
28483
28484
28485
28486
28487   if false; then
28488     REPLACE_MBTOWC=1
28489   fi
28490
28491   if test $REPLACE_MBTOWC = 1; then
28492
28493
28494
28495
28496
28497
28498
28499
28500   gl_LIBOBJS="$gl_LIBOBJS mbtowc.$ac_objext"
28501
28502
28503   :
28504
28505   fi
28506
28507
28508
28509
28510
28511           GNULIB_MBTOWC=1
28512
28513
28514
28515
28516
28517 $as_echo "#define GNULIB_TEST_MBTOWC 1" >>confdefs.h
28518
28519
28520
28521
28522   if test $HAVE_MEMCHR = 0 || test $REPLACE_MEMCHR = 1; then
28523
28524
28525
28526
28527
28528
28529
28530
28531   gl_LIBOBJS="$gl_LIBOBJS memchr.$ac_objext"
28532
28533
28534   for ac_header in bp-sym.h
28535 do :
28536   ac_fn_c_check_header_mongrel "$LINENO" "bp-sym.h" "ac_cv_header_bp_sym_h" "$ac_includes_default"
28537 if test "x$ac_cv_header_bp_sym_h" = xyes; then :
28538   cat >>confdefs.h <<_ACEOF
28539 #define HAVE_BP_SYM_H 1
28540 _ACEOF
28541
28542 fi
28543
28544 done
28545
28546
28547   fi
28548
28549
28550
28551
28552
28553           GNULIB_MEMCHR=1
28554
28555
28556
28557
28558
28559 $as_echo "#define GNULIB_TEST_MEMCHR 1" >>confdefs.h
28560
28561
28562
28563
28564
28565   :
28566
28567
28568
28569
28570
28571
28572
28573
28574   for ac_func in mkdtemp
28575 do :
28576   ac_fn_c_check_func "$LINENO" "mkdtemp" "ac_cv_func_mkdtemp"
28577 if test "x$ac_cv_func_mkdtemp" = xyes; then :
28578   cat >>confdefs.h <<_ACEOF
28579 #define HAVE_MKDTEMP 1
28580 _ACEOF
28581
28582 fi
28583 done
28584
28585   if test $ac_cv_func_mkdtemp = no; then
28586     HAVE_MKDTEMP=0
28587   fi
28588
28589   if test $HAVE_MKDTEMP = 0; then
28590
28591
28592
28593
28594
28595
28596
28597
28598   gl_LIBOBJS="$gl_LIBOBJS mkdtemp.$ac_objext"
28599
28600     :
28601
28602   fi
28603
28604
28605
28606
28607
28608           GNULIB_MKDTEMP=1
28609
28610
28611
28612
28613
28614 $as_echo "#define GNULIB_TEST_MKDTEMP 1" >>confdefs.h
28615
28616
28617
28618
28619
28620
28621
28622
28623
28624   :
28625
28626
28627
28628
28629
28630   if test $ac_cv_func_mkostemp != yes; then
28631     HAVE_MKOSTEMP=0
28632   fi
28633
28634   if test $HAVE_MKOSTEMP = 0; then
28635
28636
28637
28638
28639
28640
28641
28642
28643   gl_LIBOBJS="$gl_LIBOBJS mkostemp.$ac_objext"
28644
28645
28646
28647   fi
28648
28649
28650 cat >>confdefs.h <<_ACEOF
28651 #define GNULIB_MKOSTEMP 1
28652 _ACEOF
28653
28654
28655
28656
28657
28658
28659
28660           GNULIB_MKOSTEMP=1
28661
28662
28663
28664
28665
28666 $as_echo "#define GNULIB_TEST_MKOSTEMP 1" >>confdefs.h
28667
28668
28669
28670
28671
28672
28673
28674
28675
28676   :
28677
28678
28679
28680
28681
28682   if test $ac_cv_func_mkostemps != yes; then
28683     HAVE_MKOSTEMPS=0
28684   fi
28685
28686   if test $HAVE_MKOSTEMPS = 0; then
28687
28688
28689
28690
28691
28692
28693
28694
28695   gl_LIBOBJS="$gl_LIBOBJS mkostemps.$ac_objext"
28696
28697   fi
28698
28699
28700 cat >>confdefs.h <<_ACEOF
28701 #define GNULIB_MKOSTEMPS 1
28702 _ACEOF
28703
28704
28705
28706
28707
28708
28709
28710           GNULIB_MKOSTEMPS=1
28711
28712
28713
28714
28715
28716 $as_echo "#define GNULIB_TEST_MKOSTEMPS 1" >>confdefs.h
28717
28718
28719
28720
28721
28722
28723
28724   :
28725
28726
28727
28728
28729
28730
28731   :
28732
28733
28734
28735
28736
28737
28738   if test $APPLE_UNIVERSAL_BUILD = 1; then
28739     # A universal build on Apple Mac OS X platforms.
28740     # The test result would be 'yes' in 32-bit mode and 'no' in 64-bit mode.
28741     # But we need a configuration result that is valid in both modes.
28742     gl_cv_func_working_mktime=no
28743   fi
28744   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mktime" >&5
28745 $as_echo_n "checking for working mktime... " >&6; }
28746 if ${gl_cv_func_working_mktime+:} false; then :
28747   $as_echo_n "(cached) " >&6
28748 else
28749   if test "$cross_compiling" = yes; then :
28750   gl_cv_func_working_mktime=no
28751 else
28752   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28753 /* end confdefs.h.  */
28754 /* Test program from Paul Eggert and Tony Leneis.  */
28755 #include <limits.h>
28756 #include <stdlib.h>
28757 #include <time.h>
28758
28759 #ifdef HAVE_UNISTD_H
28760 # include <unistd.h>
28761 #endif
28762
28763 #if HAVE_DECL_ALARM
28764 # include <signal.h>
28765 #endif
28766
28767 /* Work around redefinition to rpl_putenv by other config tests.  */
28768 #undef putenv
28769
28770 static time_t time_t_max;
28771 static time_t time_t_min;
28772
28773 /* Values we'll use to set the TZ environment variable.  */
28774 static char *tz_strings[] = {
28775   (char *) 0, "TZ=GMT0", "TZ=JST-9",
28776   "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
28777 };
28778 #define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
28779
28780 /* Return 0 if mktime fails to convert a date in the spring-forward gap.
28781    Based on a problem report from Andreas Jaeger.  */
28782 static int
28783 spring_forward_gap ()
28784 {
28785   /* glibc (up to about 1998-10-07) failed this test. */
28786   struct tm tm;
28787
28788   /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
28789      instead of "TZ=America/Vancouver" in order to detect the bug even
28790      on systems that don't support the Olson extension, or don't have the
28791      full zoneinfo tables installed.  */
28792   putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
28793
28794   tm.tm_year = 98;
28795   tm.tm_mon = 3;
28796   tm.tm_mday = 5;
28797   tm.tm_hour = 2;
28798   tm.tm_min = 0;
28799   tm.tm_sec = 0;
28800   tm.tm_isdst = -1;
28801   return mktime (&tm) != (time_t) -1;
28802 }
28803
28804 static int
28805 mktime_test1 (time_t now)
28806 {
28807   struct tm *lt;
28808   return ! (lt = localtime (&now)) || mktime (lt) == now;
28809 }
28810
28811 static int
28812 mktime_test (time_t now)
28813 {
28814   return (mktime_test1 (now)
28815           && mktime_test1 ((time_t) (time_t_max - now))
28816           && mktime_test1 ((time_t) (time_t_min + now)));
28817 }
28818
28819 static int
28820 irix_6_4_bug ()
28821 {
28822   /* Based on code from Ariel Faigon.  */
28823   struct tm tm;
28824   tm.tm_year = 96;
28825   tm.tm_mon = 3;
28826   tm.tm_mday = 0;
28827   tm.tm_hour = 0;
28828   tm.tm_min = 0;
28829   tm.tm_sec = 0;
28830   tm.tm_isdst = -1;
28831   mktime (&tm);
28832   return tm.tm_mon == 2 && tm.tm_mday == 31;
28833 }
28834
28835 static int
28836 bigtime_test (int j)
28837 {
28838   struct tm tm;
28839   time_t now;
28840   tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
28841   now = mktime (&tm);
28842   if (now != (time_t) -1)
28843     {
28844       struct tm *lt = localtime (&now);
28845       if (! (lt
28846              && lt->tm_year == tm.tm_year
28847              && lt->tm_mon == tm.tm_mon
28848              && lt->tm_mday == tm.tm_mday
28849              && lt->tm_hour == tm.tm_hour
28850              && lt->tm_min == tm.tm_min
28851              && lt->tm_sec == tm.tm_sec
28852              && lt->tm_yday == tm.tm_yday
28853              && lt->tm_wday == tm.tm_wday
28854              && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
28855                   == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
28856         return 0;
28857     }
28858   return 1;
28859 }
28860
28861 static int
28862 year_2050_test ()
28863 {
28864   /* The correct answer for 2050-02-01 00:00:00 in Pacific time,
28865      ignoring leap seconds.  */
28866   unsigned long int answer = 2527315200UL;
28867
28868   struct tm tm;
28869   time_t t;
28870   tm.tm_year = 2050 - 1900;
28871   tm.tm_mon = 2 - 1;
28872   tm.tm_mday = 1;
28873   tm.tm_hour = tm.tm_min = tm.tm_sec = 0;
28874   tm.tm_isdst = -1;
28875
28876   /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
28877      instead of "TZ=America/Vancouver" in order to detect the bug even
28878      on systems that don't support the Olson extension, or don't have the
28879      full zoneinfo tables installed.  */
28880   putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
28881
28882   t = mktime (&tm);
28883
28884   /* Check that the result is either a failure, or close enough
28885      to the correct answer that we can assume the discrepancy is
28886      due to leap seconds.  */
28887   return (t == (time_t) -1
28888           || (0 < t && answer - 120 <= t && t <= answer + 120));
28889 }
28890
28891 int
28892 main ()
28893 {
28894   int result = 0;
28895   time_t t, delta;
28896   int i, j;
28897   int time_t_signed_magnitude = (time_t) ~ (time_t) 0 < (time_t) -1;
28898   int time_t_signed = ! ((time_t) 0 < (time_t) -1);
28899
28900 #if HAVE_DECL_ALARM
28901   /* This test makes some buggy mktime implementations loop.
28902      Give up after 60 seconds; a mktime slower than that
28903      isn't worth using anyway.  */
28904   signal (SIGALRM, SIG_DFL);
28905   alarm (60);
28906 #endif
28907
28908   time_t_max = (! time_t_signed
28909                 ? (time_t) -1
28910                 : ((((time_t) 1 << (sizeof (time_t) * CHAR_BIT - 2)) - 1)
28911                    * 2 + 1));
28912   time_t_min = (! time_t_signed
28913                 ? (time_t) 0
28914                 : time_t_signed_magnitude
28915                 ? ~ (time_t) 0
28916                 : ~ time_t_max);
28917
28918   delta = time_t_max / 997; /* a suitable prime number */
28919   for (i = 0; i < N_STRINGS; i++)
28920     {
28921       if (tz_strings[i])
28922         putenv (tz_strings[i]);
28923
28924       for (t = 0; t <= time_t_max - delta && (result & 1) == 0; t += delta)
28925         if (! mktime_test (t))
28926           result |= 1;
28927       if ((result & 2) == 0
28928           && ! (mktime_test ((time_t) 1)
28929                 && mktime_test ((time_t) (60 * 60))
28930                 && mktime_test ((time_t) (60 * 60 * 24))))
28931         result |= 2;
28932
28933       for (j = 1; (result & 4) == 0; j <<= 1)
28934         {
28935           if (! bigtime_test (j))
28936             result |= 4;
28937           if (INT_MAX / 2 < j)
28938             break;
28939         }
28940       if ((result & 8) == 0 && ! bigtime_test (INT_MAX))
28941         result |= 8;
28942     }
28943   if (! irix_6_4_bug ())
28944     result |= 16;
28945   if (! spring_forward_gap ())
28946     result |= 32;
28947   if (! year_2050_test ())
28948     result |= 64;
28949   return result;
28950 }
28951 _ACEOF
28952 if ac_fn_c_try_run "$LINENO"; then :
28953   gl_cv_func_working_mktime=yes
28954 else
28955   gl_cv_func_working_mktime=no
28956 fi
28957 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28958   conftest.$ac_objext conftest.beam conftest.$ac_ext
28959 fi
28960
28961
28962 fi
28963 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_mktime" >&5
28964 $as_echo "$gl_cv_func_working_mktime" >&6; }
28965
28966   if test $gl_cv_func_working_mktime = no; then
28967     REPLACE_MKTIME=1
28968   else
28969     REPLACE_MKTIME=0
28970   fi
28971
28972   if test $REPLACE_MKTIME = 1; then
28973
28974
28975
28976
28977
28978
28979
28980
28981   gl_LIBOBJS="$gl_LIBOBJS mktime.$ac_objext"
28982
28983     :
28984   fi
28985
28986
28987
28988
28989
28990           GNULIB_MKTIME=1
28991
28992
28993
28994
28995
28996 $as_echo "#define GNULIB_TEST_MKTIME 1" >>confdefs.h
28997
28998
28999
29000
29001
29002   if test $REPLACE_MKTIME = 0; then
29003         ac_fn_c_check_func "$LINENO" "__mktime_internal" "ac_cv_func___mktime_internal"
29004 if test "x$ac_cv_func___mktime_internal" = xyes; then :
29005
29006 $as_echo "#define mktime_internal __mktime_internal" >>confdefs.h
29007
29008
29009 else
29010                 REPLACE_MKTIME=1
29011
29012 fi
29013
29014   fi
29015
29016   if test $REPLACE_MKTIME = 1; then
29017
29018
29019
29020
29021
29022
29023
29024
29025   gl_LIBOBJS="$gl_LIBOBJS mktime.$ac_objext"
29026
29027     :
29028   fi
29029
29030
29031   :
29032
29033
29034
29035
29036
29037   if test $ac_cv_func__set_invalid_parameter_handler = yes; then
29038     HAVE_MSVC_INVALID_PARAMETER_HANDLER=1
29039
29040 $as_echo "#define HAVE_MSVC_INVALID_PARAMETER_HANDLER 1" >>confdefs.h
29041
29042   else
29043     HAVE_MSVC_INVALID_PARAMETER_HANDLER=0
29044   fi
29045
29046
29047   if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
29048
29049
29050
29051
29052
29053
29054
29055
29056   gl_LIBOBJS="$gl_LIBOBJS msvc-inval.$ac_objext"
29057
29058   fi
29059
29060
29061
29062   if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
29063
29064
29065
29066
29067
29068
29069
29070
29071   gl_LIBOBJS="$gl_LIBOBJS msvc-nothrow.$ac_objext"
29072
29073   fi
29074
29075
29076   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <net/if.h> is self-contained" >&5
29077 $as_echo_n "checking whether <net/if.h> is self-contained... " >&6; }
29078 if ${gl_cv_header_net_if_h_selfcontained+:} false; then :
29079   $as_echo_n "(cached) " >&6
29080 else
29081
29082       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29083 /* end confdefs.h.  */
29084 #include <net/if.h>
29085 int
29086 main ()
29087 {
29088
29089   ;
29090   return 0;
29091 }
29092 _ACEOF
29093 if ac_fn_c_try_compile "$LINENO"; then :
29094   gl_cv_header_net_if_h_selfcontained=yes
29095 else
29096   gl_cv_header_net_if_h_selfcontained=no
29097 fi
29098 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29099
29100 fi
29101 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_net_if_h_selfcontained" >&5
29102 $as_echo "$gl_cv_header_net_if_h_selfcontained" >&6; }
29103   if test $gl_cv_header_net_if_h_selfcontained = yes; then
29104     NET_IF_H=''
29105   else
29106     NET_IF_H='net/if.h'
29107     for ac_header in net/if.h
29108 do :
29109   ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "#include <sys/socket.h>
29110 "
29111 if test "x$ac_cv_header_net_if_h" = xyes; then :
29112   cat >>confdefs.h <<_ACEOF
29113 #define HAVE_NET_IF_H 1
29114 _ACEOF
29115
29116 fi
29117
29118 done
29119
29120
29121
29122
29123
29124
29125
29126
29127
29128      if test $gl_cv_have_include_next = yes; then
29129        gl_cv_next_net_if_h='<'net/if.h'>'
29130      else
29131        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <net/if.h>" >&5
29132 $as_echo_n "checking absolute name of <net/if.h>... " >&6; }
29133 if ${gl_cv_next_net_if_h+:} false; then :
29134   $as_echo_n "(cached) " >&6
29135 else
29136
29137
29138
29139   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29140 /* end confdefs.h.  */
29141 #include <net/if.h>
29142 _ACEOF
29143                 case "$host_os" in
29144     aix*) gl_absname_cpp="$ac_cpp -C" ;;
29145     *)    gl_absname_cpp="$ac_cpp" ;;
29146   esac
29147
29148   case "$host_os" in
29149     mingw*)
29150                                           gl_dirsep_regex='[/\\]'
29151       ;;
29152     *)
29153       gl_dirsep_regex='\/'
29154       ;;
29155   esac
29156       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
29157   gl_header_literal_regex=`echo 'net/if.h' \
29158                            | sed -e "$gl_make_literal_regex_sed"`
29159   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
29160       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
29161       s|^/[^/]|//&|
29162       p
29163       q
29164     }'
29165
29166         gl_cv_absolute_net_if_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
29167   sed -n "$gl_absolute_header_sed"`
29168
29169            gl_header=$gl_cv_absolute_net_if_h
29170            gl_cv_next_net_if_h='"'$gl_header'"'
29171
29172
29173 fi
29174 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_net_if_h" >&5
29175 $as_echo "$gl_cv_next_net_if_h" >&6; }
29176      fi
29177      NEXT_NET_IF_H=$gl_cv_next_net_if_h
29178
29179      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
29180        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
29181        gl_next_as_first_directive='<'net/if.h'>'
29182      else
29183        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
29184        gl_next_as_first_directive=$gl_cv_next_net_if_h
29185      fi
29186      NEXT_AS_FIRST_DIRECTIVE_NET_IF_H=$gl_next_as_first_directive
29187
29188
29189
29190
29191     if test $ac_cv_header_net_if_h = yes; then
29192       HAVE_NET_IF_H=1
29193     else
29194       HAVE_NET_IF_H=0
29195     fi
29196
29197   fi
29198
29199    if test -n "$NET_IF_H"; then
29200   GL_GENERATE_NET_IF_H_TRUE=
29201   GL_GENERATE_NET_IF_H_FALSE='#'
29202 else
29203   GL_GENERATE_NET_IF_H_TRUE='#'
29204   GL_GENERATE_NET_IF_H_FALSE=
29205 fi
29206
29207
29208
29209
29210
29211
29212
29213
29214
29215
29216
29217   :
29218
29219
29220
29221
29222
29223
29224
29225
29226      if test $gl_cv_have_include_next = yes; then
29227        gl_cv_next_netdb_h='<'netdb.h'>'
29228      else
29229        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <netdb.h>" >&5
29230 $as_echo_n "checking absolute name of <netdb.h>... " >&6; }
29231 if ${gl_cv_next_netdb_h+:} false; then :
29232   $as_echo_n "(cached) " >&6
29233 else
29234
29235              if test $ac_cv_header_netdb_h = yes; then
29236
29237
29238
29239
29240   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29241 /* end confdefs.h.  */
29242 #include <netdb.h>
29243 _ACEOF
29244                 case "$host_os" in
29245     aix*) gl_absname_cpp="$ac_cpp -C" ;;
29246     *)    gl_absname_cpp="$ac_cpp" ;;
29247   esac
29248
29249   case "$host_os" in
29250     mingw*)
29251                                           gl_dirsep_regex='[/\\]'
29252       ;;
29253     *)
29254       gl_dirsep_regex='\/'
29255       ;;
29256   esac
29257       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
29258   gl_header_literal_regex=`echo 'netdb.h' \
29259                            | sed -e "$gl_make_literal_regex_sed"`
29260   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
29261       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
29262       s|^/[^/]|//&|
29263       p
29264       q
29265     }'
29266
29267         gl_cv_absolute_netdb_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
29268   sed -n "$gl_absolute_header_sed"`
29269
29270            gl_header=$gl_cv_absolute_netdb_h
29271            gl_cv_next_netdb_h='"'$gl_header'"'
29272           else
29273                gl_cv_next_netdb_h='<'netdb.h'>'
29274              fi
29275
29276
29277 fi
29278 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_netdb_h" >&5
29279 $as_echo "$gl_cv_next_netdb_h" >&6; }
29280      fi
29281      NEXT_NETDB_H=$gl_cv_next_netdb_h
29282
29283      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
29284        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
29285        gl_next_as_first_directive='<'netdb.h'>'
29286      else
29287        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
29288        gl_next_as_first_directive=$gl_cv_next_netdb_h
29289      fi
29290      NEXT_AS_FIRST_DIRECTIVE_NETDB_H=$gl_next_as_first_directive
29291
29292
29293
29294
29295   if test $ac_cv_header_netdb_h = yes; then
29296     HAVE_NETDB_H=1
29297   else
29298     HAVE_NETDB_H=0
29299   fi
29300
29301
29302
29303
29304
29305   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <netinet/in.h> is self-contained" >&5
29306 $as_echo_n "checking whether <netinet/in.h> is self-contained... " >&6; }
29307 if ${gl_cv_header_netinet_in_h_selfcontained+:} false; then :
29308   $as_echo_n "(cached) " >&6
29309 else
29310
29311       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29312 /* end confdefs.h.  */
29313 #include <netinet/in.h>
29314 int
29315 main ()
29316 {
29317
29318   ;
29319   return 0;
29320 }
29321 _ACEOF
29322 if ac_fn_c_try_compile "$LINENO"; then :
29323   gl_cv_header_netinet_in_h_selfcontained=yes
29324 else
29325   gl_cv_header_netinet_in_h_selfcontained=no
29326 fi
29327 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29328
29329 fi
29330 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_netinet_in_h_selfcontained" >&5
29331 $as_echo "$gl_cv_header_netinet_in_h_selfcontained" >&6; }
29332   if test $gl_cv_header_netinet_in_h_selfcontained = yes; then
29333     NETINET_IN_H=''
29334   else
29335     NETINET_IN_H='netinet/in.h'
29336     for ac_header in netinet/in.h
29337 do :
29338   ac_fn_c_check_header_mongrel "$LINENO" "netinet/in.h" "ac_cv_header_netinet_in_h" "$ac_includes_default"
29339 if test "x$ac_cv_header_netinet_in_h" = xyes; then :
29340   cat >>confdefs.h <<_ACEOF
29341 #define HAVE_NETINET_IN_H 1
29342 _ACEOF
29343
29344 fi
29345
29346 done
29347
29348
29349
29350
29351
29352
29353
29354   :
29355
29356
29357
29358
29359
29360
29361
29362
29363      if test $gl_cv_have_include_next = yes; then
29364        gl_cv_next_netinet_in_h='<'netinet/in.h'>'
29365      else
29366        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <netinet/in.h>" >&5
29367 $as_echo_n "checking absolute name of <netinet/in.h>... " >&6; }
29368 if ${gl_cv_next_netinet_in_h+:} false; then :
29369   $as_echo_n "(cached) " >&6
29370 else
29371
29372              if test $ac_cv_header_netinet_in_h = yes; then
29373
29374
29375
29376
29377   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29378 /* end confdefs.h.  */
29379 #include <netinet/in.h>
29380 _ACEOF
29381                 case "$host_os" in
29382     aix*) gl_absname_cpp="$ac_cpp -C" ;;
29383     *)    gl_absname_cpp="$ac_cpp" ;;
29384   esac
29385
29386   case "$host_os" in
29387     mingw*)
29388                                           gl_dirsep_regex='[/\\]'
29389       ;;
29390     *)
29391       gl_dirsep_regex='\/'
29392       ;;
29393   esac
29394       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
29395   gl_header_literal_regex=`echo 'netinet/in.h' \
29396                            | sed -e "$gl_make_literal_regex_sed"`
29397   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
29398       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
29399       s|^/[^/]|//&|
29400       p
29401       q
29402     }'
29403
29404         gl_cv_absolute_netinet_in_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
29405   sed -n "$gl_absolute_header_sed"`
29406
29407            gl_header=$gl_cv_absolute_netinet_in_h
29408            gl_cv_next_netinet_in_h='"'$gl_header'"'
29409           else
29410                gl_cv_next_netinet_in_h='<'netinet/in.h'>'
29411              fi
29412
29413
29414 fi
29415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_netinet_in_h" >&5
29416 $as_echo "$gl_cv_next_netinet_in_h" >&6; }
29417      fi
29418      NEXT_NETINET_IN_H=$gl_cv_next_netinet_in_h
29419
29420      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
29421        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
29422        gl_next_as_first_directive='<'netinet/in.h'>'
29423      else
29424        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
29425        gl_next_as_first_directive=$gl_cv_next_netinet_in_h
29426      fi
29427      NEXT_AS_FIRST_DIRECTIVE_NETINET_IN_H=$gl_next_as_first_directive
29428
29429
29430
29431
29432     if test $ac_cv_header_netinet_in_h = yes; then
29433       HAVE_NETINET_IN_H=1
29434     else
29435       HAVE_NETINET_IN_H=0
29436     fi
29437
29438   fi
29439
29440    if test -n "$NETINET_IN_H"; then
29441   GL_GENERATE_NETINET_IN_H_TRUE=
29442   GL_GENERATE_NETINET_IN_H_FALSE='#'
29443 else
29444   GL_GENERATE_NETINET_IN_H_TRUE='#'
29445   GL_GENERATE_NETINET_IN_H_FALSE=
29446 fi
29447
29448
29449
29450
29451
29452
29453
29454   :
29455
29456
29457
29458
29459
29460      if test $ac_cv_func_nl_langinfo = yes; then
29461     # On Irix 6.5, YESEXPR is defined, but nl_langinfo(YESEXPR) is broken.
29462     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether YESEXPR works" >&5
29463 $as_echo_n "checking whether YESEXPR works... " >&6; }
29464 if ${gl_cv_func_nl_langinfo_yesexpr_works+:} false; then :
29465   $as_echo_n "(cached) " >&6
29466 else
29467   if test "$cross_compiling" = yes; then :
29468
29469          case "$host_os" in
29470                    # Guess no on irix systems.
29471            irix*)  gl_cv_func_nl_langinfo_yesexpr_works="guessing no";;
29472                    # Guess yes elsewhere.
29473            *)      gl_cv_func_nl_langinfo_yesexpr_works="guessing yes";;
29474          esac
29475
29476 else
29477   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29478 /* end confdefs.h.  */
29479 #include <langinfo.h>
29480
29481 int
29482 main ()
29483 {
29484 return !*nl_langinfo(YESEXPR);
29485
29486   ;
29487   return 0;
29488 }
29489 _ACEOF
29490 if ac_fn_c_try_run "$LINENO"; then :
29491   gl_cv_func_nl_langinfo_yesexpr_works=yes
29492 else
29493   gl_cv_func_nl_langinfo_yesexpr_works=no
29494 fi
29495 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
29496   conftest.$ac_objext conftest.beam conftest.$ac_ext
29497 fi
29498
29499
29500 fi
29501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_nl_langinfo_yesexpr_works" >&5
29502 $as_echo "$gl_cv_func_nl_langinfo_yesexpr_works" >&6; }
29503     case $gl_cv_func_nl_langinfo_yesexpr_works in
29504       *yes) FUNC_NL_LANGINFO_YESEXPR_WORKS=1 ;;
29505       *)    FUNC_NL_LANGINFO_YESEXPR_WORKS=0 ;;
29506     esac
29507
29508 cat >>confdefs.h <<_ACEOF
29509 #define FUNC_NL_LANGINFO_YESEXPR_WORKS $FUNC_NL_LANGINFO_YESEXPR_WORKS
29510 _ACEOF
29511
29512     if test $HAVE_LANGINFO_CODESET = 1 && test $HAVE_LANGINFO_ERA = 1 \
29513         && test $FUNC_NL_LANGINFO_YESEXPR_WORKS = 1; then
29514       :
29515     else
29516       REPLACE_NL_LANGINFO=1
29517
29518 $as_echo "#define REPLACE_NL_LANGINFO 1" >>confdefs.h
29519
29520     fi
29521   else
29522     HAVE_NL_LANGINFO=0
29523   fi
29524
29525   if test $HAVE_NL_LANGINFO = 0 || test $REPLACE_NL_LANGINFO = 1; then
29526
29527
29528
29529
29530
29531
29532
29533
29534   gl_LIBOBJS="$gl_LIBOBJS nl_langinfo.$ac_objext"
29535
29536   fi
29537
29538
29539
29540
29541
29542           GNULIB_NL_LANGINFO=1
29543
29544
29545
29546
29547
29548 $as_echo "#define GNULIB_TEST_NL_LANGINFO 1" >>confdefs.h
29549
29550
29551
29552
29553
29554
29555
29556
29557
29558
29559
29560           GNULIB_NONBLOCKING=1
29561
29562
29563
29564
29565
29566 $as_echo "#define GNULIB_TEST_NONBLOCKING 1" >>confdefs.h
29567
29568
29569
29570
29571
29572 cat >>confdefs.h <<_ACEOF
29573 #define GNULIB_NONBLOCKING 1
29574 _ACEOF
29575
29576
29577
29578
29579   GNULIB_STDIO_H_NONBLOCKING=1
29580
29581   GNULIB_UNISTD_H_NONBLOCKING=1
29582
29583
29584   case "$host_os" in
29585     mingw* | pw*)
29586       REPLACE_OPEN=1
29587       ;;
29588     *)
29589
29590   :
29591
29592
29593
29594
29595
29596       { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether open recognizes a trailing slash" >&5
29597 $as_echo_n "checking whether open recognizes a trailing slash... " >&6; }
29598 if ${gl_cv_func_open_slash+:} false; then :
29599   $as_echo_n "(cached) " >&6
29600 else
29601   # Assume that if we have lstat, we can also check symlinks.
29602           if test $ac_cv_func_lstat = yes; then
29603             touch conftest.tmp
29604             ln -s conftest.tmp conftest.lnk
29605           fi
29606           if test "$cross_compiling" = yes; then :
29607
29608              case "$host_os" in
29609                freebsd* | aix* | hpux* | solaris2.[0-9] | solaris2.[0-9].*)
29610                  gl_cv_func_open_slash="guessing no" ;;
29611                *)
29612                  gl_cv_func_open_slash="guessing yes" ;;
29613              esac
29614
29615 else
29616   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29617 /* end confdefs.h.  */
29618
29619 #include <fcntl.h>
29620 #if HAVE_UNISTD_H
29621 # include <unistd.h>
29622 #endif
29623 int main ()
29624 {
29625   int result = 0;
29626 #if HAVE_LSTAT
29627   if (open ("conftest.lnk/", O_RDONLY) != -1)
29628     result |= 1;
29629 #endif
29630   if (open ("conftest.sl/", O_CREAT, 0600) >= 0)
29631     result |= 2;
29632   return result;
29633 }
29634 _ACEOF
29635 if ac_fn_c_try_run "$LINENO"; then :
29636   gl_cv_func_open_slash=yes
29637 else
29638   gl_cv_func_open_slash=no
29639 fi
29640 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
29641   conftest.$ac_objext conftest.beam conftest.$ac_ext
29642 fi
29643
29644           rm -f conftest.sl conftest.tmp conftest.lnk
29645
29646 fi
29647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_open_slash" >&5
29648 $as_echo "$gl_cv_func_open_slash" >&6; }
29649       case "$gl_cv_func_open_slash" in
29650         *no)
29651
29652 $as_echo "#define OPEN_TRAILING_SLASH_BUG 1" >>confdefs.h
29653
29654           REPLACE_OPEN=1
29655           ;;
29656       esac
29657       ;;
29658   esac
29659
29660
29661     if test $REPLACE_OPEN = 0; then
29662
29663
29664
29665       if test $gl_cv_have_open_O_NONBLOCK != yes; then
29666         REPLACE_OPEN=1
29667       fi
29668     fi
29669
29670
29671   if test $REPLACE_OPEN = 1; then
29672
29673
29674
29675
29676
29677
29678
29679
29680   gl_LIBOBJS="$gl_LIBOBJS open.$ac_objext"
29681
29682
29683
29684   :
29685
29686   fi
29687
29688
29689
29690
29691
29692           GNULIB_OPEN=1
29693
29694
29695
29696
29697
29698 $as_echo "#define GNULIB_TEST_OPEN 1" >>confdefs.h
29699
29700
29701
29702
29703
29704
29705
29706
29707
29708       ac_fn_c_check_decl "$LINENO" "openpty" "ac_cv_have_decl_openpty" "
29709 /* <sys/types.h> is a prerequisite of <libutil.h> on FreeBSD 8.0.  */
29710 #include <sys/types.h>
29711 #if HAVE_PTY_H
29712 # include <pty.h>
29713 #endif
29714 #if HAVE_UTIL_H
29715 # include <util.h>
29716 #endif
29717 #if HAVE_LIBUTIL_H
29718 # include <libutil.h>
29719 #endif
29720
29721 "
29722 if test "x$ac_cv_have_decl_openpty" = xyes; then :
29723   ac_have_decl=1
29724 else
29725   ac_have_decl=0
29726 fi
29727
29728 cat >>confdefs.h <<_ACEOF
29729 #define HAVE_DECL_OPENPTY $ac_have_decl
29730 _ACEOF
29731
29732   if test $ac_cv_have_decl_openpty = yes; then
29733
29734 $as_echo "#define HAVE_OPENPTY 1" >>confdefs.h
29735
29736             { $as_echo "$as_me:${as_lineno-$LINENO}: checking for const-safe openpty signature" >&5
29737 $as_echo_n "checking for const-safe openpty signature... " >&6; }
29738 if ${gl_cv_func_openpty_const+:} false; then :
29739   $as_echo_n "(cached) " >&6
29740 else
29741   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29742 /* end confdefs.h.  */
29743
29744 /* <sys/types.h> is a prerequisite of <libutil.h> on FreeBSD 8.0.  */
29745 #include <sys/types.h>
29746 #if HAVE_PTY_H
29747 # include <pty.h>
29748 #endif
29749 #if HAVE_UTIL_H
29750 # include <util.h>
29751 #endif
29752 #if HAVE_LIBUTIL_H
29753 # include <libutil.h>
29754 #endif
29755
29756 int
29757 main ()
29758 {
29759
29760             int openpty (int *, int *, char *, struct termios const *,
29761                        struct winsize const *);
29762
29763   ;
29764   return 0;
29765 }
29766
29767 _ACEOF
29768 if ac_fn_c_try_compile "$LINENO"; then :
29769   gl_cv_func_openpty_const=yes
29770 else
29771   gl_cv_func_openpty_const=no
29772 fi
29773 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29774
29775 fi
29776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_openpty_const" >&5
29777 $as_echo "$gl_cv_func_openpty_const" >&6; }
29778     if test $gl_cv_func_openpty_const != yes; then
29779       REPLACE_OPENPTY=1
29780     fi
29781   else
29782         HAVE_OPENPTY=0
29783         for ac_func in _getpty posix_openpt
29784 do :
29785   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
29786 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
29787 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
29788   cat >>confdefs.h <<_ACEOF
29789 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
29790 _ACEOF
29791
29792 fi
29793 done
29794
29795   fi
29796
29797   if test $HAVE_OPENPTY = 0 || test $REPLACE_OPENPTY = 1; then
29798
29799
29800
29801
29802
29803
29804
29805
29806   gl_LIBOBJS="$gl_LIBOBJS openpty.$ac_objext"
29807
29808   fi
29809
29810
29811
29812
29813
29814           GNULIB_OPENPTY=1
29815
29816
29817
29818
29819
29820 $as_echo "#define GNULIB_TEST_OPENPTY 1" >>confdefs.h
29821
29822
29823
29824
29825
29826
29827   :
29828
29829
29830
29831
29832
29833
29834
29835
29836
29837
29838 $as_echo "#define _LINUX_SOURCE_COMPAT 1" >>confdefs.h
29839
29840
29841       ac_fn_c_check_member "$LINENO" "struct msghdr" "msg_accrights" "ac_cv_member_struct_msghdr_msg_accrights" "
29842     #include <sys/types.h>
29843     #include <sys/socket.h>
29844
29845 "
29846 if test "x$ac_cv_member_struct_msghdr_msg_accrights" = xyes; then :
29847
29848 cat >>confdefs.h <<_ACEOF
29849 #define HAVE_STRUCT_MSGHDR_MSG_ACCRIGHTS 1
29850 _ACEOF
29851
29852
29853 fi
29854
29855
29856
29857
29858   :
29859
29860
29861
29862
29863
29864
29865
29866
29867
29868
29869
29870           if test "$ERRNO_H:$REPLACE_STRERROR_0" != :0; then
29871             REPLACE_PERROR=1
29872   fi
29873   case ${gl_cv_func_strerror_r_works-unset} in
29874     unset|*yes)
29875       { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether perror matches strerror" >&5
29876 $as_echo_n "checking whether perror matches strerror... " >&6; }
29877 if ${gl_cv_func_perror_works+:} false; then :
29878   $as_echo_n "(cached) " >&6
29879 else
29880   if test "$cross_compiling" = yes; then :
29881               gl_cv_func_perror_works="guessing no"
29882
29883 else
29884   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29885 /* end confdefs.h.  */
29886 #include <errno.h>
29887                 #include <stdio.h>
29888                 #include <stdlib.h>
29889                 #include <string.h>
29890
29891 int
29892 main ()
29893 {
29894 char *str = strerror (-1);
29895                 if (!getenv("CONFTEST_OUTPUT")) return 0;
29896                 if (!str) str = "";
29897                 puts (str);
29898                 errno = -1;
29899                 perror ("");
29900                 return 0;
29901
29902   ;
29903   return 0;
29904 }
29905 _ACEOF
29906 if ac_fn_c_try_run "$LINENO"; then :
29907   if CONFTEST_OUTPUT=1 ./conftest$EXEEXT >conftest.txt1 2>conftest.txt2 \
29908                && cmp conftest.txt1 conftest.txt2 >/dev/null; then
29909               gl_cv_func_perror_works=yes
29910             else
29911               gl_cv_func_perror_works=no
29912             fi
29913             rm -rf conftest.txt1 conftest.txt2
29914 else
29915   gl_cv_func_perror_works=no
29916 fi
29917 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
29918   conftest.$ac_objext conftest.beam conftest.$ac_ext
29919 fi
29920
29921
29922 fi
29923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_perror_works" >&5
29924 $as_echo "$gl_cv_func_perror_works" >&6; }
29925       if test "$gl_cv_func_perror_works" != yes; then
29926         REPLACE_PERROR=1
29927       fi
29928       ;;
29929     *)
29930                   REPLACE_PERROR=1
29931       ;;
29932   esac
29933
29934   if test $REPLACE_PERROR = 1; then
29935
29936
29937
29938
29939
29940
29941
29942
29943   gl_LIBOBJS="$gl_LIBOBJS perror.$ac_objext"
29944
29945   fi
29946
29947
29948
29949
29950
29951           GNULIB_PERROR=1
29952
29953
29954
29955
29956
29957 $as_echo "#define GNULIB_TEST_PERROR 1" >>confdefs.h
29958
29959
29960
29961
29962   # Prerequisites of lib/physmem.c.
29963   for ac_header in sys/pstat.h sys/sysmp.h sys/sysinfo.h \
29964     machine/hal_sysinfo.h sys/table.h sys/param.h sys/systemcfg.h
29965 do :
29966   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
29967 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
29968 "
29969 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
29970   cat >>confdefs.h <<_ACEOF
29971 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
29972 _ACEOF
29973
29974 fi
29975
29976 done
29977
29978     for ac_header in sys/sysctl.h
29979 do :
29980   ac_fn_c_check_header_compile "$LINENO" "sys/sysctl.h" "ac_cv_header_sys_sysctl_h" "$ac_includes_default
29981      #if HAVE_SYS_PARAM_H
29982      # include <sys/param.h>
29983      #endif
29984
29985 "
29986 if test "x$ac_cv_header_sys_sysctl_h" = xyes; then :
29987   cat >>confdefs.h <<_ACEOF
29988 #define HAVE_SYS_SYSCTL_H 1
29989 _ACEOF
29990
29991 fi
29992
29993 done
29994
29995
29996   for ac_func in pstat_getstatic pstat_getdynamic sysmp getsysinfo sysctl table sysinfo
29997 do :
29998   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
29999 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
30000 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
30001   cat >>confdefs.h <<_ACEOF
30002 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
30003 _ACEOF
30004
30005 fi
30006 done
30007
30008   ac_fn_c_check_member "$LINENO" "struct sysinfo" "mem_unit" "ac_cv_member_struct_sysinfo_mem_unit" "#include <sys/sysinfo.h>
30009 "
30010 if test "x$ac_cv_member_struct_sysinfo_mem_unit" = xyes; then :
30011
30012 cat >>confdefs.h <<_ACEOF
30013 #define HAVE_STRUCT_SYSINFO_MEM_UNIT 1
30014 _ACEOF
30015
30016
30017 fi
30018
30019
30020
30021
30022
30023
30024
30025   :
30026
30027
30028
30029
30030
30031   if test $ac_cv_func_pipe != yes; then
30032     HAVE_PIPE=0
30033   fi
30034
30035   if test $HAVE_PIPE = 0; then
30036
30037
30038
30039
30040
30041
30042
30043
30044   gl_LIBOBJS="$gl_LIBOBJS pipe.$ac_objext"
30045
30046   fi
30047
30048
30049
30050
30051
30052           GNULIB_PIPE=1
30053
30054
30055
30056
30057
30058 $as_echo "#define GNULIB_TEST_PIPE 1" >>confdefs.h
30059
30060
30061
30062
30063
30064
30065
30066
30067
30068   :
30069
30070
30071
30072
30073
30074   if test $ac_cv_func_pipe2 != yes; then
30075     HAVE_PIPE2=0
30076   fi
30077
30078
30079
30080
30081
30082
30083           GNULIB_PIPE2=1
30084
30085
30086
30087
30088
30089 $as_echo "#define GNULIB_TEST_PIPE2 1" >>confdefs.h
30090
30091
30092
30093
30094
30095
30096   if test $ac_cv_header_poll_h = no; then
30097     ac_cv_func_poll=no
30098     gl_cv_func_poll=no
30099   else
30100     ac_fn_c_check_func "$LINENO" "poll" "ac_cv_func_poll"
30101 if test "x$ac_cv_func_poll" = xyes; then :
30102   # Check whether poll() works on special files (like /dev/null) and
30103        # and ttys (like /dev/tty). On Mac OS X 10.4.0 and AIX 5.3, it doesn't.
30104        if test "$cross_compiling" = yes; then :
30105   # When cross-compiling, assume that poll() works everywhere except on
30106           # Mac OS X or AIX, regardless of its version.
30107           cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30108 /* end confdefs.h.  */
30109
30110 #if (defined(__APPLE__) && defined(__MACH__)) || defined(_AIX)
30111 This is MacOSX or AIX
30112 #endif
30113
30114 _ACEOF
30115 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
30116   $EGREP "MacOSX" >/dev/null 2>&1; then :
30117   gl_cv_func_poll=no
30118 else
30119   gl_cv_func_poll=yes
30120 fi
30121 rm -f conftest*
30122
30123 else
30124   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30125 /* end confdefs.h.  */
30126
30127 #include <fcntl.h>
30128 #include <poll.h>
30129          int main()
30130          {
30131            int result = 0;
30132            struct pollfd ufd;
30133            /* Try /dev/null for reading.  */
30134            ufd.fd = open ("/dev/null", O_RDONLY);
30135            /* If /dev/null does not exist, it's not Mac OS X nor AIX. */
30136            if (ufd.fd >= 0)
30137              {
30138                ufd.events = POLLIN;
30139                ufd.revents = 0;
30140                if (!(poll (&ufd, 1, 0) == 1 && ufd.revents == POLLIN))
30141                  result |= 1;
30142              }
30143            /* Try /dev/null for writing.  */
30144            ufd.fd = open ("/dev/null", O_WRONLY);
30145            /* If /dev/null does not exist, it's not Mac OS X nor AIX. */
30146            if (ufd.fd >= 0)
30147              {
30148                ufd.events = POLLOUT;
30149                ufd.revents = 0;
30150                if (!(poll (&ufd, 1, 0) == 1 && ufd.revents == POLLOUT))
30151                  result |= 2;
30152              }
30153            /* Trying /dev/tty may be too environment dependent.  */
30154            return result;
30155          }
30156 _ACEOF
30157 if ac_fn_c_try_run "$LINENO"; then :
30158   gl_cv_func_poll=yes
30159 else
30160   gl_cv_func_poll=no
30161 fi
30162 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
30163   conftest.$ac_objext conftest.beam conftest.$ac_ext
30164 fi
30165
30166 fi
30167
30168   fi
30169   if test $gl_cv_func_poll != yes; then
30170     ac_fn_c_check_func "$LINENO" "poll" "ac_cv_func_poll"
30171 if test "x$ac_cv_func_poll" = xyes; then :
30172   ac_cv_func_poll=yes
30173 else
30174   ac_cv_func_poll=no
30175 fi
30176
30177     if test $ac_cv_func_poll = no; then
30178       HAVE_POLL=0
30179     else
30180       REPLACE_POLL=1
30181     fi
30182   fi
30183   if test $HAVE_POLL = 0 || test $REPLACE_POLL = 1; then
30184     :
30185   else
30186
30187 $as_echo "#define HAVE_POLL 1" >>confdefs.h
30188
30189   fi
30190
30191     LIB_POLL="$LIBSOCKET"
30192   if test $HAVE_POLL = 0 || test $REPLACE_POLL = 1; then
30193     case "$host_os" in
30194       mingw*)
30195                                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30196 /* end confdefs.h.  */
30197
30198 #define WIN32_LEAN_AND_MEAN
30199 #include <windows.h>
30200 int
30201 main ()
30202 {
30203   MsgWaitForMultipleObjects (0, NULL, 0, 0, 0);
30204   return 0;
30205 }
30206 _ACEOF
30207 if ac_fn_c_try_link "$LINENO"; then :
30208
30209 else
30210   LIB_POLL="$LIB_POLL -luser32"
30211 fi
30212 rm -f core conftest.err conftest.$ac_objext \
30213     conftest$ac_exeext conftest.$ac_ext
30214         ;;
30215     esac
30216   fi
30217
30218
30219   if test $HAVE_POLL = 0 || test $REPLACE_POLL = 1; then
30220
30221
30222
30223
30224
30225
30226
30227
30228   gl_LIBOBJS="$gl_LIBOBJS poll.$ac_objext"
30229
30230
30231
30232   :
30233
30234
30235
30236
30237
30238
30239
30240
30241
30242   fi
30243
30244
30245
30246
30247
30248           GNULIB_POLL=1
30249
30250
30251
30252
30253
30254 $as_echo "#define GNULIB_TEST_POLL 1" >>confdefs.h
30255
30256
30257
30258
30259
30260
30261
30262   :
30263
30264
30265
30266
30267
30268   if test $ac_cv_header_poll_h = yes; then
30269     HAVE_POLL_H=1
30270   else
30271     HAVE_POLL_H=0
30272   fi
30273
30274
30275
30276
30277
30278
30279
30280
30281   :
30282
30283
30284
30285
30286
30287
30288
30289
30290      if test $gl_cv_have_include_next = yes; then
30291        gl_cv_next_poll_h='<'poll.h'>'
30292      else
30293        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <poll.h>" >&5
30294 $as_echo_n "checking absolute name of <poll.h>... " >&6; }
30295 if ${gl_cv_next_poll_h+:} false; then :
30296   $as_echo_n "(cached) " >&6
30297 else
30298
30299              if test $ac_cv_header_poll_h = yes; then
30300
30301
30302
30303
30304   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30305 /* end confdefs.h.  */
30306 #include <poll.h>
30307 _ACEOF
30308                 case "$host_os" in
30309     aix*) gl_absname_cpp="$ac_cpp -C" ;;
30310     *)    gl_absname_cpp="$ac_cpp" ;;
30311   esac
30312
30313   case "$host_os" in
30314     mingw*)
30315                                           gl_dirsep_regex='[/\\]'
30316       ;;
30317     *)
30318       gl_dirsep_regex='\/'
30319       ;;
30320   esac
30321       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
30322   gl_header_literal_regex=`echo 'poll.h' \
30323                            | sed -e "$gl_make_literal_regex_sed"`
30324   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
30325       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
30326       s|^/[^/]|//&|
30327       p
30328       q
30329     }'
30330
30331         gl_cv_absolute_poll_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
30332   sed -n "$gl_absolute_header_sed"`
30333
30334            gl_header=$gl_cv_absolute_poll_h
30335            gl_cv_next_poll_h='"'$gl_header'"'
30336           else
30337                gl_cv_next_poll_h='<'poll.h'>'
30338              fi
30339
30340
30341 fi
30342 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_poll_h" >&5
30343 $as_echo "$gl_cv_next_poll_h" >&6; }
30344      fi
30345      NEXT_POLL_H=$gl_cv_next_poll_h
30346
30347      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
30348        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
30349        gl_next_as_first_directive='<'poll.h'>'
30350      else
30351        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
30352        gl_next_as_first_directive=$gl_cv_next_poll_h
30353      fi
30354      NEXT_AS_FIRST_DIRECTIVE_POLL_H=$gl_next_as_first_directive
30355
30356
30357
30358
30359
30360
30361
30362
30363   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a shell that conforms to POSIX" >&5
30364 $as_echo_n "checking for a shell that conforms to POSIX... " >&6; }
30365 if ${gl_cv_posix_shell+:} false; then :
30366   $as_echo_n "(cached) " >&6
30367 else
30368   gl_test_posix_shell_script='
30369        func_return () {
30370          (exit $1)
30371        }
30372        func_success () {
30373          func_return 0
30374        }
30375        func_failure () {
30376          func_return 1
30377        }
30378        func_ret_success () {
30379          return 0
30380        }
30381        func_ret_failure () {
30382          return 1
30383        }
30384        subshell_umask_sanity () {
30385          (umask 22; (umask 0); test $(umask) -eq 22)
30386        }
30387        test "$(echo foo)" = foo &&
30388        func_success &&
30389        ! func_failure &&
30390        func_ret_success &&
30391        ! func_ret_failure &&
30392        (set x && func_ret_success y && test x = "$1") &&
30393        subshell_umask_sanity
30394      '
30395      for gl_cv_posix_shell in \
30396          "$CONFIG_SHELL" "$SHELL" /bin/sh /bin/bash /bin/ksh /bin/sh5 no; do
30397        case $gl_cv_posix_shell in
30398          /*)
30399            "$gl_cv_posix_shell" -c "$gl_test_posix_shell_script" 2>/dev/null \
30400              && break;;
30401        esac
30402      done
30403 fi
30404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_posix_shell" >&5
30405 $as_echo "$gl_cv_posix_shell" >&6; }
30406
30407   if test "$gl_cv_posix_shell" != no; then
30408     POSIX_SHELL=$gl_cv_posix_shell
30409     PREFERABLY_POSIX_SHELL=$POSIX_SHELL
30410   else
30411     POSIX_SHELL=
30412     PREFERABLY_POSIX_SHELL=/bin/sh
30413   fi
30414
30415
30416
30417
30418
30419
30420
30421
30422
30423   :
30424
30425
30426
30427
30428
30429   if test $ac_cv_func_posix_openpt != yes; then
30430         HAVE_POSIX_OPENPT=0
30431   fi
30432
30433   if test $HAVE_POSIX_OPENPT = 0; then
30434
30435
30436
30437
30438
30439
30440
30441
30442   gl_LIBOBJS="$gl_LIBOBJS posix_openpt.$ac_objext"
30443
30444   fi
30445
30446
30447
30448
30449
30450           GNULIB_POSIX_OPENPT=1
30451
30452
30453
30454
30455
30456 $as_echo "#define GNULIB_TEST_POSIX_OPENPT 1" >>confdefs.h
30457
30458
30459
30460
30461
30462
30463
30464
30465
30466
30467
30468   :
30469
30470
30471
30472
30473
30474
30475
30476
30477      if test $gl_cv_have_include_next = yes; then
30478        gl_cv_next_pthread_h='<'pthread.h'>'
30479      else
30480        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <pthread.h>" >&5
30481 $as_echo_n "checking absolute name of <pthread.h>... " >&6; }
30482 if ${gl_cv_next_pthread_h+:} false; then :
30483   $as_echo_n "(cached) " >&6
30484 else
30485
30486              if test $ac_cv_header_pthread_h = yes; then
30487
30488
30489
30490
30491   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30492 /* end confdefs.h.  */
30493 #include <pthread.h>
30494 _ACEOF
30495                 case "$host_os" in
30496     aix*) gl_absname_cpp="$ac_cpp -C" ;;
30497     *)    gl_absname_cpp="$ac_cpp" ;;
30498   esac
30499
30500   case "$host_os" in
30501     mingw*)
30502                                           gl_dirsep_regex='[/\\]'
30503       ;;
30504     *)
30505       gl_dirsep_regex='\/'
30506       ;;
30507   esac
30508       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
30509   gl_header_literal_regex=`echo 'pthread.h' \
30510                            | sed -e "$gl_make_literal_regex_sed"`
30511   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
30512       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
30513       s|^/[^/]|//&|
30514       p
30515       q
30516     }'
30517
30518         gl_cv_absolute_pthread_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
30519   sed -n "$gl_absolute_header_sed"`
30520
30521            gl_header=$gl_cv_absolute_pthread_h
30522            gl_cv_next_pthread_h='"'$gl_header'"'
30523           else
30524                gl_cv_next_pthread_h='<'pthread.h'>'
30525              fi
30526
30527
30528 fi
30529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_pthread_h" >&5
30530 $as_echo "$gl_cv_next_pthread_h" >&6; }
30531      fi
30532      NEXT_PTHREAD_H=$gl_cv_next_pthread_h
30533
30534      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
30535        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
30536        gl_next_as_first_directive='<'pthread.h'>'
30537      else
30538        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
30539        gl_next_as_first_directive=$gl_cv_next_pthread_h
30540      fi
30541      NEXT_AS_FIRST_DIRECTIVE_PTHREAD_H=$gl_next_as_first_directive
30542
30543
30544
30545
30546    if test $ac_cv_header_pthread_h = yes; then
30547      HAVE_PTHREAD_H=1
30548      # mingw 3.0 uses winpthreads which installs broken macros via <pthread.h>
30549      { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <pthread.h> pollutes the namespace" >&5
30550 $as_echo_n "checking whether <pthread.h> pollutes the namespace... " >&6; }
30551 if ${gl_cv_header_pthread_h_pollution+:} false; then :
30552   $as_echo_n "(cached) " >&6
30553 else
30554   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30555 /* end confdefs.h.  */
30556 #include <pthread.h>
30557             #ifdef strtok_r
30558             #error
30559              break me
30560             #endif
30561
30562 int
30563 main ()
30564 {
30565
30566   ;
30567   return 0;
30568 }
30569 _ACEOF
30570 if ac_fn_c_try_compile "$LINENO"; then :
30571   gl_cv_header_pthread_h_pollution=no
30572 else
30573   gl_cv_header_pthread_h_pollution=yes
30574 fi
30575 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30576 fi
30577 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_pthread_h_pollution" >&5
30578 $as_echo "$gl_cv_header_pthread_h_pollution" >&6; }
30579    else
30580      HAVE_PTHREAD_H=0
30581    fi
30582
30583    ac_fn_c_check_type "$LINENO" "pthread_t" "ac_cv_type_pthread_t" "$ac_includes_default
30584       #if HAVE_PTHREAD_H
30585        #include <pthread.h>
30586       #endif
30587 "
30588 if test "x$ac_cv_type_pthread_t" = xyes; then :
30589
30590 cat >>confdefs.h <<_ACEOF
30591 #define HAVE_PTHREAD_T 1
30592 _ACEOF
30593
30594
30595 fi
30596 ac_fn_c_check_type "$LINENO" "pthread_spinlock_t" "ac_cv_type_pthread_spinlock_t" "$ac_includes_default
30597       #if HAVE_PTHREAD_H
30598        #include <pthread.h>
30599       #endif
30600 "
30601 if test "x$ac_cv_type_pthread_spinlock_t" = xyes; then :
30602
30603 cat >>confdefs.h <<_ACEOF
30604 #define HAVE_PTHREAD_SPINLOCK_T 1
30605 _ACEOF
30606
30607
30608 fi
30609
30610    if test $ac_cv_type_pthread_t != yes; then
30611      HAVE_PTHREAD_T=0
30612    fi
30613    if test $ac_cv_type_pthread_spinlock_t != yes; then
30614      HAVE_PTHREAD_SPINLOCK_T=0
30615    fi
30616
30617    if test $ac_cv_header_pthread_h != yes ||
30618       test $ac_cv_type_pthread_t != yes ||
30619       test $ac_cv_type_pthread_spinlock_t != yes; then
30620      PTHREAD_H='pthread.h'
30621
30622
30623
30624
30625
30626
30627
30628
30629   gl_LIBOBJS="$gl_LIBOBJS pthread.$ac_objext"
30630
30631    elif test $gl_cv_header_pthread_h_pollution = yes; then
30632      PTHREAD_H=pthread.h
30633    else
30634      PTHREAD_H=
30635    fi
30636
30637     if test -n "$PTHREAD_H"; then
30638   GL_GENERATE_PTHREAD_H_TRUE=
30639   GL_GENERATE_PTHREAD_H_FALSE='#'
30640 else
30641   GL_GENERATE_PTHREAD_H_TRUE='#'
30642   GL_GENERATE_PTHREAD_H_FALSE=
30643 fi
30644
30645
30646    LIB_PTHREAD=
30647    if test $ac_cv_header_pthread_h = yes; then
30648                               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing pthread_create and pthread_join" >&5
30649 $as_echo_n "checking for library containing pthread_create and pthread_join... " >&6; }
30650 if ${gl_cv_lib_pthread+:} false; then :
30651   $as_echo_n "(cached) " >&6
30652 else
30653   gl_saved_libs=$LIBS
30654         gl_cv_lib_pthread=
30655         for gl_lib_prefix in '' '-lpthread'; do
30656           LIBS="$gl_lib_prefix $gl_saved_libs"
30657           cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30658 /* end confdefs.h.  */
30659 #include <pthread.h>
30660                  void *noop (void *p) { return p; }
30661 int
30662 main ()
30663 {
30664 pthread_t pt;
30665                  void *arg = 0;
30666                  pthread_create (&pt, 0, noop, arg);
30667                  pthread_join (pthread_self (), &arg);
30668   ;
30669   return 0;
30670 }
30671 _ACEOF
30672 if ac_fn_c_try_link "$LINENO"; then :
30673   if test -z "$gl_lib_prefix"; then
30674                gl_cv_lib_pthread="none required"
30675              else
30676                gl_cv_lib_pthread=$gl_lib_prefix
30677              fi
30678 fi
30679 rm -f core conftest.err conftest.$ac_objext \
30680     conftest$ac_exeext conftest.$ac_ext
30681           test -n "$gl_cv_lib_pthread" && break
30682         done
30683         LIBS="$gl_saved_libs"
30684
30685 fi
30686 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_lib_pthread" >&5
30687 $as_echo "$gl_cv_lib_pthread" >&6; }
30688      if test "$gl_cv_lib_pthread" != "none required"; then
30689        LIB_PTHREAD="$gl_cv_lib_pthread"
30690      fi
30691    fi
30692
30693
30694
30695
30696
30697
30698 cat >>confdefs.h <<_ACEOF
30699 #define GNULIB_PTHREAD 1
30700 _ACEOF
30701
30702
30703
30704
30705
30706
30707   :
30708
30709
30710
30711
30712
30713   LIB_PTHREAD_SIGMASK=
30714
30715
30716
30717
30718     if test "$gl_threads_api" = posix; then
30719       if test $ac_cv_func_pthread_sigmask = yes; then
30720                 :
30721       else
30722         if test -n "$LIBMULTITHREAD"; then
30723           { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_sigmask in $LIBMULTITHREAD" >&5
30724 $as_echo_n "checking for pthread_sigmask in $LIBMULTITHREAD... " >&6; }
30725 if ${gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD+:} false; then :
30726   $as_echo_n "(cached) " >&6
30727 else
30728   gl_save_LIBS="$LIBS"
30729              LIBS="$LIBS $LIBMULTITHREAD"
30730              cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30731 /* end confdefs.h.  */
30732 #include <pthread.h>
30733                     #include <signal.h>
30734
30735 int
30736 main ()
30737 {
30738 return pthread_sigmask (0, (sigset_t *) 0, (sigset_t *) 0);
30739   ;
30740   return 0;
30741 }
30742
30743 _ACEOF
30744 if ac_fn_c_try_link "$LINENO"; then :
30745   gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD=yes
30746 else
30747   gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD=no
30748 fi
30749 rm -f core conftest.err conftest.$ac_objext \
30750     conftest$ac_exeext conftest.$ac_ext
30751              LIBS="$gl_save_LIBS"
30752
30753 fi
30754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD" >&5
30755 $as_echo "$gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD" >&6; }
30756           if test $gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD = yes; then
30757                         LIB_PTHREAD_SIGMASK="$LIBMULTITHREAD"
30758           else
30759                         HAVE_PTHREAD_SIGMASK=0
30760           fi
30761         else
30762                     HAVE_PTHREAD_SIGMASK=0
30763         fi
30764       fi
30765     else
30766                                           if test $ac_cv_func_pthread_sigmask = yes; then
30767         REPLACE_PTHREAD_SIGMASK=1
30768       else
30769         HAVE_PTHREAD_SIGMASK=0
30770       fi
30771     fi
30772
30773
30774
30775
30776     if test $HAVE_PTHREAD_SIGMASK = 1; then
30777
30778
30779                 if test -z "$LIB_PTHREAD_SIGMASK"; then
30780       { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask works without -lpthread" >&5
30781 $as_echo_n "checking whether pthread_sigmask works without -lpthread... " >&6; }
30782 if ${gl_cv_func_pthread_sigmask_in_libc_works+:} false; then :
30783   $as_echo_n "(cached) " >&6
30784 else
30785
30786           if test "$cross_compiling" = yes; then :
30787
30788              case "$host_os" in
30789                freebsd* | hpux* | solaris | solaris2.[2-9]*)
30790                  gl_cv_func_pthread_sigmask_in_libc_works="guessing no";;
30791                *)
30792                  gl_cv_func_pthread_sigmask_in_libc_works="guessing yes";;
30793              esac
30794
30795 else
30796   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30797 /* end confdefs.h.  */
30798
30799 #include <pthread.h>
30800 #include <signal.h>
30801 #include <stddef.h>
30802 int main ()
30803 {
30804   sigset_t set;
30805   sigemptyset (&set);
30806   return pthread_sigmask (1729, &set, NULL) != 0;
30807 }
30808 _ACEOF
30809 if ac_fn_c_try_run "$LINENO"; then :
30810   gl_cv_func_pthread_sigmask_in_libc_works=no
30811 else
30812   gl_cv_func_pthread_sigmask_in_libc_works=yes
30813 fi
30814 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
30815   conftest.$ac_objext conftest.beam conftest.$ac_ext
30816 fi
30817
30818
30819 fi
30820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_in_libc_works" >&5
30821 $as_echo "$gl_cv_func_pthread_sigmask_in_libc_works" >&6; }
30822       case "$gl_cv_func_pthread_sigmask_in_libc_works" in
30823         *no)
30824           REPLACE_PTHREAD_SIGMASK=1
30825
30826 $as_echo "#define PTHREAD_SIGMASK_INEFFECTIVE 1" >>confdefs.h
30827
30828           ;;
30829       esac
30830     fi
30831
30832             { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask returns error numbers" >&5
30833 $as_echo_n "checking whether pthread_sigmask returns error numbers... " >&6; }
30834 if ${gl_cv_func_pthread_sigmask_return_works+:} false; then :
30835   $as_echo_n "(cached) " >&6
30836 else
30837
30838         gl_save_LIBS="$LIBS"
30839         LIBS="$LIBS $LIB_PTHREAD_SIGMASK"
30840         if test "$cross_compiling" = yes; then :
30841   case "$host_os" in
30842              cygwin*)
30843                gl_cv_func_pthread_sigmask_return_works="guessing no";;
30844              *)
30845                gl_cv_func_pthread_sigmask_return_works="guessing yes";;
30846            esac
30847
30848 else
30849   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30850 /* end confdefs.h.  */
30851
30852 #include <pthread.h>
30853 #include <signal.h>
30854 #include <stddef.h>
30855 int main ()
30856 {
30857   sigset_t set;
30858   sigemptyset (&set);
30859   if (pthread_sigmask (1729, &set, NULL) == -1)
30860     return 1;
30861   return 0;
30862 }
30863 _ACEOF
30864 if ac_fn_c_try_run "$LINENO"; then :
30865   gl_cv_func_pthread_sigmask_return_works=yes
30866 else
30867   gl_cv_func_pthread_sigmask_return_works=no
30868 fi
30869 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
30870   conftest.$ac_objext conftest.beam conftest.$ac_ext
30871 fi
30872
30873         LIBS="$gl_save_LIBS"
30874
30875 fi
30876 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_return_works" >&5
30877 $as_echo "$gl_cv_func_pthread_sigmask_return_works" >&6; }
30878     case "$gl_cv_func_pthread_sigmask_return_works" in
30879       *no)
30880         REPLACE_PTHREAD_SIGMASK=1
30881
30882 $as_echo "#define PTHREAD_SIGMASK_FAILS_WITH_ERRNO 1" >>confdefs.h
30883
30884         ;;
30885     esac
30886
30887                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask unblocks signals correctly" >&5
30888 $as_echo_n "checking whether pthread_sigmask unblocks signals correctly... " >&6; }
30889 if ${gl_cv_func_pthread_sigmask_unblock_works+:} false; then :
30890   $as_echo_n "(cached) " >&6
30891 else
30892
30893         case "$host_os" in
30894           irix*)
30895             gl_cv_func_pthread_sigmask_unblock_works="guessing no";;
30896           *)
30897             gl_cv_func_pthread_sigmask_unblock_works="guessing yes";;
30898         esac
30899                                 gl_save_LIBS="$LIBS"
30900         LIBS="$LIBS $LIBMULTITHREAD"
30901         if test "$cross_compiling" = yes; then :
30902   :
30903 else
30904   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
30905 /* end confdefs.h.  */
30906
30907 #include <pthread.h>
30908 #include <signal.h>
30909 #include <stdio.h>
30910 #include <stdlib.h>
30911 #include <unistd.h>
30912 static volatile int sigint_occurred;
30913 static void
30914 sigint_handler (int sig)
30915 {
30916   sigint_occurred++;
30917 }
30918 int main ()
30919 {
30920   sigset_t set;
30921   int pid = getpid ();
30922   char command[80];
30923   signal (SIGINT, sigint_handler);
30924   sigemptyset (&set);
30925   sigaddset (&set, SIGINT);
30926   if (!(pthread_sigmask (SIG_BLOCK, &set, NULL) == 0))
30927     return 1;
30928   sprintf (command, "sh -c 'sleep 1; kill -%d %d' &", SIGINT, pid);
30929   if (!(system (command) == 0))
30930     return 2;
30931   sleep (2);
30932   if (!(sigint_occurred == 0))
30933     return 3;
30934   if (!(pthread_sigmask (SIG_UNBLOCK, &set, NULL) == 0))
30935     return 4;
30936   if (!(sigint_occurred == 1)) /* This fails on IRIX.  */
30937     return 5;
30938   return 0;
30939 }
30940 _ACEOF
30941 if ac_fn_c_try_run "$LINENO"; then :
30942   :
30943 else
30944   gl_cv_func_pthread_sigmask_unblock_works=no
30945 fi
30946 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
30947   conftest.$ac_objext conftest.beam conftest.$ac_ext
30948 fi
30949
30950         LIBS="$gl_save_LIBS"
30951
30952 fi
30953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_unblock_works" >&5
30954 $as_echo "$gl_cv_func_pthread_sigmask_unblock_works" >&6; }
30955     case "$gl_cv_func_pthread_sigmask_unblock_works" in
30956       *no)
30957         REPLACE_PTHREAD_SIGMASK=1
30958
30959 $as_echo "#define PTHREAD_SIGMASK_UNBLOCK_BUG 1" >>confdefs.h
30960
30961         ;;
30962     esac
30963   fi
30964
30965   if test $HAVE_PTHREAD_SIGMASK = 0 || test $REPLACE_PTHREAD_SIGMASK = 1; then
30966
30967
30968
30969
30970
30971
30972
30973
30974   gl_LIBOBJS="$gl_LIBOBJS pthread_sigmask.$ac_objext"
30975
30976
30977   if test $HAVE_PTHREAD_SIGMASK = 1; then
30978
30979 $as_echo "#define HAVE_PTHREAD_SIGMASK 1" >>confdefs.h
30980
30981   fi
30982
30983   fi
30984
30985
30986
30987
30988
30989           GNULIB_PTHREAD_SIGMASK=1
30990
30991
30992
30993
30994
30995 $as_echo "#define GNULIB_TEST_PTHREAD_SIGMASK 1" >>confdefs.h
30996
30997
30998
30999
31000
31001
31002
31003
31004   for ac_func in raise
31005 do :
31006   ac_fn_c_check_func "$LINENO" "raise" "ac_cv_func_raise"
31007 if test "x$ac_cv_func_raise" = xyes; then :
31008   cat >>confdefs.h <<_ACEOF
31009 #define HAVE_RAISE 1
31010 _ACEOF
31011
31012 fi
31013 done
31014
31015   if test $ac_cv_func_raise = no; then
31016     HAVE_RAISE=0
31017   else
31018     if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
31019       REPLACE_RAISE=1
31020     fi
31021
31022
31023
31024
31025   if test $gl_cv_type_sigset_t = yes; then
31026     ac_fn_c_check_func "$LINENO" "sigprocmask" "ac_cv_func_sigprocmask"
31027 if test "x$ac_cv_func_sigprocmask" = xyes; then :
31028   gl_cv_func_sigprocmask=1
31029 fi
31030
31031   fi
31032   if test -z "$gl_cv_func_sigprocmask"; then
31033     HAVE_POSIX_SIGNALBLOCKING=0
31034   fi
31035
31036       if test $HAVE_POSIX_SIGNALBLOCKING = 0; then
31037
31038
31039
31040
31041           if test $gl_cv_header_signal_h_SIGPIPE != yes; then
31042             REPLACE_RAISE=1
31043           fi
31044
31045       fi
31046
31047   fi
31048
31049   if test $HAVE_RAISE = 0 || test $REPLACE_RAISE = 1; then
31050
31051
31052
31053
31054
31055
31056
31057
31058   gl_LIBOBJS="$gl_LIBOBJS raise.$ac_objext"
31059
31060     :
31061   fi
31062
31063
31064
31065
31066
31067           GNULIB_RAISE=1
31068
31069
31070
31071
31072
31073 $as_echo "#define GNULIB_TEST_RAISE 1" >>confdefs.h
31074
31075
31076
31077
31078
31079
31080
31081   for ac_header in random.h
31082 do :
31083   ac_fn_c_check_header_compile "$LINENO" "random.h" "ac_cv_header_random_h" "$ac_includes_default
31084 "
31085 if test "x$ac_cv_header_random_h" = xyes; then :
31086   cat >>confdefs.h <<_ACEOF
31087 #define HAVE_RANDOM_H 1
31088 _ACEOF
31089
31090 fi
31091
31092 done
31093
31094   if test $ac_cv_header_random_h = no; then
31095     HAVE_RANDOM_H=0
31096   fi
31097
31098   ac_fn_c_check_type "$LINENO" "struct random_data" "ac_cv_type_struct_random_data" "#include <stdlib.h>
31099       #if HAVE_RANDOM_H
31100       # include <random.h>
31101       #endif
31102
31103 "
31104 if test "x$ac_cv_type_struct_random_data" = xyes; then :
31105
31106 cat >>confdefs.h <<_ACEOF
31107 #define HAVE_STRUCT_RANDOM_DATA 1
31108 _ACEOF
31109
31110
31111 else
31112   HAVE_STRUCT_RANDOM_DATA=0
31113 fi
31114
31115
31116       case "$host_os" in
31117     aix* | osf*)
31118       REPLACE_RANDOM_R=1
31119       ;;
31120     *)
31121       for ac_func in random_r
31122 do :
31123   ac_fn_c_check_func "$LINENO" "random_r" "ac_cv_func_random_r"
31124 if test "x$ac_cv_func_random_r" = xyes; then :
31125   cat >>confdefs.h <<_ACEOF
31126 #define HAVE_RANDOM_R 1
31127 _ACEOF
31128
31129 fi
31130 done
31131
31132       if test $ac_cv_func_random_r = no; then
31133         HAVE_RANDOM_R=0
31134       fi
31135       ;;
31136   esac
31137
31138   if test $HAVE_RANDOM_R = 0 || test $REPLACE_RANDOM_R = 1; then
31139
31140
31141
31142
31143
31144
31145
31146
31147   gl_LIBOBJS="$gl_LIBOBJS random_r.$ac_objext"
31148
31149
31150   :
31151
31152   fi
31153
31154
31155
31156
31157
31158           GNULIB_RANDOM_R=1
31159
31160
31161
31162
31163
31164 $as_echo "#define GNULIB_TEST_RANDOM_R 1" >>confdefs.h
31165
31166
31167
31168
31169
31170
31171
31172   for ac_func in rawmemchr
31173 do :
31174   ac_fn_c_check_func "$LINENO" "rawmemchr" "ac_cv_func_rawmemchr"
31175 if test "x$ac_cv_func_rawmemchr" = xyes; then :
31176   cat >>confdefs.h <<_ACEOF
31177 #define HAVE_RAWMEMCHR 1
31178 _ACEOF
31179
31180 fi
31181 done
31182
31183   if test $ac_cv_func_rawmemchr = no; then
31184     HAVE_RAWMEMCHR=0
31185   fi
31186
31187   if test $HAVE_RAWMEMCHR = 0; then
31188
31189
31190
31191
31192
31193
31194
31195
31196   gl_LIBOBJS="$gl_LIBOBJS rawmemchr.$ac_objext"
31197
31198     :
31199   fi
31200
31201
31202
31203
31204
31205           GNULIB_RAWMEMCHR=1
31206
31207
31208
31209
31210
31211 $as_echo "#define GNULIB_TEST_RAWMEMCHR 1" >>confdefs.h
31212
31213
31214
31215
31216
31217
31218   :
31219
31220
31221
31222
31223
31224   if test $ac_cv_func_readlink = no; then
31225     HAVE_READLINK=0
31226   else
31227     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink signature is correct" >&5
31228 $as_echo_n "checking whether readlink signature is correct... " >&6; }
31229 if ${gl_cv_decl_readlink_works+:} false; then :
31230   $as_echo_n "(cached) " >&6
31231 else
31232   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31233 /* end confdefs.h.  */
31234 #include <unistd.h>
31235       /* Cause compilation failure if original declaration has wrong type.  */
31236       ssize_t readlink (const char *, char *, size_t);
31237 int
31238 main ()
31239 {
31240
31241   ;
31242   return 0;
31243 }
31244 _ACEOF
31245 if ac_fn_c_try_compile "$LINENO"; then :
31246   gl_cv_decl_readlink_works=yes
31247 else
31248   gl_cv_decl_readlink_works=no
31249 fi
31250 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31251 fi
31252 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_readlink_works" >&5
31253 $as_echo "$gl_cv_decl_readlink_works" >&6; }
31254             { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink handles trailing slash correctly" >&5
31255 $as_echo_n "checking whether readlink handles trailing slash correctly... " >&6; }
31256 if ${gl_cv_func_readlink_works+:} false; then :
31257   $as_echo_n "(cached) " >&6
31258 else
31259   # We have readlink, so assume ln -s works.
31260        ln -s conftest.no-such conftest.link
31261        ln -s conftest.link conftest.lnk2
31262        if test "$cross_compiling" = yes; then :
31263   case "$host_os" in
31264                     # Guess yes on glibc systems.
31265             *-gnu*) gl_cv_func_readlink_works="guessing yes" ;;
31266                     # If we don't know, assume the worst.
31267             *)      gl_cv_func_readlink_works="guessing no" ;;
31268           esac
31269
31270 else
31271   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31272 /* end confdefs.h.  */
31273 #include <unistd.h>
31274
31275 int
31276 main ()
31277 {
31278 char buf[20];
31279       return readlink ("conftest.lnk2/", buf, sizeof buf) != -1;
31280   ;
31281   return 0;
31282 }
31283 _ACEOF
31284 if ac_fn_c_try_run "$LINENO"; then :
31285   gl_cv_func_readlink_works=yes
31286 else
31287   gl_cv_func_readlink_works=no
31288 fi
31289 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
31290   conftest.$ac_objext conftest.beam conftest.$ac_ext
31291 fi
31292
31293       rm -f conftest.link conftest.lnk2
31294 fi
31295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_readlink_works" >&5
31296 $as_echo "$gl_cv_func_readlink_works" >&6; }
31297     case "$gl_cv_func_readlink_works" in
31298       *yes)
31299         if test "$gl_cv_decl_readlink_works" != yes; then
31300           REPLACE_READLINK=1
31301         fi
31302         ;;
31303       *)
31304
31305 $as_echo "#define READLINK_TRAILING_SLASH_BUG 1" >>confdefs.h
31306
31307         REPLACE_READLINK=1
31308         ;;
31309     esac
31310   fi
31311
31312   if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
31313
31314
31315
31316
31317
31318
31319
31320
31321   gl_LIBOBJS="$gl_LIBOBJS readlink.$ac_objext"
31322
31323
31324   :
31325
31326   fi
31327
31328
31329
31330
31331
31332           GNULIB_READLINK=1
31333
31334
31335
31336
31337
31338 $as_echo "#define GNULIB_TEST_READLINK 1" >>confdefs.h
31339
31340
31341
31342
31343
31344
31345   if test $gl_cv_func_malloc_posix = yes; then
31346
31347 $as_echo "#define HAVE_REALLOC_POSIX 1" >>confdefs.h
31348
31349   else
31350     REPLACE_REALLOC=1
31351   fi
31352
31353   if test $REPLACE_REALLOC = 1; then
31354
31355
31356
31357
31358
31359
31360
31361
31362   gl_LIBOBJS="$gl_LIBOBJS realloc.$ac_objext"
31363
31364   fi
31365
31366
31367
31368
31369
31370           GNULIB_REALLOC_POSIX=1
31371
31372
31373
31374
31375
31376 $as_echo "#define GNULIB_TEST_REALLOC_POSIX 1" >>confdefs.h
31377
31378
31379
31380
31381   if test "$ac_cv_header_winsock2_h" = yes; then
31382
31383
31384
31385
31386
31387
31388
31389
31390   gl_LIBOBJS="$gl_LIBOBJS recv.$ac_objext"
31391
31392   fi
31393
31394
31395
31396
31397
31398           GNULIB_RECV=1
31399
31400
31401
31402
31403
31404 $as_echo "#define GNULIB_TEST_RECV 1" >>confdefs.h
31405
31406
31407
31408
31409
31410 # Check whether --with-included-regex was given.
31411 if test "${with_included_regex+set}" = set; then :
31412   withval=$with_included_regex;
31413 fi
31414
31415
31416   case $with_included_regex in #(
31417   yes|no) ac_use_included_regex=$with_included_regex
31418         ;;
31419   '')
31420     # If the system regex support is good enough that it passes the
31421     # following run test, then default to *not* using the included regex.c.
31422     # If cross compiling, assume the test would fail and use the included
31423     # regex.c.
31424
31425   :
31426
31427
31428
31429
31430
31431
31432   :
31433
31434
31435
31436
31437
31438     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working re_compile_pattern" >&5
31439 $as_echo_n "checking for working re_compile_pattern... " >&6; }
31440 if ${gl_cv_func_re_compile_pattern_working+:} false; then :
31441   $as_echo_n "(cached) " >&6
31442 else
31443   if test "$cross_compiling" = yes; then :
31444          gl_cv_func_re_compile_pattern_working=no
31445 else
31446   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31447 /* end confdefs.h.  */
31448 #include <regex.h>
31449
31450             #include <locale.h>
31451             #include <limits.h>
31452             #include <string.h>
31453
31454             #if defined M_CHECK_ACTION || HAVE_DECL_ALARM
31455             # include <signal.h>
31456             # include <unistd.h>
31457             #endif
31458
31459             #if HAVE_MALLOC_H
31460             # include <malloc.h>
31461             #endif
31462
31463             #ifdef M_CHECK_ACTION
31464             /* Exit with distinguishable exit code.  */
31465             static void sigabrt_no_core (int sig) { raise (SIGTERM); }
31466             #endif
31467
31468 int
31469 main ()
31470 {
31471 int result = 0;
31472             static struct re_pattern_buffer regex;
31473             unsigned char folded_chars[UCHAR_MAX + 1];
31474             int i;
31475             const char *s;
31476             struct re_registers regs;
31477
31478             /* Some builds of glibc go into an infinite loop on this
31479                test.  Use alarm to force death, and mallopt to avoid
31480                malloc recursion in diagnosing the corrupted heap. */
31481 #if HAVE_DECL_ALARM
31482             signal (SIGALRM, SIG_DFL);
31483             alarm (2);
31484 #endif
31485 #ifdef M_CHECK_ACTION
31486             signal (SIGABRT, sigabrt_no_core);
31487             mallopt (M_CHECK_ACTION, 2);
31488 #endif
31489
31490             if (setlocale (LC_ALL, "en_US.UTF-8"))
31491               {
31492                 {
31493                   /* http://sourceware.org/ml/libc-hacker/2006-09/msg00008.html
31494                      This test needs valgrind to catch the bug on Debian
31495                      GNU/Linux 3.1 x86, but it might catch the bug better
31496                      on other platforms and it shouldn't hurt to try the
31497                      test here.  */
31498                   static char const pat[] = "insert into";
31499                   static char const data[] =
31500                     "\xFF\0\x12\xA2\xAA\xC4\xB1,K\x12\xC4\xB1*\xACK";
31501                   re_set_syntax (RE_SYNTAX_GREP | RE_HAT_LISTS_NOT_NEWLINE
31502                                  | RE_ICASE);
31503                   memset (&regex, 0, sizeof regex);
31504                   s = re_compile_pattern (pat, sizeof pat - 1, &regex);
31505                   if (s)
31506                     result |= 1;
31507                   else if (re_search (&regex, data, sizeof data - 1,
31508                                       0, sizeof data - 1, &regs)
31509                            != -1)
31510                     result |= 1;
31511                 }
31512
31513                 {
31514                   /* This test is from glibc bug 15078.
31515                      The test case is from Andreas Schwab in
31516                      <http://www.sourceware.org/ml/libc-alpha/2013-01/msg00967.html>.
31517                      */
31518                   static char const pat[] = "[^x]x";
31519                   static char const data[] =
31520                     /* <U1000><U103B><U103D><U1014><U103A><U102F><U1015><U103A> */
31521                     "\xe1\x80\x80"
31522                     "\xe1\x80\xbb"
31523                     "\xe1\x80\xbd"
31524                     "\xe1\x80\x94"
31525                     "\xe1\x80\xba"
31526                     "\xe1\x80\xaf"
31527                     "\xe1\x80\x95"
31528                     "\xe1\x80\xba"
31529                     "x";
31530                   re_set_syntax (0);
31531                   memset (&regex, 0, sizeof regex);
31532                   s = re_compile_pattern (pat, sizeof pat - 1, &regex);
31533                   if (s)
31534                     result |= 1;
31535                   else
31536                     {
31537                       i = re_search (&regex, data, sizeof data - 1,
31538                                      0, sizeof data - 1, 0);
31539                       if (i != 0 && i != 21)
31540                         result |= 1;
31541                     }
31542                 }
31543
31544                 if (! setlocale (LC_ALL, "C"))
31545                   return 1;
31546               }
31547
31548             /* This test is from glibc bug 3957, reported by Andrew Mackey.  */
31549             re_set_syntax (RE_SYNTAX_EGREP | RE_HAT_LISTS_NOT_NEWLINE);
31550             memset (&regex, 0, sizeof regex);
31551             s = re_compile_pattern ("a[^x]b", 6, &regex);
31552             if (s)
31553               result |= 2;
31554             /* This should fail, but succeeds for glibc-2.5.  */
31555             else if (re_search (&regex, "a\nb", 3, 0, 3, &regs) != -1)
31556               result |= 2;
31557
31558             /* This regular expression is from Spencer ere test number 75
31559                in grep-2.3.  */
31560             re_set_syntax (RE_SYNTAX_POSIX_EGREP);
31561             memset (&regex, 0, sizeof regex);
31562             for (i = 0; i <= UCHAR_MAX; i++)
31563               folded_chars[i] = i;
31564             regex.translate = folded_chars;
31565             s = re_compile_pattern ("a[[:]:]]b\n", 11, &regex);
31566             /* This should fail with _Invalid character class name_ error.  */
31567             if (!s)
31568               result |= 4;
31569
31570             /* Ensure that [b-a] is diagnosed as invalid, when
31571                using RE_NO_EMPTY_RANGES. */
31572             re_set_syntax (RE_SYNTAX_POSIX_EGREP | RE_NO_EMPTY_RANGES);
31573             memset (&regex, 0, sizeof regex);
31574             s = re_compile_pattern ("a[b-a]", 6, &regex);
31575             if (s == 0)
31576               result |= 8;
31577
31578             /* This should succeed, but does not for glibc-2.1.3.  */
31579             memset (&regex, 0, sizeof regex);
31580             s = re_compile_pattern ("{1", 2, &regex);
31581             if (s)
31582               result |= 8;
31583
31584             /* The following example is derived from a problem report
31585                against gawk from Jorge Stolfi <stolfi@ic.unicamp.br>.  */
31586             memset (&regex, 0, sizeof regex);
31587             s = re_compile_pattern ("[an\371]*n", 7, &regex);
31588             if (s)
31589               result |= 8;
31590             /* This should match, but does not for glibc-2.2.1.  */
31591             else if (re_match (&regex, "an", 2, 0, &regs) != 2)
31592               result |= 8;
31593
31594             memset (&regex, 0, sizeof regex);
31595             s = re_compile_pattern ("x", 1, &regex);
31596             if (s)
31597               result |= 8;
31598             /* glibc-2.2.93 does not work with a negative RANGE argument.  */
31599             else if (re_search (&regex, "wxy", 3, 2, -2, &regs) != 1)
31600               result |= 8;
31601
31602             /* The version of regex.c in older versions of gnulib
31603                ignored RE_ICASE.  Detect that problem too.  */
31604             re_set_syntax (RE_SYNTAX_EMACS | RE_ICASE);
31605             memset (&regex, 0, sizeof regex);
31606             s = re_compile_pattern ("x", 1, &regex);
31607             if (s)
31608               result |= 16;
31609             else if (re_search (&regex, "WXY", 3, 0, 3, &regs) < 0)
31610               result |= 16;
31611
31612             /* Catch a bug reported by Vin Shelton in
31613                http://lists.gnu.org/archive/html/bug-coreutils/2007-06/msg00089.html
31614                */
31615             re_set_syntax (RE_SYNTAX_POSIX_BASIC
31616                            & ~RE_CONTEXT_INVALID_DUP
31617                            & ~RE_NO_EMPTY_RANGES);
31618             memset (&regex, 0, sizeof regex);
31619             s = re_compile_pattern ("[[:alnum:]_-]\\\\+$", 16, &regex);
31620             if (s)
31621               result |= 32;
31622
31623             /* REG_STARTEND was added to glibc on 2004-01-15.
31624                Reject older versions.  */
31625             if (! REG_STARTEND)
31626               result |= 64;
31627
31628 #if 0
31629             /* It would be nice to reject hosts whose regoff_t values are too
31630                narrow (including glibc on hosts with 64-bit ptrdiff_t and
31631                32-bit int), but we should wait until glibc implements this
31632                feature.  Otherwise, support for equivalence classes and
31633                multibyte collation symbols would always be broken except
31634                when compiling --without-included-regex.   */
31635             if (sizeof (regoff_t) < sizeof (ptrdiff_t)
31636                 || sizeof (regoff_t) < sizeof (ssize_t))
31637               result |= 64;
31638 #endif
31639
31640             return result;
31641
31642   ;
31643   return 0;
31644 }
31645 _ACEOF
31646 if ac_fn_c_try_run "$LINENO"; then :
31647   gl_cv_func_re_compile_pattern_working=yes
31648 else
31649   gl_cv_func_re_compile_pattern_working=no
31650 fi
31651 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
31652   conftest.$ac_objext conftest.beam conftest.$ac_ext
31653 fi
31654
31655 fi
31656 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_re_compile_pattern_working" >&5
31657 $as_echo "$gl_cv_func_re_compile_pattern_working" >&6; }
31658     case $gl_cv_func_re_compile_pattern_working in #(
31659     yes) ac_use_included_regex=no;; #(
31660     no) ac_use_included_regex=yes;;
31661     esac
31662     ;;
31663   *) as_fn_error $? "Invalid value for --with-included-regex: $with_included_regex" "$LINENO" 5
31664     ;;
31665   esac
31666
31667   if test $ac_use_included_regex = yes; then
31668
31669 $as_echo "#define _REGEX_INCLUDE_LIMITS_H 1" >>confdefs.h
31670
31671
31672 $as_echo "#define _REGEX_LARGE_OFFSETS 1" >>confdefs.h
31673
31674
31675 $as_echo "#define re_syntax_options rpl_re_syntax_options" >>confdefs.h
31676
31677
31678 $as_echo "#define re_set_syntax rpl_re_set_syntax" >>confdefs.h
31679
31680
31681 $as_echo "#define re_compile_pattern rpl_re_compile_pattern" >>confdefs.h
31682
31683
31684 $as_echo "#define re_compile_fastmap rpl_re_compile_fastmap" >>confdefs.h
31685
31686
31687 $as_echo "#define re_search rpl_re_search" >>confdefs.h
31688
31689
31690 $as_echo "#define re_search_2 rpl_re_search_2" >>confdefs.h
31691
31692
31693 $as_echo "#define re_match rpl_re_match" >>confdefs.h
31694
31695
31696 $as_echo "#define re_match_2 rpl_re_match_2" >>confdefs.h
31697
31698
31699 $as_echo "#define re_set_registers rpl_re_set_registers" >>confdefs.h
31700
31701
31702 $as_echo "#define re_comp rpl_re_comp" >>confdefs.h
31703
31704
31705 $as_echo "#define re_exec rpl_re_exec" >>confdefs.h
31706
31707
31708 $as_echo "#define regcomp rpl_regcomp" >>confdefs.h
31709
31710
31711 $as_echo "#define regexec rpl_regexec" >>confdefs.h
31712
31713
31714 $as_echo "#define regerror rpl_regerror" >>confdefs.h
31715
31716
31717 $as_echo "#define regfree rpl_regfree" >>confdefs.h
31718
31719   fi
31720
31721   if test $ac_use_included_regex = yes; then
31722
31723
31724
31725
31726
31727
31728
31729
31730   gl_LIBOBJS="$gl_LIBOBJS regex.$ac_objext"
31731
31732
31733
31734
31735
31736
31737
31738
31739   for ac_header in libintl.h
31740 do :
31741   ac_fn_c_check_header_mongrel "$LINENO" "libintl.h" "ac_cv_header_libintl_h" "$ac_includes_default"
31742 if test "x$ac_cv_header_libintl_h" = xyes; then :
31743   cat >>confdefs.h <<_ACEOF
31744 #define HAVE_LIBINTL_H 1
31745 _ACEOF
31746
31747 fi
31748
31749 done
31750
31751
31752   :
31753
31754
31755
31756
31757
31758
31759
31760
31761   ac_fn_c_check_decl "$LINENO" "isblank" "ac_cv_have_decl_isblank" "#include <ctype.h>
31762 "
31763 if test "x$ac_cv_have_decl_isblank" = xyes; then :
31764   ac_have_decl=1
31765 else
31766   ac_have_decl=0
31767 fi
31768
31769 cat >>confdefs.h <<_ACEOF
31770 #define HAVE_DECL_ISBLANK $ac_have_decl
31771 _ACEOF
31772
31773
31774   fi
31775
31776   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31777 /* end confdefs.h.  */
31778
31779        #include <sched.h>
31780        struct sched_param a;
31781        int b[] = { SCHED_FIFO, SCHED_RR, SCHED_OTHER };
31782        pid_t t1;
31783
31784 int
31785 main ()
31786 {
31787
31788   ;
31789   return 0;
31790 }
31791 _ACEOF
31792 if ac_fn_c_try_compile "$LINENO"; then :
31793   SCHED_H=''
31794 else
31795   SCHED_H='sched.h'
31796
31797
31798
31799
31800
31801
31802
31803   :
31804
31805
31806
31807
31808
31809
31810
31811
31812      if test $gl_cv_have_include_next = yes; then
31813        gl_cv_next_sched_h='<'sched.h'>'
31814      else
31815        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sched.h>" >&5
31816 $as_echo_n "checking absolute name of <sched.h>... " >&6; }
31817 if ${gl_cv_next_sched_h+:} false; then :
31818   $as_echo_n "(cached) " >&6
31819 else
31820
31821              if test $ac_cv_header_sched_h = yes; then
31822
31823
31824
31825
31826   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
31827 /* end confdefs.h.  */
31828 #include <sched.h>
31829 _ACEOF
31830                 case "$host_os" in
31831     aix*) gl_absname_cpp="$ac_cpp -C" ;;
31832     *)    gl_absname_cpp="$ac_cpp" ;;
31833   esac
31834
31835   case "$host_os" in
31836     mingw*)
31837                                           gl_dirsep_regex='[/\\]'
31838       ;;
31839     *)
31840       gl_dirsep_regex='\/'
31841       ;;
31842   esac
31843       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
31844   gl_header_literal_regex=`echo 'sched.h' \
31845                            | sed -e "$gl_make_literal_regex_sed"`
31846   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
31847       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
31848       s|^/[^/]|//&|
31849       p
31850       q
31851     }'
31852
31853         gl_cv_absolute_sched_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
31854   sed -n "$gl_absolute_header_sed"`
31855
31856            gl_header=$gl_cv_absolute_sched_h
31857            gl_cv_next_sched_h='"'$gl_header'"'
31858           else
31859                gl_cv_next_sched_h='<'sched.h'>'
31860              fi
31861
31862
31863 fi
31864 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sched_h" >&5
31865 $as_echo "$gl_cv_next_sched_h" >&6; }
31866      fi
31867      NEXT_SCHED_H=$gl_cv_next_sched_h
31868
31869      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
31870        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
31871        gl_next_as_first_directive='<'sched.h'>'
31872      else
31873        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
31874        gl_next_as_first_directive=$gl_cv_next_sched_h
31875      fi
31876      NEXT_AS_FIRST_DIRECTIVE_SCHED_H=$gl_next_as_first_directive
31877
31878
31879
31880
31881
31882      if test $ac_cv_header_sched_h = yes; then
31883        HAVE_SCHED_H=1
31884      else
31885        HAVE_SCHED_H=0
31886      fi
31887
31888
31889      ac_fn_c_check_type "$LINENO" "struct sched_param" "ac_cv_type_struct_sched_param" "#include <sched.h>
31890 "
31891 if test "x$ac_cv_type_struct_sched_param" = xyes; then :
31892   HAVE_STRUCT_SCHED_PARAM=1
31893 else
31894   HAVE_STRUCT_SCHED_PARAM=0
31895 fi
31896
31897
31898
31899
31900
31901 fi
31902 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31903
31904    if test -n "$SCHED_H"; then
31905   GL_GENERATE_SCHED_H_TRUE=
31906   GL_GENERATE_SCHED_H_FALSE='#'
31907 else
31908   GL_GENERATE_SCHED_H_TRUE='#'
31909   GL_GENERATE_SCHED_H_FALSE=
31910 fi
31911
31912
31913
31914
31915
31916
31917
31918   :
31919
31920
31921
31922
31923
31924   if test $ac_cv_func_secure_getenv = no; then
31925     HAVE_SECURE_GETENV=0
31926   fi
31927
31928   if test $HAVE_SECURE_GETENV = 0; then
31929
31930
31931
31932
31933
31934
31935
31936
31937   gl_LIBOBJS="$gl_LIBOBJS secure_getenv.$ac_objext"
31938
31939
31940   for ac_func in __secure_getenv
31941 do :
31942   ac_fn_c_check_func "$LINENO" "__secure_getenv" "ac_cv_func___secure_getenv"
31943 if test "x$ac_cv_func___secure_getenv" = xyes; then :
31944   cat >>confdefs.h <<_ACEOF
31945 #define HAVE___SECURE_GETENV 1
31946 _ACEOF
31947
31948 fi
31949 done
31950
31951   if test $ac_cv_func___secure_getenv = no; then
31952     for ac_func in issetugid
31953 do :
31954   ac_fn_c_check_func "$LINENO" "issetugid" "ac_cv_func_issetugid"
31955 if test "x$ac_cv_func_issetugid" = xyes; then :
31956   cat >>confdefs.h <<_ACEOF
31957 #define HAVE_ISSETUGID 1
31958 _ACEOF
31959
31960 fi
31961 done
31962
31963   fi
31964
31965   fi
31966
31967
31968
31969
31970
31971           GNULIB_SECURE_GETENV=1
31972
31973
31974
31975
31976
31977 $as_echo "#define GNULIB_TEST_SECURE_GETENV 1" >>confdefs.h
31978
31979
31980
31981
31982
31983
31984   if test "$ac_cv_header_winsock2_h" = yes; then
31985     REPLACE_SELECT=1
31986   else
31987
31988   :
31989
31990
31991
31992
31993
31994     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether select supports a 0 argument" >&5
31995 $as_echo_n "checking whether select supports a 0 argument... " >&6; }
31996 if ${gl_cv_func_select_supports0+:} false; then :
31997   $as_echo_n "(cached) " >&6
31998 else
31999
32000         if test "$cross_compiling" = yes; then :
32001
32002            case "$host_os" in
32003                        # Guess no on Interix.
32004              interix*) gl_cv_func_select_supports0="guessing no";;
32005                        # Guess yes otherwise.
32006              *)        gl_cv_func_select_supports0="guessing yes";;
32007            esac
32008
32009 else
32010   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32011 /* end confdefs.h.  */
32012
32013 #include <sys/types.h>
32014 #include <sys/time.h>
32015 #if HAVE_SYS_SELECT_H
32016 #include <sys/select.h>
32017 #endif
32018 int main ()
32019 {
32020   struct timeval timeout;
32021   timeout.tv_sec = 0;
32022   timeout.tv_usec = 5;
32023   return select (0, (fd_set *)0, (fd_set *)0, (fd_set *)0, &timeout) < 0;
32024 }
32025 _ACEOF
32026 if ac_fn_c_try_run "$LINENO"; then :
32027   gl_cv_func_select_supports0=yes
32028 else
32029   gl_cv_func_select_supports0=no
32030 fi
32031 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
32032   conftest.$ac_objext conftest.beam conftest.$ac_ext
32033 fi
32034
32035
32036 fi
32037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_select_supports0" >&5
32038 $as_echo "$gl_cv_func_select_supports0" >&6; }
32039     case "$gl_cv_func_select_supports0" in
32040       *yes) ;;
32041       *) REPLACE_SELECT=1 ;;
32042     esac
32043
32044         { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether select detects invalid fds" >&5
32045 $as_echo_n "checking whether select detects invalid fds... " >&6; }
32046 if ${gl_cv_func_select_detects_ebadf+:} false; then :
32047   $as_echo_n "(cached) " >&6
32048 else
32049
32050         if test "$cross_compiling" = yes; then :
32051
32052            case "$host_os" in
32053                     # Guess yes on glibc systems.
32054             *-gnu*) gl_cv_func_select_detects_ebadf="guessing yes" ;;
32055                     # If we don't know, assume the worst.
32056             *)      gl_cv_func_select_detects_ebadf="guessing no" ;;
32057            esac
32058
32059 else
32060   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32061 /* end confdefs.h.  */
32062
32063 #include <sys/types.h>
32064 #include <sys/time.h>
32065 #if HAVE_SYS_SELECT_H
32066 # include <sys/select.h>
32067 #endif
32068 #include <unistd.h>
32069 #include <errno.h>
32070
32071 int
32072 main ()
32073 {
32074
32075   fd_set set;
32076   dup2(0, 16);
32077   FD_ZERO(&set);
32078   FD_SET(16, &set);
32079   close(16);
32080   struct timeval timeout;
32081   timeout.tv_sec = 0;
32082   timeout.tv_usec = 5;
32083   return select (17, &set, NULL, NULL, &timeout) != -1 || errno != EBADF;
32084
32085   ;
32086   return 0;
32087 }
32088 _ACEOF
32089 if ac_fn_c_try_run "$LINENO"; then :
32090   gl_cv_func_select_detects_ebadf=yes
32091 else
32092   gl_cv_func_select_detects_ebadf=no
32093 fi
32094 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
32095   conftest.$ac_objext conftest.beam conftest.$ac_ext
32096 fi
32097
32098
32099 fi
32100 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_select_detects_ebadf" >&5
32101 $as_echo "$gl_cv_func_select_detects_ebadf" >&6; }
32102     case $gl_cv_func_select_detects_ebadf in
32103       *yes) ;;
32104       *) REPLACE_SELECT=1 ;;
32105     esac
32106   fi
32107
32108     LIB_SELECT="$LIBSOCKET"
32109   if test $REPLACE_SELECT = 1; then
32110     case "$host_os" in
32111       mingw*)
32112                                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32113 /* end confdefs.h.  */
32114
32115 #define WIN32_LEAN_AND_MEAN
32116 #include <windows.h>
32117 int
32118 main ()
32119 {
32120   MsgWaitForMultipleObjects (0, NULL, 0, 0, 0);
32121   return 0;
32122 }
32123 _ACEOF
32124 if ac_fn_c_try_link "$LINENO"; then :
32125
32126 else
32127   LIB_SELECT="$LIB_SELECT -luser32"
32128 fi
32129 rm -f core conftest.err conftest.$ac_objext \
32130     conftest$ac_exeext conftest.$ac_ext
32131         ;;
32132     esac
32133   fi
32134
32135
32136   if test $REPLACE_SELECT = 1; then
32137
32138
32139
32140
32141
32142
32143
32144
32145   gl_LIBOBJS="$gl_LIBOBJS select.$ac_objext"
32146
32147   fi
32148
32149
32150
32151
32152
32153           GNULIB_SELECT=1
32154
32155
32156
32157
32158
32159 $as_echo "#define GNULIB_TEST_SELECT 1" >>confdefs.h
32160
32161
32162
32163
32164   if test "$ac_cv_header_winsock2_h" = yes; then
32165
32166
32167
32168
32169
32170
32171
32172
32173   gl_LIBOBJS="$gl_LIBOBJS send.$ac_objext"
32174
32175   fi
32176
32177
32178
32179
32180
32181           GNULIB_SEND=1
32182
32183
32184
32185
32186
32187 $as_echo "#define GNULIB_TEST_SEND 1" >>confdefs.h
32188
32189
32190
32191
32192                       SERVENT_LIB=
32193   gl_saved_libs="$LIBS"
32194   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing getservbyname" >&5
32195 $as_echo_n "checking for library containing getservbyname... " >&6; }
32196 if ${ac_cv_search_getservbyname+:} false; then :
32197   $as_echo_n "(cached) " >&6
32198 else
32199   ac_func_search_save_LIBS=$LIBS
32200 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32201 /* end confdefs.h.  */
32202
32203 /* Override any GCC internal prototype to avoid an error.
32204    Use char because int might match the return type of a GCC
32205    builtin and then its argument prototype would still apply.  */
32206 #ifdef __cplusplus
32207 extern "C"
32208 #endif
32209 char getservbyname ();
32210 int
32211 main ()
32212 {
32213 return getservbyname ();
32214   ;
32215   return 0;
32216 }
32217 _ACEOF
32218 for ac_lib in '' socket network net; do
32219   if test -z "$ac_lib"; then
32220     ac_res="none required"
32221   else
32222     ac_res=-l$ac_lib
32223     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
32224   fi
32225   if ac_fn_c_try_link "$LINENO"; then :
32226   ac_cv_search_getservbyname=$ac_res
32227 fi
32228 rm -f core conftest.err conftest.$ac_objext \
32229     conftest$ac_exeext
32230   if ${ac_cv_search_getservbyname+:} false; then :
32231   break
32232 fi
32233 done
32234 if ${ac_cv_search_getservbyname+:} false; then :
32235
32236 else
32237   ac_cv_search_getservbyname=no
32238 fi
32239 rm conftest.$ac_ext
32240 LIBS=$ac_func_search_save_LIBS
32241 fi
32242 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_getservbyname" >&5
32243 $as_echo "$ac_cv_search_getservbyname" >&6; }
32244 ac_res=$ac_cv_search_getservbyname
32245 if test "$ac_res" != no; then :
32246   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
32247   if test "$ac_cv_search_getservbyname" != "none required"; then
32248        SERVENT_LIB="$ac_cv_search_getservbyname"
32249      fi
32250 fi
32251
32252   LIBS="$gl_saved_libs"
32253   if test -z "$SERVENT_LIB"; then
32254     for ac_func in getservbyname
32255 do :
32256   ac_fn_c_check_func "$LINENO" "getservbyname" "ac_cv_func_getservbyname"
32257 if test "x$ac_cv_func_getservbyname" = xyes; then :
32258   cat >>confdefs.h <<_ACEOF
32259 #define HAVE_GETSERVBYNAME 1
32260 _ACEOF
32261
32262 else
32263
32264       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getservbyname in winsock2.h and -lws2_32" >&5
32265 $as_echo_n "checking for getservbyname in winsock2.h and -lws2_32... " >&6; }
32266 if ${gl_cv_w32_getservbyname+:} false; then :
32267   $as_echo_n "(cached) " >&6
32268 else
32269   gl_cv_w32_getservbyname=no
32270          gl_save_LIBS="$LIBS"
32271          LIBS="$LIBS -lws2_32"
32272          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32273 /* end confdefs.h.  */
32274
32275 #ifdef HAVE_WINSOCK2_H
32276 #include <winsock2.h>
32277 #endif
32278 #include <stddef.h>
32279
32280 int
32281 main ()
32282 {
32283 getservbyname(NULL,NULL);
32284   ;
32285   return 0;
32286 }
32287 _ACEOF
32288 if ac_fn_c_try_link "$LINENO"; then :
32289   gl_cv_w32_getservbyname=yes
32290 fi
32291 rm -f core conftest.err conftest.$ac_objext \
32292     conftest$ac_exeext conftest.$ac_ext
32293          LIBS="$gl_save_LIBS"
32294
32295 fi
32296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_w32_getservbyname" >&5
32297 $as_echo "$gl_cv_w32_getservbyname" >&6; }
32298       if test "$gl_cv_w32_getservbyname" = "yes"; then
32299         SERVENT_LIB="-lws2_32"
32300       fi
32301
32302 fi
32303 done
32304
32305   fi
32306
32307
32308
32309
32310      if test $ac_cv_func_setenv = no; then
32311     HAVE_SETENV=0
32312   else
32313     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether setenv validates arguments" >&5
32314 $as_echo_n "checking whether setenv validates arguments... " >&6; }
32315 if ${gl_cv_func_setenv_works+:} false; then :
32316   $as_echo_n "(cached) " >&6
32317 else
32318   if test "$cross_compiling" = yes; then :
32319   case "$host_os" in
32320                  # Guess yes on glibc systems.
32321          *-gnu*) gl_cv_func_setenv_works="guessing yes" ;;
32322                  # If we don't know, assume the worst.
32323          *)      gl_cv_func_setenv_works="guessing no" ;;
32324        esac
32325
32326 else
32327   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32328 /* end confdefs.h.  */
32329
32330        #include <stdlib.h>
32331        #include <errno.h>
32332        #include <string.h>
32333
32334 int
32335 main ()
32336 {
32337
32338        int result = 0;
32339        {
32340          if (setenv ("", "", 0) != -1)
32341            result |= 1;
32342          else if (errno != EINVAL)
32343            result |= 2;
32344        }
32345        {
32346          if (setenv ("a", "=", 1) != 0)
32347            result |= 4;
32348          else if (strcmp (getenv ("a"), "=") != 0)
32349            result |= 8;
32350        }
32351        return result;
32352
32353   ;
32354   return 0;
32355 }
32356 _ACEOF
32357 if ac_fn_c_try_run "$LINENO"; then :
32358   gl_cv_func_setenv_works=yes
32359 else
32360   gl_cv_func_setenv_works=no
32361 fi
32362 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
32363   conftest.$ac_objext conftest.beam conftest.$ac_ext
32364 fi
32365
32366 fi
32367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_setenv_works" >&5
32368 $as_echo "$gl_cv_func_setenv_works" >&6; }
32369     case "$gl_cv_func_setenv_works" in
32370       *yes) ;;
32371       *)
32372         REPLACE_SETENV=1
32373         ;;
32374     esac
32375   fi
32376
32377   if test $HAVE_SETENV = 0 || test $REPLACE_SETENV = 1; then
32378
32379
32380
32381
32382
32383
32384
32385
32386   gl_LIBOBJS="$gl_LIBOBJS setenv.$ac_objext"
32387
32388   fi
32389
32390
32391
32392
32393
32394           GNULIB_SETENV=1
32395
32396
32397
32398
32399
32400 $as_echo "#define GNULIB_TEST_SETENV 1" >>confdefs.h
32401
32402
32403
32404
32405   if test "$ac_cv_header_winsock2_h" = yes; then
32406
32407
32408
32409
32410
32411
32412
32413
32414   gl_LIBOBJS="$gl_LIBOBJS setsockopt.$ac_objext"
32415
32416   fi
32417
32418
32419
32420
32421
32422           GNULIB_SETSOCKOPT=1
32423
32424
32425
32426
32427
32428 $as_echo "#define GNULIB_TEST_SETSOCKOPT 1" >>confdefs.h
32429
32430
32431
32432
32433
32434
32435   :
32436
32437
32438
32439
32440
32441   if test $ac_cv_func_sigaction = yes; then
32442     ac_fn_c_check_member "$LINENO" "struct sigaction" "sa_sigaction" "ac_cv_member_struct_sigaction_sa_sigaction" "#include <signal.h>
32443 "
32444 if test "x$ac_cv_member_struct_sigaction_sa_sigaction" = xyes; then :
32445
32446 cat >>confdefs.h <<_ACEOF
32447 #define HAVE_STRUCT_SIGACTION_SA_SIGACTION 1
32448 _ACEOF
32449
32450
32451 fi
32452
32453     if test $ac_cv_member_struct_sigaction_sa_sigaction = no; then
32454       HAVE_STRUCT_SIGACTION_SA_SIGACTION=0
32455     fi
32456   else
32457     HAVE_SIGACTION=0
32458   fi
32459
32460   if test $HAVE_SIGACTION = 0; then
32461
32462
32463
32464
32465
32466
32467
32468
32469   gl_LIBOBJS="$gl_LIBOBJS sigaction.$ac_objext"
32470
32471
32472
32473
32474
32475
32476
32477   :
32478
32479
32480
32481
32482
32483
32484
32485
32486   ac_fn_c_check_type "$LINENO" "siginfo_t" "ac_cv_type_siginfo_t" "
32487 #include <signal.h>
32488
32489 "
32490 if test "x$ac_cv_type_siginfo_t" = xyes; then :
32491
32492 cat >>confdefs.h <<_ACEOF
32493 #define HAVE_SIGINFO_T 1
32494 _ACEOF
32495
32496
32497 fi
32498
32499   if test $ac_cv_type_siginfo_t = no; then
32500     HAVE_SIGINFO_T=0
32501   fi
32502
32503   fi
32504
32505
32506
32507
32508
32509           GNULIB_SIGACTION=1
32510
32511
32512
32513
32514
32515 $as_echo "#define GNULIB_TEST_SIGACTION 1" >>confdefs.h
32516
32517
32518
32519
32520
32521
32522
32523
32524
32525
32526
32527
32528
32529
32530      if test $gl_cv_have_include_next = yes; then
32531        gl_cv_next_signal_h='<'signal.h'>'
32532      else
32533        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <signal.h>" >&5
32534 $as_echo_n "checking absolute name of <signal.h>... " >&6; }
32535 if ${gl_cv_next_signal_h+:} false; then :
32536   $as_echo_n "(cached) " >&6
32537 else
32538
32539
32540
32541   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32542 /* end confdefs.h.  */
32543 #include <signal.h>
32544 _ACEOF
32545                 case "$host_os" in
32546     aix*) gl_absname_cpp="$ac_cpp -C" ;;
32547     *)    gl_absname_cpp="$ac_cpp" ;;
32548   esac
32549
32550   case "$host_os" in
32551     mingw*)
32552                                           gl_dirsep_regex='[/\\]'
32553       ;;
32554     *)
32555       gl_dirsep_regex='\/'
32556       ;;
32557   esac
32558       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
32559   gl_header_literal_regex=`echo 'signal.h' \
32560                            | sed -e "$gl_make_literal_regex_sed"`
32561   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
32562       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
32563       s|^/[^/]|//&|
32564       p
32565       q
32566     }'
32567
32568         gl_cv_absolute_signal_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
32569   sed -n "$gl_absolute_header_sed"`
32570
32571            gl_header=$gl_cv_absolute_signal_h
32572            gl_cv_next_signal_h='"'$gl_header'"'
32573
32574
32575 fi
32576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_signal_h" >&5
32577 $as_echo "$gl_cv_next_signal_h" >&6; }
32578      fi
32579      NEXT_SIGNAL_H=$gl_cv_next_signal_h
32580
32581      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
32582        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
32583        gl_next_as_first_directive='<'signal.h'>'
32584      else
32585        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
32586        gl_next_as_first_directive=$gl_cv_next_signal_h
32587      fi
32588      NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H=$gl_next_as_first_directive
32589
32590
32591
32592
32593
32594 # AIX declares sig_atomic_t to already include volatile, and C89 compilers
32595 # then choke on 'volatile sig_atomic_t'.  C99 requires that it compile.
32596   ac_fn_c_check_type "$LINENO" "volatile sig_atomic_t" "ac_cv_type_volatile_sig_atomic_t" "
32597 #include <signal.h>
32598
32599 "
32600 if test "x$ac_cv_type_volatile_sig_atomic_t" = xyes; then :
32601
32602 else
32603   HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=0
32604 fi
32605
32606
32607
32608
32609
32610
32611
32612   ac_fn_c_check_type "$LINENO" "sighandler_t" "ac_cv_type_sighandler_t" "
32613 #include <signal.h>
32614
32615 "
32616 if test "x$ac_cv_type_sighandler_t" = xyes; then :
32617
32618 else
32619   HAVE_SIGHANDLER_T=0
32620 fi
32621
32622
32623
32624
32625
32626
32627
32628
32629
32630 cat >>confdefs.h <<_ACEOF
32631 #define GNULIB_SIGPIPE 1
32632 _ACEOF
32633
32634
32635
32636   GNULIB_SIGNAL_H_SIGPIPE=1
32637
32638
32639   GNULIB_STDIO_H_SIGPIPE=1
32640
32641   GNULIB_UNISTD_H_SIGPIPE=1
32642
32643
32644
32645   if test $gl_cv_type_sigset_t = yes; then
32646     ac_fn_c_check_func "$LINENO" "sigprocmask" "ac_cv_func_sigprocmask"
32647 if test "x$ac_cv_func_sigprocmask" = xyes; then :
32648   gl_cv_func_sigprocmask=1
32649 fi
32650
32651   fi
32652   if test -z "$gl_cv_func_sigprocmask"; then
32653     HAVE_POSIX_SIGNALBLOCKING=0
32654   fi
32655
32656   if test $HAVE_POSIX_SIGNALBLOCKING = 0; then
32657
32658
32659
32660
32661
32662
32663
32664
32665   gl_LIBOBJS="$gl_LIBOBJS sigprocmask.$ac_objext"
32666
32667     :
32668   fi
32669
32670
32671
32672
32673
32674           GNULIB_SIGPROCMASK=1
32675
32676
32677
32678
32679
32680 $as_echo "#define GNULIB_TEST_SIGPROCMASK 1" >>confdefs.h
32681
32682
32683
32684
32685   for ac_header in stdint.h
32686 do :
32687   ac_fn_c_check_header_mongrel "$LINENO" "stdint.h" "ac_cv_header_stdint_h" "$ac_includes_default"
32688 if test "x$ac_cv_header_stdint_h" = xyes; then :
32689   cat >>confdefs.h <<_ACEOF
32690 #define HAVE_STDINT_H 1
32691 _ACEOF
32692
32693 fi
32694
32695 done
32696
32697     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SIZE_MAX" >&5
32698 $as_echo_n "checking for SIZE_MAX... " >&6; }
32699 if ${gl_cv_size_max+:} false; then :
32700   $as_echo_n "(cached) " >&6
32701 else
32702
32703     gl_cv_size_max=
32704     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32705 /* end confdefs.h.  */
32706
32707 #include <limits.h>
32708 #if HAVE_STDINT_H
32709 #include <stdint.h>
32710 #endif
32711 #ifdef SIZE_MAX
32712 Found it
32713 #endif
32714
32715 _ACEOF
32716 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
32717   $EGREP "Found it" >/dev/null 2>&1; then :
32718   gl_cv_size_max=yes
32719 fi
32720 rm -f conftest*
32721
32722     if test -z "$gl_cv_size_max"; then
32723                         if ac_fn_c_compute_int "$LINENO" "sizeof (size_t) * CHAR_BIT - 1" "size_t_bits_minus_1"        "#include <stddef.h>
32724 #include <limits.h>"; then :
32725
32726 else
32727   size_t_bits_minus_1=
32728 fi
32729
32730       if ac_fn_c_compute_int "$LINENO" "sizeof (size_t) <= sizeof (unsigned int)" "fits_in_uint"        "#include <stddef.h>"; then :
32731
32732 else
32733   fits_in_uint=
32734 fi
32735
32736       if test -n "$size_t_bits_minus_1" && test -n "$fits_in_uint"; then
32737         if test $fits_in_uint = 1; then
32738                               cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32739 /* end confdefs.h.  */
32740 #include <stddef.h>
32741                  extern size_t foo;
32742                  extern unsigned long foo;
32743
32744 int
32745 main ()
32746 {
32747
32748   ;
32749   return 0;
32750 }
32751 _ACEOF
32752 if ac_fn_c_try_compile "$LINENO"; then :
32753   fits_in_uint=0
32754 fi
32755 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32756         fi
32757                                 if test $fits_in_uint = 1; then
32758           gl_cv_size_max="(((1U << $size_t_bits_minus_1) - 1) * 2 + 1)"
32759         else
32760           gl_cv_size_max="(((1UL << $size_t_bits_minus_1) - 1) * 2 + 1)"
32761         fi
32762       else
32763                 gl_cv_size_max='((size_t)~(size_t)0)'
32764       fi
32765     fi
32766
32767 fi
32768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_size_max" >&5
32769 $as_echo "$gl_cv_size_max" >&6; }
32770   if test "$gl_cv_size_max" != yes; then
32771
32772 cat >>confdefs.h <<_ACEOF
32773 #define SIZE_MAX $gl_cv_size_max
32774 _ACEOF
32775
32776   fi
32777
32778
32779
32780
32781                ac_fn_c_check_decl "$LINENO" "sleep" "ac_cv_have_decl_sleep" "#include <unistd.h>
32782 "
32783 if test "x$ac_cv_have_decl_sleep" = xyes; then :
32784   ac_have_decl=1
32785 else
32786   ac_have_decl=0
32787 fi
32788
32789 cat >>confdefs.h <<_ACEOF
32790 #define HAVE_DECL_SLEEP $ac_have_decl
32791 _ACEOF
32792
32793
32794   :
32795
32796
32797
32798
32799
32800   if test $ac_cv_have_decl_sleep != yes; then
32801     HAVE_SLEEP=0
32802   else
32803         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working sleep" >&5
32804 $as_echo_n "checking for working sleep... " >&6; }
32805 if ${gl_cv_func_sleep_works+:} false; then :
32806   $as_echo_n "(cached) " >&6
32807 else
32808   if test "$cross_compiling" = yes; then :
32809   case "$host_os" in
32810                  # Guess yes on glibc systems.
32811          *-gnu*) gl_cv_func_sleep_works="guessing yes" ;;
32812                  # If we don't know, assume the worst.
32813          *)      gl_cv_func_sleep_works="guessing no" ;;
32814        esac
32815
32816 else
32817   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32818 /* end confdefs.h.  */
32819
32820 #include <errno.h>
32821 #include <unistd.h>
32822 #include <signal.h>
32823 static void
32824 handle_alarm (int sig)
32825 {
32826   if (sig != SIGALRM)
32827     _exit (2);
32828 }
32829
32830 int
32831 main ()
32832 {
32833
32834     /* Failure to compile this test due to missing alarm is okay,
32835        since all such platforms (mingw) also lack sleep.  */
32836     unsigned int pentecost = 50 * 24 * 60 * 60; /* 50 days.  */
32837     unsigned int remaining;
32838     signal (SIGALRM, handle_alarm);
32839     alarm (1);
32840     remaining = sleep (pentecost);
32841     if (remaining > pentecost)
32842       return 3;
32843     if (remaining <= pentecost - 10)
32844       return 4;
32845     return 0;
32846
32847   ;
32848   return 0;
32849 }
32850 _ACEOF
32851 if ac_fn_c_try_run "$LINENO"; then :
32852   gl_cv_func_sleep_works=yes
32853 else
32854   gl_cv_func_sleep_works=no
32855 fi
32856 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
32857   conftest.$ac_objext conftest.beam conftest.$ac_ext
32858 fi
32859
32860 fi
32861 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_sleep_works" >&5
32862 $as_echo "$gl_cv_func_sleep_works" >&6; }
32863     case "$gl_cv_func_sleep_works" in
32864       *yes) ;;
32865       *)
32866         REPLACE_SLEEP=1
32867         ;;
32868     esac
32869   fi
32870
32871   if test $HAVE_SLEEP = 0 || test $REPLACE_SLEEP = 1; then
32872
32873
32874
32875
32876
32877
32878
32879
32880   gl_LIBOBJS="$gl_LIBOBJS sleep.$ac_objext"
32881
32882   fi
32883
32884
32885
32886
32887
32888           GNULIB_SLEEP=1
32889
32890
32891
32892
32893
32894 $as_echo "#define GNULIB_TEST_SLEEP 1" >>confdefs.h
32895
32896
32897
32898
32899
32900   gl_cv_func_snprintf_usable=no
32901   for ac_func in snprintf
32902 do :
32903   ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
32904 if test "x$ac_cv_func_snprintf" = xyes; then :
32905   cat >>confdefs.h <<_ACEOF
32906 #define HAVE_SNPRINTF 1
32907 _ACEOF
32908
32909 fi
32910 done
32911
32912   if test $ac_cv_func_snprintf = yes; then
32913
32914
32915
32916   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether snprintf respects a size of 1" >&5
32917 $as_echo_n "checking whether snprintf respects a size of 1... " >&6; }
32918 if ${gl_cv_func_snprintf_size1+:} false; then :
32919   $as_echo_n "(cached) " >&6
32920 else
32921
32922       if test "$cross_compiling" = yes; then :
32923   gl_cv_func_snprintf_size1="guessing yes"
32924 else
32925   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32926 /* end confdefs.h.  */
32927
32928 #include <stdio.h>
32929 #if HAVE_SNPRINTF
32930 # define my_snprintf snprintf
32931 #else
32932 # include <stdarg.h>
32933 static int my_snprintf (char *buf, int size, const char *format, ...)
32934 {
32935   va_list args;
32936   int ret;
32937   va_start (args, format);
32938   ret = vsnprintf (buf, size, format, args);
32939   va_end (args);
32940   return ret;
32941 }
32942 #endif
32943 int main()
32944 {
32945   static char buf[8] = { 'D', 'E', 'A', 'D', 'B', 'E', 'E', 'F' };
32946   my_snprintf (buf, 1, "%d", 12345);
32947   return buf[1] != 'E';
32948 }
32949 _ACEOF
32950 if ac_fn_c_try_run "$LINENO"; then :
32951   gl_cv_func_snprintf_size1=yes
32952 else
32953   gl_cv_func_snprintf_size1=no
32954 fi
32955 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
32956   conftest.$ac_objext conftest.beam conftest.$ac_ext
32957 fi
32958
32959
32960 fi
32961 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_snprintf_size1" >&5
32962 $as_echo "$gl_cv_func_snprintf_size1" >&6; }
32963
32964     case "$gl_cv_func_snprintf_size1" in
32965       *yes)
32966
32967         case "$gl_cv_func_snprintf_retval_c99" in
32968           *yes)
32969
32970
32971      { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether printf supports POSIX/XSI format strings with positions" >&5
32972 $as_echo_n "checking whether printf supports POSIX/XSI format strings with positions... " >&6; }
32973 if ${gl_cv_func_printf_positions+:} false; then :
32974   $as_echo_n "(cached) " >&6
32975 else
32976
32977       if test "$cross_compiling" = yes; then :
32978
32979          case "$host_os" in
32980            netbsd[1-3]* | netbsdelf[1-3]* | netbsdaout[1-3]* | netbsdcoff[1-3]*)
32981                          gl_cv_func_printf_positions="guessing no";;
32982            beos*)        gl_cv_func_printf_positions="guessing no";;
32983            mingw* | pw*) gl_cv_func_printf_positions="guessing no";;
32984            *)            gl_cv_func_printf_positions="guessing yes";;
32985          esac
32986
32987 else
32988   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
32989 /* end confdefs.h.  */
32990
32991 #include <stdio.h>
32992 #include <string.h>
32993 /* The string "%2$d %1$d", with dollar characters protected from the shell's
32994    dollar expansion (possibly an autoconf bug).  */
32995 static char format[] = { '%', '2', '$', 'd', ' ', '%', '1', '$', 'd', '\0' };
32996 static char buf[100];
32997 int main ()
32998 {
32999   sprintf (buf, format, 33, 55);
33000   return (strcmp (buf, "55 33") != 0);
33001 }
33002 _ACEOF
33003 if ac_fn_c_try_run "$LINENO"; then :
33004   gl_cv_func_printf_positions=yes
33005 else
33006   gl_cv_func_printf_positions=no
33007 fi
33008 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
33009   conftest.$ac_objext conftest.beam conftest.$ac_ext
33010 fi
33011
33012
33013 fi
33014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_printf_positions" >&5
33015 $as_echo "$gl_cv_func_printf_positions" >&6; }
33016
33017             case "$gl_cv_func_printf_positions" in
33018               *yes)
33019                 gl_cv_func_snprintf_usable=yes
33020                 ;;
33021             esac
33022             ;;
33023         esac
33024         ;;
33025     esac
33026   fi
33027   if test $gl_cv_func_snprintf_usable = no; then
33028
33029
33030
33031
33032
33033
33034
33035
33036
33037
33038   gl_LIBOBJS="$gl_LIBOBJS snprintf.$ac_objext"
33039
33040   if test $ac_cv_func_snprintf = yes; then
33041     REPLACE_SNPRINTF=1
33042   fi
33043   :
33044
33045   fi
33046
33047   :
33048
33049
33050
33051
33052
33053   if test $ac_cv_have_decl_snprintf = no; then
33054     HAVE_DECL_SNPRINTF=0
33055   fi
33056
33057
33058
33059
33060
33061
33062           GNULIB_SNPRINTF=1
33063
33064
33065
33066
33067
33068 $as_echo "#define GNULIB_TEST_SNPRINTF 1" >>confdefs.h
33069
33070
33071
33072
33073
33074 cat >>confdefs.h <<_ACEOF
33075 #define GNULIB_SNPRINTF 1
33076 _ACEOF
33077
33078
33079
33080   if test "$ac_cv_header_winsock2_h" = yes; then
33081
33082
33083
33084
33085
33086
33087
33088
33089   gl_LIBOBJS="$gl_LIBOBJS socket.$ac_objext"
33090
33091   fi
33092   # When this module is used, sockets may actually occur as file descriptors,
33093   # hence it is worth warning if the modules 'close' and 'ioctl' are not used.
33094
33095
33096
33097   if test "$ac_cv_header_winsock2_h" = yes; then
33098     UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS=1
33099     SYS_IOCTL_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS=1
33100   fi
33101
33102
33103
33104
33105
33106           GNULIB_SOCKET=1
33107
33108
33109
33110
33111
33112 $as_echo "#define GNULIB_TEST_SOCKET 1" >>confdefs.h
33113
33114
33115
33116
33117
33118
33119
33120
33121   :
33122
33123
33124
33125
33126
33127   if test $ac_cv_header_sys_socket_h != yes; then
33128                     for ac_header in winsock2.h
33129 do :
33130   ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
33131 if test "x$ac_cv_header_winsock2_h" = xyes; then :
33132   cat >>confdefs.h <<_ACEOF
33133 #define HAVE_WINSOCK2_H 1
33134 _ACEOF
33135
33136 fi
33137
33138 done
33139
33140   fi
33141   if test "$ac_cv_header_winsock2_h" = yes; then
33142     HAVE_WINSOCK2_H=1
33143     UNISTD_H_HAVE_WINSOCK2_H=1
33144     SYS_IOCTL_H_HAVE_WINSOCK2_H=1
33145   else
33146     HAVE_WINSOCK2_H=0
33147   fi
33148
33149    LIBSOCKET=
33150   if test $HAVE_WINSOCK2_H = 1; then
33151         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we need to call WSAStartup in winsock2.h and -lws2_32" >&5
33152 $as_echo_n "checking if we need to call WSAStartup in winsock2.h and -lws2_32... " >&6; }
33153 if ${gl_cv_func_wsastartup+:} false; then :
33154   $as_echo_n "(cached) " >&6
33155 else
33156
33157       gl_save_LIBS="$LIBS"
33158       LIBS="$LIBS -lws2_32"
33159       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33160 /* end confdefs.h.  */
33161
33162 #ifdef HAVE_WINSOCK2_H
33163 # include <winsock2.h>
33164 #endif
33165 int
33166 main ()
33167 {
33168
33169           WORD wVersionRequested = MAKEWORD(1, 1);
33170           WSADATA wsaData;
33171           int err = WSAStartup(wVersionRequested, &wsaData);
33172           WSACleanup ();
33173   ;
33174   return 0;
33175 }
33176 _ACEOF
33177 if ac_fn_c_try_link "$LINENO"; then :
33178   gl_cv_func_wsastartup=yes
33179 else
33180   gl_cv_func_wsastartup=no
33181 fi
33182 rm -f core conftest.err conftest.$ac_objext \
33183     conftest$ac_exeext conftest.$ac_ext
33184       LIBS="$gl_save_LIBS"
33185
33186 fi
33187 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_wsastartup" >&5
33188 $as_echo "$gl_cv_func_wsastartup" >&6; }
33189     if test "$gl_cv_func_wsastartup" = "yes"; then
33190
33191 $as_echo "#define WINDOWS_SOCKETS 1" >>confdefs.h
33192
33193       LIBSOCKET='-lws2_32'
33194     fi
33195   else
33196                     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing setsockopt" >&5
33197 $as_echo_n "checking for library containing setsockopt... " >&6; }
33198 if ${gl_cv_lib_socket+:} false; then :
33199   $as_echo_n "(cached) " >&6
33200 else
33201
33202       gl_cv_lib_socket=
33203       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33204 /* end confdefs.h.  */
33205 extern
33206 #ifdef __cplusplus
33207 "C"
33208 #endif
33209 char setsockopt();
33210 int
33211 main ()
33212 {
33213 setsockopt();
33214   ;
33215   return 0;
33216 }
33217 _ACEOF
33218 if ac_fn_c_try_link "$LINENO"; then :
33219
33220 else
33221   gl_save_LIBS="$LIBS"
33222          LIBS="$gl_save_LIBS -lsocket"
33223          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33224 /* end confdefs.h.  */
33225 extern
33226 #ifdef __cplusplus
33227 "C"
33228 #endif
33229 char setsockopt();
33230 int
33231 main ()
33232 {
33233 setsockopt();
33234   ;
33235   return 0;
33236 }
33237 _ACEOF
33238 if ac_fn_c_try_link "$LINENO"; then :
33239   gl_cv_lib_socket="-lsocket"
33240 fi
33241 rm -f core conftest.err conftest.$ac_objext \
33242     conftest$ac_exeext conftest.$ac_ext
33243          if test -z "$gl_cv_lib_socket"; then
33244            LIBS="$gl_save_LIBS -lnetwork"
33245            cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33246 /* end confdefs.h.  */
33247 extern
33248 #ifdef __cplusplus
33249 "C"
33250 #endif
33251 char setsockopt();
33252 int
33253 main ()
33254 {
33255 setsockopt();
33256   ;
33257   return 0;
33258 }
33259 _ACEOF
33260 if ac_fn_c_try_link "$LINENO"; then :
33261   gl_cv_lib_socket="-lnetwork"
33262 fi
33263 rm -f core conftest.err conftest.$ac_objext \
33264     conftest$ac_exeext conftest.$ac_ext
33265            if test -z "$gl_cv_lib_socket"; then
33266              LIBS="$gl_save_LIBS -lnet"
33267              cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33268 /* end confdefs.h.  */
33269 extern
33270 #ifdef __cplusplus
33271 "C"
33272 #endif
33273 char setsockopt();
33274 int
33275 main ()
33276 {
33277 setsockopt();
33278   ;
33279   return 0;
33280 }
33281 _ACEOF
33282 if ac_fn_c_try_link "$LINENO"; then :
33283   gl_cv_lib_socket="-lnet"
33284 fi
33285 rm -f core conftest.err conftest.$ac_objext \
33286     conftest$ac_exeext conftest.$ac_ext
33287            fi
33288          fi
33289          LIBS="$gl_save_LIBS"
33290
33291 fi
33292 rm -f core conftest.err conftest.$ac_objext \
33293     conftest$ac_exeext conftest.$ac_ext
33294       if test -z "$gl_cv_lib_socket"; then
33295         gl_cv_lib_socket="none needed"
33296       fi
33297
33298 fi
33299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_lib_socket" >&5
33300 $as_echo "$gl_cv_lib_socket" >&6; }
33301     if test "$gl_cv_lib_socket" != "none needed"; then
33302       LIBSOCKET="$gl_cv_lib_socket"
33303     fi
33304   fi
33305
33306
33307
33308
33309
33310
33311   :
33312
33313
33314      ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "
33315 /* <sys/types.h> is not needed according to POSIX, but the
33316    <sys/socket.h> in i386-unknown-freebsd4.10 and
33317    powerpc-apple-darwin5.5 required it. */
33318 #include <sys/types.h>
33319 #if HAVE_SYS_SOCKET_H
33320 # include <sys/socket.h>
33321 #elif HAVE_WS2TCPIP_H
33322 # include <ws2tcpip.h>
33323 #endif
33324
33325 "
33326 if test "x$ac_cv_type_socklen_t" = xyes; then :
33327
33328 else
33329   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t equivalent" >&5
33330 $as_echo_n "checking for socklen_t equivalent... " >&6; }
33331       if ${gl_cv_socklen_t_equiv+:} false; then :
33332   $as_echo_n "(cached) " >&6
33333 else
33334   # Systems have either "struct sockaddr *" or
33335          # "void *" as the second argument to getpeername
33336          gl_cv_socklen_t_equiv=
33337          for arg2 in "struct sockaddr" void; do
33338            for t in int size_t "unsigned int" "long int" "unsigned long int"; do
33339              cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33340 /* end confdefs.h.  */
33341 #include <sys/types.h>
33342                    #include <sys/socket.h>
33343
33344                    int getpeername (int, $arg2 *, $t *);
33345 int
33346 main ()
33347 {
33348 $t len;
33349                   getpeername (0, 0, &len);
33350   ;
33351   return 0;
33352 }
33353 _ACEOF
33354 if ac_fn_c_try_compile "$LINENO"; then :
33355   gl_cv_socklen_t_equiv="$t"
33356 fi
33357 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33358              test "$gl_cv_socklen_t_equiv" != "" && break
33359            done
33360            test "$gl_cv_socklen_t_equiv" != "" && break
33361          done
33362
33363 fi
33364
33365       if test "$gl_cv_socklen_t_equiv" = ""; then
33366         as_fn_error $? "Cannot find a type to use in place of socklen_t" "$LINENO" 5
33367       fi
33368       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_socklen_t_equiv" >&5
33369 $as_echo "$gl_cv_socklen_t_equiv" >&6; }
33370
33371 cat >>confdefs.h <<_ACEOF
33372 #define socklen_t $gl_cv_socklen_t_equiv
33373 _ACEOF
33374
33375 fi
33376
33377
33378   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5
33379 $as_echo_n "checking for ssize_t... " >&6; }
33380 if ${gt_cv_ssize_t+:} false; then :
33381   $as_echo_n "(cached) " >&6
33382 else
33383   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33384 /* end confdefs.h.  */
33385 #include <sys/types.h>
33386 int
33387 main ()
33388 {
33389 int x = sizeof (ssize_t *) + sizeof (ssize_t);
33390             return !x;
33391   ;
33392   return 0;
33393 }
33394 _ACEOF
33395 if ac_fn_c_try_compile "$LINENO"; then :
33396   gt_cv_ssize_t=yes
33397 else
33398   gt_cv_ssize_t=no
33399 fi
33400 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33401 fi
33402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_ssize_t" >&5
33403 $as_echo "$gt_cv_ssize_t" >&6; }
33404   if test $gt_cv_ssize_t = no; then
33405     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rank of size_t" >&5
33406 $as_echo_n "checking for rank of size_t... " >&6; }
33407 if ${gt_cv_size_t_rank+:} false; then :
33408   $as_echo_n "(cached) " >&6
33409 else
33410   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33411 /* end confdefs.h.  */
33412 #include <sys/types.h>
33413           #ifdef __cplusplus
33414           extern "C" {
33415           #endif
33416             int foo(unsigned long bar);
33417             int foo(size_t bar);
33418           #ifdef __cplusplus
33419           }
33420           #endif
33421
33422 int
33423 main ()
33424 {
33425
33426   ;
33427   return 0;
33428 }
33429 _ACEOF
33430 if ac_fn_c_try_compile "$LINENO"; then :
33431   gt_cv_size_t_rank=long
33432 else
33433   gt_cv_size_t_rank=int
33434 fi
33435 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33436 fi
33437 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_size_t_rank" >&5
33438 $as_echo "$gt_cv_size_t_rank" >&6; }
33439
33440 cat >>confdefs.h <<_ACEOF
33441 #define ssize_t $gt_cv_size_t_rank
33442 _ACEOF
33443
33444   fi
33445
33446
33447
33448
33449   :
33450
33451
33452
33453
33454
33455     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on directories" >&5
33456 $as_echo_n "checking whether stat handles trailing slashes on directories... " >&6; }
33457 if ${gl_cv_func_stat_dir_slash+:} false; then :
33458   $as_echo_n "(cached) " >&6
33459 else
33460   if test "$cross_compiling" = yes; then :
33461   case $host_os in
33462             mingw*) gl_cv_func_stat_dir_slash="guessing no";;
33463             *) gl_cv_func_stat_dir_slash="guessing yes";;
33464           esac
33465 else
33466   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33467 /* end confdefs.h.  */
33468 #include <sys/stat.h>
33469
33470 int
33471 main ()
33472 {
33473 struct stat st; return stat (".", &st) != stat ("./", &st);
33474   ;
33475   return 0;
33476 }
33477 _ACEOF
33478 if ac_fn_c_try_run "$LINENO"; then :
33479   gl_cv_func_stat_dir_slash=yes
33480 else
33481   gl_cv_func_stat_dir_slash=no
33482 fi
33483 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
33484   conftest.$ac_objext conftest.beam conftest.$ac_ext
33485 fi
33486
33487 fi
33488 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_dir_slash" >&5
33489 $as_echo "$gl_cv_func_stat_dir_slash" >&6; }
33490         { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on files" >&5
33491 $as_echo_n "checking whether stat handles trailing slashes on files... " >&6; }
33492 if ${gl_cv_func_stat_file_slash+:} false; then :
33493   $as_echo_n "(cached) " >&6
33494 else
33495   touch conftest.tmp
33496        # Assume that if we have lstat, we can also check symlinks.
33497        if test $ac_cv_func_lstat = yes; then
33498          ln -s conftest.tmp conftest.lnk
33499        fi
33500        if test "$cross_compiling" = yes; then :
33501   case "$host_os" in
33502                     # Guess yes on glibc systems.
33503             *-gnu*) gl_cv_func_stat_file_slash="guessing yes" ;;
33504                     # If we don't know, assume the worst.
33505             *)      gl_cv_func_stat_file_slash="guessing no" ;;
33506           esac
33507
33508 else
33509   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33510 /* end confdefs.h.  */
33511 #include <sys/stat.h>
33512
33513 int
33514 main ()
33515 {
33516 int result = 0;
33517       struct stat st;
33518       if (!stat ("conftest.tmp/", &st))
33519         result |= 1;
33520 #if HAVE_LSTAT
33521       if (!stat ("conftest.lnk/", &st))
33522         result |= 2;
33523 #endif
33524       return result;
33525
33526   ;
33527   return 0;
33528 }
33529 _ACEOF
33530 if ac_fn_c_try_run "$LINENO"; then :
33531   gl_cv_func_stat_file_slash=yes
33532 else
33533   gl_cv_func_stat_file_slash=no
33534 fi
33535 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
33536   conftest.$ac_objext conftest.beam conftest.$ac_ext
33537 fi
33538
33539        rm -f conftest.tmp conftest.lnk
33540 fi
33541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_file_slash" >&5
33542 $as_echo "$gl_cv_func_stat_file_slash" >&6; }
33543   case $gl_cv_func_stat_dir_slash in
33544     *no) REPLACE_STAT=1
33545
33546 $as_echo "#define REPLACE_FUNC_STAT_DIR 1" >>confdefs.h
33547 ;;
33548   esac
33549   case $gl_cv_func_stat_file_slash in
33550     *no) REPLACE_STAT=1
33551
33552 $as_echo "#define REPLACE_FUNC_STAT_FILE 1" >>confdefs.h
33553 ;;
33554   esac
33555
33556   if test $REPLACE_STAT = 1; then
33557
33558
33559
33560
33561
33562
33563
33564
33565   gl_LIBOBJS="$gl_LIBOBJS stat.$ac_objext"
33566
33567     :
33568   fi
33569
33570
33571
33572
33573
33574           GNULIB_STAT=1
33575
33576
33577
33578
33579
33580 $as_echo "#define GNULIB_TEST_STAT 1" >>confdefs.h
33581
33582
33583
33584
33585
33586
33587   :
33588
33589
33590
33591
33592
33593
33594   ac_fn_c_check_member "$LINENO" "struct stat" "st_atim.tv_nsec" "ac_cv_member_struct_stat_st_atim_tv_nsec" "#include <sys/types.h>
33595      #include <sys/stat.h>
33596 "
33597 if test "x$ac_cv_member_struct_stat_st_atim_tv_nsec" = xyes; then :
33598
33599 cat >>confdefs.h <<_ACEOF
33600 #define HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC 1
33601 _ACEOF
33602
33603 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct stat.st_atim is of type struct timespec" >&5
33604 $as_echo_n "checking whether struct stat.st_atim is of type struct timespec... " >&6; }
33605 if ${ac_cv_typeof_struct_stat_st_atim_is_struct_timespec+:} false; then :
33606   $as_echo_n "(cached) " >&6
33607 else
33608   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33609 /* end confdefs.h.  */
33610
33611             #include <sys/types.h>
33612             #include <sys/stat.h>
33613             #if HAVE_SYS_TIME_H
33614             # include <sys/time.h>
33615             #endif
33616             #include <time.h>
33617             struct timespec ts;
33618             struct stat st;
33619
33620 int
33621 main ()
33622 {
33623
33624             st.st_atim = ts;
33625
33626   ;
33627   return 0;
33628 }
33629 _ACEOF
33630 if ac_fn_c_try_compile "$LINENO"; then :
33631   ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=yes
33632 else
33633   ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=no
33634 fi
33635 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33636 fi
33637 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&5
33638 $as_echo "$ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&6; }
33639      if test $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec = yes; then
33640
33641 $as_echo "#define TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC 1" >>confdefs.h
33642
33643      fi
33644 else
33645   ac_fn_c_check_member "$LINENO" "struct stat" "st_atimespec.tv_nsec" "ac_cv_member_struct_stat_st_atimespec_tv_nsec" "#include <sys/types.h>
33646         #include <sys/stat.h>
33647 "
33648 if test "x$ac_cv_member_struct_stat_st_atimespec_tv_nsec" = xyes; then :
33649
33650 cat >>confdefs.h <<_ACEOF
33651 #define HAVE_STRUCT_STAT_ST_ATIMESPEC_TV_NSEC 1
33652 _ACEOF
33653
33654
33655 else
33656   ac_fn_c_check_member "$LINENO" "struct stat" "st_atimensec" "ac_cv_member_struct_stat_st_atimensec" "#include <sys/types.h>
33657            #include <sys/stat.h>
33658 "
33659 if test "x$ac_cv_member_struct_stat_st_atimensec" = xyes; then :
33660
33661 cat >>confdefs.h <<_ACEOF
33662 #define HAVE_STRUCT_STAT_ST_ATIMENSEC 1
33663 _ACEOF
33664
33665
33666 else
33667   ac_fn_c_check_member "$LINENO" "struct stat" "st_atim.st__tim.tv_nsec" "ac_cv_member_struct_stat_st_atim_st__tim_tv_nsec" "#include <sys/types.h>
33668               #include <sys/stat.h>
33669 "
33670 if test "x$ac_cv_member_struct_stat_st_atim_st__tim_tv_nsec" = xyes; then :
33671
33672 cat >>confdefs.h <<_ACEOF
33673 #define HAVE_STRUCT_STAT_ST_ATIM_ST__TIM_TV_NSEC 1
33674 _ACEOF
33675
33676
33677 fi
33678
33679 fi
33680
33681 fi
33682
33683 fi
33684
33685
33686
33687
33688
33689   :
33690
33691
33692
33693
33694
33695   ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtimespec.tv_nsec" "ac_cv_member_struct_stat_st_birthtimespec_tv_nsec" "#include <sys/types.h>
33696      #include <sys/stat.h>
33697 "
33698 if test "x$ac_cv_member_struct_stat_st_birthtimespec_tv_nsec" = xyes; then :
33699
33700 cat >>confdefs.h <<_ACEOF
33701 #define HAVE_STRUCT_STAT_ST_BIRTHTIMESPEC_TV_NSEC 1
33702 _ACEOF
33703
33704
33705 else
33706   ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtimensec" "ac_cv_member_struct_stat_st_birthtimensec" "#include <sys/types.h>
33707         #include <sys/stat.h>
33708 "
33709 if test "x$ac_cv_member_struct_stat_st_birthtimensec" = xyes; then :
33710
33711 cat >>confdefs.h <<_ACEOF
33712 #define HAVE_STRUCT_STAT_ST_BIRTHTIMENSEC 1
33713 _ACEOF
33714
33715
33716 else
33717   ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtim.tv_nsec" "ac_cv_member_struct_stat_st_birthtim_tv_nsec" "#include <sys/types.h>
33718           #include <sys/stat.h>
33719 "
33720 if test "x$ac_cv_member_struct_stat_st_birthtim_tv_nsec" = xyes; then :
33721
33722 cat >>confdefs.h <<_ACEOF
33723 #define HAVE_STRUCT_STAT_ST_BIRTHTIM_TV_NSEC 1
33724 _ACEOF
33725
33726
33727 fi
33728
33729 fi
33730
33731 fi
33732
33733
33734
33735   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working stdalign.h" >&5
33736 $as_echo_n "checking for working stdalign.h... " >&6; }
33737 if ${gl_cv_header_working_stdalign_h+:} false; then :
33738   $as_echo_n "(cached) " >&6
33739 else
33740   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33741 /* end confdefs.h.  */
33742 #include <stdalign.h>
33743             #include <stddef.h>
33744
33745             /* Test that alignof yields a result consistent with offsetof.
33746                This catches GCC bug 52023
33747                <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52023>.  */
33748             #ifdef __cplusplus
33749                template <class t> struct alignof_helper { char a; t b; };
33750             # define ao(type) offsetof (alignof_helper<type>, b)
33751             #else
33752             # define ao(type) offsetof (struct { char a; type b; }, b)
33753             #endif
33754             char test_double[ao (double) % _Alignof (double) == 0 ? 1 : -1];
33755             char test_long[ao (long int) % _Alignof (long int) == 0 ? 1 : -1];
33756             char test_alignof[alignof (double) == _Alignof (double) ? 1 : -1];
33757
33758             /* Test _Alignas only on platforms where gnulib can help.  */
33759             #if \
33760                 ((defined __cplusplus && 201103 <= __cplusplus) \
33761                  || __GNUC__ || __IBMC__ || __IBMCPP__ || __ICC \
33762                  || 0x5110 <= __SUNPRO_C || 1300 <= _MSC_VER)
33763               struct alignas_test { char c; char alignas (8) alignas_8; };
33764               char test_alignas[offsetof (struct alignas_test, alignas_8) == 8
33765                                 ? 1 : -1];
33766             #endif
33767
33768 int
33769 main ()
33770 {
33771
33772   ;
33773   return 0;
33774 }
33775 _ACEOF
33776 if ac_fn_c_try_compile "$LINENO"; then :
33777   gl_cv_header_working_stdalign_h=yes
33778 else
33779   gl_cv_header_working_stdalign_h=no
33780 fi
33781 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33782 fi
33783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdalign_h" >&5
33784 $as_echo "$gl_cv_header_working_stdalign_h" >&6; }
33785
33786   if test $gl_cv_header_working_stdalign_h = yes; then
33787     STDALIGN_H=''
33788   else
33789     STDALIGN_H='stdalign.h'
33790   fi
33791
33792
33793    if test -n "$STDALIGN_H"; then
33794   GL_GENERATE_STDALIGN_H_TRUE=
33795   GL_GENERATE_STDALIGN_H_FALSE='#'
33796 else
33797   GL_GENERATE_STDALIGN_H_TRUE='#'
33798   GL_GENERATE_STDALIGN_H_FALSE=
33799 fi
33800
33801
33802
33803   STDARG_H=''
33804   NEXT_STDARG_H='<stdarg.h>'
33805   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for va_copy" >&5
33806 $as_echo_n "checking for va_copy... " >&6; }
33807   if ${gl_cv_func_va_copy+:} false; then :
33808   $as_echo_n "(cached) " >&6
33809 else
33810
33811     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33812 /* end confdefs.h.  */
33813 #include <stdarg.h>
33814 int
33815 main ()
33816 {
33817
33818 #ifndef va_copy
33819 void (*func) (va_list, va_list) = va_copy;
33820 #endif
33821
33822   ;
33823   return 0;
33824 }
33825 _ACEOF
33826 if ac_fn_c_try_compile "$LINENO"; then :
33827   gl_cv_func_va_copy=yes
33828 else
33829   gl_cv_func_va_copy=no
33830 fi
33831 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33832 fi
33833
33834   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_va_copy" >&5
33835 $as_echo "$gl_cv_func_va_copy" >&6; }
33836   if test $gl_cv_func_va_copy = no; then
33837                                     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33838 /* end confdefs.h.  */
33839 #if defined _AIX && !defined __GNUC__
33840         AIX vaccine
33841        #endif
33842
33843 _ACEOF
33844 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
33845   $EGREP "vaccine" >/dev/null 2>&1; then :
33846   gl_aixcc=yes
33847 else
33848   gl_aixcc=no
33849 fi
33850 rm -f conftest*
33851
33852     if test $gl_aixcc = yes; then
33853             STDARG_H=stdarg.h
33854
33855
33856
33857
33858
33859
33860
33861
33862      if test $gl_cv_have_include_next = yes; then
33863        gl_cv_next_stdarg_h='<'stdarg.h'>'
33864      else
33865        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdarg.h>" >&5
33866 $as_echo_n "checking absolute name of <stdarg.h>... " >&6; }
33867 if ${gl_cv_next_stdarg_h+:} false; then :
33868   $as_echo_n "(cached) " >&6
33869 else
33870
33871
33872
33873   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33874 /* end confdefs.h.  */
33875 #include <stdarg.h>
33876 _ACEOF
33877                 case "$host_os" in
33878     aix*) gl_absname_cpp="$ac_cpp -C" ;;
33879     *)    gl_absname_cpp="$ac_cpp" ;;
33880   esac
33881
33882   case "$host_os" in
33883     mingw*)
33884                                           gl_dirsep_regex='[/\\]'
33885       ;;
33886     *)
33887       gl_dirsep_regex='\/'
33888       ;;
33889   esac
33890       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
33891   gl_header_literal_regex=`echo 'stdarg.h' \
33892                            | sed -e "$gl_make_literal_regex_sed"`
33893   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
33894       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
33895       s|^/[^/]|//&|
33896       p
33897       q
33898     }'
33899
33900         gl_cv_absolute_stdarg_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
33901   sed -n "$gl_absolute_header_sed"`
33902
33903            gl_header=$gl_cv_absolute_stdarg_h
33904            gl_cv_next_stdarg_h='"'$gl_header'"'
33905
33906
33907 fi
33908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdarg_h" >&5
33909 $as_echo "$gl_cv_next_stdarg_h" >&6; }
33910      fi
33911      NEXT_STDARG_H=$gl_cv_next_stdarg_h
33912
33913      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
33914        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
33915        gl_next_as_first_directive='<'stdarg.h'>'
33916      else
33917        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
33918        gl_next_as_first_directive=$gl_cv_next_stdarg_h
33919      fi
33920      NEXT_AS_FIRST_DIRECTIVE_STDARG_H=$gl_next_as_first_directive
33921
33922
33923
33924
33925             if test "$gl_cv_next_stdarg_h" = '""'; then
33926         gl_cv_next_stdarg_h='"///usr/include/stdarg.h"'
33927         NEXT_STDARG_H="$gl_cv_next_stdarg_h"
33928       fi
33929     else
33930
33931   saved_as_echo_n="$as_echo_n"
33932   as_echo_n=':'
33933   if ${gl_cv_func___va_copy+:} false; then :
33934   $as_echo_n "(cached) " >&6
33935 else
33936
33937         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
33938 /* end confdefs.h.  */
33939 #include <stdarg.h>
33940 int
33941 main ()
33942 {
33943
33944 #ifndef __va_copy
33945 error, bail out
33946 #endif
33947
33948   ;
33949   return 0;
33950 }
33951 _ACEOF
33952 if ac_fn_c_try_compile "$LINENO"; then :
33953   gl_cv_func___va_copy=yes
33954 else
33955   gl_cv_func___va_copy=no
33956 fi
33957 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33958 fi
33959
33960   as_echo_n="$saved_as_echo_n"
33961
33962       if test $gl_cv_func___va_copy = yes; then
33963
33964 $as_echo "#define va_copy __va_copy" >>confdefs.h
33965
33966       else
33967
33968
33969 $as_echo "#define va_copy gl_va_copy" >>confdefs.h
33970
33971       fi
33972     fi
33973   fi
33974
33975    if test -n "$STDARG_H"; then
33976   GL_GENERATE_STDARG_H_TRUE=
33977   GL_GENERATE_STDARG_H_FALSE='#'
33978 else
33979   GL_GENERATE_STDARG_H_TRUE='#'
33980   GL_GENERATE_STDARG_H_FALSE=
33981 fi
33982
33983
33984
33985
33986
33987
33988   # Define two additional variables used in the Makefile substitution.
33989
33990   if test "$ac_cv_header_stdbool_h" = yes; then
33991     STDBOOL_H=''
33992   else
33993     STDBOOL_H='stdbool.h'
33994   fi
33995
33996    if test -n "$STDBOOL_H"; then
33997   GL_GENERATE_STDBOOL_H_TRUE=
33998   GL_GENERATE_STDBOOL_H_FALSE='#'
33999 else
34000   GL_GENERATE_STDBOOL_H_TRUE='#'
34001   GL_GENERATE_STDBOOL_H_FALSE=
34002 fi
34003
34004
34005   if test "$ac_cv_type__Bool" = yes; then
34006     HAVE__BOOL=1
34007   else
34008     HAVE__BOOL=0
34009   fi
34010
34011
34012
34013
34014
34015   STDDEF_H=
34016   if test $gt_cv_c_wchar_t = no; then
34017     HAVE_WCHAR_T=0
34018     STDDEF_H=stddef.h
34019   fi
34020   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
34021 $as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
34022 if ${gl_cv_decl_null_works+:} false; then :
34023   $as_echo_n "(cached) " >&6
34024 else
34025   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34026 /* end confdefs.h.  */
34027 #include <stddef.h>
34028       int test[2 * (sizeof NULL == sizeof (void *)) -1];
34029
34030 int
34031 main ()
34032 {
34033
34034   ;
34035   return 0;
34036 }
34037 _ACEOF
34038 if ac_fn_c_try_compile "$LINENO"; then :
34039   gl_cv_decl_null_works=yes
34040 else
34041   gl_cv_decl_null_works=no
34042 fi
34043 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
34044 fi
34045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
34046 $as_echo "$gl_cv_decl_null_works" >&6; }
34047   if test $gl_cv_decl_null_works = no; then
34048     REPLACE_NULL=1
34049     STDDEF_H=stddef.h
34050   fi
34051
34052    if test -n "$STDDEF_H"; then
34053   GL_GENERATE_STDDEF_H_TRUE=
34054   GL_GENERATE_STDDEF_H_FALSE='#'
34055 else
34056   GL_GENERATE_STDDEF_H_TRUE='#'
34057   GL_GENERATE_STDDEF_H_FALSE=
34058 fi
34059
34060   if test -n "$STDDEF_H"; then
34061
34062
34063
34064
34065
34066
34067
34068
34069      if test $gl_cv_have_include_next = yes; then
34070        gl_cv_next_stddef_h='<'stddef.h'>'
34071      else
34072        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
34073 $as_echo_n "checking absolute name of <stddef.h>... " >&6; }
34074 if ${gl_cv_next_stddef_h+:} false; then :
34075   $as_echo_n "(cached) " >&6
34076 else
34077
34078
34079
34080   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34081 /* end confdefs.h.  */
34082 #include <stddef.h>
34083 _ACEOF
34084                 case "$host_os" in
34085     aix*) gl_absname_cpp="$ac_cpp -C" ;;
34086     *)    gl_absname_cpp="$ac_cpp" ;;
34087   esac
34088
34089   case "$host_os" in
34090     mingw*)
34091                                           gl_dirsep_regex='[/\\]'
34092       ;;
34093     *)
34094       gl_dirsep_regex='\/'
34095       ;;
34096   esac
34097       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
34098   gl_header_literal_regex=`echo 'stddef.h' \
34099                            | sed -e "$gl_make_literal_regex_sed"`
34100   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
34101       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
34102       s|^/[^/]|//&|
34103       p
34104       q
34105     }'
34106
34107         gl_cv_absolute_stddef_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
34108   sed -n "$gl_absolute_header_sed"`
34109
34110            gl_header=$gl_cv_absolute_stddef_h
34111            gl_cv_next_stddef_h='"'$gl_header'"'
34112
34113
34114 fi
34115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
34116 $as_echo "$gl_cv_next_stddef_h" >&6; }
34117      fi
34118      NEXT_STDDEF_H=$gl_cv_next_stddef_h
34119
34120      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
34121        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
34122        gl_next_as_first_directive='<'stddef.h'>'
34123      else
34124        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
34125        gl_next_as_first_directive=$gl_cv_next_stddef_h
34126      fi
34127      NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
34128
34129
34130
34131
34132   fi
34133
34134
34135
34136
34137
34138
34139
34140
34141
34142
34143
34144
34145      if test $gl_cv_have_include_next = yes; then
34146        gl_cv_next_stdio_h='<'stdio.h'>'
34147      else
34148        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdio.h>" >&5
34149 $as_echo_n "checking absolute name of <stdio.h>... " >&6; }
34150 if ${gl_cv_next_stdio_h+:} false; then :
34151   $as_echo_n "(cached) " >&6
34152 else
34153
34154
34155
34156   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34157 /* end confdefs.h.  */
34158 #include <stdio.h>
34159 _ACEOF
34160                 case "$host_os" in
34161     aix*) gl_absname_cpp="$ac_cpp -C" ;;
34162     *)    gl_absname_cpp="$ac_cpp" ;;
34163   esac
34164
34165   case "$host_os" in
34166     mingw*)
34167                                           gl_dirsep_regex='[/\\]'
34168       ;;
34169     *)
34170       gl_dirsep_regex='\/'
34171       ;;
34172   esac
34173       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
34174   gl_header_literal_regex=`echo 'stdio.h' \
34175                            | sed -e "$gl_make_literal_regex_sed"`
34176   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
34177       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
34178       s|^/[^/]|//&|
34179       p
34180       q
34181     }'
34182
34183         gl_cv_absolute_stdio_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
34184   sed -n "$gl_absolute_header_sed"`
34185
34186            gl_header=$gl_cv_absolute_stdio_h
34187            gl_cv_next_stdio_h='"'$gl_header'"'
34188
34189
34190 fi
34191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdio_h" >&5
34192 $as_echo "$gl_cv_next_stdio_h" >&6; }
34193      fi
34194      NEXT_STDIO_H=$gl_cv_next_stdio_h
34195
34196      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
34197        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
34198        gl_next_as_first_directive='<'stdio.h'>'
34199      else
34200        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
34201        gl_next_as_first_directive=$gl_cv_next_stdio_h
34202      fi
34203      NEXT_AS_FIRST_DIRECTIVE_STDIO_H=$gl_next_as_first_directive
34204
34205
34206
34207
34208
34209       GNULIB_FSCANF=1
34210
34211
34212 cat >>confdefs.h <<_ACEOF
34213 #define GNULIB_FSCANF 1
34214 _ACEOF
34215
34216
34217   GNULIB_SCANF=1
34218
34219
34220 cat >>confdefs.h <<_ACEOF
34221 #define GNULIB_SCANF 1
34222 _ACEOF
34223
34224
34225   GNULIB_FGETC=1
34226   GNULIB_GETC=1
34227   GNULIB_GETCHAR=1
34228   GNULIB_FGETS=1
34229   GNULIB_FREAD=1
34230
34231
34232
34233
34234     if test $gl_cv_have_nonblocking != yes; then
34235       REPLACE_STDIO_READ_FUNCS=1
34236
34237
34238
34239
34240
34241
34242
34243
34244   gl_LIBOBJS="$gl_LIBOBJS stdio-read.$ac_objext"
34245
34246     fi
34247
34248
34249       GNULIB_FPRINTF=1
34250   GNULIB_PRINTF=1
34251   GNULIB_VFPRINTF=1
34252   GNULIB_VPRINTF=1
34253   GNULIB_FPUTC=1
34254   GNULIB_PUTC=1
34255   GNULIB_PUTCHAR=1
34256   GNULIB_FPUTS=1
34257   GNULIB_PUTS=1
34258   GNULIB_FWRITE=1
34259
34260
34261
34262
34263     if test $gl_cv_header_signal_h_SIGPIPE != yes; then
34264       REPLACE_STDIO_WRITE_FUNCS=1
34265
34266
34267
34268
34269
34270
34271
34272
34273   gl_LIBOBJS="$gl_LIBOBJS stdio-write.$ac_objext"
34274
34275     fi
34276
34277
34278
34279
34280
34281     if test $gl_cv_have_nonblocking != yes; then
34282       REPLACE_STDIO_WRITE_FUNCS=1
34283
34284
34285
34286
34287
34288
34289
34290
34291   gl_LIBOBJS="$gl_LIBOBJS stdio-write.$ac_objext"
34292
34293     fi
34294
34295
34296
34297
34298
34299
34300
34301
34302
34303
34304
34305
34306
34307
34308      if test $gl_cv_have_include_next = yes; then
34309        gl_cv_next_stdlib_h='<'stdlib.h'>'
34310      else
34311        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdlib.h>" >&5
34312 $as_echo_n "checking absolute name of <stdlib.h>... " >&6; }
34313 if ${gl_cv_next_stdlib_h+:} false; then :
34314   $as_echo_n "(cached) " >&6
34315 else
34316
34317
34318
34319   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34320 /* end confdefs.h.  */
34321 #include <stdlib.h>
34322 _ACEOF
34323                 case "$host_os" in
34324     aix*) gl_absname_cpp="$ac_cpp -C" ;;
34325     *)    gl_absname_cpp="$ac_cpp" ;;
34326   esac
34327
34328   case "$host_os" in
34329     mingw*)
34330                                           gl_dirsep_regex='[/\\]'
34331       ;;
34332     *)
34333       gl_dirsep_regex='\/'
34334       ;;
34335   esac
34336       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
34337   gl_header_literal_regex=`echo 'stdlib.h' \
34338                            | sed -e "$gl_make_literal_regex_sed"`
34339   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
34340       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
34341       s|^/[^/]|//&|
34342       p
34343       q
34344     }'
34345
34346         gl_cv_absolute_stdlib_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
34347   sed -n "$gl_absolute_header_sed"`
34348
34349            gl_header=$gl_cv_absolute_stdlib_h
34350            gl_cv_next_stdlib_h='"'$gl_header'"'
34351
34352
34353 fi
34354 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdlib_h" >&5
34355 $as_echo "$gl_cv_next_stdlib_h" >&6; }
34356      fi
34357      NEXT_STDLIB_H=$gl_cv_next_stdlib_h
34358
34359      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
34360        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
34361        gl_next_as_first_directive='<'stdlib.h'>'
34362      else
34363        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
34364        gl_next_as_first_directive=$gl_cv_next_stdlib_h
34365      fi
34366      NEXT_AS_FIRST_DIRECTIVE_STDLIB_H=$gl_next_as_first_directive
34367
34368
34369
34370
34371
34372
34373
34374
34375
34376
34377
34378
34379
34380   for ac_func in stpcpy
34381 do :
34382   ac_fn_c_check_func "$LINENO" "stpcpy" "ac_cv_func_stpcpy"
34383 if test "x$ac_cv_func_stpcpy" = xyes; then :
34384   cat >>confdefs.h <<_ACEOF
34385 #define HAVE_STPCPY 1
34386 _ACEOF
34387
34388 fi
34389 done
34390
34391   if test $ac_cv_func_stpcpy = no; then
34392     HAVE_STPCPY=0
34393   fi
34394
34395   if test $HAVE_STPCPY = 0; then
34396
34397
34398
34399
34400
34401
34402
34403
34404   gl_LIBOBJS="$gl_LIBOBJS stpcpy.$ac_objext"
34405
34406
34407   :
34408
34409   fi
34410
34411
34412
34413
34414
34415           GNULIB_STPCPY=1
34416
34417
34418
34419
34420
34421 $as_echo "#define GNULIB_TEST_STPCPY 1" >>confdefs.h
34422
34423
34424
34425
34426
34427
34428   for ac_func in strcasecmp
34429 do :
34430   ac_fn_c_check_func "$LINENO" "strcasecmp" "ac_cv_func_strcasecmp"
34431 if test "x$ac_cv_func_strcasecmp" = xyes; then :
34432   cat >>confdefs.h <<_ACEOF
34433 #define HAVE_STRCASECMP 1
34434 _ACEOF
34435
34436 fi
34437 done
34438
34439   if test $ac_cv_func_strcasecmp = no; then
34440     HAVE_STRCASECMP=0
34441   fi
34442
34443
34444
34445   for ac_func in strncasecmp
34446 do :
34447   ac_fn_c_check_func "$LINENO" "strncasecmp" "ac_cv_func_strncasecmp"
34448 if test "x$ac_cv_func_strncasecmp" = xyes; then :
34449   cat >>confdefs.h <<_ACEOF
34450 #define HAVE_STRNCASECMP 1
34451 _ACEOF
34452
34453 fi
34454 done
34455
34456   if test $ac_cv_func_strncasecmp = yes; then
34457     HAVE_STRNCASECMP=1
34458   else
34459     HAVE_STRNCASECMP=0
34460   fi
34461   ac_fn_c_check_decl "$LINENO" "strncasecmp" "ac_cv_have_decl_strncasecmp" "$ac_includes_default"
34462 if test "x$ac_cv_have_decl_strncasecmp" = xyes; then :
34463   ac_have_decl=1
34464 else
34465   ac_have_decl=0
34466 fi
34467
34468 cat >>confdefs.h <<_ACEOF
34469 #define HAVE_DECL_STRNCASECMP $ac_have_decl
34470 _ACEOF
34471
34472   if test $ac_cv_have_decl_strncasecmp = no; then
34473     HAVE_DECL_STRNCASECMP=0
34474   fi
34475
34476
34477   if test $HAVE_STRCASECMP = 0; then
34478
34479
34480
34481
34482
34483
34484
34485
34486   gl_LIBOBJS="$gl_LIBOBJS strcasecmp.$ac_objext"
34487
34488
34489   :
34490
34491   fi
34492   if test $HAVE_STRNCASECMP = 0; then
34493
34494
34495
34496
34497
34498
34499
34500
34501   gl_LIBOBJS="$gl_LIBOBJS strncasecmp.$ac_objext"
34502
34503
34504   :
34505
34506   fi
34507
34508
34509
34510
34511   for ac_func in strchrnul
34512 do :
34513   ac_fn_c_check_func "$LINENO" "strchrnul" "ac_cv_func_strchrnul"
34514 if test "x$ac_cv_func_strchrnul" = xyes; then :
34515   cat >>confdefs.h <<_ACEOF
34516 #define HAVE_STRCHRNUL 1
34517 _ACEOF
34518
34519 fi
34520 done
34521
34522   if test $ac_cv_func_strchrnul = no; then
34523     HAVE_STRCHRNUL=0
34524   else
34525     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strchrnul works" >&5
34526 $as_echo_n "checking whether strchrnul works... " >&6; }
34527 if ${gl_cv_func_strchrnul_works+:} false; then :
34528   $as_echo_n "(cached) " >&6
34529 else
34530   if test "$cross_compiling" = yes; then :
34531            cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34532 /* end confdefs.h.  */
34533
34534 #if defined __CYGWIN__
34535  #include <cygwin/version.h>
34536  #if CYGWIN_VERSION_DLL_COMBINED > CYGWIN_VERSION_DLL_MAKE_COMBINED (1007, 9)
34537   Lucky user
34538  #endif
34539 #else
34540   Lucky user
34541 #endif
34542
34543 _ACEOF
34544 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
34545   $EGREP "Lucky user" >/dev/null 2>&1; then :
34546   gl_cv_func_strchrnul_works="guessing yes"
34547 else
34548   gl_cv_func_strchrnul_works="guessing no"
34549 fi
34550 rm -f conftest*
34551
34552
34553 else
34554   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34555 /* end confdefs.h.  */
34556
34557 #include <string.h> /* for strchrnul */
34558
34559 int
34560 main ()
34561 {
34562 const char *buf = "a";
34563       return strchrnul (buf, 'b') != buf + 1;
34564
34565   ;
34566   return 0;
34567 }
34568 _ACEOF
34569 if ac_fn_c_try_run "$LINENO"; then :
34570   gl_cv_func_strchrnul_works=yes
34571 else
34572   gl_cv_func_strchrnul_works=no
34573 fi
34574 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
34575   conftest.$ac_objext conftest.beam conftest.$ac_ext
34576 fi
34577
34578
34579 fi
34580 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strchrnul_works" >&5
34581 $as_echo "$gl_cv_func_strchrnul_works" >&6; }
34582     case "$gl_cv_func_strchrnul_works" in
34583       *yes) ;;
34584       *) REPLACE_STRCHRNUL=1 ;;
34585     esac
34586   fi
34587
34588   if test $HAVE_STRCHRNUL = 0 || test $REPLACE_STRCHRNUL = 1; then
34589
34590
34591
34592
34593
34594
34595
34596
34597   gl_LIBOBJS="$gl_LIBOBJS strchrnul.$ac_objext"
34598
34599     :
34600   fi
34601
34602
34603
34604
34605
34606           GNULIB_STRCHRNUL=1
34607
34608
34609
34610
34611
34612 $as_echo "#define GNULIB_TEST_STRCHRNUL 1" >>confdefs.h
34613
34614
34615
34616
34617
34618
34619
34620   :
34621
34622
34623
34624
34625
34626   if test $ac_cv_func_strdup = yes; then
34627     if test $gl_cv_func_malloc_posix != yes; then
34628       REPLACE_STRDUP=1
34629     fi
34630   fi
34631
34632   :
34633
34634
34635
34636
34637
34638   if test $ac_cv_have_decl_strdup = no; then
34639     HAVE_DECL_STRDUP=0
34640   fi
34641
34642   if test $ac_cv_func_strdup = no || test $REPLACE_STRDUP = 1; then
34643
34644
34645
34646
34647
34648
34649
34650
34651   gl_LIBOBJS="$gl_LIBOBJS strdup.$ac_objext"
34652
34653     :
34654   fi
34655
34656
34657
34658
34659
34660           GNULIB_STRDUP=1
34661
34662
34663
34664
34665
34666 $as_echo "#define GNULIB_TEST_STRDUP 1" >>confdefs.h
34667
34668
34669
34670
34671
34672
34673
34674
34675
34676
34677   if test "$ERRNO_H:$REPLACE_STRERROR_0" = :0; then
34678     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working strerror function" >&5
34679 $as_echo_n "checking for working strerror function... " >&6; }
34680 if ${gl_cv_func_working_strerror+:} false; then :
34681   $as_echo_n "(cached) " >&6
34682 else
34683   if test "$cross_compiling" = yes; then :
34684   case "$host_os" in
34685                    # Guess yes on glibc systems.
34686            *-gnu*) gl_cv_func_working_strerror="guessing yes" ;;
34687                    # If we don't know, assume the worst.
34688            *)      gl_cv_func_working_strerror="guessing no" ;;
34689          esac
34690
34691 else
34692   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34693 /* end confdefs.h.  */
34694 #include <string.h>
34695
34696 int
34697 main ()
34698 {
34699 if (!*strerror (-2)) return 1;
34700   ;
34701   return 0;
34702 }
34703 _ACEOF
34704 if ac_fn_c_try_run "$LINENO"; then :
34705   gl_cv_func_working_strerror=yes
34706 else
34707   gl_cv_func_working_strerror=no
34708 fi
34709 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
34710   conftest.$ac_objext conftest.beam conftest.$ac_ext
34711 fi
34712
34713
34714 fi
34715 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_strerror" >&5
34716 $as_echo "$gl_cv_func_working_strerror" >&6; }
34717     case "$gl_cv_func_working_strerror" in
34718       *yes) ;;
34719       *)
34720                         REPLACE_STRERROR=1
34721         ;;
34722     esac
34723
34724                   case "$gl_cv_func_strerror_r_works" in
34725         *no) REPLACE_STRERROR=1 ;;
34726       esac
34727
34728   else
34729             REPLACE_STRERROR=1
34730   fi
34731
34732   if test $REPLACE_STRERROR = 1; then
34733
34734
34735
34736
34737
34738
34739
34740
34741   gl_LIBOBJS="$gl_LIBOBJS strerror.$ac_objext"
34742
34743   fi
34744
34745
34746 cat >>confdefs.h <<_ACEOF
34747 #define GNULIB_STRERROR 1
34748 _ACEOF
34749
34750
34751
34752
34753
34754
34755
34756           GNULIB_STRERROR=1
34757
34758
34759
34760
34761
34762 $as_echo "#define GNULIB_TEST_STRERROR 1" >>confdefs.h
34763
34764
34765
34766
34767
34768   if test -n "$ERRNO_H" || test $REPLACE_STRERROR_0 = 1; then
34769
34770
34771
34772
34773
34774
34775
34776
34777   gl_LIBOBJS="$gl_LIBOBJS strerror-override.$ac_objext"
34778
34779
34780
34781
34782
34783   :
34784
34785
34786
34787
34788
34789   if test $ac_cv_header_sys_socket_h != yes; then
34790                     for ac_header in winsock2.h
34791 do :
34792   ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
34793 if test "x$ac_cv_header_winsock2_h" = xyes; then :
34794   cat >>confdefs.h <<_ACEOF
34795 #define HAVE_WINSOCK2_H 1
34796 _ACEOF
34797
34798 fi
34799
34800 done
34801
34802   fi
34803   if test "$ac_cv_header_winsock2_h" = yes; then
34804     HAVE_WINSOCK2_H=1
34805     UNISTD_H_HAVE_WINSOCK2_H=1
34806     SYS_IOCTL_H_HAVE_WINSOCK2_H=1
34807   else
34808     HAVE_WINSOCK2_H=0
34809   fi
34810
34811
34812   fi
34813
34814
34815
34816
34817
34818
34819
34820   :
34821
34822
34823
34824
34825
34826   if test $ac_cv_have_decl_strerror_r = no; then
34827     HAVE_DECL_STRERROR_R=0
34828   fi
34829
34830   if test $ac_cv_func_strerror_r = yes; then
34831     if test "$ERRNO_H:$REPLACE_STRERROR_0" = :0; then
34832       if test $gl_cv_func_strerror_r_posix_signature = yes; then
34833         case "$gl_cv_func_strerror_r_works" in
34834                     *no) REPLACE_STRERROR_R=1 ;;
34835         esac
34836       else
34837                 REPLACE_STRERROR_R=1
34838       fi
34839     else
34840                   REPLACE_STRERROR_R=1
34841     fi
34842   fi
34843
34844   if test $HAVE_DECL_STRERROR_R = 0 || test $REPLACE_STRERROR_R = 1; then
34845
34846
34847
34848
34849
34850
34851
34852
34853   gl_LIBOBJS="$gl_LIBOBJS strerror_r.$ac_objext"
34854
34855
34856
34857   :
34858
34859
34860
34861
34862
34863
34864   :
34865
34866
34867
34868
34869
34870
34871   :
34872
34873
34874
34875
34876
34877
34878   fi
34879
34880
34881
34882
34883
34884           GNULIB_STRERROR_R=1
34885
34886
34887
34888
34889
34890 $as_echo "#define GNULIB_TEST_STRERROR_R 1" >>confdefs.h
34891
34892
34893
34894
34895
34896
34897
34898
34899
34900
34901
34902
34903
34904
34905   :
34906
34907
34908
34909
34910
34911
34912   :
34913
34914
34915
34916
34917
34918   if test $ac_cv_have_decl_strndup = no; then
34919     HAVE_DECL_STRNDUP=0
34920   fi
34921
34922   if test $ac_cv_func_strndup = yes; then
34923     HAVE_STRNDUP=1
34924     # AIX 4.3.3, AIX 5.1 have a function that fails to add the terminating '\0'.
34925     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working strndup" >&5
34926 $as_echo_n "checking for working strndup... " >&6; }
34927 if ${gl_cv_func_strndup_works+:} false; then :
34928   $as_echo_n "(cached) " >&6
34929 else
34930   if test "$cross_compiling" = yes; then :
34931
34932           case $host_os in
34933             aix | aix[3-6]*) gl_cv_func_strndup_works="guessing no";;
34934             *)               gl_cv_func_strndup_works="guessing yes";;
34935           esac
34936
34937 else
34938   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
34939 /* end confdefs.h.  */
34940
34941          #include <string.h>
34942                            #include <stdlib.h>
34943 int
34944 main ()
34945 {
34946
34947 #if !HAVE_DECL_STRNDUP
34948   extern
34949   #ifdef __cplusplus
34950   "C"
34951   #endif
34952   char *strndup (const char *, size_t);
34953 #endif
34954   char *s;
34955   s = strndup ("some longer string", 15);
34956   free (s);
34957   s = strndup ("shorter string", 13);
34958   return s[13] != '\0';
34959   ;
34960   return 0;
34961 }
34962 _ACEOF
34963 if ac_fn_c_try_run "$LINENO"; then :
34964   gl_cv_func_strndup_works=yes
34965 else
34966   gl_cv_func_strndup_works=no
34967 fi
34968 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
34969   conftest.$ac_objext conftest.beam conftest.$ac_ext
34970 fi
34971
34972 fi
34973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strndup_works" >&5
34974 $as_echo "$gl_cv_func_strndup_works" >&6; }
34975     case $gl_cv_func_strndup_works in
34976       *no) REPLACE_STRNDUP=1 ;;
34977     esac
34978   else
34979     HAVE_STRNDUP=0
34980   fi
34981
34982   if test $HAVE_STRNDUP = 0 || test $REPLACE_STRNDUP = 1; then
34983
34984
34985
34986
34987
34988
34989
34990
34991   gl_LIBOBJS="$gl_LIBOBJS strndup.$ac_objext"
34992
34993   fi
34994
34995
34996
34997
34998
34999           GNULIB_STRNDUP=1
35000
35001
35002
35003
35004
35005 $as_echo "#define GNULIB_TEST_STRNDUP 1" >>confdefs.h
35006
35007
35008
35009
35010
35011
35012
35013
35014
35015   :
35016
35017
35018
35019
35020
35021   if test $ac_cv_have_decl_strnlen = no; then
35022     HAVE_DECL_STRNLEN=0
35023   else
35024
35025          { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working strnlen" >&5
35026 $as_echo_n "checking for working strnlen... " >&6; }
35027 if ${ac_cv_func_strnlen_working+:} false; then :
35028   $as_echo_n "(cached) " >&6
35029 else
35030   if test "$cross_compiling" = yes; then :
35031   # Guess no on AIX systems, yes otherwise.
35032                 case "$host_os" in
35033                   aix*) ac_cv_func_strnlen_working=no;;
35034                   *)    ac_cv_func_strnlen_working=yes;;
35035                 esac
35036 else
35037   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35038 /* end confdefs.h.  */
35039 $ac_includes_default
35040 int
35041 main ()
35042 {
35043
35044 #define S "foobar"
35045 #define S_LEN (sizeof S - 1)
35046
35047   /* At least one implementation is buggy: that of AIX 4.3 would
35048      give strnlen (S, 1) == 3.  */
35049
35050   int i;
35051   for (i = 0; i < S_LEN + 1; ++i)
35052     {
35053       int expected = i <= S_LEN ? i : S_LEN;
35054       if (strnlen (S, i) != expected)
35055         return 1;
35056     }
35057   return 0;
35058
35059   ;
35060   return 0;
35061 }
35062 _ACEOF
35063 if ac_fn_c_try_run "$LINENO"; then :
35064   ac_cv_func_strnlen_working=yes
35065 else
35066   ac_cv_func_strnlen_working=no
35067 fi
35068 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
35069   conftest.$ac_objext conftest.beam conftest.$ac_ext
35070 fi
35071
35072 fi
35073 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strnlen_working" >&5
35074 $as_echo "$ac_cv_func_strnlen_working" >&6; }
35075 test $ac_cv_func_strnlen_working = no && :
35076
35077
35078     if test $ac_cv_func_strnlen_working = no; then
35079       REPLACE_STRNLEN=1
35080     fi
35081   fi
35082
35083   if test $HAVE_DECL_STRNLEN = 0 || test $REPLACE_STRNLEN = 1; then
35084
35085
35086
35087
35088
35089
35090
35091
35092   gl_LIBOBJS="$gl_LIBOBJS strnlen.$ac_objext"
35093
35094     :
35095   fi
35096
35097
35098
35099
35100
35101           GNULIB_STRNLEN=1
35102
35103
35104
35105
35106
35107 $as_echo "#define GNULIB_TEST_STRNLEN 1" >>confdefs.h
35108
35109
35110
35111
35112
35113
35114
35115   :
35116
35117
35118
35119
35120
35121   if test $ac_cv_func_strptime != yes; then
35122     HAVE_STRPTIME=0
35123   fi
35124
35125   if test $HAVE_STRPTIME = 0; then
35126
35127
35128
35129
35130
35131
35132
35133
35134   gl_LIBOBJS="$gl_LIBOBJS strptime.$ac_objext"
35135
35136
35137
35138   :
35139
35140   fi
35141
35142
35143
35144
35145
35146           GNULIB_STRPTIME=1
35147
35148
35149
35150
35151
35152 $as_echo "#define GNULIB_TEST_STRPTIME 1" >>confdefs.h
35153
35154
35155
35156
35157
35158
35159
35160
35161
35162   for ac_func in strsep
35163 do :
35164   ac_fn_c_check_func "$LINENO" "strsep" "ac_cv_func_strsep"
35165 if test "x$ac_cv_func_strsep" = xyes; then :
35166   cat >>confdefs.h <<_ACEOF
35167 #define HAVE_STRSEP 1
35168 _ACEOF
35169
35170 fi
35171 done
35172
35173   if test $ac_cv_func_strsep = no; then
35174     HAVE_STRSEP=0
35175   fi
35176
35177   if test $HAVE_STRSEP = 0; then
35178
35179
35180
35181
35182
35183
35184
35185
35186   gl_LIBOBJS="$gl_LIBOBJS strsep.$ac_objext"
35187
35188     :
35189   fi
35190
35191
35192
35193
35194
35195           GNULIB_STRSEP=1
35196
35197
35198
35199
35200
35201 $as_echo "#define GNULIB_TEST_STRSEP 1" >>confdefs.h
35202
35203
35204
35205
35206
35207
35208
35209      for ac_func in strtok_r
35210 do :
35211   ac_fn_c_check_func "$LINENO" "strtok_r" "ac_cv_func_strtok_r"
35212 if test "x$ac_cv_func_strtok_r" = xyes; then :
35213   cat >>confdefs.h <<_ACEOF
35214 #define HAVE_STRTOK_R 1
35215 _ACEOF
35216
35217 fi
35218 done
35219
35220   if test $ac_cv_func_strtok_r = yes; then
35221     HAVE_STRTOK_R=1
35222                         { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtok_r works" >&5
35223 $as_echo_n "checking whether strtok_r works... " >&6; }
35224 if ${gl_cv_func_strtok_r_works+:} false; then :
35225   $as_echo_n "(cached) " >&6
35226 else
35227   if test "$cross_compiling" = yes; then :
35228
35229           case "$host_os" in
35230                     # Guess no on glibc systems.
35231             *-gnu*) gl_cv_func_strtok_r_works="guessing no";;
35232             *)      gl_cv_func_strtok_r_works="guessing yes";;
35233           esac
35234
35235 else
35236   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35237 /* end confdefs.h.  */
35238
35239               #ifndef __OPTIMIZE__
35240               # define __OPTIMIZE__ 1
35241               #endif
35242               #undef __OPTIMIZE_SIZE__
35243               #undef __NO_INLINE__
35244               #include <stdlib.h>
35245               #include <string.h>
35246
35247 int
35248 main ()
35249 {
35250 static const char dummy[] = "\177\01a";
35251               char delimiters[] = "xxxxxxxx";
35252               char *save_ptr = (char *) dummy;
35253               strtok_r (delimiters, "x", &save_ptr);
35254               strtok_r (NULL, "x", &save_ptr);
35255               return 0;
35256
35257   ;
35258   return 0;
35259 }
35260
35261 _ACEOF
35262 if ac_fn_c_try_run "$LINENO"; then :
35263   gl_cv_func_strtok_r_works=yes
35264 else
35265   gl_cv_func_strtok_r_works=no
35266 fi
35267 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
35268   conftest.$ac_objext conftest.beam conftest.$ac_ext
35269 fi
35270
35271
35272 fi
35273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strtok_r_works" >&5
35274 $as_echo "$gl_cv_func_strtok_r_works" >&6; }
35275     case "$gl_cv_func_strtok_r_works" in
35276       *no)
35277                                 UNDEFINE_STRTOK_R=1
35278         ;;
35279     esac
35280   else
35281     HAVE_STRTOK_R=0
35282   fi
35283
35284   :
35285
35286
35287
35288
35289
35290   if test $ac_cv_have_decl_strtok_r = no; then
35291     HAVE_DECL_STRTOK_R=0
35292   fi
35293
35294   if test $HAVE_STRTOK_R = 0 || test $REPLACE_STRTOK_R = 1; then
35295
35296
35297
35298
35299
35300
35301
35302
35303   gl_LIBOBJS="$gl_LIBOBJS strtok_r.$ac_objext"
35304
35305
35306   :
35307
35308   fi
35309
35310
35311
35312
35313
35314           GNULIB_STRTOK_R=1
35315
35316
35317
35318
35319
35320 $as_echo "#define GNULIB_TEST_STRTOK_R 1" >>confdefs.h
35321
35322
35323
35324
35325
35326
35327
35328   :
35329
35330
35331
35332
35333
35334   if test $ac_cv_header_sys_ioctl_h = yes; then
35335     HAVE_SYS_IOCTL_H=1
35336             { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/ioctl.h> declares ioctl" >&5
35337 $as_echo_n "checking whether <sys/ioctl.h> declares ioctl... " >&6; }
35338 if ${gl_cv_decl_ioctl_in_sys_ioctl_h+:} false; then :
35339   $as_echo_n "(cached) " >&6
35340 else
35341          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35342 /* end confdefs.h.  */
35343 #include <sys/ioctl.h>
35344
35345 int
35346 main ()
35347 {
35348 (void) ioctl;
35349   ;
35350   return 0;
35351 }
35352 _ACEOF
35353 if ac_fn_c_try_compile "$LINENO"; then :
35354   gl_cv_decl_ioctl_in_sys_ioctl_h=yes
35355 else
35356   gl_cv_decl_ioctl_in_sys_ioctl_h=no
35357 fi
35358 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
35359
35360 fi
35361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_ioctl_in_sys_ioctl_h" >&5
35362 $as_echo "$gl_cv_decl_ioctl_in_sys_ioctl_h" >&6; }
35363   else
35364     HAVE_SYS_IOCTL_H=0
35365   fi
35366
35367
35368
35369
35370
35371
35372
35373   :
35374
35375
35376
35377
35378
35379
35380
35381
35382      if test $gl_cv_have_include_next = yes; then
35383        gl_cv_next_sys_ioctl_h='<'sys/ioctl.h'>'
35384      else
35385        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/ioctl.h>" >&5
35386 $as_echo_n "checking absolute name of <sys/ioctl.h>... " >&6; }
35387 if ${gl_cv_next_sys_ioctl_h+:} false; then :
35388   $as_echo_n "(cached) " >&6
35389 else
35390
35391              if test $ac_cv_header_sys_ioctl_h = yes; then
35392
35393
35394
35395
35396   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35397 /* end confdefs.h.  */
35398 #include <sys/ioctl.h>
35399 _ACEOF
35400                 case "$host_os" in
35401     aix*) gl_absname_cpp="$ac_cpp -C" ;;
35402     *)    gl_absname_cpp="$ac_cpp" ;;
35403   esac
35404
35405   case "$host_os" in
35406     mingw*)
35407                                           gl_dirsep_regex='[/\\]'
35408       ;;
35409     *)
35410       gl_dirsep_regex='\/'
35411       ;;
35412   esac
35413       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
35414   gl_header_literal_regex=`echo 'sys/ioctl.h' \
35415                            | sed -e "$gl_make_literal_regex_sed"`
35416   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
35417       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
35418       s|^/[^/]|//&|
35419       p
35420       q
35421     }'
35422
35423         gl_cv_absolute_sys_ioctl_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
35424   sed -n "$gl_absolute_header_sed"`
35425
35426            gl_header=$gl_cv_absolute_sys_ioctl_h
35427            gl_cv_next_sys_ioctl_h='"'$gl_header'"'
35428           else
35429                gl_cv_next_sys_ioctl_h='<'sys/ioctl.h'>'
35430              fi
35431
35432
35433 fi
35434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_ioctl_h" >&5
35435 $as_echo "$gl_cv_next_sys_ioctl_h" >&6; }
35436      fi
35437      NEXT_SYS_IOCTL_H=$gl_cv_next_sys_ioctl_h
35438
35439      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
35440        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
35441        gl_next_as_first_directive='<'sys/ioctl.h'>'
35442      else
35443        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
35444        gl_next_as_first_directive=$gl_cv_next_sys_ioctl_h
35445      fi
35446      NEXT_AS_FIRST_DIRECTIVE_SYS_IOCTL_H=$gl_next_as_first_directive
35447
35448
35449
35450
35451
35452
35453
35454
35455
35456
35457
35458   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
35459 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
35460 if ${gl_cv_header_sys_select_h_selfcontained+:} false; then :
35461   $as_echo_n "(cached) " >&6
35462 else
35463
35464                                     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35465 /* end confdefs.h.  */
35466 #include <sys/select.h>
35467 int
35468 main ()
35469 {
35470 struct timeval b;
35471   ;
35472   return 0;
35473 }
35474 _ACEOF
35475 if ac_fn_c_try_compile "$LINENO"; then :
35476   gl_cv_header_sys_select_h_selfcontained=yes
35477 else
35478   gl_cv_header_sys_select_h_selfcontained=no
35479 fi
35480 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
35481                         if test $gl_cv_header_sys_select_h_selfcontained = yes; then
35482         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35483 /* end confdefs.h.  */
35484 #include <sys/select.h>
35485 int
35486 main ()
35487 {
35488 int memset; int bzero;
35489   ;
35490   return 0;
35491 }
35492
35493 _ACEOF
35494 if ac_fn_c_try_compile "$LINENO"; then :
35495   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35496 /* end confdefs.h.  */
35497 #include <sys/select.h>
35498 int
35499 main ()
35500 {
35501
35502                   #undef memset
35503                   #define memset nonexistent_memset
35504                   extern
35505                   #ifdef __cplusplus
35506                   "C"
35507                   #endif
35508                   void *memset (void *, int, unsigned long);
35509                   #undef bzero
35510                   #define bzero nonexistent_bzero
35511                   extern
35512                   #ifdef __cplusplus
35513                   "C"
35514                   #endif
35515                   void bzero (void *, unsigned long);
35516                   fd_set fds;
35517                   FD_ZERO (&fds);
35518
35519   ;
35520   return 0;
35521 }
35522
35523 _ACEOF
35524 if ac_fn_c_try_link "$LINENO"; then :
35525
35526 else
35527   gl_cv_header_sys_select_h_selfcontained=no
35528 fi
35529 rm -f core conftest.err conftest.$ac_objext \
35530     conftest$ac_exeext conftest.$ac_ext
35531
35532 fi
35533 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
35534       fi
35535
35536 fi
35537 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
35538 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
35539
35540
35541
35542
35543
35544
35545   :
35546
35547
35548
35549
35550
35551
35552
35553
35554      if test $gl_cv_have_include_next = yes; then
35555        gl_cv_next_sys_select_h='<'sys/select.h'>'
35556      else
35557        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
35558 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
35559 if ${gl_cv_next_sys_select_h+:} false; then :
35560   $as_echo_n "(cached) " >&6
35561 else
35562
35563              if test $ac_cv_header_sys_select_h = yes; then
35564
35565
35566
35567
35568   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35569 /* end confdefs.h.  */
35570 #include <sys/select.h>
35571 _ACEOF
35572                 case "$host_os" in
35573     aix*) gl_absname_cpp="$ac_cpp -C" ;;
35574     *)    gl_absname_cpp="$ac_cpp" ;;
35575   esac
35576
35577   case "$host_os" in
35578     mingw*)
35579                                           gl_dirsep_regex='[/\\]'
35580       ;;
35581     *)
35582       gl_dirsep_regex='\/'
35583       ;;
35584   esac
35585       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
35586   gl_header_literal_regex=`echo 'sys/select.h' \
35587                            | sed -e "$gl_make_literal_regex_sed"`
35588   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
35589       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
35590       s|^/[^/]|//&|
35591       p
35592       q
35593     }'
35594
35595         gl_cv_absolute_sys_select_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
35596   sed -n "$gl_absolute_header_sed"`
35597
35598            gl_header=$gl_cv_absolute_sys_select_h
35599            gl_cv_next_sys_select_h='"'$gl_header'"'
35600           else
35601                gl_cv_next_sys_select_h='<'sys/select.h'>'
35602              fi
35603
35604
35605 fi
35606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
35607 $as_echo "$gl_cv_next_sys_select_h" >&6; }
35608      fi
35609      NEXT_SYS_SELECT_H=$gl_cv_next_sys_select_h
35610
35611      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
35612        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
35613        gl_next_as_first_directive='<'sys/select.h'>'
35614      else
35615        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
35616        gl_next_as_first_directive=$gl_cv_next_sys_select_h
35617      fi
35618      NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H=$gl_next_as_first_directive
35619
35620
35621
35622
35623   if test $ac_cv_header_sys_select_h = yes; then
35624     HAVE_SYS_SELECT_H=1
35625   else
35626     HAVE_SYS_SELECT_H=0
35627   fi
35628
35629
35630
35631
35632
35633   :
35634
35635
35636
35637
35638
35639   if test $ac_cv_header_sys_socket_h != yes; then
35640                     for ac_header in winsock2.h
35641 do :
35642   ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
35643 if test "x$ac_cv_header_winsock2_h" = xyes; then :
35644   cat >>confdefs.h <<_ACEOF
35645 #define HAVE_WINSOCK2_H 1
35646 _ACEOF
35647
35648 fi
35649
35650 done
35651
35652   fi
35653   if test "$ac_cv_header_winsock2_h" = yes; then
35654     HAVE_WINSOCK2_H=1
35655     UNISTD_H_HAVE_WINSOCK2_H=1
35656     SYS_IOCTL_H_HAVE_WINSOCK2_H=1
35657   else
35658     HAVE_WINSOCK2_H=0
35659   fi
35660
35661
35662
35663
35664
35665
35666
35667
35668
35669
35670         case "$host_os" in
35671     osf*)
35672
35673 $as_echo "#define _POSIX_PII_SOCKET 1" >>confdefs.h
35674
35675       ;;
35676   esac
35677
35678   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/socket.h> is self-contained" >&5
35679 $as_echo_n "checking whether <sys/socket.h> is self-contained... " >&6; }
35680 if ${gl_cv_header_sys_socket_h_selfcontained+:} false; then :
35681   $as_echo_n "(cached) " >&6
35682 else
35683
35684       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35685 /* end confdefs.h.  */
35686 #include <sys/socket.h>
35687 int
35688 main ()
35689 {
35690
35691   ;
35692   return 0;
35693 }
35694 _ACEOF
35695 if ac_fn_c_try_compile "$LINENO"; then :
35696   gl_cv_header_sys_socket_h_selfcontained=yes
35697 else
35698   gl_cv_header_sys_socket_h_selfcontained=no
35699 fi
35700 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
35701
35702 fi
35703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_socket_h_selfcontained" >&5
35704 $as_echo "$gl_cv_header_sys_socket_h_selfcontained" >&6; }
35705   if test $gl_cv_header_sys_socket_h_selfcontained = yes; then
35706             for ac_func in shutdown
35707 do :
35708   ac_fn_c_check_func "$LINENO" "shutdown" "ac_cv_func_shutdown"
35709 if test "x$ac_cv_func_shutdown" = xyes; then :
35710   cat >>confdefs.h <<_ACEOF
35711 #define HAVE_SHUTDOWN 1
35712 _ACEOF
35713
35714 fi
35715 done
35716
35717     if test $ac_cv_func_shutdown = yes; then
35718       { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/socket.h> defines the SHUT_* macros" >&5
35719 $as_echo_n "checking whether <sys/socket.h> defines the SHUT_* macros... " >&6; }
35720 if ${gl_cv_header_sys_socket_h_shut+:} false; then :
35721   $as_echo_n "(cached) " >&6
35722 else
35723
35724           cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35725 /* end confdefs.h.  */
35726 #include <sys/socket.h>
35727 int
35728 main ()
35729 {
35730 int a[] = { SHUT_RD, SHUT_WR, SHUT_RDWR };
35731   ;
35732   return 0;
35733 }
35734 _ACEOF
35735 if ac_fn_c_try_compile "$LINENO"; then :
35736   gl_cv_header_sys_socket_h_shut=yes
35737 else
35738   gl_cv_header_sys_socket_h_shut=no
35739 fi
35740 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
35741
35742 fi
35743 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_socket_h_shut" >&5
35744 $as_echo "$gl_cv_header_sys_socket_h_shut" >&6; }
35745       if test $gl_cv_header_sys_socket_h_shut = no; then
35746         SYS_SOCKET_H='sys/socket.h'
35747       fi
35748     fi
35749   fi
35750   # We need to check for ws2tcpip.h now.
35751
35752
35753
35754
35755
35756
35757
35758
35759   :
35760
35761
35762
35763
35764
35765
35766
35767
35768      if test $gl_cv_have_include_next = yes; then
35769        gl_cv_next_sys_socket_h='<'sys/socket.h'>'
35770      else
35771        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/socket.h>" >&5
35772 $as_echo_n "checking absolute name of <sys/socket.h>... " >&6; }
35773 if ${gl_cv_next_sys_socket_h+:} false; then :
35774   $as_echo_n "(cached) " >&6
35775 else
35776
35777              if test $ac_cv_header_sys_socket_h = yes; then
35778
35779
35780
35781
35782   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35783 /* end confdefs.h.  */
35784 #include <sys/socket.h>
35785 _ACEOF
35786                 case "$host_os" in
35787     aix*) gl_absname_cpp="$ac_cpp -C" ;;
35788     *)    gl_absname_cpp="$ac_cpp" ;;
35789   esac
35790
35791   case "$host_os" in
35792     mingw*)
35793                                           gl_dirsep_regex='[/\\]'
35794       ;;
35795     *)
35796       gl_dirsep_regex='\/'
35797       ;;
35798   esac
35799       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
35800   gl_header_literal_regex=`echo 'sys/socket.h' \
35801                            | sed -e "$gl_make_literal_regex_sed"`
35802   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
35803       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
35804       s|^/[^/]|//&|
35805       p
35806       q
35807     }'
35808
35809         gl_cv_absolute_sys_socket_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
35810   sed -n "$gl_absolute_header_sed"`
35811
35812            gl_header=$gl_cv_absolute_sys_socket_h
35813            gl_cv_next_sys_socket_h='"'$gl_header'"'
35814           else
35815                gl_cv_next_sys_socket_h='<'sys/socket.h'>'
35816              fi
35817
35818
35819 fi
35820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_socket_h" >&5
35821 $as_echo "$gl_cv_next_sys_socket_h" >&6; }
35822      fi
35823      NEXT_SYS_SOCKET_H=$gl_cv_next_sys_socket_h
35824
35825      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
35826        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
35827        gl_next_as_first_directive='<'sys/socket.h'>'
35828      else
35829        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
35830        gl_next_as_first_directive=$gl_cv_next_sys_socket_h
35831      fi
35832      NEXT_AS_FIRST_DIRECTIVE_SYS_SOCKET_H=$gl_next_as_first_directive
35833
35834
35835
35836
35837   if test $ac_cv_header_sys_socket_h = yes; then
35838     HAVE_SYS_SOCKET_H=1
35839     HAVE_WS2TCPIP_H=0
35840   else
35841     HAVE_SYS_SOCKET_H=0
35842     if test $ac_cv_header_ws2tcpip_h = yes; then
35843       HAVE_WS2TCPIP_H=1
35844     else
35845       HAVE_WS2TCPIP_H=0
35846     fi
35847   fi
35848
35849
35850
35851   ac_fn_c_check_type "$LINENO" "struct sockaddr_storage" "ac_cv_type_struct_sockaddr_storage" "
35852   /* sys/types.h is not needed according to POSIX, but the
35853      sys/socket.h in i386-unknown-freebsd4.10 and
35854      powerpc-apple-darwin5.5 required it. */
35855 #include <sys/types.h>
35856 #ifdef HAVE_SYS_SOCKET_H
35857 #include <sys/socket.h>
35858 #endif
35859 #ifdef HAVE_WS2TCPIP_H
35860 #include <ws2tcpip.h>
35861 #endif
35862
35863 "
35864 if test "x$ac_cv_type_struct_sockaddr_storage" = xyes; then :
35865
35866 cat >>confdefs.h <<_ACEOF
35867 #define HAVE_STRUCT_SOCKADDR_STORAGE 1
35868 _ACEOF
35869
35870
35871 fi
35872 ac_fn_c_check_type "$LINENO" "sa_family_t" "ac_cv_type_sa_family_t" "
35873   /* sys/types.h is not needed according to POSIX, but the
35874      sys/socket.h in i386-unknown-freebsd4.10 and
35875      powerpc-apple-darwin5.5 required it. */
35876 #include <sys/types.h>
35877 #ifdef HAVE_SYS_SOCKET_H
35878 #include <sys/socket.h>
35879 #endif
35880 #ifdef HAVE_WS2TCPIP_H
35881 #include <ws2tcpip.h>
35882 #endif
35883
35884 "
35885 if test "x$ac_cv_type_sa_family_t" = xyes; then :
35886
35887 cat >>confdefs.h <<_ACEOF
35888 #define HAVE_SA_FAMILY_T 1
35889 _ACEOF
35890
35891
35892 fi
35893
35894   if test $ac_cv_type_struct_sockaddr_storage = no; then
35895     HAVE_STRUCT_SOCKADDR_STORAGE=0
35896   fi
35897   if test $ac_cv_type_sa_family_t = no; then
35898     HAVE_SA_FAMILY_T=0
35899   fi
35900   if test $ac_cv_type_struct_sockaddr_storage != no; then
35901     ac_fn_c_check_member "$LINENO" "struct sockaddr_storage" "ss_family" "ac_cv_member_struct_sockaddr_storage_ss_family" "#include <sys/types.h>
35902        #ifdef HAVE_SYS_SOCKET_H
35903        #include <sys/socket.h>
35904        #endif
35905        #ifdef HAVE_WS2TCPIP_H
35906        #include <ws2tcpip.h>
35907        #endif
35908
35909 "
35910 if test "x$ac_cv_member_struct_sockaddr_storage_ss_family" = xyes; then :
35911
35912 cat >>confdefs.h <<_ACEOF
35913 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY 1
35914 _ACEOF
35915
35916
35917 else
35918   HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY=0
35919 fi
35920
35921   fi
35922   if test $HAVE_STRUCT_SOCKADDR_STORAGE = 0 || test $HAVE_SA_FAMILY_T = 0 \
35923      || test $HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY = 0; then
35924     SYS_SOCKET_H='sys/socket.h'
35925   fi
35926
35927
35928
35929
35930   :
35931
35932
35933
35934
35935
35936   if test $ac_cv_header_sys_socket_h != yes; then
35937                     for ac_header in winsock2.h
35938 do :
35939   ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
35940 if test "x$ac_cv_header_winsock2_h" = xyes; then :
35941   cat >>confdefs.h <<_ACEOF
35942 #define HAVE_WINSOCK2_H 1
35943 _ACEOF
35944
35945 fi
35946
35947 done
35948
35949   fi
35950   if test "$ac_cv_header_winsock2_h" = yes; then
35951     HAVE_WINSOCK2_H=1
35952     UNISTD_H_HAVE_WINSOCK2_H=1
35953     SYS_IOCTL_H_HAVE_WINSOCK2_H=1
35954   else
35955     HAVE_WINSOCK2_H=0
35956   fi
35957
35958
35959
35960
35961
35962
35963
35964
35965
35966
35967
35968
35969
35970
35971
35972
35973
35974   :
35975
35976
35977
35978
35979
35980
35981
35982
35983      if test $gl_cv_have_include_next = yes; then
35984        gl_cv_next_sys_stat_h='<'sys/stat.h'>'
35985      else
35986        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
35987 $as_echo_n "checking absolute name of <sys/stat.h>... " >&6; }
35988 if ${gl_cv_next_sys_stat_h+:} false; then :
35989   $as_echo_n "(cached) " >&6
35990 else
35991
35992              if test $ac_cv_header_sys_stat_h = yes; then
35993
35994
35995
35996
35997   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
35998 /* end confdefs.h.  */
35999 #include <sys/stat.h>
36000 _ACEOF
36001                 case "$host_os" in
36002     aix*) gl_absname_cpp="$ac_cpp -C" ;;
36003     *)    gl_absname_cpp="$ac_cpp" ;;
36004   esac
36005
36006   case "$host_os" in
36007     mingw*)
36008                                           gl_dirsep_regex='[/\\]'
36009       ;;
36010     *)
36011       gl_dirsep_regex='\/'
36012       ;;
36013   esac
36014       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
36015   gl_header_literal_regex=`echo 'sys/stat.h' \
36016                            | sed -e "$gl_make_literal_regex_sed"`
36017   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
36018       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
36019       s|^/[^/]|//&|
36020       p
36021       q
36022     }'
36023
36024         gl_cv_absolute_sys_stat_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
36025   sed -n "$gl_absolute_header_sed"`
36026
36027            gl_header=$gl_cv_absolute_sys_stat_h
36028            gl_cv_next_sys_stat_h='"'$gl_header'"'
36029           else
36030                gl_cv_next_sys_stat_h='<'sys/stat.h'>'
36031              fi
36032
36033
36034 fi
36035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
36036 $as_echo "$gl_cv_next_sys_stat_h" >&6; }
36037      fi
36038      NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h
36039
36040      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
36041        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
36042        gl_next_as_first_directive='<'sys/stat.h'>'
36043      else
36044        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
36045        gl_next_as_first_directive=$gl_cv_next_sys_stat_h
36046      fi
36047      NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive
36048
36049
36050
36051
36052
36053
36054
36055
36056
36057
36058
36059   if test $WINDOWS_64_BIT_ST_SIZE = 1; then
36060
36061 $as_echo "#define _GL_WINDOWS_64_BIT_ST_SIZE 1" >>confdefs.h
36062
36063   fi
36064
36065       ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
36066      #include <sys/stat.h>
36067 "
36068 if test "x$ac_cv_type_nlink_t" = xyes; then :
36069
36070 else
36071
36072 $as_echo "#define nlink_t int" >>confdefs.h
36073
36074 fi
36075
36076
36077
36078
36079
36080
36081
36082
36083
36084
36085
36086
36087
36088
36089
36090
36091
36092
36093
36094   :
36095
36096
36097
36098
36099
36100
36101
36102
36103      if test $gl_cv_have_include_next = yes; then
36104        gl_cv_next_sys_uio_h='<'sys/uio.h'>'
36105      else
36106        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/uio.h>" >&5
36107 $as_echo_n "checking absolute name of <sys/uio.h>... " >&6; }
36108 if ${gl_cv_next_sys_uio_h+:} false; then :
36109   $as_echo_n "(cached) " >&6
36110 else
36111
36112              if test $ac_cv_header_sys_uio_h = yes; then
36113
36114
36115
36116
36117   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36118 /* end confdefs.h.  */
36119 #include <sys/uio.h>
36120 _ACEOF
36121                 case "$host_os" in
36122     aix*) gl_absname_cpp="$ac_cpp -C" ;;
36123     *)    gl_absname_cpp="$ac_cpp" ;;
36124   esac
36125
36126   case "$host_os" in
36127     mingw*)
36128                                           gl_dirsep_regex='[/\\]'
36129       ;;
36130     *)
36131       gl_dirsep_regex='\/'
36132       ;;
36133   esac
36134       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
36135   gl_header_literal_regex=`echo 'sys/uio.h' \
36136                            | sed -e "$gl_make_literal_regex_sed"`
36137   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
36138       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
36139       s|^/[^/]|//&|
36140       p
36141       q
36142     }'
36143
36144         gl_cv_absolute_sys_uio_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
36145   sed -n "$gl_absolute_header_sed"`
36146
36147            gl_header=$gl_cv_absolute_sys_uio_h
36148            gl_cv_next_sys_uio_h='"'$gl_header'"'
36149           else
36150                gl_cv_next_sys_uio_h='<'sys/uio.h'>'
36151              fi
36152
36153
36154 fi
36155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_uio_h" >&5
36156 $as_echo "$gl_cv_next_sys_uio_h" >&6; }
36157      fi
36158      NEXT_SYS_UIO_H=$gl_cv_next_sys_uio_h
36159
36160      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
36161        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
36162        gl_next_as_first_directive='<'sys/uio.h'>'
36163      else
36164        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
36165        gl_next_as_first_directive=$gl_cv_next_sys_uio_h
36166      fi
36167      NEXT_AS_FIRST_DIRECTIVE_SYS_UIO_H=$gl_next_as_first_directive
36168
36169
36170
36171
36172   if test $ac_cv_header_sys_uio_h = yes; then
36173     HAVE_SYS_UIO_H=1
36174   else
36175     HAVE_SYS_UIO_H=0
36176   fi
36177
36178
36179
36180
36181
36182
36183
36184
36185
36186
36187
36188
36189   :
36190
36191
36192
36193
36194
36195
36196
36197
36198      if test $gl_cv_have_include_next = yes; then
36199        gl_cv_next_sys_utsname_h='<'sys/utsname.h'>'
36200      else
36201        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/utsname.h>" >&5
36202 $as_echo_n "checking absolute name of <sys/utsname.h>... " >&6; }
36203 if ${gl_cv_next_sys_utsname_h+:} false; then :
36204   $as_echo_n "(cached) " >&6
36205 else
36206
36207              if test $ac_cv_header_sys_utsname_h = yes; then
36208
36209
36210
36211
36212   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36213 /* end confdefs.h.  */
36214 #include <sys/utsname.h>
36215 _ACEOF
36216                 case "$host_os" in
36217     aix*) gl_absname_cpp="$ac_cpp -C" ;;
36218     *)    gl_absname_cpp="$ac_cpp" ;;
36219   esac
36220
36221   case "$host_os" in
36222     mingw*)
36223                                           gl_dirsep_regex='[/\\]'
36224       ;;
36225     *)
36226       gl_dirsep_regex='\/'
36227       ;;
36228   esac
36229       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
36230   gl_header_literal_regex=`echo 'sys/utsname.h' \
36231                            | sed -e "$gl_make_literal_regex_sed"`
36232   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
36233       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
36234       s|^/[^/]|//&|
36235       p
36236       q
36237     }'
36238
36239         gl_cv_absolute_sys_utsname_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
36240   sed -n "$gl_absolute_header_sed"`
36241
36242            gl_header=$gl_cv_absolute_sys_utsname_h
36243            gl_cv_next_sys_utsname_h='"'$gl_header'"'
36244           else
36245                gl_cv_next_sys_utsname_h='<'sys/utsname.h'>'
36246              fi
36247
36248
36249 fi
36250 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_utsname_h" >&5
36251 $as_echo "$gl_cv_next_sys_utsname_h" >&6; }
36252      fi
36253      NEXT_SYS_UTSNAME_H=$gl_cv_next_sys_utsname_h
36254
36255      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
36256        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
36257        gl_next_as_first_directive='<'sys/utsname.h'>'
36258      else
36259        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
36260        gl_next_as_first_directive=$gl_cv_next_sys_utsname_h
36261      fi
36262      NEXT_AS_FIRST_DIRECTIVE_SYS_UTSNAME_H=$gl_next_as_first_directive
36263
36264
36265
36266
36267   if test $ac_cv_header_sys_utsname_h != yes; then
36268     HAVE_SYS_UTSNAME_H=0
36269     HAVE_STRUCT_UTSNAME=0
36270   else
36271     HAVE_SYS_UTSNAME_H=1
36272     ac_fn_c_check_type "$LINENO" "struct utsname" "ac_cv_type_struct_utsname" "
36273 /* Minix 3.1.8 has a bug: <stddef.h> must be included before
36274    <sys/utsname.h>.  */
36275 #include <stddef.h>
36276 #include <sys/utsname.h>
36277
36278 "
36279 if test "x$ac_cv_type_struct_utsname" = xyes; then :
36280
36281 cat >>confdefs.h <<_ACEOF
36282 #define HAVE_STRUCT_UTSNAME 1
36283 _ACEOF
36284
36285
36286 else
36287   HAVE_STRUCT_UTSNAME=0
36288 fi
36289
36290   fi
36291
36292
36293
36294
36295
36296
36297
36298
36299
36300
36301
36302
36303
36304
36305   :
36306
36307
36308
36309
36310
36311
36312
36313
36314      if test $gl_cv_have_include_next = yes; then
36315        gl_cv_next_sys_wait_h='<'sys/wait.h'>'
36316      else
36317        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/wait.h>" >&5
36318 $as_echo_n "checking absolute name of <sys/wait.h>... " >&6; }
36319 if ${gl_cv_next_sys_wait_h+:} false; then :
36320   $as_echo_n "(cached) " >&6
36321 else
36322
36323              if test $ac_cv_header_sys_wait_h = yes; then
36324
36325
36326
36327
36328   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36329 /* end confdefs.h.  */
36330 #include <sys/wait.h>
36331 _ACEOF
36332                 case "$host_os" in
36333     aix*) gl_absname_cpp="$ac_cpp -C" ;;
36334     *)    gl_absname_cpp="$ac_cpp" ;;
36335   esac
36336
36337   case "$host_os" in
36338     mingw*)
36339                                           gl_dirsep_regex='[/\\]'
36340       ;;
36341     *)
36342       gl_dirsep_regex='\/'
36343       ;;
36344   esac
36345       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
36346   gl_header_literal_regex=`echo 'sys/wait.h' \
36347                            | sed -e "$gl_make_literal_regex_sed"`
36348   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
36349       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
36350       s|^/[^/]|//&|
36351       p
36352       q
36353     }'
36354
36355         gl_cv_absolute_sys_wait_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
36356   sed -n "$gl_absolute_header_sed"`
36357
36358            gl_header=$gl_cv_absolute_sys_wait_h
36359            gl_cv_next_sys_wait_h='"'$gl_header'"'
36360           else
36361                gl_cv_next_sys_wait_h='<'sys/wait.h'>'
36362              fi
36363
36364
36365 fi
36366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_wait_h" >&5
36367 $as_echo "$gl_cv_next_sys_wait_h" >&6; }
36368      fi
36369      NEXT_SYS_WAIT_H=$gl_cv_next_sys_wait_h
36370
36371      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
36372        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
36373        gl_next_as_first_directive='<'sys/wait.h'>'
36374      else
36375        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
36376        gl_next_as_first_directive=$gl_cv_next_sys_wait_h
36377      fi
36378      NEXT_AS_FIRST_DIRECTIVE_SYS_WAIT_H=$gl_next_as_first_directive
36379
36380
36381
36382
36383
36384
36385
36386
36387
36388
36389
36390
36391   :
36392
36393
36394
36395
36396
36397
36398
36399
36400
36401
36402
36403   :
36404
36405
36406
36407
36408
36409
36410
36411
36412      if test $gl_cv_have_include_next = yes; then
36413        gl_cv_next_termios_h='<'termios.h'>'
36414      else
36415        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <termios.h>" >&5
36416 $as_echo_n "checking absolute name of <termios.h>... " >&6; }
36417 if ${gl_cv_next_termios_h+:} false; then :
36418   $as_echo_n "(cached) " >&6
36419 else
36420
36421              if test $ac_cv_header_termios_h = yes; then
36422
36423
36424
36425
36426   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36427 /* end confdefs.h.  */
36428 #include <termios.h>
36429 _ACEOF
36430                 case "$host_os" in
36431     aix*) gl_absname_cpp="$ac_cpp -C" ;;
36432     *)    gl_absname_cpp="$ac_cpp" ;;
36433   esac
36434
36435   case "$host_os" in
36436     mingw*)
36437                                           gl_dirsep_regex='[/\\]'
36438       ;;
36439     *)
36440       gl_dirsep_regex='\/'
36441       ;;
36442   esac
36443       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
36444   gl_header_literal_regex=`echo 'termios.h' \
36445                            | sed -e "$gl_make_literal_regex_sed"`
36446   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
36447       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
36448       s|^/[^/]|//&|
36449       p
36450       q
36451     }'
36452
36453         gl_cv_absolute_termios_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
36454   sed -n "$gl_absolute_header_sed"`
36455
36456            gl_header=$gl_cv_absolute_termios_h
36457            gl_cv_next_termios_h='"'$gl_header'"'
36458           else
36459                gl_cv_next_termios_h='<'termios.h'>'
36460              fi
36461
36462
36463 fi
36464 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_termios_h" >&5
36465 $as_echo "$gl_cv_next_termios_h" >&6; }
36466      fi
36467      NEXT_TERMIOS_H=$gl_cv_next_termios_h
36468
36469      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
36470        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
36471        gl_next_as_first_directive='<'termios.h'>'
36472      else
36473        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
36474        gl_next_as_first_directive=$gl_cv_next_termios_h
36475      fi
36476      NEXT_AS_FIRST_DIRECTIVE_TERMIOS_H=$gl_next_as_first_directive
36477
36478
36479
36480
36481   if test $ac_cv_header_termios_h != yes; then
36482     HAVE_TERMIOS_H=0
36483   fi
36484
36485
36486
36487
36488
36489
36490
36491
36492
36493
36494
36495
36496
36497
36498
36499
36500
36501
36502       ac_fn_c_check_decl "$LINENO" "localtime_r" "ac_cv_have_decl_localtime_r" "#include <time.h>
36503 "
36504 if test "x$ac_cv_have_decl_localtime_r" = xyes; then :
36505   ac_have_decl=1
36506 else
36507   ac_have_decl=0
36508 fi
36509
36510 cat >>confdefs.h <<_ACEOF
36511 #define HAVE_DECL_LOCALTIME_R $ac_have_decl
36512 _ACEOF
36513
36514   if test $ac_cv_have_decl_localtime_r = no; then
36515     HAVE_DECL_LOCALTIME_R=0
36516   fi
36517
36518
36519   :
36520
36521
36522
36523
36524
36525   if test $ac_cv_func_localtime_r = yes; then
36526     HAVE_LOCALTIME_R=1
36527     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime_r is compatible with its POSIX signature" >&5
36528 $as_echo_n "checking whether localtime_r is compatible with its POSIX signature... " >&6; }
36529 if ${gl_cv_time_r_posix+:} false; then :
36530   $as_echo_n "(cached) " >&6
36531 else
36532   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36533 /* end confdefs.h.  */
36534 #include <time.h>
36535 int
36536 main ()
36537 {
36538 /* We don't need to append 'restrict's to the argument types,
36539                  even though the POSIX signature has the 'restrict's,
36540                  since C99 says they can't affect type compatibility.  */
36541               struct tm * (*ptr) (time_t const *, struct tm *) = localtime_r;
36542               if (ptr) return 0;
36543               /* Check the return type is a pointer.
36544                  On HP-UX 10 it is 'int'.  */
36545               *localtime_r (0, 0);
36546   ;
36547   return 0;
36548 }
36549
36550 _ACEOF
36551 if ac_fn_c_try_compile "$LINENO"; then :
36552   gl_cv_time_r_posix=yes
36553 else
36554   gl_cv_time_r_posix=no
36555 fi
36556 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
36557
36558 fi
36559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_time_r_posix" >&5
36560 $as_echo "$gl_cv_time_r_posix" >&6; }
36561     if test $gl_cv_time_r_posix = yes; then
36562       REPLACE_LOCALTIME_R=0
36563     else
36564       REPLACE_LOCALTIME_R=1
36565     fi
36566   else
36567     HAVE_LOCALTIME_R=0
36568   fi
36569
36570   if test $HAVE_LOCALTIME_R = 0 || test $REPLACE_LOCALTIME_R = 1; then
36571
36572
36573
36574
36575
36576
36577
36578
36579   gl_LIBOBJS="$gl_LIBOBJS time_r.$ac_objext"
36580
36581
36582   :
36583
36584   fi
36585
36586
36587
36588
36589
36590           GNULIB_TIME_R=1
36591
36592
36593
36594
36595
36596 $as_echo "#define GNULIB_TEST_TIME_R 1" >>confdefs.h
36597
36598
36599
36600
36601
36602
36603   REPLACE_TIMEGM=0
36604
36605   :
36606
36607
36608
36609
36610
36611   if test $ac_cv_func_timegm = yes; then
36612     if test $gl_cv_func_working_mktime = no; then
36613       # Assume that timegm is buggy if mktime is.
36614       REPLACE_TIMEGM=1
36615     fi
36616   else
36617     HAVE_TIMEGM=0
36618   fi
36619
36620   if test $HAVE_TIMEGM = 0 || test $REPLACE_TIMEGM = 1; then
36621
36622
36623
36624
36625
36626
36627
36628
36629   gl_LIBOBJS="$gl_LIBOBJS timegm.$ac_objext"
36630
36631
36632   :
36633
36634   fi
36635
36636
36637
36638
36639
36640           GNULIB_TIMEGM=1
36641
36642
36643
36644
36645
36646 $as_echo "#define GNULIB_TEST_TIMEGM 1" >>confdefs.h
36647
36648
36649
36650
36651
36652
36653
36654
36655
36656   :
36657
36658
36659
36660
36661
36662   if test $ac_cv_have_decl_ttyname_r = no; then
36663     HAVE_DECL_TTYNAME_R=0
36664   fi
36665
36666   for ac_func in ttyname_r
36667 do :
36668   ac_fn_c_check_func "$LINENO" "ttyname_r" "ac_cv_func_ttyname_r"
36669 if test "x$ac_cv_func_ttyname_r" = xyes; then :
36670   cat >>confdefs.h <<_ACEOF
36671 #define HAVE_TTYNAME_R 1
36672 _ACEOF
36673
36674 fi
36675 done
36676
36677   if test $ac_cv_func_ttyname_r = no; then
36678     HAVE_TTYNAME_R=0
36679   else
36680     HAVE_TTYNAME_R=1
36681             { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ttyname_r is compatible with its POSIX signature" >&5
36682 $as_echo_n "checking whether ttyname_r is compatible with its POSIX signature... " >&6; }
36683 if ${gl_cv_func_ttyname_r_posix+:} false; then :
36684   $as_echo_n "(cached) " >&6
36685 else
36686   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36687 /* end confdefs.h.  */
36688 #include <stddef.h>
36689               #include <unistd.h>
36690 int
36691 main ()
36692 {
36693 *ttyname_r (0, NULL, 0);
36694   ;
36695   return 0;
36696 }
36697
36698 _ACEOF
36699 if ac_fn_c_try_compile "$LINENO"; then :
36700   gl_cv_func_ttyname_r_posix=no
36701 else
36702   gl_cv_func_ttyname_r_posix=yes
36703 fi
36704 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
36705
36706 fi
36707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_ttyname_r_posix" >&5
36708 $as_echo "$gl_cv_func_ttyname_r_posix" >&6; }
36709     if test $gl_cv_func_ttyname_r_posix = no; then
36710       REPLACE_TTYNAME_R=1
36711     else
36712
36713 $as_echo "#define HAVE_POSIXDECL_TTYNAME_R 1" >>confdefs.h
36714
36715
36716       { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ttyname_r works with small buffers" >&5
36717 $as_echo_n "checking whether ttyname_r works with small buffers... " >&6; }
36718 if ${gl_cv_func_ttyname_r_works+:} false; then :
36719   $as_echo_n "(cached) " >&6
36720 else
36721
36722                               case "$host_os" in
36723                       # Guess no on Solaris.
36724             solaris*) gl_cv_func_ttyname_r_works="guessing no" ;;
36725                       # Guess no on OSF/1.
36726             osf*)     gl_cv_func_ttyname_r_works="guessing no" ;;
36727                       # Guess yes otherwise.
36728             *)        gl_cv_func_ttyname_r_works="guessing yes" ;;
36729           esac
36730           if test "$cross_compiling" = yes; then :
36731   :
36732 else
36733   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36734 /* end confdefs.h.  */
36735
36736 #include <fcntl.h>
36737 #include <unistd.h>
36738 int
36739 main (void)
36740 {
36741   int result = 0;
36742   int fd;
36743   char buf[31]; /* use any size < 128 here */
36744
36745   fd = open ("/dev/tty", O_RDONLY);
36746   if (fd < 0)
36747     result |= 16;
36748   else if (ttyname_r (fd, buf, sizeof (buf)) != 0)
36749     result |= 17;
36750   else if (ttyname_r (fd, buf, 1) == 0)
36751     result |= 18;
36752   return result;
36753 }
36754 _ACEOF
36755 if ac_fn_c_try_run "$LINENO"; then :
36756   gl_cv_func_ttyname_r_works=yes
36757 else
36758   case $? in
36759                17 | 18) gl_cv_func_ttyname_r_works=no ;;
36760              esac
36761 fi
36762 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
36763   conftest.$ac_objext conftest.beam conftest.$ac_ext
36764 fi
36765
36766
36767 fi
36768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_ttyname_r_works" >&5
36769 $as_echo "$gl_cv_func_ttyname_r_works" >&6; }
36770       case "$gl_cv_func_ttyname_r_works" in
36771         *yes) ;;
36772         *) REPLACE_TTYNAME_R=1 ;;
36773       esac
36774     fi
36775   fi
36776
36777   if test $HAVE_TTYNAME_R = 0 || test $REPLACE_TTYNAME_R = 1; then
36778
36779
36780
36781
36782
36783
36784
36785
36786   gl_LIBOBJS="$gl_LIBOBJS ttyname_r.$ac_objext"
36787
36788
36789   for ac_func in ttyname
36790 do :
36791   ac_fn_c_check_func "$LINENO" "ttyname" "ac_cv_func_ttyname"
36792 if test "x$ac_cv_func_ttyname" = xyes; then :
36793   cat >>confdefs.h <<_ACEOF
36794 #define HAVE_TTYNAME 1
36795 _ACEOF
36796
36797 fi
36798 done
36799
36800
36801   fi
36802
36803
36804
36805
36806
36807           GNULIB_TTYNAME_R=1
36808
36809
36810
36811
36812
36813 $as_echo "#define GNULIB_TEST_TTYNAME_R 1" >>confdefs.h
36814
36815
36816
36817
36818
36819   for ac_func in uname
36820 do :
36821   ac_fn_c_check_func "$LINENO" "uname" "ac_cv_func_uname"
36822 if test "x$ac_cv_func_uname" = xyes; then :
36823   cat >>confdefs.h <<_ACEOF
36824 #define HAVE_UNAME 1
36825 _ACEOF
36826
36827 fi
36828 done
36829
36830   if test $ac_cv_func_uname = no; then
36831     HAVE_UNAME=0
36832   fi
36833
36834   if test $HAVE_UNAME = 0; then
36835
36836
36837
36838
36839
36840
36841
36842
36843   gl_LIBOBJS="$gl_LIBOBJS uname.$ac_objext"
36844
36845
36846   :
36847
36848   fi
36849
36850
36851
36852
36853
36854           GNULIB_UNAME=1
36855
36856
36857
36858
36859
36860
36861
36862
36863
36864
36865
36866
36867
36868   :
36869
36870
36871
36872
36873
36874
36875
36876
36877      if test $gl_cv_have_include_next = yes; then
36878        gl_cv_next_unistd_h='<'unistd.h'>'
36879      else
36880        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <unistd.h>" >&5
36881 $as_echo_n "checking absolute name of <unistd.h>... " >&6; }
36882 if ${gl_cv_next_unistd_h+:} false; then :
36883   $as_echo_n "(cached) " >&6
36884 else
36885
36886              if test $ac_cv_header_unistd_h = yes; then
36887
36888
36889
36890
36891   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36892 /* end confdefs.h.  */
36893 #include <unistd.h>
36894 _ACEOF
36895                 case "$host_os" in
36896     aix*) gl_absname_cpp="$ac_cpp -C" ;;
36897     *)    gl_absname_cpp="$ac_cpp" ;;
36898   esac
36899
36900   case "$host_os" in
36901     mingw*)
36902                                           gl_dirsep_regex='[/\\]'
36903       ;;
36904     *)
36905       gl_dirsep_regex='\/'
36906       ;;
36907   esac
36908       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
36909   gl_header_literal_regex=`echo 'unistd.h' \
36910                            | sed -e "$gl_make_literal_regex_sed"`
36911   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
36912       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
36913       s|^/[^/]|//&|
36914       p
36915       q
36916     }'
36917
36918         gl_cv_absolute_unistd_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
36919   sed -n "$gl_absolute_header_sed"`
36920
36921            gl_header=$gl_cv_absolute_unistd_h
36922            gl_cv_next_unistd_h='"'$gl_header'"'
36923           else
36924                gl_cv_next_unistd_h='<'unistd.h'>'
36925              fi
36926
36927
36928 fi
36929 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_unistd_h" >&5
36930 $as_echo "$gl_cv_next_unistd_h" >&6; }
36931      fi
36932      NEXT_UNISTD_H=$gl_cv_next_unistd_h
36933
36934      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
36935        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
36936        gl_next_as_first_directive='<'unistd.h'>'
36937      else
36938        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
36939        gl_next_as_first_directive=$gl_cv_next_unistd_h
36940      fi
36941      NEXT_AS_FIRST_DIRECTIVE_UNISTD_H=$gl_next_as_first_directive
36942
36943
36944
36945
36946   if test $ac_cv_header_unistd_h = yes; then
36947     HAVE_UNISTD_H=1
36948   else
36949     HAVE_UNISTD_H=0
36950   fi
36951
36952
36953
36954
36955
36956
36957
36958
36959
36960
36961
36962
36963   :
36964
36965
36966
36967
36968
36969   ac_fn_c_check_type "$LINENO" "useconds_t" "ac_cv_type_useconds_t" "$ac_includes_default"
36970 if test "x$ac_cv_type_useconds_t" = xyes; then :
36971
36972 else
36973
36974 $as_echo "#define useconds_t unsigned int" >>confdefs.h
36975
36976 fi
36977
36978   if test $ac_cv_func_usleep = no; then
36979     HAVE_USLEEP=0
36980   else
36981             { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether usleep allows large arguments" >&5
36982 $as_echo_n "checking whether usleep allows large arguments... " >&6; }
36983 if ${gl_cv_func_usleep_works+:} false; then :
36984   $as_echo_n "(cached) " >&6
36985 else
36986   if test "$cross_compiling" = yes; then :
36987   case "$host_os" in
36988                    # Guess yes on glibc systems.
36989            *-gnu*) gl_cv_func_usleep_works="guessing yes" ;;
36990                    # If we don't know, assume the worst.
36991            *)      gl_cv_func_usleep_works="guessing no" ;;
36992          esac
36993
36994 else
36995   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
36996 /* end confdefs.h.  */
36997
36998 #include <unistd.h>
36999
37000 int
37001 main ()
37002 {
37003 return !!usleep (1000000);
37004   ;
37005   return 0;
37006 }
37007 _ACEOF
37008 if ac_fn_c_try_run "$LINENO"; then :
37009   gl_cv_func_usleep_works=yes
37010 else
37011   gl_cv_func_usleep_works=no
37012 fi
37013 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
37014   conftest.$ac_objext conftest.beam conftest.$ac_ext
37015 fi
37016
37017 fi
37018 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_usleep_works" >&5
37019 $as_echo "$gl_cv_func_usleep_works" >&6; }
37020     case "$gl_cv_func_usleep_works" in
37021       *yes) ;;
37022       *)
37023         REPLACE_USLEEP=1
37024         ;;
37025     esac
37026   fi
37027
37028   if test $HAVE_USLEEP = 0 || test $REPLACE_USLEEP = 1; then
37029
37030
37031
37032
37033
37034
37035
37036
37037   gl_LIBOBJS="$gl_LIBOBJS usleep.$ac_objext"
37038
37039   fi
37040
37041
37042
37043
37044
37045           GNULIB_USLEEP=1
37046
37047
37048
37049
37050
37051 $as_echo "#define GNULIB_TEST_USLEEP 1" >>confdefs.h
37052
37053
37054
37055
37056
37057   :
37058
37059
37060
37061
37062
37063   if test $ac_cv_func_vasnprintf = no; then
37064
37065
37066   :
37067
37068
37069
37070
37071
37072
37073
37074
37075
37076
37077
37078
37079
37080   gl_LIBOBJS="$gl_LIBOBJS vasnprintf.$ac_objext"
37081
37082
37083
37084
37085
37086
37087
37088
37089
37090   gl_LIBOBJS="$gl_LIBOBJS printf-args.$ac_objext"
37091
37092
37093
37094
37095
37096
37097
37098
37099
37100   gl_LIBOBJS="$gl_LIBOBJS printf-parse.$ac_objext"
37101
37102
37103
37104
37105
37106
37107
37108
37109
37110   gl_LIBOBJS="$gl_LIBOBJS asnprintf.$ac_objext"
37111
37112   if test $ac_cv_func_vasnprintf = yes; then
37113
37114 $as_echo "#define REPLACE_VASNPRINTF 1" >>confdefs.h
37115
37116   fi
37117
37118
37119
37120
37121
37122
37123
37124
37125
37126
37127
37128   ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default"
37129 if test "x$ac_cv_type_ptrdiff_t" = xyes; then :
37130
37131 else
37132
37133 $as_echo "#define ptrdiff_t long" >>confdefs.h
37134
37135
37136 fi
37137
37138
37139
37140
37141
37142
37143
37144   fi
37145
37146
37147   for ac_func in vasprintf
37148 do :
37149   ac_fn_c_check_func "$LINENO" "vasprintf" "ac_cv_func_vasprintf"
37150 if test "x$ac_cv_func_vasprintf" = xyes; then :
37151   cat >>confdefs.h <<_ACEOF
37152 #define HAVE_VASPRINTF 1
37153 _ACEOF
37154
37155 fi
37156 done
37157
37158   if test $ac_cv_func_vasprintf = no; then
37159
37160
37161
37162
37163
37164
37165
37166
37167
37168   gl_LIBOBJS="$gl_LIBOBJS vasprintf.$ac_objext"
37169
37170
37171
37172
37173
37174
37175
37176
37177
37178   gl_LIBOBJS="$gl_LIBOBJS asprintf.$ac_objext"
37179
37180
37181   if test $ac_cv_func_vasprintf = yes; then
37182     REPLACE_VASPRINTF=1
37183   else
37184     HAVE_VASPRINTF=0
37185   fi
37186
37187
37188
37189
37190
37191
37192
37193
37194   fi
37195
37196
37197
37198
37199
37200
37201           GNULIB_VASPRINTF=1
37202
37203
37204
37205
37206
37207 $as_echo "#define GNULIB_TEST_VASPRINTF 1" >>confdefs.h
37208
37209
37210
37211
37212
37213   XGETTEXT_EXTRA_OPTIONS="$XGETTEXT_EXTRA_OPTIONS --flag=asprintf:2:c-format"
37214
37215
37216
37217   XGETTEXT_EXTRA_OPTIONS="$XGETTEXT_EXTRA_OPTIONS --flag=vasprintf:2:c-format"
37218
37219
37220
37221   gl_cv_func_vsnprintf_usable=no
37222   for ac_func in vsnprintf
37223 do :
37224   ac_fn_c_check_func "$LINENO" "vsnprintf" "ac_cv_func_vsnprintf"
37225 if test "x$ac_cv_func_vsnprintf" = xyes; then :
37226   cat >>confdefs.h <<_ACEOF
37227 #define HAVE_VSNPRINTF 1
37228 _ACEOF
37229
37230 fi
37231 done
37232
37233   if test $ac_cv_func_vsnprintf = yes; then
37234
37235
37236
37237   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether snprintf respects a size of 1" >&5
37238 $as_echo_n "checking whether snprintf respects a size of 1... " >&6; }
37239 if ${gl_cv_func_snprintf_size1+:} false; then :
37240   $as_echo_n "(cached) " >&6
37241 else
37242
37243       if test "$cross_compiling" = yes; then :
37244   gl_cv_func_snprintf_size1="guessing yes"
37245 else
37246   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37247 /* end confdefs.h.  */
37248
37249 #include <stdio.h>
37250 #if HAVE_SNPRINTF
37251 # define my_snprintf snprintf
37252 #else
37253 # include <stdarg.h>
37254 static int my_snprintf (char *buf, int size, const char *format, ...)
37255 {
37256   va_list args;
37257   int ret;
37258   va_start (args, format);
37259   ret = vsnprintf (buf, size, format, args);
37260   va_end (args);
37261   return ret;
37262 }
37263 #endif
37264 int main()
37265 {
37266   static char buf[8] = { 'D', 'E', 'A', 'D', 'B', 'E', 'E', 'F' };
37267   my_snprintf (buf, 1, "%d", 12345);
37268   return buf[1] != 'E';
37269 }
37270 _ACEOF
37271 if ac_fn_c_try_run "$LINENO"; then :
37272   gl_cv_func_snprintf_size1=yes
37273 else
37274   gl_cv_func_snprintf_size1=no
37275 fi
37276 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
37277   conftest.$ac_objext conftest.beam conftest.$ac_ext
37278 fi
37279
37280
37281 fi
37282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_snprintf_size1" >&5
37283 $as_echo "$gl_cv_func_snprintf_size1" >&6; }
37284
37285     case "$gl_cv_func_snprintf_size1" in
37286       *yes)
37287
37288         case "$gl_cv_func_snprintf_retval_c99" in
37289           *yes)
37290
37291
37292      { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether printf supports POSIX/XSI format strings with positions" >&5
37293 $as_echo_n "checking whether printf supports POSIX/XSI format strings with positions... " >&6; }
37294 if ${gl_cv_func_printf_positions+:} false; then :
37295   $as_echo_n "(cached) " >&6
37296 else
37297
37298       if test "$cross_compiling" = yes; then :
37299
37300          case "$host_os" in
37301            netbsd[1-3]* | netbsdelf[1-3]* | netbsdaout[1-3]* | netbsdcoff[1-3]*)
37302                          gl_cv_func_printf_positions="guessing no";;
37303            beos*)        gl_cv_func_printf_positions="guessing no";;
37304            mingw* | pw*) gl_cv_func_printf_positions="guessing no";;
37305            *)            gl_cv_func_printf_positions="guessing yes";;
37306          esac
37307
37308 else
37309   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37310 /* end confdefs.h.  */
37311
37312 #include <stdio.h>
37313 #include <string.h>
37314 /* The string "%2$d %1$d", with dollar characters protected from the shell's
37315    dollar expansion (possibly an autoconf bug).  */
37316 static char format[] = { '%', '2', '$', 'd', ' ', '%', '1', '$', 'd', '\0' };
37317 static char buf[100];
37318 int main ()
37319 {
37320   sprintf (buf, format, 33, 55);
37321   return (strcmp (buf, "55 33") != 0);
37322 }
37323 _ACEOF
37324 if ac_fn_c_try_run "$LINENO"; then :
37325   gl_cv_func_printf_positions=yes
37326 else
37327   gl_cv_func_printf_positions=no
37328 fi
37329 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
37330   conftest.$ac_objext conftest.beam conftest.$ac_ext
37331 fi
37332
37333
37334 fi
37335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_printf_positions" >&5
37336 $as_echo "$gl_cv_func_printf_positions" >&6; }
37337
37338             case "$gl_cv_func_printf_positions" in
37339               *yes)
37340                 gl_cv_func_vsnprintf_usable=yes
37341                 ;;
37342             esac
37343             ;;
37344         esac
37345         ;;
37346     esac
37347   fi
37348   if test $gl_cv_func_vsnprintf_usable = no; then
37349
37350
37351
37352
37353
37354
37355
37356
37357
37358
37359   gl_LIBOBJS="$gl_LIBOBJS vsnprintf.$ac_objext"
37360
37361   if test $ac_cv_func_vsnprintf = yes; then
37362     REPLACE_VSNPRINTF=1
37363   fi
37364   :
37365
37366   fi
37367
37368   :
37369
37370
37371
37372
37373
37374   if test $ac_cv_have_decl_vsnprintf = no; then
37375     HAVE_DECL_VSNPRINTF=0
37376   fi
37377
37378
37379
37380
37381
37382
37383           GNULIB_VSNPRINTF=1
37384
37385
37386
37387
37388
37389 $as_echo "#define GNULIB_TEST_VSNPRINTF 1" >>confdefs.h
37390
37391
37392
37393
37394
37395   HAVE_WAITPID=1
37396   case $host_os in
37397     mingw*) HAVE_WAITPID=0 ;;
37398   esac
37399
37400   if test $HAVE_WAITPID = 0; then
37401
37402
37403
37404
37405
37406
37407
37408
37409   gl_LIBOBJS="$gl_LIBOBJS waitpid.$ac_objext"
37410
37411   fi
37412
37413
37414
37415
37416
37417           GNULIB_WAITPID=1
37418
37419
37420
37421
37422
37423 $as_echo "#define GNULIB_TEST_WAITPID 1" >>confdefs.h
37424
37425
37426
37427
37428
37429
37430
37431
37432
37433
37434
37435
37436   :
37437
37438
37439
37440
37441
37442
37443
37444
37445      if test $gl_cv_have_include_next = yes; then
37446        gl_cv_next_wchar_h='<'wchar.h'>'
37447      else
37448        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <wchar.h>" >&5
37449 $as_echo_n "checking absolute name of <wchar.h>... " >&6; }
37450 if ${gl_cv_next_wchar_h+:} false; then :
37451   $as_echo_n "(cached) " >&6
37452 else
37453
37454              if test $ac_cv_header_wchar_h = yes; then
37455
37456
37457
37458
37459   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37460 /* end confdefs.h.  */
37461 #include <wchar.h>
37462 _ACEOF
37463                 case "$host_os" in
37464     aix*) gl_absname_cpp="$ac_cpp -C" ;;
37465     *)    gl_absname_cpp="$ac_cpp" ;;
37466   esac
37467
37468   case "$host_os" in
37469     mingw*)
37470                                           gl_dirsep_regex='[/\\]'
37471       ;;
37472     *)
37473       gl_dirsep_regex='\/'
37474       ;;
37475   esac
37476       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
37477   gl_header_literal_regex=`echo 'wchar.h' \
37478                            | sed -e "$gl_make_literal_regex_sed"`
37479   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
37480       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
37481       s|^/[^/]|//&|
37482       p
37483       q
37484     }'
37485
37486         gl_cv_absolute_wchar_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
37487   sed -n "$gl_absolute_header_sed"`
37488
37489            gl_header=$gl_cv_absolute_wchar_h
37490            gl_cv_next_wchar_h='"'$gl_header'"'
37491           else
37492                gl_cv_next_wchar_h='<'wchar.h'>'
37493              fi
37494
37495
37496 fi
37497 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_wchar_h" >&5
37498 $as_echo "$gl_cv_next_wchar_h" >&6; }
37499      fi
37500      NEXT_WCHAR_H=$gl_cv_next_wchar_h
37501
37502      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
37503        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
37504        gl_next_as_first_directive='<'wchar.h'>'
37505      else
37506        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
37507        gl_next_as_first_directive=$gl_cv_next_wchar_h
37508      fi
37509      NEXT_AS_FIRST_DIRECTIVE_WCHAR_H=$gl_next_as_first_directive
37510
37511
37512
37513
37514   if test $ac_cv_header_wchar_h = yes; then
37515     HAVE_WCHAR_H=1
37516   else
37517     HAVE_WCHAR_H=0
37518   fi
37519
37520
37521
37522
37523
37524   if test $gt_cv_c_wint_t = yes; then
37525     HAVE_WINT_T=1
37526   else
37527     HAVE_WINT_T=0
37528   fi
37529
37530
37531
37532
37533
37534
37535
37536
37537
37538
37539
37540
37541
37542   :
37543
37544
37545
37546
37547
37548
37549   :
37550
37551
37552
37553
37554
37555   if test $ac_cv_func_mbsinit = yes && test $ac_cv_func_mbrtowc = yes; then
37556
37557
37558
37559      { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc handles incomplete characters" >&5
37560 $as_echo_n "checking whether mbrtowc handles incomplete characters... " >&6; }
37561 if ${gl_cv_func_mbrtowc_incomplete_state+:} false; then :
37562   $as_echo_n "(cached) " >&6
37563 else
37564
37565                   case "$host_os" in
37566                      # Guess no on AIX and OSF/1.
37567         aix* | osf*) gl_cv_func_mbrtowc_incomplete_state="guessing no" ;;
37568                      # Guess yes otherwise.
37569         *)           gl_cv_func_mbrtowc_incomplete_state="guessing yes" ;;
37570       esac
37571       if test $LOCALE_JA != none; then
37572         if test "$cross_compiling" = yes; then :
37573   :
37574 else
37575   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37576 /* end confdefs.h.  */
37577
37578 #include <locale.h>
37579 #include <string.h>
37580 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
37581    <wchar.h>.
37582    BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
37583    included before <wchar.h>.  */
37584 #include <stddef.h>
37585 #include <stdio.h>
37586 #include <time.h>
37587 #include <wchar.h>
37588 int main ()
37589 {
37590   if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
37591     {
37592       const char input[] = "B\217\253\344\217\251\316er"; /* "Büßer" */
37593       mbstate_t state;
37594       wchar_t wc;
37595
37596       memset (&state, '\0', sizeof (mbstate_t));
37597       if (mbrtowc (&wc, input + 1, 1, &state) == (size_t)(-2))
37598         if (mbsinit (&state))
37599           return 1;
37600     }
37601   return 0;
37602 }
37603 _ACEOF
37604 if ac_fn_c_try_run "$LINENO"; then :
37605   gl_cv_func_mbrtowc_incomplete_state=yes
37606 else
37607   gl_cv_func_mbrtowc_incomplete_state=no
37608 fi
37609 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
37610   conftest.$ac_objext conftest.beam conftest.$ac_ext
37611 fi
37612
37613       fi
37614
37615 fi
37616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_incomplete_state" >&5
37617 $as_echo "$gl_cv_func_mbrtowc_incomplete_state" >&6; }
37618
37619
37620
37621
37622      { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc works as well as mbtowc" >&5
37623 $as_echo_n "checking whether mbrtowc works as well as mbtowc... " >&6; }
37624 if ${gl_cv_func_mbrtowc_sanitycheck+:} false; then :
37625   $as_echo_n "(cached) " >&6
37626 else
37627
37628                   case "$host_os" in
37629                     # Guess no on Solaris 8.
37630         solaris2.8) gl_cv_func_mbrtowc_sanitycheck="guessing no" ;;
37631                     # Guess yes otherwise.
37632         *)          gl_cv_func_mbrtowc_sanitycheck="guessing yes" ;;
37633       esac
37634       if test $LOCALE_ZH_CN != none; then
37635         if test "$cross_compiling" = yes; then :
37636   :
37637 else
37638   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37639 /* end confdefs.h.  */
37640
37641 #include <locale.h>
37642 #include <stdlib.h>
37643 #include <string.h>
37644 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
37645    <wchar.h>.
37646    BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
37647    included before <wchar.h>.  */
37648 #include <stddef.h>
37649 #include <stdio.h>
37650 #include <time.h>
37651 #include <wchar.h>
37652 int main ()
37653 {
37654   /* This fails on Solaris 8:
37655      mbrtowc returns 2, and sets wc to 0x00F0.
37656      mbtowc returns 4 (correct) and sets wc to 0x5EDC.  */
37657   if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
37658     {
37659       char input[] = "B\250\271\201\060\211\070er"; /* "Büßer" */
37660       mbstate_t state;
37661       wchar_t wc;
37662
37663       memset (&state, '\0', sizeof (mbstate_t));
37664       if (mbrtowc (&wc, input + 3, 6, &state) != 4
37665           && mbtowc (&wc, input + 3, 6) == 4)
37666         return 1;
37667     }
37668   return 0;
37669 }
37670 _ACEOF
37671 if ac_fn_c_try_run "$LINENO"; then :
37672   gl_cv_func_mbrtowc_sanitycheck=yes
37673 else
37674   gl_cv_func_mbrtowc_sanitycheck=no
37675 fi
37676 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
37677   conftest.$ac_objext conftest.beam conftest.$ac_ext
37678 fi
37679
37680       fi
37681
37682 fi
37683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_mbrtowc_sanitycheck" >&5
37684 $as_echo "$gl_cv_func_mbrtowc_sanitycheck" >&6; }
37685
37686     REPLACE_MBSTATE_T=0
37687     case "$gl_cv_func_mbrtowc_incomplete_state" in
37688       *yes) ;;
37689       *) REPLACE_MBSTATE_T=1 ;;
37690     esac
37691     case "$gl_cv_func_mbrtowc_sanitycheck" in
37692       *yes) ;;
37693       *) REPLACE_MBSTATE_T=1 ;;
37694     esac
37695   else
37696     REPLACE_MBSTATE_T=1
37697   fi
37698
37699
37700
37701   :
37702
37703
37704
37705
37706
37707   if test $ac_cv_func_wcrtomb = no; then
37708     HAVE_WCRTOMB=0
37709     ac_fn_c_check_decl "$LINENO" "wcrtomb" "ac_cv_have_decl_wcrtomb" "
37710 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
37711    <wchar.h>.
37712    BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
37713    included before <wchar.h>.  */
37714 #include <stddef.h>
37715 #include <stdio.h>
37716 #include <time.h>
37717 #include <wchar.h>
37718
37719 "
37720 if test "x$ac_cv_have_decl_wcrtomb" = xyes; then :
37721   ac_have_decl=1
37722 else
37723   ac_have_decl=0
37724 fi
37725
37726 cat >>confdefs.h <<_ACEOF
37727 #define HAVE_DECL_WCRTOMB $ac_have_decl
37728 _ACEOF
37729
37730     if test $ac_cv_have_decl_wcrtomb = yes; then
37731                         REPLACE_WCRTOMB=1
37732     fi
37733   else
37734     if test $REPLACE_MBSTATE_T = 1; then
37735       REPLACE_WCRTOMB=1
37736     else
37737
37738
37739
37740
37741
37742              { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether wcrtomb return value is correct" >&5
37743 $as_echo_n "checking whether wcrtomb return value is correct... " >&6; }
37744 if ${gl_cv_func_wcrtomb_retval+:} false; then :
37745   $as_echo_n "(cached) " >&6
37746 else
37747
37748                               case "$host_os" in
37749                                      # Guess no on AIX 4, OSF/1 and Solaris.
37750             aix4* | osf* | solaris*) gl_cv_func_wcrtomb_retval="guessing no" ;;
37751                                      # Guess yes otherwise.
37752             *)                       gl_cv_func_wcrtomb_retval="guessing yes" ;;
37753           esac
37754           if test $LOCALE_FR != none || test $LOCALE_FR_UTF8 != none || test $LOCALE_JA != none || test $LOCALE_ZH_CN != none; then
37755             if test "$cross_compiling" = yes; then :
37756   :
37757 else
37758   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37759 /* end confdefs.h.  */
37760
37761 #include <locale.h>
37762 #include <string.h>
37763 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
37764    <wchar.h>.
37765    BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
37766    included before <wchar.h>.  */
37767 #include <stddef.h>
37768 #include <stdio.h>
37769 #include <time.h>
37770 #include <wchar.h>
37771 int main ()
37772 {
37773   int result = 0;
37774   if (setlocale (LC_ALL, "$LOCALE_FR") != NULL)
37775     {
37776       if (wcrtomb (NULL, 0, NULL) != 1)
37777         result |= 1;
37778     }
37779   if (setlocale (LC_ALL, "$LOCALE_FR_UTF8") != NULL)
37780     {
37781       if (wcrtomb (NULL, 0, NULL) != 1)
37782         result |= 2;
37783     }
37784   if (setlocale (LC_ALL, "$LOCALE_JA") != NULL)
37785     {
37786       if (wcrtomb (NULL, 0, NULL) != 1)
37787         result |= 4;
37788     }
37789   if (setlocale (LC_ALL, "$LOCALE_ZH_CN") != NULL)
37790     {
37791       if (wcrtomb (NULL, 0, NULL) != 1)
37792         result |= 8;
37793     }
37794   return result;
37795 }
37796 _ACEOF
37797 if ac_fn_c_try_run "$LINENO"; then :
37798   gl_cv_func_wcrtomb_retval=yes
37799 else
37800   gl_cv_func_wcrtomb_retval=no
37801 fi
37802 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
37803   conftest.$ac_objext conftest.beam conftest.$ac_ext
37804 fi
37805
37806           fi
37807
37808 fi
37809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_wcrtomb_retval" >&5
37810 $as_echo "$gl_cv_func_wcrtomb_retval" >&6; }
37811       case "$gl_cv_func_wcrtomb_retval" in
37812         *yes) ;;
37813         *) REPLACE_WCRTOMB=1 ;;
37814       esac
37815     fi
37816   fi
37817
37818   if test $HAVE_WCRTOMB = 0 || test $REPLACE_WCRTOMB = 1; then
37819
37820
37821
37822
37823
37824
37825
37826
37827   gl_LIBOBJS="$gl_LIBOBJS wcrtomb.$ac_objext"
37828
37829
37830   :
37831
37832   fi
37833
37834
37835
37836
37837
37838           GNULIB_WCRTOMB=1
37839
37840
37841
37842
37843
37844 $as_echo "#define GNULIB_TEST_WCRTOMB 1" >>confdefs.h
37845
37846
37847
37848
37849
37850
37851
37852
37853   :
37854
37855
37856
37857
37858
37859   if test $ac_cv_func_iswcntrl = yes; then
37860     HAVE_ISWCNTRL=1
37861   else
37862     HAVE_ISWCNTRL=0
37863   fi
37864
37865
37866
37867   if test $gt_cv_c_wint_t = yes; then
37868     HAVE_WINT_T=1
37869   else
37870     HAVE_WINT_T=0
37871   fi
37872
37873
37874
37875
37876
37877
37878
37879
37880   :
37881
37882
37883
37884
37885
37886
37887
37888
37889      if test $gl_cv_have_include_next = yes; then
37890        gl_cv_next_wctype_h='<'wctype.h'>'
37891      else
37892        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <wctype.h>" >&5
37893 $as_echo_n "checking absolute name of <wctype.h>... " >&6; }
37894 if ${gl_cv_next_wctype_h+:} false; then :
37895   $as_echo_n "(cached) " >&6
37896 else
37897
37898              if test $ac_cv_header_wctype_h = yes; then
37899
37900
37901
37902
37903   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37904 /* end confdefs.h.  */
37905 #include <wctype.h>
37906 _ACEOF
37907                 case "$host_os" in
37908     aix*) gl_absname_cpp="$ac_cpp -C" ;;
37909     *)    gl_absname_cpp="$ac_cpp" ;;
37910   esac
37911
37912   case "$host_os" in
37913     mingw*)
37914                                           gl_dirsep_regex='[/\\]'
37915       ;;
37916     *)
37917       gl_dirsep_regex='\/'
37918       ;;
37919   esac
37920       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
37921   gl_header_literal_regex=`echo 'wctype.h' \
37922                            | sed -e "$gl_make_literal_regex_sed"`
37923   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
37924       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
37925       s|^/[^/]|//&|
37926       p
37927       q
37928     }'
37929
37930         gl_cv_absolute_wctype_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
37931   sed -n "$gl_absolute_header_sed"`
37932
37933            gl_header=$gl_cv_absolute_wctype_h
37934            gl_cv_next_wctype_h='"'$gl_header'"'
37935           else
37936                gl_cv_next_wctype_h='<'wctype.h'>'
37937              fi
37938
37939
37940 fi
37941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_wctype_h" >&5
37942 $as_echo "$gl_cv_next_wctype_h" >&6; }
37943      fi
37944      NEXT_WCTYPE_H=$gl_cv_next_wctype_h
37945
37946      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
37947        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
37948        gl_next_as_first_directive='<'wctype.h'>'
37949      else
37950        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
37951        gl_next_as_first_directive=$gl_cv_next_wctype_h
37952      fi
37953      NEXT_AS_FIRST_DIRECTIVE_WCTYPE_H=$gl_next_as_first_directive
37954
37955
37956
37957
37958   if test $ac_cv_header_wctype_h = yes; then
37959     if test $ac_cv_func_iswcntrl = yes; then
37960                   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether iswcntrl works" >&5
37961 $as_echo_n "checking whether iswcntrl works... " >&6; }
37962 if ${gl_cv_func_iswcntrl_works+:} false; then :
37963   $as_echo_n "(cached) " >&6
37964 else
37965
37966           if test "$cross_compiling" = yes; then :
37967   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37968 /* end confdefs.h.  */
37969 #include <stdlib.h>
37970                           #if __GNU_LIBRARY__ == 1
37971                           Linux libc5 i18n is broken.
37972                           #endif
37973 int
37974 main ()
37975 {
37976
37977   ;
37978   return 0;
37979 }
37980 _ACEOF
37981 if ac_fn_c_try_compile "$LINENO"; then :
37982   gl_cv_func_iswcntrl_works="guessing yes"
37983 else
37984   gl_cv_func_iswcntrl_works="guessing no"
37985 fi
37986 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
37987
37988 else
37989   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
37990 /* end confdefs.h.  */
37991
37992                /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
37993                   included before <wchar.h>.
37994                   BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
37995                   must be included before <wchar.h>.  */
37996                #include <stddef.h>
37997                #include <stdio.h>
37998                #include <time.h>
37999                #include <wchar.h>
38000                #include <wctype.h>
38001                int main () { return iswprint ('x') == 0; }
38002
38003 _ACEOF
38004 if ac_fn_c_try_run "$LINENO"; then :
38005   gl_cv_func_iswcntrl_works=yes
38006 else
38007   gl_cv_func_iswcntrl_works=no
38008 fi
38009 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
38010   conftest.$ac_objext conftest.beam conftest.$ac_ext
38011 fi
38012
38013
38014 fi
38015 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_iswcntrl_works" >&5
38016 $as_echo "$gl_cv_func_iswcntrl_works" >&6; }
38017     fi
38018     HAVE_WCTYPE_H=1
38019   else
38020     HAVE_WCTYPE_H=0
38021   fi
38022
38023
38024   case "$gl_cv_func_iswcntrl_works" in
38025     *yes) REPLACE_ISWCNTRL=0 ;;
38026     *)    REPLACE_ISWCNTRL=1 ;;
38027   esac
38028
38029
38030   if test $HAVE_ISWCNTRL = 0 || test $REPLACE_ISWCNTRL = 1; then
38031         :
38032   fi
38033
38034   if test $REPLACE_ISWCNTRL = 1; then
38035     REPLACE_TOWLOWER=1
38036   else
38037     for ac_func in towlower
38038 do :
38039   ac_fn_c_check_func "$LINENO" "towlower" "ac_cv_func_towlower"
38040 if test "x$ac_cv_func_towlower" = xyes; then :
38041   cat >>confdefs.h <<_ACEOF
38042 #define HAVE_TOWLOWER 1
38043 _ACEOF
38044
38045 fi
38046 done
38047
38048     if test $ac_cv_func_towlower = yes; then
38049       REPLACE_TOWLOWER=0
38050     else
38051       ac_fn_c_check_decl "$LINENO" "towlower" "ac_cv_have_decl_towlower" "/* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
38052              included before <wchar.h>.
38053              BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
38054              must be included before <wchar.h>.  */
38055           #include <stddef.h>
38056           #include <stdio.h>
38057           #include <time.h>
38058           #include <wchar.h>
38059           #if HAVE_WCTYPE_H
38060           # include <wctype.h>
38061           #endif
38062
38063 "
38064 if test "x$ac_cv_have_decl_towlower" = xyes; then :
38065   ac_have_decl=1
38066 else
38067   ac_have_decl=0
38068 fi
38069
38070 cat >>confdefs.h <<_ACEOF
38071 #define HAVE_DECL_TOWLOWER $ac_have_decl
38072 _ACEOF
38073
38074       if test $ac_cv_have_decl_towlower = yes; then
38075                                 REPLACE_TOWLOWER=1
38076       else
38077         REPLACE_TOWLOWER=0
38078       fi
38079     fi
38080   fi
38081
38082
38083   if test $HAVE_ISWCNTRL = 0 || test $REPLACE_TOWLOWER = 1; then
38084         :
38085   fi
38086
38087           { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wctype_t" >&5
38088 $as_echo_n "checking for wctype_t... " >&6; }
38089 if ${gl_cv_type_wctype_t+:} false; then :
38090   $as_echo_n "(cached) " >&6
38091 else
38092   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38093 /* end confdefs.h.  */
38094 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
38095                included before <wchar.h>.
38096                BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
38097                must be included before <wchar.h>.  */
38098             #include <stddef.h>
38099             #include <stdio.h>
38100             #include <time.h>
38101             #include <wchar.h>
38102             #if HAVE_WCTYPE_H
38103             # include <wctype.h>
38104             #endif
38105             wctype_t a;
38106
38107 int
38108 main ()
38109 {
38110
38111   ;
38112   return 0;
38113 }
38114 _ACEOF
38115 if ac_fn_c_try_compile "$LINENO"; then :
38116   gl_cv_type_wctype_t=yes
38117 else
38118   gl_cv_type_wctype_t=no
38119 fi
38120 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
38121
38122 fi
38123 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_wctype_t" >&5
38124 $as_echo "$gl_cv_type_wctype_t" >&6; }
38125   if test $gl_cv_type_wctype_t = no; then
38126     HAVE_WCTYPE_T=0
38127   fi
38128
38129       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wctrans_t" >&5
38130 $as_echo_n "checking for wctrans_t... " >&6; }
38131 if ${gl_cv_type_wctrans_t+:} false; then :
38132   $as_echo_n "(cached) " >&6
38133 else
38134   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38135 /* end confdefs.h.  */
38136 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be
38137                included before <wchar.h>.
38138                BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h>
38139                must be included before <wchar.h>.  */
38140             #include <stddef.h>
38141             #include <stdio.h>
38142             #include <time.h>
38143             #include <wchar.h>
38144             #include <wctype.h>
38145             wctrans_t a;
38146
38147 int
38148 main ()
38149 {
38150
38151   ;
38152   return 0;
38153 }
38154 _ACEOF
38155 if ac_fn_c_try_compile "$LINENO"; then :
38156   gl_cv_type_wctrans_t=yes
38157 else
38158   gl_cv_type_wctrans_t=no
38159 fi
38160 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
38161
38162 fi
38163 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_wctrans_t" >&5
38164 $as_echo "$gl_cv_type_wctrans_t" >&6; }
38165   if test $gl_cv_type_wctrans_t = no; then
38166     HAVE_WCTRANS_T=0
38167   fi
38168
38169
38170
38171
38172
38173   for ac_header in stdint.h
38174 do :
38175   ac_fn_c_check_header_mongrel "$LINENO" "stdint.h" "ac_cv_header_stdint_h" "$ac_includes_default"
38176 if test "x$ac_cv_header_stdint_h" = xyes; then :
38177   cat >>confdefs.h <<_ACEOF
38178 #define HAVE_STDINT_H 1
38179 _ACEOF
38180
38181 fi
38182
38183 done
38184
38185
38186   # End of code from modules
38187
38188
38189
38190
38191
38192
38193
38194
38195
38196   gltests_libdeps=
38197   gltests_ltlibdeps=
38198
38199
38200
38201
38202
38203
38204
38205
38206
38207   gl_source_base='gnulib/tests'
38208   gltests_WITNESS=IN_`echo "${PACKAGE-$PACKAGE_TARNAME}" | LC_ALL=C tr abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ | LC_ALL=C sed -e 's/[^A-Z0-9_]/_/g'`_GNULIB_TESTS
38209
38210   gl_module_indicator_condition=$gltests_WITNESS
38211
38212
38213
38214
38215   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a traditional french locale" >&5
38216 $as_echo_n "checking for a traditional french locale... " >&6; }
38217 if ${gt_cv_locale_fr+:} false; then :
38218   $as_echo_n "(cached) " >&6
38219 else
38220
38221     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38222 /* end confdefs.h.  */
38223
38224 #include <locale.h>
38225 #include <time.h>
38226 #if HAVE_LANGINFO_CODESET
38227 # include <langinfo.h>
38228 #endif
38229 #include <stdlib.h>
38230 #include <string.h>
38231 struct tm t;
38232 char buf[16];
38233 int main () {
38234   /* Check whether the given locale name is recognized by the system.  */
38235 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
38236   /* On native Windows, setlocale(category, "") looks at the system settings,
38237      not at the environment variables.  Also, when an encoding suffix such
38238      as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
38239      category of the locale to "C".  */
38240   if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
38241       || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
38242     return 1;
38243 #else
38244   if (setlocale (LC_ALL, "") == NULL) return 1;
38245 #endif
38246   /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
38247      On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
38248      is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
38249      On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
38250      succeeds but then nl_langinfo(CODESET) is "646". In this situation,
38251      some unit tests fail.
38252      On MirBSD 10, when an unsupported locale is specified, setlocale()
38253      succeeds but then nl_langinfo(CODESET) is "UTF-8".  */
38254 #if HAVE_LANGINFO_CODESET
38255   {
38256     const char *cs = nl_langinfo (CODESET);
38257     if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
38258         || strcmp (cs, "UTF-8") == 0)
38259       return 1;
38260   }
38261 #endif
38262 #ifdef __CYGWIN__
38263   /* On Cygwin, avoid locale names without encoding suffix, because the
38264      locale_charset() function relies on the encoding suffix.  Note that
38265      LC_ALL is set on the command line.  */
38266   if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
38267 #endif
38268   /* Check whether in the abbreviation of the second month, the second
38269      character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is only
38270      one byte long. This excludes the UTF-8 encoding.  */
38271   t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
38272   if (strftime (buf, sizeof (buf), "%b", &t) < 3 || buf[2] != 'v') return 1;
38273 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy.  */
38274   /* Check whether the decimal separator is a comma.
38275      On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
38276      are nl_langinfo(RADIXCHAR) are both ".".  */
38277   if (localeconv () ->decimal_point[0] != ',') return 1;
38278 #endif
38279   return 0;
38280 }
38281
38282 _ACEOF
38283     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
38284   (eval $ac_link) 2>&5
38285   ac_status=$?
38286   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
38287   test $ac_status = 0; } && test -s conftest$ac_exeext; then
38288       case "$host_os" in
38289         # Handle native Windows specially, because there setlocale() interprets
38290         # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
38291         # "fr" or "fra" as "French" or "French_France.1252",
38292         # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
38293         # "ja" as "Japanese" or "Japanese_Japan.932",
38294         # and similar.
38295         mingw*)
38296           # Test for the native Windows locale name.
38297           if (LC_ALL=French_France.1252 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
38298             gt_cv_locale_fr=French_France.1252
38299           else
38300             # None found.
38301             gt_cv_locale_fr=none
38302           fi
38303           ;;
38304         *)
38305           # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
38306           # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
38307           # configure script would override the LC_ALL setting. Likewise for
38308           # LC_CTYPE, which is also set at the beginning of the configure script.
38309           # Test for the usual locale name.
38310           if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
38311             gt_cv_locale_fr=fr_FR
38312           else
38313             # Test for the locale name with explicit encoding suffix.
38314             if (LC_ALL=fr_FR.ISO-8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
38315               gt_cv_locale_fr=fr_FR.ISO-8859-1
38316             else
38317               # Test for the AIX, OSF/1, FreeBSD, NetBSD, OpenBSD locale name.
38318               if (LC_ALL=fr_FR.ISO8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
38319                 gt_cv_locale_fr=fr_FR.ISO8859-1
38320               else
38321                 # Test for the HP-UX locale name.
38322                 if (LC_ALL=fr_FR.iso88591 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
38323                   gt_cv_locale_fr=fr_FR.iso88591
38324                 else
38325                   # Test for the Solaris 7 locale name.
38326                   if (LC_ALL=fr LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
38327                     gt_cv_locale_fr=fr
38328                   else
38329                     # None found.
38330                     gt_cv_locale_fr=none
38331                   fi
38332                 fi
38333               fi
38334             fi
38335           fi
38336           ;;
38337       esac
38338     fi
38339     rm -fr conftest*
38340
38341 fi
38342 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr" >&5
38343 $as_echo "$gt_cv_locale_fr" >&6; }
38344   LOCALE_FR=$gt_cv_locale_fr
38345
38346
38347
38348
38349   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a french Unicode locale" >&5
38350 $as_echo_n "checking for a french Unicode locale... " >&6; }
38351 if ${gt_cv_locale_fr_utf8+:} false; then :
38352   $as_echo_n "(cached) " >&6
38353 else
38354
38355     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38356 /* end confdefs.h.  */
38357
38358 #include <locale.h>
38359 #include <time.h>
38360 #if HAVE_LANGINFO_CODESET
38361 # include <langinfo.h>
38362 #endif
38363 #include <stdlib.h>
38364 #include <string.h>
38365 struct tm t;
38366 char buf[16];
38367 int main () {
38368   /* On BeOS and Haiku, locales are not implemented in libc.  Rather, libintl
38369      imitates locale dependent behaviour by looking at the environment
38370      variables, and all locales use the UTF-8 encoding.  */
38371 #if !(defined __BEOS__ || defined __HAIKU__)
38372   /* Check whether the given locale name is recognized by the system.  */
38373 # if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
38374   /* On native Windows, setlocale(category, "") looks at the system settings,
38375      not at the environment variables.  Also, when an encoding suffix such
38376      as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
38377      category of the locale to "C".  */
38378   if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
38379       || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
38380     return 1;
38381 # else
38382   if (setlocale (LC_ALL, "") == NULL) return 1;
38383 # endif
38384   /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
38385      On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
38386      is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
38387      On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
38388      succeeds but then nl_langinfo(CODESET) is "646". In this situation,
38389      some unit tests fail.  */
38390 # if HAVE_LANGINFO_CODESET
38391   {
38392     const char *cs = nl_langinfo (CODESET);
38393     if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0)
38394       return 1;
38395   }
38396 # endif
38397 # ifdef __CYGWIN__
38398   /* On Cygwin, avoid locale names without encoding suffix, because the
38399      locale_charset() function relies on the encoding suffix.  Note that
38400      LC_ALL is set on the command line.  */
38401   if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
38402 # endif
38403   /* Check whether in the abbreviation of the second month, the second
38404      character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is
38405      two bytes long, with UTF-8 encoding.  */
38406   t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
38407   if (strftime (buf, sizeof (buf), "%b", &t) < 4
38408       || buf[1] != (char) 0xc3 || buf[2] != (char) 0xa9 || buf[3] != 'v')
38409     return 1;
38410 #endif
38411 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy.  */
38412   /* Check whether the decimal separator is a comma.
38413      On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
38414      are nl_langinfo(RADIXCHAR) are both ".".  */
38415   if (localeconv () ->decimal_point[0] != ',') return 1;
38416 #endif
38417   return 0;
38418 }
38419
38420 _ACEOF
38421     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
38422   (eval $ac_link) 2>&5
38423   ac_status=$?
38424   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
38425   test $ac_status = 0; } && test -s conftest$ac_exeext; then
38426       case "$host_os" in
38427         # Handle native Windows specially, because there setlocale() interprets
38428         # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
38429         # "fr" or "fra" as "French" or "French_France.1252",
38430         # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
38431         # "ja" as "Japanese" or "Japanese_Japan.932",
38432         # and similar.
38433         mingw*)
38434           # Test for the hypothetical native Windows locale name.
38435           if (LC_ALL=French_France.65001 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
38436             gt_cv_locale_fr_utf8=French_France.65001
38437           else
38438             # None found.
38439             gt_cv_locale_fr_utf8=none
38440           fi
38441           ;;
38442         *)
38443           # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
38444           # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
38445           # configure script would override the LC_ALL setting. Likewise for
38446           # LC_CTYPE, which is also set at the beginning of the configure script.
38447           # Test for the usual locale name.
38448           if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
38449             gt_cv_locale_fr_utf8=fr_FR
38450           else
38451             # Test for the locale name with explicit encoding suffix.
38452             if (LC_ALL=fr_FR.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
38453               gt_cv_locale_fr_utf8=fr_FR.UTF-8
38454             else
38455               # Test for the Solaris 7 locale name.
38456               if (LC_ALL=fr.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
38457                 gt_cv_locale_fr_utf8=fr.UTF-8
38458               else
38459                 # None found.
38460                 gt_cv_locale_fr_utf8=none
38461               fi
38462             fi
38463           fi
38464           ;;
38465       esac
38466     fi
38467     rm -fr conftest*
38468
38469 fi
38470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr_utf8" >&5
38471 $as_echo "$gt_cv_locale_fr_utf8" >&6; }
38472   LOCALE_FR_UTF8=$gt_cv_locale_fr_utf8
38473
38474
38475
38476
38477
38478   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a traditional french locale" >&5
38479 $as_echo_n "checking for a traditional french locale... " >&6; }
38480 if ${gt_cv_locale_fr+:} false; then :
38481   $as_echo_n "(cached) " >&6
38482 else
38483
38484     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38485 /* end confdefs.h.  */
38486
38487 #include <locale.h>
38488 #include <time.h>
38489 #if HAVE_LANGINFO_CODESET
38490 # include <langinfo.h>
38491 #endif
38492 #include <stdlib.h>
38493 #include <string.h>
38494 struct tm t;
38495 char buf[16];
38496 int main () {
38497   /* Check whether the given locale name is recognized by the system.  */
38498 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
38499   /* On native Windows, setlocale(category, "") looks at the system settings,
38500      not at the environment variables.  Also, when an encoding suffix such
38501      as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
38502      category of the locale to "C".  */
38503   if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
38504       || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
38505     return 1;
38506 #else
38507   if (setlocale (LC_ALL, "") == NULL) return 1;
38508 #endif
38509   /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
38510      On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
38511      is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
38512      On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
38513      succeeds but then nl_langinfo(CODESET) is "646". In this situation,
38514      some unit tests fail.
38515      On MirBSD 10, when an unsupported locale is specified, setlocale()
38516      succeeds but then nl_langinfo(CODESET) is "UTF-8".  */
38517 #if HAVE_LANGINFO_CODESET
38518   {
38519     const char *cs = nl_langinfo (CODESET);
38520     if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
38521         || strcmp (cs, "UTF-8") == 0)
38522       return 1;
38523   }
38524 #endif
38525 #ifdef __CYGWIN__
38526   /* On Cygwin, avoid locale names without encoding suffix, because the
38527      locale_charset() function relies on the encoding suffix.  Note that
38528      LC_ALL is set on the command line.  */
38529   if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
38530 #endif
38531   /* Check whether in the abbreviation of the second month, the second
38532      character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is only
38533      one byte long. This excludes the UTF-8 encoding.  */
38534   t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
38535   if (strftime (buf, sizeof (buf), "%b", &t) < 3 || buf[2] != 'v') return 1;
38536 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy.  */
38537   /* Check whether the decimal separator is a comma.
38538      On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
38539      are nl_langinfo(RADIXCHAR) are both ".".  */
38540   if (localeconv () ->decimal_point[0] != ',') return 1;
38541 #endif
38542   return 0;
38543 }
38544
38545 _ACEOF
38546     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
38547   (eval $ac_link) 2>&5
38548   ac_status=$?
38549   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
38550   test $ac_status = 0; } && test -s conftest$ac_exeext; then
38551       case "$host_os" in
38552         # Handle native Windows specially, because there setlocale() interprets
38553         # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
38554         # "fr" or "fra" as "French" or "French_France.1252",
38555         # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
38556         # "ja" as "Japanese" or "Japanese_Japan.932",
38557         # and similar.
38558         mingw*)
38559           # Test for the native Windows locale name.
38560           if (LC_ALL=French_France.1252 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
38561             gt_cv_locale_fr=French_France.1252
38562           else
38563             # None found.
38564             gt_cv_locale_fr=none
38565           fi
38566           ;;
38567         *)
38568           # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
38569           # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
38570           # configure script would override the LC_ALL setting. Likewise for
38571           # LC_CTYPE, which is also set at the beginning of the configure script.
38572           # Test for the usual locale name.
38573           if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
38574             gt_cv_locale_fr=fr_FR
38575           else
38576             # Test for the locale name with explicit encoding suffix.
38577             if (LC_ALL=fr_FR.ISO-8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
38578               gt_cv_locale_fr=fr_FR.ISO-8859-1
38579             else
38580               # Test for the AIX, OSF/1, FreeBSD, NetBSD, OpenBSD locale name.
38581               if (LC_ALL=fr_FR.ISO8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
38582                 gt_cv_locale_fr=fr_FR.ISO8859-1
38583               else
38584                 # Test for the HP-UX locale name.
38585                 if (LC_ALL=fr_FR.iso88591 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
38586                   gt_cv_locale_fr=fr_FR.iso88591
38587                 else
38588                   # Test for the Solaris 7 locale name.
38589                   if (LC_ALL=fr LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
38590                     gt_cv_locale_fr=fr
38591                   else
38592                     # None found.
38593                     gt_cv_locale_fr=none
38594                   fi
38595                 fi
38596               fi
38597             fi
38598           fi
38599           ;;
38600       esac
38601     fi
38602     rm -fr conftest*
38603
38604 fi
38605 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr" >&5
38606 $as_echo "$gt_cv_locale_fr" >&6; }
38607   LOCALE_FR=$gt_cv_locale_fr
38608
38609
38610
38611
38612
38613   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a turkish Unicode locale" >&5
38614 $as_echo_n "checking for a turkish Unicode locale... " >&6; }
38615 if ${gt_cv_locale_tr_utf8+:} false; then :
38616   $as_echo_n "(cached) " >&6
38617 else
38618
38619     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38620 /* end confdefs.h.  */
38621
38622 #include <locale.h>
38623 #include <time.h>
38624 #if HAVE_LANGINFO_CODESET
38625 # include <langinfo.h>
38626 #endif
38627 #include <stdlib.h>
38628 #include <string.h>
38629 struct tm t;
38630 char buf[16];
38631 int main () {
38632   /* On BeOS, locales are not implemented in libc.  Rather, libintl
38633      imitates locale dependent behaviour by looking at the environment
38634      variables, and all locales use the UTF-8 encoding.  But BeOS does not
38635      implement the Turkish upper-/lowercase mappings.  Therefore, let this
38636      program return 1 on BeOS.  */
38637   /* Check whether the given locale name is recognized by the system.  */
38638 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
38639   /* On native Windows, setlocale(category, "") looks at the system settings,
38640      not at the environment variables.  Also, when an encoding suffix such
38641      as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
38642      category of the locale to "C".  */
38643   if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
38644       || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
38645     return 1;
38646 #else
38647   if (setlocale (LC_ALL, "") == NULL) return 1;
38648 #endif
38649   /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
38650      On Mac OS X 10.3.5 (Darwin 7.5) in the tr_TR locale, nl_langinfo(CODESET)
38651      is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
38652      On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
38653      succeeds but then nl_langinfo(CODESET) is "646". In this situation,
38654      some unit tests fail.  */
38655 #if HAVE_LANGINFO_CODESET
38656   {
38657     const char *cs = nl_langinfo (CODESET);
38658     if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0)
38659       return 1;
38660   }
38661 #endif
38662 #ifdef __CYGWIN__
38663   /* On Cygwin, avoid locale names without encoding suffix, because the
38664      locale_charset() function relies on the encoding suffix.  Note that
38665      LC_ALL is set on the command line.  */
38666   if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
38667 #endif
38668   /* Check whether in the abbreviation of the eighth month, the second
38669      character (should be U+011F: LATIN SMALL LETTER G WITH BREVE) is
38670      two bytes long, with UTF-8 encoding.  */
38671   t.tm_year = 1992 - 1900; t.tm_mon = 8 - 1; t.tm_mday = 19;
38672   if (strftime (buf, sizeof (buf), "%b", &t) < 4
38673       || buf[1] != (char) 0xc4 || buf[2] != (char) 0x9f)
38674     return 1;
38675   /* Check whether the upper-/lowercase mappings are as expected for
38676      Turkish.  */
38677   if (towupper ('i') != 0x0130 || towlower (0x0130) != 'i'
38678       || towupper(0x0131) != 'I' || towlower ('I') != 0x0131)
38679     return 1;
38680   return 0;
38681 }
38682
38683 _ACEOF
38684     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
38685   (eval $ac_link) 2>&5
38686   ac_status=$?
38687   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
38688   test $ac_status = 0; } && test -s conftest$ac_exeext; then
38689       case "$host_os" in
38690         # Handle native Windows specially, because there setlocale() interprets
38691         # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
38692         # "fr" or "fra" as "French" or "French_France.1252",
38693         # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
38694         # "ja" as "Japanese" or "Japanese_Japan.932",
38695         # and similar.
38696         mingw*)
38697           # Test for the hypothetical native Windows locale name.
38698           if (LC_ALL=Turkish_Turkey.65001 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
38699             gt_cv_locale_tr_utf8=Turkish_Turkey.65001
38700           else
38701             # None found.
38702             gt_cv_locale_tr_utf8=none
38703           fi
38704           ;;
38705         *)
38706           # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
38707           # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
38708           # configure script would override the LC_ALL setting. Likewise for
38709           # LC_CTYPE, which is also set at the beginning of the configure script.
38710           # Test for the usual locale name.
38711           if (LC_ALL=tr_TR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
38712             gt_cv_locale_tr_utf8=tr_TR
38713           else
38714             # Test for the locale name with explicit encoding suffix.
38715             if (LC_ALL=tr_TR.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
38716               gt_cv_locale_tr_utf8=tr_TR.UTF-8
38717             else
38718               # Test for the Solaris 7 locale name.
38719               if (LC_ALL=tr.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
38720                 gt_cv_locale_tr_utf8=tr.UTF-8
38721               else
38722                 # None found.
38723                 gt_cv_locale_tr_utf8=none
38724               fi
38725             fi
38726           fi
38727           ;;
38728       esac
38729     else
38730       gt_cv_locale_tr_utf8=none
38731     fi
38732     rm -fr conftest*
38733
38734 fi
38735 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_tr_utf8" >&5
38736 $as_echo "$gt_cv_locale_tr_utf8" >&6; }
38737   LOCALE_TR_UTF8=$gt_cv_locale_tr_utf8
38738
38739
38740
38741   :
38742
38743
38744
38745
38746
38747
38748
38749
38750   if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
38751     REPLACE_DUP=1
38752   fi
38753
38754
38755   if test $REPLACE_DUP = 1; then
38756
38757
38758
38759
38760
38761
38762
38763
38764   gltests_LIBOBJS="$gltests_LIBOBJS dup.$ac_objext"
38765
38766     :
38767   fi
38768
38769
38770
38771
38772
38773     if test "$GNULIB_DUP" != 1; then
38774         if test "$GNULIB_DUP" = 0; then
38775       GNULIB_DUP=$gl_module_indicator_condition
38776     else
38777       GNULIB_DUP="($GNULIB_DUP || $gl_module_indicator_condition)"
38778     fi
38779   fi
38780
38781
38782
38783
38784
38785 $as_echo "#define GNULIB_TEST_DUP 1" >>confdefs.h
38786
38787
38788
38789
38790       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for error_at_line" >&5
38791 $as_echo_n "checking for error_at_line... " >&6; }
38792 if ${ac_cv_lib_error_at_line+:} false; then :
38793   $as_echo_n "(cached) " >&6
38794 else
38795   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38796 /* end confdefs.h.  */
38797 #include <error.h>
38798 int
38799 main ()
38800 {
38801 error_at_line (0, 0, "", 0, "an error occurred");
38802   ;
38803   return 0;
38804 }
38805 _ACEOF
38806 if ac_fn_c_try_link "$LINENO"; then :
38807   ac_cv_lib_error_at_line=yes
38808 else
38809   ac_cv_lib_error_at_line=no
38810 fi
38811 rm -f core conftest.err conftest.$ac_objext \
38812     conftest$ac_exeext conftest.$ac_ext
38813 fi
38814 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_error_at_line" >&5
38815 $as_echo "$ac_cv_lib_error_at_line" >&6; }
38816
38817   if test $ac_cv_lib_error_at_line = no; then
38818
38819
38820
38821
38822
38823
38824
38825
38826   gltests_LIBOBJS="$gltests_LIBOBJS error.$ac_objext"
38827
38828
38829
38830   :
38831
38832   fi
38833
38834
38835   XGETTEXT_EXTRA_OPTIONS="$XGETTEXT_EXTRA_OPTIONS --flag=error:3:c-format"
38836
38837
38838
38839   XGETTEXT_EXTRA_OPTIONS="$XGETTEXT_EXTRA_OPTIONS --flag=error_at_line:5:c-format"
38840
38841
38842
38843
38844   :
38845
38846
38847
38848
38849
38850   :
38851
38852
38853
38854
38855   if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
38856     REPLACE_FDOPEN=1
38857   else
38858         { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fdopen sets errno" >&5
38859 $as_echo_n "checking whether fdopen sets errno... " >&6; }
38860 if ${gl_cv_func_fdopen_works+:} false; then :
38861   $as_echo_n "(cached) " >&6
38862 else
38863
38864         if test "$cross_compiling" = yes; then :
38865   case "$host_os" in
38866              mingw*) gl_cv_func_fdopen_works="guessing no" ;;
38867              *)      gl_cv_func_fdopen_works="guessing yes" ;;
38868            esac
38869
38870 else
38871   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
38872 /* end confdefs.h.  */
38873
38874 #include <stdio.h>
38875 #include <errno.h>
38876 int
38877 main (void)
38878 {
38879   FILE *fp;
38880   errno = 0;
38881   fp = fdopen (-1, "r");
38882   if (fp == NULL && errno == 0)
38883     return 1;
38884   return 0;
38885 }
38886 _ACEOF
38887 if ac_fn_c_try_run "$LINENO"; then :
38888   gl_cv_func_fdopen_works=yes
38889 else
38890   gl_cv_func_fdopen_works=no
38891 fi
38892 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
38893   conftest.$ac_objext conftest.beam conftest.$ac_ext
38894 fi
38895
38896
38897 fi
38898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fdopen_works" >&5
38899 $as_echo "$gl_cv_func_fdopen_works" >&6; }
38900     case "$gl_cv_func_fdopen_works" in
38901       *no) REPLACE_FDOPEN=1 ;;
38902     esac
38903   fi
38904
38905   if test $REPLACE_FDOPEN = 1; then
38906
38907
38908
38909
38910
38911
38912
38913
38914   gltests_LIBOBJS="$gltests_LIBOBJS fdopen.$ac_objext"
38915
38916
38917   fi
38918
38919
38920
38921
38922
38923     if test "$GNULIB_FDOPEN" != 1; then
38924         if test "$GNULIB_FDOPEN" = 0; then
38925       GNULIB_FDOPEN=$gl_module_indicator_condition
38926     else
38927       GNULIB_FDOPEN="($GNULIB_FDOPEN || $gl_module_indicator_condition)"
38928     fi
38929   fi
38930
38931
38932
38933
38934
38935 $as_echo "#define GNULIB_TEST_FDOPEN 1" >>confdefs.h
38936
38937
38938
38939
38940
38941
38942
38943
38944
38945
38946   :
38947
38948
38949
38950
38951
38952   if test $ac_cv_func_ftruncate = yes; then
38953
38954
38955       case "$host_os" in
38956         mingw*)
38957                                                                       REPLACE_FTRUNCATE=1
38958           ;;
38959       esac
38960
38961   else
38962     HAVE_FTRUNCATE=0
38963   fi
38964
38965   if test $HAVE_FTRUNCATE = 0 || test $REPLACE_FTRUNCATE = 1; then
38966
38967
38968
38969
38970
38971
38972
38973
38974   gltests_LIBOBJS="$gltests_LIBOBJS ftruncate.$ac_objext"
38975
38976
38977   for ac_func in chsize
38978 do :
38979   ac_fn_c_check_func "$LINENO" "chsize" "ac_cv_func_chsize"
38980 if test "x$ac_cv_func_chsize" = xyes; then :
38981   cat >>confdefs.h <<_ACEOF
38982 #define HAVE_CHSIZE 1
38983 _ACEOF
38984
38985 fi
38986 done
38987
38988
38989   fi
38990
38991
38992
38993
38994
38995     if test "$GNULIB_FTRUNCATE" != 1; then
38996         if test "$GNULIB_FTRUNCATE" = 0; then
38997       GNULIB_FTRUNCATE=$gl_module_indicator_condition
38998     else
38999       GNULIB_FTRUNCATE="($GNULIB_FTRUNCATE || $gl_module_indicator_condition)"
39000     fi
39001   fi
39002
39003
39004
39005
39006
39007 $as_echo "#define GNULIB_TEST_FTRUNCATE 1" >>confdefs.h
39008
39009
39010
39011
39012
39013
39014   for ac_func in getpagesize
39015 do :
39016   ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
39017 if test "x$ac_cv_func_getpagesize" = xyes; then :
39018   cat >>confdefs.h <<_ACEOF
39019 #define HAVE_GETPAGESIZE 1
39020 _ACEOF
39021
39022 fi
39023 done
39024
39025   if test $ac_cv_func_getpagesize = no; then
39026     HAVE_GETPAGESIZE=0
39027     for ac_header in OS.h
39028 do :
39029   ac_fn_c_check_header_mongrel "$LINENO" "OS.h" "ac_cv_header_OS_h" "$ac_includes_default"
39030 if test "x$ac_cv_header_OS_h" = xyes; then :
39031   cat >>confdefs.h <<_ACEOF
39032 #define HAVE_OS_H 1
39033 _ACEOF
39034
39035 fi
39036
39037 done
39038
39039     if test $ac_cv_header_OS_h = yes; then
39040       HAVE_OS_H=1
39041     fi
39042     for ac_header in sys/param.h
39043 do :
39044   ac_fn_c_check_header_mongrel "$LINENO" "sys/param.h" "ac_cv_header_sys_param_h" "$ac_includes_default"
39045 if test "x$ac_cv_header_sys_param_h" = xyes; then :
39046   cat >>confdefs.h <<_ACEOF
39047 #define HAVE_SYS_PARAM_H 1
39048 _ACEOF
39049
39050 fi
39051
39052 done
39053
39054     if test $ac_cv_header_sys_param_h = yes; then
39055       HAVE_SYS_PARAM_H=1
39056     fi
39057   fi
39058   case "$host_os" in
39059     mingw*)
39060       REPLACE_GETPAGESIZE=1
39061       ;;
39062   esac
39063       ac_fn_c_check_decl "$LINENO" "getpagesize" "ac_cv_have_decl_getpagesize" "$ac_includes_default"
39064 if test "x$ac_cv_have_decl_getpagesize" = xyes; then :
39065
39066 else
39067   HAVE_DECL_GETPAGESIZE=0
39068 fi
39069
39070
39071   if test $REPLACE_GETPAGESIZE = 1; then
39072
39073
39074
39075
39076
39077
39078
39079
39080   gltests_LIBOBJS="$gltests_LIBOBJS getpagesize.$ac_objext"
39081
39082   fi
39083
39084
39085
39086
39087
39088     if test "$GNULIB_GETPAGESIZE" != 1; then
39089         if test "$GNULIB_GETPAGESIZE" = 0; then
39090       GNULIB_GETPAGESIZE=$gl_module_indicator_condition
39091     else
39092       GNULIB_GETPAGESIZE="($GNULIB_GETPAGESIZE || $gl_module_indicator_condition)"
39093     fi
39094   fi
39095
39096
39097
39098
39099
39100 $as_echo "#define GNULIB_TEST_GETPAGESIZE 1" >>confdefs.h
39101
39102
39103
39104
39105   if test "$ac_cv_header_winsock2_h" = yes; then
39106
39107
39108
39109
39110
39111
39112
39113
39114   gltests_LIBOBJS="$gltests_LIBOBJS getsockopt.$ac_objext"
39115
39116   fi
39117
39118
39119
39120
39121
39122     if test "$GNULIB_GETSOCKOPT" != 1; then
39123         if test "$GNULIB_GETSOCKOPT" = 0; then
39124       GNULIB_GETSOCKOPT=$gl_module_indicator_condition
39125     else
39126       GNULIB_GETSOCKOPT="($GNULIB_GETSOCKOPT || $gl_module_indicator_condition)"
39127     fi
39128   fi
39129
39130
39131
39132
39133
39134 $as_echo "#define GNULIB_TEST_GETSOCKOPT 1" >>confdefs.h
39135
39136
39137
39138
39139
39140
39141
39142
39143   for ac_func in grantpt
39144 do :
39145   ac_fn_c_check_func "$LINENO" "grantpt" "ac_cv_func_grantpt"
39146 if test "x$ac_cv_func_grantpt" = xyes; then :
39147   cat >>confdefs.h <<_ACEOF
39148 #define HAVE_GRANTPT 1
39149 _ACEOF
39150
39151 fi
39152 done
39153
39154   if test $ac_cv_func_grantpt = no; then
39155     HAVE_GRANTPT=0
39156   fi
39157
39158   if test $HAVE_GRANTPT = 0; then
39159
39160
39161
39162
39163
39164
39165
39166
39167   gltests_LIBOBJS="$gltests_LIBOBJS grantpt.$ac_objext"
39168
39169
39170   for ac_func in setrlimit
39171 do :
39172   ac_fn_c_check_func "$LINENO" "setrlimit" "ac_cv_func_setrlimit"
39173 if test "x$ac_cv_func_setrlimit" = xyes; then :
39174   cat >>confdefs.h <<_ACEOF
39175 #define HAVE_SETRLIMIT 1
39176 _ACEOF
39177
39178 fi
39179 done
39180
39181
39182   fi
39183
39184
39185
39186
39187
39188     if test "$GNULIB_GRANTPT" != 1; then
39189         if test "$GNULIB_GRANTPT" = 0; then
39190       GNULIB_GRANTPT=$gl_module_indicator_condition
39191     else
39192       GNULIB_GRANTPT="($GNULIB_GRANTPT || $gl_module_indicator_condition)"
39193     fi
39194   fi
39195
39196
39197
39198
39199
39200 $as_echo "#define GNULIB_TEST_GRANTPT 1" >>confdefs.h
39201
39202
39203
39204    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
39205 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
39206 if ${ac_cv_c_bigendian+:} false; then :
39207   $as_echo_n "(cached) " >&6
39208 else
39209   ac_cv_c_bigendian=unknown
39210     # See if we're dealing with a universal compiler.
39211     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39212 /* end confdefs.h.  */
39213 #ifndef __APPLE_CC__
39214                not a universal capable compiler
39215              #endif
39216              typedef int dummy;
39217
39218 _ACEOF
39219 if ac_fn_c_try_compile "$LINENO"; then :
39220
39221         # Check for potential -arch flags.  It is not universal unless
39222         # there are at least two -arch flags with different values.
39223         ac_arch=
39224         ac_prev=
39225         for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
39226          if test -n "$ac_prev"; then
39227            case $ac_word in
39228              i?86 | x86_64 | ppc | ppc64)
39229                if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
39230                  ac_arch=$ac_word
39231                else
39232                  ac_cv_c_bigendian=universal
39233                  break
39234                fi
39235                ;;
39236            esac
39237            ac_prev=
39238          elif test "x$ac_word" = "x-arch"; then
39239            ac_prev=arch
39240          fi
39241        done
39242 fi
39243 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
39244     if test $ac_cv_c_bigendian = unknown; then
39245       # See if sys/param.h defines the BYTE_ORDER macro.
39246       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39247 /* end confdefs.h.  */
39248 #include <sys/types.h>
39249              #include <sys/param.h>
39250
39251 int
39252 main ()
39253 {
39254 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
39255                      && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
39256                      && LITTLE_ENDIAN)
39257               bogus endian macros
39258              #endif
39259
39260   ;
39261   return 0;
39262 }
39263 _ACEOF
39264 if ac_fn_c_try_compile "$LINENO"; then :
39265   # It does; now see whether it defined to BIG_ENDIAN or not.
39266          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39267 /* end confdefs.h.  */
39268 #include <sys/types.h>
39269                 #include <sys/param.h>
39270
39271 int
39272 main ()
39273 {
39274 #if BYTE_ORDER != BIG_ENDIAN
39275                  not big endian
39276                 #endif
39277
39278   ;
39279   return 0;
39280 }
39281 _ACEOF
39282 if ac_fn_c_try_compile "$LINENO"; then :
39283   ac_cv_c_bigendian=yes
39284 else
39285   ac_cv_c_bigendian=no
39286 fi
39287 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
39288 fi
39289 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
39290     fi
39291     if test $ac_cv_c_bigendian = unknown; then
39292       # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
39293       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39294 /* end confdefs.h.  */
39295 #include <limits.h>
39296
39297 int
39298 main ()
39299 {
39300 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
39301               bogus endian macros
39302              #endif
39303
39304   ;
39305   return 0;
39306 }
39307 _ACEOF
39308 if ac_fn_c_try_compile "$LINENO"; then :
39309   # It does; now see whether it defined to _BIG_ENDIAN or not.
39310          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39311 /* end confdefs.h.  */
39312 #include <limits.h>
39313
39314 int
39315 main ()
39316 {
39317 #ifndef _BIG_ENDIAN
39318                  not big endian
39319                 #endif
39320
39321   ;
39322   return 0;
39323 }
39324 _ACEOF
39325 if ac_fn_c_try_compile "$LINENO"; then :
39326   ac_cv_c_bigendian=yes
39327 else
39328   ac_cv_c_bigendian=no
39329 fi
39330 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
39331 fi
39332 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
39333     fi
39334     if test $ac_cv_c_bigendian = unknown; then
39335       # Compile a test program.
39336       if test "$cross_compiling" = yes; then :
39337   # Try to guess by grepping values from an object file.
39338          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39339 /* end confdefs.h.  */
39340 short int ascii_mm[] =
39341                   { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
39342                 short int ascii_ii[] =
39343                   { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
39344                 int use_ascii (int i) {
39345                   return ascii_mm[i] + ascii_ii[i];
39346                 }
39347                 short int ebcdic_ii[] =
39348                   { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
39349                 short int ebcdic_mm[] =
39350                   { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
39351                 int use_ebcdic (int i) {
39352                   return ebcdic_mm[i] + ebcdic_ii[i];
39353                 }
39354                 extern int foo;
39355
39356 int
39357 main ()
39358 {
39359 return use_ascii (foo) == use_ebcdic (foo);
39360   ;
39361   return 0;
39362 }
39363 _ACEOF
39364 if ac_fn_c_try_compile "$LINENO"; then :
39365   if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
39366               ac_cv_c_bigendian=yes
39367             fi
39368             if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
39369               if test "$ac_cv_c_bigendian" = unknown; then
39370                 ac_cv_c_bigendian=no
39371               else
39372                 # finding both strings is unlikely to happen, but who knows?
39373                 ac_cv_c_bigendian=unknown
39374               fi
39375             fi
39376 fi
39377 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
39378 else
39379   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39380 /* end confdefs.h.  */
39381 $ac_includes_default
39382 int
39383 main ()
39384 {
39385
39386              /* Are we little or big endian?  From Harbison&Steele.  */
39387              union
39388              {
39389                long int l;
39390                char c[sizeof (long int)];
39391              } u;
39392              u.l = 1;
39393              return u.c[sizeof (long int) - 1] == 1;
39394
39395   ;
39396   return 0;
39397 }
39398 _ACEOF
39399 if ac_fn_c_try_run "$LINENO"; then :
39400   ac_cv_c_bigendian=no
39401 else
39402   ac_cv_c_bigendian=yes
39403 fi
39404 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
39405   conftest.$ac_objext conftest.beam conftest.$ac_ext
39406 fi
39407
39408     fi
39409 fi
39410 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
39411 $as_echo "$ac_cv_c_bigendian" >&6; }
39412  case $ac_cv_c_bigendian in #(
39413    yes)
39414      $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
39415 ;; #(
39416    no)
39417       ;; #(
39418    universal)
39419
39420 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
39421
39422      ;; #(
39423    *)
39424      as_fn_error $? "unknown endianness
39425  presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
39426  esac
39427
39428    { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
39429 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
39430 if ${ac_cv_c_bigendian+:} false; then :
39431   $as_echo_n "(cached) " >&6
39432 else
39433   ac_cv_c_bigendian=unknown
39434     # See if we're dealing with a universal compiler.
39435     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39436 /* end confdefs.h.  */
39437 #ifndef __APPLE_CC__
39438                not a universal capable compiler
39439              #endif
39440              typedef int dummy;
39441
39442 _ACEOF
39443 if ac_fn_c_try_compile "$LINENO"; then :
39444
39445         # Check for potential -arch flags.  It is not universal unless
39446         # there are at least two -arch flags with different values.
39447         ac_arch=
39448         ac_prev=
39449         for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
39450          if test -n "$ac_prev"; then
39451            case $ac_word in
39452              i?86 | x86_64 | ppc | ppc64)
39453                if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
39454                  ac_arch=$ac_word
39455                else
39456                  ac_cv_c_bigendian=universal
39457                  break
39458                fi
39459                ;;
39460            esac
39461            ac_prev=
39462          elif test "x$ac_word" = "x-arch"; then
39463            ac_prev=arch
39464          fi
39465        done
39466 fi
39467 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
39468     if test $ac_cv_c_bigendian = unknown; then
39469       # See if sys/param.h defines the BYTE_ORDER macro.
39470       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39471 /* end confdefs.h.  */
39472 #include <sys/types.h>
39473              #include <sys/param.h>
39474
39475 int
39476 main ()
39477 {
39478 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
39479                      && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
39480                      && LITTLE_ENDIAN)
39481               bogus endian macros
39482              #endif
39483
39484   ;
39485   return 0;
39486 }
39487 _ACEOF
39488 if ac_fn_c_try_compile "$LINENO"; then :
39489   # It does; now see whether it defined to BIG_ENDIAN or not.
39490          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39491 /* end confdefs.h.  */
39492 #include <sys/types.h>
39493                 #include <sys/param.h>
39494
39495 int
39496 main ()
39497 {
39498 #if BYTE_ORDER != BIG_ENDIAN
39499                  not big endian
39500                 #endif
39501
39502   ;
39503   return 0;
39504 }
39505 _ACEOF
39506 if ac_fn_c_try_compile "$LINENO"; then :
39507   ac_cv_c_bigendian=yes
39508 else
39509   ac_cv_c_bigendian=no
39510 fi
39511 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
39512 fi
39513 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
39514     fi
39515     if test $ac_cv_c_bigendian = unknown; then
39516       # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
39517       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39518 /* end confdefs.h.  */
39519 #include <limits.h>
39520
39521 int
39522 main ()
39523 {
39524 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
39525               bogus endian macros
39526              #endif
39527
39528   ;
39529   return 0;
39530 }
39531 _ACEOF
39532 if ac_fn_c_try_compile "$LINENO"; then :
39533   # It does; now see whether it defined to _BIG_ENDIAN or not.
39534          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39535 /* end confdefs.h.  */
39536 #include <limits.h>
39537
39538 int
39539 main ()
39540 {
39541 #ifndef _BIG_ENDIAN
39542                  not big endian
39543                 #endif
39544
39545   ;
39546   return 0;
39547 }
39548 _ACEOF
39549 if ac_fn_c_try_compile "$LINENO"; then :
39550   ac_cv_c_bigendian=yes
39551 else
39552   ac_cv_c_bigendian=no
39553 fi
39554 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
39555 fi
39556 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
39557     fi
39558     if test $ac_cv_c_bigendian = unknown; then
39559       # Compile a test program.
39560       if test "$cross_compiling" = yes; then :
39561   # Try to guess by grepping values from an object file.
39562          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39563 /* end confdefs.h.  */
39564 short int ascii_mm[] =
39565                   { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
39566                 short int ascii_ii[] =
39567                   { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
39568                 int use_ascii (int i) {
39569                   return ascii_mm[i] + ascii_ii[i];
39570                 }
39571                 short int ebcdic_ii[] =
39572                   { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
39573                 short int ebcdic_mm[] =
39574                   { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
39575                 int use_ebcdic (int i) {
39576                   return ebcdic_mm[i] + ebcdic_ii[i];
39577                 }
39578                 extern int foo;
39579
39580 int
39581 main ()
39582 {
39583 return use_ascii (foo) == use_ebcdic (foo);
39584   ;
39585   return 0;
39586 }
39587 _ACEOF
39588 if ac_fn_c_try_compile "$LINENO"; then :
39589   if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
39590               ac_cv_c_bigendian=yes
39591             fi
39592             if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
39593               if test "$ac_cv_c_bigendian" = unknown; then
39594                 ac_cv_c_bigendian=no
39595               else
39596                 # finding both strings is unlikely to happen, but who knows?
39597                 ac_cv_c_bigendian=unknown
39598               fi
39599             fi
39600 fi
39601 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
39602 else
39603   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39604 /* end confdefs.h.  */
39605 $ac_includes_default
39606 int
39607 main ()
39608 {
39609
39610              /* Are we little or big endian?  From Harbison&Steele.  */
39611              union
39612              {
39613                long int l;
39614                char c[sizeof (long int)];
39615              } u;
39616              u.l = 1;
39617              return u.c[sizeof (long int) - 1] == 1;
39618
39619   ;
39620   return 0;
39621 }
39622 _ACEOF
39623 if ac_fn_c_try_run "$LINENO"; then :
39624   ac_cv_c_bigendian=no
39625 else
39626   ac_cv_c_bigendian=yes
39627 fi
39628 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
39629   conftest.$ac_objext conftest.beam conftest.$ac_ext
39630 fi
39631
39632     fi
39633 fi
39634 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
39635 $as_echo "$ac_cv_c_bigendian" >&6; }
39636  case $ac_cv_c_bigendian in #(
39637    yes)
39638      $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
39639 ;; #(
39640    no)
39641       ;; #(
39642    universal)
39643
39644 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
39645
39646      ;; #(
39647    *)
39648      as_fn_error $? "unknown endianness
39649  presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
39650  esac
39651
39652
39653
39654
39655
39656
39657   PRIPTR_PREFIX=
39658   if test -n "$STDINT_H"; then
39659         PRIPTR_PREFIX='"l"'
39660   else
39661         for glpfx in '' l ll I64; do
39662       case $glpfx in
39663         '')  gltype1='int';;
39664         l)   gltype1='long int';;
39665         ll)  gltype1='long long int';;
39666         I64) gltype1='__int64';;
39667       esac
39668       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39669 /* end confdefs.h.  */
39670 #include <stdint.h>
39671            extern intptr_t foo;
39672            extern $gltype1 foo;
39673 int
39674 main ()
39675 {
39676
39677   ;
39678   return 0;
39679 }
39680 _ACEOF
39681 if ac_fn_c_try_compile "$LINENO"; then :
39682   PRIPTR_PREFIX='"'$glpfx'"'
39683 fi
39684 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
39685       test -n "$PRIPTR_PREFIX" && break
39686     done
39687   fi
39688
39689
39690
39691   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether INT32_MAX < INTMAX_MAX" >&5
39692 $as_echo_n "checking whether INT32_MAX < INTMAX_MAX... " >&6; }
39693 if ${gl_cv_test_INT32_MAX_LT_INTMAX_MAX+:} false; then :
39694   $as_echo_n "(cached) " >&6
39695 else
39696   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39697 /* end confdefs.h.  */
39698 /* Work also in C++ mode.  */
39699             #define __STDC_LIMIT_MACROS 1
39700
39701             /* Work if build is not clean.  */
39702             #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H
39703
39704             #include <limits.h>
39705             #if HAVE_STDINT_H
39706              #include <stdint.h>
39707             #endif
39708
39709             #if defined INT32_MAX && defined INTMAX_MAX
39710              #define CONDITION (INT32_MAX < INTMAX_MAX)
39711             #elif HAVE_LONG_LONG_INT
39712              #define CONDITION (sizeof (int) < sizeof (long long int))
39713             #else
39714              #define CONDITION 0
39715             #endif
39716             int test[CONDITION ? 1 : -1];
39717 int
39718 main ()
39719 {
39720
39721   ;
39722   return 0;
39723 }
39724 _ACEOF
39725 if ac_fn_c_try_compile "$LINENO"; then :
39726   gl_cv_test_INT32_MAX_LT_INTMAX_MAX=yes
39727 else
39728   gl_cv_test_INT32_MAX_LT_INTMAX_MAX=no
39729 fi
39730 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
39731 fi
39732 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_test_INT32_MAX_LT_INTMAX_MAX" >&5
39733 $as_echo "$gl_cv_test_INT32_MAX_LT_INTMAX_MAX" >&6; }
39734   if test $gl_cv_test_INT32_MAX_LT_INTMAX_MAX = yes; then
39735     INT32_MAX_LT_INTMAX_MAX=1;
39736   else
39737     INT32_MAX_LT_INTMAX_MAX=0;
39738   fi
39739
39740
39741   if test $APPLE_UNIVERSAL_BUILD = 0; then
39742
39743   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether INT64_MAX == LONG_MAX" >&5
39744 $as_echo_n "checking whether INT64_MAX == LONG_MAX... " >&6; }
39745 if ${gl_cv_test_INT64_MAX_EQ_LONG_MAX+:} false; then :
39746   $as_echo_n "(cached) " >&6
39747 else
39748   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39749 /* end confdefs.h.  */
39750 /* Work also in C++ mode.  */
39751             #define __STDC_LIMIT_MACROS 1
39752
39753             /* Work if build is not clean.  */
39754             #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H
39755
39756             #include <limits.h>
39757             #if HAVE_STDINT_H
39758              #include <stdint.h>
39759             #endif
39760
39761             #if defined INT64_MAX
39762              #define CONDITION (INT64_MAX == LONG_MAX)
39763             #elif HAVE_LONG_LONG_INT
39764              #define CONDITION (sizeof (long long int) == sizeof (long int))
39765             #else
39766              #define CONDITION 0
39767             #endif
39768             int test[CONDITION ? 1 : -1];
39769 int
39770 main ()
39771 {
39772
39773   ;
39774   return 0;
39775 }
39776 _ACEOF
39777 if ac_fn_c_try_compile "$LINENO"; then :
39778   gl_cv_test_INT64_MAX_EQ_LONG_MAX=yes
39779 else
39780   gl_cv_test_INT64_MAX_EQ_LONG_MAX=no
39781 fi
39782 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
39783 fi
39784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_test_INT64_MAX_EQ_LONG_MAX" >&5
39785 $as_echo "$gl_cv_test_INT64_MAX_EQ_LONG_MAX" >&6; }
39786   if test $gl_cv_test_INT64_MAX_EQ_LONG_MAX = yes; then
39787     INT64_MAX_EQ_LONG_MAX=1;
39788   else
39789     INT64_MAX_EQ_LONG_MAX=0;
39790   fi
39791
39792
39793   else
39794     INT64_MAX_EQ_LONG_MAX=-1
39795   fi
39796
39797   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether UINT32_MAX < UINTMAX_MAX" >&5
39798 $as_echo_n "checking whether UINT32_MAX < UINTMAX_MAX... " >&6; }
39799 if ${gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX+:} false; then :
39800   $as_echo_n "(cached) " >&6
39801 else
39802   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39803 /* end confdefs.h.  */
39804 /* Work also in C++ mode.  */
39805             #define __STDC_LIMIT_MACROS 1
39806
39807             /* Work if build is not clean.  */
39808             #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H
39809
39810             #include <limits.h>
39811             #if HAVE_STDINT_H
39812              #include <stdint.h>
39813             #endif
39814
39815             #if defined UINT32_MAX && defined UINTMAX_MAX
39816              #define CONDITION (UINT32_MAX < UINTMAX_MAX)
39817             #elif HAVE_LONG_LONG_INT
39818              #define CONDITION (sizeof (unsigned int) < sizeof (unsigned long long int))
39819             #else
39820              #define CONDITION 0
39821             #endif
39822             int test[CONDITION ? 1 : -1];
39823 int
39824 main ()
39825 {
39826
39827   ;
39828   return 0;
39829 }
39830 _ACEOF
39831 if ac_fn_c_try_compile "$LINENO"; then :
39832   gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX=yes
39833 else
39834   gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX=no
39835 fi
39836 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
39837 fi
39838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX" >&5
39839 $as_echo "$gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX" >&6; }
39840   if test $gl_cv_test_UINT32_MAX_LT_UINTMAX_MAX = yes; then
39841     UINT32_MAX_LT_UINTMAX_MAX=1;
39842   else
39843     UINT32_MAX_LT_UINTMAX_MAX=0;
39844   fi
39845
39846
39847   if test $APPLE_UNIVERSAL_BUILD = 0; then
39848
39849   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether UINT64_MAX == ULONG_MAX" >&5
39850 $as_echo_n "checking whether UINT64_MAX == ULONG_MAX... " >&6; }
39851 if ${gl_cv_test_UINT64_MAX_EQ_ULONG_MAX+:} false; then :
39852   $as_echo_n "(cached) " >&6
39853 else
39854   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39855 /* end confdefs.h.  */
39856 /* Work also in C++ mode.  */
39857             #define __STDC_LIMIT_MACROS 1
39858
39859             /* Work if build is not clean.  */
39860             #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H
39861
39862             #include <limits.h>
39863             #if HAVE_STDINT_H
39864              #include <stdint.h>
39865             #endif
39866
39867             #if defined UINT64_MAX
39868              #define CONDITION (UINT64_MAX == ULONG_MAX)
39869             #elif HAVE_LONG_LONG_INT
39870              #define CONDITION (sizeof (unsigned long long int) == sizeof (unsigned long int))
39871             #else
39872              #define CONDITION 0
39873             #endif
39874             int test[CONDITION ? 1 : -1];
39875 int
39876 main ()
39877 {
39878
39879   ;
39880   return 0;
39881 }
39882 _ACEOF
39883 if ac_fn_c_try_compile "$LINENO"; then :
39884   gl_cv_test_UINT64_MAX_EQ_ULONG_MAX=yes
39885 else
39886   gl_cv_test_UINT64_MAX_EQ_ULONG_MAX=no
39887 fi
39888 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
39889 fi
39890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_test_UINT64_MAX_EQ_ULONG_MAX" >&5
39891 $as_echo "$gl_cv_test_UINT64_MAX_EQ_ULONG_MAX" >&6; }
39892   if test $gl_cv_test_UINT64_MAX_EQ_ULONG_MAX = yes; then
39893     UINT64_MAX_EQ_ULONG_MAX=1;
39894   else
39895     UINT64_MAX_EQ_ULONG_MAX=0;
39896   fi
39897
39898
39899   else
39900     UINT64_MAX_EQ_ULONG_MAX=-1
39901   fi
39902
39903
39904
39905
39906
39907   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether isnan(double) can be used without linking with libm" >&5
39908 $as_echo_n "checking whether isnan(double) can be used without linking with libm... " >&6; }
39909 if ${gl_cv_func_isnand_no_libm+:} false; then :
39910   $as_echo_n "(cached) " >&6
39911 else
39912
39913       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39914 /* end confdefs.h.  */
39915 #include <math.h>
39916              #if __GNUC__ >= 4
39917              # undef isnand
39918              # define isnand(x) __builtin_isnan ((double)(x))
39919              #else
39920              # undef isnand
39921              # define isnand(x) isnan ((double)(x))
39922              #endif
39923              double x;
39924 int
39925 main ()
39926 {
39927 return isnand (x);
39928   ;
39929   return 0;
39930 }
39931 _ACEOF
39932 if ac_fn_c_try_link "$LINENO"; then :
39933   gl_cv_func_isnand_no_libm=yes
39934 else
39935   gl_cv_func_isnand_no_libm=no
39936 fi
39937 rm -f core conftest.err conftest.$ac_objext \
39938     conftest$ac_exeext conftest.$ac_ext
39939
39940 fi
39941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_isnand_no_libm" >&5
39942 $as_echo "$gl_cv_func_isnand_no_libm" >&6; }
39943
39944   gl_func_isnand_no_libm=$gl_cv_func_isnand_no_libm
39945   if test $gl_cv_func_isnand_no_libm = yes; then
39946
39947 $as_echo "#define HAVE_ISNAND_IN_LIBC 1" >>confdefs.h
39948
39949   fi
39950
39951   if test $gl_func_isnand_no_libm != yes; then
39952
39953
39954
39955
39956
39957
39958
39959
39960   gltests_LIBOBJS="$gltests_LIBOBJS isnand.$ac_objext"
39961
39962
39963
39964
39965   fi
39966
39967   { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the exponent in a 'double'" >&5
39968 $as_echo_n "checking where to find the exponent in a 'double'... " >&6; }
39969 if ${gl_cv_cc_double_expbit0+:} false; then :
39970   $as_echo_n "(cached) " >&6
39971 else
39972
39973       if test "$cross_compiling" = yes; then :
39974
39975                                                                       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39976 /* end confdefs.h.  */
39977
39978 #if defined arm || defined __arm || defined __arm__
39979   mixed_endianness
39980 #endif
39981
39982 _ACEOF
39983 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
39984   $EGREP "mixed_endianness" >/dev/null 2>&1; then :
39985   gl_cv_cc_double_expbit0="unknown"
39986 else
39987
39988                                                          :
39989 if ${ac_cv_c_bigendian+:} false; then :
39990   $as_echo_n "(cached) " >&6
39991 else
39992   ac_cv_c_bigendian=unknown
39993     # See if we're dealing with a universal compiler.
39994     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
39995 /* end confdefs.h.  */
39996 #ifndef __APPLE_CC__
39997                not a universal capable compiler
39998              #endif
39999              typedef int dummy;
40000
40001 _ACEOF
40002 if ac_fn_c_try_compile "$LINENO"; then :
40003
40004         # Check for potential -arch flags.  It is not universal unless
40005         # there are at least two -arch flags with different values.
40006         ac_arch=
40007         ac_prev=
40008         for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
40009          if test -n "$ac_prev"; then
40010            case $ac_word in
40011              i?86 | x86_64 | ppc | ppc64)
40012                if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
40013                  ac_arch=$ac_word
40014                else
40015                  ac_cv_c_bigendian=universal
40016                  break
40017                fi
40018                ;;
40019            esac
40020            ac_prev=
40021          elif test "x$ac_word" = "x-arch"; then
40022            ac_prev=arch
40023          fi
40024        done
40025 fi
40026 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
40027     if test $ac_cv_c_bigendian = unknown; then
40028       # See if sys/param.h defines the BYTE_ORDER macro.
40029       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40030 /* end confdefs.h.  */
40031 #include <sys/types.h>
40032              #include <sys/param.h>
40033
40034 int
40035 main ()
40036 {
40037 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
40038                      && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
40039                      && LITTLE_ENDIAN)
40040               bogus endian macros
40041              #endif
40042
40043   ;
40044   return 0;
40045 }
40046 _ACEOF
40047 if ac_fn_c_try_compile "$LINENO"; then :
40048   # It does; now see whether it defined to BIG_ENDIAN or not.
40049          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40050 /* end confdefs.h.  */
40051 #include <sys/types.h>
40052                 #include <sys/param.h>
40053
40054 int
40055 main ()
40056 {
40057 #if BYTE_ORDER != BIG_ENDIAN
40058                  not big endian
40059                 #endif
40060
40061   ;
40062   return 0;
40063 }
40064 _ACEOF
40065 if ac_fn_c_try_compile "$LINENO"; then :
40066   ac_cv_c_bigendian=yes
40067 else
40068   ac_cv_c_bigendian=no
40069 fi
40070 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
40071 fi
40072 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
40073     fi
40074     if test $ac_cv_c_bigendian = unknown; then
40075       # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
40076       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40077 /* end confdefs.h.  */
40078 #include <limits.h>
40079
40080 int
40081 main ()
40082 {
40083 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
40084               bogus endian macros
40085              #endif
40086
40087   ;
40088   return 0;
40089 }
40090 _ACEOF
40091 if ac_fn_c_try_compile "$LINENO"; then :
40092   # It does; now see whether it defined to _BIG_ENDIAN or not.
40093          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40094 /* end confdefs.h.  */
40095 #include <limits.h>
40096
40097 int
40098 main ()
40099 {
40100 #ifndef _BIG_ENDIAN
40101                  not big endian
40102                 #endif
40103
40104   ;
40105   return 0;
40106 }
40107 _ACEOF
40108 if ac_fn_c_try_compile "$LINENO"; then :
40109   ac_cv_c_bigendian=yes
40110 else
40111   ac_cv_c_bigendian=no
40112 fi
40113 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
40114 fi
40115 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
40116     fi
40117     if test $ac_cv_c_bigendian = unknown; then
40118       # Compile a test program.
40119       if test "$cross_compiling" = yes; then :
40120   # Try to guess by grepping values from an object file.
40121          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40122 /* end confdefs.h.  */
40123 short int ascii_mm[] =
40124                   { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
40125                 short int ascii_ii[] =
40126                   { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
40127                 int use_ascii (int i) {
40128                   return ascii_mm[i] + ascii_ii[i];
40129                 }
40130                 short int ebcdic_ii[] =
40131                   { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
40132                 short int ebcdic_mm[] =
40133                   { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
40134                 int use_ebcdic (int i) {
40135                   return ebcdic_mm[i] + ebcdic_ii[i];
40136                 }
40137                 extern int foo;
40138
40139 int
40140 main ()
40141 {
40142 return use_ascii (foo) == use_ebcdic (foo);
40143   ;
40144   return 0;
40145 }
40146 _ACEOF
40147 if ac_fn_c_try_compile "$LINENO"; then :
40148   if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
40149               ac_cv_c_bigendian=yes
40150             fi
40151             if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
40152               if test "$ac_cv_c_bigendian" = unknown; then
40153                 ac_cv_c_bigendian=no
40154               else
40155                 # finding both strings is unlikely to happen, but who knows?
40156                 ac_cv_c_bigendian=unknown
40157               fi
40158             fi
40159 fi
40160 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
40161 else
40162   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40163 /* end confdefs.h.  */
40164 $ac_includes_default
40165 int
40166 main ()
40167 {
40168
40169              /* Are we little or big endian?  From Harbison&Steele.  */
40170              union
40171              {
40172                long int l;
40173                char c[sizeof (long int)];
40174              } u;
40175              u.l = 1;
40176              return u.c[sizeof (long int) - 1] == 1;
40177
40178   ;
40179   return 0;
40180 }
40181 _ACEOF
40182 if ac_fn_c_try_run "$LINENO"; then :
40183   ac_cv_c_bigendian=no
40184 else
40185   ac_cv_c_bigendian=yes
40186 fi
40187 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
40188   conftest.$ac_objext conftest.beam conftest.$ac_ext
40189 fi
40190
40191     fi
40192 fi
40193 :
40194  case $ac_cv_c_bigendian in #(
40195    yes)
40196      gl_cv_cc_double_expbit0="word 0 bit 20";; #(
40197    no)
40198      gl_cv_cc_double_expbit0="word 1 bit 20" ;; #(
40199    universal)
40200
40201 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
40202
40203      ;; #(
40204    *)
40205      gl_cv_cc_double_expbit0="unknown" ;;
40206  esac
40207
40208
40209 fi
40210 rm -f conftest*
40211
40212
40213 else
40214   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40215 /* end confdefs.h.  */
40216
40217 #include <float.h>
40218 #include <stddef.h>
40219 #include <stdio.h>
40220 #include <string.h>
40221 #define NWORDS \
40222   ((sizeof (double) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
40223 typedef union { double value; unsigned int word[NWORDS]; } memory_double;
40224 static unsigned int ored_words[NWORDS];
40225 static unsigned int anded_words[NWORDS];
40226 static void add_to_ored_words (double x)
40227 {
40228   memory_double m;
40229   size_t i;
40230   /* Clear it first, in case sizeof (double) < sizeof (memory_double).  */
40231   memset (&m, 0, sizeof (memory_double));
40232   m.value = x;
40233   for (i = 0; i < NWORDS; i++)
40234     {
40235       ored_words[i] |= m.word[i];
40236       anded_words[i] &= m.word[i];
40237     }
40238 }
40239 int main ()
40240 {
40241   size_t j;
40242   FILE *fp = fopen ("conftest.out", "w");
40243   if (fp == NULL)
40244     return 1;
40245   for (j = 0; j < NWORDS; j++)
40246     anded_words[j] = ~ (unsigned int) 0;
40247   add_to_ored_words (0.25);
40248   add_to_ored_words (0.5);
40249   add_to_ored_words (1.0);
40250   add_to_ored_words (2.0);
40251   add_to_ored_words (4.0);
40252   /* Remove bits that are common (e.g. if representation of the first mantissa
40253      bit is explicit).  */
40254   for (j = 0; j < NWORDS; j++)
40255     ored_words[j] &= ~anded_words[j];
40256   /* Now find the nonzero word.  */
40257   for (j = 0; j < NWORDS; j++)
40258     if (ored_words[j] != 0)
40259       break;
40260   if (j < NWORDS)
40261     {
40262       size_t i;
40263       for (i = j + 1; i < NWORDS; i++)
40264         if (ored_words[i] != 0)
40265           {
40266             fprintf (fp, "unknown");
40267             return (fclose (fp) != 0);
40268           }
40269       for (i = 0; ; i++)
40270         if ((ored_words[j] >> i) & 1)
40271           {
40272             fprintf (fp, "word %d bit %d", (int) j, (int) i);
40273             return (fclose (fp) != 0);
40274           }
40275     }
40276   fprintf (fp, "unknown");
40277   return (fclose (fp) != 0);
40278 }
40279
40280 _ACEOF
40281 if ac_fn_c_try_run "$LINENO"; then :
40282   gl_cv_cc_double_expbit0=`cat conftest.out`
40283 else
40284   gl_cv_cc_double_expbit0="unknown"
40285 fi
40286 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
40287   conftest.$ac_objext conftest.beam conftest.$ac_ext
40288 fi
40289
40290       rm -f conftest.out
40291
40292 fi
40293 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_double_expbit0" >&5
40294 $as_echo "$gl_cv_cc_double_expbit0" >&6; }
40295   case "$gl_cv_cc_double_expbit0" in
40296     word*bit*)
40297       word=`echo "$gl_cv_cc_double_expbit0" | sed -e 's/word //' -e 's/ bit.*//'`
40298       bit=`echo "$gl_cv_cc_double_expbit0" | sed -e 's/word.*bit //'`
40299
40300 cat >>confdefs.h <<_ACEOF
40301 #define DBL_EXPBIT0_WORD $word
40302 _ACEOF
40303
40304
40305 cat >>confdefs.h <<_ACEOF
40306 #define DBL_EXPBIT0_BIT $bit
40307 _ACEOF
40308
40309       ;;
40310   esac
40311
40312
40313
40314   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether isnan(float) can be used without linking with libm" >&5
40315 $as_echo_n "checking whether isnan(float) can be used without linking with libm... " >&6; }
40316 if ${gl_cv_func_isnanf_no_libm+:} false; then :
40317   $as_echo_n "(cached) " >&6
40318 else
40319
40320       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40321 /* end confdefs.h.  */
40322 #include <math.h>
40323              #if __GNUC__ >= 4
40324              # undef isnanf
40325              # define isnanf(x) __builtin_isnanf ((float)(x))
40326              #elif defined isnan
40327              # undef isnanf
40328              # define isnanf(x) isnan ((float)(x))
40329              #endif
40330              float x;
40331 int
40332 main ()
40333 {
40334 return isnanf (x);
40335   ;
40336   return 0;
40337 }
40338 _ACEOF
40339 if ac_fn_c_try_link "$LINENO"; then :
40340   gl_cv_func_isnanf_no_libm=yes
40341 else
40342   gl_cv_func_isnanf_no_libm=no
40343 fi
40344 rm -f core conftest.err conftest.$ac_objext \
40345     conftest$ac_exeext conftest.$ac_ext
40346
40347 fi
40348 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_isnanf_no_libm" >&5
40349 $as_echo "$gl_cv_func_isnanf_no_libm" >&6; }
40350
40351   if test $gl_cv_func_isnanf_no_libm = yes; then
40352
40353
40354
40355   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether isnan(float) works" >&5
40356 $as_echo_n "checking whether isnan(float) works... " >&6; }
40357 if ${gl_cv_func_isnanf_works+:} false; then :
40358   $as_echo_n "(cached) " >&6
40359 else
40360
40361       if test "$cross_compiling" = yes; then :
40362   case "$host_os" in
40363            irix* | solaris*) gl_cv_func_isnanf_works="guessing no";;
40364            *)                gl_cv_func_isnanf_works="guessing yes";;
40365          esac
40366
40367 else
40368   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40369 /* end confdefs.h.  */
40370
40371 #include <math.h>
40372 #if __GNUC__ >= 4
40373 # undef isnanf
40374 # define isnanf(x) __builtin_isnanf ((float)(x))
40375 #elif defined isnan
40376 # undef isnanf
40377 # define isnanf(x) isnan ((float)(x))
40378 #endif
40379 /* The Compaq (ex-DEC) C 6.4 compiler chokes on the expression 0.0 / 0.0.  */
40380 #ifdef __DECC
40381 static float
40382 NaN ()
40383 {
40384   static float zero = 0.0f;
40385   return zero / zero;
40386 }
40387 #else
40388 # define NaN() (0.0f / 0.0f)
40389 #endif
40390 #define NWORDS \
40391   ((sizeof (float) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
40392 typedef union { unsigned int word[NWORDS]; float value; } memory_float;
40393 int main()
40394 {
40395   int result = 0;
40396
40397   if (isnanf (1.0f / 0.0f))
40398     result |= 1;
40399
40400   if (!isnanf (NaN ()))
40401     result |= 2;
40402
40403 #if defined FLT_EXPBIT0_WORD && defined FLT_EXPBIT0_BIT
40404   /* The isnanf function should be immune against changes in the sign bit and
40405      in the mantissa bits.  The xor operation twiddles a bit that can only be
40406      a sign bit or a mantissa bit.  */
40407   if (FLT_EXPBIT0_WORD == 0 && FLT_EXPBIT0_BIT > 0)
40408     {
40409       memory_float m;
40410
40411       m.value = NaN ();
40412       /* Set the bits below the exponent to 01111...111.  */
40413       m.word[0] &= -1U << FLT_EXPBIT0_BIT;
40414       m.word[0] |= 1U << (FLT_EXPBIT0_BIT - 1) - 1;
40415       if (!isnanf (m.value))
40416         result |= 4;
40417     }
40418 #endif
40419
40420   return result;
40421 }
40422 _ACEOF
40423 if ac_fn_c_try_run "$LINENO"; then :
40424   gl_cv_func_isnanf_works=yes
40425 else
40426   gl_cv_func_isnanf_works=no
40427 fi
40428 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
40429   conftest.$ac_objext conftest.beam conftest.$ac_ext
40430 fi
40431
40432
40433 fi
40434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_isnanf_works" >&5
40435 $as_echo "$gl_cv_func_isnanf_works" >&6; }
40436
40437   fi
40438   if test $gl_cv_func_isnanf_no_libm = yes \
40439      && { case "$gl_cv_func_isnanf_works" in
40440             *yes) true;;
40441             *) false;;
40442           esac
40443         }; then
40444     gl_func_isnanf_no_libm=yes
40445
40446 $as_echo "#define HAVE_ISNANF_IN_LIBC 1" >>confdefs.h
40447
40448   else
40449     gl_func_isnanf_no_libm=no
40450   fi
40451
40452   if test $gl_func_isnanf_no_libm != yes; then
40453
40454
40455
40456
40457
40458
40459
40460
40461   gltests_LIBOBJS="$gltests_LIBOBJS isnanf.$ac_objext"
40462
40463
40464
40465   { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the exponent in a 'float'" >&5
40466 $as_echo_n "checking where to find the exponent in a 'float'... " >&6; }
40467 if ${gl_cv_cc_float_expbit0+:} false; then :
40468   $as_echo_n "(cached) " >&6
40469 else
40470
40471       if test "$cross_compiling" = yes; then :
40472   gl_cv_cc_float_expbit0="word 0 bit 23"
40473 else
40474   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40475 /* end confdefs.h.  */
40476
40477 #include <float.h>
40478 #include <stddef.h>
40479 #include <stdio.h>
40480 #include <string.h>
40481 #define NWORDS \
40482   ((sizeof (float) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
40483 typedef union { float value; unsigned int word[NWORDS]; } memory_float;
40484 static unsigned int ored_words[NWORDS];
40485 static unsigned int anded_words[NWORDS];
40486 static void add_to_ored_words (float x)
40487 {
40488   memory_float m;
40489   size_t i;
40490   /* Clear it first, in case
40491      sizeof (float) < sizeof (memory_float).  */
40492   memset (&m, 0, sizeof (memory_float));
40493   m.value = x;
40494   for (i = 0; i < NWORDS; i++)
40495     {
40496       ored_words[i] |= m.word[i];
40497       anded_words[i] &= m.word[i];
40498     }
40499 }
40500 int main ()
40501 {
40502   size_t j;
40503   FILE *fp = fopen ("conftest.out", "w");
40504   if (fp == NULL)
40505     return 1;
40506   for (j = 0; j < NWORDS; j++)
40507     anded_words[j] = ~ (unsigned int) 0;
40508   add_to_ored_words (0.25f);
40509   add_to_ored_words (0.5f);
40510   add_to_ored_words (1.0f);
40511   add_to_ored_words (2.0f);
40512   add_to_ored_words (4.0f);
40513   /* Remove bits that are common (e.g. if representation of the first mantissa
40514      bit is explicit).  */
40515   for (j = 0; j < NWORDS; j++)
40516     ored_words[j] &= ~anded_words[j];
40517   /* Now find the nonzero word.  */
40518   for (j = 0; j < NWORDS; j++)
40519     if (ored_words[j] != 0)
40520       break;
40521   if (j < NWORDS)
40522     {
40523       size_t i;
40524       for (i = j + 1; i < NWORDS; i++)
40525         if (ored_words[i] != 0)
40526           {
40527             fprintf (fp, "unknown");
40528             return (fclose (fp) != 0);
40529           }
40530       for (i = 0; ; i++)
40531         if ((ored_words[j] >> i) & 1)
40532           {
40533             fprintf (fp, "word %d bit %d", (int) j, (int) i);
40534             return (fclose (fp) != 0);
40535           }
40536     }
40537   fprintf (fp, "unknown");
40538   return (fclose (fp) != 0);
40539 }
40540
40541 _ACEOF
40542 if ac_fn_c_try_run "$LINENO"; then :
40543   gl_cv_cc_float_expbit0=`cat conftest.out`
40544 else
40545   gl_cv_cc_float_expbit0="unknown"
40546 fi
40547 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
40548   conftest.$ac_objext conftest.beam conftest.$ac_ext
40549 fi
40550
40551       rm -f conftest.out
40552
40553 fi
40554 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_float_expbit0" >&5
40555 $as_echo "$gl_cv_cc_float_expbit0" >&6; }
40556   case "$gl_cv_cc_float_expbit0" in
40557     word*bit*)
40558       word=`echo "$gl_cv_cc_float_expbit0" | sed -e 's/word //' -e 's/ bit.*//'`
40559       bit=`echo "$gl_cv_cc_float_expbit0" | sed -e 's/word.*bit //'`
40560
40561 cat >>confdefs.h <<_ACEOF
40562 #define FLT_EXPBIT0_WORD $word
40563 _ACEOF
40564
40565
40566 cat >>confdefs.h <<_ACEOF
40567 #define FLT_EXPBIT0_BIT $bit
40568 _ACEOF
40569
40570       ;;
40571   esac
40572
40573
40574   fi
40575
40576   { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the exponent in a 'float'" >&5
40577 $as_echo_n "checking where to find the exponent in a 'float'... " >&6; }
40578 if ${gl_cv_cc_float_expbit0+:} false; then :
40579   $as_echo_n "(cached) " >&6
40580 else
40581
40582       if test "$cross_compiling" = yes; then :
40583   gl_cv_cc_float_expbit0="word 0 bit 23"
40584 else
40585   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40586 /* end confdefs.h.  */
40587
40588 #include <float.h>
40589 #include <stddef.h>
40590 #include <stdio.h>
40591 #include <string.h>
40592 #define NWORDS \
40593   ((sizeof (float) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
40594 typedef union { float value; unsigned int word[NWORDS]; } memory_float;
40595 static unsigned int ored_words[NWORDS];
40596 static unsigned int anded_words[NWORDS];
40597 static void add_to_ored_words (float x)
40598 {
40599   memory_float m;
40600   size_t i;
40601   /* Clear it first, in case
40602      sizeof (float) < sizeof (memory_float).  */
40603   memset (&m, 0, sizeof (memory_float));
40604   m.value = x;
40605   for (i = 0; i < NWORDS; i++)
40606     {
40607       ored_words[i] |= m.word[i];
40608       anded_words[i] &= m.word[i];
40609     }
40610 }
40611 int main ()
40612 {
40613   size_t j;
40614   FILE *fp = fopen ("conftest.out", "w");
40615   if (fp == NULL)
40616     return 1;
40617   for (j = 0; j < NWORDS; j++)
40618     anded_words[j] = ~ (unsigned int) 0;
40619   add_to_ored_words (0.25f);
40620   add_to_ored_words (0.5f);
40621   add_to_ored_words (1.0f);
40622   add_to_ored_words (2.0f);
40623   add_to_ored_words (4.0f);
40624   /* Remove bits that are common (e.g. if representation of the first mantissa
40625      bit is explicit).  */
40626   for (j = 0; j < NWORDS; j++)
40627     ored_words[j] &= ~anded_words[j];
40628   /* Now find the nonzero word.  */
40629   for (j = 0; j < NWORDS; j++)
40630     if (ored_words[j] != 0)
40631       break;
40632   if (j < NWORDS)
40633     {
40634       size_t i;
40635       for (i = j + 1; i < NWORDS; i++)
40636         if (ored_words[i] != 0)
40637           {
40638             fprintf (fp, "unknown");
40639             return (fclose (fp) != 0);
40640           }
40641       for (i = 0; ; i++)
40642         if ((ored_words[j] >> i) & 1)
40643           {
40644             fprintf (fp, "word %d bit %d", (int) j, (int) i);
40645             return (fclose (fp) != 0);
40646           }
40647     }
40648   fprintf (fp, "unknown");
40649   return (fclose (fp) != 0);
40650 }
40651
40652 _ACEOF
40653 if ac_fn_c_try_run "$LINENO"; then :
40654   gl_cv_cc_float_expbit0=`cat conftest.out`
40655 else
40656   gl_cv_cc_float_expbit0="unknown"
40657 fi
40658 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
40659   conftest.$ac_objext conftest.beam conftest.$ac_ext
40660 fi
40661
40662       rm -f conftest.out
40663
40664 fi
40665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_float_expbit0" >&5
40666 $as_echo "$gl_cv_cc_float_expbit0" >&6; }
40667   case "$gl_cv_cc_float_expbit0" in
40668     word*bit*)
40669       word=`echo "$gl_cv_cc_float_expbit0" | sed -e 's/word //' -e 's/ bit.*//'`
40670       bit=`echo "$gl_cv_cc_float_expbit0" | sed -e 's/word.*bit //'`
40671
40672 cat >>confdefs.h <<_ACEOF
40673 #define FLT_EXPBIT0_WORD $word
40674 _ACEOF
40675
40676
40677 cat >>confdefs.h <<_ACEOF
40678 #define FLT_EXPBIT0_BIT $bit
40679 _ACEOF
40680
40681       ;;
40682   esac
40683
40684
40685
40686   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether isnan(long double) can be used without linking with libm" >&5
40687 $as_echo_n "checking whether isnan(long double) can be used without linking with libm... " >&6; }
40688 if ${gl_cv_func_isnanl_no_libm+:} false; then :
40689   $as_echo_n "(cached) " >&6
40690 else
40691
40692       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40693 /* end confdefs.h.  */
40694 #include <math.h>
40695              #if __GNUC__ >= 4
40696              # undef isnanl
40697              # define isnanl(x) __builtin_isnanl ((long double)(x))
40698              #elif defined isnan
40699              # undef isnanl
40700              # define isnanl(x) isnan ((long double)(x))
40701              #endif
40702              long double x;
40703 int
40704 main ()
40705 {
40706 return isnanl (x);
40707   ;
40708   return 0;
40709 }
40710 _ACEOF
40711 if ac_fn_c_try_link "$LINENO"; then :
40712   gl_cv_func_isnanl_no_libm=yes
40713 else
40714   gl_cv_func_isnanl_no_libm=no
40715 fi
40716 rm -f core conftest.err conftest.$ac_objext \
40717     conftest$ac_exeext conftest.$ac_ext
40718
40719 fi
40720 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_isnanl_no_libm" >&5
40721 $as_echo "$gl_cv_func_isnanl_no_libm" >&6; }
40722
40723   gl_func_isnanl_no_libm=$gl_cv_func_isnanl_no_libm
40724   if test $gl_func_isnanl_no_libm = yes; then
40725
40726
40727
40728
40729      { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether isnanl works" >&5
40730 $as_echo_n "checking whether isnanl works... " >&6; }
40731 if ${gl_cv_func_isnanl_works+:} false; then :
40732   $as_echo_n "(cached) " >&6
40733 else
40734
40735       if test "$cross_compiling" = yes; then :
40736   case "$host_cpu" in
40737                                  # Guess no on ia64, x86_64, i386.
40738            ia64 | x86_64 | i*86) gl_cv_func_isnanl_works="guessing no";;
40739            *)
40740              case "$host_os" in
40741                netbsd*) gl_cv_func_isnanl_works="guessing no";;
40742                *)       gl_cv_func_isnanl_works="guessing yes";;
40743              esac
40744              ;;
40745          esac
40746
40747 else
40748   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40749 /* end confdefs.h.  */
40750
40751 #include <float.h>
40752 #include <limits.h>
40753 #include <math.h>
40754 #if __GNUC__ >= 4
40755 # undef isnanl
40756 # define isnanl(x) __builtin_isnanl ((long double)(x))
40757 #elif defined isnan
40758 # undef isnanl
40759 # define isnanl(x) isnan ((long double)(x))
40760 #endif
40761 #define NWORDS \
40762   ((sizeof (long double) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
40763 typedef union { unsigned int word[NWORDS]; long double value; }
40764         memory_long_double;
40765 /* On Irix 6.5, gcc 3.4.3 can't compute compile-time NaN, and needs the
40766    runtime type conversion.  */
40767 #ifdef __sgi
40768 static long double NaNl ()
40769 {
40770   double zero = 0.0;
40771   return zero / zero;
40772 }
40773 #else
40774 # define NaNl() (0.0L / 0.0L)
40775 #endif
40776 int main ()
40777 {
40778   int result = 0;
40779
40780   if (!isnanl (NaNl ()))
40781     result |= 1;
40782
40783   {
40784     memory_long_double m;
40785     unsigned int i;
40786
40787     /* The isnanl function should be immune against changes in the sign bit and
40788        in the mantissa bits.  The xor operation twiddles a bit that can only be
40789        a sign bit or a mantissa bit (since the exponent never extends to
40790        bit 31).  */
40791     m.value = NaNl ();
40792     m.word[NWORDS / 2] ^= (unsigned int) 1 << (sizeof (unsigned int) * CHAR_BIT - 1);
40793     for (i = 0; i < NWORDS; i++)
40794       m.word[i] |= 1;
40795     if (!isnanl (m.value))
40796       result |= 1;
40797   }
40798
40799 #if ((defined __ia64 && LDBL_MANT_DIG == 64) || (defined __x86_64__ || defined __amd64__) || (defined __i386 || defined __i386__ || defined _I386 || defined _M_IX86 || defined _X86_)) && !HAVE_SAME_LONG_DOUBLE_AS_DOUBLE
40800 /* Representation of an 80-bit 'long double' as an initializer for a sequence
40801    of 'unsigned int' words.  */
40802 # ifdef WORDS_BIGENDIAN
40803 #  define LDBL80_WORDS(exponent,manthi,mantlo) \
40804      { ((unsigned int) (exponent) << 16) | ((unsigned int) (manthi) >> 16), \
40805        ((unsigned int) (manthi) << 16) | (unsigned int) (mantlo) >> 16),    \
40806        (unsigned int) (mantlo) << 16                                        \
40807      }
40808 # else
40809 #  define LDBL80_WORDS(exponent,manthi,mantlo) \
40810      { mantlo, manthi, exponent }
40811 # endif
40812   { /* Quiet NaN.  */
40813     static memory_long_double x =
40814       { LDBL80_WORDS (0xFFFF, 0xC3333333, 0x00000000) };
40815     if (!isnanl (x.value))
40816       result |= 2;
40817   }
40818   {
40819     /* Signalling NaN.  */
40820     static memory_long_double x =
40821       { LDBL80_WORDS (0xFFFF, 0x83333333, 0x00000000) };
40822     if (!isnanl (x.value))
40823       result |= 2;
40824   }
40825   /* The isnanl function should recognize Pseudo-NaNs, Pseudo-Infinities,
40826      Pseudo-Zeroes, Unnormalized Numbers, and Pseudo-Denormals, as defined in
40827        Intel IA-64 Architecture Software Developer's Manual, Volume 1:
40828        Application Architecture.
40829        Table 5-2 "Floating-Point Register Encodings"
40830        Figure 5-6 "Memory to Floating-Point Register Data Translation"
40831    */
40832   { /* Pseudo-NaN.  */
40833     static memory_long_double x =
40834       { LDBL80_WORDS (0xFFFF, 0x40000001, 0x00000000) };
40835     if (!isnanl (x.value))
40836       result |= 4;
40837   }
40838   { /* Pseudo-Infinity.  */
40839     static memory_long_double x =
40840       { LDBL80_WORDS (0xFFFF, 0x00000000, 0x00000000) };
40841     if (!isnanl (x.value))
40842       result |= 8;
40843   }
40844   { /* Pseudo-Zero.  */
40845     static memory_long_double x =
40846       { LDBL80_WORDS (0x4004, 0x00000000, 0x00000000) };
40847     if (!isnanl (x.value))
40848       result |= 16;
40849   }
40850   { /* Unnormalized number.  */
40851     static memory_long_double x =
40852       { LDBL80_WORDS (0x4000, 0x63333333, 0x00000000) };
40853     if (!isnanl (x.value))
40854       result |= 32;
40855   }
40856   { /* Pseudo-Denormal.  */
40857     static memory_long_double x =
40858       { LDBL80_WORDS (0x0000, 0x83333333, 0x00000000) };
40859     if (!isnanl (x.value))
40860       result |= 64;
40861   }
40862 #endif
40863
40864   return result;
40865 }
40866 _ACEOF
40867 if ac_fn_c_try_run "$LINENO"; then :
40868   gl_cv_func_isnanl_works=yes
40869 else
40870   gl_cv_func_isnanl_works=no
40871 fi
40872 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
40873   conftest.$ac_objext conftest.beam conftest.$ac_ext
40874 fi
40875
40876
40877 fi
40878 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_isnanl_works" >&5
40879 $as_echo "$gl_cv_func_isnanl_works" >&6; }
40880
40881     case "$gl_cv_func_isnanl_works" in
40882       *yes) ;;
40883       *)    gl_func_isnanl_no_libm=no ;;
40884     esac
40885   fi
40886   if test $gl_func_isnanl_no_libm = yes; then
40887
40888 $as_echo "#define HAVE_ISNANL_IN_LIBC 1" >>confdefs.h
40889
40890   fi
40891
40892   if test $gl_func_isnanl_no_libm != yes; then
40893
40894
40895
40896
40897
40898
40899
40900
40901   gltests_LIBOBJS="$gltests_LIBOBJS isnanl.$ac_objext"
40902
40903
40904
40905
40906   { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the exponent in a 'long double'" >&5
40907 $as_echo_n "checking where to find the exponent in a 'long double'... " >&6; }
40908 if ${gl_cv_cc_long_double_expbit0+:} false; then :
40909   $as_echo_n "(cached) " >&6
40910 else
40911
40912       if test "$cross_compiling" = yes; then :
40913
40914                               gl_cv_cc_long_double_expbit0="unknown"
40915
40916 else
40917   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40918 /* end confdefs.h.  */
40919
40920 #include <float.h>
40921 #include <stddef.h>
40922 #include <stdio.h>
40923 #include <string.h>
40924 #define NWORDS \
40925   ((sizeof (long double) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
40926 typedef union { long double value; unsigned int word[NWORDS]; }
40927         memory_long_double;
40928 static unsigned int ored_words[NWORDS];
40929 static unsigned int anded_words[NWORDS];
40930 static void add_to_ored_words (long double x)
40931 {
40932   memory_long_double m;
40933   size_t i;
40934   /* Clear it first, in case
40935      sizeof (long double) < sizeof (memory_long_double).  */
40936   memset (&m, 0, sizeof (memory_long_double));
40937   m.value = x;
40938   for (i = 0; i < NWORDS; i++)
40939     {
40940       ored_words[i] |= m.word[i];
40941       anded_words[i] &= m.word[i];
40942     }
40943 }
40944 int main ()
40945 {
40946   size_t j;
40947   FILE *fp = fopen ("conftest.out", "w");
40948   if (fp == NULL)
40949     return 1;
40950   for (j = 0; j < NWORDS; j++)
40951     anded_words[j] = ~ (unsigned int) 0;
40952   add_to_ored_words (0.25L);
40953   add_to_ored_words (0.5L);
40954   add_to_ored_words (1.0L);
40955   add_to_ored_words (2.0L);
40956   add_to_ored_words (4.0L);
40957   /* Remove bits that are common (e.g. if representation of the first mantissa
40958      bit is explicit).  */
40959   for (j = 0; j < NWORDS; j++)
40960     ored_words[j] &= ~anded_words[j];
40961   /* Now find the nonzero word.  */
40962   for (j = 0; j < NWORDS; j++)
40963     if (ored_words[j] != 0)
40964       break;
40965   if (j < NWORDS)
40966     {
40967       size_t i;
40968       for (i = j + 1; i < NWORDS; i++)
40969         if (ored_words[i] != 0)
40970           {
40971             fprintf (fp, "unknown");
40972             return (fclose (fp) != 0);
40973           }
40974       for (i = 0; ; i++)
40975         if ((ored_words[j] >> i) & 1)
40976           {
40977             fprintf (fp, "word %d bit %d", (int) j, (int) i);
40978             return (fclose (fp) != 0);
40979           }
40980     }
40981   fprintf (fp, "unknown");
40982   return (fclose (fp) != 0);
40983 }
40984
40985 _ACEOF
40986 if ac_fn_c_try_run "$LINENO"; then :
40987   gl_cv_cc_long_double_expbit0=`cat conftest.out`
40988 else
40989   gl_cv_cc_long_double_expbit0="unknown"
40990 fi
40991 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
40992   conftest.$ac_objext conftest.beam conftest.$ac_ext
40993 fi
40994
40995       rm -f conftest.out
40996
40997 fi
40998 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_long_double_expbit0" >&5
40999 $as_echo "$gl_cv_cc_long_double_expbit0" >&6; }
41000   case "$gl_cv_cc_long_double_expbit0" in
41001     word*bit*)
41002       word=`echo "$gl_cv_cc_long_double_expbit0" | sed -e 's/word //' -e 's/ bit.*//'`
41003       bit=`echo "$gl_cv_cc_long_double_expbit0" | sed -e 's/word.*bit //'`
41004
41005 cat >>confdefs.h <<_ACEOF
41006 #define LDBL_EXPBIT0_WORD $word
41007 _ACEOF
41008
41009
41010 cat >>confdefs.h <<_ACEOF
41011 #define LDBL_EXPBIT0_BIT $bit
41012 _ACEOF
41013
41014       ;;
41015   esac
41016
41017
41018
41019   fi
41020
41021
41022   { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the exponent in a 'long double'" >&5
41023 $as_echo_n "checking where to find the exponent in a 'long double'... " >&6; }
41024 if ${gl_cv_cc_long_double_expbit0+:} false; then :
41025   $as_echo_n "(cached) " >&6
41026 else
41027
41028       if test "$cross_compiling" = yes; then :
41029
41030                               gl_cv_cc_long_double_expbit0="unknown"
41031
41032 else
41033   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41034 /* end confdefs.h.  */
41035
41036 #include <float.h>
41037 #include <stddef.h>
41038 #include <stdio.h>
41039 #include <string.h>
41040 #define NWORDS \
41041   ((sizeof (long double) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
41042 typedef union { long double value; unsigned int word[NWORDS]; }
41043         memory_long_double;
41044 static unsigned int ored_words[NWORDS];
41045 static unsigned int anded_words[NWORDS];
41046 static void add_to_ored_words (long double x)
41047 {
41048   memory_long_double m;
41049   size_t i;
41050   /* Clear it first, in case
41051      sizeof (long double) < sizeof (memory_long_double).  */
41052   memset (&m, 0, sizeof (memory_long_double));
41053   m.value = x;
41054   for (i = 0; i < NWORDS; i++)
41055     {
41056       ored_words[i] |= m.word[i];
41057       anded_words[i] &= m.word[i];
41058     }
41059 }
41060 int main ()
41061 {
41062   size_t j;
41063   FILE *fp = fopen ("conftest.out", "w");
41064   if (fp == NULL)
41065     return 1;
41066   for (j = 0; j < NWORDS; j++)
41067     anded_words[j] = ~ (unsigned int) 0;
41068   add_to_ored_words (0.25L);
41069   add_to_ored_words (0.5L);
41070   add_to_ored_words (1.0L);
41071   add_to_ored_words (2.0L);
41072   add_to_ored_words (4.0L);
41073   /* Remove bits that are common (e.g. if representation of the first mantissa
41074      bit is explicit).  */
41075   for (j = 0; j < NWORDS; j++)
41076     ored_words[j] &= ~anded_words[j];
41077   /* Now find the nonzero word.  */
41078   for (j = 0; j < NWORDS; j++)
41079     if (ored_words[j] != 0)
41080       break;
41081   if (j < NWORDS)
41082     {
41083       size_t i;
41084       for (i = j + 1; i < NWORDS; i++)
41085         if (ored_words[i] != 0)
41086           {
41087             fprintf (fp, "unknown");
41088             return (fclose (fp) != 0);
41089           }
41090       for (i = 0; ; i++)
41091         if ((ored_words[j] >> i) & 1)
41092           {
41093             fprintf (fp, "word %d bit %d", (int) j, (int) i);
41094             return (fclose (fp) != 0);
41095           }
41096     }
41097   fprintf (fp, "unknown");
41098   return (fclose (fp) != 0);
41099 }
41100
41101 _ACEOF
41102 if ac_fn_c_try_run "$LINENO"; then :
41103   gl_cv_cc_long_double_expbit0=`cat conftest.out`
41104 else
41105   gl_cv_cc_long_double_expbit0="unknown"
41106 fi
41107 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
41108   conftest.$ac_objext conftest.beam conftest.$ac_ext
41109 fi
41110
41111       rm -f conftest.out
41112
41113 fi
41114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_long_double_expbit0" >&5
41115 $as_echo "$gl_cv_cc_long_double_expbit0" >&6; }
41116   case "$gl_cv_cc_long_double_expbit0" in
41117     word*bit*)
41118       word=`echo "$gl_cv_cc_long_double_expbit0" | sed -e 's/word //' -e 's/ bit.*//'`
41119       bit=`echo "$gl_cv_cc_long_double_expbit0" | sed -e 's/word.*bit //'`
41120
41121 cat >>confdefs.h <<_ACEOF
41122 #define LDBL_EXPBIT0_WORD $word
41123 _ACEOF
41124
41125
41126 cat >>confdefs.h <<_ACEOF
41127 #define LDBL_EXPBIT0_BIT $bit
41128 _ACEOF
41129
41130       ;;
41131   esac
41132
41133
41134
41135   :
41136
41137
41138
41139
41140
41141
41142
41143
41144   for ac_func in setlocale uselocale
41145 do :
41146   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
41147 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
41148 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
41149   cat >>confdefs.h <<_ACEOF
41150 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
41151 _ACEOF
41152
41153 fi
41154 done
41155
41156
41157
41158   :
41159
41160
41161
41162
41163
41164
41165
41166
41167
41168
41169
41170
41171
41172   :
41173
41174
41175
41176
41177
41178
41179
41180
41181      if test $gl_cv_have_include_next = yes; then
41182        gl_cv_next_math_h='<'math.h'>'
41183      else
41184        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <math.h>" >&5
41185 $as_echo_n "checking absolute name of <math.h>... " >&6; }
41186 if ${gl_cv_next_math_h+:} false; then :
41187   $as_echo_n "(cached) " >&6
41188 else
41189
41190              if test $ac_cv_header_math_h = yes; then
41191
41192
41193
41194
41195   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41196 /* end confdefs.h.  */
41197 #include <math.h>
41198 _ACEOF
41199                 case "$host_os" in
41200     aix*) gl_absname_cpp="$ac_cpp -C" ;;
41201     *)    gl_absname_cpp="$ac_cpp" ;;
41202   esac
41203
41204   case "$host_os" in
41205     mingw*)
41206                                           gl_dirsep_regex='[/\\]'
41207       ;;
41208     *)
41209       gl_dirsep_regex='\/'
41210       ;;
41211   esac
41212       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
41213   gl_header_literal_regex=`echo 'math.h' \
41214                            | sed -e "$gl_make_literal_regex_sed"`
41215   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
41216       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
41217       s|^/[^/]|//&|
41218       p
41219       q
41220     }'
41221
41222         gl_cv_absolute_math_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
41223   sed -n "$gl_absolute_header_sed"`
41224
41225            gl_header=$gl_cv_absolute_math_h
41226            gl_cv_next_math_h='"'$gl_header'"'
41227           else
41228                gl_cv_next_math_h='<'math.h'>'
41229              fi
41230
41231
41232 fi
41233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_math_h" >&5
41234 $as_echo "$gl_cv_next_math_h" >&6; }
41235      fi
41236      NEXT_MATH_H=$gl_cv_next_math_h
41237
41238      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
41239        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
41240        gl_next_as_first_directive='<'math.h'>'
41241      else
41242        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
41243        gl_next_as_first_directive=$gl_cv_next_math_h
41244      fi
41245      NEXT_AS_FIRST_DIRECTIVE_MATH_H=$gl_next_as_first_directive
41246
41247
41248
41249
41250
41251   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NAN macro works" >&5
41252 $as_echo_n "checking whether NAN macro works... " >&6; }
41253 if ${gl_cv_header_math_nan_works+:} false; then :
41254   $as_echo_n "(cached) " >&6
41255 else
41256   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41257 /* end confdefs.h.  */
41258 #include <math.h>
41259 int
41260 main ()
41261 {
41262 /* Solaris 10 has a broken definition of NAN.  Other platforms
41263         fail to provide NAN, or provide it only in C99 mode; this
41264         test only needs to fail when NAN is provided but wrong.  */
41265          float f = 1.0f;
41266 #ifdef NAN
41267          f = NAN;
41268 #endif
41269          return f == 0;
41270   ;
41271   return 0;
41272 }
41273 _ACEOF
41274 if ac_fn_c_try_compile "$LINENO"; then :
41275   gl_cv_header_math_nan_works=yes
41276 else
41277   gl_cv_header_math_nan_works=no
41278 fi
41279 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41280 fi
41281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_math_nan_works" >&5
41282 $as_echo "$gl_cv_header_math_nan_works" >&6; }
41283   if test $gl_cv_header_math_nan_works = no; then
41284     REPLACE_NAN=1
41285   fi
41286   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether HUGE_VAL works" >&5
41287 $as_echo_n "checking whether HUGE_VAL works... " >&6; }
41288 if ${gl_cv_header_math_huge_val_works+:} false; then :
41289   $as_echo_n "(cached) " >&6
41290 else
41291   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41292 /* end confdefs.h.  */
41293 #include <math.h>
41294 int
41295 main ()
41296 {
41297 /* Solaris 10 has a broken definition of HUGE_VAL.  */
41298          double d = HUGE_VAL;
41299          return d == 0;
41300   ;
41301   return 0;
41302 }
41303 _ACEOF
41304 if ac_fn_c_try_compile "$LINENO"; then :
41305   gl_cv_header_math_huge_val_works=yes
41306 else
41307   gl_cv_header_math_huge_val_works=no
41308 fi
41309 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
41310 fi
41311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_math_huge_val_works" >&5
41312 $as_echo "$gl_cv_header_math_huge_val_works" >&6; }
41313   if test $gl_cv_header_math_huge_val_works = no; then
41314     REPLACE_HUGE_VAL=1
41315   fi
41316
41317
41318
41319
41320
41321
41322   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a traditional french locale" >&5
41323 $as_echo_n "checking for a traditional french locale... " >&6; }
41324 if ${gt_cv_locale_fr+:} false; then :
41325   $as_echo_n "(cached) " >&6
41326 else
41327
41328     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41329 /* end confdefs.h.  */
41330
41331 #include <locale.h>
41332 #include <time.h>
41333 #if HAVE_LANGINFO_CODESET
41334 # include <langinfo.h>
41335 #endif
41336 #include <stdlib.h>
41337 #include <string.h>
41338 struct tm t;
41339 char buf[16];
41340 int main () {
41341   /* Check whether the given locale name is recognized by the system.  */
41342 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
41343   /* On native Windows, setlocale(category, "") looks at the system settings,
41344      not at the environment variables.  Also, when an encoding suffix such
41345      as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
41346      category of the locale to "C".  */
41347   if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
41348       || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
41349     return 1;
41350 #else
41351   if (setlocale (LC_ALL, "") == NULL) return 1;
41352 #endif
41353   /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
41354      On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
41355      is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
41356      On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
41357      succeeds but then nl_langinfo(CODESET) is "646". In this situation,
41358      some unit tests fail.
41359      On MirBSD 10, when an unsupported locale is specified, setlocale()
41360      succeeds but then nl_langinfo(CODESET) is "UTF-8".  */
41361 #if HAVE_LANGINFO_CODESET
41362   {
41363     const char *cs = nl_langinfo (CODESET);
41364     if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
41365         || strcmp (cs, "UTF-8") == 0)
41366       return 1;
41367   }
41368 #endif
41369 #ifdef __CYGWIN__
41370   /* On Cygwin, avoid locale names without encoding suffix, because the
41371      locale_charset() function relies on the encoding suffix.  Note that
41372      LC_ALL is set on the command line.  */
41373   if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
41374 #endif
41375   /* Check whether in the abbreviation of the second month, the second
41376      character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is only
41377      one byte long. This excludes the UTF-8 encoding.  */
41378   t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
41379   if (strftime (buf, sizeof (buf), "%b", &t) < 3 || buf[2] != 'v') return 1;
41380 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy.  */
41381   /* Check whether the decimal separator is a comma.
41382      On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
41383      are nl_langinfo(RADIXCHAR) are both ".".  */
41384   if (localeconv () ->decimal_point[0] != ',') return 1;
41385 #endif
41386   return 0;
41387 }
41388
41389 _ACEOF
41390     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
41391   (eval $ac_link) 2>&5
41392   ac_status=$?
41393   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
41394   test $ac_status = 0; } && test -s conftest$ac_exeext; then
41395       case "$host_os" in
41396         # Handle native Windows specially, because there setlocale() interprets
41397         # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
41398         # "fr" or "fra" as "French" or "French_France.1252",
41399         # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
41400         # "ja" as "Japanese" or "Japanese_Japan.932",
41401         # and similar.
41402         mingw*)
41403           # Test for the native Windows locale name.
41404           if (LC_ALL=French_France.1252 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
41405             gt_cv_locale_fr=French_France.1252
41406           else
41407             # None found.
41408             gt_cv_locale_fr=none
41409           fi
41410           ;;
41411         *)
41412           # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
41413           # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
41414           # configure script would override the LC_ALL setting. Likewise for
41415           # LC_CTYPE, which is also set at the beginning of the configure script.
41416           # Test for the usual locale name.
41417           if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
41418             gt_cv_locale_fr=fr_FR
41419           else
41420             # Test for the locale name with explicit encoding suffix.
41421             if (LC_ALL=fr_FR.ISO-8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
41422               gt_cv_locale_fr=fr_FR.ISO-8859-1
41423             else
41424               # Test for the AIX, OSF/1, FreeBSD, NetBSD, OpenBSD locale name.
41425               if (LC_ALL=fr_FR.ISO8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
41426                 gt_cv_locale_fr=fr_FR.ISO8859-1
41427               else
41428                 # Test for the HP-UX locale name.
41429                 if (LC_ALL=fr_FR.iso88591 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
41430                   gt_cv_locale_fr=fr_FR.iso88591
41431                 else
41432                   # Test for the Solaris 7 locale name.
41433                   if (LC_ALL=fr LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
41434                     gt_cv_locale_fr=fr
41435                   else
41436                     # None found.
41437                     gt_cv_locale_fr=none
41438                   fi
41439                 fi
41440               fi
41441             fi
41442           fi
41443           ;;
41444       esac
41445     fi
41446     rm -fr conftest*
41447
41448 fi
41449 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr" >&5
41450 $as_echo "$gt_cv_locale_fr" >&6; }
41451   LOCALE_FR=$gt_cv_locale_fr
41452
41453
41454
41455
41456   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a french Unicode locale" >&5
41457 $as_echo_n "checking for a french Unicode locale... " >&6; }
41458 if ${gt_cv_locale_fr_utf8+:} false; then :
41459   $as_echo_n "(cached) " >&6
41460 else
41461
41462     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41463 /* end confdefs.h.  */
41464
41465 #include <locale.h>
41466 #include <time.h>
41467 #if HAVE_LANGINFO_CODESET
41468 # include <langinfo.h>
41469 #endif
41470 #include <stdlib.h>
41471 #include <string.h>
41472 struct tm t;
41473 char buf[16];
41474 int main () {
41475   /* On BeOS and Haiku, locales are not implemented in libc.  Rather, libintl
41476      imitates locale dependent behaviour by looking at the environment
41477      variables, and all locales use the UTF-8 encoding.  */
41478 #if !(defined __BEOS__ || defined __HAIKU__)
41479   /* Check whether the given locale name is recognized by the system.  */
41480 # if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
41481   /* On native Windows, setlocale(category, "") looks at the system settings,
41482      not at the environment variables.  Also, when an encoding suffix such
41483      as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
41484      category of the locale to "C".  */
41485   if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
41486       || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
41487     return 1;
41488 # else
41489   if (setlocale (LC_ALL, "") == NULL) return 1;
41490 # endif
41491   /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
41492      On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
41493      is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
41494      On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
41495      succeeds but then nl_langinfo(CODESET) is "646". In this situation,
41496      some unit tests fail.  */
41497 # if HAVE_LANGINFO_CODESET
41498   {
41499     const char *cs = nl_langinfo (CODESET);
41500     if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0)
41501       return 1;
41502   }
41503 # endif
41504 # ifdef __CYGWIN__
41505   /* On Cygwin, avoid locale names without encoding suffix, because the
41506      locale_charset() function relies on the encoding suffix.  Note that
41507      LC_ALL is set on the command line.  */
41508   if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
41509 # endif
41510   /* Check whether in the abbreviation of the second month, the second
41511      character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is
41512      two bytes long, with UTF-8 encoding.  */
41513   t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
41514   if (strftime (buf, sizeof (buf), "%b", &t) < 4
41515       || buf[1] != (char) 0xc3 || buf[2] != (char) 0xa9 || buf[3] != 'v')
41516     return 1;
41517 #endif
41518 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy.  */
41519   /* Check whether the decimal separator is a comma.
41520      On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
41521      are nl_langinfo(RADIXCHAR) are both ".".  */
41522   if (localeconv () ->decimal_point[0] != ',') return 1;
41523 #endif
41524   return 0;
41525 }
41526
41527 _ACEOF
41528     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
41529   (eval $ac_link) 2>&5
41530   ac_status=$?
41531   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
41532   test $ac_status = 0; } && test -s conftest$ac_exeext; then
41533       case "$host_os" in
41534         # Handle native Windows specially, because there setlocale() interprets
41535         # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
41536         # "fr" or "fra" as "French" or "French_France.1252",
41537         # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
41538         # "ja" as "Japanese" or "Japanese_Japan.932",
41539         # and similar.
41540         mingw*)
41541           # Test for the hypothetical native Windows locale name.
41542           if (LC_ALL=French_France.65001 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
41543             gt_cv_locale_fr_utf8=French_France.65001
41544           else
41545             # None found.
41546             gt_cv_locale_fr_utf8=none
41547           fi
41548           ;;
41549         *)
41550           # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
41551           # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
41552           # configure script would override the LC_ALL setting. Likewise for
41553           # LC_CTYPE, which is also set at the beginning of the configure script.
41554           # Test for the usual locale name.
41555           if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
41556             gt_cv_locale_fr_utf8=fr_FR
41557           else
41558             # Test for the locale name with explicit encoding suffix.
41559             if (LC_ALL=fr_FR.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
41560               gt_cv_locale_fr_utf8=fr_FR.UTF-8
41561             else
41562               # Test for the Solaris 7 locale name.
41563               if (LC_ALL=fr.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
41564                 gt_cv_locale_fr_utf8=fr.UTF-8
41565               else
41566                 # None found.
41567                 gt_cv_locale_fr_utf8=none
41568               fi
41569             fi
41570           fi
41571           ;;
41572       esac
41573     fi
41574     rm -fr conftest*
41575
41576 fi
41577 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr_utf8" >&5
41578 $as_echo "$gt_cv_locale_fr_utf8" >&6; }
41579   LOCALE_FR_UTF8=$gt_cv_locale_fr_utf8
41580
41581
41582
41583
41584
41585   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a traditional japanese locale" >&5
41586 $as_echo_n "checking for a traditional japanese locale... " >&6; }
41587 if ${gt_cv_locale_ja+:} false; then :
41588   $as_echo_n "(cached) " >&6
41589 else
41590
41591     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41592 /* end confdefs.h.  */
41593
41594 #include <locale.h>
41595 #include <time.h>
41596 #if HAVE_LANGINFO_CODESET
41597 # include <langinfo.h>
41598 #endif
41599 #include <stdlib.h>
41600 #include <string.h>
41601 struct tm t;
41602 char buf[16];
41603 int main ()
41604 {
41605   const char *p;
41606   /* Check whether the given locale name is recognized by the system.  */
41607 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
41608   /* On native Windows, setlocale(category, "") looks at the system settings,
41609      not at the environment variables.  Also, when an encoding suffix such
41610      as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
41611      category of the locale to "C".  */
41612   if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
41613       || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
41614     return 1;
41615 #else
41616   if (setlocale (LC_ALL, "") == NULL) return 1;
41617 #endif
41618   /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
41619      On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
41620      is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
41621      On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
41622      succeeds but then nl_langinfo(CODESET) is "646". In this situation,
41623      some unit tests fail.
41624      On MirBSD 10, when an unsupported locale is specified, setlocale()
41625      succeeds but then nl_langinfo(CODESET) is "UTF-8".  */
41626 #if HAVE_LANGINFO_CODESET
41627   {
41628     const char *cs = nl_langinfo (CODESET);
41629     if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
41630         || strcmp (cs, "UTF-8") == 0)
41631       return 1;
41632   }
41633 #endif
41634 #ifdef __CYGWIN__
41635   /* On Cygwin, avoid locale names without encoding suffix, because the
41636      locale_charset() function relies on the encoding suffix.  Note that
41637      LC_ALL is set on the command line.  */
41638   if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
41639 #endif
41640   /* Check whether MB_CUR_MAX is > 1.  This excludes the dysfunctional locales
41641      on Cygwin 1.5.x.  */
41642   if (MB_CUR_MAX == 1)
41643     return 1;
41644   /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
41645      This excludes the UTF-8 encoding (except on MirBSD).  */
41646   t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
41647   if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
41648   for (p = buf; *p != '\0'; p++)
41649     if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
41650       return 1;
41651   return 0;
41652 }
41653
41654 _ACEOF
41655     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
41656   (eval $ac_link) 2>&5
41657   ac_status=$?
41658   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
41659   test $ac_status = 0; } && test -s conftest$ac_exeext; then
41660       case "$host_os" in
41661         # Handle native Windows specially, because there setlocale() interprets
41662         # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
41663         # "fr" or "fra" as "French" or "French_France.1252",
41664         # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
41665         # "ja" as "Japanese" or "Japanese_Japan.932",
41666         # and similar.
41667         mingw*)
41668           # Note that on native Windows, the Japanese locale is
41669           # Japanese_Japan.932, and CP932 is very different from EUC-JP, so we
41670           # cannot use it here.
41671           gt_cv_locale_ja=none
41672           ;;
41673         *)
41674           # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
41675           # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
41676           # configure script would override the LC_ALL setting. Likewise for
41677           # LC_CTYPE, which is also set at the beginning of the configure script.
41678           # Test for the AIX locale name.
41679           if (LC_ALL=ja_JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
41680             gt_cv_locale_ja=ja_JP
41681           else
41682             # Test for the locale name with explicit encoding suffix.
41683             if (LC_ALL=ja_JP.EUC-JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
41684               gt_cv_locale_ja=ja_JP.EUC-JP
41685             else
41686               # Test for the HP-UX, OSF/1, NetBSD locale name.
41687               if (LC_ALL=ja_JP.eucJP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
41688                 gt_cv_locale_ja=ja_JP.eucJP
41689               else
41690                 # Test for the IRIX, FreeBSD locale name.
41691                 if (LC_ALL=ja_JP.EUC LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
41692                   gt_cv_locale_ja=ja_JP.EUC
41693                 else
41694                   # Test for the Solaris 7 locale name.
41695                   if (LC_ALL=ja LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
41696                     gt_cv_locale_ja=ja
41697                   else
41698                     # Special test for NetBSD 1.6.
41699                     if test -f /usr/share/locale/ja_JP.eucJP/LC_CTYPE; then
41700                       gt_cv_locale_ja=ja_JP.eucJP
41701                     else
41702                       # None found.
41703                       gt_cv_locale_ja=none
41704                     fi
41705                   fi
41706                 fi
41707               fi
41708             fi
41709           fi
41710           ;;
41711       esac
41712     fi
41713     rm -fr conftest*
41714
41715 fi
41716 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_ja" >&5
41717 $as_echo "$gt_cv_locale_ja" >&6; }
41718   LOCALE_JA=$gt_cv_locale_ja
41719
41720
41721
41722
41723
41724   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a transitional chinese locale" >&5
41725 $as_echo_n "checking for a transitional chinese locale... " >&6; }
41726 if ${gt_cv_locale_zh_CN+:} false; then :
41727   $as_echo_n "(cached) " >&6
41728 else
41729
41730     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41731 /* end confdefs.h.  */
41732
41733 #include <locale.h>
41734 #include <stdlib.h>
41735 #include <time.h>
41736 #if HAVE_LANGINFO_CODESET
41737 # include <langinfo.h>
41738 #endif
41739 #include <stdlib.h>
41740 #include <string.h>
41741 struct tm t;
41742 char buf[16];
41743 int main ()
41744 {
41745   const char *p;
41746   /* Check whether the given locale name is recognized by the system.  */
41747 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
41748   /* On native Windows, setlocale(category, "") looks at the system settings,
41749      not at the environment variables.  Also, when an encoding suffix such
41750      as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
41751      category of the locale to "C".  */
41752   if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
41753       || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
41754     return 1;
41755 #else
41756   if (setlocale (LC_ALL, "") == NULL) return 1;
41757 #endif
41758   /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
41759      On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
41760      is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
41761      On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
41762      succeeds but then nl_langinfo(CODESET) is "646". In this situation,
41763      some unit tests fail.
41764      On MirBSD 10, when an unsupported locale is specified, setlocale()
41765      succeeds but then nl_langinfo(CODESET) is "UTF-8".  */
41766 #if HAVE_LANGINFO_CODESET
41767   {
41768     const char *cs = nl_langinfo (CODESET);
41769     if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
41770         || strcmp (cs, "UTF-8") == 0)
41771       return 1;
41772   }
41773 #endif
41774 #ifdef __CYGWIN__
41775   /* On Cygwin, avoid locale names without encoding suffix, because the
41776      locale_charset() function relies on the encoding suffix.  Note that
41777      LC_ALL is set on the command line.  */
41778   if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
41779 #endif
41780   /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
41781      This excludes the UTF-8 encoding (except on MirBSD).  */
41782   t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
41783   if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
41784   for (p = buf; *p != '\0'; p++)
41785     if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
41786       return 1;
41787   /* Check whether a typical GB18030 multibyte sequence is recognized as a
41788      single wide character.  This excludes the GB2312 and GBK encodings.  */
41789   if (mblen ("\203\062\332\066", 5) != 4)
41790     return 1;
41791   return 0;
41792 }
41793
41794 _ACEOF
41795     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
41796   (eval $ac_link) 2>&5
41797   ac_status=$?
41798   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
41799   test $ac_status = 0; } && test -s conftest$ac_exeext; then
41800       case "$host_os" in
41801         # Handle native Windows specially, because there setlocale() interprets
41802         # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
41803         # "fr" or "fra" as "French" or "French_France.1252",
41804         # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
41805         # "ja" as "Japanese" or "Japanese_Japan.932",
41806         # and similar.
41807         mingw*)
41808           # Test for the hypothetical native Windows locale name.
41809           if (LC_ALL=Chinese_China.54936 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
41810             gt_cv_locale_zh_CN=Chinese_China.54936
41811           else
41812             # None found.
41813             gt_cv_locale_zh_CN=none
41814           fi
41815           ;;
41816         solaris2.8)
41817           # On Solaris 8, the locales zh_CN.GB18030, zh_CN.GBK, zh.GBK are
41818           # broken. One witness is the test case in gl_MBRTOWC_SANITYCHECK.
41819           # Another witness is that "LC_ALL=zh_CN.GB18030 bash -c true" dumps core.
41820           gt_cv_locale_zh_CN=none
41821           ;;
41822         *)
41823           # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
41824           # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
41825           # configure script would override the LC_ALL setting. Likewise for
41826           # LC_CTYPE, which is also set at the beginning of the configure script.
41827           # Test for the locale name without encoding suffix.
41828           if (LC_ALL=zh_CN LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
41829             gt_cv_locale_zh_CN=zh_CN
41830           else
41831             # Test for the locale name with explicit encoding suffix.
41832             if (LC_ALL=zh_CN.GB18030 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
41833               gt_cv_locale_zh_CN=zh_CN.GB18030
41834             else
41835               # None found.
41836               gt_cv_locale_zh_CN=none
41837             fi
41838           fi
41839           ;;
41840       esac
41841     else
41842       # If there was a link error, due to mblen(), the system is so old that
41843       # it certainly doesn't have a chinese locale.
41844       gt_cv_locale_zh_CN=none
41845     fi
41846     rm -fr conftest*
41847
41848 fi
41849 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_zh_CN" >&5
41850 $as_echo "$gt_cv_locale_zh_CN" >&6; }
41851   LOCALE_ZH_CN=$gt_cv_locale_zh_CN
41852
41853
41854
41855
41856   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a french Unicode locale" >&5
41857 $as_echo_n "checking for a french Unicode locale... " >&6; }
41858 if ${gt_cv_locale_fr_utf8+:} false; then :
41859   $as_echo_n "(cached) " >&6
41860 else
41861
41862     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41863 /* end confdefs.h.  */
41864
41865 #include <locale.h>
41866 #include <time.h>
41867 #if HAVE_LANGINFO_CODESET
41868 # include <langinfo.h>
41869 #endif
41870 #include <stdlib.h>
41871 #include <string.h>
41872 struct tm t;
41873 char buf[16];
41874 int main () {
41875   /* On BeOS and Haiku, locales are not implemented in libc.  Rather, libintl
41876      imitates locale dependent behaviour by looking at the environment
41877      variables, and all locales use the UTF-8 encoding.  */
41878 #if !(defined __BEOS__ || defined __HAIKU__)
41879   /* Check whether the given locale name is recognized by the system.  */
41880 # if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
41881   /* On native Windows, setlocale(category, "") looks at the system settings,
41882      not at the environment variables.  Also, when an encoding suffix such
41883      as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
41884      category of the locale to "C".  */
41885   if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
41886       || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
41887     return 1;
41888 # else
41889   if (setlocale (LC_ALL, "") == NULL) return 1;
41890 # endif
41891   /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
41892      On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
41893      is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
41894      On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
41895      succeeds but then nl_langinfo(CODESET) is "646". In this situation,
41896      some unit tests fail.  */
41897 # if HAVE_LANGINFO_CODESET
41898   {
41899     const char *cs = nl_langinfo (CODESET);
41900     if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0)
41901       return 1;
41902   }
41903 # endif
41904 # ifdef __CYGWIN__
41905   /* On Cygwin, avoid locale names without encoding suffix, because the
41906      locale_charset() function relies on the encoding suffix.  Note that
41907      LC_ALL is set on the command line.  */
41908   if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
41909 # endif
41910   /* Check whether in the abbreviation of the second month, the second
41911      character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is
41912      two bytes long, with UTF-8 encoding.  */
41913   t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
41914   if (strftime (buf, sizeof (buf), "%b", &t) < 4
41915       || buf[1] != (char) 0xc3 || buf[2] != (char) 0xa9 || buf[3] != 'v')
41916     return 1;
41917 #endif
41918 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy.  */
41919   /* Check whether the decimal separator is a comma.
41920      On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
41921      are nl_langinfo(RADIXCHAR) are both ".".  */
41922   if (localeconv () ->decimal_point[0] != ',') return 1;
41923 #endif
41924   return 0;
41925 }
41926
41927 _ACEOF
41928     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
41929   (eval $ac_link) 2>&5
41930   ac_status=$?
41931   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
41932   test $ac_status = 0; } && test -s conftest$ac_exeext; then
41933       case "$host_os" in
41934         # Handle native Windows specially, because there setlocale() interprets
41935         # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
41936         # "fr" or "fra" as "French" or "French_France.1252",
41937         # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
41938         # "ja" as "Japanese" or "Japanese_Japan.932",
41939         # and similar.
41940         mingw*)
41941           # Test for the hypothetical native Windows locale name.
41942           if (LC_ALL=French_France.65001 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
41943             gt_cv_locale_fr_utf8=French_France.65001
41944           else
41945             # None found.
41946             gt_cv_locale_fr_utf8=none
41947           fi
41948           ;;
41949         *)
41950           # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
41951           # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
41952           # configure script would override the LC_ALL setting. Likewise for
41953           # LC_CTYPE, which is also set at the beginning of the configure script.
41954           # Test for the usual locale name.
41955           if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
41956             gt_cv_locale_fr_utf8=fr_FR
41957           else
41958             # Test for the locale name with explicit encoding suffix.
41959             if (LC_ALL=fr_FR.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
41960               gt_cv_locale_fr_utf8=fr_FR.UTF-8
41961             else
41962               # Test for the Solaris 7 locale name.
41963               if (LC_ALL=fr.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
41964                 gt_cv_locale_fr_utf8=fr.UTF-8
41965               else
41966                 # None found.
41967                 gt_cv_locale_fr_utf8=none
41968               fi
41969             fi
41970           fi
41971           ;;
41972       esac
41973     fi
41974     rm -fr conftest*
41975
41976 fi
41977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr_utf8" >&5
41978 $as_echo "$gt_cv_locale_fr_utf8" >&6; }
41979   LOCALE_FR_UTF8=$gt_cv_locale_fr_utf8
41980
41981
41982
41983
41984
41985   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a traditional french locale" >&5
41986 $as_echo_n "checking for a traditional french locale... " >&6; }
41987 if ${gt_cv_locale_fr+:} false; then :
41988   $as_echo_n "(cached) " >&6
41989 else
41990
41991     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
41992 /* end confdefs.h.  */
41993
41994 #include <locale.h>
41995 #include <time.h>
41996 #if HAVE_LANGINFO_CODESET
41997 # include <langinfo.h>
41998 #endif
41999 #include <stdlib.h>
42000 #include <string.h>
42001 struct tm t;
42002 char buf[16];
42003 int main () {
42004   /* Check whether the given locale name is recognized by the system.  */
42005 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
42006   /* On native Windows, setlocale(category, "") looks at the system settings,
42007      not at the environment variables.  Also, when an encoding suffix such
42008      as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
42009      category of the locale to "C".  */
42010   if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
42011       || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
42012     return 1;
42013 #else
42014   if (setlocale (LC_ALL, "") == NULL) return 1;
42015 #endif
42016   /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
42017      On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
42018      is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
42019      On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
42020      succeeds but then nl_langinfo(CODESET) is "646". In this situation,
42021      some unit tests fail.
42022      On MirBSD 10, when an unsupported locale is specified, setlocale()
42023      succeeds but then nl_langinfo(CODESET) is "UTF-8".  */
42024 #if HAVE_LANGINFO_CODESET
42025   {
42026     const char *cs = nl_langinfo (CODESET);
42027     if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
42028         || strcmp (cs, "UTF-8") == 0)
42029       return 1;
42030   }
42031 #endif
42032 #ifdef __CYGWIN__
42033   /* On Cygwin, avoid locale names without encoding suffix, because the
42034      locale_charset() function relies on the encoding suffix.  Note that
42035      LC_ALL is set on the command line.  */
42036   if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
42037 #endif
42038   /* Check whether in the abbreviation of the second month, the second
42039      character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is only
42040      one byte long. This excludes the UTF-8 encoding.  */
42041   t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
42042   if (strftime (buf, sizeof (buf), "%b", &t) < 3 || buf[2] != 'v') return 1;
42043 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy.  */
42044   /* Check whether the decimal separator is a comma.
42045      On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
42046      are nl_langinfo(RADIXCHAR) are both ".".  */
42047   if (localeconv () ->decimal_point[0] != ',') return 1;
42048 #endif
42049   return 0;
42050 }
42051
42052 _ACEOF
42053     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
42054   (eval $ac_link) 2>&5
42055   ac_status=$?
42056   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
42057   test $ac_status = 0; } && test -s conftest$ac_exeext; then
42058       case "$host_os" in
42059         # Handle native Windows specially, because there setlocale() interprets
42060         # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
42061         # "fr" or "fra" as "French" or "French_France.1252",
42062         # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
42063         # "ja" as "Japanese" or "Japanese_Japan.932",
42064         # and similar.
42065         mingw*)
42066           # Test for the native Windows locale name.
42067           if (LC_ALL=French_France.1252 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
42068             gt_cv_locale_fr=French_France.1252
42069           else
42070             # None found.
42071             gt_cv_locale_fr=none
42072           fi
42073           ;;
42074         *)
42075           # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
42076           # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
42077           # configure script would override the LC_ALL setting. Likewise for
42078           # LC_CTYPE, which is also set at the beginning of the configure script.
42079           # Test for the usual locale name.
42080           if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
42081             gt_cv_locale_fr=fr_FR
42082           else
42083             # Test for the locale name with explicit encoding suffix.
42084             if (LC_ALL=fr_FR.ISO-8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
42085               gt_cv_locale_fr=fr_FR.ISO-8859-1
42086             else
42087               # Test for the AIX, OSF/1, FreeBSD, NetBSD, OpenBSD locale name.
42088               if (LC_ALL=fr_FR.ISO8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
42089                 gt_cv_locale_fr=fr_FR.ISO8859-1
42090               else
42091                 # Test for the HP-UX locale name.
42092                 if (LC_ALL=fr_FR.iso88591 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
42093                   gt_cv_locale_fr=fr_FR.iso88591
42094                 else
42095                   # Test for the Solaris 7 locale name.
42096                   if (LC_ALL=fr LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
42097                     gt_cv_locale_fr=fr
42098                   else
42099                     # None found.
42100                     gt_cv_locale_fr=none
42101                   fi
42102                 fi
42103               fi
42104             fi
42105           fi
42106           ;;
42107       esac
42108     fi
42109     rm -fr conftest*
42110
42111 fi
42112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr" >&5
42113 $as_echo "$gt_cv_locale_fr" >&6; }
42114   LOCALE_FR=$gt_cv_locale_fr
42115
42116
42117
42118
42119   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a french Unicode locale" >&5
42120 $as_echo_n "checking for a french Unicode locale... " >&6; }
42121 if ${gt_cv_locale_fr_utf8+:} false; then :
42122   $as_echo_n "(cached) " >&6
42123 else
42124
42125     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42126 /* end confdefs.h.  */
42127
42128 #include <locale.h>
42129 #include <time.h>
42130 #if HAVE_LANGINFO_CODESET
42131 # include <langinfo.h>
42132 #endif
42133 #include <stdlib.h>
42134 #include <string.h>
42135 struct tm t;
42136 char buf[16];
42137 int main () {
42138   /* On BeOS and Haiku, locales are not implemented in libc.  Rather, libintl
42139      imitates locale dependent behaviour by looking at the environment
42140      variables, and all locales use the UTF-8 encoding.  */
42141 #if !(defined __BEOS__ || defined __HAIKU__)
42142   /* Check whether the given locale name is recognized by the system.  */
42143 # if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
42144   /* On native Windows, setlocale(category, "") looks at the system settings,
42145      not at the environment variables.  Also, when an encoding suffix such
42146      as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
42147      category of the locale to "C".  */
42148   if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
42149       || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
42150     return 1;
42151 # else
42152   if (setlocale (LC_ALL, "") == NULL) return 1;
42153 # endif
42154   /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
42155      On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
42156      is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
42157      On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
42158      succeeds but then nl_langinfo(CODESET) is "646". In this situation,
42159      some unit tests fail.  */
42160 # if HAVE_LANGINFO_CODESET
42161   {
42162     const char *cs = nl_langinfo (CODESET);
42163     if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0)
42164       return 1;
42165   }
42166 # endif
42167 # ifdef __CYGWIN__
42168   /* On Cygwin, avoid locale names without encoding suffix, because the
42169      locale_charset() function relies on the encoding suffix.  Note that
42170      LC_ALL is set on the command line.  */
42171   if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
42172 # endif
42173   /* Check whether in the abbreviation of the second month, the second
42174      character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is
42175      two bytes long, with UTF-8 encoding.  */
42176   t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
42177   if (strftime (buf, sizeof (buf), "%b", &t) < 4
42178       || buf[1] != (char) 0xc3 || buf[2] != (char) 0xa9 || buf[3] != 'v')
42179     return 1;
42180 #endif
42181 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy.  */
42182   /* Check whether the decimal separator is a comma.
42183      On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
42184      are nl_langinfo(RADIXCHAR) are both ".".  */
42185   if (localeconv () ->decimal_point[0] != ',') return 1;
42186 #endif
42187   return 0;
42188 }
42189
42190 _ACEOF
42191     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
42192   (eval $ac_link) 2>&5
42193   ac_status=$?
42194   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
42195   test $ac_status = 0; } && test -s conftest$ac_exeext; then
42196       case "$host_os" in
42197         # Handle native Windows specially, because there setlocale() interprets
42198         # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
42199         # "fr" or "fra" as "French" or "French_France.1252",
42200         # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
42201         # "ja" as "Japanese" or "Japanese_Japan.932",
42202         # and similar.
42203         mingw*)
42204           # Test for the hypothetical native Windows locale name.
42205           if (LC_ALL=French_France.65001 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
42206             gt_cv_locale_fr_utf8=French_France.65001
42207           else
42208             # None found.
42209             gt_cv_locale_fr_utf8=none
42210           fi
42211           ;;
42212         *)
42213           # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
42214           # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
42215           # configure script would override the LC_ALL setting. Likewise for
42216           # LC_CTYPE, which is also set at the beginning of the configure script.
42217           # Test for the usual locale name.
42218           if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
42219             gt_cv_locale_fr_utf8=fr_FR
42220           else
42221             # Test for the locale name with explicit encoding suffix.
42222             if (LC_ALL=fr_FR.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
42223               gt_cv_locale_fr_utf8=fr_FR.UTF-8
42224             else
42225               # Test for the Solaris 7 locale name.
42226               if (LC_ALL=fr.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
42227                 gt_cv_locale_fr_utf8=fr.UTF-8
42228               else
42229                 # None found.
42230                 gt_cv_locale_fr_utf8=none
42231               fi
42232             fi
42233           fi
42234           ;;
42235       esac
42236     fi
42237     rm -fr conftest*
42238
42239 fi
42240 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr_utf8" >&5
42241 $as_echo "$gt_cv_locale_fr_utf8" >&6; }
42242   LOCALE_FR_UTF8=$gt_cv_locale_fr_utf8
42243
42244
42245
42246
42247
42248   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a traditional japanese locale" >&5
42249 $as_echo_n "checking for a traditional japanese locale... " >&6; }
42250 if ${gt_cv_locale_ja+:} false; then :
42251   $as_echo_n "(cached) " >&6
42252 else
42253
42254     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42255 /* end confdefs.h.  */
42256
42257 #include <locale.h>
42258 #include <time.h>
42259 #if HAVE_LANGINFO_CODESET
42260 # include <langinfo.h>
42261 #endif
42262 #include <stdlib.h>
42263 #include <string.h>
42264 struct tm t;
42265 char buf[16];
42266 int main ()
42267 {
42268   const char *p;
42269   /* Check whether the given locale name is recognized by the system.  */
42270 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
42271   /* On native Windows, setlocale(category, "") looks at the system settings,
42272      not at the environment variables.  Also, when an encoding suffix such
42273      as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
42274      category of the locale to "C".  */
42275   if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
42276       || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
42277     return 1;
42278 #else
42279   if (setlocale (LC_ALL, "") == NULL) return 1;
42280 #endif
42281   /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
42282      On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
42283      is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
42284      On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
42285      succeeds but then nl_langinfo(CODESET) is "646". In this situation,
42286      some unit tests fail.
42287      On MirBSD 10, when an unsupported locale is specified, setlocale()
42288      succeeds but then nl_langinfo(CODESET) is "UTF-8".  */
42289 #if HAVE_LANGINFO_CODESET
42290   {
42291     const char *cs = nl_langinfo (CODESET);
42292     if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
42293         || strcmp (cs, "UTF-8") == 0)
42294       return 1;
42295   }
42296 #endif
42297 #ifdef __CYGWIN__
42298   /* On Cygwin, avoid locale names without encoding suffix, because the
42299      locale_charset() function relies on the encoding suffix.  Note that
42300      LC_ALL is set on the command line.  */
42301   if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
42302 #endif
42303   /* Check whether MB_CUR_MAX is > 1.  This excludes the dysfunctional locales
42304      on Cygwin 1.5.x.  */
42305   if (MB_CUR_MAX == 1)
42306     return 1;
42307   /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
42308      This excludes the UTF-8 encoding (except on MirBSD).  */
42309   t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
42310   if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
42311   for (p = buf; *p != '\0'; p++)
42312     if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
42313       return 1;
42314   return 0;
42315 }
42316
42317 _ACEOF
42318     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
42319   (eval $ac_link) 2>&5
42320   ac_status=$?
42321   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
42322   test $ac_status = 0; } && test -s conftest$ac_exeext; then
42323       case "$host_os" in
42324         # Handle native Windows specially, because there setlocale() interprets
42325         # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
42326         # "fr" or "fra" as "French" or "French_France.1252",
42327         # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
42328         # "ja" as "Japanese" or "Japanese_Japan.932",
42329         # and similar.
42330         mingw*)
42331           # Note that on native Windows, the Japanese locale is
42332           # Japanese_Japan.932, and CP932 is very different from EUC-JP, so we
42333           # cannot use it here.
42334           gt_cv_locale_ja=none
42335           ;;
42336         *)
42337           # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
42338           # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
42339           # configure script would override the LC_ALL setting. Likewise for
42340           # LC_CTYPE, which is also set at the beginning of the configure script.
42341           # Test for the AIX locale name.
42342           if (LC_ALL=ja_JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
42343             gt_cv_locale_ja=ja_JP
42344           else
42345             # Test for the locale name with explicit encoding suffix.
42346             if (LC_ALL=ja_JP.EUC-JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
42347               gt_cv_locale_ja=ja_JP.EUC-JP
42348             else
42349               # Test for the HP-UX, OSF/1, NetBSD locale name.
42350               if (LC_ALL=ja_JP.eucJP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
42351                 gt_cv_locale_ja=ja_JP.eucJP
42352               else
42353                 # Test for the IRIX, FreeBSD locale name.
42354                 if (LC_ALL=ja_JP.EUC LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
42355                   gt_cv_locale_ja=ja_JP.EUC
42356                 else
42357                   # Test for the Solaris 7 locale name.
42358                   if (LC_ALL=ja LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
42359                     gt_cv_locale_ja=ja
42360                   else
42361                     # Special test for NetBSD 1.6.
42362                     if test -f /usr/share/locale/ja_JP.eucJP/LC_CTYPE; then
42363                       gt_cv_locale_ja=ja_JP.eucJP
42364                     else
42365                       # None found.
42366                       gt_cv_locale_ja=none
42367                     fi
42368                   fi
42369                 fi
42370               fi
42371             fi
42372           fi
42373           ;;
42374       esac
42375     fi
42376     rm -fr conftest*
42377
42378 fi
42379 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_ja" >&5
42380 $as_echo "$gt_cv_locale_ja" >&6; }
42381   LOCALE_JA=$gt_cv_locale_ja
42382
42383
42384
42385
42386
42387   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a transitional chinese locale" >&5
42388 $as_echo_n "checking for a transitional chinese locale... " >&6; }
42389 if ${gt_cv_locale_zh_CN+:} false; then :
42390   $as_echo_n "(cached) " >&6
42391 else
42392
42393     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42394 /* end confdefs.h.  */
42395
42396 #include <locale.h>
42397 #include <stdlib.h>
42398 #include <time.h>
42399 #if HAVE_LANGINFO_CODESET
42400 # include <langinfo.h>
42401 #endif
42402 #include <stdlib.h>
42403 #include <string.h>
42404 struct tm t;
42405 char buf[16];
42406 int main ()
42407 {
42408   const char *p;
42409   /* Check whether the given locale name is recognized by the system.  */
42410 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
42411   /* On native Windows, setlocale(category, "") looks at the system settings,
42412      not at the environment variables.  Also, when an encoding suffix such
42413      as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
42414      category of the locale to "C".  */
42415   if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
42416       || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
42417     return 1;
42418 #else
42419   if (setlocale (LC_ALL, "") == NULL) return 1;
42420 #endif
42421   /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
42422      On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
42423      is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
42424      On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
42425      succeeds but then nl_langinfo(CODESET) is "646". In this situation,
42426      some unit tests fail.
42427      On MirBSD 10, when an unsupported locale is specified, setlocale()
42428      succeeds but then nl_langinfo(CODESET) is "UTF-8".  */
42429 #if HAVE_LANGINFO_CODESET
42430   {
42431     const char *cs = nl_langinfo (CODESET);
42432     if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
42433         || strcmp (cs, "UTF-8") == 0)
42434       return 1;
42435   }
42436 #endif
42437 #ifdef __CYGWIN__
42438   /* On Cygwin, avoid locale names without encoding suffix, because the
42439      locale_charset() function relies on the encoding suffix.  Note that
42440      LC_ALL is set on the command line.  */
42441   if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
42442 #endif
42443   /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
42444      This excludes the UTF-8 encoding (except on MirBSD).  */
42445   t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
42446   if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
42447   for (p = buf; *p != '\0'; p++)
42448     if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
42449       return 1;
42450   /* Check whether a typical GB18030 multibyte sequence is recognized as a
42451      single wide character.  This excludes the GB2312 and GBK encodings.  */
42452   if (mblen ("\203\062\332\066", 5) != 4)
42453     return 1;
42454   return 0;
42455 }
42456
42457 _ACEOF
42458     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
42459   (eval $ac_link) 2>&5
42460   ac_status=$?
42461   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
42462   test $ac_status = 0; } && test -s conftest$ac_exeext; then
42463       case "$host_os" in
42464         # Handle native Windows specially, because there setlocale() interprets
42465         # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
42466         # "fr" or "fra" as "French" or "French_France.1252",
42467         # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
42468         # "ja" as "Japanese" or "Japanese_Japan.932",
42469         # and similar.
42470         mingw*)
42471           # Test for the hypothetical native Windows locale name.
42472           if (LC_ALL=Chinese_China.54936 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
42473             gt_cv_locale_zh_CN=Chinese_China.54936
42474           else
42475             # None found.
42476             gt_cv_locale_zh_CN=none
42477           fi
42478           ;;
42479         solaris2.8)
42480           # On Solaris 8, the locales zh_CN.GB18030, zh_CN.GBK, zh.GBK are
42481           # broken. One witness is the test case in gl_MBRTOWC_SANITYCHECK.
42482           # Another witness is that "LC_ALL=zh_CN.GB18030 bash -c true" dumps core.
42483           gt_cv_locale_zh_CN=none
42484           ;;
42485         *)
42486           # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
42487           # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
42488           # configure script would override the LC_ALL setting. Likewise for
42489           # LC_CTYPE, which is also set at the beginning of the configure script.
42490           # Test for the locale name without encoding suffix.
42491           if (LC_ALL=zh_CN LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
42492             gt_cv_locale_zh_CN=zh_CN
42493           else
42494             # Test for the locale name with explicit encoding suffix.
42495             if (LC_ALL=zh_CN.GB18030 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
42496               gt_cv_locale_zh_CN=zh_CN.GB18030
42497             else
42498               # None found.
42499               gt_cv_locale_zh_CN=none
42500             fi
42501           fi
42502           ;;
42503       esac
42504     else
42505       # If there was a link error, due to mblen(), the system is so old that
42506       # it certainly doesn't have a chinese locale.
42507       gt_cv_locale_zh_CN=none
42508     fi
42509     rm -fr conftest*
42510
42511 fi
42512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_zh_CN" >&5
42513 $as_echo "$gt_cv_locale_zh_CN" >&6; }
42514   LOCALE_ZH_CN=$gt_cv_locale_zh_CN
42515
42516
42517
42518
42519
42520   # Check for mmap(). Don't use AC_FUNC_MMAP, because it checks too much: it
42521   # fails on HP-UX 11, because MAP_FIXED mappings do not work. But this is
42522   # irrelevant for anonymous mappings.
42523   ac_fn_c_check_func "$LINENO" "mmap" "ac_cv_func_mmap"
42524 if test "x$ac_cv_func_mmap" = xyes; then :
42525   gl_have_mmap=yes
42526 else
42527   gl_have_mmap=no
42528 fi
42529
42530
42531   # Try to allow MAP_ANONYMOUS.
42532   gl_have_mmap_anonymous=no
42533   if test $gl_have_mmap = yes; then
42534     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MAP_ANONYMOUS" >&5
42535 $as_echo_n "checking for MAP_ANONYMOUS... " >&6; }
42536     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42537 /* end confdefs.h.  */
42538
42539 #include <sys/mman.h>
42540 #ifdef MAP_ANONYMOUS
42541     I cannot identify this map
42542 #endif
42543
42544 _ACEOF
42545 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
42546   $EGREP "I cannot identify this map" >/dev/null 2>&1; then :
42547   gl_have_mmap_anonymous=yes
42548 fi
42549 rm -f conftest*
42550
42551     if test $gl_have_mmap_anonymous != yes; then
42552       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42553 /* end confdefs.h.  */
42554
42555 #include <sys/mman.h>
42556 #ifdef MAP_ANON
42557     I cannot identify this map
42558 #endif
42559
42560 _ACEOF
42561 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
42562   $EGREP "I cannot identify this map" >/dev/null 2>&1; then :
42563
42564 $as_echo "#define MAP_ANONYMOUS MAP_ANON" >>confdefs.h
42565
42566          gl_have_mmap_anonymous=yes
42567 fi
42568 rm -f conftest*
42569
42570     fi
42571     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_have_mmap_anonymous" >&5
42572 $as_echo "$gl_have_mmap_anonymous" >&6; }
42573     if test $gl_have_mmap_anonymous = yes; then
42574
42575 $as_echo "#define HAVE_MAP_ANONYMOUS 1" >>confdefs.h
42576
42577     fi
42578   fi
42579
42580
42581   :
42582
42583
42584
42585
42586
42587
42588   :
42589
42590
42591
42592
42593
42594
42595
42596
42597
42598
42599
42600   :
42601
42602
42603
42604
42605
42606
42607
42608  nanosleep_save_libs=$LIBS
42609
42610  # Solaris 2.5.1 needs -lposix4 to get the nanosleep function.
42611  # Solaris 7 prefers the library name -lrt to the obsolescent name -lposix4.
42612  LIB_NANOSLEEP=
42613
42614  { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing nanosleep" >&5
42615 $as_echo_n "checking for library containing nanosleep... " >&6; }
42616 if ${ac_cv_search_nanosleep+:} false; then :
42617   $as_echo_n "(cached) " >&6
42618 else
42619   ac_func_search_save_LIBS=$LIBS
42620 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42621 /* end confdefs.h.  */
42622
42623 /* Override any GCC internal prototype to avoid an error.
42624    Use char because int might match the return type of a GCC
42625    builtin and then its argument prototype would still apply.  */
42626 #ifdef __cplusplus
42627 extern "C"
42628 #endif
42629 char nanosleep ();
42630 int
42631 main ()
42632 {
42633 return nanosleep ();
42634   ;
42635   return 0;
42636 }
42637 _ACEOF
42638 for ac_lib in '' rt posix4; do
42639   if test -z "$ac_lib"; then
42640     ac_res="none required"
42641   else
42642     ac_res=-l$ac_lib
42643     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
42644   fi
42645   if ac_fn_c_try_link "$LINENO"; then :
42646   ac_cv_search_nanosleep=$ac_res
42647 fi
42648 rm -f core conftest.err conftest.$ac_objext \
42649     conftest$ac_exeext
42650   if ${ac_cv_search_nanosleep+:} false; then :
42651   break
42652 fi
42653 done
42654 if ${ac_cv_search_nanosleep+:} false; then :
42655
42656 else
42657   ac_cv_search_nanosleep=no
42658 fi
42659 rm conftest.$ac_ext
42660 LIBS=$ac_func_search_save_LIBS
42661 fi
42662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_nanosleep" >&5
42663 $as_echo "$ac_cv_search_nanosleep" >&6; }
42664 ac_res=$ac_cv_search_nanosleep
42665 if test "$ac_res" != no; then :
42666   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
42667   test "$ac_cv_search_nanosleep" = "none required" ||
42668                  LIB_NANOSLEEP=$ac_cv_search_nanosleep
42669 fi
42670
42671  if test "x$ac_cv_search_nanosleep" != xno; then
42672
42673
42674    if test $APPLE_UNIVERSAL_BUILD = 1; then
42675      # A universal build on Apple Mac OS X platforms.
42676      # The test result would be 'no (mishandles large arguments)' in 64-bit
42677      # mode but 'yes' in 32-bit mode. But we need a configuration result that
42678      # is valid in both modes.
42679      gl_cv_func_nanosleep='no (mishandles large arguments)'
42680    fi
42681
42682    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working nanosleep" >&5
42683 $as_echo_n "checking for working nanosleep... " >&6; }
42684 if ${gl_cv_func_nanosleep+:} false; then :
42685   $as_echo_n "(cached) " >&6
42686 else
42687
42688      if test "$cross_compiling" = yes; then :
42689   case "$host_os" in           linux*) # Guess it halfway works when the kernel is Linux.
42690             gl_cv_func_nanosleep='guessing no (mishandles large arguments)' ;;
42691           *)      # If we don't know, assume the worst.
42692             gl_cv_func_nanosleep='guessing no' ;;
42693         esac
42694
42695 else
42696   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42697 /* end confdefs.h.  */
42698
42699           #include <errno.h>
42700           #include <limits.h>
42701           #include <signal.h>
42702           #if HAVE_SYS_TIME_H
42703            #include <sys/time.h>
42704           #endif
42705           #include <time.h>
42706           #include <unistd.h>
42707           #define TYPE_SIGNED(t) (! ((t) 0 < (t) -1))
42708           #define TYPE_MAXIMUM(t) \
42709             ((t) (! TYPE_SIGNED (t) \
42710                   ? (t) -1 \
42711                   : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1)))
42712
42713           static void
42714           check_for_SIGALRM (int sig)
42715           {
42716             if (sig != SIGALRM)
42717               _exit (1);
42718           }
42719
42720           int
42721           main ()
42722           {
42723             static struct timespec ts_sleep;
42724             static struct timespec ts_remaining;
42725             static struct sigaction act;
42726             /* Test for major problems first.  */
42727             if (! nanosleep)
42728               return 2;
42729             act.sa_handler = check_for_SIGALRM;
42730             sigemptyset (&act.sa_mask);
42731             sigaction (SIGALRM, &act, NULL);
42732             ts_sleep.tv_sec = 0;
42733             ts_sleep.tv_nsec = 1;
42734             alarm (1);
42735             if (nanosleep (&ts_sleep, NULL) != 0)
42736               return 3;
42737             /* Test for a minor problem: the handling of large arguments.  */
42738             ts_sleep.tv_sec = TYPE_MAXIMUM (time_t);
42739             ts_sleep.tv_nsec = 999999999;
42740             alarm (1);
42741             if (nanosleep (&ts_sleep, &ts_remaining) != -1)
42742               return 4;
42743             if (errno != EINTR)
42744               return 5;
42745             if (ts_remaining.tv_sec <= TYPE_MAXIMUM (time_t) - 10)
42746               return 6;
42747             return 0;
42748           }
42749 _ACEOF
42750 if ac_fn_c_try_run "$LINENO"; then :
42751   gl_cv_func_nanosleep=yes
42752 else
42753   case $? in         4|5|6) gl_cv_func_nanosleep='no (mishandles large arguments)';;         *)   gl_cv_func_nanosleep=no;;
42754         esac
42755 fi
42756 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
42757   conftest.$ac_objext conftest.beam conftest.$ac_ext
42758 fi
42759
42760
42761 fi
42762 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_nanosleep" >&5
42763 $as_echo "$gl_cv_func_nanosleep" >&6; }
42764    case "$gl_cv_func_nanosleep" in
42765      *yes)
42766        REPLACE_NANOSLEEP=0
42767        ;;
42768      *)
42769        REPLACE_NANOSLEEP=1
42770        case "$gl_cv_func_nanosleep" in
42771          *"mishandles large arguments"*)
42772
42773 $as_echo "#define HAVE_BUG_BIG_NANOSLEEP 1" >>confdefs.h
42774
42775            ;;
42776          *)
42777            # The replacement uses select(). Add $LIBSOCKET to $LIB_NANOSLEEP.
42778            for ac_lib in $LIBSOCKET; do
42779              case " $LIB_NANOSLEEP " in
42780                *" $ac_lib "*) ;;
42781                *) LIB_NANOSLEEP="$LIB_NANOSLEEP $ac_lib";;
42782              esac
42783            done
42784            ;;
42785        esac
42786        ;;
42787    esac
42788  else
42789    HAVE_NANOSLEEP=0
42790  fi
42791  LIBS=$nanosleep_save_libs
42792
42793   if test $HAVE_NANOSLEEP = 0 || test $REPLACE_NANOSLEEP = 1; then
42794
42795
42796
42797
42798
42799
42800
42801
42802   gltests_LIBOBJS="$gltests_LIBOBJS nanosleep.$ac_objext"
42803
42804
42805
42806   :
42807
42808
42809
42810
42811
42812   :
42813
42814   fi
42815
42816
42817
42818
42819
42820     if test "$GNULIB_NANOSLEEP" != 1; then
42821         if test "$GNULIB_NANOSLEEP" = 0; then
42822       GNULIB_NANOSLEEP=$gl_module_indicator_condition
42823     else
42824       GNULIB_NANOSLEEP="($GNULIB_NANOSLEEP || $gl_module_indicator_condition)"
42825     fi
42826   fi
42827
42828
42829
42830
42831
42832 $as_echo "#define GNULIB_TEST_NANOSLEEP 1" >>confdefs.h
42833
42834
42835
42836
42837   :
42838
42839
42840
42841
42842
42843   NET_IF_LIB=
42844   gl_saved_libs="$LIBS"
42845   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing if_nameindex" >&5
42846 $as_echo_n "checking for library containing if_nameindex... " >&6; }
42847 if ${ac_cv_search_if_nameindex+:} false; then :
42848   $as_echo_n "(cached) " >&6
42849 else
42850   ac_func_search_save_LIBS=$LIBS
42851 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42852 /* end confdefs.h.  */
42853
42854 /* Override any GCC internal prototype to avoid an error.
42855    Use char because int might match the return type of a GCC
42856    builtin and then its argument prototype would still apply.  */
42857 #ifdef __cplusplus
42858 extern "C"
42859 #endif
42860 char if_nameindex ();
42861 int
42862 main ()
42863 {
42864 return if_nameindex ();
42865   ;
42866   return 0;
42867 }
42868 _ACEOF
42869 for ac_lib in '' socket; do
42870   if test -z "$ac_lib"; then
42871     ac_res="none required"
42872   else
42873     ac_res=-l$ac_lib
42874     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
42875   fi
42876   if ac_fn_c_try_link "$LINENO"; then :
42877   ac_cv_search_if_nameindex=$ac_res
42878 fi
42879 rm -f core conftest.err conftest.$ac_objext \
42880     conftest$ac_exeext
42881   if ${ac_cv_search_if_nameindex+:} false; then :
42882   break
42883 fi
42884 done
42885 if ${ac_cv_search_if_nameindex+:} false; then :
42886
42887 else
42888   ac_cv_search_if_nameindex=no
42889 fi
42890 rm conftest.$ac_ext
42891 LIBS=$ac_func_search_save_LIBS
42892 fi
42893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_if_nameindex" >&5
42894 $as_echo "$ac_cv_search_if_nameindex" >&6; }
42895 ac_res=$ac_cv_search_if_nameindex
42896 if test "$ac_res" != no; then :
42897   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
42898
42899 $as_echo "#define HAVE_IF_NAMEINDEX 1" >>confdefs.h
42900
42901      if test "$ac_cv_search_if_nameindex" != "none required"; then
42902        NET_IF_LIB="$ac_cv_search_if_nameindex"
42903      fi
42904 fi
42905
42906   LIBS="$gl_saved_libs"
42907
42908
42909
42910
42911   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a traditional french locale" >&5
42912 $as_echo_n "checking for a traditional french locale... " >&6; }
42913 if ${gt_cv_locale_fr+:} false; then :
42914   $as_echo_n "(cached) " >&6
42915 else
42916
42917     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
42918 /* end confdefs.h.  */
42919
42920 #include <locale.h>
42921 #include <time.h>
42922 #if HAVE_LANGINFO_CODESET
42923 # include <langinfo.h>
42924 #endif
42925 #include <stdlib.h>
42926 #include <string.h>
42927 struct tm t;
42928 char buf[16];
42929 int main () {
42930   /* Check whether the given locale name is recognized by the system.  */
42931 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
42932   /* On native Windows, setlocale(category, "") looks at the system settings,
42933      not at the environment variables.  Also, when an encoding suffix such
42934      as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
42935      category of the locale to "C".  */
42936   if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
42937       || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
42938     return 1;
42939 #else
42940   if (setlocale (LC_ALL, "") == NULL) return 1;
42941 #endif
42942   /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
42943      On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
42944      is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
42945      On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
42946      succeeds but then nl_langinfo(CODESET) is "646". In this situation,
42947      some unit tests fail.
42948      On MirBSD 10, when an unsupported locale is specified, setlocale()
42949      succeeds but then nl_langinfo(CODESET) is "UTF-8".  */
42950 #if HAVE_LANGINFO_CODESET
42951   {
42952     const char *cs = nl_langinfo (CODESET);
42953     if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
42954         || strcmp (cs, "UTF-8") == 0)
42955       return 1;
42956   }
42957 #endif
42958 #ifdef __CYGWIN__
42959   /* On Cygwin, avoid locale names without encoding suffix, because the
42960      locale_charset() function relies on the encoding suffix.  Note that
42961      LC_ALL is set on the command line.  */
42962   if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
42963 #endif
42964   /* Check whether in the abbreviation of the second month, the second
42965      character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is only
42966      one byte long. This excludes the UTF-8 encoding.  */
42967   t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
42968   if (strftime (buf, sizeof (buf), "%b", &t) < 3 || buf[2] != 'v') return 1;
42969 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy.  */
42970   /* Check whether the decimal separator is a comma.
42971      On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
42972      are nl_langinfo(RADIXCHAR) are both ".".  */
42973   if (localeconv () ->decimal_point[0] != ',') return 1;
42974 #endif
42975   return 0;
42976 }
42977
42978 _ACEOF
42979     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
42980   (eval $ac_link) 2>&5
42981   ac_status=$?
42982   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
42983   test $ac_status = 0; } && test -s conftest$ac_exeext; then
42984       case "$host_os" in
42985         # Handle native Windows specially, because there setlocale() interprets
42986         # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
42987         # "fr" or "fra" as "French" or "French_France.1252",
42988         # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
42989         # "ja" as "Japanese" or "Japanese_Japan.932",
42990         # and similar.
42991         mingw*)
42992           # Test for the native Windows locale name.
42993           if (LC_ALL=French_France.1252 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
42994             gt_cv_locale_fr=French_France.1252
42995           else
42996             # None found.
42997             gt_cv_locale_fr=none
42998           fi
42999           ;;
43000         *)
43001           # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
43002           # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
43003           # configure script would override the LC_ALL setting. Likewise for
43004           # LC_CTYPE, which is also set at the beginning of the configure script.
43005           # Test for the usual locale name.
43006           if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
43007             gt_cv_locale_fr=fr_FR
43008           else
43009             # Test for the locale name with explicit encoding suffix.
43010             if (LC_ALL=fr_FR.ISO-8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
43011               gt_cv_locale_fr=fr_FR.ISO-8859-1
43012             else
43013               # Test for the AIX, OSF/1, FreeBSD, NetBSD, OpenBSD locale name.
43014               if (LC_ALL=fr_FR.ISO8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
43015                 gt_cv_locale_fr=fr_FR.ISO8859-1
43016               else
43017                 # Test for the HP-UX locale name.
43018                 if (LC_ALL=fr_FR.iso88591 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
43019                   gt_cv_locale_fr=fr_FR.iso88591
43020                 else
43021                   # Test for the Solaris 7 locale name.
43022                   if (LC_ALL=fr LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
43023                     gt_cv_locale_fr=fr
43024                   else
43025                     # None found.
43026                     gt_cv_locale_fr=none
43027                   fi
43028                 fi
43029               fi
43030             fi
43031           fi
43032           ;;
43033       esac
43034     fi
43035     rm -fr conftest*
43036
43037 fi
43038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr" >&5
43039 $as_echo "$gt_cv_locale_fr" >&6; }
43040   LOCALE_FR=$gt_cv_locale_fr
43041
43042
43043
43044
43045   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a french Unicode locale" >&5
43046 $as_echo_n "checking for a french Unicode locale... " >&6; }
43047 if ${gt_cv_locale_fr_utf8+:} false; then :
43048   $as_echo_n "(cached) " >&6
43049 else
43050
43051     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43052 /* end confdefs.h.  */
43053
43054 #include <locale.h>
43055 #include <time.h>
43056 #if HAVE_LANGINFO_CODESET
43057 # include <langinfo.h>
43058 #endif
43059 #include <stdlib.h>
43060 #include <string.h>
43061 struct tm t;
43062 char buf[16];
43063 int main () {
43064   /* On BeOS and Haiku, locales are not implemented in libc.  Rather, libintl
43065      imitates locale dependent behaviour by looking at the environment
43066      variables, and all locales use the UTF-8 encoding.  */
43067 #if !(defined __BEOS__ || defined __HAIKU__)
43068   /* Check whether the given locale name is recognized by the system.  */
43069 # if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
43070   /* On native Windows, setlocale(category, "") looks at the system settings,
43071      not at the environment variables.  Also, when an encoding suffix such
43072      as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
43073      category of the locale to "C".  */
43074   if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
43075       || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
43076     return 1;
43077 # else
43078   if (setlocale (LC_ALL, "") == NULL) return 1;
43079 # endif
43080   /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
43081      On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
43082      is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
43083      On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
43084      succeeds but then nl_langinfo(CODESET) is "646". In this situation,
43085      some unit tests fail.  */
43086 # if HAVE_LANGINFO_CODESET
43087   {
43088     const char *cs = nl_langinfo (CODESET);
43089     if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0)
43090       return 1;
43091   }
43092 # endif
43093 # ifdef __CYGWIN__
43094   /* On Cygwin, avoid locale names without encoding suffix, because the
43095      locale_charset() function relies on the encoding suffix.  Note that
43096      LC_ALL is set on the command line.  */
43097   if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
43098 # endif
43099   /* Check whether in the abbreviation of the second month, the second
43100      character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is
43101      two bytes long, with UTF-8 encoding.  */
43102   t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
43103   if (strftime (buf, sizeof (buf), "%b", &t) < 4
43104       || buf[1] != (char) 0xc3 || buf[2] != (char) 0xa9 || buf[3] != 'v')
43105     return 1;
43106 #endif
43107 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy.  */
43108   /* Check whether the decimal separator is a comma.
43109      On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
43110      are nl_langinfo(RADIXCHAR) are both ".".  */
43111   if (localeconv () ->decimal_point[0] != ',') return 1;
43112 #endif
43113   return 0;
43114 }
43115
43116 _ACEOF
43117     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
43118   (eval $ac_link) 2>&5
43119   ac_status=$?
43120   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
43121   test $ac_status = 0; } && test -s conftest$ac_exeext; then
43122       case "$host_os" in
43123         # Handle native Windows specially, because there setlocale() interprets
43124         # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
43125         # "fr" or "fra" as "French" or "French_France.1252",
43126         # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
43127         # "ja" as "Japanese" or "Japanese_Japan.932",
43128         # and similar.
43129         mingw*)
43130           # Test for the hypothetical native Windows locale name.
43131           if (LC_ALL=French_France.65001 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
43132             gt_cv_locale_fr_utf8=French_France.65001
43133           else
43134             # None found.
43135             gt_cv_locale_fr_utf8=none
43136           fi
43137           ;;
43138         *)
43139           # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
43140           # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
43141           # configure script would override the LC_ALL setting. Likewise for
43142           # LC_CTYPE, which is also set at the beginning of the configure script.
43143           # Test for the usual locale name.
43144           if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
43145             gt_cv_locale_fr_utf8=fr_FR
43146           else
43147             # Test for the locale name with explicit encoding suffix.
43148             if (LC_ALL=fr_FR.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
43149               gt_cv_locale_fr_utf8=fr_FR.UTF-8
43150             else
43151               # Test for the Solaris 7 locale name.
43152               if (LC_ALL=fr.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
43153                 gt_cv_locale_fr_utf8=fr.UTF-8
43154               else
43155                 # None found.
43156                 gt_cv_locale_fr_utf8=none
43157               fi
43158             fi
43159           fi
43160           ;;
43161       esac
43162     fi
43163     rm -fr conftest*
43164
43165 fi
43166 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr_utf8" >&5
43167 $as_echo "$gt_cv_locale_fr_utf8" >&6; }
43168   LOCALE_FR_UTF8=$gt_cv_locale_fr_utf8
43169
43170
43171
43172   :
43173
43174
43175
43176
43177
43178
43179   :
43180
43181
43182
43183
43184
43185
43186   :
43187
43188
43189
43190
43191
43192
43193
43194
43195
43196
43197
43198
43199
43200
43201   if test $REPLACE_POSIX_SPAWN = 1; then
43202     REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE=1
43203   else
43204             { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether posix_spawn_file_actions_addclose works" >&5
43205 $as_echo_n "checking whether posix_spawn_file_actions_addclose works... " >&6; }
43206 if ${gl_cv_func_posix_spawn_file_actions_addclose_works+:} false; then :
43207   $as_echo_n "(cached) " >&6
43208 else
43209   if test "$cross_compiling" = yes; then :
43210   # Guess no on Solaris, yes otherwise.
43211           case "$host_os" in
43212             solaris*) gl_cv_func_posix_spawn_file_actions_addclose_works="guessing no";;
43213             *)        gl_cv_func_posix_spawn_file_actions_addclose_works="guessing yes";;
43214           esac
43215
43216 else
43217   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43218 /* end confdefs.h.  */
43219
43220 #include <spawn.h>
43221 int main ()
43222 {
43223   posix_spawn_file_actions_t actions;
43224   if (posix_spawn_file_actions_init (&actions) != 0)
43225     return 1;
43226   if (posix_spawn_file_actions_addclose (&actions, 10000000) == 0)
43227     return 2;
43228   return 0;
43229 }
43230 _ACEOF
43231 if ac_fn_c_try_run "$LINENO"; then :
43232   gl_cv_func_posix_spawn_file_actions_addclose_works=yes
43233 else
43234   gl_cv_func_posix_spawn_file_actions_addclose_works=no
43235 fi
43236 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
43237   conftest.$ac_objext conftest.beam conftest.$ac_ext
43238 fi
43239
43240
43241 fi
43242 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_posix_spawn_file_actions_addclose_works" >&5
43243 $as_echo "$gl_cv_func_posix_spawn_file_actions_addclose_works" >&6; }
43244     case "$gl_cv_func_posix_spawn_file_actions_addclose_works" in
43245       *yes) ;;
43246       *) REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE=1 ;;
43247     esac
43248   fi
43249
43250   if test $HAVE_POSIX_SPAWN = 0 || test $REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE = 1; then
43251
43252
43253
43254
43255
43256
43257
43258
43259   gltests_LIBOBJS="$gltests_LIBOBJS spawn_faction_addclose.$ac_objext"
43260
43261   fi
43262
43263
43264
43265
43266
43267     if test "$GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE" != 1; then
43268         if test "$GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE" = 0; then
43269       GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE=$gl_module_indicator_condition
43270     else
43271       GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE="($GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE || $gl_module_indicator_condition)"
43272     fi
43273   fi
43274
43275
43276
43277
43278
43279 $as_echo "#define GNULIB_TEST_POSIX_SPAWN_FILE_ACTIONS_ADDCLOSE 1" >>confdefs.h
43280
43281
43282
43283
43284
43285
43286
43287
43288
43289   if test $REPLACE_POSIX_SPAWN = 1; then
43290     REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2=1
43291   else
43292             { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether posix_spawn_file_actions_adddup2 works" >&5
43293 $as_echo_n "checking whether posix_spawn_file_actions_adddup2 works... " >&6; }
43294 if ${gl_cv_func_posix_spawn_file_actions_adddup2_works+:} false; then :
43295   $as_echo_n "(cached) " >&6
43296 else
43297   if test "$cross_compiling" = yes; then :
43298   # Guess no on Solaris, yes otherwise.
43299           case "$host_os" in
43300             solaris*) gl_cv_func_posix_spawn_file_actions_adddup2_works="guessing no";;
43301             *)        gl_cv_func_posix_spawn_file_actions_adddup2_works="guessing yes";;
43302           esac
43303
43304 else
43305   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43306 /* end confdefs.h.  */
43307
43308 #include <spawn.h>
43309 int main ()
43310 {
43311   posix_spawn_file_actions_t actions;
43312   if (posix_spawn_file_actions_init (&actions) != 0)
43313     return 1;
43314   if (posix_spawn_file_actions_adddup2 (&actions, 10000000, 2) == 0)
43315     return 2;
43316   return 0;
43317 }
43318 _ACEOF
43319 if ac_fn_c_try_run "$LINENO"; then :
43320   gl_cv_func_posix_spawn_file_actions_adddup2_works=yes
43321 else
43322   gl_cv_func_posix_spawn_file_actions_adddup2_works=no
43323 fi
43324 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
43325   conftest.$ac_objext conftest.beam conftest.$ac_ext
43326 fi
43327
43328
43329 fi
43330 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_posix_spawn_file_actions_adddup2_works" >&5
43331 $as_echo "$gl_cv_func_posix_spawn_file_actions_adddup2_works" >&6; }
43332     case "$gl_cv_func_posix_spawn_file_actions_adddup2_works" in
43333       *yes) ;;
43334       *) REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2=1 ;;
43335     esac
43336   fi
43337
43338   if test $HAVE_POSIX_SPAWN = 0 || test $REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2 = 1; then
43339
43340
43341
43342
43343
43344
43345
43346
43347   gltests_LIBOBJS="$gltests_LIBOBJS spawn_faction_adddup2.$ac_objext"
43348
43349   fi
43350
43351
43352
43353
43354
43355     if test "$GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2" != 1; then
43356         if test "$GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2" = 0; then
43357       GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2=$gl_module_indicator_condition
43358     else
43359       GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2="($GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2 || $gl_module_indicator_condition)"
43360     fi
43361   fi
43362
43363
43364
43365
43366
43367 $as_echo "#define GNULIB_TEST_POSIX_SPAWN_FILE_ACTIONS_ADDDUP2 1" >>confdefs.h
43368
43369
43370
43371
43372
43373
43374
43375
43376
43377   if test $REPLACE_POSIX_SPAWN = 1; then
43378     REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN=1
43379   else
43380             { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether posix_spawn_file_actions_addopen works" >&5
43381 $as_echo_n "checking whether posix_spawn_file_actions_addopen works... " >&6; }
43382 if ${gl_cv_func_posix_spawn_file_actions_addopen_works+:} false; then :
43383   $as_echo_n "(cached) " >&6
43384 else
43385   if test "$cross_compiling" = yes; then :
43386   # Guess no on Solaris, yes otherwise.
43387           case "$host_os" in
43388             solaris*) gl_cv_func_posix_spawn_file_actions_addopen_works="guessing no";;
43389             *)        gl_cv_func_posix_spawn_file_actions_addopen_works="guessing yes";;
43390           esac
43391
43392 else
43393   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43394 /* end confdefs.h.  */
43395
43396 #include <spawn.h>
43397 #include <fcntl.h>
43398 int main ()
43399 {
43400   posix_spawn_file_actions_t actions;
43401   if (posix_spawn_file_actions_init (&actions) != 0)
43402     return 1;
43403   if (posix_spawn_file_actions_addopen (&actions, 10000000, "foo", 0, O_RDONLY)
43404       == 0)
43405     return 2;
43406   return 0;
43407 }
43408 _ACEOF
43409 if ac_fn_c_try_run "$LINENO"; then :
43410   gl_cv_func_posix_spawn_file_actions_addopen_works=yes
43411 else
43412   gl_cv_func_posix_spawn_file_actions_addopen_works=no
43413 fi
43414 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
43415   conftest.$ac_objext conftest.beam conftest.$ac_ext
43416 fi
43417
43418
43419 fi
43420 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_posix_spawn_file_actions_addopen_works" >&5
43421 $as_echo "$gl_cv_func_posix_spawn_file_actions_addopen_works" >&6; }
43422     case "$gl_cv_func_posix_spawn_file_actions_addopen_works" in
43423       *yes) ;;
43424       *) REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN=1 ;;
43425     esac
43426   fi
43427
43428   if test $HAVE_POSIX_SPAWN = 0 || test $REPLACE_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN = 1; then
43429
43430
43431
43432
43433
43434
43435
43436
43437   gltests_LIBOBJS="$gltests_LIBOBJS spawn_faction_addopen.$ac_objext"
43438
43439   fi
43440
43441
43442
43443
43444
43445     if test "$GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN" != 1; then
43446         if test "$GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN" = 0; then
43447       GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN=$gl_module_indicator_condition
43448     else
43449       GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN="($GNULIB_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN || $gl_module_indicator_condition)"
43450     fi
43451   fi
43452
43453
43454
43455
43456
43457 $as_echo "#define GNULIB_TEST_POSIX_SPAWN_FILE_ACTIONS_ADDOPEN 1" >>confdefs.h
43458
43459
43460
43461
43462
43463
43464   if test $HAVE_POSIX_SPAWN = 0 || test $REPLACE_POSIX_SPAWN = 1; then
43465
43466
43467
43468
43469
43470
43471
43472
43473   gltests_LIBOBJS="$gltests_LIBOBJS spawn_faction_destroy.$ac_objext"
43474
43475   fi
43476
43477
43478
43479
43480
43481     if test "$GNULIB_POSIX_SPAWN_FILE_ACTIONS_DESTROY" != 1; then
43482         if test "$GNULIB_POSIX_SPAWN_FILE_ACTIONS_DESTROY" = 0; then
43483       GNULIB_POSIX_SPAWN_FILE_ACTIONS_DESTROY=$gl_module_indicator_condition
43484     else
43485       GNULIB_POSIX_SPAWN_FILE_ACTIONS_DESTROY="($GNULIB_POSIX_SPAWN_FILE_ACTIONS_DESTROY || $gl_module_indicator_condition)"
43486     fi
43487   fi
43488
43489
43490
43491
43492
43493 $as_echo "#define GNULIB_TEST_POSIX_SPAWN_FILE_ACTIONS_DESTROY 1" >>confdefs.h
43494
43495
43496
43497
43498
43499
43500   if test $HAVE_POSIX_SPAWN = 0 || test $REPLACE_POSIX_SPAWN = 1; then
43501
43502
43503
43504
43505
43506
43507
43508
43509   gltests_LIBOBJS="$gltests_LIBOBJS spawn_faction_init.$ac_objext"
43510
43511   fi
43512
43513
43514
43515
43516
43517     if test "$GNULIB_POSIX_SPAWN_FILE_ACTIONS_INIT" != 1; then
43518         if test "$GNULIB_POSIX_SPAWN_FILE_ACTIONS_INIT" = 0; then
43519       GNULIB_POSIX_SPAWN_FILE_ACTIONS_INIT=$gl_module_indicator_condition
43520     else
43521       GNULIB_POSIX_SPAWN_FILE_ACTIONS_INIT="($GNULIB_POSIX_SPAWN_FILE_ACTIONS_INIT || $gl_module_indicator_condition)"
43522     fi
43523   fi
43524
43525
43526
43527
43528
43529 $as_echo "#define GNULIB_TEST_POSIX_SPAWN_FILE_ACTIONS_INIT 1" >>confdefs.h
43530
43531
43532
43533
43534
43535
43536   if test $HAVE_POSIX_SPAWN = 0 || test $REPLACE_POSIX_SPAWN = 1; then
43537
43538
43539
43540
43541
43542
43543
43544
43545   gltests_LIBOBJS="$gltests_LIBOBJS spawnattr_destroy.$ac_objext"
43546
43547   fi
43548
43549
43550
43551
43552
43553     if test "$GNULIB_POSIX_SPAWNATTR_DESTROY" != 1; then
43554         if test "$GNULIB_POSIX_SPAWNATTR_DESTROY" = 0; then
43555       GNULIB_POSIX_SPAWNATTR_DESTROY=$gl_module_indicator_condition
43556     else
43557       GNULIB_POSIX_SPAWNATTR_DESTROY="($GNULIB_POSIX_SPAWNATTR_DESTROY || $gl_module_indicator_condition)"
43558     fi
43559   fi
43560
43561
43562
43563
43564
43565 $as_echo "#define GNULIB_TEST_POSIX_SPAWNATTR_DESTROY 1" >>confdefs.h
43566
43567
43568
43569
43570
43571
43572   if test $HAVE_POSIX_SPAWN = 0 || test $REPLACE_POSIX_SPAWN = 1; then
43573
43574
43575
43576
43577
43578
43579
43580
43581   gltests_LIBOBJS="$gltests_LIBOBJS spawnattr_init.$ac_objext"
43582
43583   fi
43584
43585
43586
43587
43588
43589     if test "$GNULIB_POSIX_SPAWNATTR_INIT" != 1; then
43590         if test "$GNULIB_POSIX_SPAWNATTR_INIT" = 0; then
43591       GNULIB_POSIX_SPAWNATTR_INIT=$gl_module_indicator_condition
43592     else
43593       GNULIB_POSIX_SPAWNATTR_INIT="($GNULIB_POSIX_SPAWNATTR_INIT || $gl_module_indicator_condition)"
43594     fi
43595   fi
43596
43597
43598
43599
43600
43601 $as_echo "#define GNULIB_TEST_POSIX_SPAWNATTR_INIT 1" >>confdefs.h
43602
43603
43604
43605
43606
43607
43608   if test $HAVE_POSIX_SPAWN = 0 || test $REPLACE_POSIX_SPAWN = 1; then
43609
43610
43611
43612
43613
43614
43615
43616
43617   gltests_LIBOBJS="$gltests_LIBOBJS spawnattr_setflags.$ac_objext"
43618
43619   fi
43620
43621
43622
43623
43624
43625     if test "$GNULIB_POSIX_SPAWNATTR_SETFLAGS" != 1; then
43626         if test "$GNULIB_POSIX_SPAWNATTR_SETFLAGS" = 0; then
43627       GNULIB_POSIX_SPAWNATTR_SETFLAGS=$gl_module_indicator_condition
43628     else
43629       GNULIB_POSIX_SPAWNATTR_SETFLAGS="($GNULIB_POSIX_SPAWNATTR_SETFLAGS || $gl_module_indicator_condition)"
43630     fi
43631   fi
43632
43633
43634
43635
43636
43637 $as_echo "#define GNULIB_TEST_POSIX_SPAWNATTR_SETFLAGS 1" >>confdefs.h
43638
43639
43640
43641
43642
43643
43644   if test $HAVE_POSIX_SPAWN = 0 || test $REPLACE_POSIX_SPAWN = 1; then
43645
43646
43647
43648
43649
43650
43651
43652
43653   gltests_LIBOBJS="$gltests_LIBOBJS spawnattr_setsigmask.$ac_objext"
43654
43655   fi
43656
43657
43658
43659
43660
43661     if test "$GNULIB_POSIX_SPAWNATTR_SETSIGMASK" != 1; then
43662         if test "$GNULIB_POSIX_SPAWNATTR_SETSIGMASK" = 0; then
43663       GNULIB_POSIX_SPAWNATTR_SETSIGMASK=$gl_module_indicator_condition
43664     else
43665       GNULIB_POSIX_SPAWNATTR_SETSIGMASK="($GNULIB_POSIX_SPAWNATTR_SETSIGMASK || $gl_module_indicator_condition)"
43666     fi
43667   fi
43668
43669
43670
43671
43672
43673 $as_echo "#define GNULIB_TEST_POSIX_SPAWNATTR_SETSIGMASK 1" >>confdefs.h
43674
43675
43676
43677
43678
43679
43680   if test $HAVE_POSIX_SPAWN = 0 || test $REPLACE_POSIX_SPAWN = 1; then
43681
43682
43683
43684
43685
43686
43687
43688
43689   gltests_LIBOBJS="$gltests_LIBOBJS spawnp.$ac_objext"
43690
43691
43692
43693
43694
43695
43696
43697
43698
43699   gltests_LIBOBJS="$gltests_LIBOBJS spawni.$ac_objext"
43700
43701
43702   for ac_header in paths.h
43703 do :
43704   ac_fn_c_check_header_mongrel "$LINENO" "paths.h" "ac_cv_header_paths_h" "$ac_includes_default"
43705 if test "x$ac_cv_header_paths_h" = xyes; then :
43706   cat >>confdefs.h <<_ACEOF
43707 #define HAVE_PATHS_H 1
43708 _ACEOF
43709
43710 fi
43711
43712 done
43713
43714   for ac_func in confstr sched_setparam sched_setscheduler setegid seteuid vfork
43715 do :
43716   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
43717 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
43718 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
43719   cat >>confdefs.h <<_ACEOF
43720 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
43721 _ACEOF
43722
43723 fi
43724 done
43725
43726
43727   fi
43728
43729
43730
43731
43732
43733     if test "$GNULIB_POSIX_SPAWNP" != 1; then
43734         if test "$GNULIB_POSIX_SPAWNP" = 0; then
43735       GNULIB_POSIX_SPAWNP=$gl_module_indicator_condition
43736     else
43737       GNULIB_POSIX_SPAWNP="($GNULIB_POSIX_SPAWNP || $gl_module_indicator_condition)"
43738     fi
43739   fi
43740
43741
43742
43743
43744
43745 $as_echo "#define GNULIB_TEST_POSIX_SPAWNP 1" >>confdefs.h
43746
43747
43748
43749   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43750 /* end confdefs.h.  */
43751 [
43752   #if defined _MSC_VER || defined __MINGW32__
43753     notposix
43754   #endif
43755     ]
43756 _ACEOF
43757 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
43758   $EGREP "notposix" >/dev/null 2>&1; then :
43759   posix_spawn_ported=no
43760 else
43761   posix_spawn_ported=yes
43762 fi
43763 rm -f conftest*
43764
43765    if test $posix_spawn_ported = yes; then
43766   POSIX_SPAWN_PORTED_TRUE=
43767   POSIX_SPAWN_PORTED_FALSE='#'
43768 else
43769   POSIX_SPAWN_PORTED_TRUE='#'
43770   POSIX_SPAWN_PORTED_FALSE=
43771 fi
43772
43773   ac_fn_c_check_decl "$LINENO" "program_invocation_name" "ac_cv_have_decl_program_invocation_name" "#include <errno.h>
43774 "
43775 if test "x$ac_cv_have_decl_program_invocation_name" = xyes; then :
43776   ac_have_decl=1
43777 else
43778   ac_have_decl=0
43779 fi
43780
43781 cat >>confdefs.h <<_ACEOF
43782 #define HAVE_DECL_PROGRAM_INVOCATION_NAME $ac_have_decl
43783 _ACEOF
43784
43785   ac_fn_c_check_decl "$LINENO" "program_invocation_short_name" "ac_cv_have_decl_program_invocation_short_name" "#include <errno.h>
43786 "
43787 if test "x$ac_cv_have_decl_program_invocation_short_name" = xyes; then :
43788   ac_have_decl=1
43789 else
43790   ac_have_decl=0
43791 fi
43792
43793 cat >>confdefs.h <<_ACEOF
43794 #define HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME $ac_have_decl
43795 _ACEOF
43796
43797
43798
43799
43800
43801
43802   for ac_func in ptsname
43803 do :
43804   ac_fn_c_check_func "$LINENO" "ptsname" "ac_cv_func_ptsname"
43805 if test "x$ac_cv_func_ptsname" = xyes; then :
43806   cat >>confdefs.h <<_ACEOF
43807 #define HAVE_PTSNAME 1
43808 _ACEOF
43809
43810 fi
43811 done
43812
43813   if test $ac_cv_func_ptsname = no; then
43814     HAVE_PTSNAME=0
43815   else
43816     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ptsname sets errno on failure" >&5
43817 $as_echo_n "checking whether ptsname sets errno on failure... " >&6; }
43818 if ${gl_cv_func_ptsname_sets_errno+:} false; then :
43819   $as_echo_n "(cached) " >&6
43820 else
43821   if test "$cross_compiling" = yes; then :
43822   case "$host_os" in
43823                     # Guess yes on glibc systems.
43824             *-gnu*) gl_cv_func_ptsname_sets_errno="guessing yes" ;;
43825                     # If we don't know, assume the worst.
43826             *)      gl_cv_func_ptsname_sets_errno="guessing no" ;;
43827           esac
43828
43829 else
43830   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43831 /* end confdefs.h.  */
43832 #include <errno.h>
43833
43834 int
43835 main ()
43836 {
43837
43838       return ptsname (-1) || !errno;
43839
43840   ;
43841   return 0;
43842 }
43843 _ACEOF
43844 if ac_fn_c_try_run "$LINENO"; then :
43845   gl_cv_func_ptsname_sets_errno=yes
43846 else
43847   gl_cv_func_ptsname_sets_errno=no
43848 fi
43849 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
43850   conftest.$ac_objext conftest.beam conftest.$ac_ext
43851 fi
43852
43853 fi
43854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_ptsname_sets_errno" >&5
43855 $as_echo "$gl_cv_func_ptsname_sets_errno" >&6; }
43856     case $gl_cv_func_ptsname_sets_errno in
43857       *no) REPLACE_PTSNAME=1 ;;
43858     esac
43859   fi
43860
43861   if test $HAVE_PTSNAME = 0 || test $REPLACE_PTSNAME = 1; then
43862
43863
43864
43865
43866
43867
43868
43869
43870   gltests_LIBOBJS="$gltests_LIBOBJS ptsname.$ac_objext"
43871
43872
43873   :
43874
43875   fi
43876
43877
43878
43879
43880
43881     if test "$GNULIB_PTSNAME" != 1; then
43882         if test "$GNULIB_PTSNAME" = 0; then
43883       GNULIB_PTSNAME=$gl_module_indicator_condition
43884     else
43885       GNULIB_PTSNAME="($GNULIB_PTSNAME || $gl_module_indicator_condition)"
43886     fi
43887   fi
43888
43889
43890
43891
43892
43893 $as_echo "#define GNULIB_TEST_PTSNAME 1" >>confdefs.h
43894
43895
43896
43897
43898   :
43899
43900
43901
43902
43903
43904
43905
43906
43907
43908
43909
43910   :
43911
43912
43913
43914
43915
43916   if test $ac_cv_func_ptsname_r = no; then
43917     HAVE_PTSNAME_R=0
43918   else
43919             { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ptsname_r has the same signature as in glibc" >&5
43920 $as_echo_n "checking whether ptsname_r has the same signature as in glibc... " >&6; }
43921 if ${gl_cv_func_ptsname_r_signature_ok+:} false; then :
43922   $as_echo_n "(cached) " >&6
43923 else
43924   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43925 /* end confdefs.h.  */
43926 #include <stddef.h>
43927               #include <stdlib.h>
43928               /* Test whether ptsname_r is declared at all.  */
43929               int (*f) (int, char *, size_t) = ptsname_r;
43930               /* Test whether it has the same declaration as in glibc.  */
43931               #undef ptsname_r
43932               extern
43933               #ifdef __cplusplus
43934               "C"
43935               #endif
43936               int ptsname_r (int, char *, size_t);
43937
43938 int
43939 main ()
43940 {
43941 return f (0, NULL, 0);
43942   ;
43943   return 0;
43944 }
43945
43946 _ACEOF
43947 if ac_fn_c_try_compile "$LINENO"; then :
43948   gl_cv_func_ptsname_r_signature_ok=yes
43949 else
43950   gl_cv_func_ptsname_r_signature_ok=no
43951 fi
43952 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
43953
43954 fi
43955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_ptsname_r_signature_ok" >&5
43956 $as_echo "$gl_cv_func_ptsname_r_signature_ok" >&6; }
43957     if test $gl_cv_func_ptsname_r_signature_ok = no; then
43958       REPLACE_PTSNAME_R=1
43959     fi
43960   fi
43961
43962   if test $HAVE_PTSNAME_R = 0 || test $REPLACE_PTSNAME_R = 1; then
43963
43964
43965
43966
43967
43968
43969
43970
43971   gltests_LIBOBJS="$gltests_LIBOBJS ptsname_r.$ac_objext"
43972
43973
43974      { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether isatty sets errno when it fails" >&5
43975 $as_echo_n "checking whether isatty sets errno when it fails... " >&6; }
43976 if ${gl_cv_func_isatty_sets_errno+:} false; then :
43977   $as_echo_n "(cached) " >&6
43978 else
43979   if test "$cross_compiling" = yes; then :
43980   case "$host_os" in
43981           irix* | solaris* | mingw*)
43982             gl_cv_func_isatty_sets_errno="guessing no";;
43983           *)
43984             gl_cv_func_isatty_sets_errno="guessing yes";;
43985         esac
43986
43987 else
43988   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
43989 /* end confdefs.h.  */
43990 #include <errno.h>
43991             #if (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
43992             # include <io.h>
43993             #else
43994             # include <unistd.h>
43995             #endif
43996
43997 int
43998 main ()
43999 {
44000 errno = 0;
44001             isatty (-1);
44002             return errno == 0;
44003
44004   ;
44005   return 0;
44006 }
44007
44008 _ACEOF
44009 if ac_fn_c_try_run "$LINENO"; then :
44010   gl_cv_func_isatty_sets_errno=yes
44011 else
44012   gl_cv_func_isatty_sets_errno=no
44013 fi
44014 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
44015   conftest.$ac_objext conftest.beam conftest.$ac_ext
44016 fi
44017
44018
44019 fi
44020 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_isatty_sets_errno" >&5
44021 $as_echo "$gl_cv_func_isatty_sets_errno" >&6; }
44022   case "$gl_cv_func_isatty_sets_errno" in
44023     *yes) ;;
44024     *)
44025
44026 $as_echo "#define ISATTY_FAILS_WITHOUT_SETTING_ERRNO 1" >>confdefs.h
44027
44028       ;;
44029   esac
44030
44031   fi
44032
44033
44034
44035
44036
44037     if test "$GNULIB_PTSNAME_R" != 1; then
44038         if test "$GNULIB_PTSNAME_R" = 0; then
44039       GNULIB_PTSNAME_R=$gl_module_indicator_condition
44040     else
44041       GNULIB_PTSNAME_R="($GNULIB_PTSNAME_R || $gl_module_indicator_condition)"
44042     fi
44043   fi
44044
44045
44046
44047
44048
44049 $as_echo "#define GNULIB_TEST_PTSNAME_R 1" >>confdefs.h
44050
44051
44052
44053
44054   :
44055
44056
44057
44058
44059
44060
44061
44062      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for putenv compatible with GNU and SVID" >&5
44063 $as_echo_n "checking for putenv compatible with GNU and SVID... " >&6; }
44064 if ${gl_cv_func_svid_putenv+:} false; then :
44065   $as_echo_n "(cached) " >&6
44066 else
44067   if test "$cross_compiling" = yes; then :
44068                case "$host_os" in
44069                         # Guess yes on glibc systems.
44070                 *-gnu*) gl_cv_func_svid_putenv="guessing yes" ;;
44071                         # If we don't know, assume the worst.
44072                 *)      gl_cv_func_svid_putenv="guessing no" ;;
44073               esac
44074
44075 else
44076   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
44077 /* end confdefs.h.  */
44078 $ac_includes_default
44079 int
44080 main ()
44081 {
44082
44083     /* Put it in env.  */
44084     if (putenv ("CONFTEST_putenv=val"))
44085       return 1;
44086
44087     /* Try to remove it.  */
44088     if (putenv ("CONFTEST_putenv"))
44089       return 2;
44090
44091     /* Make sure it was deleted.  */
44092     if (getenv ("CONFTEST_putenv") != 0)
44093       return 3;
44094
44095     return 0;
44096
44097   ;
44098   return 0;
44099 }
44100 _ACEOF
44101 if ac_fn_c_try_run "$LINENO"; then :
44102   gl_cv_func_svid_putenv=yes
44103 else
44104   gl_cv_func_svid_putenv=no
44105 fi
44106 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
44107   conftest.$ac_objext conftest.beam conftest.$ac_ext
44108 fi
44109
44110
44111 fi
44112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_svid_putenv" >&5
44113 $as_echo "$gl_cv_func_svid_putenv" >&6; }
44114   case "$gl_cv_func_svid_putenv" in
44115     *yes) ;;
44116     *)
44117       REPLACE_PUTENV=1
44118       ;;
44119   esac
44120
44121   if test $REPLACE_PUTENV = 1; then
44122
44123
44124
44125
44126
44127
44128
44129
44130   gltests_LIBOBJS="$gltests_LIBOBJS putenv.$ac_objext"
44131
44132
44133   ac_fn_c_check_decl "$LINENO" "_putenv" "ac_cv_have_decl__putenv" "$ac_includes_default"
44134 if test "x$ac_cv_have_decl__putenv" = xyes; then :
44135   ac_have_decl=1
44136 else
44137   ac_have_decl=0
44138 fi
44139
44140 cat >>confdefs.h <<_ACEOF
44141 #define HAVE_DECL__PUTENV $ac_have_decl
44142 _ACEOF
44143
44144
44145   fi
44146
44147
44148
44149
44150
44151     if test "$GNULIB_PUTENV" != 1; then
44152         if test "$GNULIB_PUTENV" = 0; then
44153       GNULIB_PUTENV=$gl_module_indicator_condition
44154     else
44155       GNULIB_PUTENV="($GNULIB_PUTENV || $gl_module_indicator_condition)"
44156     fi
44157   fi
44158
44159
44160
44161
44162
44163 $as_echo "#define GNULIB_TEST_PUTENV 1" >>confdefs.h
44164
44165
44166
44167
44168
44169
44170   # Check for mmap(). Don't use AC_FUNC_MMAP, because it checks too much: it
44171   # fails on HP-UX 11, because MAP_FIXED mappings do not work. But this is
44172   # irrelevant for anonymous mappings.
44173   ac_fn_c_check_func "$LINENO" "mmap" "ac_cv_func_mmap"
44174 if test "x$ac_cv_func_mmap" = xyes; then :
44175   gl_have_mmap=yes
44176 else
44177   gl_have_mmap=no
44178 fi
44179
44180
44181   # Try to allow MAP_ANONYMOUS.
44182   gl_have_mmap_anonymous=no
44183   if test $gl_have_mmap = yes; then
44184     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MAP_ANONYMOUS" >&5
44185 $as_echo_n "checking for MAP_ANONYMOUS... " >&6; }
44186     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
44187 /* end confdefs.h.  */
44188
44189 #include <sys/mman.h>
44190 #ifdef MAP_ANONYMOUS
44191     I cannot identify this map
44192 #endif
44193
44194 _ACEOF
44195 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
44196   $EGREP "I cannot identify this map" >/dev/null 2>&1; then :
44197   gl_have_mmap_anonymous=yes
44198 fi
44199 rm -f conftest*
44200
44201     if test $gl_have_mmap_anonymous != yes; then
44202       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
44203 /* end confdefs.h.  */
44204
44205 #include <sys/mman.h>
44206 #ifdef MAP_ANON
44207     I cannot identify this map
44208 #endif
44209
44210 _ACEOF
44211 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
44212   $EGREP "I cannot identify this map" >/dev/null 2>&1; then :
44213
44214 $as_echo "#define MAP_ANONYMOUS MAP_ANON" >>confdefs.h
44215
44216          gl_have_mmap_anonymous=yes
44217 fi
44218 rm -f conftest*
44219
44220     fi
44221     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_have_mmap_anonymous" >&5
44222 $as_echo "$gl_have_mmap_anonymous" >&6; }
44223     if test $gl_have_mmap_anonymous = yes; then
44224
44225 $as_echo "#define HAVE_MAP_ANONYMOUS 1" >>confdefs.h
44226
44227     fi
44228   fi
44229
44230
44231   :
44232
44233
44234
44235
44236
44237
44238   :
44239
44240
44241
44242
44243
44244
44245
44246
44247   if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
44248     REPLACE_READ=1
44249   fi
44250
44251
44252
44253
44254     if test $gl_cv_have_nonblocking != yes; then
44255       REPLACE_READ=1
44256     fi
44257
44258
44259   if test $REPLACE_READ = 1; then
44260
44261
44262
44263
44264
44265
44266
44267
44268   gltests_LIBOBJS="$gltests_LIBOBJS read.$ac_objext"
44269
44270     :
44271   fi
44272
44273
44274
44275
44276
44277     if test "$GNULIB_READ" != 1; then
44278         if test "$GNULIB_READ" = 0; then
44279       GNULIB_READ=$gl_module_indicator_condition
44280     else
44281       GNULIB_READ="($GNULIB_READ || $gl_module_indicator_condition)"
44282     fi
44283   fi
44284
44285
44286
44287
44288
44289 $as_echo "#define GNULIB_TEST_READ 1" >>confdefs.h
44290
44291
44292
44293
44294   :
44295
44296
44297
44298
44299
44300
44301
44302
44303   case "$host_os" in
44304             mingw*) REPLACE_SETLOCALE=1 ;;
44305             cygwin*)
44306       case `uname -r` in
44307         1.5.*) REPLACE_SETLOCALE=1 ;;
44308       esac
44309       ;;
44310   esac
44311
44312   if test $REPLACE_SETLOCALE = 1; then
44313
44314
44315
44316
44317
44318
44319
44320
44321   gltests_LIBOBJS="$gltests_LIBOBJS setlocale.$ac_objext"
44322
44323
44324   :
44325
44326   fi
44327
44328
44329
44330
44331
44332     if test "$GNULIB_SETLOCALE" != 1; then
44333         if test "$GNULIB_SETLOCALE" = 0; then
44334       GNULIB_SETLOCALE=$gl_module_indicator_condition
44335     else
44336       GNULIB_SETLOCALE="($GNULIB_SETLOCALE || $gl_module_indicator_condition)"
44337     fi
44338   fi
44339
44340
44341
44342
44343
44344 $as_echo "#define GNULIB_TEST_SETLOCALE 1" >>confdefs.h
44345
44346
44347
44348
44349
44350
44351   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a traditional french locale" >&5
44352 $as_echo_n "checking for a traditional french locale... " >&6; }
44353 if ${gt_cv_locale_fr+:} false; then :
44354   $as_echo_n "(cached) " >&6
44355 else
44356
44357     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
44358 /* end confdefs.h.  */
44359
44360 #include <locale.h>
44361 #include <time.h>
44362 #if HAVE_LANGINFO_CODESET
44363 # include <langinfo.h>
44364 #endif
44365 #include <stdlib.h>
44366 #include <string.h>
44367 struct tm t;
44368 char buf[16];
44369 int main () {
44370   /* Check whether the given locale name is recognized by the system.  */
44371 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
44372   /* On native Windows, setlocale(category, "") looks at the system settings,
44373      not at the environment variables.  Also, when an encoding suffix such
44374      as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
44375      category of the locale to "C".  */
44376   if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
44377       || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
44378     return 1;
44379 #else
44380   if (setlocale (LC_ALL, "") == NULL) return 1;
44381 #endif
44382   /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
44383      On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
44384      is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
44385      On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
44386      succeeds but then nl_langinfo(CODESET) is "646". In this situation,
44387      some unit tests fail.
44388      On MirBSD 10, when an unsupported locale is specified, setlocale()
44389      succeeds but then nl_langinfo(CODESET) is "UTF-8".  */
44390 #if HAVE_LANGINFO_CODESET
44391   {
44392     const char *cs = nl_langinfo (CODESET);
44393     if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
44394         || strcmp (cs, "UTF-8") == 0)
44395       return 1;
44396   }
44397 #endif
44398 #ifdef __CYGWIN__
44399   /* On Cygwin, avoid locale names without encoding suffix, because the
44400      locale_charset() function relies on the encoding suffix.  Note that
44401      LC_ALL is set on the command line.  */
44402   if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
44403 #endif
44404   /* Check whether in the abbreviation of the second month, the second
44405      character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is only
44406      one byte long. This excludes the UTF-8 encoding.  */
44407   t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
44408   if (strftime (buf, sizeof (buf), "%b", &t) < 3 || buf[2] != 'v') return 1;
44409 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy.  */
44410   /* Check whether the decimal separator is a comma.
44411      On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
44412      are nl_langinfo(RADIXCHAR) are both ".".  */
44413   if (localeconv () ->decimal_point[0] != ',') return 1;
44414 #endif
44415   return 0;
44416 }
44417
44418 _ACEOF
44419     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
44420   (eval $ac_link) 2>&5
44421   ac_status=$?
44422   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
44423   test $ac_status = 0; } && test -s conftest$ac_exeext; then
44424       case "$host_os" in
44425         # Handle native Windows specially, because there setlocale() interprets
44426         # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
44427         # "fr" or "fra" as "French" or "French_France.1252",
44428         # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
44429         # "ja" as "Japanese" or "Japanese_Japan.932",
44430         # and similar.
44431         mingw*)
44432           # Test for the native Windows locale name.
44433           if (LC_ALL=French_France.1252 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
44434             gt_cv_locale_fr=French_France.1252
44435           else
44436             # None found.
44437             gt_cv_locale_fr=none
44438           fi
44439           ;;
44440         *)
44441           # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
44442           # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
44443           # configure script would override the LC_ALL setting. Likewise for
44444           # LC_CTYPE, which is also set at the beginning of the configure script.
44445           # Test for the usual locale name.
44446           if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
44447             gt_cv_locale_fr=fr_FR
44448           else
44449             # Test for the locale name with explicit encoding suffix.
44450             if (LC_ALL=fr_FR.ISO-8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
44451               gt_cv_locale_fr=fr_FR.ISO-8859-1
44452             else
44453               # Test for the AIX, OSF/1, FreeBSD, NetBSD, OpenBSD locale name.
44454               if (LC_ALL=fr_FR.ISO8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
44455                 gt_cv_locale_fr=fr_FR.ISO8859-1
44456               else
44457                 # Test for the HP-UX locale name.
44458                 if (LC_ALL=fr_FR.iso88591 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
44459                   gt_cv_locale_fr=fr_FR.iso88591
44460                 else
44461                   # Test for the Solaris 7 locale name.
44462                   if (LC_ALL=fr LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
44463                     gt_cv_locale_fr=fr
44464                   else
44465                     # None found.
44466                     gt_cv_locale_fr=none
44467                   fi
44468                 fi
44469               fi
44470             fi
44471           fi
44472           ;;
44473       esac
44474     fi
44475     rm -fr conftest*
44476
44477 fi
44478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr" >&5
44479 $as_echo "$gt_cv_locale_fr" >&6; }
44480   LOCALE_FR=$gt_cv_locale_fr
44481
44482
44483
44484
44485   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a french Unicode locale" >&5
44486 $as_echo_n "checking for a french Unicode locale... " >&6; }
44487 if ${gt_cv_locale_fr_utf8+:} false; then :
44488   $as_echo_n "(cached) " >&6
44489 else
44490
44491     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
44492 /* end confdefs.h.  */
44493
44494 #include <locale.h>
44495 #include <time.h>
44496 #if HAVE_LANGINFO_CODESET
44497 # include <langinfo.h>
44498 #endif
44499 #include <stdlib.h>
44500 #include <string.h>
44501 struct tm t;
44502 char buf[16];
44503 int main () {
44504   /* On BeOS and Haiku, locales are not implemented in libc.  Rather, libintl
44505      imitates locale dependent behaviour by looking at the environment
44506      variables, and all locales use the UTF-8 encoding.  */
44507 #if !(defined __BEOS__ || defined __HAIKU__)
44508   /* Check whether the given locale name is recognized by the system.  */
44509 # if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
44510   /* On native Windows, setlocale(category, "") looks at the system settings,
44511      not at the environment variables.  Also, when an encoding suffix such
44512      as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
44513      category of the locale to "C".  */
44514   if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
44515       || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
44516     return 1;
44517 # else
44518   if (setlocale (LC_ALL, "") == NULL) return 1;
44519 # endif
44520   /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
44521      On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
44522      is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
44523      On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
44524      succeeds but then nl_langinfo(CODESET) is "646". In this situation,
44525      some unit tests fail.  */
44526 # if HAVE_LANGINFO_CODESET
44527   {
44528     const char *cs = nl_langinfo (CODESET);
44529     if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0)
44530       return 1;
44531   }
44532 # endif
44533 # ifdef __CYGWIN__
44534   /* On Cygwin, avoid locale names without encoding suffix, because the
44535      locale_charset() function relies on the encoding suffix.  Note that
44536      LC_ALL is set on the command line.  */
44537   if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
44538 # endif
44539   /* Check whether in the abbreviation of the second month, the second
44540      character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is
44541      two bytes long, with UTF-8 encoding.  */
44542   t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
44543   if (strftime (buf, sizeof (buf), "%b", &t) < 4
44544       || buf[1] != (char) 0xc3 || buf[2] != (char) 0xa9 || buf[3] != 'v')
44545     return 1;
44546 #endif
44547 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy.  */
44548   /* Check whether the decimal separator is a comma.
44549      On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
44550      are nl_langinfo(RADIXCHAR) are both ".".  */
44551   if (localeconv () ->decimal_point[0] != ',') return 1;
44552 #endif
44553   return 0;
44554 }
44555
44556 _ACEOF
44557     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
44558   (eval $ac_link) 2>&5
44559   ac_status=$?
44560   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
44561   test $ac_status = 0; } && test -s conftest$ac_exeext; then
44562       case "$host_os" in
44563         # Handle native Windows specially, because there setlocale() interprets
44564         # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
44565         # "fr" or "fra" as "French" or "French_France.1252",
44566         # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
44567         # "ja" as "Japanese" or "Japanese_Japan.932",
44568         # and similar.
44569         mingw*)
44570           # Test for the hypothetical native Windows locale name.
44571           if (LC_ALL=French_France.65001 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
44572             gt_cv_locale_fr_utf8=French_France.65001
44573           else
44574             # None found.
44575             gt_cv_locale_fr_utf8=none
44576           fi
44577           ;;
44578         *)
44579           # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
44580           # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
44581           # configure script would override the LC_ALL setting. Likewise for
44582           # LC_CTYPE, which is also set at the beginning of the configure script.
44583           # Test for the usual locale name.
44584           if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
44585             gt_cv_locale_fr_utf8=fr_FR
44586           else
44587             # Test for the locale name with explicit encoding suffix.
44588             if (LC_ALL=fr_FR.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
44589               gt_cv_locale_fr_utf8=fr_FR.UTF-8
44590             else
44591               # Test for the Solaris 7 locale name.
44592               if (LC_ALL=fr.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
44593                 gt_cv_locale_fr_utf8=fr.UTF-8
44594               else
44595                 # None found.
44596                 gt_cv_locale_fr_utf8=none
44597               fi
44598             fi
44599           fi
44600           ;;
44601       esac
44602     fi
44603     rm -fr conftest*
44604
44605 fi
44606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr_utf8" >&5
44607 $as_echo "$gt_cv_locale_fr_utf8" >&6; }
44608   LOCALE_FR_UTF8=$gt_cv_locale_fr_utf8
44609
44610
44611
44612
44613
44614   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a traditional japanese locale" >&5
44615 $as_echo_n "checking for a traditional japanese locale... " >&6; }
44616 if ${gt_cv_locale_ja+:} false; then :
44617   $as_echo_n "(cached) " >&6
44618 else
44619
44620     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
44621 /* end confdefs.h.  */
44622
44623 #include <locale.h>
44624 #include <time.h>
44625 #if HAVE_LANGINFO_CODESET
44626 # include <langinfo.h>
44627 #endif
44628 #include <stdlib.h>
44629 #include <string.h>
44630 struct tm t;
44631 char buf[16];
44632 int main ()
44633 {
44634   const char *p;
44635   /* Check whether the given locale name is recognized by the system.  */
44636 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
44637   /* On native Windows, setlocale(category, "") looks at the system settings,
44638      not at the environment variables.  Also, when an encoding suffix such
44639      as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
44640      category of the locale to "C".  */
44641   if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
44642       || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
44643     return 1;
44644 #else
44645   if (setlocale (LC_ALL, "") == NULL) return 1;
44646 #endif
44647   /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
44648      On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
44649      is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
44650      On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
44651      succeeds but then nl_langinfo(CODESET) is "646". In this situation,
44652      some unit tests fail.
44653      On MirBSD 10, when an unsupported locale is specified, setlocale()
44654      succeeds but then nl_langinfo(CODESET) is "UTF-8".  */
44655 #if HAVE_LANGINFO_CODESET
44656   {
44657     const char *cs = nl_langinfo (CODESET);
44658     if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
44659         || strcmp (cs, "UTF-8") == 0)
44660       return 1;
44661   }
44662 #endif
44663 #ifdef __CYGWIN__
44664   /* On Cygwin, avoid locale names without encoding suffix, because the
44665      locale_charset() function relies on the encoding suffix.  Note that
44666      LC_ALL is set on the command line.  */
44667   if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
44668 #endif
44669   /* Check whether MB_CUR_MAX is > 1.  This excludes the dysfunctional locales
44670      on Cygwin 1.5.x.  */
44671   if (MB_CUR_MAX == 1)
44672     return 1;
44673   /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
44674      This excludes the UTF-8 encoding (except on MirBSD).  */
44675   t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
44676   if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
44677   for (p = buf; *p != '\0'; p++)
44678     if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
44679       return 1;
44680   return 0;
44681 }
44682
44683 _ACEOF
44684     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
44685   (eval $ac_link) 2>&5
44686   ac_status=$?
44687   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
44688   test $ac_status = 0; } && test -s conftest$ac_exeext; then
44689       case "$host_os" in
44690         # Handle native Windows specially, because there setlocale() interprets
44691         # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
44692         # "fr" or "fra" as "French" or "French_France.1252",
44693         # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
44694         # "ja" as "Japanese" or "Japanese_Japan.932",
44695         # and similar.
44696         mingw*)
44697           # Note that on native Windows, the Japanese locale is
44698           # Japanese_Japan.932, and CP932 is very different from EUC-JP, so we
44699           # cannot use it here.
44700           gt_cv_locale_ja=none
44701           ;;
44702         *)
44703           # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
44704           # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
44705           # configure script would override the LC_ALL setting. Likewise for
44706           # LC_CTYPE, which is also set at the beginning of the configure script.
44707           # Test for the AIX locale name.
44708           if (LC_ALL=ja_JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
44709             gt_cv_locale_ja=ja_JP
44710           else
44711             # Test for the locale name with explicit encoding suffix.
44712             if (LC_ALL=ja_JP.EUC-JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
44713               gt_cv_locale_ja=ja_JP.EUC-JP
44714             else
44715               # Test for the HP-UX, OSF/1, NetBSD locale name.
44716               if (LC_ALL=ja_JP.eucJP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
44717                 gt_cv_locale_ja=ja_JP.eucJP
44718               else
44719                 # Test for the IRIX, FreeBSD locale name.
44720                 if (LC_ALL=ja_JP.EUC LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
44721                   gt_cv_locale_ja=ja_JP.EUC
44722                 else
44723                   # Test for the Solaris 7 locale name.
44724                   if (LC_ALL=ja LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
44725                     gt_cv_locale_ja=ja
44726                   else
44727                     # Special test for NetBSD 1.6.
44728                     if test -f /usr/share/locale/ja_JP.eucJP/LC_CTYPE; then
44729                       gt_cv_locale_ja=ja_JP.eucJP
44730                     else
44731                       # None found.
44732                       gt_cv_locale_ja=none
44733                     fi
44734                   fi
44735                 fi
44736               fi
44737             fi
44738           fi
44739           ;;
44740       esac
44741     fi
44742     rm -fr conftest*
44743
44744 fi
44745 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_ja" >&5
44746 $as_echo "$gt_cv_locale_ja" >&6; }
44747   LOCALE_JA=$gt_cv_locale_ja
44748
44749
44750
44751
44752
44753   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a transitional chinese locale" >&5
44754 $as_echo_n "checking for a transitional chinese locale... " >&6; }
44755 if ${gt_cv_locale_zh_CN+:} false; then :
44756   $as_echo_n "(cached) " >&6
44757 else
44758
44759     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
44760 /* end confdefs.h.  */
44761
44762 #include <locale.h>
44763 #include <stdlib.h>
44764 #include <time.h>
44765 #if HAVE_LANGINFO_CODESET
44766 # include <langinfo.h>
44767 #endif
44768 #include <stdlib.h>
44769 #include <string.h>
44770 struct tm t;
44771 char buf[16];
44772 int main ()
44773 {
44774   const char *p;
44775   /* Check whether the given locale name is recognized by the system.  */
44776 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
44777   /* On native Windows, setlocale(category, "") looks at the system settings,
44778      not at the environment variables.  Also, when an encoding suffix such
44779      as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
44780      category of the locale to "C".  */
44781   if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
44782       || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
44783     return 1;
44784 #else
44785   if (setlocale (LC_ALL, "") == NULL) return 1;
44786 #endif
44787   /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
44788      On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
44789      is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
44790      On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
44791      succeeds but then nl_langinfo(CODESET) is "646". In this situation,
44792      some unit tests fail.
44793      On MirBSD 10, when an unsupported locale is specified, setlocale()
44794      succeeds but then nl_langinfo(CODESET) is "UTF-8".  */
44795 #if HAVE_LANGINFO_CODESET
44796   {
44797     const char *cs = nl_langinfo (CODESET);
44798     if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
44799         || strcmp (cs, "UTF-8") == 0)
44800       return 1;
44801   }
44802 #endif
44803 #ifdef __CYGWIN__
44804   /* On Cygwin, avoid locale names without encoding suffix, because the
44805      locale_charset() function relies on the encoding suffix.  Note that
44806      LC_ALL is set on the command line.  */
44807   if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
44808 #endif
44809   /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
44810      This excludes the UTF-8 encoding (except on MirBSD).  */
44811   t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
44812   if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
44813   for (p = buf; *p != '\0'; p++)
44814     if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
44815       return 1;
44816   /* Check whether a typical GB18030 multibyte sequence is recognized as a
44817      single wide character.  This excludes the GB2312 and GBK encodings.  */
44818   if (mblen ("\203\062\332\066", 5) != 4)
44819     return 1;
44820   return 0;
44821 }
44822
44823 _ACEOF
44824     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
44825   (eval $ac_link) 2>&5
44826   ac_status=$?
44827   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
44828   test $ac_status = 0; } && test -s conftest$ac_exeext; then
44829       case "$host_os" in
44830         # Handle native Windows specially, because there setlocale() interprets
44831         # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
44832         # "fr" or "fra" as "French" or "French_France.1252",
44833         # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
44834         # "ja" as "Japanese" or "Japanese_Japan.932",
44835         # and similar.
44836         mingw*)
44837           # Test for the hypothetical native Windows locale name.
44838           if (LC_ALL=Chinese_China.54936 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
44839             gt_cv_locale_zh_CN=Chinese_China.54936
44840           else
44841             # None found.
44842             gt_cv_locale_zh_CN=none
44843           fi
44844           ;;
44845         solaris2.8)
44846           # On Solaris 8, the locales zh_CN.GB18030, zh_CN.GBK, zh.GBK are
44847           # broken. One witness is the test case in gl_MBRTOWC_SANITYCHECK.
44848           # Another witness is that "LC_ALL=zh_CN.GB18030 bash -c true" dumps core.
44849           gt_cv_locale_zh_CN=none
44850           ;;
44851         *)
44852           # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
44853           # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
44854           # configure script would override the LC_ALL setting. Likewise for
44855           # LC_CTYPE, which is also set at the beginning of the configure script.
44856           # Test for the locale name without encoding suffix.
44857           if (LC_ALL=zh_CN LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
44858             gt_cv_locale_zh_CN=zh_CN
44859           else
44860             # Test for the locale name with explicit encoding suffix.
44861             if (LC_ALL=zh_CN.GB18030 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
44862               gt_cv_locale_zh_CN=zh_CN.GB18030
44863             else
44864               # None found.
44865               gt_cv_locale_zh_CN=none
44866             fi
44867           fi
44868           ;;
44869       esac
44870     else
44871       # If there was a link error, due to mblen(), the system is so old that
44872       # it certainly doesn't have a chinese locale.
44873       gt_cv_locale_zh_CN=none
44874     fi
44875     rm -fr conftest*
44876
44877 fi
44878 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_zh_CN" >&5
44879 $as_echo "$gt_cv_locale_zh_CN" >&6; }
44880   LOCALE_ZH_CN=$gt_cv_locale_zh_CN
44881
44882
44883
44884
44885      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for signbit macro" >&5
44886 $as_echo_n "checking for signbit macro... " >&6; }
44887 if ${gl_cv_func_signbit+:} false; then :
44888   $as_echo_n "(cached) " >&6
44889 else
44890
44891       if test "$cross_compiling" = yes; then :
44892   case "$host_os" in
44893                    # Guess yes on glibc systems.
44894            *-gnu*) gl_cv_func_signbit="guessing yes" ;;
44895                    # If we don't know, assume the worst.
44896            *)      gl_cv_func_signbit="guessing no" ;;
44897          esac
44898
44899 else
44900   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
44901 /* end confdefs.h.  */
44902
44903 #include <math.h>
44904 /* If signbit is defined as a function, don't use it, since calling it for
44905    'float' or 'long double' arguments would involve conversions.
44906    If signbit is not declared at all but exists as a library function, don't
44907    use it, since the prototype may not match.
44908    If signbit is not declared at all but exists as a compiler built-in, don't
44909    use it, since it's preferable to use __builtin_signbit* (no warnings,
44910    no conversions).  */
44911 #ifndef signbit
44912 # error "signbit should be a macro"
44913 #endif
44914 #include <string.h>
44915
44916 /* Global variables.
44917    Needed because GCC 4 constant-folds __builtin_signbitl (literal)
44918    but cannot constant-fold            __builtin_signbitl (variable).  */
44919 float vf;
44920 double vd;
44921 long double vl;
44922 int main ()
44923 {
44924 /* HP cc on HP-UX 10.20 has a bug with the constant expression -0.0.
44925    So we use -p0f and -p0d instead.  */
44926 float p0f = 0.0f;
44927 float m0f = -p0f;
44928 double p0d = 0.0;
44929 double m0d = -p0d;
44930 /* On HP-UX 10.20, negating 0.0L does not yield -0.0L.
44931    So we use another constant expression instead.
44932    But that expression does not work on other platforms, such as when
44933    cross-compiling to PowerPC on Mac OS X 10.5.  */
44934 long double p0l = 0.0L;
44935 #if defined __hpux || defined __sgi
44936 long double m0l = -LDBL_MIN * LDBL_MIN;
44937 #else
44938 long double m0l = -p0l;
44939 #endif
44940   int result = 0;
44941   if (signbit (vf)) /* link check */
44942     vf++;
44943   {
44944     float plus_inf = 1.0f / p0f;
44945     float minus_inf = -1.0f / p0f;
44946     if (!(!signbit (255.0f)
44947           && signbit (-255.0f)
44948           && !signbit (p0f)
44949           && (memcmp (&m0f, &p0f, sizeof (float)) == 0 || signbit (m0f))
44950           && !signbit (plus_inf)
44951           && signbit (minus_inf)))
44952       result |= 1;
44953   }
44954   if (signbit (vd)) /* link check */
44955     vd++;
44956   {
44957     double plus_inf = 1.0 / p0d;
44958     double minus_inf = -1.0 / p0d;
44959     if (!(!signbit (255.0)
44960           && signbit (-255.0)
44961           && !signbit (p0d)
44962           && (memcmp (&m0d, &p0d, sizeof (double)) == 0 || signbit (m0d))
44963           && !signbit (plus_inf)
44964           && signbit (minus_inf)))
44965       result |= 2;
44966   }
44967   if (signbit (vl)) /* link check */
44968     vl++;
44969   {
44970     long double plus_inf = 1.0L / p0l;
44971     long double minus_inf = -1.0L / p0l;
44972     if (signbit (255.0L))
44973       result |= 4;
44974     if (!signbit (-255.0L))
44975       result |= 4;
44976     if (signbit (p0l))
44977       result |= 8;
44978     if (!(memcmp (&m0l, &p0l, sizeof (long double)) == 0 || signbit (m0l)))
44979       result |= 16;
44980     if (signbit (plus_inf))
44981       result |= 32;
44982     if (!signbit (minus_inf))
44983       result |= 64;
44984   }
44985   return result;
44986 }
44987
44988
44989 _ACEOF
44990 if ac_fn_c_try_run "$LINENO"; then :
44991   gl_cv_func_signbit=yes
44992 else
44993   gl_cv_func_signbit=no
44994 fi
44995 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
44996   conftest.$ac_objext conftest.beam conftest.$ac_ext
44997 fi
44998
44999
45000 fi
45001 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_signbit" >&5
45002 $as_echo "$gl_cv_func_signbit" >&6; }
45003           { $as_echo "$as_me:${as_lineno-$LINENO}: checking for signbit compiler built-ins" >&5
45004 $as_echo_n "checking for signbit compiler built-ins... " >&6; }
45005 if ${gl_cv_func_signbit_gcc+:} false; then :
45006   $as_echo_n "(cached) " >&6
45007 else
45008
45009       if test "$cross_compiling" = yes; then :
45010   case "$host_os" in
45011                    # Guess yes on glibc systems.
45012            *-gnu*) gl_cv_func_signbit_gcc="guessing yes" ;;
45013                    # If we don't know, assume the worst.
45014            *)      gl_cv_func_signbit_gcc="guessing no" ;;
45015          esac
45016
45017 else
45018   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
45019 /* end confdefs.h.  */
45020
45021 #if __GNUC__ >= 4
45022 # define signbit(x) \
45023    (sizeof (x) == sizeof (long double) ? __builtin_signbitl (x) : \
45024     sizeof (x) == sizeof (double) ? __builtin_signbit (x) : \
45025     __builtin_signbitf (x))
45026 #else
45027 # error "signbit should be three compiler built-ins"
45028 #endif
45029 #include <string.h>
45030
45031 /* Global variables.
45032    Needed because GCC 4 constant-folds __builtin_signbitl (literal)
45033    but cannot constant-fold            __builtin_signbitl (variable).  */
45034 float vf;
45035 double vd;
45036 long double vl;
45037 int main ()
45038 {
45039 /* HP cc on HP-UX 10.20 has a bug with the constant expression -0.0.
45040    So we use -p0f and -p0d instead.  */
45041 float p0f = 0.0f;
45042 float m0f = -p0f;
45043 double p0d = 0.0;
45044 double m0d = -p0d;
45045 /* On HP-UX 10.20, negating 0.0L does not yield -0.0L.
45046    So we use another constant expression instead.
45047    But that expression does not work on other platforms, such as when
45048    cross-compiling to PowerPC on Mac OS X 10.5.  */
45049 long double p0l = 0.0L;
45050 #if defined __hpux || defined __sgi
45051 long double m0l = -LDBL_MIN * LDBL_MIN;
45052 #else
45053 long double m0l = -p0l;
45054 #endif
45055   int result = 0;
45056   if (signbit (vf)) /* link check */
45057     vf++;
45058   {
45059     float plus_inf = 1.0f / p0f;
45060     float minus_inf = -1.0f / p0f;
45061     if (!(!signbit (255.0f)
45062           && signbit (-255.0f)
45063           && !signbit (p0f)
45064           && (memcmp (&m0f, &p0f, sizeof (float)) == 0 || signbit (m0f))
45065           && !signbit (plus_inf)
45066           && signbit (minus_inf)))
45067       result |= 1;
45068   }
45069   if (signbit (vd)) /* link check */
45070     vd++;
45071   {
45072     double plus_inf = 1.0 / p0d;
45073     double minus_inf = -1.0 / p0d;
45074     if (!(!signbit (255.0)
45075           && signbit (-255.0)
45076           && !signbit (p0d)
45077           && (memcmp (&m0d, &p0d, sizeof (double)) == 0 || signbit (m0d))
45078           && !signbit (plus_inf)
45079           && signbit (minus_inf)))
45080       result |= 2;
45081   }
45082   if (signbit (vl)) /* link check */
45083     vl++;
45084   {
45085     long double plus_inf = 1.0L / p0l;
45086     long double minus_inf = -1.0L / p0l;
45087     if (signbit (255.0L))
45088       result |= 4;
45089     if (!signbit (-255.0L))
45090       result |= 4;
45091     if (signbit (p0l))
45092       result |= 8;
45093     if (!(memcmp (&m0l, &p0l, sizeof (long double)) == 0 || signbit (m0l)))
45094       result |= 16;
45095     if (signbit (plus_inf))
45096       result |= 32;
45097     if (!signbit (minus_inf))
45098       result |= 64;
45099   }
45100   return result;
45101 }
45102
45103
45104 _ACEOF
45105 if ac_fn_c_try_run "$LINENO"; then :
45106   gl_cv_func_signbit_gcc=yes
45107 else
45108   gl_cv_func_signbit_gcc=no
45109 fi
45110 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
45111   conftest.$ac_objext conftest.beam conftest.$ac_ext
45112 fi
45113
45114
45115 fi
45116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_signbit_gcc" >&5
45117 $as_echo "$gl_cv_func_signbit_gcc" >&6; }
45118       case "$gl_cv_func_signbit_gcc" in
45119     *yes)
45120       REPLACE_SIGNBIT_USING_GCC=1
45121       ;;
45122     *)
45123       case "$gl_cv_func_signbit" in
45124         *yes) ;;
45125         *)
45126                     REPLACE_SIGNBIT=1
45127
45128
45129   { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the sign bit in a 'float'" >&5
45130 $as_echo_n "checking where to find the sign bit in a 'float'... " >&6; }
45131 if ${gl_cv_cc_float_signbit+:} false; then :
45132   $as_echo_n "(cached) " >&6
45133 else
45134
45135       if test "$cross_compiling" = yes; then :
45136
45137                               gl_cv_cc_float_signbit="unknown"
45138
45139 else
45140   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
45141 /* end confdefs.h.  */
45142
45143 #include <stddef.h>
45144 #include <stdio.h>
45145 #define NWORDS \
45146   ((sizeof (float) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
45147 typedef union { float value; unsigned int word[NWORDS]; }
45148         memory_float;
45149 static memory_float plus = { 1.0f };
45150 static memory_float minus = { -1.0f };
45151 int main ()
45152 {
45153   size_t j, k, i;
45154   unsigned int m;
45155   FILE *fp = fopen ("conftest.out", "w");
45156   if (fp == NULL)
45157     return 1;
45158   /* Find the different bit.  */
45159   k = 0; m = 0;
45160   for (j = 0; j < NWORDS; j++)
45161     {
45162       unsigned int x = plus.word[j] ^ minus.word[j];
45163       if ((x & (x - 1)) || (x && m))
45164         {
45165           /* More than one bit difference.  */
45166           fprintf (fp, "unknown");
45167           return 2;
45168         }
45169       if (x)
45170         {
45171           k = j;
45172           m = x;
45173         }
45174     }
45175   if (m == 0)
45176     {
45177       /* No difference.  */
45178       fprintf (fp, "unknown");
45179       return 3;
45180     }
45181   /* Now m = plus.word[k] ^ ~minus.word[k].  */
45182   if (plus.word[k] & ~minus.word[k])
45183     {
45184       /* Oh? The sign bit is set in the positive and cleared in the negative
45185          numbers?  */
45186       fprintf (fp, "unknown");
45187       return 4;
45188     }
45189   for (i = 0; ; i++)
45190     if ((m >> i) & 1)
45191       break;
45192   fprintf (fp, "word %d bit %d", (int) k, (int) i);
45193   if (fclose (fp) != 0)
45194     return 5;
45195   return 0;
45196 }
45197
45198 _ACEOF
45199 if ac_fn_c_try_run "$LINENO"; then :
45200   gl_cv_cc_float_signbit=`cat conftest.out`
45201 else
45202   gl_cv_cc_float_signbit="unknown"
45203 fi
45204 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
45205   conftest.$ac_objext conftest.beam conftest.$ac_ext
45206 fi
45207
45208       rm -f conftest.out
45209
45210 fi
45211 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_float_signbit" >&5
45212 $as_echo "$gl_cv_cc_float_signbit" >&6; }
45213   case "$gl_cv_cc_float_signbit" in
45214     word*bit*)
45215       word=`echo "$gl_cv_cc_float_signbit" | sed -e 's/word //' -e 's/ bit.*//'`
45216       bit=`echo "$gl_cv_cc_float_signbit" | sed -e 's/word.*bit //'`
45217
45218 cat >>confdefs.h <<_ACEOF
45219 #define FLT_SIGNBIT_WORD $word
45220 _ACEOF
45221
45222
45223 cat >>confdefs.h <<_ACEOF
45224 #define FLT_SIGNBIT_BIT $bit
45225 _ACEOF
45226
45227       ;;
45228   esac
45229
45230
45231
45232
45233   { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the sign bit in a 'double'" >&5
45234 $as_echo_n "checking where to find the sign bit in a 'double'... " >&6; }
45235 if ${gl_cv_cc_double_signbit+:} false; then :
45236   $as_echo_n "(cached) " >&6
45237 else
45238
45239       if test "$cross_compiling" = yes; then :
45240
45241                               gl_cv_cc_double_signbit="unknown"
45242
45243 else
45244   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
45245 /* end confdefs.h.  */
45246
45247 #include <stddef.h>
45248 #include <stdio.h>
45249 #define NWORDS \
45250   ((sizeof (double) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
45251 typedef union { double value; unsigned int word[NWORDS]; }
45252         memory_float;
45253 static memory_float plus = { 1.0 };
45254 static memory_float minus = { -1.0 };
45255 int main ()
45256 {
45257   size_t j, k, i;
45258   unsigned int m;
45259   FILE *fp = fopen ("conftest.out", "w");
45260   if (fp == NULL)
45261     return 1;
45262   /* Find the different bit.  */
45263   k = 0; m = 0;
45264   for (j = 0; j < NWORDS; j++)
45265     {
45266       unsigned int x = plus.word[j] ^ minus.word[j];
45267       if ((x & (x - 1)) || (x && m))
45268         {
45269           /* More than one bit difference.  */
45270           fprintf (fp, "unknown");
45271           return 2;
45272         }
45273       if (x)
45274         {
45275           k = j;
45276           m = x;
45277         }
45278     }
45279   if (m == 0)
45280     {
45281       /* No difference.  */
45282       fprintf (fp, "unknown");
45283       return 3;
45284     }
45285   /* Now m = plus.word[k] ^ ~minus.word[k].  */
45286   if (plus.word[k] & ~minus.word[k])
45287     {
45288       /* Oh? The sign bit is set in the positive and cleared in the negative
45289          numbers?  */
45290       fprintf (fp, "unknown");
45291       return 4;
45292     }
45293   for (i = 0; ; i++)
45294     if ((m >> i) & 1)
45295       break;
45296   fprintf (fp, "word %d bit %d", (int) k, (int) i);
45297   if (fclose (fp) != 0)
45298     return 5;
45299   return 0;
45300 }
45301
45302 _ACEOF
45303 if ac_fn_c_try_run "$LINENO"; then :
45304   gl_cv_cc_double_signbit=`cat conftest.out`
45305 else
45306   gl_cv_cc_double_signbit="unknown"
45307 fi
45308 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
45309   conftest.$ac_objext conftest.beam conftest.$ac_ext
45310 fi
45311
45312       rm -f conftest.out
45313
45314 fi
45315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_double_signbit" >&5
45316 $as_echo "$gl_cv_cc_double_signbit" >&6; }
45317   case "$gl_cv_cc_double_signbit" in
45318     word*bit*)
45319       word=`echo "$gl_cv_cc_double_signbit" | sed -e 's/word //' -e 's/ bit.*//'`
45320       bit=`echo "$gl_cv_cc_double_signbit" | sed -e 's/word.*bit //'`
45321
45322 cat >>confdefs.h <<_ACEOF
45323 #define DBL_SIGNBIT_WORD $word
45324 _ACEOF
45325
45326
45327 cat >>confdefs.h <<_ACEOF
45328 #define DBL_SIGNBIT_BIT $bit
45329 _ACEOF
45330
45331       ;;
45332   esac
45333
45334
45335
45336
45337   { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the sign bit in a 'long double'" >&5
45338 $as_echo_n "checking where to find the sign bit in a 'long double'... " >&6; }
45339 if ${gl_cv_cc_long_double_signbit+:} false; then :
45340   $as_echo_n "(cached) " >&6
45341 else
45342
45343       if test "$cross_compiling" = yes; then :
45344
45345                               gl_cv_cc_long_double_signbit="unknown"
45346
45347 else
45348   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
45349 /* end confdefs.h.  */
45350
45351 #include <stddef.h>
45352 #include <stdio.h>
45353 #define NWORDS \
45354   ((sizeof (long double) + sizeof (unsigned int) - 1) / sizeof (unsigned int))
45355 typedef union { long double value; unsigned int word[NWORDS]; }
45356         memory_float;
45357 static memory_float plus = { 1.0L };
45358 static memory_float minus = { -1.0L };
45359 int main ()
45360 {
45361   size_t j, k, i;
45362   unsigned int m;
45363   FILE *fp = fopen ("conftest.out", "w");
45364   if (fp == NULL)
45365     return 1;
45366   /* Find the different bit.  */
45367   k = 0; m = 0;
45368   for (j = 0; j < NWORDS; j++)
45369     {
45370       unsigned int x = plus.word[j] ^ minus.word[j];
45371       if ((x & (x - 1)) || (x && m))
45372         {
45373           /* More than one bit difference.  */
45374           fprintf (fp, "unknown");
45375           return 2;
45376         }
45377       if (x)
45378         {
45379           k = j;
45380           m = x;
45381         }
45382     }
45383   if (m == 0)
45384     {
45385       /* No difference.  */
45386       fprintf (fp, "unknown");
45387       return 3;
45388     }
45389   /* Now m = plus.word[k] ^ ~minus.word[k].  */
45390   if (plus.word[k] & ~minus.word[k])
45391     {
45392       /* Oh? The sign bit is set in the positive and cleared in the negative
45393          numbers?  */
45394       fprintf (fp, "unknown");
45395       return 4;
45396     }
45397   for (i = 0; ; i++)
45398     if ((m >> i) & 1)
45399       break;
45400   fprintf (fp, "word %d bit %d", (int) k, (int) i);
45401   if (fclose (fp) != 0)
45402     return 5;
45403   return 0;
45404 }
45405
45406 _ACEOF
45407 if ac_fn_c_try_run "$LINENO"; then :
45408   gl_cv_cc_long_double_signbit=`cat conftest.out`
45409 else
45410   gl_cv_cc_long_double_signbit="unknown"
45411 fi
45412 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
45413   conftest.$ac_objext conftest.beam conftest.$ac_ext
45414 fi
45415
45416       rm -f conftest.out
45417
45418 fi
45419 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_long_double_signbit" >&5
45420 $as_echo "$gl_cv_cc_long_double_signbit" >&6; }
45421   case "$gl_cv_cc_long_double_signbit" in
45422     word*bit*)
45423       word=`echo "$gl_cv_cc_long_double_signbit" | sed -e 's/word //' -e 's/ bit.*//'`
45424       bit=`echo "$gl_cv_cc_long_double_signbit" | sed -e 's/word.*bit //'`
45425
45426 cat >>confdefs.h <<_ACEOF
45427 #define LDBL_SIGNBIT_WORD $word
45428 _ACEOF
45429
45430
45431 cat >>confdefs.h <<_ACEOF
45432 #define LDBL_SIGNBIT_BIT $bit
45433 _ACEOF
45434
45435       ;;
45436   esac
45437
45438
45439           if test "$gl_cv_cc_float_signbit" = unknown; then
45440                         ac_fn_c_check_decl "$LINENO" "copysignf" "ac_cv_have_decl_copysignf" "#include <math.h>
45441 "
45442 if test "x$ac_cv_have_decl_copysignf" = xyes; then :
45443   ac_have_decl=1
45444 else
45445   ac_have_decl=0
45446 fi
45447
45448 cat >>confdefs.h <<_ACEOF
45449 #define HAVE_DECL_COPYSIGNF $ac_have_decl
45450 _ACEOF
45451
45452             if test "$ac_cv_have_decl_copysignf" = yes; then
45453                             { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether copysignf can be used without linking with libm" >&5
45454 $as_echo_n "checking whether copysignf can be used without linking with libm... " >&6; }
45455 if ${gl_cv_func_copysignf_no_libm+:} false; then :
45456   $as_echo_n "(cached) " >&6
45457 else
45458
45459                   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
45460 /* end confdefs.h.  */
45461 #include <math.h>
45462                          float x, y;
45463 int
45464 main ()
45465 {
45466 return copysignf (x, y) < 0;
45467   ;
45468   return 0;
45469 }
45470 _ACEOF
45471 if ac_fn_c_try_link "$LINENO"; then :
45472   gl_cv_func_copysignf_no_libm=yes
45473 else
45474   gl_cv_func_copysignf_no_libm=no
45475 fi
45476 rm -f core conftest.err conftest.$ac_objext \
45477     conftest$ac_exeext conftest.$ac_ext
45478
45479 fi
45480 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_copysignf_no_libm" >&5
45481 $as_echo "$gl_cv_func_copysignf_no_libm" >&6; }
45482               if test $gl_cv_func_copysignf_no_libm = yes; then
45483
45484 $as_echo "#define HAVE_COPYSIGNF_IN_LIBC 1" >>confdefs.h
45485
45486               fi
45487             fi
45488           fi
45489           if test "$gl_cv_cc_double_signbit" = unknown; then
45490                         ac_fn_c_check_decl "$LINENO" "copysign" "ac_cv_have_decl_copysign" "#include <math.h>
45491 "
45492 if test "x$ac_cv_have_decl_copysign" = xyes; then :
45493   ac_have_decl=1
45494 else
45495   ac_have_decl=0
45496 fi
45497
45498 cat >>confdefs.h <<_ACEOF
45499 #define HAVE_DECL_COPYSIGN $ac_have_decl
45500 _ACEOF
45501
45502             if test "$ac_cv_have_decl_copysign" = yes; then
45503                             { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether copysign can be used without linking with libm" >&5
45504 $as_echo_n "checking whether copysign can be used without linking with libm... " >&6; }
45505 if ${gl_cv_func_copysign_no_libm+:} false; then :
45506   $as_echo_n "(cached) " >&6
45507 else
45508
45509                   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
45510 /* end confdefs.h.  */
45511 #include <math.h>
45512                          double x, y;
45513 int
45514 main ()
45515 {
45516 return copysign (x, y) < 0;
45517   ;
45518   return 0;
45519 }
45520 _ACEOF
45521 if ac_fn_c_try_link "$LINENO"; then :
45522   gl_cv_func_copysign_no_libm=yes
45523 else
45524   gl_cv_func_copysign_no_libm=no
45525 fi
45526 rm -f core conftest.err conftest.$ac_objext \
45527     conftest$ac_exeext conftest.$ac_ext
45528
45529 fi
45530 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_copysign_no_libm" >&5
45531 $as_echo "$gl_cv_func_copysign_no_libm" >&6; }
45532               if test $gl_cv_func_copysign_no_libm = yes; then
45533
45534 $as_echo "#define HAVE_COPYSIGN_IN_LIBC 1" >>confdefs.h
45535
45536               fi
45537             fi
45538           fi
45539           if test "$gl_cv_cc_long_double_signbit" = unknown; then
45540                         ac_fn_c_check_decl "$LINENO" "copysignl" "ac_cv_have_decl_copysignl" "#include <math.h>
45541 "
45542 if test "x$ac_cv_have_decl_copysignl" = xyes; then :
45543   ac_have_decl=1
45544 else
45545   ac_have_decl=0
45546 fi
45547
45548 cat >>confdefs.h <<_ACEOF
45549 #define HAVE_DECL_COPYSIGNL $ac_have_decl
45550 _ACEOF
45551
45552             if test "$ac_cv_have_decl_copysignl" = yes; then
45553                             { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether copysignl can be used without linking with libm" >&5
45554 $as_echo_n "checking whether copysignl can be used without linking with libm... " >&6; }
45555 if ${gl_cv_func_copysignl_no_libm+:} false; then :
45556   $as_echo_n "(cached) " >&6
45557 else
45558
45559                   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
45560 /* end confdefs.h.  */
45561 #include <math.h>
45562                          long double x, y;
45563 int
45564 main ()
45565 {
45566 return copysignl (x, y) < 0;
45567   ;
45568   return 0;
45569 }
45570 _ACEOF
45571 if ac_fn_c_try_link "$LINENO"; then :
45572   gl_cv_func_copysignl_no_libm=yes
45573 else
45574   gl_cv_func_copysignl_no_libm=no
45575 fi
45576 rm -f core conftest.err conftest.$ac_objext \
45577     conftest$ac_exeext conftest.$ac_ext
45578
45579 fi
45580 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_copysignl_no_libm" >&5
45581 $as_echo "$gl_cv_func_copysignl_no_libm" >&6; }
45582               if test $gl_cv_func_copysignl_no_libm = yes; then
45583
45584 $as_echo "#define HAVE_COPYSIGNL_IN_LIBC 1" >>confdefs.h
45585
45586               fi
45587             fi
45588           fi
45589           ;;
45590       esac
45591       ;;
45592   esac
45593
45594   if test $REPLACE_SIGNBIT = 1; then
45595
45596
45597
45598
45599
45600
45601
45602
45603   gltests_LIBOBJS="$gltests_LIBOBJS signbitf.$ac_objext"
45604
45605
45606
45607
45608
45609
45610
45611
45612
45613   gltests_LIBOBJS="$gltests_LIBOBJS signbitd.$ac_objext"
45614
45615
45616
45617
45618
45619
45620
45621
45622
45623   gltests_LIBOBJS="$gltests_LIBOBJS signbitl.$ac_objext"
45624
45625   fi
45626
45627
45628
45629
45630
45631     if test "$GNULIB_SIGNBIT" != 1; then
45632         if test "$GNULIB_SIGNBIT" = 0; then
45633       GNULIB_SIGNBIT=$gl_module_indicator_condition
45634     else
45635       GNULIB_SIGNBIT="($GNULIB_SIGNBIT || $gl_module_indicator_condition)"
45636     fi
45637   fi
45638
45639
45640
45641
45642
45643 $as_echo "#define GNULIB_TEST_SIGNBIT 1" >>confdefs.h
45644
45645
45646
45647
45648
45649
45650
45651   :
45652
45653
45654
45655
45656
45657
45658
45659
45660
45661
45662
45663
45664
45665
45666   :
45667
45668
45669
45670
45671
45672
45673
45674
45675      if test $gl_cv_have_include_next = yes; then
45676        gl_cv_next_spawn_h='<'spawn.h'>'
45677      else
45678        { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <spawn.h>" >&5
45679 $as_echo_n "checking absolute name of <spawn.h>... " >&6; }
45680 if ${gl_cv_next_spawn_h+:} false; then :
45681   $as_echo_n "(cached) " >&6
45682 else
45683
45684              if test $ac_cv_header_spawn_h = yes; then
45685
45686
45687
45688
45689   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
45690 /* end confdefs.h.  */
45691 #include <spawn.h>
45692 _ACEOF
45693                 case "$host_os" in
45694     aix*) gl_absname_cpp="$ac_cpp -C" ;;
45695     *)    gl_absname_cpp="$ac_cpp" ;;
45696   esac
45697
45698   case "$host_os" in
45699     mingw*)
45700                                           gl_dirsep_regex='[/\\]'
45701       ;;
45702     *)
45703       gl_dirsep_regex='\/'
45704       ;;
45705   esac
45706       gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
45707   gl_header_literal_regex=`echo 'spawn.h' \
45708                            | sed -e "$gl_make_literal_regex_sed"`
45709   gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
45710       s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
45711       s|^/[^/]|//&|
45712       p
45713       q
45714     }'
45715
45716         gl_cv_absolute_spawn_h=`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
45717   sed -n "$gl_absolute_header_sed"`
45718
45719            gl_header=$gl_cv_absolute_spawn_h
45720            gl_cv_next_spawn_h='"'$gl_header'"'
45721           else
45722                gl_cv_next_spawn_h='<'spawn.h'>'
45723              fi
45724
45725
45726 fi
45727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_spawn_h" >&5
45728 $as_echo "$gl_cv_next_spawn_h" >&6; }
45729      fi
45730      NEXT_SPAWN_H=$gl_cv_next_spawn_h
45731
45732      if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
45733        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
45734        gl_next_as_first_directive='<'spawn.h'>'
45735      else
45736        # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
45737        gl_next_as_first_directive=$gl_cv_next_spawn_h
45738      fi
45739      NEXT_AS_FIRST_DIRECTIVE_SPAWN_H=$gl_next_as_first_directive
45740
45741
45742
45743
45744
45745   if test $ac_cv_header_spawn_h = yes; then
45746     HAVE_SPAWN_H=1
45747     ac_fn_c_check_type "$LINENO" "posix_spawnattr_t" "ac_cv_type_posix_spawnattr_t" "
45748 #include <spawn.h>
45749
45750 "
45751 if test "x$ac_cv_type_posix_spawnattr_t" = xyes; then :
45752
45753 cat >>confdefs.h <<_ACEOF
45754 #define HAVE_POSIX_SPAWNATTR_T 1
45755 _ACEOF
45756
45757
45758 else
45759   HAVE_POSIX_SPAWNATTR_T=0
45760 fi
45761
45762     ac_fn_c_check_type "$LINENO" "posix_spawn_file_actions_t" "ac_cv_type_posix_spawn_file_actions_t" "
45763 #include <spawn.h>
45764
45765 "
45766 if test "x$ac_cv_type_posix_spawn_file_actions_t" = xyes; then :
45767
45768 cat >>confdefs.h <<_ACEOF
45769 #define HAVE_POSIX_SPAWN_FILE_ACTIONS_T 1
45770 _ACEOF
45771
45772
45773 else
45774   HAVE_POSIX_SPAWN_FILE_ACTIONS_T=0
45775 fi
45776
45777   else
45778     HAVE_SPAWN_H=0
45779     HAVE_POSIX_SPAWNATTR_T=0
45780     HAVE_POSIX_SPAWN_FILE_ACTIONS_T=0
45781   fi
45782
45783
45784
45785
45786
45787
45788
45789
45790
45791
45792
45793
45794
45795
45796
45797
45798
45799   # Check for mmap(). Don't use AC_FUNC_MMAP, because it checks too much: it
45800   # fails on HP-UX 11, because MAP_FIXED mappings do not work. But this is
45801   # irrelevant for anonymous mappings.
45802   ac_fn_c_check_func "$LINENO" "mmap" "ac_cv_func_mmap"
45803 if test "x$ac_cv_func_mmap" = xyes; then :
45804   gl_have_mmap=yes
45805 else
45806   gl_have_mmap=no
45807 fi
45808
45809
45810   # Try to allow MAP_ANONYMOUS.
45811   gl_have_mmap_anonymous=no
45812   if test $gl_have_mmap = yes; then
45813     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MAP_ANONYMOUS" >&5
45814 $as_echo_n "checking for MAP_ANONYMOUS... " >&6; }
45815     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
45816 /* end confdefs.h.  */
45817
45818 #include <sys/mman.h>
45819 #ifdef MAP_ANONYMOUS
45820     I cannot identify this map
45821 #endif
45822
45823 _ACEOF
45824 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
45825   $EGREP "I cannot identify this map" >/dev/null 2>&1; then :
45826   gl_have_mmap_anonymous=yes
45827 fi
45828 rm -f conftest*
45829
45830     if test $gl_have_mmap_anonymous != yes; then
45831       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
45832 /* end confdefs.h.  */
45833
45834 #include <sys/mman.h>
45835 #ifdef MAP_ANON
45836     I cannot identify this map
45837 #endif
45838
45839 _ACEOF
45840 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
45841   $EGREP "I cannot identify this map" >/dev/null 2>&1; then :
45842
45843 $as_echo "#define MAP_ANONYMOUS MAP_ANON" >>confdefs.h
45844
45845          gl_have_mmap_anonymous=yes
45846 fi
45847 rm -f conftest*
45848
45849     fi
45850     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_have_mmap_anonymous" >&5
45851 $as_echo "$gl_have_mmap_anonymous" >&6; }
45852     if test $gl_have_mmap_anonymous = yes; then
45853
45854 $as_echo "#define HAVE_MAP_ANONYMOUS 1" >>confdefs.h
45855
45856     fi
45857   fi
45858
45859
45860   :
45861
45862
45863
45864
45865
45866
45867   :
45868
45869
45870
45871
45872
45873
45874
45875
45876   :
45877
45878
45879
45880
45881
45882         if test $ac_cv_func_symlink = no; then
45883     HAVE_SYMLINK=0
45884   else
45885     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether symlink handles trailing slash correctly" >&5
45886 $as_echo_n "checking whether symlink handles trailing slash correctly... " >&6; }
45887 if ${gl_cv_func_symlink_works+:} false; then :
45888   $as_echo_n "(cached) " >&6
45889 else
45890   if test "$cross_compiling" = yes; then :
45891   case "$host_os" in
45892                     # Guess yes on glibc systems.
45893             *-gnu*) gl_cv_func_symlink_works="guessing yes" ;;
45894                     # If we don't know, assume the worst.
45895             *)      gl_cv_func_symlink_works="guessing no" ;;
45896           esac
45897
45898 else
45899   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
45900 /* end confdefs.h.  */
45901 #include <unistd.h>
45902
45903 int
45904 main ()
45905 {
45906 int result = 0;
45907              if (!symlink ("a", "conftest.link/"))
45908                result |= 1;
45909              if (symlink ("conftest.f", "conftest.lnk2"))
45910                result |= 2;
45911              else if (!symlink ("a", "conftest.lnk2/"))
45912                result |= 4;
45913              return result;
45914
45915   ;
45916   return 0;
45917 }
45918 _ACEOF
45919 if ac_fn_c_try_run "$LINENO"; then :
45920   gl_cv_func_symlink_works=yes
45921 else
45922   gl_cv_func_symlink_works=no
45923 fi
45924 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
45925   conftest.$ac_objext conftest.beam conftest.$ac_ext
45926 fi
45927
45928       rm -f conftest.f conftest.link conftest.lnk2
45929 fi
45930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_symlink_works" >&5
45931 $as_echo "$gl_cv_func_symlink_works" >&6; }
45932     case "$gl_cv_func_symlink_works" in
45933       *yes) ;;
45934       *)
45935         REPLACE_SYMLINK=1
45936         ;;
45937     esac
45938   fi
45939
45940   if test $HAVE_SYMLINK = 0 || test $REPLACE_SYMLINK = 1; then
45941
45942
45943
45944
45945
45946
45947
45948
45949   gltests_LIBOBJS="$gltests_LIBOBJS symlink.$ac_objext"
45950
45951   fi
45952
45953
45954
45955
45956
45957     if test "$GNULIB_SYMLINK" != 1; then
45958         if test "$GNULIB_SYMLINK" = 0; then
45959       GNULIB_SYMLINK=$gl_module_indicator_condition
45960     else
45961       GNULIB_SYMLINK="($GNULIB_SYMLINK || $gl_module_indicator_condition)"
45962     fi
45963   fi
45964
45965
45966
45967
45968
45969 $as_echo "#define GNULIB_TEST_SYMLINK 1" >>confdefs.h
45970
45971
45972
45973
45974   :
45975
45976
45977
45978
45979
45980
45981
45982
45983   if test $gl_threads_api = posix; then
45984     gl_save_LIBS="$LIBS"
45985     LIBS="$LIBS $LIBMULTITHREAD"
45986     for ac_func in pthread_atfork
45987 do :
45988   ac_fn_c_check_func "$LINENO" "pthread_atfork" "ac_cv_func_pthread_atfork"
45989 if test "x$ac_cv_func_pthread_atfork" = xyes; then :
45990   cat >>confdefs.h <<_ACEOF
45991 #define HAVE_PTHREAD_ATFORK 1
45992 _ACEOF
45993
45994 fi
45995 done
45996
45997     LIBS="$gl_save_LIBS"
45998   fi
45999
46000
46001
46002
46003
46004
46005   for ac_func in unlockpt
46006 do :
46007   ac_fn_c_check_func "$LINENO" "unlockpt" "ac_cv_func_unlockpt"
46008 if test "x$ac_cv_func_unlockpt" = xyes; then :
46009   cat >>confdefs.h <<_ACEOF
46010 #define HAVE_UNLOCKPT 1
46011 _ACEOF
46012
46013 fi
46014 done
46015
46016   if test $ac_cv_func_unlockpt = no; then
46017     HAVE_UNLOCKPT=0
46018   fi
46019
46020   if test $HAVE_UNLOCKPT = 0; then
46021
46022
46023
46024
46025
46026
46027
46028
46029   gltests_LIBOBJS="$gltests_LIBOBJS unlockpt.$ac_objext"
46030
46031
46032   for ac_func in revoke
46033 do :
46034   ac_fn_c_check_func "$LINENO" "revoke" "ac_cv_func_revoke"
46035 if test "x$ac_cv_func_revoke" = xyes; then :
46036   cat >>confdefs.h <<_ACEOF
46037 #define HAVE_REVOKE 1
46038 _ACEOF
46039
46040 fi
46041 done
46042
46043
46044   fi
46045
46046
46047
46048
46049
46050     if test "$GNULIB_UNLOCKPT" != 1; then
46051         if test "$GNULIB_UNLOCKPT" = 0; then
46052       GNULIB_UNLOCKPT=$gl_module_indicator_condition
46053     else
46054       GNULIB_UNLOCKPT="($GNULIB_UNLOCKPT || $gl_module_indicator_condition)"
46055     fi
46056   fi
46057
46058
46059
46060
46061
46062 $as_echo "#define GNULIB_TEST_UNLOCKPT 1" >>confdefs.h
46063
46064
46065
46066
46067
46068
46069   :
46070
46071
46072
46073
46074
46075   if test $ac_cv_have_decl_unsetenv = no; then
46076     HAVE_DECL_UNSETENV=0
46077   fi
46078   for ac_func in unsetenv
46079 do :
46080   ac_fn_c_check_func "$LINENO" "unsetenv" "ac_cv_func_unsetenv"
46081 if test "x$ac_cv_func_unsetenv" = xyes; then :
46082   cat >>confdefs.h <<_ACEOF
46083 #define HAVE_UNSETENV 1
46084 _ACEOF
46085
46086 fi
46087 done
46088
46089   if test $ac_cv_func_unsetenv = no; then
46090     HAVE_UNSETENV=0
46091   else
46092     HAVE_UNSETENV=1
46093         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsetenv() return type" >&5
46094 $as_echo_n "checking for unsetenv() return type... " >&6; }
46095 if ${gt_cv_func_unsetenv_ret+:} false; then :
46096   $as_echo_n "(cached) " >&6
46097 else
46098   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46099 /* end confdefs.h.  */
46100
46101 #undef _BSD
46102 #define _BSD 1 /* unhide unsetenv declaration in OSF/1 5.1 <stdlib.h> */
46103 #include <stdlib.h>
46104 extern
46105 #ifdef __cplusplus
46106 "C"
46107 #endif
46108 int unsetenv (const char *name);
46109
46110 int
46111 main ()
46112 {
46113
46114   ;
46115   return 0;
46116 }
46117 _ACEOF
46118 if ac_fn_c_try_compile "$LINENO"; then :
46119   gt_cv_func_unsetenv_ret='int'
46120 else
46121   gt_cv_func_unsetenv_ret='void'
46122 fi
46123 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
46124 fi
46125 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_unsetenv_ret" >&5
46126 $as_echo "$gt_cv_func_unsetenv_ret" >&6; }
46127     if test $gt_cv_func_unsetenv_ret = 'void'; then
46128
46129 $as_echo "#define VOID_UNSETENV 1" >>confdefs.h
46130
46131       REPLACE_UNSETENV=1
46132     fi
46133
46134                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether unsetenv obeys POSIX" >&5
46135 $as_echo_n "checking whether unsetenv obeys POSIX... " >&6; }
46136 if ${gl_cv_func_unsetenv_works+:} false; then :
46137   $as_echo_n "(cached) " >&6
46138 else
46139   if test "$cross_compiling" = yes; then :
46140   case "$host_os" in
46141                  # Guess yes on glibc systems.
46142          *-gnu*) gl_cv_func_unsetenv_works="guessing yes" ;;
46143                  # If we don't know, assume the worst.
46144          *)      gl_cv_func_unsetenv_works="guessing no" ;;
46145        esac
46146
46147 else
46148   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46149 /* end confdefs.h.  */
46150
46151        #include <stdlib.h>
46152        #include <errno.h>
46153        extern char **environ;
46154
46155 int
46156 main ()
46157 {
46158
46159        char entry1[] = "a=1";
46160        char entry2[] = "b=2";
46161        char *env[] = { entry1, entry2, NULL };
46162        if (putenv ((char *) "a=1")) return 1;
46163        if (putenv (entry2)) return 2;
46164        entry2[0] = 'a';
46165        unsetenv ("a");
46166        if (getenv ("a")) return 3;
46167        if (!unsetenv ("") || errno != EINVAL) return 4;
46168        entry2[0] = 'b';
46169        environ = env;
46170        if (!getenv ("a")) return 5;
46171        entry2[0] = 'a';
46172        unsetenv ("a");
46173        if (getenv ("a")) return 6;
46174
46175   ;
46176   return 0;
46177 }
46178 _ACEOF
46179 if ac_fn_c_try_run "$LINENO"; then :
46180   gl_cv_func_unsetenv_works=yes
46181 else
46182   gl_cv_func_unsetenv_works=no
46183 fi
46184 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
46185   conftest.$ac_objext conftest.beam conftest.$ac_ext
46186 fi
46187
46188 fi
46189 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_unsetenv_works" >&5
46190 $as_echo "$gl_cv_func_unsetenv_works" >&6; }
46191     case "$gl_cv_func_unsetenv_works" in
46192       *yes) ;;
46193       *)
46194         REPLACE_UNSETENV=1
46195         ;;
46196     esac
46197   fi
46198
46199   if test $HAVE_UNSETENV = 0 || test $REPLACE_UNSETENV = 1; then
46200
46201
46202
46203
46204
46205
46206
46207
46208   gltests_LIBOBJS="$gltests_LIBOBJS unsetenv.$ac_objext"
46209
46210
46211
46212
46213   :
46214
46215
46216
46217
46218
46219
46220   fi
46221
46222
46223
46224
46225
46226     if test "$GNULIB_UNSETENV" != 1; then
46227         if test "$GNULIB_UNSETENV" = 0; then
46228       GNULIB_UNSETENV=$gl_module_indicator_condition
46229     else
46230       GNULIB_UNSETENV="($GNULIB_UNSETENV || $gl_module_indicator_condition)"
46231     fi
46232   fi
46233
46234
46235
46236
46237
46238 $as_echo "#define GNULIB_TEST_UNSETENV 1" >>confdefs.h
46239
46240
46241
46242   abs_aux_dir=`cd "$ac_aux_dir"; pwd`
46243
46244
46245
46246   for ac_func in waitid
46247 do :
46248   ac_fn_c_check_func "$LINENO" "waitid" "ac_cv_func_waitid"
46249 if test "x$ac_cv_func_waitid" = xyes; then :
46250   cat >>confdefs.h <<_ACEOF
46251 #define HAVE_WAITID 1
46252 _ACEOF
46253
46254 fi
46255 done
46256
46257
46258
46259
46260
46261   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a traditional french locale" >&5
46262 $as_echo_n "checking for a traditional french locale... " >&6; }
46263 if ${gt_cv_locale_fr+:} false; then :
46264   $as_echo_n "(cached) " >&6
46265 else
46266
46267     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46268 /* end confdefs.h.  */
46269
46270 #include <locale.h>
46271 #include <time.h>
46272 #if HAVE_LANGINFO_CODESET
46273 # include <langinfo.h>
46274 #endif
46275 #include <stdlib.h>
46276 #include <string.h>
46277 struct tm t;
46278 char buf[16];
46279 int main () {
46280   /* Check whether the given locale name is recognized by the system.  */
46281 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
46282   /* On native Windows, setlocale(category, "") looks at the system settings,
46283      not at the environment variables.  Also, when an encoding suffix such
46284      as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
46285      category of the locale to "C".  */
46286   if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
46287       || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
46288     return 1;
46289 #else
46290   if (setlocale (LC_ALL, "") == NULL) return 1;
46291 #endif
46292   /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
46293      On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
46294      is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
46295      On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
46296      succeeds but then nl_langinfo(CODESET) is "646". In this situation,
46297      some unit tests fail.
46298      On MirBSD 10, when an unsupported locale is specified, setlocale()
46299      succeeds but then nl_langinfo(CODESET) is "UTF-8".  */
46300 #if HAVE_LANGINFO_CODESET
46301   {
46302     const char *cs = nl_langinfo (CODESET);
46303     if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
46304         || strcmp (cs, "UTF-8") == 0)
46305       return 1;
46306   }
46307 #endif
46308 #ifdef __CYGWIN__
46309   /* On Cygwin, avoid locale names without encoding suffix, because the
46310      locale_charset() function relies on the encoding suffix.  Note that
46311      LC_ALL is set on the command line.  */
46312   if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
46313 #endif
46314   /* Check whether in the abbreviation of the second month, the second
46315      character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is only
46316      one byte long. This excludes the UTF-8 encoding.  */
46317   t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
46318   if (strftime (buf, sizeof (buf), "%b", &t) < 3 || buf[2] != 'v') return 1;
46319 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy.  */
46320   /* Check whether the decimal separator is a comma.
46321      On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
46322      are nl_langinfo(RADIXCHAR) are both ".".  */
46323   if (localeconv () ->decimal_point[0] != ',') return 1;
46324 #endif
46325   return 0;
46326 }
46327
46328 _ACEOF
46329     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
46330   (eval $ac_link) 2>&5
46331   ac_status=$?
46332   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
46333   test $ac_status = 0; } && test -s conftest$ac_exeext; then
46334       case "$host_os" in
46335         # Handle native Windows specially, because there setlocale() interprets
46336         # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
46337         # "fr" or "fra" as "French" or "French_France.1252",
46338         # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
46339         # "ja" as "Japanese" or "Japanese_Japan.932",
46340         # and similar.
46341         mingw*)
46342           # Test for the native Windows locale name.
46343           if (LC_ALL=French_France.1252 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
46344             gt_cv_locale_fr=French_France.1252
46345           else
46346             # None found.
46347             gt_cv_locale_fr=none
46348           fi
46349           ;;
46350         *)
46351           # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
46352           # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
46353           # configure script would override the LC_ALL setting. Likewise for
46354           # LC_CTYPE, which is also set at the beginning of the configure script.
46355           # Test for the usual locale name.
46356           if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
46357             gt_cv_locale_fr=fr_FR
46358           else
46359             # Test for the locale name with explicit encoding suffix.
46360             if (LC_ALL=fr_FR.ISO-8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
46361               gt_cv_locale_fr=fr_FR.ISO-8859-1
46362             else
46363               # Test for the AIX, OSF/1, FreeBSD, NetBSD, OpenBSD locale name.
46364               if (LC_ALL=fr_FR.ISO8859-1 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
46365                 gt_cv_locale_fr=fr_FR.ISO8859-1
46366               else
46367                 # Test for the HP-UX locale name.
46368                 if (LC_ALL=fr_FR.iso88591 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
46369                   gt_cv_locale_fr=fr_FR.iso88591
46370                 else
46371                   # Test for the Solaris 7 locale name.
46372                   if (LC_ALL=fr LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
46373                     gt_cv_locale_fr=fr
46374                   else
46375                     # None found.
46376                     gt_cv_locale_fr=none
46377                   fi
46378                 fi
46379               fi
46380             fi
46381           fi
46382           ;;
46383       esac
46384     fi
46385     rm -fr conftest*
46386
46387 fi
46388 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr" >&5
46389 $as_echo "$gt_cv_locale_fr" >&6; }
46390   LOCALE_FR=$gt_cv_locale_fr
46391
46392
46393
46394
46395   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a french Unicode locale" >&5
46396 $as_echo_n "checking for a french Unicode locale... " >&6; }
46397 if ${gt_cv_locale_fr_utf8+:} false; then :
46398   $as_echo_n "(cached) " >&6
46399 else
46400
46401     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46402 /* end confdefs.h.  */
46403
46404 #include <locale.h>
46405 #include <time.h>
46406 #if HAVE_LANGINFO_CODESET
46407 # include <langinfo.h>
46408 #endif
46409 #include <stdlib.h>
46410 #include <string.h>
46411 struct tm t;
46412 char buf[16];
46413 int main () {
46414   /* On BeOS and Haiku, locales are not implemented in libc.  Rather, libintl
46415      imitates locale dependent behaviour by looking at the environment
46416      variables, and all locales use the UTF-8 encoding.  */
46417 #if !(defined __BEOS__ || defined __HAIKU__)
46418   /* Check whether the given locale name is recognized by the system.  */
46419 # if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
46420   /* On native Windows, setlocale(category, "") looks at the system settings,
46421      not at the environment variables.  Also, when an encoding suffix such
46422      as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
46423      category of the locale to "C".  */
46424   if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
46425       || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
46426     return 1;
46427 # else
46428   if (setlocale (LC_ALL, "") == NULL) return 1;
46429 # endif
46430   /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
46431      On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
46432      is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
46433      On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
46434      succeeds but then nl_langinfo(CODESET) is "646". In this situation,
46435      some unit tests fail.  */
46436 # if HAVE_LANGINFO_CODESET
46437   {
46438     const char *cs = nl_langinfo (CODESET);
46439     if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0)
46440       return 1;
46441   }
46442 # endif
46443 # ifdef __CYGWIN__
46444   /* On Cygwin, avoid locale names without encoding suffix, because the
46445      locale_charset() function relies on the encoding suffix.  Note that
46446      LC_ALL is set on the command line.  */
46447   if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
46448 # endif
46449   /* Check whether in the abbreviation of the second month, the second
46450      character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is
46451      two bytes long, with UTF-8 encoding.  */
46452   t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
46453   if (strftime (buf, sizeof (buf), "%b", &t) < 4
46454       || buf[1] != (char) 0xc3 || buf[2] != (char) 0xa9 || buf[3] != 'v')
46455     return 1;
46456 #endif
46457 #if !defined __BIONIC__ /* Bionic libc's 'struct lconv' is just a dummy.  */
46458   /* Check whether the decimal separator is a comma.
46459      On NetBSD 3.0 in the fr_FR.ISO8859-1 locale, localeconv()->decimal_point
46460      are nl_langinfo(RADIXCHAR) are both ".".  */
46461   if (localeconv () ->decimal_point[0] != ',') return 1;
46462 #endif
46463   return 0;
46464 }
46465
46466 _ACEOF
46467     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
46468   (eval $ac_link) 2>&5
46469   ac_status=$?
46470   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
46471   test $ac_status = 0; } && test -s conftest$ac_exeext; then
46472       case "$host_os" in
46473         # Handle native Windows specially, because there setlocale() interprets
46474         # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
46475         # "fr" or "fra" as "French" or "French_France.1252",
46476         # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
46477         # "ja" as "Japanese" or "Japanese_Japan.932",
46478         # and similar.
46479         mingw*)
46480           # Test for the hypothetical native Windows locale name.
46481           if (LC_ALL=French_France.65001 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
46482             gt_cv_locale_fr_utf8=French_France.65001
46483           else
46484             # None found.
46485             gt_cv_locale_fr_utf8=none
46486           fi
46487           ;;
46488         *)
46489           # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
46490           # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
46491           # configure script would override the LC_ALL setting. Likewise for
46492           # LC_CTYPE, which is also set at the beginning of the configure script.
46493           # Test for the usual locale name.
46494           if (LC_ALL=fr_FR LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
46495             gt_cv_locale_fr_utf8=fr_FR
46496           else
46497             # Test for the locale name with explicit encoding suffix.
46498             if (LC_ALL=fr_FR.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
46499               gt_cv_locale_fr_utf8=fr_FR.UTF-8
46500             else
46501               # Test for the Solaris 7 locale name.
46502               if (LC_ALL=fr.UTF-8 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
46503                 gt_cv_locale_fr_utf8=fr.UTF-8
46504               else
46505                 # None found.
46506                 gt_cv_locale_fr_utf8=none
46507               fi
46508             fi
46509           fi
46510           ;;
46511       esac
46512     fi
46513     rm -fr conftest*
46514
46515 fi
46516 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fr_utf8" >&5
46517 $as_echo "$gt_cv_locale_fr_utf8" >&6; }
46518   LOCALE_FR_UTF8=$gt_cv_locale_fr_utf8
46519
46520
46521
46522
46523
46524   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a traditional japanese locale" >&5
46525 $as_echo_n "checking for a traditional japanese locale... " >&6; }
46526 if ${gt_cv_locale_ja+:} false; then :
46527   $as_echo_n "(cached) " >&6
46528 else
46529
46530     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46531 /* end confdefs.h.  */
46532
46533 #include <locale.h>
46534 #include <time.h>
46535 #if HAVE_LANGINFO_CODESET
46536 # include <langinfo.h>
46537 #endif
46538 #include <stdlib.h>
46539 #include <string.h>
46540 struct tm t;
46541 char buf[16];
46542 int main ()
46543 {
46544   const char *p;
46545   /* Check whether the given locale name is recognized by the system.  */
46546 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
46547   /* On native Windows, setlocale(category, "") looks at the system settings,
46548      not at the environment variables.  Also, when an encoding suffix such
46549      as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
46550      category of the locale to "C".  */
46551   if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
46552       || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
46553     return 1;
46554 #else
46555   if (setlocale (LC_ALL, "") == NULL) return 1;
46556 #endif
46557   /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
46558      On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
46559      is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
46560      On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
46561      succeeds but then nl_langinfo(CODESET) is "646". In this situation,
46562      some unit tests fail.
46563      On MirBSD 10, when an unsupported locale is specified, setlocale()
46564      succeeds but then nl_langinfo(CODESET) is "UTF-8".  */
46565 #if HAVE_LANGINFO_CODESET
46566   {
46567     const char *cs = nl_langinfo (CODESET);
46568     if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
46569         || strcmp (cs, "UTF-8") == 0)
46570       return 1;
46571   }
46572 #endif
46573 #ifdef __CYGWIN__
46574   /* On Cygwin, avoid locale names without encoding suffix, because the
46575      locale_charset() function relies on the encoding suffix.  Note that
46576      LC_ALL is set on the command line.  */
46577   if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
46578 #endif
46579   /* Check whether MB_CUR_MAX is > 1.  This excludes the dysfunctional locales
46580      on Cygwin 1.5.x.  */
46581   if (MB_CUR_MAX == 1)
46582     return 1;
46583   /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
46584      This excludes the UTF-8 encoding (except on MirBSD).  */
46585   t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
46586   if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
46587   for (p = buf; *p != '\0'; p++)
46588     if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
46589       return 1;
46590   return 0;
46591 }
46592
46593 _ACEOF
46594     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
46595   (eval $ac_link) 2>&5
46596   ac_status=$?
46597   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
46598   test $ac_status = 0; } && test -s conftest$ac_exeext; then
46599       case "$host_os" in
46600         # Handle native Windows specially, because there setlocale() interprets
46601         # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
46602         # "fr" or "fra" as "French" or "French_France.1252",
46603         # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
46604         # "ja" as "Japanese" or "Japanese_Japan.932",
46605         # and similar.
46606         mingw*)
46607           # Note that on native Windows, the Japanese locale is
46608           # Japanese_Japan.932, and CP932 is very different from EUC-JP, so we
46609           # cannot use it here.
46610           gt_cv_locale_ja=none
46611           ;;
46612         *)
46613           # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
46614           # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
46615           # configure script would override the LC_ALL setting. Likewise for
46616           # LC_CTYPE, which is also set at the beginning of the configure script.
46617           # Test for the AIX locale name.
46618           if (LC_ALL=ja_JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
46619             gt_cv_locale_ja=ja_JP
46620           else
46621             # Test for the locale name with explicit encoding suffix.
46622             if (LC_ALL=ja_JP.EUC-JP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
46623               gt_cv_locale_ja=ja_JP.EUC-JP
46624             else
46625               # Test for the HP-UX, OSF/1, NetBSD locale name.
46626               if (LC_ALL=ja_JP.eucJP LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
46627                 gt_cv_locale_ja=ja_JP.eucJP
46628               else
46629                 # Test for the IRIX, FreeBSD locale name.
46630                 if (LC_ALL=ja_JP.EUC LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
46631                   gt_cv_locale_ja=ja_JP.EUC
46632                 else
46633                   # Test for the Solaris 7 locale name.
46634                   if (LC_ALL=ja LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
46635                     gt_cv_locale_ja=ja
46636                   else
46637                     # Special test for NetBSD 1.6.
46638                     if test -f /usr/share/locale/ja_JP.eucJP/LC_CTYPE; then
46639                       gt_cv_locale_ja=ja_JP.eucJP
46640                     else
46641                       # None found.
46642                       gt_cv_locale_ja=none
46643                     fi
46644                   fi
46645                 fi
46646               fi
46647             fi
46648           fi
46649           ;;
46650       esac
46651     fi
46652     rm -fr conftest*
46653
46654 fi
46655 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_ja" >&5
46656 $as_echo "$gt_cv_locale_ja" >&6; }
46657   LOCALE_JA=$gt_cv_locale_ja
46658
46659
46660
46661
46662
46663   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a transitional chinese locale" >&5
46664 $as_echo_n "checking for a transitional chinese locale... " >&6; }
46665 if ${gt_cv_locale_zh_CN+:} false; then :
46666   $as_echo_n "(cached) " >&6
46667 else
46668
46669     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46670 /* end confdefs.h.  */
46671
46672 #include <locale.h>
46673 #include <stdlib.h>
46674 #include <time.h>
46675 #if HAVE_LANGINFO_CODESET
46676 # include <langinfo.h>
46677 #endif
46678 #include <stdlib.h>
46679 #include <string.h>
46680 struct tm t;
46681 char buf[16];
46682 int main ()
46683 {
46684   const char *p;
46685   /* Check whether the given locale name is recognized by the system.  */
46686 #if (defined _WIN32 || defined __WIN32__) && !defined __CYGWIN__
46687   /* On native Windows, setlocale(category, "") looks at the system settings,
46688      not at the environment variables.  Also, when an encoding suffix such
46689      as ".65001" or ".54936" is specified, it succeeds but sets the LC_CTYPE
46690      category of the locale to "C".  */
46691   if (setlocale (LC_ALL, getenv ("LC_ALL")) == NULL
46692       || strcmp (setlocale (LC_CTYPE, NULL), "C") == 0)
46693     return 1;
46694 #else
46695   if (setlocale (LC_ALL, "") == NULL) return 1;
46696 #endif
46697   /* Check whether nl_langinfo(CODESET) is nonempty and not "ASCII" or "646".
46698      On Mac OS X 10.3.5 (Darwin 7.5) in the fr_FR locale, nl_langinfo(CODESET)
46699      is empty, and the behaviour of Tcl 8.4 in this locale is not useful.
46700      On OpenBSD 4.0, when an unsupported locale is specified, setlocale()
46701      succeeds but then nl_langinfo(CODESET) is "646". In this situation,
46702      some unit tests fail.
46703      On MirBSD 10, when an unsupported locale is specified, setlocale()
46704      succeeds but then nl_langinfo(CODESET) is "UTF-8".  */
46705 #if HAVE_LANGINFO_CODESET
46706   {
46707     const char *cs = nl_langinfo (CODESET);
46708     if (cs[0] == '\0' || strcmp (cs, "ASCII") == 0 || strcmp (cs, "646") == 0
46709         || strcmp (cs, "UTF-8") == 0)
46710       return 1;
46711   }
46712 #endif
46713 #ifdef __CYGWIN__
46714   /* On Cygwin, avoid locale names without encoding suffix, because the
46715      locale_charset() function relies on the encoding suffix.  Note that
46716      LC_ALL is set on the command line.  */
46717   if (strchr (getenv ("LC_ALL"), '.') == NULL) return 1;
46718 #endif
46719   /* Check whether in a month name, no byte in the range 0x80..0x9F occurs.
46720      This excludes the UTF-8 encoding (except on MirBSD).  */
46721   t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
46722   if (strftime (buf, sizeof (buf), "%B", &t) < 2) return 1;
46723   for (p = buf; *p != '\0'; p++)
46724     if ((unsigned char) *p >= 0x80 && (unsigned char) *p < 0xa0)
46725       return 1;
46726   /* Check whether a typical GB18030 multibyte sequence is recognized as a
46727      single wide character.  This excludes the GB2312 and GBK encodings.  */
46728   if (mblen ("\203\062\332\066", 5) != 4)
46729     return 1;
46730   return 0;
46731 }
46732
46733 _ACEOF
46734     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
46735   (eval $ac_link) 2>&5
46736   ac_status=$?
46737   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
46738   test $ac_status = 0; } && test -s conftest$ac_exeext; then
46739       case "$host_os" in
46740         # Handle native Windows specially, because there setlocale() interprets
46741         # "ar" as "Arabic" or "Arabic_Saudi Arabia.1256",
46742         # "fr" or "fra" as "French" or "French_France.1252",
46743         # "ge"(!) or "deu"(!) as "German" or "German_Germany.1252",
46744         # "ja" as "Japanese" or "Japanese_Japan.932",
46745         # and similar.
46746         mingw*)
46747           # Test for the hypothetical native Windows locale name.
46748           if (LC_ALL=Chinese_China.54936 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
46749             gt_cv_locale_zh_CN=Chinese_China.54936
46750           else
46751             # None found.
46752             gt_cv_locale_zh_CN=none
46753           fi
46754           ;;
46755         solaris2.8)
46756           # On Solaris 8, the locales zh_CN.GB18030, zh_CN.GBK, zh.GBK are
46757           # broken. One witness is the test case in gl_MBRTOWC_SANITYCHECK.
46758           # Another witness is that "LC_ALL=zh_CN.GB18030 bash -c true" dumps core.
46759           gt_cv_locale_zh_CN=none
46760           ;;
46761         *)
46762           # Setting LC_ALL is not enough. Need to set LC_TIME to empty, because
46763           # otherwise on Mac OS X 10.3.5 the LC_TIME=C from the beginning of the
46764           # configure script would override the LC_ALL setting. Likewise for
46765           # LC_CTYPE, which is also set at the beginning of the configure script.
46766           # Test for the locale name without encoding suffix.
46767           if (LC_ALL=zh_CN LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
46768             gt_cv_locale_zh_CN=zh_CN
46769           else
46770             # Test for the locale name with explicit encoding suffix.
46771             if (LC_ALL=zh_CN.GB18030 LC_TIME= LC_CTYPE= ./conftest; exit) 2>/dev/null; then
46772               gt_cv_locale_zh_CN=zh_CN.GB18030
46773             else
46774               # None found.
46775               gt_cv_locale_zh_CN=none
46776             fi
46777           fi
46778           ;;
46779       esac
46780     else
46781       # If there was a link error, due to mblen(), the system is so old that
46782       # it certainly doesn't have a chinese locale.
46783       gt_cv_locale_zh_CN=none
46784     fi
46785     rm -fr conftest*
46786
46787 fi
46788 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_zh_CN" >&5
46789 $as_echo "$gt_cv_locale_zh_CN" >&6; }
46790   LOCALE_ZH_CN=$gt_cv_locale_zh_CN
46791
46792
46793
46794
46795
46796
46797   :
46798
46799
46800
46801
46802
46803   if test $ac_cv_func_wctob = no; then
46804     HAVE_WCTOB=0
46805     HAVE_DECL_WCTOB=0
46806   else
46807     HAVE_WCTOB=1
46808
46809
46810
46811          { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether wctob works" >&5
46812 $as_echo_n "checking whether wctob works... " >&6; }
46813 if ${gl_cv_func_wctob_works+:} false; then :
46814   $as_echo_n "(cached) " >&6
46815 else
46816
46817                         case "$host_os" in
46818             # Guess no on Solaris <= 9 and Cygwin.
46819           solaris2.[1-9] | solaris2.[1-9].* | cygwin*)
46820             gl_cv_func_wctob_works="guessing no" ;;
46821             # Guess yes otherwise.
46822           *) gl_cv_func_wctob_works="guessing yes" ;;
46823         esac
46824         case "$host_os" in
46825           cygwin*)
46826             if test "$cross_compiling" = yes; then :
46827   :
46828 else
46829   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46830 /* end confdefs.h.  */
46831
46832 #include <locale.h>
46833 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
46834    <wchar.h>.
46835    BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
46836    included before <wchar.h>.  */
46837 #include <stddef.h>
46838 #include <stdio.h>
46839 #include <time.h>
46840 #include <wchar.h>
46841
46842 register long global __asm__ ("%ebx");
46843
46844 int main ()
46845 {
46846   setlocale (LC_ALL, "en_US.UTF-8");
46847
46848   global = 0x12345678;
46849   if (wctob (0x00FC) != -1)
46850     return 1;
46851   if (global != 0x12345678)
46852     return 2;
46853   return 0;
46854 }
46855 _ACEOF
46856 if ac_fn_c_try_run "$LINENO"; then :
46857   :
46858 else
46859   gl_cv_func_wctob_works=no
46860 fi
46861 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
46862   conftest.$ac_objext conftest.beam conftest.$ac_ext
46863 fi
46864
46865             ;;
46866         esac
46867         if test "$gl_cv_func_wctob_works" != no && test $LOCALE_FR != none; then
46868           if test "$cross_compiling" = yes; then :
46869   :
46870 else
46871   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
46872 /* end confdefs.h.  */
46873
46874 #include <locale.h>
46875 #include <string.h>
46876 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
46877    <wchar.h>.
46878    BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
46879    included before <wchar.h>.  */
46880 #include <stddef.h>
46881 #include <stdio.h>
46882 #include <time.h>
46883 #include <wchar.h>
46884 int main ()
46885 {
46886   if (setlocale (LC_ALL, "$LOCALE_FR") != NULL)
46887     {
46888       wchar_t wc;
46889
46890       if (mbtowc (&wc, "\374", 1) == 1)
46891         if (wctob (wc) != (unsigned char) '\374')
46892           return 1;
46893     }
46894   return 0;
46895 }
46896 _ACEOF
46897 if ac_fn_c_try_run "$LINENO"; then :
46898   gl_cv_func_wctob_works=yes
46899 else
46900   gl_cv_func_wctob_works=no
46901 fi
46902 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
46903   conftest.$ac_objext conftest.beam conftest.$ac_ext
46904 fi
46905
46906         fi
46907
46908 fi
46909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_wctob_works" >&5
46910 $as_echo "$gl_cv_func_wctob_works" >&6; }
46911     case "$gl_cv_func_wctob_works" in
46912       *yes) ;;
46913       *) REPLACE_WCTOB=1 ;;
46914     esac
46915     if test $REPLACE_WCTOB = 0; then
46916
46917             ac_fn_c_check_decl "$LINENO" "wctob" "ac_cv_have_decl_wctob" "
46918 /* Tru64 with Desktop Toolkit C has a bug: <stdio.h> must be included before
46919    <wchar.h>.
46920    BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be included
46921    before <wchar.h>.  */
46922 #include <stddef.h>
46923 #include <stdio.h>
46924 #include <time.h>
46925 #include <wchar.h>
46926
46927 "
46928 if test "x$ac_cv_have_decl_wctob" = xyes; then :
46929   ac_have_decl=1
46930 else
46931   ac_have_decl=0
46932 fi
46933
46934 cat >>confdefs.h <<_ACEOF
46935 #define HAVE_DECL_WCTOB $ac_have_decl
46936 _ACEOF
46937
46938       if test $ac_cv_have_decl_wctob != yes; then
46939         HAVE_DECL_WCTOB=0
46940       fi
46941     fi
46942   fi
46943
46944   if test $HAVE_WCTOB = 0 || test $REPLACE_WCTOB = 1; then
46945
46946
46947
46948
46949
46950
46951
46952
46953   gltests_LIBOBJS="$gltests_LIBOBJS wctob.$ac_objext"
46954
46955
46956   :
46957
46958   fi
46959
46960
46961
46962
46963
46964     if test "$GNULIB_WCTOB" != 1; then
46965         if test "$GNULIB_WCTOB" = 0; then
46966       GNULIB_WCTOB=$gl_module_indicator_condition
46967     else
46968       GNULIB_WCTOB="($GNULIB_WCTOB || $gl_module_indicator_condition)"
46969     fi
46970   fi
46971
46972
46973
46974
46975
46976 $as_echo "#define GNULIB_TEST_WCTOB 1" >>confdefs.h
46977
46978
46979
46980
46981
46982
46983   if false; then
46984     REPLACE_WCTOMB=1
46985   fi
46986
46987   if test $REPLACE_WCTOMB = 1; then
46988
46989
46990
46991
46992
46993
46994
46995
46996   gltests_LIBOBJS="$gltests_LIBOBJS wctomb.$ac_objext"
46997
46998
46999   :
47000
47001   fi
47002
47003
47004
47005
47006
47007     if test "$GNULIB_WCTOMB" != 1; then
47008         if test "$GNULIB_WCTOMB" = 0; then
47009       GNULIB_WCTOMB=$gl_module_indicator_condition
47010     else
47011       GNULIB_WCTOMB="($GNULIB_WCTOMB || $gl_module_indicator_condition)"
47012     fi
47013   fi
47014
47015
47016
47017
47018
47019 $as_echo "#define GNULIB_TEST_WCTOMB 1" >>confdefs.h
47020
47021
47022
47023
47024
47025
47026   if test $HAVE_MSVC_INVALID_PARAMETER_HANDLER = 1; then
47027     REPLACE_WRITE=1
47028   fi
47029
47030
47031
47032
47033     if test $gl_cv_header_signal_h_SIGPIPE != yes; then
47034       REPLACE_WRITE=1
47035     fi
47036
47037
47038
47039
47040
47041     if test $gl_cv_have_nonblocking != yes; then
47042       REPLACE_WRITE=1
47043     fi
47044
47045
47046   if test $REPLACE_WRITE = 1; then
47047
47048
47049
47050
47051
47052
47053
47054
47055   gltests_LIBOBJS="$gltests_LIBOBJS write.$ac_objext"
47056
47057     :
47058   fi
47059
47060
47061
47062
47063
47064     if test "$GNULIB_WRITE" != 1; then
47065         if test "$GNULIB_WRITE" = 0; then
47066       GNULIB_WRITE=$gl_module_indicator_condition
47067     else
47068       GNULIB_WRITE="($GNULIB_WRITE || $gl_module_indicator_condition)"
47069     fi
47070   fi
47071
47072
47073
47074
47075
47076 $as_echo "#define GNULIB_TEST_WRITE 1" >>confdefs.h
47077
47078
47079
47080   :
47081
47082
47083
47084
47085
47086
47087
47088
47089
47090
47091   LIBTESTS_LIBDEPS="$gltests_libdeps"
47092
47093
47094
47095 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5
47096 $as_echo_n "checking for uid_t in sys/types.h... " >&6; }
47097 if ${ac_cv_type_uid_t+:} false; then :
47098   $as_echo_n "(cached) " >&6
47099 else
47100   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
47101 /* end confdefs.h.  */
47102 #include <sys/types.h>
47103
47104 _ACEOF
47105 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
47106   $EGREP "uid_t" >/dev/null 2>&1; then :
47107   ac_cv_type_uid_t=yes
47108 else
47109   ac_cv_type_uid_t=no
47110 fi
47111 rm -f conftest*
47112
47113 fi
47114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5
47115 $as_echo "$ac_cv_type_uid_t" >&6; }
47116 if test $ac_cv_type_uid_t = no; then
47117
47118 $as_echo "#define uid_t int" >>confdefs.h
47119
47120
47121 $as_echo "#define gid_t int" >>confdefs.h
47122
47123 fi
47124
47125
47126 enable_win32_dll=yes
47127
47128 case $host in
47129 *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-cegcc*)
47130   if test -n "$ac_tool_prefix"; then
47131   # Extract the first word of "${ac_tool_prefix}as", so it can be a program name with args.
47132 set dummy ${ac_tool_prefix}as; ac_word=$2
47133 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
47134 $as_echo_n "checking for $ac_word... " >&6; }
47135 if ${ac_cv_prog_AS+:} false; then :
47136   $as_echo_n "(cached) " >&6
47137 else
47138   if test -n "$AS"; then
47139   ac_cv_prog_AS="$AS" # Let the user override the test.
47140 else
47141 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
47142 for as_dir in $PATH
47143 do
47144   IFS=$as_save_IFS
47145   test -z "$as_dir" && as_dir=.
47146     for ac_exec_ext in '' $ac_executable_extensions; do
47147   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
47148     ac_cv_prog_AS="${ac_tool_prefix}as"
47149     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
47150     break 2
47151   fi
47152 done
47153   done
47154 IFS=$as_save_IFS
47155
47156 fi
47157 fi
47158 AS=$ac_cv_prog_AS
47159 if test -n "$AS"; then
47160   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
47161 $as_echo "$AS" >&6; }
47162 else
47163   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
47164 $as_echo "no" >&6; }
47165 fi
47166
47167
47168 fi
47169 if test -z "$ac_cv_prog_AS"; then
47170   ac_ct_AS=$AS
47171   # Extract the first word of "as", so it can be a program name with args.
47172 set dummy as; ac_word=$2
47173 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
47174 $as_echo_n "checking for $ac_word... " >&6; }
47175 if ${ac_cv_prog_ac_ct_AS+:} false; then :
47176   $as_echo_n "(cached) " >&6
47177 else
47178   if test -n "$ac_ct_AS"; then
47179   ac_cv_prog_ac_ct_AS="$ac_ct_AS" # Let the user override the test.
47180 else
47181 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
47182 for as_dir in $PATH
47183 do
47184   IFS=$as_save_IFS
47185   test -z "$as_dir" && as_dir=.
47186     for ac_exec_ext in '' $ac_executable_extensions; do
47187   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
47188     ac_cv_prog_ac_ct_AS="as"
47189     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
47190     break 2
47191   fi
47192 done
47193   done
47194 IFS=$as_save_IFS
47195
47196 fi
47197 fi
47198 ac_ct_AS=$ac_cv_prog_ac_ct_AS
47199 if test -n "$ac_ct_AS"; then
47200   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AS" >&5
47201 $as_echo "$ac_ct_AS" >&6; }
47202 else
47203   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
47204 $as_echo "no" >&6; }
47205 fi
47206
47207   if test "x$ac_ct_AS" = x; then
47208     AS="false"
47209   else
47210     case $cross_compiling:$ac_tool_warned in
47211 yes:)
47212 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
47213 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
47214 ac_tool_warned=yes ;;
47215 esac
47216     AS=$ac_ct_AS
47217   fi
47218 else
47219   AS="$ac_cv_prog_AS"
47220 fi
47221
47222   if test -n "$ac_tool_prefix"; then
47223   # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
47224 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
47225 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
47226 $as_echo_n "checking for $ac_word... " >&6; }
47227 if ${ac_cv_prog_DLLTOOL+:} false; then :
47228   $as_echo_n "(cached) " >&6
47229 else
47230   if test -n "$DLLTOOL"; then
47231   ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
47232 else
47233 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
47234 for as_dir in $PATH
47235 do
47236   IFS=$as_save_IFS
47237   test -z "$as_dir" && as_dir=.
47238     for ac_exec_ext in '' $ac_executable_extensions; do
47239   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
47240     ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
47241     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
47242     break 2
47243   fi
47244 done
47245   done
47246 IFS=$as_save_IFS
47247
47248 fi
47249 fi
47250 DLLTOOL=$ac_cv_prog_DLLTOOL
47251 if test -n "$DLLTOOL"; then
47252   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
47253 $as_echo "$DLLTOOL" >&6; }
47254 else
47255   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
47256 $as_echo "no" >&6; }
47257 fi
47258
47259
47260 fi
47261 if test -z "$ac_cv_prog_DLLTOOL"; then
47262   ac_ct_DLLTOOL=$DLLTOOL
47263   # Extract the first word of "dlltool", so it can be a program name with args.
47264 set dummy dlltool; ac_word=$2
47265 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
47266 $as_echo_n "checking for $ac_word... " >&6; }
47267 if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
47268   $as_echo_n "(cached) " >&6
47269 else
47270   if test -n "$ac_ct_DLLTOOL"; then
47271   ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
47272 else
47273 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
47274 for as_dir in $PATH
47275 do
47276   IFS=$as_save_IFS
47277   test -z "$as_dir" && as_dir=.
47278     for ac_exec_ext in '' $ac_executable_extensions; do
47279   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
47280     ac_cv_prog_ac_ct_DLLTOOL="dlltool"
47281     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
47282     break 2
47283   fi
47284 done
47285   done
47286 IFS=$as_save_IFS
47287
47288 fi
47289 fi
47290 ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
47291 if test -n "$ac_ct_DLLTOOL"; then
47292   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
47293 $as_echo "$ac_ct_DLLTOOL" >&6; }
47294 else
47295   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
47296 $as_echo "no" >&6; }
47297 fi
47298
47299   if test "x$ac_ct_DLLTOOL" = x; then
47300     DLLTOOL="false"
47301   else
47302     case $cross_compiling:$ac_tool_warned in
47303 yes:)
47304 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
47305 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
47306 ac_tool_warned=yes ;;
47307 esac
47308     DLLTOOL=$ac_ct_DLLTOOL
47309   fi
47310 else
47311   DLLTOOL="$ac_cv_prog_DLLTOOL"
47312 fi
47313
47314   if test -n "$ac_tool_prefix"; then
47315   # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
47316 set dummy ${ac_tool_prefix}objdump; ac_word=$2
47317 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
47318 $as_echo_n "checking for $ac_word... " >&6; }
47319 if ${ac_cv_prog_OBJDUMP+:} false; then :
47320   $as_echo_n "(cached) " >&6
47321 else
47322   if test -n "$OBJDUMP"; then
47323   ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
47324 else
47325 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
47326 for as_dir in $PATH
47327 do
47328   IFS=$as_save_IFS
47329   test -z "$as_dir" && as_dir=.
47330     for ac_exec_ext in '' $ac_executable_extensions; do
47331   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
47332     ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
47333     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
47334     break 2
47335   fi
47336 done
47337   done
47338 IFS=$as_save_IFS
47339
47340 fi
47341 fi
47342 OBJDUMP=$ac_cv_prog_OBJDUMP
47343 if test -n "$OBJDUMP"; then
47344   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
47345 $as_echo "$OBJDUMP" >&6; }
47346 else
47347   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
47348 $as_echo "no" >&6; }
47349 fi
47350
47351
47352 fi
47353 if test -z "$ac_cv_prog_OBJDUMP"; then
47354   ac_ct_OBJDUMP=$OBJDUMP
47355   # Extract the first word of "objdump", so it can be a program name with args.
47356 set dummy objdump; ac_word=$2
47357 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
47358 $as_echo_n "checking for $ac_word... " >&6; }
47359 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
47360   $as_echo_n "(cached) " >&6
47361 else
47362   if test -n "$ac_ct_OBJDUMP"; then
47363   ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
47364 else
47365 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
47366 for as_dir in $PATH
47367 do
47368   IFS=$as_save_IFS
47369   test -z "$as_dir" && as_dir=.
47370     for ac_exec_ext in '' $ac_executable_extensions; do
47371   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
47372     ac_cv_prog_ac_ct_OBJDUMP="objdump"
47373     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
47374     break 2
47375   fi
47376 done
47377   done
47378 IFS=$as_save_IFS
47379
47380 fi
47381 fi
47382 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
47383 if test -n "$ac_ct_OBJDUMP"; then
47384   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
47385 $as_echo "$ac_ct_OBJDUMP" >&6; }
47386 else
47387   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
47388 $as_echo "no" >&6; }
47389 fi
47390
47391   if test "x$ac_ct_OBJDUMP" = x; then
47392     OBJDUMP="false"
47393   else
47394     case $cross_compiling:$ac_tool_warned in
47395 yes:)
47396 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
47397 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
47398 ac_tool_warned=yes ;;
47399 esac
47400     OBJDUMP=$ac_ct_OBJDUMP
47401   fi
47402 else
47403   OBJDUMP="$ac_cv_prog_OBJDUMP"
47404 fi
47405
47406   ;;
47407 esac
47408
47409 test -z "$AS" && AS=as
47410
47411
47412
47413
47414
47415 test -z "$DLLTOOL" && DLLTOOL=dlltool
47416
47417
47418
47419
47420
47421 test -z "$OBJDUMP" && OBJDUMP=objdump
47422
47423
47424
47425
47426
47427
47428
47429
47430
47431   case `pwd` in
47432   *\ * | *\     *)
47433     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5
47434 $as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;;
47435 esac
47436
47437
47438
47439 macro_version='2.4.2'
47440 macro_revision='1.3337'
47441
47442
47443
47444
47445
47446
47447
47448
47449
47450
47451
47452
47453
47454 ltmain="$ac_aux_dir/ltmain.sh"
47455
47456 # Backslashify metacharacters that are still active within
47457 # double-quoted strings.
47458 sed_quote_subst='s/\(["`$\\]\)/\\\1/g'
47459
47460 # Same as above, but do not quote variable references.
47461 double_quote_subst='s/\(["`\\]\)/\\\1/g'
47462
47463 # Sed substitution to delay expansion of an escaped shell variable in a
47464 # double_quote_subst'ed string.
47465 delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
47466
47467 # Sed substitution to delay expansion of an escaped single quote.
47468 delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
47469
47470 # Sed substitution to avoid accidental globbing in evaled expressions
47471 no_glob_subst='s/\*/\\\*/g'
47472
47473 ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
47474 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
47475 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
47476
47477 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
47478 $as_echo_n "checking how to print strings... " >&6; }
47479 # Test print first, because it will be a builtin if present.
47480 if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
47481    test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
47482   ECHO='print -r --'
47483 elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
47484   ECHO='printf %s\n'
47485 else
47486   # Use this function as a fallback that always works.
47487   func_fallback_echo ()
47488   {
47489     eval 'cat <<_LTECHO_EOF
47490 $1
47491 _LTECHO_EOF'
47492   }
47493   ECHO='func_fallback_echo'
47494 fi
47495
47496 # func_echo_all arg...
47497 # Invoke $ECHO with all args, space-separated.
47498 func_echo_all ()
47499 {
47500     $ECHO ""
47501 }
47502
47503 case "$ECHO" in
47504   printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5
47505 $as_echo "printf" >&6; } ;;
47506   print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5
47507 $as_echo "print -r" >&6; } ;;
47508   *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5
47509 $as_echo "cat" >&6; } ;;
47510 esac
47511
47512
47513
47514
47515
47516
47517
47518
47519
47520
47521
47522
47523
47524
47525 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
47526 $as_echo_n "checking for a sed that does not truncate output... " >&6; }
47527 if ${ac_cv_path_SED+:} false; then :
47528   $as_echo_n "(cached) " >&6
47529 else
47530             ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
47531      for ac_i in 1 2 3 4 5 6 7; do
47532        ac_script="$ac_script$as_nl$ac_script"
47533      done
47534      echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
47535      { ac_script=; unset ac_script;}
47536      if test -z "$SED"; then
47537   ac_path_SED_found=false
47538   # Loop through the user's path and test for each of PROGNAME-LIST
47539   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
47540 for as_dir in $PATH
47541 do
47542   IFS=$as_save_IFS
47543   test -z "$as_dir" && as_dir=.
47544     for ac_prog in sed gsed; do
47545     for ac_exec_ext in '' $ac_executable_extensions; do
47546       ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
47547       as_fn_executable_p "$ac_path_SED" || continue
47548 # Check for GNU ac_path_SED and select it if it is found.
47549   # Check for GNU $ac_path_SED
47550 case `"$ac_path_SED" --version 2>&1` in
47551 *GNU*)
47552   ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
47553 *)
47554   ac_count=0
47555   $as_echo_n 0123456789 >"conftest.in"
47556   while :
47557   do
47558     cat "conftest.in" "conftest.in" >"conftest.tmp"
47559     mv "conftest.tmp" "conftest.in"
47560     cp "conftest.in" "conftest.nl"
47561     $as_echo '' >> "conftest.nl"
47562     "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
47563     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
47564     as_fn_arith $ac_count + 1 && ac_count=$as_val
47565     if test $ac_count -gt ${ac_path_SED_max-0}; then
47566       # Best one so far, save it but keep looking for a better one
47567       ac_cv_path_SED="$ac_path_SED"
47568       ac_path_SED_max=$ac_count
47569     fi
47570     # 10*(2^10) chars as input seems more than enough
47571     test $ac_count -gt 10 && break
47572   done
47573   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
47574 esac
47575
47576       $ac_path_SED_found && break 3
47577     done
47578   done
47579   done
47580 IFS=$as_save_IFS
47581   if test -z "$ac_cv_path_SED"; then
47582     as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
47583   fi
47584 else
47585   ac_cv_path_SED=$SED
47586 fi
47587
47588 fi
47589 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
47590 $as_echo "$ac_cv_path_SED" >&6; }
47591  SED="$ac_cv_path_SED"
47592   rm -f conftest.sed
47593
47594 test -z "$SED" && SED=sed
47595 Xsed="$SED -e 1s/^X//"
47596
47597
47598
47599
47600
47601
47602
47603
47604
47605
47606
47607 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
47608 $as_echo_n "checking for fgrep... " >&6; }
47609 if ${ac_cv_path_FGREP+:} false; then :
47610   $as_echo_n "(cached) " >&6
47611 else
47612   if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
47613    then ac_cv_path_FGREP="$GREP -F"
47614    else
47615      if test -z "$FGREP"; then
47616   ac_path_FGREP_found=false
47617   # Loop through the user's path and test for each of PROGNAME-LIST
47618   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
47619 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
47620 do
47621   IFS=$as_save_IFS
47622   test -z "$as_dir" && as_dir=.
47623     for ac_prog in fgrep; do
47624     for ac_exec_ext in '' $ac_executable_extensions; do
47625       ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
47626       as_fn_executable_p "$ac_path_FGREP" || continue
47627 # Check for GNU ac_path_FGREP and select it if it is found.
47628   # Check for GNU $ac_path_FGREP
47629 case `"$ac_path_FGREP" --version 2>&1` in
47630 *GNU*)
47631   ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
47632 *)
47633   ac_count=0
47634   $as_echo_n 0123456789 >"conftest.in"
47635   while :
47636   do
47637     cat "conftest.in" "conftest.in" >"conftest.tmp"
47638     mv "conftest.tmp" "conftest.in"
47639     cp "conftest.in" "conftest.nl"
47640     $as_echo 'FGREP' >> "conftest.nl"
47641     "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
47642     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
47643     as_fn_arith $ac_count + 1 && ac_count=$as_val
47644     if test $ac_count -gt ${ac_path_FGREP_max-0}; then
47645       # Best one so far, save it but keep looking for a better one
47646       ac_cv_path_FGREP="$ac_path_FGREP"
47647       ac_path_FGREP_max=$ac_count
47648     fi
47649     # 10*(2^10) chars as input seems more than enough
47650     test $ac_count -gt 10 && break
47651   done
47652   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
47653 esac
47654
47655       $ac_path_FGREP_found && break 3
47656     done
47657   done
47658   done
47659 IFS=$as_save_IFS
47660   if test -z "$ac_cv_path_FGREP"; then
47661     as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
47662   fi
47663 else
47664   ac_cv_path_FGREP=$FGREP
47665 fi
47666
47667    fi
47668 fi
47669 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
47670 $as_echo "$ac_cv_path_FGREP" >&6; }
47671  FGREP="$ac_cv_path_FGREP"
47672
47673
47674 test -z "$GREP" && GREP=grep
47675
47676
47677
47678
47679
47680
47681
47682
47683
47684
47685
47686
47687
47688
47689
47690
47691
47692
47693
47694 # Check whether --with-gnu-ld was given.
47695 if test "${with_gnu_ld+set}" = set; then :
47696   withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
47697 else
47698   with_gnu_ld=no
47699 fi
47700
47701 ac_prog=ld
47702 if test "$GCC" = yes; then
47703   # Check if gcc -print-prog-name=ld gives a path.
47704   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
47705 $as_echo_n "checking for ld used by $CC... " >&6; }
47706   case $host in
47707   *-*-mingw*)
47708     # gcc leaves a trailing carriage return which upsets mingw
47709     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
47710   *)
47711     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
47712   esac
47713   case $ac_prog in
47714     # Accept absolute paths.
47715     [\\/]* | ?:[\\/]*)
47716       re_direlt='/[^/][^/]*/\.\./'
47717       # Canonicalize the pathname of ld
47718       ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
47719       while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
47720         ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
47721       done
47722       test -z "$LD" && LD="$ac_prog"
47723       ;;
47724   "")
47725     # If it fails, then pretend we aren't using GCC.
47726     ac_prog=ld
47727     ;;
47728   *)
47729     # If it is relative, then search for the first ld in PATH.
47730     with_gnu_ld=unknown
47731     ;;
47732   esac
47733 elif test "$with_gnu_ld" = yes; then
47734   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
47735 $as_echo_n "checking for GNU ld... " >&6; }
47736 else
47737   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
47738 $as_echo_n "checking for non-GNU ld... " >&6; }
47739 fi
47740 if ${lt_cv_path_LD+:} false; then :
47741   $as_echo_n "(cached) " >&6
47742 else
47743   if test -z "$LD"; then
47744   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
47745   for ac_dir in $PATH; do
47746     IFS="$lt_save_ifs"
47747     test -z "$ac_dir" && ac_dir=.
47748     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
47749       lt_cv_path_LD="$ac_dir/$ac_prog"
47750       # Check to see if the program is GNU ld.  I'd rather use --version,
47751       # but apparently some variants of GNU ld only accept -v.
47752       # Break only if it was the GNU/non-GNU ld that we prefer.
47753       case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
47754       *GNU* | *'with BFD'*)
47755         test "$with_gnu_ld" != no && break
47756         ;;
47757       *)
47758         test "$with_gnu_ld" != yes && break
47759         ;;
47760       esac
47761     fi
47762   done
47763   IFS="$lt_save_ifs"
47764 else
47765   lt_cv_path_LD="$LD" # Let the user override the test with a path.
47766 fi
47767 fi
47768
47769 LD="$lt_cv_path_LD"
47770 if test -n "$LD"; then
47771   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
47772 $as_echo "$LD" >&6; }
47773 else
47774   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
47775 $as_echo "no" >&6; }
47776 fi
47777 test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
47778 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
47779 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
47780 if ${lt_cv_prog_gnu_ld+:} false; then :
47781   $as_echo_n "(cached) " >&6
47782 else
47783   # I'd rather use --version here, but apparently some GNU lds only accept -v.
47784 case `$LD -v 2>&1 </dev/null` in
47785 *GNU* | *'with BFD'*)
47786   lt_cv_prog_gnu_ld=yes
47787   ;;
47788 *)
47789   lt_cv_prog_gnu_ld=no
47790   ;;
47791 esac
47792 fi
47793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
47794 $as_echo "$lt_cv_prog_gnu_ld" >&6; }
47795 with_gnu_ld=$lt_cv_prog_gnu_ld
47796
47797
47798
47799
47800
47801
47802
47803
47804
47805 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5
47806 $as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; }
47807 if ${lt_cv_path_NM+:} false; then :
47808   $as_echo_n "(cached) " >&6
47809 else
47810   if test -n "$NM"; then
47811   # Let the user override the test.
47812   lt_cv_path_NM="$NM"
47813 else
47814   lt_nm_to_check="${ac_tool_prefix}nm"
47815   if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
47816     lt_nm_to_check="$lt_nm_to_check nm"
47817   fi
47818   for lt_tmp_nm in $lt_nm_to_check; do
47819     lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
47820     for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
47821       IFS="$lt_save_ifs"
47822       test -z "$ac_dir" && ac_dir=.
47823       tmp_nm="$ac_dir/$lt_tmp_nm"
47824       if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
47825         # Check to see if the nm accepts a BSD-compat flag.
47826         # Adding the `sed 1q' prevents false positives on HP-UX, which says:
47827         #   nm: unknown option "B" ignored
47828         # Tru64's nm complains that /dev/null is an invalid object file
47829         case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
47830         */dev/null* | *'Invalid file or object type'*)
47831           lt_cv_path_NM="$tmp_nm -B"
47832           break
47833           ;;
47834         *)
47835           case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
47836           */dev/null*)
47837             lt_cv_path_NM="$tmp_nm -p"
47838             break
47839             ;;
47840           *)
47841             lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
47842             continue # so that we can try to find one that supports BSD flags
47843             ;;
47844           esac
47845           ;;
47846         esac
47847       fi
47848     done
47849     IFS="$lt_save_ifs"
47850   done
47851   : ${lt_cv_path_NM=no}
47852 fi
47853 fi
47854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5
47855 $as_echo "$lt_cv_path_NM" >&6; }
47856 if test "$lt_cv_path_NM" != "no"; then
47857   NM="$lt_cv_path_NM"
47858 else
47859   # Didn't find any BSD compatible name lister, look for dumpbin.
47860   if test -n "$DUMPBIN"; then :
47861     # Let the user override the test.
47862   else
47863     if test -n "$ac_tool_prefix"; then
47864   for ac_prog in dumpbin "link -dump"
47865   do
47866     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
47867 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
47868 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
47869 $as_echo_n "checking for $ac_word... " >&6; }
47870 if ${ac_cv_prog_DUMPBIN+:} false; then :
47871   $as_echo_n "(cached) " >&6
47872 else
47873   if test -n "$DUMPBIN"; then
47874   ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test.
47875 else
47876 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
47877 for as_dir in $PATH
47878 do
47879   IFS=$as_save_IFS
47880   test -z "$as_dir" && as_dir=.
47881     for ac_exec_ext in '' $ac_executable_extensions; do
47882   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
47883     ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog"
47884     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
47885     break 2
47886   fi
47887 done
47888   done
47889 IFS=$as_save_IFS
47890
47891 fi
47892 fi
47893 DUMPBIN=$ac_cv_prog_DUMPBIN
47894 if test -n "$DUMPBIN"; then
47895   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5
47896 $as_echo "$DUMPBIN" >&6; }
47897 else
47898   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
47899 $as_echo "no" >&6; }
47900 fi
47901
47902
47903     test -n "$DUMPBIN" && break
47904   done
47905 fi
47906 if test -z "$DUMPBIN"; then
47907   ac_ct_DUMPBIN=$DUMPBIN
47908   for ac_prog in dumpbin "link -dump"
47909 do
47910   # Extract the first word of "$ac_prog", so it can be a program name with args.
47911 set dummy $ac_prog; ac_word=$2
47912 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
47913 $as_echo_n "checking for $ac_word... " >&6; }
47914 if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then :
47915   $as_echo_n "(cached) " >&6
47916 else
47917   if test -n "$ac_ct_DUMPBIN"; then
47918   ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test.
47919 else
47920 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
47921 for as_dir in $PATH
47922 do
47923   IFS=$as_save_IFS
47924   test -z "$as_dir" && as_dir=.
47925     for ac_exec_ext in '' $ac_executable_extensions; do
47926   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
47927     ac_cv_prog_ac_ct_DUMPBIN="$ac_prog"
47928     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
47929     break 2
47930   fi
47931 done
47932   done
47933 IFS=$as_save_IFS
47934
47935 fi
47936 fi
47937 ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN
47938 if test -n "$ac_ct_DUMPBIN"; then
47939   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5
47940 $as_echo "$ac_ct_DUMPBIN" >&6; }
47941 else
47942   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
47943 $as_echo "no" >&6; }
47944 fi
47945
47946
47947   test -n "$ac_ct_DUMPBIN" && break
47948 done
47949
47950   if test "x$ac_ct_DUMPBIN" = x; then
47951     DUMPBIN=":"
47952   else
47953     case $cross_compiling:$ac_tool_warned in
47954 yes:)
47955 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
47956 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
47957 ac_tool_warned=yes ;;
47958 esac
47959     DUMPBIN=$ac_ct_DUMPBIN
47960   fi
47961 fi
47962
47963     case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in
47964     *COFF*)
47965       DUMPBIN="$DUMPBIN -symbols"
47966       ;;
47967     *)
47968       DUMPBIN=:
47969       ;;
47970     esac
47971   fi
47972
47973   if test "$DUMPBIN" != ":"; then
47974     NM="$DUMPBIN"
47975   fi
47976 fi
47977 test -z "$NM" && NM=nm
47978
47979
47980
47981
47982
47983
47984 { $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5
47985 $as_echo_n "checking the name lister ($NM) interface... " >&6; }
47986 if ${lt_cv_nm_interface+:} false; then :
47987   $as_echo_n "(cached) " >&6
47988 else
47989   lt_cv_nm_interface="BSD nm"
47990   echo "int some_variable = 0;" > conftest.$ac_ext
47991   (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5)
47992   (eval "$ac_compile" 2>conftest.err)
47993   cat conftest.err >&5
47994   (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
47995   (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
47996   cat conftest.err >&5
47997   (eval echo "\"\$as_me:$LINENO: output\"" >&5)
47998   cat conftest.out >&5
47999   if $GREP 'External.*some_variable' conftest.out > /dev/null; then
48000     lt_cv_nm_interface="MS dumpbin"
48001   fi
48002   rm -f conftest*
48003 fi
48004 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5
48005 $as_echo "$lt_cv_nm_interface" >&6; }
48006
48007 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
48008 $as_echo_n "checking whether ln -s works... " >&6; }
48009 LN_S=$as_ln_s
48010 if test "$LN_S" = "ln -s"; then
48011   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
48012 $as_echo "yes" >&6; }
48013 else
48014   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
48015 $as_echo "no, using $LN_S" >&6; }
48016 fi
48017
48018 # find the maximum length of command line arguments
48019 { $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5
48020 $as_echo_n "checking the maximum length of command line arguments... " >&6; }
48021 if ${lt_cv_sys_max_cmd_len+:} false; then :
48022   $as_echo_n "(cached) " >&6
48023 else
48024     i=0
48025   teststring="ABCD"
48026
48027   case $build_os in
48028   msdosdjgpp*)
48029     # On DJGPP, this test can blow up pretty badly due to problems in libc
48030     # (any single argument exceeding 2000 bytes causes a buffer overrun
48031     # during glob expansion).  Even if it were fixed, the result of this
48032     # check would be larger than it should be.
48033     lt_cv_sys_max_cmd_len=12288;    # 12K is about right
48034     ;;
48035
48036   gnu*)
48037     # Under GNU Hurd, this test is not required because there is
48038     # no limit to the length of command line arguments.
48039     # Libtool will interpret -1 as no limit whatsoever
48040     lt_cv_sys_max_cmd_len=-1;
48041     ;;
48042
48043   cygwin* | mingw* | cegcc*)
48044     # On Win9x/ME, this test blows up -- it succeeds, but takes
48045     # about 5 minutes as the teststring grows exponentially.
48046     # Worse, since 9x/ME are not pre-emptively multitasking,
48047     # you end up with a "frozen" computer, even though with patience
48048     # the test eventually succeeds (with a max line length of 256k).
48049     # Instead, let's just punt: use the minimum linelength reported by
48050     # all of the supported platforms: 8192 (on NT/2K/XP).
48051     lt_cv_sys_max_cmd_len=8192;
48052     ;;
48053
48054   mint*)
48055     # On MiNT this can take a long time and run out of memory.
48056     lt_cv_sys_max_cmd_len=8192;
48057     ;;
48058
48059   amigaos*)
48060     # On AmigaOS with pdksh, this test takes hours, literally.
48061     # So we just punt and use a minimum line length of 8192.
48062     lt_cv_sys_max_cmd_len=8192;
48063     ;;
48064
48065   netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
48066     # This has been around since 386BSD, at least.  Likely further.
48067     if test -x /sbin/sysctl; then
48068       lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
48069     elif test -x /usr/sbin/sysctl; then
48070       lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
48071     else
48072       lt_cv_sys_max_cmd_len=65536       # usable default for all BSDs
48073     fi
48074     # And add a safety zone
48075     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
48076     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
48077     ;;
48078
48079   interix*)
48080     # We know the value 262144 and hardcode it with a safety zone (like BSD)
48081     lt_cv_sys_max_cmd_len=196608
48082     ;;
48083
48084   os2*)
48085     # The test takes a long time on OS/2.
48086     lt_cv_sys_max_cmd_len=8192
48087     ;;
48088
48089   osf*)
48090     # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
48091     # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
48092     # nice to cause kernel panics so lets avoid the loop below.
48093     # First set a reasonable default.
48094     lt_cv_sys_max_cmd_len=16384
48095     #
48096     if test -x /sbin/sysconfig; then
48097       case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
48098         *1*) lt_cv_sys_max_cmd_len=-1 ;;
48099       esac
48100     fi
48101     ;;
48102   sco3.2v5*)
48103     lt_cv_sys_max_cmd_len=102400
48104     ;;
48105   sysv5* | sco5v6* | sysv4.2uw2*)
48106     kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
48107     if test -n "$kargmax"; then
48108       lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[  ]//'`
48109     else
48110       lt_cv_sys_max_cmd_len=32768
48111     fi
48112     ;;
48113   *)
48114     lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
48115     if test -n "$lt_cv_sys_max_cmd_len"; then
48116       lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
48117       lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
48118     else
48119       # Make teststring a little bigger before we do anything with it.
48120       # a 1K string should be a reasonable start.
48121       for i in 1 2 3 4 5 6 7 8 ; do
48122         teststring=$teststring$teststring
48123       done
48124       SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
48125       # If test is not a shell built-in, we'll probably end up computing a
48126       # maximum length that is only half of the actual maximum length, but
48127       # we can't tell.
48128       while { test "X"`env echo "$teststring$teststring" 2>/dev/null` \
48129                  = "X$teststring$teststring"; } >/dev/null 2>&1 &&
48130               test $i != 17 # 1/2 MB should be enough
48131       do
48132         i=`expr $i + 1`
48133         teststring=$teststring$teststring
48134       done
48135       # Only check the string length outside the loop.
48136       lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
48137       teststring=
48138       # Add a significant safety factor because C++ compilers can tack on
48139       # massive amounts of additional arguments before passing them to the
48140       # linker.  It appears as though 1/2 is a usable value.
48141       lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
48142     fi
48143     ;;
48144   esac
48145
48146 fi
48147
48148 if test -n $lt_cv_sys_max_cmd_len ; then
48149   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5
48150 $as_echo "$lt_cv_sys_max_cmd_len" >&6; }
48151 else
48152   { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5
48153 $as_echo "none" >&6; }
48154 fi
48155 max_cmd_len=$lt_cv_sys_max_cmd_len
48156
48157
48158
48159
48160
48161
48162 : ${CP="cp -f"}
48163 : ${MV="mv -f"}
48164 : ${RM="rm -f"}
48165
48166 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands some XSI constructs" >&5
48167 $as_echo_n "checking whether the shell understands some XSI constructs... " >&6; }
48168 # Try some XSI features
48169 xsi_shell=no
48170 ( _lt_dummy="a/b/c"
48171   test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \
48172       = c,a/b,b/c, \
48173     && eval 'test $(( 1 + 1 )) -eq 2 \
48174     && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
48175   && xsi_shell=yes
48176 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $xsi_shell" >&5
48177 $as_echo "$xsi_shell" >&6; }
48178
48179
48180 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands \"+=\"" >&5
48181 $as_echo_n "checking whether the shell understands \"+=\"... " >&6; }
48182 lt_shell_append=no
48183 ( foo=bar; set foo baz; eval "$1+=\$2" && test "$foo" = barbaz ) \
48184     >/dev/null 2>&1 \
48185   && lt_shell_append=yes
48186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_shell_append" >&5
48187 $as_echo "$lt_shell_append" >&6; }
48188
48189
48190 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
48191   lt_unset=unset
48192 else
48193   lt_unset=false
48194 fi
48195
48196
48197
48198
48199
48200 # test EBCDIC or ASCII
48201 case `echo X|tr X '\101'` in
48202  A) # ASCII based system
48203     # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
48204   lt_SP2NL='tr \040 \012'
48205   lt_NL2SP='tr \015\012 \040\040'
48206   ;;
48207  *) # EBCDIC based system
48208   lt_SP2NL='tr \100 \n'
48209   lt_NL2SP='tr \r\n \100\100'
48210   ;;
48211 esac
48212
48213
48214
48215
48216
48217
48218
48219
48220
48221 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5
48222 $as_echo_n "checking how to convert $build file names to $host format... " >&6; }
48223 if ${lt_cv_to_host_file_cmd+:} false; then :
48224   $as_echo_n "(cached) " >&6
48225 else
48226   case $host in
48227   *-*-mingw* )
48228     case $build in
48229       *-*-mingw* ) # actually msys
48230         lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
48231         ;;
48232       *-*-cygwin* )
48233         lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
48234         ;;
48235       * ) # otherwise, assume *nix
48236         lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
48237         ;;
48238     esac
48239     ;;
48240   *-*-cygwin* )
48241     case $build in
48242       *-*-mingw* ) # actually msys
48243         lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
48244         ;;
48245       *-*-cygwin* )
48246         lt_cv_to_host_file_cmd=func_convert_file_noop
48247         ;;
48248       * ) # otherwise, assume *nix
48249         lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
48250         ;;
48251     esac
48252     ;;
48253   * ) # unhandled hosts (and "normal" native builds)
48254     lt_cv_to_host_file_cmd=func_convert_file_noop
48255     ;;
48256 esac
48257
48258 fi
48259
48260 to_host_file_cmd=$lt_cv_to_host_file_cmd
48261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5
48262 $as_echo "$lt_cv_to_host_file_cmd" >&6; }
48263
48264
48265
48266
48267
48268 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5
48269 $as_echo_n "checking how to convert $build file names to toolchain format... " >&6; }
48270 if ${lt_cv_to_tool_file_cmd+:} false; then :
48271   $as_echo_n "(cached) " >&6
48272 else
48273   #assume ordinary cross tools, or native build.
48274 lt_cv_to_tool_file_cmd=func_convert_file_noop
48275 case $host in
48276   *-*-mingw* )
48277     case $build in
48278       *-*-mingw* ) # actually msys
48279         lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
48280         ;;
48281     esac
48282     ;;
48283 esac
48284
48285 fi
48286
48287 to_tool_file_cmd=$lt_cv_to_tool_file_cmd
48288 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5
48289 $as_echo "$lt_cv_to_tool_file_cmd" >&6; }
48290
48291
48292
48293
48294
48295 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
48296 $as_echo_n "checking for $LD option to reload object files... " >&6; }
48297 if ${lt_cv_ld_reload_flag+:} false; then :
48298   $as_echo_n "(cached) " >&6
48299 else
48300   lt_cv_ld_reload_flag='-r'
48301 fi
48302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5
48303 $as_echo "$lt_cv_ld_reload_flag" >&6; }
48304 reload_flag=$lt_cv_ld_reload_flag
48305 case $reload_flag in
48306 "" | " "*) ;;
48307 *) reload_flag=" $reload_flag" ;;
48308 esac
48309 reload_cmds='$LD$reload_flag -o $output$reload_objs'
48310 case $host_os in
48311   cygwin* | mingw* | pw32* | cegcc*)
48312     if test "$GCC" != yes; then
48313       reload_cmds=false
48314     fi
48315     ;;
48316   darwin*)
48317     if test "$GCC" = yes; then
48318       reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
48319     else
48320       reload_cmds='$LD$reload_flag -o $output$reload_objs'
48321     fi
48322     ;;
48323 esac
48324
48325
48326
48327
48328
48329
48330
48331
48332
48333 if test -n "$ac_tool_prefix"; then
48334   # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
48335 set dummy ${ac_tool_prefix}objdump; ac_word=$2
48336 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
48337 $as_echo_n "checking for $ac_word... " >&6; }
48338 if ${ac_cv_prog_OBJDUMP+:} false; then :
48339   $as_echo_n "(cached) " >&6
48340 else
48341   if test -n "$OBJDUMP"; then
48342   ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
48343 else
48344 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
48345 for as_dir in $PATH
48346 do
48347   IFS=$as_save_IFS
48348   test -z "$as_dir" && as_dir=.
48349     for ac_exec_ext in '' $ac_executable_extensions; do
48350   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
48351     ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
48352     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
48353     break 2
48354   fi
48355 done
48356   done
48357 IFS=$as_save_IFS
48358
48359 fi
48360 fi
48361 OBJDUMP=$ac_cv_prog_OBJDUMP
48362 if test -n "$OBJDUMP"; then
48363   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
48364 $as_echo "$OBJDUMP" >&6; }
48365 else
48366   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48367 $as_echo "no" >&6; }
48368 fi
48369
48370
48371 fi
48372 if test -z "$ac_cv_prog_OBJDUMP"; then
48373   ac_ct_OBJDUMP=$OBJDUMP
48374   # Extract the first word of "objdump", so it can be a program name with args.
48375 set dummy objdump; ac_word=$2
48376 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
48377 $as_echo_n "checking for $ac_word... " >&6; }
48378 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
48379   $as_echo_n "(cached) " >&6
48380 else
48381   if test -n "$ac_ct_OBJDUMP"; then
48382   ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
48383 else
48384 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
48385 for as_dir in $PATH
48386 do
48387   IFS=$as_save_IFS
48388   test -z "$as_dir" && as_dir=.
48389     for ac_exec_ext in '' $ac_executable_extensions; do
48390   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
48391     ac_cv_prog_ac_ct_OBJDUMP="objdump"
48392     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
48393     break 2
48394   fi
48395 done
48396   done
48397 IFS=$as_save_IFS
48398
48399 fi
48400 fi
48401 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
48402 if test -n "$ac_ct_OBJDUMP"; then
48403   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
48404 $as_echo "$ac_ct_OBJDUMP" >&6; }
48405 else
48406   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48407 $as_echo "no" >&6; }
48408 fi
48409
48410   if test "x$ac_ct_OBJDUMP" = x; then
48411     OBJDUMP="false"
48412   else
48413     case $cross_compiling:$ac_tool_warned in
48414 yes:)
48415 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
48416 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
48417 ac_tool_warned=yes ;;
48418 esac
48419     OBJDUMP=$ac_ct_OBJDUMP
48420   fi
48421 else
48422   OBJDUMP="$ac_cv_prog_OBJDUMP"
48423 fi
48424
48425 test -z "$OBJDUMP" && OBJDUMP=objdump
48426
48427
48428
48429
48430
48431
48432 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5
48433 $as_echo_n "checking how to recognize dependent libraries... " >&6; }
48434 if ${lt_cv_deplibs_check_method+:} false; then :
48435   $as_echo_n "(cached) " >&6
48436 else
48437   lt_cv_file_magic_cmd='$MAGIC_CMD'
48438 lt_cv_file_magic_test_file=
48439 lt_cv_deplibs_check_method='unknown'
48440 # Need to set the preceding variable on all platforms that support
48441 # interlibrary dependencies.
48442 # 'none' -- dependencies not supported.
48443 # `unknown' -- same as none, but documents that we really don't know.
48444 # 'pass_all' -- all dependencies passed with no checks.
48445 # 'test_compile' -- check by making test program.
48446 # 'file_magic [[regex]]' -- check by looking for files in library path
48447 # which responds to the $file_magic_cmd with a given extended regex.
48448 # If you have `file' or equivalent on your system and you're not sure
48449 # whether `pass_all' will *always* work, you probably want this one.
48450
48451 case $host_os in
48452 aix[4-9]*)
48453   lt_cv_deplibs_check_method=pass_all
48454   ;;
48455
48456 beos*)
48457   lt_cv_deplibs_check_method=pass_all
48458   ;;
48459
48460 bsdi[45]*)
48461   lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
48462   lt_cv_file_magic_cmd='/usr/bin/file -L'
48463   lt_cv_file_magic_test_file=/shlib/libc.so
48464   ;;
48465
48466 cygwin*)
48467   # func_win32_libid is a shell function defined in ltmain.sh
48468   lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
48469   lt_cv_file_magic_cmd='func_win32_libid'
48470   ;;
48471
48472 mingw* | pw32*)
48473   # Base MSYS/MinGW do not provide the 'file' command needed by
48474   # func_win32_libid shell function, so use a weaker test based on 'objdump',
48475   # unless we find 'file', for example because we are cross-compiling.
48476   # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin.
48477   if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then
48478     lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
48479     lt_cv_file_magic_cmd='func_win32_libid'
48480   else
48481     # Keep this pattern in sync with the one in func_win32_libid.
48482     lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
48483     lt_cv_file_magic_cmd='$OBJDUMP -f'
48484   fi
48485   ;;
48486
48487 cegcc*)
48488   # use the weaker test based on 'objdump'. See mingw*.
48489   lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
48490   lt_cv_file_magic_cmd='$OBJDUMP -f'
48491   ;;
48492
48493 darwin* | rhapsody*)
48494   lt_cv_deplibs_check_method=pass_all
48495   ;;
48496
48497 freebsd* | dragonfly*)
48498   if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
48499     case $host_cpu in
48500     i*86 )
48501       # Not sure whether the presence of OpenBSD here was a mistake.
48502       # Let's accept both of them until this is cleared up.
48503       lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library'
48504       lt_cv_file_magic_cmd=/usr/bin/file
48505       lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
48506       ;;
48507     esac
48508   else
48509     lt_cv_deplibs_check_method=pass_all
48510   fi
48511   ;;
48512
48513 gnu*)
48514   lt_cv_deplibs_check_method=pass_all
48515   ;;
48516
48517 haiku*)
48518   lt_cv_deplibs_check_method=pass_all
48519   ;;
48520
48521 hpux10.20* | hpux11*)
48522   lt_cv_file_magic_cmd=/usr/bin/file
48523   case $host_cpu in
48524   ia64*)
48525     lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
48526     lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
48527     ;;
48528   hppa*64*)
48529     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]'
48530     lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
48531     ;;
48532   *)
48533     lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library'
48534     lt_cv_file_magic_test_file=/usr/lib/libc.sl
48535     ;;
48536   esac
48537   ;;
48538
48539 interix[3-9]*)
48540   # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
48541   lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$'
48542   ;;
48543
48544 irix5* | irix6* | nonstopux*)
48545   case $LD in
48546   *-32|*"-32 ") libmagic=32-bit;;
48547   *-n32|*"-n32 ") libmagic=N32;;
48548   *-64|*"-64 ") libmagic=64-bit;;
48549   *) libmagic=never-match;;
48550   esac
48551   lt_cv_deplibs_check_method=pass_all
48552   ;;
48553
48554 # This must be glibc/ELF.
48555 linux* | k*bsd*-gnu | kopensolaris*-gnu)
48556   lt_cv_deplibs_check_method=pass_all
48557   ;;
48558
48559 netbsd*)
48560   if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
48561     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
48562   else
48563     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$'
48564   fi
48565   ;;
48566
48567 newos6*)
48568   lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
48569   lt_cv_file_magic_cmd=/usr/bin/file
48570   lt_cv_file_magic_test_file=/usr/lib/libnls.so
48571   ;;
48572
48573 *nto* | *qnx*)
48574   lt_cv_deplibs_check_method=pass_all
48575   ;;
48576
48577 openbsd*)
48578   if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
48579     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$'
48580   else
48581     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
48582   fi
48583   ;;
48584
48585 osf3* | osf4* | osf5*)
48586   lt_cv_deplibs_check_method=pass_all
48587   ;;
48588
48589 rdos*)
48590   lt_cv_deplibs_check_method=pass_all
48591   ;;
48592
48593 solaris*)
48594   lt_cv_deplibs_check_method=pass_all
48595   ;;
48596
48597 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
48598   lt_cv_deplibs_check_method=pass_all
48599   ;;
48600
48601 sysv4 | sysv4.3*)
48602   case $host_vendor in
48603   motorola)
48604     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]'
48605     lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
48606     ;;
48607   ncr)
48608     lt_cv_deplibs_check_method=pass_all
48609     ;;
48610   sequent)
48611     lt_cv_file_magic_cmd='/bin/file'
48612     lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
48613     ;;
48614   sni)
48615     lt_cv_file_magic_cmd='/bin/file'
48616     lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
48617     lt_cv_file_magic_test_file=/lib/libc.so
48618     ;;
48619   siemens)
48620     lt_cv_deplibs_check_method=pass_all
48621     ;;
48622   pc)
48623     lt_cv_deplibs_check_method=pass_all
48624     ;;
48625   esac
48626   ;;
48627
48628 tpf*)
48629   lt_cv_deplibs_check_method=pass_all
48630   ;;
48631 esac
48632
48633 fi
48634 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
48635 $as_echo "$lt_cv_deplibs_check_method" >&6; }
48636
48637 file_magic_glob=
48638 want_nocaseglob=no
48639 if test "$build" = "$host"; then
48640   case $host_os in
48641   mingw* | pw32*)
48642     if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
48643       want_nocaseglob=yes
48644     else
48645       file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"`
48646     fi
48647     ;;
48648   esac
48649 fi
48650
48651 file_magic_cmd=$lt_cv_file_magic_cmd
48652 deplibs_check_method=$lt_cv_deplibs_check_method
48653 test -z "$deplibs_check_method" && deplibs_check_method=unknown
48654
48655
48656
48657
48658
48659
48660
48661
48662
48663
48664
48665
48666
48667
48668
48669
48670
48671
48672
48673
48674
48675
48676 if test -n "$ac_tool_prefix"; then
48677   # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
48678 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
48679 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
48680 $as_echo_n "checking for $ac_word... " >&6; }
48681 if ${ac_cv_prog_DLLTOOL+:} false; then :
48682   $as_echo_n "(cached) " >&6
48683 else
48684   if test -n "$DLLTOOL"; then
48685   ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
48686 else
48687 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
48688 for as_dir in $PATH
48689 do
48690   IFS=$as_save_IFS
48691   test -z "$as_dir" && as_dir=.
48692     for ac_exec_ext in '' $ac_executable_extensions; do
48693   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
48694     ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
48695     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
48696     break 2
48697   fi
48698 done
48699   done
48700 IFS=$as_save_IFS
48701
48702 fi
48703 fi
48704 DLLTOOL=$ac_cv_prog_DLLTOOL
48705 if test -n "$DLLTOOL"; then
48706   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
48707 $as_echo "$DLLTOOL" >&6; }
48708 else
48709   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48710 $as_echo "no" >&6; }
48711 fi
48712
48713
48714 fi
48715 if test -z "$ac_cv_prog_DLLTOOL"; then
48716   ac_ct_DLLTOOL=$DLLTOOL
48717   # Extract the first word of "dlltool", so it can be a program name with args.
48718 set dummy dlltool; ac_word=$2
48719 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
48720 $as_echo_n "checking for $ac_word... " >&6; }
48721 if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
48722   $as_echo_n "(cached) " >&6
48723 else
48724   if test -n "$ac_ct_DLLTOOL"; then
48725   ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
48726 else
48727 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
48728 for as_dir in $PATH
48729 do
48730   IFS=$as_save_IFS
48731   test -z "$as_dir" && as_dir=.
48732     for ac_exec_ext in '' $ac_executable_extensions; do
48733   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
48734     ac_cv_prog_ac_ct_DLLTOOL="dlltool"
48735     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
48736     break 2
48737   fi
48738 done
48739   done
48740 IFS=$as_save_IFS
48741
48742 fi
48743 fi
48744 ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
48745 if test -n "$ac_ct_DLLTOOL"; then
48746   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
48747 $as_echo "$ac_ct_DLLTOOL" >&6; }
48748 else
48749   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48750 $as_echo "no" >&6; }
48751 fi
48752
48753   if test "x$ac_ct_DLLTOOL" = x; then
48754     DLLTOOL="false"
48755   else
48756     case $cross_compiling:$ac_tool_warned in
48757 yes:)
48758 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
48759 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
48760 ac_tool_warned=yes ;;
48761 esac
48762     DLLTOOL=$ac_ct_DLLTOOL
48763   fi
48764 else
48765   DLLTOOL="$ac_cv_prog_DLLTOOL"
48766 fi
48767
48768 test -z "$DLLTOOL" && DLLTOOL=dlltool
48769
48770
48771
48772
48773
48774
48775
48776 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5
48777 $as_echo_n "checking how to associate runtime and link libraries... " >&6; }
48778 if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then :
48779   $as_echo_n "(cached) " >&6
48780 else
48781   lt_cv_sharedlib_from_linklib_cmd='unknown'
48782
48783 case $host_os in
48784 cygwin* | mingw* | pw32* | cegcc*)
48785   # two different shell functions defined in ltmain.sh
48786   # decide which to use based on capabilities of $DLLTOOL
48787   case `$DLLTOOL --help 2>&1` in
48788   *--identify-strict*)
48789     lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
48790     ;;
48791   *)
48792     lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
48793     ;;
48794   esac
48795   ;;
48796 *)
48797   # fallback: assume linklib IS sharedlib
48798   lt_cv_sharedlib_from_linklib_cmd="$ECHO"
48799   ;;
48800 esac
48801
48802 fi
48803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5
48804 $as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; }
48805 sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
48806 test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
48807
48808
48809
48810
48811
48812
48813
48814 if test -n "$ac_tool_prefix"; then
48815   for ac_prog in ar
48816   do
48817     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
48818 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
48819 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
48820 $as_echo_n "checking for $ac_word... " >&6; }
48821 if ${ac_cv_prog_AR+:} false; then :
48822   $as_echo_n "(cached) " >&6
48823 else
48824   if test -n "$AR"; then
48825   ac_cv_prog_AR="$AR" # Let the user override the test.
48826 else
48827 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
48828 for as_dir in $PATH
48829 do
48830   IFS=$as_save_IFS
48831   test -z "$as_dir" && as_dir=.
48832     for ac_exec_ext in '' $ac_executable_extensions; do
48833   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
48834     ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
48835     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
48836     break 2
48837   fi
48838 done
48839   done
48840 IFS=$as_save_IFS
48841
48842 fi
48843 fi
48844 AR=$ac_cv_prog_AR
48845 if test -n "$AR"; then
48846   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
48847 $as_echo "$AR" >&6; }
48848 else
48849   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48850 $as_echo "no" >&6; }
48851 fi
48852
48853
48854     test -n "$AR" && break
48855   done
48856 fi
48857 if test -z "$AR"; then
48858   ac_ct_AR=$AR
48859   for ac_prog in ar
48860 do
48861   # Extract the first word of "$ac_prog", so it can be a program name with args.
48862 set dummy $ac_prog; ac_word=$2
48863 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
48864 $as_echo_n "checking for $ac_word... " >&6; }
48865 if ${ac_cv_prog_ac_ct_AR+:} false; then :
48866   $as_echo_n "(cached) " >&6
48867 else
48868   if test -n "$ac_ct_AR"; then
48869   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
48870 else
48871 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
48872 for as_dir in $PATH
48873 do
48874   IFS=$as_save_IFS
48875   test -z "$as_dir" && as_dir=.
48876     for ac_exec_ext in '' $ac_executable_extensions; do
48877   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
48878     ac_cv_prog_ac_ct_AR="$ac_prog"
48879     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
48880     break 2
48881   fi
48882 done
48883   done
48884 IFS=$as_save_IFS
48885
48886 fi
48887 fi
48888 ac_ct_AR=$ac_cv_prog_ac_ct_AR
48889 if test -n "$ac_ct_AR"; then
48890   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
48891 $as_echo "$ac_ct_AR" >&6; }
48892 else
48893   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
48894 $as_echo "no" >&6; }
48895 fi
48896
48897
48898   test -n "$ac_ct_AR" && break
48899 done
48900
48901   if test "x$ac_ct_AR" = x; then
48902     AR="false"
48903   else
48904     case $cross_compiling:$ac_tool_warned in
48905 yes:)
48906 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
48907 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
48908 ac_tool_warned=yes ;;
48909 esac
48910     AR=$ac_ct_AR
48911   fi
48912 fi
48913
48914 : ${AR=ar}
48915 : ${AR_FLAGS=cru}
48916
48917
48918
48919
48920
48921
48922
48923
48924
48925
48926
48927 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
48928 $as_echo_n "checking for archiver @FILE support... " >&6; }
48929 if ${lt_cv_ar_at_file+:} false; then :
48930   $as_echo_n "(cached) " >&6
48931 else
48932   lt_cv_ar_at_file=no
48933    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
48934 /* end confdefs.h.  */
48935
48936 int
48937 main ()
48938 {
48939
48940   ;
48941   return 0;
48942 }
48943 _ACEOF
48944 if ac_fn_c_try_compile "$LINENO"; then :
48945   echo conftest.$ac_objext > conftest.lst
48946       lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5'
48947       { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
48948   (eval $lt_ar_try) 2>&5
48949   ac_status=$?
48950   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
48951   test $ac_status = 0; }
48952       if test "$ac_status" -eq 0; then
48953         # Ensure the archiver fails upon bogus file names.
48954         rm -f conftest.$ac_objext libconftest.a
48955         { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
48956   (eval $lt_ar_try) 2>&5
48957   ac_status=$?
48958   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
48959   test $ac_status = 0; }
48960         if test "$ac_status" -ne 0; then
48961           lt_cv_ar_at_file=@
48962         fi
48963       fi
48964       rm -f conftest.* libconftest.a
48965
48966 fi
48967 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
48968
48969 fi
48970 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5
48971 $as_echo "$lt_cv_ar_at_file" >&6; }
48972
48973 if test "x$lt_cv_ar_at_file" = xno; then
48974   archiver_list_spec=
48975 else
48976   archiver_list_spec=$lt_cv_ar_at_file
48977 fi
48978
48979
48980
48981
48982
48983
48984
48985 if test -n "$ac_tool_prefix"; then
48986   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
48987 set dummy ${ac_tool_prefix}strip; ac_word=$2
48988 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
48989 $as_echo_n "checking for $ac_word... " >&6; }
48990 if ${ac_cv_prog_STRIP+:} false; then :
48991   $as_echo_n "(cached) " >&6
48992 else
48993   if test -n "$STRIP"; then
48994   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
48995 else
48996 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
48997 for as_dir in $PATH
48998 do
48999   IFS=$as_save_IFS
49000   test -z "$as_dir" && as_dir=.
49001     for ac_exec_ext in '' $ac_executable_extensions; do
49002   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
49003     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
49004     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
49005     break 2
49006   fi
49007 done
49008   done
49009 IFS=$as_save_IFS
49010
49011 fi
49012 fi
49013 STRIP=$ac_cv_prog_STRIP
49014 if test -n "$STRIP"; then
49015   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
49016 $as_echo "$STRIP" >&6; }
49017 else
49018   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
49019 $as_echo "no" >&6; }
49020 fi
49021
49022
49023 fi
49024 if test -z "$ac_cv_prog_STRIP"; then
49025   ac_ct_STRIP=$STRIP
49026   # Extract the first word of "strip", so it can be a program name with args.
49027 set dummy strip; ac_word=$2
49028 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
49029 $as_echo_n "checking for $ac_word... " >&6; }
49030 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
49031   $as_echo_n "(cached) " >&6
49032 else
49033   if test -n "$ac_ct_STRIP"; then
49034   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
49035 else
49036 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
49037 for as_dir in $PATH
49038 do
49039   IFS=$as_save_IFS
49040   test -z "$as_dir" && as_dir=.
49041     for ac_exec_ext in '' $ac_executable_extensions; do
49042   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
49043     ac_cv_prog_ac_ct_STRIP="strip"
49044     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
49045     break 2
49046   fi
49047 done
49048   done
49049 IFS=$as_save_IFS
49050
49051 fi
49052 fi
49053 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
49054 if test -n "$ac_ct_STRIP"; then
49055   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
49056 $as_echo "$ac_ct_STRIP" >&6; }
49057 else
49058   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
49059 $as_echo "no" >&6; }
49060 fi
49061
49062   if test "x$ac_ct_STRIP" = x; then
49063     STRIP=":"
49064   else
49065     case $cross_compiling:$ac_tool_warned in
49066 yes:)
49067 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
49068 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
49069 ac_tool_warned=yes ;;
49070 esac
49071     STRIP=$ac_ct_STRIP
49072   fi
49073 else
49074   STRIP="$ac_cv_prog_STRIP"
49075 fi
49076
49077 test -z "$STRIP" && STRIP=:
49078
49079
49080
49081
49082
49083
49084 if test -n "$ac_tool_prefix"; then
49085   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
49086 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
49087 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
49088 $as_echo_n "checking for $ac_word... " >&6; }
49089 if ${ac_cv_prog_RANLIB+:} false; then :
49090   $as_echo_n "(cached) " >&6
49091 else
49092   if test -n "$RANLIB"; then
49093   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
49094 else
49095 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
49096 for as_dir in $PATH
49097 do
49098   IFS=$as_save_IFS
49099   test -z "$as_dir" && as_dir=.
49100     for ac_exec_ext in '' $ac_executable_extensions; do
49101   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
49102     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
49103     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
49104     break 2
49105   fi
49106 done
49107   done
49108 IFS=$as_save_IFS
49109
49110 fi
49111 fi
49112 RANLIB=$ac_cv_prog_RANLIB
49113 if test -n "$RANLIB"; then
49114   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
49115 $as_echo "$RANLIB" >&6; }
49116 else
49117   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
49118 $as_echo "no" >&6; }
49119 fi
49120
49121
49122 fi
49123 if test -z "$ac_cv_prog_RANLIB"; then
49124   ac_ct_RANLIB=$RANLIB
49125   # Extract the first word of "ranlib", so it can be a program name with args.
49126 set dummy ranlib; ac_word=$2
49127 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
49128 $as_echo_n "checking for $ac_word... " >&6; }
49129 if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
49130   $as_echo_n "(cached) " >&6
49131 else
49132   if test -n "$ac_ct_RANLIB"; then
49133   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
49134 else
49135 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
49136 for as_dir in $PATH
49137 do
49138   IFS=$as_save_IFS
49139   test -z "$as_dir" && as_dir=.
49140     for ac_exec_ext in '' $ac_executable_extensions; do
49141   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
49142     ac_cv_prog_ac_ct_RANLIB="ranlib"
49143     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
49144     break 2
49145   fi
49146 done
49147   done
49148 IFS=$as_save_IFS
49149
49150 fi
49151 fi
49152 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
49153 if test -n "$ac_ct_RANLIB"; then
49154   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
49155 $as_echo "$ac_ct_RANLIB" >&6; }
49156 else
49157   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
49158 $as_echo "no" >&6; }
49159 fi
49160
49161   if test "x$ac_ct_RANLIB" = x; then
49162     RANLIB=":"
49163   else
49164     case $cross_compiling:$ac_tool_warned in
49165 yes:)
49166 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
49167 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
49168 ac_tool_warned=yes ;;
49169 esac
49170     RANLIB=$ac_ct_RANLIB
49171   fi
49172 else
49173   RANLIB="$ac_cv_prog_RANLIB"
49174 fi
49175
49176 test -z "$RANLIB" && RANLIB=:
49177
49178
49179
49180
49181
49182
49183 # Determine commands to create old-style static archives.
49184 old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
49185 old_postinstall_cmds='chmod 644 $oldlib'
49186 old_postuninstall_cmds=
49187
49188 if test -n "$RANLIB"; then
49189   case $host_os in
49190   openbsd*)
49191     old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib"
49192     ;;
49193   *)
49194     old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$tool_oldlib"
49195     ;;
49196   esac
49197   old_archive_cmds="$old_archive_cmds~\$RANLIB \$tool_oldlib"
49198 fi
49199
49200 case $host_os in
49201   darwin*)
49202     lock_old_archive_extraction=yes ;;
49203   *)
49204     lock_old_archive_extraction=no ;;
49205 esac
49206
49207
49208
49209
49210
49211
49212
49213
49214
49215
49216
49217
49218
49219
49220
49221
49222
49223
49224
49225
49226
49227
49228
49229
49230
49231
49232
49233
49234
49235
49236
49237
49238
49239
49240
49241
49242
49243
49244
49245 # If no C compiler was specified, use CC.
49246 LTCC=${LTCC-"$CC"}
49247
49248 # If no C compiler flags were specified, use CFLAGS.
49249 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
49250
49251 # Allow CC to be a program name with arguments.
49252 compiler=$CC
49253
49254
49255 # Check for command to grab the raw symbol name followed by C symbol from nm.
49256 { $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5
49257 $as_echo_n "checking command to parse $NM output from $compiler object... " >&6; }
49258 if ${lt_cv_sys_global_symbol_pipe+:} false; then :
49259   $as_echo_n "(cached) " >&6
49260 else
49261
49262 # These are sane defaults that work on at least a few old systems.
49263 # [They come from Ultrix.  What could be older than Ultrix?!! ;)]
49264
49265 # Character class describing NM global symbol codes.
49266 symcode='[BCDEGRST]'
49267
49268 # Regexp to match symbols that can be accessed directly from C.
49269 sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
49270
49271 # Define system-specific variables.
49272 case $host_os in
49273 aix*)
49274   symcode='[BCDT]'
49275   ;;
49276 cygwin* | mingw* | pw32* | cegcc*)
49277   symcode='[ABCDGISTW]'
49278   ;;
49279 hpux*)
49280   if test "$host_cpu" = ia64; then
49281     symcode='[ABCDEGRST]'
49282   fi
49283   ;;
49284 irix* | nonstopux*)
49285   symcode='[BCDEGRST]'
49286   ;;
49287 osf*)
49288   symcode='[BCDEGQRST]'
49289   ;;
49290 solaris*)
49291   symcode='[BDRT]'
49292   ;;
49293 sco3.2v5*)
49294   symcode='[DT]'
49295   ;;
49296 sysv4.2uw2*)
49297   symcode='[DT]'
49298   ;;
49299 sysv5* | sco5v6* | unixware* | OpenUNIX*)
49300   symcode='[ABDT]'
49301   ;;
49302 sysv4)
49303   symcode='[DFNSTU]'
49304   ;;
49305 esac
49306
49307 # If we're using GNU nm, then use its standard symbol codes.
49308 case `$NM -V 2>&1` in
49309 *GNU* | *'with BFD'*)
49310   symcode='[ABCDGIRSTW]' ;;
49311 esac
49312
49313 # Transform an extracted symbol line into a proper C declaration.
49314 # Some systems (esp. on ia64) link data and code symbols differently,
49315 # so use this general approach.
49316 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
49317
49318 # Transform an extracted symbol line into symbol name and symbol address
49319 lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\)[ ]*$/  {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/  {\"\2\", (void *) \&\2},/p'"
49320 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\)[ ]*$/  {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/  {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/  {\"lib\2\", (void *) \&\2},/p'"
49321
49322 # Handle CRLF in mingw tool chain
49323 opt_cr=
49324 case $build_os in
49325 mingw*)
49326   opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
49327   ;;
49328 esac
49329
49330 # Try without a prefix underscore, then with it.
49331 for ac_symprfx in "" "_"; do
49332
49333   # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
49334   symxfrm="\\1 $ac_symprfx\\2 \\2"
49335
49336   # Write the raw and C identifiers.
49337   if test "$lt_cv_nm_interface" = "MS dumpbin"; then
49338     # Fake it for dumpbin and say T for any non-static function
49339     # and D for any global variable.
49340     # Also find C++ and __fastcall symbols from MSVC++,
49341     # which start with @ or ?.
49342     lt_cv_sys_global_symbol_pipe="$AWK '"\
49343 "     {last_section=section; section=\$ 3};"\
49344 "     /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\
49345 "     /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
49346 "     \$ 0!~/External *\|/{next};"\
49347 "     / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
49348 "     {if(hide[section]) next};"\
49349 "     {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
49350 "     {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
49351 "     s[1]~/^[@?]/{print s[1], s[1]; next};"\
49352 "     s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
49353 "     ' prfx=^$ac_symprfx"
49354   else
49355     lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[      ]\($symcode$symcode*\)[         ][      ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
49356   fi
49357   lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
49358
49359   # Check to see that the pipe works correctly.
49360   pipe_works=no
49361
49362   rm -f conftest*
49363   cat > conftest.$ac_ext <<_LT_EOF
49364 #ifdef __cplusplus
49365 extern "C" {
49366 #endif
49367 char nm_test_var;
49368 void nm_test_func(void);
49369 void nm_test_func(void){}
49370 #ifdef __cplusplus
49371 }
49372 #endif
49373 int main(){nm_test_var='a';nm_test_func();return(0);}
49374 _LT_EOF
49375
49376   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
49377   (eval $ac_compile) 2>&5
49378   ac_status=$?
49379   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
49380   test $ac_status = 0; }; then
49381     # Now try to grab the symbols.
49382     nlist=conftest.nm
49383     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5
49384   (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5
49385   ac_status=$?
49386   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
49387   test $ac_status = 0; } && test -s "$nlist"; then
49388       # Try sorting and uniquifying the output.
49389       if sort "$nlist" | uniq > "$nlist"T; then
49390         mv -f "$nlist"T "$nlist"
49391       else
49392         rm -f "$nlist"T
49393       fi
49394
49395       # Make sure that we snagged all the symbols we need.
49396       if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
49397         if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
49398           cat <<_LT_EOF > conftest.$ac_ext
49399 /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests.  */
49400 #if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE)
49401 /* DATA imports from DLLs on WIN32 con't be const, because runtime
49402    relocations are performed -- see ld's documentation on pseudo-relocs.  */
49403 # define LT_DLSYM_CONST
49404 #elif defined(__osf__)
49405 /* This system does not cope well with relocations in const data.  */
49406 # define LT_DLSYM_CONST
49407 #else
49408 # define LT_DLSYM_CONST const
49409 #endif
49410
49411 #ifdef __cplusplus
49412 extern "C" {
49413 #endif
49414
49415 _LT_EOF
49416           # Now generate the symbol file.
49417           eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
49418
49419           cat <<_LT_EOF >> conftest.$ac_ext
49420
49421 /* The mapping between symbol names and symbols.  */
49422 LT_DLSYM_CONST struct {
49423   const char *name;
49424   void       *address;
49425 }
49426 lt__PROGRAM__LTX_preloaded_symbols[] =
49427 {
49428   { "@PROGRAM@", (void *) 0 },
49429 _LT_EOF
49430           $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/  {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
49431           cat <<\_LT_EOF >> conftest.$ac_ext
49432   {0, (void *) 0}
49433 };
49434
49435 /* This works around a problem in FreeBSD linker */
49436 #ifdef FREEBSD_WORKAROUND
49437 static const void *lt_preloaded_setup() {
49438   return lt__PROGRAM__LTX_preloaded_symbols;
49439 }
49440 #endif
49441
49442 #ifdef __cplusplus
49443 }
49444 #endif
49445 _LT_EOF
49446           # Now try linking the two files.
49447           mv conftest.$ac_objext conftstm.$ac_objext
49448           lt_globsym_save_LIBS=$LIBS
49449           lt_globsym_save_CFLAGS=$CFLAGS
49450           LIBS="conftstm.$ac_objext"
49451           CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
49452           if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
49453   (eval $ac_link) 2>&5
49454   ac_status=$?
49455   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
49456   test $ac_status = 0; } && test -s conftest${ac_exeext}; then
49457             pipe_works=yes
49458           fi
49459           LIBS=$lt_globsym_save_LIBS
49460           CFLAGS=$lt_globsym_save_CFLAGS
49461         else
49462           echo "cannot find nm_test_func in $nlist" >&5
49463         fi
49464       else
49465         echo "cannot find nm_test_var in $nlist" >&5
49466       fi
49467     else
49468       echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
49469     fi
49470   else
49471     echo "$progname: failed program was:" >&5
49472     cat conftest.$ac_ext >&5
49473   fi
49474   rm -rf conftest* conftst*
49475
49476   # Do not use the global_symbol_pipe unless it works.
49477   if test "$pipe_works" = yes; then
49478     break
49479   else
49480     lt_cv_sys_global_symbol_pipe=
49481   fi
49482 done
49483
49484 fi
49485
49486 if test -z "$lt_cv_sys_global_symbol_pipe"; then
49487   lt_cv_sys_global_symbol_to_cdecl=
49488 fi
49489 if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
49490   { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
49491 $as_echo "failed" >&6; }
49492 else
49493   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
49494 $as_echo "ok" >&6; }
49495 fi
49496
49497 # Response file support.
49498 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
49499   nm_file_list_spec='@'
49500 elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then
49501   nm_file_list_spec='@'
49502 fi
49503
49504
49505
49506
49507
49508
49509
49510
49511
49512
49513
49514
49515
49516
49517
49518
49519
49520
49521
49522
49523
49524
49525
49526
49527
49528
49529
49530 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
49531 $as_echo_n "checking for sysroot... " >&6; }
49532
49533 # Check whether --with-sysroot was given.
49534 if test "${with_sysroot+set}" = set; then :
49535   withval=$with_sysroot;
49536 else
49537   with_sysroot=no
49538 fi
49539
49540
49541 lt_sysroot=
49542 case ${with_sysroot} in #(
49543  yes)
49544    if test "$GCC" = yes; then
49545      lt_sysroot=`$CC --print-sysroot 2>/dev/null`
49546    fi
49547    ;; #(
49548  /*)
49549    lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"`
49550    ;; #(
49551  no|'')
49552    ;; #(
49553  *)
49554    { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_sysroot}" >&5
49555 $as_echo "${with_sysroot}" >&6; }
49556    as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5
49557    ;;
49558 esac
49559
49560  { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5
49561 $as_echo "${lt_sysroot:-no}" >&6; }
49562
49563
49564
49565
49566
49567 # Check whether --enable-libtool-lock was given.
49568 if test "${enable_libtool_lock+set}" = set; then :
49569   enableval=$enable_libtool_lock;
49570 fi
49571
49572 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
49573
49574 # Some flags need to be propagated to the compiler or linker for good
49575 # libtool support.
49576 case $host in
49577 ia64-*-hpux*)
49578   # Find out which ABI we are using.
49579   echo 'int i;' > conftest.$ac_ext
49580   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
49581   (eval $ac_compile) 2>&5
49582   ac_status=$?
49583   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
49584   test $ac_status = 0; }; then
49585     case `/usr/bin/file conftest.$ac_objext` in
49586       *ELF-32*)
49587         HPUX_IA64_MODE="32"
49588         ;;
49589       *ELF-64*)
49590         HPUX_IA64_MODE="64"
49591         ;;
49592     esac
49593   fi
49594   rm -rf conftest*
49595   ;;
49596 *-*-irix6*)
49597   # Find out which ABI we are using.
49598   echo '#line '$LINENO' "configure"' > conftest.$ac_ext
49599   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
49600   (eval $ac_compile) 2>&5
49601   ac_status=$?
49602   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
49603   test $ac_status = 0; }; then
49604     if test "$lt_cv_prog_gnu_ld" = yes; then
49605       case `/usr/bin/file conftest.$ac_objext` in
49606         *32-bit*)
49607           LD="${LD-ld} -melf32bsmip"
49608           ;;
49609         *N32*)
49610           LD="${LD-ld} -melf32bmipn32"
49611           ;;
49612         *64-bit*)
49613           LD="${LD-ld} -melf64bmip"
49614         ;;
49615       esac
49616     else
49617       case `/usr/bin/file conftest.$ac_objext` in
49618         *32-bit*)
49619           LD="${LD-ld} -32"
49620           ;;
49621         *N32*)
49622           LD="${LD-ld} -n32"
49623           ;;
49624         *64-bit*)
49625           LD="${LD-ld} -64"
49626           ;;
49627       esac
49628     fi
49629   fi
49630   rm -rf conftest*
49631   ;;
49632
49633 x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \
49634 s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
49635   # Find out which ABI we are using.
49636   echo 'int i;' > conftest.$ac_ext
49637   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
49638   (eval $ac_compile) 2>&5
49639   ac_status=$?
49640   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
49641   test $ac_status = 0; }; then
49642     case `/usr/bin/file conftest.o` in
49643       *32-bit*)
49644         case $host in
49645           x86_64-*kfreebsd*-gnu)
49646             LD="${LD-ld} -m elf_i386_fbsd"
49647             ;;
49648           x86_64-*linux*)
49649             LD="${LD-ld} -m elf_i386"
49650             ;;
49651           powerpc64le-*linux*)
49652             LD="${LD-ld} -m elf32lppclinux"
49653             ;;
49654           powerpc64-*linux*)
49655             LD="${LD-ld} -m elf32ppclinux"
49656             ;;
49657           s390x-*linux*)
49658             LD="${LD-ld} -m elf_s390"
49659             ;;
49660           sparc64-*linux*)
49661             LD="${LD-ld} -m elf32_sparc"
49662             ;;
49663         esac
49664         ;;
49665       *64-bit*)
49666         case $host in
49667           x86_64-*kfreebsd*-gnu)
49668             LD="${LD-ld} -m elf_x86_64_fbsd"
49669             ;;
49670           x86_64-*linux*)
49671             LD="${LD-ld} -m elf_x86_64"
49672             ;;
49673           powerpcle-*linux*)
49674             LD="${LD-ld} -m elf64lppc"
49675             ;;
49676           powerpc-*linux*)
49677             LD="${LD-ld} -m elf64ppc"
49678             ;;
49679           s390*-*linux*|s390*-*tpf*)
49680             LD="${LD-ld} -m elf64_s390"
49681             ;;
49682           sparc*-*linux*)
49683             LD="${LD-ld} -m elf64_sparc"
49684             ;;
49685         esac
49686         ;;
49687     esac
49688   fi
49689   rm -rf conftest*
49690   ;;
49691
49692 *-*-sco3.2v5*)
49693   # On SCO OpenServer 5, we need -belf to get full-featured binaries.
49694   SAVE_CFLAGS="$CFLAGS"
49695   CFLAGS="$CFLAGS -belf"
49696   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5
49697 $as_echo_n "checking whether the C compiler needs -belf... " >&6; }
49698 if ${lt_cv_cc_needs_belf+:} false; then :
49699   $as_echo_n "(cached) " >&6
49700 else
49701   ac_ext=c
49702 ac_cpp='$CPP $CPPFLAGS'
49703 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
49704 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
49705 ac_compiler_gnu=$ac_cv_c_compiler_gnu
49706
49707      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
49708 /* end confdefs.h.  */
49709
49710 int
49711 main ()
49712 {
49713
49714   ;
49715   return 0;
49716 }
49717 _ACEOF
49718 if ac_fn_c_try_link "$LINENO"; then :
49719   lt_cv_cc_needs_belf=yes
49720 else
49721   lt_cv_cc_needs_belf=no
49722 fi
49723 rm -f core conftest.err conftest.$ac_objext \
49724     conftest$ac_exeext conftest.$ac_ext
49725      ac_ext=c
49726 ac_cpp='$CPP $CPPFLAGS'
49727 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
49728 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
49729 ac_compiler_gnu=$ac_cv_c_compiler_gnu
49730
49731 fi
49732 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5
49733 $as_echo "$lt_cv_cc_needs_belf" >&6; }
49734   if test x"$lt_cv_cc_needs_belf" != x"yes"; then
49735     # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
49736     CFLAGS="$SAVE_CFLAGS"
49737   fi
49738   ;;
49739 *-*solaris*)
49740   # Find out which ABI we are using.
49741   echo 'int i;' > conftest.$ac_ext
49742   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
49743   (eval $ac_compile) 2>&5
49744   ac_status=$?
49745   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
49746   test $ac_status = 0; }; then
49747     case `/usr/bin/file conftest.o` in
49748     *64-bit*)
49749       case $lt_cv_prog_gnu_ld in
49750       yes*)
49751         case $host in
49752         i?86-*-solaris*)
49753           LD="${LD-ld} -m elf_x86_64"
49754           ;;
49755         sparc*-*-solaris*)
49756           LD="${LD-ld} -m elf64_sparc"
49757           ;;
49758         esac
49759         # GNU ld 2.21 introduced _sol2 emulations.  Use them if available.
49760         if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then
49761           LD="${LD-ld}_sol2"
49762         fi
49763         ;;
49764       *)
49765         if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
49766           LD="${LD-ld} -64"
49767         fi
49768         ;;
49769       esac
49770       ;;
49771     esac
49772   fi
49773   rm -rf conftest*
49774   ;;
49775 esac
49776
49777 need_locks="$enable_libtool_lock"
49778
49779 if test -n "$ac_tool_prefix"; then
49780   # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args.
49781 set dummy ${ac_tool_prefix}mt; ac_word=$2
49782 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
49783 $as_echo_n "checking for $ac_word... " >&6; }
49784 if ${ac_cv_prog_MANIFEST_TOOL+:} false; then :
49785   $as_echo_n "(cached) " >&6
49786 else
49787   if test -n "$MANIFEST_TOOL"; then
49788   ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test.
49789 else
49790 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
49791 for as_dir in $PATH
49792 do
49793   IFS=$as_save_IFS
49794   test -z "$as_dir" && as_dir=.
49795     for ac_exec_ext in '' $ac_executable_extensions; do
49796   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
49797     ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt"
49798     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
49799     break 2
49800   fi
49801 done
49802   done
49803 IFS=$as_save_IFS
49804
49805 fi
49806 fi
49807 MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL
49808 if test -n "$MANIFEST_TOOL"; then
49809   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5
49810 $as_echo "$MANIFEST_TOOL" >&6; }
49811 else
49812   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
49813 $as_echo "no" >&6; }
49814 fi
49815
49816
49817 fi
49818 if test -z "$ac_cv_prog_MANIFEST_TOOL"; then
49819   ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL
49820   # Extract the first word of "mt", so it can be a program name with args.
49821 set dummy mt; ac_word=$2
49822 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
49823 $as_echo_n "checking for $ac_word... " >&6; }
49824 if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then :
49825   $as_echo_n "(cached) " >&6
49826 else
49827   if test -n "$ac_ct_MANIFEST_TOOL"; then
49828   ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test.
49829 else
49830 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
49831 for as_dir in $PATH
49832 do
49833   IFS=$as_save_IFS
49834   test -z "$as_dir" && as_dir=.
49835     for ac_exec_ext in '' $ac_executable_extensions; do
49836   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
49837     ac_cv_prog_ac_ct_MANIFEST_TOOL="mt"
49838     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
49839     break 2
49840   fi
49841 done
49842   done
49843 IFS=$as_save_IFS
49844
49845 fi
49846 fi
49847 ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL
49848 if test -n "$ac_ct_MANIFEST_TOOL"; then
49849   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5
49850 $as_echo "$ac_ct_MANIFEST_TOOL" >&6; }
49851 else
49852   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
49853 $as_echo "no" >&6; }
49854 fi
49855
49856   if test "x$ac_ct_MANIFEST_TOOL" = x; then
49857     MANIFEST_TOOL=":"
49858   else
49859     case $cross_compiling:$ac_tool_warned in
49860 yes:)
49861 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
49862 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
49863 ac_tool_warned=yes ;;
49864 esac
49865     MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL
49866   fi
49867 else
49868   MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL"
49869 fi
49870
49871 test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
49872 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5
49873 $as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; }
49874 if ${lt_cv_path_mainfest_tool+:} false; then :
49875   $as_echo_n "(cached) " >&6
49876 else
49877   lt_cv_path_mainfest_tool=no
49878   echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5
49879   $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
49880   cat conftest.err >&5
49881   if $GREP 'Manifest Tool' conftest.out > /dev/null; then
49882     lt_cv_path_mainfest_tool=yes
49883   fi
49884   rm -f conftest*
49885 fi
49886 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5
49887 $as_echo "$lt_cv_path_mainfest_tool" >&6; }
49888 if test "x$lt_cv_path_mainfest_tool" != xyes; then
49889   MANIFEST_TOOL=:
49890 fi
49891
49892
49893
49894
49895
49896
49897   case $host_os in
49898     rhapsody* | darwin*)
49899     if test -n "$ac_tool_prefix"; then
49900   # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args.
49901 set dummy ${ac_tool_prefix}dsymutil; ac_word=$2
49902 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
49903 $as_echo_n "checking for $ac_word... " >&6; }
49904 if ${ac_cv_prog_DSYMUTIL+:} false; then :
49905   $as_echo_n "(cached) " >&6
49906 else
49907   if test -n "$DSYMUTIL"; then
49908   ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
49909 else
49910 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
49911 for as_dir in $PATH
49912 do
49913   IFS=$as_save_IFS
49914   test -z "$as_dir" && as_dir=.
49915     for ac_exec_ext in '' $ac_executable_extensions; do
49916   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
49917     ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil"
49918     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
49919     break 2
49920   fi
49921 done
49922   done
49923 IFS=$as_save_IFS
49924
49925 fi
49926 fi
49927 DSYMUTIL=$ac_cv_prog_DSYMUTIL
49928 if test -n "$DSYMUTIL"; then
49929   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
49930 $as_echo "$DSYMUTIL" >&6; }
49931 else
49932   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
49933 $as_echo "no" >&6; }
49934 fi
49935
49936
49937 fi
49938 if test -z "$ac_cv_prog_DSYMUTIL"; then
49939   ac_ct_DSYMUTIL=$DSYMUTIL
49940   # Extract the first word of "dsymutil", so it can be a program name with args.
49941 set dummy dsymutil; ac_word=$2
49942 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
49943 $as_echo_n "checking for $ac_word... " >&6; }
49944 if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then :
49945   $as_echo_n "(cached) " >&6
49946 else
49947   if test -n "$ac_ct_DSYMUTIL"; then
49948   ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test.
49949 else
49950 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
49951 for as_dir in $PATH
49952 do
49953   IFS=$as_save_IFS
49954   test -z "$as_dir" && as_dir=.
49955     for ac_exec_ext in '' $ac_executable_extensions; do
49956   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
49957     ac_cv_prog_ac_ct_DSYMUTIL="dsymutil"
49958     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
49959     break 2
49960   fi
49961 done
49962   done
49963 IFS=$as_save_IFS
49964
49965 fi
49966 fi
49967 ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL
49968 if test -n "$ac_ct_DSYMUTIL"; then
49969   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5
49970 $as_echo "$ac_ct_DSYMUTIL" >&6; }
49971 else
49972   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
49973 $as_echo "no" >&6; }
49974 fi
49975
49976   if test "x$ac_ct_DSYMUTIL" = x; then
49977     DSYMUTIL=":"
49978   else
49979     case $cross_compiling:$ac_tool_warned in
49980 yes:)
49981 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
49982 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
49983 ac_tool_warned=yes ;;
49984 esac
49985     DSYMUTIL=$ac_ct_DSYMUTIL
49986   fi
49987 else
49988   DSYMUTIL="$ac_cv_prog_DSYMUTIL"
49989 fi
49990
49991     if test -n "$ac_tool_prefix"; then
49992   # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args.
49993 set dummy ${ac_tool_prefix}nmedit; ac_word=$2
49994 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
49995 $as_echo_n "checking for $ac_word... " >&6; }
49996 if ${ac_cv_prog_NMEDIT+:} false; then :
49997   $as_echo_n "(cached) " >&6
49998 else
49999   if test -n "$NMEDIT"; then
50000   ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test.
50001 else
50002 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
50003 for as_dir in $PATH
50004 do
50005   IFS=$as_save_IFS
50006   test -z "$as_dir" && as_dir=.
50007     for ac_exec_ext in '' $ac_executable_extensions; do
50008   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
50009     ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit"
50010     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
50011     break 2
50012   fi
50013 done
50014   done
50015 IFS=$as_save_IFS
50016
50017 fi
50018 fi
50019 NMEDIT=$ac_cv_prog_NMEDIT
50020 if test -n "$NMEDIT"; then
50021   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5
50022 $as_echo "$NMEDIT" >&6; }
50023 else
50024   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
50025 $as_echo "no" >&6; }
50026 fi
50027
50028
50029 fi
50030 if test -z "$ac_cv_prog_NMEDIT"; then
50031   ac_ct_NMEDIT=$NMEDIT
50032   # Extract the first word of "nmedit", so it can be a program name with args.
50033 set dummy nmedit; ac_word=$2
50034 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
50035 $as_echo_n "checking for $ac_word... " >&6; }
50036 if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then :
50037   $as_echo_n "(cached) " >&6
50038 else
50039   if test -n "$ac_ct_NMEDIT"; then
50040   ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test.
50041 else
50042 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
50043 for as_dir in $PATH
50044 do
50045   IFS=$as_save_IFS
50046   test -z "$as_dir" && as_dir=.
50047     for ac_exec_ext in '' $ac_executable_extensions; do
50048   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
50049     ac_cv_prog_ac_ct_NMEDIT="nmedit"
50050     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
50051     break 2
50052   fi
50053 done
50054   done
50055 IFS=$as_save_IFS
50056
50057 fi
50058 fi
50059 ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT
50060 if test -n "$ac_ct_NMEDIT"; then
50061   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5
50062 $as_echo "$ac_ct_NMEDIT" >&6; }
50063 else
50064   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
50065 $as_echo "no" >&6; }
50066 fi
50067
50068   if test "x$ac_ct_NMEDIT" = x; then
50069     NMEDIT=":"
50070   else
50071     case $cross_compiling:$ac_tool_warned in
50072 yes:)
50073 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
50074 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
50075 ac_tool_warned=yes ;;
50076 esac
50077     NMEDIT=$ac_ct_NMEDIT
50078   fi
50079 else
50080   NMEDIT="$ac_cv_prog_NMEDIT"
50081 fi
50082
50083     if test -n "$ac_tool_prefix"; then
50084   # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args.
50085 set dummy ${ac_tool_prefix}lipo; ac_word=$2
50086 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
50087 $as_echo_n "checking for $ac_word... " >&6; }
50088 if ${ac_cv_prog_LIPO+:} false; then :
50089   $as_echo_n "(cached) " >&6
50090 else
50091   if test -n "$LIPO"; then
50092   ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
50093 else
50094 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
50095 for as_dir in $PATH
50096 do
50097   IFS=$as_save_IFS
50098   test -z "$as_dir" && as_dir=.
50099     for ac_exec_ext in '' $ac_executable_extensions; do
50100   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
50101     ac_cv_prog_LIPO="${ac_tool_prefix}lipo"
50102     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
50103     break 2
50104   fi
50105 done
50106   done
50107 IFS=$as_save_IFS
50108
50109 fi
50110 fi
50111 LIPO=$ac_cv_prog_LIPO
50112 if test -n "$LIPO"; then
50113   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
50114 $as_echo "$LIPO" >&6; }
50115 else
50116   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
50117 $as_echo "no" >&6; }
50118 fi
50119
50120
50121 fi
50122 if test -z "$ac_cv_prog_LIPO"; then
50123   ac_ct_LIPO=$LIPO
50124   # Extract the first word of "lipo", so it can be a program name with args.
50125 set dummy lipo; ac_word=$2
50126 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
50127 $as_echo_n "checking for $ac_word... " >&6; }
50128 if ${ac_cv_prog_ac_ct_LIPO+:} false; then :
50129   $as_echo_n "(cached) " >&6
50130 else
50131   if test -n "$ac_ct_LIPO"; then
50132   ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test.
50133 else
50134 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
50135 for as_dir in $PATH
50136 do
50137   IFS=$as_save_IFS
50138   test -z "$as_dir" && as_dir=.
50139     for ac_exec_ext in '' $ac_executable_extensions; do
50140   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
50141     ac_cv_prog_ac_ct_LIPO="lipo"
50142     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
50143     break 2
50144   fi
50145 done
50146   done
50147 IFS=$as_save_IFS
50148
50149 fi
50150 fi
50151 ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO
50152 if test -n "$ac_ct_LIPO"; then
50153   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5
50154 $as_echo "$ac_ct_LIPO" >&6; }
50155 else
50156   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
50157 $as_echo "no" >&6; }
50158 fi
50159
50160   if test "x$ac_ct_LIPO" = x; then
50161     LIPO=":"
50162   else
50163     case $cross_compiling:$ac_tool_warned in
50164 yes:)
50165 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
50166 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
50167 ac_tool_warned=yes ;;
50168 esac
50169     LIPO=$ac_ct_LIPO
50170   fi
50171 else
50172   LIPO="$ac_cv_prog_LIPO"
50173 fi
50174
50175     if test -n "$ac_tool_prefix"; then
50176   # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args.
50177 set dummy ${ac_tool_prefix}otool; ac_word=$2
50178 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
50179 $as_echo_n "checking for $ac_word... " >&6; }
50180 if ${ac_cv_prog_OTOOL+:} false; then :
50181   $as_echo_n "(cached) " >&6
50182 else
50183   if test -n "$OTOOL"; then
50184   ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
50185 else
50186 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
50187 for as_dir in $PATH
50188 do
50189   IFS=$as_save_IFS
50190   test -z "$as_dir" && as_dir=.
50191     for ac_exec_ext in '' $ac_executable_extensions; do
50192   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
50193     ac_cv_prog_OTOOL="${ac_tool_prefix}otool"
50194     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
50195     break 2
50196   fi
50197 done
50198   done
50199 IFS=$as_save_IFS
50200
50201 fi
50202 fi
50203 OTOOL=$ac_cv_prog_OTOOL
50204 if test -n "$OTOOL"; then
50205   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
50206 $as_echo "$OTOOL" >&6; }
50207 else
50208   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
50209 $as_echo "no" >&6; }
50210 fi
50211
50212
50213 fi
50214 if test -z "$ac_cv_prog_OTOOL"; then
50215   ac_ct_OTOOL=$OTOOL
50216   # Extract the first word of "otool", so it can be a program name with args.
50217 set dummy otool; ac_word=$2
50218 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
50219 $as_echo_n "checking for $ac_word... " >&6; }
50220 if ${ac_cv_prog_ac_ct_OTOOL+:} false; then :
50221   $as_echo_n "(cached) " >&6
50222 else
50223   if test -n "$ac_ct_OTOOL"; then
50224   ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test.
50225 else
50226 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
50227 for as_dir in $PATH
50228 do
50229   IFS=$as_save_IFS
50230   test -z "$as_dir" && as_dir=.
50231     for ac_exec_ext in '' $ac_executable_extensions; do
50232   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
50233     ac_cv_prog_ac_ct_OTOOL="otool"
50234     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
50235     break 2
50236   fi
50237 done
50238   done
50239 IFS=$as_save_IFS
50240
50241 fi
50242 fi
50243 ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL
50244 if test -n "$ac_ct_OTOOL"; then
50245   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5
50246 $as_echo "$ac_ct_OTOOL" >&6; }
50247 else
50248   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
50249 $as_echo "no" >&6; }
50250 fi
50251
50252   if test "x$ac_ct_OTOOL" = x; then
50253     OTOOL=":"
50254   else
50255     case $cross_compiling:$ac_tool_warned in
50256 yes:)
50257 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
50258 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
50259 ac_tool_warned=yes ;;
50260 esac
50261     OTOOL=$ac_ct_OTOOL
50262   fi
50263 else
50264   OTOOL="$ac_cv_prog_OTOOL"
50265 fi
50266
50267     if test -n "$ac_tool_prefix"; then
50268   # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args.
50269 set dummy ${ac_tool_prefix}otool64; ac_word=$2
50270 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
50271 $as_echo_n "checking for $ac_word... " >&6; }
50272 if ${ac_cv_prog_OTOOL64+:} false; then :
50273   $as_echo_n "(cached) " >&6
50274 else
50275   if test -n "$OTOOL64"; then
50276   ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test.
50277 else
50278 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
50279 for as_dir in $PATH
50280 do
50281   IFS=$as_save_IFS
50282   test -z "$as_dir" && as_dir=.
50283     for ac_exec_ext in '' $ac_executable_extensions; do
50284   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
50285     ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64"
50286     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
50287     break 2
50288   fi
50289 done
50290   done
50291 IFS=$as_save_IFS
50292
50293 fi
50294 fi
50295 OTOOL64=$ac_cv_prog_OTOOL64
50296 if test -n "$OTOOL64"; then
50297   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5
50298 $as_echo "$OTOOL64" >&6; }
50299 else
50300   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
50301 $as_echo "no" >&6; }
50302 fi
50303
50304
50305 fi
50306 if test -z "$ac_cv_prog_OTOOL64"; then
50307   ac_ct_OTOOL64=$OTOOL64
50308   # Extract the first word of "otool64", so it can be a program name with args.
50309 set dummy otool64; ac_word=$2
50310 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
50311 $as_echo_n "checking for $ac_word... " >&6; }
50312 if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then :
50313   $as_echo_n "(cached) " >&6
50314 else
50315   if test -n "$ac_ct_OTOOL64"; then
50316   ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test.
50317 else
50318 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
50319 for as_dir in $PATH
50320 do
50321   IFS=$as_save_IFS
50322   test -z "$as_dir" && as_dir=.
50323     for ac_exec_ext in '' $ac_executable_extensions; do
50324   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
50325     ac_cv_prog_ac_ct_OTOOL64="otool64"
50326     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
50327     break 2
50328   fi
50329 done
50330   done
50331 IFS=$as_save_IFS
50332
50333 fi
50334 fi
50335 ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64
50336 if test -n "$ac_ct_OTOOL64"; then
50337   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5
50338 $as_echo "$ac_ct_OTOOL64" >&6; }
50339 else
50340   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
50341 $as_echo "no" >&6; }
50342 fi
50343
50344   if test "x$ac_ct_OTOOL64" = x; then
50345     OTOOL64=":"
50346   else
50347     case $cross_compiling:$ac_tool_warned in
50348 yes:)
50349 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
50350 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
50351 ac_tool_warned=yes ;;
50352 esac
50353     OTOOL64=$ac_ct_OTOOL64
50354   fi
50355 else
50356   OTOOL64="$ac_cv_prog_OTOOL64"
50357 fi
50358
50359
50360
50361
50362
50363
50364
50365
50366
50367
50368
50369
50370
50371
50372
50373
50374
50375
50376
50377
50378
50379
50380
50381
50382
50383
50384
50385     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5
50386 $as_echo_n "checking for -single_module linker flag... " >&6; }
50387 if ${lt_cv_apple_cc_single_mod+:} false; then :
50388   $as_echo_n "(cached) " >&6
50389 else
50390   lt_cv_apple_cc_single_mod=no
50391       if test -z "${LT_MULTI_MODULE}"; then
50392         # By default we will add the -single_module flag. You can override
50393         # by either setting the environment variable LT_MULTI_MODULE
50394         # non-empty at configure time, or by adding -multi_module to the
50395         # link flags.
50396         rm -rf libconftest.dylib*
50397         echo "int foo(void){return 1;}" > conftest.c
50398         echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
50399 -dynamiclib -Wl,-single_module conftest.c" >&5
50400         $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
50401           -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
50402         _lt_result=$?
50403         # If there is a non-empty error log, and "single_module"
50404         # appears in it, assume the flag caused a linker warning
50405         if test -s conftest.err && $GREP single_module conftest.err; then
50406           cat conftest.err >&5
50407         # Otherwise, if the output was created with a 0 exit code from
50408         # the compiler, it worked.
50409         elif test -f libconftest.dylib && test $_lt_result -eq 0; then
50410           lt_cv_apple_cc_single_mod=yes
50411         else
50412           cat conftest.err >&5
50413         fi
50414         rm -rf libconftest.dylib*
50415         rm -f conftest.*
50416       fi
50417 fi
50418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5
50419 $as_echo "$lt_cv_apple_cc_single_mod" >&6; }
50420
50421     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5
50422 $as_echo_n "checking for -exported_symbols_list linker flag... " >&6; }
50423 if ${lt_cv_ld_exported_symbols_list+:} false; then :
50424   $as_echo_n "(cached) " >&6
50425 else
50426   lt_cv_ld_exported_symbols_list=no
50427       save_LDFLAGS=$LDFLAGS
50428       echo "_main" > conftest.sym
50429       LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
50430       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
50431 /* end confdefs.h.  */
50432
50433 int
50434 main ()
50435 {
50436
50437   ;
50438   return 0;
50439 }
50440 _ACEOF
50441 if ac_fn_c_try_link "$LINENO"; then :
50442   lt_cv_ld_exported_symbols_list=yes
50443 else
50444   lt_cv_ld_exported_symbols_list=no
50445 fi
50446 rm -f core conftest.err conftest.$ac_objext \
50447     conftest$ac_exeext conftest.$ac_ext
50448         LDFLAGS="$save_LDFLAGS"
50449
50450 fi
50451 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5
50452 $as_echo "$lt_cv_ld_exported_symbols_list" >&6; }
50453
50454     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5
50455 $as_echo_n "checking for -force_load linker flag... " >&6; }
50456 if ${lt_cv_ld_force_load+:} false; then :
50457   $as_echo_n "(cached) " >&6
50458 else
50459   lt_cv_ld_force_load=no
50460       cat > conftest.c << _LT_EOF
50461 int forced_loaded() { return 2;}
50462 _LT_EOF
50463       echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5
50464       $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
50465       echo "$AR cru libconftest.a conftest.o" >&5
50466       $AR cru libconftest.a conftest.o 2>&5
50467       echo "$RANLIB libconftest.a" >&5
50468       $RANLIB libconftest.a 2>&5
50469       cat > conftest.c << _LT_EOF
50470 int main() { return 0;}
50471 _LT_EOF
50472       echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5
50473       $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
50474       _lt_result=$?
50475       if test -s conftest.err && $GREP force_load conftest.err; then
50476         cat conftest.err >&5
50477       elif test -f conftest && test $_lt_result -eq 0 && $GREP forced_load conftest >/dev/null 2>&1 ; then
50478         lt_cv_ld_force_load=yes
50479       else
50480         cat conftest.err >&5
50481       fi
50482         rm -f conftest.err libconftest.a conftest conftest.c
50483         rm -rf conftest.dSYM
50484
50485 fi
50486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5
50487 $as_echo "$lt_cv_ld_force_load" >&6; }
50488     case $host_os in
50489     rhapsody* | darwin1.[012])
50490       _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
50491     darwin1.*)
50492       _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
50493     darwin*) # darwin 5.x on
50494       # if running on 10.5 or later, the deployment target defaults
50495       # to the OS version, if on x86, and 10.4, the deployment
50496       # target defaults to 10.4. Don't you love it?
50497       case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
50498         10.0,*86*-darwin8*|10.0,*-darwin[91]*)
50499           _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
50500         10.[012]*)
50501           _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
50502         10.*)
50503           _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
50504       esac
50505     ;;
50506   esac
50507     if test "$lt_cv_apple_cc_single_mod" = "yes"; then
50508       _lt_dar_single_mod='$single_module'
50509     fi
50510     if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
50511       _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
50512     else
50513       _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
50514     fi
50515     if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then
50516       _lt_dsymutil='~$DSYMUTIL $lib || :'
50517     else
50518       _lt_dsymutil=
50519     fi
50520     ;;
50521   esac
50522
50523 for ac_header in dlfcn.h
50524 do :
50525   ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
50526 "
50527 if test "x$ac_cv_header_dlfcn_h" = xyes; then :
50528   cat >>confdefs.h <<_ACEOF
50529 #define HAVE_DLFCN_H 1
50530 _ACEOF
50531
50532 fi
50533
50534 done
50535
50536
50537
50538
50539
50540 # Set options
50541 # Check whether --enable-shared was given.
50542 if test "${enable_shared+set}" = set; then :
50543   enableval=$enable_shared; p=${PACKAGE-default}
50544     case $enableval in
50545     yes) enable_shared=yes ;;
50546     no) enable_shared=no ;;
50547     *)
50548       enable_shared=no
50549       # Look at the argument we got.  We use all the common list separators.
50550       lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
50551       for pkg in $enableval; do
50552         IFS="$lt_save_ifs"
50553         if test "X$pkg" = "X$p"; then
50554           enable_shared=yes
50555         fi
50556       done
50557       IFS="$lt_save_ifs"
50558       ;;
50559     esac
50560 else
50561   enable_shared=yes
50562 fi
50563
50564
50565
50566
50567
50568
50569
50570 # Check whether --enable-static was given.
50571 if test "${enable_static+set}" = set; then :
50572   enableval=$enable_static; p=${PACKAGE-default}
50573     case $enableval in
50574     yes) enable_static=yes ;;
50575     no) enable_static=no ;;
50576     *)
50577      enable_static=no
50578       # Look at the argument we got.  We use all the common list separators.
50579       lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
50580       for pkg in $enableval; do
50581         IFS="$lt_save_ifs"
50582         if test "X$pkg" = "X$p"; then
50583           enable_static=yes
50584         fi
50585       done
50586       IFS="$lt_save_ifs"
50587       ;;
50588     esac
50589 else
50590   enable_static=no
50591 fi
50592
50593
50594
50595
50596
50597
50598
50599
50600
50601
50602         enable_dlopen=no
50603
50604
50605
50606
50607
50608
50609 # Check whether --with-pic was given.
50610 if test "${with_pic+set}" = set; then :
50611   withval=$with_pic; lt_p=${PACKAGE-default}
50612     case $withval in
50613     yes|no) pic_mode=$withval ;;
50614     *)
50615       pic_mode=default
50616       # Look at the argument we got.  We use all the common list separators.
50617       lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
50618       for lt_pkg in $withval; do
50619         IFS="$lt_save_ifs"
50620         if test "X$lt_pkg" = "X$lt_p"; then
50621           pic_mode=yes
50622         fi
50623       done
50624       IFS="$lt_save_ifs"
50625       ;;
50626     esac
50627 else
50628   pic_mode=default
50629 fi
50630
50631
50632 test -z "$pic_mode" && pic_mode=default
50633
50634
50635
50636
50637
50638
50639
50640   # Check whether --enable-fast-install was given.
50641 if test "${enable_fast_install+set}" = set; then :
50642   enableval=$enable_fast_install; p=${PACKAGE-default}
50643     case $enableval in
50644     yes) enable_fast_install=yes ;;
50645     no) enable_fast_install=no ;;
50646     *)
50647       enable_fast_install=no
50648       # Look at the argument we got.  We use all the common list separators.
50649       lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
50650       for pkg in $enableval; do
50651         IFS="$lt_save_ifs"
50652         if test "X$pkg" = "X$p"; then
50653           enable_fast_install=yes
50654         fi
50655       done
50656       IFS="$lt_save_ifs"
50657       ;;
50658     esac
50659 else
50660   enable_fast_install=yes
50661 fi
50662
50663
50664
50665
50666
50667
50668
50669
50670
50671
50672
50673 # This can be used to rebuild libtool when needed
50674 LIBTOOL_DEPS="$ltmain"
50675
50676 # Always use our own libtool.
50677 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
50678
50679
50680
50681
50682
50683
50684
50685
50686
50687
50688
50689
50690
50691
50692
50693
50694
50695
50696
50697
50698
50699
50700
50701
50702
50703
50704
50705
50706
50707
50708 test -z "$LN_S" && LN_S="ln -s"
50709
50710
50711
50712
50713
50714
50715
50716
50717
50718
50719
50720
50721
50722
50723 if test -n "${ZSH_VERSION+set}" ; then
50724    setopt NO_GLOB_SUBST
50725 fi
50726
50727 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5
50728 $as_echo_n "checking for objdir... " >&6; }
50729 if ${lt_cv_objdir+:} false; then :
50730   $as_echo_n "(cached) " >&6
50731 else
50732   rm -f .libs 2>/dev/null
50733 mkdir .libs 2>/dev/null
50734 if test -d .libs; then
50735   lt_cv_objdir=.libs
50736 else
50737   # MS-DOS does not allow filenames that begin with a dot.
50738   lt_cv_objdir=_libs
50739 fi
50740 rmdir .libs 2>/dev/null
50741 fi
50742 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5
50743 $as_echo "$lt_cv_objdir" >&6; }
50744 objdir=$lt_cv_objdir
50745
50746
50747
50748
50749
50750 cat >>confdefs.h <<_ACEOF
50751 #define LT_OBJDIR "$lt_cv_objdir/"
50752 _ACEOF
50753
50754
50755
50756
50757 case $host_os in
50758 aix3*)
50759   # AIX sometimes has problems with the GCC collect2 program.  For some
50760   # reason, if we set the COLLECT_NAMES environment variable, the problems
50761   # vanish in a puff of smoke.
50762   if test "X${COLLECT_NAMES+set}" != Xset; then
50763     COLLECT_NAMES=
50764     export COLLECT_NAMES
50765   fi
50766   ;;
50767 esac
50768
50769 # Global variables:
50770 ofile=libtool
50771 can_build_shared=yes
50772
50773 # All known linkers require a `.a' archive for static linking (except MSVC,
50774 # which needs '.lib').
50775 libext=a
50776
50777 with_gnu_ld="$lt_cv_prog_gnu_ld"
50778
50779 old_CC="$CC"
50780 old_CFLAGS="$CFLAGS"
50781
50782 # Set sane defaults for various variables
50783 test -z "$CC" && CC=cc
50784 test -z "$LTCC" && LTCC=$CC
50785 test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
50786 test -z "$LD" && LD=ld
50787 test -z "$ac_objext" && ac_objext=o
50788
50789 for cc_temp in $compiler""; do
50790   case $cc_temp in
50791     compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
50792     distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
50793     \-*) ;;
50794     *) break;;
50795   esac
50796 done
50797 cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
50798
50799
50800 # Only perform the check for file, if the check method requires it
50801 test -z "$MAGIC_CMD" && MAGIC_CMD=file
50802 case $deplibs_check_method in
50803 file_magic*)
50804   if test "$file_magic_cmd" = '$MAGIC_CMD'; then
50805     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5
50806 $as_echo_n "checking for ${ac_tool_prefix}file... " >&6; }
50807 if ${lt_cv_path_MAGIC_CMD+:} false; then :
50808   $as_echo_n "(cached) " >&6
50809 else
50810   case $MAGIC_CMD in
50811 [\\/*] |  ?:[\\/]*)
50812   lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
50813   ;;
50814 *)
50815   lt_save_MAGIC_CMD="$MAGIC_CMD"
50816   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
50817   ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
50818   for ac_dir in $ac_dummy; do
50819     IFS="$lt_save_ifs"
50820     test -z "$ac_dir" && ac_dir=.
50821     if test -f $ac_dir/${ac_tool_prefix}file; then
50822       lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file"
50823       if test -n "$file_magic_test_file"; then
50824         case $deplibs_check_method in
50825         "file_magic "*)
50826           file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
50827           MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
50828           if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
50829             $EGREP "$file_magic_regex" > /dev/null; then
50830             :
50831           else
50832             cat <<_LT_EOF 1>&2
50833
50834 *** Warning: the command libtool uses to detect shared libraries,
50835 *** $file_magic_cmd, produces output that libtool cannot recognize.
50836 *** The result is that libtool may fail to recognize shared libraries
50837 *** as such.  This will affect the creation of libtool libraries that
50838 *** depend on shared libraries, but programs linked with such libtool
50839 *** libraries will work regardless of this problem.  Nevertheless, you
50840 *** may want to report the problem to your system manager and/or to
50841 *** bug-libtool@gnu.org
50842
50843 _LT_EOF
50844           fi ;;
50845         esac
50846       fi
50847       break
50848     fi
50849   done
50850   IFS="$lt_save_ifs"
50851   MAGIC_CMD="$lt_save_MAGIC_CMD"
50852   ;;
50853 esac
50854 fi
50855
50856 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
50857 if test -n "$MAGIC_CMD"; then
50858   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
50859 $as_echo "$MAGIC_CMD" >&6; }
50860 else
50861   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
50862 $as_echo "no" >&6; }
50863 fi
50864
50865
50866
50867
50868
50869 if test -z "$lt_cv_path_MAGIC_CMD"; then
50870   if test -n "$ac_tool_prefix"; then
50871     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5
50872 $as_echo_n "checking for file... " >&6; }
50873 if ${lt_cv_path_MAGIC_CMD+:} false; then :
50874   $as_echo_n "(cached) " >&6
50875 else
50876   case $MAGIC_CMD in
50877 [\\/*] |  ?:[\\/]*)
50878   lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
50879   ;;
50880 *)
50881   lt_save_MAGIC_CMD="$MAGIC_CMD"
50882   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
50883   ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
50884   for ac_dir in $ac_dummy; do
50885     IFS="$lt_save_ifs"
50886     test -z "$ac_dir" && ac_dir=.
50887     if test -f $ac_dir/file; then
50888       lt_cv_path_MAGIC_CMD="$ac_dir/file"
50889       if test -n "$file_magic_test_file"; then
50890         case $deplibs_check_method in
50891         "file_magic "*)
50892           file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
50893           MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
50894           if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
50895             $EGREP "$file_magic_regex" > /dev/null; then
50896             :
50897           else
50898             cat <<_LT_EOF 1>&2
50899
50900 *** Warning: the command libtool uses to detect shared libraries,
50901 *** $file_magic_cmd, produces output that libtool cannot recognize.
50902 *** The result is that libtool may fail to recognize shared libraries
50903 *** as such.  This will affect the creation of libtool libraries that
50904 *** depend on shared libraries, but programs linked with such libtool
50905 *** libraries will work regardless of this problem.  Nevertheless, you
50906 *** may want to report the problem to your system manager and/or to
50907 *** bug-libtool@gnu.org
50908
50909 _LT_EOF
50910           fi ;;
50911         esac
50912       fi
50913       break
50914     fi
50915   done
50916   IFS="$lt_save_ifs"
50917   MAGIC_CMD="$lt_save_MAGIC_CMD"
50918   ;;
50919 esac
50920 fi
50921
50922 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
50923 if test -n "$MAGIC_CMD"; then
50924   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
50925 $as_echo "$MAGIC_CMD" >&6; }
50926 else
50927   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
50928 $as_echo "no" >&6; }
50929 fi
50930
50931
50932   else
50933     MAGIC_CMD=:
50934   fi
50935 fi
50936
50937   fi
50938   ;;
50939 esac
50940
50941 # Use C for the default configuration in the libtool script
50942
50943 lt_save_CC="$CC"
50944 ac_ext=c
50945 ac_cpp='$CPP $CPPFLAGS'
50946 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
50947 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
50948 ac_compiler_gnu=$ac_cv_c_compiler_gnu
50949
50950
50951 # Source file extension for C test sources.
50952 ac_ext=c
50953
50954 # Object file extension for compiled C test sources.
50955 objext=o
50956 objext=$objext
50957
50958 # Code to be used in simple compile tests
50959 lt_simple_compile_test_code="int some_variable = 0;"
50960
50961 # Code to be used in simple link tests
50962 lt_simple_link_test_code='int main(){return(0);}'
50963
50964
50965
50966
50967
50968
50969
50970 # If no C compiler was specified, use CC.
50971 LTCC=${LTCC-"$CC"}
50972
50973 # If no C compiler flags were specified, use CFLAGS.
50974 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
50975
50976 # Allow CC to be a program name with arguments.
50977 compiler=$CC
50978
50979 # Save the default compiler, since it gets overwritten when the other
50980 # tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
50981 compiler_DEFAULT=$CC
50982
50983 # save warnings/boilerplate of simple test code
50984 ac_outfile=conftest.$ac_objext
50985 echo "$lt_simple_compile_test_code" >conftest.$ac_ext
50986 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
50987 _lt_compiler_boilerplate=`cat conftest.err`
50988 $RM conftest*
50989
50990 ac_outfile=conftest.$ac_objext
50991 echo "$lt_simple_link_test_code" >conftest.$ac_ext
50992 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
50993 _lt_linker_boilerplate=`cat conftest.err`
50994 $RM -r conftest*
50995
50996
50997 ## CAVEAT EMPTOR:
50998 ## There is no encapsulation within the following macros, do not change
50999 ## the running order or otherwise move them around unless you know exactly
51000 ## what you are doing...
51001 if test -n "$compiler"; then
51002
51003 lt_prog_compiler_no_builtin_flag=
51004
51005 if test "$GCC" = yes; then
51006   case $cc_basename in
51007   nvcc*)
51008     lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;;
51009   *)
51010     lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;;
51011   esac
51012
51013   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
51014 $as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; }
51015 if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then :
51016   $as_echo_n "(cached) " >&6
51017 else
51018   lt_cv_prog_compiler_rtti_exceptions=no
51019    ac_outfile=conftest.$ac_objext
51020    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
51021    lt_compiler_flag="-fno-rtti -fno-exceptions"
51022    # Insert the option either (1) after the last *FLAGS variable, or
51023    # (2) before a word containing "conftest.", or (3) at the end.
51024    # Note that $ac_compile itself does not contain backslashes and begins
51025    # with a dollar sign (not a hyphen), so the echo should work correctly.
51026    # The option is referenced via a variable to avoid confusing sed.
51027    lt_compile=`echo "$ac_compile" | $SED \
51028    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
51029    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
51030    -e 's:$: $lt_compiler_flag:'`
51031    (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
51032    (eval "$lt_compile" 2>conftest.err)
51033    ac_status=$?
51034    cat conftest.err >&5
51035    echo "$as_me:$LINENO: \$? = $ac_status" >&5
51036    if (exit $ac_status) && test -s "$ac_outfile"; then
51037      # The compiler can only warn and ignore the option if not recognized
51038      # So say no if there are warnings other than the usual output.
51039      $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
51040      $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
51041      if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
51042        lt_cv_prog_compiler_rtti_exceptions=yes
51043      fi
51044    fi
51045    $RM conftest*
51046
51047 fi
51048 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
51049 $as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; }
51050
51051 if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then
51052     lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
51053 else
51054     :
51055 fi
51056
51057 fi
51058
51059
51060
51061
51062
51063
51064   lt_prog_compiler_wl=
51065 lt_prog_compiler_pic=
51066 lt_prog_compiler_static=
51067
51068
51069   if test "$GCC" = yes; then
51070     lt_prog_compiler_wl='-Wl,'
51071     lt_prog_compiler_static='-static'
51072
51073     case $host_os in
51074       aix*)
51075       # All AIX code is PIC.
51076       if test "$host_cpu" = ia64; then
51077         # AIX 5 now supports IA64 processor
51078         lt_prog_compiler_static='-Bstatic'
51079       fi
51080       ;;
51081
51082     amigaos*)
51083       case $host_cpu in
51084       powerpc)
51085             # see comment about AmigaOS4 .so support
51086             lt_prog_compiler_pic='-fPIC'
51087         ;;
51088       m68k)
51089             # FIXME: we need at least 68020 code to build shared libraries, but
51090             # adding the `-m68020' flag to GCC prevents building anything better,
51091             # like `-m68040'.
51092             lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
51093         ;;
51094       esac
51095       ;;
51096
51097     beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
51098       # PIC is the default for these OSes.
51099       ;;
51100
51101     mingw* | cygwin* | pw32* | os2* | cegcc*)
51102       # This hack is so that the source file can tell whether it is being
51103       # built for inclusion in a dll (and should export symbols for example).
51104       # Although the cygwin gcc ignores -fPIC, still need this for old-style
51105       # (--disable-auto-import) libraries
51106       lt_prog_compiler_pic='-DDLL_EXPORT'
51107       ;;
51108
51109     darwin* | rhapsody*)
51110       # PIC is the default on this platform
51111       # Common symbols not allowed in MH_DYLIB files
51112       lt_prog_compiler_pic='-fno-common'
51113       ;;
51114
51115     haiku*)
51116       # PIC is the default for Haiku.
51117       # The "-static" flag exists, but is broken.
51118       lt_prog_compiler_static=
51119       ;;
51120
51121     hpux*)
51122       # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
51123       # PA HP-UX.  On IA64 HP-UX, PIC is the default but the pic flag
51124       # sets the default TLS model and affects inlining.
51125       case $host_cpu in
51126       hppa*64*)
51127         # +Z the default
51128         ;;
51129       *)
51130         lt_prog_compiler_pic='-fPIC'
51131         ;;
51132       esac
51133       ;;
51134
51135     interix[3-9]*)
51136       # Interix 3.x gcc -fpic/-fPIC options generate broken code.
51137       # Instead, we relocate shared libraries at runtime.
51138       ;;
51139
51140     msdosdjgpp*)
51141       # Just because we use GCC doesn't mean we suddenly get shared libraries
51142       # on systems that don't support them.
51143       lt_prog_compiler_can_build_shared=no
51144       enable_shared=no
51145       ;;
51146
51147     *nto* | *qnx*)
51148       # QNX uses GNU C++, but need to define -shared option too, otherwise
51149       # it will coredump.
51150       lt_prog_compiler_pic='-fPIC -shared'
51151       ;;
51152
51153     sysv4*MP*)
51154       if test -d /usr/nec; then
51155         lt_prog_compiler_pic=-Kconform_pic
51156       fi
51157       ;;
51158
51159     *)
51160       lt_prog_compiler_pic='-fPIC'
51161       ;;
51162     esac
51163
51164     case $cc_basename in
51165     nvcc*) # Cuda Compiler Driver 2.2
51166       lt_prog_compiler_wl='-Xlinker '
51167       if test -n "$lt_prog_compiler_pic"; then
51168         lt_prog_compiler_pic="-Xcompiler $lt_prog_compiler_pic"
51169       fi
51170       ;;
51171     esac
51172   else
51173     # PORTME Check for flag to pass linker flags through the system compiler.
51174     case $host_os in
51175     aix*)
51176       lt_prog_compiler_wl='-Wl,'
51177       if test "$host_cpu" = ia64; then
51178         # AIX 5 now supports IA64 processor
51179         lt_prog_compiler_static='-Bstatic'
51180       else
51181         lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp'
51182       fi
51183       ;;
51184
51185     mingw* | cygwin* | pw32* | os2* | cegcc*)
51186       # This hack is so that the source file can tell whether it is being
51187       # built for inclusion in a dll (and should export symbols for example).
51188       lt_prog_compiler_pic='-DDLL_EXPORT'
51189       ;;
51190
51191     hpux9* | hpux10* | hpux11*)
51192       lt_prog_compiler_wl='-Wl,'
51193       # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
51194       # not for PA HP-UX.
51195       case $host_cpu in
51196       hppa*64*|ia64*)
51197         # +Z the default
51198         ;;
51199       *)
51200         lt_prog_compiler_pic='+Z'
51201         ;;
51202       esac
51203       # Is there a better lt_prog_compiler_static that works with the bundled CC?
51204       lt_prog_compiler_static='${wl}-a ${wl}archive'
51205       ;;
51206
51207     irix5* | irix6* | nonstopux*)
51208       lt_prog_compiler_wl='-Wl,'
51209       # PIC (with -KPIC) is the default.
51210       lt_prog_compiler_static='-non_shared'
51211       ;;
51212
51213     linux* | k*bsd*-gnu | kopensolaris*-gnu)
51214       case $cc_basename in
51215       # old Intel for x86_64 which still supported -KPIC.
51216       ecc*)
51217         lt_prog_compiler_wl='-Wl,'
51218         lt_prog_compiler_pic='-KPIC'
51219         lt_prog_compiler_static='-static'
51220         ;;
51221       # icc used to be incompatible with GCC.
51222       # ICC 10 doesn't accept -KPIC any more.
51223       icc* | ifort*)
51224         lt_prog_compiler_wl='-Wl,'
51225         lt_prog_compiler_pic='-fPIC'
51226         lt_prog_compiler_static='-static'
51227         ;;
51228       # Lahey Fortran 8.1.
51229       lf95*)
51230         lt_prog_compiler_wl='-Wl,'
51231         lt_prog_compiler_pic='--shared'
51232         lt_prog_compiler_static='--static'
51233         ;;
51234       nagfor*)
51235         # NAG Fortran compiler
51236         lt_prog_compiler_wl='-Wl,-Wl,,'
51237         lt_prog_compiler_pic='-PIC'
51238         lt_prog_compiler_static='-Bstatic'
51239         ;;
51240       pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
51241         # Portland Group compilers (*not* the Pentium gcc compiler,
51242         # which looks to be a dead project)
51243         lt_prog_compiler_wl='-Wl,'
51244         lt_prog_compiler_pic='-fpic'
51245         lt_prog_compiler_static='-Bstatic'
51246         ;;
51247       ccc*)
51248         lt_prog_compiler_wl='-Wl,'
51249         # All Alpha code is PIC.
51250         lt_prog_compiler_static='-non_shared'
51251         ;;
51252       xl* | bgxl* | bgf* | mpixl*)
51253         # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
51254         lt_prog_compiler_wl='-Wl,'
51255         lt_prog_compiler_pic='-qpic'
51256         lt_prog_compiler_static='-qstaticlink'
51257         ;;
51258       *)
51259         case `$CC -V 2>&1 | sed 5q` in
51260         *Sun\ Ceres\ Fortran* | *Sun*Fortran*\ [1-7].* | *Sun*Fortran*\ 8.[0-3]*)
51261           # Sun Fortran 8.3 passes all unrecognized flags to the linker
51262           lt_prog_compiler_pic='-KPIC'
51263           lt_prog_compiler_static='-Bstatic'
51264           lt_prog_compiler_wl=''
51265           ;;
51266         *Sun\ F* | *Sun*Fortran*)
51267           lt_prog_compiler_pic='-KPIC'
51268           lt_prog_compiler_static='-Bstatic'
51269           lt_prog_compiler_wl='-Qoption ld '
51270           ;;
51271         *Sun\ C*)
51272           # Sun C 5.9
51273           lt_prog_compiler_pic='-KPIC'
51274           lt_prog_compiler_static='-Bstatic'
51275           lt_prog_compiler_wl='-Wl,'
51276           ;;
51277         *Intel*\ [CF]*Compiler*)
51278           lt_prog_compiler_wl='-Wl,'
51279           lt_prog_compiler_pic='-fPIC'
51280           lt_prog_compiler_static='-static'
51281           ;;
51282         *Portland\ Group*)
51283           lt_prog_compiler_wl='-Wl,'
51284           lt_prog_compiler_pic='-fpic'
51285           lt_prog_compiler_static='-Bstatic'
51286           ;;
51287         esac
51288         ;;
51289       esac
51290       ;;
51291
51292     newsos6)
51293       lt_prog_compiler_pic='-KPIC'
51294       lt_prog_compiler_static='-Bstatic'
51295       ;;
51296
51297     *nto* | *qnx*)
51298       # QNX uses GNU C++, but need to define -shared option too, otherwise
51299       # it will coredump.
51300       lt_prog_compiler_pic='-fPIC -shared'
51301       ;;
51302
51303     osf3* | osf4* | osf5*)
51304       lt_prog_compiler_wl='-Wl,'
51305       # All OSF/1 code is PIC.
51306       lt_prog_compiler_static='-non_shared'
51307       ;;
51308
51309     rdos*)
51310       lt_prog_compiler_static='-non_shared'
51311       ;;
51312
51313     solaris*)
51314       lt_prog_compiler_pic='-KPIC'
51315       lt_prog_compiler_static='-Bstatic'
51316       case $cc_basename in
51317       f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
51318         lt_prog_compiler_wl='-Qoption ld ';;
51319       *)
51320         lt_prog_compiler_wl='-Wl,';;
51321       esac
51322       ;;
51323
51324     sunos4*)
51325       lt_prog_compiler_wl='-Qoption ld '
51326       lt_prog_compiler_pic='-PIC'
51327       lt_prog_compiler_static='-Bstatic'
51328       ;;
51329
51330     sysv4 | sysv4.2uw2* | sysv4.3*)
51331       lt_prog_compiler_wl='-Wl,'
51332       lt_prog_compiler_pic='-KPIC'
51333       lt_prog_compiler_static='-Bstatic'
51334       ;;
51335
51336     sysv4*MP*)
51337       if test -d /usr/nec ;then
51338         lt_prog_compiler_pic='-Kconform_pic'
51339         lt_prog_compiler_static='-Bstatic'
51340       fi
51341       ;;
51342
51343     sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
51344       lt_prog_compiler_wl='-Wl,'
51345       lt_prog_compiler_pic='-KPIC'
51346       lt_prog_compiler_static='-Bstatic'
51347       ;;
51348
51349     unicos*)
51350       lt_prog_compiler_wl='-Wl,'
51351       lt_prog_compiler_can_build_shared=no
51352       ;;
51353
51354     uts4*)
51355       lt_prog_compiler_pic='-pic'
51356       lt_prog_compiler_static='-Bstatic'
51357       ;;
51358
51359     *)
51360       lt_prog_compiler_can_build_shared=no
51361       ;;
51362     esac
51363   fi
51364
51365 case $host_os in
51366   # For platforms which do not support PIC, -DPIC is meaningless:
51367   *djgpp*)
51368     lt_prog_compiler_pic=
51369     ;;
51370   *)
51371     lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
51372     ;;
51373 esac
51374
51375 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
51376 $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
51377 if ${lt_cv_prog_compiler_pic+:} false; then :
51378   $as_echo_n "(cached) " >&6
51379 else
51380   lt_cv_prog_compiler_pic=$lt_prog_compiler_pic
51381 fi
51382 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5
51383 $as_echo "$lt_cv_prog_compiler_pic" >&6; }
51384 lt_prog_compiler_pic=$lt_cv_prog_compiler_pic
51385
51386 #
51387 # Check to make sure the PIC flag actually works.
51388 #
51389 if test -n "$lt_prog_compiler_pic"; then
51390   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
51391 $as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; }
51392 if ${lt_cv_prog_compiler_pic_works+:} false; then :
51393   $as_echo_n "(cached) " >&6
51394 else
51395   lt_cv_prog_compiler_pic_works=no
51396    ac_outfile=conftest.$ac_objext
51397    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
51398    lt_compiler_flag="$lt_prog_compiler_pic -DPIC"
51399    # Insert the option either (1) after the last *FLAGS variable, or
51400    # (2) before a word containing "conftest.", or (3) at the end.
51401    # Note that $ac_compile itself does not contain backslashes and begins
51402    # with a dollar sign (not a hyphen), so the echo should work correctly.
51403    # The option is referenced via a variable to avoid confusing sed.
51404    lt_compile=`echo "$ac_compile" | $SED \
51405    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
51406    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
51407    -e 's:$: $lt_compiler_flag:'`
51408    (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
51409    (eval "$lt_compile" 2>conftest.err)
51410    ac_status=$?
51411    cat conftest.err >&5
51412    echo "$as_me:$LINENO: \$? = $ac_status" >&5
51413    if (exit $ac_status) && test -s "$ac_outfile"; then
51414      # The compiler can only warn and ignore the option if not recognized
51415      # So say no if there are warnings other than the usual output.
51416      $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
51417      $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
51418      if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
51419        lt_cv_prog_compiler_pic_works=yes
51420      fi
51421    fi
51422    $RM conftest*
51423
51424 fi
51425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5
51426 $as_echo "$lt_cv_prog_compiler_pic_works" >&6; }
51427
51428 if test x"$lt_cv_prog_compiler_pic_works" = xyes; then
51429     case $lt_prog_compiler_pic in
51430      "" | " "*) ;;
51431      *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
51432      esac
51433 else
51434     lt_prog_compiler_pic=
51435      lt_prog_compiler_can_build_shared=no
51436 fi
51437
51438 fi
51439
51440
51441
51442
51443
51444
51445
51446
51447
51448
51449
51450 #
51451 # Check to make sure the static flag actually works.
51452 #
51453 wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\"
51454 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
51455 $as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
51456 if ${lt_cv_prog_compiler_static_works+:} false; then :
51457   $as_echo_n "(cached) " >&6
51458 else
51459   lt_cv_prog_compiler_static_works=no
51460    save_LDFLAGS="$LDFLAGS"
51461    LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
51462    echo "$lt_simple_link_test_code" > conftest.$ac_ext
51463    if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
51464      # The linker can only warn and ignore the option if not recognized
51465      # So say no if there are warnings
51466      if test -s conftest.err; then
51467        # Append any errors to the config.log.
51468        cat conftest.err 1>&5
51469        $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
51470        $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
51471        if diff conftest.exp conftest.er2 >/dev/null; then
51472          lt_cv_prog_compiler_static_works=yes
51473        fi
51474      else
51475        lt_cv_prog_compiler_static_works=yes
51476      fi
51477    fi
51478    $RM -r conftest*
51479    LDFLAGS="$save_LDFLAGS"
51480
51481 fi
51482 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5
51483 $as_echo "$lt_cv_prog_compiler_static_works" >&6; }
51484
51485 if test x"$lt_cv_prog_compiler_static_works" = xyes; then
51486     :
51487 else
51488     lt_prog_compiler_static=
51489 fi
51490
51491
51492
51493
51494
51495
51496
51497   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
51498 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
51499 if ${lt_cv_prog_compiler_c_o+:} false; then :
51500   $as_echo_n "(cached) " >&6
51501 else
51502   lt_cv_prog_compiler_c_o=no
51503    $RM -r conftest 2>/dev/null
51504    mkdir conftest
51505    cd conftest
51506    mkdir out
51507    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
51508
51509    lt_compiler_flag="-o out/conftest2.$ac_objext"
51510    # Insert the option either (1) after the last *FLAGS variable, or
51511    # (2) before a word containing "conftest.", or (3) at the end.
51512    # Note that $ac_compile itself does not contain backslashes and begins
51513    # with a dollar sign (not a hyphen), so the echo should work correctly.
51514    lt_compile=`echo "$ac_compile" | $SED \
51515    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
51516    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
51517    -e 's:$: $lt_compiler_flag:'`
51518    (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
51519    (eval "$lt_compile" 2>out/conftest.err)
51520    ac_status=$?
51521    cat out/conftest.err >&5
51522    echo "$as_me:$LINENO: \$? = $ac_status" >&5
51523    if (exit $ac_status) && test -s out/conftest2.$ac_objext
51524    then
51525      # The compiler can only warn and ignore the option if not recognized
51526      # So say no if there are warnings
51527      $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
51528      $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
51529      if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
51530        lt_cv_prog_compiler_c_o=yes
51531      fi
51532    fi
51533    chmod u+w . 2>&5
51534    $RM conftest*
51535    # SGI C++ compiler will create directory out/ii_files/ for
51536    # template instantiation
51537    test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
51538    $RM out/* && rmdir out
51539    cd ..
51540    $RM -r conftest
51541    $RM conftest*
51542
51543 fi
51544 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
51545 $as_echo "$lt_cv_prog_compiler_c_o" >&6; }
51546
51547
51548
51549
51550
51551
51552   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
51553 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
51554 if ${lt_cv_prog_compiler_c_o+:} false; then :
51555   $as_echo_n "(cached) " >&6
51556 else
51557   lt_cv_prog_compiler_c_o=no
51558    $RM -r conftest 2>/dev/null
51559    mkdir conftest
51560    cd conftest
51561    mkdir out
51562    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
51563
51564    lt_compiler_flag="-o out/conftest2.$ac_objext"
51565    # Insert the option either (1) after the last *FLAGS variable, or
51566    # (2) before a word containing "conftest.", or (3) at the end.
51567    # Note that $ac_compile itself does not contain backslashes and begins
51568    # with a dollar sign (not a hyphen), so the echo should work correctly.
51569    lt_compile=`echo "$ac_compile" | $SED \
51570    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
51571    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
51572    -e 's:$: $lt_compiler_flag:'`
51573    (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
51574    (eval "$lt_compile" 2>out/conftest.err)
51575    ac_status=$?
51576    cat out/conftest.err >&5
51577    echo "$as_me:$LINENO: \$? = $ac_status" >&5
51578    if (exit $ac_status) && test -s out/conftest2.$ac_objext
51579    then
51580      # The compiler can only warn and ignore the option if not recognized
51581      # So say no if there are warnings
51582      $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
51583      $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
51584      if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
51585        lt_cv_prog_compiler_c_o=yes
51586      fi
51587    fi
51588    chmod u+w . 2>&5
51589    $RM conftest*
51590    # SGI C++ compiler will create directory out/ii_files/ for
51591    # template instantiation
51592    test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
51593    $RM out/* && rmdir out
51594    cd ..
51595    $RM -r conftest
51596    $RM conftest*
51597
51598 fi
51599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
51600 $as_echo "$lt_cv_prog_compiler_c_o" >&6; }
51601
51602
51603
51604
51605 hard_links="nottested"
51606 if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then
51607   # do not overwrite the value of need_locks provided by the user
51608   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
51609 $as_echo_n "checking if we can lock with hard links... " >&6; }
51610   hard_links=yes
51611   $RM conftest*
51612   ln conftest.a conftest.b 2>/dev/null && hard_links=no
51613   touch conftest.a
51614   ln conftest.a conftest.b 2>&5 || hard_links=no
51615   ln conftest.a conftest.b 2>/dev/null && hard_links=no
51616   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
51617 $as_echo "$hard_links" >&6; }
51618   if test "$hard_links" = no; then
51619     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
51620 $as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
51621     need_locks=warn
51622   fi
51623 else
51624   need_locks=no
51625 fi
51626
51627
51628
51629
51630
51631
51632   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
51633 $as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
51634
51635   runpath_var=
51636   allow_undefined_flag=
51637   always_export_symbols=no
51638   archive_cmds=
51639   archive_expsym_cmds=
51640   compiler_needs_object=no
51641   enable_shared_with_static_runtimes=no
51642   export_dynamic_flag_spec=
51643   export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
51644   hardcode_automatic=no
51645   hardcode_direct=no
51646   hardcode_direct_absolute=no
51647   hardcode_libdir_flag_spec=
51648   hardcode_libdir_separator=
51649   hardcode_minus_L=no
51650   hardcode_shlibpath_var=unsupported
51651   inherit_rpath=no
51652   link_all_deplibs=unknown
51653   module_cmds=
51654   module_expsym_cmds=
51655   old_archive_from_new_cmds=
51656   old_archive_from_expsyms_cmds=
51657   thread_safe_flag_spec=
51658   whole_archive_flag_spec=
51659   # include_expsyms should be a list of space-separated symbols to be *always*
51660   # included in the symbol list
51661   include_expsyms=
51662   # exclude_expsyms can be an extended regexp of symbols to exclude
51663   # it will be wrapped by ` (' and `)$', so one must not match beginning or
51664   # end of line.  Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
51665   # as well as any symbol that contains `d'.
51666   exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
51667   # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
51668   # platforms (ab)use it in PIC code, but their linkers get confused if
51669   # the symbol is explicitly referenced.  Since portable code cannot
51670   # rely on this symbol name, it's probably fine to never include it in
51671   # preloaded symbol tables.
51672   # Exclude shared library initialization/finalization symbols.
51673   extract_expsyms_cmds=
51674
51675   case $host_os in
51676   cygwin* | mingw* | pw32* | cegcc*)
51677     # FIXME: the MSVC++ port hasn't been tested in a loooong time
51678     # When not using gcc, we currently assume that we are using
51679     # Microsoft Visual C++.
51680     if test "$GCC" != yes; then
51681       with_gnu_ld=no
51682     fi
51683     ;;
51684   interix*)
51685     # we just hope/assume this is gcc and not c89 (= MSVC++)
51686     with_gnu_ld=yes
51687     ;;
51688   openbsd*)
51689     with_gnu_ld=no
51690     ;;
51691   esac
51692
51693   ld_shlibs=yes
51694
51695   # On some targets, GNU ld is compatible enough with the native linker
51696   # that we're better off using the native interface for both.
51697   lt_use_gnu_ld_interface=no
51698   if test "$with_gnu_ld" = yes; then
51699     case $host_os in
51700       aix*)
51701         # The AIX port of GNU ld has always aspired to compatibility
51702         # with the native linker.  However, as the warning in the GNU ld
51703         # block says, versions before 2.19.5* couldn't really create working
51704         # shared libraries, regardless of the interface used.
51705         case `$LD -v 2>&1` in
51706           *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
51707           *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;;
51708           *\ \(GNU\ Binutils\)\ [3-9]*) ;;
51709           *)
51710             lt_use_gnu_ld_interface=yes
51711             ;;
51712         esac
51713         ;;
51714       *)
51715         lt_use_gnu_ld_interface=yes
51716         ;;
51717     esac
51718   fi
51719
51720   if test "$lt_use_gnu_ld_interface" = yes; then
51721     # If archive_cmds runs LD, not CC, wlarc should be empty
51722     wlarc='${wl}'
51723
51724     # Set some defaults for GNU ld with shared library support. These
51725     # are reset later if shared libraries are not supported. Putting them
51726     # here allows them to be overridden if necessary.
51727     runpath_var=LD_RUN_PATH
51728     hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
51729     export_dynamic_flag_spec='${wl}--export-dynamic'
51730     # ancient GNU ld didn't support --whole-archive et. al.
51731     if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
51732       whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
51733     else
51734       whole_archive_flag_spec=
51735     fi
51736     supports_anon_versioning=no
51737     case `$LD -v 2>&1` in
51738       *GNU\ gold*) supports_anon_versioning=yes ;;
51739       *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
51740       *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
51741       *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
51742       *\ 2.11.*) ;; # other 2.11 versions
51743       *) supports_anon_versioning=yes ;;
51744     esac
51745
51746     # See if GNU ld supports shared libraries.
51747     case $host_os in
51748     aix[3-9]*)
51749       # On AIX/PPC, the GNU linker is very broken
51750       if test "$host_cpu" != ia64; then
51751         ld_shlibs=no
51752         cat <<_LT_EOF 1>&2
51753
51754 *** Warning: the GNU linker, at least up to release 2.19, is reported
51755 *** to be unable to reliably create shared libraries on AIX.
51756 *** Therefore, libtool is disabling shared libraries support.  If you
51757 *** really care for shared libraries, you may want to install binutils
51758 *** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
51759 *** You will then need to restart the configuration process.
51760
51761 _LT_EOF
51762       fi
51763       ;;
51764
51765     amigaos*)
51766       case $host_cpu in
51767       powerpc)
51768             # see comment about AmigaOS4 .so support
51769             archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
51770             archive_expsym_cmds=''
51771         ;;
51772       m68k)
51773             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)'
51774             hardcode_libdir_flag_spec='-L$libdir'
51775             hardcode_minus_L=yes
51776         ;;
51777       esac
51778       ;;
51779
51780     beos*)
51781       if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
51782         allow_undefined_flag=unsupported
51783         # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
51784         # support --undefined.  This deserves some investigation.  FIXME
51785         archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
51786       else
51787         ld_shlibs=no
51788       fi
51789       ;;
51790
51791     cygwin* | mingw* | pw32* | cegcc*)
51792       # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
51793       # as there is no search path for DLLs.
51794       hardcode_libdir_flag_spec='-L$libdir'
51795       export_dynamic_flag_spec='${wl}--export-all-symbols'
51796       allow_undefined_flag=unsupported
51797       always_export_symbols=no
51798       enable_shared_with_static_runtimes=yes
51799       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'
51800       exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'
51801
51802       if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
51803         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
51804         # If the export-symbols file already is a .def file (1st line
51805         # is EXPORTS), use it as is; otherwise, prepend...
51806         archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
51807           cp $export_symbols $output_objdir/$soname.def;
51808         else
51809           echo EXPORTS > $output_objdir/$soname.def;
51810           cat $export_symbols >> $output_objdir/$soname.def;
51811         fi~
51812         $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
51813       else
51814         ld_shlibs=no
51815       fi
51816       ;;
51817
51818     haiku*)
51819       archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
51820       link_all_deplibs=yes
51821       ;;
51822
51823     interix[3-9]*)
51824       hardcode_direct=no
51825       hardcode_shlibpath_var=no
51826       hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
51827       export_dynamic_flag_spec='${wl}-E'
51828       # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
51829       # Instead, shared libraries are loaded at an image base (0x10000000 by
51830       # default) and relocated if they conflict, which is a slow very memory
51831       # consuming and fragmenting process.  To avoid this, we pick a random,
51832       # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
51833       # time.  Moving up from 0x10000000 also allows more sbrk(2) space.
51834       archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
51835       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'
51836       ;;
51837
51838     gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
51839       tmp_diet=no
51840       if test "$host_os" = linux-dietlibc; then
51841         case $cc_basename in
51842           diet\ *) tmp_diet=yes;;       # linux-dietlibc with static linking (!diet-dyn)
51843         esac
51844       fi
51845       if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
51846          && test "$tmp_diet" = no
51847       then
51848         tmp_addflag=' $pic_flag'
51849         tmp_sharedflag='-shared'
51850         case $cc_basename,$host_cpu in
51851         pgcc*)                          # Portland Group C compiler
51852           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'
51853           tmp_addflag=' $pic_flag'
51854           ;;
51855         pgf77* | pgf90* | pgf95* | pgfortran*)
51856                                         # Portland Group f77 and f90 compilers
51857           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'
51858           tmp_addflag=' $pic_flag -Mnomain' ;;
51859         ecc*,ia64* | icc*,ia64*)        # Intel C compiler on ia64
51860           tmp_addflag=' -i_dynamic' ;;
51861         efc*,ia64* | ifort*,ia64*)      # Intel Fortran compiler on ia64
51862           tmp_addflag=' -i_dynamic -nofor_main' ;;
51863         ifc* | ifort*)                  # Intel Fortran compiler
51864           tmp_addflag=' -nofor_main' ;;
51865         lf95*)                          # Lahey Fortran 8.1
51866           whole_archive_flag_spec=
51867           tmp_sharedflag='--shared' ;;
51868         xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below)
51869           tmp_sharedflag='-qmkshrobj'
51870           tmp_addflag= ;;
51871         nvcc*)  # Cuda Compiler Driver 2.2
51872           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'
51873           compiler_needs_object=yes
51874           ;;
51875         esac
51876         case `$CC -V 2>&1 | sed 5q` in
51877         *Sun\ C*)                       # Sun C 5.9
51878           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'
51879           compiler_needs_object=yes
51880           tmp_sharedflag='-G' ;;
51881         *Sun\ F*)                       # Sun Fortran 8.3
51882           tmp_sharedflag='-G' ;;
51883         esac
51884         archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
51885
51886         if test "x$supports_anon_versioning" = xyes; then
51887           archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
51888             cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
51889             echo "local: *; };" >> $output_objdir/$libname.ver~
51890             $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
51891         fi
51892
51893         case $cc_basename in
51894         xlf* | bgf* | bgxlf* | mpixlf*)
51895           # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
51896           whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
51897           hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
51898           archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
51899           if test "x$supports_anon_versioning" = xyes; then
51900             archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
51901               cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
51902               echo "local: *; };" >> $output_objdir/$libname.ver~
51903               $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
51904           fi
51905           ;;
51906         esac
51907       else
51908         ld_shlibs=no
51909       fi
51910       ;;
51911
51912     netbsd*)
51913       if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
51914         archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
51915         wlarc=
51916       else
51917         archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
51918         archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
51919       fi
51920       ;;
51921
51922     solaris*)
51923       if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
51924         ld_shlibs=no
51925         cat <<_LT_EOF 1>&2
51926
51927 *** Warning: The releases 2.8.* of the GNU linker cannot reliably
51928 *** create shared libraries on Solaris systems.  Therefore, libtool
51929 *** is disabling shared libraries support.  We urge you to upgrade GNU
51930 *** binutils to release 2.9.1 or newer.  Another option is to modify
51931 *** your PATH or compiler configuration so that the native linker is
51932 *** used, and then restart.
51933
51934 _LT_EOF
51935       elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
51936         archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
51937         archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
51938       else
51939         ld_shlibs=no
51940       fi
51941       ;;
51942
51943     sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
51944       case `$LD -v 2>&1` in
51945         *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*)
51946         ld_shlibs=no
51947         cat <<_LT_EOF 1>&2
51948
51949 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
51950 *** reliably create shared libraries on SCO systems.  Therefore, libtool
51951 *** is disabling shared libraries support.  We urge you to upgrade GNU
51952 *** binutils to release 2.16.91.0.3 or newer.  Another option is to modify
51953 *** your PATH or compiler configuration so that the native linker is
51954 *** used, and then restart.
51955
51956 _LT_EOF
51957         ;;
51958         *)
51959           # For security reasons, it is highly recommended that you always
51960           # use absolute paths for naming shared libraries, and exclude the
51961           # DT_RUNPATH tag from executables and libraries.  But doing so
51962           # requires that you compile everything twice, which is a pain.
51963           if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
51964             hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
51965             archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
51966             archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
51967           else
51968             ld_shlibs=no
51969           fi
51970         ;;
51971       esac
51972       ;;
51973
51974     sunos4*)
51975       archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
51976       wlarc=
51977       hardcode_direct=yes
51978       hardcode_shlibpath_var=no
51979       ;;
51980
51981     *)
51982       if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
51983         archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
51984         archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
51985       else
51986         ld_shlibs=no
51987       fi
51988       ;;
51989     esac
51990
51991     if test "$ld_shlibs" = no; then
51992       runpath_var=
51993       hardcode_libdir_flag_spec=
51994       export_dynamic_flag_spec=
51995       whole_archive_flag_spec=
51996     fi
51997   else
51998     # PORTME fill in a description of your system's linker (not GNU ld)
51999     case $host_os in
52000     aix3*)
52001       allow_undefined_flag=unsupported
52002       always_export_symbols=yes
52003       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'
52004       # Note: this linker hardcodes the directories in LIBPATH if there
52005       # are no directories specified by -L.
52006       hardcode_minus_L=yes
52007       if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
52008         # Neither direct hardcoding nor static linking is supported with a
52009         # broken collect2.
52010         hardcode_direct=unsupported
52011       fi
52012       ;;
52013
52014     aix[4-9]*)
52015       if test "$host_cpu" = ia64; then
52016         # On IA64, the linker does run time linking by default, so we don't
52017         # have to do anything special.
52018         aix_use_runtimelinking=no
52019         exp_sym_flag='-Bexport'
52020         no_entry_flag=""
52021       else
52022         # If we're using GNU nm, then we don't want the "-C" option.
52023         # -C means demangle to AIX nm, but means don't demangle with GNU nm
52024         # Also, AIX nm treats weak defined symbols like other global
52025         # defined symbols, whereas GNU nm marks them as "W".
52026         if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
52027           export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
52028         else
52029           export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
52030         fi
52031         aix_use_runtimelinking=no
52032
52033         # Test if we are trying to use run time linking or normal
52034         # AIX style linking. If -brtl is somewhere in LDFLAGS, we
52035         # need to do runtime linking.
52036         case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
52037           for ld_flag in $LDFLAGS; do
52038           if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
52039             aix_use_runtimelinking=yes
52040             break
52041           fi
52042           done
52043           ;;
52044         esac
52045
52046         exp_sym_flag='-bexport'
52047         no_entry_flag='-bnoentry'
52048       fi
52049
52050       # When large executables or shared objects are built, AIX ld can
52051       # have problems creating the table of contents.  If linking a library
52052       # or program results in "error TOC overflow" add -mminimal-toc to
52053       # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
52054       # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
52055
52056       archive_cmds=''
52057       hardcode_direct=yes
52058       hardcode_direct_absolute=yes
52059       hardcode_libdir_separator=':'
52060       link_all_deplibs=yes
52061       file_list_spec='${wl}-f,'
52062
52063       if test "$GCC" = yes; then
52064         case $host_os in aix4.[012]|aix4.[012].*)
52065         # We only want to do this on AIX 4.2 and lower, the check
52066         # below for broken collect2 doesn't work under 4.3+
52067           collect2name=`${CC} -print-prog-name=collect2`
52068           if test -f "$collect2name" &&
52069            strings "$collect2name" | $GREP resolve_lib_name >/dev/null
52070           then
52071           # We have reworked collect2
52072           :
52073           else
52074           # We have old collect2
52075           hardcode_direct=unsupported
52076           # It fails to find uninstalled libraries when the uninstalled
52077           # path is not listed in the libpath.  Setting hardcode_minus_L
52078           # to unsupported forces relinking
52079           hardcode_minus_L=yes
52080           hardcode_libdir_flag_spec='-L$libdir'
52081           hardcode_libdir_separator=
52082           fi
52083           ;;
52084         esac
52085         shared_flag='-shared'
52086         if test "$aix_use_runtimelinking" = yes; then
52087           shared_flag="$shared_flag "'${wl}-G'
52088         fi
52089       else
52090         # not using gcc
52091         if test "$host_cpu" = ia64; then
52092         # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
52093         # chokes on -Wl,-G. The following line is correct:
52094           shared_flag='-G'
52095         else
52096           if test "$aix_use_runtimelinking" = yes; then
52097             shared_flag='${wl}-G'
52098           else
52099             shared_flag='${wl}-bM:SRE'
52100           fi
52101         fi
52102       fi
52103
52104       export_dynamic_flag_spec='${wl}-bexpall'
52105       # It seems that -bexpall does not export symbols beginning with
52106       # underscore (_), so it is better to generate a list of symbols to export.
52107       always_export_symbols=yes
52108       if test "$aix_use_runtimelinking" = yes; then
52109         # Warning - without using the other runtime loading flags (-brtl),
52110         # -berok will link without error, but may produce a broken library.
52111         allow_undefined_flag='-berok'
52112         # Determine the default libpath from the value encoded in an
52113         # empty executable.
52114         if test "${lt_cv_aix_libpath+set}" = set; then
52115   aix_libpath=$lt_cv_aix_libpath
52116 else
52117   if ${lt_cv_aix_libpath_+:} false; then :
52118   $as_echo_n "(cached) " >&6
52119 else
52120   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
52121 /* end confdefs.h.  */
52122
52123 int
52124 main ()
52125 {
52126
52127   ;
52128   return 0;
52129 }
52130 _ACEOF
52131 if ac_fn_c_try_link "$LINENO"; then :
52132
52133   lt_aix_libpath_sed='
52134       /Import File Strings/,/^$/ {
52135           /^0/ {
52136               s/^0  *\([^ ]*\) *$/\1/
52137               p
52138           }
52139       }'
52140   lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
52141   # Check for a 64-bit object if we didn't find anything.
52142   if test -z "$lt_cv_aix_libpath_"; then
52143     lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
52144   fi
52145 fi
52146 rm -f core conftest.err conftest.$ac_objext \
52147     conftest$ac_exeext conftest.$ac_ext
52148   if test -z "$lt_cv_aix_libpath_"; then
52149     lt_cv_aix_libpath_="/usr/lib:/lib"
52150   fi
52151
52152 fi
52153
52154   aix_libpath=$lt_cv_aix_libpath_
52155 fi
52156
52157         hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
52158         archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
52159       else
52160         if test "$host_cpu" = ia64; then
52161           hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
52162           allow_undefined_flag="-z nodefs"
52163           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"
52164         else
52165          # Determine the default libpath from the value encoded in an
52166          # empty executable.
52167          if test "${lt_cv_aix_libpath+set}" = set; then
52168   aix_libpath=$lt_cv_aix_libpath
52169 else
52170   if ${lt_cv_aix_libpath_+:} false; then :
52171   $as_echo_n "(cached) " >&6
52172 else
52173   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
52174 /* end confdefs.h.  */
52175
52176 int
52177 main ()
52178 {
52179
52180   ;
52181   return 0;
52182 }
52183 _ACEOF
52184 if ac_fn_c_try_link "$LINENO"; then :
52185
52186   lt_aix_libpath_sed='
52187       /Import File Strings/,/^$/ {
52188           /^0/ {
52189               s/^0  *\([^ ]*\) *$/\1/
52190               p
52191           }
52192       }'
52193   lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
52194   # Check for a 64-bit object if we didn't find anything.
52195   if test -z "$lt_cv_aix_libpath_"; then
52196     lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
52197   fi
52198 fi
52199 rm -f core conftest.err conftest.$ac_objext \
52200     conftest$ac_exeext conftest.$ac_ext
52201   if test -z "$lt_cv_aix_libpath_"; then
52202     lt_cv_aix_libpath_="/usr/lib:/lib"
52203   fi
52204
52205 fi
52206
52207   aix_libpath=$lt_cv_aix_libpath_
52208 fi
52209
52210          hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
52211           # Warning - without using the other run time loading flags,
52212           # -berok will link without error, but may produce a broken library.
52213           no_undefined_flag=' ${wl}-bernotok'
52214           allow_undefined_flag=' ${wl}-berok'
52215           if test "$with_gnu_ld" = yes; then
52216             # We only use this code for GNU lds that support --whole-archive.
52217             whole_archive_flag_spec='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
52218           else
52219             # Exported symbols can be pulled into shared objects from archives
52220             whole_archive_flag_spec='$convenience'
52221           fi
52222           archive_cmds_need_lc=yes
52223           # This is similar to how AIX traditionally builds its shared libraries.
52224           archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
52225         fi
52226       fi
52227       ;;
52228
52229     amigaos*)
52230       case $host_cpu in
52231       powerpc)
52232             # see comment about AmigaOS4 .so support
52233             archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
52234             archive_expsym_cmds=''
52235         ;;
52236       m68k)
52237             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)'
52238             hardcode_libdir_flag_spec='-L$libdir'
52239             hardcode_minus_L=yes
52240         ;;
52241       esac
52242       ;;
52243
52244     bsdi[45]*)
52245       export_dynamic_flag_spec=-rdynamic
52246       ;;
52247
52248     cygwin* | mingw* | pw32* | cegcc*)
52249       # When not using gcc, we currently assume that we are using
52250       # Microsoft Visual C++.
52251       # hardcode_libdir_flag_spec is actually meaningless, as there is
52252       # no search path for DLLs.
52253       case $cc_basename in
52254       cl*)
52255         # Native MSVC
52256         hardcode_libdir_flag_spec=' '
52257         allow_undefined_flag=unsupported
52258         always_export_symbols=yes
52259         file_list_spec='@'
52260         # Tell ltmain to make .lib files, not .a files.
52261         libext=lib
52262         # Tell ltmain to make .dll files, not .so files.
52263         shrext_cmds=".dll"
52264         # FIXME: Setting linknames here is a bad hack.
52265         archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
52266         archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
52267             sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
52268           else
52269             sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
52270           fi~
52271           $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
52272           linknames='
52273         # The linker will not automatically build a static lib if we build a DLL.
52274         # _LT_TAGVAR(old_archive_from_new_cmds, )='true'
52275         enable_shared_with_static_runtimes=yes
52276         exclude_expsyms='_NULL_IMPORT_DESCRIPTOR|_IMPORT_DESCRIPTOR_.*'
52277         export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
52278         # Don't use ranlib
52279         old_postinstall_cmds='chmod 644 $oldlib'
52280         postlink_cmds='lt_outputfile="@OUTPUT@"~
52281           lt_tool_outputfile="@TOOL_OUTPUT@"~
52282           case $lt_outputfile in
52283             *.exe|*.EXE) ;;
52284             *)
52285               lt_outputfile="$lt_outputfile.exe"
52286               lt_tool_outputfile="$lt_tool_outputfile.exe"
52287               ;;
52288           esac~
52289           if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
52290             $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
52291             $RM "$lt_outputfile.manifest";
52292           fi'
52293         ;;
52294       *)
52295         # Assume MSVC wrapper
52296         hardcode_libdir_flag_spec=' '
52297         allow_undefined_flag=unsupported
52298         # Tell ltmain to make .lib files, not .a files.
52299         libext=lib
52300         # Tell ltmain to make .dll files, not .so files.
52301         shrext_cmds=".dll"
52302         # FIXME: Setting linknames here is a bad hack.
52303         archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
52304         # The linker will automatically build a .lib file if we build a DLL.
52305         old_archive_from_new_cmds='true'
52306         # FIXME: Should let the user specify the lib program.
52307         old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
52308         enable_shared_with_static_runtimes=yes
52309         ;;
52310       esac
52311       ;;
52312
52313     darwin* | rhapsody*)
52314
52315
52316   archive_cmds_need_lc=no
52317   hardcode_direct=no
52318   hardcode_automatic=yes
52319   hardcode_shlibpath_var=unsupported
52320   if test "$lt_cv_ld_force_load" = "yes"; then
52321     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\"`'
52322
52323   else
52324     whole_archive_flag_spec=''
52325   fi
52326   link_all_deplibs=yes
52327   allow_undefined_flag="$_lt_dar_allow_undefined"
52328   case $cc_basename in
52329      ifort*) _lt_dar_can_shared=yes ;;
52330      *) _lt_dar_can_shared=$GCC ;;
52331   esac
52332   if test "$_lt_dar_can_shared" = "yes"; then
52333     output_verbose_link_cmd=func_echo_all
52334     archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
52335     module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
52336     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}"
52337     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}"
52338
52339   else
52340   ld_shlibs=no
52341   fi
52342
52343       ;;
52344
52345     dgux*)
52346       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
52347       hardcode_libdir_flag_spec='-L$libdir'
52348       hardcode_shlibpath_var=no
52349       ;;
52350
52351     # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
52352     # support.  Future versions do this automatically, but an explicit c++rt0.o
52353     # does not break anything, and helps significantly (at the cost of a little
52354     # extra space).
52355     freebsd2.2*)
52356       archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
52357       hardcode_libdir_flag_spec='-R$libdir'
52358       hardcode_direct=yes
52359       hardcode_shlibpath_var=no
52360       ;;
52361
52362     # Unfortunately, older versions of FreeBSD 2 do not have this feature.
52363     freebsd2.*)
52364       archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
52365       hardcode_direct=yes
52366       hardcode_minus_L=yes
52367       hardcode_shlibpath_var=no
52368       ;;
52369
52370     # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
52371     freebsd* | dragonfly*)
52372       archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
52373       hardcode_libdir_flag_spec='-R$libdir'
52374       hardcode_direct=yes
52375       hardcode_shlibpath_var=no
52376       ;;
52377
52378     hpux9*)
52379       if test "$GCC" = yes; then
52380         archive_cmds='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
52381       else
52382         archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
52383       fi
52384       hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
52385       hardcode_libdir_separator=:
52386       hardcode_direct=yes
52387
52388       # hardcode_minus_L: Not really in the search PATH,
52389       # but as the default location of the library.
52390       hardcode_minus_L=yes
52391       export_dynamic_flag_spec='${wl}-E'
52392       ;;
52393
52394     hpux10*)
52395       if test "$GCC" = yes && test "$with_gnu_ld" = no; then
52396         archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
52397       else
52398         archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
52399       fi
52400       if test "$with_gnu_ld" = no; then
52401         hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
52402         hardcode_libdir_separator=:
52403         hardcode_direct=yes
52404         hardcode_direct_absolute=yes
52405         export_dynamic_flag_spec='${wl}-E'
52406         # hardcode_minus_L: Not really in the search PATH,
52407         # but as the default location of the library.
52408         hardcode_minus_L=yes
52409       fi
52410       ;;
52411
52412     hpux11*)
52413       if test "$GCC" = yes && test "$with_gnu_ld" = no; then
52414         case $host_cpu in
52415         hppa*64*)
52416           archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
52417           ;;
52418         ia64*)
52419           archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
52420           ;;
52421         *)
52422           archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
52423           ;;
52424         esac
52425       else
52426         case $host_cpu in
52427         hppa*64*)
52428           archive_cmds='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
52429           ;;
52430         ia64*)
52431           archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
52432           ;;
52433         *)
52434
52435           # Older versions of the 11.00 compiler do not understand -b yet
52436           # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
52437           { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5
52438 $as_echo_n "checking if $CC understands -b... " >&6; }
52439 if ${lt_cv_prog_compiler__b+:} false; then :
52440   $as_echo_n "(cached) " >&6
52441 else
52442   lt_cv_prog_compiler__b=no
52443    save_LDFLAGS="$LDFLAGS"
52444    LDFLAGS="$LDFLAGS -b"
52445    echo "$lt_simple_link_test_code" > conftest.$ac_ext
52446    if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
52447      # The linker can only warn and ignore the option if not recognized
52448      # So say no if there are warnings
52449      if test -s conftest.err; then
52450        # Append any errors to the config.log.
52451        cat conftest.err 1>&5
52452        $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
52453        $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
52454        if diff conftest.exp conftest.er2 >/dev/null; then
52455          lt_cv_prog_compiler__b=yes
52456        fi
52457      else
52458        lt_cv_prog_compiler__b=yes
52459      fi
52460    fi
52461    $RM -r conftest*
52462    LDFLAGS="$save_LDFLAGS"
52463
52464 fi
52465 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5
52466 $as_echo "$lt_cv_prog_compiler__b" >&6; }
52467
52468 if test x"$lt_cv_prog_compiler__b" = xyes; then
52469     archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
52470 else
52471     archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
52472 fi
52473
52474           ;;
52475         esac
52476       fi
52477       if test "$with_gnu_ld" = no; then
52478         hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
52479         hardcode_libdir_separator=:
52480
52481         case $host_cpu in
52482         hppa*64*|ia64*)
52483           hardcode_direct=no
52484           hardcode_shlibpath_var=no
52485           ;;
52486         *)
52487           hardcode_direct=yes
52488           hardcode_direct_absolute=yes
52489           export_dynamic_flag_spec='${wl}-E'
52490
52491           # hardcode_minus_L: Not really in the search PATH,
52492           # but as the default location of the library.
52493           hardcode_minus_L=yes
52494           ;;
52495         esac
52496       fi
52497       ;;
52498
52499     irix5* | irix6* | nonstopux*)
52500       if test "$GCC" = yes; then
52501         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'
52502         # Try to use the -exported_symbol ld option, if it does not
52503         # work, assume that -exports_file does not work either and
52504         # implicitly export all symbols.
52505         # This should be the same for all languages, so no per-tag cache variable.
52506         { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
52507 $as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
52508 if ${lt_cv_irix_exported_symbol+:} false; then :
52509   $as_echo_n "(cached) " >&6
52510 else
52511   save_LDFLAGS="$LDFLAGS"
52512            LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
52513            cat confdefs.h - <<_ACEOF >conftest.$ac_ext
52514 /* end confdefs.h.  */
52515 int foo (void) { return 0; }
52516 _ACEOF
52517 if ac_fn_c_try_link "$LINENO"; then :
52518   lt_cv_irix_exported_symbol=yes
52519 else
52520   lt_cv_irix_exported_symbol=no
52521 fi
52522 rm -f core conftest.err conftest.$ac_objext \
52523     conftest$ac_exeext conftest.$ac_ext
52524            LDFLAGS="$save_LDFLAGS"
52525 fi
52526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5
52527 $as_echo "$lt_cv_irix_exported_symbol" >&6; }
52528         if test "$lt_cv_irix_exported_symbol" = yes; then
52529           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'
52530         fi
52531       else
52532         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'
52533         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'
52534       fi
52535       archive_cmds_need_lc='no'
52536       hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
52537       hardcode_libdir_separator=:
52538       inherit_rpath=yes
52539       link_all_deplibs=yes
52540       ;;
52541
52542     netbsd*)
52543       if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
52544         archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'  # a.out
52545       else
52546         archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags'      # ELF
52547       fi
52548       hardcode_libdir_flag_spec='-R$libdir'
52549       hardcode_direct=yes
52550       hardcode_shlibpath_var=no
52551       ;;
52552
52553     newsos6)
52554       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
52555       hardcode_direct=yes
52556       hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
52557       hardcode_libdir_separator=:
52558       hardcode_shlibpath_var=no
52559       ;;
52560
52561     *nto* | *qnx*)
52562       ;;
52563
52564     openbsd*)
52565       if test -f /usr/libexec/ld.so; then
52566         hardcode_direct=yes
52567         hardcode_shlibpath_var=no
52568         hardcode_direct_absolute=yes
52569         if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
52570           archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
52571           archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
52572           hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
52573           export_dynamic_flag_spec='${wl}-E'
52574         else
52575           case $host_os in
52576            openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
52577              archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
52578              hardcode_libdir_flag_spec='-R$libdir'
52579              ;;
52580            *)
52581              archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
52582              hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
52583              ;;
52584           esac
52585         fi
52586       else
52587         ld_shlibs=no
52588       fi
52589       ;;
52590
52591     os2*)
52592       hardcode_libdir_flag_spec='-L$libdir'
52593       hardcode_minus_L=yes
52594       allow_undefined_flag=unsupported
52595       archive_cmds='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
52596       old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
52597       ;;
52598
52599     osf3*)
52600       if test "$GCC" = yes; then
52601         allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
52602         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'
52603       else
52604         allow_undefined_flag=' -expect_unresolved \*'
52605         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'
52606       fi
52607       archive_cmds_need_lc='no'
52608       hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
52609       hardcode_libdir_separator=:
52610       ;;
52611
52612     osf4* | osf5*)      # as osf3* with the addition of -msym flag
52613       if test "$GCC" = yes; then
52614         allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
52615         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'
52616         hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
52617       else
52618         allow_undefined_flag=' -expect_unresolved \*'
52619         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'
52620         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~
52621         $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'
52622
52623         # Both c and cxx compiler support -rpath directly
52624         hardcode_libdir_flag_spec='-rpath $libdir'
52625       fi
52626       archive_cmds_need_lc='no'
52627       hardcode_libdir_separator=:
52628       ;;
52629
52630     solaris*)
52631       no_undefined_flag=' -z defs'
52632       if test "$GCC" = yes; then
52633         wlarc='${wl}'
52634         archive_cmds='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
52635         archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
52636           $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'
52637       else
52638         case `$CC -V 2>&1` in
52639         *"Compilers 5.0"*)
52640           wlarc=''
52641           archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
52642           archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
52643           $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
52644           ;;
52645         *)
52646           wlarc='${wl}'
52647           archive_cmds='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags'
52648           archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
52649           $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
52650           ;;
52651         esac
52652       fi
52653       hardcode_libdir_flag_spec='-R$libdir'
52654       hardcode_shlibpath_var=no
52655       case $host_os in
52656       solaris2.[0-5] | solaris2.[0-5].*) ;;
52657       *)
52658         # The compiler driver will combine and reorder linker options,
52659         # but understands `-z linker_flag'.  GCC discards it without `$wl',
52660         # but is careful enough not to reorder.
52661         # Supported since Solaris 2.6 (maybe 2.5.1?)
52662         if test "$GCC" = yes; then
52663           whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
52664         else
52665           whole_archive_flag_spec='-z allextract$convenience -z defaultextract'
52666         fi
52667         ;;
52668       esac
52669       link_all_deplibs=yes
52670       ;;
52671
52672     sunos4*)
52673       if test "x$host_vendor" = xsequent; then
52674         # Use $CC to link under sequent, because it throws in some extra .o
52675         # files that make .init and .fini sections work.
52676         archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
52677       else
52678         archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
52679       fi
52680       hardcode_libdir_flag_spec='-L$libdir'
52681       hardcode_direct=yes
52682       hardcode_minus_L=yes
52683       hardcode_shlibpath_var=no
52684       ;;
52685
52686     sysv4)
52687       case $host_vendor in
52688         sni)
52689           archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
52690           hardcode_direct=yes # is this really true???
52691         ;;
52692         siemens)
52693           ## LD is ld it makes a PLAMLIB
52694           ## CC just makes a GrossModule.
52695           archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
52696           reload_cmds='$CC -r -o $output$reload_objs'
52697           hardcode_direct=no
52698         ;;
52699         motorola)
52700           archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
52701           hardcode_direct=no #Motorola manual says yes, but my tests say they lie
52702         ;;
52703       esac
52704       runpath_var='LD_RUN_PATH'
52705       hardcode_shlibpath_var=no
52706       ;;
52707
52708     sysv4.3*)
52709       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
52710       hardcode_shlibpath_var=no
52711       export_dynamic_flag_spec='-Bexport'
52712       ;;
52713
52714     sysv4*MP*)
52715       if test -d /usr/nec; then
52716         archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
52717         hardcode_shlibpath_var=no
52718         runpath_var=LD_RUN_PATH
52719         hardcode_runpath_var=yes
52720         ld_shlibs=yes
52721       fi
52722       ;;
52723
52724     sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
52725       no_undefined_flag='${wl}-z,text'
52726       archive_cmds_need_lc=no
52727       hardcode_shlibpath_var=no
52728       runpath_var='LD_RUN_PATH'
52729
52730       if test "$GCC" = yes; then
52731         archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
52732         archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
52733       else
52734         archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
52735         archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
52736       fi
52737       ;;
52738
52739     sysv5* | sco3.2v5* | sco5v6*)
52740       # Note: We can NOT use -z defs as we might desire, because we do not
52741       # link with -lc, and that would cause any symbols used from libc to
52742       # always be unresolved, which means just about no library would
52743       # ever link correctly.  If we're not using GNU ld we use -z text
52744       # though, which does catch some bad symbols but isn't as heavy-handed
52745       # as -z defs.
52746       no_undefined_flag='${wl}-z,text'
52747       allow_undefined_flag='${wl}-z,nodefs'
52748       archive_cmds_need_lc=no
52749       hardcode_shlibpath_var=no
52750       hardcode_libdir_flag_spec='${wl}-R,$libdir'
52751       hardcode_libdir_separator=':'
52752       link_all_deplibs=yes
52753       export_dynamic_flag_spec='${wl}-Bexport'
52754       runpath_var='LD_RUN_PATH'
52755
52756       if test "$GCC" = yes; then
52757         archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
52758         archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
52759       else
52760         archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
52761         archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
52762       fi
52763       ;;
52764
52765     uts4*)
52766       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
52767       hardcode_libdir_flag_spec='-L$libdir'
52768       hardcode_shlibpath_var=no
52769       ;;
52770
52771     *)
52772       ld_shlibs=no
52773       ;;
52774     esac
52775
52776     if test x$host_vendor = xsni; then
52777       case $host in
52778       sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
52779         export_dynamic_flag_spec='${wl}-Blargedynsym'
52780         ;;
52781       esac
52782     fi
52783   fi
52784
52785 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5
52786 $as_echo "$ld_shlibs" >&6; }
52787 test "$ld_shlibs" = no && can_build_shared=no
52788
52789 with_gnu_ld=$with_gnu_ld
52790
52791
52792
52793
52794
52795
52796
52797
52798
52799
52800
52801
52802
52803
52804
52805 #
52806 # Do we need to explicitly link libc?
52807 #
52808 case "x$archive_cmds_need_lc" in
52809 x|xyes)
52810   # Assume -lc should be added
52811   archive_cmds_need_lc=yes
52812
52813   if test "$enable_shared" = yes && test "$GCC" = yes; then
52814     case $archive_cmds in
52815     *'~'*)
52816       # FIXME: we may have to deal with multi-command sequences.
52817       ;;
52818     '$CC '*)
52819       # Test whether the compiler implicitly links with -lc since on some
52820       # systems, -lgcc has to come before -lc. If gcc already passes -lc
52821       # to ld, don't add -lc before -lgcc.
52822       { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
52823 $as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
52824 if ${lt_cv_archive_cmds_need_lc+:} false; then :
52825   $as_echo_n "(cached) " >&6
52826 else
52827   $RM conftest*
52828         echo "$lt_simple_compile_test_code" > conftest.$ac_ext
52829
52830         if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
52831   (eval $ac_compile) 2>&5
52832   ac_status=$?
52833   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
52834   test $ac_status = 0; } 2>conftest.err; then
52835           soname=conftest
52836           lib=conftest
52837           libobjs=conftest.$ac_objext
52838           deplibs=
52839           wl=$lt_prog_compiler_wl
52840           pic_flag=$lt_prog_compiler_pic
52841           compiler_flags=-v
52842           linker_flags=-v
52843           verstring=
52844           output_objdir=.
52845           libname=conftest
52846           lt_save_allow_undefined_flag=$allow_undefined_flag
52847           allow_undefined_flag=
52848           if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
52849   (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
52850   ac_status=$?
52851   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
52852   test $ac_status = 0; }
52853           then
52854             lt_cv_archive_cmds_need_lc=no
52855           else
52856             lt_cv_archive_cmds_need_lc=yes
52857           fi
52858           allow_undefined_flag=$lt_save_allow_undefined_flag
52859         else
52860           cat conftest.err 1>&5
52861         fi
52862         $RM conftest*
52863
52864 fi
52865 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5
52866 $as_echo "$lt_cv_archive_cmds_need_lc" >&6; }
52867       archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc
52868       ;;
52869     esac
52870   fi
52871   ;;
52872 esac
52873
52874
52875
52876
52877
52878
52879
52880
52881
52882
52883
52884
52885
52886
52887
52888
52889
52890
52891
52892
52893
52894
52895
52896
52897
52898
52899
52900
52901
52902
52903
52904
52905
52906
52907
52908
52909
52910
52911
52912
52913
52914
52915
52916
52917
52918
52919
52920
52921
52922
52923
52924
52925
52926
52927
52928
52929
52930
52931
52932
52933
52934
52935
52936
52937
52938
52939
52940
52941
52942
52943
52944
52945
52946
52947
52948
52949
52950
52951
52952
52953
52954
52955
52956
52957
52958
52959
52960
52961
52962
52963
52964
52965
52966
52967
52968
52969
52970
52971
52972
52973
52974
52975
52976
52977
52978
52979
52980
52981
52982
52983
52984
52985
52986
52987
52988
52989
52990
52991
52992
52993
52994
52995
52996
52997
52998
52999
53000
53001
53002
53003
53004
53005
53006
53007
53008
53009
53010
53011
53012
53013
53014
53015
53016
53017
53018
53019
53020
53021
53022
53023
53024
53025   { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
53026 $as_echo_n "checking dynamic linker characteristics... " >&6; }
53027
53028 if test "$GCC" = yes; then
53029   case $host_os in
53030     darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
53031     *) lt_awk_arg="/^libraries:/" ;;
53032   esac
53033   case $host_os in
53034     mingw* | cegcc*) lt_sed_strip_eq="s,=\([A-Za-z]:\),\1,g" ;;
53035     *) lt_sed_strip_eq="s,=/,/,g" ;;
53036   esac
53037   lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
53038   case $lt_search_path_spec in
53039   *\;*)
53040     # if the path contains ";" then we assume it to be the separator
53041     # otherwise default to the standard path separator (i.e. ":") - it is
53042     # assumed that no part of a normal pathname contains ";" but that should
53043     # okay in the real world where ";" in dirpaths is itself problematic.
53044     lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
53045     ;;
53046   *)
53047     lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
53048     ;;
53049   esac
53050   # Ok, now we have the path, separated by spaces, we can step through it
53051   # and add multilib dir if necessary.
53052   lt_tmp_lt_search_path_spec=
53053   lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
53054   for lt_sys_path in $lt_search_path_spec; do
53055     if test -d "$lt_sys_path/$lt_multi_os_dir"; then
53056       lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
53057     else
53058       test -d "$lt_sys_path" && \
53059         lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
53060     fi
53061   done
53062   lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
53063 BEGIN {RS=" "; FS="/|\n";} {
53064   lt_foo="";
53065   lt_count=0;
53066   for (lt_i = NF; lt_i > 0; lt_i--) {
53067     if ($lt_i != "" && $lt_i != ".") {
53068       if ($lt_i == "..") {
53069         lt_count++;
53070       } else {
53071         if (lt_count == 0) {
53072           lt_foo="/" $lt_i lt_foo;
53073         } else {
53074           lt_count--;
53075         }
53076       }
53077     }
53078   }
53079   if (lt_foo != "") { lt_freq[lt_foo]++; }
53080   if (lt_freq[lt_foo] == 1) { print lt_foo; }
53081 }'`
53082   # AWK program above erroneously prepends '/' to C:/dos/paths
53083   # for these hosts.
53084   case $host_os in
53085     mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
53086       $SED 's,/\([A-Za-z]:\),\1,g'` ;;
53087   esac
53088   sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
53089 else
53090   sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
53091 fi
53092 library_names_spec=
53093 libname_spec='lib$name'
53094 soname_spec=
53095 shrext_cmds=".so"
53096 postinstall_cmds=
53097 postuninstall_cmds=
53098 finish_cmds=
53099 finish_eval=
53100 shlibpath_var=
53101 shlibpath_overrides_runpath=unknown
53102 version_type=none
53103 dynamic_linker="$host_os ld.so"
53104 sys_lib_dlsearch_path_spec="/lib /usr/lib"
53105 need_lib_prefix=unknown
53106 hardcode_into_libs=no
53107
53108 # when you set need_version to no, make sure it does not cause -set_version
53109 # flags to be left without arguments
53110 need_version=unknown
53111
53112 case $host_os in
53113 aix3*)
53114   version_type=linux # correct to gnu/linux during the next big refactor
53115   library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
53116   shlibpath_var=LIBPATH
53117
53118   # AIX 3 has no versioning support, so we append a major version to the name.
53119   soname_spec='${libname}${release}${shared_ext}$major'
53120   ;;
53121
53122 aix[4-9]*)
53123   version_type=linux # correct to gnu/linux during the next big refactor
53124   need_lib_prefix=no
53125   need_version=no
53126   hardcode_into_libs=yes
53127   if test "$host_cpu" = ia64; then
53128     # AIX 5 supports IA64
53129     library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
53130     shlibpath_var=LD_LIBRARY_PATH
53131   else
53132     # With GCC up to 2.95.x, collect2 would create an import file
53133     # for dependence libraries.  The import file would start with
53134     # the line `#! .'.  This would cause the generated library to
53135     # depend on `.', always an invalid library.  This was fixed in
53136     # development snapshots of GCC prior to 3.0.
53137     case $host_os in
53138       aix4 | aix4.[01] | aix4.[01].*)
53139       if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
53140            echo ' yes '
53141            echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
53142         :
53143       else
53144         can_build_shared=no
53145       fi
53146       ;;
53147     esac
53148     # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
53149     # soname into executable. Probably we can add versioning support to
53150     # collect2, so additional links can be useful in future.
53151     if test "$aix_use_runtimelinking" = yes; then
53152       # If using run time linking (on AIX 4.2 or later) use lib<name>.so
53153       # instead of lib<name>.a to let people know that these are not
53154       # typical AIX shared libraries.
53155       library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
53156     else
53157       # We preserve .a as extension for shared libraries through AIX4.2
53158       # and later when we are not doing run time linking.
53159       library_names_spec='${libname}${release}.a $libname.a'
53160       soname_spec='${libname}${release}${shared_ext}$major'
53161     fi
53162     shlibpath_var=LIBPATH
53163   fi
53164   ;;
53165
53166 amigaos*)
53167   case $host_cpu in
53168   powerpc)
53169     # Since July 2007 AmigaOS4 officially supports .so libraries.
53170     # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
53171     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
53172     ;;
53173   m68k)
53174     library_names_spec='$libname.ixlibrary $libname.a'
53175     # Create ${libname}_ixlibrary.a entries in /sys/libs.
53176     finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $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'
53177     ;;
53178   esac
53179   ;;
53180
53181 beos*)
53182   library_names_spec='${libname}${shared_ext}'
53183   dynamic_linker="$host_os ld.so"
53184   shlibpath_var=LIBRARY_PATH
53185   ;;
53186
53187 bsdi[45]*)
53188   version_type=linux # correct to gnu/linux during the next big refactor
53189   need_version=no
53190   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
53191   soname_spec='${libname}${release}${shared_ext}$major'
53192   finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
53193   shlibpath_var=LD_LIBRARY_PATH
53194   sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
53195   sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
53196   # the default ld.so.conf also contains /usr/contrib/lib and
53197   # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
53198   # libtool to hard-code these into programs
53199   ;;
53200
53201 cygwin* | mingw* | pw32* | cegcc*)
53202   version_type=windows
53203   shrext_cmds=".dll"
53204   need_version=no
53205   need_lib_prefix=no
53206
53207   case $GCC,$cc_basename in
53208   yes,*)
53209     # gcc
53210     library_names_spec='$libname.dll.a'
53211     # DLL is installed to $(libdir)/../bin by postinstall_cmds
53212     postinstall_cmds='base_file=`basename \${file}`~
53213       dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
53214       dldir=$destdir/`dirname \$dlpath`~
53215       test -d \$dldir || mkdir -p \$dldir~
53216       $install_prog $dir/$dlname \$dldir/$dlname~
53217       chmod a+x \$dldir/$dlname~
53218       if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
53219         eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
53220       fi'
53221     postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
53222       dlpath=$dir/\$dldll~
53223        $RM \$dlpath'
53224     shlibpath_overrides_runpath=yes
53225
53226     case $host_os in
53227     cygwin*)
53228       # Cygwin DLLs use 'cyg' prefix rather than 'lib'
53229       soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
53230
53231       sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"
53232       ;;
53233     mingw* | cegcc*)
53234       # MinGW DLLs use traditional 'lib' prefix
53235       soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
53236       ;;
53237     pw32*)
53238       # pw32 DLLs use 'pw' prefix rather than 'lib'
53239       library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
53240       ;;
53241     esac
53242     dynamic_linker='Win32 ld.exe'
53243     ;;
53244
53245   *,cl*)
53246     # Native MSVC
53247     libname_spec='$name'
53248     soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
53249     library_names_spec='${libname}.dll.lib'
53250
53251     case $build_os in
53252     mingw*)
53253       sys_lib_search_path_spec=
53254       lt_save_ifs=$IFS
53255       IFS=';'
53256       for lt_path in $LIB
53257       do
53258         IFS=$lt_save_ifs
53259         # Let DOS variable expansion print the short 8.3 style file name.
53260         lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
53261         sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
53262       done
53263       IFS=$lt_save_ifs
53264       # Convert to MSYS style.
53265       sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'`
53266       ;;
53267     cygwin*)
53268       # Convert to unix form, then to dos form, then back to unix form
53269       # but this time dos style (no spaces!) so that the unix form looks
53270       # like /cygdrive/c/PROGRA~1:/cygdr...
53271       sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
53272       sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
53273       sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
53274       ;;
53275     *)
53276       sys_lib_search_path_spec="$LIB"
53277       if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
53278         # It is most probably a Windows format PATH.
53279         sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
53280       else
53281         sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
53282       fi
53283       # FIXME: find the short name or the path components, as spaces are
53284       # common. (e.g. "Program Files" -> "PROGRA~1")
53285       ;;
53286     esac
53287
53288     # DLL is installed to $(libdir)/../bin by postinstall_cmds
53289     postinstall_cmds='base_file=`basename \${file}`~
53290       dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
53291       dldir=$destdir/`dirname \$dlpath`~
53292       test -d \$dldir || mkdir -p \$dldir~
53293       $install_prog $dir/$dlname \$dldir/$dlname'
53294     postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
53295       dlpath=$dir/\$dldll~
53296        $RM \$dlpath'
53297     shlibpath_overrides_runpath=yes
53298     dynamic_linker='Win32 link.exe'
53299     ;;
53300
53301   *)
53302     # Assume MSVC wrapper
53303     library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
53304     dynamic_linker='Win32 ld.exe'
53305     ;;
53306   esac
53307   # FIXME: first we should search . and the directory the executable is in
53308   shlibpath_var=PATH
53309   ;;
53310
53311 darwin* | rhapsody*)
53312   dynamic_linker="$host_os dyld"
53313   version_type=darwin
53314   need_lib_prefix=no
53315   need_version=no
53316   library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
53317   soname_spec='${libname}${release}${major}$shared_ext'
53318   shlibpath_overrides_runpath=yes
53319   shlibpath_var=DYLD_LIBRARY_PATH
53320   shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
53321
53322   sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"
53323   sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
53324   ;;
53325
53326 dgux*)
53327   version_type=linux # correct to gnu/linux during the next big refactor
53328   need_lib_prefix=no
53329   need_version=no
53330   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
53331   soname_spec='${libname}${release}${shared_ext}$major'
53332   shlibpath_var=LD_LIBRARY_PATH
53333   ;;
53334
53335 freebsd* | dragonfly*)
53336   # DragonFly does not have aout.  When/if they implement a new
53337   # versioning mechanism, adjust this.
53338   if test -x /usr/bin/objformat; then
53339     objformat=`/usr/bin/objformat`
53340   else
53341     case $host_os in
53342     freebsd[23].*) objformat=aout ;;
53343     *) objformat=elf ;;
53344     esac
53345   fi
53346   version_type=freebsd-$objformat
53347   case $version_type in
53348     freebsd-elf*)
53349       library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
53350       need_version=no
53351       need_lib_prefix=no
53352       ;;
53353     freebsd-*)
53354       library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
53355       need_version=yes
53356       ;;
53357   esac
53358   shlibpath_var=LD_LIBRARY_PATH
53359   case $host_os in
53360   freebsd2.*)
53361     shlibpath_overrides_runpath=yes
53362     ;;
53363   freebsd3.[01]* | freebsdelf3.[01]*)
53364     shlibpath_overrides_runpath=yes
53365     hardcode_into_libs=yes
53366     ;;
53367   freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
53368   freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
53369     shlibpath_overrides_runpath=no
53370     hardcode_into_libs=yes
53371     ;;
53372   *) # from 4.6 on, and DragonFly
53373     shlibpath_overrides_runpath=yes
53374     hardcode_into_libs=yes
53375     ;;
53376   esac
53377   ;;
53378
53379 gnu*)
53380   version_type=linux # correct to gnu/linux during the next big refactor
53381   need_lib_prefix=no
53382   need_version=no
53383   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
53384   soname_spec='${libname}${release}${shared_ext}$major'
53385   shlibpath_var=LD_LIBRARY_PATH
53386   shlibpath_overrides_runpath=no
53387   hardcode_into_libs=yes
53388   ;;
53389
53390 haiku*)
53391   version_type=linux # correct to gnu/linux during the next big refactor
53392   need_lib_prefix=no
53393   need_version=no
53394   dynamic_linker="$host_os runtime_loader"
53395   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
53396   soname_spec='${libname}${release}${shared_ext}$major'
53397   shlibpath_var=LIBRARY_PATH
53398   shlibpath_overrides_runpath=yes
53399   sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
53400   hardcode_into_libs=yes
53401   ;;
53402
53403 hpux9* | hpux10* | hpux11*)
53404   # Give a soname corresponding to the major version so that dld.sl refuses to
53405   # link against other versions.
53406   version_type=sunos
53407   need_lib_prefix=no
53408   need_version=no
53409   case $host_cpu in
53410   ia64*)
53411     shrext_cmds='.so'
53412     hardcode_into_libs=yes
53413     dynamic_linker="$host_os dld.so"
53414     shlibpath_var=LD_LIBRARY_PATH
53415     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
53416     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
53417     soname_spec='${libname}${release}${shared_ext}$major'
53418     if test "X$HPUX_IA64_MODE" = X32; then
53419       sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
53420     else
53421       sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
53422     fi
53423     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
53424     ;;
53425   hppa*64*)
53426     shrext_cmds='.sl'
53427     hardcode_into_libs=yes
53428     dynamic_linker="$host_os dld.sl"
53429     shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
53430     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
53431     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
53432     soname_spec='${libname}${release}${shared_ext}$major'
53433     sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
53434     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
53435     ;;
53436   *)
53437     shrext_cmds='.sl'
53438     dynamic_linker="$host_os dld.sl"
53439     shlibpath_var=SHLIB_PATH
53440     shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
53441     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
53442     soname_spec='${libname}${release}${shared_ext}$major'
53443     ;;
53444   esac
53445   # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
53446   postinstall_cmds='chmod 555 $lib'
53447   # or fails outright, so override atomically:
53448   install_override_mode=555
53449   ;;
53450
53451 interix[3-9]*)
53452   version_type=linux # correct to gnu/linux during the next big refactor
53453   need_lib_prefix=no
53454   need_version=no
53455   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
53456   soname_spec='${libname}${release}${shared_ext}$major'
53457   dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
53458   shlibpath_var=LD_LIBRARY_PATH
53459   shlibpath_overrides_runpath=no
53460   hardcode_into_libs=yes
53461   ;;
53462
53463 irix5* | irix6* | nonstopux*)
53464   case $host_os in
53465     nonstopux*) version_type=nonstopux ;;
53466     *)
53467         if test "$lt_cv_prog_gnu_ld" = yes; then
53468                 version_type=linux # correct to gnu/linux during the next big refactor
53469         else
53470                 version_type=irix
53471         fi ;;
53472   esac
53473   need_lib_prefix=no
53474   need_version=no
53475   soname_spec='${libname}${release}${shared_ext}$major'
53476   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
53477   case $host_os in
53478   irix5* | nonstopux*)
53479     libsuff= shlibsuff=
53480     ;;
53481   *)
53482     case $LD in # libtool.m4 will add one of these switches to LD
53483     *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
53484       libsuff= shlibsuff= libmagic=32-bit;;
53485     *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
53486       libsuff=32 shlibsuff=N32 libmagic=N32;;
53487     *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
53488       libsuff=64 shlibsuff=64 libmagic=64-bit;;
53489     *) libsuff= shlibsuff= libmagic=never-match;;
53490     esac
53491     ;;
53492   esac
53493   shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
53494   shlibpath_overrides_runpath=no
53495   sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
53496   sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
53497   hardcode_into_libs=yes
53498   ;;
53499
53500 # No shared lib support for Linux oldld, aout, or coff.
53501 linux*oldld* | linux*aout* | linux*coff*)
53502   dynamic_linker=no
53503   ;;
53504
53505 # This must be glibc/ELF.
53506 linux* | k*bsd*-gnu | kopensolaris*-gnu)
53507   version_type=linux # correct to gnu/linux during the next big refactor
53508   need_lib_prefix=no
53509   need_version=no
53510   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
53511   soname_spec='${libname}${release}${shared_ext}$major'
53512   finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
53513   shlibpath_var=LD_LIBRARY_PATH
53514   shlibpath_overrides_runpath=no
53515
53516   # Some binutils ld are patched to set DT_RUNPATH
53517   if ${lt_cv_shlibpath_overrides_runpath+:} false; then :
53518   $as_echo_n "(cached) " >&6
53519 else
53520   lt_cv_shlibpath_overrides_runpath=no
53521     save_LDFLAGS=$LDFLAGS
53522     save_libdir=$libdir
53523     eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \
53524          LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\""
53525     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
53526 /* end confdefs.h.  */
53527
53528 int
53529 main ()
53530 {
53531
53532   ;
53533   return 0;
53534 }
53535 _ACEOF
53536 if ac_fn_c_try_link "$LINENO"; then :
53537   if  ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then :
53538   lt_cv_shlibpath_overrides_runpath=yes
53539 fi
53540 fi
53541 rm -f core conftest.err conftest.$ac_objext \
53542     conftest$ac_exeext conftest.$ac_ext
53543     LDFLAGS=$save_LDFLAGS
53544     libdir=$save_libdir
53545
53546 fi
53547
53548   shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
53549
53550   # This implies no fast_install, which is unacceptable.
53551   # Some rework will be needed to allow for fast_install
53552   # before this can be enabled.
53553   hardcode_into_libs=yes
53554
53555   # Add ABI-specific directories to the system library path.
53556   sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib"
53557
53558   # Append ld.so.conf contents to the search path
53559   if test -f /etc/ld.so.conf; then
53560     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' ' '`
53561     sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra"
53562
53563   fi
53564
53565   # We used to test for /lib/ld.so.1 and disable shared libraries on
53566   # powerpc, because MkLinux only supported shared libraries with the
53567   # GNU dynamic linker.  Since this was broken with cross compilers,
53568   # most powerpc-linux boxes support dynamic linking these days and
53569   # people can always --disable-shared, the test was removed, and we
53570   # assume the GNU/Linux dynamic linker is in use.
53571   dynamic_linker='GNU/Linux ld.so'
53572   ;;
53573
53574 netbsd*)
53575   version_type=sunos
53576   need_lib_prefix=no
53577   need_version=no
53578   if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
53579     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
53580     finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
53581     dynamic_linker='NetBSD (a.out) ld.so'
53582   else
53583     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
53584     soname_spec='${libname}${release}${shared_ext}$major'
53585     dynamic_linker='NetBSD ld.elf_so'
53586   fi
53587   shlibpath_var=LD_LIBRARY_PATH
53588   shlibpath_overrides_runpath=yes
53589   hardcode_into_libs=yes
53590   ;;
53591
53592 newsos6)
53593   version_type=linux # correct to gnu/linux during the next big refactor
53594   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
53595   shlibpath_var=LD_LIBRARY_PATH
53596   shlibpath_overrides_runpath=yes
53597   ;;
53598
53599 *nto* | *qnx*)
53600   version_type=qnx
53601   need_lib_prefix=no
53602   need_version=no
53603   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
53604   soname_spec='${libname}${release}${shared_ext}$major'
53605   shlibpath_var=LD_LIBRARY_PATH
53606   shlibpath_overrides_runpath=no
53607   hardcode_into_libs=yes
53608   dynamic_linker='ldqnx.so'
53609   ;;
53610
53611 openbsd*)
53612   version_type=sunos
53613   sys_lib_dlsearch_path_spec="/usr/lib"
53614   need_lib_prefix=no
53615   # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
53616   case $host_os in
53617     openbsd3.3 | openbsd3.3.*)  need_version=yes ;;
53618     *)                          need_version=no  ;;
53619   esac
53620   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
53621   finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
53622   shlibpath_var=LD_LIBRARY_PATH
53623   if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
53624     case $host_os in
53625       openbsd2.[89] | openbsd2.[89].*)
53626         shlibpath_overrides_runpath=no
53627         ;;
53628       *)
53629         shlibpath_overrides_runpath=yes
53630         ;;
53631       esac
53632   else
53633     shlibpath_overrides_runpath=yes
53634   fi
53635   ;;
53636
53637 os2*)
53638   libname_spec='$name'
53639   shrext_cmds=".dll"
53640   need_lib_prefix=no
53641   library_names_spec='$libname${shared_ext} $libname.a'
53642   dynamic_linker='OS/2 ld.exe'
53643   shlibpath_var=LIBPATH
53644   ;;
53645
53646 osf3* | osf4* | osf5*)
53647   version_type=osf
53648   need_lib_prefix=no
53649   need_version=no
53650   soname_spec='${libname}${release}${shared_ext}$major'
53651   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
53652   shlibpath_var=LD_LIBRARY_PATH
53653   sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
53654   sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
53655   ;;
53656
53657 rdos*)
53658   dynamic_linker=no
53659   ;;
53660
53661 solaris*)
53662   version_type=linux # correct to gnu/linux during the next big refactor
53663   need_lib_prefix=no
53664   need_version=no
53665   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
53666   soname_spec='${libname}${release}${shared_ext}$major'
53667   shlibpath_var=LD_LIBRARY_PATH
53668   shlibpath_overrides_runpath=yes
53669   hardcode_into_libs=yes
53670   # ldd complains unless libraries are executable
53671   postinstall_cmds='chmod +x $lib'
53672   ;;
53673
53674 sunos4*)
53675   version_type=sunos
53676   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
53677   finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
53678   shlibpath_var=LD_LIBRARY_PATH
53679   shlibpath_overrides_runpath=yes
53680   if test "$with_gnu_ld" = yes; then
53681     need_lib_prefix=no
53682   fi
53683   need_version=yes
53684   ;;
53685
53686 sysv4 | sysv4.3*)
53687   version_type=linux # correct to gnu/linux during the next big refactor
53688   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
53689   soname_spec='${libname}${release}${shared_ext}$major'
53690   shlibpath_var=LD_LIBRARY_PATH
53691   case $host_vendor in
53692     sni)
53693       shlibpath_overrides_runpath=no
53694       need_lib_prefix=no
53695       runpath_var=LD_RUN_PATH
53696       ;;
53697     siemens)
53698       need_lib_prefix=no
53699       ;;
53700     motorola)
53701       need_lib_prefix=no
53702       need_version=no
53703       shlibpath_overrides_runpath=no
53704       sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
53705       ;;
53706   esac
53707   ;;
53708
53709 sysv4*MP*)
53710   if test -d /usr/nec ;then
53711     version_type=linux # correct to gnu/linux during the next big refactor
53712     library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
53713     soname_spec='$libname${shared_ext}.$major'
53714     shlibpath_var=LD_LIBRARY_PATH
53715   fi
53716   ;;
53717
53718 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
53719   version_type=freebsd-elf
53720   need_lib_prefix=no
53721   need_version=no
53722   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
53723   soname_spec='${libname}${release}${shared_ext}$major'
53724   shlibpath_var=LD_LIBRARY_PATH
53725   shlibpath_overrides_runpath=yes
53726   hardcode_into_libs=yes
53727   if test "$with_gnu_ld" = yes; then
53728     sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
53729   else
53730     sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
53731     case $host_os in
53732       sco3.2v5*)
53733         sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
53734         ;;
53735     esac
53736   fi
53737   sys_lib_dlsearch_path_spec='/usr/lib'
53738   ;;
53739
53740 tpf*)
53741   # TPF is a cross-target only.  Preferred cross-host = GNU/Linux.
53742   version_type=linux # correct to gnu/linux during the next big refactor
53743   need_lib_prefix=no
53744   need_version=no
53745   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
53746   shlibpath_var=LD_LIBRARY_PATH
53747   shlibpath_overrides_runpath=no
53748   hardcode_into_libs=yes
53749   ;;
53750
53751 uts4*)
53752   version_type=linux # correct to gnu/linux during the next big refactor
53753   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
53754   soname_spec='${libname}${release}${shared_ext}$major'
53755   shlibpath_var=LD_LIBRARY_PATH
53756   ;;
53757
53758 *)
53759   dynamic_linker=no
53760   ;;
53761 esac
53762 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
53763 $as_echo "$dynamic_linker" >&6; }
53764 test "$dynamic_linker" = no && can_build_shared=no
53765
53766 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
53767 if test "$GCC" = yes; then
53768   variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
53769 fi
53770
53771 if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
53772   sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
53773 fi
53774 if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
53775   sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
53776 fi
53777
53778
53779
53780
53781
53782
53783
53784
53785
53786
53787
53788
53789
53790
53791
53792
53793
53794
53795
53796
53797
53798
53799
53800
53801
53802
53803
53804
53805
53806
53807
53808
53809
53810
53811
53812
53813
53814
53815
53816
53817
53818
53819
53820
53821
53822
53823
53824
53825
53826
53827
53828
53829
53830
53831
53832
53833
53834
53835
53836
53837
53838
53839
53840
53841
53842
53843
53844
53845
53846
53847
53848
53849
53850
53851
53852
53853
53854
53855
53856
53857
53858
53859
53860
53861
53862
53863
53864
53865
53866
53867
53868
53869   { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
53870 $as_echo_n "checking how to hardcode library paths into programs... " >&6; }
53871 hardcode_action=
53872 if test -n "$hardcode_libdir_flag_spec" ||
53873    test -n "$runpath_var" ||
53874    test "X$hardcode_automatic" = "Xyes" ; then
53875
53876   # We can hardcode non-existent directories.
53877   if test "$hardcode_direct" != no &&
53878      # If the only mechanism to avoid hardcoding is shlibpath_var, we
53879      # have to relink, otherwise we might link with an installed library
53880      # when we should be linking with a yet-to-be-installed one
53881      ## test "$_LT_TAGVAR(hardcode_shlibpath_var, )" != no &&
53882      test "$hardcode_minus_L" != no; then
53883     # Linking always hardcodes the temporary library directory.
53884     hardcode_action=relink
53885   else
53886     # We can link without hardcoding, and we can hardcode nonexisting dirs.
53887     hardcode_action=immediate
53888   fi
53889 else
53890   # We cannot hardcode anything, or else we can only hardcode existing
53891   # directories.
53892   hardcode_action=unsupported
53893 fi
53894 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5
53895 $as_echo "$hardcode_action" >&6; }
53896
53897 if test "$hardcode_action" = relink ||
53898    test "$inherit_rpath" = yes; then
53899   # Fast installation is not supported
53900   enable_fast_install=no
53901 elif test "$shlibpath_overrides_runpath" = yes ||
53902      test "$enable_shared" = no; then
53903   # Fast installation is not necessary
53904   enable_fast_install=needless
53905 fi
53906
53907
53908
53909
53910
53911
53912   if test "x$enable_dlopen" != xyes; then
53913   enable_dlopen=unknown
53914   enable_dlopen_self=unknown
53915   enable_dlopen_self_static=unknown
53916 else
53917   lt_cv_dlopen=no
53918   lt_cv_dlopen_libs=
53919
53920   case $host_os in
53921   beos*)
53922     lt_cv_dlopen="load_add_on"
53923     lt_cv_dlopen_libs=
53924     lt_cv_dlopen_self=yes
53925     ;;
53926
53927   mingw* | pw32* | cegcc*)
53928     lt_cv_dlopen="LoadLibrary"
53929     lt_cv_dlopen_libs=
53930     ;;
53931
53932   cygwin*)
53933     lt_cv_dlopen="dlopen"
53934     lt_cv_dlopen_libs=
53935     ;;
53936
53937   darwin*)
53938   # if libdl is installed we need to link against it
53939     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
53940 $as_echo_n "checking for dlopen in -ldl... " >&6; }
53941 if ${ac_cv_lib_dl_dlopen+:} false; then :
53942   $as_echo_n "(cached) " >&6
53943 else
53944   ac_check_lib_save_LIBS=$LIBS
53945 LIBS="-ldl  $LIBS"
53946 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
53947 /* end confdefs.h.  */
53948
53949 /* Override any GCC internal prototype to avoid an error.
53950    Use char because int might match the return type of a GCC
53951    builtin and then its argument prototype would still apply.  */
53952 #ifdef __cplusplus
53953 extern "C"
53954 #endif
53955 char dlopen ();
53956 int
53957 main ()
53958 {
53959 return dlopen ();
53960   ;
53961   return 0;
53962 }
53963 _ACEOF
53964 if ac_fn_c_try_link "$LINENO"; then :
53965   ac_cv_lib_dl_dlopen=yes
53966 else
53967   ac_cv_lib_dl_dlopen=no
53968 fi
53969 rm -f core conftest.err conftest.$ac_objext \
53970     conftest$ac_exeext conftest.$ac_ext
53971 LIBS=$ac_check_lib_save_LIBS
53972 fi
53973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
53974 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
53975 if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
53976   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
53977 else
53978
53979     lt_cv_dlopen="dyld"
53980     lt_cv_dlopen_libs=
53981     lt_cv_dlopen_self=yes
53982
53983 fi
53984
53985     ;;
53986
53987   *)
53988     ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load"
53989 if test "x$ac_cv_func_shl_load" = xyes; then :
53990   lt_cv_dlopen="shl_load"
53991 else
53992   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
53993 $as_echo_n "checking for shl_load in -ldld... " >&6; }
53994 if ${ac_cv_lib_dld_shl_load+:} false; then :
53995   $as_echo_n "(cached) " >&6
53996 else
53997   ac_check_lib_save_LIBS=$LIBS
53998 LIBS="-ldld  $LIBS"
53999 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
54000 /* end confdefs.h.  */
54001
54002 /* Override any GCC internal prototype to avoid an error.
54003    Use char because int might match the return type of a GCC
54004    builtin and then its argument prototype would still apply.  */
54005 #ifdef __cplusplus
54006 extern "C"
54007 #endif
54008 char shl_load ();
54009 int
54010 main ()
54011 {
54012 return shl_load ();
54013   ;
54014   return 0;
54015 }
54016 _ACEOF
54017 if ac_fn_c_try_link "$LINENO"; then :
54018   ac_cv_lib_dld_shl_load=yes
54019 else
54020   ac_cv_lib_dld_shl_load=no
54021 fi
54022 rm -f core conftest.err conftest.$ac_objext \
54023     conftest$ac_exeext conftest.$ac_ext
54024 LIBS=$ac_check_lib_save_LIBS
54025 fi
54026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
54027 $as_echo "$ac_cv_lib_dld_shl_load" >&6; }
54028 if test "x$ac_cv_lib_dld_shl_load" = xyes; then :
54029   lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"
54030 else
54031   ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
54032 if test "x$ac_cv_func_dlopen" = xyes; then :
54033   lt_cv_dlopen="dlopen"
54034 else
54035   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
54036 $as_echo_n "checking for dlopen in -ldl... " >&6; }
54037 if ${ac_cv_lib_dl_dlopen+:} false; then :
54038   $as_echo_n "(cached) " >&6
54039 else
54040   ac_check_lib_save_LIBS=$LIBS
54041 LIBS="-ldl  $LIBS"
54042 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
54043 /* end confdefs.h.  */
54044
54045 /* Override any GCC internal prototype to avoid an error.
54046    Use char because int might match the return type of a GCC
54047    builtin and then its argument prototype would still apply.  */
54048 #ifdef __cplusplus
54049 extern "C"
54050 #endif
54051 char dlopen ();
54052 int
54053 main ()
54054 {
54055 return dlopen ();
54056   ;
54057   return 0;
54058 }
54059 _ACEOF
54060 if ac_fn_c_try_link "$LINENO"; then :
54061   ac_cv_lib_dl_dlopen=yes
54062 else
54063   ac_cv_lib_dl_dlopen=no
54064 fi
54065 rm -f core conftest.err conftest.$ac_objext \
54066     conftest$ac_exeext conftest.$ac_ext
54067 LIBS=$ac_check_lib_save_LIBS
54068 fi
54069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
54070 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
54071 if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
54072   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
54073 else
54074   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5
54075 $as_echo_n "checking for dlopen in -lsvld... " >&6; }
54076 if ${ac_cv_lib_svld_dlopen+:} false; then :
54077   $as_echo_n "(cached) " >&6
54078 else
54079   ac_check_lib_save_LIBS=$LIBS
54080 LIBS="-lsvld  $LIBS"
54081 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
54082 /* end confdefs.h.  */
54083
54084 /* Override any GCC internal prototype to avoid an error.
54085    Use char because int might match the return type of a GCC
54086    builtin and then its argument prototype would still apply.  */
54087 #ifdef __cplusplus
54088 extern "C"
54089 #endif
54090 char dlopen ();
54091 int
54092 main ()
54093 {
54094 return dlopen ();
54095   ;
54096   return 0;
54097 }
54098 _ACEOF
54099 if ac_fn_c_try_link "$LINENO"; then :
54100   ac_cv_lib_svld_dlopen=yes
54101 else
54102   ac_cv_lib_svld_dlopen=no
54103 fi
54104 rm -f core conftest.err conftest.$ac_objext \
54105     conftest$ac_exeext conftest.$ac_ext
54106 LIBS=$ac_check_lib_save_LIBS
54107 fi
54108 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5
54109 $as_echo "$ac_cv_lib_svld_dlopen" >&6; }
54110 if test "x$ac_cv_lib_svld_dlopen" = xyes; then :
54111   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"
54112 else
54113   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5
54114 $as_echo_n "checking for dld_link in -ldld... " >&6; }
54115 if ${ac_cv_lib_dld_dld_link+:} false; then :
54116   $as_echo_n "(cached) " >&6
54117 else
54118   ac_check_lib_save_LIBS=$LIBS
54119 LIBS="-ldld  $LIBS"
54120 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
54121 /* end confdefs.h.  */
54122
54123 /* Override any GCC internal prototype to avoid an error.
54124    Use char because int might match the return type of a GCC
54125    builtin and then its argument prototype would still apply.  */
54126 #ifdef __cplusplus
54127 extern "C"
54128 #endif
54129 char dld_link ();
54130 int
54131 main ()
54132 {
54133 return dld_link ();
54134   ;
54135   return 0;
54136 }
54137 _ACEOF
54138 if ac_fn_c_try_link "$LINENO"; then :
54139   ac_cv_lib_dld_dld_link=yes
54140 else
54141   ac_cv_lib_dld_dld_link=no
54142 fi
54143 rm -f core conftest.err conftest.$ac_objext \
54144     conftest$ac_exeext conftest.$ac_ext
54145 LIBS=$ac_check_lib_save_LIBS
54146 fi
54147 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5
54148 $as_echo "$ac_cv_lib_dld_dld_link" >&6; }
54149 if test "x$ac_cv_lib_dld_dld_link" = xyes; then :
54150   lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"
54151 fi
54152
54153
54154 fi
54155
54156
54157 fi
54158
54159
54160 fi
54161
54162
54163 fi
54164
54165
54166 fi
54167
54168     ;;
54169   esac
54170
54171   if test "x$lt_cv_dlopen" != xno; then
54172     enable_dlopen=yes
54173   else
54174     enable_dlopen=no
54175   fi
54176
54177   case $lt_cv_dlopen in
54178   dlopen)
54179     save_CPPFLAGS="$CPPFLAGS"
54180     test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
54181
54182     save_LDFLAGS="$LDFLAGS"
54183     wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
54184
54185     save_LIBS="$LIBS"
54186     LIBS="$lt_cv_dlopen_libs $LIBS"
54187
54188     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5
54189 $as_echo_n "checking whether a program can dlopen itself... " >&6; }
54190 if ${lt_cv_dlopen_self+:} false; then :
54191   $as_echo_n "(cached) " >&6
54192 else
54193           if test "$cross_compiling" = yes; then :
54194   lt_cv_dlopen_self=cross
54195 else
54196   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
54197   lt_status=$lt_dlunknown
54198   cat > conftest.$ac_ext <<_LT_EOF
54199 #line $LINENO "configure"
54200 #include "confdefs.h"
54201
54202 #if HAVE_DLFCN_H
54203 #include <dlfcn.h>
54204 #endif
54205
54206 #include <stdio.h>
54207
54208 #ifdef RTLD_GLOBAL
54209 #  define LT_DLGLOBAL           RTLD_GLOBAL
54210 #else
54211 #  ifdef DL_GLOBAL
54212 #    define LT_DLGLOBAL         DL_GLOBAL
54213 #  else
54214 #    define LT_DLGLOBAL         0
54215 #  endif
54216 #endif
54217
54218 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
54219    find out it does not work in some platform. */
54220 #ifndef LT_DLLAZY_OR_NOW
54221 #  ifdef RTLD_LAZY
54222 #    define LT_DLLAZY_OR_NOW            RTLD_LAZY
54223 #  else
54224 #    ifdef DL_LAZY
54225 #      define LT_DLLAZY_OR_NOW          DL_LAZY
54226 #    else
54227 #      ifdef RTLD_NOW
54228 #        define LT_DLLAZY_OR_NOW        RTLD_NOW
54229 #      else
54230 #        ifdef DL_NOW
54231 #          define LT_DLLAZY_OR_NOW      DL_NOW
54232 #        else
54233 #          define LT_DLLAZY_OR_NOW      0
54234 #        endif
54235 #      endif
54236 #    endif
54237 #  endif
54238 #endif
54239
54240 /* When -fvisbility=hidden is used, assume the code has been annotated
54241    correspondingly for the symbols needed.  */
54242 #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
54243 int fnord () __attribute__((visibility("default")));
54244 #endif
54245
54246 int fnord () { return 42; }
54247 int main ()
54248 {
54249   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
54250   int status = $lt_dlunknown;
54251
54252   if (self)
54253     {
54254       if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
54255       else
54256         {
54257           if (dlsym( self,"_fnord"))  status = $lt_dlneed_uscore;
54258           else puts (dlerror ());
54259         }
54260       /* dlclose (self); */
54261     }
54262   else
54263     puts (dlerror ());
54264
54265   return status;
54266 }
54267 _LT_EOF
54268   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
54269   (eval $ac_link) 2>&5
54270   ac_status=$?
54271   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
54272   test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then
54273     (./conftest; exit; ) >&5 2>/dev/null
54274     lt_status=$?
54275     case x$lt_status in
54276       x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
54277       x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
54278       x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;;
54279     esac
54280   else :
54281     # compilation failed
54282     lt_cv_dlopen_self=no
54283   fi
54284 fi
54285 rm -fr conftest*
54286
54287
54288 fi
54289 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5
54290 $as_echo "$lt_cv_dlopen_self" >&6; }
54291
54292     if test "x$lt_cv_dlopen_self" = xyes; then
54293       wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
54294       { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5
54295 $as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; }
54296 if ${lt_cv_dlopen_self_static+:} false; then :
54297   $as_echo_n "(cached) " >&6
54298 else
54299           if test "$cross_compiling" = yes; then :
54300   lt_cv_dlopen_self_static=cross
54301 else
54302   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
54303   lt_status=$lt_dlunknown
54304   cat > conftest.$ac_ext <<_LT_EOF
54305 #line $LINENO "configure"
54306 #include "confdefs.h"
54307
54308 #if HAVE_DLFCN_H
54309 #include <dlfcn.h>
54310 #endif
54311
54312 #include <stdio.h>
54313
54314 #ifdef RTLD_GLOBAL
54315 #  define LT_DLGLOBAL           RTLD_GLOBAL
54316 #else
54317 #  ifdef DL_GLOBAL
54318 #    define LT_DLGLOBAL         DL_GLOBAL
54319 #  else
54320 #    define LT_DLGLOBAL         0
54321 #  endif
54322 #endif
54323
54324 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
54325    find out it does not work in some platform. */
54326 #ifndef LT_DLLAZY_OR_NOW
54327 #  ifdef RTLD_LAZY
54328 #    define LT_DLLAZY_OR_NOW            RTLD_LAZY
54329 #  else
54330 #    ifdef DL_LAZY
54331 #      define LT_DLLAZY_OR_NOW          DL_LAZY
54332 #    else
54333 #      ifdef RTLD_NOW
54334 #        define LT_DLLAZY_OR_NOW        RTLD_NOW
54335 #      else
54336 #        ifdef DL_NOW
54337 #          define LT_DLLAZY_OR_NOW      DL_NOW
54338 #        else
54339 #          define LT_DLLAZY_OR_NOW      0
54340 #        endif
54341 #      endif
54342 #    endif
54343 #  endif
54344 #endif
54345
54346 /* When -fvisbility=hidden is used, assume the code has been annotated
54347    correspondingly for the symbols needed.  */
54348 #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
54349 int fnord () __attribute__((visibility("default")));
54350 #endif
54351
54352 int fnord () { return 42; }
54353 int main ()
54354 {
54355   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
54356   int status = $lt_dlunknown;
54357
54358   if (self)
54359     {
54360       if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
54361       else
54362         {
54363           if (dlsym( self,"_fnord"))  status = $lt_dlneed_uscore;
54364           else puts (dlerror ());
54365         }
54366       /* dlclose (self); */
54367     }
54368   else
54369     puts (dlerror ());
54370
54371   return status;
54372 }
54373 _LT_EOF
54374   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
54375   (eval $ac_link) 2>&5
54376   ac_status=$?
54377   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
54378   test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then
54379     (./conftest; exit; ) >&5 2>/dev/null
54380     lt_status=$?
54381     case x$lt_status in
54382       x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
54383       x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
54384       x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;;
54385     esac
54386   else :
54387     # compilation failed
54388     lt_cv_dlopen_self_static=no
54389   fi
54390 fi
54391 rm -fr conftest*
54392
54393
54394 fi
54395 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5
54396 $as_echo "$lt_cv_dlopen_self_static" >&6; }
54397     fi
54398
54399     CPPFLAGS="$save_CPPFLAGS"
54400     LDFLAGS="$save_LDFLAGS"
54401     LIBS="$save_LIBS"
54402     ;;
54403   esac
54404
54405   case $lt_cv_dlopen_self in
54406   yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
54407   *) enable_dlopen_self=unknown ;;
54408   esac
54409
54410   case $lt_cv_dlopen_self_static in
54411   yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
54412   *) enable_dlopen_self_static=unknown ;;
54413   esac
54414 fi
54415
54416
54417
54418
54419
54420
54421
54422
54423
54424
54425
54426
54427
54428
54429
54430
54431
54432 striplib=
54433 old_striplib=
54434 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5
54435 $as_echo_n "checking whether stripping libraries is possible... " >&6; }
54436 if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
54437   test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
54438   test -z "$striplib" && striplib="$STRIP --strip-unneeded"
54439   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
54440 $as_echo "yes" >&6; }
54441 else
54442 # FIXME - insert some real tests, host_os isn't really good enough
54443   case $host_os in
54444   darwin*)
54445     if test -n "$STRIP" ; then
54446       striplib="$STRIP -x"
54447       old_striplib="$STRIP -S"
54448       { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
54449 $as_echo "yes" >&6; }
54450     else
54451       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
54452 $as_echo "no" >&6; }
54453     fi
54454     ;;
54455   *)
54456     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
54457 $as_echo "no" >&6; }
54458     ;;
54459   esac
54460 fi
54461
54462
54463
54464
54465
54466
54467
54468
54469
54470
54471
54472
54473   # Report which library types will actually be built
54474   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5
54475 $as_echo_n "checking if libtool supports shared libraries... " >&6; }
54476   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5
54477 $as_echo "$can_build_shared" >&6; }
54478
54479   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5
54480 $as_echo_n "checking whether to build shared libraries... " >&6; }
54481   test "$can_build_shared" = "no" && enable_shared=no
54482
54483   # On AIX, shared libraries and static libraries use the same namespace, and
54484   # are all built from PIC.
54485   case $host_os in
54486   aix3*)
54487     test "$enable_shared" = yes && enable_static=no
54488     if test -n "$RANLIB"; then
54489       archive_cmds="$archive_cmds~\$RANLIB \$lib"
54490       postinstall_cmds='$RANLIB $lib'
54491     fi
54492     ;;
54493
54494   aix[4-9]*)
54495     if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
54496       test "$enable_shared" = yes && enable_static=no
54497     fi
54498     ;;
54499   esac
54500   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5
54501 $as_echo "$enable_shared" >&6; }
54502
54503   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5
54504 $as_echo_n "checking whether to build static libraries... " >&6; }
54505   # Make sure either enable_shared or enable_static is yes.
54506   test "$enable_shared" = yes || enable_static=yes
54507   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5
54508 $as_echo "$enable_static" >&6; }
54509
54510
54511
54512
54513 fi
54514 ac_ext=c
54515 ac_cpp='$CPP $CPPFLAGS'
54516 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
54517 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
54518 ac_compiler_gnu=$ac_cv_c_compiler_gnu
54519
54520 CC="$lt_save_CC"
54521
54522
54523
54524
54525
54526
54527
54528
54529
54530
54531
54532
54533
54534
54535
54536         ac_config_commands="$ac_config_commands libtool"
54537
54538
54539
54540
54541 # Only expand once:
54542
54543
54544
54545 # FIXME: we rely on the cache variable name because
54546 # there is no other way.
54547 set dummy $CC
54548 am_cc=`echo $2 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
54549 eval am_t=\$ac_cv_prog_cc_${am_cc}_c_o
54550 if test "$am_t" != yes; then
54551    # Losing compiler, so override with the script.
54552    # FIXME: It is wrong to rewrite CC.
54553    # But if we don't then we get into trouble of one sort or another.
54554    # A longer-term fix would be to have automake use am__CC in this case,
54555    # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
54556    CC="$am_aux_dir/compile $CC"
54557 fi
54558
54559
54560
54561
54562 # Check whether --with-gnu-ld was given.
54563 if test "${with_gnu_ld+set}" = set; then :
54564   withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
54565 else
54566   with_gnu_ld=no
54567 fi
54568
54569 ac_prog=ld
54570 if test "$GCC" = yes; then
54571   # Check if gcc -print-prog-name=ld gives a path.
54572   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
54573 $as_echo_n "checking for ld used by $CC... " >&6; }
54574   case $host in
54575   *-*-mingw*)
54576     # gcc leaves a trailing carriage return which upsets mingw
54577     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
54578   *)
54579     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
54580   esac
54581   case $ac_prog in
54582     # Accept absolute paths.
54583     [\\/]* | ?:[\\/]*)
54584       re_direlt='/[^/][^/]*/\.\./'
54585       # Canonicalize the pathname of ld
54586       ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
54587       while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
54588         ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
54589       done
54590       test -z "$LD" && LD="$ac_prog"
54591       ;;
54592   "")
54593     # If it fails, then pretend we aren't using GCC.
54594     ac_prog=ld
54595     ;;
54596   *)
54597     # If it is relative, then search for the first ld in PATH.
54598     with_gnu_ld=unknown
54599     ;;
54600   esac
54601 elif test "$with_gnu_ld" = yes; then
54602   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
54603 $as_echo_n "checking for GNU ld... " >&6; }
54604 else
54605   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
54606 $as_echo_n "checking for non-GNU ld... " >&6; }
54607 fi
54608 if ${lt_cv_path_LD+:} false; then :
54609   $as_echo_n "(cached) " >&6
54610 else
54611   if test -z "$LD"; then
54612   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
54613   for ac_dir in $PATH; do
54614     IFS="$lt_save_ifs"
54615     test -z "$ac_dir" && ac_dir=.
54616     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
54617       lt_cv_path_LD="$ac_dir/$ac_prog"
54618       # Check to see if the program is GNU ld.  I'd rather use --version,
54619       # but apparently some variants of GNU ld only accept -v.
54620       # Break only if it was the GNU/non-GNU ld that we prefer.
54621       case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
54622       *GNU* | *'with BFD'*)
54623         test "$with_gnu_ld" != no && break
54624         ;;
54625       *)
54626         test "$with_gnu_ld" != yes && break
54627         ;;
54628       esac
54629     fi
54630   done
54631   IFS="$lt_save_ifs"
54632 else
54633   lt_cv_path_LD="$LD" # Let the user override the test with a path.
54634 fi
54635 fi
54636
54637 LD="$lt_cv_path_LD"
54638 if test -n "$LD"; then
54639   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
54640 $as_echo "$LD" >&6; }
54641 else
54642   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
54643 $as_echo "no" >&6; }
54644 fi
54645 test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
54646 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
54647 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
54648 if ${lt_cv_prog_gnu_ld+:} false; then :
54649   $as_echo_n "(cached) " >&6
54650 else
54651   # I'd rather use --version here, but apparently some GNU lds only accept -v.
54652 case `$LD -v 2>&1 </dev/null` in
54653 *GNU* | *'with BFD'*)
54654   lt_cv_prog_gnu_ld=yes
54655   ;;
54656 *)
54657   lt_cv_prog_gnu_ld=no
54658   ;;
54659 esac
54660 fi
54661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
54662 $as_echo "$lt_cv_prog_gnu_ld" >&6; }
54663 with_gnu_ld=$lt_cv_prog_gnu_ld
54664
54665
54666
54667
54668
54669
54670
54671 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for how to mark DSO non-deletable at runtime" >&5
54672 $as_echo_n "checking for how to mark DSO non-deletable at runtime... " >&6; }
54673 LIBVIRT_NODELETE=
54674 `$LD --help 2>&1 | grep -- "-z nodelete" >/dev/null` && \
54675     LIBVIRT_NODELETE="-Wl,-z -Wl,nodelete"
54676 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBVIRT_NODELETE" >&5
54677 $as_echo "$LIBVIRT_NODELETE" >&6; }
54678
54679
54680 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for how to set DSO symbol versions" >&5
54681 $as_echo_n "checking for how to set DSO symbol versions... " >&6; }
54682 VERSION_SCRIPT_FLAGS=-Wl,--version-script=
54683 `$LD --help 2>&1 | grep -- --version-script >/dev/null` || \
54684     VERSION_SCRIPT_FLAGS="-Wl,-M -Wl,"
54685 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $VERSION_SCRIPT_FLAGS" >&5
54686 $as_echo "$VERSION_SCRIPT_FLAGS" >&6; }
54687
54688 want_ifconfig=no
54689
54690
54691 with_linux=no with_osx=no with_freebsd=no
54692 case $host in
54693   *-*-linux*) with_linux=yes ;;
54694   *-*-darwin*) with_osx=yes ;;
54695   *-*-freebsd*) with_freebsd=yes ;;
54696   *-*-mingw* | *-*-msvc* ) with_win=yes ;;
54697 esac
54698
54699 if test $with_linux = no; then
54700     if test "x$with_lxc" != xyes
54701     then
54702         with_lxc=no
54703     fi
54704     with_dtrace=no
54705 fi
54706
54707 if test $with_freebsd = yes; then
54708    want_ifconfig=yes
54709
54710    with_firewalld=no
54711 fi
54712
54713  if test "$with_linux" = "yes"; then
54714   WITH_LINUX_TRUE=
54715   WITH_LINUX_FALSE='#'
54716 else
54717   WITH_LINUX_TRUE='#'
54718   WITH_LINUX_FALSE=
54719 fi
54720
54721  if test "$with_freebsd" = "yes"; then
54722   WITH_FREEBSD_TRUE=
54723   WITH_FREEBSD_FALSE='#'
54724 else
54725   WITH_FREEBSD_TRUE='#'
54726   WITH_FREEBSD_FALSE=
54727 fi
54728
54729
54730 # We don't support the daemon yet
54731 if test "$with_win" = "yes" ; then
54732   with_libvirtd=no
54733 fi
54734
54735 # The daemon requires remote support.  Likewise, if we are not using
54736 # RPC, we don't need several libraries.
54737 if test "$with_remote" = "no" ; then
54738   with_libvirtd=no
54739   with_gnutls=no
54740   with_ssh2=no
54741   with_sasl=no
54742 fi
54743 # Stateful drivers are useful only when building the daemon.
54744 if test "$with_libvirtd" = "no" ; then
54745   with_qemu=no
54746   with_xen=no
54747   with_lxc=no
54748   with_libxl=no
54749   with_uml=no
54750   with_vbox=no
54751 fi
54752
54753 # Check for compiler and library settings.
54754
54755 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Werror -Wunknown-warning-option" >&5
54756 $as_echo_n "checking whether C compiler handles -Werror -Wunknown-warning-option... " >&6; }
54757 if ${gl_cv_warn_c__Werror__Wunknown_warning_option+:} false; then :
54758   $as_echo_n "(cached) " >&6
54759 else
54760
54761   gl_save_compiler_FLAGS="$CFLAGS"
54762   as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Werror -Wunknown-warning-option"
54763   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
54764 /* end confdefs.h.  */
54765
54766 int
54767 main ()
54768 {
54769
54770   ;
54771   return 0;
54772 }
54773 _ACEOF
54774 if ac_fn_c_try_link "$LINENO"; then :
54775   gl_cv_warn_c__Werror__Wunknown_warning_option=yes
54776 else
54777   gl_cv_warn_c__Werror__Wunknown_warning_option=no
54778 fi
54779 rm -f core conftest.err conftest.$ac_objext \
54780     conftest$ac_exeext conftest.$ac_ext
54781   CFLAGS="$gl_save_compiler_FLAGS"
54782
54783 fi
54784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Werror__Wunknown_warning_option" >&5
54785 $as_echo "$gl_cv_warn_c__Werror__Wunknown_warning_option" >&6; }
54786 if test "x$gl_cv_warn_c__Werror__Wunknown_warning_option" = xyes; then :
54787   gl_unknown_warnings_are_errors='-Wunknown-warning-option -Werror'
54788 else
54789   gl_unknown_warnings_are_errors=
54790 fi
54791
54792
54793
54794     # Check whether --enable-werror was given.
54795 if test "${enable_werror+set}" = set; then :
54796   enableval=$enable_werror; set_werror="$enableval"
54797 else
54798   if test -d $srcdir/.git; then
54799                      is_git_version=true
54800                      set_werror=yes
54801                    else
54802                      set_werror=no
54803                    fi
54804 fi
54805
54806
54807     # List of warnings that are not relevant / wanted
54808
54809     # Don't care about C++ compiler compat
54810     dontwarn="$dontwarn -Wc++-compat"
54811     dontwarn="$dontwarn -Wabi"
54812     dontwarn="$dontwarn -Wdeprecated"
54813     # Don't care about ancient C standard compat
54814     dontwarn="$dontwarn -Wtraditional"
54815     # Don't care about ancient C standard compat
54816     dontwarn="$dontwarn -Wtraditional-conversion"
54817     # Ignore warnings in /usr/include
54818     dontwarn="$dontwarn -Wsystem-headers"
54819     # Happy for compiler to add struct padding
54820     dontwarn="$dontwarn -Wpadded"
54821     # GCC very confused with -O2
54822     dontwarn="$dontwarn -Wunreachable-code"
54823     # Too many to deal with
54824     dontwarn="$dontwarn -Wconversion"
54825     # Too many to deal with
54826     dontwarn="$dontwarn -Wsign-conversion"
54827     # GNULIB gettext.h violates
54828     dontwarn="$dontwarn -Wvla"
54829     # Many GNULIB header violations
54830     dontwarn="$dontwarn -Wundef"
54831     # Need to allow bad cast for execve()
54832     dontwarn="$dontwarn -Wcast-qual"
54833     # We need to use long long in many places
54834     dontwarn="$dontwarn -Wlong-long"
54835     # We allow manual list of all enum cases without default:
54836     dontwarn="$dontwarn -Wswitch-default"
54837     # We allow optional default: instead of listing all enum values
54838     dontwarn="$dontwarn -Wswitch-enum"
54839     # Not a problem since we don't use -fstrict-overflow
54840     dontwarn="$dontwarn -Wstrict-overflow"
54841     # Not a problem since we don't use -funsafe-loop-optimizations
54842     dontwarn="$dontwarn -Wunsafe-loop-optimizations"
54843     # Things like virAsprintf mean we can't use this
54844     dontwarn="$dontwarn -Wformat-nonliteral"
54845     # Gnulib's stat-time.h violates this
54846     dontwarn="$dontwarn -Waggregate-return"
54847     # gcc 4.4.6 complains this is C++ only; gcc 4.7.0 implies this from -Wall
54848     dontwarn="$dontwarn -Wenum-compare"
54849
54850     # gcc 4.2 treats attribute(format) as an implicit attribute(nonnull),
54851     # which triggers spurious warnings for our usage
54852     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler's -Wformat allows NULL strings" >&5
54853 $as_echo_n "checking whether the C compiler's -Wformat allows NULL strings... " >&6; }
54854 if ${lv_cv_gcc_wformat_null_works+:} false; then :
54855   $as_echo_n "(cached) " >&6
54856 else
54857
54858       save_CFLAGS=$CFLAGS
54859       CFLAGS='-Wunknown-pragmas -Werror -Wformat'
54860       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
54861 /* end confdefs.h.  */
54862
54863         #include <stddef.h>
54864         static __attribute__ ((__format__ (__printf__, 1, 2))) int
54865         foo (const char *fmt, ...) { return !fmt; }
54866
54867 int
54868 main ()
54869 {
54870
54871         return foo(NULL);
54872
54873   ;
54874   return 0;
54875 }
54876 _ACEOF
54877 if ac_fn_c_try_compile "$LINENO"; then :
54878   lv_cv_gcc_wformat_null_works=yes
54879 else
54880   lv_cv_gcc_wformat_null_works=no
54881 fi
54882 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
54883       CFLAGS=$save_CFLAGS
54884 fi
54885 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lv_cv_gcc_wformat_null_works" >&5
54886 $as_echo "$lv_cv_gcc_wformat_null_works" >&6; }
54887
54888     # Gnulib uses '#pragma GCC diagnostic push' to silence some
54889     # warnings, but older gcc doesn't support this.
54890     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pragma GCC diagnostic push works" >&5
54891 $as_echo_n "checking whether pragma GCC diagnostic push works... " >&6; }
54892 if ${lv_cv_gcc_pragma_push_works+:} false; then :
54893   $as_echo_n "(cached) " >&6
54894 else
54895
54896       save_CFLAGS=$CFLAGS
54897       CFLAGS='-Wunknown-pragmas -Werror'
54898       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
54899 /* end confdefs.h.  */
54900
54901         #pragma GCC diagnostic push
54902         #pragma GCC diagnostic pop
54903
54904 int
54905 main ()
54906 {
54907
54908   ;
54909   return 0;
54910 }
54911 _ACEOF
54912 if ac_fn_c_try_compile "$LINENO"; then :
54913   lv_cv_gcc_pragma_push_works=yes
54914 else
54915   lv_cv_gcc_pragma_push_works=no
54916 fi
54917 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
54918       CFLAGS=$save_CFLAGS
54919 fi
54920 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lv_cv_gcc_pragma_push_works" >&5
54921 $as_echo "$lv_cv_gcc_pragma_push_works" >&6; }
54922     if test $lv_cv_gcc_pragma_push_works = no; then
54923       dontwarn="$dontwarn -Wmissing-prototypes"
54924       dontwarn="$dontwarn -Wmissing-declarations"
54925       dontwarn="$dontwarn -Wcast-align"
54926     else
54927
54928 cat >>confdefs.h <<_ACEOF
54929 #define WORKING_PRAGMA_PUSH 1
54930 _ACEOF
54931
54932     fi
54933
54934             { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler's -Wlogical-op gives bogus warnings" >&5
54935 $as_echo_n "checking whether the C compiler's -Wlogical-op gives bogus warnings... " >&6; }
54936 if ${lv_cv_gcc_wlogical_op_broken+:} false; then :
54937   $as_echo_n "(cached) " >&6
54938 else
54939
54940       save_CFLAGS="$CFLAGS"
54941       CFLAGS="-O2 -Wlogical-op -Werror"
54942       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
54943 /* end confdefs.h.  */
54944
54945         #include <string.h>
54946
54947 int
54948 main ()
54949 {
54950
54951         const char *haystack;
54952         char needle;
54953         return strchr(haystack, needle) == haystack;
54954   ;
54955   return 0;
54956 }
54957 _ACEOF
54958 if ac_fn_c_try_compile "$LINENO"; then :
54959   lv_cv_gcc_wlogical_op_broken=no
54960 else
54961   lv_cv_gcc_wlogical_op_broken=yes
54962 fi
54963 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
54964       CFLAGS="$save_CFLAGS"
54965 fi
54966 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lv_cv_gcc_wlogical_op_broken" >&5
54967 $as_echo "$lv_cv_gcc_wlogical_op_broken" >&6; }
54968
54969     # We might fundamentally need some of these disabled forever, but
54970     # ideally we'd turn many of them on
54971     dontwarn="$dontwarn -Wfloat-equal"
54972     dontwarn="$dontwarn -Wdeclaration-after-statement"
54973     dontwarn="$dontwarn -Wcast-qual"
54974     dontwarn="$dontwarn -Wconversion"
54975     dontwarn="$dontwarn -Wsign-conversion"
54976     dontwarn="$dontwarn -Wpacked"
54977     dontwarn="$dontwarn -Wunused-macros"
54978     dontwarn="$dontwarn -Woverlength-strings"
54979     dontwarn="$dontwarn -Wstack-protector"
54980
54981     # Get all possible GCC warnings
54982
54983
54984   if test -n "$GCC"; then
54985
54986             { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is supported" >&5
54987 $as_echo_n "checking whether -Wno-missing-field-initializers is supported... " >&6; }
54988     if ${gl_cv_cc_nomfi_supported+:} false; then :
54989   $as_echo_n "(cached) " >&6
54990 else
54991
54992       gl_save_CFLAGS="$CFLAGS"
54993       CFLAGS="$CFLAGS -W -Werror -Wno-missing-field-initializers"
54994       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
54995 /* end confdefs.h.  */
54996
54997 int
54998 main ()
54999 {
55000
55001   ;
55002   return 0;
55003 }
55004 _ACEOF
55005 if ac_fn_c_try_compile "$LINENO"; then :
55006   gl_cv_cc_nomfi_supported=yes
55007 else
55008   gl_cv_cc_nomfi_supported=no
55009 fi
55010 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
55011       CFLAGS="$gl_save_CFLAGS"
55012 fi
55013
55014     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_supported" >&5
55015 $as_echo "$gl_cv_cc_nomfi_supported" >&6; }
55016
55017     if test "$gl_cv_cc_nomfi_supported" = yes; then
55018                   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is needed" >&5
55019 $as_echo_n "checking whether -Wno-missing-field-initializers is needed... " >&6; }
55020       if ${gl_cv_cc_nomfi_needed+:} false; then :
55021   $as_echo_n "(cached) " >&6
55022 else
55023
55024         gl_save_CFLAGS="$CFLAGS"
55025         CFLAGS="$CFLAGS -W -Werror"
55026         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
55027 /* end confdefs.h.  */
55028 void f (void)
55029                {
55030                  typedef struct { int a; int b; } s_t;
55031                  s_t s1 = { 0, };
55032                }
55033
55034 int
55035 main ()
55036 {
55037
55038   ;
55039   return 0;
55040 }
55041 _ACEOF
55042 if ac_fn_c_try_compile "$LINENO"; then :
55043   gl_cv_cc_nomfi_needed=no
55044 else
55045   gl_cv_cc_nomfi_needed=yes
55046 fi
55047 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
55048         CFLAGS="$gl_save_CFLAGS"
55049
55050 fi
55051
55052       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_needed" >&5
55053 $as_echo "$gl_cv_cc_nomfi_needed" >&6; }
55054     fi
55055
55056                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wuninitialized is supported" >&5
55057 $as_echo_n "checking whether -Wuninitialized is supported... " >&6; }
55058     if ${gl_cv_cc_uninitialized_supported+:} false; then :
55059   $as_echo_n "(cached) " >&6
55060 else
55061
55062       gl_save_CFLAGS="$CFLAGS"
55063       CFLAGS="$CFLAGS -Werror -Wuninitialized"
55064       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
55065 /* end confdefs.h.  */
55066
55067 int
55068 main ()
55069 {
55070
55071   ;
55072   return 0;
55073 }
55074 _ACEOF
55075 if ac_fn_c_try_compile "$LINENO"; then :
55076   gl_cv_cc_uninitialized_supported=yes
55077 else
55078   gl_cv_cc_uninitialized_supported=no
55079 fi
55080 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
55081       CFLAGS="$gl_save_CFLAGS"
55082 fi
55083
55084     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_uninitialized_supported" >&5
55085 $as_echo "$gl_cv_cc_uninitialized_supported" >&6; }
55086
55087   fi
55088
55089   # List all gcc warning categories.
55090   gl_manywarn_set=
55091   for gl_manywarn_item in \
55092     -W \
55093     -Wabi \
55094     -Waddress \
55095     -Waggressive-loop-optimizations \
55096     -Wall \
55097     -Warray-bounds \
55098     -Wattributes \
55099     -Wbad-function-cast \
55100     -Wbuiltin-macro-redefined \
55101     -Wcast-align \
55102     -Wchar-subscripts \
55103     -Wclobbered \
55104     -Wcomment \
55105     -Wcomments \
55106     -Wcoverage-mismatch \
55107     -Wcpp \
55108     -Wdeprecated \
55109     -Wdeprecated-declarations \
55110     -Wdisabled-optimization \
55111     -Wdiv-by-zero \
55112     -Wdouble-promotion \
55113     -Wempty-body \
55114     -Wendif-labels \
55115     -Wenum-compare \
55116     -Wextra \
55117     -Wformat-contains-nul \
55118     -Wformat-extra-args \
55119     -Wformat-nonliteral \
55120     -Wformat-security \
55121     -Wformat-y2k \
55122     -Wformat-zero-length \
55123     -Wfree-nonheap-object \
55124     -Wignored-qualifiers \
55125     -Wimplicit \
55126     -Wimplicit-function-declaration \
55127     -Wimplicit-int \
55128     -Winit-self \
55129     -Winline \
55130     -Wint-to-pointer-cast \
55131     -Winvalid-memory-model \
55132     -Winvalid-pch \
55133     -Wjump-misses-init \
55134     -Wlogical-op \
55135     -Wmain \
55136     -Wmaybe-uninitialized \
55137     -Wmissing-braces \
55138     -Wmissing-declarations \
55139     -Wmissing-field-initializers \
55140     -Wmissing-include-dirs \
55141     -Wmissing-parameter-type \
55142     -Wmissing-prototypes \
55143     -Wmultichar \
55144     -Wnarrowing \
55145     -Wnested-externs \
55146     -Wnonnull \
55147     -Wnormalized=nfc \
55148     -Wold-style-declaration \
55149     -Wold-style-definition \
55150     -Woverflow \
55151     -Woverlength-strings \
55152     -Woverride-init \
55153     -Wpacked \
55154     -Wpacked-bitfield-compat \
55155     -Wparentheses \
55156     -Wpointer-arith \
55157     -Wpointer-sign \
55158     -Wpointer-to-int-cast \
55159     -Wpragmas \
55160     -Wreturn-local-addr \
55161     -Wreturn-type \
55162     -Wsequence-point \
55163     -Wshadow \
55164     -Wsizeof-pointer-memaccess \
55165     -Wstack-protector \
55166     -Wstrict-aliasing \
55167     -Wstrict-overflow \
55168     -Wstrict-prototypes \
55169     -Wsuggest-attribute=const \
55170     -Wsuggest-attribute=format \
55171     -Wsuggest-attribute=noreturn \
55172     -Wsuggest-attribute=pure \
55173     -Wswitch \
55174     -Wswitch-default \
55175     -Wsync-nand \
55176     -Wsystem-headers \
55177     -Wtrampolines \
55178     -Wtrigraphs \
55179     -Wtype-limits \
55180     -Wuninitialized \
55181     -Wunknown-pragmas \
55182     -Wunsafe-loop-optimizations \
55183     -Wunused \
55184     -Wunused-but-set-parameter \
55185     -Wunused-but-set-variable \
55186     -Wunused-function \
55187     -Wunused-label \
55188     -Wunused-local-typedefs \
55189     -Wunused-macros \
55190     -Wunused-parameter \
55191     -Wunused-result \
55192     -Wunused-value \
55193     -Wunused-variable \
55194     -Wvarargs \
55195     -Wvariadic-macros \
55196     -Wvector-operation-performance \
55197     -Wvla \
55198     -Wvolatile-register-var \
55199     -Wwrite-strings \
55200     -fdiagnostics-show-option \
55201     -funit-at-a-time \
55202     \
55203     ; do
55204     gl_manywarn_set="$gl_manywarn_set $gl_manywarn_item"
55205   done
55206
55207   # Disable specific options as needed.
55208   if test "$gl_cv_cc_nomfi_needed" = yes; then
55209     gl_manywarn_set="$gl_manywarn_set -Wno-missing-field-initializers"
55210   fi
55211
55212   if test "$gl_cv_cc_uninitialized_supported" = no; then
55213     gl_manywarn_set="$gl_manywarn_set -Wno-uninitialized"
55214   fi
55215
55216   maybewarn=$gl_manywarn_set
55217
55218
55219     # Remove the ones we don't want, blacklisted earlier
55220
55221   gl_warn_set=
55222   set x $maybewarn; shift
55223   for gl_warn_item
55224   do
55225     case " $dontwarn " in
55226       *" $gl_warn_item "*)
55227         ;;
55228       *)
55229         gl_warn_set="$gl_warn_set $gl_warn_item"
55230         ;;
55231     esac
55232   done
55233   wantwarn=$gl_warn_set
55234
55235
55236     # GNULIB uses '-W' (aka -Wextra) which includes a bunch of stuff.
55237     # Unfortunately, this means you can't simply use '-Wsign-compare'
55238     # with gl_MANYWARN_COMPLEMENT
55239     # So we have -W enabled, and then have to explicitly turn off...
55240     wantwarn="$wantwarn -Wno-sign-compare"
55241
55242     # GNULIB expects this to be part of -Wc++-compat, but we turn
55243     # that one off, so we need to manually enable this again
55244     wantwarn="$wantwarn -Wjump-misses-init"
55245
55246     # GNULIB turns on -Wformat=2 which implies -Wformat-nonliteral,
55247     # so we need to manually re-exclude it.  Also, older gcc 4.2
55248     # added an implied ATTRIBUTE_NONNULL on any parameter marked
55249     # ATTRIBUTE_FMT_PRINT, which causes -Wformat failure on our
55250     # intentional use of virReportError(code, NULL).
55251     wantwarn="$wantwarn -Wno-format-nonliteral"
55252     if test $lv_cv_gcc_wformat_null_works = no; then
55253       wantwarn="$wantwarn -Wno-format"
55254     fi
55255
55256     # This should be < 256 really. Currently we're down to 4096,
55257     # but using 1024 bytes sized buffers (mostly for virStrerror)
55258     # stops us from going down further
55259     wantwarn="$wantwarn -Wframe-larger-than=4096"
55260
55261     # Extra special flags
55262             case $host in
55263        aarch64-*-*)
55264               ;;
55265        *-*-linux*)
55266                             wantwarn="$wantwarn -fstack-protector-all"
55267        wantwarn="$wantwarn --param=ssp-buffer-size=4"
55268                                                  wantwarn="$wantwarn -Wno-unused-command-line-argument"
55269        ;;
55270        *-*-freebsd*)
55271                      wantwarn="$wantwarn -fstack-protector"
55272
55273        wantwarn="$wantwarn -Wno-unused-command-line-argument"
55274        ;;
55275     esac
55276     wantwarn="$wantwarn -fexceptions"
55277     wantwarn="$wantwarn -fasynchronous-unwind-tables"
55278
55279     # Need -fipa-pure-const in order to make -Wsuggest-attribute=pure
55280     # fire even without -O.
55281     wantwarn="$wantwarn -fipa-pure-const"
55282     # We should eventually enable this, but right now there are at
55283     # least 75 functions triggering warnings.
55284     wantwarn="$wantwarn -Wno-suggest-attribute=pure"
55285     wantwarn="$wantwarn -Wno-suggest-attribute=const"
55286
55287     if test "$set_werror" = "yes"
55288     then
55289       wantwarn="$wantwarn -Werror"
55290     fi
55291
55292     # Check for $CC support of each warning
55293     for w in $wantwarn; do
55294
55295 as_gl_Warn=`$as_echo "gl_cv_warn_c_$w" | $as_tr_sh`
55296 gl_positive="$w"
55297 case $gl_positive in
55298   -Wno-*) gl_positive=-W`expr "X$gl_positive" : 'X-Wno-\(.*\)'` ;;
55299 esac
55300 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles $w" >&5
55301 $as_echo_n "checking whether C compiler handles $w... " >&6; }
55302 if eval \${$as_gl_Warn+:} false; then :
55303   $as_echo_n "(cached) " >&6
55304 else
55305
55306   gl_save_compiler_FLAGS="$CFLAGS"
55307   as_fn_append CFLAGS " $gl_unknown_warnings_are_errors $gl_positive"
55308   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
55309 /* end confdefs.h.  */
55310
55311 int
55312 main ()
55313 {
55314
55315   ;
55316   return 0;
55317 }
55318 _ACEOF
55319 if ac_fn_c_try_link "$LINENO"; then :
55320   eval "$as_gl_Warn=yes"
55321 else
55322   eval "$as_gl_Warn=no"
55323 fi
55324 rm -f core conftest.err conftest.$ac_objext \
55325     conftest$ac_exeext conftest.$ac_ext
55326   CFLAGS="$gl_save_compiler_FLAGS"
55327
55328 fi
55329 eval ac_res=\$$as_gl_Warn
55330                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
55331 $as_echo "$ac_res" >&6; }
55332 if eval test \"x\$"$as_gl_Warn"\" = x"yes"; then :
55333   as_fn_append WARN_CFLAGS " $w"
55334 fi
55335
55336
55337     done
55338
55339     # Silence certain warnings in gnulib, and use improved glibc headers
55340
55341 $as_echo "#define lint 1" >>confdefs.h
55342
55343
55344
55345     if test "$gl_cv_warn_c__Wlogical_op" = yes &&
55346        test "$lv_cv_gcc_wlogical_op_broken" = yes; then
55347
55348 cat >>confdefs.h <<_ACEOF
55349 #define BROKEN_GCC_WLOGICALOP 1
55350 _ACEOF
55351
55352     fi
55353
55354
55355     PIE_CFLAGS=
55356     PIE_LDFLAGS=
55357     case "$host" in
55358       *-*-mingw* | *-*-msvc* | *-*-cygwin* )
55359          ;;       *)
55360       { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -fPIE -DPIE" >&5
55361 $as_echo_n "checking whether C compiler handles -fPIE -DPIE... " >&6; }
55362 if ${gl_cv_warn_c__fPIE__DPIE+:} false; then :
55363   $as_echo_n "(cached) " >&6
55364 else
55365
55366   gl_save_compiler_FLAGS="$CFLAGS"
55367   as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -fPIE -DPIE"
55368   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
55369 /* end confdefs.h.  */
55370
55371 int
55372 main ()
55373 {
55374
55375   ;
55376   return 0;
55377 }
55378 _ACEOF
55379 if ac_fn_c_try_link "$LINENO"; then :
55380   gl_cv_warn_c__fPIE__DPIE=yes
55381 else
55382   gl_cv_warn_c__fPIE__DPIE=no
55383 fi
55384 rm -f core conftest.err conftest.$ac_objext \
55385     conftest$ac_exeext conftest.$ac_ext
55386   CFLAGS="$gl_save_compiler_FLAGS"
55387
55388 fi
55389 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__fPIE__DPIE" >&5
55390 $as_echo "$gl_cv_warn_c__fPIE__DPIE" >&6; }
55391 if test "x$gl_cv_warn_c__fPIE__DPIE" = xyes; then :
55392
55393         PIE_CFLAGS="-fPIE -DPIE"
55394         PIE_LDFLAGS="-pie"
55395
55396 fi
55397
55398     esac
55399
55400
55401
55402
55403     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for how to force completely read-only GOT table" >&5
55404 $as_echo_n "checking for how to force completely read-only GOT table... " >&6; }
55405
55406     RELRO_LDFLAGS=
55407     ld_help=`$LD --help 2>&1`
55408     case $ld_help in
55409         *"-z relro"*) RELRO_LDFLAGS="-Wl,-z -Wl,relro" ;;
55410     esac
55411     case $ld_help in
55412         *"-z now"*) RELRO_LDFLAGS="$RELRO_LDFLAGS -Wl,-z -Wl,now" ;;
55413     esac
55414
55415
55416     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RELRO_LDFLAGS" >&5
55417 $as_echo "$RELRO_LDFLAGS" >&6; }
55418
55419
55420     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for how to avoid indirect lib deps" >&5
55421 $as_echo_n "checking for how to avoid indirect lib deps... " >&6; }
55422
55423     NO_INDIRECT_LDFLAGS=
55424     case `$LD --help 2>&1` in
55425         *"--no-copy-dt-needed-entries"*)
55426                 NO_INDIRECT_LDFLAGS="-Wl,--no-copy-dt-needed-entries" ;;
55427     esac
55428
55429
55430     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NO_INDIRECT_LDFLAGS" >&5
55431 $as_echo "$NO_INDIRECT_LDFLAGS" >&6; }
55432
55433
55434
55435
55436
55437
55438
55439
55440
55441
55442
55443
55444
55445
55446
55447
55448
55449
55450
55451
55452
55453 # Check whether --with-apparmor was given.
55454 if test "${with_apparmor+set}" = set; then :
55455   withval=$with_apparmor;
55456 fi
55457
55458
55459   old_LIBS=$LIBS
55460   old_CFLAGS=$CFLAGS
55461   APPARMOR_CFLAGS=
55462   APPARMOR_LIBS=
55463
55464   fail=0
55465   if test "x$with_apparmor" != "xno" ; then
55466     if test "x$with_apparmor" != "xyes" && test "x$with_apparmor" != "xcheck" ; then
55467       APPARMOR_CFLAGS="-I$with_apparmor/include"
55468       APPARMOR_LIBS="-L$with_apparmor/lib"
55469     fi
55470     CFLAGS="$CFLAGS $APPARMOR_CFLAGS"
55471     LIBS="$LIBS $APPARMOR_LIBS"
55472     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for aa_change_profile in -lapparmor" >&5
55473 $as_echo_n "checking for aa_change_profile in -lapparmor... " >&6; }
55474 if ${ac_cv_lib_apparmor_aa_change_profile+:} false; then :
55475   $as_echo_n "(cached) " >&6
55476 else
55477   ac_check_lib_save_LIBS=$LIBS
55478 LIBS="-lapparmor  $LIBS"
55479 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
55480 /* end confdefs.h.  */
55481
55482 /* Override any GCC internal prototype to avoid an error.
55483    Use char because int might match the return type of a GCC
55484    builtin and then its argument prototype would still apply.  */
55485 #ifdef __cplusplus
55486 extern "C"
55487 #endif
55488 char aa_change_profile ();
55489 int
55490 main ()
55491 {
55492 return aa_change_profile ();
55493   ;
55494   return 0;
55495 }
55496 _ACEOF
55497 if ac_fn_c_try_link "$LINENO"; then :
55498   ac_cv_lib_apparmor_aa_change_profile=yes
55499 else
55500   ac_cv_lib_apparmor_aa_change_profile=no
55501 fi
55502 rm -f core conftest.err conftest.$ac_objext \
55503     conftest$ac_exeext conftest.$ac_ext
55504 LIBS=$ac_check_lib_save_LIBS
55505 fi
55506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_apparmor_aa_change_profile" >&5
55507 $as_echo "$ac_cv_lib_apparmor_aa_change_profile" >&6; }
55508 if test "x$ac_cv_lib_apparmor_aa_change_profile" = xyes; then :
55509   cat >>confdefs.h <<_ACEOF
55510 #define HAVE_LIBAPPARMOR 1
55511 _ACEOF
55512
55513   LIBS="-lapparmor $LIBS"
55514
55515 else
55516
55517       if test "x$with_apparmor" != "xcheck"; then
55518         fail=1
55519       fi
55520       with_apparmor=no
55521
55522 fi
55523
55524     if test "$fail" = "0" && test "x$with_apparmor" != "xno" ; then
55525       ac_fn_c_check_header_mongrel "$LINENO" "sys/apparmor.h" "ac_cv_header_header_name" "$ac_includes_default"
55526 if test "x$ac_cv_header_header_name" = xyes; then :
55527
55528         with_apparmor=yes
55529
55530 else
55531
55532         if test "x$with_apparmor" != "xcheck"; then
55533           fail=1
55534         fi
55535         with_apparmor=no
55536
55537 fi
55538
55539
55540     fi
55541   fi
55542
55543   LIBS=$old_LIBS
55544   CFLAGS=$old_CFLAGS
55545
55546   if test $fail = 1; then
55547     as_fn_error $? "You must install the libapparmor library & headers to compile libvirt" "$LINENO" 5
55548   else
55549     if test "x$with_apparmor" = "xyes" ; then
55550       if test "x$APPARMOR_LIBS" = 'x' ; then
55551         APPARMOR_LIBS="-lapparmor"
55552       else
55553         APPARMOR_LIBS="$APPARMOR_LIBS -lapparmor"
55554       fi
55555
55556 cat >>confdefs.h <<_ACEOF
55557 #define WITH_APPARMOR 1
55558 _ACEOF
55559
55560     fi
55561
55562      if test "x$with_apparmor" = "xyes"; then
55563   WITH_APPARMOR_TRUE=
55564   WITH_APPARMOR_FALSE='#'
55565 else
55566   WITH_APPARMOR_TRUE='#'
55567   WITH_APPARMOR_FALSE=
55568 fi
55569
55570
55571
55572
55573   fi
55574
55575
55576
55577
55578
55579
55580
55581
55582
55583
55584
55585
55586
55587
55588
55589
55590
55591
55592 # Check whether --with-apparmor_mount was given.
55593 if test "${with_apparmor_mount+set}" = set; then :
55594   withval=$with_apparmor_mount;
55595 else
55596   with_apparmor_mount=check
55597 fi
55598
55599
55600   if test "$with_apparmor" = "yes"; then
55601
55602 cat >>confdefs.h <<_ACEOF
55603 #define APPARMOR_DIR "/etc/apparmor.d"
55604 _ACEOF
55605
55606
55607 cat >>confdefs.h <<_ACEOF
55608 #define APPARMOR_PROFILES_PATH "/sys/kernel/security/apparmor/profiles"
55609 _ACEOF
55610
55611   fi
55612
55613
55614
55615
55616
55617
55618
55619
55620
55621
55622
55623
55624
55625
55626
55627
55628
55629
55630
55631
55632 # Check whether --with-attr was given.
55633 if test "${with_attr+set}" = set; then :
55634   withval=$with_attr;
55635 fi
55636
55637
55638   old_LIBS=$LIBS
55639   old_CFLAGS=$CFLAGS
55640   ATTR_CFLAGS=
55641   ATTR_LIBS=
55642
55643   fail=0
55644   if test "x$with_attr" != "xno" ; then
55645     if test "x$with_attr" != "xyes" && test "x$with_attr" != "xcheck" ; then
55646       ATTR_CFLAGS="-I$with_attr/include"
55647       ATTR_LIBS="-L$with_attr/lib"
55648     fi
55649     CFLAGS="$CFLAGS $ATTR_CFLAGS"
55650     LIBS="$LIBS $ATTR_LIBS"
55651     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getxattr in -lattr" >&5
55652 $as_echo_n "checking for getxattr in -lattr... " >&6; }
55653 if ${ac_cv_lib_attr_getxattr+:} false; then :
55654   $as_echo_n "(cached) " >&6
55655 else
55656   ac_check_lib_save_LIBS=$LIBS
55657 LIBS="-lattr  $LIBS"
55658 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
55659 /* end confdefs.h.  */
55660
55661 /* Override any GCC internal prototype to avoid an error.
55662    Use char because int might match the return type of a GCC
55663    builtin and then its argument prototype would still apply.  */
55664 #ifdef __cplusplus
55665 extern "C"
55666 #endif
55667 char getxattr ();
55668 int
55669 main ()
55670 {
55671 return getxattr ();
55672   ;
55673   return 0;
55674 }
55675 _ACEOF
55676 if ac_fn_c_try_link "$LINENO"; then :
55677   ac_cv_lib_attr_getxattr=yes
55678 else
55679   ac_cv_lib_attr_getxattr=no
55680 fi
55681 rm -f core conftest.err conftest.$ac_objext \
55682     conftest$ac_exeext conftest.$ac_ext
55683 LIBS=$ac_check_lib_save_LIBS
55684 fi
55685 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_attr_getxattr" >&5
55686 $as_echo "$ac_cv_lib_attr_getxattr" >&6; }
55687 if test "x$ac_cv_lib_attr_getxattr" = xyes; then :
55688   cat >>confdefs.h <<_ACEOF
55689 #define HAVE_LIBATTR 1
55690 _ACEOF
55691
55692   LIBS="-lattr $LIBS"
55693
55694 else
55695
55696       if test "x$with_attr" != "xcheck"; then
55697         fail=1
55698       fi
55699       with_attr=no
55700
55701 fi
55702
55703     if test "$fail" = "0" && test "x$with_attr" != "xno" ; then
55704       ac_fn_c_check_header_mongrel "$LINENO" "attr/xattr.h" "ac_cv_header_header_name" "$ac_includes_default"
55705 if test "x$ac_cv_header_header_name" = xyes; then :
55706
55707         with_attr=yes
55708
55709 else
55710
55711         if test "x$with_attr" != "xcheck"; then
55712           fail=1
55713         fi
55714         with_attr=no
55715
55716 fi
55717
55718
55719     fi
55720   fi
55721
55722   LIBS=$old_LIBS
55723   CFLAGS=$old_CFLAGS
55724
55725   if test $fail = 1; then
55726     as_fn_error $? "You must install the libattr library & headers to compile libvirt" "$LINENO" 5
55727   else
55728     if test "x$with_attr" = "xyes" ; then
55729       if test "x$ATTR_LIBS" = 'x' ; then
55730         ATTR_LIBS="-lattr"
55731       else
55732         ATTR_LIBS="$ATTR_LIBS -lattr"
55733       fi
55734
55735 cat >>confdefs.h <<_ACEOF
55736 #define WITH_ATTR 1
55737 _ACEOF
55738
55739     fi
55740
55741      if test "x$with_attr" = "xyes"; then
55742   WITH_ATTR_TRUE=
55743   WITH_ATTR_FALSE='#'
55744 else
55745   WITH_ATTR_TRUE='#'
55746   WITH_ATTR_FALSE=
55747 fi
55748
55749
55750
55751
55752   fi
55753
55754
55755
55756
55757
55758
55759
55760
55761
55762
55763
55764
55765
55766
55767
55768
55769
55770
55771
55772
55773
55774
55775
55776
55777
55778
55779
55780
55781
55782
55783
55784
55785
55786
55787
55788
55789 # Check whether --with-audit was given.
55790 if test "${with_audit+set}" = set; then :
55791   withval=$with_audit;
55792 fi
55793
55794
55795   old_LIBS=$LIBS
55796   old_CFLAGS=$CFLAGS
55797   AUDIT_CFLAGS=
55798   AUDIT_LIBS=
55799
55800   fail=0
55801   if test "x$with_audit" != "xno" ; then
55802     if test "x$with_audit" != "xyes" && test "x$with_audit" != "xcheck" ; then
55803       AUDIT_CFLAGS="-I$with_audit/include"
55804       AUDIT_LIBS="-L$with_audit/lib"
55805     fi
55806     CFLAGS="$CFLAGS $AUDIT_CFLAGS"
55807     LIBS="$LIBS $AUDIT_LIBS"
55808     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for audit_encode_nv_string in -laudit" >&5
55809 $as_echo_n "checking for audit_encode_nv_string in -laudit... " >&6; }
55810 if ${ac_cv_lib_audit_audit_encode_nv_string+:} false; then :
55811   $as_echo_n "(cached) " >&6
55812 else
55813   ac_check_lib_save_LIBS=$LIBS
55814 LIBS="-laudit  $LIBS"
55815 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
55816 /* end confdefs.h.  */
55817
55818 /* Override any GCC internal prototype to avoid an error.
55819    Use char because int might match the return type of a GCC
55820    builtin and then its argument prototype would still apply.  */
55821 #ifdef __cplusplus
55822 extern "C"
55823 #endif
55824 char audit_encode_nv_string ();
55825 int
55826 main ()
55827 {
55828 return audit_encode_nv_string ();
55829   ;
55830   return 0;
55831 }
55832 _ACEOF
55833 if ac_fn_c_try_link "$LINENO"; then :
55834   ac_cv_lib_audit_audit_encode_nv_string=yes
55835 else
55836   ac_cv_lib_audit_audit_encode_nv_string=no
55837 fi
55838 rm -f core conftest.err conftest.$ac_objext \
55839     conftest$ac_exeext conftest.$ac_ext
55840 LIBS=$ac_check_lib_save_LIBS
55841 fi
55842 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_audit_audit_encode_nv_string" >&5
55843 $as_echo "$ac_cv_lib_audit_audit_encode_nv_string" >&6; }
55844 if test "x$ac_cv_lib_audit_audit_encode_nv_string" = xyes; then :
55845   cat >>confdefs.h <<_ACEOF
55846 #define HAVE_LIBAUDIT 1
55847 _ACEOF
55848
55849   LIBS="-laudit $LIBS"
55850
55851 else
55852
55853       if test "x$with_audit" != "xcheck"; then
55854         fail=1
55855       fi
55856       with_audit=no
55857
55858 fi
55859
55860     if test "$fail" = "0" && test "x$with_audit" != "xno" ; then
55861       ac_fn_c_check_header_mongrel "$LINENO" "libaudit.h" "ac_cv_header_header_name" "$ac_includes_default"
55862 if test "x$ac_cv_header_header_name" = xyes; then :
55863
55864         with_audit=yes
55865
55866 else
55867
55868         if test "x$with_audit" != "xcheck"; then
55869           fail=1
55870         fi
55871         with_audit=no
55872
55873 fi
55874
55875
55876     fi
55877   fi
55878
55879   LIBS=$old_LIBS
55880   CFLAGS=$old_CFLAGS
55881
55882   if test $fail = 1; then
55883     as_fn_error $? "You must install the libaudit library & headers to compile libvirt" "$LINENO" 5
55884   else
55885     if test "x$with_audit" = "xyes" ; then
55886       if test "x$AUDIT_LIBS" = 'x' ; then
55887         AUDIT_LIBS="-laudit"
55888       else
55889         AUDIT_LIBS="$AUDIT_LIBS -laudit"
55890       fi
55891
55892 cat >>confdefs.h <<_ACEOF
55893 #define WITH_AUDIT 1
55894 _ACEOF
55895
55896     fi
55897
55898      if test "x$with_audit" = "xyes"; then
55899   WITH_AUDIT_TRUE=
55900   WITH_AUDIT_FALSE='#'
55901 else
55902   WITH_AUDIT_TRUE='#'
55903   WITH_AUDIT_FALSE=
55904 fi
55905
55906
55907
55908
55909   fi
55910
55911
55912
55913
55914
55915
55916
55917
55918
55919
55920
55921
55922
55923
55924
55925
55926
55927
55928
55929
55930
55931
55932
55933
55934 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
55935         if test -n "$ac_tool_prefix"; then
55936   # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
55937 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
55938 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
55939 $as_echo_n "checking for $ac_word... " >&6; }
55940 if ${ac_cv_path_PKG_CONFIG+:} false; then :
55941   $as_echo_n "(cached) " >&6
55942 else
55943   case $PKG_CONFIG in
55944   [\\/]* | ?:[\\/]*)
55945   ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
55946   ;;
55947   *)
55948   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
55949 for as_dir in $PATH
55950 do
55951   IFS=$as_save_IFS
55952   test -z "$as_dir" && as_dir=.
55953     for ac_exec_ext in '' $ac_executable_extensions; do
55954   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
55955     ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
55956     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
55957     break 2
55958   fi
55959 done
55960   done
55961 IFS=$as_save_IFS
55962
55963   ;;
55964 esac
55965 fi
55966 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
55967 if test -n "$PKG_CONFIG"; then
55968   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
55969 $as_echo "$PKG_CONFIG" >&6; }
55970 else
55971   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
55972 $as_echo "no" >&6; }
55973 fi
55974
55975
55976 fi
55977 if test -z "$ac_cv_path_PKG_CONFIG"; then
55978   ac_pt_PKG_CONFIG=$PKG_CONFIG
55979   # Extract the first word of "pkg-config", so it can be a program name with args.
55980 set dummy pkg-config; ac_word=$2
55981 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
55982 $as_echo_n "checking for $ac_word... " >&6; }
55983 if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
55984   $as_echo_n "(cached) " >&6
55985 else
55986   case $ac_pt_PKG_CONFIG in
55987   [\\/]* | ?:[\\/]*)
55988   ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
55989   ;;
55990   *)
55991   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
55992 for as_dir in $PATH
55993 do
55994   IFS=$as_save_IFS
55995   test -z "$as_dir" && as_dir=.
55996     for ac_exec_ext in '' $ac_executable_extensions; do
55997   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
55998     ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
55999     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
56000     break 2
56001   fi
56002 done
56003   done
56004 IFS=$as_save_IFS
56005
56006   ;;
56007 esac
56008 fi
56009 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
56010 if test -n "$ac_pt_PKG_CONFIG"; then
56011   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
56012 $as_echo "$ac_pt_PKG_CONFIG" >&6; }
56013 else
56014   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
56015 $as_echo "no" >&6; }
56016 fi
56017
56018   if test "x$ac_pt_PKG_CONFIG" = x; then
56019     PKG_CONFIG=""
56020   else
56021     case $cross_compiling:$ac_tool_warned in
56022 yes:)
56023 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
56024 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
56025 ac_tool_warned=yes ;;
56026 esac
56027     PKG_CONFIG=$ac_pt_PKG_CONFIG
56028   fi
56029 else
56030   PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
56031 fi
56032
56033 fi
56034 if test -n "$PKG_CONFIG"; then
56035         _pkg_min_version=0.9.0
56036         { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
56037 $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
56038         if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
56039                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
56040 $as_echo "yes" >&6; }
56041         else
56042                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
56043 $as_echo "no" >&6; }
56044                 PKG_CONFIG=""
56045         fi
56046 fi
56047
56048
56049
56050
56051
56052
56053
56054
56055
56056
56057
56058
56059
56060
56061
56062
56063
56064
56065 # Check whether --with-avahi was given.
56066 if test "${with_avahi+set}" = set; then :
56067   withval=$with_avahi;
56068 fi
56069
56070
56071   fail=0
56072   if test "x$with_avahi" != "xno" ; then
56073
56074 pkg_failed=no
56075 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AVAHI" >&5
56076 $as_echo_n "checking for AVAHI... " >&6; }
56077
56078 if test -n "$AVAHI_CFLAGS"; then
56079     pkg_cv_AVAHI_CFLAGS="$AVAHI_CFLAGS"
56080  elif test -n "$PKG_CONFIG"; then
56081     if test -n "$PKG_CONFIG" && \
56082     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"avahi-client >= 0.6.0\""; } >&5
56083   ($PKG_CONFIG --exists --print-errors "avahi-client >= 0.6.0") 2>&5
56084   ac_status=$?
56085   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
56086   test $ac_status = 0; }; then
56087   pkg_cv_AVAHI_CFLAGS=`$PKG_CONFIG --cflags "avahi-client >= 0.6.0" 2>/dev/null`
56088                       test "x$?" != "x0" && pkg_failed=yes
56089 else
56090   pkg_failed=yes
56091 fi
56092  else
56093     pkg_failed=untried
56094 fi
56095 if test -n "$AVAHI_LIBS"; then
56096     pkg_cv_AVAHI_LIBS="$AVAHI_LIBS"
56097  elif test -n "$PKG_CONFIG"; then
56098     if test -n "$PKG_CONFIG" && \
56099     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"avahi-client >= 0.6.0\""; } >&5
56100   ($PKG_CONFIG --exists --print-errors "avahi-client >= 0.6.0") 2>&5
56101   ac_status=$?
56102   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
56103   test $ac_status = 0; }; then
56104   pkg_cv_AVAHI_LIBS=`$PKG_CONFIG --libs "avahi-client >= 0.6.0" 2>/dev/null`
56105                       test "x$?" != "x0" && pkg_failed=yes
56106 else
56107   pkg_failed=yes
56108 fi
56109  else
56110     pkg_failed=untried
56111 fi
56112
56113
56114
56115 if test $pkg_failed = yes; then
56116         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
56117 $as_echo "no" >&6; }
56118
56119 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
56120         _pkg_short_errors_supported=yes
56121 else
56122         _pkg_short_errors_supported=no
56123 fi
56124         if test $_pkg_short_errors_supported = yes; then
56125                 AVAHI_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "avahi-client >= 0.6.0" 2>&1`
56126         else
56127                 AVAHI_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "avahi-client >= 0.6.0" 2>&1`
56128         fi
56129         # Put the nasty error message in config.log where it belongs
56130         echo "$AVAHI_PKG_ERRORS" >&5
56131
56132
56133       if test "x$with_avahi" != "xcheck"; then
56134         fail=1
56135       fi
56136       with_avahi=no
56137
56138 elif test $pkg_failed = untried; then
56139         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
56140 $as_echo "no" >&6; }
56141
56142       if test "x$with_avahi" != "xcheck"; then
56143         fail=1
56144       fi
56145       with_avahi=no
56146
56147 else
56148         AVAHI_CFLAGS=$pkg_cv_AVAHI_CFLAGS
56149         AVAHI_LIBS=$pkg_cv_AVAHI_LIBS
56150         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
56151 $as_echo "yes" >&6; }
56152
56153       with_avahi=yes
56154
56155 fi
56156   fi
56157
56158   if test $fail = 1; then
56159     as_fn_error $? "You must install the avahi-client >= 0.6.0 pkg-config module to compile libvirt" "$LINENO" 5
56160   fi
56161
56162   if test "x$with_avahi" = "xyes" ; then
56163
56164 cat >>confdefs.h <<_ACEOF
56165 #define WITH_AVAHI 1
56166 _ACEOF
56167
56168   fi
56169
56170    if test "x$with_avahi" = "xyes"; then
56171   WITH_AVAHI_TRUE=
56172   WITH_AVAHI_FALSE='#'
56173 else
56174   WITH_AVAHI_TRUE='#'
56175   WITH_AVAHI_FALSE=
56176 fi
56177
56178
56179
56180
56181
56182
56183
56184
56185
56186
56187
56188
56189
56190
56191
56192
56193
56194
56195
56196
56197
56198
56199
56200
56201
56202
56203
56204
56205
56206
56207
56208
56209
56210
56211
56212 # Check whether --with-blkid was given.
56213 if test "${with_blkid+set}" = set; then :
56214   withval=$with_blkid;
56215 fi
56216
56217
56218   fail=0
56219   if test "x$with_blkid" != "xno" ; then
56220
56221 pkg_failed=no
56222 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BLKID" >&5
56223 $as_echo_n "checking for BLKID... " >&6; }
56224
56225 if test -n "$BLKID_CFLAGS"; then
56226     pkg_cv_BLKID_CFLAGS="$BLKID_CFLAGS"
56227  elif test -n "$PKG_CONFIG"; then
56228     if test -n "$PKG_CONFIG" && \
56229     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"blkid >= 2.17\""; } >&5
56230   ($PKG_CONFIG --exists --print-errors "blkid >= 2.17") 2>&5
56231   ac_status=$?
56232   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
56233   test $ac_status = 0; }; then
56234   pkg_cv_BLKID_CFLAGS=`$PKG_CONFIG --cflags "blkid >= 2.17" 2>/dev/null`
56235                       test "x$?" != "x0" && pkg_failed=yes
56236 else
56237   pkg_failed=yes
56238 fi
56239  else
56240     pkg_failed=untried
56241 fi
56242 if test -n "$BLKID_LIBS"; then
56243     pkg_cv_BLKID_LIBS="$BLKID_LIBS"
56244  elif test -n "$PKG_CONFIG"; then
56245     if test -n "$PKG_CONFIG" && \
56246     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"blkid >= 2.17\""; } >&5
56247   ($PKG_CONFIG --exists --print-errors "blkid >= 2.17") 2>&5
56248   ac_status=$?
56249   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
56250   test $ac_status = 0; }; then
56251   pkg_cv_BLKID_LIBS=`$PKG_CONFIG --libs "blkid >= 2.17" 2>/dev/null`
56252                       test "x$?" != "x0" && pkg_failed=yes
56253 else
56254   pkg_failed=yes
56255 fi
56256  else
56257     pkg_failed=untried
56258 fi
56259
56260
56261
56262 if test $pkg_failed = yes; then
56263         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
56264 $as_echo "no" >&6; }
56265
56266 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
56267         _pkg_short_errors_supported=yes
56268 else
56269         _pkg_short_errors_supported=no
56270 fi
56271         if test $_pkg_short_errors_supported = yes; then
56272                 BLKID_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "blkid >= 2.17" 2>&1`
56273         else
56274                 BLKID_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "blkid >= 2.17" 2>&1`
56275         fi
56276         # Put the nasty error message in config.log where it belongs
56277         echo "$BLKID_PKG_ERRORS" >&5
56278
56279
56280       if test "x$with_blkid" != "xcheck"; then
56281         fail=1
56282       fi
56283       with_blkid=no
56284
56285 elif test $pkg_failed = untried; then
56286         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
56287 $as_echo "no" >&6; }
56288
56289       if test "x$with_blkid" != "xcheck"; then
56290         fail=1
56291       fi
56292       with_blkid=no
56293
56294 else
56295         BLKID_CFLAGS=$pkg_cv_BLKID_CFLAGS
56296         BLKID_LIBS=$pkg_cv_BLKID_LIBS
56297         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
56298 $as_echo "yes" >&6; }
56299
56300       with_blkid=yes
56301
56302 fi
56303   fi
56304
56305   if test $fail = 1; then
56306     as_fn_error $? "You must install the blkid >= 2.17 pkg-config module to compile libvirt" "$LINENO" 5
56307   fi
56308
56309   if test "x$with_blkid" = "xyes" ; then
56310
56311 cat >>confdefs.h <<_ACEOF
56312 #define WITH_BLKID 1
56313 _ACEOF
56314
56315   fi
56316
56317    if test "x$with_blkid" = "xyes"; then
56318   WITH_BLKID_TRUE=
56319   WITH_BLKID_FALSE='#'
56320 else
56321   WITH_BLKID_TRUE='#'
56322   WITH_BLKID_FALSE=
56323 fi
56324
56325
56326
56327
56328
56329
56330
56331
56332
56333
56334
56335
56336
56337
56338
56339
56340
56341
56342
56343
56344
56345
56346
56347
56348
56349
56350
56351
56352
56353
56354
56355
56356
56357
56358
56359
56360 # Check whether --with-capng was given.
56361 if test "${with_capng+set}" = set; then :
56362   withval=$with_capng;
56363 fi
56364
56365
56366   old_LIBS=$LIBS
56367   old_CFLAGS=$CFLAGS
56368   CAPNG_CFLAGS=
56369   CAPNG_LIBS=
56370
56371   fail=0
56372   if test "x$with_capng" != "xno" ; then
56373     if test "x$with_capng" != "xyes" && test "x$with_capng" != "xcheck" ; then
56374       CAPNG_CFLAGS="-I$with_capng/include"
56375       CAPNG_LIBS="-L$with_capng/lib"
56376     fi
56377     CFLAGS="$CFLAGS $CAPNG_CFLAGS"
56378     LIBS="$LIBS $CAPNG_LIBS"
56379     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for capng_updatev in -lcap-ng" >&5
56380 $as_echo_n "checking for capng_updatev in -lcap-ng... " >&6; }
56381 if ${ac_cv_lib_cap_ng_capng_updatev+:} false; then :
56382   $as_echo_n "(cached) " >&6
56383 else
56384   ac_check_lib_save_LIBS=$LIBS
56385 LIBS="-lcap-ng  $LIBS"
56386 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
56387 /* end confdefs.h.  */
56388
56389 /* Override any GCC internal prototype to avoid an error.
56390    Use char because int might match the return type of a GCC
56391    builtin and then its argument prototype would still apply.  */
56392 #ifdef __cplusplus
56393 extern "C"
56394 #endif
56395 char capng_updatev ();
56396 int
56397 main ()
56398 {
56399 return capng_updatev ();
56400   ;
56401   return 0;
56402 }
56403 _ACEOF
56404 if ac_fn_c_try_link "$LINENO"; then :
56405   ac_cv_lib_cap_ng_capng_updatev=yes
56406 else
56407   ac_cv_lib_cap_ng_capng_updatev=no
56408 fi
56409 rm -f core conftest.err conftest.$ac_objext \
56410     conftest$ac_exeext conftest.$ac_ext
56411 LIBS=$ac_check_lib_save_LIBS
56412 fi
56413 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_cap_ng_capng_updatev" >&5
56414 $as_echo "$ac_cv_lib_cap_ng_capng_updatev" >&6; }
56415 if test "x$ac_cv_lib_cap_ng_capng_updatev" = xyes; then :
56416   cat >>confdefs.h <<_ACEOF
56417 #define HAVE_LIBCAP_NG 1
56418 _ACEOF
56419
56420   LIBS="-lcap-ng $LIBS"
56421
56422 else
56423
56424       if test "x$with_capng" != "xcheck"; then
56425         fail=1
56426       fi
56427       with_capng=no
56428
56429 fi
56430
56431     if test "$fail" = "0" && test "x$with_capng" != "xno" ; then
56432       ac_fn_c_check_header_mongrel "$LINENO" "cap-ng.h" "ac_cv_header_header_name" "$ac_includes_default"
56433 if test "x$ac_cv_header_header_name" = xyes; then :
56434
56435         with_capng=yes
56436
56437 else
56438
56439         if test "x$with_capng" != "xcheck"; then
56440           fail=1
56441         fi
56442         with_capng=no
56443
56444 fi
56445
56446
56447     fi
56448   fi
56449
56450   LIBS=$old_LIBS
56451   CFLAGS=$old_CFLAGS
56452
56453   if test $fail = 1; then
56454     as_fn_error $? "You must install the libcap-ng library & headers to compile libvirt" "$LINENO" 5
56455   else
56456     if test "x$with_capng" = "xyes" ; then
56457       if test "x$CAPNG_LIBS" = 'x' ; then
56458         CAPNG_LIBS="-lcap-ng"
56459       else
56460         CAPNG_LIBS="$CAPNG_LIBS -lcap-ng"
56461       fi
56462
56463 cat >>confdefs.h <<_ACEOF
56464 #define WITH_CAPNG 1
56465 _ACEOF
56466
56467     fi
56468
56469      if test "x$with_capng" = "xyes"; then
56470   WITH_CAPNG_TRUE=
56471   WITH_CAPNG_FALSE='#'
56472 else
56473   WITH_CAPNG_TRUE='#'
56474   WITH_CAPNG_FALSE=
56475 fi
56476
56477
56478
56479
56480   fi
56481
56482
56483
56484
56485
56486
56487
56488
56489
56490
56491
56492
56493
56494
56495
56496
56497
56498
56499
56500
56501
56502
56503
56504
56505
56506
56507
56508
56509
56510
56511
56512
56513
56514
56515
56516 # Check whether --with-curl was given.
56517 if test "${with_curl+set}" = set; then :
56518   withval=$with_curl;
56519 fi
56520
56521
56522   fail=0
56523   if test "x$with_curl" != "xno" ; then
56524
56525 pkg_failed=no
56526 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CURL" >&5
56527 $as_echo_n "checking for CURL... " >&6; }
56528
56529 if test -n "$CURL_CFLAGS"; then
56530     pkg_cv_CURL_CFLAGS="$CURL_CFLAGS"
56531  elif test -n "$PKG_CONFIG"; then
56532     if test -n "$PKG_CONFIG" && \
56533     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libcurl >= 7.18.0\""; } >&5
56534   ($PKG_CONFIG --exists --print-errors "libcurl >= 7.18.0") 2>&5
56535   ac_status=$?
56536   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
56537   test $ac_status = 0; }; then
56538   pkg_cv_CURL_CFLAGS=`$PKG_CONFIG --cflags "libcurl >= 7.18.0" 2>/dev/null`
56539                       test "x$?" != "x0" && pkg_failed=yes
56540 else
56541   pkg_failed=yes
56542 fi
56543  else
56544     pkg_failed=untried
56545 fi
56546 if test -n "$CURL_LIBS"; then
56547     pkg_cv_CURL_LIBS="$CURL_LIBS"
56548  elif test -n "$PKG_CONFIG"; then
56549     if test -n "$PKG_CONFIG" && \
56550     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libcurl >= 7.18.0\""; } >&5
56551   ($PKG_CONFIG --exists --print-errors "libcurl >= 7.18.0") 2>&5
56552   ac_status=$?
56553   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
56554   test $ac_status = 0; }; then
56555   pkg_cv_CURL_LIBS=`$PKG_CONFIG --libs "libcurl >= 7.18.0" 2>/dev/null`
56556                       test "x$?" != "x0" && pkg_failed=yes
56557 else
56558   pkg_failed=yes
56559 fi
56560  else
56561     pkg_failed=untried
56562 fi
56563
56564
56565
56566 if test $pkg_failed = yes; then
56567         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
56568 $as_echo "no" >&6; }
56569
56570 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
56571         _pkg_short_errors_supported=yes
56572 else
56573         _pkg_short_errors_supported=no
56574 fi
56575         if test $_pkg_short_errors_supported = yes; then
56576                 CURL_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libcurl >= 7.18.0" 2>&1`
56577         else
56578                 CURL_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libcurl >= 7.18.0" 2>&1`
56579         fi
56580         # Put the nasty error message in config.log where it belongs
56581         echo "$CURL_PKG_ERRORS" >&5
56582
56583
56584       if test "x$with_curl" != "xcheck"; then
56585         fail=1
56586       fi
56587       with_curl=no
56588
56589 elif test $pkg_failed = untried; then
56590         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
56591 $as_echo "no" >&6; }
56592
56593       if test "x$with_curl" != "xcheck"; then
56594         fail=1
56595       fi
56596       with_curl=no
56597
56598 else
56599         CURL_CFLAGS=$pkg_cv_CURL_CFLAGS
56600         CURL_LIBS=$pkg_cv_CURL_LIBS
56601         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
56602 $as_echo "yes" >&6; }
56603
56604       with_curl=yes
56605
56606 fi
56607   fi
56608
56609   if test $fail = 1; then
56610     as_fn_error $? "You must install the libcurl >= 7.18.0 pkg-config module to compile libvirt" "$LINENO" 5
56611   fi
56612
56613   if test "x$with_curl" = "xyes" ; then
56614
56615 cat >>confdefs.h <<_ACEOF
56616 #define WITH_CURL 1
56617 _ACEOF
56618
56619   fi
56620
56621    if test "x$with_curl" = "xyes"; then
56622   WITH_CURL_TRUE=
56623   WITH_CURL_FALSE='#'
56624 else
56625   WITH_CURL_TRUE='#'
56626   WITH_CURL_FALSE=
56627 fi
56628
56629
56630
56631
56632
56633
56634
56635
56636
56637
56638
56639
56640
56641
56642
56643
56644
56645   # XXX as of libcurl-devel-7.20.1-3.fc13.x86_64, curl ships a version
56646   # of <curl/curl.h> that #defines several wrapper macros around underlying
56647   # functions to add type safety for gcc only.  However, these macros
56648   # spuriously trip gcc's -Wlogical-op warning.  Avoid the warning by
56649   # disabling the wrappers; even if it removes some type-check safety.
56650   CURL_CFLAGS="-DCURL_DISABLE_TYPECHECK $CURL_CFLAGS"
56651
56652
56653
56654
56655
56656
56657
56658
56659
56660
56661
56662
56663
56664
56665
56666
56667
56668
56669
56670
56671 # Check whether --with-dbus was given.
56672 if test "${with_dbus+set}" = set; then :
56673   withval=$with_dbus;
56674 fi
56675
56676
56677   fail=0
56678   if test "x$with_dbus" != "xno" ; then
56679
56680 pkg_failed=no
56681 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DBUS" >&5
56682 $as_echo_n "checking for DBUS... " >&6; }
56683
56684 if test -n "$DBUS_CFLAGS"; then
56685     pkg_cv_DBUS_CFLAGS="$DBUS_CFLAGS"
56686  elif test -n "$PKG_CONFIG"; then
56687     if test -n "$PKG_CONFIG" && \
56688     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"dbus-1 >= 1.0.0\""; } >&5
56689   ($PKG_CONFIG --exists --print-errors "dbus-1 >= 1.0.0") 2>&5
56690   ac_status=$?
56691   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
56692   test $ac_status = 0; }; then
56693   pkg_cv_DBUS_CFLAGS=`$PKG_CONFIG --cflags "dbus-1 >= 1.0.0" 2>/dev/null`
56694                       test "x$?" != "x0" && pkg_failed=yes
56695 else
56696   pkg_failed=yes
56697 fi
56698  else
56699     pkg_failed=untried
56700 fi
56701 if test -n "$DBUS_LIBS"; then
56702     pkg_cv_DBUS_LIBS="$DBUS_LIBS"
56703  elif test -n "$PKG_CONFIG"; then
56704     if test -n "$PKG_CONFIG" && \
56705     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"dbus-1 >= 1.0.0\""; } >&5
56706   ($PKG_CONFIG --exists --print-errors "dbus-1 >= 1.0.0") 2>&5
56707   ac_status=$?
56708   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
56709   test $ac_status = 0; }; then
56710   pkg_cv_DBUS_LIBS=`$PKG_CONFIG --libs "dbus-1 >= 1.0.0" 2>/dev/null`
56711                       test "x$?" != "x0" && pkg_failed=yes
56712 else
56713   pkg_failed=yes
56714 fi
56715  else
56716     pkg_failed=untried
56717 fi
56718
56719
56720
56721 if test $pkg_failed = yes; then
56722         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
56723 $as_echo "no" >&6; }
56724
56725 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
56726         _pkg_short_errors_supported=yes
56727 else
56728         _pkg_short_errors_supported=no
56729 fi
56730         if test $_pkg_short_errors_supported = yes; then
56731                 DBUS_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "dbus-1 >= 1.0.0" 2>&1`
56732         else
56733                 DBUS_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "dbus-1 >= 1.0.0" 2>&1`
56734         fi
56735         # Put the nasty error message in config.log where it belongs
56736         echo "$DBUS_PKG_ERRORS" >&5
56737
56738
56739       if test "x$with_dbus" != "xcheck"; then
56740         fail=1
56741       fi
56742       with_dbus=no
56743
56744 elif test $pkg_failed = untried; then
56745         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
56746 $as_echo "no" >&6; }
56747
56748       if test "x$with_dbus" != "xcheck"; then
56749         fail=1
56750       fi
56751       with_dbus=no
56752
56753 else
56754         DBUS_CFLAGS=$pkg_cv_DBUS_CFLAGS
56755         DBUS_LIBS=$pkg_cv_DBUS_LIBS
56756         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
56757 $as_echo "yes" >&6; }
56758
56759       with_dbus=yes
56760
56761 fi
56762   fi
56763
56764   if test $fail = 1; then
56765     as_fn_error $? "You must install the dbus-1 >= 1.0.0 pkg-config module to compile libvirt" "$LINENO" 5
56766   fi
56767
56768   if test "x$with_dbus" = "xyes" ; then
56769
56770 cat >>confdefs.h <<_ACEOF
56771 #define WITH_DBUS 1
56772 _ACEOF
56773
56774   fi
56775
56776    if test "x$with_dbus" = "xyes"; then
56777   WITH_DBUS_TRUE=
56778   WITH_DBUS_FALSE='#'
56779 else
56780   WITH_DBUS_TRUE='#'
56781   WITH_DBUS_FALSE=
56782 fi
56783
56784
56785
56786
56787
56788
56789
56790
56791
56792
56793
56794
56795
56796
56797
56798
56799
56800   if test "$with_dbus" = "yes" ; then
56801     old_CFLAGS="$CFLAGS"
56802     old_LIBS="$LIBS"
56803     CFLAGS="$CFLAGS $DBUS_CFLAGS"
56804     LIBS="$LIBS $DBUS_LIBS"
56805     for ac_func in dbus_watch_get_unix_fd
56806 do :
56807   ac_fn_c_check_func "$LINENO" "dbus_watch_get_unix_fd" "ac_cv_func_dbus_watch_get_unix_fd"
56808 if test "x$ac_cv_func_dbus_watch_get_unix_fd" = xyes; then :
56809   cat >>confdefs.h <<_ACEOF
56810 #define HAVE_DBUS_WATCH_GET_UNIX_FD 1
56811 _ACEOF
56812
56813 fi
56814 done
56815
56816     CFLAGS="$old_CFLAGS"
56817     LIBS="$old_LIBS"
56818   fi
56819
56820
56821
56822
56823
56824
56825
56826
56827
56828
56829
56830
56831
56832
56833
56834
56835
56836
56837
56838 # Check whether --with-fuse was given.
56839 if test "${with_fuse+set}" = set; then :
56840   withval=$with_fuse;
56841 fi
56842
56843
56844   fail=0
56845   if test "x$with_fuse" != "xno" ; then
56846
56847 pkg_failed=no
56848 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FUSE" >&5
56849 $as_echo_n "checking for FUSE... " >&6; }
56850
56851 if test -n "$FUSE_CFLAGS"; then
56852     pkg_cv_FUSE_CFLAGS="$FUSE_CFLAGS"
56853  elif test -n "$PKG_CONFIG"; then
56854     if test -n "$PKG_CONFIG" && \
56855     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"fuse >= 2.8.6\""; } >&5
56856   ($PKG_CONFIG --exists --print-errors "fuse >= 2.8.6") 2>&5
56857   ac_status=$?
56858   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
56859   test $ac_status = 0; }; then
56860   pkg_cv_FUSE_CFLAGS=`$PKG_CONFIG --cflags "fuse >= 2.8.6" 2>/dev/null`
56861                       test "x$?" != "x0" && pkg_failed=yes
56862 else
56863   pkg_failed=yes
56864 fi
56865  else
56866     pkg_failed=untried
56867 fi
56868 if test -n "$FUSE_LIBS"; then
56869     pkg_cv_FUSE_LIBS="$FUSE_LIBS"
56870  elif test -n "$PKG_CONFIG"; then
56871     if test -n "$PKG_CONFIG" && \
56872     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"fuse >= 2.8.6\""; } >&5
56873   ($PKG_CONFIG --exists --print-errors "fuse >= 2.8.6") 2>&5
56874   ac_status=$?
56875   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
56876   test $ac_status = 0; }; then
56877   pkg_cv_FUSE_LIBS=`$PKG_CONFIG --libs "fuse >= 2.8.6" 2>/dev/null`
56878                       test "x$?" != "x0" && pkg_failed=yes
56879 else
56880   pkg_failed=yes
56881 fi
56882  else
56883     pkg_failed=untried
56884 fi
56885
56886
56887
56888 if test $pkg_failed = yes; then
56889         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
56890 $as_echo "no" >&6; }
56891
56892 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
56893         _pkg_short_errors_supported=yes
56894 else
56895         _pkg_short_errors_supported=no
56896 fi
56897         if test $_pkg_short_errors_supported = yes; then
56898                 FUSE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "fuse >= 2.8.6" 2>&1`
56899         else
56900                 FUSE_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "fuse >= 2.8.6" 2>&1`
56901         fi
56902         # Put the nasty error message in config.log where it belongs
56903         echo "$FUSE_PKG_ERRORS" >&5
56904
56905
56906       if test "x$with_fuse" != "xcheck"; then
56907         fail=1
56908       fi
56909       with_fuse=no
56910
56911 elif test $pkg_failed = untried; then
56912         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
56913 $as_echo "no" >&6; }
56914
56915       if test "x$with_fuse" != "xcheck"; then
56916         fail=1
56917       fi
56918       with_fuse=no
56919
56920 else
56921         FUSE_CFLAGS=$pkg_cv_FUSE_CFLAGS
56922         FUSE_LIBS=$pkg_cv_FUSE_LIBS
56923         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
56924 $as_echo "yes" >&6; }
56925
56926       with_fuse=yes
56927
56928 fi
56929   fi
56930
56931   if test $fail = 1; then
56932     as_fn_error $? "You must install the fuse >= 2.8.6 pkg-config module to compile libvirt" "$LINENO" 5
56933   fi
56934
56935   if test "x$with_fuse" = "xyes" ; then
56936
56937 cat >>confdefs.h <<_ACEOF
56938 #define WITH_FUSE 1
56939 _ACEOF
56940
56941   fi
56942
56943    if test "x$with_fuse" = "xyes"; then
56944   WITH_FUSE_TRUE=
56945   WITH_FUSE_FALSE='#'
56946 else
56947   WITH_FUSE_TRUE='#'
56948   WITH_FUSE_FALSE=
56949 fi
56950
56951
56952
56953
56954
56955
56956
56957
56958
56959
56960
56961
56962
56963
56964
56965
56966
56967
56968
56969
56970
56971
56972
56973
56974
56975
56976
56977
56978
56979
56980
56981
56982
56983
56984
56985 # Check whether --with-glusterfs was given.
56986 if test "${with_glusterfs+set}" = set; then :
56987   withval=$with_glusterfs;
56988 fi
56989
56990
56991   fail=0
56992   if test "x$with_glusterfs" != "xno" ; then
56993
56994 pkg_failed=no
56995 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GLUSTERFS" >&5
56996 $as_echo_n "checking for GLUSTERFS... " >&6; }
56997
56998 if test -n "$GLUSTERFS_CFLAGS"; then
56999     pkg_cv_GLUSTERFS_CFLAGS="$GLUSTERFS_CFLAGS"
57000  elif test -n "$PKG_CONFIG"; then
57001     if test -n "$PKG_CONFIG" && \
57002     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"glusterfs-api >= 3.4.1\""; } >&5
57003   ($PKG_CONFIG --exists --print-errors "glusterfs-api >= 3.4.1") 2>&5
57004   ac_status=$?
57005   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
57006   test $ac_status = 0; }; then
57007   pkg_cv_GLUSTERFS_CFLAGS=`$PKG_CONFIG --cflags "glusterfs-api >= 3.4.1" 2>/dev/null`
57008                       test "x$?" != "x0" && pkg_failed=yes
57009 else
57010   pkg_failed=yes
57011 fi
57012  else
57013     pkg_failed=untried
57014 fi
57015 if test -n "$GLUSTERFS_LIBS"; then
57016     pkg_cv_GLUSTERFS_LIBS="$GLUSTERFS_LIBS"
57017  elif test -n "$PKG_CONFIG"; then
57018     if test -n "$PKG_CONFIG" && \
57019     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"glusterfs-api >= 3.4.1\""; } >&5
57020   ($PKG_CONFIG --exists --print-errors "glusterfs-api >= 3.4.1") 2>&5
57021   ac_status=$?
57022   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
57023   test $ac_status = 0; }; then
57024   pkg_cv_GLUSTERFS_LIBS=`$PKG_CONFIG --libs "glusterfs-api >= 3.4.1" 2>/dev/null`
57025                       test "x$?" != "x0" && pkg_failed=yes
57026 else
57027   pkg_failed=yes
57028 fi
57029  else
57030     pkg_failed=untried
57031 fi
57032
57033
57034
57035 if test $pkg_failed = yes; then
57036         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
57037 $as_echo "no" >&6; }
57038
57039 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
57040         _pkg_short_errors_supported=yes
57041 else
57042         _pkg_short_errors_supported=no
57043 fi
57044         if test $_pkg_short_errors_supported = yes; then
57045                 GLUSTERFS_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "glusterfs-api >= 3.4.1" 2>&1`
57046         else
57047                 GLUSTERFS_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "glusterfs-api >= 3.4.1" 2>&1`
57048         fi
57049         # Put the nasty error message in config.log where it belongs
57050         echo "$GLUSTERFS_PKG_ERRORS" >&5
57051
57052
57053       if test "x$with_glusterfs" != "xcheck"; then
57054         fail=1
57055       fi
57056       with_glusterfs=no
57057
57058 elif test $pkg_failed = untried; then
57059         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
57060 $as_echo "no" >&6; }
57061
57062       if test "x$with_glusterfs" != "xcheck"; then
57063         fail=1
57064       fi
57065       with_glusterfs=no
57066
57067 else
57068         GLUSTERFS_CFLAGS=$pkg_cv_GLUSTERFS_CFLAGS
57069         GLUSTERFS_LIBS=$pkg_cv_GLUSTERFS_LIBS
57070         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
57071 $as_echo "yes" >&6; }
57072
57073       with_glusterfs=yes
57074
57075 fi
57076   fi
57077
57078   if test $fail = 1; then
57079     as_fn_error $? "You must install the glusterfs-api >= 3.4.1 pkg-config module to compile libvirt" "$LINENO" 5
57080   fi
57081
57082   if test "x$with_glusterfs" = "xyes" ; then
57083
57084 cat >>confdefs.h <<_ACEOF
57085 #define WITH_GLUSTERFS 1
57086 _ACEOF
57087
57088   fi
57089
57090    if test "x$with_glusterfs" = "xyes"; then
57091   WITH_GLUSTERFS_TRUE=
57092   WITH_GLUSTERFS_FALSE='#'
57093 else
57094   WITH_GLUSTERFS_TRUE='#'
57095   WITH_GLUSTERFS_FALSE=
57096 fi
57097
57098
57099
57100
57101
57102
57103
57104
57105
57106
57107
57108
57109
57110
57111
57112
57113
57114
57115
57116
57117
57118
57119
57120
57121
57122
57123
57124
57125
57126
57127
57128
57129
57130
57131
57132 # Check whether --with-hal was given.
57133 if test "${with_hal+set}" = set; then :
57134   withval=$with_hal;
57135 fi
57136
57137
57138   fail=0
57139   if test "x$with_hal" != "xno" ; then
57140
57141 pkg_failed=no
57142 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HAL" >&5
57143 $as_echo_n "checking for HAL... " >&6; }
57144
57145 if test -n "$HAL_CFLAGS"; then
57146     pkg_cv_HAL_CFLAGS="$HAL_CFLAGS"
57147  elif test -n "$PKG_CONFIG"; then
57148     if test -n "$PKG_CONFIG" && \
57149     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"hal >= 0.5.0\""; } >&5
57150   ($PKG_CONFIG --exists --print-errors "hal >= 0.5.0") 2>&5
57151   ac_status=$?
57152   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
57153   test $ac_status = 0; }; then
57154   pkg_cv_HAL_CFLAGS=`$PKG_CONFIG --cflags "hal >= 0.5.0" 2>/dev/null`
57155                       test "x$?" != "x0" && pkg_failed=yes
57156 else
57157   pkg_failed=yes
57158 fi
57159  else
57160     pkg_failed=untried
57161 fi
57162 if test -n "$HAL_LIBS"; then
57163     pkg_cv_HAL_LIBS="$HAL_LIBS"
57164  elif test -n "$PKG_CONFIG"; then
57165     if test -n "$PKG_CONFIG" && \
57166     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"hal >= 0.5.0\""; } >&5
57167   ($PKG_CONFIG --exists --print-errors "hal >= 0.5.0") 2>&5
57168   ac_status=$?
57169   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
57170   test $ac_status = 0; }; then
57171   pkg_cv_HAL_LIBS=`$PKG_CONFIG --libs "hal >= 0.5.0" 2>/dev/null`
57172                       test "x$?" != "x0" && pkg_failed=yes
57173 else
57174   pkg_failed=yes
57175 fi
57176  else
57177     pkg_failed=untried
57178 fi
57179
57180
57181
57182 if test $pkg_failed = yes; then
57183         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
57184 $as_echo "no" >&6; }
57185
57186 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
57187         _pkg_short_errors_supported=yes
57188 else
57189         _pkg_short_errors_supported=no
57190 fi
57191         if test $_pkg_short_errors_supported = yes; then
57192                 HAL_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "hal >= 0.5.0" 2>&1`
57193         else
57194                 HAL_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "hal >= 0.5.0" 2>&1`
57195         fi
57196         # Put the nasty error message in config.log where it belongs
57197         echo "$HAL_PKG_ERRORS" >&5
57198
57199
57200       if test "x$with_hal" != "xcheck"; then
57201         fail=1
57202       fi
57203       with_hal=no
57204
57205 elif test $pkg_failed = untried; then
57206         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
57207 $as_echo "no" >&6; }
57208
57209       if test "x$with_hal" != "xcheck"; then
57210         fail=1
57211       fi
57212       with_hal=no
57213
57214 else
57215         HAL_CFLAGS=$pkg_cv_HAL_CFLAGS
57216         HAL_LIBS=$pkg_cv_HAL_LIBS
57217         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
57218 $as_echo "yes" >&6; }
57219
57220       with_hal=yes
57221
57222 fi
57223   fi
57224
57225   if test $fail = 1; then
57226     as_fn_error $? "You must install the hal >= 0.5.0 pkg-config module to compile libvirt" "$LINENO" 5
57227   fi
57228
57229   if test "x$with_hal" = "xyes" ; then
57230
57231 cat >>confdefs.h <<_ACEOF
57232 #define WITH_HAL 1
57233 _ACEOF
57234
57235   fi
57236
57237    if test "x$with_hal" = "xyes"; then
57238   WITH_HAL_TRUE=
57239   WITH_HAL_FALSE='#'
57240 else
57241   WITH_HAL_TRUE='#'
57242   WITH_HAL_FALSE=
57243 fi
57244
57245
57246
57247
57248
57249
57250
57251
57252
57253
57254
57255
57256
57257
57258
57259
57260
57261
57262
57263
57264
57265
57266
57267
57268
57269
57270
57271
57272
57273
57274
57275
57276
57277
57278
57279 # Check whether --with-netcf was given.
57280 if test "${with_netcf+set}" = set; then :
57281   withval=$with_netcf;
57282 fi
57283
57284
57285   fail=0
57286   if test "x$with_netcf" != "xno" ; then
57287
57288 pkg_failed=no
57289 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NETCF" >&5
57290 $as_echo_n "checking for NETCF... " >&6; }
57291
57292 if test -n "$NETCF_CFLAGS"; then
57293     pkg_cv_NETCF_CFLAGS="$NETCF_CFLAGS"
57294  elif test -n "$PKG_CONFIG"; then
57295     if test -n "$PKG_CONFIG" && \
57296     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"netcf >= 0.1.4\""; } >&5
57297   ($PKG_CONFIG --exists --print-errors "netcf >= 0.1.4") 2>&5
57298   ac_status=$?
57299   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
57300   test $ac_status = 0; }; then
57301   pkg_cv_NETCF_CFLAGS=`$PKG_CONFIG --cflags "netcf >= 0.1.4" 2>/dev/null`
57302                       test "x$?" != "x0" && pkg_failed=yes
57303 else
57304   pkg_failed=yes
57305 fi
57306  else
57307     pkg_failed=untried
57308 fi
57309 if test -n "$NETCF_LIBS"; then
57310     pkg_cv_NETCF_LIBS="$NETCF_LIBS"
57311  elif test -n "$PKG_CONFIG"; then
57312     if test -n "$PKG_CONFIG" && \
57313     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"netcf >= 0.1.4\""; } >&5
57314   ($PKG_CONFIG --exists --print-errors "netcf >= 0.1.4") 2>&5
57315   ac_status=$?
57316   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
57317   test $ac_status = 0; }; then
57318   pkg_cv_NETCF_LIBS=`$PKG_CONFIG --libs "netcf >= 0.1.4" 2>/dev/null`
57319                       test "x$?" != "x0" && pkg_failed=yes
57320 else
57321   pkg_failed=yes
57322 fi
57323  else
57324     pkg_failed=untried
57325 fi
57326
57327
57328
57329 if test $pkg_failed = yes; then
57330         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
57331 $as_echo "no" >&6; }
57332
57333 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
57334         _pkg_short_errors_supported=yes
57335 else
57336         _pkg_short_errors_supported=no
57337 fi
57338         if test $_pkg_short_errors_supported = yes; then
57339                 NETCF_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "netcf >= 0.1.4" 2>&1`
57340         else
57341                 NETCF_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "netcf >= 0.1.4" 2>&1`
57342         fi
57343         # Put the nasty error message in config.log where it belongs
57344         echo "$NETCF_PKG_ERRORS" >&5
57345
57346
57347       if test "x$with_netcf" != "xcheck"; then
57348         fail=1
57349       fi
57350       with_netcf=no
57351
57352 elif test $pkg_failed = untried; then
57353         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
57354 $as_echo "no" >&6; }
57355
57356       if test "x$with_netcf" != "xcheck"; then
57357         fail=1
57358       fi
57359       with_netcf=no
57360
57361 else
57362         NETCF_CFLAGS=$pkg_cv_NETCF_CFLAGS
57363         NETCF_LIBS=$pkg_cv_NETCF_LIBS
57364         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
57365 $as_echo "yes" >&6; }
57366
57367       with_netcf=yes
57368
57369 fi
57370   fi
57371
57372   if test $fail = 1; then
57373     as_fn_error $? "You must install the netcf >= 0.1.4 pkg-config module to compile libvirt" "$LINENO" 5
57374   fi
57375
57376   if test "x$with_netcf" = "xyes" ; then
57377
57378 cat >>confdefs.h <<_ACEOF
57379 #define WITH_NETCF 1
57380 _ACEOF
57381
57382   fi
57383
57384    if test "x$with_netcf" = "xyes"; then
57385   WITH_NETCF_TRUE=
57386   WITH_NETCF_FALSE='#'
57387 else
57388   WITH_NETCF_TRUE='#'
57389   WITH_NETCF_FALSE=
57390 fi
57391
57392
57393
57394
57395
57396
57397
57398
57399
57400
57401
57402
57403
57404
57405
57406
57407
57408   if test "$with_netcf" = "yes" ; then
57409     old_CFLAGS="$CFLAGS"
57410     old_LIBS="$CFLAGS"
57411     CFLAGS="$CFLAGS $NETCF_CFLAGS"
57412     LIBS="$LIBS $NETCF_LIBS"
57413     ac_fn_c_check_func "$LINENO" "ncf_change_begin" "ac_cv_func_ncf_change_begin"
57414 if test "x$ac_cv_func_ncf_change_begin" = xyes; then :
57415   netcf_transactions=1
57416 else
57417   netcf_transactions=0
57418 fi
57419
57420     if test "$netcf_transactions" = "1" ; then
57421
57422 cat >>confdefs.h <<_ACEOF
57423 #define HAVE_NETCF_TRANSACTIONS 1
57424 _ACEOF
57425
57426     fi
57427     CFLAGS="$old_CFLAGS"
57428     LIBS="$old_LIBS"
57429   fi
57430
57431
57432
57433
57434
57435
57436
57437
57438
57439
57440
57441
57442
57443
57444
57445
57446
57447
57448
57449
57450 # Check whether --with-numactl was given.
57451 if test "${with_numactl+set}" = set; then :
57452   withval=$with_numactl;
57453 fi
57454
57455
57456   old_LIBS=$LIBS
57457   old_CFLAGS=$CFLAGS
57458   NUMACTL_CFLAGS=
57459   NUMACTL_LIBS=
57460
57461   fail=0
57462   if test "x$with_numactl" != "xno" ; then
57463     if test "x$with_numactl" != "xyes" && test "x$with_numactl" != "xcheck" ; then
57464       NUMACTL_CFLAGS="-I$with_numactl/include"
57465       NUMACTL_LIBS="-L$with_numactl/lib"
57466     fi
57467     CFLAGS="$CFLAGS $NUMACTL_CFLAGS"
57468     LIBS="$LIBS $NUMACTL_LIBS"
57469     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for numa_available in -lnuma" >&5
57470 $as_echo_n "checking for numa_available in -lnuma... " >&6; }
57471 if ${ac_cv_lib_numa_numa_available+:} false; then :
57472   $as_echo_n "(cached) " >&6
57473 else
57474   ac_check_lib_save_LIBS=$LIBS
57475 LIBS="-lnuma  $LIBS"
57476 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
57477 /* end confdefs.h.  */
57478
57479 /* Override any GCC internal prototype to avoid an error.
57480    Use char because int might match the return type of a GCC
57481    builtin and then its argument prototype would still apply.  */
57482 #ifdef __cplusplus
57483 extern "C"
57484 #endif
57485 char numa_available ();
57486 int
57487 main ()
57488 {
57489 return numa_available ();
57490   ;
57491   return 0;
57492 }
57493 _ACEOF
57494 if ac_fn_c_try_link "$LINENO"; then :
57495   ac_cv_lib_numa_numa_available=yes
57496 else
57497   ac_cv_lib_numa_numa_available=no
57498 fi
57499 rm -f core conftest.err conftest.$ac_objext \
57500     conftest$ac_exeext conftest.$ac_ext
57501 LIBS=$ac_check_lib_save_LIBS
57502 fi
57503 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_numa_numa_available" >&5
57504 $as_echo "$ac_cv_lib_numa_numa_available" >&6; }
57505 if test "x$ac_cv_lib_numa_numa_available" = xyes; then :
57506   cat >>confdefs.h <<_ACEOF
57507 #define HAVE_LIBNUMA 1
57508 _ACEOF
57509
57510   LIBS="-lnuma $LIBS"
57511
57512 else
57513
57514       if test "x$with_numactl" != "xcheck"; then
57515         fail=1
57516       fi
57517       with_numactl=no
57518
57519 fi
57520
57521     if test "$fail" = "0" && test "x$with_numactl" != "xno" ; then
57522       ac_fn_c_check_header_mongrel "$LINENO" "numa.h" "ac_cv_header_header_name" "$ac_includes_default"
57523 if test "x$ac_cv_header_header_name" = xyes; then :
57524
57525         with_numactl=yes
57526
57527 else
57528
57529         if test "x$with_numactl" != "xcheck"; then
57530           fail=1
57531         fi
57532         with_numactl=no
57533
57534 fi
57535
57536
57537     fi
57538   fi
57539
57540   LIBS=$old_LIBS
57541   CFLAGS=$old_CFLAGS
57542
57543   if test $fail = 1; then
57544     as_fn_error $? "You must install the libnuma library & headers to compile libvirt" "$LINENO" 5
57545   else
57546     if test "x$with_numactl" = "xyes" ; then
57547       if test "x$NUMACTL_LIBS" = 'x' ; then
57548         NUMACTL_LIBS="-lnuma"
57549       else
57550         NUMACTL_LIBS="$NUMACTL_LIBS -lnuma"
57551       fi
57552
57553 cat >>confdefs.h <<_ACEOF
57554 #define WITH_NUMACTL 1
57555 _ACEOF
57556
57557     fi
57558
57559      if test "x$with_numactl" = "xyes"; then
57560   WITH_NUMACTL_TRUE=
57561   WITH_NUMACTL_FALSE='#'
57562 else
57563   WITH_NUMACTL_TRUE='#'
57564   WITH_NUMACTL_FALSE=
57565 fi
57566
57567
57568
57569
57570   fi
57571
57572
57573
57574
57575
57576
57577
57578
57579
57580
57581
57582
57583
57584
57585
57586
57587
57588
57589
57590
57591
57592
57593
57594
57595
57596
57597
57598
57599
57600
57601
57602
57603
57604
57605
57606 # Check whether --with-openwsman was given.
57607 if test "${with_openwsman+set}" = set; then :
57608   withval=$with_openwsman;
57609 fi
57610
57611
57612   fail=0
57613   if test "x$with_openwsman" != "xno" ; then
57614
57615 pkg_failed=no
57616 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OPENWSMAN" >&5
57617 $as_echo_n "checking for OPENWSMAN... " >&6; }
57618
57619 if test -n "$OPENWSMAN_CFLAGS"; then
57620     pkg_cv_OPENWSMAN_CFLAGS="$OPENWSMAN_CFLAGS"
57621  elif test -n "$PKG_CONFIG"; then
57622     if test -n "$PKG_CONFIG" && \
57623     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"openwsman >= 2.2.3\""; } >&5
57624   ($PKG_CONFIG --exists --print-errors "openwsman >= 2.2.3") 2>&5
57625   ac_status=$?
57626   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
57627   test $ac_status = 0; }; then
57628   pkg_cv_OPENWSMAN_CFLAGS=`$PKG_CONFIG --cflags "openwsman >= 2.2.3" 2>/dev/null`
57629                       test "x$?" != "x0" && pkg_failed=yes
57630 else
57631   pkg_failed=yes
57632 fi
57633  else
57634     pkg_failed=untried
57635 fi
57636 if test -n "$OPENWSMAN_LIBS"; then
57637     pkg_cv_OPENWSMAN_LIBS="$OPENWSMAN_LIBS"
57638  elif test -n "$PKG_CONFIG"; then
57639     if test -n "$PKG_CONFIG" && \
57640     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"openwsman >= 2.2.3\""; } >&5
57641   ($PKG_CONFIG --exists --print-errors "openwsman >= 2.2.3") 2>&5
57642   ac_status=$?
57643   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
57644   test $ac_status = 0; }; then
57645   pkg_cv_OPENWSMAN_LIBS=`$PKG_CONFIG --libs "openwsman >= 2.2.3" 2>/dev/null`
57646                       test "x$?" != "x0" && pkg_failed=yes
57647 else
57648   pkg_failed=yes
57649 fi
57650  else
57651     pkg_failed=untried
57652 fi
57653
57654
57655
57656 if test $pkg_failed = yes; then
57657         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
57658 $as_echo "no" >&6; }
57659
57660 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
57661         _pkg_short_errors_supported=yes
57662 else
57663         _pkg_short_errors_supported=no
57664 fi
57665         if test $_pkg_short_errors_supported = yes; then
57666                 OPENWSMAN_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "openwsman >= 2.2.3" 2>&1`
57667         else
57668                 OPENWSMAN_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "openwsman >= 2.2.3" 2>&1`
57669         fi
57670         # Put the nasty error message in config.log where it belongs
57671         echo "$OPENWSMAN_PKG_ERRORS" >&5
57672
57673
57674       if test "x$with_openwsman" != "xcheck"; then
57675         fail=1
57676       fi
57677       with_openwsman=no
57678
57679 elif test $pkg_failed = untried; then
57680         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
57681 $as_echo "no" >&6; }
57682
57683       if test "x$with_openwsman" != "xcheck"; then
57684         fail=1
57685       fi
57686       with_openwsman=no
57687
57688 else
57689         OPENWSMAN_CFLAGS=$pkg_cv_OPENWSMAN_CFLAGS
57690         OPENWSMAN_LIBS=$pkg_cv_OPENWSMAN_LIBS
57691         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
57692 $as_echo "yes" >&6; }
57693
57694       with_openwsman=yes
57695
57696 fi
57697   fi
57698
57699   if test $fail = 1; then
57700     as_fn_error $? "You must install the openwsman >= 2.2.3 pkg-config module to compile libvirt" "$LINENO" 5
57701   fi
57702
57703   if test "x$with_openwsman" = "xyes" ; then
57704
57705 cat >>confdefs.h <<_ACEOF
57706 #define WITH_OPENWSMAN 1
57707 _ACEOF
57708
57709   fi
57710
57711    if test "x$with_openwsman" = "xyes"; then
57712   WITH_OPENWSMAN_TRUE=
57713   WITH_OPENWSMAN_FALSE='#'
57714 else
57715   WITH_OPENWSMAN_TRUE='#'
57716   WITH_OPENWSMAN_FALSE=
57717 fi
57718
57719
57720
57721
57722
57723
57724
57725
57726
57727
57728
57729
57730
57731
57732
57733
57734
57735
57736
57737
57738
57739
57740
57741
57742
57743
57744
57745
57746
57747
57748
57749
57750
57751
57752
57753 # Check whether --with-pciaccess was given.
57754 if test "${with_pciaccess+set}" = set; then :
57755   withval=$with_pciaccess;
57756 fi
57757
57758
57759   fail=0
57760   if test "x$with_pciaccess" != "xno" ; then
57761
57762 pkg_failed=no
57763 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PCIACCESS" >&5
57764 $as_echo_n "checking for PCIACCESS... " >&6; }
57765
57766 if test -n "$PCIACCESS_CFLAGS"; then
57767     pkg_cv_PCIACCESS_CFLAGS="$PCIACCESS_CFLAGS"
57768  elif test -n "$PKG_CONFIG"; then
57769     if test -n "$PKG_CONFIG" && \
57770     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"pciaccess >= 0.10.0\""; } >&5
57771   ($PKG_CONFIG --exists --print-errors "pciaccess >= 0.10.0") 2>&5
57772   ac_status=$?
57773   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
57774   test $ac_status = 0; }; then
57775   pkg_cv_PCIACCESS_CFLAGS=`$PKG_CONFIG --cflags "pciaccess >= 0.10.0" 2>/dev/null`
57776                       test "x$?" != "x0" && pkg_failed=yes
57777 else
57778   pkg_failed=yes
57779 fi
57780  else
57781     pkg_failed=untried
57782 fi
57783 if test -n "$PCIACCESS_LIBS"; then
57784     pkg_cv_PCIACCESS_LIBS="$PCIACCESS_LIBS"
57785  elif test -n "$PKG_CONFIG"; then
57786     if test -n "$PKG_CONFIG" && \
57787     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"pciaccess >= 0.10.0\""; } >&5
57788   ($PKG_CONFIG --exists --print-errors "pciaccess >= 0.10.0") 2>&5
57789   ac_status=$?
57790   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
57791   test $ac_status = 0; }; then
57792   pkg_cv_PCIACCESS_LIBS=`$PKG_CONFIG --libs "pciaccess >= 0.10.0" 2>/dev/null`
57793                       test "x$?" != "x0" && pkg_failed=yes
57794 else
57795   pkg_failed=yes
57796 fi
57797  else
57798     pkg_failed=untried
57799 fi
57800
57801
57802
57803 if test $pkg_failed = yes; then
57804         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
57805 $as_echo "no" >&6; }
57806
57807 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
57808         _pkg_short_errors_supported=yes
57809 else
57810         _pkg_short_errors_supported=no
57811 fi
57812         if test $_pkg_short_errors_supported = yes; then
57813                 PCIACCESS_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "pciaccess >= 0.10.0" 2>&1`
57814         else
57815                 PCIACCESS_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "pciaccess >= 0.10.0" 2>&1`
57816         fi
57817         # Put the nasty error message in config.log where it belongs
57818         echo "$PCIACCESS_PKG_ERRORS" >&5
57819
57820
57821       if test "x$with_pciaccess" != "xcheck"; then
57822         fail=1
57823       fi
57824       with_pciaccess=no
57825
57826 elif test $pkg_failed = untried; then
57827         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
57828 $as_echo "no" >&6; }
57829
57830       if test "x$with_pciaccess" != "xcheck"; then
57831         fail=1
57832       fi
57833       with_pciaccess=no
57834
57835 else
57836         PCIACCESS_CFLAGS=$pkg_cv_PCIACCESS_CFLAGS
57837         PCIACCESS_LIBS=$pkg_cv_PCIACCESS_LIBS
57838         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
57839 $as_echo "yes" >&6; }
57840
57841       with_pciaccess=yes
57842
57843 fi
57844   fi
57845
57846   if test $fail = 1; then
57847     as_fn_error $? "You must install the pciaccess >= 0.10.0 pkg-config module to compile libvirt" "$LINENO" 5
57848   fi
57849
57850   if test "x$with_pciaccess" = "xyes" ; then
57851
57852 cat >>confdefs.h <<_ACEOF
57853 #define WITH_PCIACCESS 1
57854 _ACEOF
57855
57856   fi
57857
57858    if test "x$with_pciaccess" = "xyes"; then
57859   WITH_PCIACCESS_TRUE=
57860   WITH_PCIACCESS_FALSE='#'
57861 else
57862   WITH_PCIACCESS_TRUE='#'
57863   WITH_PCIACCESS_FALSE=
57864 fi
57865
57866
57867
57868
57869
57870
57871
57872
57873
57874
57875
57876
57877
57878
57879
57880
57881
57882
57883   extra_LIBS=
57884   lv_saved_libs=$LIBS
57885   if test "x$with_readline" != xno; then
57886     # Linking with -lreadline may require some termcap-related code, e.g.,
57887     # from one of the following libraries.  Add it to LIBS before using
57888     # canned library checks; then verify later if it was needed.
57889     LIBS=
57890     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tgetent" >&5
57891 $as_echo_n "checking for library containing tgetent... " >&6; }
57892 if ${ac_cv_search_tgetent+:} false; then :
57893   $as_echo_n "(cached) " >&6
57894 else
57895   ac_func_search_save_LIBS=$LIBS
57896 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
57897 /* end confdefs.h.  */
57898
57899 /* Override any GCC internal prototype to avoid an error.
57900    Use char because int might match the return type of a GCC
57901    builtin and then its argument prototype would still apply.  */
57902 #ifdef __cplusplus
57903 extern "C"
57904 #endif
57905 char tgetent ();
57906 int
57907 main ()
57908 {
57909 return tgetent ();
57910   ;
57911   return 0;
57912 }
57913 _ACEOF
57914 for ac_lib in '' ncurses curses termcap termlib; do
57915   if test -z "$ac_lib"; then
57916     ac_res="none required"
57917   else
57918     ac_res=-l$ac_lib
57919     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
57920   fi
57921   if ac_fn_c_try_link "$LINENO"; then :
57922   ac_cv_search_tgetent=$ac_res
57923 fi
57924 rm -f core conftest.err conftest.$ac_objext \
57925     conftest$ac_exeext
57926   if ${ac_cv_search_tgetent+:} false; then :
57927   break
57928 fi
57929 done
57930 if ${ac_cv_search_tgetent+:} false; then :
57931
57932 else
57933   ac_cv_search_tgetent=no
57934 fi
57935 rm conftest.$ac_ext
57936 LIBS=$ac_func_search_save_LIBS
57937 fi
57938 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_tgetent" >&5
57939 $as_echo "$ac_cv_search_tgetent" >&6; }
57940 ac_res=$ac_cv_search_tgetent
57941 if test "$ac_res" != no; then :
57942   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
57943
57944 fi
57945
57946     case $LIBS in
57947       no*) ;;  # handle "no" and "none required"
57948       *) # anything else is a -lLIBRARY
57949         extra_LIBS=$LIBS ;;
57950     esac
57951     LIBS="$lv_saved_libs $extra_LIBS"
57952   fi
57953
57954   # The normal library check...
57955
57956
57957
57958
57959
57960
57961
57962
57963
57964
57965
57966
57967
57968
57969
57970
57971
57972
57973 # Check whether --with-readline was given.
57974 if test "${with_readline+set}" = set; then :
57975   withval=$with_readline;
57976 fi
57977
57978
57979   old_LIBS=$LIBS
57980   old_CFLAGS=$CFLAGS
57981   READLINE_CFLAGS=
57982   READLINE_LIBS=
57983
57984   fail=0
57985   if test "x$with_readline" != "xno" ; then
57986     if test "x$with_readline" != "xyes" && test "x$with_readline" != "xcheck" ; then
57987       READLINE_CFLAGS="-I$with_readline/include"
57988       READLINE_LIBS="-L$with_readline/lib"
57989     fi
57990     CFLAGS="$CFLAGS $READLINE_CFLAGS"
57991     LIBS="$LIBS $READLINE_LIBS"
57992     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for readline in -lreadline" >&5
57993 $as_echo_n "checking for readline in -lreadline... " >&6; }
57994 if ${ac_cv_lib_readline_readline+:} false; then :
57995   $as_echo_n "(cached) " >&6
57996 else
57997   ac_check_lib_save_LIBS=$LIBS
57998 LIBS="-lreadline  $LIBS"
57999 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
58000 /* end confdefs.h.  */
58001
58002 /* Override any GCC internal prototype to avoid an error.
58003    Use char because int might match the return type of a GCC
58004    builtin and then its argument prototype would still apply.  */
58005 #ifdef __cplusplus
58006 extern "C"
58007 #endif
58008 char readline ();
58009 int
58010 main ()
58011 {
58012 return readline ();
58013   ;
58014   return 0;
58015 }
58016 _ACEOF
58017 if ac_fn_c_try_link "$LINENO"; then :
58018   ac_cv_lib_readline_readline=yes
58019 else
58020   ac_cv_lib_readline_readline=no
58021 fi
58022 rm -f core conftest.err conftest.$ac_objext \
58023     conftest$ac_exeext conftest.$ac_ext
58024 LIBS=$ac_check_lib_save_LIBS
58025 fi
58026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_readline" >&5
58027 $as_echo "$ac_cv_lib_readline_readline" >&6; }
58028 if test "x$ac_cv_lib_readline_readline" = xyes; then :
58029   cat >>confdefs.h <<_ACEOF
58030 #define HAVE_LIBREADLINE 1
58031 _ACEOF
58032
58033   LIBS="-lreadline $LIBS"
58034
58035 else
58036
58037       if test "x$with_readline" != "xcheck"; then
58038         fail=1
58039       fi
58040       with_readline=no
58041
58042 fi
58043
58044     if test "$fail" = "0" && test "x$with_readline" != "xno" ; then
58045       ac_fn_c_check_header_mongrel "$LINENO" "readline/readline.h" "ac_cv_header_header_name" "$ac_includes_default"
58046 if test "x$ac_cv_header_header_name" = xyes; then :
58047
58048         with_readline=yes
58049
58050 else
58051
58052         if test "x$with_readline" != "xcheck"; then
58053           fail=1
58054         fi
58055         with_readline=no
58056
58057 fi
58058
58059
58060     fi
58061   fi
58062
58063   LIBS=$old_LIBS
58064   CFLAGS=$old_CFLAGS
58065
58066   if test $fail = 1; then
58067     as_fn_error $? "You must install the libreadline library & headers to compile libvirt" "$LINENO" 5
58068   else
58069     if test "x$with_readline" = "xyes" ; then
58070       if test "x$READLINE_LIBS" = 'x' ; then
58071         READLINE_LIBS="-lreadline"
58072       else
58073         READLINE_LIBS="$READLINE_LIBS -lreadline"
58074       fi
58075
58076 cat >>confdefs.h <<_ACEOF
58077 #define WITH_READLINE 1
58078 _ACEOF
58079
58080     fi
58081
58082      if test "x$with_readline" = "xyes"; then
58083   WITH_READLINE_TRUE=
58084   WITH_READLINE_FALSE='#'
58085 else
58086   WITH_READLINE_TRUE='#'
58087   WITH_READLINE_FALSE=
58088 fi
58089
58090
58091
58092
58093   fi
58094
58095
58096
58097
58098
58099
58100
58101
58102
58103
58104
58105
58106
58107
58108
58109
58110
58111   # Touch things up to avoid $extra_LIBS, if possible.  Test a second
58112   # function, to ensure we aren't being confused by caching.
58113   LIBS=$lv_saved_libs
58114   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for rl_initialize in -lreadline" >&5
58115 $as_echo_n "checking for rl_initialize in -lreadline... " >&6; }
58116 if ${ac_cv_lib_readline_rl_initialize+:} false; then :
58117   $as_echo_n "(cached) " >&6
58118 else
58119   ac_check_lib_save_LIBS=$LIBS
58120 LIBS="-lreadline  $LIBS"
58121 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
58122 /* end confdefs.h.  */
58123
58124 /* Override any GCC internal prototype to avoid an error.
58125    Use char because int might match the return type of a GCC
58126    builtin and then its argument prototype would still apply.  */
58127 #ifdef __cplusplus
58128 extern "C"
58129 #endif
58130 char rl_initialize ();
58131 int
58132 main ()
58133 {
58134 return rl_initialize ();
58135   ;
58136   return 0;
58137 }
58138 _ACEOF
58139 if ac_fn_c_try_link "$LINENO"; then :
58140   ac_cv_lib_readline_rl_initialize=yes
58141 else
58142   ac_cv_lib_readline_rl_initialize=no
58143 fi
58144 rm -f core conftest.err conftest.$ac_objext \
58145     conftest$ac_exeext conftest.$ac_ext
58146 LIBS=$ac_check_lib_save_LIBS
58147 fi
58148 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_readline_rl_initialize" >&5
58149 $as_echo "$ac_cv_lib_readline_rl_initialize" >&6; }
58150 if test "x$ac_cv_lib_readline_rl_initialize" = xyes; then :
58151   cat >>confdefs.h <<_ACEOF
58152 #define HAVE_LIBREADLINE 1
58153 _ACEOF
58154
58155   LIBS="-lreadline $LIBS"
58156
58157 else
58158   READLINE_LIBS="$READLINE_LIBS $extra_LIBS"
58159 fi
58160
58161   LIBS=$lv_saved_libs
58162
58163
58164
58165
58166
58167
58168
58169
58170
58171
58172
58173
58174
58175
58176
58177
58178
58179
58180
58181
58182 # Check whether --with-sanlock was given.
58183 if test "${with_sanlock+set}" = set; then :
58184   withval=$with_sanlock;
58185 fi
58186
58187
58188   old_LIBS=$LIBS
58189   old_CFLAGS=$CFLAGS
58190   SANLOCK_CFLAGS=
58191   SANLOCK_LIBS=
58192
58193   fail=0
58194   if test "x$with_sanlock" != "xno" ; then
58195     if test "x$with_sanlock" != "xyes" && test "x$with_sanlock" != "xcheck" ; then
58196       SANLOCK_CFLAGS="-I$with_sanlock/include"
58197       SANLOCK_LIBS="-L$with_sanlock/lib"
58198     fi
58199     CFLAGS="$CFLAGS $SANLOCK_CFLAGS"
58200     LIBS="$LIBS $SANLOCK_LIBS"
58201     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sanlock_init in -lsanlock_client" >&5
58202 $as_echo_n "checking for sanlock_init in -lsanlock_client... " >&6; }
58203 if ${ac_cv_lib_sanlock_client_sanlock_init+:} false; then :
58204   $as_echo_n "(cached) " >&6
58205 else
58206   ac_check_lib_save_LIBS=$LIBS
58207 LIBS="-lsanlock_client  $LIBS"
58208 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
58209 /* end confdefs.h.  */
58210
58211 /* Override any GCC internal prototype to avoid an error.
58212    Use char because int might match the return type of a GCC
58213    builtin and then its argument prototype would still apply.  */
58214 #ifdef __cplusplus
58215 extern "C"
58216 #endif
58217 char sanlock_init ();
58218 int
58219 main ()
58220 {
58221 return sanlock_init ();
58222   ;
58223   return 0;
58224 }
58225 _ACEOF
58226 if ac_fn_c_try_link "$LINENO"; then :
58227   ac_cv_lib_sanlock_client_sanlock_init=yes
58228 else
58229   ac_cv_lib_sanlock_client_sanlock_init=no
58230 fi
58231 rm -f core conftest.err conftest.$ac_objext \
58232     conftest$ac_exeext conftest.$ac_ext
58233 LIBS=$ac_check_lib_save_LIBS
58234 fi
58235 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_sanlock_client_sanlock_init" >&5
58236 $as_echo "$ac_cv_lib_sanlock_client_sanlock_init" >&6; }
58237 if test "x$ac_cv_lib_sanlock_client_sanlock_init" = xyes; then :
58238   cat >>confdefs.h <<_ACEOF
58239 #define HAVE_LIBSANLOCK_CLIENT 1
58240 _ACEOF
58241
58242   LIBS="-lsanlock_client $LIBS"
58243
58244 else
58245
58246       if test "x$with_sanlock" != "xcheck"; then
58247         fail=1
58248       fi
58249       with_sanlock=no
58250
58251 fi
58252
58253     if test "$fail" = "0" && test "x$with_sanlock" != "xno" ; then
58254       ac_fn_c_check_header_mongrel "$LINENO" "sanlock.h" "ac_cv_header_header_name" "$ac_includes_default"
58255 if test "x$ac_cv_header_header_name" = xyes; then :
58256
58257         with_sanlock=yes
58258
58259 else
58260
58261         if test "x$with_sanlock" != "xcheck"; then
58262           fail=1
58263         fi
58264         with_sanlock=no
58265
58266 fi
58267
58268
58269     fi
58270   fi
58271
58272   LIBS=$old_LIBS
58273   CFLAGS=$old_CFLAGS
58274
58275   if test $fail = 1; then
58276     as_fn_error $? "You must install the libsanlock_client library & headers to compile libvirt" "$LINENO" 5
58277   else
58278     if test "x$with_sanlock" = "xyes" ; then
58279       if test "x$SANLOCK_LIBS" = 'x' ; then
58280         SANLOCK_LIBS="-lsanlock_client"
58281       else
58282         SANLOCK_LIBS="$SANLOCK_LIBS -lsanlock_client"
58283       fi
58284
58285 cat >>confdefs.h <<_ACEOF
58286 #define WITH_SANLOCK 1
58287 _ACEOF
58288
58289     fi
58290
58291      if test "x$with_sanlock" = "xyes"; then
58292   WITH_SANLOCK_TRUE=
58293   WITH_SANLOCK_FALSE='#'
58294 else
58295   WITH_SANLOCK_TRUE='#'
58296   WITH_SANLOCK_FALSE=
58297 fi
58298
58299
58300
58301
58302   fi
58303
58304
58305
58306
58307
58308
58309
58310
58311
58312
58313
58314
58315
58316
58317
58318
58319
58320   if test "x$with_sanlock" = "xyes" ; then
58321     ac_fn_c_check_decl "$LINENO" "SANLK_INQ_WAIT" "ac_cv_have_decl_SANLK_INQ_WAIT" "
58322       #include <stdint.h>
58323       #include <sanlock_admin.h>
58324
58325 "
58326 if test "x$ac_cv_have_decl_SANLK_INQ_WAIT" = xyes; then :
58327   ac_have_decl=1
58328 else
58329   ac_have_decl=0
58330 fi
58331
58332 cat >>confdefs.h <<_ACEOF
58333 #define HAVE_DECL_SANLK_INQ_WAIT $ac_have_decl
58334 _ACEOF
58335 if test $ac_have_decl = 1; then :
58336   sanlock_inq_wait=1
58337 else
58338   sanlock_inq_wait=0
58339 fi
58340
58341
58342     old_cppflags="$CPPFLAGS"
58343     old_libs="$LIBS"
58344     CPPFLAGS="$CPPFLAGS $SANLOCK_CFLAGS"
58345     LIBS="$LIBS $SANLOCK_LIBS"
58346
58347     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sanlock_killpath in -lsanlock_client" >&5
58348 $as_echo_n "checking for sanlock_killpath in -lsanlock_client... " >&6; }
58349 if ${ac_cv_lib_sanlock_client_sanlock_killpath+:} false; then :
58350   $as_echo_n "(cached) " >&6
58351 else
58352   ac_check_lib_save_LIBS=$LIBS
58353 LIBS="-lsanlock_client  $LIBS"
58354 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
58355 /* end confdefs.h.  */
58356
58357 /* Override any GCC internal prototype to avoid an error.
58358    Use char because int might match the return type of a GCC
58359    builtin and then its argument prototype would still apply.  */
58360 #ifdef __cplusplus
58361 extern "C"
58362 #endif
58363 char sanlock_killpath ();
58364 int
58365 main ()
58366 {
58367 return sanlock_killpath ();
58368   ;
58369   return 0;
58370 }
58371 _ACEOF
58372 if ac_fn_c_try_link "$LINENO"; then :
58373   ac_cv_lib_sanlock_client_sanlock_killpath=yes
58374 else
58375   ac_cv_lib_sanlock_client_sanlock_killpath=no
58376 fi
58377 rm -f core conftest.err conftest.$ac_objext \
58378     conftest$ac_exeext conftest.$ac_ext
58379 LIBS=$ac_check_lib_save_LIBS
58380 fi
58381 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_sanlock_client_sanlock_killpath" >&5
58382 $as_echo "$ac_cv_lib_sanlock_client_sanlock_killpath" >&6; }
58383 if test "x$ac_cv_lib_sanlock_client_sanlock_killpath" = xyes; then :
58384   sanlock_killpath=yes
58385 else
58386   sanlock_killpath=no
58387 fi
58388
58389     if test "x$sanlock_killpath" = "xyes" ; then
58390
58391 cat >>confdefs.h <<_ACEOF
58392 #define HAVE_SANLOCK_KILLPATH 1
58393 _ACEOF
58394
58395     fi
58396
58397     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sanlock_inq_lockspace in -lsanlock_client" >&5
58398 $as_echo_n "checking for sanlock_inq_lockspace in -lsanlock_client... " >&6; }
58399 if ${ac_cv_lib_sanlock_client_sanlock_inq_lockspace+:} false; then :
58400   $as_echo_n "(cached) " >&6
58401 else
58402   ac_check_lib_save_LIBS=$LIBS
58403 LIBS="-lsanlock_client  $LIBS"
58404 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
58405 /* end confdefs.h.  */
58406
58407 /* Override any GCC internal prototype to avoid an error.
58408    Use char because int might match the return type of a GCC
58409    builtin and then its argument prototype would still apply.  */
58410 #ifdef __cplusplus
58411 extern "C"
58412 #endif
58413 char sanlock_inq_lockspace ();
58414 int
58415 main ()
58416 {
58417 return sanlock_inq_lockspace ();
58418   ;
58419   return 0;
58420 }
58421 _ACEOF
58422 if ac_fn_c_try_link "$LINENO"; then :
58423   ac_cv_lib_sanlock_client_sanlock_inq_lockspace=yes
58424 else
58425   ac_cv_lib_sanlock_client_sanlock_inq_lockspace=no
58426 fi
58427 rm -f core conftest.err conftest.$ac_objext \
58428     conftest$ac_exeext conftest.$ac_ext
58429 LIBS=$ac_check_lib_save_LIBS
58430 fi
58431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_sanlock_client_sanlock_inq_lockspace" >&5
58432 $as_echo "$ac_cv_lib_sanlock_client_sanlock_inq_lockspace" >&6; }
58433 if test "x$ac_cv_lib_sanlock_client_sanlock_inq_lockspace" = xyes; then :
58434   sanlock_inq_lockspace=yes
58435 else
58436   sanlock_inq_lockspace=no
58437 fi
58438
58439     if test "x$sanlock_inq_lockspace" = "xyes" && \
58440        test $sanlock_inq_wait = 1; then
58441
58442 cat >>confdefs.h <<_ACEOF
58443 #define HAVE_SANLOCK_INQ_LOCKSPACE 1
58444 _ACEOF
58445
58446     fi
58447
58448     CPPFLAGS="$old_cppflags"
58449     LIBS="$old_libs"
58450   fi
58451
58452
58453
58454
58455
58456
58457
58458
58459
58460
58461
58462
58463
58464
58465
58466
58467
58468
58469
58470
58471
58472
58473
58474
58475
58476
58477 # Check whether --with-sasl was given.
58478 if test "${with_sasl+set}" = set; then :
58479   withval=$with_sasl;
58480 fi
58481
58482
58483   old_LIBS=$LIBS
58484   old_CFLAGS=$CFLAGS
58485   SASL_CFLAGS=
58486   SASL_LIBS=
58487
58488   fail=0
58489   alt=0
58490   if test "x$with_sasl" != "xno" ; then
58491     if test "x$with_sasl" != "xyes" && test "x$with_sasl" != "xcheck" ; then
58492       SASL_CFLAGS="-I$with_sasl/include"
58493       SASL_LIBS="-L$with_sasl/lib"
58494     fi
58495     CFLAGS="$CFLAGS $SASL_CFLAGS"
58496     LIBS="$LIBS $SASL_LIBS"
58497     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sasl_client_init in -lsasl2" >&5
58498 $as_echo_n "checking for sasl_client_init in -lsasl2... " >&6; }
58499 if ${ac_cv_lib_sasl2_sasl_client_init+:} false; then :
58500   $as_echo_n "(cached) " >&6
58501 else
58502   ac_check_lib_save_LIBS=$LIBS
58503 LIBS="-lsasl2  $LIBS"
58504 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
58505 /* end confdefs.h.  */
58506
58507 /* Override any GCC internal prototype to avoid an error.
58508    Use char because int might match the return type of a GCC
58509    builtin and then its argument prototype would still apply.  */
58510 #ifdef __cplusplus
58511 extern "C"
58512 #endif
58513 char sasl_client_init ();
58514 int
58515 main ()
58516 {
58517 return sasl_client_init ();
58518   ;
58519   return 0;
58520 }
58521 _ACEOF
58522 if ac_fn_c_try_link "$LINENO"; then :
58523   ac_cv_lib_sasl2_sasl_client_init=yes
58524 else
58525   ac_cv_lib_sasl2_sasl_client_init=no
58526 fi
58527 rm -f core conftest.err conftest.$ac_objext \
58528     conftest$ac_exeext conftest.$ac_ext
58529 LIBS=$ac_check_lib_save_LIBS
58530 fi
58531 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_sasl2_sasl_client_init" >&5
58532 $as_echo "$ac_cv_lib_sasl2_sasl_client_init" >&6; }
58533 if test "x$ac_cv_lib_sasl2_sasl_client_init" = xyes; then :
58534   cat >>confdefs.h <<_ACEOF
58535 #define HAVE_LIBSASL2 1
58536 _ACEOF
58537
58538   LIBS="-lsasl2 $LIBS"
58539
58540 else
58541
58542       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sasl_client_init in -lsasl" >&5
58543 $as_echo_n "checking for sasl_client_init in -lsasl... " >&6; }
58544 if ${ac_cv_lib_sasl_sasl_client_init+:} false; then :
58545   $as_echo_n "(cached) " >&6
58546 else
58547   ac_check_lib_save_LIBS=$LIBS
58548 LIBS="-lsasl  $LIBS"
58549 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
58550 /* end confdefs.h.  */
58551
58552 /* Override any GCC internal prototype to avoid an error.
58553    Use char because int might match the return type of a GCC
58554    builtin and then its argument prototype would still apply.  */
58555 #ifdef __cplusplus
58556 extern "C"
58557 #endif
58558 char sasl_client_init ();
58559 int
58560 main ()
58561 {
58562 return sasl_client_init ();
58563   ;
58564   return 0;
58565 }
58566 _ACEOF
58567 if ac_fn_c_try_link "$LINENO"; then :
58568   ac_cv_lib_sasl_sasl_client_init=yes
58569 else
58570   ac_cv_lib_sasl_sasl_client_init=no
58571 fi
58572 rm -f core conftest.err conftest.$ac_objext \
58573     conftest$ac_exeext conftest.$ac_ext
58574 LIBS=$ac_check_lib_save_LIBS
58575 fi
58576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_sasl_sasl_client_init" >&5
58577 $as_echo "$ac_cv_lib_sasl_sasl_client_init" >&6; }
58578 if test "x$ac_cv_lib_sasl_sasl_client_init" = xyes; then :
58579
58580         alt=1
58581
58582 else
58583
58584         if test "x$with_sasl" != "xcheck"; then
58585           fail=1
58586         fi
58587         with_sasl=no
58588
58589 fi
58590
58591
58592 fi
58593
58594     if test "$fail" = "0" && test "x$with_sasl" != "xno" ; then
58595       ac_fn_c_check_header_mongrel "$LINENO" "sasl/sasl.h" "ac_cv_header_header_name" "$ac_includes_default"
58596 if test "x$ac_cv_header_header_name" = xyes; then :
58597
58598         with_sasl=yes
58599
58600 else
58601
58602         ac_fn_c_check_header_mongrel "$LINENO" "sasl/sasl.h" "ac_cv_header_header_name_alt" "$ac_includes_default"
58603 if test "x$ac_cv_header_header_name_alt" = xyes; then :
58604
58605           with_sasl=yes
58606
58607 else
58608
58609           if test "x$with_sasl" != "xcheck"; then
58610             fail=1
58611           fi
58612           with_sasl=no
58613
58614 fi
58615
58616
58617
58618 fi
58619
58620
58621     fi
58622   fi
58623
58624   LIBS=$old_LIBS
58625   CFLAGS=$old_CFLAGS
58626
58627   if test $fail = 1; then
58628     as_fn_error $? "You must install the libsasl2 library & headers to compile libvirt" "$LINENO" 5
58629   else
58630     if test "x$with_sasl" = "xyes" ; then
58631       if test "x$SASL_LIBS" = 'x' ; then
58632         SASL_LIBS="-lsasl2"
58633       else
58634         SASL_LIBS="$SASL_LIBS -lsasl2"
58635       fi
58636
58637
58638 cat >>confdefs.h <<_ACEOF
58639 #define WITH_SASL 1
58640 _ACEOF
58641
58642       if test "$alt" = "1" ; then
58643
58644 cat >>confdefs.h <<_ACEOF
58645 #define WITH_SASL1 1
58646 _ACEOF
58647
58648       fi
58649     fi
58650
58651      if test "x$with_sasl" = "xyes"; then
58652   WITH_SASL_TRUE=
58653   WITH_SASL_FALSE='#'
58654 else
58655   WITH_SASL_TRUE='#'
58656   WITH_SASL_FALSE=
58657 fi
58658
58659      if test "x$with_sasl" = "xyes" && test "$alt" = "1"; then
58660   WITH_SASL1_TRUE=
58661   WITH_SASL1_FALSE='#'
58662 else
58663   WITH_SASL1_TRUE='#'
58664   WITH_SASL1_FALSE=
58665 fi
58666
58667
58668
58669
58670   fi
58671
58672
58673
58674
58675
58676
58677
58678
58679
58680
58681
58682
58683
58684
58685
58686
58687
58688
58689
58690
58691
58692
58693
58694
58695
58696
58697
58698
58699
58700
58701
58702
58703
58704
58705
58706
58707
58708
58709
58710
58711
58712 # Check whether --with-selinux was given.
58713 if test "${with_selinux+set}" = set; then :
58714   withval=$with_selinux;
58715 fi
58716
58717
58718   old_LIBS=$LIBS
58719   old_CFLAGS=$CFLAGS
58720   SELINUX_CFLAGS=
58721   SELINUX_LIBS=
58722
58723   fail=0
58724   if test "x$with_selinux" != "xno" ; then
58725     if test "x$with_selinux" != "xyes" && test "x$with_selinux" != "xcheck" ; then
58726       SELINUX_CFLAGS="-I$with_selinux/include"
58727       SELINUX_LIBS="-L$with_selinux/lib"
58728     fi
58729     CFLAGS="$CFLAGS $SELINUX_CFLAGS"
58730     LIBS="$LIBS $SELINUX_LIBS"
58731     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgetfilecon_raw in -lselinux" >&5
58732 $as_echo_n "checking for fgetfilecon_raw in -lselinux... " >&6; }
58733 if ${ac_cv_lib_selinux_fgetfilecon_raw+:} false; then :
58734   $as_echo_n "(cached) " >&6
58735 else
58736   ac_check_lib_save_LIBS=$LIBS
58737 LIBS="-lselinux  $LIBS"
58738 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
58739 /* end confdefs.h.  */
58740
58741 /* Override any GCC internal prototype to avoid an error.
58742    Use char because int might match the return type of a GCC
58743    builtin and then its argument prototype would still apply.  */
58744 #ifdef __cplusplus
58745 extern "C"
58746 #endif
58747 char fgetfilecon_raw ();
58748 int
58749 main ()
58750 {
58751 return fgetfilecon_raw ();
58752   ;
58753   return 0;
58754 }
58755 _ACEOF
58756 if ac_fn_c_try_link "$LINENO"; then :
58757   ac_cv_lib_selinux_fgetfilecon_raw=yes
58758 else
58759   ac_cv_lib_selinux_fgetfilecon_raw=no
58760 fi
58761 rm -f core conftest.err conftest.$ac_objext \
58762     conftest$ac_exeext conftest.$ac_ext
58763 LIBS=$ac_check_lib_save_LIBS
58764 fi
58765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_selinux_fgetfilecon_raw" >&5
58766 $as_echo "$ac_cv_lib_selinux_fgetfilecon_raw" >&6; }
58767 if test "x$ac_cv_lib_selinux_fgetfilecon_raw" = xyes; then :
58768   cat >>confdefs.h <<_ACEOF
58769 #define HAVE_LIBSELINUX 1
58770 _ACEOF
58771
58772   LIBS="-lselinux $LIBS"
58773
58774 else
58775
58776       if test "x$with_selinux" != "xcheck"; then
58777         fail=1
58778       fi
58779       with_selinux=no
58780
58781 fi
58782
58783     if test "$fail" = "0" && test "x$with_selinux" != "xno" ; then
58784       ac_fn_c_check_header_mongrel "$LINENO" "selinux/selinux.h" "ac_cv_header_header_name" "$ac_includes_default"
58785 if test "x$ac_cv_header_header_name" = xyes; then :
58786
58787         with_selinux=yes
58788
58789 else
58790
58791         if test "x$with_selinux" != "xcheck"; then
58792           fail=1
58793         fi
58794         with_selinux=no
58795
58796 fi
58797
58798
58799     fi
58800   fi
58801
58802   LIBS=$old_LIBS
58803   CFLAGS=$old_CFLAGS
58804
58805   if test $fail = 1; then
58806     as_fn_error $? "You must install the libselinux library & headers to compile libvirt" "$LINENO" 5
58807   else
58808     if test "x$with_selinux" = "xyes" ; then
58809       if test "x$SELINUX_LIBS" = 'x' ; then
58810         SELINUX_LIBS="-lselinux"
58811       else
58812         SELINUX_LIBS="$SELINUX_LIBS -lselinux"
58813       fi
58814
58815 cat >>confdefs.h <<_ACEOF
58816 #define WITH_SELINUX 1
58817 _ACEOF
58818
58819     fi
58820
58821      if test "x$with_selinux" = "xyes"; then
58822   WITH_SELINUX_TRUE=
58823   WITH_SELINUX_FALSE='#'
58824 else
58825   WITH_SELINUX_TRUE='#'
58826   WITH_SELINUX_FALSE=
58827 fi
58828
58829
58830
58831
58832   fi
58833
58834
58835
58836
58837
58838
58839
58840
58841
58842
58843
58844
58845
58846
58847
58848
58849
58850
58851 # Check whether --with-selinux_mount was given.
58852 if test "${with_selinux_mount+set}" = set; then :
58853   withval=$with_selinux_mount;
58854 else
58855   with_selinux_mount=check
58856 fi
58857
58858
58859   if test "$with_selinux" = "yes"; then
58860     # libselinux changed signatures between 2.2 and 2.3
58861     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for selinux setcon parameter type" >&5
58862 $as_echo_n "checking for selinux setcon parameter type... " >&6; }
58863 if ${lv_cv_setcon_const+:} false; then :
58864   $as_echo_n "(cached) " >&6
58865 else
58866   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
58867 /* end confdefs.h.  */
58868
58869 #include <selinux/selinux.h>
58870 int setcon(char *context);
58871
58872 int
58873 main ()
58874 {
58875
58876   ;
58877   return 0;
58878 }
58879 _ACEOF
58880 if ac_fn_c_try_compile "$LINENO"; then :
58881   lv_cv_setcon_const=''
58882 else
58883   lv_cv_setcon_const='const'
58884 fi
58885 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
58886 fi
58887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lv_cv_setcon_const" >&5
58888 $as_echo "$lv_cv_setcon_const" >&6; }
58889
58890 cat >>confdefs.h <<_ACEOF
58891 #define VIR_SELINUX_CTX_CONST $lv_cv_setcon_const
58892 _ACEOF
58893
58894
58895     { $as_echo "$as_me:${as_lineno-$LINENO}: checking SELinux mount point" >&5
58896 $as_echo_n "checking SELinux mount point... " >&6; }
58897     if test "$with_selinux_mount" = "check" || test -z "$with_selinux_mount"; then
58898       if test -d /sys/fs/selinux ; then
58899         SELINUX_MOUNT=/sys/fs/selinux
58900       else
58901         SELINUX_MOUNT=/selinux
58902       fi
58903     else
58904       SELINUX_MOUNT=$with_selinux_mount
58905     fi
58906     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SELINUX_MOUNT" >&5
58907 $as_echo "$SELINUX_MOUNT" >&6; }
58908
58909 cat >>confdefs.h <<_ACEOF
58910 #define SELINUX_MOUNT "$SELINUX_MOUNT"
58911 _ACEOF
58912
58913
58914             for ac_header in selinux/label.h
58915 do :
58916   ac_fn_c_check_header_mongrel "$LINENO" "selinux/label.h" "ac_cv_header_selinux_label_h" "$ac_includes_default"
58917 if test "x$ac_cv_header_selinux_label_h" = xyes; then :
58918   cat >>confdefs.h <<_ACEOF
58919 #define HAVE_SELINUX_LABEL_H 1
58920 _ACEOF
58921
58922 fi
58923
58924 done
58925
58926   fi
58927
58928
58929
58930
58931
58932
58933
58934
58935
58936
58937
58938
58939
58940
58941
58942
58943
58944
58945
58946 # Check whether --with-ssh2 was given.
58947 if test "${with_ssh2+set}" = set; then :
58948   withval=$with_ssh2;
58949 fi
58950
58951
58952   fail=0
58953   if test "x$with_ssh2" != "xno" ; then
58954
58955 pkg_failed=no
58956 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SSH2" >&5
58957 $as_echo_n "checking for SSH2... " >&6; }
58958
58959 if test -n "$SSH2_CFLAGS"; then
58960     pkg_cv_SSH2_CFLAGS="$SSH2_CFLAGS"
58961  elif test -n "$PKG_CONFIG"; then
58962     if test -n "$PKG_CONFIG" && \
58963     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libssh2 >= 1.3\""; } >&5
58964   ($PKG_CONFIG --exists --print-errors "libssh2 >= 1.3") 2>&5
58965   ac_status=$?
58966   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
58967   test $ac_status = 0; }; then
58968   pkg_cv_SSH2_CFLAGS=`$PKG_CONFIG --cflags "libssh2 >= 1.3" 2>/dev/null`
58969                       test "x$?" != "x0" && pkg_failed=yes
58970 else
58971   pkg_failed=yes
58972 fi
58973  else
58974     pkg_failed=untried
58975 fi
58976 if test -n "$SSH2_LIBS"; then
58977     pkg_cv_SSH2_LIBS="$SSH2_LIBS"
58978  elif test -n "$PKG_CONFIG"; then
58979     if test -n "$PKG_CONFIG" && \
58980     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libssh2 >= 1.3\""; } >&5
58981   ($PKG_CONFIG --exists --print-errors "libssh2 >= 1.3") 2>&5
58982   ac_status=$?
58983   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
58984   test $ac_status = 0; }; then
58985   pkg_cv_SSH2_LIBS=`$PKG_CONFIG --libs "libssh2 >= 1.3" 2>/dev/null`
58986                       test "x$?" != "x0" && pkg_failed=yes
58987 else
58988   pkg_failed=yes
58989 fi
58990  else
58991     pkg_failed=untried
58992 fi
58993
58994
58995
58996 if test $pkg_failed = yes; then
58997         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
58998 $as_echo "no" >&6; }
58999
59000 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
59001         _pkg_short_errors_supported=yes
59002 else
59003         _pkg_short_errors_supported=no
59004 fi
59005         if test $_pkg_short_errors_supported = yes; then
59006                 SSH2_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libssh2 >= 1.3" 2>&1`
59007         else
59008                 SSH2_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libssh2 >= 1.3" 2>&1`
59009         fi
59010         # Put the nasty error message in config.log where it belongs
59011         echo "$SSH2_PKG_ERRORS" >&5
59012
59013
59014       if test "x$with_ssh2" != "xcheck"; then
59015         fail=1
59016       fi
59017       with_ssh2=no
59018
59019 elif test $pkg_failed = untried; then
59020         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
59021 $as_echo "no" >&6; }
59022
59023       if test "x$with_ssh2" != "xcheck"; then
59024         fail=1
59025       fi
59026       with_ssh2=no
59027
59028 else
59029         SSH2_CFLAGS=$pkg_cv_SSH2_CFLAGS
59030         SSH2_LIBS=$pkg_cv_SSH2_LIBS
59031         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
59032 $as_echo "yes" >&6; }
59033
59034       with_ssh2=yes
59035
59036 fi
59037   fi
59038
59039   if test $fail = 1; then
59040     as_fn_error $? "You must install the libssh2 >= 1.3 pkg-config module to compile libvirt" "$LINENO" 5
59041   fi
59042
59043   if test "x$with_ssh2" = "xyes" ; then
59044
59045 cat >>confdefs.h <<_ACEOF
59046 #define WITH_SSH2 1
59047 _ACEOF
59048
59049   fi
59050
59051    if test "x$with_ssh2" = "xyes"; then
59052   WITH_SSH2_TRUE=
59053   WITH_SSH2_FALSE='#'
59054 else
59055   WITH_SSH2_TRUE='#'
59056   WITH_SSH2_FALSE=
59057 fi
59058
59059
59060
59061
59062
59063
59064
59065
59066
59067
59068
59069
59070
59071
59072
59073
59074
59075
59076
59077
59078
59079
59080
59081
59082
59083
59084
59085
59086
59087
59088
59089
59090
59091
59092
59093 # Check whether --with-systemd-daemon was given.
59094 if test "${with_systemd_daemon+set}" = set; then :
59095   withval=$with_systemd_daemon;
59096 fi
59097
59098
59099   fail=0
59100   if test "x$with_systemd_daemon" != "xno" ; then
59101
59102 pkg_failed=no
59103 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SYSTEMD_DAEMON" >&5
59104 $as_echo_n "checking for SYSTEMD_DAEMON... " >&6; }
59105
59106 if test -n "$SYSTEMD_DAEMON_CFLAGS"; then
59107     pkg_cv_SYSTEMD_DAEMON_CFLAGS="$SYSTEMD_DAEMON_CFLAGS"
59108  elif test -n "$PKG_CONFIG"; then
59109     if test -n "$PKG_CONFIG" && \
59110     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libsystemd-daemon >= 0.27.1\""; } >&5
59111   ($PKG_CONFIG --exists --print-errors "libsystemd-daemon >= 0.27.1") 2>&5
59112   ac_status=$?
59113   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
59114   test $ac_status = 0; }; then
59115   pkg_cv_SYSTEMD_DAEMON_CFLAGS=`$PKG_CONFIG --cflags "libsystemd-daemon >= 0.27.1" 2>/dev/null`
59116                       test "x$?" != "x0" && pkg_failed=yes
59117 else
59118   pkg_failed=yes
59119 fi
59120  else
59121     pkg_failed=untried
59122 fi
59123 if test -n "$SYSTEMD_DAEMON_LIBS"; then
59124     pkg_cv_SYSTEMD_DAEMON_LIBS="$SYSTEMD_DAEMON_LIBS"
59125  elif test -n "$PKG_CONFIG"; then
59126     if test -n "$PKG_CONFIG" && \
59127     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libsystemd-daemon >= 0.27.1\""; } >&5
59128   ($PKG_CONFIG --exists --print-errors "libsystemd-daemon >= 0.27.1") 2>&5
59129   ac_status=$?
59130   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
59131   test $ac_status = 0; }; then
59132   pkg_cv_SYSTEMD_DAEMON_LIBS=`$PKG_CONFIG --libs "libsystemd-daemon >= 0.27.1" 2>/dev/null`
59133                       test "x$?" != "x0" && pkg_failed=yes
59134 else
59135   pkg_failed=yes
59136 fi
59137  else
59138     pkg_failed=untried
59139 fi
59140
59141
59142
59143 if test $pkg_failed = yes; then
59144         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
59145 $as_echo "no" >&6; }
59146
59147 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
59148         _pkg_short_errors_supported=yes
59149 else
59150         _pkg_short_errors_supported=no
59151 fi
59152         if test $_pkg_short_errors_supported = yes; then
59153                 SYSTEMD_DAEMON_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libsystemd-daemon >= 0.27.1" 2>&1`
59154         else
59155                 SYSTEMD_DAEMON_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libsystemd-daemon >= 0.27.1" 2>&1`
59156         fi
59157         # Put the nasty error message in config.log where it belongs
59158         echo "$SYSTEMD_DAEMON_PKG_ERRORS" >&5
59159
59160
59161       if test "x$with_systemd_daemon" != "xcheck"; then
59162         fail=1
59163       fi
59164       with_systemd_daemon=no
59165
59166 elif test $pkg_failed = untried; then
59167         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
59168 $as_echo "no" >&6; }
59169
59170       if test "x$with_systemd_daemon" != "xcheck"; then
59171         fail=1
59172       fi
59173       with_systemd_daemon=no
59174
59175 else
59176         SYSTEMD_DAEMON_CFLAGS=$pkg_cv_SYSTEMD_DAEMON_CFLAGS
59177         SYSTEMD_DAEMON_LIBS=$pkg_cv_SYSTEMD_DAEMON_LIBS
59178         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
59179 $as_echo "yes" >&6; }
59180
59181       with_systemd_daemon=yes
59182
59183 fi
59184   fi
59185
59186   if test $fail = 1; then
59187     as_fn_error $? "You must install the libsystemd-daemon >= 0.27.1 pkg-config module to compile libvirt" "$LINENO" 5
59188   fi
59189
59190   if test "x$with_systemd_daemon" = "xyes" ; then
59191
59192 cat >>confdefs.h <<_ACEOF
59193 #define WITH_SYSTEMD_DAEMON 1
59194 _ACEOF
59195
59196   fi
59197
59198    if test "x$with_systemd_daemon" = "xyes"; then
59199   WITH_SYSTEMD_DAEMON_TRUE=
59200   WITH_SYSTEMD_DAEMON_FALSE='#'
59201 else
59202   WITH_SYSTEMD_DAEMON_TRUE='#'
59203   WITH_SYSTEMD_DAEMON_FALSE=
59204 fi
59205
59206
59207
59208
59209
59210
59211
59212
59213
59214
59215
59216
59217
59218
59219
59220
59221
59222     old_CFLAGS="$CFLAGS"
59223     old_LIBS="$LIBS"
59224     CFLAGS="$CFLAGS $SYSTEMD_DAEMON_CFLAGS"
59225     LIBS="$LIBS $SYSTEMD_DAEMON_LIBS"
59226     for ac_func in sd_notify
59227 do :
59228   ac_fn_c_check_func "$LINENO" "sd_notify" "ac_cv_func_sd_notify"
59229 if test "x$ac_cv_func_sd_notify" = xyes; then :
59230   cat >>confdefs.h <<_ACEOF
59231 #define HAVE_SD_NOTIFY 1
59232 _ACEOF
59233
59234 fi
59235 done
59236
59237     CFLAGS="$old_CFLAGS"
59238     LIBS="$old_LIBS"
59239
59240
59241
59242
59243
59244
59245
59246
59247
59248
59249
59250
59251
59252
59253
59254
59255
59256
59257
59258
59259 # Check whether --with-udev was given.
59260 if test "${with_udev+set}" = set; then :
59261   withval=$with_udev;
59262 fi
59263
59264
59265   fail=0
59266   if test "x$with_udev" != "xno" ; then
59267
59268 pkg_failed=no
59269 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UDEV" >&5
59270 $as_echo_n "checking for UDEV... " >&6; }
59271
59272 if test -n "$UDEV_CFLAGS"; then
59273     pkg_cv_UDEV_CFLAGS="$UDEV_CFLAGS"
59274  elif test -n "$PKG_CONFIG"; then
59275     if test -n "$PKG_CONFIG" && \
59276     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libudev >= 145\""; } >&5
59277   ($PKG_CONFIG --exists --print-errors "libudev >= 145") 2>&5
59278   ac_status=$?
59279   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
59280   test $ac_status = 0; }; then
59281   pkg_cv_UDEV_CFLAGS=`$PKG_CONFIG --cflags "libudev >= 145" 2>/dev/null`
59282                       test "x$?" != "x0" && pkg_failed=yes
59283 else
59284   pkg_failed=yes
59285 fi
59286  else
59287     pkg_failed=untried
59288 fi
59289 if test -n "$UDEV_LIBS"; then
59290     pkg_cv_UDEV_LIBS="$UDEV_LIBS"
59291  elif test -n "$PKG_CONFIG"; then
59292     if test -n "$PKG_CONFIG" && \
59293     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libudev >= 145\""; } >&5
59294   ($PKG_CONFIG --exists --print-errors "libudev >= 145") 2>&5
59295   ac_status=$?
59296   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
59297   test $ac_status = 0; }; then
59298   pkg_cv_UDEV_LIBS=`$PKG_CONFIG --libs "libudev >= 145" 2>/dev/null`
59299                       test "x$?" != "x0" && pkg_failed=yes
59300 else
59301   pkg_failed=yes
59302 fi
59303  else
59304     pkg_failed=untried
59305 fi
59306
59307
59308
59309 if test $pkg_failed = yes; then
59310         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
59311 $as_echo "no" >&6; }
59312
59313 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
59314         _pkg_short_errors_supported=yes
59315 else
59316         _pkg_short_errors_supported=no
59317 fi
59318         if test $_pkg_short_errors_supported = yes; then
59319                 UDEV_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libudev >= 145" 2>&1`
59320         else
59321                 UDEV_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libudev >= 145" 2>&1`
59322         fi
59323         # Put the nasty error message in config.log where it belongs
59324         echo "$UDEV_PKG_ERRORS" >&5
59325
59326
59327       if test "x$with_udev" != "xcheck"; then
59328         fail=1
59329       fi
59330       with_udev=no
59331
59332 elif test $pkg_failed = untried; then
59333         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
59334 $as_echo "no" >&6; }
59335
59336       if test "x$with_udev" != "xcheck"; then
59337         fail=1
59338       fi
59339       with_udev=no
59340
59341 else
59342         UDEV_CFLAGS=$pkg_cv_UDEV_CFLAGS
59343         UDEV_LIBS=$pkg_cv_UDEV_LIBS
59344         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
59345 $as_echo "yes" >&6; }
59346
59347       with_udev=yes
59348
59349 fi
59350   fi
59351
59352   if test $fail = 1; then
59353     as_fn_error $? "You must install the libudev >= 145 pkg-config module to compile libvirt" "$LINENO" 5
59354   fi
59355
59356   if test "x$with_udev" = "xyes" ; then
59357
59358 cat >>confdefs.h <<_ACEOF
59359 #define WITH_UDEV 1
59360 _ACEOF
59361
59362   fi
59363
59364    if test "x$with_udev" = "xyes"; then
59365   WITH_UDEV_TRUE=
59366   WITH_UDEV_FALSE='#'
59367 else
59368   WITH_UDEV_TRUE='#'
59369   WITH_UDEV_FALSE=
59370 fi
59371
59372
59373
59374
59375
59376
59377
59378
59379
59380
59381
59382
59383
59384
59385
59386
59387
59388   if test "$with_udev" = "yes" && test "$with_pciaccess" != "yes" ; then
59389     as_fn_error $? "You must install the pciaccess module to build with udev" "$LINENO" 5
59390   fi
59391
59392
59393     if test "$with_qemu:$with_yajl" = yes:check; then
59394                 for ac_prog in qemu-kvm qemu kvm qemu-system-x86_64
59395 do
59396   # Extract the first word of "$ac_prog", so it can be a program name with args.
59397 set dummy $ac_prog; ac_word=$2
59398 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
59399 $as_echo_n "checking for $ac_word... " >&6; }
59400 if ${ac_cv_path_QEMU+:} false; then :
59401   $as_echo_n "(cached) " >&6
59402 else
59403   case $QEMU in
59404   [\\/]* | ?:[\\/]*)
59405   ac_cv_path_QEMU="$QEMU" # Let the user override the test with a path.
59406   ;;
59407   *)
59408   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
59409 as_dummy="$PATH:/usr/bin:/usr/libexec"
59410 for as_dir in $as_dummy
59411 do
59412   IFS=$as_save_IFS
59413   test -z "$as_dir" && as_dir=.
59414     for ac_exec_ext in '' $ac_executable_extensions; do
59415   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
59416     ac_cv_path_QEMU="$as_dir/$ac_word$ac_exec_ext"
59417     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
59418     break 2
59419   fi
59420 done
59421   done
59422 IFS=$as_save_IFS
59423
59424   ;;
59425 esac
59426 fi
59427 QEMU=$ac_cv_path_QEMU
59428 if test -n "$QEMU"; then
59429   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $QEMU" >&5
59430 $as_echo "$QEMU" >&6; }
59431 else
59432   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
59433 $as_echo "no" >&6; }
59434 fi
59435
59436
59437   test -n "$QEMU" && break
59438 done
59439
59440     if test -x "$QEMU"; then
59441       if `$QEMU -help | grep libvirt` >/dev/null; then
59442         with_yajl=yes
59443       else
59444         qemu_version_sed='s/.*ersion \([0-9.,]*\).*/\1/'
59445         qemu_version=`$QEMU -version | sed "$qemu_version_sed"`
59446         case $qemu_version in
59447           [1-9].* | 0.15.* ) with_yajl=yes ;;
59448           0.* | '' ) ;;
59449           *) as_fn_error $? "Unexpected qemu version string" "$LINENO" 5 ;;
59450         esac
59451       fi
59452     fi
59453   fi
59454
59455
59456
59457
59458
59459
59460
59461
59462
59463
59464
59465
59466
59467
59468
59469
59470
59471
59472
59473
59474
59475
59476
59477
59478
59479 # Check whether --with-yajl was given.
59480 if test "${with_yajl+set}" = set; then :
59481   withval=$with_yajl;
59482 fi
59483
59484
59485   old_LIBS=$LIBS
59486   old_CFLAGS=$CFLAGS
59487   YAJL_CFLAGS=
59488   YAJL_LIBS=
59489
59490   fail=0
59491   alt=0
59492   if test "x$with_yajl" != "xno" ; then
59493     if test "x$with_yajl" != "xyes" && test "x$with_yajl" != "xcheck" ; then
59494       YAJL_CFLAGS="-I$with_yajl/include"
59495       YAJL_LIBS="-L$with_yajl/lib"
59496     fi
59497     CFLAGS="$CFLAGS $YAJL_CFLAGS"
59498     LIBS="$LIBS $YAJL_LIBS"
59499     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for yajl_parse_complete in -lyajl" >&5
59500 $as_echo_n "checking for yajl_parse_complete in -lyajl... " >&6; }
59501 if ${ac_cv_lib_yajl_yajl_parse_complete+:} false; then :
59502   $as_echo_n "(cached) " >&6
59503 else
59504   ac_check_lib_save_LIBS=$LIBS
59505 LIBS="-lyajl  $LIBS"
59506 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
59507 /* end confdefs.h.  */
59508
59509 /* Override any GCC internal prototype to avoid an error.
59510    Use char because int might match the return type of a GCC
59511    builtin and then its argument prototype would still apply.  */
59512 #ifdef __cplusplus
59513 extern "C"
59514 #endif
59515 char yajl_parse_complete ();
59516 int
59517 main ()
59518 {
59519 return yajl_parse_complete ();
59520   ;
59521   return 0;
59522 }
59523 _ACEOF
59524 if ac_fn_c_try_link "$LINENO"; then :
59525   ac_cv_lib_yajl_yajl_parse_complete=yes
59526 else
59527   ac_cv_lib_yajl_yajl_parse_complete=no
59528 fi
59529 rm -f core conftest.err conftest.$ac_objext \
59530     conftest$ac_exeext conftest.$ac_ext
59531 LIBS=$ac_check_lib_save_LIBS
59532 fi
59533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_yajl_yajl_parse_complete" >&5
59534 $as_echo "$ac_cv_lib_yajl_yajl_parse_complete" >&6; }
59535 if test "x$ac_cv_lib_yajl_yajl_parse_complete" = xyes; then :
59536   cat >>confdefs.h <<_ACEOF
59537 #define HAVE_LIBYAJL 1
59538 _ACEOF
59539
59540   LIBS="-lyajl $LIBS"
59541
59542 else
59543
59544       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for yajl_tree_parse in -lyajl" >&5
59545 $as_echo_n "checking for yajl_tree_parse in -lyajl... " >&6; }
59546 if ${ac_cv_lib_yajl_yajl_tree_parse+:} false; then :
59547   $as_echo_n "(cached) " >&6
59548 else
59549   ac_check_lib_save_LIBS=$LIBS
59550 LIBS="-lyajl  $LIBS"
59551 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
59552 /* end confdefs.h.  */
59553
59554 /* Override any GCC internal prototype to avoid an error.
59555    Use char because int might match the return type of a GCC
59556    builtin and then its argument prototype would still apply.  */
59557 #ifdef __cplusplus
59558 extern "C"
59559 #endif
59560 char yajl_tree_parse ();
59561 int
59562 main ()
59563 {
59564 return yajl_tree_parse ();
59565   ;
59566   return 0;
59567 }
59568 _ACEOF
59569 if ac_fn_c_try_link "$LINENO"; then :
59570   ac_cv_lib_yajl_yajl_tree_parse=yes
59571 else
59572   ac_cv_lib_yajl_yajl_tree_parse=no
59573 fi
59574 rm -f core conftest.err conftest.$ac_objext \
59575     conftest$ac_exeext conftest.$ac_ext
59576 LIBS=$ac_check_lib_save_LIBS
59577 fi
59578 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_yajl_yajl_tree_parse" >&5
59579 $as_echo "$ac_cv_lib_yajl_yajl_tree_parse" >&6; }
59580 if test "x$ac_cv_lib_yajl_yajl_tree_parse" = xyes; then :
59581
59582         alt=1
59583
59584 else
59585
59586         if test "x$with_yajl" != "xcheck"; then
59587           fail=1
59588         fi
59589         with_yajl=no
59590
59591 fi
59592
59593
59594 fi
59595
59596     if test "$fail" = "0" && test "x$with_yajl" != "xno" ; then
59597       ac_fn_c_check_header_mongrel "$LINENO" "yajl/yajl_common.h" "ac_cv_header_header_name" "$ac_includes_default"
59598 if test "x$ac_cv_header_header_name" = xyes; then :
59599
59600         with_yajl=yes
59601
59602 else
59603
59604         ac_fn_c_check_header_mongrel "$LINENO" "yajl/yajl_common.h" "ac_cv_header_header_name_alt" "$ac_includes_default"
59605 if test "x$ac_cv_header_header_name_alt" = xyes; then :
59606
59607           with_yajl=yes
59608
59609 else
59610
59611           if test "x$with_yajl" != "xcheck"; then
59612             fail=1
59613           fi
59614           with_yajl=no
59615
59616 fi
59617
59618
59619
59620 fi
59621
59622
59623     fi
59624   fi
59625
59626   LIBS=$old_LIBS
59627   CFLAGS=$old_CFLAGS
59628
59629   if test $fail = 1; then
59630     as_fn_error $? "You must install the libyajl library & headers to compile libvirt" "$LINENO" 5
59631   else
59632     if test "x$with_yajl" = "xyes" ; then
59633       if test "x$YAJL_LIBS" = 'x' ; then
59634         YAJL_LIBS="-lyajl"
59635       else
59636         YAJL_LIBS="$YAJL_LIBS -lyajl"
59637       fi
59638
59639
59640 cat >>confdefs.h <<_ACEOF
59641 #define WITH_YAJL 1
59642 _ACEOF
59643
59644       if test "$alt" = "1" ; then
59645
59646 cat >>confdefs.h <<_ACEOF
59647 #define WITH_YAJL2 1
59648 _ACEOF
59649
59650       fi
59651     fi
59652
59653      if test "x$with_yajl" = "xyes"; then
59654   WITH_YAJL_TRUE=
59655   WITH_YAJL_FALSE='#'
59656 else
59657   WITH_YAJL_TRUE='#'
59658   WITH_YAJL_FALSE=
59659 fi
59660
59661      if test "x$with_yajl" = "xyes" && test "$alt" = "1"; then
59662   WITH_YAJL2_TRUE=
59663   WITH_YAJL2_FALSE='#'
59664 else
59665   WITH_YAJL2_TRUE='#'
59666   WITH_YAJL2_FALSE=
59667 fi
59668
59669
59670
59671
59672   fi
59673
59674
59675
59676
59677
59678
59679
59680
59681
59682
59683
59684
59685
59686
59687
59688
59689
59690
59691
59692
59693
59694
59695
59696 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CPUID instruction" >&5
59697 $as_echo_n "checking for CPUID instruction... " >&6; }
59698 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
59699 /* end confdefs.h.  */
59700
59701     #include <stdint.h>
59702
59703 int
59704 main ()
59705 {
59706
59707     uint32_t eax, ebx, ecx, edx;
59708     asm volatile (
59709         "cpuid"
59710         : "=a" (eax), "=b" (ebx), "=c" (ecx), "=d" (edx)
59711         : "a" (eax));
59712
59713   ;
59714   return 0;
59715 }
59716 _ACEOF
59717 if ac_fn_c_try_compile "$LINENO"; then :
59718   have_cpuid=yes
59719 else
59720   have_cpuid=no
59721 fi
59722 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
59723 if test "x$have_cpuid" = xyes; then
59724
59725 cat >>confdefs.h <<_ACEOF
59726 #define HAVE_CPUID 1
59727 _ACEOF
59728
59729 fi
59730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_cpuid" >&5
59731 $as_echo "$have_cpuid" >&6; }
59732
59733 # The cast to long int works around a bug in the HP C Compiler
59734 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
59735 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
59736 # This bug is HP SR number 8606223364.
59737 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
59738 $as_echo_n "checking size of long... " >&6; }
59739 if ${ac_cv_sizeof_long+:} false; then :
59740   $as_echo_n "(cached) " >&6
59741 else
59742   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long"        "$ac_includes_default"; then :
59743
59744 else
59745   if test "$ac_cv_type_long" = yes; then
59746      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
59747 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
59748 as_fn_error 77 "cannot compute sizeof (long)
59749 See \`config.log' for more details" "$LINENO" 5; }
59750    else
59751      ac_cv_sizeof_long=0
59752    fi
59753 fi
59754
59755 fi
59756 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
59757 $as_echo "$ac_cv_sizeof_long" >&6; }
59758
59759
59760
59761 cat >>confdefs.h <<_ACEOF
59762 #define SIZEOF_LONG $ac_cv_sizeof_long
59763 _ACEOF
59764
59765
59766
59767
59768
59769
59770
59771
59772
59773
59774
59775
59776
59777
59778
59779
59780
59781
59782
59783
59784
59785
59786
59787
59788
59789
59790
59791
59792
59793
59794
59795
59796
59797
59798
59799
59800
59801
59802
59803
59804
59805
59806
59807
59808
59809
59810
59811
59812
59813
59814
59815
59816
59817
59818
59819
59820
59821
59822
59823
59824
59825
59826
59827
59828
59829
59830
59831
59832
59833
59834
59835
59836
59837
59838
59839
59840
59841
59842
59843
59844
59845
59846
59847
59848
59849
59850
59851
59852
59853
59854
59855
59856
59857
59858
59859
59860
59861
59862
59863   :
59864
59865
59866
59867
59868
59869
59870
59871
59872
59873
59874
59875
59876
59877
59878
59879
59880
59881
59882
59883
59884
59885
59886
59887
59888
59889
59890
59891
59892
59893
59894
59895
59896
59897
59898
59899
59900
59901
59902
59903
59904
59905
59906
59907
59908
59909
59910
59911
59912
59913
59914
59915
59916
59917
59918
59919
59920
59921
59922
59923
59924
59925
59926
59927
59928
59929
59930 old_LIBS=$LIBS
59931 LIBS="$LIBS $LIB_PTHREAD $LIBMULTITHREAD"
59932
59933 pthread_found=yes
59934 for ac_func in pthread_mutexattr_init
59935 do :
59936   ac_fn_c_check_func "$LINENO" "pthread_mutexattr_init" "ac_cv_func_pthread_mutexattr_init"
59937 if test "x$ac_cv_func_pthread_mutexattr_init" = xyes; then :
59938   cat >>confdefs.h <<_ACEOF
59939 #define HAVE_PTHREAD_MUTEXATTR_INIT 1
59940 _ACEOF
59941
59942 fi
59943 done
59944
59945 ac_fn_c_check_header_mongrel "$LINENO" "pthread.h" "ac_cv_header_pthread_h" "$ac_includes_default"
59946 if test "x$ac_cv_header_pthread_h" = xyes; then :
59947
59948 else
59949   pthread_found=no
59950 fi
59951
59952
59953
59954 if test "$ac_cv_func_pthread_mutexattr_init:$pthread_found" != "yes:yes"
59955 then
59956   as_fn_error $? "A pthreads impl is required for building libvirt" "$LINENO" 5
59957 fi
59958
59959 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask does anything" >&5
59960 $as_echo_n "checking whether pthread_sigmask does anything... " >&6; }
59961 if ${lv_cv_pthread_sigmask_works+:} false; then :
59962   $as_echo_n "(cached) " >&6
59963 else
59964   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
59965 /* end confdefs.h.  */
59966
59967     #include <sys/types.h>
59968     #include <signal.h>
59969
59970 int
59971 main ()
59972 {
59973
59974     #ifdef pthread_sigmask
59975     int (*foo)(int, const sigset_t *, sigset_t *) = &pthread_sigmask;
59976     return !foo;
59977     #endif
59978
59979   ;
59980   return 0;
59981 }
59982 _ACEOF
59983 if ac_fn_c_try_compile "$LINENO"; then :
59984   lv_cv_pthread_sigmask_works=yes
59985 else
59986   lv_cv_pthread_sigmask_works=no
59987 fi
59988 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
59989 fi
59990 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lv_cv_pthread_sigmask_works" >&5
59991 $as_echo "$lv_cv_pthread_sigmask_works" >&6; }
59992 if test "x$lv_cv_pthread_sigmask_works" != xyes; then
59993
59994 $as_echo "#define FUNC_PTHREAD_SIGMASK_BROKEN 1" >>confdefs.h
59995
59996 fi
59997 LIBS=$old_libs
59998
59999 for ac_header in pwd.h paths.h regex.h sys/un.h \
60000   sys/poll.h syslog.h mntent.h net/ethernet.h linux/magic.h \
60001   sys/un.h sys/syscall.h sys/sysctl.h netinet/tcp.h ifaddrs.h \
60002   libtasn1.h sys/ucred.h sys/mount.h
60003 do :
60004   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
60005 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
60006 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
60007   cat >>confdefs.h <<_ACEOF
60008 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
60009 _ACEOF
60010
60011 fi
60012
60013 done
60014
60015 ac_fn_c_check_decl "$LINENO" "htole64" "ac_cv_have_decl_htole64" "#include <endian.h>
60016 "
60017 if test "x$ac_cv_have_decl_htole64" = xyes; then :
60018   ac_have_decl=1
60019 else
60020   ac_have_decl=0
60021 fi
60022
60023 cat >>confdefs.h <<_ACEOF
60024 #define HAVE_DECL_HTOLE64 $ac_have_decl
60025 _ACEOF
60026
60027
60028
60029
60030 atomic_ops=
60031
60032 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for atomic ops implementation" >&5
60033 $as_echo_n "checking for atomic ops implementation... " >&6; }
60034
60035 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
60036 /* end confdefs.h.  */
60037
60038 int
60039 main ()
60040 {
60041 __GCC_HAVE_SYNC_COMPARE_AND_SWAP_4;
60042   ;
60043   return 0;
60044 }
60045 _ACEOF
60046 if ac_fn_c_try_compile "$LINENO"; then :
60047
60048   atomic_ops=gcc
60049
60050 fi
60051 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
60052
60053 if test "$atomic_ops" = "" ; then
60054   SAVE_CFLAGS="${CFLAGS}"
60055   CFLAGS="-march=i486"
60056   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
60057 /* end confdefs.h.  */
60058
60059 int
60060 main ()
60061 {
60062 __GCC_HAVE_SYNC_COMPARE_AND_SWAP_4;
60063   ;
60064   return 0;
60065 }
60066 _ACEOF
60067 if ac_fn_c_try_compile "$LINENO"; then :
60068   as_fn_error $? "Libvirt must be built with -march=i486 or later." "$LINENO" 5
60069 fi
60070 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
60071   CFLAGS="${SAVE_CFLAGS}"
60072
60073   case "$host" in
60074     *-*-mingw* | *-*-msvc* )
60075       atomic_ops=win32
60076       ;;
60077     *)
60078       if test "$ac_cv_header_pthread_h" = "yes" ; then
60079         atomic_ops=pthread
60080       else
60081         as_fn_error $? "Libvirt must be built with GCC or have pthread.h on non-Win32 platforms" "$LINENO" 5
60082       fi
60083       ;;
60084   esac
60085 fi
60086
60087 case "$atomic_ops" in
60088    gcc)
60089
60090 $as_echo "#define VIR_ATOMIC_OPS_GCC 1" >>confdefs.h
60091
60092      ;;
60093    win32)
60094
60095 $as_echo "#define VIR_ATOMIC_OPS_WIN32 1" >>confdefs.h
60096
60097      ;;
60098    pthread)
60099
60100 $as_echo "#define VIR_ATOMIC_OPS_PTHREAD 1" >>confdefs.h
60101
60102      ;;
60103 esac
60104  if test "$atomic_ops" = "pthread"; then
60105   WITH_ATOMIC_OPS_PTHREAD_TRUE=
60106   WITH_ATOMIC_OPS_PTHREAD_FALSE='#'
60107 else
60108   WITH_ATOMIC_OPS_PTHREAD_TRUE='#'
60109   WITH_ATOMIC_OPS_PTHREAD_FALSE=
60110 fi
60111
60112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $atomic_ops" >&5
60113 $as_echo "$atomic_ops" >&6; }
60114
60115
60116 ac_fn_c_check_type "$LINENO" "struct ifreq" "ac_cv_type_struct_ifreq" "#include <sys/socket.h>
60117         #include <net/if.h>
60118
60119 "
60120 if test "x$ac_cv_type_struct_ifreq" = xyes; then :
60121
60122 $as_echo "#define HAVE_STRUCT_IFREQ 1" >>confdefs.h
60123
60124 fi
60125
60126
60127  if test "x$ac_cv_header_libtasn1_h" = "xyes"; then
60128   HAVE_LIBTASN1_TRUE=
60129   HAVE_LIBTASN1_FALSE='#'
60130 else
60131   HAVE_LIBTASN1_TRUE='#'
60132   HAVE_LIBTASN1_FALSE=
60133 fi
60134
60135
60136 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gettext in -lintl" >&5
60137 $as_echo_n "checking for gettext in -lintl... " >&6; }
60138 if ${ac_cv_lib_intl_gettext+:} false; then :
60139   $as_echo_n "(cached) " >&6
60140 else
60141   ac_check_lib_save_LIBS=$LIBS
60142 LIBS="-lintl  $LIBS"
60143 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
60144 /* end confdefs.h.  */
60145
60146 /* Override any GCC internal prototype to avoid an error.
60147    Use char because int might match the return type of a GCC
60148    builtin and then its argument prototype would still apply.  */
60149 #ifdef __cplusplus
60150 extern "C"
60151 #endif
60152 char gettext ();
60153 int
60154 main ()
60155 {
60156 return gettext ();
60157   ;
60158   return 0;
60159 }
60160 _ACEOF
60161 if ac_fn_c_try_link "$LINENO"; then :
60162   ac_cv_lib_intl_gettext=yes
60163 else
60164   ac_cv_lib_intl_gettext=no
60165 fi
60166 rm -f core conftest.err conftest.$ac_objext \
60167     conftest$ac_exeext conftest.$ac_ext
60168 LIBS=$ac_check_lib_save_LIBS
60169 fi
60170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_gettext" >&5
60171 $as_echo "$ac_cv_lib_intl_gettext" >&6; }
60172 if test "x$ac_cv_lib_intl_gettext" = xyes; then :
60173   cat >>confdefs.h <<_ACEOF
60174 #define HAVE_LIBINTL 1
60175 _ACEOF
60176
60177   LIBS="-lintl $LIBS"
60178
60179 fi
60180
60181
60182 # Extract the first word of "rpcgen", so it can be a program name with args.
60183 set dummy rpcgen; ac_word=$2
60184 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
60185 $as_echo_n "checking for $ac_word... " >&6; }
60186 if ${ac_cv_path_RPCGEN+:} false; then :
60187   $as_echo_n "(cached) " >&6
60188 else
60189   case $RPCGEN in
60190   [\\/]* | ?:[\\/]*)
60191   ac_cv_path_RPCGEN="$RPCGEN" # Let the user override the test with a path.
60192   ;;
60193   *)
60194   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
60195 for as_dir in $PATH
60196 do
60197   IFS=$as_save_IFS
60198   test -z "$as_dir" && as_dir=.
60199     for ac_exec_ext in '' $ac_executable_extensions; do
60200   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
60201     ac_cv_path_RPCGEN="$as_dir/$ac_word$ac_exec_ext"
60202     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
60203     break 2
60204   fi
60205 done
60206   done
60207 IFS=$as_save_IFS
60208
60209   test -z "$ac_cv_path_RPCGEN" && ac_cv_path_RPCGEN="no"
60210   ;;
60211 esac
60212 fi
60213 RPCGEN=$ac_cv_path_RPCGEN
60214 if test -n "$RPCGEN"; then
60215   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RPCGEN" >&5
60216 $as_echo "$RPCGEN" >&6; }
60217 else
60218   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
60219 $as_echo "no" >&6; }
60220 fi
60221
60222
60223  if test "x$ac_cv_path_RPCGEN" != "xno"; then
60224   HAVE_RPCGEN_TRUE=
60225   HAVE_RPCGEN_FALSE='#'
60226 else
60227   HAVE_RPCGEN_TRUE='#'
60228   HAVE_RPCGEN_FALSE=
60229 fi
60230
60231  if test "x$ac_cv_path_RPCGEN" != "xno" &&
60232                 $ac_cv_path_RPCGEN -t </dev/null >/dev/null 2>&1; then
60233   HAVE_GLIBC_RPCGEN_TRUE=
60234   HAVE_GLIBC_RPCGEN_FALSE='#'
60235 else
60236   HAVE_GLIBC_RPCGEN_TRUE='#'
60237   HAVE_GLIBC_RPCGEN_FALSE=
60238 fi
60239
60240
60241 # Extract the first word of "xmllint", so it can be a program name with args.
60242 set dummy xmllint; ac_word=$2
60243 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
60244 $as_echo_n "checking for $ac_word... " >&6; }
60245 if ${ac_cv_path_XMLLINT+:} false; then :
60246   $as_echo_n "(cached) " >&6
60247 else
60248   case $XMLLINT in
60249   [\\/]* | ?:[\\/]*)
60250   ac_cv_path_XMLLINT="$XMLLINT" # Let the user override the test with a path.
60251   ;;
60252   *)
60253   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
60254 for as_dir in $PATH
60255 do
60256   IFS=$as_save_IFS
60257   test -z "$as_dir" && as_dir=.
60258     for ac_exec_ext in '' $ac_executable_extensions; do
60259   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
60260     ac_cv_path_XMLLINT="$as_dir/$ac_word$ac_exec_ext"
60261     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
60262     break 2
60263   fi
60264 done
60265   done
60266 IFS=$as_save_IFS
60267
60268   test -z "$ac_cv_path_XMLLINT" && ac_cv_path_XMLLINT="/usr/bin/xmllint"
60269   ;;
60270 esac
60271 fi
60272 XMLLINT=$ac_cv_path_XMLLINT
60273 if test -n "$XMLLINT"; then
60274   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XMLLINT" >&5
60275 $as_echo "$XMLLINT" >&6; }
60276 else
60277   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
60278 $as_echo "no" >&6; }
60279 fi
60280
60281
60282 # Extract the first word of "xmlcatalog", so it can be a program name with args.
60283 set dummy xmlcatalog; ac_word=$2
60284 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
60285 $as_echo_n "checking for $ac_word... " >&6; }
60286 if ${ac_cv_path_XMLCATALOG+:} false; then :
60287   $as_echo_n "(cached) " >&6
60288 else
60289   case $XMLCATALOG in
60290   [\\/]* | ?:[\\/]*)
60291   ac_cv_path_XMLCATALOG="$XMLCATALOG" # Let the user override the test with a path.
60292   ;;
60293   *)
60294   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
60295 for as_dir in $PATH
60296 do
60297   IFS=$as_save_IFS
60298   test -z "$as_dir" && as_dir=.
60299     for ac_exec_ext in '' $ac_executable_extensions; do
60300   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
60301     ac_cv_path_XMLCATALOG="$as_dir/$ac_word$ac_exec_ext"
60302     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
60303     break 2
60304   fi
60305 done
60306   done
60307 IFS=$as_save_IFS
60308
60309   test -z "$ac_cv_path_XMLCATALOG" && ac_cv_path_XMLCATALOG="/usr/bin/xmlcatalog"
60310   ;;
60311 esac
60312 fi
60313 XMLCATALOG=$ac_cv_path_XMLCATALOG
60314 if test -n "$XMLCATALOG"; then
60315   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XMLCATALOG" >&5
60316 $as_echo "$XMLCATALOG" >&6; }
60317 else
60318   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
60319 $as_echo "no" >&6; }
60320 fi
60321
60322
60323 # Extract the first word of "xsltproc", so it can be a program name with args.
60324 set dummy xsltproc; ac_word=$2
60325 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
60326 $as_echo_n "checking for $ac_word... " >&6; }
60327 if ${ac_cv_path_XSLTPROC+:} false; then :
60328   $as_echo_n "(cached) " >&6
60329 else
60330   case $XSLTPROC in
60331   [\\/]* | ?:[\\/]*)
60332   ac_cv_path_XSLTPROC="$XSLTPROC" # Let the user override the test with a path.
60333   ;;
60334   *)
60335   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
60336 for as_dir in $PATH
60337 do
60338   IFS=$as_save_IFS
60339   test -z "$as_dir" && as_dir=.
60340     for ac_exec_ext in '' $ac_executable_extensions; do
60341   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
60342     ac_cv_path_XSLTPROC="$as_dir/$ac_word$ac_exec_ext"
60343     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
60344     break 2
60345   fi
60346 done
60347   done
60348 IFS=$as_save_IFS
60349
60350   test -z "$ac_cv_path_XSLTPROC" && ac_cv_path_XSLTPROC="/usr/bin/xsltproc"
60351   ;;
60352 esac
60353 fi
60354 XSLTPROC=$ac_cv_path_XSLTPROC
60355 if test -n "$XSLTPROC"; then
60356   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XSLTPROC" >&5
60357 $as_echo "$XSLTPROC" >&6; }
60358 else
60359   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
60360 $as_echo "no" >&6; }
60361 fi
60362
60363
60364 # Extract the first word of "augparse", so it can be a program name with args.
60365 set dummy augparse; ac_word=$2
60366 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
60367 $as_echo_n "checking for $ac_word... " >&6; }
60368 if ${ac_cv_path_AUGPARSE+:} false; then :
60369   $as_echo_n "(cached) " >&6
60370 else
60371   case $AUGPARSE in
60372   [\\/]* | ?:[\\/]*)
60373   ac_cv_path_AUGPARSE="$AUGPARSE" # Let the user override the test with a path.
60374   ;;
60375   *)
60376   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
60377 for as_dir in $PATH
60378 do
60379   IFS=$as_save_IFS
60380   test -z "$as_dir" && as_dir=.
60381     for ac_exec_ext in '' $ac_executable_extensions; do
60382   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
60383     ac_cv_path_AUGPARSE="$as_dir/$ac_word$ac_exec_ext"
60384     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
60385     break 2
60386   fi
60387 done
60388   done
60389 IFS=$as_save_IFS
60390
60391   test -z "$ac_cv_path_AUGPARSE" && ac_cv_path_AUGPARSE="/usr/bin/augparse"
60392   ;;
60393 esac
60394 fi
60395 AUGPARSE=$ac_cv_path_AUGPARSE
60396 if test -n "$AUGPARSE"; then
60397   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AUGPARSE" >&5
60398 $as_echo "$AUGPARSE" >&6; }
60399 else
60400   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
60401 $as_echo "no" >&6; }
60402 fi
60403
60404
60405
60406
60407 # Extract the first word of "dmidecode", so it can be a program name with args.
60408 set dummy dmidecode; ac_word=$2
60409 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
60410 $as_echo_n "checking for $ac_word... " >&6; }
60411 if ${ac_cv_path_DMIDECODE+:} false; then :
60412   $as_echo_n "(cached) " >&6
60413 else
60414   case $DMIDECODE in
60415   [\\/]* | ?:[\\/]*)
60416   ac_cv_path_DMIDECODE="$DMIDECODE" # Let the user override the test with a path.
60417   ;;
60418   *)
60419   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
60420 as_dummy="/sbin:/usr/sbin:/usr/local/sbin:$PATH"
60421 for as_dir in $as_dummy
60422 do
60423   IFS=$as_save_IFS
60424   test -z "$as_dir" && as_dir=.
60425     for ac_exec_ext in '' $ac_executable_extensions; do
60426   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
60427     ac_cv_path_DMIDECODE="$as_dir/$ac_word$ac_exec_ext"
60428     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
60429     break 2
60430   fi
60431 done
60432   done
60433 IFS=$as_save_IFS
60434
60435   test -z "$ac_cv_path_DMIDECODE" && ac_cv_path_DMIDECODE="dmidecode"
60436   ;;
60437 esac
60438 fi
60439 DMIDECODE=$ac_cv_path_DMIDECODE
60440 if test -n "$DMIDECODE"; then
60441   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DMIDECODE" >&5
60442 $as_echo "$DMIDECODE" >&6; }
60443 else
60444   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
60445 $as_echo "no" >&6; }
60446 fi
60447
60448
60449 # Extract the first word of "dnsmasq", so it can be a program name with args.
60450 set dummy dnsmasq; ac_word=$2
60451 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
60452 $as_echo_n "checking for $ac_word... " >&6; }
60453 if ${ac_cv_path_DNSMASQ+:} false; then :
60454   $as_echo_n "(cached) " >&6
60455 else
60456   case $DNSMASQ in
60457   [\\/]* | ?:[\\/]*)
60458   ac_cv_path_DNSMASQ="$DNSMASQ" # Let the user override the test with a path.
60459   ;;
60460   *)
60461   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
60462 as_dummy="/sbin:/usr/sbin:/usr/local/sbin:$PATH"
60463 for as_dir in $as_dummy
60464 do
60465   IFS=$as_save_IFS
60466   test -z "$as_dir" && as_dir=.
60467     for ac_exec_ext in '' $ac_executable_extensions; do
60468   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
60469     ac_cv_path_DNSMASQ="$as_dir/$ac_word$ac_exec_ext"
60470     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
60471     break 2
60472   fi
60473 done
60474   done
60475 IFS=$as_save_IFS
60476
60477   test -z "$ac_cv_path_DNSMASQ" && ac_cv_path_DNSMASQ="dnsmasq"
60478   ;;
60479 esac
60480 fi
60481 DNSMASQ=$ac_cv_path_DNSMASQ
60482 if test -n "$DNSMASQ"; then
60483   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DNSMASQ" >&5
60484 $as_echo "$DNSMASQ" >&6; }
60485 else
60486   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
60487 $as_echo "no" >&6; }
60488 fi
60489
60490
60491 # Extract the first word of "radvd", so it can be a program name with args.
60492 set dummy radvd; ac_word=$2
60493 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
60494 $as_echo_n "checking for $ac_word... " >&6; }
60495 if ${ac_cv_path_RADVD+:} false; then :
60496   $as_echo_n "(cached) " >&6
60497 else
60498   case $RADVD in
60499   [\\/]* | ?:[\\/]*)
60500   ac_cv_path_RADVD="$RADVD" # Let the user override the test with a path.
60501   ;;
60502   *)
60503   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
60504 as_dummy="/sbin:/usr/sbin:/usr/local/sbin:$PATH"
60505 for as_dir in $as_dummy
60506 do
60507   IFS=$as_save_IFS
60508   test -z "$as_dir" && as_dir=.
60509     for ac_exec_ext in '' $ac_executable_extensions; do
60510   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
60511     ac_cv_path_RADVD="$as_dir/$ac_word$ac_exec_ext"
60512     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
60513     break 2
60514   fi
60515 done
60516   done
60517 IFS=$as_save_IFS
60518
60519   test -z "$ac_cv_path_RADVD" && ac_cv_path_RADVD="radvd"
60520   ;;
60521 esac
60522 fi
60523 RADVD=$ac_cv_path_RADVD
60524 if test -n "$RADVD"; then
60525   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RADVD" >&5
60526 $as_echo "$RADVD" >&6; }
60527 else
60528   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
60529 $as_echo "no" >&6; }
60530 fi
60531
60532
60533 # Extract the first word of "tc", so it can be a program name with args.
60534 set dummy tc; ac_word=$2
60535 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
60536 $as_echo_n "checking for $ac_word... " >&6; }
60537 if ${ac_cv_path_TC+:} false; then :
60538   $as_echo_n "(cached) " >&6
60539 else
60540   case $TC in
60541   [\\/]* | ?:[\\/]*)
60542   ac_cv_path_TC="$TC" # Let the user override the test with a path.
60543   ;;
60544   *)
60545   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
60546 as_dummy="/sbin:/usr/sbin:/usr/local/sbin:$PATH"
60547 for as_dir in $as_dummy
60548 do
60549   IFS=$as_save_IFS
60550   test -z "$as_dir" && as_dir=.
60551     for ac_exec_ext in '' $ac_executable_extensions; do
60552   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
60553     ac_cv_path_TC="$as_dir/$ac_word$ac_exec_ext"
60554     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
60555     break 2
60556   fi
60557 done
60558   done
60559 IFS=$as_save_IFS
60560
60561   test -z "$ac_cv_path_TC" && ac_cv_path_TC="tc"
60562   ;;
60563 esac
60564 fi
60565 TC=$ac_cv_path_TC
60566 if test -n "$TC"; then
60567   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TC" >&5
60568 $as_echo "$TC" >&6; }
60569 else
60570   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
60571 $as_echo "no" >&6; }
60572 fi
60573
60574
60575 # Extract the first word of "udevadm", so it can be a program name with args.
60576 set dummy udevadm; ac_word=$2
60577 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
60578 $as_echo_n "checking for $ac_word... " >&6; }
60579 if ${ac_cv_path_UDEVADM+:} false; then :
60580   $as_echo_n "(cached) " >&6
60581 else
60582   case $UDEVADM in
60583   [\\/]* | ?:[\\/]*)
60584   ac_cv_path_UDEVADM="$UDEVADM" # Let the user override the test with a path.
60585   ;;
60586   *)
60587   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
60588 as_dummy="/sbin:/usr/sbin:/usr/local/sbin:$PATH"
60589 for as_dir in $as_dummy
60590 do
60591   IFS=$as_save_IFS
60592   test -z "$as_dir" && as_dir=.
60593     for ac_exec_ext in '' $ac_executable_extensions; do
60594   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
60595     ac_cv_path_UDEVADM="$as_dir/$ac_word$ac_exec_ext"
60596     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
60597     break 2
60598   fi
60599 done
60600   done
60601 IFS=$as_save_IFS
60602
60603   ;;
60604 esac
60605 fi
60606 UDEVADM=$ac_cv_path_UDEVADM
60607 if test -n "$UDEVADM"; then
60608   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UDEVADM" >&5
60609 $as_echo "$UDEVADM" >&6; }
60610 else
60611   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
60612 $as_echo "no" >&6; }
60613 fi
60614
60615
60616 # Extract the first word of "udevsettle", so it can be a program name with args.
60617 set dummy udevsettle; ac_word=$2
60618 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
60619 $as_echo_n "checking for $ac_word... " >&6; }
60620 if ${ac_cv_path_UDEVSETTLE+:} false; then :
60621   $as_echo_n "(cached) " >&6
60622 else
60623   case $UDEVSETTLE in
60624   [\\/]* | ?:[\\/]*)
60625   ac_cv_path_UDEVSETTLE="$UDEVSETTLE" # Let the user override the test with a path.
60626   ;;
60627   *)
60628   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
60629 as_dummy="/sbin:/usr/sbin:/usr/local/sbin:$PATH"
60630 for as_dir in $as_dummy
60631 do
60632   IFS=$as_save_IFS
60633   test -z "$as_dir" && as_dir=.
60634     for ac_exec_ext in '' $ac_executable_extensions; do
60635   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
60636     ac_cv_path_UDEVSETTLE="$as_dir/$ac_word$ac_exec_ext"
60637     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
60638     break 2
60639   fi
60640 done
60641   done
60642 IFS=$as_save_IFS
60643
60644   ;;
60645 esac
60646 fi
60647 UDEVSETTLE=$ac_cv_path_UDEVSETTLE
60648 if test -n "$UDEVSETTLE"; then
60649   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UDEVSETTLE" >&5
60650 $as_echo "$UDEVSETTLE" >&6; }
60651 else
60652   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
60653 $as_echo "no" >&6; }
60654 fi
60655
60656
60657 # Extract the first word of "modprobe", so it can be a program name with args.
60658 set dummy modprobe; ac_word=$2
60659 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
60660 $as_echo_n "checking for $ac_word... " >&6; }
60661 if ${ac_cv_path_MODPROBE+:} false; then :
60662   $as_echo_n "(cached) " >&6
60663 else
60664   case $MODPROBE in
60665   [\\/]* | ?:[\\/]*)
60666   ac_cv_path_MODPROBE="$MODPROBE" # Let the user override the test with a path.
60667   ;;
60668   *)
60669   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
60670 as_dummy="/sbin:/usr/sbin:/usr/local/sbin:$PATH"
60671 for as_dir in $as_dummy
60672 do
60673   IFS=$as_save_IFS
60674   test -z "$as_dir" && as_dir=.
60675     for ac_exec_ext in '' $ac_executable_extensions; do
60676   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
60677     ac_cv_path_MODPROBE="$as_dir/$ac_word$ac_exec_ext"
60678     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
60679     break 2
60680   fi
60681 done
60682   done
60683 IFS=$as_save_IFS
60684
60685   test -z "$ac_cv_path_MODPROBE" && ac_cv_path_MODPROBE="modprobe"
60686   ;;
60687 esac
60688 fi
60689 MODPROBE=$ac_cv_path_MODPROBE
60690 if test -n "$MODPROBE"; then
60691   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MODPROBE" >&5
60692 $as_echo "$MODPROBE" >&6; }
60693 else
60694   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
60695 $as_echo "no" >&6; }
60696 fi
60697
60698
60699 # Extract the first word of "rmmod", so it can be a program name with args.
60700 set dummy rmmod; ac_word=$2
60701 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
60702 $as_echo_n "checking for $ac_word... " >&6; }
60703 if ${ac_cv_path_RMMOD+:} false; then :
60704   $as_echo_n "(cached) " >&6
60705 else
60706   case $RMMOD in
60707   [\\/]* | ?:[\\/]*)
60708   ac_cv_path_RMMOD="$RMMOD" # Let the user override the test with a path.
60709   ;;
60710   *)
60711   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
60712 as_dummy="/sbin:/usr/sbin:/usr/local/sbin:$PATH"
60713 for as_dir in $as_dummy
60714 do
60715   IFS=$as_save_IFS
60716   test -z "$as_dir" && as_dir=.
60717     for ac_exec_ext in '' $ac_executable_extensions; do
60718   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
60719     ac_cv_path_RMMOD="$as_dir/$ac_word$ac_exec_ext"
60720     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
60721     break 2
60722   fi
60723 done
60724   done
60725 IFS=$as_save_IFS
60726
60727   test -z "$ac_cv_path_RMMOD" && ac_cv_path_RMMOD="rmmod"
60728   ;;
60729 esac
60730 fi
60731 RMMOD=$ac_cv_path_RMMOD
60732 if test -n "$RMMOD"; then
60733   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RMMOD" >&5
60734 $as_echo "$RMMOD" >&6; }
60735 else
60736   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
60737 $as_echo "no" >&6; }
60738 fi
60739
60740
60741 # Extract the first word of "ovs-vsctl", so it can be a program name with args.
60742 set dummy ovs-vsctl; ac_word=$2
60743 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
60744 $as_echo_n "checking for $ac_word... " >&6; }
60745 if ${ac_cv_path_OVSVSCTL+:} false; then :
60746   $as_echo_n "(cached) " >&6
60747 else
60748   case $OVSVSCTL in
60749   [\\/]* | ?:[\\/]*)
60750   ac_cv_path_OVSVSCTL="$OVSVSCTL" # Let the user override the test with a path.
60751   ;;
60752   *)
60753   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
60754 as_dummy="/sbin:/usr/sbin:/usr/local/sbin:$PATH"
60755 for as_dir in $as_dummy
60756 do
60757   IFS=$as_save_IFS
60758   test -z "$as_dir" && as_dir=.
60759     for ac_exec_ext in '' $ac_executable_extensions; do
60760   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
60761     ac_cv_path_OVSVSCTL="$as_dir/$ac_word$ac_exec_ext"
60762     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
60763     break 2
60764   fi
60765 done
60766   done
60767 IFS=$as_save_IFS
60768
60769   test -z "$ac_cv_path_OVSVSCTL" && ac_cv_path_OVSVSCTL="ovs-vsctl"
60770   ;;
60771 esac
60772 fi
60773 OVSVSCTL=$ac_cv_path_OVSVSCTL
60774 if test -n "$OVSVSCTL"; then
60775   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OVSVSCTL" >&5
60776 $as_echo "$OVSVSCTL" >&6; }
60777 else
60778   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
60779 $as_echo "no" >&6; }
60780 fi
60781
60782
60783 # Extract the first word of "scrub", so it can be a program name with args.
60784 set dummy scrub; ac_word=$2
60785 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
60786 $as_echo_n "checking for $ac_word... " >&6; }
60787 if ${ac_cv_path_SCRUB+:} false; then :
60788   $as_echo_n "(cached) " >&6
60789 else
60790   case $SCRUB in
60791   [\\/]* | ?:[\\/]*)
60792   ac_cv_path_SCRUB="$SCRUB" # Let the user override the test with a path.
60793   ;;
60794   *)
60795   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
60796 as_dummy="/sbin:/usr/sbin:/usr/local/sbin:$PATH"
60797 for as_dir in $as_dummy
60798 do
60799   IFS=$as_save_IFS
60800   test -z "$as_dir" && as_dir=.
60801     for ac_exec_ext in '' $ac_executable_extensions; do
60802   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
60803     ac_cv_path_SCRUB="$as_dir/$ac_word$ac_exec_ext"
60804     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
60805     break 2
60806   fi
60807 done
60808   done
60809 IFS=$as_save_IFS
60810
60811   test -z "$ac_cv_path_SCRUB" && ac_cv_path_SCRUB="scrub"
60812   ;;
60813 esac
60814 fi
60815 SCRUB=$ac_cv_path_SCRUB
60816 if test -n "$SCRUB"; then
60817   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SCRUB" >&5
60818 $as_echo "$SCRUB" >&6; }
60819 else
60820   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
60821 $as_echo "no" >&6; }
60822 fi
60823
60824
60825 # Extract the first word of "addr2line", so it can be a program name with args.
60826 set dummy addr2line; ac_word=$2
60827 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
60828 $as_echo_n "checking for $ac_word... " >&6; }
60829 if ${ac_cv_path_ADDR2LINE+:} false; then :
60830   $as_echo_n "(cached) " >&6
60831 else
60832   case $ADDR2LINE in
60833   [\\/]* | ?:[\\/]*)
60834   ac_cv_path_ADDR2LINE="$ADDR2LINE" # Let the user override the test with a path.
60835   ;;
60836   *)
60837   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
60838 as_dummy="/sbin:/usr/bin:/usr/sbin:/usr/local/sbin:$PATH"
60839 for as_dir in $as_dummy
60840 do
60841   IFS=$as_save_IFS
60842   test -z "$as_dir" && as_dir=.
60843     for ac_exec_ext in '' $ac_executable_extensions; do
60844   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
60845     ac_cv_path_ADDR2LINE="$as_dir/$ac_word$ac_exec_ext"
60846     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
60847     break 2
60848   fi
60849 done
60850   done
60851 IFS=$as_save_IFS
60852
60853   test -z "$ac_cv_path_ADDR2LINE" && ac_cv_path_ADDR2LINE="addr2line"
60854   ;;
60855 esac
60856 fi
60857 ADDR2LINE=$ac_cv_path_ADDR2LINE
60858 if test -n "$ADDR2LINE"; then
60859   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ADDR2LINE" >&5
60860 $as_echo "$ADDR2LINE" >&6; }
60861 else
60862   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
60863 $as_echo "no" >&6; }
60864 fi
60865
60866
60867
60868
60869 cat >>confdefs.h <<_ACEOF
60870 #define DMIDECODE "$DMIDECODE"
60871 _ACEOF
60872
60873
60874 cat >>confdefs.h <<_ACEOF
60875 #define DNSMASQ "$DNSMASQ"
60876 _ACEOF
60877
60878
60879 cat >>confdefs.h <<_ACEOF
60880 #define RADVD "$RADVD"
60881 _ACEOF
60882
60883
60884 cat >>confdefs.h <<_ACEOF
60885 #define TC "$TC"
60886 _ACEOF
60887
60888
60889 cat >>confdefs.h <<_ACEOF
60890 #define OVSVSCTL "$OVSVSCTL"
60891 _ACEOF
60892
60893
60894 if test -n "$UDEVADM"; then
60895
60896 cat >>confdefs.h <<_ACEOF
60897 #define UDEVADM "$UDEVADM"
60898 _ACEOF
60899
60900 fi
60901 if test -n "$UDEVSETTLE"; then
60902
60903 cat >>confdefs.h <<_ACEOF
60904 #define UDEVSETTLE "$UDEVSETTLE"
60905 _ACEOF
60906
60907 fi
60908 if test -n "$MODPROBE"; then
60909
60910 cat >>confdefs.h <<_ACEOF
60911 #define MODPROBE "$MODPROBE"
60912 _ACEOF
60913
60914 fi
60915 if test -n "$RMMOD"; then
60916
60917 cat >>confdefs.h <<_ACEOF
60918 #define RMMOD "$RMMOD"
60919 _ACEOF
60920
60921 fi
60922
60923 cat >>confdefs.h <<_ACEOF
60924 #define SCRUB "$SCRUB"
60925 _ACEOF
60926
60927
60928 cat >>confdefs.h <<_ACEOF
60929 #define ADDR2LINE "$ADDR2LINE"
60930 _ACEOF
60931
60932
60933
60934 # Check whether --with-html-dir was given.
60935 if test "${with_html_dir+set}" = set; then :
60936   withval=$with_html_dir; HTML_DIR=$withval
60937 else
60938   HTML_DIR='$(datadir)/doc'
60939 fi
60940
60941
60942
60943 # Check whether --with-html-subdir was given.
60944 if test "${with_html_subdir+set}" = set; then :
60945   withval=$with_html_subdir; test "x$withval" != "x" && HTML_DIR="$HTML_DIR/$withval"
60946 else
60947   HTML_DIR="$HTML_DIR/\$(PACKAGE)-\$(VERSION)/html"
60948 fi
60949
60950
60951
60952
60953 # Check whether --with-xml-catalog-file was given.
60954 if test "${with_xml_catalog_file+set}" = set; then :
60955   withval=$with_xml_catalog_file; XML_CATALOG_FILE=$withval
60956 else
60957   XML_CATALOG_FILE='/etc/xml/catalog'
60958 fi
60959
60960
60961
60962
60963 if test "$prefix" = "/usr" && test "$localstatedir" = '${prefix}/var' ; then
60964     localstatedir='/var'
60965 fi
60966 if test "$prefix" = "/usr" && test "$sysconfdir" = '${prefix}/etc' ; then
60967     sysconfdir='/etc'
60968 fi
60969
60970
60971 # Check whether --with-xen was given.
60972 if test "${with_xen+set}" = set; then :
60973   withval=$with_xen;
60974 fi
60975
60976
60977
60978 # Check whether --with-xen-inotify was given.
60979 if test "${with_xen_inotify+set}" = set; then :
60980   withval=$with_xen_inotify;
60981 fi
60982
60983
60984
60985 # Check whether --with-qemu was given.
60986 if test "${with_qemu+set}" = set; then :
60987   withval=$with_qemu;
60988 fi
60989
60990
60991
60992 # Check whether --with-uml was given.
60993 if test "${with_uml+set}" = set; then :
60994   withval=$with_uml;
60995 fi
60996
60997
60998
60999 # Check whether --with-openvz was given.
61000 if test "${with_openvz+set}" = set; then :
61001   withval=$with_openvz;
61002 fi
61003
61004
61005
61006 # Check whether --with-vmware was given.
61007 if test "${with_vmware+set}" = set; then :
61008   withval=$with_vmware;
61009 fi
61010
61011
61012
61013 # Check whether --with-phyp was given.
61014 if test "${with_phyp+set}" = set; then :
61015   withval=$with_phyp;
61016 fi
61017
61018
61019
61020 # Check whether --with-xenapi was given.
61021 if test "${with_xenapi+set}" = set; then :
61022   withval=$with_xenapi;
61023 fi
61024
61025
61026
61027 # Check whether --with-libxl was given.
61028 if test "${with_libxl+set}" = set; then :
61029   withval=$with_libxl;
61030 fi
61031
61032
61033
61034 # Check whether --with-vbox was given.
61035 if test "${with_vbox+set}" = set; then :
61036   withval=$with_vbox;
61037 fi
61038
61039
61040
61041 # Check whether --with-lxc was given.
61042 if test "${with_lxc+set}" = set; then :
61043   withval=$with_lxc;
61044 fi
61045
61046
61047
61048 # Check whether --with-esx was given.
61049 if test "${with_esx+set}" = set; then :
61050   withval=$with_esx;
61051 fi
61052
61053
61054
61055 # Check whether --with-hyperv was given.
61056 if test "${with_hyperv+set}" = set; then :
61057   withval=$with_hyperv;
61058 fi
61059
61060
61061
61062 # Check whether --with-parallels was given.
61063 if test "${with_parallels+set}" = set; then :
61064   withval=$with_parallels;
61065 fi
61066
61067
61068
61069 # Check whether --with-test was given.
61070 if test "${with_test+set}" = set; then :
61071   withval=$with_test;
61072 fi
61073
61074
61075
61076 # Check whether --with-remote was given.
61077 if test "${with_remote+set}" = set; then :
61078   withval=$with_remote;
61079 fi
61080
61081
61082
61083 # Check whether --with-libvirtd was given.
61084 if test "${with_libvirtd+set}" = set; then :
61085   withval=$with_libvirtd;
61086 fi
61087
61088
61089
61090 # Check whether --with-chrdev-lock-files was given.
61091 if test "${with_chrdev_lock_files+set}" = set; then :
61092   withval=$with_chrdev_lock_files;
61093 fi
61094
61095
61096
61097 # Check whether --with-pm-utils was given.
61098 if test "${with_pm_utils+set}" = set; then :
61099   withval=$with_pm_utils;
61100 fi
61101
61102
61103
61104 STATIC_BINARIES=
61105
61106
61107 # Check whether --enable-debug was given.
61108 if test "${enable_debug+set}" = set; then :
61109   enableval=$enable_debug;
61110 else
61111   enable_debug=yes
61112 fi
61113
61114  if test x"$enable_debug" = x"yes"; then
61115   ENABLE_DEBUG_TRUE=
61116   ENABLE_DEBUG_FALSE='#'
61117 else
61118   ENABLE_DEBUG_TRUE='#'
61119   ENABLE_DEBUG_FALSE=
61120 fi
61121
61122 if test x"$enable_debug" = x"yes"; then
61123
61124 $as_echo "#define ENABLE_DEBUG /**/" >>confdefs.h
61125
61126 fi
61127
61128
61129
61130 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for init script flavor" >&5
61131 $as_echo_n "checking for init script flavor... " >&6; }
61132
61133 # Check whether --with-init-script was given.
61134 if test "${with_init_script+set}" = set; then :
61135   withval=$with_init_script;
61136 else
61137   with_init_script=check
61138 fi
61139
61140 init_redhat=no
61141 init_systemd=no
61142 init_upstart=no
61143 case "$with_init_script" in
61144     systemd+redhat)
61145        init_redhat=yes
61146        init_systemd=yes
61147        ;;
61148     systemd)
61149        init_systemd=yes
61150        ;;
61151     upstart)
61152        init_upstart=yes
61153        ;;
61154     redhat)
61155        init_redhat=yes
61156        ;;
61157     none)
61158        ;;
61159     check)
61160        if test "$cross_compiling" != yes && test -f /etc/redhat-release; then
61161           init_redhat=yes
61162           with_init_script=redhat
61163        fi
61164        ;;
61165     *)
61166        as_fn_error $? "Unknown initscript flavour $with_init_script" "$LINENO" 5
61167     ;;
61168 esac
61169  if test "$init_redhat" = "yes"; then
61170   LIBVIRT_INIT_SCRIPT_RED_HAT_TRUE=
61171   LIBVIRT_INIT_SCRIPT_RED_HAT_FALSE='#'
61172 else
61173   LIBVIRT_INIT_SCRIPT_RED_HAT_TRUE='#'
61174   LIBVIRT_INIT_SCRIPT_RED_HAT_FALSE=
61175 fi
61176
61177  if test "$init_upstart" = "yes"; then
61178   LIBVIRT_INIT_SCRIPT_UPSTART_TRUE=
61179   LIBVIRT_INIT_SCRIPT_UPSTART_FALSE='#'
61180 else
61181   LIBVIRT_INIT_SCRIPT_UPSTART_TRUE='#'
61182   LIBVIRT_INIT_SCRIPT_UPSTART_FALSE=
61183 fi
61184
61185  if test "$init_systemd" = "yes"; then
61186   LIBVIRT_INIT_SCRIPT_SYSTEMD_TRUE=
61187   LIBVIRT_INIT_SCRIPT_SYSTEMD_FALSE='#'
61188 else
61189   LIBVIRT_INIT_SCRIPT_SYSTEMD_TRUE='#'
61190   LIBVIRT_INIT_SCRIPT_SYSTEMD_FALSE=
61191 fi
61192
61193 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_init_script" >&5
61194 $as_echo "$with_init_script" >&6; }
61195
61196
61197 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for whether to install sysctl config" >&5
61198 $as_echo_n "checking for whether to install sysctl config... " >&6; }
61199
61200 # Check whether --with-sysctl was given.
61201 if test "${with_sysctl+set}" = set; then :
61202   withval=$with_sysctl;
61203 else
61204   with_sysctl=check
61205 fi
61206
61207
61208 if test "$with_sysctl" = "yes" || test "$with_sysctl" = "check"
61209 then
61210   case $host in
61211     *-*-linux*)
61212       with_sysctl=yes
61213       ;;
61214     **)
61215       if test "$with_sysctl" = "yes"; then
61216          as_fn_error $? "No sysctl configuration supported for $host" "$LINENO" 5
61217       else
61218          with_sysctl=no
61219       fi
61220       ;;
61221   esac
61222 fi
61223  if test "$with_sysctl" = "yes"; then
61224   WITH_SYSCTL_TRUE=
61225   WITH_SYSCTL_FALSE='#'
61226 else
61227   WITH_SYSCTL_TRUE='#'
61228   WITH_SYSCTL_FALSE=
61229 fi
61230
61231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_sysctl" >&5
61232 $as_echo "$with_sysctl" >&6; }
61233
61234
61235 # Check whether --with-rhel5-api was given.
61236 if test "${with_rhel5_api+set}" = set; then :
61237   withval=$with_rhel5_api;
61238 fi
61239
61240 if test x"$with_rhel5_api" = x"yes"; then
61241
61242 $as_echo "#define WITH_RHEL5_API 1" >>confdefs.h
61243
61244 fi
61245
61246 # Extract the first word of "ip", so it can be a program name with args.
61247 set dummy ip; ac_word=$2
61248 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
61249 $as_echo_n "checking for $ac_word... " >&6; }
61250 if ${ac_cv_path_IP_PATH+:} false; then :
61251   $as_echo_n "(cached) " >&6
61252 else
61253   case $IP_PATH in
61254   [\\/]* | ?:[\\/]*)
61255   ac_cv_path_IP_PATH="$IP_PATH" # Let the user override the test with a path.
61256   ;;
61257   *)
61258   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
61259 as_dummy="/usr/sbin:$PATH"
61260 for as_dir in $as_dummy
61261 do
61262   IFS=$as_save_IFS
61263   test -z "$as_dir" && as_dir=.
61264     for ac_exec_ext in '' $ac_executable_extensions; do
61265   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
61266     ac_cv_path_IP_PATH="$as_dir/$ac_word$ac_exec_ext"
61267     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
61268     break 2
61269   fi
61270 done
61271   done
61272 IFS=$as_save_IFS
61273
61274   test -z "$ac_cv_path_IP_PATH" && ac_cv_path_IP_PATH="/sbin/ip"
61275   ;;
61276 esac
61277 fi
61278 IP_PATH=$ac_cv_path_IP_PATH
61279 if test -n "$IP_PATH"; then
61280   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $IP_PATH" >&5
61281 $as_echo "$IP_PATH" >&6; }
61282 else
61283   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
61284 $as_echo "no" >&6; }
61285 fi
61286
61287
61288
61289 cat >>confdefs.h <<_ACEOF
61290 #define IP_PATH "$IP_PATH"
61291 _ACEOF
61292
61293
61294 # Extract the first word of "iptables", so it can be a program name with args.
61295 set dummy iptables; ac_word=$2
61296 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
61297 $as_echo_n "checking for $ac_word... " >&6; }
61298 if ${ac_cv_path_IPTABLES_PATH+:} false; then :
61299   $as_echo_n "(cached) " >&6
61300 else
61301   case $IPTABLES_PATH in
61302   [\\/]* | ?:[\\/]*)
61303   ac_cv_path_IPTABLES_PATH="$IPTABLES_PATH" # Let the user override the test with a path.
61304   ;;
61305   *)
61306   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
61307 as_dummy="/usr/sbin:$PATH"
61308 for as_dir in $as_dummy
61309 do
61310   IFS=$as_save_IFS
61311   test -z "$as_dir" && as_dir=.
61312     for ac_exec_ext in '' $ac_executable_extensions; do
61313   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
61314     ac_cv_path_IPTABLES_PATH="$as_dir/$ac_word$ac_exec_ext"
61315     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
61316     break 2
61317   fi
61318 done
61319   done
61320 IFS=$as_save_IFS
61321
61322   test -z "$ac_cv_path_IPTABLES_PATH" && ac_cv_path_IPTABLES_PATH="/sbin/iptables"
61323   ;;
61324 esac
61325 fi
61326 IPTABLES_PATH=$ac_cv_path_IPTABLES_PATH
61327 if test -n "$IPTABLES_PATH"; then
61328   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $IPTABLES_PATH" >&5
61329 $as_echo "$IPTABLES_PATH" >&6; }
61330 else
61331   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
61332 $as_echo "no" >&6; }
61333 fi
61334
61335
61336
61337 cat >>confdefs.h <<_ACEOF
61338 #define IPTABLES_PATH "$IPTABLES_PATH"
61339 _ACEOF
61340
61341
61342 # Extract the first word of "ip6tables", so it can be a program name with args.
61343 set dummy ip6tables; ac_word=$2
61344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
61345 $as_echo_n "checking for $ac_word... " >&6; }
61346 if ${ac_cv_path_IP6TABLES_PATH+:} false; then :
61347   $as_echo_n "(cached) " >&6
61348 else
61349   case $IP6TABLES_PATH in
61350   [\\/]* | ?:[\\/]*)
61351   ac_cv_path_IP6TABLES_PATH="$IP6TABLES_PATH" # Let the user override the test with a path.
61352   ;;
61353   *)
61354   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
61355 as_dummy="/usr/sbin:$PATH"
61356 for as_dir in $as_dummy
61357 do
61358   IFS=$as_save_IFS
61359   test -z "$as_dir" && as_dir=.
61360     for ac_exec_ext in '' $ac_executable_extensions; do
61361   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
61362     ac_cv_path_IP6TABLES_PATH="$as_dir/$ac_word$ac_exec_ext"
61363     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
61364     break 2
61365   fi
61366 done
61367   done
61368 IFS=$as_save_IFS
61369
61370   test -z "$ac_cv_path_IP6TABLES_PATH" && ac_cv_path_IP6TABLES_PATH="/sbin/ip6tables"
61371   ;;
61372 esac
61373 fi
61374 IP6TABLES_PATH=$ac_cv_path_IP6TABLES_PATH
61375 if test -n "$IP6TABLES_PATH"; then
61376   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $IP6TABLES_PATH" >&5
61377 $as_echo "$IP6TABLES_PATH" >&6; }
61378 else
61379   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
61380 $as_echo "no" >&6; }
61381 fi
61382
61383
61384
61385 cat >>confdefs.h <<_ACEOF
61386 #define IP6TABLES_PATH "$IP6TABLES_PATH"
61387 _ACEOF
61388
61389
61390 # Extract the first word of "ebtables", so it can be a program name with args.
61391 set dummy ebtables; ac_word=$2
61392 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
61393 $as_echo_n "checking for $ac_word... " >&6; }
61394 if ${ac_cv_path_EBTABLES_PATH+:} false; then :
61395   $as_echo_n "(cached) " >&6
61396 else
61397   case $EBTABLES_PATH in
61398   [\\/]* | ?:[\\/]*)
61399   ac_cv_path_EBTABLES_PATH="$EBTABLES_PATH" # Let the user override the test with a path.
61400   ;;
61401   *)
61402   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
61403 as_dummy="/usr/sbin:$PATH"
61404 for as_dir in $as_dummy
61405 do
61406   IFS=$as_save_IFS
61407   test -z "$as_dir" && as_dir=.
61408     for ac_exec_ext in '' $ac_executable_extensions; do
61409   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
61410     ac_cv_path_EBTABLES_PATH="$as_dir/$ac_word$ac_exec_ext"
61411     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
61412     break 2
61413   fi
61414 done
61415   done
61416 IFS=$as_save_IFS
61417
61418   test -z "$ac_cv_path_EBTABLES_PATH" && ac_cv_path_EBTABLES_PATH="/sbin/ebtables"
61419   ;;
61420 esac
61421 fi
61422 EBTABLES_PATH=$ac_cv_path_EBTABLES_PATH
61423 if test -n "$EBTABLES_PATH"; then
61424   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EBTABLES_PATH" >&5
61425 $as_echo "$EBTABLES_PATH" >&6; }
61426 else
61427   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
61428 $as_echo "no" >&6; }
61429 fi
61430
61431
61432
61433 cat >>confdefs.h <<_ACEOF
61434 #define EBTABLES_PATH "$EBTABLES_PATH"
61435 _ACEOF
61436
61437
61438
61439
61440 if test "$with_openvz" = "check"; then
61441     with_openvz=$with_linux
61442 fi
61443
61444 if test "$with_openvz" = "yes" && test "$with_linux" = "no"; then
61445     as_fn_error $? "The OpenVZ driver can be enabled on Linux only." "$LINENO" 5
61446 fi
61447
61448 if test "$with_openvz" = "yes"; then
61449
61450 cat >>confdefs.h <<_ACEOF
61451 #define WITH_OPENVZ 1
61452 _ACEOF
61453
61454 fi
61455  if test "$with_openvz" = "yes"; then
61456   WITH_OPENVZ_TRUE=
61457   WITH_OPENVZ_FALSE='#'
61458 else
61459   WITH_OPENVZ_TRUE='#'
61460   WITH_OPENVZ_FALSE=
61461 fi
61462
61463
61464
61465
61466 if test "$with_vmware" = "yes"; then
61467
61468 cat >>confdefs.h <<_ACEOF
61469 #define WITH_VMWARE 1
61470 _ACEOF
61471
61472 fi
61473  if test "$with_vmware" = "yes"; then
61474   WITH_VMWARE_TRUE=
61475   WITH_VMWARE_FALSE='#'
61476 else
61477   WITH_VMWARE_TRUE='#'
61478   WITH_VMWARE_FALSE=
61479 fi
61480
61481
61482
61483
61484 if test x"$with_remote" = x"yes" || test x"$with_libvirtd" = x"yes"; then
61485                     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xdrmem_create in -lportablexdr" >&5
61486 $as_echo_n "checking for xdrmem_create in -lportablexdr... " >&6; }
61487 if ${ac_cv_lib_portablexdr_xdrmem_create+:} false; then :
61488   $as_echo_n "(cached) " >&6
61489 else
61490   ac_check_lib_save_LIBS=$LIBS
61491 LIBS="-lportablexdr  $LIBS"
61492 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
61493 /* end confdefs.h.  */
61494
61495 /* Override any GCC internal prototype to avoid an error.
61496    Use char because int might match the return type of a GCC
61497    builtin and then its argument prototype would still apply.  */
61498 #ifdef __cplusplus
61499 extern "C"
61500 #endif
61501 char xdrmem_create ();
61502 int
61503 main ()
61504 {
61505 return xdrmem_create ();
61506   ;
61507   return 0;
61508 }
61509 _ACEOF
61510 if ac_fn_c_try_link "$LINENO"; then :
61511   ac_cv_lib_portablexdr_xdrmem_create=yes
61512 else
61513   ac_cv_lib_portablexdr_xdrmem_create=no
61514 fi
61515 rm -f core conftest.err conftest.$ac_objext \
61516     conftest$ac_exeext conftest.$ac_ext
61517 LIBS=$ac_check_lib_save_LIBS
61518 fi
61519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_portablexdr_xdrmem_create" >&5
61520 $as_echo "$ac_cv_lib_portablexdr_xdrmem_create" >&6; }
61521 if test "x$ac_cv_lib_portablexdr_xdrmem_create" = xyes; then :
61522   cat >>confdefs.h <<_ACEOF
61523 #define HAVE_LIBPORTABLEXDR 1
61524 _ACEOF
61525
61526   LIBS="-lportablexdr $LIBS"
61527
61528 else
61529
61530         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing xdrmem_create" >&5
61531 $as_echo_n "checking for library containing xdrmem_create... " >&6; }
61532 if ${ac_cv_search_xdrmem_create+:} false; then :
61533   $as_echo_n "(cached) " >&6
61534 else
61535   ac_func_search_save_LIBS=$LIBS
61536 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
61537 /* end confdefs.h.  */
61538
61539 /* Override any GCC internal prototype to avoid an error.
61540    Use char because int might match the return type of a GCC
61541    builtin and then its argument prototype would still apply.  */
61542 #ifdef __cplusplus
61543 extern "C"
61544 #endif
61545 char xdrmem_create ();
61546 int
61547 main ()
61548 {
61549 return xdrmem_create ();
61550   ;
61551   return 0;
61552 }
61553 _ACEOF
61554 for ac_lib in '' rpc xdr nsl tirpc; do
61555   if test -z "$ac_lib"; then
61556     ac_res="none required"
61557   else
61558     ac_res=-l$ac_lib
61559     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
61560   fi
61561   if ac_fn_c_try_link "$LINENO"; then :
61562   ac_cv_search_xdrmem_create=$ac_res
61563 fi
61564 rm -f core conftest.err conftest.$ac_objext \
61565     conftest$ac_exeext
61566   if ${ac_cv_search_xdrmem_create+:} false; then :
61567   break
61568 fi
61569 done
61570 if ${ac_cv_search_xdrmem_create+:} false; then :
61571
61572 else
61573   ac_cv_search_xdrmem_create=no
61574 fi
61575 rm conftest.$ac_ext
61576 LIBS=$ac_func_search_save_LIBS
61577 fi
61578 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_xdrmem_create" >&5
61579 $as_echo "$ac_cv_search_xdrmem_create" >&6; }
61580 ac_res=$ac_cv_search_xdrmem_create
61581 if test "$ac_res" != no; then :
61582   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
61583
61584 else
61585   as_fn_error $? "Cannot find a XDR library" "$LINENO" 5
61586 fi
61587
61588
61589 fi
61590
61591
61592         for ac_func in xdr_u_int64_t
61593 do :
61594   ac_fn_c_check_func "$LINENO" "xdr_u_int64_t" "ac_cv_func_xdr_u_int64_t"
61595 if test "x$ac_cv_func_xdr_u_int64_t" = xyes; then :
61596   cat >>confdefs.h <<_ACEOF
61597 #define HAVE_XDR_U_INT64_T 1
61598 _ACEOF
61599
61600 fi
61601 done
61602
61603
61604         old_CFLAGS=$CFLAGS
61605     { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find <rpc/rpc.h>" >&5
61606 $as_echo_n "checking where to find <rpc/rpc.h>... " >&6; }
61607 if ${lv_cv_xdr_cflags+:} false; then :
61608   $as_echo_n "(cached) " >&6
61609 else
61610
61611       for add_CFLAGS in '' '-I/usr/include/tirpc' 'missing'; do
61612         if test x"$add_CFLAGS" = xmissing; then
61613           lv_cv_xdr_cflags=missing; break
61614         fi
61615         CFLAGS="$old_CFLAGS $add_CFLAGS"
61616         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
61617 /* end confdefs.h.  */
61618 #include <rpc/rpc.h>
61619
61620 int
61621 main ()
61622 {
61623
61624   ;
61625   return 0;
61626 }
61627 _ACEOF
61628 if ac_fn_c_try_compile "$LINENO"; then :
61629   lv_cv_xdr_cflags=${add_CFLAGS:-none}; break
61630 fi
61631 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
61632       done
61633
61634 fi
61635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lv_cv_xdr_cflags" >&5
61636 $as_echo "$lv_cv_xdr_cflags" >&6; }
61637     CFLAGS=$old_CFLAGS
61638     case $lv_cv_xdr_cflags in
61639       none) XDR_CFLAGS= ;;
61640       missing) as_fn_error $? "Unable to find <rpc/rpc.h>" "$LINENO" 5 ;;
61641       *) XDR_CFLAGS=$lv_cv_xdr_cflags ;;
61642     esac
61643
61644 fi
61645
61646
61647
61648 dlfcn_found=yes
61649 dlopen_found=yes
61650
61651 ac_fn_c_check_header_mongrel "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default"
61652 if test "x$ac_cv_header_dlfcn_h" = xyes; then :
61653
61654 else
61655   dlfcn_found=no
61656 fi
61657
61658
61659 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlopen" >&5
61660 $as_echo_n "checking for library containing dlopen... " >&6; }
61661 if ${ac_cv_search_dlopen+:} false; then :
61662   $as_echo_n "(cached) " >&6
61663 else
61664   ac_func_search_save_LIBS=$LIBS
61665 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
61666 /* end confdefs.h.  */
61667
61668 /* Override any GCC internal prototype to avoid an error.
61669    Use char because int might match the return type of a GCC
61670    builtin and then its argument prototype would still apply.  */
61671 #ifdef __cplusplus
61672 extern "C"
61673 #endif
61674 char dlopen ();
61675 int
61676 main ()
61677 {
61678 return dlopen ();
61679   ;
61680   return 0;
61681 }
61682 _ACEOF
61683 for ac_lib in '' dl; do
61684   if test -z "$ac_lib"; then
61685     ac_res="none required"
61686   else
61687     ac_res=-l$ac_lib
61688     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
61689   fi
61690   if ac_fn_c_try_link "$LINENO"; then :
61691   ac_cv_search_dlopen=$ac_res
61692 fi
61693 rm -f core conftest.err conftest.$ac_objext \
61694     conftest$ac_exeext
61695   if ${ac_cv_search_dlopen+:} false; then :
61696   break
61697 fi
61698 done
61699 if ${ac_cv_search_dlopen+:} false; then :
61700
61701 else
61702   ac_cv_search_dlopen=no
61703 fi
61704 rm conftest.$ac_ext
61705 LIBS=$ac_func_search_save_LIBS
61706 fi
61707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlopen" >&5
61708 $as_echo "$ac_cv_search_dlopen" >&6; }
61709 ac_res=$ac_cv_search_dlopen
61710 if test "$ac_res" != no; then :
61711   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
61712
61713 else
61714   dlopen_found=no
61715 fi
61716
61717
61718 case $ac_cv_search_dlopen:$host_os in
61719   'none required'* | *:mingw* | *:msvc*) DLOPEN_LIBS= ;;
61720   no*) as_fn_error $? "Unable to find dlopen()" "$LINENO" 5 ;;
61721   *) if test "x$dlfcn_found" != "xyes"; then
61722        as_fn_error $? "Unable to find dlfcn.h" "$LINENO" 5
61723      fi
61724      DLOPEN_LIBS=$ac_cv_search_dlopen ;;
61725 esac
61726
61727
61728
61729
61730
61731 vbox_xpcomc_dir=
61732
61733 if test "x$with_vbox" != "xyes" && test "x$with_vbox" != "xno"; then
61734     # intentionally don't do any further checks here on the provided path
61735     vbox_xpcomc_dir=$with_vbox
61736     with_vbox=yes
61737 fi
61738
61739
61740 cat >>confdefs.h <<_ACEOF
61741 #define VBOX_XPCOMC_DIR "$vbox_xpcomc_dir"
61742 _ACEOF
61743
61744
61745 if test "x$with_vbox" = "xyes"; then
61746
61747 cat >>confdefs.h <<_ACEOF
61748 #define WITH_VBOX 1
61749 _ACEOF
61750
61751 fi
61752  if test "$with_vbox" = "yes"; then
61753   WITH_VBOX_TRUE=
61754   WITH_VBOX_FALSE='#'
61755 else
61756   WITH_VBOX_TRUE='#'
61757   WITH_VBOX_FALSE=
61758 fi
61759
61760
61761 if test "$with_qemu" = "yes" ; then
61762
61763 cat >>confdefs.h <<_ACEOF
61764 #define WITH_QEMU 1
61765 _ACEOF
61766
61767 fi
61768  if test "$with_qemu" = "yes"; then
61769   WITH_QEMU_TRUE=
61770   WITH_QEMU_FALSE='#'
61771 else
61772   WITH_QEMU_TRUE='#'
61773   WITH_QEMU_FALSE=
61774 fi
61775
61776
61777 if test "$with_test" = "yes" ; then
61778
61779 cat >>confdefs.h <<_ACEOF
61780 #define WITH_TEST 1
61781 _ACEOF
61782
61783 fi
61784  if test "$with_test" = "yes"; then
61785   WITH_TEST_TRUE=
61786   WITH_TEST_FALSE='#'
61787 else
61788   WITH_TEST_TRUE='#'
61789   WITH_TEST_FALSE=
61790 fi
61791
61792
61793 if test "$with_remote" = "yes" ; then
61794
61795 cat >>confdefs.h <<_ACEOF
61796 #define WITH_REMOTE 1
61797 _ACEOF
61798
61799 fi
61800  if test "$with_remote" = "yes"; then
61801   WITH_REMOTE_TRUE=
61802   WITH_REMOTE_FALSE='#'
61803 else
61804   WITH_REMOTE_TRUE='#'
61805   WITH_REMOTE_FALSE=
61806 fi
61807
61808
61809 if test "$with_libvirtd" = "yes" ; then
61810
61811 cat >>confdefs.h <<_ACEOF
61812 #define WITH_LIBVIRTD 1
61813 _ACEOF
61814
61815 fi
61816  if test "$with_libvirtd" = "yes"; then
61817   WITH_LIBVIRTD_TRUE=
61818   WITH_LIBVIRTD_FALSE='#'
61819 else
61820   WITH_LIBVIRTD_TRUE='#'
61821   WITH_LIBVIRTD_FALSE=
61822 fi
61823
61824
61825
61826 old_LIBS="$LIBS"
61827 old_CFLAGS="$CFLAGS"
61828 LIBXENSERVER_LIBS=""
61829 LIBXENSERVER_CFLAGS=""
61830 fail=0
61831 if test "$with_xenapi" != "no" ; then
61832     if test "$with_xenapi" != "yes" && test "$with_xenapi" != "check" ; then
61833         LIBXENSERVER_CFLAGS="-I$with_xenapi/include"
61834         LIBXENSERVER_LIBS="-L$with_xenapi"
61835     fi
61836     CFLAGS="$CFLAGS $LIBXENSERVER_CFLAGS"
61837     LIBS="$LIBS $LIBXENSERVER_LIBS"
61838     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xen_vm_start in -lxenserver" >&5
61839 $as_echo_n "checking for xen_vm_start in -lxenserver... " >&6; }
61840 if ${ac_cv_lib_xenserver_xen_vm_start+:} false; then :
61841   $as_echo_n "(cached) " >&6
61842 else
61843   ac_check_lib_save_LIBS=$LIBS
61844 LIBS="-lxenserver  $LIBS"
61845 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
61846 /* end confdefs.h.  */
61847
61848 /* Override any GCC internal prototype to avoid an error.
61849    Use char because int might match the return type of a GCC
61850    builtin and then its argument prototype would still apply.  */
61851 #ifdef __cplusplus
61852 extern "C"
61853 #endif
61854 char xen_vm_start ();
61855 int
61856 main ()
61857 {
61858 return xen_vm_start ();
61859   ;
61860   return 0;
61861 }
61862 _ACEOF
61863 if ac_fn_c_try_link "$LINENO"; then :
61864   ac_cv_lib_xenserver_xen_vm_start=yes
61865 else
61866   ac_cv_lib_xenserver_xen_vm_start=no
61867 fi
61868 rm -f core conftest.err conftest.$ac_objext \
61869     conftest$ac_exeext conftest.$ac_ext
61870 LIBS=$ac_check_lib_save_LIBS
61871 fi
61872 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xenserver_xen_vm_start" >&5
61873 $as_echo "$ac_cv_lib_xenserver_xen_vm_start" >&6; }
61874 if test "x$ac_cv_lib_xenserver_xen_vm_start" = xyes; then :
61875
61876         LIBXENSERVER_LIBS="$LIBXENSERVER_LIBS -lxenserver"
61877
61878 else
61879
61880         if test "$with_xenapi" = "yes"; then
61881             fail=1
61882         fi
61883         with_xenapi=no
61884
61885 fi
61886
61887     if test "$with_xenapi" != "no" ; then
61888         if test "$with_curl" = "no"; then
61889             if test "$with_xenapi" = "yes"; then
61890                 fail=1
61891             fi
61892             with_xenapi=no
61893         else
61894             with_xenapi=yes
61895         fi
61896     fi
61897 fi
61898
61899 LIBS="$old_LIBS"
61900 CFLAGS="$old_CFLAGS"
61901
61902 if test $fail = 1; then
61903     as_fn_error $? "You must install libxenserver and libcurl to compile the XenAPI driver" "$LINENO" 5
61904 fi
61905
61906 if test "$with_xenapi" = "yes"; then
61907
61908 cat >>confdefs.h <<_ACEOF
61909 #define WITH_XENAPI 1
61910 _ACEOF
61911
61912 fi
61913
61914
61915
61916
61917 old_LIBS="$LIBS"
61918 old_CFLAGS="$CFLAGS"
61919 LIBXL_LIBS=""
61920 LIBXL_CFLAGS=""
61921 fail=0
61922 if test "$with_libxl" != "no" ; then
61923     if test "$with_libxl" != "yes" && test "$with_libxl" != "check" ; then
61924         LIBXL_CFLAGS="-I$with_libxl/include"
61925         LIBXL_LIBS="-L$with_libxl"
61926     fi
61927     CFLAGS="$CFLAGS $LIBXL_CFLAGS"
61928     LIBS="$LIBS $LIBXL_LIBS"
61929     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libxl_ctx_alloc in -lxenlight" >&5
61930 $as_echo_n "checking for libxl_ctx_alloc in -lxenlight... " >&6; }
61931 if ${ac_cv_lib_xenlight_libxl_ctx_alloc+:} false; then :
61932   $as_echo_n "(cached) " >&6
61933 else
61934   ac_check_lib_save_LIBS=$LIBS
61935 LIBS="-lxenlight  $LIBS"
61936 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
61937 /* end confdefs.h.  */
61938
61939 /* Override any GCC internal prototype to avoid an error.
61940    Use char because int might match the return type of a GCC
61941    builtin and then its argument prototype would still apply.  */
61942 #ifdef __cplusplus
61943 extern "C"
61944 #endif
61945 char libxl_ctx_alloc ();
61946 int
61947 main ()
61948 {
61949 return libxl_ctx_alloc ();
61950   ;
61951   return 0;
61952 }
61953 _ACEOF
61954 if ac_fn_c_try_link "$LINENO"; then :
61955   ac_cv_lib_xenlight_libxl_ctx_alloc=yes
61956 else
61957   ac_cv_lib_xenlight_libxl_ctx_alloc=no
61958 fi
61959 rm -f core conftest.err conftest.$ac_objext \
61960     conftest$ac_exeext conftest.$ac_ext
61961 LIBS=$ac_check_lib_save_LIBS
61962 fi
61963 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xenlight_libxl_ctx_alloc" >&5
61964 $as_echo "$ac_cv_lib_xenlight_libxl_ctx_alloc" >&6; }
61965 if test "x$ac_cv_lib_xenlight_libxl_ctx_alloc" = xyes; then :
61966
61967         with_libxl=yes
61968         LIBXL_LIBS="$LIBXL_LIBS -lxenlight -lxenctrl"
61969
61970 else
61971
61972         if test "$with_libxl" = "yes"; then
61973             fail=1
61974         fi
61975         with_libxl=no
61976
61977 fi
61978
61979 fi
61980
61981 LIBS="$old_LIBS"
61982 CFLAGS="$old_CFLAGS"
61983
61984 if test $fail = 1; then
61985     as_fn_error $? "You must install the libxl Library from Xen >= 4.2 to compile libxenlight driver with -lxl" "$LINENO" 5
61986 fi
61987
61988 if test "$with_libxl" = "yes"; then
61989
61990 cat >>confdefs.h <<_ACEOF
61991 #define WITH_LIBXL 1
61992 _ACEOF
61993
61994 fi
61995  if test "$with_libxl" = "yes"; then
61996   WITH_LIBXL_TRUE=
61997   WITH_LIBXL_FALSE='#'
61998 else
61999   WITH_LIBXL_TRUE='#'
62000   WITH_LIBXL_FALSE=
62001 fi
62002
62003
62004
62005
62006
62007 old_LIBS="$LIBS"
62008 old_CFLAGS="$CFLAGS"
62009 XEN_LIBS=""
62010 XEN_CFLAGS=""
62011 if test "$with_xen" != "no" ; then
62012     if test "$with_xen" != "yes" && test "$with_xen" != "check" ; then
62013         XEN_CFLAGS="-I$with_xen/include"
62014         XEN_LIBS="-L$with_xen/lib64 -L$with_xen/lib"
62015     fi
62016     fail=0
62017     CFLAGS="$CFLAGS $XEN_CFLAGS"
62018     LIBS="$LIBS $XEN_LIBS"
62019     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xs_read in -lxenstore" >&5
62020 $as_echo_n "checking for xs_read in -lxenstore... " >&6; }
62021 if ${ac_cv_lib_xenstore_xs_read+:} false; then :
62022   $as_echo_n "(cached) " >&6
62023 else
62024   ac_check_lib_save_LIBS=$LIBS
62025 LIBS="-lxenstore  $LIBS"
62026 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
62027 /* end confdefs.h.  */
62028
62029 /* Override any GCC internal prototype to avoid an error.
62030    Use char because int might match the return type of a GCC
62031    builtin and then its argument prototype would still apply.  */
62032 #ifdef __cplusplus
62033 extern "C"
62034 #endif
62035 char xs_read ();
62036 int
62037 main ()
62038 {
62039 return xs_read ();
62040   ;
62041   return 0;
62042 }
62043 _ACEOF
62044 if ac_fn_c_try_link "$LINENO"; then :
62045   ac_cv_lib_xenstore_xs_read=yes
62046 else
62047   ac_cv_lib_xenstore_xs_read=no
62048 fi
62049 rm -f core conftest.err conftest.$ac_objext \
62050     conftest$ac_exeext conftest.$ac_ext
62051 LIBS=$ac_check_lib_save_LIBS
62052 fi
62053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xenstore_xs_read" >&5
62054 $as_echo "$ac_cv_lib_xenstore_xs_read" >&6; }
62055 if test "x$ac_cv_lib_xenstore_xs_read" = xyes; then :
62056
62057            with_xen=yes
62058            XEN_LIBS="$XEN_LIBS -lxenstore"
62059
62060 else
62061
62062            if test "$with_xen" = "yes"; then
62063                fail=1
62064            fi
62065            with_xen=no
62066
62067 fi
62068
62069 fi
62070
62071 if test "$with_xen" != "no" ; then
62072         for ac_header in xenstore.h
62073 do :
62074   ac_fn_c_check_header_mongrel "$LINENO" "xenstore.h" "ac_cv_header_xenstore_h" "$ac_includes_default"
62075 if test "x$ac_cv_header_xenstore_h" = xyes; then :
62076   cat >>confdefs.h <<_ACEOF
62077 #define HAVE_XENSTORE_H 1
62078 _ACEOF
62079
62080 fi
62081
62082 done
62083
62084     for ac_header in xen/xen.h xen/version.h xen/dom0_ops.h
62085 do :
62086   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
62087 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "#include <stdio.h>
62088 #include <stdint.h>
62089
62090 "
62091 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
62092   cat >>confdefs.h <<_ACEOF
62093 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
62094 _ACEOF
62095
62096 else
62097
62098        if test "$with_xen" = "yes"; then
62099            fail=1
62100        fi
62101        with_xen=no
62102
62103 fi
62104
62105 done
62106
62107 fi
62108
62109 if test "$with_xen" != "no" ; then
62110         found=
62111     for ac_header in xen/sys/privcmd.h xen/linux/privcmd.h
62112 do :
62113   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
62114 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "#include <stdio.h>
62115         #include <stdint.h>
62116         #include <xen/xen.h>
62117
62118 "
62119 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
62120   cat >>confdefs.h <<_ACEOF
62121 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
62122 _ACEOF
62123  found=yes; break;
62124 fi
62125
62126 done
62127
62128     if test "x$found" != "xyes"; then
62129         if test "$with_xen" = "yes"; then
62130             fail=1
62131         fi
62132         with_xen=no
62133     fi
62134 fi
62135
62136 LIBS="$old_LIBS"
62137 CFLAGS="$old_CFLAGS"
62138
62139 if test $fail = 1; then
62140     as_fn_error $? "You must install the Xen development package to compile Xen driver with -lxenstore" "$LINENO" 5
62141 fi
62142
62143 if test "$with_xen" = "yes"; then
62144
62145 cat >>confdefs.h <<_ACEOF
62146 #define WITH_XEN 1
62147 _ACEOF
62148
62149 fi
62150
62151  if test "$with_xen" = "yes"; then
62152   WITH_XEN_TRUE=
62153   WITH_XEN_FALSE='#'
62154 else
62155   WITH_XEN_TRUE='#'
62156   WITH_XEN_FALSE=
62157 fi
62158
62159
62160
62161
62162  if test "$with_libxl" = "yes" || test "$with_xen" = "yes"; then
62163   WITH_XENXS_TRUE=
62164   WITH_XENXS_FALSE='#'
62165 else
62166   WITH_XENXS_TRUE='#'
62167   WITH_XENXS_FALSE=
62168 fi
62169
62170
62171 if test "$with_xen" != "yes"; then
62172     with_xen_inotify=no
62173 fi
62174 if test "$with_xen_inotify" != "no"; then
62175     ac_fn_c_check_header_mongrel "$LINENO" "sys/inotify.h" "ac_cv_header_sys_inotify_h" "$ac_includes_default"
62176 if test "x$ac_cv_header_sys_inotify_h" = xyes; then :
62177
62178         with_xen_inotify=yes
62179
62180 else
62181
62182         if test "$with_xen_inotify" = "check"; then
62183             with_xen_inotify=no
62184             { $as_echo "$as_me:${as_lineno-$LINENO}: Header file <sys/inotify.h> is required for Xen Inotify support, disabling it" >&5
62185 $as_echo "$as_me: Header file <sys/inotify.h> is required for Xen Inotify support, disabling it" >&6;}
62186         else
62187             as_fn_error $? "Header file <sys/inotify.h> is required for Xen Inotify support!" "$LINENO" 5
62188         fi
62189     0
62190 fi
62191
62192
62193 fi
62194 if test "$with_xen_inotify" = "yes"; then
62195
62196 cat >>confdefs.h <<_ACEOF
62197 #define WITH_XEN_INOTIFY 1
62198 _ACEOF
62199
62200 fi
62201  if test "$with_xen_inotify" = "yes"; then
62202   WITH_XEN_INOTIFY_TRUE=
62203   WITH_XEN_INOTIFY_FALSE='#'
62204 else
62205   WITH_XEN_INOTIFY_TRUE='#'
62206   WITH_XEN_INOTIFY_FALSE=
62207 fi
62208
62209
62210 for ac_header in linux/kvm.h
62211 do :
62212   ac_fn_c_check_header_mongrel "$LINENO" "linux/kvm.h" "ac_cv_header_linux_kvm_h" "$ac_includes_default"
62213 if test "x$ac_cv_header_linux_kvm_h" = xyes; then :
62214   cat >>confdefs.h <<_ACEOF
62215 #define HAVE_LINUX_KVM_H 1
62216 _ACEOF
62217
62218 fi
62219
62220 done
62221
62222
62223 if test "$with_libvirtd" = "no" ; then
62224   with_lxc=no
62225 fi
62226 if test "$with_lxc" = "yes" || test "$with_lxc" = "check"; then
62227     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
62228 /* end confdefs.h.  */
62229
62230         #include <sched.h>
62231         #include <linux/loop.h>
62232         #include <sys/epoll.h>
62233
62234 int
62235 main ()
62236 {
62237
62238         unshare(!(LO_FLAGS_AUTOCLEAR + EPOLL_CLOEXEC));
62239
62240   ;
62241   return 0;
62242 }
62243 _ACEOF
62244 if ac_fn_c_try_link "$LINENO"; then :
62245
62246         with_lxc=yes
62247
62248 $as_echo "#define HAVE_DECL_LO_FLAGS_AUTOCLEAR 1" >>confdefs.h
62249
62250
62251 else
62252
62253         if test "$with_lxc" = "check"; then
62254             with_lxc=no
62255             { $as_echo "$as_me:${as_lineno-$LINENO}: Required kernel features were not found, disabling LXC" >&5
62256 $as_echo "$as_me: Required kernel features were not found, disabling LXC" >&6;}
62257         else
62258             as_fn_error $? "Required kernel features for LXC were not found" "$LINENO" 5
62259         fi
62260
62261 fi
62262 rm -f core conftest.err conftest.$ac_objext \
62263     conftest$ac_exeext conftest.$ac_ext
62264     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
62265 /* end confdefs.h.  */
62266
62267         #include <sched.h>
62268         #include <linux/loop.h>
62269         #include <sys/epoll.h>
62270
62271 int
62272 main ()
62273 {
62274
62275         unshare(!(LOOP_CTL_GET_FREE));
62276
62277   ;
62278   return 0;
62279 }
62280 _ACEOF
62281 if ac_fn_c_try_link "$LINENO"; then :
62282
62283
62284 $as_echo "#define HAVE_DECL_LOOP_CTL_GET_FREE 1" >>confdefs.h
62285
62286
62287 fi
62288 rm -f core conftest.err conftest.$ac_objext \
62289     conftest$ac_exeext conftest.$ac_ext
62290 fi
62291 if test "$with_lxc" = "yes" ; then
62292
62293 cat >>confdefs.h <<_ACEOF
62294 #define WITH_LXC 1
62295 _ACEOF
62296
62297 fi
62298  if test "$with_lxc" = "yes"; then
62299   WITH_LXC_TRUE=
62300   WITH_LXC_FALSE='#'
62301 else
62302   WITH_LXC_TRUE='#'
62303   WITH_LXC_FALSE=
62304 fi
62305
62306
62307
62308 if test "$with_parallels" = "check"; then
62309     with_parallels=$with_linux
62310     if test ! $host_cpu = 'x86_64'; then
62311         with_parallels=no
62312     fi
62313 fi
62314
62315 if test "$with_parallels" = "yes" && test "$with_linux" = "no"; then
62316     as_fn_error $? "The Parallels driver can be enabled on Linux only." "$LINENO" 5
62317 fi
62318
62319 if test "$with_parallels" = "yes"; then
62320
62321 cat >>confdefs.h <<_ACEOF
62322 #define WITH_PARALLELS 1
62323 _ACEOF
62324
62325 fi
62326  if test "$with_parallels" = "yes"; then
62327   WITH_PARALLELS_TRUE=
62328   WITH_PARALLELS_FALSE='#'
62329 else
62330   WITH_PARALLELS_TRUE='#'
62331   WITH_PARALLELS_FALSE=
62332 fi
62333
62334
62335
62336
62337
62338 # Check whether --with-bhyve was given.
62339 if test "${with_bhyve+set}" = set; then :
62340   withval=$with_bhyve;
62341 fi
62342
62343
62344
62345     if test "$with_bhyve" != "no"; then
62346         # Extract the first word of "bhyve", so it can be a program name with args.
62347 set dummy bhyve; ac_word=$2
62348 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
62349 $as_echo_n "checking for $ac_word... " >&6; }
62350 if ${ac_cv_path_BHYVE+:} false; then :
62351   $as_echo_n "(cached) " >&6
62352 else
62353   case $BHYVE in
62354   [\\/]* | ?:[\\/]*)
62355   ac_cv_path_BHYVE="$BHYVE" # Let the user override the test with a path.
62356   ;;
62357   *)
62358   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
62359 as_dummy="$PATH:/usr/sbin"
62360 for as_dir in $as_dummy
62361 do
62362   IFS=$as_save_IFS
62363   test -z "$as_dir" && as_dir=.
62364     for ac_exec_ext in '' $ac_executable_extensions; do
62365   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
62366     ac_cv_path_BHYVE="$as_dir/$ac_word$ac_exec_ext"
62367     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
62368     break 2
62369   fi
62370 done
62371   done
62372 IFS=$as_save_IFS
62373
62374   ;;
62375 esac
62376 fi
62377 BHYVE=$ac_cv_path_BHYVE
62378 if test -n "$BHYVE"; then
62379   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BHYVE" >&5
62380 $as_echo "$BHYVE" >&6; }
62381 else
62382   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
62383 $as_echo "no" >&6; }
62384 fi
62385
62386
62387         # Extract the first word of "bhyvectl", so it can be a program name with args.
62388 set dummy bhyvectl; ac_word=$2
62389 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
62390 $as_echo_n "checking for $ac_word... " >&6; }
62391 if ${ac_cv_path_BHYVECTL+:} false; then :
62392   $as_echo_n "(cached) " >&6
62393 else
62394   case $BHYVECTL in
62395   [\\/]* | ?:[\\/]*)
62396   ac_cv_path_BHYVECTL="$BHYVECTL" # Let the user override the test with a path.
62397   ;;
62398   *)
62399   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
62400 as_dummy="$PATH:/usr/sbin"
62401 for as_dir in $as_dummy
62402 do
62403   IFS=$as_save_IFS
62404   test -z "$as_dir" && as_dir=.
62405     for ac_exec_ext in '' $ac_executable_extensions; do
62406   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
62407     ac_cv_path_BHYVECTL="$as_dir/$ac_word$ac_exec_ext"
62408     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
62409     break 2
62410   fi
62411 done
62412   done
62413 IFS=$as_save_IFS
62414
62415   ;;
62416 esac
62417 fi
62418 BHYVECTL=$ac_cv_path_BHYVECTL
62419 if test -n "$BHYVECTL"; then
62420   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BHYVECTL" >&5
62421 $as_echo "$BHYVECTL" >&6; }
62422 else
62423   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
62424 $as_echo "no" >&6; }
62425 fi
62426
62427
62428         # Extract the first word of "bhyveload", so it can be a program name with args.
62429 set dummy bhyveload; ac_word=$2
62430 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
62431 $as_echo_n "checking for $ac_word... " >&6; }
62432 if ${ac_cv_path_BHYVELOAD+:} false; then :
62433   $as_echo_n "(cached) " >&6
62434 else
62435   case $BHYVELOAD in
62436   [\\/]* | ?:[\\/]*)
62437   ac_cv_path_BHYVELOAD="$BHYVELOAD" # Let the user override the test with a path.
62438   ;;
62439   *)
62440   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
62441 as_dummy="$PATH:/usr/sbin/"
62442 for as_dir in $as_dummy
62443 do
62444   IFS=$as_save_IFS
62445   test -z "$as_dir" && as_dir=.
62446     for ac_exec_ext in '' $ac_executable_extensions; do
62447   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
62448     ac_cv_path_BHYVELOAD="$as_dir/$ac_word$ac_exec_ext"
62449     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
62450     break 2
62451   fi
62452 done
62453   done
62454 IFS=$as_save_IFS
62455
62456   ;;
62457 esac
62458 fi
62459 BHYVELOAD=$ac_cv_path_BHYVELOAD
62460 if test -n "$BHYVELOAD"; then
62461   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BHYVELOAD" >&5
62462 $as_echo "$BHYVELOAD" >&6; }
62463 else
62464   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
62465 $as_echo "no" >&6; }
62466 fi
62467
62468
62469
62470         if test -z "$BHYVE" || test -z "$BHYVECTL" \
62471             test -z "$BHYVELOAD" || test "$with_freebsd" = "no"; then
62472             if test "$with_bhyve" = "check"; then
62473                 with_bhyve="no"
62474             else
62475                 as_fn_error $? "The bhyve driver cannot be enabled" "$LINENO" 5
62476             fi
62477         else
62478             with_bhyve="yes"
62479         fi
62480     fi
62481
62482     if test "$with_bhyve" = "yes"; then
62483
62484 cat >>confdefs.h <<_ACEOF
62485 #define WITH_BHYVE 1
62486 _ACEOF
62487
62488
62489 cat >>confdefs.h <<_ACEOF
62490 #define BHYVE "$BHYVE"
62491 _ACEOF
62492
62493
62494 cat >>confdefs.h <<_ACEOF
62495 #define BHYVECTL "$BHYVECTL"
62496 _ACEOF
62497
62498
62499 cat >>confdefs.h <<_ACEOF
62500 #define BHYVELOAD "$BHYVELOAD"
62501 _ACEOF
62502
62503     fi
62504      if test "$with_bhyve" = "yes"; then
62505   WITH_BHYVE_TRUE=
62506   WITH_BHYVE_FALSE='#'
62507 else
62508   WITH_BHYVE_TRUE='#'
62509   WITH_BHYVE_FALSE=
62510 fi
62511
62512
62513
62514 if test "$with_qemu" = yes; then
62515   lv_wrapper_shell=
62516   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shell that supports <> redirection" >&5
62517 $as_echo_n "checking for shell that supports <> redirection... " >&6; }
62518 if ${lv_cv_wrapper_shell+:} false; then :
62519   $as_echo_n "(cached) " >&6
62520 else
62521
62522     # If cross-compiling, guess that /bin/sh is good enough except for
62523     # Linux, where it might be dash 0.5.5 which is known broken; and on
62524     # Linux, we have a good chance that /bin/bash will exist.
62525     # If we guess wrong, a user can override the cache variable.
62526     # Going through /bin/bash is a slight slowdown if /bin/sh works.
62527     if test "$cross_compiling" = yes; then
62528       case $host_os in
62529         linux*) lv_cv_wrapper_shell=/bin/bash ;;
62530         *) lv_cv_wrapper_shell=/bin/sh ;;
62531       esac
62532     else
62533       for lv_cv_wrapper_shell in /bin/sh bash ksh zsh none; do
62534         test $lv_cv_wrapper_shell = none &&
62535           as_fn_error $? "could not find decent shell" "$LINENO" 5
62536         echo a > conftest.a
62537         ($lv_cv_wrapper_shell -c ': 1<>conftest.a') 2>/dev/null &&
62538         case `cat conftest.a`.$lv_cv_wrapper_shell in
62539           a./*) break;;           a.*)                            lv_cv_wrapper_shell=`$lv_cv_wrapper_shell -c \
62540               "command -v $lv_cv_wrapper_shell"`
62541             case $lv_cv_wrapper_shell in
62542               /*) break;;
62543             esac
62544             ;;
62545         esac
62546       done
62547       rm -f conftest.a
62548     fi
62549
62550 fi
62551 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lv_cv_wrapper_shell" >&5
62552 $as_echo "$lv_cv_wrapper_shell" >&6; }
62553   if test "x$lv_cv_wrapper_shell" != x/bin/sh; then
62554     lv_wrapper_shell=$lv_cv_wrapper_shell
62555   fi
62556   if test "x$lv_wrapper_shell" != x; then
62557
62558 cat >>confdefs.h <<_ACEOF
62559 #define VIR_WRAPPER_SHELL "$lv_wrapper_shell"
62560 _ACEOF
62561
62562   fi
62563 fi
62564
62565
62566 if test "$with_linux" = "yes"; then
62567     # Various kernel versions have headers that are not self-standing, but
62568     # yet are incompatible with the corresponding glibc headers.  In order
62569     # to guarantee compilation across a wide range of versions (from RHEL 5
62570     # to rawhide), we first have to probe whether glibc and kernel can be
62571     # used in tandem; and if not, provide workarounds that ensure that
62572     # ABI-compatible IPv6 types are present for use by the kernel headers.
62573     # These probes mirror the usage in virnetdevbridge.c
62574     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <linux/*.h> and <netinet/*.h> headers are compatible" >&5
62575 $as_echo_n "checking whether <linux/*.h> and <netinet/*.h> headers are compatible... " >&6; }
62576 if ${lv_cv_netinet_linux_compatible+:} false; then :
62577   $as_echo_n "(cached) " >&6
62578 else
62579   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
62580 /* end confdefs.h.  */
62581
62582         #include <netinet/in.h>
62583         #include <linux/in6.h>
62584
62585 int
62586 main ()
62587 {
62588
62589   ;
62590   return 0;
62591 }
62592 _ACEOF
62593 if ac_fn_c_try_compile "$LINENO"; then :
62594   lv_cv_netinet_linux_compatible=yes
62595 else
62596   lv_cv_netinet_linux_compatible=no
62597 fi
62598 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
62599 fi
62600 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lv_cv_netinet_linux_compatible" >&5
62601 $as_echo "$lv_cv_netinet_linux_compatible" >&6; }
62602     if test "x$lv_cv_netinet_linux_compatible" != xyes; then
62603
62604 $as_echo "#define NETINET_LINUX_WORKAROUND 1" >>confdefs.h
62605
62606     fi
62607     for ac_header in linux/param.h linux/sockios.h linux/if_bridge.h linux/if_tun.h
62608 do :
62609   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
62610 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "#include <netinet/in.h>
62611         #if NETINET_LINUX_WORKAROUND
62612         # define in6_addr in6_addr_
62613         # define sockaddr_in6 sockaddr_in6_
62614         # define ipv6_mreq ipv6_mreq_
62615         # define in6addr_any in6addr_any_
62616         # define in6addr_loopback in6addr_loopback_
62617         #endif
62618         #include <linux/in6.h>
62619
62620 "
62621 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
62622   cat >>confdefs.h <<_ACEOF
62623 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
62624 _ACEOF
62625
62626 else
62627   as_fn_error $? "You must install kernel-headers in order to compile libvirt with QEMU or LXC support" "$LINENO" 5
62628 fi
62629
62630 done
62631
62632 fi
62633
62634
62635
62636
62637
62638
62639
62640
62641
62642 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
62643         if test -n "$ac_tool_prefix"; then
62644   # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
62645 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
62646 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
62647 $as_echo_n "checking for $ac_word... " >&6; }
62648 if ${ac_cv_path_PKG_CONFIG+:} false; then :
62649   $as_echo_n "(cached) " >&6
62650 else
62651   case $PKG_CONFIG in
62652   [\\/]* | ?:[\\/]*)
62653   ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
62654   ;;
62655   *)
62656   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
62657 for as_dir in $PATH
62658 do
62659   IFS=$as_save_IFS
62660   test -z "$as_dir" && as_dir=.
62661     for ac_exec_ext in '' $ac_executable_extensions; do
62662   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
62663     ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
62664     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
62665     break 2
62666   fi
62667 done
62668   done
62669 IFS=$as_save_IFS
62670
62671   ;;
62672 esac
62673 fi
62674 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
62675 if test -n "$PKG_CONFIG"; then
62676   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
62677 $as_echo "$PKG_CONFIG" >&6; }
62678 else
62679   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
62680 $as_echo "no" >&6; }
62681 fi
62682
62683
62684 fi
62685 if test -z "$ac_cv_path_PKG_CONFIG"; then
62686   ac_pt_PKG_CONFIG=$PKG_CONFIG
62687   # Extract the first word of "pkg-config", so it can be a program name with args.
62688 set dummy pkg-config; ac_word=$2
62689 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
62690 $as_echo_n "checking for $ac_word... " >&6; }
62691 if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
62692   $as_echo_n "(cached) " >&6
62693 else
62694   case $ac_pt_PKG_CONFIG in
62695   [\\/]* | ?:[\\/]*)
62696   ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
62697   ;;
62698   *)
62699   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
62700 for as_dir in $PATH
62701 do
62702   IFS=$as_save_IFS
62703   test -z "$as_dir" && as_dir=.
62704     for ac_exec_ext in '' $ac_executable_extensions; do
62705   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
62706     ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
62707     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
62708     break 2
62709   fi
62710 done
62711   done
62712 IFS=$as_save_IFS
62713
62714   ;;
62715 esac
62716 fi
62717 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
62718 if test -n "$ac_pt_PKG_CONFIG"; then
62719   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
62720 $as_echo "$ac_pt_PKG_CONFIG" >&6; }
62721 else
62722   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
62723 $as_echo "no" >&6; }
62724 fi
62725
62726   if test "x$ac_pt_PKG_CONFIG" = x; then
62727     PKG_CONFIG=""
62728   else
62729     case $cross_compiling:$ac_tool_warned in
62730 yes:)
62731 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
62732 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
62733 ac_tool_warned=yes ;;
62734 esac
62735     PKG_CONFIG=$ac_pt_PKG_CONFIG
62736   fi
62737 else
62738   PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
62739 fi
62740
62741 fi
62742 if test -n "$PKG_CONFIG"; then
62743         _pkg_min_version=0.9.0
62744         { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
62745 $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
62746         if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
62747                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
62748 $as_echo "yes" >&6; }
62749         else
62750                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
62751 $as_echo "no" >&6; }
62752                 PKG_CONFIG=""
62753         fi
62754 fi
62755
62756
62757 LIBXML_CONFIG="xml2-config"
62758 LIBXML_CFLAGS=""
62759 LIBXML_LIBS=""
62760 LIBXML_FOUND="no"
62761
62762
62763 # Check whether --with-libxml was given.
62764 if test "${with_libxml+set}" = set; then :
62765   withval=$with_libxml;
62766 fi
62767
62768 if test "x$with_libxml" = "xno" ; then
62769     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libxml2 libraries >= $LIBXML_REQUIRED" >&5
62770 $as_echo_n "checking for libxml2 libraries >= $LIBXML_REQUIRED... " >&6; }
62771     as_fn_error $? "libxml2 >= $LIBXML_REQUIRED is required for libvirt" "$LINENO" 5
62772 elif test "x$with_libxml" = "x" && test "x$PKG_CONFIG" != "x" ; then
62773
62774 pkg_failed=no
62775 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIBXML" >&5
62776 $as_echo_n "checking for LIBXML... " >&6; }
62777
62778 if test -n "$LIBXML_CFLAGS"; then
62779     pkg_cv_LIBXML_CFLAGS="$LIBXML_CFLAGS"
62780  elif test -n "$PKG_CONFIG"; then
62781     if test -n "$PKG_CONFIG" && \
62782     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libxml-2.0 >= \$LIBXML_REQUIRED\""; } >&5
62783   ($PKG_CONFIG --exists --print-errors "libxml-2.0 >= $LIBXML_REQUIRED") 2>&5
62784   ac_status=$?
62785   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
62786   test $ac_status = 0; }; then
62787   pkg_cv_LIBXML_CFLAGS=`$PKG_CONFIG --cflags "libxml-2.0 >= $LIBXML_REQUIRED" 2>/dev/null`
62788                       test "x$?" != "x0" && pkg_failed=yes
62789 else
62790   pkg_failed=yes
62791 fi
62792  else
62793     pkg_failed=untried
62794 fi
62795 if test -n "$LIBXML_LIBS"; then
62796     pkg_cv_LIBXML_LIBS="$LIBXML_LIBS"
62797  elif test -n "$PKG_CONFIG"; then
62798     if test -n "$PKG_CONFIG" && \
62799     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libxml-2.0 >= \$LIBXML_REQUIRED\""; } >&5
62800   ($PKG_CONFIG --exists --print-errors "libxml-2.0 >= $LIBXML_REQUIRED") 2>&5
62801   ac_status=$?
62802   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
62803   test $ac_status = 0; }; then
62804   pkg_cv_LIBXML_LIBS=`$PKG_CONFIG --libs "libxml-2.0 >= $LIBXML_REQUIRED" 2>/dev/null`
62805                       test "x$?" != "x0" && pkg_failed=yes
62806 else
62807   pkg_failed=yes
62808 fi
62809  else
62810     pkg_failed=untried
62811 fi
62812
62813
62814
62815 if test $pkg_failed = yes; then
62816         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
62817 $as_echo "no" >&6; }
62818
62819 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
62820         _pkg_short_errors_supported=yes
62821 else
62822         _pkg_short_errors_supported=no
62823 fi
62824         if test $_pkg_short_errors_supported = yes; then
62825                 LIBXML_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libxml-2.0 >= $LIBXML_REQUIRED" 2>&1`
62826         else
62827                 LIBXML_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libxml-2.0 >= $LIBXML_REQUIRED" 2>&1`
62828         fi
62829         # Put the nasty error message in config.log where it belongs
62830         echo "$LIBXML_PKG_ERRORS" >&5
62831
62832         LIBXML_FOUND=no
62833 elif test $pkg_failed = untried; then
62834         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
62835 $as_echo "no" >&6; }
62836         LIBXML_FOUND=no
62837 else
62838         LIBXML_CFLAGS=$pkg_cv_LIBXML_CFLAGS
62839         LIBXML_LIBS=$pkg_cv_LIBXML_LIBS
62840         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
62841 $as_echo "yes" >&6; }
62842         LIBXML_FOUND=yes
62843 fi
62844 fi
62845 if test "$LIBXML_FOUND" = "no" ; then
62846     if test "x$with_libxml" != "x" ; then
62847         LIBXML_CONFIG=$with_libxml/bin/$LIBXML_CONFIG
62848     fi
62849     { $as_echo "$as_me:${as_lineno-$LINENO}: checking libxml2 $LIBXML_CONFIG >= $LIBXML_REQUIRED " >&5
62850 $as_echo_n "checking libxml2 $LIBXML_CONFIG >= $LIBXML_REQUIRED ... " >&6; }
62851     if ! $LIBXML_CONFIG --version > /dev/null 2>&1 ; then
62852         as_fn_error $? "Could not find libxml2 anywhere (see config.log for details)." "$LINENO" 5
62853     fi
62854     vers=`$LIBXML_CONFIG --version | awk -F. '{ printf "%d", ($1 * 1000 + $2) * 1000 + $3;}'`
62855     minvers=`echo $LIBXML_REQUIRED | awk -F. '{ printf "%d", ($1 * 1000 + $2) * 1000 + $3;}'`
62856     if test "$vers" -ge "$minvers" ; then
62857         LIBXML_LIBS="`$LIBXML_CONFIG --libs`"
62858         LIBXML_CFLAGS="`$LIBXML_CONFIG --cflags`"
62859         LIBXML_FOUND="yes"
62860         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
62861 $as_echo "yes" >&6; }
62862     else
62863         as_fn_error $? "You need at least libxml2 $LIBXML_REQUIRED for this version of libvirt" "$LINENO" 5
62864     fi
62865 fi
62866
62867
62868
62869
62870 old_cflags="$CFLAGS"
62871 old_libs="$LIBS"
62872 CFLAGS="$CFLAGS $LIBXML_CFLAGS"
62873 LIBS="$LIBS $LIBXML_LIBS"
62874 ac_fn_c_check_member "$LINENO" "struct _xmlURI" "query_raw" "ac_cv_member_struct__xmlURI_query_raw" "#include <libxml/uri.h>
62875 "
62876 if test "x$ac_cv_member_struct__xmlURI_query_raw" = xyes; then :
62877
62878 $as_echo "#define HAVE_XMLURI_QUERY_RAW /**/" >>confdefs.h
62879
62880 fi
62881
62882 CFLAGS="$old_cflags"
62883 LIBS="$old_libs"
62884
62885
62886 # Check whether --with-gnutls was given.
62887 if test "${with_gnutls+set}" = set; then :
62888   withval=$with_gnutls;
62889 else
62890   with_gnutls=check
62891 fi
62892
62893
62894
62895 if test "x$with_gnutls" != "xno"; then
62896   if test "x$with_gnutls" != "xyes" && test "x$with_gnutls" != "xcheck"; then
62897     GNUTLS_CFLAGS="-I$with_gnutls/include"
62898     GNUTLS_LIBS="-L$with_gnutls/lib"
62899   fi
62900   fail=0
62901   old_cflags="$CFLAGS"
62902   old_libs="$LIBS"
62903   CFLAGS="$CFLAGS $GNUTLS_CFLAGS"
62904   LIBS="$LIBS $GNUTLS_LIBS"
62905
62906   GNUTLS_FOUND=no
62907   GNUTLS_GCRYPT=unknown
62908   if test -x "$PKG_CONFIG" ; then
62909                     if $PKG_CONFIG --exists 'gnutls >= 3.0'; then
62910       GNUTLS_GCRYPT=no
62911     elif $PKG_CONFIG --exists 'gnutls >= 2.12'; then
62912       GNUTLS_GCRYPT=probe
62913     else
62914       GNUTLS_GCRYPT=yes
62915     fi
62916
62917 pkg_failed=no
62918 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNUTLS" >&5
62919 $as_echo_n "checking for GNUTLS... " >&6; }
62920
62921 if test -n "$GNUTLS_CFLAGS"; then
62922     pkg_cv_GNUTLS_CFLAGS="$GNUTLS_CFLAGS"
62923  elif test -n "$PKG_CONFIG"; then
62924     if test -n "$PKG_CONFIG" && \
62925     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gnutls >= \$GNUTLS_REQUIRED\""; } >&5
62926   ($PKG_CONFIG --exists --print-errors "gnutls >= $GNUTLS_REQUIRED") 2>&5
62927   ac_status=$?
62928   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
62929   test $ac_status = 0; }; then
62930   pkg_cv_GNUTLS_CFLAGS=`$PKG_CONFIG --cflags "gnutls >= $GNUTLS_REQUIRED" 2>/dev/null`
62931                       test "x$?" != "x0" && pkg_failed=yes
62932 else
62933   pkg_failed=yes
62934 fi
62935  else
62936     pkg_failed=untried
62937 fi
62938 if test -n "$GNUTLS_LIBS"; then
62939     pkg_cv_GNUTLS_LIBS="$GNUTLS_LIBS"
62940  elif test -n "$PKG_CONFIG"; then
62941     if test -n "$PKG_CONFIG" && \
62942     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gnutls >= \$GNUTLS_REQUIRED\""; } >&5
62943   ($PKG_CONFIG --exists --print-errors "gnutls >= $GNUTLS_REQUIRED") 2>&5
62944   ac_status=$?
62945   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
62946   test $ac_status = 0; }; then
62947   pkg_cv_GNUTLS_LIBS=`$PKG_CONFIG --libs "gnutls >= $GNUTLS_REQUIRED" 2>/dev/null`
62948                       test "x$?" != "x0" && pkg_failed=yes
62949 else
62950   pkg_failed=yes
62951 fi
62952  else
62953     pkg_failed=untried
62954 fi
62955
62956
62957
62958 if test $pkg_failed = yes; then
62959         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
62960 $as_echo "no" >&6; }
62961
62962 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
62963         _pkg_short_errors_supported=yes
62964 else
62965         _pkg_short_errors_supported=no
62966 fi
62967         if test $_pkg_short_errors_supported = yes; then
62968                 GNUTLS_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "gnutls >= $GNUTLS_REQUIRED" 2>&1`
62969         else
62970                 GNUTLS_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "gnutls >= $GNUTLS_REQUIRED" 2>&1`
62971         fi
62972         # Put the nasty error message in config.log where it belongs
62973         echo "$GNUTLS_PKG_ERRORS" >&5
62974
62975         GNUTLS_FOUND=no
62976 elif test $pkg_failed = untried; then
62977         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
62978 $as_echo "no" >&6; }
62979         GNUTLS_FOUND=no
62980 else
62981         GNUTLS_CFLAGS=$pkg_cv_GNUTLS_CFLAGS
62982         GNUTLS_LIBS=$pkg_cv_GNUTLS_LIBS
62983         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
62984 $as_echo "yes" >&6; }
62985         GNUTLS_FOUND=yes
62986 fi
62987   fi
62988   if test "$GNUTLS_FOUND" = "no"; then
62989         fail=0
62990     GNUTLS_GCRYPT=yes
62991     ac_fn_c_check_header_mongrel "$LINENO" "gnutls/gnutls.h" "ac_cv_header_gnutls_gnutls_h" "$ac_includes_default"
62992 if test "x$ac_cv_header_gnutls_gnutls_h" = xyes; then :
62993
62994 else
62995   fail=1
62996 fi
62997
62998
62999     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gnutls_handshake in -lgnutls" >&5
63000 $as_echo_n "checking for gnutls_handshake in -lgnutls... " >&6; }
63001 if ${ac_cv_lib_gnutls_gnutls_handshake+:} false; then :
63002   $as_echo_n "(cached) " >&6
63003 else
63004   ac_check_lib_save_LIBS=$LIBS
63005 LIBS="-lgnutls -lgcrypt $LIBS"
63006 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
63007 /* end confdefs.h.  */
63008
63009 /* Override any GCC internal prototype to avoid an error.
63010    Use char because int might match the return type of a GCC
63011    builtin and then its argument prototype would still apply.  */
63012 #ifdef __cplusplus
63013 extern "C"
63014 #endif
63015 char gnutls_handshake ();
63016 int
63017 main ()
63018 {
63019 return gnutls_handshake ();
63020   ;
63021   return 0;
63022 }
63023 _ACEOF
63024 if ac_fn_c_try_link "$LINENO"; then :
63025   ac_cv_lib_gnutls_gnutls_handshake=yes
63026 else
63027   ac_cv_lib_gnutls_gnutls_handshake=no
63028 fi
63029 rm -f core conftest.err conftest.$ac_objext \
63030     conftest$ac_exeext conftest.$ac_ext
63031 LIBS=$ac_check_lib_save_LIBS
63032 fi
63033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gnutls_gnutls_handshake" >&5
63034 $as_echo "$ac_cv_lib_gnutls_gnutls_handshake" >&6; }
63035 if test "x$ac_cv_lib_gnutls_gnutls_handshake" = xyes; then :
63036   cat >>confdefs.h <<_ACEOF
63037 #define HAVE_LIBGNUTLS 1
63038 _ACEOF
63039
63040   LIBS="-lgnutls $LIBS"
63041
63042 else
63043   fail=1
63044 fi
63045
63046
63047     test $fail = 0 && GNUTLS_FOUND=yes
63048
63049     GNUTLS_LIBS="$GNUTLS_LIBS -lgnutls"
63050   fi
63051   if test "$GNUTLS_FOUND" = "no"; then
63052     if test "$with_gnutls" = "check"; then
63053       with_gnutls=no
63054       GNUTLS_LIBS=
63055       GNUTLS_CFLAGS=
63056     else
63057       as_fn_error $? "You must install the GnuTLS library in order to compile and run libvirt" "$LINENO" 5
63058     fi
63059   else
63060         if test "$GNUTLS_GCRYPT" = probe; then
63061       case `$PKG_CONFIG --libs --static gnutls` in
63062         *gcrypt*) GNUTLS_GCRYPT=yes     ;;
63063         *nettle*) GNUTLS_GCRYPT=no      ;;
63064         *)        GNUTLS_GCRYPT=unknown ;;
63065       esac
63066     fi
63067     if test "$GNUTLS_GCRYPT" = yes || test "$GNUTLS_GCRYPT" = unknown; then
63068       GNUTLS_LIBS="$GNUTLS_LIBS -lgcrypt"
63069                   GNUTLS_CFLAGS="$GNUTLS_CFLAGS -DGCRYPT_NO_DEPRECATED"
63070
63071 cat >>confdefs.h <<_ACEOF
63072 #define WITH_GNUTLS_GCRYPT 1
63073 _ACEOF
63074
63075     fi
63076
63077         for ac_header in gnutls/crypto.h
63078 do :
63079   ac_fn_c_check_header_compile "$LINENO" "gnutls/crypto.h" "ac_cv_header_gnutls_crypto_h" "
63080       #include <gnutls/gnutls.h>
63081
63082 "
63083 if test "x$ac_cv_header_gnutls_crypto_h" = xyes; then :
63084   cat >>confdefs.h <<_ACEOF
63085 #define HAVE_GNUTLS_CRYPTO_H 1
63086 _ACEOF
63087
63088 fi
63089
63090 done
63091
63092
63093     with_gnutls=yes
63094   fi
63095
63096   LIBS="$old_libs"
63097   CFLAGS="$old_CFLAGS"
63098 fi
63099
63100 if test "x$with_gnutls" = "xyes" ; then
63101
63102 cat >>confdefs.h <<_ACEOF
63103 #define WITH_GNUTLS 1
63104 _ACEOF
63105
63106 fi
63107  if test "x$with_gnutls" = "xyes"; then
63108   WITH_GNUTLS_TRUE=
63109   WITH_GNUTLS_FALSE='#'
63110 else
63111   WITH_GNUTLS_TRUE='#'
63112   WITH_GNUTLS_FALSE=
63113 fi
63114
63115
63116
63117
63118
63119 POLKIT_CFLAGS=
63120 POLKIT_LIBS=
63121 PKCHECK_PATH=
63122
63123 # Check whether --with-polkit was given.
63124 if test "${with_polkit+set}" = set; then :
63125   withval=$with_polkit;
63126 else
63127   with_polkit=check
63128 fi
63129
63130
63131 with_polkit0=no
63132 with_polkit1=no
63133 if test "x$with_polkit" = "xyes" || test "x$with_polkit" = "xcheck"; then
63134     # Extract the first word of "pkcheck", so it can be a program name with args.
63135 set dummy pkcheck; ac_word=$2
63136 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
63137 $as_echo_n "checking for $ac_word... " >&6; }
63138 if ${ac_cv_path_PKCHECK_PATH+:} false; then :
63139   $as_echo_n "(cached) " >&6
63140 else
63141   case $PKCHECK_PATH in
63142   [\\/]* | ?:[\\/]*)
63143   ac_cv_path_PKCHECK_PATH="$PKCHECK_PATH" # Let the user override the test with a path.
63144   ;;
63145   *)
63146   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
63147 as_dummy="/usr/sbin:$PATH"
63148 for as_dir in $as_dummy
63149 do
63150   IFS=$as_save_IFS
63151   test -z "$as_dir" && as_dir=.
63152     for ac_exec_ext in '' $ac_executable_extensions; do
63153   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
63154     ac_cv_path_PKCHECK_PATH="$as_dir/$ac_word$ac_exec_ext"
63155     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
63156     break 2
63157   fi
63158 done
63159   done
63160 IFS=$as_save_IFS
63161
63162   ;;
63163 esac
63164 fi
63165 PKCHECK_PATH=$ac_cv_path_PKCHECK_PATH
63166 if test -n "$PKCHECK_PATH"; then
63167   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKCHECK_PATH" >&5
63168 $as_echo "$PKCHECK_PATH" >&6; }
63169 else
63170   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
63171 $as_echo "no" >&6; }
63172 fi
63173
63174
63175   if test "x$PKCHECK_PATH" != "x" ; then
63176
63177 cat >>confdefs.h <<_ACEOF
63178 #define PKCHECK_PATH "$PKCHECK_PATH"
63179 _ACEOF
63180
63181     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pkcheck supports uid value" >&5
63182 $as_echo_n "checking whether pkcheck supports uid value... " >&6; }
63183     pkcheck_supports_uid=`$PKG_CONFIG --variable pkcheck_supports_uid polkit-gobject-1`
63184     if test "x$pkcheck_supports_uid" = "xtrue"; then
63185       { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
63186 $as_echo "yes" >&6; }
63187
63188 cat >>confdefs.h <<_ACEOF
63189 #define PKCHECK_SUPPORTS_UID 1
63190 _ACEOF
63191
63192     else
63193       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
63194 $as_echo "no" >&6; }
63195     fi
63196
63197 cat >>confdefs.h <<_ACEOF
63198 #define WITH_POLKIT 1
63199 _ACEOF
63200
63201
63202 cat >>confdefs.h <<_ACEOF
63203 #define WITH_POLKIT1 1
63204 _ACEOF
63205
63206     with_polkit="yes"
63207     with_polkit1="yes"
63208   else
63209
63210 pkg_failed=no
63211 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for POLKIT" >&5
63212 $as_echo_n "checking for POLKIT... " >&6; }
63213
63214 if test -n "$POLKIT_CFLAGS"; then
63215     pkg_cv_POLKIT_CFLAGS="$POLKIT_CFLAGS"
63216  elif test -n "$PKG_CONFIG"; then
63217     if test -n "$PKG_CONFIG" && \
63218     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"polkit-dbus >= \$POLKIT_REQUIRED\""; } >&5
63219   ($PKG_CONFIG --exists --print-errors "polkit-dbus >= $POLKIT_REQUIRED") 2>&5
63220   ac_status=$?
63221   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
63222   test $ac_status = 0; }; then
63223   pkg_cv_POLKIT_CFLAGS=`$PKG_CONFIG --cflags "polkit-dbus >= $POLKIT_REQUIRED" 2>/dev/null`
63224                       test "x$?" != "x0" && pkg_failed=yes
63225 else
63226   pkg_failed=yes
63227 fi
63228  else
63229     pkg_failed=untried
63230 fi
63231 if test -n "$POLKIT_LIBS"; then
63232     pkg_cv_POLKIT_LIBS="$POLKIT_LIBS"
63233  elif test -n "$PKG_CONFIG"; then
63234     if test -n "$PKG_CONFIG" && \
63235     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"polkit-dbus >= \$POLKIT_REQUIRED\""; } >&5
63236   ($PKG_CONFIG --exists --print-errors "polkit-dbus >= $POLKIT_REQUIRED") 2>&5
63237   ac_status=$?
63238   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
63239   test $ac_status = 0; }; then
63240   pkg_cv_POLKIT_LIBS=`$PKG_CONFIG --libs "polkit-dbus >= $POLKIT_REQUIRED" 2>/dev/null`
63241                       test "x$?" != "x0" && pkg_failed=yes
63242 else
63243   pkg_failed=yes
63244 fi
63245  else
63246     pkg_failed=untried
63247 fi
63248
63249
63250
63251 if test $pkg_failed = yes; then
63252         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
63253 $as_echo "no" >&6; }
63254
63255 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
63256         _pkg_short_errors_supported=yes
63257 else
63258         _pkg_short_errors_supported=no
63259 fi
63260         if test $_pkg_short_errors_supported = yes; then
63261                 POLKIT_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "polkit-dbus >= $POLKIT_REQUIRED" 2>&1`
63262         else
63263                 POLKIT_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "polkit-dbus >= $POLKIT_REQUIRED" 2>&1`
63264         fi
63265         # Put the nasty error message in config.log where it belongs
63266         echo "$POLKIT_PKG_ERRORS" >&5
63267
63268
63269       if test "x$with_polkit" = "xcheck" ; then
63270          with_polkit=no
63271       else
63272          as_fn_error $? "You must install PolicyKit >= $POLKIT_REQUIRED to compile libvirt" "$LINENO" 5
63273       fi
63274
63275 elif test $pkg_failed = untried; then
63276         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
63277 $as_echo "no" >&6; }
63278
63279       if test "x$with_polkit" = "xcheck" ; then
63280          with_polkit=no
63281       else
63282          as_fn_error $? "You must install PolicyKit >= $POLKIT_REQUIRED to compile libvirt" "$LINENO" 5
63283       fi
63284
63285 else
63286         POLKIT_CFLAGS=$pkg_cv_POLKIT_CFLAGS
63287         POLKIT_LIBS=$pkg_cv_POLKIT_LIBS
63288         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
63289 $as_echo "yes" >&6; }
63290         with_polkit=yes
63291 fi
63292     if test "x$with_polkit" = "xyes" ; then
63293
63294 cat >>confdefs.h <<_ACEOF
63295 #define WITH_POLKIT 1
63296 _ACEOF
63297
63298
63299 cat >>confdefs.h <<_ACEOF
63300 #define WITH_POLKIT0 1
63301 _ACEOF
63302
63303
63304       old_CFLAGS=$CFLAGS
63305       old_LIBS=$LIBS
63306       CFLAGS="$CFLAGS $POLKIT_CFLAGS"
63307       LIBS="$LIBS $POLKIT_LIBS"
63308       for ac_func in polkit_context_is_caller_authorized
63309 do :
63310   ac_fn_c_check_func "$LINENO" "polkit_context_is_caller_authorized" "ac_cv_func_polkit_context_is_caller_authorized"
63311 if test "x$ac_cv_func_polkit_context_is_caller_authorized" = xyes; then :
63312   cat >>confdefs.h <<_ACEOF
63313 #define HAVE_POLKIT_CONTEXT_IS_CALLER_AUTHORIZED 1
63314 _ACEOF
63315
63316 fi
63317 done
63318
63319       CFLAGS="$old_CFLAGS"
63320       LIBS="$old_LIBS"
63321
63322       # Extract the first word of "polkit-auth", so it can be a program name with args.
63323 set dummy polkit-auth; ac_word=$2
63324 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
63325 $as_echo_n "checking for $ac_word... " >&6; }
63326 if ${ac_cv_path_POLKIT_AUTH+:} false; then :
63327   $as_echo_n "(cached) " >&6
63328 else
63329   case $POLKIT_AUTH in
63330   [\\/]* | ?:[\\/]*)
63331   ac_cv_path_POLKIT_AUTH="$POLKIT_AUTH" # Let the user override the test with a path.
63332   ;;
63333   *)
63334   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
63335 for as_dir in $PATH
63336 do
63337   IFS=$as_save_IFS
63338   test -z "$as_dir" && as_dir=.
63339     for ac_exec_ext in '' $ac_executable_extensions; do
63340   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
63341     ac_cv_path_POLKIT_AUTH="$as_dir/$ac_word$ac_exec_ext"
63342     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
63343     break 2
63344   fi
63345 done
63346   done
63347 IFS=$as_save_IFS
63348
63349   ;;
63350 esac
63351 fi
63352 POLKIT_AUTH=$ac_cv_path_POLKIT_AUTH
63353 if test -n "$POLKIT_AUTH"; then
63354   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POLKIT_AUTH" >&5
63355 $as_echo "$POLKIT_AUTH" >&6; }
63356 else
63357   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
63358 $as_echo "no" >&6; }
63359 fi
63360
63361
63362       if test "x$POLKIT_AUTH" != "x"; then
63363
63364 cat >>confdefs.h <<_ACEOF
63365 #define POLKIT_AUTH "$POLKIT_AUTH"
63366 _ACEOF
63367
63368       fi
63369       with_polkit0="yes"
63370     fi
63371   fi
63372 fi
63373  if test "x$with_polkit" = "xyes"; then
63374   WITH_POLKIT_TRUE=
63375   WITH_POLKIT_FALSE='#'
63376 else
63377   WITH_POLKIT_TRUE='#'
63378   WITH_POLKIT_FALSE=
63379 fi
63380
63381  if test "x$with_polkit0" = "xyes"; then
63382   WITH_POLKIT0_TRUE=
63383   WITH_POLKIT0_FALSE='#'
63384 else
63385   WITH_POLKIT0_TRUE='#'
63386   WITH_POLKIT0_FALSE=
63387 fi
63388
63389  if test "x$with_polkit1" = "xyes"; then
63390   WITH_POLKIT1_TRUE=
63391   WITH_POLKIT1_FALSE='#'
63392 else
63393   WITH_POLKIT1_TRUE='#'
63394   WITH_POLKIT1_FALSE=
63395 fi
63396
63397
63398
63399
63400
63401 # Check whether --with-firewalld was given.
63402 if test "${with_firewalld+set}" = set; then :
63403   withval=$with_firewalld;
63404 else
63405   with_firewalld=check
63406 fi
63407
63408 if test "x$with_firewalld" = "xcheck" ; then
63409    with_firewalld=$with_dbus
63410 fi
63411 if test "x$with_firewalld" == "xyes" ; then
63412   if test "x$with_dbus" != "xyes" ; then
63413      as_fn_error $? "You must have dbus enabled for firewalld support" "$LINENO" 5
63414   fi
63415
63416 cat >>confdefs.h <<_ACEOF
63417 #define HAVE_FIREWALLD 1
63418 _ACEOF
63419
63420 fi
63421  if test "x$with_firewalld" != "xno"; then
63422   HAVE_FIREWALLD_TRUE=
63423   HAVE_FIREWALLD_FALSE='#'
63424 else
63425   HAVE_FIREWALLD_TRUE='#'
63426   HAVE_FIREWALLD_FALSE=
63427 fi
63428
63429
63430
63431 if test "$with_chrdev_lock_files" != "no"; then
63432   case $with_chrdev_lock_files in
63433   yes | auto)
63434         if test "$with_linux" = "yes"; then
63435       with_chrdev_lock_files=/var/lock
63436     elif test "$with_chrdev_lock_files" = "auto"; then
63437       with_chrdev_lock_files=no
63438     fi ;;
63439   esac
63440   if test "$with_chrdev_lock_files" = "yes"; then
63441     as_fn_error $? "You must specify path for the lock files on this
63442 platform" "$LINENO" 5
63443   fi
63444   if test "$with_chrdev_lock_files" != "no"; then
63445
63446 cat >>confdefs.h <<_ACEOF
63447 #define VIR_CHRDEV_LOCK_FILE_PATH "$with_chrdev_lock_files"
63448 _ACEOF
63449
63450   fi
63451 fi
63452  if test "$with_chrdev_lock_files" != "no"; then
63453   VIR_CHRDEV_LOCK_FILE_PATH_TRUE=
63454   VIR_CHRDEV_LOCK_FILE_PATH_FALSE='#'
63455 else
63456   VIR_CHRDEV_LOCK_FILE_PATH_TRUE='#'
63457   VIR_CHRDEV_LOCK_FILE_PATH_FALSE=
63458 fi
63459
63460
63461
63462
63463 # Check whether --with-secdriver-selinux was given.
63464 if test "${with_secdriver_selinux+set}" = set; then :
63465   withval=$with_secdriver_selinux;
63466 else
63467   with_secdriver_selinux=check
63468 fi
63469
63470
63471 if test "$with_selinux" != "yes" ; then
63472   if test "$with_secdriver_selinux" = "check" ; then
63473     with_secdriver_selinux=no
63474   fi
63475   if test "$with_secdriver_selinux" != "no"; then
63476         as_fn_error $? "You must install the libselinux development package and enable SELinux with the --with-selinux=yes in order to compile libvirt --with-secdriver-selinux=yes" "$LINENO" 5
63477   fi
63478 elif test "$with_secdriver_selinux" != "no"; then
63479   old_cflags="$CFLAGS"
63480   old_libs="$LIBS"
63481   CFLAGS="$CFLAGS $SELINUX_CFLAGS"
63482   LIBS="$CFLAGS $SELINUX_LIBS"
63483
63484   fail=0
63485   ac_fn_c_check_func "$LINENO" "selinux_virtual_domain_context_path" "ac_cv_func_selinux_virtual_domain_context_path"
63486 if test "x$ac_cv_func_selinux_virtual_domain_context_path" = xyes; then :
63487
63488 else
63489   fail=1
63490 fi
63491
63492   ac_fn_c_check_func "$LINENO" "selinux_virtual_image_context_path" "ac_cv_func_selinux_virtual_image_context_path"
63493 if test "x$ac_cv_func_selinux_virtual_image_context_path" = xyes; then :
63494
63495 else
63496   fail=1
63497 fi
63498
63499   for ac_func in selinux_lxc_contexts_path
63500 do :
63501   ac_fn_c_check_func "$LINENO" "selinux_lxc_contexts_path" "ac_cv_func_selinux_lxc_contexts_path"
63502 if test "x$ac_cv_func_selinux_lxc_contexts_path" = xyes; then :
63503   cat >>confdefs.h <<_ACEOF
63504 #define HAVE_SELINUX_LXC_CONTEXTS_PATH 1
63505 _ACEOF
63506
63507 fi
63508 done
63509
63510   CFLAGS="$old_cflags"
63511   LIBS="$old_libs"
63512
63513   if test "$fail" = "1" ; then
63514     if test "$with_secdriver_selinux" = "check" ; then
63515       with_secdriver_selinux=no
63516     else
63517       as_fn_error $? "You must install libselinux development package >= 2.0.82 in order to compile libvirt --with-secdriver-selinux=yes" "$LINENO" 5
63518     fi
63519   else
63520     with_secdriver_selinux=yes
63521
63522 cat >>confdefs.h <<_ACEOF
63523 #define WITH_SECDRIVER_SELINUX 1
63524 _ACEOF
63525
63526   fi
63527 fi
63528  if test "$with_secdriver_selinux" != "no"; then
63529   WITH_SECDRIVER_SELINUX_TRUE=
63530   WITH_SECDRIVER_SELINUX_FALSE='#'
63531 else
63532   WITH_SECDRIVER_SELINUX_TRUE='#'
63533   WITH_SECDRIVER_SELINUX_FALSE=
63534 fi
63535
63536
63537
63538
63539 # Check whether --with-secdriver-apparmor was given.
63540 if test "${with_secdriver_apparmor+set}" = set; then :
63541   withval=$with_secdriver_apparmor;
63542 else
63543   with_secdriver_apparmor=check
63544 fi
63545
63546
63547 if test "$with_apparmor" != "yes" ; then
63548   if test "$with_secdriver_apparmor" = "check" ; then
63549     with_secdriver_apparmor=no
63550   fi
63551   if test "$with_secdriver_apparmor" != "no" ; then
63552     as_fn_error $? "You must install the AppArmor development package in order to compile libvirt" "$LINENO" 5
63553   fi
63554 elif test "with_secdriver_apparmor" != "no" ; then
63555   with_secdriver_apparmor=yes
63556
63557 cat >>confdefs.h <<_ACEOF
63558 #define WITH_SECDRIVER_APPARMOR 1
63559 _ACEOF
63560
63561 fi
63562  if test "$with_secdriver_apparmor" != "no"; then
63563   WITH_SECDRIVER_APPARMOR_TRUE=
63564   WITH_SECDRIVER_APPARMOR_FALSE='#'
63565 else
63566   WITH_SECDRIVER_APPARMOR_TRUE='#'
63567   WITH_SECDRIVER_APPARMOR_FALSE=
63568 fi
63569
63570
63571
63572 # Check whether --with-apparmor-profiles was given.
63573 if test "${with_apparmor_profiles+set}" = set; then :
63574   withval=$with_apparmor_profiles; with_apparmor_profiles=yes
63575 else
63576   with_apparmor_profiles=no
63577 fi
63578
63579 if test "$with_apparmor" = "no"; then
63580   with_apparmor_profiles="no"
63581 fi
63582  if test "$with_apparmor_profiles" != "no"; then
63583   WITH_APPARMOR_PROFILES_TRUE=
63584   WITH_APPARMOR_PROFILES_FALSE='#'
63585 else
63586   WITH_APPARMOR_PROFILES_TRUE='#'
63587   WITH_APPARMOR_PROFILES_FALSE=
63588 fi
63589
63590
63591
63592 # Check whether --with-dtrace was given.
63593 if test "${with_dtrace+set}" = set; then :
63594   withval=$with_dtrace;
63595 else
63596   with_dtrace=check
63597 fi
63598
63599
63600 if test "$with_dtrace" != "no" ; then
63601   # Extract the first word of "dtrace", so it can be a program name with args.
63602 set dummy dtrace; ac_word=$2
63603 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
63604 $as_echo_n "checking for $ac_word... " >&6; }
63605 if ${ac_cv_path_DTRACE+:} false; then :
63606   $as_echo_n "(cached) " >&6
63607 else
63608   case $DTRACE in
63609   [\\/]* | ?:[\\/]*)
63610   ac_cv_path_DTRACE="$DTRACE" # Let the user override the test with a path.
63611   ;;
63612   *)
63613   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
63614 as_dummy="/bin:/usr/bin"
63615 for as_dir in $as_dummy
63616 do
63617   IFS=$as_save_IFS
63618   test -z "$as_dir" && as_dir=.
63619     for ac_exec_ext in '' $ac_executable_extensions; do
63620   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
63621     ac_cv_path_DTRACE="$as_dir/$ac_word$ac_exec_ext"
63622     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
63623     break 2
63624   fi
63625 done
63626   done
63627 IFS=$as_save_IFS
63628
63629   ;;
63630 esac
63631 fi
63632 DTRACE=$ac_cv_path_DTRACE
63633 if test -n "$DTRACE"; then
63634   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5
63635 $as_echo "$DTRACE" >&6; }
63636 else
63637   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
63638 $as_echo "no" >&6; }
63639 fi
63640
63641
63642   if test -z "$DTRACE" ; then
63643     if test "$with_dtrace" = "check"; then
63644       with_dtrace=no
63645     else
63646       as_fn_error $? "You must install the 'dtrace' binary to enable libvirt static probes" "$LINENO" 5
63647     fi
63648   else
63649     with_dtrace=yes
63650   fi
63651   if test "$with_dtrace" = "yes"; then
63652
63653 cat >>confdefs.h <<_ACEOF
63654 #define WITH_DTRACE_PROBES 1
63655 _ACEOF
63656
63657   fi
63658 fi
63659  if test "$with_dtrace" != "no"; then
63660   WITH_DTRACE_PROBES_TRUE=
63661   WITH_DTRACE_PROBES_FALSE='#'
63662 else
63663   WITH_DTRACE_PROBES_TRUE='#'
63664   WITH_DTRACE_PROBES_FALSE=
63665 fi
63666
63667
63668
63669
63670 # Check whether --with-numad was given.
63671 if test "${with_numad+set}" = set; then :
63672   withval=$with_numad;
63673 else
63674   with_numad=check
63675 fi
63676
63677
63678 if test "$with_numad" != "no" ; then
63679   fail=0
63680
63681   # Extract the first word of "numad", so it can be a program name with args.
63682 set dummy numad; ac_word=$2
63683 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
63684 $as_echo_n "checking for $ac_word... " >&6; }
63685 if ${ac_cv_path_NUMAD+:} false; then :
63686   $as_echo_n "(cached) " >&6
63687 else
63688   case $NUMAD in
63689   [\\/]* | ?:[\\/]*)
63690   ac_cv_path_NUMAD="$NUMAD" # Let the user override the test with a path.
63691   ;;
63692   *)
63693   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
63694 as_dummy="/bin:/usr/bin:/usr/sbin"
63695 for as_dir in $as_dummy
63696 do
63697   IFS=$as_save_IFS
63698   test -z "$as_dir" && as_dir=.
63699     for ac_exec_ext in '' $ac_executable_extensions; do
63700   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
63701     ac_cv_path_NUMAD="$as_dir/$ac_word$ac_exec_ext"
63702     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
63703     break 2
63704   fi
63705 done
63706   done
63707 IFS=$as_save_IFS
63708
63709   ;;
63710 esac
63711 fi
63712 NUMAD=$ac_cv_path_NUMAD
63713 if test -n "$NUMAD"; then
63714   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NUMAD" >&5
63715 $as_echo "$NUMAD" >&6; }
63716 else
63717   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
63718 $as_echo "no" >&6; }
63719 fi
63720
63721
63722
63723   if test "$with_numad" = "check"; then
63724     test "$with_numactl" = "yes" || fail=1
63725     if test -z "$NUMAD" || test $fail = 1; then
63726       with_numad="no"
63727     else
63728       with_numad="yes"
63729     fi
63730   else
63731     test -z  "$NUMAD" &&
63732       as_fn_error $? "You must install numad package to manage CPU and memory placement dynamically" "$LINENO" 5
63733
63734     test "$with_numactl" = "yes" || fail=1
63735     test $fail = 1 &&
63736       as_fn_error $? "You must install the numactl development package in order to compile and run libvirt" "$LINENO" 5
63737   fi
63738 fi
63739 if test "$with_numad" = "yes"; then
63740
63741 cat >>confdefs.h <<_ACEOF
63742 #define HAVE_NUMAD 1
63743 _ACEOF
63744
63745
63746 cat >>confdefs.h <<_ACEOF
63747 #define NUMAD "$NUMAD"
63748 _ACEOF
63749
63750 fi
63751  if test "$with_numad" != "no"; then
63752   HAVE_NUMAD_TRUE=
63753   HAVE_NUMAD_FALSE='#'
63754 else
63755   HAVE_NUMAD_TRUE='#'
63756   HAVE_NUMAD_FALSE=
63757 fi
63758
63759
63760 LIBPCAP_CONFIG="pcap-config"
63761 LIBPCAP_CFLAGS=""
63762 LIBPCAP_LIBS=""
63763 LIBPCAP_FOUND="no"
63764
63765
63766 # Check whether --with-libpcap was given.
63767 if test "${with_libpcap+set}" = set; then :
63768   withval=$with_libpcap;
63769 fi
63770
63771 if test "$with_qemu" = "yes"; then
63772   case $with_libpcap in
63773     no)     LIBPCAP_CONFIG= ;;
63774     ''|yes) LIBPCAP_CONFIG="pcap-config" ;;
63775     *)      LIBPCAP_CONFIG="$with_libpcap/bin/pcap-config" ;;
63776   esac
63777   if test "x$LIBPCAP_CONFIG" != "x"; then :
63778
63779     { $as_echo "$as_me:${as_lineno-$LINENO}: checking libpcap $LIBPCAP_CONFIG >= $LIBPCAP_REQUIRED " >&5
63780 $as_echo_n "checking libpcap $LIBPCAP_CONFIG >= $LIBPCAP_REQUIRED ... " >&6; }
63781     if ! $LIBPCAP_CONFIG --libs > /dev/null 2>&1 ; then
63782       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
63783 $as_echo "no" >&6; }
63784     else
63785       LIBPCAP_LIBS="`$LIBPCAP_CONFIG --libs`"
63786       LIBPCAP_CFLAGS="`$LIBPCAP_CONFIG --cflags`"
63787       LIBPCAP_FOUND="yes"
63788       { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
63789 $as_echo "yes" >&6; }
63790     fi
63791
63792 fi
63793 fi
63794
63795 if test "x$LIBPCAP_FOUND" = "xyes"; then
63796
63797 cat >>confdefs.h <<_ACEOF
63798 #define HAVE_LIBPCAP 1
63799 _ACEOF
63800
63801 fi
63802
63803
63804
63805
63806
63807
63808
63809 if test "$with_libvirtd" = "no" ; then
63810   with_uml=no
63811 fi
63812 if test "$with_uml" = "yes" || test "$with_uml" = "check"; then
63813     ac_fn_c_check_header_mongrel "$LINENO" "sys/inotify.h" "ac_cv_header_sys_inotify_h" "$ac_includes_default"
63814 if test "x$ac_cv_header_sys_inotify_h" = xyes; then :
63815
63816         with_uml=yes
63817
63818 else
63819
63820         if test "$with_uml" = "check"; then
63821             with_uml=no
63822             { $as_echo "$as_me:${as_lineno-$LINENO}: <sys/inotify.h> is required for the UML driver, disabling it" >&5
63823 $as_echo "$as_me: <sys/inotify.h> is required for the UML driver, disabling it" >&6;}
63824         else
63825             as_fn_error $? "The <sys/inotify.h> is required for the UML driver. Upgrade your libc6." "$LINENO" 5
63826         fi
63827
63828 fi
63829
63830
63831 fi
63832 if test "$with_uml" = "yes" ; then
63833
63834 cat >>confdefs.h <<_ACEOF
63835 #define WITH_UML 1
63836 _ACEOF
63837
63838 fi
63839  if test "$with_uml" = "yes"; then
63840   WITH_UML_TRUE=
63841   WITH_UML_FALSE='#'
63842 else
63843   WITH_UML_TRUE='#'
63844   WITH_UML_FALSE=
63845 fi
63846
63847
63848
63849
63850
63851 if test "$with_phyp" != "no"; then
63852   if test "$with_ssh2" = "no" ; then
63853     if test "$with_phyp" = "check"; then
63854       with_phyp=no
63855     else
63856       as_fn_error $? "libssh2 is required for Phyp driver" "$LINENO" 5
63857     fi
63858   else
63859     with_phyp=yes
63860   fi
63861 fi
63862
63863 if test "$with_phyp" = "yes"; then
63864
63865 cat >>confdefs.h <<_ACEOF
63866 #define WITH_PHYP 1
63867 _ACEOF
63868
63869 fi
63870
63871  if test "$with_phyp" = "yes"; then
63872   WITH_PHYP_TRUE=
63873   WITH_PHYP_FALSE='#'
63874 else
63875   WITH_PHYP_TRUE='#'
63876   WITH_PHYP_FALSE=
63877 fi
63878
63879
63880 if test "$with_pm_utils" = "check"; then
63881     with_pm_utils=yes
63882     if test "$with_dbus" = "yes"; then
63883         if test "$init_systemd" = "yes"; then
63884             with_pm_utils=no
63885         fi
63886     fi
63887 fi
63888
63889 if test "$with_pm_utils" = "yes"; then
63890
63891 cat >>confdefs.h <<_ACEOF
63892 #define WITH_PM_UTILS 1
63893 _ACEOF
63894
63895 fi
63896  if test "$with_pm_utils" = "yes"; then
63897   WITH_PM_UTILS_TRUE=
63898   WITH_PM_UTILS_FALSE='#'
63899 else
63900   WITH_PM_UTILS_TRUE='#'
63901   WITH_PM_UTILS_FALSE=
63902 fi
63903
63904
63905 VIRSH_LIBS="$VIRSH_LIBS $READLINE_LIBS"
63906
63907
63908
63909
63910 # Check whether --with-network was given.
63911 if test "${with_network+set}" = set; then :
63912   withval=$with_network;
63913 else
63914   with_network=yes
63915 fi
63916
63917
63918
63919 if test "$with_libvirtd" = "no" || test "$with_osx" = "yes"; then
63920   with_network=no
63921 fi
63922
63923 if test "$with_network" = "yes" ; then
63924
63925 cat >>confdefs.h <<_ACEOF
63926 #define WITH_NETWORK 1
63927 _ACEOF
63928
63929 fi
63930  if test "$with_network" = "yes"; then
63931   WITH_NETWORK_TRUE=
63932   WITH_NETWORK_FALSE='#'
63933 else
63934   WITH_NETWORK_TRUE='#'
63935   WITH_NETWORK_FALSE=
63936 fi
63937
63938
63939 with_bridge=no
63940 if test "$with_qemu:$with_lxc:$with_network" != "no:no:no"; then
63941     with_bridge=yes
63942
63943 cat >>confdefs.h <<_ACEOF
63944 #define WITH_BRIDGE 1
63945 _ACEOF
63946
63947 fi
63948  if test "$with_bridge" = "yes"; then
63949   WITH_BRIDGE_TRUE=
63950   WITH_BRIDGE_FALSE='#'
63951 else
63952   WITH_BRIDGE_TRUE='#'
63953   WITH_BRIDGE_FALSE=
63954 fi
63955
63956
63957
63958
63959 # Check whether --with-secrets was given.
63960 if test "${with_secrets+set}" = set; then :
63961   withval=$with_secrets;
63962 else
63963   with_secrets=yes
63964 fi
63965
63966
63967 if test "$with_libvirtd" = "no"; then
63968   with_secrets=no
63969 fi
63970 if test "$with_secrets" = "yes" ; then
63971
63972 cat >>confdefs.h <<_ACEOF
63973 #define WITH_SECRETS 1
63974 _ACEOF
63975
63976 fi
63977  if test "$with_secrets" = "yes"; then
63978   WITH_SECRETS_TRUE=
63979   WITH_SECRETS_FALSE='#'
63980 else
63981   WITH_SECRETS_TRUE='#'
63982   WITH_SECRETS_FALSE=
63983 fi
63984
63985
63986
63987
63988 # Check whether --with-storage-dir was given.
63989 if test "${with_storage_dir+set}" = set; then :
63990   withval=$with_storage_dir;
63991 else
63992   with_storage_dir=yes
63993 fi
63994
63995
63996 # Check whether --with-storage-fs was given.
63997 if test "${with_storage_fs+set}" = set; then :
63998   withval=$with_storage_fs;
63999 else
64000   with_storage_fs=check
64001 fi
64002
64003
64004 # Check whether --with-storage-lvm was given.
64005 if test "${with_storage_lvm+set}" = set; then :
64006   withval=$with_storage_lvm;
64007 else
64008   with_storage_lvm=check
64009 fi
64010
64011
64012 # Check whether --with-storage-iscsi was given.
64013 if test "${with_storage_iscsi+set}" = set; then :
64014   withval=$with_storage_iscsi;
64015 else
64016   with_storage_iscsi=check
64017 fi
64018
64019
64020 # Check whether --with-storage-scsi was given.
64021 if test "${with_storage_scsi+set}" = set; then :
64022   withval=$with_storage_scsi;
64023 else
64024   with_storage_scsi=check
64025 fi
64026
64027
64028 # Check whether --with-storage-mpath was given.
64029 if test "${with_storage_mpath+set}" = set; then :
64030   withval=$with_storage_mpath;
64031 else
64032   with_storage_mpath=check
64033 fi
64034
64035
64036 # Check whether --with-storage-disk was given.
64037 if test "${with_storage_disk+set}" = set; then :
64038   withval=$with_storage_disk;
64039 else
64040   with_storage_disk=check
64041 fi
64042
64043
64044 # Check whether --with-storage-rbd was given.
64045 if test "${with_storage_rbd+set}" = set; then :
64046   withval=$with_storage_rbd;
64047 else
64048   with_storage_rbd=check
64049 fi
64050
64051
64052 # Check whether --with-storage-sheepdog was given.
64053 if test "${with_storage_sheepdog+set}" = set; then :
64054   withval=$with_storage_sheepdog;
64055 else
64056   with_storage_sheepdog=check
64057 fi
64058
64059
64060 # Check whether --with-storage-gluster was given.
64061 if test "${with_storage_gluster+set}" = set; then :
64062   withval=$with_storage_gluster;
64063 else
64064   with_storage_gluster=check
64065 fi
64066
64067
64068 if test "$with_libvirtd" = "no"; then
64069   with_storage_dir=no
64070   with_storage_fs=no
64071   with_storage_lvm=no
64072   with_storage_iscsi=no
64073   with_storage_scsi=no
64074   with_storage_mpath=no
64075   with_storage_disk=no
64076   with_storage_rbd=no
64077   with_storage_sheepdog=no
64078   with_storage_gluster=no
64079 fi
64080 if test "$with_storage_dir" = "yes" ; then
64081
64082 cat >>confdefs.h <<_ACEOF
64083 #define WITH_STORAGE_DIR 1
64084 _ACEOF
64085
64086 fi
64087  if test "$with_storage_dir" = "yes"; then
64088   WITH_STORAGE_DIR_TRUE=
64089   WITH_STORAGE_DIR_FALSE='#'
64090 else
64091   WITH_STORAGE_DIR_TRUE='#'
64092   WITH_STORAGE_DIR_FALSE=
64093 fi
64094
64095
64096
64097 if test "$with_osx" = "yes"; then
64098   with_storage_fs=no
64099 fi
64100
64101 if test "$with_storage_fs" = "yes" || test "$with_storage_fs" = "check"; then
64102     ac_fn_c_check_header_mongrel "$LINENO" "mntent.h" "ac_cv_header_mntent_h" "$ac_includes_default"
64103 if test "x$ac_cv_header_mntent_h" = xyes; then :
64104
64105 else
64106
64107         if test "$with_storage_fs" = "check"; then
64108             with_storage_fs=no
64109             { $as_echo "$as_me:${as_lineno-$LINENO}: <mntent.h> is required for the FS storage driver, disabling it" >&5
64110 $as_echo "$as_me: <mntent.h> is required for the FS storage driver, disabling it" >&6;}
64111         else
64112             as_fn_error $? "<mntent.h> is required for the FS storage driver" "$LINENO" 5
64113         fi
64114
64115 fi
64116
64117
64118 fi
64119
64120 if test "$with_storage_fs" = "yes" || test "$with_storage_fs" = "check"; then
64121   # Extract the first word of "mount", so it can be a program name with args.
64122 set dummy mount; ac_word=$2
64123 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
64124 $as_echo_n "checking for $ac_word... " >&6; }
64125 if ${ac_cv_path_MOUNT+:} false; then :
64126   $as_echo_n "(cached) " >&6
64127 else
64128   case $MOUNT in
64129   [\\/]* | ?:[\\/]*)
64130   ac_cv_path_MOUNT="$MOUNT" # Let the user override the test with a path.
64131   ;;
64132   *)
64133   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
64134 as_dummy="$PATH:/sbin:/usr/sbin"
64135 for as_dir in $as_dummy
64136 do
64137   IFS=$as_save_IFS
64138   test -z "$as_dir" && as_dir=.
64139     for ac_exec_ext in '' $ac_executable_extensions; do
64140   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
64141     ac_cv_path_MOUNT="$as_dir/$ac_word$ac_exec_ext"
64142     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
64143     break 2
64144   fi
64145 done
64146   done
64147 IFS=$as_save_IFS
64148
64149   ;;
64150 esac
64151 fi
64152 MOUNT=$ac_cv_path_MOUNT
64153 if test -n "$MOUNT"; then
64154   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MOUNT" >&5
64155 $as_echo "$MOUNT" >&6; }
64156 else
64157   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
64158 $as_echo "no" >&6; }
64159 fi
64160
64161
64162   # Extract the first word of "umount", so it can be a program name with args.
64163 set dummy umount; ac_word=$2
64164 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
64165 $as_echo_n "checking for $ac_word... " >&6; }
64166 if ${ac_cv_path_UMOUNT+:} false; then :
64167   $as_echo_n "(cached) " >&6
64168 else
64169   case $UMOUNT in
64170   [\\/]* | ?:[\\/]*)
64171   ac_cv_path_UMOUNT="$UMOUNT" # Let the user override the test with a path.
64172   ;;
64173   *)
64174   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
64175 as_dummy="$PATH:/sbin:/usr/sbin"
64176 for as_dir in $as_dummy
64177 do
64178   IFS=$as_save_IFS
64179   test -z "$as_dir" && as_dir=.
64180     for ac_exec_ext in '' $ac_executable_extensions; do
64181   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
64182     ac_cv_path_UMOUNT="$as_dir/$ac_word$ac_exec_ext"
64183     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
64184     break 2
64185   fi
64186 done
64187   done
64188 IFS=$as_save_IFS
64189
64190   ;;
64191 esac
64192 fi
64193 UMOUNT=$ac_cv_path_UMOUNT
64194 if test -n "$UMOUNT"; then
64195   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UMOUNT" >&5
64196 $as_echo "$UMOUNT" >&6; }
64197 else
64198   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
64199 $as_echo "no" >&6; }
64200 fi
64201
64202
64203   # Extract the first word of "mkfs", so it can be a program name with args.
64204 set dummy mkfs; ac_word=$2
64205 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
64206 $as_echo_n "checking for $ac_word... " >&6; }
64207 if ${ac_cv_path_MKFS+:} false; then :
64208   $as_echo_n "(cached) " >&6
64209 else
64210   case $MKFS in
64211   [\\/]* | ?:[\\/]*)
64212   ac_cv_path_MKFS="$MKFS" # Let the user override the test with a path.
64213   ;;
64214   *)
64215   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
64216 as_dummy="$PATH:/sbin:/usr/sbin"
64217 for as_dir in $as_dummy
64218 do
64219   IFS=$as_save_IFS
64220   test -z "$as_dir" && as_dir=.
64221     for ac_exec_ext in '' $ac_executable_extensions; do
64222   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
64223     ac_cv_path_MKFS="$as_dir/$ac_word$ac_exec_ext"
64224     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
64225     break 2
64226   fi
64227 done
64228   done
64229 IFS=$as_save_IFS
64230
64231   ;;
64232 esac
64233 fi
64234 MKFS=$ac_cv_path_MKFS
64235 if test -n "$MKFS"; then
64236   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKFS" >&5
64237 $as_echo "$MKFS" >&6; }
64238 else
64239   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
64240 $as_echo "no" >&6; }
64241 fi
64242
64243
64244   if test "$with_storage_fs" = "yes" ; then
64245     if test -z "$MOUNT" ; then as_fn_error $? "We need mount for FS storage driver" "$LINENO" 5 ; fi
64246     if test -z "$UMOUNT" ; then as_fn_error $? "We need umount for FS storage driver" "$LINENO" 5 ; fi
64247     if test -z "$MKFS" ; then as_fn_error $? "We need mkfs for FS storage driver" "$LINENO" 5 ; fi
64248   else
64249     if test -z "$MOUNT" ; then with_storage_fs=no ; fi
64250     if test -z "$UMOUNT" ; then with_storage_fs=no ; fi
64251     if test -z "$MKFS" ; then with_storage_fs=no ; fi
64252
64253     if test "$with_storage_fs" = "check" ; then with_storage_fs=yes ; fi
64254   fi
64255
64256   if test "$with_storage_fs" = "yes" ; then
64257
64258 cat >>confdefs.h <<_ACEOF
64259 #define WITH_STORAGE_FS 1
64260 _ACEOF
64261
64262
64263 cat >>confdefs.h <<_ACEOF
64264 #define MOUNT "$MOUNT"
64265 _ACEOF
64266
64267
64268 cat >>confdefs.h <<_ACEOF
64269 #define UMOUNT "$UMOUNT"
64270 _ACEOF
64271
64272
64273 cat >>confdefs.h <<_ACEOF
64274 #define MKFS "$MKFS"
64275 _ACEOF
64276
64277   fi
64278 fi
64279  if test "$with_storage_fs" = "yes"; then
64280   WITH_STORAGE_FS_TRUE=
64281   WITH_STORAGE_FS_FALSE='#'
64282 else
64283   WITH_STORAGE_FS_TRUE='#'
64284   WITH_STORAGE_FS_FALSE=
64285 fi
64286
64287 if test "$with_storage_fs" = "yes"; then
64288   # Extract the first word of "showmount", so it can be a program name with args.
64289 set dummy showmount; ac_word=$2
64290 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
64291 $as_echo_n "checking for $ac_word... " >&6; }
64292 if ${ac_cv_path_SHOWMOUNT+:} false; then :
64293   $as_echo_n "(cached) " >&6
64294 else
64295   case $SHOWMOUNT in
64296   [\\/]* | ?:[\\/]*)
64297   ac_cv_path_SHOWMOUNT="$SHOWMOUNT" # Let the user override the test with a path.
64298   ;;
64299   *)
64300   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
64301 as_dummy="$PATH:/sbin:/usr/sbin"
64302 for as_dir in $as_dummy
64303 do
64304   IFS=$as_save_IFS
64305   test -z "$as_dir" && as_dir=.
64306     for ac_exec_ext in '' $ac_executable_extensions; do
64307   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
64308     ac_cv_path_SHOWMOUNT="$as_dir/$ac_word$ac_exec_ext"
64309     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
64310     break 2
64311   fi
64312 done
64313   done
64314 IFS=$as_save_IFS
64315
64316   ;;
64317 esac
64318 fi
64319 SHOWMOUNT=$ac_cv_path_SHOWMOUNT
64320 if test -n "$SHOWMOUNT"; then
64321   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SHOWMOUNT" >&5
64322 $as_echo "$SHOWMOUNT" >&6; }
64323 else
64324   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
64325 $as_echo "no" >&6; }
64326 fi
64327
64328
64329
64330 cat >>confdefs.h <<_ACEOF
64331 #define SHOWMOUNT "$SHOWMOUNT"
64332 _ACEOF
64333
64334 fi
64335
64336 if test "$with_storage_lvm" = "yes" || test "$with_storage_lvm" = "check"; then
64337   # Extract the first word of "pvcreate", so it can be a program name with args.
64338 set dummy pvcreate; ac_word=$2
64339 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
64340 $as_echo_n "checking for $ac_word... " >&6; }
64341 if ${ac_cv_path_PVCREATE+:} false; then :
64342   $as_echo_n "(cached) " >&6
64343 else
64344   case $PVCREATE in
64345   [\\/]* | ?:[\\/]*)
64346   ac_cv_path_PVCREATE="$PVCREATE" # Let the user override the test with a path.
64347   ;;
64348   *)
64349   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
64350 as_dummy="$PATH:/sbin:/usr/sbin"
64351 for as_dir in $as_dummy
64352 do
64353   IFS=$as_save_IFS
64354   test -z "$as_dir" && as_dir=.
64355     for ac_exec_ext in '' $ac_executable_extensions; do
64356   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
64357     ac_cv_path_PVCREATE="$as_dir/$ac_word$ac_exec_ext"
64358     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
64359     break 2
64360   fi
64361 done
64362   done
64363 IFS=$as_save_IFS
64364
64365   ;;
64366 esac
64367 fi
64368 PVCREATE=$ac_cv_path_PVCREATE
64369 if test -n "$PVCREATE"; then
64370   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PVCREATE" >&5
64371 $as_echo "$PVCREATE" >&6; }
64372 else
64373   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
64374 $as_echo "no" >&6; }
64375 fi
64376
64377
64378   # Extract the first word of "vgcreate", so it can be a program name with args.
64379 set dummy vgcreate; ac_word=$2
64380 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
64381 $as_echo_n "checking for $ac_word... " >&6; }
64382 if ${ac_cv_path_VGCREATE+:} false; then :
64383   $as_echo_n "(cached) " >&6
64384 else
64385   case $VGCREATE in
64386   [\\/]* | ?:[\\/]*)
64387   ac_cv_path_VGCREATE="$VGCREATE" # Let the user override the test with a path.
64388   ;;
64389   *)
64390   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
64391 as_dummy="$PATH:/sbin:/usr/sbin"
64392 for as_dir in $as_dummy
64393 do
64394   IFS=$as_save_IFS
64395   test -z "$as_dir" && as_dir=.
64396     for ac_exec_ext in '' $ac_executable_extensions; do
64397   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
64398     ac_cv_path_VGCREATE="$as_dir/$ac_word$ac_exec_ext"
64399     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
64400     break 2
64401   fi
64402 done
64403   done
64404 IFS=$as_save_IFS
64405
64406   ;;
64407 esac
64408 fi
64409 VGCREATE=$ac_cv_path_VGCREATE
64410 if test -n "$VGCREATE"; then
64411   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $VGCREATE" >&5
64412 $as_echo "$VGCREATE" >&6; }
64413 else
64414   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
64415 $as_echo "no" >&6; }
64416 fi
64417
64418
64419   # Extract the first word of "lvcreate", so it can be a program name with args.
64420 set dummy lvcreate; ac_word=$2
64421 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
64422 $as_echo_n "checking for $ac_word... " >&6; }
64423 if ${ac_cv_path_LVCREATE+:} false; then :
64424   $as_echo_n "(cached) " >&6
64425 else
64426   case $LVCREATE in
64427   [\\/]* | ?:[\\/]*)
64428   ac_cv_path_LVCREATE="$LVCREATE" # Let the user override the test with a path.
64429   ;;
64430   *)
64431   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
64432 as_dummy="$PATH:/sbin:/usr/sbin"
64433 for as_dir in $as_dummy
64434 do
64435   IFS=$as_save_IFS
64436   test -z "$as_dir" && as_dir=.
64437     for ac_exec_ext in '' $ac_executable_extensions; do
64438   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
64439     ac_cv_path_LVCREATE="$as_dir/$ac_word$ac_exec_ext"
64440     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
64441     break 2
64442   fi
64443 done
64444   done
64445 IFS=$as_save_IFS
64446
64447   ;;
64448 esac
64449 fi
64450 LVCREATE=$ac_cv_path_LVCREATE
64451 if test -n "$LVCREATE"; then
64452   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LVCREATE" >&5
64453 $as_echo "$LVCREATE" >&6; }
64454 else
64455   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
64456 $as_echo "no" >&6; }
64457 fi
64458
64459
64460   # Extract the first word of "pvremove", so it can be a program name with args.
64461 set dummy pvremove; ac_word=$2
64462 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
64463 $as_echo_n "checking for $ac_word... " >&6; }
64464 if ${ac_cv_path_PVREMOVE+:} false; then :
64465   $as_echo_n "(cached) " >&6
64466 else
64467   case $PVREMOVE in
64468   [\\/]* | ?:[\\/]*)
64469   ac_cv_path_PVREMOVE="$PVREMOVE" # Let the user override the test with a path.
64470   ;;
64471   *)
64472   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
64473 as_dummy="$PATH:/sbin:/usr/sbin"
64474 for as_dir in $as_dummy
64475 do
64476   IFS=$as_save_IFS
64477   test -z "$as_dir" && as_dir=.
64478     for ac_exec_ext in '' $ac_executable_extensions; do
64479   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
64480     ac_cv_path_PVREMOVE="$as_dir/$ac_word$ac_exec_ext"
64481     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
64482     break 2
64483   fi
64484 done
64485   done
64486 IFS=$as_save_IFS
64487
64488   ;;
64489 esac
64490 fi
64491 PVREMOVE=$ac_cv_path_PVREMOVE
64492 if test -n "$PVREMOVE"; then
64493   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PVREMOVE" >&5
64494 $as_echo "$PVREMOVE" >&6; }
64495 else
64496   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
64497 $as_echo "no" >&6; }
64498 fi
64499
64500
64501   # Extract the first word of "vgremove", so it can be a program name with args.
64502 set dummy vgremove; ac_word=$2
64503 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
64504 $as_echo_n "checking for $ac_word... " >&6; }
64505 if ${ac_cv_path_VGREMOVE+:} false; then :
64506   $as_echo_n "(cached) " >&6
64507 else
64508   case $VGREMOVE in
64509   [\\/]* | ?:[\\/]*)
64510   ac_cv_path_VGREMOVE="$VGREMOVE" # Let the user override the test with a path.
64511   ;;
64512   *)
64513   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
64514 as_dummy="$PATH:/sbin:/usr/sbin"
64515 for as_dir in $as_dummy
64516 do
64517   IFS=$as_save_IFS
64518   test -z "$as_dir" && as_dir=.
64519     for ac_exec_ext in '' $ac_executable_extensions; do
64520   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
64521     ac_cv_path_VGREMOVE="$as_dir/$ac_word$ac_exec_ext"
64522     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
64523     break 2
64524   fi
64525 done
64526   done
64527 IFS=$as_save_IFS
64528
64529   ;;
64530 esac
64531 fi
64532 VGREMOVE=$ac_cv_path_VGREMOVE
64533 if test -n "$VGREMOVE"; then
64534   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $VGREMOVE" >&5
64535 $as_echo "$VGREMOVE" >&6; }
64536 else
64537   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
64538 $as_echo "no" >&6; }
64539 fi
64540
64541
64542   # Extract the first word of "lvremove", so it can be a program name with args.
64543 set dummy lvremove; ac_word=$2
64544 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
64545 $as_echo_n "checking for $ac_word... " >&6; }
64546 if ${ac_cv_path_LVREMOVE+:} false; then :
64547   $as_echo_n "(cached) " >&6
64548 else
64549   case $LVREMOVE in
64550   [\\/]* | ?:[\\/]*)
64551   ac_cv_path_LVREMOVE="$LVREMOVE" # Let the user override the test with a path.
64552   ;;
64553   *)
64554   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
64555 as_dummy="$PATH:/sbin:/usr/sbin"
64556 for as_dir in $as_dummy
64557 do
64558   IFS=$as_save_IFS
64559   test -z "$as_dir" && as_dir=.
64560     for ac_exec_ext in '' $ac_executable_extensions; do
64561   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
64562     ac_cv_path_LVREMOVE="$as_dir/$ac_word$ac_exec_ext"
64563     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
64564     break 2
64565   fi
64566 done
64567   done
64568 IFS=$as_save_IFS
64569
64570   ;;
64571 esac
64572 fi
64573 LVREMOVE=$ac_cv_path_LVREMOVE
64574 if test -n "$LVREMOVE"; then
64575   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LVREMOVE" >&5
64576 $as_echo "$LVREMOVE" >&6; }
64577 else
64578   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
64579 $as_echo "no" >&6; }
64580 fi
64581
64582
64583   # Extract the first word of "lvchange", so it can be a program name with args.
64584 set dummy lvchange; ac_word=$2
64585 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
64586 $as_echo_n "checking for $ac_word... " >&6; }
64587 if ${ac_cv_path_LVCHANGE+:} false; then :
64588   $as_echo_n "(cached) " >&6
64589 else
64590   case $LVCHANGE in
64591   [\\/]* | ?:[\\/]*)
64592   ac_cv_path_LVCHANGE="$LVCHANGE" # Let the user override the test with a path.
64593   ;;
64594   *)
64595   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
64596 as_dummy="$PATH:/sbin:/usr/sbin"
64597 for as_dir in $as_dummy
64598 do
64599   IFS=$as_save_IFS
64600   test -z "$as_dir" && as_dir=.
64601     for ac_exec_ext in '' $ac_executable_extensions; do
64602   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
64603     ac_cv_path_LVCHANGE="$as_dir/$ac_word$ac_exec_ext"
64604     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
64605     break 2
64606   fi
64607 done
64608   done
64609 IFS=$as_save_IFS
64610
64611   ;;
64612 esac
64613 fi
64614 LVCHANGE=$ac_cv_path_LVCHANGE
64615 if test -n "$LVCHANGE"; then
64616   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LVCHANGE" >&5
64617 $as_echo "$LVCHANGE" >&6; }
64618 else
64619   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
64620 $as_echo "no" >&6; }
64621 fi
64622
64623
64624   # Extract the first word of "vgchange", so it can be a program name with args.
64625 set dummy vgchange; ac_word=$2
64626 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
64627 $as_echo_n "checking for $ac_word... " >&6; }
64628 if ${ac_cv_path_VGCHANGE+:} false; then :
64629   $as_echo_n "(cached) " >&6
64630 else
64631   case $VGCHANGE in
64632   [\\/]* | ?:[\\/]*)
64633   ac_cv_path_VGCHANGE="$VGCHANGE" # Let the user override the test with a path.
64634   ;;
64635   *)
64636   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
64637 as_dummy="$PATH:/sbin:/usr/sbin"
64638 for as_dir in $as_dummy
64639 do
64640   IFS=$as_save_IFS
64641   test -z "$as_dir" && as_dir=.
64642     for ac_exec_ext in '' $ac_executable_extensions; do
64643   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
64644     ac_cv_path_VGCHANGE="$as_dir/$ac_word$ac_exec_ext"
64645     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
64646     break 2
64647   fi
64648 done
64649   done
64650 IFS=$as_save_IFS
64651
64652   ;;
64653 esac
64654 fi
64655 VGCHANGE=$ac_cv_path_VGCHANGE
64656 if test -n "$VGCHANGE"; then
64657   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $VGCHANGE" >&5
64658 $as_echo "$VGCHANGE" >&6; }
64659 else
64660   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
64661 $as_echo "no" >&6; }
64662 fi
64663
64664
64665   # Extract the first word of "vgscan", so it can be a program name with args.
64666 set dummy vgscan; ac_word=$2
64667 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
64668 $as_echo_n "checking for $ac_word... " >&6; }
64669 if ${ac_cv_path_VGSCAN+:} false; then :
64670   $as_echo_n "(cached) " >&6
64671 else
64672   case $VGSCAN in
64673   [\\/]* | ?:[\\/]*)
64674   ac_cv_path_VGSCAN="$VGSCAN" # Let the user override the test with a path.
64675   ;;
64676   *)
64677   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
64678 as_dummy="$PATH:/sbin:/usr/sbin"
64679 for as_dir in $as_dummy
64680 do
64681   IFS=$as_save_IFS
64682   test -z "$as_dir" && as_dir=.
64683     for ac_exec_ext in '' $ac_executable_extensions; do
64684   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
64685     ac_cv_path_VGSCAN="$as_dir/$ac_word$ac_exec_ext"
64686     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
64687     break 2
64688   fi
64689 done
64690   done
64691 IFS=$as_save_IFS
64692
64693   ;;
64694 esac
64695 fi
64696 VGSCAN=$ac_cv_path_VGSCAN
64697 if test -n "$VGSCAN"; then
64698   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $VGSCAN" >&5
64699 $as_echo "$VGSCAN" >&6; }
64700 else
64701   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
64702 $as_echo "no" >&6; }
64703 fi
64704
64705
64706   # Extract the first word of "pvs", so it can be a program name with args.
64707 set dummy pvs; ac_word=$2
64708 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
64709 $as_echo_n "checking for $ac_word... " >&6; }
64710 if ${ac_cv_path_PVS+:} false; then :
64711   $as_echo_n "(cached) " >&6
64712 else
64713   case $PVS in
64714   [\\/]* | ?:[\\/]*)
64715   ac_cv_path_PVS="$PVS" # Let the user override the test with a path.
64716   ;;
64717   *)
64718   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
64719 as_dummy="$PATH:/sbin:/usr/sbin"
64720 for as_dir in $as_dummy
64721 do
64722   IFS=$as_save_IFS
64723   test -z "$as_dir" && as_dir=.
64724     for ac_exec_ext in '' $ac_executable_extensions; do
64725   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
64726     ac_cv_path_PVS="$as_dir/$ac_word$ac_exec_ext"
64727     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
64728     break 2
64729   fi
64730 done
64731   done
64732 IFS=$as_save_IFS
64733
64734   ;;
64735 esac
64736 fi
64737 PVS=$ac_cv_path_PVS
64738 if test -n "$PVS"; then
64739   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PVS" >&5
64740 $as_echo "$PVS" >&6; }
64741 else
64742   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
64743 $as_echo "no" >&6; }
64744 fi
64745
64746
64747   # Extract the first word of "vgs", so it can be a program name with args.
64748 set dummy vgs; ac_word=$2
64749 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
64750 $as_echo_n "checking for $ac_word... " >&6; }
64751 if ${ac_cv_path_VGS+:} false; then :
64752   $as_echo_n "(cached) " >&6
64753 else
64754   case $VGS in
64755   [\\/]* | ?:[\\/]*)
64756   ac_cv_path_VGS="$VGS" # Let the user override the test with a path.
64757   ;;
64758   *)
64759   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
64760 as_dummy="$PATH:/sbin:/usr/sbin"
64761 for as_dir in $as_dummy
64762 do
64763   IFS=$as_save_IFS
64764   test -z "$as_dir" && as_dir=.
64765     for ac_exec_ext in '' $ac_executable_extensions; do
64766   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
64767     ac_cv_path_VGS="$as_dir/$ac_word$ac_exec_ext"
64768     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
64769     break 2
64770   fi
64771 done
64772   done
64773 IFS=$as_save_IFS
64774
64775   ;;
64776 esac
64777 fi
64778 VGS=$ac_cv_path_VGS
64779 if test -n "$VGS"; then
64780   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $VGS" >&5
64781 $as_echo "$VGS" >&6; }
64782 else
64783   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
64784 $as_echo "no" >&6; }
64785 fi
64786
64787
64788   # Extract the first word of "lvs", so it can be a program name with args.
64789 set dummy lvs; ac_word=$2
64790 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
64791 $as_echo_n "checking for $ac_word... " >&6; }
64792 if ${ac_cv_path_LVS+:} false; then :
64793   $as_echo_n "(cached) " >&6
64794 else
64795   case $LVS in
64796   [\\/]* | ?:[\\/]*)
64797   ac_cv_path_LVS="$LVS" # Let the user override the test with a path.
64798   ;;
64799   *)
64800   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
64801 as_dummy="$PATH:/sbin:/usr/sbin"
64802 for as_dir in $as_dummy
64803 do
64804   IFS=$as_save_IFS
64805   test -z "$as_dir" && as_dir=.
64806     for ac_exec_ext in '' $ac_executable_extensions; do
64807   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
64808     ac_cv_path_LVS="$as_dir/$ac_word$ac_exec_ext"
64809     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
64810     break 2
64811   fi
64812 done
64813   done
64814 IFS=$as_save_IFS
64815
64816   ;;
64817 esac
64818 fi
64819 LVS=$ac_cv_path_LVS
64820 if test -n "$LVS"; then
64821   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LVS" >&5
64822 $as_echo "$LVS" >&6; }
64823 else
64824   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
64825 $as_echo "no" >&6; }
64826 fi
64827
64828
64829
64830   if test "$with_storage_lvm" = "yes" ; then
64831     if test -z "$PVCREATE" ; then as_fn_error $? "We need pvcreate for LVM storage driver" "$LINENO" 5 ; fi
64832     if test -z "$VGCREATE" ; then as_fn_error $? "We need vgcreate for LVM storage driver" "$LINENO" 5 ; fi
64833     if test -z "$LVCREATE" ; then as_fn_error $? "We need lvcreate for LVM storage driver" "$LINENO" 5 ; fi
64834     if test -z "$PVREMOVE" ; then as_fn_error $? "We need pvremove for LVM storage driver" "$LINENO" 5 ; fi
64835     if test -z "$VGREMOVE" ; then as_fn_error $? "We need vgremove for LVM storage driver" "$LINENO" 5 ; fi
64836     if test -z "$LVREMOVE" ; then as_fn_error $? "We need lvremove for LVM storage driver" "$LINENO" 5 ; fi
64837     if test -z "$LVCHANGE" ; then as_fn_error $? "We need lvchange for LVM storage driver" "$LINENO" 5 ; fi
64838     if test -z "$VGCHANGE" ; then as_fn_error $? "We need vgchange for LVM storage driver" "$LINENO" 5 ; fi
64839     if test -z "$VGSCAN" ; then as_fn_error $? "We need vgscan for LVM storage driver" "$LINENO" 5 ; fi
64840     if test -z "$PVS" ; then as_fn_error $? "We need pvs for LVM storage driver" "$LINENO" 5 ; fi
64841     if test -z "$VGS" ; then as_fn_error $? "We need vgs for LVM storage driver" "$LINENO" 5 ; fi
64842     if test -z "$LVS" ; then as_fn_error $? "We need lvs for LVM storage driver" "$LINENO" 5 ; fi
64843   else
64844     if test -z "$PVCREATE" ; then with_storage_lvm=no ; fi
64845     if test -z "$VGCREATE" ; then with_storage_lvm=no ; fi
64846     if test -z "$LVCREATE" ; then with_storage_lvm=no ; fi
64847     if test -z "$PVREMOVE" ; then with_storage_lvm=no ; fi
64848     if test -z "$VGREMOVE" ; then with_storage_lvm=no ; fi
64849     if test -z "$LVREMOVE" ; then with_storage_lvm=no ; fi
64850     if test -z "$LVCHANGE" ; then with_storage_lvm=no ; fi
64851     if test -z "$VGCHANGE" ; then with_storage_lvm=no ; fi
64852     if test -z "$VGSCAN" ; then with_storage_lvm=no ; fi
64853     if test -z "$PVS" ; then with_storage_lvm=no ; fi
64854     if test -z "$VGS" ; then with_storage_lvm=no ; fi
64855     if test -z "$LVS" ; then with_storage_lvm=no ; fi
64856
64857     if test "$with_storage_lvm" = "check" ; then with_storage_lvm=yes ; fi
64858   fi
64859
64860   if test "$with_storage_lvm" = "yes" ; then
64861
64862 cat >>confdefs.h <<_ACEOF
64863 #define WITH_STORAGE_LVM 1
64864 _ACEOF
64865
64866
64867 cat >>confdefs.h <<_ACEOF
64868 #define PVCREATE "$PVCREATE"
64869 _ACEOF
64870
64871
64872 cat >>confdefs.h <<_ACEOF
64873 #define VGCREATE "$VGCREATE"
64874 _ACEOF
64875
64876
64877 cat >>confdefs.h <<_ACEOF
64878 #define LVCREATE "$LVCREATE"
64879 _ACEOF
64880
64881
64882 cat >>confdefs.h <<_ACEOF
64883 #define PVREMOVE "$PVREMOVE"
64884 _ACEOF
64885
64886
64887 cat >>confdefs.h <<_ACEOF
64888 #define VGREMOVE "$VGREMOVE"
64889 _ACEOF
64890
64891
64892 cat >>confdefs.h <<_ACEOF
64893 #define LVREMOVE "$LVREMOVE"
64894 _ACEOF
64895
64896
64897 cat >>confdefs.h <<_ACEOF
64898 #define LVCHANGE "$LVCHANGE"
64899 _ACEOF
64900
64901
64902 cat >>confdefs.h <<_ACEOF
64903 #define VGCHANGE "$VGCHANGE"
64904 _ACEOF
64905
64906
64907 cat >>confdefs.h <<_ACEOF
64908 #define VGSCAN "$VGSCAN"
64909 _ACEOF
64910
64911
64912 cat >>confdefs.h <<_ACEOF
64913 #define PVS "$PVS"
64914 _ACEOF
64915
64916
64917 cat >>confdefs.h <<_ACEOF
64918 #define VGS "$VGS"
64919 _ACEOF
64920
64921
64922 cat >>confdefs.h <<_ACEOF
64923 #define LVS "$LVS"
64924 _ACEOF
64925
64926   fi
64927 fi
64928  if test "$with_storage_lvm" = "yes"; then
64929   WITH_STORAGE_LVM_TRUE=
64930   WITH_STORAGE_LVM_FALSE='#'
64931 else
64932   WITH_STORAGE_LVM_TRUE='#'
64933   WITH_STORAGE_LVM_FALSE=
64934 fi
64935
64936
64937
64938
64939 if test "$with_storage_iscsi" = "yes" || test "$with_storage_iscsi" = "check"; then
64940   # Extract the first word of "iscsiadm", so it can be a program name with args.
64941 set dummy iscsiadm; ac_word=$2
64942 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
64943 $as_echo_n "checking for $ac_word... " >&6; }
64944 if ${ac_cv_path_ISCSIADM+:} false; then :
64945   $as_echo_n "(cached) " >&6
64946 else
64947   case $ISCSIADM in
64948   [\\/]* | ?:[\\/]*)
64949   ac_cv_path_ISCSIADM="$ISCSIADM" # Let the user override the test with a path.
64950   ;;
64951   *)
64952   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
64953 as_dummy="$PATH:/sbin:/usr/sbin"
64954 for as_dir in $as_dummy
64955 do
64956   IFS=$as_save_IFS
64957   test -z "$as_dir" && as_dir=.
64958     for ac_exec_ext in '' $ac_executable_extensions; do
64959   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
64960     ac_cv_path_ISCSIADM="$as_dir/$ac_word$ac_exec_ext"
64961     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
64962     break 2
64963   fi
64964 done
64965   done
64966 IFS=$as_save_IFS
64967
64968   ;;
64969 esac
64970 fi
64971 ISCSIADM=$ac_cv_path_ISCSIADM
64972 if test -n "$ISCSIADM"; then
64973   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ISCSIADM" >&5
64974 $as_echo "$ISCSIADM" >&6; }
64975 else
64976   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
64977 $as_echo "no" >&6; }
64978 fi
64979
64980
64981   if test "$with_storage_iscsi" = "yes" ; then
64982     if test -z "$ISCSIADM" ; then as_fn_error $? "We need iscsiadm for iSCSI storage driver" "$LINENO" 5 ; fi
64983   else
64984     if test -z "$ISCSIADM" ; then with_storage_iscsi=no ; fi
64985
64986     if test "$with_storage_iscsi" = "check" ; then with_storage_iscsi=yes ; fi
64987   fi
64988
64989   if test "$with_storage_iscsi" = "yes" ; then
64990
64991 cat >>confdefs.h <<_ACEOF
64992 #define WITH_STORAGE_ISCSI 1
64993 _ACEOF
64994
64995   fi
64996 fi
64997 if test -z "$ISCIADM" ; then
64998
64999 cat >>confdefs.h <<_ACEOF
65000 #define ISCSIADM "iscsiadm"
65001 _ACEOF
65002
65003 else
65004
65005 cat >>confdefs.h <<_ACEOF
65006 #define ISCSIADM "$ISCSIADM"
65007 _ACEOF
65008
65009 fi
65010  if test "$with_storage_iscsi" = "yes"; then
65011   WITH_STORAGE_ISCSI_TRUE=
65012   WITH_STORAGE_ISCSI_FALSE='#'
65013 else
65014   WITH_STORAGE_ISCSI_TRUE='#'
65015   WITH_STORAGE_ISCSI_FALSE=
65016 fi
65017
65018
65019 if test "$with_storage_scsi" = "check"; then
65020    with_storage_scsi=yes
65021
65022
65023 cat >>confdefs.h <<_ACEOF
65024 #define WITH_STORAGE_SCSI 1
65025 _ACEOF
65026
65027 fi
65028  if test "$with_storage_scsi" = "yes"; then
65029   WITH_STORAGE_SCSI_TRUE=
65030   WITH_STORAGE_SCSI_FALSE='#'
65031 else
65032   WITH_STORAGE_SCSI_TRUE='#'
65033   WITH_STORAGE_SCSI_FALSE=
65034 fi
65035
65036
65037 if test "$with_storage_mpath" = "check"; then
65038    if test "$with_linux" = "yes"; then
65039       with_storage_mpath=yes
65040
65041
65042 cat >>confdefs.h <<_ACEOF
65043 #define WITH_STORAGE_MPATH 1
65044 _ACEOF
65045
65046    else
65047       with_storage_mpath=no
65048    fi
65049 fi
65050  if test "$with_storage_mpath" = "yes"; then
65051   WITH_STORAGE_MPATH_TRUE=
65052   WITH_STORAGE_MPATH_FALSE='#'
65053 else
65054   WITH_STORAGE_MPATH_TRUE='#'
65055   WITH_STORAGE_MPATH_FALSE=
65056 fi
65057
65058
65059 LIBRBD_LIBS=
65060 if test "$with_storage_rbd" = "yes" || test "$with_storage_rbd" = "check"; then
65061     ac_fn_c_check_header_mongrel "$LINENO" "rbd/librbd.h" "ac_cv_header_rbd_librbd_h" "$ac_includes_default"
65062 if test "x$ac_cv_header_rbd_librbd_h" = xyes; then :
65063   LIBRBD_FOUND=yes; break;
65064 fi
65065
65066
65067
65068     if test "$LIBRBD_FOUND" = "yes"; then
65069         with_storage_rbd=yes
65070         LIBRBD_LIBS="-lrbd -lrados"
65071
65072 cat >>confdefs.h <<_ACEOF
65073 #define WITH_STORAGE_RBD 1
65074 _ACEOF
65075
65076     else
65077         with_storage_rbd=no
65078     fi
65079 fi
65080  if test "$with_storage_rbd" = "yes"; then
65081   WITH_STORAGE_RBD_TRUE=
65082   WITH_STORAGE_RBD_FALSE='#'
65083 else
65084   WITH_STORAGE_RBD_TRUE='#'
65085   WITH_STORAGE_RBD_FALSE=
65086 fi
65087
65088
65089
65090 if test "$with_storage_sheepdog" = "yes" ||
65091    test "$with_storage_sheepdog" = "check"; then
65092   # Extract the first word of "collie", so it can be a program name with args.
65093 set dummy collie; ac_word=$2
65094 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
65095 $as_echo_n "checking for $ac_word... " >&6; }
65096 if ${ac_cv_path_COLLIE+:} false; then :
65097   $as_echo_n "(cached) " >&6
65098 else
65099   case $COLLIE in
65100   [\\/]* | ?:[\\/]*)
65101   ac_cv_path_COLLIE="$COLLIE" # Let the user override the test with a path.
65102   ;;
65103   *)
65104   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
65105 as_dummy="$PATH:/sbin:/usr/sbin"
65106 for as_dir in $as_dummy
65107 do
65108   IFS=$as_save_IFS
65109   test -z "$as_dir" && as_dir=.
65110     for ac_exec_ext in '' $ac_executable_extensions; do
65111   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
65112     ac_cv_path_COLLIE="$as_dir/$ac_word$ac_exec_ext"
65113     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
65114     break 2
65115   fi
65116 done
65117   done
65118 IFS=$as_save_IFS
65119
65120   ;;
65121 esac
65122 fi
65123 COLLIE=$ac_cv_path_COLLIE
65124 if test -n "$COLLIE"; then
65125   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COLLIE" >&5
65126 $as_echo "$COLLIE" >&6; }
65127 else
65128   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
65129 $as_echo "no" >&6; }
65130 fi
65131
65132
65133
65134   if test "$with_storage_sheepdog" = "yes"; then
65135     if test -z "$COLLIE"; then
65136       as_fn_error $? "We need collie for Sheepdog storage driver" "$LINENO" 5
65137     fi
65138   else
65139     if test -z "$COLLIE"; then
65140       with_storage_sheepdog=no
65141     fi
65142
65143     if test "$with_storage_sheepdog" = "check"; then
65144       with_storage_sheepdog=yes
65145     fi
65146   fi
65147
65148   if test "$with_storage_sheepdog" = "yes"; then
65149
65150 cat >>confdefs.h <<_ACEOF
65151 #define WITH_STORAGE_SHEEPDOG 1
65152 _ACEOF
65153
65154
65155 cat >>confdefs.h <<_ACEOF
65156 #define COLLIE "$COLLIE"
65157 _ACEOF
65158
65159   fi
65160 fi
65161  if test "$with_storage_sheepdog" = "yes"; then
65162   WITH_STORAGE_SHEEPDOG_TRUE=
65163   WITH_STORAGE_SHEEPDOG_FALSE='#'
65164 else
65165   WITH_STORAGE_SHEEPDOG_TRUE='#'
65166   WITH_STORAGE_SHEEPDOG_FALSE=
65167 fi
65168
65169
65170 if test "$with_storage_gluster" = "check"; then
65171   with_storage_gluster=$with_glusterfs
65172 fi
65173 if test "$with_storage_gluster" = "yes"; then
65174   if test "$with_glusterfs" = no; then
65175     as_fn_error $? "Need glusterfs (libgfapi) for gluster storage driver" "$LINENO" 5
65176   fi
65177
65178 cat >>confdefs.h <<_ACEOF
65179 #define WITH_STORAGE_GLUSTER 1
65180 _ACEOF
65181
65182 fi
65183  if test "$with_storage_gluster" = "yes"; then
65184   WITH_STORAGE_GLUSTER_TRUE=
65185   WITH_STORAGE_GLUSTER_FALSE='#'
65186 else
65187   WITH_STORAGE_GLUSTER_TRUE='#'
65188   WITH_STORAGE_GLUSTER_FALSE=
65189 fi
65190
65191
65192 if test "$with_storage_fs" = "yes" ||
65193    test "$with_storage_gluster" = "yes"; then
65194   # Extract the first word of "gluster", so it can be a program name with args.
65195 set dummy gluster; ac_word=$2
65196 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
65197 $as_echo_n "checking for $ac_word... " >&6; }
65198 if ${ac_cv_path_GLUSTER_CLI+:} false; then :
65199   $as_echo_n "(cached) " >&6
65200 else
65201   case $GLUSTER_CLI in
65202   [\\/]* | ?:[\\/]*)
65203   ac_cv_path_GLUSTER_CLI="$GLUSTER_CLI" # Let the user override the test with a path.
65204   ;;
65205   *)
65206   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
65207 as_dummy="$PATH:/sbin:/usr/sbin"
65208 for as_dir in $as_dummy
65209 do
65210   IFS=$as_save_IFS
65211   test -z "$as_dir" && as_dir=.
65212     for ac_exec_ext in '' $ac_executable_extensions; do
65213   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
65214     ac_cv_path_GLUSTER_CLI="$as_dir/$ac_word$ac_exec_ext"
65215     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
65216     break 2
65217   fi
65218 done
65219   done
65220 IFS=$as_save_IFS
65221
65222   ;;
65223 esac
65224 fi
65225 GLUSTER_CLI=$ac_cv_path_GLUSTER_CLI
65226 if test -n "$GLUSTER_CLI"; then
65227   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GLUSTER_CLI" >&5
65228 $as_echo "$GLUSTER_CLI" >&6; }
65229 else
65230   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
65231 $as_echo "no" >&6; }
65232 fi
65233
65234
65235   if test "x$GLUSTER_CLI" != "x"; then
65236
65237 cat >>confdefs.h <<_ACEOF
65238 #define GLUSTER_CLI "$GLUSTER_CLI"
65239 _ACEOF
65240
65241   fi
65242 fi
65243
65244 LIBPARTED_CFLAGS=
65245 LIBPARTED_LIBS=
65246 if test "$with_storage_disk" = "yes" ||
65247    test "$with_storage_disk" = "check"; then
65248   # Extract the first word of "parted", so it can be a program name with args.
65249 set dummy parted; ac_word=$2
65250 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
65251 $as_echo_n "checking for $ac_word... " >&6; }
65252 if ${ac_cv_path_PARTED+:} false; then :
65253   $as_echo_n "(cached) " >&6
65254 else
65255   case $PARTED in
65256   [\\/]* | ?:[\\/]*)
65257   ac_cv_path_PARTED="$PARTED" # Let the user override the test with a path.
65258   ;;
65259   *)
65260   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
65261 as_dummy="$PATH:/sbin:/usr/sbin"
65262 for as_dir in $as_dummy
65263 do
65264   IFS=$as_save_IFS
65265   test -z "$as_dir" && as_dir=.
65266     for ac_exec_ext in '' $ac_executable_extensions; do
65267   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
65268     ac_cv_path_PARTED="$as_dir/$ac_word$ac_exec_ext"
65269     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
65270     break 2
65271   fi
65272 done
65273   done
65274 IFS=$as_save_IFS
65275
65276   ;;
65277 esac
65278 fi
65279 PARTED=$ac_cv_path_PARTED
65280 if test -n "$PARTED"; then
65281   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PARTED" >&5
65282 $as_echo "$PARTED" >&6; }
65283 else
65284   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
65285 $as_echo "no" >&6; }
65286 fi
65287
65288
65289   # Extract the first word of "dmsetup", so it can be a program name with args.
65290 set dummy dmsetup; ac_word=$2
65291 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
65292 $as_echo_n "checking for $ac_word... " >&6; }
65293 if ${ac_cv_path_DMSETUP+:} false; then :
65294   $as_echo_n "(cached) " >&6
65295 else
65296   case $DMSETUP in
65297   [\\/]* | ?:[\\/]*)
65298   ac_cv_path_DMSETUP="$DMSETUP" # Let the user override the test with a path.
65299   ;;
65300   *)
65301   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
65302 as_dummy="$PATH:/sbin:/usr/sbin"
65303 for as_dir in $as_dummy
65304 do
65305   IFS=$as_save_IFS
65306   test -z "$as_dir" && as_dir=.
65307     for ac_exec_ext in '' $ac_executable_extensions; do
65308   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
65309     ac_cv_path_DMSETUP="$as_dir/$ac_word$ac_exec_ext"
65310     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
65311     break 2
65312   fi
65313 done
65314   done
65315 IFS=$as_save_IFS
65316
65317   ;;
65318 esac
65319 fi
65320 DMSETUP=$ac_cv_path_DMSETUP
65321 if test -n "$DMSETUP"; then
65322   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DMSETUP" >&5
65323 $as_echo "$DMSETUP" >&6; }
65324 else
65325   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
65326 $as_echo "no" >&6; }
65327 fi
65328
65329
65330   if test -z "$PARTED" ; then
65331     PARTED_FOUND=no
65332   else
65333     PARTED_FOUND=yes
65334   fi
65335
65336   if test -z "$DMSETUP" ; then
65337     DMSETUP_FOUND=no
65338   else
65339     DMSETUP_FOUND=yes
65340   fi
65341
65342   if test "$PARTED_FOUND" = "yes" && test "x$PKG_CONFIG" != "x" ; then
65343
65344 pkg_failed=no
65345 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIBPARTED" >&5
65346 $as_echo_n "checking for LIBPARTED... " >&6; }
65347
65348 if test -n "$LIBPARTED_CFLAGS"; then
65349     pkg_cv_LIBPARTED_CFLAGS="$LIBPARTED_CFLAGS"
65350  elif test -n "$PKG_CONFIG"; then
65351     if test -n "$PKG_CONFIG" && \
65352     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libparted >= \$PARTED_REQUIRED\""; } >&5
65353   ($PKG_CONFIG --exists --print-errors "libparted >= $PARTED_REQUIRED") 2>&5
65354   ac_status=$?
65355   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
65356   test $ac_status = 0; }; then
65357   pkg_cv_LIBPARTED_CFLAGS=`$PKG_CONFIG --cflags "libparted >= $PARTED_REQUIRED" 2>/dev/null`
65358                       test "x$?" != "x0" && pkg_failed=yes
65359 else
65360   pkg_failed=yes
65361 fi
65362  else
65363     pkg_failed=untried
65364 fi
65365 if test -n "$LIBPARTED_LIBS"; then
65366     pkg_cv_LIBPARTED_LIBS="$LIBPARTED_LIBS"
65367  elif test -n "$PKG_CONFIG"; then
65368     if test -n "$PKG_CONFIG" && \
65369     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libparted >= \$PARTED_REQUIRED\""; } >&5
65370   ($PKG_CONFIG --exists --print-errors "libparted >= $PARTED_REQUIRED") 2>&5
65371   ac_status=$?
65372   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
65373   test $ac_status = 0; }; then
65374   pkg_cv_LIBPARTED_LIBS=`$PKG_CONFIG --libs "libparted >= $PARTED_REQUIRED" 2>/dev/null`
65375                       test "x$?" != "x0" && pkg_failed=yes
65376 else
65377   pkg_failed=yes
65378 fi
65379  else
65380     pkg_failed=untried
65381 fi
65382
65383
65384
65385 if test $pkg_failed = yes; then
65386         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
65387 $as_echo "no" >&6; }
65388
65389 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
65390         _pkg_short_errors_supported=yes
65391 else
65392         _pkg_short_errors_supported=no
65393 fi
65394         if test $_pkg_short_errors_supported = yes; then
65395                 LIBPARTED_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libparted >= $PARTED_REQUIRED" 2>&1`
65396         else
65397                 LIBPARTED_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libparted >= $PARTED_REQUIRED" 2>&1`
65398         fi
65399         # Put the nasty error message in config.log where it belongs
65400         echo "$LIBPARTED_PKG_ERRORS" >&5
65401
65402         PARTED_FOUND=no
65403 elif test $pkg_failed = untried; then
65404         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
65405 $as_echo "no" >&6; }
65406         PARTED_FOUND=no
65407 else
65408         LIBPARTED_CFLAGS=$pkg_cv_LIBPARTED_CFLAGS
65409         LIBPARTED_LIBS=$pkg_cv_LIBPARTED_LIBS
65410         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
65411 $as_echo "yes" >&6; }
65412
65413 fi
65414   fi
65415   if test "$PARTED_FOUND" = "no"; then
65416     # RHEL-5 vintage parted is missing pkg-config files
65417     save_LIBS="$LIBS"
65418     save_CFLAGS="$CFLAGS"
65419     PARTED_FOUND=yes
65420     ac_fn_c_check_header_mongrel "$LINENO" "parted/parted.h" "ac_cv_header_parted_parted_h" "$ac_includes_default"
65421 if test "x$ac_cv_header_parted_parted_h" = xyes; then :
65422
65423 else
65424   PARTED_FOUND=no
65425 fi
65426
65427
65428     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uuid_generate in -luuid" >&5
65429 $as_echo_n "checking for uuid_generate in -luuid... " >&6; }
65430 if ${ac_cv_lib_uuid_uuid_generate+:} false; then :
65431   $as_echo_n "(cached) " >&6
65432 else
65433   ac_check_lib_save_LIBS=$LIBS
65434 LIBS="-luuid  $LIBS"
65435 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
65436 /* end confdefs.h.  */
65437
65438 /* Override any GCC internal prototype to avoid an error.
65439    Use char because int might match the return type of a GCC
65440    builtin and then its argument prototype would still apply.  */
65441 #ifdef __cplusplus
65442 extern "C"
65443 #endif
65444 char uuid_generate ();
65445 int
65446 main ()
65447 {
65448 return uuid_generate ();
65449   ;
65450   return 0;
65451 }
65452 _ACEOF
65453 if ac_fn_c_try_link "$LINENO"; then :
65454   ac_cv_lib_uuid_uuid_generate=yes
65455 else
65456   ac_cv_lib_uuid_uuid_generate=no
65457 fi
65458 rm -f core conftest.err conftest.$ac_objext \
65459     conftest$ac_exeext conftest.$ac_ext
65460 LIBS=$ac_check_lib_save_LIBS
65461 fi
65462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_uuid_uuid_generate" >&5
65463 $as_echo "$ac_cv_lib_uuid_uuid_generate" >&6; }
65464 if test "x$ac_cv_lib_uuid_uuid_generate" = xyes; then :
65465   cat >>confdefs.h <<_ACEOF
65466 #define HAVE_LIBUUID 1
65467 _ACEOF
65468
65469   LIBS="-luuid $LIBS"
65470
65471 else
65472   PARTED_FOUND=no
65473 fi
65474
65475     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ped_device_read in -lparted" >&5
65476 $as_echo_n "checking for ped_device_read in -lparted... " >&6; }
65477 if ${ac_cv_lib_parted_ped_device_read+:} false; then :
65478   $as_echo_n "(cached) " >&6
65479 else
65480   ac_check_lib_save_LIBS=$LIBS
65481 LIBS="-lparted  $LIBS"
65482 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
65483 /* end confdefs.h.  */
65484
65485 /* Override any GCC internal prototype to avoid an error.
65486    Use char because int might match the return type of a GCC
65487    builtin and then its argument prototype would still apply.  */
65488 #ifdef __cplusplus
65489 extern "C"
65490 #endif
65491 char ped_device_read ();
65492 int
65493 main ()
65494 {
65495 return ped_device_read ();
65496   ;
65497   return 0;
65498 }
65499 _ACEOF
65500 if ac_fn_c_try_link "$LINENO"; then :
65501   ac_cv_lib_parted_ped_device_read=yes
65502 else
65503   ac_cv_lib_parted_ped_device_read=no
65504 fi
65505 rm -f core conftest.err conftest.$ac_objext \
65506     conftest$ac_exeext conftest.$ac_ext
65507 LIBS=$ac_check_lib_save_LIBS
65508 fi
65509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_parted_ped_device_read" >&5
65510 $as_echo "$ac_cv_lib_parted_ped_device_read" >&6; }
65511 if test "x$ac_cv_lib_parted_ped_device_read" = xyes; then :
65512   cat >>confdefs.h <<_ACEOF
65513 #define HAVE_LIBPARTED 1
65514 _ACEOF
65515
65516   LIBS="-lparted $LIBS"
65517
65518 else
65519   PARTED_FOUND=no
65520 fi
65521
65522     LIBPARTED_LIBS="-luuid -lparted"
65523     LIBS="$save_LIBS"
65524     CFLAGS="$save_CFLAGS"
65525   fi
65526
65527   if test "$with_storage_disk" = "yes" &&
65528      test "$PARTED_FOUND:$DMSETUP_FOUND" != "yes:yes"; then
65529     as_fn_error $? "Need both parted and dmsetup for disk storage driver" "$LINENO" 5
65530   fi
65531
65532   if test "$with_storage_disk" = "check"; then
65533     if test "$PARTED_FOUND:$DMSETUP_FOUND" != "yes:yes"; then
65534       with_storage_disk=no
65535     else
65536       with_storage_disk=yes
65537     fi
65538   fi
65539
65540   if test "$with_storage_disk" = "yes"; then
65541
65542 cat >>confdefs.h <<_ACEOF
65543 #define WITH_STORAGE_DISK 1
65544 _ACEOF
65545
65546
65547 cat >>confdefs.h <<_ACEOF
65548 #define PARTED "$PARTED"
65549 _ACEOF
65550
65551
65552 cat >>confdefs.h <<_ACEOF
65553 #define DMSETUP "$DMSETUP"
65554 _ACEOF
65555
65556   fi
65557 fi
65558  if test "$with_storage_disk" = "yes"; then
65559   WITH_STORAGE_DISK_TRUE=
65560   WITH_STORAGE_DISK_FALSE='#'
65561 else
65562   WITH_STORAGE_DISK_TRUE='#'
65563   WITH_STORAGE_DISK_FALSE=
65564 fi
65565
65566
65567
65568
65569 if test "$with_storage_mpath" = "yes" ||
65570    test "$with_storage_disk" = "yes"; then
65571    DEVMAPPER_CFLAGS=
65572    DEVMAPPER_LIBS=
65573
65574 pkg_failed=no
65575 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DEVMAPPER" >&5
65576 $as_echo_n "checking for DEVMAPPER... " >&6; }
65577
65578 if test -n "$DEVMAPPER_CFLAGS"; then
65579     pkg_cv_DEVMAPPER_CFLAGS="$DEVMAPPER_CFLAGS"
65580  elif test -n "$PKG_CONFIG"; then
65581     if test -n "$PKG_CONFIG" && \
65582     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"devmapper >= \$DEVMAPPER_REQUIRED\""; } >&5
65583   ($PKG_CONFIG --exists --print-errors "devmapper >= $DEVMAPPER_REQUIRED") 2>&5
65584   ac_status=$?
65585   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
65586   test $ac_status = 0; }; then
65587   pkg_cv_DEVMAPPER_CFLAGS=`$PKG_CONFIG --cflags "devmapper >= $DEVMAPPER_REQUIRED" 2>/dev/null`
65588                       test "x$?" != "x0" && pkg_failed=yes
65589 else
65590   pkg_failed=yes
65591 fi
65592  else
65593     pkg_failed=untried
65594 fi
65595 if test -n "$DEVMAPPER_LIBS"; then
65596     pkg_cv_DEVMAPPER_LIBS="$DEVMAPPER_LIBS"
65597  elif test -n "$PKG_CONFIG"; then
65598     if test -n "$PKG_CONFIG" && \
65599     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"devmapper >= \$DEVMAPPER_REQUIRED\""; } >&5
65600   ($PKG_CONFIG --exists --print-errors "devmapper >= $DEVMAPPER_REQUIRED") 2>&5
65601   ac_status=$?
65602   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
65603   test $ac_status = 0; }; then
65604   pkg_cv_DEVMAPPER_LIBS=`$PKG_CONFIG --libs "devmapper >= $DEVMAPPER_REQUIRED" 2>/dev/null`
65605                       test "x$?" != "x0" && pkg_failed=yes
65606 else
65607   pkg_failed=yes
65608 fi
65609  else
65610     pkg_failed=untried
65611 fi
65612
65613
65614
65615 if test $pkg_failed = yes; then
65616         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
65617 $as_echo "no" >&6; }
65618
65619 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
65620         _pkg_short_errors_supported=yes
65621 else
65622         _pkg_short_errors_supported=no
65623 fi
65624         if test $_pkg_short_errors_supported = yes; then
65625                 DEVMAPPER_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "devmapper >= $DEVMAPPER_REQUIRED" 2>&1`
65626         else
65627                 DEVMAPPER_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "devmapper >= $DEVMAPPER_REQUIRED" 2>&1`
65628         fi
65629         # Put the nasty error message in config.log where it belongs
65630         echo "$DEVMAPPER_PKG_ERRORS" >&5
65631
65632         DEVMAPPER_FOUND=no
65633 elif test $pkg_failed = untried; then
65634         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
65635 $as_echo "no" >&6; }
65636         DEVMAPPER_FOUND=no
65637 else
65638         DEVMAPPER_CFLAGS=$pkg_cv_DEVMAPPER_CFLAGS
65639         DEVMAPPER_LIBS=$pkg_cv_DEVMAPPER_LIBS
65640         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
65641 $as_echo "yes" >&6; }
65642
65643 fi
65644    if test "$DEVMAPPER_FOUND" = "no"; then
65645      # devmapper is missing pkg-config files in ubuntu, suse, etc
65646      save_LIBS="$LIBS"
65647      save_CFLAGS="$CFLAGS"
65648      DEVMAPPER_FOUND=yes
65649      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dm_task_run in -ldevmapper" >&5
65650 $as_echo_n "checking for dm_task_run in -ldevmapper... " >&6; }
65651 if ${ac_cv_lib_devmapper_dm_task_run+:} false; then :
65652   $as_echo_n "(cached) " >&6
65653 else
65654   ac_check_lib_save_LIBS=$LIBS
65655 LIBS="-ldevmapper  $LIBS"
65656 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
65657 /* end confdefs.h.  */
65658
65659 /* Override any GCC internal prototype to avoid an error.
65660    Use char because int might match the return type of a GCC
65661    builtin and then its argument prototype would still apply.  */
65662 #ifdef __cplusplus
65663 extern "C"
65664 #endif
65665 char dm_task_run ();
65666 int
65667 main ()
65668 {
65669 return dm_task_run ();
65670   ;
65671   return 0;
65672 }
65673 _ACEOF
65674 if ac_fn_c_try_link "$LINENO"; then :
65675   ac_cv_lib_devmapper_dm_task_run=yes
65676 else
65677   ac_cv_lib_devmapper_dm_task_run=no
65678 fi
65679 rm -f core conftest.err conftest.$ac_objext \
65680     conftest$ac_exeext conftest.$ac_ext
65681 LIBS=$ac_check_lib_save_LIBS
65682 fi
65683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_devmapper_dm_task_run" >&5
65684 $as_echo "$ac_cv_lib_devmapper_dm_task_run" >&6; }
65685 if test "x$ac_cv_lib_devmapper_dm_task_run" = xyes; then :
65686   cat >>confdefs.h <<_ACEOF
65687 #define HAVE_LIBDEVMAPPER 1
65688 _ACEOF
65689
65690   LIBS="-ldevmapper $LIBS"
65691
65692 else
65693   DEVMAPPER_FOUND=no
65694 fi
65695
65696      DEVMAPPER_LIBS="-ldevmapper"
65697      LIBS="$save_LIBS"
65698      CFLAGS="$save_CFLAGS"
65699    fi
65700    for ac_header in libdevmapper.h
65701 do :
65702   ac_fn_c_check_header_mongrel "$LINENO" "libdevmapper.h" "ac_cv_header_libdevmapper_h" "$ac_includes_default"
65703 if test "x$ac_cv_header_libdevmapper_h" = xyes; then :
65704   cat >>confdefs.h <<_ACEOF
65705 #define HAVE_LIBDEVMAPPER_H 1
65706 _ACEOF
65707
65708 else
65709   DEVMAPPER_FOUND=no
65710 fi
65711
65712 done
65713
65714    if test "$DEVMAPPER_FOUND" = "no" ; then
65715      as_fn_error $? "You must install device-mapper-devel/libdevmapper >= $DEVMAPPER_REQUIRED to compile libvirt" "$LINENO" 5
65716    fi
65717
65718 fi
65719
65720
65721
65722 with_storage=no
65723 for backend in dir fs lvm iscsi scsi mpath rbd disk; do
65724     if eval test \$with_storage_$backend = yes; then
65725         with_storage=yes
65726         break
65727     fi
65728 done
65729 if test $with_storage = yes; then
65730
65731 $as_echo "#define WITH_STORAGE 1" >>confdefs.h
65732
65733 fi
65734  if test "$with_storage" = "yes"; then
65735   WITH_STORAGE_TRUE=
65736   WITH_STORAGE_FALSE='#'
65737 else
65738   WITH_STORAGE_TRUE='#'
65739   WITH_STORAGE_FALSE=
65740 fi
65741
65742
65743
65744 if test "$with_curl" != "yes" ; then
65745   if test "$with_esx" != "yes"; then
65746     with_esx=no
65747   else
65748     as_fn_error $? "Curl is required for the ESX driver" "$LINENO" 5
65749   fi
65750 else
65751   if test "$with_esx" = "check"; then
65752     with_esx=yes
65753   fi
65754 fi
65755
65756 if test "$with_esx" = "yes" ; then
65757
65758 cat >>confdefs.h <<_ACEOF
65759 #define WITH_ESX 1
65760 _ACEOF
65761
65762 fi
65763  if test "$with_esx" = "yes"; then
65764   WITH_ESX_TRUE=
65765   WITH_ESX_FALSE='#'
65766 else
65767   WITH_ESX_TRUE='#'
65768   WITH_ESX_FALSE=
65769 fi
65770
65771
65772 with_vmx=yes
65773 if test "$with_esx" != "yes" && test "$with_vmware" != "yes"; then
65774   with_vmx=no
65775 fi
65776 if test "$with_vmx" = "yes" ; then
65777
65778 cat >>confdefs.h <<_ACEOF
65779 #define WITH_VMX 1
65780 _ACEOF
65781
65782 fi
65783  if test "$with_vmx" = "yes"; then
65784   WITH_VMX_TRUE=
65785   WITH_VMX_FALSE='#'
65786 else
65787   WITH_VMX_TRUE='#'
65788   WITH_VMX_FALSE=
65789 fi
65790
65791
65792 if test "$with_xenapi" = "yes" ; then
65793
65794 cat >>confdefs.h <<_ACEOF
65795 #define WITH_XENAPI 1
65796 _ACEOF
65797
65798 fi
65799  if test "$with_xenapi" = "yes"; then
65800   WITH_XENAPI_TRUE=
65801   WITH_XENAPI_FALSE='#'
65802 else
65803   WITH_XENAPI_TRUE='#'
65804   WITH_XENAPI_FALSE=
65805 fi
65806
65807
65808
65809
65810 if test "$with_hyperv" != "no"; then
65811   if test "$with_openwsman" != "yes"; then
65812     if test "$with_hyperv" = "check"; then
65813       with_hyperv=no
65814     else
65815       as_fn_error $? "openwsman is required for the Hyper-V driver" "$LINENO" 5
65816     fi
65817   else
65818     with_hyperv=yes
65819   fi
65820 fi
65821
65822 if test "$with_hyperv" = "yes" ; then
65823
65824 cat >>confdefs.h <<_ACEOF
65825 #define WITH_HYPERV 1
65826 _ACEOF
65827
65828 fi
65829  if test "$with_hyperv" = "yes"; then
65830   WITH_HYPERV_TRUE=
65831   WITH_HYPERV_FALSE='#'
65832 else
65833   WITH_HYPERV_TRUE='#'
65834   WITH_HYPERV_FALSE=
65835 fi
65836
65837
65838
65839 for ac_prog in python2 python
65840 do
65841   # Extract the first word of "$ac_prog", so it can be a program name with args.
65842 set dummy $ac_prog; ac_word=$2
65843 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
65844 $as_echo_n "checking for $ac_word... " >&6; }
65845 if ${ac_cv_path_PYTHON+:} false; then :
65846   $as_echo_n "(cached) " >&6
65847 else
65848   case $PYTHON in
65849   [\\/]* | ?:[\\/]*)
65850   ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
65851   ;;
65852   *)
65853   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
65854 for as_dir in $PATH
65855 do
65856   IFS=$as_save_IFS
65857   test -z "$as_dir" && as_dir=.
65858     for ac_exec_ext in '' $ac_executable_extensions; do
65859   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
65860     ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
65861     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
65862     break 2
65863   fi
65864 done
65865   done
65866 IFS=$as_save_IFS
65867
65868   ;;
65869 esac
65870 fi
65871 PYTHON=$ac_cv_path_PYTHON
65872 if test -n "$PYTHON"; then
65873   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHON" >&5
65874 $as_echo "$PYTHON" >&6; }
65875 else
65876   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
65877 $as_echo "no" >&6; }
65878 fi
65879
65880
65881   test -n "$PYTHON" && break
65882 done
65883
65884 # Extract the first word of "perl", so it can be a program name with args.
65885 set dummy perl; ac_word=$2
65886 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
65887 $as_echo_n "checking for $ac_word... " >&6; }
65888 if ${ac_cv_path_PERL+:} false; then :
65889   $as_echo_n "(cached) " >&6
65890 else
65891   case $PERL in
65892   [\\/]* | ?:[\\/]*)
65893   ac_cv_path_PERL="$PERL" # Let the user override the test with a path.
65894   ;;
65895   *)
65896   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
65897 for as_dir in $PATH
65898 do
65899   IFS=$as_save_IFS
65900   test -z "$as_dir" && as_dir=.
65901     for ac_exec_ext in '' $ac_executable_extensions; do
65902   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
65903     ac_cv_path_PERL="$as_dir/$ac_word$ac_exec_ext"
65904     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
65905     break 2
65906   fi
65907 done
65908   done
65909 IFS=$as_save_IFS
65910
65911   ;;
65912 esac
65913 fi
65914 PERL=$ac_cv_path_PERL
65915 if test -n "$PERL"; then
65916   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PERL" >&5
65917 $as_echo "$PERL" >&6; }
65918 else
65919   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
65920 $as_echo "no" >&6; }
65921 fi
65922
65923
65924
65925
65926 # Check whether --with-test-suite was given.
65927 if test "${with_test_suite+set}" = set; then :
65928   withval=$with_test_suite; case "${withval}" in
65929                yes|no|check) ;;
65930                *)      as_fn_error $? "bad value ${withval} for tests option" "$LINENO" 5 ;;
65931             esac
65932 else
65933   withval=check
65934 fi
65935
65936
65937 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Whether to build test suite by default" >&5
65938 $as_echo_n "checking Whether to build test suite by default... " >&6; }
65939 if test "$withval" = "check" ; then
65940   if test -d $srcdir/.git ; then
65941     withval=yes
65942   else
65943     withval=no
65944   fi
65945 fi
65946 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $withval" >&5
65947 $as_echo "$withval" >&6; }
65948  if test "$withval" = "yes"; then
65949   WITH_TESTS_TRUE=
65950   WITH_TESTS_FALSE='#'
65951 else
65952   WITH_TESTS_TRUE='#'
65953   WITH_TESTS_FALSE=
65954 fi
65955
65956
65957 # Check whether --enable-expensive-tests was given.
65958 if test "${enable_expensive_tests+set}" = set; then :
65959   enableval=$enable_expensive_tests; case $enableval in
65960     0|no) VIR_TEST_EXPENSIVE_DEFAULT=0 ;;
65961     1|yes) VIR_TEST_EXPENSIVE_DEFAULT=1 ;;
65962     check) ;;
65963     *) as_fn_error $? "bad value ${enableval} for enable-expensive-tests option" "$LINENO" 5
65964       ;;
65965   esac
65966 else
65967   enableval=check
65968 fi
65969
65970 if test "$enableval" = check; then
65971   if test -d $srcdir/.git ; then
65972     VIR_TEST_EXPENSIVE_DEFAULT=0
65973   else
65974     VIR_TEST_EXPENSIVE_DEFAULT=1
65975   fi
65976 fi
65977
65978  if test $VIR_TEST_EXPENSIVE_DEFAULT = 1; then
65979   WITH_EXPENSIVE_TESTS_TRUE=
65980   WITH_EXPENSIVE_TESTS_FALSE='#'
65981 else
65982   WITH_EXPENSIVE_TESTS_TRUE='#'
65983   WITH_EXPENSIVE_TESTS_FALSE=
65984 fi
65985
65986
65987 # Check whether --enable-test-coverage was given.
65988 if test "${enable_test_coverage+set}" = set; then :
65989   enableval=$enable_test_coverage; case "${enableval}" in
65990    yes|no) ;;
65991    *)      as_fn_error $? "bad value ${enableval} for test-coverage option" "$LINENO" 5 ;;
65992  esac
65993 else
65994   enableval=no
65995 fi
65996
65997 enable_coverage=$enableval
65998
65999 if test "${enable_coverage}" = yes; then
66000   save_WARN_CFLAGS=$WARN_CFLAGS
66001   WARN_CFLAGS=
66002
66003 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -fprofile-arcs" >&5
66004 $as_echo_n "checking whether C compiler handles -fprofile-arcs... " >&6; }
66005 if ${gl_cv_warn_c__fprofile_arcs+:} false; then :
66006   $as_echo_n "(cached) " >&6
66007 else
66008
66009   gl_save_compiler_FLAGS="$CFLAGS"
66010   as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -fprofile-arcs"
66011   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
66012 /* end confdefs.h.  */
66013
66014 int
66015 main ()
66016 {
66017
66018   ;
66019   return 0;
66020 }
66021 _ACEOF
66022 if ac_fn_c_try_link "$LINENO"; then :
66023   gl_cv_warn_c__fprofile_arcs=yes
66024 else
66025   gl_cv_warn_c__fprofile_arcs=no
66026 fi
66027 rm -f core conftest.err conftest.$ac_objext \
66028     conftest$ac_exeext conftest.$ac_ext
66029   CFLAGS="$gl_save_compiler_FLAGS"
66030
66031 fi
66032 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__fprofile_arcs" >&5
66033 $as_echo "$gl_cv_warn_c__fprofile_arcs" >&6; }
66034 if test "x$gl_cv_warn_c__fprofile_arcs" = xyes; then :
66035   as_fn_append WARN_CFLAGS " -fprofile-arcs"
66036 fi
66037
66038
66039
66040 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -ftest-coverage" >&5
66041 $as_echo_n "checking whether C compiler handles -ftest-coverage... " >&6; }
66042 if ${gl_cv_warn_c__ftest_coverage+:} false; then :
66043   $as_echo_n "(cached) " >&6
66044 else
66045
66046   gl_save_compiler_FLAGS="$CFLAGS"
66047   as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -ftest-coverage"
66048   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
66049 /* end confdefs.h.  */
66050
66051 int
66052 main ()
66053 {
66054
66055   ;
66056   return 0;
66057 }
66058 _ACEOF
66059 if ac_fn_c_try_link "$LINENO"; then :
66060   gl_cv_warn_c__ftest_coverage=yes
66061 else
66062   gl_cv_warn_c__ftest_coverage=no
66063 fi
66064 rm -f core conftest.err conftest.$ac_objext \
66065     conftest$ac_exeext conftest.$ac_ext
66066   CFLAGS="$gl_save_compiler_FLAGS"
66067
66068 fi
66069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__ftest_coverage" >&5
66070 $as_echo "$gl_cv_warn_c__ftest_coverage" >&6; }
66071 if test "x$gl_cv_warn_c__ftest_coverage" = xyes; then :
66072   as_fn_append WARN_CFLAGS " -ftest-coverage"
66073 fi
66074
66075
66076   COVERAGE_FLAGS=$WARN_CFLAGS
66077   COVERAGE_CFLAGS=$COVERAGE_FLAGS
66078
66079   COVERAGE_LDFLAGS=$COVERAGE_FLAGS
66080
66081   WARN_CFLAGS=$save_WARN_CFLAGS
66082 fi
66083
66084 # Check whether --enable-test-oom was given.
66085 if test "${enable_test_oom+set}" = set; then :
66086   enableval=$enable_test_oom; case "${enableval}" in
66087    yes|no) ;;
66088    *)      as_fn_error $? "bad value ${enableval} for test-oom option" "$LINENO" 5 ;;
66089  esac
66090 else
66091   enableval=no
66092 fi
66093
66094 enable_oom=$enableval
66095
66096 if test "${enable_oom}" = yes; then
66097   have_trace=yes
66098   ac_fn_c_check_header_mongrel "$LINENO" "execinfo.h" "ac_cv_header_execinfo_h" "$ac_includes_default"
66099 if test "x$ac_cv_header_execinfo_h" = xyes; then :
66100
66101 else
66102   have_trace=no
66103 fi
66104
66105
66106   ac_fn_c_check_func "$LINENO" "backtrace" "ac_cv_func_backtrace"
66107 if test "x$ac_cv_func_backtrace" = xyes; then :
66108
66109 else
66110   have_trace=no
66111 fi
66112
66113   if test "$have_trace" = "yes"; then
66114
66115 $as_echo "#define TEST_OOM_TRACE 1" >>confdefs.h
66116
66117   fi
66118
66119 $as_echo "#define TEST_OOM 1" >>confdefs.h
66120
66121 fi
66122
66123
66124 # Check whether --enable-test-locking was given.
66125 if test "${enable_test_locking+set}" = set; then :
66126   enableval=$enable_test_locking; case "${enableval}" in
66127    yes|no) ;;
66128    *)      as_fn_error $? "bad value ${enableval} for test-locking option" "$LINENO" 5 ;;
66129  esac
66130 else
66131   enableval=no
66132 fi
66133
66134 enable_locking=$enableval
66135
66136 if test "$enable_locking" = "yes"; then
66137   LOCK_CHECKING_CFLAGS="-save-temps"
66138
66139 fi
66140  if test "$enable_locking" = "yes"; then
66141   WITH_CIL_TRUE=
66142   WITH_CIL_FALSE='#'
66143 else
66144   WITH_CIL_TRUE='#'
66145   WITH_CIL_FALSE=
66146 fi
66147
66148
66149  if test "x$with_libvirtd" = "xyes"; then
66150   WITH_LIBVIRTD_TRUE=
66151   WITH_LIBVIRTD_FALSE='#'
66152 else
66153   WITH_LIBVIRTD_TRUE='#'
66154   WITH_LIBVIRTD_FALSE=
66155 fi
66156
66157
66158 save_CPPFLAGS="$CPPFLAGS"
66159
66160
66161 mkdir_p="$MKDIR_P"
66162 case $mkdir_p in
66163   [\\/$]* | ?:[\\/]*) ;;
66164   */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
66165 esac
66166
66167
66168   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
66169 $as_echo_n "checking whether NLS is requested... " >&6; }
66170     # Check whether --enable-nls was given.
66171 if test "${enable_nls+set}" = set; then :
66172   enableval=$enable_nls; USE_NLS=$enableval
66173 else
66174   USE_NLS=yes
66175 fi
66176
66177   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5
66178 $as_echo "$USE_NLS" >&6; }
66179
66180
66181
66182
66183       GETTEXT_MACRO_VERSION=0.17
66184
66185
66186
66187
66188 # Prepare PATH_SEPARATOR.
66189 # The user is always right.
66190 if test "${PATH_SEPARATOR+set}" != set; then
66191   echo "#! /bin/sh" >conf$$.sh
66192   echo  "exit 0"   >>conf$$.sh
66193   chmod +x conf$$.sh
66194   if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
66195     PATH_SEPARATOR=';'
66196   else
66197     PATH_SEPARATOR=:
66198   fi
66199   rm -f conf$$.sh
66200 fi
66201
66202 # Find out how to test for executable files. Don't use a zero-byte file,
66203 # as systems may use methods other than mode bits to determine executability.
66204 cat >conf$$.file <<_ASEOF
66205 #! /bin/sh
66206 exit 0
66207 _ASEOF
66208 chmod +x conf$$.file
66209 if test -x conf$$.file >/dev/null 2>&1; then
66210   ac_executable_p="test -x"
66211 else
66212   ac_executable_p="test -f"
66213 fi
66214 rm -f conf$$.file
66215
66216 # Extract the first word of "msgfmt", so it can be a program name with args.
66217 set dummy msgfmt; ac_word=$2
66218 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
66219 $as_echo_n "checking for $ac_word... " >&6; }
66220 if ${ac_cv_path_MSGFMT+:} false; then :
66221   $as_echo_n "(cached) " >&6
66222 else
66223   case "$MSGFMT" in
66224   [\\/]* | ?:[\\/]*)
66225     ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
66226     ;;
66227   *)
66228     ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
66229     for ac_dir in $PATH; do
66230       IFS="$ac_save_IFS"
66231       test -z "$ac_dir" && ac_dir=.
66232       for ac_exec_ext in '' $ac_executable_extensions; do
66233         if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
66234           echo "$as_me: trying $ac_dir/$ac_word..." >&5
66235           if $ac_dir/$ac_word --statistics /dev/null >&5 2>&1 &&
66236      (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
66237             ac_cv_path_MSGFMT="$ac_dir/$ac_word$ac_exec_ext"
66238             break 2
66239           fi
66240         fi
66241       done
66242     done
66243     IFS="$ac_save_IFS"
66244   test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":"
66245     ;;
66246 esac
66247 fi
66248 MSGFMT="$ac_cv_path_MSGFMT"
66249 if test "$MSGFMT" != ":"; then
66250   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5
66251 $as_echo "$MSGFMT" >&6; }
66252 else
66253   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
66254 $as_echo "no" >&6; }
66255 fi
66256
66257   # Extract the first word of "gmsgfmt", so it can be a program name with args.
66258 set dummy gmsgfmt; ac_word=$2
66259 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
66260 $as_echo_n "checking for $ac_word... " >&6; }
66261 if ${ac_cv_path_GMSGFMT+:} false; then :
66262   $as_echo_n "(cached) " >&6
66263 else
66264   case $GMSGFMT in
66265   [\\/]* | ?:[\\/]*)
66266   ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
66267   ;;
66268   *)
66269   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
66270 for as_dir in $PATH
66271 do
66272   IFS=$as_save_IFS
66273   test -z "$as_dir" && as_dir=.
66274     for ac_exec_ext in '' $ac_executable_extensions; do
66275   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
66276     ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext"
66277     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
66278     break 2
66279   fi
66280 done
66281   done
66282 IFS=$as_save_IFS
66283
66284   test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
66285   ;;
66286 esac
66287 fi
66288 GMSGFMT=$ac_cv_path_GMSGFMT
66289 if test -n "$GMSGFMT"; then
66290   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GMSGFMT" >&5
66291 $as_echo "$GMSGFMT" >&6; }
66292 else
66293   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
66294 $as_echo "no" >&6; }
66295 fi
66296
66297
66298
66299     case `$MSGFMT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in
66300     '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) MSGFMT_015=: ;;
66301     *) MSGFMT_015=$MSGFMT ;;
66302   esac
66303
66304   case `$GMSGFMT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in
66305     '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) GMSGFMT_015=: ;;
66306     *) GMSGFMT_015=$GMSGFMT ;;
66307   esac
66308
66309
66310
66311 # Prepare PATH_SEPARATOR.
66312 # The user is always right.
66313 if test "${PATH_SEPARATOR+set}" != set; then
66314   echo "#! /bin/sh" >conf$$.sh
66315   echo  "exit 0"   >>conf$$.sh
66316   chmod +x conf$$.sh
66317   if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
66318     PATH_SEPARATOR=';'
66319   else
66320     PATH_SEPARATOR=:
66321   fi
66322   rm -f conf$$.sh
66323 fi
66324
66325 # Find out how to test for executable files. Don't use a zero-byte file,
66326 # as systems may use methods other than mode bits to determine executability.
66327 cat >conf$$.file <<_ASEOF
66328 #! /bin/sh
66329 exit 0
66330 _ASEOF
66331 chmod +x conf$$.file
66332 if test -x conf$$.file >/dev/null 2>&1; then
66333   ac_executable_p="test -x"
66334 else
66335   ac_executable_p="test -f"
66336 fi
66337 rm -f conf$$.file
66338
66339 # Extract the first word of "xgettext", so it can be a program name with args.
66340 set dummy xgettext; ac_word=$2
66341 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
66342 $as_echo_n "checking for $ac_word... " >&6; }
66343 if ${ac_cv_path_XGETTEXT+:} false; then :
66344   $as_echo_n "(cached) " >&6
66345 else
66346   case "$XGETTEXT" in
66347   [\\/]* | ?:[\\/]*)
66348     ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
66349     ;;
66350   *)
66351     ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
66352     for ac_dir in $PATH; do
66353       IFS="$ac_save_IFS"
66354       test -z "$ac_dir" && ac_dir=.
66355       for ac_exec_ext in '' $ac_executable_extensions; do
66356         if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
66357           echo "$as_me: trying $ac_dir/$ac_word..." >&5
66358           if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >&5 2>&1 &&
66359      (if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
66360             ac_cv_path_XGETTEXT="$ac_dir/$ac_word$ac_exec_ext"
66361             break 2
66362           fi
66363         fi
66364       done
66365     done
66366     IFS="$ac_save_IFS"
66367   test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
66368     ;;
66369 esac
66370 fi
66371 XGETTEXT="$ac_cv_path_XGETTEXT"
66372 if test "$XGETTEXT" != ":"; then
66373   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5
66374 $as_echo "$XGETTEXT" >&6; }
66375 else
66376   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
66377 $as_echo "no" >&6; }
66378 fi
66379
66380     rm -f messages.po
66381
66382     case `$XGETTEXT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in
66383     '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) XGETTEXT_015=: ;;
66384     *) XGETTEXT_015=$XGETTEXT ;;
66385   esac
66386
66387
66388
66389 # Prepare PATH_SEPARATOR.
66390 # The user is always right.
66391 if test "${PATH_SEPARATOR+set}" != set; then
66392   echo "#! /bin/sh" >conf$$.sh
66393   echo  "exit 0"   >>conf$$.sh
66394   chmod +x conf$$.sh
66395   if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
66396     PATH_SEPARATOR=';'
66397   else
66398     PATH_SEPARATOR=:
66399   fi
66400   rm -f conf$$.sh
66401 fi
66402
66403 # Find out how to test for executable files. Don't use a zero-byte file,
66404 # as systems may use methods other than mode bits to determine executability.
66405 cat >conf$$.file <<_ASEOF
66406 #! /bin/sh
66407 exit 0
66408 _ASEOF
66409 chmod +x conf$$.file
66410 if test -x conf$$.file >/dev/null 2>&1; then
66411   ac_executable_p="test -x"
66412 else
66413   ac_executable_p="test -f"
66414 fi
66415 rm -f conf$$.file
66416
66417 # Extract the first word of "msgmerge", so it can be a program name with args.
66418 set dummy msgmerge; ac_word=$2
66419 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
66420 $as_echo_n "checking for $ac_word... " >&6; }
66421 if ${ac_cv_path_MSGMERGE+:} false; then :
66422   $as_echo_n "(cached) " >&6
66423 else
66424   case "$MSGMERGE" in
66425   [\\/]* | ?:[\\/]*)
66426     ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path.
66427     ;;
66428   *)
66429     ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
66430     for ac_dir in $PATH; do
66431       IFS="$ac_save_IFS"
66432       test -z "$ac_dir" && ac_dir=.
66433       for ac_exec_ext in '' $ac_executable_extensions; do
66434         if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
66435           echo "$as_me: trying $ac_dir/$ac_word..." >&5
66436           if $ac_dir/$ac_word --update -q /dev/null /dev/null >&5 2>&1; then
66437             ac_cv_path_MSGMERGE="$ac_dir/$ac_word$ac_exec_ext"
66438             break 2
66439           fi
66440         fi
66441       done
66442     done
66443     IFS="$ac_save_IFS"
66444   test -z "$ac_cv_path_MSGMERGE" && ac_cv_path_MSGMERGE=":"
66445     ;;
66446 esac
66447 fi
66448 MSGMERGE="$ac_cv_path_MSGMERGE"
66449 if test "$MSGMERGE" != ":"; then
66450   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5
66451 $as_echo "$MSGMERGE" >&6; }
66452 else
66453   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
66454 $as_echo "no" >&6; }
66455 fi
66456
66457
66458         test -n "$localedir" || localedir='${datadir}/locale'
66459
66460
66461     test -n "${XGETTEXT_EXTRA_OPTIONS+set}" || XGETTEXT_EXTRA_OPTIONS=
66462
66463
66464   ac_config_commands="$ac_config_commands po-directories"
66465
66466
66467
66468
66469
66470
66471
66472
66473
66474
66475
66476
66477
66478     use_additional=yes
66479
66480   acl_save_prefix="$prefix"
66481   prefix="$acl_final_prefix"
66482   acl_save_exec_prefix="$exec_prefix"
66483   exec_prefix="$acl_final_exec_prefix"
66484
66485     eval additional_includedir=\"$includedir\"
66486     eval additional_libdir=\"$libdir\"
66487
66488   exec_prefix="$acl_save_exec_prefix"
66489   prefix="$acl_save_prefix"
66490
66491
66492 # Check whether --with-libiconv-prefix was given.
66493 if test "${with_libiconv_prefix+set}" = set; then :
66494   withval=$with_libiconv_prefix;
66495     if test "X$withval" = "Xno"; then
66496       use_additional=no
66497     else
66498       if test "X$withval" = "X"; then
66499
66500   acl_save_prefix="$prefix"
66501   prefix="$acl_final_prefix"
66502   acl_save_exec_prefix="$exec_prefix"
66503   exec_prefix="$acl_final_exec_prefix"
66504
66505           eval additional_includedir=\"$includedir\"
66506           eval additional_libdir=\"$libdir\"
66507
66508   exec_prefix="$acl_save_exec_prefix"
66509   prefix="$acl_save_prefix"
66510
66511       else
66512         additional_includedir="$withval/include"
66513         additional_libdir="$withval/$acl_libdirstem"
66514         if test "$acl_libdirstem2" != "$acl_libdirstem" \
66515            && ! test -d "$withval/$acl_libdirstem"; then
66516           additional_libdir="$withval/$acl_libdirstem2"
66517         fi
66518       fi
66519     fi
66520
66521 fi
66522
66523       LIBICONV=
66524   LTLIBICONV=
66525   INCICONV=
66526   LIBICONV_PREFIX=
66527       HAVE_LIBICONV=
66528   rpathdirs=
66529   ltrpathdirs=
66530   names_already_handled=
66531   names_next_round='iconv '
66532   while test -n "$names_next_round"; do
66533     names_this_round="$names_next_round"
66534     names_next_round=
66535     for name in $names_this_round; do
66536       already_handled=
66537       for n in $names_already_handled; do
66538         if test "$n" = "$name"; then
66539           already_handled=yes
66540           break
66541         fi
66542       done
66543       if test -z "$already_handled"; then
66544         names_already_handled="$names_already_handled $name"
66545                         uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./+-|ABCDEFGHIJKLMNOPQRSTUVWXYZ____|'`
66546         eval value=\"\$HAVE_LIB$uppername\"
66547         if test -n "$value"; then
66548           if test "$value" = yes; then
66549             eval value=\"\$LIB$uppername\"
66550             test -z "$value" || LIBICONV="${LIBICONV}${LIBICONV:+ }$value"
66551             eval value=\"\$LTLIB$uppername\"
66552             test -z "$value" || LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$value"
66553           else
66554                                     :
66555           fi
66556         else
66557                               found_dir=
66558           found_la=
66559           found_so=
66560           found_a=
66561           eval libname=\"$acl_libname_spec\"    # typically: libname=lib$name
66562           if test -n "$acl_shlibext"; then
66563             shrext=".$acl_shlibext"             # typically: shrext=.so
66564           else
66565             shrext=
66566           fi
66567           if test $use_additional = yes; then
66568             dir="$additional_libdir"
66569                                     if test -n "$acl_shlibext"; then
66570               if test -f "$dir/$libname$shrext"; then
66571                 found_dir="$dir"
66572                 found_so="$dir/$libname$shrext"
66573               else
66574                 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
66575                   ver=`(cd "$dir" && \
66576                         for f in "$libname$shrext".*; do echo "$f"; done \
66577                         | sed -e "s,^$libname$shrext\\\\.,," \
66578                         | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
66579                         | sed 1q ) 2>/dev/null`
66580                   if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then
66581                     found_dir="$dir"
66582                     found_so="$dir/$libname$shrext.$ver"
66583                   fi
66584                 else
66585                   eval library_names=\"$acl_library_names_spec\"
66586                   for f in $library_names; do
66587                     if test -f "$dir/$f"; then
66588                       found_dir="$dir"
66589                       found_so="$dir/$f"
66590                       break
66591                     fi
66592                   done
66593                 fi
66594               fi
66595             fi
66596                         if test "X$found_dir" = "X"; then
66597               if test -f "$dir/$libname.$acl_libext"; then
66598                 found_dir="$dir"
66599                 found_a="$dir/$libname.$acl_libext"
66600               fi
66601             fi
66602             if test "X$found_dir" != "X"; then
66603               if test -f "$dir/$libname.la"; then
66604                 found_la="$dir/$libname.la"
66605               fi
66606             fi
66607           fi
66608           if test "X$found_dir" = "X"; then
66609             for x in $LDFLAGS $LTLIBICONV; do
66610
66611   acl_save_prefix="$prefix"
66612   prefix="$acl_final_prefix"
66613   acl_save_exec_prefix="$exec_prefix"
66614   exec_prefix="$acl_final_exec_prefix"
66615   eval x=\"$x\"
66616   exec_prefix="$acl_save_exec_prefix"
66617   prefix="$acl_save_prefix"
66618
66619               case "$x" in
66620                 -L*)
66621                   dir=`echo "X$x" | sed -e 's/^X-L//'`
66622                                     if test -n "$acl_shlibext"; then
66623                     if test -f "$dir/$libname$shrext"; then
66624                       found_dir="$dir"
66625                       found_so="$dir/$libname$shrext"
66626                     else
66627                       if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
66628                         ver=`(cd "$dir" && \
66629                               for f in "$libname$shrext".*; do echo "$f"; done \
66630                               | sed -e "s,^$libname$shrext\\\\.,," \
66631                               | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
66632                               | sed 1q ) 2>/dev/null`
66633                         if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then
66634                           found_dir="$dir"
66635                           found_so="$dir/$libname$shrext.$ver"
66636                         fi
66637                       else
66638                         eval library_names=\"$acl_library_names_spec\"
66639                         for f in $library_names; do
66640                           if test -f "$dir/$f"; then
66641                             found_dir="$dir"
66642                             found_so="$dir/$f"
66643                             break
66644                           fi
66645                         done
66646                       fi
66647                     fi
66648                   fi
66649                                     if test "X$found_dir" = "X"; then
66650                     if test -f "$dir/$libname.$acl_libext"; then
66651                       found_dir="$dir"
66652                       found_a="$dir/$libname.$acl_libext"
66653                     fi
66654                   fi
66655                   if test "X$found_dir" != "X"; then
66656                     if test -f "$dir/$libname.la"; then
66657                       found_la="$dir/$libname.la"
66658                     fi
66659                   fi
66660                   ;;
66661               esac
66662               if test "X$found_dir" != "X"; then
66663                 break
66664               fi
66665             done
66666           fi
66667           if test "X$found_dir" != "X"; then
66668                         LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$found_dir -l$name"
66669             if test "X$found_so" != "X"; then
66670                                                         if test "$enable_rpath" = no \
66671                  || test "X$found_dir" = "X/usr/$acl_libdirstem" \
66672                  || test "X$found_dir" = "X/usr/$acl_libdirstem2"; then
66673                                 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
66674               else
66675                                                                                 haveit=
66676                 for x in $ltrpathdirs; do
66677                   if test "X$x" = "X$found_dir"; then
66678                     haveit=yes
66679                     break
66680                   fi
66681                 done
66682                 if test -z "$haveit"; then
66683                   ltrpathdirs="$ltrpathdirs $found_dir"
66684                 fi
66685                                 if test "$acl_hardcode_direct" = yes; then
66686                                                       LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
66687                 else
66688                   if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then
66689                                                             LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
66690                                                             haveit=
66691                     for x in $rpathdirs; do
66692                       if test "X$x" = "X$found_dir"; then
66693                         haveit=yes
66694                         break
66695                       fi
66696                     done
66697                     if test -z "$haveit"; then
66698                       rpathdirs="$rpathdirs $found_dir"
66699                     fi
66700                   else
66701                                                                                 haveit=
66702                     for x in $LDFLAGS $LIBICONV; do
66703
66704   acl_save_prefix="$prefix"
66705   prefix="$acl_final_prefix"
66706   acl_save_exec_prefix="$exec_prefix"
66707   exec_prefix="$acl_final_exec_prefix"
66708   eval x=\"$x\"
66709   exec_prefix="$acl_save_exec_prefix"
66710   prefix="$acl_save_prefix"
66711
66712                       if test "X$x" = "X-L$found_dir"; then
66713                         haveit=yes
66714                         break
66715                       fi
66716                     done
66717                     if test -z "$haveit"; then
66718                       LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir"
66719                     fi
66720                     if test "$acl_hardcode_minus_L" != no; then
66721                                                                                         LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
66722                     else
66723                                                                                                                                                                                 LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
66724                     fi
66725                   fi
66726                 fi
66727               fi
66728             else
66729               if test "X$found_a" != "X"; then
66730                                 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_a"
66731               else
66732                                                 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir -l$name"
66733               fi
66734             fi
66735                         additional_includedir=
66736             case "$found_dir" in
66737               */$acl_libdirstem | */$acl_libdirstem/)
66738                 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'`
66739                 if test "$name" = 'iconv'; then
66740                   LIBICONV_PREFIX="$basedir"
66741                 fi
66742                 additional_includedir="$basedir/include"
66743                 ;;
66744               */$acl_libdirstem2 | */$acl_libdirstem2/)
66745                 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem2/"'*$,,'`
66746                 if test "$name" = 'iconv'; then
66747                   LIBICONV_PREFIX="$basedir"
66748                 fi
66749                 additional_includedir="$basedir/include"
66750                 ;;
66751             esac
66752             if test "X$additional_includedir" != "X"; then
66753                                                                                                                 if test "X$additional_includedir" != "X/usr/include"; then
66754                 haveit=
66755                 if test "X$additional_includedir" = "X/usr/local/include"; then
66756                   if test -n "$GCC"; then
66757                     case $host_os in
66758                       linux* | gnu* | k*bsd*-gnu) haveit=yes;;
66759                     esac
66760                   fi
66761                 fi
66762                 if test -z "$haveit"; then
66763                   for x in $CPPFLAGS $INCICONV; do
66764
66765   acl_save_prefix="$prefix"
66766   prefix="$acl_final_prefix"
66767   acl_save_exec_prefix="$exec_prefix"
66768   exec_prefix="$acl_final_exec_prefix"
66769   eval x=\"$x\"
66770   exec_prefix="$acl_save_exec_prefix"
66771   prefix="$acl_save_prefix"
66772
66773                     if test "X$x" = "X-I$additional_includedir"; then
66774                       haveit=yes
66775                       break
66776                     fi
66777                   done
66778                   if test -z "$haveit"; then
66779                     if test -d "$additional_includedir"; then
66780                                             INCICONV="${INCICONV}${INCICONV:+ }-I$additional_includedir"
66781                     fi
66782                   fi
66783                 fi
66784               fi
66785             fi
66786                         if test -n "$found_la"; then
66787                                                         save_libdir="$libdir"
66788               case "$found_la" in
66789                 */* | *\\*) . "$found_la" ;;
66790                 *) . "./$found_la" ;;
66791               esac
66792               libdir="$save_libdir"
66793                             for dep in $dependency_libs; do
66794                 case "$dep" in
66795                   -L*)
66796                     additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
66797                                                                                                                                                                 if test "X$additional_libdir" != "X/usr/$acl_libdirstem" \
66798                        && test "X$additional_libdir" != "X/usr/$acl_libdirstem2"; then
66799                       haveit=
66800                       if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem" \
66801                          || test "X$additional_libdir" = "X/usr/local/$acl_libdirstem2"; then
66802                         if test -n "$GCC"; then
66803                           case $host_os in
66804                             linux* | gnu* | k*bsd*-gnu) haveit=yes;;
66805                           esac
66806                         fi
66807                       fi
66808                       if test -z "$haveit"; then
66809                         haveit=
66810                         for x in $LDFLAGS $LIBICONV; do
66811
66812   acl_save_prefix="$prefix"
66813   prefix="$acl_final_prefix"
66814   acl_save_exec_prefix="$exec_prefix"
66815   exec_prefix="$acl_final_exec_prefix"
66816   eval x=\"$x\"
66817   exec_prefix="$acl_save_exec_prefix"
66818   prefix="$acl_save_prefix"
66819
66820                           if test "X$x" = "X-L$additional_libdir"; then
66821                             haveit=yes
66822                             break
66823                           fi
66824                         done
66825                         if test -z "$haveit"; then
66826                           if test -d "$additional_libdir"; then
66827                                                         LIBICONV="${LIBICONV}${LIBICONV:+ }-L$additional_libdir"
66828                           fi
66829                         fi
66830                         haveit=
66831                         for x in $LDFLAGS $LTLIBICONV; do
66832
66833   acl_save_prefix="$prefix"
66834   prefix="$acl_final_prefix"
66835   acl_save_exec_prefix="$exec_prefix"
66836   exec_prefix="$acl_final_exec_prefix"
66837   eval x=\"$x\"
66838   exec_prefix="$acl_save_exec_prefix"
66839   prefix="$acl_save_prefix"
66840
66841                           if test "X$x" = "X-L$additional_libdir"; then
66842                             haveit=yes
66843                             break
66844                           fi
66845                         done
66846                         if test -z "$haveit"; then
66847                           if test -d "$additional_libdir"; then
66848                                                         LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$additional_libdir"
66849                           fi
66850                         fi
66851                       fi
66852                     fi
66853                     ;;
66854                   -R*)
66855                     dir=`echo "X$dep" | sed -e 's/^X-R//'`
66856                     if test "$enable_rpath" != no; then
66857                                                                   haveit=
66858                       for x in $rpathdirs; do
66859                         if test "X$x" = "X$dir"; then
66860                           haveit=yes
66861                           break
66862                         fi
66863                       done
66864                       if test -z "$haveit"; then
66865                         rpathdirs="$rpathdirs $dir"
66866                       fi
66867                                                                   haveit=
66868                       for x in $ltrpathdirs; do
66869                         if test "X$x" = "X$dir"; then
66870                           haveit=yes
66871                           break
66872                         fi
66873                       done
66874                       if test -z "$haveit"; then
66875                         ltrpathdirs="$ltrpathdirs $dir"
66876                       fi
66877                     fi
66878                     ;;
66879                   -l*)
66880                                         names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
66881                     ;;
66882                   *.la)
66883                                                                                 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
66884                     ;;
66885                   *)
66886                                         LIBICONV="${LIBICONV}${LIBICONV:+ }$dep"
66887                     LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$dep"
66888                     ;;
66889                 esac
66890               done
66891             fi
66892           else
66893                                                             LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
66894             LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l$name"
66895           fi
66896         fi
66897       fi
66898     done
66899   done
66900   if test "X$rpathdirs" != "X"; then
66901     if test -n "$acl_hardcode_libdir_separator"; then
66902                         alldirs=
66903       for found_dir in $rpathdirs; do
66904         alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$found_dir"
66905       done
66906             acl_save_libdir="$libdir"
66907       libdir="$alldirs"
66908       eval flag=\"$acl_hardcode_libdir_flag_spec\"
66909       libdir="$acl_save_libdir"
66910       LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
66911     else
66912             for found_dir in $rpathdirs; do
66913         acl_save_libdir="$libdir"
66914         libdir="$found_dir"
66915         eval flag=\"$acl_hardcode_libdir_flag_spec\"
66916         libdir="$acl_save_libdir"
66917         LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
66918       done
66919     fi
66920   fi
66921   if test "X$ltrpathdirs" != "X"; then
66922             for found_dir in $ltrpathdirs; do
66923       LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-R$found_dir"
66924     done
66925   fi
66926
66927
66928
66929
66930
66931
66932
66933
66934
66935
66936
66937
66938
66939
66940
66941
66942
66943
66944
66945
66946
66947
66948
66949
66950
66951
66952
66953
66954
66955
66956     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFPreferencesCopyAppValue" >&5
66957 $as_echo_n "checking for CFPreferencesCopyAppValue... " >&6; }
66958 if ${gt_cv_func_CFPreferencesCopyAppValue+:} false; then :
66959   $as_echo_n "(cached) " >&6
66960 else
66961   gt_save_LIBS="$LIBS"
66962      LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
66963      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
66964 /* end confdefs.h.  */
66965 #include <CoreFoundation/CFPreferences.h>
66966 int
66967 main ()
66968 {
66969 CFPreferencesCopyAppValue(NULL, NULL)
66970   ;
66971   return 0;
66972 }
66973 _ACEOF
66974 if ac_fn_c_try_link "$LINENO"; then :
66975   gt_cv_func_CFPreferencesCopyAppValue=yes
66976 else
66977   gt_cv_func_CFPreferencesCopyAppValue=no
66978 fi
66979 rm -f core conftest.err conftest.$ac_objext \
66980     conftest$ac_exeext conftest.$ac_ext
66981      LIBS="$gt_save_LIBS"
66982 fi
66983 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFPreferencesCopyAppValue" >&5
66984 $as_echo "$gt_cv_func_CFPreferencesCopyAppValue" >&6; }
66985   if test $gt_cv_func_CFPreferencesCopyAppValue = yes; then
66986
66987 $as_echo "#define HAVE_CFPREFERENCESCOPYAPPVALUE 1" >>confdefs.h
66988
66989   fi
66990     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFLocaleCopyCurrent" >&5
66991 $as_echo_n "checking for CFLocaleCopyCurrent... " >&6; }
66992 if ${gt_cv_func_CFLocaleCopyCurrent+:} false; then :
66993   $as_echo_n "(cached) " >&6
66994 else
66995   gt_save_LIBS="$LIBS"
66996      LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
66997      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
66998 /* end confdefs.h.  */
66999 #include <CoreFoundation/CFLocale.h>
67000 int
67001 main ()
67002 {
67003 CFLocaleCopyCurrent();
67004   ;
67005   return 0;
67006 }
67007 _ACEOF
67008 if ac_fn_c_try_link "$LINENO"; then :
67009   gt_cv_func_CFLocaleCopyCurrent=yes
67010 else
67011   gt_cv_func_CFLocaleCopyCurrent=no
67012 fi
67013 rm -f core conftest.err conftest.$ac_objext \
67014     conftest$ac_exeext conftest.$ac_ext
67015      LIBS="$gt_save_LIBS"
67016 fi
67017 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFLocaleCopyCurrent" >&5
67018 $as_echo "$gt_cv_func_CFLocaleCopyCurrent" >&6; }
67019   if test $gt_cv_func_CFLocaleCopyCurrent = yes; then
67020
67021 $as_echo "#define HAVE_CFLOCALECOPYCURRENT 1" >>confdefs.h
67022
67023   fi
67024   INTL_MACOSX_LIBS=
67025   if test $gt_cv_func_CFPreferencesCopyAppValue = yes || test $gt_cv_func_CFLocaleCopyCurrent = yes; then
67026     INTL_MACOSX_LIBS="-Wl,-framework -Wl,CoreFoundation"
67027   fi
67028
67029
67030
67031
67032
67033
67034   LIBINTL=
67035   LTLIBINTL=
67036   POSUB=
67037
67038     case " $gt_needs " in
67039     *" need-formatstring-macros "*) gt_api_version=3 ;;
67040     *" need-ngettext "*) gt_api_version=2 ;;
67041     *) gt_api_version=1 ;;
67042   esac
67043   gt_func_gnugettext_libc="gt_cv_func_gnugettext${gt_api_version}_libc"
67044   gt_func_gnugettext_libintl="gt_cv_func_gnugettext${gt_api_version}_libintl"
67045
67046     if test "$USE_NLS" = "yes"; then
67047     gt_use_preinstalled_gnugettext=no
67048
67049
67050         if test $gt_api_version -ge 3; then
67051           gt_revision_test_code='
67052 #ifndef __GNU_GETTEXT_SUPPORTED_REVISION
67053 #define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1)
67054 #endif
67055 typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1];
67056 '
67057         else
67058           gt_revision_test_code=
67059         fi
67060         if test $gt_api_version -ge 2; then
67061           gt_expression_test_code=' + * ngettext ("", "", 0)'
67062         else
67063           gt_expression_test_code=
67064         fi
67065
67066         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libc" >&5
67067 $as_echo_n "checking for GNU gettext in libc... " >&6; }
67068 if eval \${$gt_func_gnugettext_libc+:} false; then :
67069   $as_echo_n "(cached) " >&6
67070 else
67071   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
67072 /* end confdefs.h.  */
67073 #include <libintl.h>
67074 $gt_revision_test_code
67075 extern int _nl_msg_cat_cntr;
67076 extern int *_nl_domain_bindings;
67077 int
67078 main ()
67079 {
67080 bindtextdomain ("", "");
67081 return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_domain_bindings
67082   ;
67083   return 0;
67084 }
67085 _ACEOF
67086 if ac_fn_c_try_link "$LINENO"; then :
67087   eval "$gt_func_gnugettext_libc=yes"
67088 else
67089   eval "$gt_func_gnugettext_libc=no"
67090 fi
67091 rm -f core conftest.err conftest.$ac_objext \
67092     conftest$ac_exeext conftest.$ac_ext
67093 fi
67094 eval ac_res=\$$gt_func_gnugettext_libc
67095                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
67096 $as_echo "$ac_res" >&6; }
67097
67098         if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" != "yes"; }; then
67099
67100
67101
67102
67103
67104           am_save_CPPFLAGS="$CPPFLAGS"
67105
67106   for element in $INCICONV; do
67107     haveit=
67108     for x in $CPPFLAGS; do
67109
67110   acl_save_prefix="$prefix"
67111   prefix="$acl_final_prefix"
67112   acl_save_exec_prefix="$exec_prefix"
67113   exec_prefix="$acl_final_exec_prefix"
67114   eval x=\"$x\"
67115   exec_prefix="$acl_save_exec_prefix"
67116   prefix="$acl_save_prefix"
67117
67118       if test "X$x" = "X$element"; then
67119         haveit=yes
67120         break
67121       fi
67122     done
67123     if test -z "$haveit"; then
67124       CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
67125     fi
67126   done
67127
67128
67129   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5
67130 $as_echo_n "checking for iconv... " >&6; }
67131 if ${am_cv_func_iconv+:} false; then :
67132   $as_echo_n "(cached) " >&6
67133 else
67134
67135     am_cv_func_iconv="no, consider installing GNU libiconv"
67136     am_cv_lib_iconv=no
67137     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
67138 /* end confdefs.h.  */
67139 #include <stdlib.h>
67140 #include <iconv.h>
67141 int
67142 main ()
67143 {
67144 iconv_t cd = iconv_open("","");
67145        iconv(cd,NULL,NULL,NULL,NULL);
67146        iconv_close(cd);
67147   ;
67148   return 0;
67149 }
67150 _ACEOF
67151 if ac_fn_c_try_link "$LINENO"; then :
67152   am_cv_func_iconv=yes
67153 fi
67154 rm -f core conftest.err conftest.$ac_objext \
67155     conftest$ac_exeext conftest.$ac_ext
67156     if test "$am_cv_func_iconv" != yes; then
67157       am_save_LIBS="$LIBS"
67158       LIBS="$LIBS $LIBICONV"
67159       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
67160 /* end confdefs.h.  */
67161 #include <stdlib.h>
67162 #include <iconv.h>
67163 int
67164 main ()
67165 {
67166 iconv_t cd = iconv_open("","");
67167          iconv(cd,NULL,NULL,NULL,NULL);
67168          iconv_close(cd);
67169   ;
67170   return 0;
67171 }
67172 _ACEOF
67173 if ac_fn_c_try_link "$LINENO"; then :
67174   am_cv_lib_iconv=yes
67175         am_cv_func_iconv=yes
67176 fi
67177 rm -f core conftest.err conftest.$ac_objext \
67178     conftest$ac_exeext conftest.$ac_ext
67179       LIBS="$am_save_LIBS"
67180     fi
67181
67182 fi
67183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5
67184 $as_echo "$am_cv_func_iconv" >&6; }
67185   if test "$am_cv_func_iconv" = yes; then
67186     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working iconv" >&5
67187 $as_echo_n "checking for working iconv... " >&6; }
67188 if ${am_cv_func_iconv_works+:} false; then :
67189   $as_echo_n "(cached) " >&6
67190 else
67191
67192             am_save_LIBS="$LIBS"
67193       if test $am_cv_lib_iconv = yes; then
67194         LIBS="$LIBS $LIBICONV"
67195       fi
67196       if test "$cross_compiling" = yes; then :
67197   case "$host_os" in
67198            aix* | hpux*) am_cv_func_iconv_works="guessing no" ;;
67199            *)            am_cv_func_iconv_works="guessing yes" ;;
67200          esac
67201 else
67202   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
67203 /* end confdefs.h.  */
67204
67205 #include <iconv.h>
67206 #include <string.h>
67207 int main ()
67208 {
67209   /* Test against AIX 5.1 bug: Failures are not distinguishable from successful
67210      returns.  */
67211   {
67212     iconv_t cd_utf8_to_88591 = iconv_open ("ISO8859-1", "UTF-8");
67213     if (cd_utf8_to_88591 != (iconv_t)(-1))
67214       {
67215         static const char input[] = "\342\202\254"; /* EURO SIGN */
67216         char buf[10];
67217         const char *inptr = input;
67218         size_t inbytesleft = strlen (input);
67219         char *outptr = buf;
67220         size_t outbytesleft = sizeof (buf);
67221         size_t res = iconv (cd_utf8_to_88591,
67222                             (char **) &inptr, &inbytesleft,
67223                             &outptr, &outbytesleft);
67224         if (res == 0)
67225           return 1;
67226       }
67227   }
67228 #if 0 /* This bug could be worked around by the caller.  */
67229   /* Test against HP-UX 11.11 bug: Positive return value instead of 0.  */
67230   {
67231     iconv_t cd_88591_to_utf8 = iconv_open ("utf8", "iso88591");
67232     if (cd_88591_to_utf8 != (iconv_t)(-1))
67233       {
67234         static const char input[] = "\304rger mit b\366sen B\374bchen ohne Augenma\337";
67235         char buf[50];
67236         const char *inptr = input;
67237         size_t inbytesleft = strlen (input);
67238         char *outptr = buf;
67239         size_t outbytesleft = sizeof (buf);
67240         size_t res = iconv (cd_88591_to_utf8,
67241                             (char **) &inptr, &inbytesleft,
67242                             &outptr, &outbytesleft);
67243         if ((int)res > 0)
67244           return 1;
67245       }
67246   }
67247 #endif
67248   /* Test against HP-UX 11.11 bug: No converter from EUC-JP to UTF-8 is
67249      provided.  */
67250   if (/* Try standardized names.  */
67251       iconv_open ("UTF-8", "EUC-JP") == (iconv_t)(-1)
67252       /* Try IRIX, OSF/1 names.  */
67253       && iconv_open ("UTF-8", "eucJP") == (iconv_t)(-1)
67254       /* Try AIX names.  */
67255       && iconv_open ("UTF-8", "IBM-eucJP") == (iconv_t)(-1)
67256       /* Try HP-UX names.  */
67257       && iconv_open ("utf8", "eucJP") == (iconv_t)(-1))
67258     return 1;
67259   return 0;
67260 }
67261 _ACEOF
67262 if ac_fn_c_try_run "$LINENO"; then :
67263   am_cv_func_iconv_works=yes
67264 else
67265   am_cv_func_iconv_works=no
67266 fi
67267 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
67268   conftest.$ac_objext conftest.beam conftest.$ac_ext
67269 fi
67270
67271       LIBS="$am_save_LIBS"
67272
67273 fi
67274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv_works" >&5
67275 $as_echo "$am_cv_func_iconv_works" >&6; }
67276     case "$am_cv_func_iconv_works" in
67277       *no) am_func_iconv=no am_cv_lib_iconv=no ;;
67278       *)   am_func_iconv=yes ;;
67279     esac
67280   else
67281     am_func_iconv=no am_cv_lib_iconv=no
67282   fi
67283   if test "$am_func_iconv" = yes; then
67284
67285 $as_echo "#define HAVE_ICONV 1" >>confdefs.h
67286
67287   fi
67288   if test "$am_cv_lib_iconv" = yes; then
67289     { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libiconv" >&5
67290 $as_echo_n "checking how to link with libiconv... " >&6; }
67291     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBICONV" >&5
67292 $as_echo "$LIBICONV" >&6; }
67293   else
67294             CPPFLAGS="$am_save_CPPFLAGS"
67295     LIBICONV=
67296     LTLIBICONV=
67297   fi
67298
67299
67300
67301
67302
67303
67304
67305
67306
67307
67308
67309     use_additional=yes
67310
67311   acl_save_prefix="$prefix"
67312   prefix="$acl_final_prefix"
67313   acl_save_exec_prefix="$exec_prefix"
67314   exec_prefix="$acl_final_exec_prefix"
67315
67316     eval additional_includedir=\"$includedir\"
67317     eval additional_libdir=\"$libdir\"
67318
67319   exec_prefix="$acl_save_exec_prefix"
67320   prefix="$acl_save_prefix"
67321
67322
67323 # Check whether --with-libintl-prefix was given.
67324 if test "${with_libintl_prefix+set}" = set; then :
67325   withval=$with_libintl_prefix;
67326     if test "X$withval" = "Xno"; then
67327       use_additional=no
67328     else
67329       if test "X$withval" = "X"; then
67330
67331   acl_save_prefix="$prefix"
67332   prefix="$acl_final_prefix"
67333   acl_save_exec_prefix="$exec_prefix"
67334   exec_prefix="$acl_final_exec_prefix"
67335
67336           eval additional_includedir=\"$includedir\"
67337           eval additional_libdir=\"$libdir\"
67338
67339   exec_prefix="$acl_save_exec_prefix"
67340   prefix="$acl_save_prefix"
67341
67342       else
67343         additional_includedir="$withval/include"
67344         additional_libdir="$withval/$acl_libdirstem"
67345         if test "$acl_libdirstem2" != "$acl_libdirstem" \
67346            && ! test -d "$withval/$acl_libdirstem"; then
67347           additional_libdir="$withval/$acl_libdirstem2"
67348         fi
67349       fi
67350     fi
67351
67352 fi
67353
67354       LIBINTL=
67355   LTLIBINTL=
67356   INCINTL=
67357   LIBINTL_PREFIX=
67358       HAVE_LIBINTL=
67359   rpathdirs=
67360   ltrpathdirs=
67361   names_already_handled=
67362   names_next_round='intl '
67363   while test -n "$names_next_round"; do
67364     names_this_round="$names_next_round"
67365     names_next_round=
67366     for name in $names_this_round; do
67367       already_handled=
67368       for n in $names_already_handled; do
67369         if test "$n" = "$name"; then
67370           already_handled=yes
67371           break
67372         fi
67373       done
67374       if test -z "$already_handled"; then
67375         names_already_handled="$names_already_handled $name"
67376                         uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./+-|ABCDEFGHIJKLMNOPQRSTUVWXYZ____|'`
67377         eval value=\"\$HAVE_LIB$uppername\"
67378         if test -n "$value"; then
67379           if test "$value" = yes; then
67380             eval value=\"\$LIB$uppername\"
67381             test -z "$value" || LIBINTL="${LIBINTL}${LIBINTL:+ }$value"
67382             eval value=\"\$LTLIB$uppername\"
67383             test -z "$value" || LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$value"
67384           else
67385                                     :
67386           fi
67387         else
67388                               found_dir=
67389           found_la=
67390           found_so=
67391           found_a=
67392           eval libname=\"$acl_libname_spec\"    # typically: libname=lib$name
67393           if test -n "$acl_shlibext"; then
67394             shrext=".$acl_shlibext"             # typically: shrext=.so
67395           else
67396             shrext=
67397           fi
67398           if test $use_additional = yes; then
67399             dir="$additional_libdir"
67400                                     if test -n "$acl_shlibext"; then
67401               if test -f "$dir/$libname$shrext"; then
67402                 found_dir="$dir"
67403                 found_so="$dir/$libname$shrext"
67404               else
67405                 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
67406                   ver=`(cd "$dir" && \
67407                         for f in "$libname$shrext".*; do echo "$f"; done \
67408                         | sed -e "s,^$libname$shrext\\\\.,," \
67409                         | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
67410                         | sed 1q ) 2>/dev/null`
67411                   if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then
67412                     found_dir="$dir"
67413                     found_so="$dir/$libname$shrext.$ver"
67414                   fi
67415                 else
67416                   eval library_names=\"$acl_library_names_spec\"
67417                   for f in $library_names; do
67418                     if test -f "$dir/$f"; then
67419                       found_dir="$dir"
67420                       found_so="$dir/$f"
67421                       break
67422                     fi
67423                   done
67424                 fi
67425               fi
67426             fi
67427                         if test "X$found_dir" = "X"; then
67428               if test -f "$dir/$libname.$acl_libext"; then
67429                 found_dir="$dir"
67430                 found_a="$dir/$libname.$acl_libext"
67431               fi
67432             fi
67433             if test "X$found_dir" != "X"; then
67434               if test -f "$dir/$libname.la"; then
67435                 found_la="$dir/$libname.la"
67436               fi
67437             fi
67438           fi
67439           if test "X$found_dir" = "X"; then
67440             for x in $LDFLAGS $LTLIBINTL; do
67441
67442   acl_save_prefix="$prefix"
67443   prefix="$acl_final_prefix"
67444   acl_save_exec_prefix="$exec_prefix"
67445   exec_prefix="$acl_final_exec_prefix"
67446   eval x=\"$x\"
67447   exec_prefix="$acl_save_exec_prefix"
67448   prefix="$acl_save_prefix"
67449
67450               case "$x" in
67451                 -L*)
67452                   dir=`echo "X$x" | sed -e 's/^X-L//'`
67453                                     if test -n "$acl_shlibext"; then
67454                     if test -f "$dir/$libname$shrext"; then
67455                       found_dir="$dir"
67456                       found_so="$dir/$libname$shrext"
67457                     else
67458                       if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
67459                         ver=`(cd "$dir" && \
67460                               for f in "$libname$shrext".*; do echo "$f"; done \
67461                               | sed -e "s,^$libname$shrext\\\\.,," \
67462                               | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
67463                               | sed 1q ) 2>/dev/null`
67464                         if test -n "$ver" && test -f "$dir/$libname$shrext.$ver"; then
67465                           found_dir="$dir"
67466                           found_so="$dir/$libname$shrext.$ver"
67467                         fi
67468                       else
67469                         eval library_names=\"$acl_library_names_spec\"
67470                         for f in $library_names; do
67471                           if test -f "$dir/$f"; then
67472                             found_dir="$dir"
67473                             found_so="$dir/$f"
67474                             break
67475                           fi
67476                         done
67477                       fi
67478                     fi
67479                   fi
67480                                     if test "X$found_dir" = "X"; then
67481                     if test -f "$dir/$libname.$acl_libext"; then
67482                       found_dir="$dir"
67483                       found_a="$dir/$libname.$acl_libext"
67484                     fi
67485                   fi
67486                   if test "X$found_dir" != "X"; then
67487                     if test -f "$dir/$libname.la"; then
67488                       found_la="$dir/$libname.la"
67489                     fi
67490                   fi
67491                   ;;
67492               esac
67493               if test "X$found_dir" != "X"; then
67494                 break
67495               fi
67496             done
67497           fi
67498           if test "X$found_dir" != "X"; then
67499                         LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$found_dir -l$name"
67500             if test "X$found_so" != "X"; then
67501                                                         if test "$enable_rpath" = no \
67502                  || test "X$found_dir" = "X/usr/$acl_libdirstem" \
67503                  || test "X$found_dir" = "X/usr/$acl_libdirstem2"; then
67504                                 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
67505               else
67506                                                                                 haveit=
67507                 for x in $ltrpathdirs; do
67508                   if test "X$x" = "X$found_dir"; then
67509                     haveit=yes
67510                     break
67511                   fi
67512                 done
67513                 if test -z "$haveit"; then
67514                   ltrpathdirs="$ltrpathdirs $found_dir"
67515                 fi
67516                                 if test "$acl_hardcode_direct" = yes; then
67517                                                       LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
67518                 else
67519                   if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then
67520                                                             LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
67521                                                             haveit=
67522                     for x in $rpathdirs; do
67523                       if test "X$x" = "X$found_dir"; then
67524                         haveit=yes
67525                         break
67526                       fi
67527                     done
67528                     if test -z "$haveit"; then
67529                       rpathdirs="$rpathdirs $found_dir"
67530                     fi
67531                   else
67532                                                                                 haveit=
67533                     for x in $LDFLAGS $LIBINTL; do
67534
67535   acl_save_prefix="$prefix"
67536   prefix="$acl_final_prefix"
67537   acl_save_exec_prefix="$exec_prefix"
67538   exec_prefix="$acl_final_exec_prefix"
67539   eval x=\"$x\"
67540   exec_prefix="$acl_save_exec_prefix"
67541   prefix="$acl_save_prefix"
67542
67543                       if test "X$x" = "X-L$found_dir"; then
67544                         haveit=yes
67545                         break
67546                       fi
67547                     done
67548                     if test -z "$haveit"; then
67549                       LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir"
67550                     fi
67551                     if test "$acl_hardcode_minus_L" != no; then
67552                                                                                         LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
67553                     else
67554                                                                                                                                                                                 LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
67555                     fi
67556                   fi
67557                 fi
67558               fi
67559             else
67560               if test "X$found_a" != "X"; then
67561                                 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_a"
67562               else
67563                                                 LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir -l$name"
67564               fi
67565             fi
67566                         additional_includedir=
67567             case "$found_dir" in
67568               */$acl_libdirstem | */$acl_libdirstem/)
67569                 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'`
67570                 if test "$name" = 'intl'; then
67571                   LIBINTL_PREFIX="$basedir"
67572                 fi
67573                 additional_includedir="$basedir/include"
67574                 ;;
67575               */$acl_libdirstem2 | */$acl_libdirstem2/)
67576                 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem2/"'*$,,'`
67577                 if test "$name" = 'intl'; then
67578                   LIBINTL_PREFIX="$basedir"
67579                 fi
67580                 additional_includedir="$basedir/include"
67581                 ;;
67582             esac
67583             if test "X$additional_includedir" != "X"; then
67584                                                                                                                 if test "X$additional_includedir" != "X/usr/include"; then
67585                 haveit=
67586                 if test "X$additional_includedir" = "X/usr/local/include"; then
67587                   if test -n "$GCC"; then
67588                     case $host_os in
67589                       linux* | gnu* | k*bsd*-gnu) haveit=yes;;
67590                     esac
67591                   fi
67592                 fi
67593                 if test -z "$haveit"; then
67594                   for x in $CPPFLAGS $INCINTL; do
67595
67596   acl_save_prefix="$prefix"
67597   prefix="$acl_final_prefix"
67598   acl_save_exec_prefix="$exec_prefix"
67599   exec_prefix="$acl_final_exec_prefix"
67600   eval x=\"$x\"
67601   exec_prefix="$acl_save_exec_prefix"
67602   prefix="$acl_save_prefix"
67603
67604                     if test "X$x" = "X-I$additional_includedir"; then
67605                       haveit=yes
67606                       break
67607                     fi
67608                   done
67609                   if test -z "$haveit"; then
67610                     if test -d "$additional_includedir"; then
67611                                             INCINTL="${INCINTL}${INCINTL:+ }-I$additional_includedir"
67612                     fi
67613                   fi
67614                 fi
67615               fi
67616             fi
67617                         if test -n "$found_la"; then
67618                                                         save_libdir="$libdir"
67619               case "$found_la" in
67620                 */* | *\\*) . "$found_la" ;;
67621                 *) . "./$found_la" ;;
67622               esac
67623               libdir="$save_libdir"
67624                             for dep in $dependency_libs; do
67625                 case "$dep" in
67626                   -L*)
67627                     additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
67628                                                                                                                                                                 if test "X$additional_libdir" != "X/usr/$acl_libdirstem" \
67629                        && test "X$additional_libdir" != "X/usr/$acl_libdirstem2"; then
67630                       haveit=
67631                       if test "X$additional_libdir" = "X/usr/local/$acl_libdirstem" \
67632                          || test "X$additional_libdir" = "X/usr/local/$acl_libdirstem2"; then
67633                         if test -n "$GCC"; then
67634                           case $host_os in
67635                             linux* | gnu* | k*bsd*-gnu) haveit=yes;;
67636                           esac
67637                         fi
67638                       fi
67639                       if test -z "$haveit"; then
67640                         haveit=
67641                         for x in $LDFLAGS $LIBINTL; do
67642
67643   acl_save_prefix="$prefix"
67644   prefix="$acl_final_prefix"
67645   acl_save_exec_prefix="$exec_prefix"
67646   exec_prefix="$acl_final_exec_prefix"
67647   eval x=\"$x\"
67648   exec_prefix="$acl_save_exec_prefix"
67649   prefix="$acl_save_prefix"
67650
67651                           if test "X$x" = "X-L$additional_libdir"; then
67652                             haveit=yes
67653                             break
67654                           fi
67655                         done
67656                         if test -z "$haveit"; then
67657                           if test -d "$additional_libdir"; then
67658                                                         LIBINTL="${LIBINTL}${LIBINTL:+ }-L$additional_libdir"
67659                           fi
67660                         fi
67661                         haveit=
67662                         for x in $LDFLAGS $LTLIBINTL; do
67663
67664   acl_save_prefix="$prefix"
67665   prefix="$acl_final_prefix"
67666   acl_save_exec_prefix="$exec_prefix"
67667   exec_prefix="$acl_final_exec_prefix"
67668   eval x=\"$x\"
67669   exec_prefix="$acl_save_exec_prefix"
67670   prefix="$acl_save_prefix"
67671
67672                           if test "X$x" = "X-L$additional_libdir"; then
67673                             haveit=yes
67674                             break
67675                           fi
67676                         done
67677                         if test -z "$haveit"; then
67678                           if test -d "$additional_libdir"; then
67679                                                         LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$additional_libdir"
67680                           fi
67681                         fi
67682                       fi
67683                     fi
67684                     ;;
67685                   -R*)
67686                     dir=`echo "X$dep" | sed -e 's/^X-R//'`
67687                     if test "$enable_rpath" != no; then
67688                                                                   haveit=
67689                       for x in $rpathdirs; do
67690                         if test "X$x" = "X$dir"; then
67691                           haveit=yes
67692                           break
67693                         fi
67694                       done
67695                       if test -z "$haveit"; then
67696                         rpathdirs="$rpathdirs $dir"
67697                       fi
67698                                                                   haveit=
67699                       for x in $ltrpathdirs; do
67700                         if test "X$x" = "X$dir"; then
67701                           haveit=yes
67702                           break
67703                         fi
67704                       done
67705                       if test -z "$haveit"; then
67706                         ltrpathdirs="$ltrpathdirs $dir"
67707                       fi
67708                     fi
67709                     ;;
67710                   -l*)
67711                                         names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
67712                     ;;
67713                   *.la)
67714                                                                                 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
67715                     ;;
67716                   *)
67717                                         LIBINTL="${LIBINTL}${LIBINTL:+ }$dep"
67718                     LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$dep"
67719                     ;;
67720                 esac
67721               done
67722             fi
67723           else
67724                                                             LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
67725             LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l$name"
67726           fi
67727         fi
67728       fi
67729     done
67730   done
67731   if test "X$rpathdirs" != "X"; then
67732     if test -n "$acl_hardcode_libdir_separator"; then
67733                         alldirs=
67734       for found_dir in $rpathdirs; do
67735         alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$found_dir"
67736       done
67737             acl_save_libdir="$libdir"
67738       libdir="$alldirs"
67739       eval flag=\"$acl_hardcode_libdir_flag_spec\"
67740       libdir="$acl_save_libdir"
67741       LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
67742     else
67743             for found_dir in $rpathdirs; do
67744         acl_save_libdir="$libdir"
67745         libdir="$found_dir"
67746         eval flag=\"$acl_hardcode_libdir_flag_spec\"
67747         libdir="$acl_save_libdir"
67748         LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
67749       done
67750     fi
67751   fi
67752   if test "X$ltrpathdirs" != "X"; then
67753             for found_dir in $ltrpathdirs; do
67754       LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-R$found_dir"
67755     done
67756   fi
67757
67758
67759
67760
67761
67762
67763           { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libintl" >&5
67764 $as_echo_n "checking for GNU gettext in libintl... " >&6; }
67765 if eval \${$gt_func_gnugettext_libintl+:} false; then :
67766   $as_echo_n "(cached) " >&6
67767 else
67768   gt_save_CPPFLAGS="$CPPFLAGS"
67769             CPPFLAGS="$CPPFLAGS $INCINTL"
67770             gt_save_LIBS="$LIBS"
67771             LIBS="$LIBS $LIBINTL"
67772                         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
67773 /* end confdefs.h.  */
67774 #include <libintl.h>
67775 $gt_revision_test_code
67776 extern int _nl_msg_cat_cntr;
67777 extern
67778 #ifdef __cplusplus
67779 "C"
67780 #endif
67781 const char *_nl_expand_alias (const char *);
67782 int
67783 main ()
67784 {
67785 bindtextdomain ("", "");
67786 return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_expand_alias ("")
67787   ;
67788   return 0;
67789 }
67790 _ACEOF
67791 if ac_fn_c_try_link "$LINENO"; then :
67792   eval "$gt_func_gnugettext_libintl=yes"
67793 else
67794   eval "$gt_func_gnugettext_libintl=no"
67795 fi
67796 rm -f core conftest.err conftest.$ac_objext \
67797     conftest$ac_exeext conftest.$ac_ext
67798                         if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" != yes; } && test -n "$LIBICONV"; then
67799               LIBS="$LIBS $LIBICONV"
67800               cat confdefs.h - <<_ACEOF >conftest.$ac_ext
67801 /* end confdefs.h.  */
67802 #include <libintl.h>
67803 $gt_revision_test_code
67804 extern int _nl_msg_cat_cntr;
67805 extern
67806 #ifdef __cplusplus
67807 "C"
67808 #endif
67809 const char *_nl_expand_alias (const char *);
67810 int
67811 main ()
67812 {
67813 bindtextdomain ("", "");
67814 return * gettext ("")$gt_expression_test_code + _nl_msg_cat_cntr + *_nl_expand_alias ("")
67815   ;
67816   return 0;
67817 }
67818 _ACEOF
67819 if ac_fn_c_try_link "$LINENO"; then :
67820   LIBINTL="$LIBINTL $LIBICONV"
67821                 LTLIBINTL="$LTLIBINTL $LTLIBICONV"
67822                 eval "$gt_func_gnugettext_libintl=yes"
67823
67824 fi
67825 rm -f core conftest.err conftest.$ac_objext \
67826     conftest$ac_exeext conftest.$ac_ext
67827             fi
67828             CPPFLAGS="$gt_save_CPPFLAGS"
67829             LIBS="$gt_save_LIBS"
67830 fi
67831 eval ac_res=\$$gt_func_gnugettext_libintl
67832                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
67833 $as_echo "$ac_res" >&6; }
67834         fi
67835
67836                                         if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" = "yes"; } \
67837            || { { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; } \
67838                 && test "$PACKAGE" != gettext-runtime \
67839                 && test "$PACKAGE" != gettext-tools; }; then
67840           gt_use_preinstalled_gnugettext=yes
67841         else
67842                     LIBINTL=
67843           LTLIBINTL=
67844           INCINTL=
67845         fi
67846
67847
67848
67849     if test -n "$INTL_MACOSX_LIBS"; then
67850       if test "$gt_use_preinstalled_gnugettext" = "yes" \
67851          || test "$nls_cv_use_gnu_gettext" = "yes"; then
67852                 LIBINTL="$LIBINTL $INTL_MACOSX_LIBS"
67853         LTLIBINTL="$LTLIBINTL $INTL_MACOSX_LIBS"
67854       fi
67855     fi
67856
67857     if test "$gt_use_preinstalled_gnugettext" = "yes" \
67858        || test "$nls_cv_use_gnu_gettext" = "yes"; then
67859
67860 $as_echo "#define ENABLE_NLS 1" >>confdefs.h
67861
67862     else
67863       USE_NLS=no
67864     fi
67865   fi
67866
67867   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use NLS" >&5
67868 $as_echo_n "checking whether to use NLS... " >&6; }
67869   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5
67870 $as_echo "$USE_NLS" >&6; }
67871   if test "$USE_NLS" = "yes"; then
67872     { $as_echo "$as_me:${as_lineno-$LINENO}: checking where the gettext function comes from" >&5
67873 $as_echo_n "checking where the gettext function comes from... " >&6; }
67874     if test "$gt_use_preinstalled_gnugettext" = "yes"; then
67875       if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
67876         gt_source="external libintl"
67877       else
67878         gt_source="libc"
67879       fi
67880     else
67881       gt_source="included intl directory"
67882     fi
67883     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_source" >&5
67884 $as_echo "$gt_source" >&6; }
67885   fi
67886
67887   if test "$USE_NLS" = "yes"; then
67888
67889     if test "$gt_use_preinstalled_gnugettext" = "yes"; then
67890       if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
67891         { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libintl" >&5
67892 $as_echo_n "checking how to link with libintl... " >&6; }
67893         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBINTL" >&5
67894 $as_echo "$LIBINTL" >&6; }
67895
67896   for element in $INCINTL; do
67897     haveit=
67898     for x in $CPPFLAGS; do
67899
67900   acl_save_prefix="$prefix"
67901   prefix="$acl_final_prefix"
67902   acl_save_exec_prefix="$exec_prefix"
67903   exec_prefix="$acl_final_exec_prefix"
67904   eval x=\"$x\"
67905   exec_prefix="$acl_save_exec_prefix"
67906   prefix="$acl_save_prefix"
67907
67908       if test "X$x" = "X$element"; then
67909         haveit=yes
67910         break
67911       fi
67912     done
67913     if test -z "$haveit"; then
67914       CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
67915     fi
67916   done
67917
67918       fi
67919
67920
67921 $as_echo "#define HAVE_GETTEXT 1" >>confdefs.h
67922
67923
67924 $as_echo "#define HAVE_DCGETTEXT 1" >>confdefs.h
67925
67926     fi
67927
67928         POSUB=po
67929   fi
67930
67931
67932
67933     INTLLIBS="$LIBINTL"
67934
67935
67936
67937
67938
67939
67940 GETTEXT_CPPFLAGS=
67941 if test "x$save_CPPFLAGS" != "x$CPPFLAGS"; then
67942  set dummy $CPPFLAGS; shift
67943  for var
67944  do
67945    case " $var " in
67946      " $save_CPPFLAGS ") ;;
67947      *) GETTEXT_CPPFLAGS="$GETTEXT_CPPFLAGS $var" ;;
67948    esac
67949  done
67950 fi
67951 CPPFLAGS="$save_CPPFLAGS"
67952
67953
67954 ALL_LINGUAS=`cd "$srcdir/po" > /dev/null && ls *.po | sed 's+\.po$++'`
67955
67956 CYGWIN_EXTRA_LDFLAGS=
67957 CYGWIN_EXTRA_LIBADD=
67958 MINGW_EXTRA_LDFLAGS=
67959 WIN32_EXTRA_CFLAGS=
67960 LIBVIRT_SYMBOL_FILE=libvirt.syms
67961 LIBVIRT_LXC_SYMBOL_FILE='$(srcdir)/libvirt_lxc.syms'
67962 LIBVIRT_QEMU_SYMBOL_FILE='$(srcdir)/libvirt_qemu.syms'
67963 MSCOM_LIBS=
67964 case "$host" in
67965   *-*-cygwin*)
67966     CYGWIN_EXTRA_LDFLAGS="-no-undefined"
67967     CYGWIN_EXTRA_LIBADD="${INTLLIBS}"
67968     MSCOM_LIBS="-lole32 -loleaut32"
67969     ;;
67970   *-*-mingw*)
67971     MINGW_EXTRA_LDFLAGS="-no-undefined"
67972     MSCOM_LIBS="-lole32 -loleaut32"
67973     ;;
67974   *-*-msvc*)
67975     MSCOM_LIBS="-lole32 -loleaut32"
67976     ;;
67977 esac
67978 case "$host" in
67979   *-*-mingw* | *-*-cygwin* | *-*-msvc* )
67980     # If the host is Windows, and shared libraries are disabled, we
67981     # need to add -DLIBVIRT_STATIC to the CFLAGS for proper linking
67982     if test "x$enable_shared" = "xno"; then
67983       WIN32_EXTRA_CFLAGS="-DLIBVIRT_STATIC"
67984     fi
67985 esac
67986 case "$host" in
67987   *-*-mingw* | *-*-msvc* )
67988     # Also set the symbol file to .def, so src/Makefile generates libvirt.def
67989     # from libvirt.syms and passes libvirt.def instead of libvirt.syms to the linker
67990     LIBVIRT_SYMBOL_FILE=libvirt.def
67991     LIBVIRT_LXC_SYMBOL_FILE=libvirt_lxc.def
67992     LIBVIRT_QEMU_SYMBOL_FILE=libvirt_qemu.def
67993     # mingw's ld has the --version-script parameter, but it requires a .def file
67994     # instead to work properly, therefore clear --version-script here and use
67995     # -Wl, to pass the .def file to the linker
67996     # cygwin's ld has the --version-script parameter too, but for some reason
67997     # it's working there as expected
67998     VERSION_SCRIPT_FLAGS="-Wl,"
67999     ;;
68000 esac
68001
68002
68003
68004
68005
68006
68007
68008
68009
68010
68011
68012 case "$host" in
68013   *-*-mingw* | *-*-cygwin* | *-*-msvc* )
68014     if test -n "$ac_tool_prefix"; then
68015   # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
68016 set dummy ${ac_tool_prefix}windres; ac_word=$2
68017 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
68018 $as_echo_n "checking for $ac_word... " >&6; }
68019 if ${ac_cv_prog_WINDRES+:} false; then :
68020   $as_echo_n "(cached) " >&6
68021 else
68022   if test -n "$WINDRES"; then
68023   ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
68024 else
68025 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
68026 for as_dir in $PATH
68027 do
68028   IFS=$as_save_IFS
68029   test -z "$as_dir" && as_dir=.
68030     for ac_exec_ext in '' $ac_executable_extensions; do
68031   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
68032     ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
68033     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
68034     break 2
68035   fi
68036 done
68037   done
68038 IFS=$as_save_IFS
68039
68040 fi
68041 fi
68042 WINDRES=$ac_cv_prog_WINDRES
68043 if test -n "$WINDRES"; then
68044   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
68045 $as_echo "$WINDRES" >&6; }
68046 else
68047   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
68048 $as_echo "no" >&6; }
68049 fi
68050
68051
68052 fi
68053 if test -z "$ac_cv_prog_WINDRES"; then
68054   ac_ct_WINDRES=$WINDRES
68055   # Extract the first word of "windres", so it can be a program name with args.
68056 set dummy windres; ac_word=$2
68057 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
68058 $as_echo_n "checking for $ac_word... " >&6; }
68059 if ${ac_cv_prog_ac_ct_WINDRES+:} false; then :
68060   $as_echo_n "(cached) " >&6
68061 else
68062   if test -n "$ac_ct_WINDRES"; then
68063   ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
68064 else
68065 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
68066 for as_dir in $PATH
68067 do
68068   IFS=$as_save_IFS
68069   test -z "$as_dir" && as_dir=.
68070     for ac_exec_ext in '' $ac_executable_extensions; do
68071   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
68072     ac_cv_prog_ac_ct_WINDRES="windres"
68073     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
68074     break 2
68075   fi
68076 done
68077   done
68078 IFS=$as_save_IFS
68079
68080 fi
68081 fi
68082 ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
68083 if test -n "$ac_ct_WINDRES"; then
68084   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_WINDRES" >&5
68085 $as_echo "$ac_ct_WINDRES" >&6; }
68086 else
68087   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
68088 $as_echo "no" >&6; }
68089 fi
68090
68091   if test "x$ac_ct_WINDRES" = x; then
68092     WINDRES=""
68093   else
68094     case $cross_compiling:$ac_tool_warned in
68095 yes:)
68096 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
68097 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
68098 ac_tool_warned=yes ;;
68099 esac
68100     WINDRES=$ac_ct_WINDRES
68101   fi
68102 else
68103   WINDRES="$ac_cv_prog_WINDRES"
68104 fi
68105
68106     ;;
68107 esac
68108  if test "$WINDRES" != ""; then
68109   WITH_WIN_ICON_TRUE=
68110   WITH_WIN_ICON_FALSE='#'
68111 else
68112   WITH_WIN_ICON_TRUE='#'
68113   WITH_WIN_ICON_FALSE=
68114 fi
68115
68116
68117
68118
68119 # Check whether --with-driver-modules was given.
68120 if test "${with_driver_modules+set}" = set; then :
68121   withval=$with_driver_modules;
68122 else
68123   with_driver_modules=check
68124 fi
68125
68126
68127 if test "$with_libvirtd" = "no" ; then
68128   with_driver_modules=no
68129 fi
68130
68131 DRIVER_MODULE_CFLAGS=
68132 DRIVER_MODULE_LIBS=
68133 if test "$with_driver_modules" = "yes" || test "$with_driver_modules" = "check"; then
68134   if test "$dlfcn_found" != "yes" || test "$dlopen_found" != "yes"; then
68135     if test "$with_driver_modules" = "yes" ; then
68136       as_fn_error $? "You must have dlfcn.h / dlopen() support to build driver modules" "$LINENO" 5
68137     else
68138       with_driver_modules=no
68139     fi
68140   else
68141     with_driver_modules=yes
68142   fi
68143 fi
68144
68145 if test "$with_driver_modules" = "yes" ; then
68146   DRIVER_MODULE_LDFLAGS="-export-dynamic"
68147   case $ac_cv_search_dlopen in
68148     no*) DRIVER_MODULE_LIBS= ;;
68149     *) DRIVER_MODULE_LIBS=$ac_cv_search_dlopen ;;
68150   esac
68151
68152 cat >>confdefs.h <<_ACEOF
68153 #define WITH_DRIVER_MODULES 1
68154 _ACEOF
68155
68156 fi
68157  if test "$with_driver_modules" != "no"; then
68158   WITH_DRIVER_MODULES_TRUE=
68159   WITH_DRIVER_MODULES_FALSE='#'
68160 else
68161   WITH_DRIVER_MODULES_TRUE='#'
68162   WITH_DRIVER_MODULES_FALSE=
68163 fi
68164
68165
68166
68167
68168
68169 # Set LV_LIBTOOL_OBJDIR to "." or $lt_cv_objdir, depending on whether
68170 # we're building shared libraries.  This is the name of the directory
68171 # in which .o files will be created.
68172 test "$enable_shared" = no && lt_cv_objdir=.
68173 LV_LIBTOOL_OBJDIR=${lt_cv_objdir-.}
68174
68175
68176
68177 with_nodedev=no;
68178 if test "$with_hal" = "yes" || test "$with_udev" = "yes";
68179 then
68180   with_nodedev=yes
68181
68182 cat >>confdefs.h <<_ACEOF
68183 #define WITH_NODE_DEVICES 1
68184 _ACEOF
68185
68186 fi
68187  if test "$with_nodedev" = "yes"; then
68188   WITH_NODE_DEVICES_TRUE=
68189   WITH_NODE_DEVICES_FALSE='#'
68190 else
68191   WITH_NODE_DEVICES_TRUE='#'
68192   WITH_NODE_DEVICES_FALSE=
68193 fi
68194
68195
68196
68197 with_nwfilter=yes
68198 if test "$with_libvirtd" = "no" || test "$with_linux" != "yes"; then
68199   with_nwfilter=no
68200 fi
68201 if test "$with_nwfilter" = "yes" ; then
68202
68203 $as_echo "#define WITH_NWFILTER 1" >>confdefs.h
68204
68205 fi
68206  if test "$with_nwfilter" = "yes"; then
68207   WITH_NWFILTER_TRUE=
68208   WITH_NWFILTER_FALSE='#'
68209 else
68210   WITH_NWFILTER_TRUE='#'
68211   WITH_NWFILTER_FALSE=
68212 fi
68213
68214
68215
68216 # Check whether --with-interface was given.
68217 if test "${with_interface+set}" = set; then :
68218   withval=$with_interface;
68219 else
68220   with_interface=check
68221 fi
68222
68223
68224 if test "$with_libvirtd" = "no" ; then
68225   with_interface=no
68226 fi
68227
68228 case $with_interface:$with_netcf:$with_udev in
68229     check:*yes*) with_interface=yes ;;
68230     check:no:no) with_interface=no ;;
68231     yes:no:no) as_fn_error $? "Requested the Interface driver without netcf or udev support" "$LINENO" 5 ;;
68232 esac
68233
68234 if test "$with_interface" = "yes" ; then
68235
68236 cat >>confdefs.h <<_ACEOF
68237 #define WITH_INTERFACE 1
68238 _ACEOF
68239
68240 fi
68241  if test "$with_interface" = "yes"; then
68242   WITH_INTERFACE_TRUE=
68243   WITH_INTERFACE_FALSE='#'
68244 else
68245   WITH_INTERFACE_TRUE='#'
68246   WITH_INTERFACE_FALSE=
68247 fi
68248
68249
68250
68251 if test $with_freebsd = yes || test $with_osx = yes; then
68252   default_qemu_user=root
68253   default_qemu_group=wheel
68254 else
68255   default_qemu_user=root
68256   default_qemu_group=root
68257 fi
68258
68259
68260 # Check whether --with-qemu-user was given.
68261 if test "${with_qemu_user+set}" = set; then :
68262   withval=$with_qemu_user; QEMU_USER=${withval}
68263 else
68264   QEMU_USER=${default_qemu_user}
68265 fi
68266
68267
68268 # Check whether --with-qemu-group was given.
68269 if test "${with_qemu_group+set}" = set; then :
68270   withval=$with_qemu_group; QEMU_GROUP=${withval}
68271 else
68272   QEMU_GROUP=${default_qemu_group}
68273 fi
68274
68275
68276 cat >>confdefs.h <<_ACEOF
68277 #define QEMU_USER "$QEMU_USER"
68278 _ACEOF
68279
68280
68281 cat >>confdefs.h <<_ACEOF
68282 #define QEMU_GROUP "$QEMU_GROUP"
68283 _ACEOF
68284
68285
68286
68287
68288 # Check whether --with-macvtap was given.
68289 if test "${with_macvtap+set}" = set; then :
68290   withval=$with_macvtap; with_macvtap=${withval}
68291 else
68292   with_macvtap=check
68293 fi
68294
68295
68296 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to compile with macvtap support" >&5
68297 $as_echo_n "checking whether to compile with macvtap support... " >&6; }
68298 if test "$with_macvtap" != "no" ; then
68299     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
68300 /* end confdefs.h.  */
68301  #include <sys/socket.h>
68302                      #include <linux/rtnetlink.h>
68303 int
68304 main ()
68305 {
68306  int x = MACVLAN_MODE_BRIDGE;
68307                      int y = IFLA_VF_MAX;
68308   ;
68309   return 0;
68310 }
68311 _ACEOF
68312 if ac_fn_c_try_compile "$LINENO"; then :
68313    with_macvtap=yes
68314 else
68315    if test "$with_macvtap" = "yes" ; then
68316                          as_fn_error $? "Installed linux headers don't show support for macvtap device." "$LINENO" 5
68317                      fi
68318                      with_macvtap=no
68319 fi
68320 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
68321     if test "$with_macvtap" = "yes" ; then
68322         val=1
68323     else
68324         val=0
68325     fi
68326
68327 cat >>confdefs.h <<_ACEOF
68328 #define WITH_MACVTAP $val
68329 _ACEOF
68330
68331 fi
68332  if test "$with_macvtap" = "yes"; then
68333   WITH_MACVTAP_TRUE=
68334   WITH_MACVTAP_FALSE='#'
68335 else
68336   WITH_MACVTAP_TRUE='#'
68337   WITH_MACVTAP_FALSE=
68338 fi
68339
68340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_macvtap" >&5
68341 $as_echo "$with_macvtap" >&6; }
68342 if test "$with_macvtap" = yes; then
68343     ac_fn_c_check_decl "$LINENO" "MACVLAN_MODE_PASSTHRU" "ac_cv_have_decl_MACVLAN_MODE_PASSTHRU" "
68344       #include <sys/socket.h>
68345       #include <linux/if_link.h>
68346
68347 "
68348 if test "x$ac_cv_have_decl_MACVLAN_MODE_PASSTHRU" = xyes; then :
68349   ac_have_decl=1
68350 else
68351   ac_have_decl=0
68352 fi
68353
68354 cat >>confdefs.h <<_ACEOF
68355 #define HAVE_DECL_MACVLAN_MODE_PASSTHRU $ac_have_decl
68356 _ACEOF
68357
68358 fi
68359
68360
68361
68362 # Check whether --with-virtualport was given.
68363 if test "${with_virtualport+set}" = set; then :
68364   withval=$with_virtualport; with_virtualport=${withval}
68365 else
68366   with_virtualport=check
68367 fi
68368
68369
68370
68371 if test "$with_virtualport" = "yes"; then
68372     if test "$with_macvtap" = "no"; then
68373         as_fn_error $? "--with-virtualport requires --with-macvtap" "$LINENO" 5
68374     fi
68375 fi
68376
68377
68378 if test "$with_macvtap" != "yes"; then
68379     with_virtualport=no
68380 fi
68381 if test "$with_virtualport" != "no"; then
68382     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to compile with virtual port support" >&5
68383 $as_echo_n "checking whether to compile with virtual port support... " >&6; }
68384     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
68385 /* end confdefs.h.  */
68386  #include <sys/socket.h>
68387                      #include <linux/rtnetlink.h>
68388 int
68389 main ()
68390 {
68391  int x = IFLA_PORT_MAX;
68392   ;
68393   return 0;
68394 }
68395 _ACEOF
68396 if ac_fn_c_try_compile "$LINENO"; then :
68397    with_virtualport=yes
68398 else
68399    if test "$with_virtualport" = "yes" ; then
68400                          as_fn_error $? "Installed linux headers don't show support for virtual port support." "$LINENO" 5
68401                        fi
68402                        with_virtualport=no
68403 fi
68404 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
68405     if test "$with_virtualport" = "yes"; then
68406         val=1
68407     else
68408         val=0
68409     fi
68410
68411 cat >>confdefs.h <<_ACEOF
68412 #define WITH_VIRTUALPORT $val
68413 _ACEOF
68414
68415     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_virtualport" >&5
68416 $as_echo "$with_virtualport" >&6; }
68417 fi
68418  if test "$with_virtualport" = "yes"; then
68419   WITH_VIRTUALPORT_TRUE=
68420   WITH_VIRTUALPORT_FALSE='#'
68421 else
68422   WITH_VIRTUALPORT_TRUE='#'
68423   WITH_VIRTUALPORT_FALSE=
68424 fi
68425
68426
68427 ac_fn_c_check_decl "$LINENO" "GET_VLAN_VID_CMD" "ac_cv_have_decl_GET_VLAN_VID_CMD" "#include <linux/if_vlan.h>
68428 "
68429 if test "x$ac_cv_have_decl_GET_VLAN_VID_CMD" = xyes; then :
68430   ac_have_decl=1
68431 else
68432   ac_have_decl=0
68433 fi
68434
68435 cat >>confdefs.h <<_ACEOF
68436 #define HAVE_DECL_GET_VLAN_VID_CMD $ac_have_decl
68437 _ACEOF
68438
68439
68440
68441 have_libnl=no
68442
68443 if test "$with_linux" = "yes"; then
68444     # When linking with netcf, we must ensure that we pick the same version
68445     # of libnl that netcf picked.  Prefer libnl-3 unless we can prove
68446     # netcf linked against libnl-1, or unless the user set LIBNL_CFLAGS.
68447     # (Setting LIBNL_CFLAGS is already used by PKG_CHECK_MODULES to
68448     # override any probing, so if it set, you know which libnl is in use.)
68449     libnl_ldd=
68450     for dir in /usr/lib64 /usr/lib /usr/lib/*-linux-gnu*; do
68451         if test -f $dir/libnetcf.so; then
68452             libnl_ldd=`(ldd $dir/libnetcf.so) 2>&1`
68453             break
68454         fi
68455     done
68456     case $libnl_ldd:${LIBNL_CFLAGS+set} in
68457         *libnl-3.so.*:) LIBNL_REQUIRED=3.0 ;;
68458     esac
68459     case $libnl_ldd:${LIBNL_CFLAGS+set} in
68460         *libnl.so.1*:) ;;
68461         *)
68462
68463 pkg_failed=no
68464 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIBNL" >&5
68465 $as_echo_n "checking for LIBNL... " >&6; }
68466
68467 if test -n "$LIBNL_CFLAGS"; then
68468     pkg_cv_LIBNL_CFLAGS="$LIBNL_CFLAGS"
68469  elif test -n "$PKG_CONFIG"; then
68470     if test -n "$PKG_CONFIG" && \
68471     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libnl-3.0\""; } >&5
68472   ($PKG_CONFIG --exists --print-errors "libnl-3.0") 2>&5
68473   ac_status=$?
68474   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
68475   test $ac_status = 0; }; then
68476   pkg_cv_LIBNL_CFLAGS=`$PKG_CONFIG --cflags "libnl-3.0" 2>/dev/null`
68477                       test "x$?" != "x0" && pkg_failed=yes
68478 else
68479   pkg_failed=yes
68480 fi
68481  else
68482     pkg_failed=untried
68483 fi
68484 if test -n "$LIBNL_LIBS"; then
68485     pkg_cv_LIBNL_LIBS="$LIBNL_LIBS"
68486  elif test -n "$PKG_CONFIG"; then
68487     if test -n "$PKG_CONFIG" && \
68488     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libnl-3.0\""; } >&5
68489   ($PKG_CONFIG --exists --print-errors "libnl-3.0") 2>&5
68490   ac_status=$?
68491   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
68492   test $ac_status = 0; }; then
68493   pkg_cv_LIBNL_LIBS=`$PKG_CONFIG --libs "libnl-3.0" 2>/dev/null`
68494                       test "x$?" != "x0" && pkg_failed=yes
68495 else
68496   pkg_failed=yes
68497 fi
68498  else
68499     pkg_failed=untried
68500 fi
68501
68502
68503
68504 if test $pkg_failed = yes; then
68505         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
68506 $as_echo "no" >&6; }
68507
68508 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
68509         _pkg_short_errors_supported=yes
68510 else
68511         _pkg_short_errors_supported=no
68512 fi
68513         if test $_pkg_short_errors_supported = yes; then
68514                 LIBNL_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libnl-3.0" 2>&1`
68515         else
68516                 LIBNL_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libnl-3.0" 2>&1`
68517         fi
68518         # Put the nasty error message in config.log where it belongs
68519         echo "$LIBNL_PKG_ERRORS" >&5
68520
68521         :
68522 elif test $pkg_failed = untried; then
68523         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
68524 $as_echo "no" >&6; }
68525         :
68526 else
68527         LIBNL_CFLAGS=$pkg_cv_LIBNL_CFLAGS
68528         LIBNL_LIBS=$pkg_cv_LIBNL_LIBS
68529         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
68530 $as_echo "yes" >&6; }
68531
68532             have_libnl=yes
68533
68534 $as_echo "#define HAVE_LIBNL3 1" >>confdefs.h
68535
68536
68537 $as_echo "#define HAVE_LIBNL 1" >>confdefs.h
68538
68539
68540 pkg_failed=no
68541 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIBNL_ROUTE3" >&5
68542 $as_echo_n "checking for LIBNL_ROUTE3... " >&6; }
68543
68544 if test -n "$LIBNL_ROUTE3_CFLAGS"; then
68545     pkg_cv_LIBNL_ROUTE3_CFLAGS="$LIBNL_ROUTE3_CFLAGS"
68546  elif test -n "$PKG_CONFIG"; then
68547     if test -n "$PKG_CONFIG" && \
68548     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libnl-route-3.0\""; } >&5
68549   ($PKG_CONFIG --exists --print-errors "libnl-route-3.0") 2>&5
68550   ac_status=$?
68551   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
68552   test $ac_status = 0; }; then
68553   pkg_cv_LIBNL_ROUTE3_CFLAGS=`$PKG_CONFIG --cflags "libnl-route-3.0" 2>/dev/null`
68554                       test "x$?" != "x0" && pkg_failed=yes
68555 else
68556   pkg_failed=yes
68557 fi
68558  else
68559     pkg_failed=untried
68560 fi
68561 if test -n "$LIBNL_ROUTE3_LIBS"; then
68562     pkg_cv_LIBNL_ROUTE3_LIBS="$LIBNL_ROUTE3_LIBS"
68563  elif test -n "$PKG_CONFIG"; then
68564     if test -n "$PKG_CONFIG" && \
68565     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libnl-route-3.0\""; } >&5
68566   ($PKG_CONFIG --exists --print-errors "libnl-route-3.0") 2>&5
68567   ac_status=$?
68568   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
68569   test $ac_status = 0; }; then
68570   pkg_cv_LIBNL_ROUTE3_LIBS=`$PKG_CONFIG --libs "libnl-route-3.0" 2>/dev/null`
68571                       test "x$?" != "x0" && pkg_failed=yes
68572 else
68573   pkg_failed=yes
68574 fi
68575  else
68576     pkg_failed=untried
68577 fi
68578
68579
68580
68581 if test $pkg_failed = yes; then
68582         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
68583 $as_echo "no" >&6; }
68584
68585 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
68586         _pkg_short_errors_supported=yes
68587 else
68588         _pkg_short_errors_supported=no
68589 fi
68590         if test $_pkg_short_errors_supported = yes; then
68591                 LIBNL_ROUTE3_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libnl-route-3.0" 2>&1`
68592         else
68593                 LIBNL_ROUTE3_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libnl-route-3.0" 2>&1`
68594         fi
68595         # Put the nasty error message in config.log where it belongs
68596         echo "$LIBNL_ROUTE3_PKG_ERRORS" >&5
68597
68598         as_fn_error $? "Package requirements (libnl-route-3.0) were not met:
68599
68600 $LIBNL_ROUTE3_PKG_ERRORS
68601
68602 Consider adjusting the PKG_CONFIG_PATH environment variable if you
68603 installed software in a non-standard prefix.
68604
68605 Alternatively, you may set the environment variables LIBNL_ROUTE3_CFLAGS
68606 and LIBNL_ROUTE3_LIBS to avoid the need to call pkg-config.
68607 See the pkg-config man page for more details." "$LINENO" 5
68608 elif test $pkg_failed = untried; then
68609         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
68610 $as_echo "no" >&6; }
68611         { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
68612 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
68613 as_fn_error $? "The pkg-config script could not be found or is too old.  Make sure it
68614 is in your PATH or set the PKG_CONFIG environment variable to the full
68615 path to pkg-config.
68616
68617 Alternatively, you may set the environment variables LIBNL_ROUTE3_CFLAGS
68618 and LIBNL_ROUTE3_LIBS to avoid the need to call pkg-config.
68619 See the pkg-config man page for more details.
68620
68621 To get pkg-config, see <http://pkg-config.freedesktop.org/>.
68622 See \`config.log' for more details" "$LINENO" 5; }
68623 else
68624         LIBNL_ROUTE3_CFLAGS=$pkg_cv_LIBNL_ROUTE3_CFLAGS
68625         LIBNL_ROUTE3_LIBS=$pkg_cv_LIBNL_ROUTE3_LIBS
68626         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
68627 $as_echo "yes" >&6; }
68628
68629 fi
68630             LIBNL_CFLAGS="$LIBNL_CFLAGS $LIBNL_ROUTE3_CFLAGS"
68631             LIBNL_LIBS="$LIBNL_LIBS $LIBNL_ROUTE3_LIBS"
68632
68633 fi ;;
68634     esac
68635     if test "$have_libnl" = no; then
68636
68637 pkg_failed=no
68638 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIBNL" >&5
68639 $as_echo_n "checking for LIBNL... " >&6; }
68640
68641 if test -n "$LIBNL_CFLAGS"; then
68642     pkg_cv_LIBNL_CFLAGS="$LIBNL_CFLAGS"
68643  elif test -n "$PKG_CONFIG"; then
68644     if test -n "$PKG_CONFIG" && \
68645     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libnl-1 >= \$LIBNL_REQUIRED\""; } >&5
68646   ($PKG_CONFIG --exists --print-errors "libnl-1 >= $LIBNL_REQUIRED") 2>&5
68647   ac_status=$?
68648   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
68649   test $ac_status = 0; }; then
68650   pkg_cv_LIBNL_CFLAGS=`$PKG_CONFIG --cflags "libnl-1 >= $LIBNL_REQUIRED" 2>/dev/null`
68651                       test "x$?" != "x0" && pkg_failed=yes
68652 else
68653   pkg_failed=yes
68654 fi
68655  else
68656     pkg_failed=untried
68657 fi
68658 if test -n "$LIBNL_LIBS"; then
68659     pkg_cv_LIBNL_LIBS="$LIBNL_LIBS"
68660  elif test -n "$PKG_CONFIG"; then
68661     if test -n "$PKG_CONFIG" && \
68662     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libnl-1 >= \$LIBNL_REQUIRED\""; } >&5
68663   ($PKG_CONFIG --exists --print-errors "libnl-1 >= $LIBNL_REQUIRED") 2>&5
68664   ac_status=$?
68665   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
68666   test $ac_status = 0; }; then
68667   pkg_cv_LIBNL_LIBS=`$PKG_CONFIG --libs "libnl-1 >= $LIBNL_REQUIRED" 2>/dev/null`
68668                       test "x$?" != "x0" && pkg_failed=yes
68669 else
68670   pkg_failed=yes
68671 fi
68672  else
68673     pkg_failed=untried
68674 fi
68675
68676
68677
68678 if test $pkg_failed = yes; then
68679         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
68680 $as_echo "no" >&6; }
68681
68682 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
68683         _pkg_short_errors_supported=yes
68684 else
68685         _pkg_short_errors_supported=no
68686 fi
68687         if test $_pkg_short_errors_supported = yes; then
68688                 LIBNL_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libnl-1 >= $LIBNL_REQUIRED" 2>&1`
68689         else
68690                 LIBNL_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libnl-1 >= $LIBNL_REQUIRED" 2>&1`
68691         fi
68692         # Put the nasty error message in config.log where it belongs
68693         echo "$LIBNL_PKG_ERRORS" >&5
68694
68695
68696             if test "$with_macvtap" = "yes"; then
68697                 as_fn_error $? "libnl-devel >= $LIBNL_REQUIRED is required for macvtap support" "$LINENO" 5
68698             fi
68699
68700 elif test $pkg_failed = untried; then
68701         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
68702 $as_echo "no" >&6; }
68703
68704             if test "$with_macvtap" = "yes"; then
68705                 as_fn_error $? "libnl-devel >= $LIBNL_REQUIRED is required for macvtap support" "$LINENO" 5
68706             fi
68707
68708 else
68709         LIBNL_CFLAGS=$pkg_cv_LIBNL_CFLAGS
68710         LIBNL_LIBS=$pkg_cv_LIBNL_LIBS
68711         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
68712 $as_echo "yes" >&6; }
68713
68714             have_libnl=yes
68715
68716 cat >>confdefs.h <<_ACEOF
68717 #define HAVE_LIBNL 1
68718 _ACEOF
68719
68720
68721 cat >>confdefs.h <<_ACEOF
68722 #define HAVE_LIBNL1 1
68723 _ACEOF
68724
68725
68726 fi
68727     fi
68728 fi
68729  if test "$have_libnl" = "yes"; then
68730   HAVE_LIBNL_TRUE=
68731   HAVE_LIBNL_FALSE='#'
68732 else
68733   HAVE_LIBNL_TRUE='#'
68734   HAVE_LIBNL_FALSE=
68735 fi
68736
68737
68738
68739
68740
68741
68742
68743 # Check whether --with-wireshark-dissector was given.
68744 if test "${with_wireshark_dissector+set}" = set; then :
68745   withval=$with_wireshark_dissector;  with_wireshark_dissector=$withval
68746 else
68747    with_wireshark_dissector=check
68748 fi
68749
68750
68751
68752 if test "$with_wireshark_dissector" != "no"; then
68753         for ac_header in rpc/types.h
68754 do :
68755   ac_fn_c_check_header_mongrel "$LINENO" "rpc/types.h" "ac_cv_header_rpc_types_h" "$ac_includes_default"
68756 if test "x$ac_cv_header_rpc_types_h" = xyes; then :
68757   cat >>confdefs.h <<_ACEOF
68758 #define HAVE_RPC_TYPES_H 1
68759 _ACEOF
68760
68761 fi
68762
68763 done
68764
68765
68766
68767 pkg_failed=no
68768 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GLIB" >&5
68769 $as_echo_n "checking for GLIB... " >&6; }
68770
68771 if test -n "$GLIB_CFLAGS"; then
68772     pkg_cv_GLIB_CFLAGS="$GLIB_CFLAGS"
68773  elif test -n "$PKG_CONFIG"; then
68774     if test -n "$PKG_CONFIG" && \
68775     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"glib-2.0\""; } >&5
68776   ($PKG_CONFIG --exists --print-errors "glib-2.0") 2>&5
68777   ac_status=$?
68778   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
68779   test $ac_status = 0; }; then
68780   pkg_cv_GLIB_CFLAGS=`$PKG_CONFIG --cflags "glib-2.0" 2>/dev/null`
68781                       test "x$?" != "x0" && pkg_failed=yes
68782 else
68783   pkg_failed=yes
68784 fi
68785  else
68786     pkg_failed=untried
68787 fi
68788 if test -n "$GLIB_LIBS"; then
68789     pkg_cv_GLIB_LIBS="$GLIB_LIBS"
68790  elif test -n "$PKG_CONFIG"; then
68791     if test -n "$PKG_CONFIG" && \
68792     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"glib-2.0\""; } >&5
68793   ($PKG_CONFIG --exists --print-errors "glib-2.0") 2>&5
68794   ac_status=$?
68795   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
68796   test $ac_status = 0; }; then
68797   pkg_cv_GLIB_LIBS=`$PKG_CONFIG --libs "glib-2.0" 2>/dev/null`
68798                       test "x$?" != "x0" && pkg_failed=yes
68799 else
68800   pkg_failed=yes
68801 fi
68802  else
68803     pkg_failed=untried
68804 fi
68805
68806
68807
68808 if test $pkg_failed = yes; then
68809         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
68810 $as_echo "no" >&6; }
68811
68812 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
68813         _pkg_short_errors_supported=yes
68814 else
68815         _pkg_short_errors_supported=no
68816 fi
68817         if test $_pkg_short_errors_supported = yes; then
68818                 GLIB_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "glib-2.0" 2>&1`
68819         else
68820                 GLIB_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "glib-2.0" 2>&1`
68821         fi
68822         # Put the nasty error message in config.log where it belongs
68823         echo "$GLIB_PKG_ERRORS" >&5
68824
68825
68826
68827   if test "$with_wireshark_dissector" = "yes"; then
68828     as_fn_error $? "pkg-config 'glib-2.0' is required for wireshark-dissector support" "$LINENO" 5
68829   else
68830     with_wireshark_dissector=no
68831   fi
68832
68833
68834 elif test $pkg_failed = untried; then
68835         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
68836 $as_echo "no" >&6; }
68837
68838
68839   if test "$with_wireshark_dissector" = "yes"; then
68840     as_fn_error $? "pkg-config 'glib-2.0' is required for wireshark-dissector support" "$LINENO" 5
68841   else
68842     with_wireshark_dissector=no
68843   fi
68844
68845
68846 else
68847         GLIB_CFLAGS=$pkg_cv_GLIB_CFLAGS
68848         GLIB_LIBS=$pkg_cv_GLIB_LIBS
68849         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
68850 $as_echo "yes" >&6; }
68851
68852       WS_DISSECTOR_CPPFLAGS="$WS_DISSECTOR_CPPFLAGS `$PKG_CONFIG --cflags glib-2.0`"
68853
68854 fi
68855
68856         # Extract the first word of "wireshark", so it can be a program name with args.
68857 set dummy wireshark; ac_word=$2
68858 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
68859 $as_echo_n "checking for $ac_word... " >&6; }
68860 if ${ac_cv_path_WIRESHARK+:} false; then :
68861   $as_echo_n "(cached) " >&6
68862 else
68863   case $WIRESHARK in
68864   [\\/]* | ?:[\\/]*)
68865   ac_cv_path_WIRESHARK="$WIRESHARK" # Let the user override the test with a path.
68866   ;;
68867   *)
68868   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
68869 for as_dir in $PATH
68870 do
68871   IFS=$as_save_IFS
68872   test -z "$as_dir" && as_dir=.
68873     for ac_exec_ext in '' $ac_executable_extensions; do
68874   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
68875     ac_cv_path_WIRESHARK="$as_dir/$ac_word$ac_exec_ext"
68876     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
68877     break 2
68878   fi
68879 done
68880   done
68881 IFS=$as_save_IFS
68882
68883   ;;
68884 esac
68885 fi
68886 WIRESHARK=$ac_cv_path_WIRESHARK
68887 if test -n "$WIRESHARK"; then
68888   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WIRESHARK" >&5
68889 $as_echo "$WIRESHARK" >&6; }
68890 else
68891   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
68892 $as_echo "no" >&6; }
68893 fi
68894
68895
68896     # Extract the first word of "tshark", so it can be a program name with args.
68897 set dummy tshark; ac_word=$2
68898 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
68899 $as_echo_n "checking for $ac_word... " >&6; }
68900 if ${ac_cv_path_WIRESHARK+:} false; then :
68901   $as_echo_n "(cached) " >&6
68902 else
68903   case $WIRESHARK in
68904   [\\/]* | ?:[\\/]*)
68905   ac_cv_path_WIRESHARK="$WIRESHARK" # Let the user override the test with a path.
68906   ;;
68907   *)
68908   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
68909 for as_dir in $PATH
68910 do
68911   IFS=$as_save_IFS
68912   test -z "$as_dir" && as_dir=.
68913     for ac_exec_ext in '' $ac_executable_extensions; do
68914   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
68915     ac_cv_path_WIRESHARK="$as_dir/$ac_word$ac_exec_ext"
68916     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
68917     break 2
68918   fi
68919 done
68920   done
68921 IFS=$as_save_IFS
68922
68923   ;;
68924 esac
68925 fi
68926 WIRESHARK=$ac_cv_path_WIRESHARK
68927 if test -n "$WIRESHARK"; then
68928   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WIRESHARK" >&5
68929 $as_echo "$WIRESHARK" >&6; }
68930 else
68931   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
68932 $as_echo "no" >&6; }
68933 fi
68934
68935
68936     if test -z "$WIRESHARK"; then
68937
68938   if test "$with_wireshark_dissector" = "yes"; then
68939     as_fn_error $? "command not found wireshark or tshark" "$LINENO" 5
68940   else
68941     with_wireshark_dissector=no
68942   fi
68943
68944     else
68945                 save_CPPFLAGS="$CPPFLAGS"
68946         WS_DISSECTOR_CPPFLAGS="$WS_DISSECTOR_CPPFLAGS -I`dirname $WIRESHARK`/../include/wireshark"
68947         CPPFLAGS="$CPPFLAGS $WS_DISSECTOR_CPPFLAGS"
68948         for ac_header in wireshark/config.h
68949 do :
68950   ac_fn_c_check_header_mongrel "$LINENO" "wireshark/config.h" "ac_cv_header_wireshark_config_h" "$ac_includes_default"
68951 if test "x$ac_cv_header_wireshark_config_h" = xyes; then :
68952   cat >>confdefs.h <<_ACEOF
68953 #define HAVE_WIRESHARK_CONFIG_H 1
68954 _ACEOF
68955
68956 else
68957
68958
68959   if test "$with_wireshark_dissector" = "yes"; then
68960     as_fn_error $? "wireshark/config.h is required for wireshark-dissector support" "$LINENO" 5
68961   else
68962     with_wireshark_dissector=no
68963   fi
68964
68965
68966 fi
68967
68968 done
68969
68970         for ac_header in wireshark/epan/packet.h wireshark/epan/dissectors/packet-tcp.h
68971 do :
68972   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
68973 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "
68974           #include <wireshark/config.h>
68975
68976 "
68977 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
68978   cat >>confdefs.h <<_ACEOF
68979 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
68980 _ACEOF
68981
68982 else
68983
68984
68985   if test "$with_wireshark_dissector" = "yes"; then
68986     as_fn_error $? "wireshark/epan/{packet,packet-tcp}.h are required for wireshark-dissector support" "$LINENO" 5
68987   else
68988     with_wireshark_dissector=no
68989   fi
68990
68991
68992 fi
68993
68994 done
68995
68996         CPPFLAGS="$save_CPPFLAGS"
68997     fi
68998     if test "$with_wireshark_dissector" != "no"; then
68999         with_wireshark_dissector=yes
69000     fi
69001 fi
69002
69003  if test "$with_wireshark_dissector" = "yes"; then
69004   WITH_WIRESHARK_DISSECTOR_TRUE=
69005   WITH_WIRESHARK_DISSECTOR_FALSE='#'
69006 else
69007   WITH_WIRESHARK_DISSECTOR_TRUE='#'
69008   WITH_WIRESHARK_DISSECTOR_FALSE=
69009 fi
69010
69011
69012
69013 # Check whether --with-ws-plugindir was given.
69014 if test "${with_ws_plugindir+set}" = set; then :
69015   withval=$with_ws_plugindir; ws_plugindir=$withval
69016 fi
69017
69018
69019 if test "$with_wireshark_dissector" != "no" && test -z "$ws_plugindir"; then
69020     ws_version=`$WIRESHARK -v | head -1 | cut -f 2 -d' '`
69021     ws_plugindir="$libdir/wireshark/plugins/$ws_version"
69022 fi
69023
69024
69025 # Check for Linux vs. BSD ifreq members
69026 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_newname" "ac_cv_member_struct_ifreq_ifr_newname" "#include <sys/socket.h>
69027                   #include <net/if.h>
69028
69029 "
69030 if test "x$ac_cv_member_struct_ifreq_ifr_newname" = xyes; then :
69031
69032 cat >>confdefs.h <<_ACEOF
69033 #define HAVE_STRUCT_IFREQ_IFR_NEWNAME 1
69034 _ACEOF
69035
69036
69037 fi
69038 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_ifindex" "ac_cv_member_struct_ifreq_ifr_ifindex" "#include <sys/socket.h>
69039                   #include <net/if.h>
69040
69041 "
69042 if test "x$ac_cv_member_struct_ifreq_ifr_ifindex" = xyes; then :
69043
69044 cat >>confdefs.h <<_ACEOF
69045 #define HAVE_STRUCT_IFREQ_IFR_IFINDEX 1
69046 _ACEOF
69047
69048
69049 fi
69050 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_index" "ac_cv_member_struct_ifreq_ifr_index" "#include <sys/socket.h>
69051                   #include <net/if.h>
69052
69053 "
69054 if test "x$ac_cv_member_struct_ifreq_ifr_index" = xyes; then :
69055
69056 cat >>confdefs.h <<_ACEOF
69057 #define HAVE_STRUCT_IFREQ_IFR_INDEX 1
69058 _ACEOF
69059
69060
69061 fi
69062
69063
69064 # Check for BSD approach for setting MAC addr
69065 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
69066 /* end confdefs.h.  */
69067
69068         #include <sys/types.h>
69069         #include <sys/socket.h>
69070         #include <net/if_dl.h>
69071
69072 int
69073 main ()
69074 {
69075
69076         link_addr(0, 0)
69077   ;
69078   return 0;
69079 }
69080 _ACEOF
69081 if ac_fn_c_try_link "$LINENO"; then :
69082
69083 $as_echo "#define HAVE_DECL_LINK_ADDR 1" >>confdefs.h
69084
69085 fi
69086 rm -f core conftest.err conftest.$ac_objext \
69087     conftest$ac_exeext conftest.$ac_ext
69088
69089 # Check for BSD approach for bridge management
69090 ac_fn_c_check_decl "$LINENO" "BRDGSFD" "ac_cv_have_decl_BRDGSFD" "#include <stdint.h>
69091                 #include <net/if.h>
69092                 #include <net/ethernet.h>
69093                 #include <net/if_bridgevar.h>
69094
69095 "
69096 if test "x$ac_cv_have_decl_BRDGSFD" = xyes; then :
69097   ac_have_decl=1
69098 else
69099   ac_have_decl=0
69100 fi
69101
69102 cat >>confdefs.h <<_ACEOF
69103 #define HAVE_DECL_BRDGSFD $ac_have_decl
69104 _ACEOF
69105 if test $ac_have_decl = 1; then :
69106
69107 $as_echo "#define HAVE_BSD_BRIDGE_MGMT 1" >>confdefs.h
69108
69109 fi
69110 ac_fn_c_check_decl "$LINENO" "BRDGADD" "ac_cv_have_decl_BRDGADD" "#include <stdint.h>
69111                 #include <net/if.h>
69112                 #include <net/ethernet.h>
69113                 #include <net/if_bridgevar.h>
69114
69115 "
69116 if test "x$ac_cv_have_decl_BRDGADD" = xyes; then :
69117   ac_have_decl=1
69118 else
69119   ac_have_decl=0
69120 fi
69121
69122 cat >>confdefs.h <<_ACEOF
69123 #define HAVE_DECL_BRDGADD $ac_have_decl
69124 _ACEOF
69125 if test $ac_have_decl = 1; then :
69126
69127 $as_echo "#define HAVE_BSD_BRIDGE_MGMT 1" >>confdefs.h
69128
69129 fi
69130 ac_fn_c_check_decl "$LINENO" "BRDGDEL" "ac_cv_have_decl_BRDGDEL" "#include <stdint.h>
69131                 #include <net/if.h>
69132                 #include <net/ethernet.h>
69133                 #include <net/if_bridgevar.h>
69134
69135 "
69136 if test "x$ac_cv_have_decl_BRDGDEL" = xyes; then :
69137   ac_have_decl=1
69138 else
69139   ac_have_decl=0
69140 fi
69141
69142 cat >>confdefs.h <<_ACEOF
69143 #define HAVE_DECL_BRDGDEL $ac_have_decl
69144 _ACEOF
69145 if test $ac_have_decl = 1; then :
69146
69147 $as_echo "#define HAVE_BSD_BRIDGE_MGMT 1" >>confdefs.h
69148
69149 fi
69150
69151
69152 # Check for BSD CPU affinity availability
69153 ac_fn_c_check_decl "$LINENO" "cpuset_getaffinity" "ac_cv_have_decl_cpuset_getaffinity" "#include <sys/param.h>
69154                 #include <sys/cpuset.h>
69155
69156 "
69157 if test "x$ac_cv_have_decl_cpuset_getaffinity" = xyes; then :
69158   ac_have_decl=1
69159 else
69160   ac_have_decl=0
69161 fi
69162
69163 cat >>confdefs.h <<_ACEOF
69164 #define HAVE_DECL_CPUSET_GETAFFINITY $ac_have_decl
69165 _ACEOF
69166 if test $ac_have_decl = 1; then :
69167
69168 $as_echo "#define HAVE_BSD_CPU_AFFINITY 1" >>confdefs.h
69169
69170 fi
69171
69172
69173 # Check for BSD kvm (kernel memory interface)
69174 if test $with_freebsd = yes; then
69175      { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kvm_getprocs in -lkvm" >&5
69176 $as_echo_n "checking for kvm_getprocs in -lkvm... " >&6; }
69177 if ${ac_cv_lib_kvm_kvm_getprocs+:} false; then :
69178   $as_echo_n "(cached) " >&6
69179 else
69180   ac_check_lib_save_LIBS=$LIBS
69181 LIBS="-lkvm  $LIBS"
69182 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
69183 /* end confdefs.h.  */
69184
69185 /* Override any GCC internal prototype to avoid an error.
69186    Use char because int might match the return type of a GCC
69187    builtin and then its argument prototype would still apply.  */
69188 #ifdef __cplusplus
69189 extern "C"
69190 #endif
69191 char kvm_getprocs ();
69192 int
69193 main ()
69194 {
69195 return kvm_getprocs ();
69196   ;
69197   return 0;
69198 }
69199 _ACEOF
69200 if ac_fn_c_try_link "$LINENO"; then :
69201   ac_cv_lib_kvm_kvm_getprocs=yes
69202 else
69203   ac_cv_lib_kvm_kvm_getprocs=no
69204 fi
69205 rm -f core conftest.err conftest.$ac_objext \
69206     conftest$ac_exeext conftest.$ac_ext
69207 LIBS=$ac_check_lib_save_LIBS
69208 fi
69209 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kvm_kvm_getprocs" >&5
69210 $as_echo "$ac_cv_lib_kvm_kvm_getprocs" >&6; }
69211 if test "x$ac_cv_lib_kvm_kvm_getprocs" = xyes; then :
69212   cat >>confdefs.h <<_ACEOF
69213 #define HAVE_LIBKVM 1
69214 _ACEOF
69215
69216   LIBS="-lkvm $LIBS"
69217
69218 else
69219   as_fn_error $? "BSD kernel memory interface library is required to build on FreeBSD" "$LINENO" 5
69220
69221 fi
69222
69223 fi
69224
69225 # Check if we need to look for ifconfig
69226 if test "$want_ifconfig" = "yes"; then
69227      # Extract the first word of "ifconfig", so it can be a program name with args.
69228 set dummy ifconfig; ac_word=$2
69229 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
69230 $as_echo_n "checking for $ac_word... " >&6; }
69231 if ${ac_cv_path_IFCONFIG_PATH+:} false; then :
69232   $as_echo_n "(cached) " >&6
69233 else
69234   case $IFCONFIG_PATH in
69235   [\\/]* | ?:[\\/]*)
69236   ac_cv_path_IFCONFIG_PATH="$IFCONFIG_PATH" # Let the user override the test with a path.
69237   ;;
69238   *)
69239   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
69240 for as_dir in $PATH
69241 do
69242   IFS=$as_save_IFS
69243   test -z "$as_dir" && as_dir=.
69244     for ac_exec_ext in '' $ac_executable_extensions; do
69245   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
69246     ac_cv_path_IFCONFIG_PATH="$as_dir/$ac_word$ac_exec_ext"
69247     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
69248     break 2
69249   fi
69250 done
69251   done
69252 IFS=$as_save_IFS
69253
69254   ;;
69255 esac
69256 fi
69257 IFCONFIG_PATH=$ac_cv_path_IFCONFIG_PATH
69258 if test -n "$IFCONFIG_PATH"; then
69259   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $IFCONFIG_PATH" >&5
69260 $as_echo "$IFCONFIG_PATH" >&6; }
69261 else
69262   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
69263 $as_echo "no" >&6; }
69264 fi
69265
69266
69267      if test -z "$IFCONFIG_PATH"; then
69268          as_fn_error $? "Failed to find ifconfig." "$LINENO" 5
69269      fi
69270
69271 cat >>confdefs.h <<_ACEOF
69272 #define IFCONFIG_PATH "$IFCONFIG_PATH"
69273 _ACEOF
69274
69275 fi
69276
69277 # Detect when running under the clang static analyzer's scan-build driver
69278 # or Coverity-prevent's cov-build.  Define STATIC_ANALYSIS accordingly.
69279 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether this build is done by a static analysis tool" >&5
69280 $as_echo_n "checking whether this build is done by a static analysis tool... " >&6; }
69281 if ${lv_cv_static_analysis+:} false; then :
69282   $as_echo_n "(cached) " >&6
69283 else
69284
69285     lv_cv_static_analysis=no
69286     if test -n "${CCC_ANALYZER_ANALYSIS+set}" || \
69287        test -n "$COVERITY_BUILD_COMMAND$COVERITY_LD_PRELOAD"; then
69288       lv_cv_static_analysis=yes
69289     fi
69290
69291 fi
69292 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lv_cv_static_analysis" >&5
69293 $as_echo "$lv_cv_static_analysis" >&6; }
69294 t=0
69295 test "x$lv_cv_static_analysis" = xyes && t=1
69296
69297 cat >>confdefs.h <<_ACEOF
69298 #define STATIC_ANALYSIS $t
69299 _ACEOF
69300
69301
69302 # Some GNULIB base64 symbols clash with a kerberos library
69303
69304 cat >>confdefs.h <<_ACEOF
69305 #define isbase64 libvirt_gl_isbase64
69306 _ACEOF
69307
69308
69309 cat >>confdefs.h <<_ACEOF
69310 #define base64_encode libvirt_gl_base64_encode
69311 _ACEOF
69312
69313
69314 cat >>confdefs.h <<_ACEOF
69315 #define base64_encode_alloc libvirt_gl_base64_encode_alloc
69316 _ACEOF
69317
69318
69319 ac_config_files="$ac_config_files run"
69320
69321 ac_config_files="$ac_config_files Makefile src/Makefile include/Makefile docs/Makefile docs/schemas/Makefile gnulib/lib/Makefile gnulib/tests/Makefile libvirt.pc libvirt.spec mingw-libvirt.spec po/Makefile.in include/libvirt/Makefile include/libvirt/libvirt.h daemon/Makefile tools/Makefile tests/Makefile examples/apparmor/Makefile examples/object-events/Makefile examples/domsuspend/Makefile examples/dominfo/Makefile examples/dommigrate/Makefile examples/openauth/Makefile examples/hellolibvirt/Makefile examples/systemtap/Makefile examples/xml/nwfilter/Makefile tools/wireshark/Makefile tools/wireshark/src/Makefile"
69322
69323 cat >confcache <<\_ACEOF
69324 # This file is a shell script that caches the results of configure
69325 # tests run on this system so they can be shared between configure
69326 # scripts and configure runs, see configure's option --config-cache.
69327 # It is not useful on other systems.  If it contains results you don't
69328 # want to keep, you may remove or edit it.
69329 #
69330 # config.status only pays attention to the cache file if you give it
69331 # the --recheck option to rerun configure.
69332 #
69333 # `ac_cv_env_foo' variables (set or unset) will be overridden when
69334 # loading this file, other *unset* `ac_cv_foo' will be assigned the
69335 # following values.
69336
69337 _ACEOF
69338
69339 # The following way of writing the cache mishandles newlines in values,
69340 # but we know of no workaround that is simple, portable, and efficient.
69341 # So, we kill variables containing newlines.
69342 # Ultrix sh set writes to stderr and can't be redirected directly,
69343 # and sets the high bit in the cache file unless we assign to the vars.
69344 (
69345   for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
69346     eval ac_val=\$$ac_var
69347     case $ac_val in #(
69348     *${as_nl}*)
69349       case $ac_var in #(
69350       *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
69351 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
69352       esac
69353       case $ac_var in #(
69354       _ | IFS | as_nl) ;; #(
69355       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
69356       *) { eval $ac_var=; unset $ac_var;} ;;
69357       esac ;;
69358     esac
69359   done
69360
69361   (set) 2>&1 |
69362     case $as_nl`(ac_space=' '; set) 2>&1` in #(
69363     *${as_nl}ac_space=\ *)
69364       # `set' does not quote correctly, so add quotes: double-quote
69365       # substitution turns \\\\ into \\, and sed turns \\ into \.
69366       sed -n \
69367         "s/'/'\\\\''/g;
69368           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
69369       ;; #(
69370     *)
69371       # `set' quotes correctly as required by POSIX, so do not add quotes.
69372       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
69373       ;;
69374     esac |
69375     sort
69376 ) |
69377   sed '
69378      /^ac_cv_env_/b end
69379      t clear
69380      :clear
69381      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
69382      t end
69383      s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
69384      :end' >>confcache
69385 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
69386   if test -w "$cache_file"; then
69387     if test "x$cache_file" != "x/dev/null"; then
69388       { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
69389 $as_echo "$as_me: updating cache $cache_file" >&6;}
69390       if test ! -f "$cache_file" || test -h "$cache_file"; then
69391         cat confcache >"$cache_file"
69392       else
69393         case $cache_file in #(
69394         */* | ?:*)
69395           mv -f confcache "$cache_file"$$ &&
69396           mv -f "$cache_file"$$ "$cache_file" ;; #(
69397         *)
69398           mv -f confcache "$cache_file" ;;
69399         esac
69400       fi
69401     fi
69402   else
69403     { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
69404 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
69405   fi
69406 fi
69407 rm -f confcache
69408
69409 test "x$prefix" = xNONE && prefix=$ac_default_prefix
69410 # Let make expand exec_prefix.
69411 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
69412
69413 DEFS=-DHAVE_CONFIG_H
69414
69415 ac_libobjs=
69416 ac_ltlibobjs=
69417 U=
69418 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
69419   # 1. Remove the extension, and $U if already installed.
69420   ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
69421   ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
69422   # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
69423   #    will be set to the directory where LIBOBJS objects are built.
69424   as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
69425   as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
69426 done
69427 LIBOBJS=$ac_libobjs
69428
69429 LTLIBOBJS=$ac_ltlibobjs
69430
69431
69432 { $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5
69433 $as_echo_n "checking that generated files are newer than configure... " >&6; }
69434    if test -n "$am_sleep_pid"; then
69435      # Hide warnings about reused PIDs.
69436      wait $am_sleep_pid 2>/dev/null
69437    fi
69438    { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5
69439 $as_echo "done" >&6; }
69440  if test -n "$EXEEXT"; then
69441   am__EXEEXT_TRUE=
69442   am__EXEEXT_FALSE='#'
69443 else
69444   am__EXEEXT_TRUE='#'
69445   am__EXEEXT_FALSE=
69446 fi
69447
69448 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
69449   as_fn_error $? "conditional \"AMDEP\" was never defined.
69450 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69451 fi
69452 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
69453   as_fn_error $? "conditional \"am__fastdepCC\" was never defined.
69454 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69455 fi
69456 if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then
69457   as_fn_error $? "conditional \"GL_COND_LIBTOOL\" was never defined.
69458 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69459 fi
69460 if test -z "${GL_GENERATE_ALLOCA_H_TRUE}" && test -z "${GL_GENERATE_ALLOCA_H_FALSE}"; then
69461   as_fn_error $? "conditional \"GL_GENERATE_ALLOCA_H\" was never defined.
69462 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69463 fi
69464 if test -z "${GL_GENERATE_BYTESWAP_H_TRUE}" && test -z "${GL_GENERATE_BYTESWAP_H_FALSE}"; then
69465   as_fn_error $? "conditional \"GL_GENERATE_BYTESWAP_H\" was never defined.
69466 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69467 fi
69468
69469 if test -z "${GL_GENERATE_ERRNO_H_TRUE}" && test -z "${GL_GENERATE_ERRNO_H_FALSE}"; then
69470   as_fn_error $? "conditional \"GL_GENERATE_ERRNO_H\" was never defined.
69471 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69472 fi
69473 if test -z "${GL_GENERATE_EXECINFO_H_TRUE}" && test -z "${GL_GENERATE_EXECINFO_H_FALSE}"; then
69474   as_fn_error $? "conditional \"GL_GENERATE_EXECINFO_H\" was never defined.
69475 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69476 fi
69477 if test -z "${GL_GENERATE_FLOAT_H_TRUE}" && test -z "${GL_GENERATE_FLOAT_H_FALSE}"; then
69478   as_fn_error $? "conditional \"GL_GENERATE_FLOAT_H\" was never defined.
69479 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69480 fi
69481 if test -z "${GL_GENERATE_FNMATCH_H_TRUE}" && test -z "${GL_GENERATE_FNMATCH_H_FALSE}"; then
69482   as_fn_error $? "conditional \"GL_GENERATE_FNMATCH_H\" was never defined.
69483 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69484 fi
69485 if test -z "${GL_GENERATE_STDDEF_H_TRUE}" && test -z "${GL_GENERATE_STDDEF_H_FALSE}"; then
69486   as_fn_error $? "conditional \"GL_GENERATE_STDDEF_H\" was never defined.
69487 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69488 fi
69489 CONFIG_INCLUDE=config.h
69490
69491 if test -z "${GL_GENERATE_NET_IF_H_TRUE}" && test -z "${GL_GENERATE_NET_IF_H_FALSE}"; then
69492   as_fn_error $? "conditional \"GL_GENERATE_NET_IF_H\" was never defined.
69493 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69494 fi
69495 if test -z "${GL_GENERATE_NETINET_IN_H_TRUE}" && test -z "${GL_GENERATE_NETINET_IN_H_FALSE}"; then
69496   as_fn_error $? "conditional \"GL_GENERATE_NETINET_IN_H\" was never defined.
69497 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69498 fi
69499 if test -z "${GL_GENERATE_PTHREAD_H_TRUE}" && test -z "${GL_GENERATE_PTHREAD_H_FALSE}"; then
69500   as_fn_error $? "conditional \"GL_GENERATE_PTHREAD_H\" was never defined.
69501 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69502 fi
69503 if test -z "${GL_GENERATE_SCHED_H_TRUE}" && test -z "${GL_GENERATE_SCHED_H_FALSE}"; then
69504   as_fn_error $? "conditional \"GL_GENERATE_SCHED_H\" was never defined.
69505 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69506 fi
69507 if test -z "${GL_GENERATE_STDALIGN_H_TRUE}" && test -z "${GL_GENERATE_STDALIGN_H_FALSE}"; then
69508   as_fn_error $? "conditional \"GL_GENERATE_STDALIGN_H\" was never defined.
69509 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69510 fi
69511 if test -z "${GL_GENERATE_STDARG_H_TRUE}" && test -z "${GL_GENERATE_STDARG_H_FALSE}"; then
69512   as_fn_error $? "conditional \"GL_GENERATE_STDARG_H\" was never defined.
69513 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69514 fi
69515 if test -z "${GL_GENERATE_STDBOOL_H_TRUE}" && test -z "${GL_GENERATE_STDBOOL_H_FALSE}"; then
69516   as_fn_error $? "conditional \"GL_GENERATE_STDBOOL_H\" was never defined.
69517 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69518 fi
69519 if test -z "${GL_GENERATE_STDDEF_H_TRUE}" && test -z "${GL_GENERATE_STDDEF_H_FALSE}"; then
69520   as_fn_error $? "conditional \"GL_GENERATE_STDDEF_H\" was never defined.
69521 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69522 fi
69523 if test -z "${GL_GENERATE_STDINT_H_TRUE}" && test -z "${GL_GENERATE_STDINT_H_FALSE}"; then
69524   as_fn_error $? "conditional \"GL_GENERATE_STDINT_H\" was never defined.
69525 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69526 fi
69527
69528
69529     gl_libobjs=
69530     gl_ltlibobjs=
69531     if test -n "$gl_LIBOBJS"; then
69532       # Remove the extension.
69533       sed_drop_objext='s/\.o$//;s/\.obj$//'
69534       for i in `for i in $gl_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
69535         gl_libobjs="$gl_libobjs $i.$ac_objext"
69536         gl_ltlibobjs="$gl_ltlibobjs $i.lo"
69537       done
69538     fi
69539     gl_LIBOBJS=$gl_libobjs
69540
69541     gl_LTLIBOBJS=$gl_ltlibobjs
69542
69543
69544
69545
69546
69547 if test -z "${POSIX_SPAWN_PORTED_TRUE}" && test -z "${POSIX_SPAWN_PORTED_FALSE}"; then
69548   as_fn_error $? "conditional \"POSIX_SPAWN_PORTED\" was never defined.
69549 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69550 fi
69551
69552     gltests_libobjs=
69553     gltests_ltlibobjs=
69554     if test -n "$gltests_LIBOBJS"; then
69555       # Remove the extension.
69556       sed_drop_objext='s/\.o$//;s/\.obj$//'
69557       for i in `for i in $gltests_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
69558         gltests_libobjs="$gltests_libobjs $i.$ac_objext"
69559         gltests_ltlibobjs="$gltests_ltlibobjs $i.lo"
69560       done
69561     fi
69562     gltests_LIBOBJS=$gltests_libobjs
69563
69564     gltests_LTLIBOBJS=$gltests_ltlibobjs
69565
69566
69567 if test -z "${WITH_LINUX_TRUE}" && test -z "${WITH_LINUX_FALSE}"; then
69568   as_fn_error $? "conditional \"WITH_LINUX\" was never defined.
69569 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69570 fi
69571 if test -z "${WITH_FREEBSD_TRUE}" && test -z "${WITH_FREEBSD_FALSE}"; then
69572   as_fn_error $? "conditional \"WITH_FREEBSD\" was never defined.
69573 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69574 fi
69575 if test -z "${WITH_APPARMOR_TRUE}" && test -z "${WITH_APPARMOR_FALSE}"; then
69576   as_fn_error $? "conditional \"WITH_APPARMOR\" was never defined.
69577 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69578 fi
69579 if test -z "${WITH_ATTR_TRUE}" && test -z "${WITH_ATTR_FALSE}"; then
69580   as_fn_error $? "conditional \"WITH_ATTR\" was never defined.
69581 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69582 fi
69583 if test -z "${WITH_AUDIT_TRUE}" && test -z "${WITH_AUDIT_FALSE}"; then
69584   as_fn_error $? "conditional \"WITH_AUDIT\" was never defined.
69585 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69586 fi
69587 if test -z "${WITH_AVAHI_TRUE}" && test -z "${WITH_AVAHI_FALSE}"; then
69588   as_fn_error $? "conditional \"WITH_AVAHI\" was never defined.
69589 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69590 fi
69591 if test -z "${WITH_BLKID_TRUE}" && test -z "${WITH_BLKID_FALSE}"; then
69592   as_fn_error $? "conditional \"WITH_BLKID\" was never defined.
69593 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69594 fi
69595 if test -z "${WITH_CAPNG_TRUE}" && test -z "${WITH_CAPNG_FALSE}"; then
69596   as_fn_error $? "conditional \"WITH_CAPNG\" was never defined.
69597 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69598 fi
69599 if test -z "${WITH_CURL_TRUE}" && test -z "${WITH_CURL_FALSE}"; then
69600   as_fn_error $? "conditional \"WITH_CURL\" was never defined.
69601 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69602 fi
69603 if test -z "${WITH_DBUS_TRUE}" && test -z "${WITH_DBUS_FALSE}"; then
69604   as_fn_error $? "conditional \"WITH_DBUS\" was never defined.
69605 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69606 fi
69607 if test -z "${WITH_FUSE_TRUE}" && test -z "${WITH_FUSE_FALSE}"; then
69608   as_fn_error $? "conditional \"WITH_FUSE\" was never defined.
69609 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69610 fi
69611 if test -z "${WITH_GLUSTERFS_TRUE}" && test -z "${WITH_GLUSTERFS_FALSE}"; then
69612   as_fn_error $? "conditional \"WITH_GLUSTERFS\" was never defined.
69613 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69614 fi
69615 if test -z "${WITH_HAL_TRUE}" && test -z "${WITH_HAL_FALSE}"; then
69616   as_fn_error $? "conditional \"WITH_HAL\" was never defined.
69617 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69618 fi
69619 if test -z "${WITH_NETCF_TRUE}" && test -z "${WITH_NETCF_FALSE}"; then
69620   as_fn_error $? "conditional \"WITH_NETCF\" was never defined.
69621 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69622 fi
69623 if test -z "${WITH_NUMACTL_TRUE}" && test -z "${WITH_NUMACTL_FALSE}"; then
69624   as_fn_error $? "conditional \"WITH_NUMACTL\" was never defined.
69625 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69626 fi
69627 if test -z "${WITH_OPENWSMAN_TRUE}" && test -z "${WITH_OPENWSMAN_FALSE}"; then
69628   as_fn_error $? "conditional \"WITH_OPENWSMAN\" was never defined.
69629 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69630 fi
69631 if test -z "${WITH_PCIACCESS_TRUE}" && test -z "${WITH_PCIACCESS_FALSE}"; then
69632   as_fn_error $? "conditional \"WITH_PCIACCESS\" was never defined.
69633 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69634 fi
69635 if test -z "${WITH_READLINE_TRUE}" && test -z "${WITH_READLINE_FALSE}"; then
69636   as_fn_error $? "conditional \"WITH_READLINE\" was never defined.
69637 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69638 fi
69639 if test -z "${WITH_SANLOCK_TRUE}" && test -z "${WITH_SANLOCK_FALSE}"; then
69640   as_fn_error $? "conditional \"WITH_SANLOCK\" was never defined.
69641 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69642 fi
69643 if test -z "${WITH_SASL_TRUE}" && test -z "${WITH_SASL_FALSE}"; then
69644   as_fn_error $? "conditional \"WITH_SASL\" was never defined.
69645 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69646 fi
69647 if test -z "${WITH_SASL1_TRUE}" && test -z "${WITH_SASL1_FALSE}"; then
69648   as_fn_error $? "conditional \"WITH_SASL1\" was never defined.
69649 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69650 fi
69651 if test -z "${WITH_SELINUX_TRUE}" && test -z "${WITH_SELINUX_FALSE}"; then
69652   as_fn_error $? "conditional \"WITH_SELINUX\" was never defined.
69653 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69654 fi
69655 if test -z "${WITH_SSH2_TRUE}" && test -z "${WITH_SSH2_FALSE}"; then
69656   as_fn_error $? "conditional \"WITH_SSH2\" was never defined.
69657 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69658 fi
69659 if test -z "${WITH_SYSTEMD_DAEMON_TRUE}" && test -z "${WITH_SYSTEMD_DAEMON_FALSE}"; then
69660   as_fn_error $? "conditional \"WITH_SYSTEMD_DAEMON\" was never defined.
69661 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69662 fi
69663 if test -z "${WITH_UDEV_TRUE}" && test -z "${WITH_UDEV_FALSE}"; then
69664   as_fn_error $? "conditional \"WITH_UDEV\" was never defined.
69665 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69666 fi
69667 if test -z "${WITH_YAJL_TRUE}" && test -z "${WITH_YAJL_FALSE}"; then
69668   as_fn_error $? "conditional \"WITH_YAJL\" was never defined.
69669 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69670 fi
69671 if test -z "${WITH_YAJL2_TRUE}" && test -z "${WITH_YAJL2_FALSE}"; then
69672   as_fn_error $? "conditional \"WITH_YAJL2\" was never defined.
69673 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69674 fi
69675 if test -z "${WITH_ATOMIC_OPS_PTHREAD_TRUE}" && test -z "${WITH_ATOMIC_OPS_PTHREAD_FALSE}"; then
69676   as_fn_error $? "conditional \"WITH_ATOMIC_OPS_PTHREAD\" was never defined.
69677 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69678 fi
69679 if test -z "${HAVE_LIBTASN1_TRUE}" && test -z "${HAVE_LIBTASN1_FALSE}"; then
69680   as_fn_error $? "conditional \"HAVE_LIBTASN1\" was never defined.
69681 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69682 fi
69683 if test -z "${HAVE_RPCGEN_TRUE}" && test -z "${HAVE_RPCGEN_FALSE}"; then
69684   as_fn_error $? "conditional \"HAVE_RPCGEN\" was never defined.
69685 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69686 fi
69687 if test -z "${HAVE_GLIBC_RPCGEN_TRUE}" && test -z "${HAVE_GLIBC_RPCGEN_FALSE}"; then
69688   as_fn_error $? "conditional \"HAVE_GLIBC_RPCGEN\" was never defined.
69689 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69690 fi
69691 if test -z "${ENABLE_DEBUG_TRUE}" && test -z "${ENABLE_DEBUG_FALSE}"; then
69692   as_fn_error $? "conditional \"ENABLE_DEBUG\" was never defined.
69693 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69694 fi
69695 if test -z "${LIBVIRT_INIT_SCRIPT_RED_HAT_TRUE}" && test -z "${LIBVIRT_INIT_SCRIPT_RED_HAT_FALSE}"; then
69696   as_fn_error $? "conditional \"LIBVIRT_INIT_SCRIPT_RED_HAT\" was never defined.
69697 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69698 fi
69699 if test -z "${LIBVIRT_INIT_SCRIPT_UPSTART_TRUE}" && test -z "${LIBVIRT_INIT_SCRIPT_UPSTART_FALSE}"; then
69700   as_fn_error $? "conditional \"LIBVIRT_INIT_SCRIPT_UPSTART\" was never defined.
69701 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69702 fi
69703 if test -z "${LIBVIRT_INIT_SCRIPT_SYSTEMD_TRUE}" && test -z "${LIBVIRT_INIT_SCRIPT_SYSTEMD_FALSE}"; then
69704   as_fn_error $? "conditional \"LIBVIRT_INIT_SCRIPT_SYSTEMD\" was never defined.
69705 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69706 fi
69707 if test -z "${WITH_SYSCTL_TRUE}" && test -z "${WITH_SYSCTL_FALSE}"; then
69708   as_fn_error $? "conditional \"WITH_SYSCTL\" was never defined.
69709 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69710 fi
69711 if test -z "${WITH_OPENVZ_TRUE}" && test -z "${WITH_OPENVZ_FALSE}"; then
69712   as_fn_error $? "conditional \"WITH_OPENVZ\" was never defined.
69713 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69714 fi
69715 if test -z "${WITH_VMWARE_TRUE}" && test -z "${WITH_VMWARE_FALSE}"; then
69716   as_fn_error $? "conditional \"WITH_VMWARE\" was never defined.
69717 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69718 fi
69719 if test -z "${WITH_VBOX_TRUE}" && test -z "${WITH_VBOX_FALSE}"; then
69720   as_fn_error $? "conditional \"WITH_VBOX\" was never defined.
69721 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69722 fi
69723 if test -z "${WITH_QEMU_TRUE}" && test -z "${WITH_QEMU_FALSE}"; then
69724   as_fn_error $? "conditional \"WITH_QEMU\" was never defined.
69725 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69726 fi
69727 if test -z "${WITH_TEST_TRUE}" && test -z "${WITH_TEST_FALSE}"; then
69728   as_fn_error $? "conditional \"WITH_TEST\" was never defined.
69729 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69730 fi
69731 if test -z "${WITH_REMOTE_TRUE}" && test -z "${WITH_REMOTE_FALSE}"; then
69732   as_fn_error $? "conditional \"WITH_REMOTE\" was never defined.
69733 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69734 fi
69735 if test -z "${WITH_LIBVIRTD_TRUE}" && test -z "${WITH_LIBVIRTD_FALSE}"; then
69736   as_fn_error $? "conditional \"WITH_LIBVIRTD\" was never defined.
69737 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69738 fi
69739 if test -z "${WITH_LIBXL_TRUE}" && test -z "${WITH_LIBXL_FALSE}"; then
69740   as_fn_error $? "conditional \"WITH_LIBXL\" was never defined.
69741 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69742 fi
69743 if test -z "${WITH_XEN_TRUE}" && test -z "${WITH_XEN_FALSE}"; then
69744   as_fn_error $? "conditional \"WITH_XEN\" was never defined.
69745 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69746 fi
69747 if test -z "${WITH_XENXS_TRUE}" && test -z "${WITH_XENXS_FALSE}"; then
69748   as_fn_error $? "conditional \"WITH_XENXS\" was never defined.
69749 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69750 fi
69751 if test -z "${WITH_XEN_INOTIFY_TRUE}" && test -z "${WITH_XEN_INOTIFY_FALSE}"; then
69752   as_fn_error $? "conditional \"WITH_XEN_INOTIFY\" was never defined.
69753 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69754 fi
69755 if test -z "${WITH_LXC_TRUE}" && test -z "${WITH_LXC_FALSE}"; then
69756   as_fn_error $? "conditional \"WITH_LXC\" was never defined.
69757 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69758 fi
69759 if test -z "${WITH_PARALLELS_TRUE}" && test -z "${WITH_PARALLELS_FALSE}"; then
69760   as_fn_error $? "conditional \"WITH_PARALLELS\" was never defined.
69761 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69762 fi
69763 if test -z "${WITH_BHYVE_TRUE}" && test -z "${WITH_BHYVE_FALSE}"; then
69764   as_fn_error $? "conditional \"WITH_BHYVE\" was never defined.
69765 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69766 fi
69767 if test -z "${WITH_GNUTLS_TRUE}" && test -z "${WITH_GNUTLS_FALSE}"; then
69768   as_fn_error $? "conditional \"WITH_GNUTLS\" was never defined.
69769 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69770 fi
69771 if test -z "${WITH_POLKIT_TRUE}" && test -z "${WITH_POLKIT_FALSE}"; then
69772   as_fn_error $? "conditional \"WITH_POLKIT\" was never defined.
69773 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69774 fi
69775 if test -z "${WITH_POLKIT0_TRUE}" && test -z "${WITH_POLKIT0_FALSE}"; then
69776   as_fn_error $? "conditional \"WITH_POLKIT0\" was never defined.
69777 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69778 fi
69779 if test -z "${WITH_POLKIT1_TRUE}" && test -z "${WITH_POLKIT1_FALSE}"; then
69780   as_fn_error $? "conditional \"WITH_POLKIT1\" was never defined.
69781 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69782 fi
69783 if test -z "${HAVE_FIREWALLD_TRUE}" && test -z "${HAVE_FIREWALLD_FALSE}"; then
69784   as_fn_error $? "conditional \"HAVE_FIREWALLD\" was never defined.
69785 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69786 fi
69787 if test -z "${VIR_CHRDEV_LOCK_FILE_PATH_TRUE}" && test -z "${VIR_CHRDEV_LOCK_FILE_PATH_FALSE}"; then
69788   as_fn_error $? "conditional \"VIR_CHRDEV_LOCK_FILE_PATH\" was never defined.
69789 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69790 fi
69791 if test -z "${WITH_SECDRIVER_SELINUX_TRUE}" && test -z "${WITH_SECDRIVER_SELINUX_FALSE}"; then
69792   as_fn_error $? "conditional \"WITH_SECDRIVER_SELINUX\" was never defined.
69793 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69794 fi
69795 if test -z "${WITH_SECDRIVER_APPARMOR_TRUE}" && test -z "${WITH_SECDRIVER_APPARMOR_FALSE}"; then
69796   as_fn_error $? "conditional \"WITH_SECDRIVER_APPARMOR\" was never defined.
69797 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69798 fi
69799 if test -z "${WITH_APPARMOR_PROFILES_TRUE}" && test -z "${WITH_APPARMOR_PROFILES_FALSE}"; then
69800   as_fn_error $? "conditional \"WITH_APPARMOR_PROFILES\" was never defined.
69801 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69802 fi
69803 if test -z "${WITH_DTRACE_PROBES_TRUE}" && test -z "${WITH_DTRACE_PROBES_FALSE}"; then
69804   as_fn_error $? "conditional \"WITH_DTRACE_PROBES\" was never defined.
69805 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69806 fi
69807 if test -z "${HAVE_NUMAD_TRUE}" && test -z "${HAVE_NUMAD_FALSE}"; then
69808   as_fn_error $? "conditional \"HAVE_NUMAD\" was never defined.
69809 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69810 fi
69811 if test -z "${WITH_UML_TRUE}" && test -z "${WITH_UML_FALSE}"; then
69812   as_fn_error $? "conditional \"WITH_UML\" was never defined.
69813 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69814 fi
69815 if test -z "${WITH_PHYP_TRUE}" && test -z "${WITH_PHYP_FALSE}"; then
69816   as_fn_error $? "conditional \"WITH_PHYP\" was never defined.
69817 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69818 fi
69819 if test -z "${WITH_PM_UTILS_TRUE}" && test -z "${WITH_PM_UTILS_FALSE}"; then
69820   as_fn_error $? "conditional \"WITH_PM_UTILS\" was never defined.
69821 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69822 fi
69823 if test -z "${WITH_NETWORK_TRUE}" && test -z "${WITH_NETWORK_FALSE}"; then
69824   as_fn_error $? "conditional \"WITH_NETWORK\" was never defined.
69825 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69826 fi
69827 if test -z "${WITH_BRIDGE_TRUE}" && test -z "${WITH_BRIDGE_FALSE}"; then
69828   as_fn_error $? "conditional \"WITH_BRIDGE\" was never defined.
69829 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69830 fi
69831 if test -z "${WITH_SECRETS_TRUE}" && test -z "${WITH_SECRETS_FALSE}"; then
69832   as_fn_error $? "conditional \"WITH_SECRETS\" was never defined.
69833 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69834 fi
69835 if test -z "${WITH_STORAGE_DIR_TRUE}" && test -z "${WITH_STORAGE_DIR_FALSE}"; then
69836   as_fn_error $? "conditional \"WITH_STORAGE_DIR\" was never defined.
69837 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69838 fi
69839 if test -z "${WITH_STORAGE_FS_TRUE}" && test -z "${WITH_STORAGE_FS_FALSE}"; then
69840   as_fn_error $? "conditional \"WITH_STORAGE_FS\" was never defined.
69841 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69842 fi
69843 if test -z "${WITH_STORAGE_LVM_TRUE}" && test -z "${WITH_STORAGE_LVM_FALSE}"; then
69844   as_fn_error $? "conditional \"WITH_STORAGE_LVM\" was never defined.
69845 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69846 fi
69847 if test -z "${WITH_STORAGE_ISCSI_TRUE}" && test -z "${WITH_STORAGE_ISCSI_FALSE}"; then
69848   as_fn_error $? "conditional \"WITH_STORAGE_ISCSI\" was never defined.
69849 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69850 fi
69851 if test -z "${WITH_STORAGE_SCSI_TRUE}" && test -z "${WITH_STORAGE_SCSI_FALSE}"; then
69852   as_fn_error $? "conditional \"WITH_STORAGE_SCSI\" was never defined.
69853 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69854 fi
69855 if test -z "${WITH_STORAGE_MPATH_TRUE}" && test -z "${WITH_STORAGE_MPATH_FALSE}"; then
69856   as_fn_error $? "conditional \"WITH_STORAGE_MPATH\" was never defined.
69857 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69858 fi
69859 if test -z "${WITH_STORAGE_RBD_TRUE}" && test -z "${WITH_STORAGE_RBD_FALSE}"; then
69860   as_fn_error $? "conditional \"WITH_STORAGE_RBD\" was never defined.
69861 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69862 fi
69863 if test -z "${WITH_STORAGE_SHEEPDOG_TRUE}" && test -z "${WITH_STORAGE_SHEEPDOG_FALSE}"; then
69864   as_fn_error $? "conditional \"WITH_STORAGE_SHEEPDOG\" was never defined.
69865 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69866 fi
69867 if test -z "${WITH_STORAGE_GLUSTER_TRUE}" && test -z "${WITH_STORAGE_GLUSTER_FALSE}"; then
69868   as_fn_error $? "conditional \"WITH_STORAGE_GLUSTER\" was never defined.
69869 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69870 fi
69871 if test -z "${WITH_STORAGE_DISK_TRUE}" && test -z "${WITH_STORAGE_DISK_FALSE}"; then
69872   as_fn_error $? "conditional \"WITH_STORAGE_DISK\" was never defined.
69873 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69874 fi
69875 if test -z "${WITH_STORAGE_TRUE}" && test -z "${WITH_STORAGE_FALSE}"; then
69876   as_fn_error $? "conditional \"WITH_STORAGE\" was never defined.
69877 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69878 fi
69879 if test -z "${WITH_ESX_TRUE}" && test -z "${WITH_ESX_FALSE}"; then
69880   as_fn_error $? "conditional \"WITH_ESX\" was never defined.
69881 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69882 fi
69883 if test -z "${WITH_VMX_TRUE}" && test -z "${WITH_VMX_FALSE}"; then
69884   as_fn_error $? "conditional \"WITH_VMX\" was never defined.
69885 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69886 fi
69887 if test -z "${WITH_XENAPI_TRUE}" && test -z "${WITH_XENAPI_FALSE}"; then
69888   as_fn_error $? "conditional \"WITH_XENAPI\" was never defined.
69889 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69890 fi
69891 if test -z "${WITH_HYPERV_TRUE}" && test -z "${WITH_HYPERV_FALSE}"; then
69892   as_fn_error $? "conditional \"WITH_HYPERV\" was never defined.
69893 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69894 fi
69895 if test -z "${WITH_TESTS_TRUE}" && test -z "${WITH_TESTS_FALSE}"; then
69896   as_fn_error $? "conditional \"WITH_TESTS\" was never defined.
69897 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69898 fi
69899 if test -z "${WITH_EXPENSIVE_TESTS_TRUE}" && test -z "${WITH_EXPENSIVE_TESTS_FALSE}"; then
69900   as_fn_error $? "conditional \"WITH_EXPENSIVE_TESTS\" was never defined.
69901 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69902 fi
69903 if test -z "${WITH_CIL_TRUE}" && test -z "${WITH_CIL_FALSE}"; then
69904   as_fn_error $? "conditional \"WITH_CIL\" was never defined.
69905 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69906 fi
69907 if test -z "${WITH_LIBVIRTD_TRUE}" && test -z "${WITH_LIBVIRTD_FALSE}"; then
69908   as_fn_error $? "conditional \"WITH_LIBVIRTD\" was never defined.
69909 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69910 fi
69911 if test -z "${WITH_WIN_ICON_TRUE}" && test -z "${WITH_WIN_ICON_FALSE}"; then
69912   as_fn_error $? "conditional \"WITH_WIN_ICON\" was never defined.
69913 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69914 fi
69915 if test -z "${WITH_DRIVER_MODULES_TRUE}" && test -z "${WITH_DRIVER_MODULES_FALSE}"; then
69916   as_fn_error $? "conditional \"WITH_DRIVER_MODULES\" was never defined.
69917 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69918 fi
69919 if test -z "${WITH_NODE_DEVICES_TRUE}" && test -z "${WITH_NODE_DEVICES_FALSE}"; then
69920   as_fn_error $? "conditional \"WITH_NODE_DEVICES\" was never defined.
69921 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69922 fi
69923 if test -z "${WITH_NWFILTER_TRUE}" && test -z "${WITH_NWFILTER_FALSE}"; then
69924   as_fn_error $? "conditional \"WITH_NWFILTER\" was never defined.
69925 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69926 fi
69927 if test -z "${WITH_INTERFACE_TRUE}" && test -z "${WITH_INTERFACE_FALSE}"; then
69928   as_fn_error $? "conditional \"WITH_INTERFACE\" was never defined.
69929 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69930 fi
69931 if test -z "${WITH_MACVTAP_TRUE}" && test -z "${WITH_MACVTAP_FALSE}"; then
69932   as_fn_error $? "conditional \"WITH_MACVTAP\" was never defined.
69933 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69934 fi
69935 if test -z "${WITH_VIRTUALPORT_TRUE}" && test -z "${WITH_VIRTUALPORT_FALSE}"; then
69936   as_fn_error $? "conditional \"WITH_VIRTUALPORT\" was never defined.
69937 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69938 fi
69939 if test -z "${HAVE_LIBNL_TRUE}" && test -z "${HAVE_LIBNL_FALSE}"; then
69940   as_fn_error $? "conditional \"HAVE_LIBNL\" was never defined.
69941 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69942 fi
69943 if test -z "${WITH_WIRESHARK_DISSECTOR_TRUE}" && test -z "${WITH_WIRESHARK_DISSECTOR_FALSE}"; then
69944   as_fn_error $? "conditional \"WITH_WIRESHARK_DISSECTOR\" was never defined.
69945 Usually this means the macro was only invoked conditionally." "$LINENO" 5
69946 fi
69947
69948 : "${CONFIG_STATUS=./config.status}"
69949 ac_write_fail=0
69950 ac_clean_files_save=$ac_clean_files
69951 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
69952 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
69953 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
69954 as_write_fail=0
69955 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
69956 #! $SHELL
69957 # Generated by $as_me.
69958 # Run this file to recreate the current configuration.
69959 # Compiler output produced by configure, useful for debugging
69960 # configure, is in config.log if it exists.
69961
69962 debug=false
69963 ac_cs_recheck=false
69964 ac_cs_silent=false
69965
69966 SHELL=\${CONFIG_SHELL-$SHELL}
69967 export SHELL
69968 _ASEOF
69969 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
69970 ## -------------------- ##
69971 ## M4sh Initialization. ##
69972 ## -------------------- ##
69973
69974 # Be more Bourne compatible
69975 DUALCASE=1; export DUALCASE # for MKS sh
69976 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
69977   emulate sh
69978   NULLCMD=:
69979   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
69980   # is contrary to our usage.  Disable this feature.
69981   alias -g '${1+"$@"}'='"$@"'
69982   setopt NO_GLOB_SUBST
69983 else
69984   case `(set -o) 2>/dev/null` in #(
69985   *posix*) :
69986     set -o posix ;; #(
69987   *) :
69988      ;;
69989 esac
69990 fi
69991
69992
69993 as_nl='
69994 '
69995 export as_nl
69996 # Printing a long string crashes Solaris 7 /usr/bin/printf.
69997 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
69998 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
69999 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
70000 # Prefer a ksh shell builtin over an external printf program on Solaris,
70001 # but without wasting forks for bash or zsh.
70002 if test -z "$BASH_VERSION$ZSH_VERSION" \
70003     && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
70004   as_echo='print -r --'
70005   as_echo_n='print -rn --'
70006 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
70007   as_echo='printf %s\n'
70008   as_echo_n='printf %s'
70009 else
70010   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
70011     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
70012     as_echo_n='/usr/ucb/echo -n'
70013   else
70014     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
70015     as_echo_n_body='eval
70016       arg=$1;
70017       case $arg in #(
70018       *"$as_nl"*)
70019         expr "X$arg" : "X\\(.*\\)$as_nl";
70020         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
70021       esac;
70022       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
70023     '
70024     export as_echo_n_body
70025     as_echo_n='sh -c $as_echo_n_body as_echo'
70026   fi
70027   export as_echo_body
70028   as_echo='sh -c $as_echo_body as_echo'
70029 fi
70030
70031 # The user is always right.
70032 if test "${PATH_SEPARATOR+set}" != set; then
70033   PATH_SEPARATOR=:
70034   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
70035     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
70036       PATH_SEPARATOR=';'
70037   }
70038 fi
70039
70040
70041 # IFS
70042 # We need space, tab and new line, in precisely that order.  Quoting is
70043 # there to prevent editors from complaining about space-tab.
70044 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
70045 # splitting by setting IFS to empty value.)
70046 IFS=" ""        $as_nl"
70047
70048 # Find who we are.  Look in the path if we contain no directory separator.
70049 as_myself=
70050 case $0 in #((
70051   *[\\/]* ) as_myself=$0 ;;
70052   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
70053 for as_dir in $PATH
70054 do
70055   IFS=$as_save_IFS
70056   test -z "$as_dir" && as_dir=.
70057     test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
70058   done
70059 IFS=$as_save_IFS
70060
70061      ;;
70062 esac
70063 # We did not find ourselves, most probably we were run as `sh COMMAND'
70064 # in which case we are not to be found in the path.
70065 if test "x$as_myself" = x; then
70066   as_myself=$0
70067 fi
70068 if test ! -f "$as_myself"; then
70069   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
70070   exit 1
70071 fi
70072
70073 # Unset variables that we do not need and which cause bugs (e.g. in
70074 # pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
70075 # suppresses any "Segmentation fault" message there.  '((' could
70076 # trigger a bug in pdksh 5.2.14.
70077 for as_var in BASH_ENV ENV MAIL MAILPATH
70078 do eval test x\${$as_var+set} = xset \
70079   && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
70080 done
70081 PS1='$ '
70082 PS2='> '
70083 PS4='+ '
70084
70085 # NLS nuisances.
70086 LC_ALL=C
70087 export LC_ALL
70088 LANGUAGE=C
70089 export LANGUAGE
70090
70091 # CDPATH.
70092 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
70093
70094
70095 # as_fn_error STATUS ERROR [LINENO LOG_FD]
70096 # ----------------------------------------
70097 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
70098 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
70099 # script with STATUS, using 1 if that was 0.
70100 as_fn_error ()
70101 {
70102   as_status=$1; test $as_status -eq 0 && as_status=1
70103   if test "$4"; then
70104     as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
70105     $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
70106   fi
70107   $as_echo "$as_me: error: $2" >&2
70108   as_fn_exit $as_status
70109 } # as_fn_error
70110
70111
70112 # as_fn_set_status STATUS
70113 # -----------------------
70114 # Set $? to STATUS, without forking.
70115 as_fn_set_status ()
70116 {
70117   return $1
70118 } # as_fn_set_status
70119
70120 # as_fn_exit STATUS
70121 # -----------------
70122 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
70123 as_fn_exit ()
70124 {
70125   set +e
70126   as_fn_set_status $1
70127   exit $1
70128 } # as_fn_exit
70129
70130 # as_fn_unset VAR
70131 # ---------------
70132 # Portably unset VAR.
70133 as_fn_unset ()
70134 {
70135   { eval $1=; unset $1;}
70136 }
70137 as_unset=as_fn_unset
70138 # as_fn_append VAR VALUE
70139 # ----------------------
70140 # Append the text in VALUE to the end of the definition contained in VAR. Take
70141 # advantage of any shell optimizations that allow amortized linear growth over
70142 # repeated appends, instead of the typical quadratic growth present in naive
70143 # implementations.
70144 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
70145   eval 'as_fn_append ()
70146   {
70147     eval $1+=\$2
70148   }'
70149 else
70150   as_fn_append ()
70151   {
70152     eval $1=\$$1\$2
70153   }
70154 fi # as_fn_append
70155
70156 # as_fn_arith ARG...
70157 # ------------------
70158 # Perform arithmetic evaluation on the ARGs, and store the result in the
70159 # global $as_val. Take advantage of shells that can avoid forks. The arguments
70160 # must be portable across $(()) and expr.
70161 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
70162   eval 'as_fn_arith ()
70163   {
70164     as_val=$(( $* ))
70165   }'
70166 else
70167   as_fn_arith ()
70168   {
70169     as_val=`expr "$@" || test $? -eq 1`
70170   }
70171 fi # as_fn_arith
70172
70173
70174 if expr a : '\(a\)' >/dev/null 2>&1 &&
70175    test "X`expr 00001 : '.*\(...\)'`" = X001; then
70176   as_expr=expr
70177 else
70178   as_expr=false
70179 fi
70180
70181 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
70182   as_basename=basename
70183 else
70184   as_basename=false
70185 fi
70186
70187 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
70188   as_dirname=dirname
70189 else
70190   as_dirname=false
70191 fi
70192
70193 as_me=`$as_basename -- "$0" ||
70194 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
70195          X"$0" : 'X\(//\)$' \| \
70196          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
70197 $as_echo X/"$0" |
70198     sed '/^.*\/\([^/][^/]*\)\/*$/{
70199             s//\1/
70200             q
70201           }
70202           /^X\/\(\/\/\)$/{
70203             s//\1/
70204             q
70205           }
70206           /^X\/\(\/\).*/{
70207             s//\1/
70208             q
70209           }
70210           s/.*/./; q'`
70211
70212 # Avoid depending upon Character Ranges.
70213 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
70214 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
70215 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
70216 as_cr_digits='0123456789'
70217 as_cr_alnum=$as_cr_Letters$as_cr_digits
70218
70219 ECHO_C= ECHO_N= ECHO_T=
70220 case `echo -n x` in #(((((
70221 -n*)
70222   case `echo 'xy\c'` in
70223   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
70224   xy)  ECHO_C='\c';;
70225   *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
70226        ECHO_T=' ';;
70227   esac;;
70228 *)
70229   ECHO_N='-n';;
70230 esac
70231
70232 rm -f conf$$ conf$$.exe conf$$.file
70233 if test -d conf$$.dir; then
70234   rm -f conf$$.dir/conf$$.file
70235 else
70236   rm -f conf$$.dir
70237   mkdir conf$$.dir 2>/dev/null
70238 fi
70239 if (echo >conf$$.file) 2>/dev/null; then
70240   if ln -s conf$$.file conf$$ 2>/dev/null; then
70241     as_ln_s='ln -s'
70242     # ... but there are two gotchas:
70243     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
70244     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
70245     # In both cases, we have to default to `cp -pR'.
70246     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
70247       as_ln_s='cp -pR'
70248   elif ln conf$$.file conf$$ 2>/dev/null; then
70249     as_ln_s=ln
70250   else
70251     as_ln_s='cp -pR'
70252   fi
70253 else
70254   as_ln_s='cp -pR'
70255 fi
70256 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
70257 rmdir conf$$.dir 2>/dev/null
70258
70259
70260 # as_fn_mkdir_p
70261 # -------------
70262 # Create "$as_dir" as a directory, including parents if necessary.
70263 as_fn_mkdir_p ()
70264 {
70265
70266   case $as_dir in #(
70267   -*) as_dir=./$as_dir;;
70268   esac
70269   test -d "$as_dir" || eval $as_mkdir_p || {
70270     as_dirs=
70271     while :; do
70272       case $as_dir in #(
70273       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
70274       *) as_qdir=$as_dir;;
70275       esac
70276       as_dirs="'$as_qdir' $as_dirs"
70277       as_dir=`$as_dirname -- "$as_dir" ||
70278 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
70279          X"$as_dir" : 'X\(//\)[^/]' \| \
70280          X"$as_dir" : 'X\(//\)$' \| \
70281          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
70282 $as_echo X"$as_dir" |
70283     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
70284             s//\1/
70285             q
70286           }
70287           /^X\(\/\/\)[^/].*/{
70288             s//\1/
70289             q
70290           }
70291           /^X\(\/\/\)$/{
70292             s//\1/
70293             q
70294           }
70295           /^X\(\/\).*/{
70296             s//\1/
70297             q
70298           }
70299           s/.*/./; q'`
70300       test -d "$as_dir" && break
70301     done
70302     test -z "$as_dirs" || eval "mkdir $as_dirs"
70303   } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
70304
70305
70306 } # as_fn_mkdir_p
70307 if mkdir -p . 2>/dev/null; then
70308   as_mkdir_p='mkdir -p "$as_dir"'
70309 else
70310   test -d ./-p && rmdir ./-p
70311   as_mkdir_p=false
70312 fi
70313
70314
70315 # as_fn_executable_p FILE
70316 # -----------------------
70317 # Test if FILE is an executable regular file.
70318 as_fn_executable_p ()
70319 {
70320   test -f "$1" && test -x "$1"
70321 } # as_fn_executable_p
70322 as_test_x='test -x'
70323 as_executable_p=as_fn_executable_p
70324
70325 # Sed expression to map a string onto a valid CPP name.
70326 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
70327
70328 # Sed expression to map a string onto a valid variable name.
70329 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
70330
70331
70332 exec 6>&1
70333 ## ----------------------------------- ##
70334 ## Main body of $CONFIG_STATUS script. ##
70335 ## ----------------------------------- ##
70336 _ASEOF
70337 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
70338
70339 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
70340 # Save the log message, to keep $0 and so on meaningful, and to
70341 # report actual input values of CONFIG_FILES etc. instead of their
70342 # values after options handling.
70343 ac_log="
70344 This file was extended by libvirt $as_me 1.2.5, which was
70345 generated by GNU Autoconf 2.69.  Invocation command line was
70346
70347   CONFIG_FILES    = $CONFIG_FILES
70348   CONFIG_HEADERS  = $CONFIG_HEADERS
70349   CONFIG_LINKS    = $CONFIG_LINKS
70350   CONFIG_COMMANDS = $CONFIG_COMMANDS
70351   $ $0 $@
70352
70353 on `(hostname || uname -n) 2>/dev/null | sed 1q`
70354 "
70355
70356 _ACEOF
70357
70358 case $ac_config_files in *"
70359 "*) set x $ac_config_files; shift; ac_config_files=$*;;
70360 esac
70361
70362 case $ac_config_headers in *"
70363 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
70364 esac
70365
70366
70367 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
70368 # Files that config.status was made for.
70369 config_files="$ac_config_files"
70370 config_headers="$ac_config_headers"
70371 config_links="$ac_config_links"
70372 config_commands="$ac_config_commands"
70373
70374 _ACEOF
70375
70376 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
70377 ac_cs_usage="\
70378 \`$as_me' instantiates files and other configuration actions
70379 from templates according to the current configuration.  Unless the files
70380 and actions are specified as TAGs, all are instantiated by default.
70381
70382 Usage: $0 [OPTION]... [TAG]...
70383
70384   -h, --help       print this help, then exit
70385   -V, --version    print version number and configuration settings, then exit
70386       --config     print configuration, then exit
70387   -q, --quiet, --silent
70388                    do not print progress messages
70389   -d, --debug      don't remove temporary files
70390       --recheck    update $as_me by reconfiguring in the same conditions
70391       --file=FILE[:TEMPLATE]
70392                    instantiate the configuration file FILE
70393       --header=FILE[:TEMPLATE]
70394                    instantiate the configuration header FILE
70395
70396 Configuration files:
70397 $config_files
70398
70399 Configuration headers:
70400 $config_headers
70401
70402 Configuration links:
70403 $config_links
70404
70405 Configuration commands:
70406 $config_commands
70407
70408 Report bugs to <libvir-list@redhat.com>.
70409 libvirt home page: <http://libvirt.org>."
70410
70411 _ACEOF
70412 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
70413 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
70414 ac_cs_version="\\
70415 libvirt config.status 1.2.5
70416 configured by $0, generated by GNU Autoconf 2.69,
70417   with options \\"\$ac_cs_config\\"
70418
70419 Copyright (C) 2012 Free Software Foundation, Inc.
70420 This config.status script is free software; the Free Software Foundation
70421 gives unlimited permission to copy, distribute and modify it."
70422
70423 ac_pwd='$ac_pwd'
70424 srcdir='$srcdir'
70425 INSTALL='$INSTALL'
70426 MKDIR_P='$MKDIR_P'
70427 AWK='$AWK'
70428 test -n "\$AWK" || AWK=awk
70429 _ACEOF
70430
70431 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
70432 # The default lists apply if the user does not specify any file.
70433 ac_need_defaults=:
70434 while test $# != 0
70435 do
70436   case $1 in
70437   --*=?*)
70438     ac_option=`expr "X$1" : 'X\([^=]*\)='`
70439     ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
70440     ac_shift=:
70441     ;;
70442   --*=)
70443     ac_option=`expr "X$1" : 'X\([^=]*\)='`
70444     ac_optarg=
70445     ac_shift=:
70446     ;;
70447   *)
70448     ac_option=$1
70449     ac_optarg=$2
70450     ac_shift=shift
70451     ;;
70452   esac
70453
70454   case $ac_option in
70455   # Handling of the options.
70456   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
70457     ac_cs_recheck=: ;;
70458   --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
70459     $as_echo "$ac_cs_version"; exit ;;
70460   --config | --confi | --conf | --con | --co | --c )
70461     $as_echo "$ac_cs_config"; exit ;;
70462   --debug | --debu | --deb | --de | --d | -d )
70463     debug=: ;;
70464   --file | --fil | --fi | --f )
70465     $ac_shift
70466     case $ac_optarg in
70467     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
70468     '') as_fn_error $? "missing file argument" ;;
70469     esac
70470     as_fn_append CONFIG_FILES " '$ac_optarg'"
70471     ac_need_defaults=false;;
70472   --header | --heade | --head | --hea )
70473     $ac_shift
70474     case $ac_optarg in
70475     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
70476     esac
70477     as_fn_append CONFIG_HEADERS " '$ac_optarg'"
70478     ac_need_defaults=false;;
70479   --he | --h)
70480     # Conflict between --help and --header
70481     as_fn_error $? "ambiguous option: \`$1'
70482 Try \`$0 --help' for more information.";;
70483   --help | --hel | -h )
70484     $as_echo "$ac_cs_usage"; exit ;;
70485   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
70486   | -silent | --silent | --silen | --sile | --sil | --si | --s)
70487     ac_cs_silent=: ;;
70488
70489   # This is an error.
70490   -*) as_fn_error $? "unrecognized option: \`$1'
70491 Try \`$0 --help' for more information." ;;
70492
70493   *) as_fn_append ac_config_targets " $1"
70494      ac_need_defaults=false ;;
70495
70496   esac
70497   shift
70498 done
70499
70500 ac_configure_extra_args=
70501
70502 if $ac_cs_silent; then
70503   exec 6>/dev/null
70504   ac_configure_extra_args="$ac_configure_extra_args --silent"
70505 fi
70506
70507 _ACEOF
70508 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
70509 if \$ac_cs_recheck; then
70510   set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
70511   shift
70512   \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
70513   CONFIG_SHELL='$SHELL'
70514   export CONFIG_SHELL
70515   exec "\$@"
70516 fi
70517
70518 _ACEOF
70519 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
70520 exec 5>>config.log
70521 {
70522   echo
70523   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
70524 ## Running $as_me. ##
70525 _ASBOX
70526   $as_echo "$ac_log"
70527 } >&5
70528
70529 _ACEOF
70530 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
70531 #
70532 # INIT-COMMANDS
70533 #
70534 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
70535 GNUmakefile=$GNUmakefile
70536
70537
70538 # The HP-UX ksh and POSIX shell print the target directory to stdout
70539 # if CDPATH is set.
70540 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
70541
70542 sed_quote_subst='$sed_quote_subst'
70543 double_quote_subst='$double_quote_subst'
70544 delay_variable_subst='$delay_variable_subst'
70545 AS='`$ECHO "$AS" | $SED "$delay_single_quote_subst"`'
70546 DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`'
70547 OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`'
70548 macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`'
70549 macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`'
70550 enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`'
70551 enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`'
70552 pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`'
70553 enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`'
70554 SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`'
70555 ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`'
70556 PATH_SEPARATOR='`$ECHO "$PATH_SEPARATOR" | $SED "$delay_single_quote_subst"`'
70557 host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`'
70558 host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`'
70559 host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`'
70560 build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`'
70561 build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`'
70562 build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`'
70563 SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`'
70564 Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`'
70565 GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`'
70566 EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`'
70567 FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`'
70568 LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`'
70569 NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`'
70570 LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`'
70571 max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`'
70572 ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`'
70573 exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
70574 lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
70575 lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
70576 lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
70577 lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`'
70578 lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`'
70579 reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`'
70580 reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`'
70581 deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`'
70582 file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`'
70583 file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`'
70584 want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`'
70585 sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`'
70586 AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`'
70587 AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`'
70588 archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`'
70589 STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
70590 RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
70591 old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
70592 old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
70593 old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`'
70594 lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`'
70595 CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`'
70596 CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`'
70597 compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`'
70598 GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`'
70599 lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`'
70600 lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
70601 lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
70602 lt_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"`'
70603 nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`'
70604 lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`'
70605 objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`'
70606 MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`'
70607 lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`'
70608 lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`'
70609 lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
70610 lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`'
70611 lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`'
70612 need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`'
70613 MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`'
70614 DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
70615 NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
70616 LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
70617 OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`'
70618 OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`'
70619 libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`'
70620 shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`'
70621 extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
70622 archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`'
70623 enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`'
70624 export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`'
70625 whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`'
70626 compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`'
70627 old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`'
70628 old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
70629 archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`'
70630 archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`'
70631 module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`'
70632 module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`'
70633 with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`'
70634 allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`'
70635 no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`'
70636 hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`'
70637 hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`'
70638 hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`'
70639 hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`'
70640 hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`'
70641 hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`'
70642 hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
70643 inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
70644 link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
70645 always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`'
70646 export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`'
70647 exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`'
70648 include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`'
70649 prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`'
70650 postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`'
70651 file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
70652 variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
70653 need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
70654 need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`'
70655 version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`'
70656 runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`'
70657 shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`'
70658 shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`'
70659 libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`'
70660 library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`'
70661 soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`'
70662 install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`'
70663 postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`'
70664 postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
70665 finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`'
70666 finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`'
70667 hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`'
70668 sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`'
70669 sys_lib_dlsearch_path_spec='`$ECHO "$sys_lib_dlsearch_path_spec" | $SED "$delay_single_quote_subst"`'
70670 hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`'
70671 enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`'
70672 enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`'
70673 enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`'
70674 old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`'
70675 striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`'
70676
70677 LTCC='$LTCC'
70678 LTCFLAGS='$LTCFLAGS'
70679 compiler='$compiler_DEFAULT'
70680
70681 # A function that is used when there is no print builtin or printf.
70682 func_fallback_echo ()
70683 {
70684   eval 'cat <<_LTECHO_EOF
70685 \$1
70686 _LTECHO_EOF'
70687 }
70688
70689 # Quote evaled strings.
70690 for var in AS \
70691 DLLTOOL \
70692 OBJDUMP \
70693 SHELL \
70694 ECHO \
70695 PATH_SEPARATOR \
70696 SED \
70697 GREP \
70698 EGREP \
70699 FGREP \
70700 LD \
70701 NM \
70702 LN_S \
70703 lt_SP2NL \
70704 lt_NL2SP \
70705 reload_flag \
70706 deplibs_check_method \
70707 file_magic_cmd \
70708 file_magic_glob \
70709 want_nocaseglob \
70710 sharedlib_from_linklib_cmd \
70711 AR \
70712 AR_FLAGS \
70713 archiver_list_spec \
70714 STRIP \
70715 RANLIB \
70716 CC \
70717 CFLAGS \
70718 compiler \
70719 lt_cv_sys_global_symbol_pipe \
70720 lt_cv_sys_global_symbol_to_cdecl \
70721 lt_cv_sys_global_symbol_to_c_name_address \
70722 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
70723 nm_file_list_spec \
70724 lt_prog_compiler_no_builtin_flag \
70725 lt_prog_compiler_pic \
70726 lt_prog_compiler_wl \
70727 lt_prog_compiler_static \
70728 lt_cv_prog_compiler_c_o \
70729 need_locks \
70730 MANIFEST_TOOL \
70731 DSYMUTIL \
70732 NMEDIT \
70733 LIPO \
70734 OTOOL \
70735 OTOOL64 \
70736 shrext_cmds \
70737 export_dynamic_flag_spec \
70738 whole_archive_flag_spec \
70739 compiler_needs_object \
70740 with_gnu_ld \
70741 allow_undefined_flag \
70742 no_undefined_flag \
70743 hardcode_libdir_flag_spec \
70744 hardcode_libdir_separator \
70745 exclude_expsyms \
70746 include_expsyms \
70747 file_list_spec \
70748 variables_saved_for_relink \
70749 libname_spec \
70750 library_names_spec \
70751 soname_spec \
70752 install_override_mode \
70753 finish_eval \
70754 old_striplib \
70755 striplib; do
70756     case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
70757     *[\\\\\\\`\\"\\\$]*)
70758       eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
70759       ;;
70760     *)
70761       eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
70762       ;;
70763     esac
70764 done
70765
70766 # Double-quote double-evaled strings.
70767 for var in reload_cmds \
70768 old_postinstall_cmds \
70769 old_postuninstall_cmds \
70770 old_archive_cmds \
70771 extract_expsyms_cmds \
70772 old_archive_from_new_cmds \
70773 old_archive_from_expsyms_cmds \
70774 archive_cmds \
70775 archive_expsym_cmds \
70776 module_cmds \
70777 module_expsym_cmds \
70778 export_symbols_cmds \
70779 prelink_cmds \
70780 postlink_cmds \
70781 postinstall_cmds \
70782 postuninstall_cmds \
70783 finish_cmds \
70784 sys_lib_search_path_spec \
70785 sys_lib_dlsearch_path_spec; do
70786     case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
70787     *[\\\\\\\`\\"\\\$]*)
70788       eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
70789       ;;
70790     *)
70791       eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
70792       ;;
70793     esac
70794 done
70795
70796 ac_aux_dir='$ac_aux_dir'
70797 xsi_shell='$xsi_shell'
70798 lt_shell_append='$lt_shell_append'
70799
70800 # See if we are running on zsh, and set the options which allow our
70801 # commands through without removal of \ escapes INIT.
70802 if test -n "\${ZSH_VERSION+set}" ; then
70803    setopt NO_GLOB_SUBST
70804 fi
70805
70806
70807     PACKAGE='$PACKAGE'
70808     VERSION='$VERSION'
70809     TIMESTAMP='$TIMESTAMP'
70810     RM='$RM'
70811     ofile='$ofile'
70812
70813
70814
70815 # Capture the value of obsolete ALL_LINGUAS because we need it to compute
70816     # POFILES, UPDATEPOFILES, DUMMYPOFILES, GMOFILES, CATALOGS. But hide it
70817     # from automake < 1.5.
70818     eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"'
70819     # Capture the value of LINGUAS because we need it to compute CATALOGS.
70820     LINGUAS="${LINGUAS-%UNSET%}"
70821
70822
70823 _ACEOF
70824
70825 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
70826
70827 # Handling of arguments.
70828 for ac_config_target in $ac_config_targets
70829 do
70830   case $ac_config_target in
70831     "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;;
70832     "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
70833     "$GNUmakefile") CONFIG_LINKS="$CONFIG_LINKS $GNUmakefile:$GNUmakefile" ;;
70834     "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;;
70835     "po-directories") CONFIG_COMMANDS="$CONFIG_COMMANDS po-directories" ;;
70836     "run") CONFIG_FILES="$CONFIG_FILES run" ;;
70837     "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
70838     "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
70839     "include/Makefile") CONFIG_FILES="$CONFIG_FILES include/Makefile" ;;
70840     "docs/Makefile") CONFIG_FILES="$CONFIG_FILES docs/Makefile" ;;
70841     "docs/schemas/Makefile") CONFIG_FILES="$CONFIG_FILES docs/schemas/Makefile" ;;
70842     "gnulib/lib/Makefile") CONFIG_FILES="$CONFIG_FILES gnulib/lib/Makefile" ;;
70843     "gnulib/tests/Makefile") CONFIG_FILES="$CONFIG_FILES gnulib/tests/Makefile" ;;
70844     "libvirt.pc") CONFIG_FILES="$CONFIG_FILES libvirt.pc" ;;
70845     "libvirt.spec") CONFIG_FILES="$CONFIG_FILES libvirt.spec" ;;
70846     "mingw-libvirt.spec") CONFIG_FILES="$CONFIG_FILES mingw-libvirt.spec" ;;
70847     "po/Makefile.in") CONFIG_FILES="$CONFIG_FILES po/Makefile.in" ;;
70848     "include/libvirt/Makefile") CONFIG_FILES="$CONFIG_FILES include/libvirt/Makefile" ;;
70849     "include/libvirt/libvirt.h") CONFIG_FILES="$CONFIG_FILES include/libvirt/libvirt.h" ;;
70850     "daemon/Makefile") CONFIG_FILES="$CONFIG_FILES daemon/Makefile" ;;
70851     "tools/Makefile") CONFIG_FILES="$CONFIG_FILES tools/Makefile" ;;
70852     "tests/Makefile") CONFIG_FILES="$CONFIG_FILES tests/Makefile" ;;
70853     "examples/apparmor/Makefile") CONFIG_FILES="$CONFIG_FILES examples/apparmor/Makefile" ;;
70854     "examples/object-events/Makefile") CONFIG_FILES="$CONFIG_FILES examples/object-events/Makefile" ;;
70855     "examples/domsuspend/Makefile") CONFIG_FILES="$CONFIG_FILES examples/domsuspend/Makefile" ;;
70856     "examples/dominfo/Makefile") CONFIG_FILES="$CONFIG_FILES examples/dominfo/Makefile" ;;
70857     "examples/dommigrate/Makefile") CONFIG_FILES="$CONFIG_FILES examples/dommigrate/Makefile" ;;
70858     "examples/openauth/Makefile") CONFIG_FILES="$CONFIG_FILES examples/openauth/Makefile" ;;
70859     "examples/hellolibvirt/Makefile") CONFIG_FILES="$CONFIG_FILES examples/hellolibvirt/Makefile" ;;
70860     "examples/systemtap/Makefile") CONFIG_FILES="$CONFIG_FILES examples/systemtap/Makefile" ;;
70861     "examples/xml/nwfilter/Makefile") CONFIG_FILES="$CONFIG_FILES examples/xml/nwfilter/Makefile" ;;
70862     "tools/wireshark/Makefile") CONFIG_FILES="$CONFIG_FILES tools/wireshark/Makefile" ;;
70863     "tools/wireshark/src/Makefile") CONFIG_FILES="$CONFIG_FILES tools/wireshark/src/Makefile" ;;
70864
70865   *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
70866   esac
70867 done
70868
70869
70870 # If the user did not use the arguments to specify the items to instantiate,
70871 # then the envvar interface is used.  Set only those that are not.
70872 # We use the long form for the default assignment because of an extremely
70873 # bizarre bug on SunOS 4.1.3.
70874 if $ac_need_defaults; then
70875   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
70876   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
70877   test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
70878   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
70879 fi
70880
70881 # Have a temporary directory for convenience.  Make it in the build tree
70882 # simply because there is no reason against having it here, and in addition,
70883 # creating and moving files from /tmp can sometimes cause problems.
70884 # Hook for its removal unless debugging.
70885 # Note that there is a small window in which the directory will not be cleaned:
70886 # after its creation but before its name has been assigned to `$tmp'.
70887 $debug ||
70888 {
70889   tmp= ac_tmp=
70890   trap 'exit_status=$?
70891   : "${ac_tmp:=$tmp}"
70892   { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
70893 ' 0
70894   trap 'as_fn_exit 1' 1 2 13 15
70895 }
70896 # Create a (secure) tmp directory for tmp files.
70897
70898 {
70899   tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
70900   test -d "$tmp"
70901 }  ||
70902 {
70903   tmp=./conf$$-$RANDOM
70904   (umask 077 && mkdir "$tmp")
70905 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
70906 ac_tmp=$tmp
70907
70908 # Set up the scripts for CONFIG_FILES section.
70909 # No need to generate them if there are no CONFIG_FILES.
70910 # This happens for instance with `./config.status config.h'.
70911 if test -n "$CONFIG_FILES"; then
70912
70913
70914 ac_cr=`echo X | tr X '\015'`
70915 # On cygwin, bash can eat \r inside `` if the user requested igncr.
70916 # But we know of no other shell where ac_cr would be empty at this
70917 # point, so we can use a bashism as a fallback.
70918 if test "x$ac_cr" = x; then
70919   eval ac_cr=\$\'\\r\'
70920 fi
70921 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
70922 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
70923   ac_cs_awk_cr='\\r'
70924 else
70925   ac_cs_awk_cr=$ac_cr
70926 fi
70927
70928 echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
70929 _ACEOF
70930
70931
70932 {
70933   echo "cat >conf$$subs.awk <<_ACEOF" &&
70934   echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
70935   echo "_ACEOF"
70936 } >conf$$subs.sh ||
70937   as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
70938 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
70939 ac_delim='%!_!# '
70940 for ac_last_try in false false false false false :; do
70941   . ./conf$$subs.sh ||
70942     as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
70943
70944   ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
70945   if test $ac_delim_n = $ac_delim_num; then
70946     break
70947   elif $ac_last_try; then
70948     as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
70949   else
70950     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
70951   fi
70952 done
70953 rm -f conf$$subs.sh
70954
70955 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
70956 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
70957 _ACEOF
70958 sed -n '
70959 h
70960 s/^/S["/; s/!.*/"]=/
70961 p
70962 g
70963 s/^[^!]*!//
70964 :repl
70965 t repl
70966 s/'"$ac_delim"'$//
70967 t delim
70968 :nl
70969 h
70970 s/\(.\{148\}\)..*/\1/
70971 t more1
70972 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
70973 p
70974 n
70975 b repl
70976 :more1
70977 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
70978 p
70979 g
70980 s/.\{148\}//
70981 t nl
70982 :delim
70983 h
70984 s/\(.\{148\}\)..*/\1/
70985 t more2
70986 s/["\\]/\\&/g; s/^/"/; s/$/"/
70987 p
70988 b
70989 :more2
70990 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
70991 p
70992 g
70993 s/.\{148\}//
70994 t delim
70995 ' <conf$$subs.awk | sed '
70996 /^[^""]/{
70997   N
70998   s/\n//
70999 }
71000 ' >>$CONFIG_STATUS || ac_write_fail=1
71001 rm -f conf$$subs.awk
71002 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
71003 _ACAWK
71004 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
71005   for (key in S) S_is_set[key] = 1
71006   FS = "\a"
71007
71008 }
71009 {
71010   line = $ 0
71011   nfields = split(line, field, "@")
71012   substed = 0
71013   len = length(field[1])
71014   for (i = 2; i < nfields; i++) {
71015     key = field[i]
71016     keylen = length(key)
71017     if (S_is_set[key]) {
71018       value = S[key]
71019       line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
71020       len += length(value) + length(field[++i])
71021       substed = 1
71022     } else
71023       len += 1 + keylen
71024   }
71025
71026   print line
71027 }
71028
71029 _ACAWK
71030 _ACEOF
71031 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
71032 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
71033   sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
71034 else
71035   cat
71036 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
71037   || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
71038 _ACEOF
71039
71040 # VPATH may cause trouble with some makes, so we remove sole $(srcdir),
71041 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
71042 # trailing colons and then remove the whole line if VPATH becomes empty
71043 # (actually we leave an empty line to preserve line numbers).
71044 if test "x$srcdir" = x.; then
71045   ac_vpsub='/^[  ]*VPATH[        ]*=[    ]*/{
71046 h
71047 s///
71048 s/^/:/
71049 s/[      ]*$/:/
71050 s/:\$(srcdir):/:/g
71051 s/:\${srcdir}:/:/g
71052 s/:@srcdir@:/:/g
71053 s/^:*//
71054 s/:*$//
71055 x
71056 s/\(=[   ]*\).*/\1/
71057 G
71058 s/\n//
71059 s/^[^=]*=[       ]*$//
71060 }'
71061 fi
71062
71063 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
71064 fi # test -n "$CONFIG_FILES"
71065
71066 # Set up the scripts for CONFIG_HEADERS section.
71067 # No need to generate them if there are no CONFIG_HEADERS.
71068 # This happens for instance with `./config.status Makefile'.
71069 if test -n "$CONFIG_HEADERS"; then
71070 cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
71071 BEGIN {
71072 _ACEOF
71073
71074 # Transform confdefs.h into an awk script `defines.awk', embedded as
71075 # here-document in config.status, that substitutes the proper values into
71076 # config.h.in to produce config.h.
71077
71078 # Create a delimiter string that does not exist in confdefs.h, to ease
71079 # handling of long lines.
71080 ac_delim='%!_!# '
71081 for ac_last_try in false false :; do
71082   ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
71083   if test -z "$ac_tt"; then
71084     break
71085   elif $ac_last_try; then
71086     as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
71087   else
71088     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
71089   fi
71090 done
71091
71092 # For the awk script, D is an array of macro values keyed by name,
71093 # likewise P contains macro parameters if any.  Preserve backslash
71094 # newline sequences.
71095
71096 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
71097 sed -n '
71098 s/.\{148\}/&'"$ac_delim"'/g
71099 t rset
71100 :rset
71101 s/^[     ]*#[    ]*define[       ][      ]*/ /
71102 t def
71103 d
71104 :def
71105 s/\\$//
71106 t bsnl
71107 s/["\\]/\\&/g
71108 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
71109 D["\1"]=" \3"/p
71110 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2"/p
71111 d
71112 :bsnl
71113 s/["\\]/\\&/g
71114 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
71115 D["\1"]=" \3\\\\\\n"\\/p
71116 t cont
71117 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
71118 t cont
71119 d
71120 :cont
71121 n
71122 s/.\{148\}/&'"$ac_delim"'/g
71123 t clear
71124 :clear
71125 s/\\$//
71126 t bsnlc
71127 s/["\\]/\\&/g; s/^/"/; s/$/"/p
71128 d
71129 :bsnlc
71130 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
71131 b cont
71132 ' <confdefs.h | sed '
71133 s/'"$ac_delim"'/"\\\
71134 "/g' >>$CONFIG_STATUS || ac_write_fail=1
71135
71136 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
71137   for (key in D) D_is_set[key] = 1
71138   FS = "\a"
71139 }
71140 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
71141   line = \$ 0
71142   split(line, arg, " ")
71143   if (arg[1] == "#") {
71144     defundef = arg[2]
71145     mac1 = arg[3]
71146   } else {
71147     defundef = substr(arg[1], 2)
71148     mac1 = arg[2]
71149   }
71150   split(mac1, mac2, "(") #)
71151   macro = mac2[1]
71152   prefix = substr(line, 1, index(line, defundef) - 1)
71153   if (D_is_set[macro]) {
71154     # Preserve the white space surrounding the "#".
71155     print prefix "define", macro P[macro] D[macro]
71156     next
71157   } else {
71158     # Replace #undef with comments.  This is necessary, for example,
71159     # in the case of _POSIX_SOURCE, which is predefined and required
71160     # on some systems where configure will not decide to define it.
71161     if (defundef == "undef") {
71162       print "/*", prefix defundef, macro, "*/"
71163       next
71164     }
71165   }
71166 }
71167 { print }
71168 _ACAWK
71169 _ACEOF
71170 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
71171   as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
71172 fi # test -n "$CONFIG_HEADERS"
71173
71174
71175 eval set X "  :F $CONFIG_FILES  :H $CONFIG_HEADERS  :L $CONFIG_LINKS  :C $CONFIG_COMMANDS"
71176 shift
71177 for ac_tag
71178 do
71179   case $ac_tag in
71180   :[FHLC]) ac_mode=$ac_tag; continue;;
71181   esac
71182   case $ac_mode$ac_tag in
71183   :[FHL]*:*);;
71184   :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
71185   :[FH]-) ac_tag=-:-;;
71186   :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
71187   esac
71188   ac_save_IFS=$IFS
71189   IFS=:
71190   set x $ac_tag
71191   IFS=$ac_save_IFS
71192   shift
71193   ac_file=$1
71194   shift
71195
71196   case $ac_mode in
71197   :L) ac_source=$1;;
71198   :[FH])
71199     ac_file_inputs=
71200     for ac_f
71201     do
71202       case $ac_f in
71203       -) ac_f="$ac_tmp/stdin";;
71204       *) # Look for the file first in the build tree, then in the source tree
71205          # (if the path is not absolute).  The absolute path cannot be DOS-style,
71206          # because $ac_f cannot contain `:'.
71207          test -f "$ac_f" ||
71208            case $ac_f in
71209            [\\/$]*) false;;
71210            *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
71211            esac ||
71212            as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
71213       esac
71214       case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
71215       as_fn_append ac_file_inputs " '$ac_f'"
71216     done
71217
71218     # Let's still pretend it is `configure' which instantiates (i.e., don't
71219     # use $as_me), people would be surprised to read:
71220     #    /* config.h.  Generated by config.status.  */
71221     configure_input='Generated from '`
71222           $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
71223         `' by configure.'
71224     if test x"$ac_file" != x-; then
71225       configure_input="$ac_file.  $configure_input"
71226       { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
71227 $as_echo "$as_me: creating $ac_file" >&6;}
71228     fi
71229     # Neutralize special characters interpreted by sed in replacement strings.
71230     case $configure_input in #(
71231     *\&* | *\|* | *\\* )
71232        ac_sed_conf_input=`$as_echo "$configure_input" |
71233        sed 's/[\\\\&|]/\\\\&/g'`;; #(
71234     *) ac_sed_conf_input=$configure_input;;
71235     esac
71236
71237     case $ac_tag in
71238     *:-:* | *:-) cat >"$ac_tmp/stdin" \
71239       || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
71240     esac
71241     ;;
71242   esac
71243
71244   ac_dir=`$as_dirname -- "$ac_file" ||
71245 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
71246          X"$ac_file" : 'X\(//\)[^/]' \| \
71247          X"$ac_file" : 'X\(//\)$' \| \
71248          X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
71249 $as_echo X"$ac_file" |
71250     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
71251             s//\1/
71252             q
71253           }
71254           /^X\(\/\/\)[^/].*/{
71255             s//\1/
71256             q
71257           }
71258           /^X\(\/\/\)$/{
71259             s//\1/
71260             q
71261           }
71262           /^X\(\/\).*/{
71263             s//\1/
71264             q
71265           }
71266           s/.*/./; q'`
71267   as_dir="$ac_dir"; as_fn_mkdir_p
71268   ac_builddir=.
71269
71270 case "$ac_dir" in
71271 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
71272 *)
71273   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
71274   # A ".." for each directory in $ac_dir_suffix.
71275   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
71276   case $ac_top_builddir_sub in
71277   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
71278   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
71279   esac ;;
71280 esac
71281 ac_abs_top_builddir=$ac_pwd
71282 ac_abs_builddir=$ac_pwd$ac_dir_suffix
71283 # for backward compatibility:
71284 ac_top_builddir=$ac_top_build_prefix
71285
71286 case $srcdir in
71287   .)  # We are building in place.
71288     ac_srcdir=.
71289     ac_top_srcdir=$ac_top_builddir_sub
71290     ac_abs_top_srcdir=$ac_pwd ;;
71291   [\\/]* | ?:[\\/]* )  # Absolute name.
71292     ac_srcdir=$srcdir$ac_dir_suffix;
71293     ac_top_srcdir=$srcdir
71294     ac_abs_top_srcdir=$srcdir ;;
71295   *) # Relative name.
71296     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
71297     ac_top_srcdir=$ac_top_build_prefix$srcdir
71298     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
71299 esac
71300 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
71301
71302
71303   case $ac_mode in
71304   :F)
71305   #
71306   # CONFIG_FILE
71307   #
71308
71309   case $INSTALL in
71310   [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
71311   *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
71312   esac
71313   ac_MKDIR_P=$MKDIR_P
71314   case $MKDIR_P in
71315   [\\/$]* | ?:[\\/]* ) ;;
71316   */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
71317   esac
71318 _ACEOF
71319
71320 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
71321 # If the template does not know about datarootdir, expand it.
71322 # FIXME: This hack should be removed a few years after 2.60.
71323 ac_datarootdir_hack=; ac_datarootdir_seen=
71324 ac_sed_dataroot='
71325 /datarootdir/ {
71326   p
71327   q
71328 }
71329 /@datadir@/p
71330 /@docdir@/p
71331 /@infodir@/p
71332 /@localedir@/p
71333 /@mandir@/p'
71334 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
71335 *datarootdir*) ac_datarootdir_seen=yes;;
71336 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
71337   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
71338 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
71339 _ACEOF
71340 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
71341   ac_datarootdir_hack='
71342   s&@datadir@&$datadir&g
71343   s&@docdir@&$docdir&g
71344   s&@infodir@&$infodir&g
71345   s&@localedir@&$localedir&g
71346   s&@mandir@&$mandir&g
71347   s&\\\${datarootdir}&$datarootdir&g' ;;
71348 esac
71349 _ACEOF
71350
71351 # Neutralize VPATH when `$srcdir' = `.'.
71352 # Shell code in configure.ac might set extrasub.
71353 # FIXME: do we really want to maintain this feature?
71354 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
71355 ac_sed_extra="$ac_vpsub
71356 $extrasub
71357 _ACEOF
71358 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
71359 :t
71360 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
71361 s|@configure_input@|$ac_sed_conf_input|;t t
71362 s&@top_builddir@&$ac_top_builddir_sub&;t t
71363 s&@top_build_prefix@&$ac_top_build_prefix&;t t
71364 s&@srcdir@&$ac_srcdir&;t t
71365 s&@abs_srcdir@&$ac_abs_srcdir&;t t
71366 s&@top_srcdir@&$ac_top_srcdir&;t t
71367 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
71368 s&@builddir@&$ac_builddir&;t t
71369 s&@abs_builddir@&$ac_abs_builddir&;t t
71370 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
71371 s&@INSTALL@&$ac_INSTALL&;t t
71372 s&@MKDIR_P@&$ac_MKDIR_P&;t t
71373 $ac_datarootdir_hack
71374 "
71375 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
71376   >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
71377
71378 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
71379   { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
71380   { ac_out=`sed -n '/^[  ]*datarootdir[  ]*:*=/p' \
71381       "$ac_tmp/out"`; test -z "$ac_out"; } &&
71382   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
71383 which seems to be undefined.  Please make sure it is defined" >&5
71384 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
71385 which seems to be undefined.  Please make sure it is defined" >&2;}
71386
71387   rm -f "$ac_tmp/stdin"
71388   case $ac_file in
71389   -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
71390   *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
71391   esac \
71392   || as_fn_error $? "could not create $ac_file" "$LINENO" 5
71393  ;;
71394   :H)
71395   #
71396   # CONFIG_HEADER
71397   #
71398   if test x"$ac_file" != x-; then
71399     {
71400       $as_echo "/* $configure_input  */" \
71401       && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
71402     } >"$ac_tmp/config.h" \
71403       || as_fn_error $? "could not create $ac_file" "$LINENO" 5
71404     if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
71405       { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
71406 $as_echo "$as_me: $ac_file is unchanged" >&6;}
71407     else
71408       rm -f "$ac_file"
71409       mv "$ac_tmp/config.h" "$ac_file" \
71410         || as_fn_error $? "could not create $ac_file" "$LINENO" 5
71411     fi
71412   else
71413     $as_echo "/* $configure_input  */" \
71414       && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
71415       || as_fn_error $? "could not create -" "$LINENO" 5
71416   fi
71417 # Compute "$ac_file"'s index in $config_headers.
71418 _am_arg="$ac_file"
71419 _am_stamp_count=1
71420 for _am_header in $config_headers :; do
71421   case $_am_header in
71422     $_am_arg | $_am_arg:* )
71423       break ;;
71424     * )
71425       _am_stamp_count=`expr $_am_stamp_count + 1` ;;
71426   esac
71427 done
71428 echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
71429 $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
71430          X"$_am_arg" : 'X\(//\)[^/]' \| \
71431          X"$_am_arg" : 'X\(//\)$' \| \
71432          X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
71433 $as_echo X"$_am_arg" |
71434     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
71435             s//\1/
71436             q
71437           }
71438           /^X\(\/\/\)[^/].*/{
71439             s//\1/
71440             q
71441           }
71442           /^X\(\/\/\)$/{
71443             s//\1/
71444             q
71445           }
71446           /^X\(\/\).*/{
71447             s//\1/
71448             q
71449           }
71450           s/.*/./; q'`/stamp-h$_am_stamp_count
71451  ;;
71452   :L)
71453   #
71454   # CONFIG_LINK
71455   #
71456
71457   if test "$ac_source" = "$ac_file" && test "$srcdir" = '.'; then
71458     :
71459   else
71460     # Prefer the file from the source tree if names are identical.
71461     if test "$ac_source" = "$ac_file" || test ! -r "$ac_source"; then
71462       ac_source=$srcdir/$ac_source
71463     fi
71464
71465     { $as_echo "$as_me:${as_lineno-$LINENO}: linking $ac_source to $ac_file" >&5
71466 $as_echo "$as_me: linking $ac_source to $ac_file" >&6;}
71467
71468     if test ! -r "$ac_source"; then
71469       as_fn_error $? "$ac_source: file not found" "$LINENO" 5
71470     fi
71471     rm -f "$ac_file"
71472
71473     # Try a relative symlink, then a hard link, then a copy.
71474     case $ac_source in
71475     [\\/$]* | ?:[\\/]* ) ac_rel_source=$ac_source ;;
71476         *) ac_rel_source=$ac_top_build_prefix$ac_source ;;
71477     esac
71478     ln -s "$ac_rel_source" "$ac_file" 2>/dev/null ||
71479       ln "$ac_source" "$ac_file" 2>/dev/null ||
71480       cp -p "$ac_source" "$ac_file" ||
71481       as_fn_error $? "cannot link or copy $ac_source to $ac_file" "$LINENO" 5
71482   fi
71483  ;;
71484   :C)  { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
71485 $as_echo "$as_me: executing $ac_file commands" >&6;}
71486  ;;
71487   esac
71488
71489
71490   case $ac_file$ac_mode in
71491     "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
71492   # Older Autoconf quotes --file arguments for eval, but not when files
71493   # are listed without --file.  Let's play safe and only enable the eval
71494   # if we detect the quoting.
71495   case $CONFIG_FILES in
71496   *\'*) eval set x "$CONFIG_FILES" ;;
71497   *)   set x $CONFIG_FILES ;;
71498   esac
71499   shift
71500   for mf
71501   do
71502     # Strip MF so we end up with the name of the file.
71503     mf=`echo "$mf" | sed -e 's/:.*$//'`
71504     # Check whether this is an Automake generated Makefile or not.
71505     # We used to match only the files named 'Makefile.in', but
71506     # some people rename them; so instead we look at the file content.
71507     # Grep'ing the first line is not enough: some people post-process
71508     # each Makefile.in and add a new line on top of each file to say so.
71509     # Grep'ing the whole file is not good either: AIX grep has a line
71510     # limit of 2048, but all sed's we know have understand at least 4000.
71511     if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
71512       dirpart=`$as_dirname -- "$mf" ||
71513 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
71514          X"$mf" : 'X\(//\)[^/]' \| \
71515          X"$mf" : 'X\(//\)$' \| \
71516          X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
71517 $as_echo X"$mf" |
71518     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
71519             s//\1/
71520             q
71521           }
71522           /^X\(\/\/\)[^/].*/{
71523             s//\1/
71524             q
71525           }
71526           /^X\(\/\/\)$/{
71527             s//\1/
71528             q
71529           }
71530           /^X\(\/\).*/{
71531             s//\1/
71532             q
71533           }
71534           s/.*/./; q'`
71535     else
71536       continue
71537     fi
71538     # Extract the definition of DEPDIR, am__include, and am__quote
71539     # from the Makefile without running 'make'.
71540     DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
71541     test -z "$DEPDIR" && continue
71542     am__include=`sed -n 's/^am__include = //p' < "$mf"`
71543     test -z "$am__include" && continue
71544     am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
71545     # Find all dependency output files, they are included files with
71546     # $(DEPDIR) in their names.  We invoke sed twice because it is the
71547     # simplest approach to changing $(DEPDIR) to its actual value in the
71548     # expansion.
71549     for file in `sed -n "
71550       s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
71551          sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do
71552       # Make sure the directory exists.
71553       test -f "$dirpart/$file" && continue
71554       fdir=`$as_dirname -- "$file" ||
71555 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
71556          X"$file" : 'X\(//\)[^/]' \| \
71557          X"$file" : 'X\(//\)$' \| \
71558          X"$file" : 'X\(/\)' \| . 2>/dev/null ||
71559 $as_echo X"$file" |
71560     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
71561             s//\1/
71562             q
71563           }
71564           /^X\(\/\/\)[^/].*/{
71565             s//\1/
71566             q
71567           }
71568           /^X\(\/\/\)$/{
71569             s//\1/
71570             q
71571           }
71572           /^X\(\/\).*/{
71573             s//\1/
71574             q
71575           }
71576           s/.*/./; q'`
71577       as_dir=$dirpart/$fdir; as_fn_mkdir_p
71578       # echo "creating $dirpart/$file"
71579       echo '# dummy' > "$dirpart/$file"
71580     done
71581   done
71582 }
71583  ;;
71584     "libtool":C)
71585
71586     # See if we are running on zsh, and set the options which allow our
71587     # commands through without removal of \ escapes.
71588     if test -n "${ZSH_VERSION+set}" ; then
71589       setopt NO_GLOB_SUBST
71590     fi
71591
71592     cfgfile="${ofile}T"
71593     trap "$RM \"$cfgfile\"; exit 1" 1 2 15
71594     $RM "$cfgfile"
71595
71596     cat <<_LT_EOF >> "$cfgfile"
71597 #! $SHELL
71598
71599 # `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
71600 # Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
71601 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
71602 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
71603 #
71604 #   Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
71605 #                 2006, 2007, 2008, 2009, 2010, 2011 Free Software
71606 #                 Foundation, Inc.
71607 #   Written by Gordon Matzigkeit, 1996
71608 #
71609 #   This file is part of GNU Libtool.
71610 #
71611 # GNU Libtool is free software; you can redistribute it and/or
71612 # modify it under the terms of the GNU General Public License as
71613 # published by the Free Software Foundation; either version 2 of
71614 # the License, or (at your option) any later version.
71615 #
71616 # As a special exception to the GNU General Public License,
71617 # if you distribute this file as part of a program or library that
71618 # is built using GNU Libtool, you may include this file under the
71619 # same distribution terms that you use for the rest of that program.
71620 #
71621 # GNU Libtool is distributed in the hope that it will be useful,
71622 # but WITHOUT ANY WARRANTY; without even the implied warranty of
71623 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
71624 # GNU General Public License for more details.
71625 #
71626 # You should have received a copy of the GNU General Public License
71627 # along with GNU Libtool; see the file COPYING.  If not, a copy
71628 # can be downloaded from http://www.gnu.org/licenses/gpl.html, or
71629 # obtained by writing to the Free Software Foundation, Inc.,
71630 # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
71631
71632
71633 # The names of the tagged configurations supported by this script.
71634 available_tags=""
71635
71636 # ### BEGIN LIBTOOL CONFIG
71637
71638 # Assembler program.
71639 AS=$lt_AS
71640
71641 # DLL creation program.
71642 DLLTOOL=$lt_DLLTOOL
71643
71644 # Object dumper program.
71645 OBJDUMP=$lt_OBJDUMP
71646
71647 # Which release of libtool.m4 was used?
71648 macro_version=$macro_version
71649 macro_revision=$macro_revision
71650
71651 # Whether or not to build shared libraries.
71652 build_libtool_libs=$enable_shared
71653
71654 # Whether or not to build static libraries.
71655 build_old_libs=$enable_static
71656
71657 # What type of objects to build.
71658 pic_mode=$pic_mode
71659
71660 # Whether or not to optimize for fast installation.
71661 fast_install=$enable_fast_install
71662
71663 # Shell to use when invoking shell scripts.
71664 SHELL=$lt_SHELL
71665
71666 # An echo program that protects backslashes.
71667 ECHO=$lt_ECHO
71668
71669 # The PATH separator for the build system.
71670 PATH_SEPARATOR=$lt_PATH_SEPARATOR
71671
71672 # The host system.
71673 host_alias=$host_alias
71674 host=$host
71675 host_os=$host_os
71676
71677 # The build system.
71678 build_alias=$build_alias
71679 build=$build
71680 build_os=$build_os
71681
71682 # A sed program that does not truncate output.
71683 SED=$lt_SED
71684
71685 # Sed that helps us avoid accidentally triggering echo(1) options like -n.
71686 Xsed="\$SED -e 1s/^X//"
71687
71688 # A grep program that handles long lines.
71689 GREP=$lt_GREP
71690
71691 # An ERE matcher.
71692 EGREP=$lt_EGREP
71693
71694 # A literal string matcher.
71695 FGREP=$lt_FGREP
71696
71697 # A BSD- or MS-compatible name lister.
71698 NM=$lt_NM
71699
71700 # Whether we need soft or hard links.
71701 LN_S=$lt_LN_S
71702
71703 # What is the maximum length of a command?
71704 max_cmd_len=$max_cmd_len
71705
71706 # Object file suffix (normally "o").
71707 objext=$ac_objext
71708
71709 # Executable file suffix (normally "").
71710 exeext=$exeext
71711
71712 # whether the shell understands "unset".
71713 lt_unset=$lt_unset
71714
71715 # turn spaces into newlines.
71716 SP2NL=$lt_lt_SP2NL
71717
71718 # turn newlines into spaces.
71719 NL2SP=$lt_lt_NL2SP
71720
71721 # convert \$build file names to \$host format.
71722 to_host_file_cmd=$lt_cv_to_host_file_cmd
71723
71724 # convert \$build files to toolchain format.
71725 to_tool_file_cmd=$lt_cv_to_tool_file_cmd
71726
71727 # Method to check whether dependent libraries are shared objects.
71728 deplibs_check_method=$lt_deplibs_check_method
71729
71730 # Command to use when deplibs_check_method = "file_magic".
71731 file_magic_cmd=$lt_file_magic_cmd
71732
71733 # How to find potential files when deplibs_check_method = "file_magic".
71734 file_magic_glob=$lt_file_magic_glob
71735
71736 # Find potential files using nocaseglob when deplibs_check_method = "file_magic".
71737 want_nocaseglob=$lt_want_nocaseglob
71738
71739 # Command to associate shared and link libraries.
71740 sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd
71741
71742 # The archiver.
71743 AR=$lt_AR
71744
71745 # Flags to create an archive.
71746 AR_FLAGS=$lt_AR_FLAGS
71747
71748 # How to feed a file listing to the archiver.
71749 archiver_list_spec=$lt_archiver_list_spec
71750
71751 # A symbol stripping program.
71752 STRIP=$lt_STRIP
71753
71754 # Commands used to install an old-style archive.
71755 RANLIB=$lt_RANLIB
71756 old_postinstall_cmds=$lt_old_postinstall_cmds
71757 old_postuninstall_cmds=$lt_old_postuninstall_cmds
71758
71759 # Whether to use a lock for old archive extraction.
71760 lock_old_archive_extraction=$lock_old_archive_extraction
71761
71762 # A C compiler.
71763 LTCC=$lt_CC
71764
71765 # LTCC compiler flags.
71766 LTCFLAGS=$lt_CFLAGS
71767
71768 # Take the output of nm and produce a listing of raw symbols and C names.
71769 global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
71770
71771 # Transform the output of nm in a proper C declaration.
71772 global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
71773
71774 # Transform the output of nm in a C name address pair.
71775 global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
71776
71777 # Transform the output of nm in a C name address pair when lib prefix is needed.
71778 global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
71779
71780 # Specify filename containing input files for \$NM.
71781 nm_file_list_spec=$lt_nm_file_list_spec
71782
71783 # The root where to search for dependent libraries,and in which our libraries should be installed.
71784 lt_sysroot=$lt_sysroot
71785
71786 # The name of the directory that contains temporary libtool files.
71787 objdir=$objdir
71788
71789 # Used to examine libraries when file_magic_cmd begins with "file".
71790 MAGIC_CMD=$MAGIC_CMD
71791
71792 # Must we lock files when doing compilation?
71793 need_locks=$lt_need_locks
71794
71795 # Manifest tool.
71796 MANIFEST_TOOL=$lt_MANIFEST_TOOL
71797
71798 # Tool to manipulate archived DWARF debug symbol files on Mac OS X.
71799 DSYMUTIL=$lt_DSYMUTIL
71800
71801 # Tool to change global to local symbols on Mac OS X.
71802 NMEDIT=$lt_NMEDIT
71803
71804 # Tool to manipulate fat objects and archives on Mac OS X.
71805 LIPO=$lt_LIPO
71806
71807 # ldd/readelf like tool for Mach-O binaries on Mac OS X.
71808 OTOOL=$lt_OTOOL
71809
71810 # ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4.
71811 OTOOL64=$lt_OTOOL64
71812
71813 # Old archive suffix (normally "a").
71814 libext=$libext
71815
71816 # Shared library suffix (normally ".so").
71817 shrext_cmds=$lt_shrext_cmds
71818
71819 # The commands to extract the exported symbol list from a shared archive.
71820 extract_expsyms_cmds=$lt_extract_expsyms_cmds
71821
71822 # Variables whose values should be saved in libtool wrapper scripts and
71823 # restored at link time.
71824 variables_saved_for_relink=$lt_variables_saved_for_relink
71825
71826 # Do we need the "lib" prefix for modules?
71827 need_lib_prefix=$need_lib_prefix
71828
71829 # Do we need a version for libraries?
71830 need_version=$need_version
71831
71832 # Library versioning type.
71833 version_type=$version_type
71834
71835 # Shared library runtime path variable.
71836 runpath_var=$runpath_var
71837
71838 # Shared library path variable.
71839 shlibpath_var=$shlibpath_var
71840
71841 # Is shlibpath searched before the hard-coded library search path?
71842 shlibpath_overrides_runpath=$shlibpath_overrides_runpath
71843
71844 # Format of library name prefix.
71845 libname_spec=$lt_libname_spec
71846
71847 # List of archive names.  First name is the real one, the rest are links.
71848 # The last name is the one that the linker finds with -lNAME
71849 library_names_spec=$lt_library_names_spec
71850
71851 # The coded name of the library, if different from the real name.
71852 soname_spec=$lt_soname_spec
71853
71854 # Permission mode override for installation of shared libraries.
71855 install_override_mode=$lt_install_override_mode
71856
71857 # Command to use after installation of a shared archive.
71858 postinstall_cmds=$lt_postinstall_cmds
71859
71860 # Command to use after uninstallation of a shared archive.
71861 postuninstall_cmds=$lt_postuninstall_cmds
71862
71863 # Commands used to finish a libtool library installation in a directory.
71864 finish_cmds=$lt_finish_cmds
71865
71866 # As "finish_cmds", except a single script fragment to be evaled but
71867 # not shown.
71868 finish_eval=$lt_finish_eval
71869
71870 # Whether we should hardcode library paths into libraries.
71871 hardcode_into_libs=$hardcode_into_libs
71872
71873 # Compile-time system search path for libraries.
71874 sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
71875
71876 # Run-time system search path for libraries.
71877 sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
71878
71879 # Whether dlopen is supported.
71880 dlopen_support=$enable_dlopen
71881
71882 # Whether dlopen of programs is supported.
71883 dlopen_self=$enable_dlopen_self
71884
71885 # Whether dlopen of statically linked programs is supported.
71886 dlopen_self_static=$enable_dlopen_self_static
71887
71888 # Commands to strip libraries.
71889 old_striplib=$lt_old_striplib
71890 striplib=$lt_striplib
71891
71892
71893 # The linker used to build libraries.
71894 LD=$lt_LD
71895
71896 # How to create reloadable object files.
71897 reload_flag=$lt_reload_flag
71898 reload_cmds=$lt_reload_cmds
71899
71900 # Commands used to build an old-style archive.
71901 old_archive_cmds=$lt_old_archive_cmds
71902
71903 # A language specific compiler.
71904 CC=$lt_compiler
71905
71906 # Is the compiler the GNU compiler?
71907 with_gcc=$GCC
71908
71909 # Compiler flag to turn off builtin functions.
71910 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
71911
71912 # Additional compiler flags for building library objects.
71913 pic_flag=$lt_lt_prog_compiler_pic
71914
71915 # How to pass a linker flag through the compiler.
71916 wl=$lt_lt_prog_compiler_wl
71917
71918 # Compiler flag to prevent dynamic linking.
71919 link_static_flag=$lt_lt_prog_compiler_static
71920
71921 # Does compiler simultaneously support -c and -o options?
71922 compiler_c_o=$lt_lt_cv_prog_compiler_c_o
71923
71924 # Whether or not to add -lc for building shared libraries.
71925 build_libtool_need_lc=$archive_cmds_need_lc
71926
71927 # Whether or not to disallow shared libs when runtime libs are static.
71928 allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes
71929
71930 # Compiler flag to allow reflexive dlopens.
71931 export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
71932
71933 # Compiler flag to generate shared objects directly from archives.
71934 whole_archive_flag_spec=$lt_whole_archive_flag_spec
71935
71936 # Whether the compiler copes with passing no objects directly.
71937 compiler_needs_object=$lt_compiler_needs_object
71938
71939 # Create an old-style archive from a shared archive.
71940 old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
71941
71942 # Create a temporary old-style archive to link instead of a shared archive.
71943 old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
71944
71945 # Commands used to build a shared archive.
71946 archive_cmds=$lt_archive_cmds
71947 archive_expsym_cmds=$lt_archive_expsym_cmds
71948
71949 # Commands used to build a loadable module if different from building
71950 # a shared archive.
71951 module_cmds=$lt_module_cmds
71952 module_expsym_cmds=$lt_module_expsym_cmds
71953
71954 # Whether we are building with GNU ld or not.
71955 with_gnu_ld=$lt_with_gnu_ld
71956
71957 # Flag that allows shared libraries with undefined symbols to be built.
71958 allow_undefined_flag=$lt_allow_undefined_flag
71959
71960 # Flag that enforces no undefined symbols.
71961 no_undefined_flag=$lt_no_undefined_flag
71962
71963 # Flag to hardcode \$libdir into a binary during linking.
71964 # This must work even if \$libdir does not exist
71965 hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
71966
71967 # Whether we need a single "-rpath" flag with a separated argument.
71968 hardcode_libdir_separator=$lt_hardcode_libdir_separator
71969
71970 # Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
71971 # DIR into the resulting binary.
71972 hardcode_direct=$hardcode_direct
71973
71974 # Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
71975 # DIR into the resulting binary and the resulting library dependency is
71976 # "absolute",i.e impossible to change by setting \${shlibpath_var} if the
71977 # library is relocated.
71978 hardcode_direct_absolute=$hardcode_direct_absolute
71979
71980 # Set to "yes" if using the -LDIR flag during linking hardcodes DIR
71981 # into the resulting binary.
71982 hardcode_minus_L=$hardcode_minus_L
71983
71984 # Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
71985 # into the resulting binary.
71986 hardcode_shlibpath_var=$hardcode_shlibpath_var
71987
71988 # Set to "yes" if building a shared library automatically hardcodes DIR
71989 # into the library and all subsequent libraries and executables linked
71990 # against it.
71991 hardcode_automatic=$hardcode_automatic
71992
71993 # Set to yes if linker adds runtime paths of dependent libraries
71994 # to runtime path list.
71995 inherit_rpath=$inherit_rpath
71996
71997 # Whether libtool must link a program against all its dependency libraries.
71998 link_all_deplibs=$link_all_deplibs
71999
72000 # Set to "yes" if exported symbols are required.
72001 always_export_symbols=$always_export_symbols
72002
72003 # The commands to list exported symbols.
72004 export_symbols_cmds=$lt_export_symbols_cmds
72005
72006 # Symbols that should not be listed in the preloaded symbols.
72007 exclude_expsyms=$lt_exclude_expsyms
72008
72009 # Symbols that must always be exported.
72010 include_expsyms=$lt_include_expsyms
72011
72012 # Commands necessary for linking programs (against libraries) with templates.
72013 prelink_cmds=$lt_prelink_cmds
72014
72015 # Commands necessary for finishing linking programs.
72016 postlink_cmds=$lt_postlink_cmds
72017
72018 # Specify filename containing input files.
72019 file_list_spec=$lt_file_list_spec
72020
72021 # How to hardcode a shared library path into an executable.
72022 hardcode_action=$hardcode_action
72023
72024 # ### END LIBTOOL CONFIG
72025
72026 _LT_EOF
72027
72028   case $host_os in
72029   aix3*)
72030     cat <<\_LT_EOF >> "$cfgfile"
72031 # AIX sometimes has problems with the GCC collect2 program.  For some
72032 # reason, if we set the COLLECT_NAMES environment variable, the problems
72033 # vanish in a puff of smoke.
72034 if test "X${COLLECT_NAMES+set}" != Xset; then
72035   COLLECT_NAMES=
72036   export COLLECT_NAMES
72037 fi
72038 _LT_EOF
72039     ;;
72040   esac
72041
72042
72043 ltmain="$ac_aux_dir/ltmain.sh"
72044
72045
72046   # We use sed instead of cat because bash on DJGPP gets confused if
72047   # if finds mixed CR/LF and LF-only lines.  Since sed operates in
72048   # text mode, it properly converts lines to CR/LF.  This bash problem
72049   # is reportedly fixed, but why not run on old versions too?
72050   sed '$q' "$ltmain" >> "$cfgfile" \
72051      || (rm -f "$cfgfile"; exit 1)
72052
72053   if test x"$xsi_shell" = xyes; then
72054   sed -e '/^func_dirname ()$/,/^} # func_dirname /c\
72055 func_dirname ()\
72056 {\
72057 \    case ${1} in\
72058 \      */*) func_dirname_result="${1%/*}${2}" ;;\
72059 \      *  ) func_dirname_result="${3}" ;;\
72060 \    esac\
72061 } # Extended-shell func_dirname implementation' "$cfgfile" > $cfgfile.tmp \
72062   && mv -f "$cfgfile.tmp" "$cfgfile" \
72063     || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
72064 test 0 -eq $? || _lt_function_replace_fail=:
72065
72066
72067   sed -e '/^func_basename ()$/,/^} # func_basename /c\
72068 func_basename ()\
72069 {\
72070 \    func_basename_result="${1##*/}"\
72071 } # Extended-shell func_basename implementation' "$cfgfile" > $cfgfile.tmp \
72072   && mv -f "$cfgfile.tmp" "$cfgfile" \
72073     || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
72074 test 0 -eq $? || _lt_function_replace_fail=:
72075
72076
72077   sed -e '/^func_dirname_and_basename ()$/,/^} # func_dirname_and_basename /c\
72078 func_dirname_and_basename ()\
72079 {\
72080 \    case ${1} in\
72081 \      */*) func_dirname_result="${1%/*}${2}" ;;\
72082 \      *  ) func_dirname_result="${3}" ;;\
72083 \    esac\
72084 \    func_basename_result="${1##*/}"\
72085 } # Extended-shell func_dirname_and_basename implementation' "$cfgfile" > $cfgfile.tmp \
72086   && mv -f "$cfgfile.tmp" "$cfgfile" \
72087     || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
72088 test 0 -eq $? || _lt_function_replace_fail=:
72089
72090
72091   sed -e '/^func_stripname ()$/,/^} # func_stripname /c\
72092 func_stripname ()\
72093 {\
72094 \    # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are\
72095 \    # positional parameters, so assign one to ordinary parameter first.\
72096 \    func_stripname_result=${3}\
72097 \    func_stripname_result=${func_stripname_result#"${1}"}\
72098 \    func_stripname_result=${func_stripname_result%"${2}"}\
72099 } # Extended-shell func_stripname implementation' "$cfgfile" > $cfgfile.tmp \
72100   && mv -f "$cfgfile.tmp" "$cfgfile" \
72101     || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
72102 test 0 -eq $? || _lt_function_replace_fail=:
72103
72104
72105   sed -e '/^func_split_long_opt ()$/,/^} # func_split_long_opt /c\
72106 func_split_long_opt ()\
72107 {\
72108 \    func_split_long_opt_name=${1%%=*}\
72109 \    func_split_long_opt_arg=${1#*=}\
72110 } # Extended-shell func_split_long_opt implementation' "$cfgfile" > $cfgfile.tmp \
72111   && mv -f "$cfgfile.tmp" "$cfgfile" \
72112     || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
72113 test 0 -eq $? || _lt_function_replace_fail=:
72114
72115
72116   sed -e '/^func_split_short_opt ()$/,/^} # func_split_short_opt /c\
72117 func_split_short_opt ()\
72118 {\
72119 \    func_split_short_opt_arg=${1#??}\
72120 \    func_split_short_opt_name=${1%"$func_split_short_opt_arg"}\
72121 } # Extended-shell func_split_short_opt implementation' "$cfgfile" > $cfgfile.tmp \
72122   && mv -f "$cfgfile.tmp" "$cfgfile" \
72123     || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
72124 test 0 -eq $? || _lt_function_replace_fail=:
72125
72126
72127   sed -e '/^func_lo2o ()$/,/^} # func_lo2o /c\
72128 func_lo2o ()\
72129 {\
72130 \    case ${1} in\
72131 \      *.lo) func_lo2o_result=${1%.lo}.${objext} ;;\
72132 \      *)    func_lo2o_result=${1} ;;\
72133 \    esac\
72134 } # Extended-shell func_lo2o implementation' "$cfgfile" > $cfgfile.tmp \
72135   && mv -f "$cfgfile.tmp" "$cfgfile" \
72136     || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
72137 test 0 -eq $? || _lt_function_replace_fail=:
72138
72139
72140   sed -e '/^func_xform ()$/,/^} # func_xform /c\
72141 func_xform ()\
72142 {\
72143     func_xform_result=${1%.*}.lo\
72144 } # Extended-shell func_xform implementation' "$cfgfile" > $cfgfile.tmp \
72145   && mv -f "$cfgfile.tmp" "$cfgfile" \
72146     || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
72147 test 0 -eq $? || _lt_function_replace_fail=:
72148
72149
72150   sed -e '/^func_arith ()$/,/^} # func_arith /c\
72151 func_arith ()\
72152 {\
72153     func_arith_result=$(( $* ))\
72154 } # Extended-shell func_arith implementation' "$cfgfile" > $cfgfile.tmp \
72155   && mv -f "$cfgfile.tmp" "$cfgfile" \
72156     || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
72157 test 0 -eq $? || _lt_function_replace_fail=:
72158
72159
72160   sed -e '/^func_len ()$/,/^} # func_len /c\
72161 func_len ()\
72162 {\
72163     func_len_result=${#1}\
72164 } # Extended-shell func_len implementation' "$cfgfile" > $cfgfile.tmp \
72165   && mv -f "$cfgfile.tmp" "$cfgfile" \
72166     || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
72167 test 0 -eq $? || _lt_function_replace_fail=:
72168
72169 fi
72170
72171 if test x"$lt_shell_append" = xyes; then
72172   sed -e '/^func_append ()$/,/^} # func_append /c\
72173 func_append ()\
72174 {\
72175     eval "${1}+=\\${2}"\
72176 } # Extended-shell func_append implementation' "$cfgfile" > $cfgfile.tmp \
72177   && mv -f "$cfgfile.tmp" "$cfgfile" \
72178     || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
72179 test 0 -eq $? || _lt_function_replace_fail=:
72180
72181
72182   sed -e '/^func_append_quoted ()$/,/^} # func_append_quoted /c\
72183 func_append_quoted ()\
72184 {\
72185 \    func_quote_for_eval "${2}"\
72186 \    eval "${1}+=\\\\ \\$func_quote_for_eval_result"\
72187 } # Extended-shell func_append_quoted implementation' "$cfgfile" > $cfgfile.tmp \
72188   && mv -f "$cfgfile.tmp" "$cfgfile" \
72189     || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
72190 test 0 -eq $? || _lt_function_replace_fail=:
72191
72192
72193   # Save a `func_append' function call where possible by direct use of '+='
72194   sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \
72195     && mv -f "$cfgfile.tmp" "$cfgfile" \
72196       || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
72197   test 0 -eq $? || _lt_function_replace_fail=:
72198 else
72199   # Save a `func_append' function call even when '+=' is not available
72200   sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \
72201     && mv -f "$cfgfile.tmp" "$cfgfile" \
72202       || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
72203   test 0 -eq $? || _lt_function_replace_fail=:
72204 fi
72205
72206 if test x"$_lt_function_replace_fail" = x":"; then
72207   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unable to substitute extended shell functions in $ofile" >&5
72208 $as_echo "$as_me: WARNING: Unable to substitute extended shell functions in $ofile" >&2;}
72209 fi
72210
72211
72212    mv -f "$cfgfile" "$ofile" ||
72213     (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
72214   chmod +x "$ofile"
72215
72216  ;;
72217     "po-directories":C)
72218     for ac_file in $CONFIG_FILES; do
72219       # Support "outfile[:infile[:infile...]]"
72220       case "$ac_file" in
72221         *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
72222       esac
72223       # PO directories have a Makefile.in generated from Makefile.in.in.
72224       case "$ac_file" in */Makefile.in)
72225         # Adjust a relative srcdir.
72226         ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
72227         ac_dir_suffix="/`echo "$ac_dir"|sed 's%^\./%%'`"
72228         ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
72229         # In autoconf-2.13 it is called $ac_given_srcdir.
72230         # In autoconf-2.50 it is called $srcdir.
72231         test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
72232         case "$ac_given_srcdir" in
72233           .)  top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
72234           /*) top_srcdir="$ac_given_srcdir" ;;
72235           *)  top_srcdir="$ac_dots$ac_given_srcdir" ;;
72236         esac
72237         # Treat a directory as a PO directory if and only if it has a
72238         # POTFILES.in file. This allows packages to have multiple PO
72239         # directories under different names or in different locations.
72240         if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
72241           rm -f "$ac_dir/POTFILES"
72242           test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES"
72243           cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[   ]*\$/d" -e "s,.*,     $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES"
72244           POMAKEFILEDEPS="POTFILES.in"
72245           # ALL_LINGUAS, POFILES, UPDATEPOFILES, DUMMYPOFILES, GMOFILES depend
72246           # on $ac_dir but don't depend on user-specified configuration
72247           # parameters.
72248           if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
72249             # The LINGUAS file contains the set of available languages.
72250             if test -n "$OBSOLETE_ALL_LINGUAS"; then
72251               test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.in is obsolete" || echo "setting ALL_LINGUAS in configure.in is obsolete"
72252             fi
72253             ALL_LINGUAS_=`sed -e "/^#/d" -e "s/#.*//" "$ac_given_srcdir/$ac_dir/LINGUAS"`
72254             # Hide the ALL_LINGUAS assigment from automake < 1.5.
72255             eval 'ALL_LINGUAS''=$ALL_LINGUAS_'
72256             POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
72257           else
72258             # The set of available languages was given in configure.in.
72259             # Hide the ALL_LINGUAS assigment from automake < 1.5.
72260             eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS'
72261           fi
72262           # Compute POFILES
72263           # as      $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).po)
72264           # Compute UPDATEPOFILES
72265           # as      $(foreach lang, $(ALL_LINGUAS), $(lang).po-update)
72266           # Compute DUMMYPOFILES
72267           # as      $(foreach lang, $(ALL_LINGUAS), $(lang).nop)
72268           # Compute GMOFILES
72269           # as      $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).gmo)
72270           case "$ac_given_srcdir" in
72271             .) srcdirpre= ;;
72272             *) srcdirpre='$(srcdir)/' ;;
72273           esac
72274           POFILES=
72275           UPDATEPOFILES=
72276           DUMMYPOFILES=
72277           GMOFILES=
72278           for lang in $ALL_LINGUAS; do
72279             POFILES="$POFILES $srcdirpre$lang.po"
72280             UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
72281             DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
72282             GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
72283           done
72284           # CATALOGS depends on both $ac_dir and the user's LINGUAS
72285           # environment variable.
72286           INST_LINGUAS=
72287           if test -n "$ALL_LINGUAS"; then
72288             for presentlang in $ALL_LINGUAS; do
72289               useit=no
72290               if test "%UNSET%" != "$LINGUAS"; then
72291                 desiredlanguages="$LINGUAS"
72292               else
72293                 desiredlanguages="$ALL_LINGUAS"
72294               fi
72295               for desiredlang in $desiredlanguages; do
72296                 # Use the presentlang catalog if desiredlang is
72297                 #   a. equal to presentlang, or
72298                 #   b. a variant of presentlang (because in this case,
72299                 #      presentlang can be used as a fallback for messages
72300                 #      which are not translated in the desiredlang catalog).
72301                 case "$desiredlang" in
72302                   "$presentlang"*) useit=yes;;
72303                 esac
72304               done
72305               if test $useit = yes; then
72306                 INST_LINGUAS="$INST_LINGUAS $presentlang"
72307               fi
72308             done
72309           fi
72310           CATALOGS=
72311           if test -n "$INST_LINGUAS"; then
72312             for lang in $INST_LINGUAS; do
72313               CATALOGS="$CATALOGS $lang.gmo"
72314             done
72315           fi
72316           test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
72317           sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
72318           for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do
72319             if test -f "$f"; then
72320               case "$f" in
72321                 *.orig | *.bak | *~) ;;
72322                 *) cat "$f" >> "$ac_dir/Makefile" ;;
72323               esac
72324             fi
72325           done
72326         fi
72327         ;;
72328       esac
72329     done ;;
72330     "run":F) chmod +x,-w run ;;
72331
72332   esac
72333 done # for ac_tag
72334
72335
72336 as_fn_exit 0
72337 _ACEOF
72338 ac_clean_files=$ac_clean_files_save
72339
72340 test $ac_write_fail = 0 ||
72341   as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
72342
72343
72344 # configure is writing to config.log, and then calls config.status.
72345 # config.status does its own redirection, appending to config.log.
72346 # Unfortunately, on DOS this fails, as config.log is still kept open
72347 # by configure, so config.status won't be able to write to it; its
72348 # output is simply discarded.  So we exec the FD to /dev/null,
72349 # effectively closing config.log, so it can be properly (re)opened and
72350 # appended to by config.status.  When coming back to configure, we
72351 # need to make the FD available again.
72352 if test "$no_create" != yes; then
72353   ac_cs_success=:
72354   ac_config_status_args=
72355   test "$silent" = yes &&
72356     ac_config_status_args="$ac_config_status_args --quiet"
72357   exec 5>/dev/null
72358   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
72359   exec 5>>config.log
72360   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
72361   # would make configure fail if this is the last instruction.
72362   $ac_cs_success || as_fn_exit 1
72363 fi
72364 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
72365   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
72366 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
72367 fi
72368
72369
72370 { $as_echo "$as_me:${as_lineno-$LINENO}: " >&5
72371 $as_echo "$as_me: " >&6;}
72372 { $as_echo "$as_me:${as_lineno-$LINENO}: Configuration summary" >&5
72373 $as_echo "$as_me: Configuration summary" >&6;}
72374 { $as_echo "$as_me:${as_lineno-$LINENO}: =====================" >&5
72375 $as_echo "$as_me: =====================" >&6;}
72376 { $as_echo "$as_me:${as_lineno-$LINENO}: " >&5
72377 $as_echo "$as_me: " >&6;}
72378 { $as_echo "$as_me:${as_lineno-$LINENO}: Drivers" >&5
72379 $as_echo "$as_me: Drivers" >&6;}
72380 { $as_echo "$as_me:${as_lineno-$LINENO}: " >&5
72381 $as_echo "$as_me: " >&6;}
72382 { $as_echo "$as_me:${as_lineno-$LINENO}:       Xen: $with_xen" >&5
72383 $as_echo "$as_me:       Xen: $with_xen" >&6;}
72384 { $as_echo "$as_me:${as_lineno-$LINENO}:      QEMU: $with_qemu" >&5
72385 $as_echo "$as_me:      QEMU: $with_qemu" >&6;}
72386 { $as_echo "$as_me:${as_lineno-$LINENO}:       UML: $with_uml" >&5
72387 $as_echo "$as_me:       UML: $with_uml" >&6;}
72388 { $as_echo "$as_me:${as_lineno-$LINENO}:    OpenVZ: $with_openvz" >&5
72389 $as_echo "$as_me:    OpenVZ: $with_openvz" >&6;}
72390 { $as_echo "$as_me:${as_lineno-$LINENO}:    VMware: $with_vmware" >&5
72391 $as_echo "$as_me:    VMware: $with_vmware" >&6;}
72392 { $as_echo "$as_me:${as_lineno-$LINENO}:      VBox: $with_vbox" >&5
72393 $as_echo "$as_me:      VBox: $with_vbox" >&6;}
72394 { $as_echo "$as_me:${as_lineno-$LINENO}:    XenAPI: $with_xenapi" >&5
72395 $as_echo "$as_me:    XenAPI: $with_xenapi" >&6;}
72396 { $as_echo "$as_me:${as_lineno-$LINENO}:  xenlight: $with_libxl" >&5
72397 $as_echo "$as_me:  xenlight: $with_libxl" >&6;}
72398 { $as_echo "$as_me:${as_lineno-$LINENO}:       LXC: $with_lxc" >&5
72399 $as_echo "$as_me:       LXC: $with_lxc" >&6;}
72400 { $as_echo "$as_me:${as_lineno-$LINENO}:      PHYP: $with_phyp" >&5
72401 $as_echo "$as_me:      PHYP: $with_phyp" >&6;}
72402 { $as_echo "$as_me:${as_lineno-$LINENO}:       ESX: $with_esx" >&5
72403 $as_echo "$as_me:       ESX: $with_esx" >&6;}
72404 { $as_echo "$as_me:${as_lineno-$LINENO}:   Hyper-V: $with_hyperv" >&5
72405 $as_echo "$as_me:   Hyper-V: $with_hyperv" >&6;}
72406 { $as_echo "$as_me:${as_lineno-$LINENO}: Parallels: $with_parallels" >&5
72407 $as_echo "$as_me: Parallels: $with_parallels" >&6;}
72408
72409     { $as_echo "$as_me:${as_lineno-$LINENO}:     Bhyve: $with_bhyve" >&5
72410 $as_echo "$as_me:     Bhyve: $with_bhyve" >&6;}
72411
72412 { $as_echo "$as_me:${as_lineno-$LINENO}:      Test: $with_test" >&5
72413 $as_echo "$as_me:      Test: $with_test" >&6;}
72414 { $as_echo "$as_me:${as_lineno-$LINENO}:    Remote: $with_remote" >&5
72415 $as_echo "$as_me:    Remote: $with_remote" >&6;}
72416 { $as_echo "$as_me:${as_lineno-$LINENO}:   Network: $with_network" >&5
72417 $as_echo "$as_me:   Network: $with_network" >&6;}
72418 { $as_echo "$as_me:${as_lineno-$LINENO}:  Libvirtd: $with_libvirtd" >&5
72419 $as_echo "$as_me:  Libvirtd: $with_libvirtd" >&6;}
72420 { $as_echo "$as_me:${as_lineno-$LINENO}: Interface: $with_interface" >&5
72421 $as_echo "$as_me: Interface: $with_interface" >&6;}
72422 { $as_echo "$as_me:${as_lineno-$LINENO}:   macvtap: $with_macvtap" >&5
72423 $as_echo "$as_me:   macvtap: $with_macvtap" >&6;}
72424 { $as_echo "$as_me:${as_lineno-$LINENO}:  virtport: $with_virtualport" >&5
72425 $as_echo "$as_me:  virtport: $with_virtualport" >&6;}
72426 { $as_echo "$as_me:${as_lineno-$LINENO}: " >&5
72427 $as_echo "$as_me: " >&6;}
72428 { $as_echo "$as_me:${as_lineno-$LINENO}: Storage Drivers" >&5
72429 $as_echo "$as_me: Storage Drivers" >&6;}
72430 { $as_echo "$as_me:${as_lineno-$LINENO}: " >&5
72431 $as_echo "$as_me: " >&6;}
72432 { $as_echo "$as_me:${as_lineno-$LINENO}:      Dir: $with_storage_dir" >&5
72433 $as_echo "$as_me:      Dir: $with_storage_dir" >&6;}
72434 { $as_echo "$as_me:${as_lineno-$LINENO}:       FS: $with_storage_fs" >&5
72435 $as_echo "$as_me:       FS: $with_storage_fs" >&6;}
72436 { $as_echo "$as_me:${as_lineno-$LINENO}:    NetFS: $with_storage_fs" >&5
72437 $as_echo "$as_me:    NetFS: $with_storage_fs" >&6;}
72438 { $as_echo "$as_me:${as_lineno-$LINENO}:      LVM: $with_storage_lvm" >&5
72439 $as_echo "$as_me:      LVM: $with_storage_lvm" >&6;}
72440 { $as_echo "$as_me:${as_lineno-$LINENO}:    iSCSI: $with_storage_iscsi" >&5
72441 $as_echo "$as_me:    iSCSI: $with_storage_iscsi" >&6;}
72442 { $as_echo "$as_me:${as_lineno-$LINENO}:     SCSI: $with_storage_scsi" >&5
72443 $as_echo "$as_me:     SCSI: $with_storage_scsi" >&6;}
72444 { $as_echo "$as_me:${as_lineno-$LINENO}:    mpath: $with_storage_mpath" >&5
72445 $as_echo "$as_me:    mpath: $with_storage_mpath" >&6;}
72446 { $as_echo "$as_me:${as_lineno-$LINENO}:     Disk: $with_storage_disk" >&5
72447 $as_echo "$as_me:     Disk: $with_storage_disk" >&6;}
72448 { $as_echo "$as_me:${as_lineno-$LINENO}:      RBD: $with_storage_rbd" >&5
72449 $as_echo "$as_me:      RBD: $with_storage_rbd" >&6;}
72450 { $as_echo "$as_me:${as_lineno-$LINENO}: Sheepdog: $with_storage_sheepdog" >&5
72451 $as_echo "$as_me: Sheepdog: $with_storage_sheepdog" >&6;}
72452 { $as_echo "$as_me:${as_lineno-$LINENO}:  Gluster: $with_storage_gluster" >&5
72453 $as_echo "$as_me:  Gluster: $with_storage_gluster" >&6;}
72454 { $as_echo "$as_me:${as_lineno-$LINENO}: " >&5
72455 $as_echo "$as_me: " >&6;}
72456 { $as_echo "$as_me:${as_lineno-$LINENO}: Security Drivers" >&5
72457 $as_echo "$as_me: Security Drivers" >&6;}
72458 { $as_echo "$as_me:${as_lineno-$LINENO}: " >&5
72459 $as_echo "$as_me: " >&6;}
72460 { $as_echo "$as_me:${as_lineno-$LINENO}:  SELinux: $with_secdriver_selinux ($SELINUX_MOUNT)" >&5
72461 $as_echo "$as_me:  SELinux: $with_secdriver_selinux ($SELINUX_MOUNT)" >&6;}
72462 { $as_echo "$as_me:${as_lineno-$LINENO}: AppArmor: $with_secdriver_apparmor (install profiles: $with_apparmor_profiles)" >&5
72463 $as_echo "$as_me: AppArmor: $with_secdriver_apparmor (install profiles: $with_apparmor_profiles)" >&6;}
72464 { $as_echo "$as_me:${as_lineno-$LINENO}: " >&5
72465 $as_echo "$as_me: " >&6;}
72466 { $as_echo "$as_me:${as_lineno-$LINENO}: Driver Loadable Modules" >&5
72467 $as_echo "$as_me: Driver Loadable Modules" >&6;}
72468 { $as_echo "$as_me:${as_lineno-$LINENO}: " >&5
72469 $as_echo "$as_me: " >&6;}
72470 if test "$with_driver_modules" != "no" ; then
72471 { $as_echo "$as_me:${as_lineno-$LINENO}:   dlopen: $DRIVER_MODULE_CFLAGS $DRIVER_MODULE_LIBS" >&5
72472 $as_echo "$as_me:   dlopen: $DRIVER_MODULE_CFLAGS $DRIVER_MODULE_LIBS" >&6;}
72473 else
72474 { $as_echo "$as_me:${as_lineno-$LINENO}:   dlopen: no" >&5
72475 $as_echo "$as_me:   dlopen: no" >&6;}
72476 fi
72477 { $as_echo "$as_me:${as_lineno-$LINENO}: " >&5
72478 $as_echo "$as_me: " >&6;}
72479 { $as_echo "$as_me:${as_lineno-$LINENO}: Libraries" >&5
72480 $as_echo "$as_me: Libraries" >&6;}
72481 { $as_echo "$as_me:${as_lineno-$LINENO}: " >&5
72482 $as_echo "$as_me: " >&6;}
72483
72484
72485
72486
72487
72488
72489
72490
72491
72492
72493
72494   if test "$with_apparmor" = "no" || test -z "CFLAGS='$APPARMOR_CFLAGS' LIBS='$APPARMOR_LIBS'" ; then
72495     STR=`printf "%10s: %-3s" "apparmor" "$with_apparmor"`
72496   else
72497     STR=`printf "%10s: %-3s (%s)" "apparmor" "$with_apparmor" "CFLAGS='$APPARMOR_CFLAGS' LIBS='$APPARMOR_LIBS'"`
72498   fi
72499
72500   { $as_echo "$as_me:${as_lineno-$LINENO}: $STR" >&5
72501 $as_echo "$as_me: $STR" >&6;}
72502
72503
72504
72505
72506
72507
72508
72509
72510
72511
72512
72513
72514
72515
72516
72517
72518
72519
72520
72521
72522
72523
72524   if test "$with_attr" = "no" || test -z "CFLAGS='$ATTR_CFLAGS' LIBS='$ATTR_LIBS'" ; then
72525     STR=`printf "%10s: %-3s" "attr" "$with_attr"`
72526   else
72527     STR=`printf "%10s: %-3s (%s)" "attr" "$with_attr" "CFLAGS='$ATTR_CFLAGS' LIBS='$ATTR_LIBS'"`
72528   fi
72529
72530   { $as_echo "$as_me:${as_lineno-$LINENO}: $STR" >&5
72531 $as_echo "$as_me: $STR" >&6;}
72532
72533
72534
72535
72536
72537
72538
72539
72540
72541
72542
72543
72544
72545
72546
72547
72548
72549
72550
72551
72552
72553
72554   if test "$with_audit" = "no" || test -z "CFLAGS='$AUDIT_CFLAGS' LIBS='$AUDIT_LIBS'" ; then
72555     STR=`printf "%10s: %-3s" "audit" "$with_audit"`
72556   else
72557     STR=`printf "%10s: %-3s (%s)" "audit" "$with_audit" "CFLAGS='$AUDIT_CFLAGS' LIBS='$AUDIT_LIBS'"`
72558   fi
72559
72560   { $as_echo "$as_me:${as_lineno-$LINENO}: $STR" >&5
72561 $as_echo "$as_me: $STR" >&6;}
72562
72563
72564
72565
72566
72567
72568
72569
72570
72571
72572
72573
72574
72575
72576
72577
72578
72579
72580
72581
72582
72583
72584   if test "$with_avahi" = "no" || test -z "CFLAGS='$AVAHI_CFLAGS' LIBS='$AVAHI_LIBS'" ; then
72585     STR=`printf "%10s: %-3s" "avahi" "$with_avahi"`
72586   else
72587     STR=`printf "%10s: %-3s (%s)" "avahi" "$with_avahi" "CFLAGS='$AVAHI_CFLAGS' LIBS='$AVAHI_LIBS'"`
72588   fi
72589
72590   { $as_echo "$as_me:${as_lineno-$LINENO}: $STR" >&5
72591 $as_echo "$as_me: $STR" >&6;}
72592
72593
72594
72595
72596
72597
72598
72599
72600
72601
72602
72603
72604
72605
72606
72607
72608
72609
72610
72611
72612
72613
72614   if test "$with_blkid" = "no" || test -z "CFLAGS='$BLKID_CFLAGS' LIBS='$BLKID_LIBS'" ; then
72615     STR=`printf "%10s: %-3s" "blkid" "$with_blkid"`
72616   else
72617     STR=`printf "%10s: %-3s (%s)" "blkid" "$with_blkid" "CFLAGS='$BLKID_CFLAGS' LIBS='$BLKID_LIBS'"`
72618   fi
72619
72620   { $as_echo "$as_me:${as_lineno-$LINENO}: $STR" >&5
72621 $as_echo "$as_me: $STR" >&6;}
72622
72623
72624
72625
72626
72627
72628
72629
72630
72631
72632
72633
72634
72635
72636
72637
72638
72639
72640
72641
72642
72643
72644   if test "$with_capng" = "no" || test -z "CFLAGS='$CAPNG_CFLAGS' LIBS='$CAPNG_LIBS'" ; then
72645     STR=`printf "%10s: %-3s" "capng" "$with_capng"`
72646   else
72647     STR=`printf "%10s: %-3s (%s)" "capng" "$with_capng" "CFLAGS='$CAPNG_CFLAGS' LIBS='$CAPNG_LIBS'"`
72648   fi
72649
72650   { $as_echo "$as_me:${as_lineno-$LINENO}: $STR" >&5
72651 $as_echo "$as_me: $STR" >&6;}
72652
72653
72654
72655
72656
72657
72658
72659
72660
72661
72662
72663
72664
72665
72666
72667
72668
72669
72670
72671
72672
72673
72674   if test "$with_curl" = "no" || test -z "CFLAGS='$CURL_CFLAGS' LIBS='$CURL_LIBS'" ; then
72675     STR=`printf "%10s: %-3s" "curl" "$with_curl"`
72676   else
72677     STR=`printf "%10s: %-3s (%s)" "curl" "$with_curl" "CFLAGS='$CURL_CFLAGS' LIBS='$CURL_LIBS'"`
72678   fi
72679
72680   { $as_echo "$as_me:${as_lineno-$LINENO}: $STR" >&5
72681 $as_echo "$as_me: $STR" >&6;}
72682
72683
72684
72685
72686
72687
72688
72689
72690
72691
72692
72693
72694
72695
72696
72697
72698
72699
72700
72701
72702
72703
72704   if test "$with_dbus" = "no" || test -z "CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" ; then
72705     STR=`printf "%10s: %-3s" "dbus" "$with_dbus"`
72706   else
72707     STR=`printf "%10s: %-3s (%s)" "dbus" "$with_dbus" "CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'"`
72708   fi
72709
72710   { $as_echo "$as_me:${as_lineno-$LINENO}: $STR" >&5
72711 $as_echo "$as_me: $STR" >&6;}
72712
72713
72714
72715
72716
72717
72718
72719
72720
72721
72722
72723
72724
72725
72726
72727
72728
72729
72730
72731
72732
72733
72734   if test "$with_fuse" = "no" || test -z "CFLAGS='$FUSE_CFLAGS' LIBS='$FUSE_LIBS'" ; then
72735     STR=`printf "%10s: %-3s" "fuse" "$with_fuse"`
72736   else
72737     STR=`printf "%10s: %-3s (%s)" "fuse" "$with_fuse" "CFLAGS='$FUSE_CFLAGS' LIBS='$FUSE_LIBS'"`
72738   fi
72739
72740   { $as_echo "$as_me:${as_lineno-$LINENO}: $STR" >&5
72741 $as_echo "$as_me: $STR" >&6;}
72742
72743
72744
72745
72746
72747
72748
72749
72750
72751
72752
72753
72754
72755
72756
72757
72758
72759
72760
72761
72762
72763
72764   if test "$with_glusterfs" = "no" || test -z "CFLAGS='$GLUSTERFS_CFLAGS' LIBS='$GLUSTERFS_LIBS'" ; then
72765     STR=`printf "%10s: %-3s" "glusterfs" "$with_glusterfs"`
72766   else
72767     STR=`printf "%10s: %-3s (%s)" "glusterfs" "$with_glusterfs" "CFLAGS='$GLUSTERFS_CFLAGS' LIBS='$GLUSTERFS_LIBS'"`
72768   fi
72769
72770   { $as_echo "$as_me:${as_lineno-$LINENO}: $STR" >&5
72771 $as_echo "$as_me: $STR" >&6;}
72772
72773
72774
72775
72776
72777
72778
72779
72780
72781
72782
72783
72784
72785
72786
72787
72788
72789
72790
72791
72792
72793
72794   if test "$with_hal" = "no" || test -z "CFLAGS='$HAL_CFLAGS' LIBS='$HAL_LIBS'" ; then
72795     STR=`printf "%10s: %-3s" "hal" "$with_hal"`
72796   else
72797     STR=`printf "%10s: %-3s (%s)" "hal" "$with_hal" "CFLAGS='$HAL_CFLAGS' LIBS='$HAL_LIBS'"`
72798   fi
72799
72800   { $as_echo "$as_me:${as_lineno-$LINENO}: $STR" >&5
72801 $as_echo "$as_me: $STR" >&6;}
72802
72803
72804
72805
72806
72807
72808
72809
72810
72811
72812
72813
72814
72815
72816
72817
72818
72819
72820
72821
72822
72823
72824   if test "$with_netcf" = "no" || test -z "CFLAGS='$NETCF_CFLAGS' LIBS='$NETCF_LIBS'" ; then
72825     STR=`printf "%10s: %-3s" "netcf" "$with_netcf"`
72826   else
72827     STR=`printf "%10s: %-3s (%s)" "netcf" "$with_netcf" "CFLAGS='$NETCF_CFLAGS' LIBS='$NETCF_LIBS'"`
72828   fi
72829
72830   { $as_echo "$as_me:${as_lineno-$LINENO}: $STR" >&5
72831 $as_echo "$as_me: $STR" >&6;}
72832
72833
72834
72835
72836
72837
72838
72839
72840
72841
72842
72843
72844
72845
72846
72847
72848
72849
72850
72851
72852
72853
72854   if test "$with_numactl" = "no" || test -z "CFLAGS='$NUMACTL_CFLAGS' LIBS='$NUMACTL_LIBS'" ; then
72855     STR=`printf "%10s: %-3s" "numactl" "$with_numactl"`
72856   else
72857     STR=`printf "%10s: %-3s (%s)" "numactl" "$with_numactl" "CFLAGS='$NUMACTL_CFLAGS' LIBS='$NUMACTL_LIBS'"`
72858   fi
72859
72860   { $as_echo "$as_me:${as_lineno-$LINENO}: $STR" >&5
72861 $as_echo "$as_me: $STR" >&6;}
72862
72863
72864
72865
72866
72867
72868
72869
72870
72871
72872
72873
72874
72875
72876
72877
72878
72879
72880
72881
72882
72883
72884   if test "$with_openwsman" = "no" || test -z "CFLAGS='$OPENWSMAN_CFLAGS' LIBS='$OPENWSMAN_LIBS'" ; then
72885     STR=`printf "%10s: %-3s" "openwsman" "$with_openwsman"`
72886   else
72887     STR=`printf "%10s: %-3s (%s)" "openwsman" "$with_openwsman" "CFLAGS='$OPENWSMAN_CFLAGS' LIBS='$OPENWSMAN_LIBS'"`
72888   fi
72889
72890   { $as_echo "$as_me:${as_lineno-$LINENO}: $STR" >&5
72891 $as_echo "$as_me: $STR" >&6;}
72892
72893
72894
72895
72896
72897
72898
72899
72900
72901
72902
72903
72904
72905
72906
72907
72908
72909
72910
72911
72912
72913
72914   if test "$with_pciaccess" = "no" || test -z "CFLAGS='$PCIACCESS_CFLAGS' LIBS='$PCIACCESS_LIBS'" ; then
72915     STR=`printf "%10s: %-3s" "pciaccess" "$with_pciaccess"`
72916   else
72917     STR=`printf "%10s: %-3s (%s)" "pciaccess" "$with_pciaccess" "CFLAGS='$PCIACCESS_CFLAGS' LIBS='$PCIACCESS_LIBS'"`
72918   fi
72919
72920   { $as_echo "$as_me:${as_lineno-$LINENO}: $STR" >&5
72921 $as_echo "$as_me: $STR" >&6;}
72922
72923
72924
72925
72926
72927
72928
72929
72930
72931
72932
72933
72934
72935
72936
72937
72938
72939
72940
72941
72942
72943
72944   if test "$with_readline" = "no" || test -z "CFLAGS='$READLINE_CFLAGS' LIBS='$READLINE_LIBS'" ; then
72945     STR=`printf "%10s: %-3s" "readline" "$with_readline"`
72946   else
72947     STR=`printf "%10s: %-3s (%s)" "readline" "$with_readline" "CFLAGS='$READLINE_CFLAGS' LIBS='$READLINE_LIBS'"`
72948   fi
72949
72950   { $as_echo "$as_me:${as_lineno-$LINENO}: $STR" >&5
72951 $as_echo "$as_me: $STR" >&6;}
72952
72953
72954
72955
72956
72957
72958
72959
72960
72961
72962
72963
72964
72965
72966
72967
72968
72969
72970
72971
72972
72973
72974   if test "$with_sanlock" = "no" || test -z "CFLAGS='$SANLOCK_CFLAGS' LIBS='$SANLOCK_LIBS'" ; then
72975     STR=`printf "%10s: %-3s" "sanlock" "$with_sanlock"`
72976   else
72977     STR=`printf "%10s: %-3s (%s)" "sanlock" "$with_sanlock" "CFLAGS='$SANLOCK_CFLAGS' LIBS='$SANLOCK_LIBS'"`
72978   fi
72979
72980   { $as_echo "$as_me:${as_lineno-$LINENO}: $STR" >&5
72981 $as_echo "$as_me: $STR" >&6;}
72982
72983
72984
72985
72986
72987
72988
72989
72990
72991
72992
72993
72994
72995
72996
72997
72998
72999
73000
73001
73002
73003
73004   if test "$with_sasl" = "no" || test -z "CFLAGS='$SASL_CFLAGS' LIBS='$SASL_LIBS'" ; then
73005     STR=`printf "%10s: %-3s" "sasl" "$with_sasl"`
73006   else
73007     STR=`printf "%10s: %-3s (%s)" "sasl" "$with_sasl" "CFLAGS='$SASL_CFLAGS' LIBS='$SASL_LIBS'"`
73008   fi
73009
73010   { $as_echo "$as_me:${as_lineno-$LINENO}: $STR" >&5
73011 $as_echo "$as_me: $STR" >&6;}
73012
73013
73014
73015
73016
73017
73018
73019
73020
73021
73022
73023
73024
73025
73026
73027
73028
73029
73030
73031
73032
73033
73034   if test "$with_selinux" = "no" || test -z "CFLAGS='$SELINUX_CFLAGS' LIBS='$SELINUX_LIBS'" ; then
73035     STR=`printf "%10s: %-3s" "selinux" "$with_selinux"`
73036   else
73037     STR=`printf "%10s: %-3s (%s)" "selinux" "$with_selinux" "CFLAGS='$SELINUX_CFLAGS' LIBS='$SELINUX_LIBS'"`
73038   fi
73039
73040   { $as_echo "$as_me:${as_lineno-$LINENO}: $STR" >&5
73041 $as_echo "$as_me: $STR" >&6;}
73042
73043
73044
73045
73046
73047
73048
73049
73050
73051
73052
73053
73054
73055
73056
73057
73058
73059
73060
73061
73062
73063
73064   if test "$with_ssh2" = "no" || test -z "CFLAGS='$SSH2_CFLAGS' LIBS='$SSH2_LIBS'" ; then
73065     STR=`printf "%10s: %-3s" "ssh2" "$with_ssh2"`
73066   else
73067     STR=`printf "%10s: %-3s (%s)" "ssh2" "$with_ssh2" "CFLAGS='$SSH2_CFLAGS' LIBS='$SSH2_LIBS'"`
73068   fi
73069
73070   { $as_echo "$as_me:${as_lineno-$LINENO}: $STR" >&5
73071 $as_echo "$as_me: $STR" >&6;}
73072
73073
73074
73075
73076
73077
73078
73079
73080
73081
73082
73083
73084
73085
73086
73087
73088
73089
73090
73091
73092
73093
73094   if test "$with_systemd_daemon" = "no" || test -z "CFLAGS='$SYSTEMD_DAEMON_CFLAGS' LIBS='$SYSTEMD_DAEMON_LIBS'" ; then
73095     STR=`printf "%10s: %-3s" "systemd_daemon" "$with_systemd_daemon"`
73096   else
73097     STR=`printf "%10s: %-3s (%s)" "systemd_daemon" "$with_systemd_daemon" "CFLAGS='$SYSTEMD_DAEMON_CFLAGS' LIBS='$SYSTEMD_DAEMON_LIBS'"`
73098   fi
73099
73100   { $as_echo "$as_me:${as_lineno-$LINENO}: $STR" >&5
73101 $as_echo "$as_me: $STR" >&6;}
73102
73103
73104
73105
73106
73107
73108
73109
73110
73111
73112
73113
73114
73115
73116
73117
73118
73119
73120
73121
73122
73123
73124
73125   if test "$with_udev" = "no" || test -z "CFLAGS='$UDEV_CFLAGS' LIBS='$UDEV_LIBS'" ; then
73126     STR=`printf "%10s: %-3s" "udev" "$with_udev"`
73127   else
73128     STR=`printf "%10s: %-3s (%s)" "udev" "$with_udev" "CFLAGS='$UDEV_CFLAGS' LIBS='$UDEV_LIBS'"`
73129   fi
73130
73131   { $as_echo "$as_me:${as_lineno-$LINENO}: $STR" >&5
73132 $as_echo "$as_me: $STR" >&6;}
73133
73134
73135
73136
73137
73138
73139
73140
73141
73142
73143
73144
73145
73146
73147
73148
73149
73150
73151
73152
73153
73154
73155   if test "$with_yajl" = "no" || test -z "CFLAGS='$YAJL_CFLAGS' LIBS='$YAJL_LIBS'" ; then
73156     STR=`printf "%10s: %-3s" "yajl" "$with_yajl"`
73157   else
73158     STR=`printf "%10s: %-3s (%s)" "yajl" "$with_yajl" "CFLAGS='$YAJL_CFLAGS' LIBS='$YAJL_LIBS'"`
73159   fi
73160
73161   { $as_echo "$as_me:${as_lineno-$LINENO}: $STR" >&5
73162 $as_echo "$as_me: $STR" >&6;}
73163
73164
73165
73166
73167
73168
73169
73170
73171
73172
73173
73174 { $as_echo "$as_me:${as_lineno-$LINENO}:   libxml: $LIBXML_CFLAGS $LIBXML_LIBS" >&5
73175 $as_echo "$as_me:   libxml: $LIBXML_CFLAGS $LIBXML_LIBS" >&6;}
73176 { $as_echo "$as_me:${as_lineno-$LINENO}:   dlopen: $DLOPEN_LIBS" >&5
73177 $as_echo "$as_me:   dlopen: $DLOPEN_LIBS" >&6;}
73178 if test "$with_hyperv" = "yes" ; then
73179 { $as_echo "$as_me:${as_lineno-$LINENO}: openwsman: $OPENWSMAN_CFLAGS $OPENWSMAN_LIBS" >&5
73180 $as_echo "$as_me: openwsman: $OPENWSMAN_CFLAGS $OPENWSMAN_LIBS" >&6;}
73181 else
73182 { $as_echo "$as_me:${as_lineno-$LINENO}: openwsman: no" >&5
73183 $as_echo "$as_me: openwsman: no" >&6;}
73184 fi
73185 if test "$with_gnutls" != "no" ; then
73186 { $as_echo "$as_me:${as_lineno-$LINENO}:   gnutls: $GNUTLS_CFLAGS $GNUTLS_LIBS" >&5
73187 $as_echo "$as_me:   gnutls: $GNUTLS_CFLAGS $GNUTLS_LIBS" >&6;}
73188 else
73189 { $as_echo "$as_me:${as_lineno-$LINENO}:   gnutls: no" >&5
73190 $as_echo "$as_me:   gnutls: no" >&6;}
73191 fi
73192 { $as_echo "$as_me:${as_lineno-$LINENO}: firewalld: $with_firewalld" >&5
73193 $as_echo "$as_me: firewalld: $with_firewalld" >&6;}
73194 if test "$with_polkit" = "yes" ; then
73195 if test "$with_polkit0" = "yes" ; then
73196 { $as_echo "$as_me:${as_lineno-$LINENO}:   polkit: $POLKIT_CFLAGS $POLKIT_LIBS (version 0)" >&5
73197 $as_echo "$as_me:   polkit: $POLKIT_CFLAGS $POLKIT_LIBS (version 0)" >&6;}
73198 else
73199 { $as_echo "$as_me:${as_lineno-$LINENO}:   polkit: $PKCHECK_PATH (version 1)" >&5
73200 $as_echo "$as_me:   polkit: $PKCHECK_PATH (version 1)" >&6;}
73201 fi
73202 else
73203 { $as_echo "$as_me:${as_lineno-$LINENO}:   polkit: no" >&5
73204 $as_echo "$as_me:   polkit: no" >&6;}
73205 fi
73206 if test "$with_xen" = "yes" ; then
73207 { $as_echo "$as_me:${as_lineno-$LINENO}:      xen: $XEN_CFLAGS $XEN_LIBS" >&5
73208 $as_echo "$as_me:      xen: $XEN_CFLAGS $XEN_LIBS" >&6;}
73209 else
73210 { $as_echo "$as_me:${as_lineno-$LINENO}:      xen: no" >&5
73211 $as_echo "$as_me:      xen: no" >&6;}
73212 fi
73213 if test "$with_xenapi" = "yes" ; then
73214 { $as_echo "$as_me:${as_lineno-$LINENO}:   xenapi: $LIBXENSERVER_CFLAGS $LIBXENSERVER_LIBS" >&5
73215 $as_echo "$as_me:   xenapi: $LIBXENSERVER_CFLAGS $LIBXENSERVER_LIBS" >&6;}
73216 else
73217 { $as_echo "$as_me:${as_lineno-$LINENO}:   xenapi: no" >&5
73218 $as_echo "$as_me:   xenapi: no" >&6;}
73219 fi
73220 if test "$with_libxl" = "yes" ; then
73221 { $as_echo "$as_me:${as_lineno-$LINENO}: xenlight: $LIBXL_CFLAGS $LIBXL_LIBS" >&5
73222 $as_echo "$as_me: xenlight: $LIBXL_CFLAGS $LIBXL_LIBS" >&6;}
73223 else
73224 { $as_echo "$as_me:${as_lineno-$LINENO}: xenlight: no" >&5
73225 $as_echo "$as_me: xenlight: no" >&6;}
73226 fi
73227 if test "$with_qemu" = "yes" && test "$LIBPCAP_FOUND" != "no"; then
73228 { $as_echo "$as_me:${as_lineno-$LINENO}:     pcap: $LIBPCAP_CFLAGS $LIBPCAP_LIBS" >&5
73229 $as_echo "$as_me:     pcap: $LIBPCAP_CFLAGS $LIBPCAP_LIBS" >&6;}
73230 else
73231 { $as_echo "$as_me:${as_lineno-$LINENO}:     pcap: no" >&5
73232 $as_echo "$as_me:     pcap: no" >&6;}
73233 fi
73234 if test "$have_libnl" = "yes" ; then
73235 { $as_echo "$as_me:${as_lineno-$LINENO}:       nl: $LIBNL_CFLAGS $LIBNL_LIBS" >&5
73236 $as_echo "$as_me:       nl: $LIBNL_CFLAGS $LIBNL_LIBS" >&6;}
73237 else
73238 { $as_echo "$as_me:${as_lineno-$LINENO}:       nl: no" >&5
73239 $as_echo "$as_me:       nl: no" >&6;}
73240 fi
73241 if test "$with_vbox" = "yes" && test -n "$MSCOM_LIBS" ; then
73242 { $as_echo "$as_me:${as_lineno-$LINENO}:    mscom: $MSCOM_LIBS" >&5
73243 $as_echo "$as_me:    mscom: $MSCOM_LIBS" >&6;}
73244 else
73245 { $as_echo "$as_me:${as_lineno-$LINENO}:    mscom: no" >&5
73246 $as_echo "$as_me:    mscom: no" >&6;}
73247 fi
73248 if test "$with_remote" = "yes" || test "$with_libvirtd" = "yes" ; then
73249 { $as_echo "$as_me:${as_lineno-$LINENO}:      xdr: $XDR_CFLAGS" >&5
73250 $as_echo "$as_me:      xdr: $XDR_CFLAGS" >&6;}
73251 else
73252 { $as_echo "$as_me:${as_lineno-$LINENO}:      xdr: no" >&5
73253 $as_echo "$as_me:      xdr: no" >&6;}
73254 fi
73255 if test "$with_storage_rbd" = "yes" ; then
73256 { $as_echo "$as_me:${as_lineno-$LINENO}:      rbd: $LIBRBD_LIBS" >&5
73257 $as_echo "$as_me:      rbd: $LIBRBD_LIBS" >&6;}
73258 else
73259 { $as_echo "$as_me:${as_lineno-$LINENO}:      rbd: no" >&5
73260 $as_echo "$as_me:      rbd: no" >&6;}
73261 fi
73262 { $as_echo "$as_me:${as_lineno-$LINENO}: pm-utils: $with_pm_utils" >&5
73263 $as_echo "$as_me: pm-utils: $with_pm_utils" >&6;}
73264
73265 { $as_echo "$as_me:${as_lineno-$LINENO}: " >&5
73266 $as_echo "$as_me: " >&6;}
73267 { $as_echo "$as_me:${as_lineno-$LINENO}: Test suite" >&5
73268 $as_echo "$as_me: Test suite" >&6;}
73269 { $as_echo "$as_me:${as_lineno-$LINENO}: " >&5
73270 $as_echo "$as_me: " >&6;}
73271 { $as_echo "$as_me:${as_lineno-$LINENO}:    Coverage: $enable_coverage" >&5
73272 $as_echo "$as_me:    Coverage: $enable_coverage" >&6;}
73273 { $as_echo "$as_me:${as_lineno-$LINENO}:   Alloc OOM: $enable_oom" >&5
73274 $as_echo "$as_me:   Alloc OOM: $enable_oom" >&6;}
73275 { $as_echo "$as_me:${as_lineno-$LINENO}: " >&5
73276 $as_echo "$as_me: " >&6;}
73277 { $as_echo "$as_me:${as_lineno-$LINENO}: Miscellaneous" >&5
73278 $as_echo "$as_me: Miscellaneous" >&6;}
73279 { $as_echo "$as_me:${as_lineno-$LINENO}: " >&5
73280 $as_echo "$as_me: " >&6;}
73281 { $as_echo "$as_me:${as_lineno-$LINENO}:             Debug: $enable_debug" >&5
73282 $as_echo "$as_me:             Debug: $enable_debug" >&6;}
73283 { $as_echo "$as_me:${as_lineno-$LINENO}:       Use -Werror: $set_werror" >&5
73284 $as_echo "$as_me:       Use -Werror: $set_werror" >&6;}
73285 { $as_echo "$as_me:${as_lineno-$LINENO}:     Warning Flags: $WARN_CFLAGS" >&5
73286 $as_echo "$as_me:     Warning Flags: $WARN_CFLAGS" >&6;}
73287 { $as_echo "$as_me:${as_lineno-$LINENO}:            DTrace: $with_dtrace" >&5
73288 $as_echo "$as_me:            DTrace: $with_dtrace" >&6;}
73289 { $as_echo "$as_me:${as_lineno-$LINENO}:             numad: $with_numad" >&5
73290 $as_echo "$as_me:             numad: $with_numad" >&6;}
73291 { $as_echo "$as_me:${as_lineno-$LINENO}:       XML Catalog: $XML_CATALOG_FILE" >&5
73292 $as_echo "$as_me:       XML Catalog: $XML_CATALOG_FILE" >&6;}
73293 { $as_echo "$as_me:${as_lineno-$LINENO}:       Init script: $with_init_script" >&5
73294 $as_echo "$as_me:       Init script: $with_init_script" >&6;}
73295 { $as_echo "$as_me:${as_lineno-$LINENO}: Char device locks: $with_chrdev_lock_files" >&5
73296 $as_echo "$as_me: Char device locks: $with_chrdev_lock_files" >&6;}
73297 { $as_echo "$as_me:${as_lineno-$LINENO}: " >&5
73298 $as_echo "$as_me: " >&6;}
73299 { $as_echo "$as_me:${as_lineno-$LINENO}: Developer Tools" >&5
73300 $as_echo "$as_me: Developer Tools" >&6;}
73301 { $as_echo "$as_me:${as_lineno-$LINENO}: " >&5
73302 $as_echo "$as_me: " >&6;}
73303 { $as_echo "$as_me:${as_lineno-$LINENO}: Wireshark dissector: $with_wireshark_dissector" >&5
73304 $as_echo "$as_me: Wireshark dissector: $with_wireshark_dissector" >&6;}
73305 { $as_echo "$as_me:${as_lineno-$LINENO}: " >&5
73306 $as_echo "$as_me: " >&6;}
73307 { $as_echo "$as_me:${as_lineno-$LINENO}: Privileges" >&5
73308 $as_echo "$as_me: Privileges" >&6;}
73309 { $as_echo "$as_me:${as_lineno-$LINENO}: " >&5
73310 $as_echo "$as_me: " >&6;}
73311 { $as_echo "$as_me:${as_lineno-$LINENO}:       QEMU: $QEMU_USER:$QEMU_GROUP" >&5
73312 $as_echo "$as_me:       QEMU: $QEMU_USER:$QEMU_GROUP" >&6;}
73313 { $as_echo "$as_me:${as_lineno-$LINENO}: " >&5
73314 $as_echo "$as_me: " >&6;}