]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - contrib/ntp/sntp/configure
MFV r284234:
[FreeBSD/FreeBSD.git] / contrib / ntp / sntp / configure
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.68 for sntp 4.2.8p2.
4 #
5 # Report bugs to <http://bugs.ntp.org./>.
6 #
7 #
8 # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
9 # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free Software
10 # Foundation, Inc.
11 #
12 #
13 # This configure script is free software; the Free Software Foundation
14 # gives unlimited permission to copy, distribute and modify it.
15 ## -------------------- ##
16 ## M4sh Initialization. ##
17 ## -------------------- ##
18
19 # Be more Bourne compatible
20 DUALCASE=1; export DUALCASE # for MKS sh
21 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
22   emulate sh
23   NULLCMD=:
24   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
25   # is contrary to our usage.  Disable this feature.
26   alias -g '${1+"$@"}'='"$@"'
27   setopt NO_GLOB_SUBST
28 else
29   case `(set -o) 2>/dev/null` in #(
30   *posix*) :
31     set -o posix ;; #(
32   *) :
33      ;;
34 esac
35 fi
36
37
38 as_nl='
39 '
40 export as_nl
41 # Printing a long string crashes Solaris 7 /usr/bin/printf.
42 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
43 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
44 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
45 # Prefer a ksh shell builtin over an external printf program on Solaris,
46 # but without wasting forks for bash or zsh.
47 if test -z "$BASH_VERSION$ZSH_VERSION" \
48     && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
49   as_echo='print -r --'
50   as_echo_n='print -rn --'
51 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
52   as_echo='printf %s\n'
53   as_echo_n='printf %s'
54 else
55   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
56     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
57     as_echo_n='/usr/ucb/echo -n'
58   else
59     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
60     as_echo_n_body='eval
61       arg=$1;
62       case $arg in #(
63       *"$as_nl"*)
64         expr "X$arg" : "X\\(.*\\)$as_nl";
65         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
66       esac;
67       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
68     '
69     export as_echo_n_body
70     as_echo_n='sh -c $as_echo_n_body as_echo'
71   fi
72   export as_echo_body
73   as_echo='sh -c $as_echo_body as_echo'
74 fi
75
76 # The user is always right.
77 if test "${PATH_SEPARATOR+set}" != set; then
78   PATH_SEPARATOR=:
79   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
80     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
81       PATH_SEPARATOR=';'
82   }
83 fi
84
85
86 # IFS
87 # We need space, tab and new line, in precisely that order.  Quoting is
88 # there to prevent editors from complaining about space-tab.
89 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
90 # splitting by setting IFS to empty value.)
91 IFS=" ""        $as_nl"
92
93 # Find who we are.  Look in the path if we contain no directory separator.
94 as_myself=
95 case $0 in #((
96   *[\\/]* ) as_myself=$0 ;;
97   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
98 for as_dir in $PATH
99 do
100   IFS=$as_save_IFS
101   test -z "$as_dir" && as_dir=.
102     test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
103   done
104 IFS=$as_save_IFS
105
106      ;;
107 esac
108 # We did not find ourselves, most probably we were run as `sh COMMAND'
109 # in which case we are not to be found in the path.
110 if test "x$as_myself" = x; then
111   as_myself=$0
112 fi
113 if test ! -f "$as_myself"; then
114   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
115   exit 1
116 fi
117
118 # Unset variables that we do not need and which cause bugs (e.g. in
119 # pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
120 # suppresses any "Segmentation fault" message there.  '((' could
121 # trigger a bug in pdksh 5.2.14.
122 for as_var in BASH_ENV ENV MAIL MAILPATH
123 do eval test x\${$as_var+set} = xset \
124   && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
125 done
126 PS1='$ '
127 PS2='> '
128 PS4='+ '
129
130 # NLS nuisances.
131 LC_ALL=C
132 export LC_ALL
133 LANGUAGE=C
134 export LANGUAGE
135
136 # CDPATH.
137 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
138
139 if test "x$CONFIG_SHELL" = x; then
140   as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
141   emulate sh
142   NULLCMD=:
143   # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
144   # is contrary to our usage.  Disable this feature.
145   alias -g '\${1+\"\$@\"}'='\"\$@\"'
146   setopt NO_GLOB_SUBST
147 else
148   case \`(set -o) 2>/dev/null\` in #(
149   *posix*) :
150     set -o posix ;; #(
151   *) :
152      ;;
153 esac
154 fi
155 "
156   as_required="as_fn_return () { (exit \$1); }
157 as_fn_success () { as_fn_return 0; }
158 as_fn_failure () { as_fn_return 1; }
159 as_fn_ret_success () { return 0; }
160 as_fn_ret_failure () { return 1; }
161
162 exitcode=0
163 as_fn_success || { exitcode=1; echo as_fn_success failed.; }
164 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
165 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
166 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
167 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
168
169 else
170   exitcode=1; echo positional parameters were not saved.
171 fi
172 test x\$exitcode = x0 || exit 1"
173   as_suggested="  as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
174   as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
175   eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
176   test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
177 test \$(( 1 + 1 )) = 2 || exit 1
178
179   test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || (
180     ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
181     ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
182     ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
183     PATH=/empty FPATH=/empty; export PATH FPATH
184     test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\
185       || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1"
186   if (eval "$as_required") 2>/dev/null; then :
187   as_have_required=yes
188 else
189   as_have_required=no
190 fi
191   if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
192
193 else
194   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
195 as_found=false
196 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
197 do
198   IFS=$as_save_IFS
199   test -z "$as_dir" && as_dir=.
200   as_found=:
201   case $as_dir in #(
202          /*)
203            for as_base in sh bash ksh sh5; do
204              # Try only shells that exist, to save several forks.
205              as_shell=$as_dir/$as_base
206              if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
207                     { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
208   CONFIG_SHELL=$as_shell as_have_required=yes
209                    if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
210   break 2
211 fi
212 fi
213            done;;
214        esac
215   as_found=false
216 done
217 $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
218               { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
219   CONFIG_SHELL=$SHELL as_have_required=yes
220 fi; }
221 IFS=$as_save_IFS
222
223
224       if test "x$CONFIG_SHELL" != x; then :
225   # We cannot yet assume a decent shell, so we have to provide a
226         # neutralization value for shells without unset; and this also
227         # works around shells that cannot unset nonexistent variables.
228         # Preserve -v and -x to the replacement shell.
229         BASH_ENV=/dev/null
230         ENV=/dev/null
231         (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
232         export CONFIG_SHELL
233         case $- in # ((((
234           *v*x* | *x*v* ) as_opts=-vx ;;
235           *v* ) as_opts=-v ;;
236           *x* ) as_opts=-x ;;
237           * ) as_opts= ;;
238         esac
239         exec "$CONFIG_SHELL" $as_opts "$as_myself" ${1+"$@"}
240 fi
241
242     if test x$as_have_required = xno; then :
243   $as_echo "$0: This script requires a shell more modern than all"
244   $as_echo "$0: the shells that I found on your system."
245   if test x${ZSH_VERSION+set} = xset ; then
246     $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
247     $as_echo "$0: be upgraded to zsh 4.3.4 or later."
248   else
249     $as_echo "$0: Please tell bug-autoconf@gnu.org and
250 $0: http://bugs.ntp.org./ about your system, including any
251 $0: error possibly output before this message. Then install
252 $0: a modern shell, or manually run the script under such a
253 $0: shell if you do have one."
254   fi
255   exit 1
256 fi
257 fi
258 fi
259 SHELL=${CONFIG_SHELL-/bin/sh}
260 export SHELL
261 # Unset more variables known to interfere with behavior of common tools.
262 CLICOLOR_FORCE= GREP_OPTIONS=
263 unset CLICOLOR_FORCE GREP_OPTIONS
264
265 ## --------------------- ##
266 ## M4sh Shell Functions. ##
267 ## --------------------- ##
268 # as_fn_unset VAR
269 # ---------------
270 # Portably unset VAR.
271 as_fn_unset ()
272 {
273   { eval $1=; unset $1;}
274 }
275 as_unset=as_fn_unset
276
277 # as_fn_set_status STATUS
278 # -----------------------
279 # Set $? to STATUS, without forking.
280 as_fn_set_status ()
281 {
282   return $1
283 } # as_fn_set_status
284
285 # as_fn_exit STATUS
286 # -----------------
287 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
288 as_fn_exit ()
289 {
290   set +e
291   as_fn_set_status $1
292   exit $1
293 } # as_fn_exit
294
295 # as_fn_mkdir_p
296 # -------------
297 # Create "$as_dir" as a directory, including parents if necessary.
298 as_fn_mkdir_p ()
299 {
300
301   case $as_dir in #(
302   -*) as_dir=./$as_dir;;
303   esac
304   test -d "$as_dir" || eval $as_mkdir_p || {
305     as_dirs=
306     while :; do
307       case $as_dir in #(
308       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
309       *) as_qdir=$as_dir;;
310       esac
311       as_dirs="'$as_qdir' $as_dirs"
312       as_dir=`$as_dirname -- "$as_dir" ||
313 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
314          X"$as_dir" : 'X\(//\)[^/]' \| \
315          X"$as_dir" : 'X\(//\)$' \| \
316          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
317 $as_echo X"$as_dir" |
318     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
319             s//\1/
320             q
321           }
322           /^X\(\/\/\)[^/].*/{
323             s//\1/
324             q
325           }
326           /^X\(\/\/\)$/{
327             s//\1/
328             q
329           }
330           /^X\(\/\).*/{
331             s//\1/
332             q
333           }
334           s/.*/./; q'`
335       test -d "$as_dir" && break
336     done
337     test -z "$as_dirs" || eval "mkdir $as_dirs"
338   } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
339
340
341 } # as_fn_mkdir_p
342 # as_fn_append VAR VALUE
343 # ----------------------
344 # Append the text in VALUE to the end of the definition contained in VAR. Take
345 # advantage of any shell optimizations that allow amortized linear growth over
346 # repeated appends, instead of the typical quadratic growth present in naive
347 # implementations.
348 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
349   eval 'as_fn_append ()
350   {
351     eval $1+=\$2
352   }'
353 else
354   as_fn_append ()
355   {
356     eval $1=\$$1\$2
357   }
358 fi # as_fn_append
359
360 # as_fn_arith ARG...
361 # ------------------
362 # Perform arithmetic evaluation on the ARGs, and store the result in the
363 # global $as_val. Take advantage of shells that can avoid forks. The arguments
364 # must be portable across $(()) and expr.
365 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
366   eval 'as_fn_arith ()
367   {
368     as_val=$(( $* ))
369   }'
370 else
371   as_fn_arith ()
372   {
373     as_val=`expr "$@" || test $? -eq 1`
374   }
375 fi # as_fn_arith
376
377
378 # as_fn_error STATUS ERROR [LINENO LOG_FD]
379 # ----------------------------------------
380 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
381 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
382 # script with STATUS, using 1 if that was 0.
383 as_fn_error ()
384 {
385   as_status=$1; test $as_status -eq 0 && as_status=1
386   if test "$4"; then
387     as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
388     $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
389   fi
390   $as_echo "$as_me: error: $2" >&2
391   as_fn_exit $as_status
392 } # as_fn_error
393
394 if expr a : '\(a\)' >/dev/null 2>&1 &&
395    test "X`expr 00001 : '.*\(...\)'`" = X001; then
396   as_expr=expr
397 else
398   as_expr=false
399 fi
400
401 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
402   as_basename=basename
403 else
404   as_basename=false
405 fi
406
407 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
408   as_dirname=dirname
409 else
410   as_dirname=false
411 fi
412
413 as_me=`$as_basename -- "$0" ||
414 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
415          X"$0" : 'X\(//\)$' \| \
416          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
417 $as_echo X/"$0" |
418     sed '/^.*\/\([^/][^/]*\)\/*$/{
419             s//\1/
420             q
421           }
422           /^X\/\(\/\/\)$/{
423             s//\1/
424             q
425           }
426           /^X\/\(\/\).*/{
427             s//\1/
428             q
429           }
430           s/.*/./; q'`
431
432 # Avoid depending upon Character Ranges.
433 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
434 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
435 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
436 as_cr_digits='0123456789'
437 as_cr_alnum=$as_cr_Letters$as_cr_digits
438
439
440   as_lineno_1=$LINENO as_lineno_1a=$LINENO
441   as_lineno_2=$LINENO as_lineno_2a=$LINENO
442   eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
443   test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
444   # Blame Lee E. McMahon (1931-1989) for sed's syntax.  :-)
445   sed -n '
446     p
447     /[$]LINENO/=
448   ' <$as_myself |
449     sed '
450       s/[$]LINENO.*/&-/
451       t lineno
452       b
453       :lineno
454       N
455       :loop
456       s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
457       t loop
458       s/-\n.*//
459     ' >$as_me.lineno &&
460   chmod +x "$as_me.lineno" ||
461     { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
462
463   # Don't try to exec as it changes $[0], causing all sort of problems
464   # (the dirname of $[0] is not the place where we might find the
465   # original and so on.  Autoconf is especially sensitive to this).
466   . "./$as_me.lineno"
467   # Exit status is that of the last command.
468   exit
469 }
470
471 ECHO_C= ECHO_N= ECHO_T=
472 case `echo -n x` in #(((((
473 -n*)
474   case `echo 'xy\c'` in
475   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
476   xy)  ECHO_C='\c';;
477   *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
478        ECHO_T=' ';;
479   esac;;
480 *)
481   ECHO_N='-n';;
482 esac
483
484 rm -f conf$$ conf$$.exe conf$$.file
485 if test -d conf$$.dir; then
486   rm -f conf$$.dir/conf$$.file
487 else
488   rm -f conf$$.dir
489   mkdir conf$$.dir 2>/dev/null
490 fi
491 if (echo >conf$$.file) 2>/dev/null; then
492   if ln -s conf$$.file conf$$ 2>/dev/null; then
493     as_ln_s='ln -s'
494     # ... but there are two gotchas:
495     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
496     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
497     # In both cases, we have to default to `cp -p'.
498     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
499       as_ln_s='cp -p'
500   elif ln conf$$.file conf$$ 2>/dev/null; then
501     as_ln_s=ln
502   else
503     as_ln_s='cp -p'
504   fi
505 else
506   as_ln_s='cp -p'
507 fi
508 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
509 rmdir conf$$.dir 2>/dev/null
510
511 if mkdir -p . 2>/dev/null; then
512   as_mkdir_p='mkdir -p "$as_dir"'
513 else
514   test -d ./-p && rmdir ./-p
515   as_mkdir_p=false
516 fi
517
518 if test -x / >/dev/null 2>&1; then
519   as_test_x='test -x'
520 else
521   if ls -dL / >/dev/null 2>&1; then
522     as_ls_L_option=L
523   else
524     as_ls_L_option=
525   fi
526   as_test_x='
527     eval sh -c '\''
528       if test -d "$1"; then
529         test -d "$1/.";
530       else
531         case $1 in #(
532         -*)set "./$1";;
533         esac;
534         case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
535         ???[sx]*):;;*)false;;esac;fi
536     '\'' sh
537   '
538 fi
539 as_executable_p=$as_test_x
540
541 # Sed expression to map a string onto a valid CPP name.
542 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
543
544 # Sed expression to map a string onto a valid variable name.
545 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
546
547 SHELL=${CONFIG_SHELL-/bin/sh}
548
549
550 test -n "$DJDIR" || exec 7<&0 </dev/null
551 exec 6>&1
552
553 # Name of the host.
554 # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
555 # so uname gets run too.
556 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
557
558 #
559 # Initializations.
560 #
561 ac_default_prefix=/usr/local
562 ac_clean_files=
563 ac_config_libobj_dir=.
564 LIBOBJS=
565 cross_compiling=no
566 subdirs=
567 MFLAGS=
568 MAKEFLAGS=
569
570 # Identity of this package.
571 PACKAGE_NAME='sntp'
572 PACKAGE_TARNAME='sntp'
573 PACKAGE_VERSION='4.2.8p2'
574 PACKAGE_STRING='sntp 4.2.8p2'
575 PACKAGE_BUGREPORT='http://bugs.ntp.org./'
576 PACKAGE_URL='http://www.ntp.org./'
577
578 # Factoring default headers for most tests.
579 ac_includes_default="\
580 #include <stdio.h>
581 #ifdef HAVE_SYS_TYPES_H
582 # include <sys/types.h>
583 #endif
584 #ifdef HAVE_SYS_STAT_H
585 # include <sys/stat.h>
586 #endif
587 #ifdef STDC_HEADERS
588 # include <stdlib.h>
589 # include <stddef.h>
590 #else
591 # ifdef HAVE_STDLIB_H
592 #  include <stdlib.h>
593 # endif
594 #endif
595 #ifdef HAVE_STRING_H
596 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
597 #  include <memory.h>
598 # endif
599 # include <string.h>
600 #endif
601 #ifdef HAVE_STRINGS_H
602 # include <strings.h>
603 #endif
604 #ifdef HAVE_INTTYPES_H
605 # include <inttypes.h>
606 #endif
607 #ifdef HAVE_STDINT_H
608 # include <stdint.h>
609 #endif
610 #ifdef HAVE_UNISTD_H
611 # include <unistd.h>
612 #endif"
613
614 ac_header_list=
615 enable_option_checking=no
616 ac_subst_vars='am__EXEEXT_FALSE
617 am__EXEEXT_TRUE
618 LTLIBOBJS
619 GTEST_AVAILABLE_FALSE
620 GTEST_AVAILABLE_TRUE
621 GTEST_CPPFLAGS
622 GTEST_CXXFLAGS
623 GTEST_LIBS
624 GTEST_LDFLAGS
625 GTEST_CONFIG
626 CXXCPP
627 am__fastdepCXX_FALSE
628 am__fastdepCXX_TRUE
629 CXXDEPMODE
630 ac_ct_CXX
631 CXXFLAGS
632 CXX
633 VER_SUFFIX
634 LIB_SYSLOG
635 subdirs
636 BUILD_LIBEVENT_FALSE
637 BUILD_LIBEVENT_TRUE
638 LDADD_LIBEVENT
639 CPPFLAGS_LIBEVENT
640 PKG_CONFIG
641 NTP_FORCE_LIBEVENT_DIST
642 LIBOPTS_DIR
643 LIBOPTS_CFLAGS
644 LIBOPTS_LDADD
645 NEED_LIBOPTS_FALSE
646 NEED_LIBOPTS_TRUE
647 INSTALL_LIBOPTS_FALSE
648 INSTALL_LIBOPTS_TRUE
649 POSIX_SHELL
650 GL_GENERATE_STDNORETURN_H_FALSE
651 GL_GENERATE_STDNORETURN_H_TRUE
652 STDNORETURN_H
653 BUILD_SNTP_FALSE
654 BUILD_SNTP_TRUE
655 SNTP
656 LIBTOOL_DEPS
657 OTOOL64
658 OTOOL
659 LIPO
660 NMEDIT
661 DSYMUTIL
662 MANIFEST_TOOL
663 RANLIB
664 ac_ct_AR
665 AR
666 DLLTOOL
667 OBJDUMP
668 LN_S
669 NM
670 ac_ct_DUMPBIN
671 DUMPBIN
672 LIBTOOL
673 LIBOBJS
674 PTHREADS_FALSE
675 PTHREADS_TRUE
676 LIBISC_PTHREADS_NOTHREADS
677 PTHREAD_LIBS
678 HAVE_INLINE
679 LDADD_LIBUTIL
680 ALLOCA
681 LIBM
682 EDITLINE_LIBS
683 LD
684 FGREP
685 SED
686 LDADD_LIBNTP
687 NTP_CROSSCOMPILE_FALSE
688 NTP_CROSSCOMPILE_TRUE
689 INSTALL_UPDATE_LEAP_FALSE
690 INSTALL_UPDATE_LEAP_TRUE
691 UPDATE_LEAP_NI
692 UPDATE_LEAP_MS
693 UPDATE_LEAP_DS
694 UPDATE_LEAP_DL
695 UPDATE_LEAP_DB
696 TIMETRIM_NI
697 TIMETRIM_MS
698 TIMETRIM_DS
699 TIMETRIM_DL
700 TIMETRIM_DB
701 TICKADJ_NI
702 TICKADJ_MS
703 TICKADJ_DS
704 TICKADJ_DL
705 TICKADJ_DB
706 SNTP_NI
707 SNTP_MS
708 SNTP_DS
709 SNTP_DL
710 SNTP_DB
711 NTP_WAIT_NI
712 NTP_WAIT_MS
713 NTP_WAIT_DS
714 NTP_WAIT_DL
715 NTP_WAIT_DB
716 NTP_KEYGEN_NI
717 NTP_KEYGEN_MS
718 NTP_KEYGEN_DS
719 NTP_KEYGEN_DL
720 NTP_KEYGEN_DB
721 NTPTRACE_NI
722 NTPTRACE_MS
723 NTPTRACE_DS
724 NTPTRACE_DL
725 NTPTRACE_DB
726 NTPTIME_NI
727 NTPTIME_MS
728 NTPTIME_DS
729 NTPTIME_DL
730 NTPTIME_DB
731 INSTALL_NTPSWEEP_FALSE
732 INSTALL_NTPSWEEP_TRUE
733 NTPSWEEP_NI
734 NTPSWEEP_MS
735 NTPSWEEP_DS
736 NTPSWEEP_DL
737 NTPSWEEP_DB
738 NTPSNMPD_NI
739 NTPSNMPD_MS
740 NTPSNMPD_DS
741 NTPSNMPD_DL
742 NTPSNMPD_DB
743 NTPQ_NI
744 NTPQ_MS
745 NTPQ_DS
746 NTPQ_DL
747 NTPQ_DB
748 NTPD_NI
749 NTPD_MS
750 NTPD_DS
751 NTPD_DL
752 NTPD_DB
753 NTPDSIM_NI
754 NTPDSIM_MS
755 NTPDSIM_DS
756 NTPDSIM_DL
757 NTPDSIM_DB
758 NTPDC_NI
759 NTPDC_MS
760 NTPDC_DS
761 NTPDC_DL
762 NTPDC_DB
763 NTPDATE_NI
764 NTPDATE_MS
765 NTPDATE_DS
766 NTPDATE_DL
767 NTPDATE_DB
768 MANTAGFMT
769 CALC_TICKADJ_NI
770 CALC_TICKADJ_MS
771 CALC_TICKADJ_DS
772 CALC_TICKADJ_DL
773 CALC_TICKADJ_DB
774 WANT_CALC_TICKADJ_MS_FALSE
775 WANT_CALC_TICKADJ_MS_TRUE
776 LDFLAGS_NTP
777 LDADD_NTP
778 CPPFLAGS_NTP
779 CFLAGS_NTP
780 EGREP
781 GREP
782 CPP
783 am__fastdepCC_FALSE
784 am__fastdepCC_TRUE
785 CCDEPMODE
786 AMDEPBACKSLASH
787 AMDEP_FALSE
788 AMDEP_TRUE
789 am__quote
790 am__include
791 DEPDIR
792 OBJEXT
793 EXEEXT
794 ac_ct_CC
795 CPPFLAGS
796 LDFLAGS
797 CFLAGS
798 CC
799 host_os
800 host_vendor
801 host_cpu
802 host
803 build_os
804 build_vendor
805 build_cpu
806 build
807 AM_BACKSLASH
808 AM_DEFAULT_VERBOSITY
809 am__untar
810 am__tar
811 AMTAR
812 am__leading_dot
813 SET_MAKE
814 AWK
815 mkdir_p
816 MKDIR_P
817 INSTALL_STRIP_PROGRAM
818 STRIP
819 install_sh
820 MAKEINFO
821 AUTOHEADER
822 AUTOMAKE
823 AUTOCONF
824 ACLOCAL
825 VERSION
826 PACKAGE
827 CYGPATH_W
828 am__isrc
829 INSTALL_DATA
830 INSTALL_SCRIPT
831 INSTALL_PROGRAM
832 target_alias
833 host_alias
834 build_alias
835 LIBS
836 ECHO_T
837 ECHO_N
838 ECHO_C
839 DEFS
840 mandir
841 localedir
842 libdir
843 psdir
844 pdfdir
845 dvidir
846 htmldir
847 infodir
848 docdir
849 oldincludedir
850 includedir
851 localstatedir
852 sharedstatedir
853 sysconfdir
854 datadir
855 datarootdir
856 libexecdir
857 sbindir
858 bindir
859 program_transform_name
860 prefix
861 exec_prefix
862 PACKAGE_URL
863 PACKAGE_BUGREPORT
864 PACKAGE_STRING
865 PACKAGE_VERSION
866 PACKAGE_TARNAME
867 PACKAGE_NAME
868 PATH_SEPARATOR
869 SHELL'
870 ac_subst_files=''
871 ac_user_opts='
872 enable_option_checking
873 enable_silent_rules
874 enable_dependency_tracking
875 with_locfile
876 with_gnu_ld
877 with_lineeditlibs
878 enable_debugging
879 enable_thread_support
880 with_threads
881 with_yielding_select
882 enable_c99_snprintf
883 enable_clockctl
884 enable_linuxcaps
885 enable_solarisprivs
886 enable_shared
887 enable_static
888 with_pic
889 enable_fast_install
890 with_sysroot
891 enable_libtool_lock
892 with_sntp
893 enable_nls
894 enable_local_libopts
895 enable_libopts_install
896 with_autoopts_config
897 with_regex_header
898 with_libregex
899 with_libregex_cflags
900 with_libregex_libs
901 enable_optional_args
902 enable_local_libevent
903 with_crypto
904 with_openssl_libdir
905 with_openssl_incdir
906 with_rpath
907 enable_ipv6
908 with_kame
909 enable_getifaddrs
910 with_gtest
911 '
912       ac_precious_vars='build_alias
913 host_alias
914 target_alias
915 CC
916 CFLAGS
917 LDFLAGS
918 LIBS
919 CPPFLAGS
920 CPP
921 CXX
922 CXXFLAGS
923 CCC
924 CXXCPP'
925 ac_subdirs_all='libevent'
926
927 # Initialize some variables set by options.
928 ac_init_help=
929 ac_init_version=false
930 ac_unrecognized_opts=
931 ac_unrecognized_sep=
932 # The variables have the same names as the options, with
933 # dashes changed to underlines.
934 cache_file=/dev/null
935 exec_prefix=NONE
936 no_create=
937 no_recursion=
938 prefix=NONE
939 program_prefix=NONE
940 program_suffix=NONE
941 program_transform_name=s,x,x,
942 silent=
943 site=
944 srcdir=
945 verbose=
946 x_includes=NONE
947 x_libraries=NONE
948
949 # Installation directory options.
950 # These are left unexpanded so users can "make install exec_prefix=/foo"
951 # and all the variables that are supposed to be based on exec_prefix
952 # by default will actually change.
953 # Use braces instead of parens because sh, perl, etc. also accept them.
954 # (The list follows the same order as the GNU Coding Standards.)
955 bindir='${exec_prefix}/bin'
956 sbindir='${exec_prefix}/sbin'
957 libexecdir='${exec_prefix}/libexec'
958 datarootdir='${prefix}/share'
959 datadir='${datarootdir}'
960 sysconfdir='${prefix}/etc'
961 sharedstatedir='${prefix}/com'
962 localstatedir='${prefix}/var'
963 includedir='${prefix}/include'
964 oldincludedir='/usr/include'
965 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
966 infodir='${datarootdir}/info'
967 htmldir='${docdir}'
968 dvidir='${docdir}'
969 pdfdir='${docdir}'
970 psdir='${docdir}'
971 libdir='${exec_prefix}/lib'
972 localedir='${datarootdir}/locale'
973 mandir='${datarootdir}/man'
974
975 ac_prev=
976 ac_dashdash=
977 for ac_option
978 do
979   # If the previous option needs an argument, assign it.
980   if test -n "$ac_prev"; then
981     eval $ac_prev=\$ac_option
982     ac_prev=
983     continue
984   fi
985
986   case $ac_option in
987   *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
988   *=)   ac_optarg= ;;
989   *)    ac_optarg=yes ;;
990   esac
991
992   # Accept the important Cygnus configure options, so we can diagnose typos.
993
994   case $ac_dashdash$ac_option in
995   --)
996     ac_dashdash=yes ;;
997
998   -bindir | --bindir | --bindi | --bind | --bin | --bi)
999     ac_prev=bindir ;;
1000   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1001     bindir=$ac_optarg ;;
1002
1003   -build | --build | --buil | --bui | --bu)
1004     ac_prev=build_alias ;;
1005   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1006     build_alias=$ac_optarg ;;
1007
1008   -cache-file | --cache-file | --cache-fil | --cache-fi \
1009   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1010     ac_prev=cache_file ;;
1011   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1012   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1013     cache_file=$ac_optarg ;;
1014
1015   --config-cache | -C)
1016     cache_file=config.cache ;;
1017
1018   -datadir | --datadir | --datadi | --datad)
1019     ac_prev=datadir ;;
1020   -datadir=* | --datadir=* | --datadi=* | --datad=*)
1021     datadir=$ac_optarg ;;
1022
1023   -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1024   | --dataroo | --dataro | --datar)
1025     ac_prev=datarootdir ;;
1026   -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1027   | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1028     datarootdir=$ac_optarg ;;
1029
1030   -disable-* | --disable-*)
1031     ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1032     # Reject names that are not valid shell variable names.
1033     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1034       as_fn_error $? "invalid feature name: $ac_useropt"
1035     ac_useropt_orig=$ac_useropt
1036     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1037     case $ac_user_opts in
1038       *"
1039 "enable_$ac_useropt"
1040 "*) ;;
1041       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1042          ac_unrecognized_sep=', ';;
1043     esac
1044     eval enable_$ac_useropt=no ;;
1045
1046   -docdir | --docdir | --docdi | --doc | --do)
1047     ac_prev=docdir ;;
1048   -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1049     docdir=$ac_optarg ;;
1050
1051   -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1052     ac_prev=dvidir ;;
1053   -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1054     dvidir=$ac_optarg ;;
1055
1056   -enable-* | --enable-*)
1057     ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1058     # Reject names that are not valid shell variable names.
1059     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1060       as_fn_error $? "invalid feature name: $ac_useropt"
1061     ac_useropt_orig=$ac_useropt
1062     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1063     case $ac_user_opts in
1064       *"
1065 "enable_$ac_useropt"
1066 "*) ;;
1067       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1068          ac_unrecognized_sep=', ';;
1069     esac
1070     eval enable_$ac_useropt=\$ac_optarg ;;
1071
1072   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1073   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1074   | --exec | --exe | --ex)
1075     ac_prev=exec_prefix ;;
1076   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1077   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1078   | --exec=* | --exe=* | --ex=*)
1079     exec_prefix=$ac_optarg ;;
1080
1081   -gas | --gas | --ga | --g)
1082     # Obsolete; use --with-gas.
1083     with_gas=yes ;;
1084
1085   -help | --help | --hel | --he | -h)
1086     ac_init_help=long ;;
1087   -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1088     ac_init_help=recursive ;;
1089   -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1090     ac_init_help=short ;;
1091
1092   -host | --host | --hos | --ho)
1093     ac_prev=host_alias ;;
1094   -host=* | --host=* | --hos=* | --ho=*)
1095     host_alias=$ac_optarg ;;
1096
1097   -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1098     ac_prev=htmldir ;;
1099   -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1100   | --ht=*)
1101     htmldir=$ac_optarg ;;
1102
1103   -includedir | --includedir | --includedi | --included | --include \
1104   | --includ | --inclu | --incl | --inc)
1105     ac_prev=includedir ;;
1106   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1107   | --includ=* | --inclu=* | --incl=* | --inc=*)
1108     includedir=$ac_optarg ;;
1109
1110   -infodir | --infodir | --infodi | --infod | --info | --inf)
1111     ac_prev=infodir ;;
1112   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1113     infodir=$ac_optarg ;;
1114
1115   -libdir | --libdir | --libdi | --libd)
1116     ac_prev=libdir ;;
1117   -libdir=* | --libdir=* | --libdi=* | --libd=*)
1118     libdir=$ac_optarg ;;
1119
1120   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1121   | --libexe | --libex | --libe)
1122     ac_prev=libexecdir ;;
1123   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1124   | --libexe=* | --libex=* | --libe=*)
1125     libexecdir=$ac_optarg ;;
1126
1127   -localedir | --localedir | --localedi | --localed | --locale)
1128     ac_prev=localedir ;;
1129   -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1130     localedir=$ac_optarg ;;
1131
1132   -localstatedir | --localstatedir | --localstatedi | --localstated \
1133   | --localstate | --localstat | --localsta | --localst | --locals)
1134     ac_prev=localstatedir ;;
1135   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1136   | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1137     localstatedir=$ac_optarg ;;
1138
1139   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1140     ac_prev=mandir ;;
1141   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1142     mandir=$ac_optarg ;;
1143
1144   -nfp | --nfp | --nf)
1145     # Obsolete; use --without-fp.
1146     with_fp=no ;;
1147
1148   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1149   | --no-cr | --no-c | -n)
1150     no_create=yes ;;
1151
1152   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1153   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1154     no_recursion=yes ;;
1155
1156   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1157   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1158   | --oldin | --oldi | --old | --ol | --o)
1159     ac_prev=oldincludedir ;;
1160   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1161   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1162   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1163     oldincludedir=$ac_optarg ;;
1164
1165   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1166     ac_prev=prefix ;;
1167   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1168     prefix=$ac_optarg ;;
1169
1170   -program-prefix | --program-prefix | --program-prefi | --program-pref \
1171   | --program-pre | --program-pr | --program-p)
1172     ac_prev=program_prefix ;;
1173   -program-prefix=* | --program-prefix=* | --program-prefi=* \
1174   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1175     program_prefix=$ac_optarg ;;
1176
1177   -program-suffix | --program-suffix | --program-suffi | --program-suff \
1178   | --program-suf | --program-su | --program-s)
1179     ac_prev=program_suffix ;;
1180   -program-suffix=* | --program-suffix=* | --program-suffi=* \
1181   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1182     program_suffix=$ac_optarg ;;
1183
1184   -program-transform-name | --program-transform-name \
1185   | --program-transform-nam | --program-transform-na \
1186   | --program-transform-n | --program-transform- \
1187   | --program-transform | --program-transfor \
1188   | --program-transfo | --program-transf \
1189   | --program-trans | --program-tran \
1190   | --progr-tra | --program-tr | --program-t)
1191     ac_prev=program_transform_name ;;
1192   -program-transform-name=* | --program-transform-name=* \
1193   | --program-transform-nam=* | --program-transform-na=* \
1194   | --program-transform-n=* | --program-transform-=* \
1195   | --program-transform=* | --program-transfor=* \
1196   | --program-transfo=* | --program-transf=* \
1197   | --program-trans=* | --program-tran=* \
1198   | --progr-tra=* | --program-tr=* | --program-t=*)
1199     program_transform_name=$ac_optarg ;;
1200
1201   -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1202     ac_prev=pdfdir ;;
1203   -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1204     pdfdir=$ac_optarg ;;
1205
1206   -psdir | --psdir | --psdi | --psd | --ps)
1207     ac_prev=psdir ;;
1208   -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1209     psdir=$ac_optarg ;;
1210
1211   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1212   | -silent | --silent | --silen | --sile | --sil)
1213     silent=yes ;;
1214
1215   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1216     ac_prev=sbindir ;;
1217   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1218   | --sbi=* | --sb=*)
1219     sbindir=$ac_optarg ;;
1220
1221   -sharedstatedir | --sharedstatedir | --sharedstatedi \
1222   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1223   | --sharedst | --shareds | --shared | --share | --shar \
1224   | --sha | --sh)
1225     ac_prev=sharedstatedir ;;
1226   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1227   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1228   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1229   | --sha=* | --sh=*)
1230     sharedstatedir=$ac_optarg ;;
1231
1232   -site | --site | --sit)
1233     ac_prev=site ;;
1234   -site=* | --site=* | --sit=*)
1235     site=$ac_optarg ;;
1236
1237   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1238     ac_prev=srcdir ;;
1239   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1240     srcdir=$ac_optarg ;;
1241
1242   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1243   | --syscon | --sysco | --sysc | --sys | --sy)
1244     ac_prev=sysconfdir ;;
1245   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1246   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1247     sysconfdir=$ac_optarg ;;
1248
1249   -target | --target | --targe | --targ | --tar | --ta | --t)
1250     ac_prev=target_alias ;;
1251   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1252     target_alias=$ac_optarg ;;
1253
1254   -v | -verbose | --verbose | --verbos | --verbo | --verb)
1255     verbose=yes ;;
1256
1257   -version | --version | --versio | --versi | --vers | -V)
1258     ac_init_version=: ;;
1259
1260   -with-* | --with-*)
1261     ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1262     # Reject names that are not valid shell variable names.
1263     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1264       as_fn_error $? "invalid package name: $ac_useropt"
1265     ac_useropt_orig=$ac_useropt
1266     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1267     case $ac_user_opts in
1268       *"
1269 "with_$ac_useropt"
1270 "*) ;;
1271       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1272          ac_unrecognized_sep=', ';;
1273     esac
1274     eval with_$ac_useropt=\$ac_optarg ;;
1275
1276   -without-* | --without-*)
1277     ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1278     # Reject names that are not valid shell variable names.
1279     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1280       as_fn_error $? "invalid package name: $ac_useropt"
1281     ac_useropt_orig=$ac_useropt
1282     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1283     case $ac_user_opts in
1284       *"
1285 "with_$ac_useropt"
1286 "*) ;;
1287       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1288          ac_unrecognized_sep=', ';;
1289     esac
1290     eval with_$ac_useropt=no ;;
1291
1292   --x)
1293     # Obsolete; use --with-x.
1294     with_x=yes ;;
1295
1296   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1297   | --x-incl | --x-inc | --x-in | --x-i)
1298     ac_prev=x_includes ;;
1299   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1300   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1301     x_includes=$ac_optarg ;;
1302
1303   -x-libraries | --x-libraries | --x-librarie | --x-librari \
1304   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1305     ac_prev=x_libraries ;;
1306   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1307   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1308     x_libraries=$ac_optarg ;;
1309
1310   -*) as_fn_error $? "unrecognized option: \`$ac_option'
1311 Try \`$0 --help' for more information"
1312     ;;
1313
1314   *=*)
1315     ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1316     # Reject names that are not valid shell variable names.
1317     case $ac_envvar in #(
1318       '' | [0-9]* | *[!_$as_cr_alnum]* )
1319       as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1320     esac
1321     eval $ac_envvar=\$ac_optarg
1322     export $ac_envvar ;;
1323
1324   *)
1325     # FIXME: should be removed in autoconf 3.0.
1326     $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1327     expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1328       $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1329     : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1330     ;;
1331
1332   esac
1333 done
1334
1335 if test -n "$ac_prev"; then
1336   ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1337   as_fn_error $? "missing argument to $ac_option"
1338 fi
1339
1340 if test -n "$ac_unrecognized_opts"; then
1341   case $enable_option_checking in
1342     no) ;;
1343     fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1344     *)     $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1345   esac
1346 fi
1347
1348 # Check all directory arguments for consistency.
1349 for ac_var in   exec_prefix prefix bindir sbindir libexecdir datarootdir \
1350                 datadir sysconfdir sharedstatedir localstatedir includedir \
1351                 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1352                 libdir localedir mandir
1353 do
1354   eval ac_val=\$$ac_var
1355   # Remove trailing slashes.
1356   case $ac_val in
1357     */ )
1358       ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1359       eval $ac_var=\$ac_val;;
1360   esac
1361   # Be sure to have absolute directory names.
1362   case $ac_val in
1363     [\\/$]* | ?:[\\/]* )  continue;;
1364     NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1365   esac
1366   as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1367 done
1368
1369 # There might be people who depend on the old broken behavior: `$host'
1370 # used to hold the argument of --host etc.
1371 # FIXME: To remove some day.
1372 build=$build_alias
1373 host=$host_alias
1374 target=$target_alias
1375
1376 # FIXME: To remove some day.
1377 if test "x$host_alias" != x; then
1378   if test "x$build_alias" = x; then
1379     cross_compiling=maybe
1380     $as_echo "$as_me: WARNING: if you wanted to set the --build type, don't use --host.
1381     If a cross compiler is detected then cross compile mode will be used" >&2
1382   elif test "x$build_alias" != "x$host_alias"; then
1383     cross_compiling=yes
1384   fi
1385 fi
1386
1387 ac_tool_prefix=
1388 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1389
1390 test "$silent" = yes && exec 6>/dev/null
1391
1392
1393 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1394 ac_ls_di=`ls -di .` &&
1395 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1396   as_fn_error $? "working directory cannot be determined"
1397 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1398   as_fn_error $? "pwd does not report name of working directory"
1399
1400
1401 # Find the source files, if location was not specified.
1402 if test -z "$srcdir"; then
1403   ac_srcdir_defaulted=yes
1404   # Try the directory containing this script, then the parent directory.
1405   ac_confdir=`$as_dirname -- "$as_myself" ||
1406 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1407          X"$as_myself" : 'X\(//\)[^/]' \| \
1408          X"$as_myself" : 'X\(//\)$' \| \
1409          X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1410 $as_echo X"$as_myself" |
1411     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1412             s//\1/
1413             q
1414           }
1415           /^X\(\/\/\)[^/].*/{
1416             s//\1/
1417             q
1418           }
1419           /^X\(\/\/\)$/{
1420             s//\1/
1421             q
1422           }
1423           /^X\(\/\).*/{
1424             s//\1/
1425             q
1426           }
1427           s/.*/./; q'`
1428   srcdir=$ac_confdir
1429   if test ! -r "$srcdir/$ac_unique_file"; then
1430     srcdir=..
1431   fi
1432 else
1433   ac_srcdir_defaulted=no
1434 fi
1435 if test ! -r "$srcdir/$ac_unique_file"; then
1436   test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1437   as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1438 fi
1439 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1440 ac_abs_confdir=`(
1441         cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1442         pwd)`
1443 # When building in place, set srcdir=.
1444 if test "$ac_abs_confdir" = "$ac_pwd"; then
1445   srcdir=.
1446 fi
1447 # Remove unnecessary trailing slashes from srcdir.
1448 # Double slashes in file names in object file debugging info
1449 # mess up M-x gdb in Emacs.
1450 case $srcdir in
1451 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1452 esac
1453 for ac_var in $ac_precious_vars; do
1454   eval ac_env_${ac_var}_set=\${${ac_var}+set}
1455   eval ac_env_${ac_var}_value=\$${ac_var}
1456   eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1457   eval ac_cv_env_${ac_var}_value=\$${ac_var}
1458 done
1459
1460 #
1461 # Report the --help message.
1462 #
1463 if test "$ac_init_help" = "long"; then
1464   # Omit some internal or obsolete options to make the list less imposing.
1465   # This message is too long to be a string in the A/UX 3.1 sh.
1466   cat <<_ACEOF
1467 \`configure' configures sntp 4.2.8p2 to adapt to many kinds of systems.
1468
1469 Usage: $0 [OPTION]... [VAR=VALUE]...
1470
1471 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1472 VAR=VALUE.  See below for descriptions of some of the useful variables.
1473
1474 Defaults for the options are specified in brackets.
1475
1476 Configuration:
1477   -h, --help              display this help and exit
1478       --help=short        display options specific to this package
1479       --help=recursive    display the short help of all the included packages
1480   -V, --version           display version information and exit
1481   -q, --quiet, --silent   do not print \`checking ...' messages
1482       --cache-file=FILE   cache test results in FILE [disabled]
1483   -C, --config-cache      alias for \`--cache-file=config.cache'
1484   -n, --no-create         do not create output files
1485       --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1486
1487 Installation directories:
1488   --prefix=PREFIX         install architecture-independent files in PREFIX
1489                           [$ac_default_prefix]
1490   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1491                           [PREFIX]
1492
1493 By default, \`make install' will install all the files in
1494 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1495 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1496 for instance \`--prefix=\$HOME'.
1497
1498 For better control, use the options below.
1499
1500 Fine tuning of the installation directories:
1501   --bindir=DIR            user executables [EPREFIX/bin]
1502   --sbindir=DIR           system admin executables [EPREFIX/sbin]
1503   --libexecdir=DIR        program executables [EPREFIX/libexec]
1504   --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
1505   --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
1506   --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
1507   --libdir=DIR            object code libraries [EPREFIX/lib]
1508   --includedir=DIR        C header files [PREFIX/include]
1509   --oldincludedir=DIR     C header files for non-gcc [/usr/include]
1510   --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
1511   --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
1512   --infodir=DIR           info documentation [DATAROOTDIR/info]
1513   --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
1514   --mandir=DIR            man documentation [DATAROOTDIR/man]
1515   --docdir=DIR            documentation root [DATAROOTDIR/doc/sntp]
1516   --htmldir=DIR           html documentation [DOCDIR]
1517   --dvidir=DIR            dvi documentation [DOCDIR]
1518   --pdfdir=DIR            pdf documentation [DOCDIR]
1519   --psdir=DIR             ps documentation [DOCDIR]
1520 _ACEOF
1521
1522   cat <<\_ACEOF
1523
1524 Program names:
1525   --program-prefix=PREFIX            prepend PREFIX to installed program names
1526   --program-suffix=SUFFIX            append SUFFIX to installed program names
1527   --program-transform-name=PROGRAM   run sed PROGRAM on installed program names
1528
1529 System types:
1530   --build=BUILD     configure for building on BUILD [guessed]
1531   --host=HOST       cross-compile to build programs to run on HOST [BUILD]
1532 _ACEOF
1533 fi
1534
1535 if test -n "$ac_init_help"; then
1536   case $ac_init_help in
1537      short | recursive ) echo "Configuration of sntp 4.2.8p2:";;
1538    esac
1539   cat <<\_ACEOF
1540
1541 Optional Features:
1542   --disable-option-checking  ignore unrecognized --enable/--with options
1543   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1544   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1545   --enable-silent-rules          less verbose build output (undo: `make V=1')
1546   --disable-silent-rules         verbose build output (undo: `make V=0')
1547   --disable-dependency-tracking  speeds up one-time build
1548   --enable-dependency-tracking   do not reject slow dependency extractors
1549   defaults:               + yes, - no, s system-specific
1550   --enable-debugging      + include ntpd debugging code
1551   --enable-thread-support s use threads (+ if available)
1552   --enable-c99-snprintf   s force replacement
1553   --enable-clockctl       s Use /dev/clockctl for non-root clock control
1554   --enable-linuxcaps      + Use Linux capabilities for non-root clock control
1555   --enable-solarisprivs   + Use Solaris privileges for non-root clock control
1556   --enable-shared[=PKGS]  build shared libraries [default=no]
1557   --enable-static[=PKGS]  build static libraries [default=yes]
1558   --enable-fast-install[=PKGS]
1559                           optimize for fast installation [default=yes]
1560   --disable-libtool-lock  avoid locking (might break parallel builds)
1561   --disable-nls           disable nls support in libopts
1562   --enable-local-libopts  Use the supplied libopts tearoff code
1563   --enable-libopts-install
1564                           Install libopts with client installation
1565   --disable-optional-args not wanting optional option args
1566   --enable-local-libevent Force using the supplied libevent tearoff code
1567   --enable-ipv6           s use IPv6?
1568
1569   --enable-getifaddrs     + Enable the use of getifaddrs() [[yes|no]].
1570
1571 Optional Packages:
1572   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1573   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1574   --with-locfile=XXX      os-specific or "legacy"
1575   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
1576   --with-lineeditlibs     edit,editline (readline may be specified if desired)
1577   --with-threads          with threads [auto]
1578   --with-yielding-select  with yielding select [auto]
1579   --with-pic              try to use only PIC/non-PIC objects [default=use
1580                           both]
1581   --with-sysroot=DIR Search for dependent libraries within DIR
1582                         (or the compiler's sysroot if not specified).
1583   --without-sntp          - disable building sntp and sntp/tests
1584   --with-autoopts-config  specify the config-info script
1585   --with-regex-header     a reg expr header is specified
1586   --with-libregex         libregex installation prefix
1587   --with-libregex-cflags  libregex compile flags
1588   --with-libregex-libs    libregex link command arguments
1589   --with-crypto           + =openssl,libcrypto
1590
1591   --with-openssl-libdir   + =/something/reasonable
1592
1593   --with-openssl-incdir   + =/something/reasonable
1594
1595   --without-rpath         s Disable auto-added -R linker paths
1596
1597   --with-kame             - =/usr/local/v6
1598   --with-gtest            Use the gtest framework (Default: if it's available)
1599
1600 Some influential environment variables:
1601   CC          C compiler command
1602   CFLAGS      C compiler flags
1603   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1604               nonstandard directory <lib dir>
1605   LIBS        libraries to pass to the linker, e.g. -l<library>
1606   CPPFLAGS    (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1607               you have headers in a nonstandard directory <include dir>
1608   CPP         C preprocessor
1609   CXX         C++ compiler command
1610   CXXFLAGS    C++ compiler flags
1611   CXXCPP      C++ preprocessor
1612
1613 Use these variables to override the choices made by `configure' or to help
1614 it to find libraries and programs with nonstandard names/locations.
1615
1616 Report bugs to <http://bugs.ntp.org./>.
1617 sntp home page: <http://www.ntp.org./>.
1618 _ACEOF
1619 ac_status=$?
1620 fi
1621
1622 if test "$ac_init_help" = "recursive"; then
1623   # If there are subdirs, report their specific --help.
1624   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1625     test -d "$ac_dir" ||
1626       { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1627       continue
1628     ac_builddir=.
1629
1630 case "$ac_dir" in
1631 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1632 *)
1633   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1634   # A ".." for each directory in $ac_dir_suffix.
1635   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1636   case $ac_top_builddir_sub in
1637   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1638   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1639   esac ;;
1640 esac
1641 ac_abs_top_builddir=$ac_pwd
1642 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1643 # for backward compatibility:
1644 ac_top_builddir=$ac_top_build_prefix
1645
1646 case $srcdir in
1647   .)  # We are building in place.
1648     ac_srcdir=.
1649     ac_top_srcdir=$ac_top_builddir_sub
1650     ac_abs_top_srcdir=$ac_pwd ;;
1651   [\\/]* | ?:[\\/]* )  # Absolute name.
1652     ac_srcdir=$srcdir$ac_dir_suffix;
1653     ac_top_srcdir=$srcdir
1654     ac_abs_top_srcdir=$srcdir ;;
1655   *) # Relative name.
1656     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1657     ac_top_srcdir=$ac_top_build_prefix$srcdir
1658     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1659 esac
1660 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1661
1662     cd "$ac_dir" || { ac_status=$?; continue; }
1663     # Check for guested configure.
1664     if test -f "$ac_srcdir/configure.gnu"; then
1665       echo &&
1666       $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1667     elif test -f "$ac_srcdir/configure"; then
1668       echo &&
1669       $SHELL "$ac_srcdir/configure" --help=recursive
1670     else
1671       $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1672     fi || ac_status=$?
1673     cd "$ac_pwd" || { ac_status=$?; break; }
1674   done
1675 fi
1676
1677 test -n "$ac_init_help" && exit $ac_status
1678 if $ac_init_version; then
1679   cat <<\_ACEOF
1680 sntp configure 4.2.8p2
1681 generated by GNU Autoconf 2.68
1682
1683 Copyright (C) 2010 Free Software Foundation, Inc.
1684 This configure script is free software; the Free Software Foundation
1685 gives unlimited permission to copy, distribute and modify it.
1686 _ACEOF
1687   exit
1688 fi
1689
1690 ## ------------------------ ##
1691 ## Autoconf initialization. ##
1692 ## ------------------------ ##
1693
1694 # ac_fn_c_try_compile LINENO
1695 # --------------------------
1696 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1697 ac_fn_c_try_compile ()
1698 {
1699   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1700   rm -f conftest.$ac_objext
1701   if { { ac_try="$ac_compile"
1702 case "(($ac_try" in
1703   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1704   *) ac_try_echo=$ac_try;;
1705 esac
1706 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1707 $as_echo "$ac_try_echo"; } >&5
1708   (eval "$ac_compile") 2>conftest.err
1709   ac_status=$?
1710   if test -s conftest.err; then
1711     grep -v '^ *+' conftest.err >conftest.er1
1712     cat conftest.er1 >&5
1713     mv -f conftest.er1 conftest.err
1714   fi
1715   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1716   test $ac_status = 0; } && {
1717          test -z "$ac_c_werror_flag" ||
1718          test ! -s conftest.err
1719        } && test -s conftest.$ac_objext; then :
1720   ac_retval=0
1721 else
1722   $as_echo "$as_me: failed program was:" >&5
1723 sed 's/^/| /' conftest.$ac_ext >&5
1724
1725         ac_retval=1
1726 fi
1727   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1728   as_fn_set_status $ac_retval
1729
1730 } # ac_fn_c_try_compile
1731
1732 # ac_fn_c_try_cpp LINENO
1733 # ----------------------
1734 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1735 ac_fn_c_try_cpp ()
1736 {
1737   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1738   if { { ac_try="$ac_cpp conftest.$ac_ext"
1739 case "(($ac_try" in
1740   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1741   *) ac_try_echo=$ac_try;;
1742 esac
1743 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1744 $as_echo "$ac_try_echo"; } >&5
1745   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1746   ac_status=$?
1747   if test -s conftest.err; then
1748     grep -v '^ *+' conftest.err >conftest.er1
1749     cat conftest.er1 >&5
1750     mv -f conftest.er1 conftest.err
1751   fi
1752   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1753   test $ac_status = 0; } > conftest.i && {
1754          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1755          test ! -s conftest.err
1756        }; then :
1757   ac_retval=0
1758 else
1759   $as_echo "$as_me: failed program was:" >&5
1760 sed 's/^/| /' conftest.$ac_ext >&5
1761
1762     ac_retval=1
1763 fi
1764   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1765   as_fn_set_status $ac_retval
1766
1767 } # ac_fn_c_try_cpp
1768
1769 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
1770 # -------------------------------------------------------
1771 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
1772 # the include files in INCLUDES and setting the cache variable VAR
1773 # accordingly.
1774 ac_fn_c_check_header_mongrel ()
1775 {
1776   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1777   if eval \${$3+:} false; then :
1778   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1779 $as_echo_n "checking for $2... " >&6; }
1780 if eval \${$3+:} false; then :
1781   $as_echo_n "(cached) " >&6
1782 fi
1783 eval ac_res=\$$3
1784                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1785 $as_echo "$ac_res" >&6; }
1786 else
1787   # Is the header compilable?
1788 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
1789 $as_echo_n "checking $2 usability... " >&6; }
1790 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1791 /* end confdefs.h.  */
1792 $4
1793 #include <$2>
1794 _ACEOF
1795 if ac_fn_c_try_compile "$LINENO"; then :
1796   ac_header_compiler=yes
1797 else
1798   ac_header_compiler=no
1799 fi
1800 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1801 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
1802 $as_echo "$ac_header_compiler" >&6; }
1803
1804 # Is the header present?
1805 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
1806 $as_echo_n "checking $2 presence... " >&6; }
1807 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1808 /* end confdefs.h.  */
1809 #include <$2>
1810 _ACEOF
1811 if ac_fn_c_try_cpp "$LINENO"; then :
1812   ac_header_preproc=yes
1813 else
1814   ac_header_preproc=no
1815 fi
1816 rm -f conftest.err conftest.i conftest.$ac_ext
1817 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
1818 $as_echo "$ac_header_preproc" >&6; }
1819
1820 # So?  What about this header?
1821 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
1822   yes:no: )
1823     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
1824 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
1825     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1826 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1827     ;;
1828   no:yes:* )
1829     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
1830 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
1831     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     check for missing prerequisite headers?" >&5
1832 $as_echo "$as_me: WARNING: $2:     check for missing prerequisite headers?" >&2;}
1833     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
1834 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
1835     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&5
1836 $as_echo "$as_me: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&2;}
1837     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1838 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1839 ( $as_echo "## ------------------------------------ ##
1840 ## Report this to http://bugs.ntp.org./ ##
1841 ## ------------------------------------ ##"
1842      ) | sed "s/^/$as_me: WARNING:     /" >&2
1843     ;;
1844 esac
1845   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1846 $as_echo_n "checking for $2... " >&6; }
1847 if eval \${$3+:} false; then :
1848   $as_echo_n "(cached) " >&6
1849 else
1850   eval "$3=\$ac_header_compiler"
1851 fi
1852 eval ac_res=\$$3
1853                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1854 $as_echo "$ac_res" >&6; }
1855 fi
1856   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1857
1858 } # ac_fn_c_check_header_mongrel
1859
1860 # ac_fn_c_try_run LINENO
1861 # ----------------------
1862 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
1863 # that executables *can* be run.
1864 ac_fn_c_try_run ()
1865 {
1866   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1867   if { { ac_try="$ac_link"
1868 case "(($ac_try" in
1869   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1870   *) ac_try_echo=$ac_try;;
1871 esac
1872 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1873 $as_echo "$ac_try_echo"; } >&5
1874   (eval "$ac_link") 2>&5
1875   ac_status=$?
1876   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1877   test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1878   { { case "(($ac_try" in
1879   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1880   *) ac_try_echo=$ac_try;;
1881 esac
1882 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1883 $as_echo "$ac_try_echo"; } >&5
1884   (eval "$ac_try") 2>&5
1885   ac_status=$?
1886   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1887   test $ac_status = 0; }; }; then :
1888   ac_retval=0
1889 else
1890   $as_echo "$as_me: program exited with status $ac_status" >&5
1891        $as_echo "$as_me: failed program was:" >&5
1892 sed 's/^/| /' conftest.$ac_ext >&5
1893
1894        ac_retval=$ac_status
1895 fi
1896   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1897   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1898   as_fn_set_status $ac_retval
1899
1900 } # ac_fn_c_try_run
1901
1902 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
1903 # -------------------------------------------------------
1904 # Tests whether HEADER exists and can be compiled using the include files in
1905 # INCLUDES, setting the cache variable VAR accordingly.
1906 ac_fn_c_check_header_compile ()
1907 {
1908   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1909   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1910 $as_echo_n "checking for $2... " >&6; }
1911 if eval \${$3+:} false; then :
1912   $as_echo_n "(cached) " >&6
1913 else
1914   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1915 /* end confdefs.h.  */
1916 $4
1917 #include <$2>
1918 _ACEOF
1919 if ac_fn_c_try_compile "$LINENO"; then :
1920   eval "$3=yes"
1921 else
1922   eval "$3=no"
1923 fi
1924 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1925 fi
1926 eval ac_res=\$$3
1927                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1928 $as_echo "$ac_res" >&6; }
1929   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1930
1931 } # ac_fn_c_check_header_compile
1932
1933 # ac_fn_c_try_link LINENO
1934 # -----------------------
1935 # Try to link conftest.$ac_ext, and return whether this succeeded.
1936 ac_fn_c_try_link ()
1937 {
1938   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1939   rm -f conftest.$ac_objext conftest$ac_exeext
1940   if { { ac_try="$ac_link"
1941 case "(($ac_try" in
1942   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1943   *) ac_try_echo=$ac_try;;
1944 esac
1945 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1946 $as_echo "$ac_try_echo"; } >&5
1947   (eval "$ac_link") 2>conftest.err
1948   ac_status=$?
1949   if test -s conftest.err; then
1950     grep -v '^ *+' conftest.err >conftest.er1
1951     cat conftest.er1 >&5
1952     mv -f conftest.er1 conftest.err
1953   fi
1954   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1955   test $ac_status = 0; } && {
1956          test -z "$ac_c_werror_flag" ||
1957          test ! -s conftest.err
1958        } && test -s conftest$ac_exeext && {
1959          test "$cross_compiling" = yes ||
1960          $as_test_x conftest$ac_exeext
1961        }; then :
1962   ac_retval=0
1963 else
1964   $as_echo "$as_me: failed program was:" >&5
1965 sed 's/^/| /' conftest.$ac_ext >&5
1966
1967         ac_retval=1
1968 fi
1969   # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1970   # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1971   # interfere with the next link command; also delete a directory that is
1972   # left behind by Apple's compiler.  We do this before executing the actions.
1973   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1974   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1975   as_fn_set_status $ac_retval
1976
1977 } # ac_fn_c_try_link
1978
1979 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
1980 # -------------------------------------------
1981 # Tests whether TYPE exists after having included INCLUDES, setting cache
1982 # variable VAR accordingly.
1983 ac_fn_c_check_type ()
1984 {
1985   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1986   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1987 $as_echo_n "checking for $2... " >&6; }
1988 if eval \${$3+:} false; then :
1989   $as_echo_n "(cached) " >&6
1990 else
1991   eval "$3=no"
1992   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1993 /* end confdefs.h.  */
1994 $4
1995 int
1996 main ()
1997 {
1998 if (sizeof ($2))
1999          return 0;
2000   ;
2001   return 0;
2002 }
2003 _ACEOF
2004 if ac_fn_c_try_compile "$LINENO"; then :
2005   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2006 /* end confdefs.h.  */
2007 $4
2008 int
2009 main ()
2010 {
2011 if (sizeof (($2)))
2012             return 0;
2013   ;
2014   return 0;
2015 }
2016 _ACEOF
2017 if ac_fn_c_try_compile "$LINENO"; then :
2018
2019 else
2020   eval "$3=yes"
2021 fi
2022 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2023 fi
2024 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2025 fi
2026 eval ac_res=\$$3
2027                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2028 $as_echo "$ac_res" >&6; }
2029   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2030
2031 } # ac_fn_c_check_type
2032
2033 # ac_fn_c_check_func LINENO FUNC VAR
2034 # ----------------------------------
2035 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2036 ac_fn_c_check_func ()
2037 {
2038   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2039   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2040 $as_echo_n "checking for $2... " >&6; }
2041 if eval \${$3+:} false; then :
2042   $as_echo_n "(cached) " >&6
2043 else
2044   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2045 /* end confdefs.h.  */
2046 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2047    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
2048 #define $2 innocuous_$2
2049
2050 /* System header to define __stub macros and hopefully few prototypes,
2051     which can conflict with char $2 (); below.
2052     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2053     <limits.h> exists even on freestanding compilers.  */
2054
2055 #ifdef __STDC__
2056 # include <limits.h>
2057 #else
2058 # include <assert.h>
2059 #endif
2060
2061 #undef $2
2062
2063 /* Override any GCC internal prototype to avoid an error.
2064    Use char because int might match the return type of a GCC
2065    builtin and then its argument prototype would still apply.  */
2066 #ifdef __cplusplus
2067 extern "C"
2068 #endif
2069 char $2 ();
2070 /* The GNU C library defines this for functions which it implements
2071     to always fail with ENOSYS.  Some functions are actually named
2072     something starting with __ and the normal name is an alias.  */
2073 #if defined __stub_$2 || defined __stub___$2
2074 choke me
2075 #endif
2076
2077 int
2078 main ()
2079 {
2080 return $2 ();
2081   ;
2082   return 0;
2083 }
2084 _ACEOF
2085 if ac_fn_c_try_link "$LINENO"; then :
2086   eval "$3=yes"
2087 else
2088   eval "$3=no"
2089 fi
2090 rm -f core conftest.err conftest.$ac_objext \
2091     conftest$ac_exeext conftest.$ac_ext
2092 fi
2093 eval ac_res=\$$3
2094                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2095 $as_echo "$ac_res" >&6; }
2096   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2097
2098 } # ac_fn_c_check_func
2099
2100 # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
2101 # ---------------------------------------------
2102 # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
2103 # accordingly.
2104 ac_fn_c_check_decl ()
2105 {
2106   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2107   as_decl_name=`echo $2|sed 's/ *(.*//'`
2108   as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
2109   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2110 $as_echo_n "checking whether $as_decl_name is declared... " >&6; }
2111 if eval \${$3+:} false; then :
2112   $as_echo_n "(cached) " >&6
2113 else
2114   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2115 /* end confdefs.h.  */
2116 $4
2117 int
2118 main ()
2119 {
2120 #ifndef $as_decl_name
2121 #ifdef __cplusplus
2122   (void) $as_decl_use;
2123 #else
2124   (void) $as_decl_name;
2125 #endif
2126 #endif
2127
2128   ;
2129   return 0;
2130 }
2131 _ACEOF
2132 if ac_fn_c_try_compile "$LINENO"; then :
2133   eval "$3=yes"
2134 else
2135   eval "$3=no"
2136 fi
2137 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2138 fi
2139 eval ac_res=\$$3
2140                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2141 $as_echo "$ac_res" >&6; }
2142   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2143
2144 } # ac_fn_c_check_decl
2145
2146 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2147 # --------------------------------------------
2148 # Tries to find the compile-time value of EXPR in a program that includes
2149 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2150 # computed
2151 ac_fn_c_compute_int ()
2152 {
2153   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2154   if test "$cross_compiling" = yes; then
2155     # Depending upon the size, compute the lo and hi bounds.
2156 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2157 /* end confdefs.h.  */
2158 $4
2159 int
2160 main ()
2161 {
2162 static int test_array [1 - 2 * !(($2) >= 0)];
2163 test_array [0] = 0
2164
2165   ;
2166   return 0;
2167 }
2168 _ACEOF
2169 if ac_fn_c_try_compile "$LINENO"; then :
2170   ac_lo=0 ac_mid=0
2171   while :; do
2172     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2173 /* end confdefs.h.  */
2174 $4
2175 int
2176 main ()
2177 {
2178 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2179 test_array [0] = 0
2180
2181   ;
2182   return 0;
2183 }
2184 _ACEOF
2185 if ac_fn_c_try_compile "$LINENO"; then :
2186   ac_hi=$ac_mid; break
2187 else
2188   as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2189                         if test $ac_lo -le $ac_mid; then
2190                           ac_lo= ac_hi=
2191                           break
2192                         fi
2193                         as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2194 fi
2195 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2196   done
2197 else
2198   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2199 /* end confdefs.h.  */
2200 $4
2201 int
2202 main ()
2203 {
2204 static int test_array [1 - 2 * !(($2) < 0)];
2205 test_array [0] = 0
2206
2207   ;
2208   return 0;
2209 }
2210 _ACEOF
2211 if ac_fn_c_try_compile "$LINENO"; then :
2212   ac_hi=-1 ac_mid=-1
2213   while :; do
2214     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2215 /* end confdefs.h.  */
2216 $4
2217 int
2218 main ()
2219 {
2220 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2221 test_array [0] = 0
2222
2223   ;
2224   return 0;
2225 }
2226 _ACEOF
2227 if ac_fn_c_try_compile "$LINENO"; then :
2228   ac_lo=$ac_mid; break
2229 else
2230   as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2231                         if test $ac_mid -le $ac_hi; then
2232                           ac_lo= ac_hi=
2233                           break
2234                         fi
2235                         as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2236 fi
2237 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2238   done
2239 else
2240   ac_lo= ac_hi=
2241 fi
2242 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2243 fi
2244 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2245 # Binary search between lo and hi bounds.
2246 while test "x$ac_lo" != "x$ac_hi"; do
2247   as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2248   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2249 /* end confdefs.h.  */
2250 $4
2251 int
2252 main ()
2253 {
2254 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2255 test_array [0] = 0
2256
2257   ;
2258   return 0;
2259 }
2260 _ACEOF
2261 if ac_fn_c_try_compile "$LINENO"; then :
2262   ac_hi=$ac_mid
2263 else
2264   as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2265 fi
2266 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2267 done
2268 case $ac_lo in #((
2269 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2270 '') ac_retval=1 ;;
2271 esac
2272   else
2273     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2274 /* end confdefs.h.  */
2275 $4
2276 static long int longval () { return $2; }
2277 static unsigned long int ulongval () { return $2; }
2278 #include <stdio.h>
2279 #include <stdlib.h>
2280 int
2281 main ()
2282 {
2283
2284   FILE *f = fopen ("conftest.val", "w");
2285   if (! f)
2286     return 1;
2287   if (($2) < 0)
2288     {
2289       long int i = longval ();
2290       if (i != ($2))
2291         return 1;
2292       fprintf (f, "%ld", i);
2293     }
2294   else
2295     {
2296       unsigned long int i = ulongval ();
2297       if (i != ($2))
2298         return 1;
2299       fprintf (f, "%lu", i);
2300     }
2301   /* Do not output a trailing newline, as this causes \r\n confusion
2302      on some platforms.  */
2303   return ferror (f) || fclose (f) != 0;
2304
2305   ;
2306   return 0;
2307 }
2308 _ACEOF
2309 if ac_fn_c_try_run "$LINENO"; then :
2310   echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2311 else
2312   ac_retval=1
2313 fi
2314 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2315   conftest.$ac_objext conftest.beam conftest.$ac_ext
2316 rm -f conftest.val
2317
2318   fi
2319   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2320   as_fn_set_status $ac_retval
2321
2322 } # ac_fn_c_compute_int
2323
2324 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2325 # ----------------------------------------------------
2326 # Tries to find if the field MEMBER exists in type AGGR, after including
2327 # INCLUDES, setting cache variable VAR accordingly.
2328 ac_fn_c_check_member ()
2329 {
2330   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2331   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2332 $as_echo_n "checking for $2.$3... " >&6; }
2333 if eval \${$4+:} false; then :
2334   $as_echo_n "(cached) " >&6
2335 else
2336   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2337 /* end confdefs.h.  */
2338 $5
2339 int
2340 main ()
2341 {
2342 static $2 ac_aggr;
2343 if (ac_aggr.$3)
2344 return 0;
2345   ;
2346   return 0;
2347 }
2348 _ACEOF
2349 if ac_fn_c_try_compile "$LINENO"; then :
2350   eval "$4=yes"
2351 else
2352   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2353 /* end confdefs.h.  */
2354 $5
2355 int
2356 main ()
2357 {
2358 static $2 ac_aggr;
2359 if (sizeof ac_aggr.$3)
2360 return 0;
2361   ;
2362   return 0;
2363 }
2364 _ACEOF
2365 if ac_fn_c_try_compile "$LINENO"; then :
2366   eval "$4=yes"
2367 else
2368   eval "$4=no"
2369 fi
2370 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2371 fi
2372 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2373 fi
2374 eval ac_res=\$$4
2375                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2376 $as_echo "$ac_res" >&6; }
2377   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2378
2379 } # ac_fn_c_check_member
2380
2381 # ac_fn_cxx_try_compile LINENO
2382 # ----------------------------
2383 # Try to compile conftest.$ac_ext, and return whether this succeeded.
2384 ac_fn_cxx_try_compile ()
2385 {
2386   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2387   rm -f conftest.$ac_objext
2388   if { { ac_try="$ac_compile"
2389 case "(($ac_try" in
2390   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2391   *) ac_try_echo=$ac_try;;
2392 esac
2393 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2394 $as_echo "$ac_try_echo"; } >&5
2395   (eval "$ac_compile") 2>conftest.err
2396   ac_status=$?
2397   if test -s conftest.err; then
2398     grep -v '^ *+' conftest.err >conftest.er1
2399     cat conftest.er1 >&5
2400     mv -f conftest.er1 conftest.err
2401   fi
2402   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2403   test $ac_status = 0; } && {
2404          test -z "$ac_cxx_werror_flag" ||
2405          test ! -s conftest.err
2406        } && test -s conftest.$ac_objext; then :
2407   ac_retval=0
2408 else
2409   $as_echo "$as_me: failed program was:" >&5
2410 sed 's/^/| /' conftest.$ac_ext >&5
2411
2412         ac_retval=1
2413 fi
2414   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2415   as_fn_set_status $ac_retval
2416
2417 } # ac_fn_cxx_try_compile
2418
2419 # ac_fn_cxx_try_cpp LINENO
2420 # ------------------------
2421 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2422 ac_fn_cxx_try_cpp ()
2423 {
2424   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2425   if { { ac_try="$ac_cpp conftest.$ac_ext"
2426 case "(($ac_try" in
2427   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2428   *) ac_try_echo=$ac_try;;
2429 esac
2430 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2431 $as_echo "$ac_try_echo"; } >&5
2432   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2433   ac_status=$?
2434   if test -s conftest.err; then
2435     grep -v '^ *+' conftest.err >conftest.er1
2436     cat conftest.er1 >&5
2437     mv -f conftest.er1 conftest.err
2438   fi
2439   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2440   test $ac_status = 0; } > conftest.i && {
2441          test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" ||
2442          test ! -s conftest.err
2443        }; then :
2444   ac_retval=0
2445 else
2446   $as_echo "$as_me: failed program was:" >&5
2447 sed 's/^/| /' conftest.$ac_ext >&5
2448
2449     ac_retval=1
2450 fi
2451   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2452   as_fn_set_status $ac_retval
2453
2454 } # ac_fn_cxx_try_cpp
2455
2456 # ac_fn_cxx_try_link LINENO
2457 # -------------------------
2458 # Try to link conftest.$ac_ext, and return whether this succeeded.
2459 ac_fn_cxx_try_link ()
2460 {
2461   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2462   rm -f conftest.$ac_objext conftest$ac_exeext
2463   if { { ac_try="$ac_link"
2464 case "(($ac_try" in
2465   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2466   *) ac_try_echo=$ac_try;;
2467 esac
2468 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2469 $as_echo "$ac_try_echo"; } >&5
2470   (eval "$ac_link") 2>conftest.err
2471   ac_status=$?
2472   if test -s conftest.err; then
2473     grep -v '^ *+' conftest.err >conftest.er1
2474     cat conftest.er1 >&5
2475     mv -f conftest.er1 conftest.err
2476   fi
2477   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2478   test $ac_status = 0; } && {
2479          test -z "$ac_cxx_werror_flag" ||
2480          test ! -s conftest.err
2481        } && test -s conftest$ac_exeext && {
2482          test "$cross_compiling" = yes ||
2483          $as_test_x conftest$ac_exeext
2484        }; then :
2485   ac_retval=0
2486 else
2487   $as_echo "$as_me: failed program was:" >&5
2488 sed 's/^/| /' conftest.$ac_ext >&5
2489
2490         ac_retval=1
2491 fi
2492   # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2493   # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2494   # interfere with the next link command; also delete a directory that is
2495   # left behind by Apple's compiler.  We do this before executing the actions.
2496   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2497   eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2498   as_fn_set_status $ac_retval
2499
2500 } # ac_fn_cxx_try_link
2501 cat >config.log <<_ACEOF
2502 This file contains any messages produced by compilers while
2503 running configure, to aid debugging if configure makes a mistake.
2504
2505 It was created by sntp $as_me 4.2.8p2, which was
2506 generated by GNU Autoconf 2.68.  Invocation command line was
2507
2508   $ $0 $@
2509
2510 _ACEOF
2511 exec 5>>config.log
2512 {
2513 cat <<_ASUNAME
2514 ## --------- ##
2515 ## Platform. ##
2516 ## --------- ##
2517
2518 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2519 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2520 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2521 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2522 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2523
2524 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2525 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
2526
2527 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
2528 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
2529 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2530 /usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
2531 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
2532 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
2533 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
2534
2535 _ASUNAME
2536
2537 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2538 for as_dir in $PATH
2539 do
2540   IFS=$as_save_IFS
2541   test -z "$as_dir" && as_dir=.
2542     $as_echo "PATH: $as_dir"
2543   done
2544 IFS=$as_save_IFS
2545
2546 } >&5
2547
2548 cat >&5 <<_ACEOF
2549
2550
2551 ## ----------- ##
2552 ## Core tests. ##
2553 ## ----------- ##
2554
2555 _ACEOF
2556
2557
2558 # Keep a trace of the command line.
2559 # Strip out --no-create and --no-recursion so they do not pile up.
2560 # Strip out --silent because we don't want to record it for future runs.
2561 # Also quote any args containing shell meta-characters.
2562 # Make two passes to allow for proper duplicate-argument suppression.
2563 ac_configure_args=
2564 ac_configure_args0=
2565 ac_configure_args1=
2566 ac_must_keep_next=false
2567 for ac_pass in 1 2
2568 do
2569   for ac_arg
2570   do
2571     case $ac_arg in
2572     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2573     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2574     | -silent | --silent | --silen | --sile | --sil)
2575       continue ;;
2576     *\'*)
2577       ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2578     esac
2579     case $ac_pass in
2580     1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2581     2)
2582       as_fn_append ac_configure_args1 " '$ac_arg'"
2583       if test $ac_must_keep_next = true; then
2584         ac_must_keep_next=false # Got value, back to normal.
2585       else
2586         case $ac_arg in
2587           *=* | --config-cache | -C | -disable-* | --disable-* \
2588           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2589           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2590           | -with-* | --with-* | -without-* | --without-* | --x)
2591             case "$ac_configure_args0 " in
2592               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2593             esac
2594             ;;
2595           -* ) ac_must_keep_next=true ;;
2596         esac
2597       fi
2598       as_fn_append ac_configure_args " '$ac_arg'"
2599       ;;
2600     esac
2601   done
2602 done
2603 { ac_configure_args0=; unset ac_configure_args0;}
2604 { ac_configure_args1=; unset ac_configure_args1;}
2605
2606 # When interrupted or exit'd, cleanup temporary files, and complete
2607 # config.log.  We remove comments because anyway the quotes in there
2608 # would cause problems or look ugly.
2609 # WARNING: Use '\'' to represent an apostrophe within the trap.
2610 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2611 trap 'exit_status=$?
2612   # Save into config.log some information that might help in debugging.
2613   {
2614     echo
2615
2616     $as_echo "## ---------------- ##
2617 ## Cache variables. ##
2618 ## ---------------- ##"
2619     echo
2620     # The following way of writing the cache mishandles newlines in values,
2621 (
2622   for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2623     eval ac_val=\$$ac_var
2624     case $ac_val in #(
2625     *${as_nl}*)
2626       case $ac_var in #(
2627       *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2628 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2629       esac
2630       case $ac_var in #(
2631       _ | IFS | as_nl) ;; #(
2632       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2633       *) { eval $ac_var=; unset $ac_var;} ;;
2634       esac ;;
2635     esac
2636   done
2637   (set) 2>&1 |
2638     case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2639     *${as_nl}ac_space=\ *)
2640       sed -n \
2641         "s/'\''/'\''\\\\'\'''\''/g;
2642           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2643       ;; #(
2644     *)
2645       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2646       ;;
2647     esac |
2648     sort
2649 )
2650     echo
2651
2652     $as_echo "## ----------------- ##
2653 ## Output variables. ##
2654 ## ----------------- ##"
2655     echo
2656     for ac_var in $ac_subst_vars
2657     do
2658       eval ac_val=\$$ac_var
2659       case $ac_val in
2660       *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2661       esac
2662       $as_echo "$ac_var='\''$ac_val'\''"
2663     done | sort
2664     echo
2665
2666     if test -n "$ac_subst_files"; then
2667       $as_echo "## ------------------- ##
2668 ## File substitutions. ##
2669 ## ------------------- ##"
2670       echo
2671       for ac_var in $ac_subst_files
2672       do
2673         eval ac_val=\$$ac_var
2674         case $ac_val in
2675         *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2676         esac
2677         $as_echo "$ac_var='\''$ac_val'\''"
2678       done | sort
2679       echo
2680     fi
2681
2682     if test -s confdefs.h; then
2683       $as_echo "## ----------- ##
2684 ## confdefs.h. ##
2685 ## ----------- ##"
2686       echo
2687       cat confdefs.h
2688       echo
2689     fi
2690     test "$ac_signal" != 0 &&
2691       $as_echo "$as_me: caught signal $ac_signal"
2692     $as_echo "$as_me: exit $exit_status"
2693   } >&5
2694   rm -f core *.core core.conftest.* &&
2695     rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2696     exit $exit_status
2697 ' 0
2698 for ac_signal in 1 2 13 15; do
2699   trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2700 done
2701 ac_signal=0
2702
2703 # confdefs.h avoids OS command line length limits that DEFS can exceed.
2704 rm -f -r conftest* confdefs.h
2705
2706 $as_echo "/* confdefs.h */" > confdefs.h
2707
2708 # Predefined preprocessor variables.
2709
2710 cat >>confdefs.h <<_ACEOF
2711 #define PACKAGE_NAME "$PACKAGE_NAME"
2712 _ACEOF
2713
2714 cat >>confdefs.h <<_ACEOF
2715 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2716 _ACEOF
2717
2718 cat >>confdefs.h <<_ACEOF
2719 #define PACKAGE_VERSION "$PACKAGE_VERSION"
2720 _ACEOF
2721
2722 cat >>confdefs.h <<_ACEOF
2723 #define PACKAGE_STRING "$PACKAGE_STRING"
2724 _ACEOF
2725
2726 cat >>confdefs.h <<_ACEOF
2727 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2728 _ACEOF
2729
2730 cat >>confdefs.h <<_ACEOF
2731 #define PACKAGE_URL "$PACKAGE_URL"
2732 _ACEOF
2733
2734
2735 # Let the site file select an alternate cache file if it wants to.
2736 # Prefer an explicitly selected file to automatically selected ones.
2737 ac_site_file1=NONE
2738 ac_site_file2=NONE
2739 if test -n "$CONFIG_SITE"; then
2740   # We do not want a PATH search for config.site.
2741   case $CONFIG_SITE in #((
2742     -*)  ac_site_file1=./$CONFIG_SITE;;
2743     */*) ac_site_file1=$CONFIG_SITE;;
2744     *)   ac_site_file1=./$CONFIG_SITE;;
2745   esac
2746 elif test "x$prefix" != xNONE; then
2747   ac_site_file1=$prefix/share/config.site
2748   ac_site_file2=$prefix/etc/config.site
2749 else
2750   ac_site_file1=$ac_default_prefix/share/config.site
2751   ac_site_file2=$ac_default_prefix/etc/config.site
2752 fi
2753 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2754 do
2755   test "x$ac_site_file" = xNONE && continue
2756   if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
2757     { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2758 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
2759     sed 's/^/| /' "$ac_site_file" >&5
2760     . "$ac_site_file" \
2761       || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2762 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2763 as_fn_error $? "failed to load site script $ac_site_file
2764 See \`config.log' for more details" "$LINENO" 5; }
2765   fi
2766 done
2767
2768 if test -r "$cache_file"; then
2769   # Some versions of bash will fail to source /dev/null (special files
2770   # actually), so we avoid doing that.  DJGPP emulates it as a regular file.
2771   if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2772     { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2773 $as_echo "$as_me: loading cache $cache_file" >&6;}
2774     case $cache_file in
2775       [\\/]* | ?:[\\/]* ) . "$cache_file";;
2776       *)                      . "./$cache_file";;
2777     esac
2778   fi
2779 else
2780   { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2781 $as_echo "$as_me: creating cache $cache_file" >&6;}
2782   >$cache_file
2783 fi
2784
2785 as_fn_append ac_header_list " stdarg.h"
2786 # Check that the precious variables saved in the cache have kept the same
2787 # value.
2788 ac_cache_corrupted=false
2789 for ac_var in $ac_precious_vars; do
2790   eval ac_old_set=\$ac_cv_env_${ac_var}_set
2791   eval ac_new_set=\$ac_env_${ac_var}_set
2792   eval ac_old_val=\$ac_cv_env_${ac_var}_value
2793   eval ac_new_val=\$ac_env_${ac_var}_value
2794   case $ac_old_set,$ac_new_set in
2795     set,)
2796       { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2797 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2798       ac_cache_corrupted=: ;;
2799     ,set)
2800       { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2801 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2802       ac_cache_corrupted=: ;;
2803     ,);;
2804     *)
2805       if test "x$ac_old_val" != "x$ac_new_val"; then
2806         # differences in whitespace do not lead to failure.
2807         ac_old_val_w=`echo x $ac_old_val`
2808         ac_new_val_w=`echo x $ac_new_val`
2809         if test "$ac_old_val_w" != "$ac_new_val_w"; then
2810           { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2811 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2812           ac_cache_corrupted=:
2813         else
2814           { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2815 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2816           eval $ac_var=\$ac_old_val
2817         fi
2818         { $as_echo "$as_me:${as_lineno-$LINENO}:   former value:  \`$ac_old_val'" >&5
2819 $as_echo "$as_me:   former value:  \`$ac_old_val'" >&2;}
2820         { $as_echo "$as_me:${as_lineno-$LINENO}:   current value: \`$ac_new_val'" >&5
2821 $as_echo "$as_me:   current value: \`$ac_new_val'" >&2;}
2822       fi;;
2823   esac
2824   # Pass precious variables to config.status.
2825   if test "$ac_new_set" = set; then
2826     case $ac_new_val in
2827     *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2828     *) ac_arg=$ac_var=$ac_new_val ;;
2829     esac
2830     case " $ac_configure_args " in
2831       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
2832       *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2833     esac
2834   fi
2835 done
2836 if $ac_cache_corrupted; then
2837   { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2838 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2839   { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2840 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2841   as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
2842 fi
2843 ## -------------------- ##
2844 ## Main body of script. ##
2845 ## -------------------- ##
2846
2847 ac_ext=c
2848 ac_cpp='$CPP $CPPFLAGS'
2849 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2850 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2851 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2852
2853
2854
2855 ac_aux_dir=
2856 for ac_dir in libevent/build-aux "$srcdir"/libevent/build-aux; do
2857   if test -f "$ac_dir/install-sh"; then
2858     ac_aux_dir=$ac_dir
2859     ac_install_sh="$ac_aux_dir/install-sh -c"
2860     break
2861   elif test -f "$ac_dir/install.sh"; then
2862     ac_aux_dir=$ac_dir
2863     ac_install_sh="$ac_aux_dir/install.sh -c"
2864     break
2865   elif test -f "$ac_dir/shtool"; then
2866     ac_aux_dir=$ac_dir
2867     ac_install_sh="$ac_aux_dir/shtool install -c"
2868     break
2869   fi
2870 done
2871 if test -z "$ac_aux_dir"; then
2872   as_fn_error $? "cannot find install-sh, install.sh, or shtool in libevent/build-aux \"$srcdir\"/libevent/build-aux" "$LINENO" 5
2873 fi
2874
2875 # These three variables are undocumented and unsupported,
2876 # and are intended to be withdrawn in a future Autoconf release.
2877 # They can cause serious problems if a builder's source tree is in a directory
2878 # whose full name contains unusual characters.
2879 ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
2880 ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
2881 ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
2882
2883
2884
2885 # Bump sntp_configure_cache_version for each change to configure.ac or
2886 # .m4 files which invalidates cached values from previous configure
2887 # runs.
2888 #
2889 # If the change affects cache variables used only by the main NTP
2890 # configure.ac, then only its version number should be bumped, while
2891 # the subdir configure.ac version numbers should be unchanged.  The
2892 # same is true for a test/variable that is used only by one subdir
2893 # being changed incompatibly; only that subdir's cache version needs
2894 # bumping.
2895 #
2896 # If a change affects variables shared by all NTP configure scripts,
2897 # please bump the version numbers of each.  If you are not sure, the
2898 # safe choice is to bump all on any cache-invalidating change.
2899 #
2900 # In order to avoid the risk of version stamp collision between -stable
2901 # and -dev branches, do not simply increment the version, instead use
2902 # the date YYYYMMDD optionally with -HHMM if there is more than one
2903 # bump in a day.
2904
2905 sntp_configure_cache_version=20120806
2906
2907 # When the version of config.cache and configure do not
2908 # match, NTP_CACHEVERSION will flush the cache.
2909
2910
2911
2912     ntp_cache_flush=1
2913
2914     case "$ntp_cv_sntp_cache_version" in
2915      $sntp_configure_cache_version)
2916         # same version, good
2917         ntp_cache_flush=0
2918         ;;
2919      '')
2920         # No cache, predates ntp_cv_sntp_cache_version, or is empty.
2921         case "$cache_file" in
2922          /dev/null)
2923             ntp_cache_flush=0
2924             ;;
2925          *)
2926             case "$NTP_CACHEVERSION_PARENT" in
2927              '')
2928                 # Do not clear the cache immediately after it is created
2929                 # empty as it is noisy.  Differentiate a newly-created
2930                 # config.cache from one predating the cache version
2931                 # mechanism by looking for the first cached variable set
2932                 # by Autoconf
2933                 case "$ac_cv_path_install" in
2934                  '')
2935                     # empty config.cache file
2936                     ntp_cache_flush=0
2937                 esac
2938                 ;;
2939              *)
2940                 # Parent configure just created cache from empty,
2941                 # flushing would be counterproductive.
2942                 ntp_cache_flush=0;
2943                 ;;
2944             esac
2945         esac
2946         ;;
2947      *)
2948         # configure cache version mismatches config.cache version
2949         ;;
2950     esac
2951
2952     case "$ntp_cache_flush" in
2953      1)
2954         c_version="${ntp_cv_sntp_cache_version:-(no version found)}"
2955
2956         # Do we flush all variables or exclude others' version stamps?
2957
2958         case "$NTP_CACHEVERSION_PARENT" in
2959          '')
2960             # Clear all *_cv_* variables including our child subdirs'
2961             # ntp_cv_*_cache_version variables.  This prevents subdir
2962             # configure scripts from noticing a version mismatch just
2963             # after the top configure in the invocation cleared and
2964             # recreated the cache.
2965
2966             c_varname_list=`set |
2967                             sed -n -e 's/=.*$//' \
2968                                    -e '/_cv_/p'
2969                            `
2970             ;;
2971          *)
2972             # This is not the top configure this particular invocation.
2973             # Clear all *_cv_* variables sparing the version stamps
2974             # of other configure scripts, so we don't trigger
2975             # useless repeated clearings.
2976
2977             c_varname_list=`set |
2978                             sed -n -e 's/=.*$//' \
2979                                    -e '/ntp_cv_.*_cache_version/d' \
2980                                    -e '/_cv_/p'
2981                            `
2982         esac
2983
2984         for c_varname in $c_varname_list
2985         do
2986                                                     { eval $c_varname=; unset $c_varname; }
2987         done
2988
2989         { $as_echo "$as_me:${as_lineno-$LINENO}: $cache_file saved by another version, ignored." >&5
2990 $as_echo "$as_me: $cache_file saved by another version, ignored." >&6;}
2991         { $as_echo "$as_me:${as_lineno-$LINENO}: configure script cache version: $sntp_configure_cache_version" >&5
2992 $as_echo "$as_me: configure script cache version: $sntp_configure_cache_version" >&6;}
2993         { $as_echo "$as_me:${as_lineno-$LINENO}: $cache_file version: $c_version" >&5
2994 $as_echo "$as_me: $cache_file version: $c_version" >&6;}
2995         { c_varname=; unset c_varname;}
2996         { c_varname_list=; unset c_varname_list;}
2997         { c_version=; unset c_version;}
2998     esac
2999
3000     { ntp_cache_flush=; unset ntp_cache_flush;}
3001
3002     # save configure version in config.cache for next time
3003     ntp_cv_sntp_cache_version="$sntp_configure_cache_version"
3004
3005     # let any subdir configure.ac NTP_CACHEVERSION invocations
3006     # know they are not the top level.
3007     NTP_CACHEVERSION_PARENT='sntp' ; export NTP_CACHEVERSION_PARENT
3008
3009
3010 am__api_version='1.11'
3011
3012 # Find a good install program.  We prefer a C program (faster),
3013 # so one script is as good as another.  But avoid the broken or
3014 # incompatible versions:
3015 # SysV /etc/install, /usr/sbin/install
3016 # SunOS /usr/etc/install
3017 # IRIX /sbin/install
3018 # AIX /bin/install
3019 # AmigaOS /C/install, which installs bootblocks on floppy discs
3020 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3021 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
3022 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3023 # OS/2's system install, which has a completely different semantic
3024 # ./install, which can be erroneously created by make from ./install.sh.
3025 # Reject install programs that cannot install multiple files.
3026 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
3027 $as_echo_n "checking for a BSD-compatible install... " >&6; }
3028 if test -z "$INSTALL"; then
3029 if ${ac_cv_path_install+:} false; then :
3030   $as_echo_n "(cached) " >&6
3031 else
3032   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3033 for as_dir in $PATH
3034 do
3035   IFS=$as_save_IFS
3036   test -z "$as_dir" && as_dir=.
3037     # Account for people who put trailing slashes in PATH elements.
3038 case $as_dir/ in #((
3039   ./ | .// | /[cC]/* | \
3040   /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3041   ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
3042   /usr/ucb/* ) ;;
3043   *)
3044     # OSF1 and SCO ODT 3.0 have their own names for install.
3045     # Don't use installbsd from OSF since it installs stuff as root
3046     # by default.
3047     for ac_prog in ginstall scoinst install; do
3048       for ac_exec_ext in '' $ac_executable_extensions; do
3049         if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
3050           if test $ac_prog = install &&
3051             grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3052             # AIX install.  It has an incompatible calling convention.
3053             :
3054           elif test $ac_prog = install &&
3055             grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3056             # program-specific install script used by HP pwplus--don't use.
3057             :
3058           else
3059             rm -rf conftest.one conftest.two conftest.dir
3060             echo one > conftest.one
3061             echo two > conftest.two
3062             mkdir conftest.dir
3063             if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
3064               test -s conftest.one && test -s conftest.two &&
3065               test -s conftest.dir/conftest.one &&
3066               test -s conftest.dir/conftest.two
3067             then
3068               ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3069               break 3
3070             fi
3071           fi
3072         fi
3073       done
3074     done
3075     ;;
3076 esac
3077
3078   done
3079 IFS=$as_save_IFS
3080
3081 rm -rf conftest.one conftest.two conftest.dir
3082
3083 fi
3084   if test "${ac_cv_path_install+set}" = set; then
3085     INSTALL=$ac_cv_path_install
3086   else
3087     # As a last resort, use the slow shell script.  Don't cache a
3088     # value for INSTALL within a source directory, because that will
3089     # break other packages using the cache if that directory is
3090     # removed, or if the value is a relative name.
3091     INSTALL=$ac_install_sh
3092   fi
3093 fi
3094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
3095 $as_echo "$INSTALL" >&6; }
3096
3097 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3098 # It thinks the first close brace ends the variable substitution.
3099 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3100
3101 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3102
3103 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3104
3105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
3106 $as_echo_n "checking whether build environment is sane... " >&6; }
3107 # Just in case
3108 sleep 1
3109 echo timestamp > conftest.file
3110 # Reject unsafe characters in $srcdir or the absolute working directory
3111 # name.  Accept space and tab only in the latter.
3112 am_lf='
3113 '
3114 case `pwd` in
3115   *[\\\"\#\$\&\'\`$am_lf]*)
3116     as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;;
3117 esac
3118 case $srcdir in
3119   *[\\\"\#\$\&\'\`$am_lf\ \     ]*)
3120     as_fn_error $? "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;;
3121 esac
3122
3123 # Do `set' in a subshell so we don't clobber the current shell's
3124 # arguments.  Must try -L first in case configure is actually a
3125 # symlink; some systems play weird games with the mod time of symlinks
3126 # (eg FreeBSD returns the mod time of the symlink's containing
3127 # directory).
3128 if (
3129    set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
3130    if test "$*" = "X"; then
3131       # -L didn't work.
3132       set X `ls -t "$srcdir/configure" conftest.file`
3133    fi
3134    rm -f conftest.file
3135    if test "$*" != "X $srcdir/configure conftest.file" \
3136       && test "$*" != "X conftest.file $srcdir/configure"; then
3137
3138       # If neither matched, then we have a broken ls.  This can happen
3139       # if, for instance, CONFIG_SHELL is bash and it inherits a
3140       # broken ls alias from the environment.  This has actually
3141       # happened.  Such a system could not be considered "sane".
3142       as_fn_error $? "ls -t appears to fail.  Make sure there is not a broken
3143 alias in your environment" "$LINENO" 5
3144    fi
3145
3146    test "$2" = conftest.file
3147    )
3148 then
3149    # Ok.
3150    :
3151 else
3152    as_fn_error $? "newly created file is older than distributed files!
3153 Check your system clock" "$LINENO" 5
3154 fi
3155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3156 $as_echo "yes" >&6; }
3157 test "$program_prefix" != NONE &&
3158   program_transform_name="s&^&$program_prefix&;$program_transform_name"
3159 # Use a double $ so make ignores it.
3160 test "$program_suffix" != NONE &&
3161   program_transform_name="s&\$&$program_suffix&;$program_transform_name"
3162 # Double any \ or $.
3163 # By default was `s,x,x', remove it if useless.
3164 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
3165 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
3166
3167 # expand $ac_aux_dir to an absolute path
3168 am_aux_dir=`cd $ac_aux_dir && pwd`
3169
3170 if test x"${MISSING+set}" != xset; then
3171   case $am_aux_dir in
3172   *\ * | *\     *)
3173     MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
3174   *)
3175     MISSING="\${SHELL} $am_aux_dir/missing" ;;
3176   esac
3177 fi
3178 # Use eval to expand $SHELL
3179 if eval "$MISSING --run true"; then
3180   am_missing_run="$MISSING --run "
3181 else
3182   am_missing_run=
3183   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5
3184 $as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
3185 fi
3186
3187 if test x"${install_sh}" != xset; then
3188   case $am_aux_dir in
3189   *\ * | *\     *)
3190     install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
3191   *)
3192     install_sh="\${SHELL} $am_aux_dir/install-sh"
3193   esac
3194 fi
3195
3196 # Installed binaries are usually stripped using `strip' when the user
3197 # run `make install-strip'.  However `strip' might not be the right
3198 # tool to use in cross-compilation environments, therefore Automake
3199 # will honor the `STRIP' environment variable to overrule this program.
3200 if test "$cross_compiling" != no; then
3201   if test -n "$ac_tool_prefix"; then
3202   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
3203 set dummy ${ac_tool_prefix}strip; ac_word=$2
3204 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3205 $as_echo_n "checking for $ac_word... " >&6; }
3206 if ${ac_cv_prog_STRIP+:} false; then :
3207   $as_echo_n "(cached) " >&6
3208 else
3209   if test -n "$STRIP"; then
3210   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
3211 else
3212 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3213 for as_dir in $PATH
3214 do
3215   IFS=$as_save_IFS
3216   test -z "$as_dir" && as_dir=.
3217     for ac_exec_ext in '' $ac_executable_extensions; do
3218   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3219     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
3220     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3221     break 2
3222   fi
3223 done
3224   done
3225 IFS=$as_save_IFS
3226
3227 fi
3228 fi
3229 STRIP=$ac_cv_prog_STRIP
3230 if test -n "$STRIP"; then
3231   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
3232 $as_echo "$STRIP" >&6; }
3233 else
3234   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3235 $as_echo "no" >&6; }
3236 fi
3237
3238
3239 fi
3240 if test -z "$ac_cv_prog_STRIP"; then
3241   ac_ct_STRIP=$STRIP
3242   # Extract the first word of "strip", so it can be a program name with args.
3243 set dummy strip; ac_word=$2
3244 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3245 $as_echo_n "checking for $ac_word... " >&6; }
3246 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
3247   $as_echo_n "(cached) " >&6
3248 else
3249   if test -n "$ac_ct_STRIP"; then
3250   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
3251 else
3252 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3253 for as_dir in $PATH
3254 do
3255   IFS=$as_save_IFS
3256   test -z "$as_dir" && as_dir=.
3257     for ac_exec_ext in '' $ac_executable_extensions; do
3258   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3259     ac_cv_prog_ac_ct_STRIP="strip"
3260     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3261     break 2
3262   fi
3263 done
3264   done
3265 IFS=$as_save_IFS
3266
3267 fi
3268 fi
3269 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
3270 if test -n "$ac_ct_STRIP"; then
3271   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
3272 $as_echo "$ac_ct_STRIP" >&6; }
3273 else
3274   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3275 $as_echo "no" >&6; }
3276 fi
3277
3278   if test "x$ac_ct_STRIP" = x; then
3279     STRIP=":"
3280   else
3281     case $cross_compiling:$ac_tool_warned in
3282 yes:)
3283 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3284 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3285 ac_tool_warned=yes ;;
3286 esac
3287     STRIP=$ac_ct_STRIP
3288   fi
3289 else
3290   STRIP="$ac_cv_prog_STRIP"
3291 fi
3292
3293 fi
3294 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
3295
3296 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
3297 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
3298 if test -z "$MKDIR_P"; then
3299   if ${ac_cv_path_mkdir+:} false; then :
3300   $as_echo_n "(cached) " >&6
3301 else
3302   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3303 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
3304 do
3305   IFS=$as_save_IFS
3306   test -z "$as_dir" && as_dir=.
3307     for ac_prog in mkdir gmkdir; do
3308          for ac_exec_ext in '' $ac_executable_extensions; do
3309            { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
3310            case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
3311              'mkdir (GNU coreutils) '* | \
3312              'mkdir (coreutils) '* | \
3313              'mkdir (fileutils) '4.1*)
3314                ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
3315                break 3;;
3316            esac
3317          done
3318        done
3319   done
3320 IFS=$as_save_IFS
3321
3322 fi
3323
3324   test -d ./--version && rmdir ./--version
3325   if test "${ac_cv_path_mkdir+set}" = set; then
3326     MKDIR_P="$ac_cv_path_mkdir -p"
3327   else
3328     # As a last resort, use the slow shell script.  Don't cache a
3329     # value for MKDIR_P within a source directory, because that will
3330     # break other packages using the cache if that directory is
3331     # removed, or if the value is a relative name.
3332     MKDIR_P="$ac_install_sh -d"
3333   fi
3334 fi
3335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
3336 $as_echo "$MKDIR_P" >&6; }
3337
3338 mkdir_p="$MKDIR_P"
3339 case $mkdir_p in
3340   [\\/$]* | ?:[\\/]*) ;;
3341   */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
3342 esac
3343
3344 for ac_prog in gawk mawk nawk awk
3345 do
3346   # Extract the first word of "$ac_prog", so it can be a program name with args.
3347 set dummy $ac_prog; ac_word=$2
3348 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3349 $as_echo_n "checking for $ac_word... " >&6; }
3350 if ${ac_cv_prog_AWK+:} false; then :
3351   $as_echo_n "(cached) " >&6
3352 else
3353   if test -n "$AWK"; then
3354   ac_cv_prog_AWK="$AWK" # Let the user override the test.
3355 else
3356 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3357 for as_dir in $PATH
3358 do
3359   IFS=$as_save_IFS
3360   test -z "$as_dir" && as_dir=.
3361     for ac_exec_ext in '' $ac_executable_extensions; do
3362   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3363     ac_cv_prog_AWK="$ac_prog"
3364     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3365     break 2
3366   fi
3367 done
3368   done
3369 IFS=$as_save_IFS
3370
3371 fi
3372 fi
3373 AWK=$ac_cv_prog_AWK
3374 if test -n "$AWK"; then
3375   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
3376 $as_echo "$AWK" >&6; }
3377 else
3378   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3379 $as_echo "no" >&6; }
3380 fi
3381
3382
3383   test -n "$AWK" && break
3384 done
3385
3386 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
3387 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
3388 set x ${MAKE-make}
3389 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
3390 if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then :
3391   $as_echo_n "(cached) " >&6
3392 else
3393   cat >conftest.make <<\_ACEOF
3394 SHELL = /bin/sh
3395 all:
3396         @echo '@@@%%%=$(MAKE)=@@@%%%'
3397 _ACEOF
3398 # GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
3399 case `${MAKE-make} -f conftest.make 2>/dev/null` in
3400   *@@@%%%=?*=@@@%%%*)
3401     eval ac_cv_prog_make_${ac_make}_set=yes;;
3402   *)
3403     eval ac_cv_prog_make_${ac_make}_set=no;;
3404 esac
3405 rm -f conftest.make
3406 fi
3407 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
3408   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3409 $as_echo "yes" >&6; }
3410   SET_MAKE=
3411 else
3412   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3413 $as_echo "no" >&6; }
3414   SET_MAKE="MAKE=${MAKE-make}"
3415 fi
3416
3417 rm -rf .tst 2>/dev/null
3418 mkdir .tst 2>/dev/null
3419 if test -d .tst; then
3420   am__leading_dot=.
3421 else
3422   am__leading_dot=_
3423 fi
3424 rmdir .tst 2>/dev/null
3425
3426 if test "`cd $srcdir && pwd`" != "`pwd`"; then
3427   # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
3428   # is not polluted with repeated "-I."
3429   am__isrc=' -I$(srcdir)'
3430   # test to see if srcdir already configured
3431   if test -f $srcdir/config.status; then
3432     as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
3433   fi
3434 fi
3435
3436 # test whether we have cygpath
3437 if test -z "$CYGPATH_W"; then
3438   if (cygpath --version) >/dev/null 2>/dev/null; then
3439     CYGPATH_W='cygpath -w'
3440   else
3441     CYGPATH_W=echo
3442   fi
3443 fi
3444
3445
3446 # Define the identity of the package.
3447  PACKAGE='sntp'
3448  VERSION='4.2.8p2'
3449
3450
3451 cat >>confdefs.h <<_ACEOF
3452 #define PACKAGE "$PACKAGE"
3453 _ACEOF
3454
3455
3456 cat >>confdefs.h <<_ACEOF
3457 #define VERSION "$VERSION"
3458 _ACEOF
3459
3460 # Some tools Automake needs.
3461
3462 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
3463
3464
3465 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
3466
3467
3468 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
3469
3470
3471 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
3472
3473
3474 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
3475
3476 # We need awk for the "check" target.  The system "awk" is bad on
3477 # some platforms.
3478 # Always define AMTAR for backward compatibility.
3479
3480 AMTAR=${AMTAR-"${am_missing_run}tar"}
3481
3482 am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
3483
3484
3485
3486
3487
3488 # Check whether --enable-silent-rules was given.
3489 if test "${enable_silent_rules+set}" = set; then :
3490   enableval=$enable_silent_rules;
3491 fi
3492
3493 case $enable_silent_rules in
3494 yes) AM_DEFAULT_VERBOSITY=0;;
3495 no)  AM_DEFAULT_VERBOSITY=1;;
3496 *)   AM_DEFAULT_VERBOSITY=0;;
3497 esac
3498 AM_BACKSLASH='\'
3499
3500
3501 # Make sure we can run config.sub.
3502 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
3503   as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
3504
3505 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
3506 $as_echo_n "checking build system type... " >&6; }
3507 if ${ac_cv_build+:} false; then :
3508   $as_echo_n "(cached) " >&6
3509 else
3510   ac_build_alias=$build_alias
3511 test "x$ac_build_alias" = x &&
3512   ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
3513 test "x$ac_build_alias" = x &&
3514   as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
3515 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
3516   as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
3517
3518 fi
3519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
3520 $as_echo "$ac_cv_build" >&6; }
3521 case $ac_cv_build in
3522 *-*-*) ;;
3523 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
3524 esac
3525 build=$ac_cv_build
3526 ac_save_IFS=$IFS; IFS='-'
3527 set x $ac_cv_build
3528 shift
3529 build_cpu=$1
3530 build_vendor=$2
3531 shift; shift
3532 # Remember, the first character of IFS is used to create $*,
3533 # except with old shells:
3534 build_os=$*
3535 IFS=$ac_save_IFS
3536 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
3537
3538
3539 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
3540 $as_echo_n "checking host system type... " >&6; }
3541 if ${ac_cv_host+:} false; then :
3542   $as_echo_n "(cached) " >&6
3543 else
3544   if test "x$host_alias" = x; then
3545   ac_cv_host=$ac_cv_build
3546 else
3547   ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
3548     as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
3549 fi
3550
3551 fi
3552 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
3553 $as_echo "$ac_cv_host" >&6; }
3554 case $ac_cv_host in
3555 *-*-*) ;;
3556 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
3557 esac
3558 host=$ac_cv_host
3559 ac_save_IFS=$IFS; IFS='-'
3560 set x $ac_cv_host
3561 shift
3562 host_cpu=$1
3563 host_vendor=$2
3564 shift; shift
3565 # Remember, the first character of IFS is used to create $*,
3566 # except with old shells:
3567 host_os=$*
3568 IFS=$ac_save_IFS
3569 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
3570
3571
3572
3573 cat >>confdefs.h <<_ACEOF
3574 #define STR_SYSTEM "$host"
3575 _ACEOF
3576
3577 ac_config_headers="$ac_config_headers config.h"
3578
3579
3580 DEPDIR="${am__leading_dot}deps"
3581
3582 ac_config_commands="$ac_config_commands depfiles"
3583
3584
3585 am_make=${MAKE-make}
3586 cat > confinc << 'END'
3587 am__doit:
3588         @echo this is the am__doit target
3589 .PHONY: am__doit
3590 END
3591 # If we don't find an include directive, just comment out the code.
3592 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
3593 $as_echo_n "checking for style of include used by $am_make... " >&6; }
3594 am__include="#"
3595 am__quote=
3596 _am_result=none
3597 # First try GNU make style include.
3598 echo "include confinc" > confmf
3599 # Ignore all kinds of additional output from `make'.
3600 case `$am_make -s -f confmf 2> /dev/null` in #(
3601 *the\ am__doit\ target*)
3602   am__include=include
3603   am__quote=
3604   _am_result=GNU
3605   ;;
3606 esac
3607 # Now try BSD make style include.
3608 if test "$am__include" = "#"; then
3609    echo '.include "confinc"' > confmf
3610    case `$am_make -s -f confmf 2> /dev/null` in #(
3611    *the\ am__doit\ target*)
3612      am__include=.include
3613      am__quote="\""
3614      _am_result=BSD
3615      ;;
3616    esac
3617 fi
3618
3619
3620 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
3621 $as_echo "$_am_result" >&6; }
3622 rm -f confinc confmf
3623
3624 # Check whether --enable-dependency-tracking was given.
3625 if test "${enable_dependency_tracking+set}" = set; then :
3626   enableval=$enable_dependency_tracking;
3627 fi
3628
3629 if test "x$enable_dependency_tracking" != xno; then
3630   am_depcomp="$ac_aux_dir/depcomp"
3631   AMDEPBACKSLASH='\'
3632 fi
3633  if test "x$enable_dependency_tracking" != xno; then
3634   AMDEP_TRUE=
3635   AMDEP_FALSE='#'
3636 else
3637   AMDEP_TRUE='#'
3638   AMDEP_FALSE=
3639 fi
3640
3641
3642 ac_ext=c
3643 ac_cpp='$CPP $CPPFLAGS'
3644 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3645 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3646 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3647 if test -n "$ac_tool_prefix"; then
3648   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
3649 set dummy ${ac_tool_prefix}gcc; ac_word=$2
3650 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3651 $as_echo_n "checking for $ac_word... " >&6; }
3652 if ${ac_cv_prog_CC+:} false; then :
3653   $as_echo_n "(cached) " >&6
3654 else
3655   if test -n "$CC"; then
3656   ac_cv_prog_CC="$CC" # Let the user override the test.
3657 else
3658 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3659 for as_dir in $PATH
3660 do
3661   IFS=$as_save_IFS
3662   test -z "$as_dir" && as_dir=.
3663     for ac_exec_ext in '' $ac_executable_extensions; do
3664   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3665     ac_cv_prog_CC="${ac_tool_prefix}gcc"
3666     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3667     break 2
3668   fi
3669 done
3670   done
3671 IFS=$as_save_IFS
3672
3673 fi
3674 fi
3675 CC=$ac_cv_prog_CC
3676 if test -n "$CC"; then
3677   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3678 $as_echo "$CC" >&6; }
3679 else
3680   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3681 $as_echo "no" >&6; }
3682 fi
3683
3684
3685 fi
3686 if test -z "$ac_cv_prog_CC"; then
3687   ac_ct_CC=$CC
3688   # Extract the first word of "gcc", so it can be a program name with args.
3689 set dummy gcc; ac_word=$2
3690 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3691 $as_echo_n "checking for $ac_word... " >&6; }
3692 if ${ac_cv_prog_ac_ct_CC+:} false; then :
3693   $as_echo_n "(cached) " >&6
3694 else
3695   if test -n "$ac_ct_CC"; then
3696   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3697 else
3698 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3699 for as_dir in $PATH
3700 do
3701   IFS=$as_save_IFS
3702   test -z "$as_dir" && as_dir=.
3703     for ac_exec_ext in '' $ac_executable_extensions; do
3704   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3705     ac_cv_prog_ac_ct_CC="gcc"
3706     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3707     break 2
3708   fi
3709 done
3710   done
3711 IFS=$as_save_IFS
3712
3713 fi
3714 fi
3715 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3716 if test -n "$ac_ct_CC"; then
3717   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3718 $as_echo "$ac_ct_CC" >&6; }
3719 else
3720   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3721 $as_echo "no" >&6; }
3722 fi
3723
3724   if test "x$ac_ct_CC" = x; then
3725     CC=""
3726   else
3727     case $cross_compiling:$ac_tool_warned in
3728 yes:)
3729 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3730 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3731 ac_tool_warned=yes ;;
3732 esac
3733     CC=$ac_ct_CC
3734   fi
3735 else
3736   CC="$ac_cv_prog_CC"
3737 fi
3738
3739 if test -z "$CC"; then
3740           if test -n "$ac_tool_prefix"; then
3741     # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
3742 set dummy ${ac_tool_prefix}cc; ac_word=$2
3743 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3744 $as_echo_n "checking for $ac_word... " >&6; }
3745 if ${ac_cv_prog_CC+:} false; then :
3746   $as_echo_n "(cached) " >&6
3747 else
3748   if test -n "$CC"; then
3749   ac_cv_prog_CC="$CC" # Let the user override the test.
3750 else
3751 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3752 for as_dir in $PATH
3753 do
3754   IFS=$as_save_IFS
3755   test -z "$as_dir" && as_dir=.
3756     for ac_exec_ext in '' $ac_executable_extensions; do
3757   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3758     ac_cv_prog_CC="${ac_tool_prefix}cc"
3759     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3760     break 2
3761   fi
3762 done
3763   done
3764 IFS=$as_save_IFS
3765
3766 fi
3767 fi
3768 CC=$ac_cv_prog_CC
3769 if test -n "$CC"; then
3770   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3771 $as_echo "$CC" >&6; }
3772 else
3773   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3774 $as_echo "no" >&6; }
3775 fi
3776
3777
3778   fi
3779 fi
3780 if test -z "$CC"; then
3781   # Extract the first word of "cc", so it can be a program name with args.
3782 set dummy cc; ac_word=$2
3783 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3784 $as_echo_n "checking for $ac_word... " >&6; }
3785 if ${ac_cv_prog_CC+:} false; then :
3786   $as_echo_n "(cached) " >&6
3787 else
3788   if test -n "$CC"; then
3789   ac_cv_prog_CC="$CC" # Let the user override the test.
3790 else
3791   ac_prog_rejected=no
3792 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3793 for as_dir in $PATH
3794 do
3795   IFS=$as_save_IFS
3796   test -z "$as_dir" && as_dir=.
3797     for ac_exec_ext in '' $ac_executable_extensions; do
3798   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3799     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
3800        ac_prog_rejected=yes
3801        continue
3802      fi
3803     ac_cv_prog_CC="cc"
3804     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3805     break 2
3806   fi
3807 done
3808   done
3809 IFS=$as_save_IFS
3810
3811 if test $ac_prog_rejected = yes; then
3812   # We found a bogon in the path, so make sure we never use it.
3813   set dummy $ac_cv_prog_CC
3814   shift
3815   if test $# != 0; then
3816     # We chose a different compiler from the bogus one.
3817     # However, it has the same basename, so the bogon will be chosen
3818     # first if we set CC to just the basename; use the full file name.
3819     shift
3820     ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
3821   fi
3822 fi
3823 fi
3824 fi
3825 CC=$ac_cv_prog_CC
3826 if test -n "$CC"; then
3827   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3828 $as_echo "$CC" >&6; }
3829 else
3830   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3831 $as_echo "no" >&6; }
3832 fi
3833
3834
3835 fi
3836 if test -z "$CC"; then
3837   if test -n "$ac_tool_prefix"; then
3838   for ac_prog in cl.exe
3839   do
3840     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3841 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3842 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3843 $as_echo_n "checking for $ac_word... " >&6; }
3844 if ${ac_cv_prog_CC+:} false; then :
3845   $as_echo_n "(cached) " >&6
3846 else
3847   if test -n "$CC"; then
3848   ac_cv_prog_CC="$CC" # Let the user override the test.
3849 else
3850 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3851 for as_dir in $PATH
3852 do
3853   IFS=$as_save_IFS
3854   test -z "$as_dir" && as_dir=.
3855     for ac_exec_ext in '' $ac_executable_extensions; do
3856   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3857     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3858     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3859     break 2
3860   fi
3861 done
3862   done
3863 IFS=$as_save_IFS
3864
3865 fi
3866 fi
3867 CC=$ac_cv_prog_CC
3868 if test -n "$CC"; then
3869   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
3870 $as_echo "$CC" >&6; }
3871 else
3872   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3873 $as_echo "no" >&6; }
3874 fi
3875
3876
3877     test -n "$CC" && break
3878   done
3879 fi
3880 if test -z "$CC"; then
3881   ac_ct_CC=$CC
3882   for ac_prog in cl.exe
3883 do
3884   # Extract the first word of "$ac_prog", so it can be a program name with args.
3885 set dummy $ac_prog; ac_word=$2
3886 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3887 $as_echo_n "checking for $ac_word... " >&6; }
3888 if ${ac_cv_prog_ac_ct_CC+:} false; then :
3889   $as_echo_n "(cached) " >&6
3890 else
3891   if test -n "$ac_ct_CC"; then
3892   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3893 else
3894 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3895 for as_dir in $PATH
3896 do
3897   IFS=$as_save_IFS
3898   test -z "$as_dir" && as_dir=.
3899     for ac_exec_ext in '' $ac_executable_extensions; do
3900   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3901     ac_cv_prog_ac_ct_CC="$ac_prog"
3902     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3903     break 2
3904   fi
3905 done
3906   done
3907 IFS=$as_save_IFS
3908
3909 fi
3910 fi
3911 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3912 if test -n "$ac_ct_CC"; then
3913   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
3914 $as_echo "$ac_ct_CC" >&6; }
3915 else
3916   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3917 $as_echo "no" >&6; }
3918 fi
3919
3920
3921   test -n "$ac_ct_CC" && break
3922 done
3923
3924   if test "x$ac_ct_CC" = x; then
3925     CC=""
3926   else
3927     case $cross_compiling:$ac_tool_warned in
3928 yes:)
3929 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3930 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3931 ac_tool_warned=yes ;;
3932 esac
3933     CC=$ac_ct_CC
3934   fi
3935 fi
3936
3937 fi
3938
3939
3940 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3941 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3942 as_fn_error $? "no acceptable C compiler found in \$PATH
3943 See \`config.log' for more details" "$LINENO" 5; }
3944
3945 # Provide some information about the compiler.
3946 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
3947 set X $ac_compile
3948 ac_compiler=$2
3949 for ac_option in --version -v -V -qversion; do
3950   { { ac_try="$ac_compiler $ac_option >&5"
3951 case "(($ac_try" in
3952   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3953   *) ac_try_echo=$ac_try;;
3954 esac
3955 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3956 $as_echo "$ac_try_echo"; } >&5
3957   (eval "$ac_compiler $ac_option >&5") 2>conftest.err
3958   ac_status=$?
3959   if test -s conftest.err; then
3960     sed '10a\
3961 ... rest of stderr output deleted ...
3962          10q' conftest.err >conftest.er1
3963     cat conftest.er1 >&5
3964   fi
3965   rm -f conftest.er1 conftest.err
3966   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3967   test $ac_status = 0; }
3968 done
3969
3970 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3971 /* end confdefs.h.  */
3972
3973 int
3974 main ()
3975 {
3976
3977   ;
3978   return 0;
3979 }
3980 _ACEOF
3981 ac_clean_files_save=$ac_clean_files
3982 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
3983 # Try to create an executable without -o first, disregard a.out.
3984 # It will help us diagnose broken compilers, and finding out an intuition
3985 # of exeext.
3986 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
3987 $as_echo_n "checking whether the C compiler works... " >&6; }
3988 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3989
3990 # The possible output files:
3991 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3992
3993 ac_rmfiles=
3994 for ac_file in $ac_files
3995 do
3996   case $ac_file in
3997     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3998     * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3999   esac
4000 done
4001 rm -f $ac_rmfiles
4002
4003 if { { ac_try="$ac_link_default"
4004 case "(($ac_try" in
4005   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4006   *) ac_try_echo=$ac_try;;
4007 esac
4008 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4009 $as_echo "$ac_try_echo"; } >&5
4010   (eval "$ac_link_default") 2>&5
4011   ac_status=$?
4012   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4013   test $ac_status = 0; }; then :
4014   # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
4015 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
4016 # in a Makefile.  We should not override ac_cv_exeext if it was cached,
4017 # so that the user can short-circuit this test for compilers unknown to
4018 # Autoconf.
4019 for ac_file in $ac_files ''
4020 do
4021   test -f "$ac_file" || continue
4022   case $ac_file in
4023     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
4024         ;;
4025     [ab].out )
4026         # We found the default executable, but exeext='' is most
4027         # certainly right.
4028         break;;
4029     *.* )
4030         if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
4031         then :; else
4032            ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4033         fi
4034         # We set ac_cv_exeext here because the later test for it is not
4035         # safe: cross compilers may not add the suffix if given an `-o'
4036         # argument, so we may need to know it at that point already.
4037         # Even if this section looks crufty: it has the advantage of
4038         # actually working.
4039         break;;
4040     * )
4041         break;;
4042   esac
4043 done
4044 test "$ac_cv_exeext" = no && ac_cv_exeext=
4045
4046 else
4047   ac_file=''
4048 fi
4049 if test -z "$ac_file"; then :
4050   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4051 $as_echo "no" >&6; }
4052 $as_echo "$as_me: failed program was:" >&5
4053 sed 's/^/| /' conftest.$ac_ext >&5
4054
4055 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4056 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4057 as_fn_error 77 "C compiler cannot create executables
4058 See \`config.log' for more details" "$LINENO" 5; }
4059 else
4060   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4061 $as_echo "yes" >&6; }
4062 fi
4063 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
4064 $as_echo_n "checking for C compiler default output file name... " >&6; }
4065 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
4066 $as_echo "$ac_file" >&6; }
4067 ac_exeext=$ac_cv_exeext
4068
4069 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
4070 ac_clean_files=$ac_clean_files_save
4071 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
4072 $as_echo_n "checking for suffix of executables... " >&6; }
4073 if { { ac_try="$ac_link"
4074 case "(($ac_try" in
4075   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4076   *) ac_try_echo=$ac_try;;
4077 esac
4078 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4079 $as_echo "$ac_try_echo"; } >&5
4080   (eval "$ac_link") 2>&5
4081   ac_status=$?
4082   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4083   test $ac_status = 0; }; then :
4084   # If both `conftest.exe' and `conftest' are `present' (well, observable)
4085 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
4086 # work properly (i.e., refer to `conftest.exe'), while it won't with
4087 # `rm'.
4088 for ac_file in conftest.exe conftest conftest.*; do
4089   test -f "$ac_file" || continue
4090   case $ac_file in
4091     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4092     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4093           break;;
4094     * ) break;;
4095   esac
4096 done
4097 else
4098   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4099 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4100 as_fn_error $? "cannot compute suffix of executables: cannot compile and link
4101 See \`config.log' for more details" "$LINENO" 5; }
4102 fi
4103 rm -f conftest conftest$ac_cv_exeext
4104 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
4105 $as_echo "$ac_cv_exeext" >&6; }
4106
4107 rm -f conftest.$ac_ext
4108 EXEEXT=$ac_cv_exeext
4109 ac_exeext=$EXEEXT
4110 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4111 /* end confdefs.h.  */
4112 #include <stdio.h>
4113 int
4114 main ()
4115 {
4116 FILE *f = fopen ("conftest.out", "w");
4117  return ferror (f) || fclose (f) != 0;
4118
4119   ;
4120   return 0;
4121 }
4122 _ACEOF
4123 ac_clean_files="$ac_clean_files conftest.out"
4124 # Check that the compiler produces executables we can run.  If not, either
4125 # the compiler is broken, or we cross compile.
4126 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
4127 $as_echo_n "checking whether we are cross compiling... " >&6; }
4128 if test "$cross_compiling" != yes; then
4129   { { ac_try="$ac_link"
4130 case "(($ac_try" in
4131   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4132   *) ac_try_echo=$ac_try;;
4133 esac
4134 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4135 $as_echo "$ac_try_echo"; } >&5
4136   (eval "$ac_link") 2>&5
4137   ac_status=$?
4138   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4139   test $ac_status = 0; }
4140   if { ac_try='./conftest$ac_cv_exeext'
4141   { { case "(($ac_try" in
4142   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4143   *) ac_try_echo=$ac_try;;
4144 esac
4145 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4146 $as_echo "$ac_try_echo"; } >&5
4147   (eval "$ac_try") 2>&5
4148   ac_status=$?
4149   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4150   test $ac_status = 0; }; }; then
4151     cross_compiling=no
4152   else
4153     if test "$cross_compiling" = maybe; then
4154         cross_compiling=yes
4155     else
4156         { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4157 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4158 as_fn_error $? "cannot run C compiled programs.
4159 If you meant to cross compile, use \`--host'.
4160 See \`config.log' for more details" "$LINENO" 5; }
4161     fi
4162   fi
4163 fi
4164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
4165 $as_echo "$cross_compiling" >&6; }
4166
4167 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
4168 ac_clean_files=$ac_clean_files_save
4169 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
4170 $as_echo_n "checking for suffix of object files... " >&6; }
4171 if ${ac_cv_objext+:} false; then :
4172   $as_echo_n "(cached) " >&6
4173 else
4174   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4175 /* end confdefs.h.  */
4176
4177 int
4178 main ()
4179 {
4180
4181   ;
4182   return 0;
4183 }
4184 _ACEOF
4185 rm -f conftest.o conftest.obj
4186 if { { ac_try="$ac_compile"
4187 case "(($ac_try" in
4188   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4189   *) ac_try_echo=$ac_try;;
4190 esac
4191 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4192 $as_echo "$ac_try_echo"; } >&5
4193   (eval "$ac_compile") 2>&5
4194   ac_status=$?
4195   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4196   test $ac_status = 0; }; then :
4197   for ac_file in conftest.o conftest.obj conftest.*; do
4198   test -f "$ac_file" || continue;
4199   case $ac_file in
4200     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
4201     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
4202        break;;
4203   esac
4204 done
4205 else
4206   $as_echo "$as_me: failed program was:" >&5
4207 sed 's/^/| /' conftest.$ac_ext >&5
4208
4209 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4210 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4211 as_fn_error $? "cannot compute suffix of object files: cannot compile
4212 See \`config.log' for more details" "$LINENO" 5; }
4213 fi
4214 rm -f conftest.$ac_cv_objext conftest.$ac_ext
4215 fi
4216 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
4217 $as_echo "$ac_cv_objext" >&6; }
4218 OBJEXT=$ac_cv_objext
4219 ac_objext=$OBJEXT
4220 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
4221 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
4222 if ${ac_cv_c_compiler_gnu+:} false; then :
4223   $as_echo_n "(cached) " >&6
4224 else
4225   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4226 /* end confdefs.h.  */
4227
4228 int
4229 main ()
4230 {
4231 #ifndef __GNUC__
4232        choke me
4233 #endif
4234
4235   ;
4236   return 0;
4237 }
4238 _ACEOF
4239 if ac_fn_c_try_compile "$LINENO"; then :
4240   ac_compiler_gnu=yes
4241 else
4242   ac_compiler_gnu=no
4243 fi
4244 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4245 ac_cv_c_compiler_gnu=$ac_compiler_gnu
4246
4247 fi
4248 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
4249 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
4250 if test $ac_compiler_gnu = yes; then
4251   GCC=yes
4252 else
4253   GCC=
4254 fi
4255 ac_test_CFLAGS=${CFLAGS+set}
4256 ac_save_CFLAGS=$CFLAGS
4257 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
4258 $as_echo_n "checking whether $CC accepts -g... " >&6; }
4259 if ${ac_cv_prog_cc_g+:} false; then :
4260   $as_echo_n "(cached) " >&6
4261 else
4262   ac_save_c_werror_flag=$ac_c_werror_flag
4263    ac_c_werror_flag=yes
4264    ac_cv_prog_cc_g=no
4265    CFLAGS="-g"
4266    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4267 /* end confdefs.h.  */
4268
4269 int
4270 main ()
4271 {
4272
4273   ;
4274   return 0;
4275 }
4276 _ACEOF
4277 if ac_fn_c_try_compile "$LINENO"; then :
4278   ac_cv_prog_cc_g=yes
4279 else
4280   CFLAGS=""
4281       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4282 /* end confdefs.h.  */
4283
4284 int
4285 main ()
4286 {
4287
4288   ;
4289   return 0;
4290 }
4291 _ACEOF
4292 if ac_fn_c_try_compile "$LINENO"; then :
4293
4294 else
4295   ac_c_werror_flag=$ac_save_c_werror_flag
4296          CFLAGS="-g"
4297          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4298 /* end confdefs.h.  */
4299
4300 int
4301 main ()
4302 {
4303
4304   ;
4305   return 0;
4306 }
4307 _ACEOF
4308 if ac_fn_c_try_compile "$LINENO"; then :
4309   ac_cv_prog_cc_g=yes
4310 fi
4311 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4312 fi
4313 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4314 fi
4315 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4316    ac_c_werror_flag=$ac_save_c_werror_flag
4317 fi
4318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
4319 $as_echo "$ac_cv_prog_cc_g" >&6; }
4320 if test "$ac_test_CFLAGS" = set; then
4321   CFLAGS=$ac_save_CFLAGS
4322 elif test $ac_cv_prog_cc_g = yes; then
4323   if test "$GCC" = yes; then
4324     CFLAGS="-g -O2"
4325   else
4326     CFLAGS="-g"
4327   fi
4328 else
4329   if test "$GCC" = yes; then
4330     CFLAGS="-O2"
4331   else
4332     CFLAGS=
4333   fi
4334 fi
4335 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
4336 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
4337 if ${ac_cv_prog_cc_c89+:} false; then :
4338   $as_echo_n "(cached) " >&6
4339 else
4340   ac_cv_prog_cc_c89=no
4341 ac_save_CC=$CC
4342 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4343 /* end confdefs.h.  */
4344 #include <stdarg.h>
4345 #include <stdio.h>
4346 #include <sys/types.h>
4347 #include <sys/stat.h>
4348 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
4349 struct buf { int x; };
4350 FILE * (*rcsopen) (struct buf *, struct stat *, int);
4351 static char *e (p, i)
4352      char **p;
4353      int i;
4354 {
4355   return p[i];
4356 }
4357 static char *f (char * (*g) (char **, int), char **p, ...)
4358 {
4359   char *s;
4360   va_list v;
4361   va_start (v,p);
4362   s = g (p, va_arg (v,int));
4363   va_end (v);
4364   return s;
4365 }
4366
4367 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
4368    function prototypes and stuff, but not '\xHH' hex character constants.
4369    These don't provoke an error unfortunately, instead are silently treated
4370    as 'x'.  The following induces an error, until -std is added to get
4371    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
4372    array size at least.  It's necessary to write '\x00'==0 to get something
4373    that's true only with -std.  */
4374 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
4375
4376 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
4377    inside strings and character constants.  */
4378 #define FOO(x) 'x'
4379 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
4380
4381 int test (int i, double x);
4382 struct s1 {int (*f) (int a);};
4383 struct s2 {int (*f) (double a);};
4384 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
4385 int argc;
4386 char **argv;
4387 int
4388 main ()
4389 {
4390 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
4391   ;
4392   return 0;
4393 }
4394 _ACEOF
4395 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
4396         -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4397 do
4398   CC="$ac_save_CC $ac_arg"
4399   if ac_fn_c_try_compile "$LINENO"; then :
4400   ac_cv_prog_cc_c89=$ac_arg
4401 fi
4402 rm -f core conftest.err conftest.$ac_objext
4403   test "x$ac_cv_prog_cc_c89" != "xno" && break
4404 done
4405 rm -f conftest.$ac_ext
4406 CC=$ac_save_CC
4407
4408 fi
4409 # AC_CACHE_VAL
4410 case "x$ac_cv_prog_cc_c89" in
4411   x)
4412     { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4413 $as_echo "none needed" >&6; } ;;
4414   xno)
4415     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4416 $as_echo "unsupported" >&6; } ;;
4417   *)
4418     CC="$CC $ac_cv_prog_cc_c89"
4419     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
4420 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
4421 esac
4422 if test "x$ac_cv_prog_cc_c89" != xno; then :
4423
4424 fi
4425
4426 ac_ext=c
4427 ac_cpp='$CPP $CPPFLAGS'
4428 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4429 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4430 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4431
4432 depcc="$CC"   am_compiler_list=
4433
4434 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
4435 $as_echo_n "checking dependency style of $depcc... " >&6; }
4436 if ${am_cv_CC_dependencies_compiler_type+:} false; then :
4437   $as_echo_n "(cached) " >&6
4438 else
4439   if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
4440   # We make a subdir and do the tests there.  Otherwise we can end up
4441   # making bogus files that we don't know about and never remove.  For
4442   # instance it was reported that on HP-UX the gcc test will end up
4443   # making a dummy file named `D' -- because `-MD' means `put the output
4444   # in D'.
4445   mkdir conftest.dir
4446   # Copy depcomp to subdir because otherwise we won't find it if we're
4447   # using a relative directory.
4448   cp "$am_depcomp" conftest.dir
4449   cd conftest.dir
4450   # We will build objects and dependencies in a subdirectory because
4451   # it helps to detect inapplicable dependency modes.  For instance
4452   # both Tru64's cc and ICC support -MD to output dependencies as a
4453   # side effect of compilation, but ICC will put the dependencies in
4454   # the current directory while Tru64 will put them in the object
4455   # directory.
4456   mkdir sub
4457
4458   am_cv_CC_dependencies_compiler_type=none
4459   if test "$am_compiler_list" = ""; then
4460      am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
4461   fi
4462   am__universal=false
4463   case " $depcc " in #(
4464      *\ -arch\ *\ -arch\ *) am__universal=true ;;
4465      esac
4466
4467   for depmode in $am_compiler_list; do
4468     # Setup a source with many dependencies, because some compilers
4469     # like to wrap large dependency lists on column 80 (with \), and
4470     # we should not choose a depcomp mode which is confused by this.
4471     #
4472     # We need to recreate these files for each test, as the compiler may
4473     # overwrite some of them when testing with obscure command lines.
4474     # This happens at least with the AIX C compiler.
4475     : > sub/conftest.c
4476     for i in 1 2 3 4 5 6; do
4477       echo '#include "conftst'$i'.h"' >> sub/conftest.c
4478       # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
4479       # Solaris 8's {/usr,}/bin/sh.
4480       touch sub/conftst$i.h
4481     done
4482     echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
4483
4484     # We check with `-c' and `-o' for the sake of the "dashmstdout"
4485     # mode.  It turns out that the SunPro C++ compiler does not properly
4486     # handle `-M -o', and we need to detect this.  Also, some Intel
4487     # versions had trouble with output in subdirs
4488     am__obj=sub/conftest.${OBJEXT-o}
4489     am__minus_obj="-o $am__obj"
4490     case $depmode in
4491     gcc)
4492       # This depmode causes a compiler race in universal mode.
4493       test "$am__universal" = false || continue
4494       ;;
4495     nosideeffect)
4496       # after this tag, mechanisms are not by side-effect, so they'll
4497       # only be used when explicitly requested
4498       if test "x$enable_dependency_tracking" = xyes; then
4499         continue
4500       else
4501         break
4502       fi
4503       ;;
4504     msvisualcpp | msvcmsys)
4505       # This compiler won't grok `-c -o', but also, the minuso test has
4506       # not run yet.  These depmodes are late enough in the game, and
4507       # so weak that their functioning should not be impacted.
4508       am__obj=conftest.${OBJEXT-o}
4509       am__minus_obj=
4510       ;;
4511     none) break ;;
4512     esac
4513     if depmode=$depmode \
4514        source=sub/conftest.c object=$am__obj \
4515        depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
4516        $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
4517          >/dev/null 2>conftest.err &&
4518        grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
4519        grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
4520        grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
4521        ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
4522       # icc doesn't choke on unknown options, it will just issue warnings
4523       # or remarks (even with -Werror).  So we grep stderr for any message
4524       # that says an option was ignored or not supported.
4525       # When given -MP, icc 7.0 and 7.1 complain thusly:
4526       #   icc: Command line warning: ignoring option '-M'; no argument required
4527       # The diagnosis changed in icc 8.0:
4528       #   icc: Command line remark: option '-MP' not supported
4529       if (grep 'ignoring option' conftest.err ||
4530           grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
4531         am_cv_CC_dependencies_compiler_type=$depmode
4532         break
4533       fi
4534     fi
4535   done
4536
4537   cd ..
4538   rm -rf conftest.dir
4539 else
4540   am_cv_CC_dependencies_compiler_type=none
4541 fi
4542
4543 fi
4544 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
4545 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
4546 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
4547
4548  if
4549   test "x$enable_dependency_tracking" != xno \
4550   && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
4551   am__fastdepCC_TRUE=
4552   am__fastdepCC_FALSE='#'
4553 else
4554   am__fastdepCC_TRUE='#'
4555   am__fastdepCC_FALSE=
4556 fi
4557
4558
4559
4560 ac_ext=c
4561 ac_cpp='$CPP $CPPFLAGS'
4562 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4563 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4564 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4565 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
4566 $as_echo_n "checking how to run the C preprocessor... " >&6; }
4567 # On Suns, sometimes $CPP names a directory.
4568 if test -n "$CPP" && test -d "$CPP"; then
4569   CPP=
4570 fi
4571 if test -z "$CPP"; then
4572   if ${ac_cv_prog_CPP+:} false; then :
4573   $as_echo_n "(cached) " >&6
4574 else
4575       # Double quotes because CPP needs to be expanded
4576     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
4577     do
4578       ac_preproc_ok=false
4579 for ac_c_preproc_warn_flag in '' yes
4580 do
4581   # Use a header file that comes with gcc, so configuring glibc
4582   # with a fresh cross-compiler works.
4583   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4584   # <limits.h> exists even on freestanding compilers.
4585   # On the NeXT, cc -E runs the code through the compiler's parser,
4586   # not just through cpp. "Syntax error" is here to catch this case.
4587   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4588 /* end confdefs.h.  */
4589 #ifdef __STDC__
4590 # include <limits.h>
4591 #else
4592 # include <assert.h>
4593 #endif
4594                      Syntax error
4595 _ACEOF
4596 if ac_fn_c_try_cpp "$LINENO"; then :
4597
4598 else
4599   # Broken: fails on valid input.
4600 continue
4601 fi
4602 rm -f conftest.err conftest.i conftest.$ac_ext
4603
4604   # OK, works on sane cases.  Now check whether nonexistent headers
4605   # can be detected and how.
4606   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4607 /* end confdefs.h.  */
4608 #include <ac_nonexistent.h>
4609 _ACEOF
4610 if ac_fn_c_try_cpp "$LINENO"; then :
4611   # Broken: success on invalid input.
4612 continue
4613 else
4614   # Passes both tests.
4615 ac_preproc_ok=:
4616 break
4617 fi
4618 rm -f conftest.err conftest.i conftest.$ac_ext
4619
4620 done
4621 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4622 rm -f conftest.i conftest.err conftest.$ac_ext
4623 if $ac_preproc_ok; then :
4624   break
4625 fi
4626
4627     done
4628     ac_cv_prog_CPP=$CPP
4629
4630 fi
4631   CPP=$ac_cv_prog_CPP
4632 else
4633   ac_cv_prog_CPP=$CPP
4634 fi
4635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
4636 $as_echo "$CPP" >&6; }
4637 ac_preproc_ok=false
4638 for ac_c_preproc_warn_flag in '' yes
4639 do
4640   # Use a header file that comes with gcc, so configuring glibc
4641   # with a fresh cross-compiler works.
4642   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4643   # <limits.h> exists even on freestanding compilers.
4644   # On the NeXT, cc -E runs the code through the compiler's parser,
4645   # not just through cpp. "Syntax error" is here to catch this case.
4646   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4647 /* end confdefs.h.  */
4648 #ifdef __STDC__
4649 # include <limits.h>
4650 #else
4651 # include <assert.h>
4652 #endif
4653                      Syntax error
4654 _ACEOF
4655 if ac_fn_c_try_cpp "$LINENO"; then :
4656
4657 else
4658   # Broken: fails on valid input.
4659 continue
4660 fi
4661 rm -f conftest.err conftest.i conftest.$ac_ext
4662
4663   # OK, works on sane cases.  Now check whether nonexistent headers
4664   # can be detected and how.
4665   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4666 /* end confdefs.h.  */
4667 #include <ac_nonexistent.h>
4668 _ACEOF
4669 if ac_fn_c_try_cpp "$LINENO"; then :
4670   # Broken: success on invalid input.
4671 continue
4672 else
4673   # Passes both tests.
4674 ac_preproc_ok=:
4675 break
4676 fi
4677 rm -f conftest.err conftest.i conftest.$ac_ext
4678
4679 done
4680 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4681 rm -f conftest.i conftest.err conftest.$ac_ext
4682 if $ac_preproc_ok; then :
4683
4684 else
4685   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4686 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4687 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
4688 See \`config.log' for more details" "$LINENO" 5; }
4689 fi
4690
4691 ac_ext=c
4692 ac_cpp='$CPP $CPPFLAGS'
4693 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4694 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4695 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4696
4697
4698 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
4699 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
4700 if ${ac_cv_path_GREP+:} false; then :
4701   $as_echo_n "(cached) " >&6
4702 else
4703   if test -z "$GREP"; then
4704   ac_path_GREP_found=false
4705   # Loop through the user's path and test for each of PROGNAME-LIST
4706   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4707 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4708 do
4709   IFS=$as_save_IFS
4710   test -z "$as_dir" && as_dir=.
4711     for ac_prog in grep ggrep; do
4712     for ac_exec_ext in '' $ac_executable_extensions; do
4713       ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
4714       { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
4715 # Check for GNU ac_path_GREP and select it if it is found.
4716   # Check for GNU $ac_path_GREP
4717 case `"$ac_path_GREP" --version 2>&1` in
4718 *GNU*)
4719   ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
4720 *)
4721   ac_count=0
4722   $as_echo_n 0123456789 >"conftest.in"
4723   while :
4724   do
4725     cat "conftest.in" "conftest.in" >"conftest.tmp"
4726     mv "conftest.tmp" "conftest.in"
4727     cp "conftest.in" "conftest.nl"
4728     $as_echo 'GREP' >> "conftest.nl"
4729     "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4730     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4731     as_fn_arith $ac_count + 1 && ac_count=$as_val
4732     if test $ac_count -gt ${ac_path_GREP_max-0}; then
4733       # Best one so far, save it but keep looking for a better one
4734       ac_cv_path_GREP="$ac_path_GREP"
4735       ac_path_GREP_max=$ac_count
4736     fi
4737     # 10*(2^10) chars as input seems more than enough
4738     test $ac_count -gt 10 && break
4739   done
4740   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4741 esac
4742
4743       $ac_path_GREP_found && break 3
4744     done
4745   done
4746   done
4747 IFS=$as_save_IFS
4748   if test -z "$ac_cv_path_GREP"; then
4749     as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4750   fi
4751 else
4752   ac_cv_path_GREP=$GREP
4753 fi
4754
4755 fi
4756 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
4757 $as_echo "$ac_cv_path_GREP" >&6; }
4758  GREP="$ac_cv_path_GREP"
4759
4760
4761 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
4762 $as_echo_n "checking for egrep... " >&6; }
4763 if ${ac_cv_path_EGREP+:} false; then :
4764   $as_echo_n "(cached) " >&6
4765 else
4766   if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
4767    then ac_cv_path_EGREP="$GREP -E"
4768    else
4769      if test -z "$EGREP"; then
4770   ac_path_EGREP_found=false
4771   # Loop through the user's path and test for each of PROGNAME-LIST
4772   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4773 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4774 do
4775   IFS=$as_save_IFS
4776   test -z "$as_dir" && as_dir=.
4777     for ac_prog in egrep; do
4778     for ac_exec_ext in '' $ac_executable_extensions; do
4779       ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
4780       { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
4781 # Check for GNU ac_path_EGREP and select it if it is found.
4782   # Check for GNU $ac_path_EGREP
4783 case `"$ac_path_EGREP" --version 2>&1` in
4784 *GNU*)
4785   ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
4786 *)
4787   ac_count=0
4788   $as_echo_n 0123456789 >"conftest.in"
4789   while :
4790   do
4791     cat "conftest.in" "conftest.in" >"conftest.tmp"
4792     mv "conftest.tmp" "conftest.in"
4793     cp "conftest.in" "conftest.nl"
4794     $as_echo 'EGREP' >> "conftest.nl"
4795     "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4796     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4797     as_fn_arith $ac_count + 1 && ac_count=$as_val
4798     if test $ac_count -gt ${ac_path_EGREP_max-0}; then
4799       # Best one so far, save it but keep looking for a better one
4800       ac_cv_path_EGREP="$ac_path_EGREP"
4801       ac_path_EGREP_max=$ac_count
4802     fi
4803     # 10*(2^10) chars as input seems more than enough
4804     test $ac_count -gt 10 && break
4805   done
4806   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4807 esac
4808
4809       $ac_path_EGREP_found && break 3
4810     done
4811   done
4812   done
4813 IFS=$as_save_IFS
4814   if test -z "$ac_cv_path_EGREP"; then
4815     as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4816   fi
4817 else
4818   ac_cv_path_EGREP=$EGREP
4819 fi
4820
4821    fi
4822 fi
4823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
4824 $as_echo "$ac_cv_path_EGREP" >&6; }
4825  EGREP="$ac_cv_path_EGREP"
4826
4827
4828 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
4829 $as_echo_n "checking for ANSI C header files... " >&6; }
4830 if ${ac_cv_header_stdc+:} false; then :
4831   $as_echo_n "(cached) " >&6
4832 else
4833   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4834 /* end confdefs.h.  */
4835 #include <stdlib.h>
4836 #include <stdarg.h>
4837 #include <string.h>
4838 #include <float.h>
4839
4840 int
4841 main ()
4842 {
4843
4844   ;
4845   return 0;
4846 }
4847 _ACEOF
4848 if ac_fn_c_try_compile "$LINENO"; then :
4849   ac_cv_header_stdc=yes
4850 else
4851   ac_cv_header_stdc=no
4852 fi
4853 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4854
4855 if test $ac_cv_header_stdc = yes; then
4856   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
4857   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4858 /* end confdefs.h.  */
4859 #include <string.h>
4860
4861 _ACEOF
4862 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4863   $EGREP "memchr" >/dev/null 2>&1; then :
4864
4865 else
4866   ac_cv_header_stdc=no
4867 fi
4868 rm -f conftest*
4869
4870 fi
4871
4872 if test $ac_cv_header_stdc = yes; then
4873   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
4874   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4875 /* end confdefs.h.  */
4876 #include <stdlib.h>
4877
4878 _ACEOF
4879 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4880   $EGREP "free" >/dev/null 2>&1; then :
4881
4882 else
4883   ac_cv_header_stdc=no
4884 fi
4885 rm -f conftest*
4886
4887 fi
4888
4889 if test $ac_cv_header_stdc = yes; then
4890   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
4891   if test "$cross_compiling" = yes; then :
4892   :
4893 else
4894   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4895 /* end confdefs.h.  */
4896 #include <ctype.h>
4897 #include <stdlib.h>
4898 #if ((' ' & 0x0FF) == 0x020)
4899 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
4900 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
4901 #else
4902 # define ISLOWER(c) \
4903                    (('a' <= (c) && (c) <= 'i') \
4904                      || ('j' <= (c) && (c) <= 'r') \
4905                      || ('s' <= (c) && (c) <= 'z'))
4906 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
4907 #endif
4908
4909 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
4910 int
4911 main ()
4912 {
4913   int i;
4914   for (i = 0; i < 256; i++)
4915     if (XOR (islower (i), ISLOWER (i))
4916         || toupper (i) != TOUPPER (i))
4917       return 2;
4918   return 0;
4919 }
4920 _ACEOF
4921 if ac_fn_c_try_run "$LINENO"; then :
4922
4923 else
4924   ac_cv_header_stdc=no
4925 fi
4926 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4927   conftest.$ac_objext conftest.beam conftest.$ac_ext
4928 fi
4929
4930 fi
4931 fi
4932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
4933 $as_echo "$ac_cv_header_stdc" >&6; }
4934 if test $ac_cv_header_stdc = yes; then
4935
4936 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
4937
4938 fi
4939
4940 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
4941 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
4942                   inttypes.h stdint.h unistd.h
4943 do :
4944   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
4945 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
4946 "
4947 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
4948   cat >>confdefs.h <<_ACEOF
4949 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
4950 _ACEOF
4951
4952 fi
4953
4954 done
4955
4956
4957
4958
4959
4960   ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
4961 if test "x$ac_cv_header_minix_config_h" = xyes; then :
4962   MINIX=yes
4963 else
4964   MINIX=
4965 fi
4966
4967
4968   if test "$MINIX" = yes; then
4969
4970 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
4971
4972
4973 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
4974
4975
4976 $as_echo "#define _MINIX 1" >>confdefs.h
4977
4978   fi
4979
4980         case "$host_os" in
4981     hpux*)
4982
4983 $as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
4984
4985       ;;
4986   esac
4987
4988
4989   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
4990 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
4991 if ${ac_cv_safe_to_define___extensions__+:} false; then :
4992   $as_echo_n "(cached) " >&6
4993 else
4994   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4995 /* end confdefs.h.  */
4996
4997 #         define __EXTENSIONS__ 1
4998           $ac_includes_default
4999 int
5000 main ()
5001 {
5002
5003   ;
5004   return 0;
5005 }
5006 _ACEOF
5007 if ac_fn_c_try_compile "$LINENO"; then :
5008   ac_cv_safe_to_define___extensions__=yes
5009 else
5010   ac_cv_safe_to_define___extensions__=no
5011 fi
5012 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5013 fi
5014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
5015 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
5016   test $ac_cv_safe_to_define___extensions__ = yes &&
5017     $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
5018
5019   $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
5020
5021   $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
5022
5023   $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
5024
5025   $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
5026
5027
5028 if test "x$CC" != xcc; then
5029   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC and cc understand -c and -o together" >&5
5030 $as_echo_n "checking whether $CC and cc understand -c and -o together... " >&6; }
5031 else
5032   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cc understands -c and -o together" >&5
5033 $as_echo_n "checking whether cc understands -c and -o together... " >&6; }
5034 fi
5035 set dummy $CC; ac_cc=`$as_echo "$2" |
5036                       sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5037 if eval \${ac_cv_prog_cc_${ac_cc}_c_o+:} false; then :
5038   $as_echo_n "(cached) " >&6
5039 else
5040   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5041 /* end confdefs.h.  */
5042
5043 int
5044 main ()
5045 {
5046
5047   ;
5048   return 0;
5049 }
5050 _ACEOF
5051 # Make sure it works both with $CC and with simple cc.
5052 # We do the test twice because some compilers refuse to overwrite an
5053 # existing .o file with -o, though they will create one.
5054 ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5055 rm -f conftest2.*
5056 if { { case "(($ac_try" in
5057   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5058   *) ac_try_echo=$ac_try;;
5059 esac
5060 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5061 $as_echo "$ac_try_echo"; } >&5
5062   (eval "$ac_try") 2>&5
5063   ac_status=$?
5064   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5065   test $ac_status = 0; } &&
5066    test -f conftest2.$ac_objext && { { case "(($ac_try" in
5067   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5068   *) ac_try_echo=$ac_try;;
5069 esac
5070 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5071 $as_echo "$ac_try_echo"; } >&5
5072   (eval "$ac_try") 2>&5
5073   ac_status=$?
5074   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5075   test $ac_status = 0; };
5076 then
5077   eval ac_cv_prog_cc_${ac_cc}_c_o=yes
5078   if test "x$CC" != xcc; then
5079     # Test first that cc exists at all.
5080     if { ac_try='cc -c conftest.$ac_ext >&5'
5081   { { case "(($ac_try" in
5082   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5083   *) ac_try_echo=$ac_try;;
5084 esac
5085 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5086 $as_echo "$ac_try_echo"; } >&5
5087   (eval "$ac_try") 2>&5
5088   ac_status=$?
5089   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5090   test $ac_status = 0; }; }; then
5091       ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5092       rm -f conftest2.*
5093       if { { case "(($ac_try" in
5094   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5095   *) ac_try_echo=$ac_try;;
5096 esac
5097 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5098 $as_echo "$ac_try_echo"; } >&5
5099   (eval "$ac_try") 2>&5
5100   ac_status=$?
5101   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5102   test $ac_status = 0; } &&
5103          test -f conftest2.$ac_objext && { { case "(($ac_try" in
5104   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5105   *) ac_try_echo=$ac_try;;
5106 esac
5107 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5108 $as_echo "$ac_try_echo"; } >&5
5109   (eval "$ac_try") 2>&5
5110   ac_status=$?
5111   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5112   test $ac_status = 0; };
5113       then
5114         # cc works too.
5115         :
5116       else
5117         # cc exists but doesn't like -o.
5118         eval ac_cv_prog_cc_${ac_cc}_c_o=no
5119       fi
5120     fi
5121   fi
5122 else
5123   eval ac_cv_prog_cc_${ac_cc}_c_o=no
5124 fi
5125 rm -f core conftest*
5126
5127 fi
5128 if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then
5129   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5130 $as_echo "yes" >&6; }
5131 else
5132   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5133 $as_echo "no" >&6; }
5134
5135 $as_echo "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h
5136
5137 fi
5138
5139    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
5140 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
5141 if ${ac_cv_prog_cc_c89+:} false; then :
5142   $as_echo_n "(cached) " >&6
5143 else
5144   ac_cv_prog_cc_c89=no
5145 ac_save_CC=$CC
5146 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5147 /* end confdefs.h.  */
5148 #include <stdarg.h>
5149 #include <stdio.h>
5150 #include <sys/types.h>
5151 #include <sys/stat.h>
5152 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
5153 struct buf { int x; };
5154 FILE * (*rcsopen) (struct buf *, struct stat *, int);
5155 static char *e (p, i)
5156      char **p;
5157      int i;
5158 {
5159   return p[i];
5160 }
5161 static char *f (char * (*g) (char **, int), char **p, ...)
5162 {
5163   char *s;
5164   va_list v;
5165   va_start (v,p);
5166   s = g (p, va_arg (v,int));
5167   va_end (v);
5168   return s;
5169 }
5170
5171 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
5172    function prototypes and stuff, but not '\xHH' hex character constants.
5173    These don't provoke an error unfortunately, instead are silently treated
5174    as 'x'.  The following induces an error, until -std is added to get
5175    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
5176    array size at least.  It's necessary to write '\x00'==0 to get something
5177    that's true only with -std.  */
5178 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5179
5180 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5181    inside strings and character constants.  */
5182 #define FOO(x) 'x'
5183 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5184
5185 int test (int i, double x);
5186 struct s1 {int (*f) (int a);};
5187 struct s2 {int (*f) (double a);};
5188 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5189 int argc;
5190 char **argv;
5191 int
5192 main ()
5193 {
5194 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
5195   ;
5196   return 0;
5197 }
5198 _ACEOF
5199 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5200         -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5201 do
5202   CC="$ac_save_CC $ac_arg"
5203   if ac_fn_c_try_compile "$LINENO"; then :
5204   ac_cv_prog_cc_c89=$ac_arg
5205 fi
5206 rm -f core conftest.err conftest.$ac_objext
5207   test "x$ac_cv_prog_cc_c89" != "xno" && break
5208 done
5209 rm -f conftest.$ac_ext
5210 CC=$ac_save_CC
5211
5212 fi
5213 # AC_CACHE_VAL
5214 case "x$ac_cv_prog_cc_c89" in
5215   x)
5216     { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5217 $as_echo "none needed" >&6; } ;;
5218   xno)
5219     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5220 $as_echo "unsupported" >&6; } ;;
5221   *)
5222     CC="$CC $ac_cv_prog_cc_c89"
5223     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5224 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
5225 esac
5226 if test "x$ac_cv_prog_cc_c89" != xno; then :
5227
5228 fi
5229
5230
5231    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5
5232 $as_echo_n "checking for $CC option to accept ISO C99... " >&6; }
5233 if ${ac_cv_prog_cc_c99+:} false; then :
5234   $as_echo_n "(cached) " >&6
5235 else
5236   ac_cv_prog_cc_c99=no
5237 ac_save_CC=$CC
5238 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5239 /* end confdefs.h.  */
5240 #include <stdarg.h>
5241 #include <stdbool.h>
5242 #include <stdlib.h>
5243 #include <wchar.h>
5244 #include <stdio.h>
5245
5246 // Check varargs macros.  These examples are taken from C99 6.10.3.5.
5247 #define debug(...) fprintf (stderr, __VA_ARGS__)
5248 #define showlist(...) puts (#__VA_ARGS__)
5249 #define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
5250 static void
5251 test_varargs_macros (void)
5252 {
5253   int x = 1234;
5254   int y = 5678;
5255   debug ("Flag");
5256   debug ("X = %d\n", x);
5257   showlist (The first, second, and third items.);
5258   report (x>y, "x is %d but y is %d", x, y);
5259 }
5260
5261 // Check long long types.
5262 #define BIG64 18446744073709551615ull
5263 #define BIG32 4294967295ul
5264 #define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
5265 #if !BIG_OK
5266   your preprocessor is broken;
5267 #endif
5268 #if BIG_OK
5269 #else
5270   your preprocessor is broken;
5271 #endif
5272 static long long int bignum = -9223372036854775807LL;
5273 static unsigned long long int ubignum = BIG64;
5274
5275 struct incomplete_array
5276 {
5277   int datasize;
5278   double data[];
5279 };
5280
5281 struct named_init {
5282   int number;
5283   const wchar_t *name;
5284   double average;
5285 };
5286
5287 typedef const char *ccp;
5288
5289 static inline int
5290 test_restrict (ccp restrict text)
5291 {
5292   // See if C++-style comments work.
5293   // Iterate through items via the restricted pointer.
5294   // Also check for declarations in for loops.
5295   for (unsigned int i = 0; *(text+i) != '\0'; ++i)
5296     continue;
5297   return 0;
5298 }
5299
5300 // Check varargs and va_copy.
5301 static void
5302 test_varargs (const char *format, ...)
5303 {
5304   va_list args;
5305   va_start (args, format);
5306   va_list args_copy;
5307   va_copy (args_copy, args);
5308
5309   const char *str;
5310   int number;
5311   float fnumber;
5312
5313   while (*format)
5314     {
5315       switch (*format++)
5316         {
5317         case 's': // string
5318           str = va_arg (args_copy, const char *);
5319           break;
5320         case 'd': // int
5321           number = va_arg (args_copy, int);
5322           break;
5323         case 'f': // float
5324           fnumber = va_arg (args_copy, double);
5325           break;
5326         default:
5327           break;
5328         }
5329     }
5330   va_end (args_copy);
5331   va_end (args);
5332 }
5333
5334 int
5335 main ()
5336 {
5337
5338   // Check bool.
5339   _Bool success = false;
5340
5341   // Check restrict.
5342   if (test_restrict ("String literal") == 0)
5343     success = true;
5344   char *restrict newvar = "Another string";
5345
5346   // Check varargs.
5347   test_varargs ("s, d' f .", "string", 65, 34.234);
5348   test_varargs_macros ();
5349
5350   // Check flexible array members.
5351   struct incomplete_array *ia =
5352     malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
5353   ia->datasize = 10;
5354   for (int i = 0; i < ia->datasize; ++i)
5355     ia->data[i] = i * 1.234;
5356
5357   // Check named initializers.
5358   struct named_init ni = {
5359     .number = 34,
5360     .name = L"Test wide string",
5361     .average = 543.34343,
5362   };
5363
5364   ni.number = 58;
5365
5366   int dynamic_array[ni.number];
5367   dynamic_array[ni.number - 1] = 543;
5368
5369   // work around unused variable warnings
5370   return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
5371           || dynamic_array[ni.number - 1] != 543);
5372
5373   ;
5374   return 0;
5375 }
5376 _ACEOF
5377 for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -xc99=all -qlanglvl=extc99
5378 do
5379   CC="$ac_save_CC $ac_arg"
5380   if ac_fn_c_try_compile "$LINENO"; then :
5381   ac_cv_prog_cc_c99=$ac_arg
5382 fi
5383 rm -f core conftest.err conftest.$ac_objext
5384   test "x$ac_cv_prog_cc_c99" != "xno" && break
5385 done
5386 rm -f conftest.$ac_ext
5387 CC=$ac_save_CC
5388
5389 fi
5390 # AC_CACHE_VAL
5391 case "x$ac_cv_prog_cc_c99" in
5392   x)
5393     { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5394 $as_echo "none needed" >&6; } ;;
5395   xno)
5396     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5397 $as_echo "unsupported" >&6; } ;;
5398   *)
5399     CC="$CC $ac_cv_prog_cc_c99"
5400     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
5401 $as_echo "$ac_cv_prog_cc_c99" >&6; } ;;
5402 esac
5403 if test "x$ac_cv_prog_cc_c99" != xno; then :
5404
5405 fi
5406
5407
5408
5409
5410
5411
5412 ac_ext=c
5413 ac_cpp='$CPP $CPPFLAGS'
5414 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5415 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5416 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5417 if test -n "$ac_tool_prefix"; then
5418   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
5419 set dummy ${ac_tool_prefix}gcc; ac_word=$2
5420 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5421 $as_echo_n "checking for $ac_word... " >&6; }
5422 if ${ac_cv_prog_CC+:} false; then :
5423   $as_echo_n "(cached) " >&6
5424 else
5425   if test -n "$CC"; then
5426   ac_cv_prog_CC="$CC" # Let the user override the test.
5427 else
5428 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5429 for as_dir in $PATH
5430 do
5431   IFS=$as_save_IFS
5432   test -z "$as_dir" && as_dir=.
5433     for ac_exec_ext in '' $ac_executable_extensions; do
5434   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5435     ac_cv_prog_CC="${ac_tool_prefix}gcc"
5436     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5437     break 2
5438   fi
5439 done
5440   done
5441 IFS=$as_save_IFS
5442
5443 fi
5444 fi
5445 CC=$ac_cv_prog_CC
5446 if test -n "$CC"; then
5447   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5448 $as_echo "$CC" >&6; }
5449 else
5450   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5451 $as_echo "no" >&6; }
5452 fi
5453
5454
5455 fi
5456 if test -z "$ac_cv_prog_CC"; then
5457   ac_ct_CC=$CC
5458   # Extract the first word of "gcc", so it can be a program name with args.
5459 set dummy gcc; ac_word=$2
5460 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5461 $as_echo_n "checking for $ac_word... " >&6; }
5462 if ${ac_cv_prog_ac_ct_CC+:} false; then :
5463   $as_echo_n "(cached) " >&6
5464 else
5465   if test -n "$ac_ct_CC"; then
5466   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
5467 else
5468 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5469 for as_dir in $PATH
5470 do
5471   IFS=$as_save_IFS
5472   test -z "$as_dir" && as_dir=.
5473     for ac_exec_ext in '' $ac_executable_extensions; do
5474   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5475     ac_cv_prog_ac_ct_CC="gcc"
5476     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5477     break 2
5478   fi
5479 done
5480   done
5481 IFS=$as_save_IFS
5482
5483 fi
5484 fi
5485 ac_ct_CC=$ac_cv_prog_ac_ct_CC
5486 if test -n "$ac_ct_CC"; then
5487   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
5488 $as_echo "$ac_ct_CC" >&6; }
5489 else
5490   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5491 $as_echo "no" >&6; }
5492 fi
5493
5494   if test "x$ac_ct_CC" = x; then
5495     CC=""
5496   else
5497     case $cross_compiling:$ac_tool_warned in
5498 yes:)
5499 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5500 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5501 ac_tool_warned=yes ;;
5502 esac
5503     CC=$ac_ct_CC
5504   fi
5505 else
5506   CC="$ac_cv_prog_CC"
5507 fi
5508
5509 if test -z "$CC"; then
5510           if test -n "$ac_tool_prefix"; then
5511     # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
5512 set dummy ${ac_tool_prefix}cc; ac_word=$2
5513 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5514 $as_echo_n "checking for $ac_word... " >&6; }
5515 if ${ac_cv_prog_CC+:} false; then :
5516   $as_echo_n "(cached) " >&6
5517 else
5518   if test -n "$CC"; then
5519   ac_cv_prog_CC="$CC" # Let the user override the test.
5520 else
5521 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5522 for as_dir in $PATH
5523 do
5524   IFS=$as_save_IFS
5525   test -z "$as_dir" && as_dir=.
5526     for ac_exec_ext in '' $ac_executable_extensions; do
5527   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5528     ac_cv_prog_CC="${ac_tool_prefix}cc"
5529     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5530     break 2
5531   fi
5532 done
5533   done
5534 IFS=$as_save_IFS
5535
5536 fi
5537 fi
5538 CC=$ac_cv_prog_CC
5539 if test -n "$CC"; then
5540   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5541 $as_echo "$CC" >&6; }
5542 else
5543   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5544 $as_echo "no" >&6; }
5545 fi
5546
5547
5548   fi
5549 fi
5550 if test -z "$CC"; then
5551   # Extract the first word of "cc", so it can be a program name with args.
5552 set dummy cc; ac_word=$2
5553 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5554 $as_echo_n "checking for $ac_word... " >&6; }
5555 if ${ac_cv_prog_CC+:} false; then :
5556   $as_echo_n "(cached) " >&6
5557 else
5558   if test -n "$CC"; then
5559   ac_cv_prog_CC="$CC" # Let the user override the test.
5560 else
5561   ac_prog_rejected=no
5562 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5563 for as_dir in $PATH
5564 do
5565   IFS=$as_save_IFS
5566   test -z "$as_dir" && as_dir=.
5567     for ac_exec_ext in '' $ac_executable_extensions; do
5568   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5569     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
5570        ac_prog_rejected=yes
5571        continue
5572      fi
5573     ac_cv_prog_CC="cc"
5574     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5575     break 2
5576   fi
5577 done
5578   done
5579 IFS=$as_save_IFS
5580
5581 if test $ac_prog_rejected = yes; then
5582   # We found a bogon in the path, so make sure we never use it.
5583   set dummy $ac_cv_prog_CC
5584   shift
5585   if test $# != 0; then
5586     # We chose a different compiler from the bogus one.
5587     # However, it has the same basename, so the bogon will be chosen
5588     # first if we set CC to just the basename; use the full file name.
5589     shift
5590     ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
5591   fi
5592 fi
5593 fi
5594 fi
5595 CC=$ac_cv_prog_CC
5596 if test -n "$CC"; then
5597   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5598 $as_echo "$CC" >&6; }
5599 else
5600   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5601 $as_echo "no" >&6; }
5602 fi
5603
5604
5605 fi
5606 if test -z "$CC"; then
5607   if test -n "$ac_tool_prefix"; then
5608   for ac_prog in cl.exe
5609   do
5610     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
5611 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
5612 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5613 $as_echo_n "checking for $ac_word... " >&6; }
5614 if ${ac_cv_prog_CC+:} false; then :
5615   $as_echo_n "(cached) " >&6
5616 else
5617   if test -n "$CC"; then
5618   ac_cv_prog_CC="$CC" # Let the user override the test.
5619 else
5620 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5621 for as_dir in $PATH
5622 do
5623   IFS=$as_save_IFS
5624   test -z "$as_dir" && as_dir=.
5625     for ac_exec_ext in '' $ac_executable_extensions; do
5626   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5627     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
5628     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5629     break 2
5630   fi
5631 done
5632   done
5633 IFS=$as_save_IFS
5634
5635 fi
5636 fi
5637 CC=$ac_cv_prog_CC
5638 if test -n "$CC"; then
5639   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5640 $as_echo "$CC" >&6; }
5641 else
5642   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5643 $as_echo "no" >&6; }
5644 fi
5645
5646
5647     test -n "$CC" && break
5648   done
5649 fi
5650 if test -z "$CC"; then
5651   ac_ct_CC=$CC
5652   for ac_prog in cl.exe
5653 do
5654   # Extract the first word of "$ac_prog", so it can be a program name with args.
5655 set dummy $ac_prog; ac_word=$2
5656 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5657 $as_echo_n "checking for $ac_word... " >&6; }
5658 if ${ac_cv_prog_ac_ct_CC+:} false; then :
5659   $as_echo_n "(cached) " >&6
5660 else
5661   if test -n "$ac_ct_CC"; then
5662   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
5663 else
5664 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5665 for as_dir in $PATH
5666 do
5667   IFS=$as_save_IFS
5668   test -z "$as_dir" && as_dir=.
5669     for ac_exec_ext in '' $ac_executable_extensions; do
5670   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5671     ac_cv_prog_ac_ct_CC="$ac_prog"
5672     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5673     break 2
5674   fi
5675 done
5676   done
5677 IFS=$as_save_IFS
5678
5679 fi
5680 fi
5681 ac_ct_CC=$ac_cv_prog_ac_ct_CC
5682 if test -n "$ac_ct_CC"; then
5683   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
5684 $as_echo "$ac_ct_CC" >&6; }
5685 else
5686   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5687 $as_echo "no" >&6; }
5688 fi
5689
5690
5691   test -n "$ac_ct_CC" && break
5692 done
5693
5694   if test "x$ac_ct_CC" = x; then
5695     CC=""
5696   else
5697     case $cross_compiling:$ac_tool_warned in
5698 yes:)
5699 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5700 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5701 ac_tool_warned=yes ;;
5702 esac
5703     CC=$ac_ct_CC
5704   fi
5705 fi
5706
5707 fi
5708
5709
5710 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5711 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5712 as_fn_error $? "no acceptable C compiler found in \$PATH
5713 See \`config.log' for more details" "$LINENO" 5; }
5714
5715 # Provide some information about the compiler.
5716 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
5717 set X $ac_compile
5718 ac_compiler=$2
5719 for ac_option in --version -v -V -qversion; do
5720   { { ac_try="$ac_compiler $ac_option >&5"
5721 case "(($ac_try" in
5722   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5723   *) ac_try_echo=$ac_try;;
5724 esac
5725 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5726 $as_echo "$ac_try_echo"; } >&5
5727   (eval "$ac_compiler $ac_option >&5") 2>conftest.err
5728   ac_status=$?
5729   if test -s conftest.err; then
5730     sed '10a\
5731 ... rest of stderr output deleted ...
5732          10q' conftest.err >conftest.er1
5733     cat conftest.er1 >&5
5734   fi
5735   rm -f conftest.er1 conftest.err
5736   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5737   test $ac_status = 0; }
5738 done
5739
5740 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
5741 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
5742 if ${ac_cv_c_compiler_gnu+:} false; then :
5743   $as_echo_n "(cached) " >&6
5744 else
5745   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5746 /* end confdefs.h.  */
5747
5748 int
5749 main ()
5750 {
5751 #ifndef __GNUC__
5752        choke me
5753 #endif
5754
5755   ;
5756   return 0;
5757 }
5758 _ACEOF
5759 if ac_fn_c_try_compile "$LINENO"; then :
5760   ac_compiler_gnu=yes
5761 else
5762   ac_compiler_gnu=no
5763 fi
5764 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5765 ac_cv_c_compiler_gnu=$ac_compiler_gnu
5766
5767 fi
5768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
5769 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
5770 if test $ac_compiler_gnu = yes; then
5771   GCC=yes
5772 else
5773   GCC=
5774 fi
5775 ac_test_CFLAGS=${CFLAGS+set}
5776 ac_save_CFLAGS=$CFLAGS
5777 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
5778 $as_echo_n "checking whether $CC accepts -g... " >&6; }
5779 if ${ac_cv_prog_cc_g+:} false; then :
5780   $as_echo_n "(cached) " >&6
5781 else
5782   ac_save_c_werror_flag=$ac_c_werror_flag
5783    ac_c_werror_flag=yes
5784    ac_cv_prog_cc_g=no
5785    CFLAGS="-g"
5786    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5787 /* end confdefs.h.  */
5788
5789 int
5790 main ()
5791 {
5792
5793   ;
5794   return 0;
5795 }
5796 _ACEOF
5797 if ac_fn_c_try_compile "$LINENO"; then :
5798   ac_cv_prog_cc_g=yes
5799 else
5800   CFLAGS=""
5801       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5802 /* end confdefs.h.  */
5803
5804 int
5805 main ()
5806 {
5807
5808   ;
5809   return 0;
5810 }
5811 _ACEOF
5812 if ac_fn_c_try_compile "$LINENO"; then :
5813
5814 else
5815   ac_c_werror_flag=$ac_save_c_werror_flag
5816          CFLAGS="-g"
5817          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5818 /* end confdefs.h.  */
5819
5820 int
5821 main ()
5822 {
5823
5824   ;
5825   return 0;
5826 }
5827 _ACEOF
5828 if ac_fn_c_try_compile "$LINENO"; then :
5829   ac_cv_prog_cc_g=yes
5830 fi
5831 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5832 fi
5833 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5834 fi
5835 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5836    ac_c_werror_flag=$ac_save_c_werror_flag
5837 fi
5838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
5839 $as_echo "$ac_cv_prog_cc_g" >&6; }
5840 if test "$ac_test_CFLAGS" = set; then
5841   CFLAGS=$ac_save_CFLAGS
5842 elif test $ac_cv_prog_cc_g = yes; then
5843   if test "$GCC" = yes; then
5844     CFLAGS="-g -O2"
5845   else
5846     CFLAGS="-g"
5847   fi
5848 else
5849   if test "$GCC" = yes; then
5850     CFLAGS="-O2"
5851   else
5852     CFLAGS=
5853   fi
5854 fi
5855 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
5856 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
5857 if ${ac_cv_prog_cc_c89+:} false; then :
5858   $as_echo_n "(cached) " >&6
5859 else
5860   ac_cv_prog_cc_c89=no
5861 ac_save_CC=$CC
5862 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5863 /* end confdefs.h.  */
5864 #include <stdarg.h>
5865 #include <stdio.h>
5866 #include <sys/types.h>
5867 #include <sys/stat.h>
5868 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
5869 struct buf { int x; };
5870 FILE * (*rcsopen) (struct buf *, struct stat *, int);
5871 static char *e (p, i)
5872      char **p;
5873      int i;
5874 {
5875   return p[i];
5876 }
5877 static char *f (char * (*g) (char **, int), char **p, ...)
5878 {
5879   char *s;
5880   va_list v;
5881   va_start (v,p);
5882   s = g (p, va_arg (v,int));
5883   va_end (v);
5884   return s;
5885 }
5886
5887 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
5888    function prototypes and stuff, but not '\xHH' hex character constants.
5889    These don't provoke an error unfortunately, instead are silently treated
5890    as 'x'.  The following induces an error, until -std is added to get
5891    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
5892    array size at least.  It's necessary to write '\x00'==0 to get something
5893    that's true only with -std.  */
5894 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5895
5896 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5897    inside strings and character constants.  */
5898 #define FOO(x) 'x'
5899 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5900
5901 int test (int i, double x);
5902 struct s1 {int (*f) (int a);};
5903 struct s2 {int (*f) (double a);};
5904 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5905 int argc;
5906 char **argv;
5907 int
5908 main ()
5909 {
5910 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
5911   ;
5912   return 0;
5913 }
5914 _ACEOF
5915 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5916         -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5917 do
5918   CC="$ac_save_CC $ac_arg"
5919   if ac_fn_c_try_compile "$LINENO"; then :
5920   ac_cv_prog_cc_c89=$ac_arg
5921 fi
5922 rm -f core conftest.err conftest.$ac_objext
5923   test "x$ac_cv_prog_cc_c89" != "xno" && break
5924 done
5925 rm -f conftest.$ac_ext
5926 CC=$ac_save_CC
5927
5928 fi
5929 # AC_CACHE_VAL
5930 case "x$ac_cv_prog_cc_c89" in
5931   x)
5932     { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5933 $as_echo "none needed" >&6; } ;;
5934   xno)
5935     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5936 $as_echo "unsupported" >&6; } ;;
5937   *)
5938     CC="$CC $ac_cv_prog_cc_c89"
5939     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5940 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
5941 esac
5942 if test "x$ac_cv_prog_cc_c89" != xno; then :
5943
5944 fi
5945
5946 ac_ext=c
5947 ac_cpp='$CPP $CPPFLAGS'
5948 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5949 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5950 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5951
5952 depcc="$CC"   am_compiler_list=
5953
5954 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
5955 $as_echo_n "checking dependency style of $depcc... " >&6; }
5956 if ${am_cv_CC_dependencies_compiler_type+:} false; then :
5957   $as_echo_n "(cached) " >&6
5958 else
5959   if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
5960   # We make a subdir and do the tests there.  Otherwise we can end up
5961   # making bogus files that we don't know about and never remove.  For
5962   # instance it was reported that on HP-UX the gcc test will end up
5963   # making a dummy file named `D' -- because `-MD' means `put the output
5964   # in D'.
5965   mkdir conftest.dir
5966   # Copy depcomp to subdir because otherwise we won't find it if we're
5967   # using a relative directory.
5968   cp "$am_depcomp" conftest.dir
5969   cd conftest.dir
5970   # We will build objects and dependencies in a subdirectory because
5971   # it helps to detect inapplicable dependency modes.  For instance
5972   # both Tru64's cc and ICC support -MD to output dependencies as a
5973   # side effect of compilation, but ICC will put the dependencies in
5974   # the current directory while Tru64 will put them in the object
5975   # directory.
5976   mkdir sub
5977
5978   am_cv_CC_dependencies_compiler_type=none
5979   if test "$am_compiler_list" = ""; then
5980      am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
5981   fi
5982   am__universal=false
5983   case " $depcc " in #(
5984      *\ -arch\ *\ -arch\ *) am__universal=true ;;
5985      esac
5986
5987   for depmode in $am_compiler_list; do
5988     # Setup a source with many dependencies, because some compilers
5989     # like to wrap large dependency lists on column 80 (with \), and
5990     # we should not choose a depcomp mode which is confused by this.
5991     #
5992     # We need to recreate these files for each test, as the compiler may
5993     # overwrite some of them when testing with obscure command lines.
5994     # This happens at least with the AIX C compiler.
5995     : > sub/conftest.c
5996     for i in 1 2 3 4 5 6; do
5997       echo '#include "conftst'$i'.h"' >> sub/conftest.c
5998       # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
5999       # Solaris 8's {/usr,}/bin/sh.
6000       touch sub/conftst$i.h
6001     done
6002     echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
6003
6004     # We check with `-c' and `-o' for the sake of the "dashmstdout"
6005     # mode.  It turns out that the SunPro C++ compiler does not properly
6006     # handle `-M -o', and we need to detect this.  Also, some Intel
6007     # versions had trouble with output in subdirs
6008     am__obj=sub/conftest.${OBJEXT-o}
6009     am__minus_obj="-o $am__obj"
6010     case $depmode in
6011     gcc)
6012       # This depmode causes a compiler race in universal mode.
6013       test "$am__universal" = false || continue
6014       ;;
6015     nosideeffect)
6016       # after this tag, mechanisms are not by side-effect, so they'll
6017       # only be used when explicitly requested
6018       if test "x$enable_dependency_tracking" = xyes; then
6019         continue
6020       else
6021         break
6022       fi
6023       ;;
6024     msvisualcpp | msvcmsys)
6025       # This compiler won't grok `-c -o', but also, the minuso test has
6026       # not run yet.  These depmodes are late enough in the game, and
6027       # so weak that their functioning should not be impacted.
6028       am__obj=conftest.${OBJEXT-o}
6029       am__minus_obj=
6030       ;;
6031     none) break ;;
6032     esac
6033     if depmode=$depmode \
6034        source=sub/conftest.c object=$am__obj \
6035        depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
6036        $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
6037          >/dev/null 2>conftest.err &&
6038        grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
6039        grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
6040        grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
6041        ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
6042       # icc doesn't choke on unknown options, it will just issue warnings
6043       # or remarks (even with -Werror).  So we grep stderr for any message
6044       # that says an option was ignored or not supported.
6045       # When given -MP, icc 7.0 and 7.1 complain thusly:
6046       #   icc: Command line warning: ignoring option '-M'; no argument required
6047       # The diagnosis changed in icc 8.0:
6048       #   icc: Command line remark: option '-MP' not supported
6049       if (grep 'ignoring option' conftest.err ||
6050           grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
6051         am_cv_CC_dependencies_compiler_type=$depmode
6052         break
6053       fi
6054     fi
6055   done
6056
6057   cd ..
6058   rm -rf conftest.dir
6059 else
6060   am_cv_CC_dependencies_compiler_type=none
6061 fi
6062
6063 fi
6064 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
6065 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
6066 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
6067
6068  if
6069   test "x$enable_dependency_tracking" != xno \
6070   && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
6071   am__fastdepCC_TRUE=
6072   am__fastdepCC_FALSE='#'
6073 else
6074   am__fastdepCC_TRUE='#'
6075   am__fastdepCC_FALSE=
6076 fi
6077
6078
6079 # Ralf Wildenhues: With per-target flags we need CC_C_O
6080 # AM_PROG_CC_C_O supersets AC_PROG_CC_C_O
6081 # FIXME: we rely on the cache variable name because
6082 # there is no other way.
6083 set dummy $CC
6084 am_cc=`echo $2 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
6085 eval am_t=\$ac_cv_prog_cc_${am_cc}_c_o
6086 if test "$am_t" != yes; then
6087    # Losing compiler, so override with the script.
6088    # FIXME: It is wrong to rewrite CC.
6089    # But if we don't then we get into trouble of one sort or another.
6090    # A longer-term fix would be to have automake use am__CC in this case,
6091    # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
6092    CC="$am_aux_dir/compile $CC"
6093 fi
6094
6095
6096 if test $ac_cv_c_compiler_gnu = yes; then
6097     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC needs -traditional" >&5
6098 $as_echo_n "checking whether $CC needs -traditional... " >&6; }
6099 if ${ac_cv_prog_gcc_traditional+:} false; then :
6100   $as_echo_n "(cached) " >&6
6101 else
6102     ac_pattern="Autoconf.*'x'"
6103   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6104 /* end confdefs.h.  */
6105 #include <sgtty.h>
6106 Autoconf TIOCGETP
6107 _ACEOF
6108 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6109   $EGREP "$ac_pattern" >/dev/null 2>&1; then :
6110   ac_cv_prog_gcc_traditional=yes
6111 else
6112   ac_cv_prog_gcc_traditional=no
6113 fi
6114 rm -f conftest*
6115
6116
6117   if test $ac_cv_prog_gcc_traditional = no; then
6118     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6119 /* end confdefs.h.  */
6120 #include <termio.h>
6121 Autoconf TCGETA
6122 _ACEOF
6123 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6124   $EGREP "$ac_pattern" >/dev/null 2>&1; then :
6125   ac_cv_prog_gcc_traditional=yes
6126 fi
6127 rm -f conftest*
6128
6129   fi
6130 fi
6131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_gcc_traditional" >&5
6132 $as_echo "$ac_cv_prog_gcc_traditional" >&6; }
6133   if test $ac_cv_prog_gcc_traditional = yes; then
6134     CC="$CC -traditional"
6135   fi
6136 fi
6137
6138
6139
6140
6141
6142 CFLAGS_NTP=
6143 CPPFLAGS_NTP=
6144 LDADD_NTP=
6145 LDFLAGS_NTP=
6146
6147
6148
6149
6150
6151 case "$ac_cv_prog_cc_c89" in
6152  no)
6153     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ANSI C89/ISO C90 is the minimum to compile NTP
6154                  version 4.2.5 and higher." >&5
6155 $as_echo "$as_me: WARNING: ANSI C89/ISO C90 is the minimum to compile NTP
6156                  version 4.2.5 and higher." >&2;}
6157     ;;
6158 esac
6159
6160 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC can handle #warning" >&5
6161 $as_echo_n "checking if $CC can handle #warning... " >&6; }
6162 if ${ntp_cv_cpp_warning+:} false; then :
6163   $as_echo_n "(cached) " >&6
6164 else
6165   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6166 /* end confdefs.h.  */
6167
6168 int
6169 main ()
6170 {
6171 #warning foo
6172   ;
6173   return 0;
6174 }
6175 _ACEOF
6176 if ac_fn_c_try_compile "$LINENO"; then :
6177   ntp_cv_cpp_warning=yes
6178 else
6179   ntp_cv_cpp_warning=no
6180
6181 fi
6182 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6183
6184 fi
6185 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_cpp_warning" >&5
6186 $as_echo "$ntp_cv_cpp_warning" >&6; }
6187 case "$ntp_cv_cpp_warning" in
6188  no)
6189
6190 $as_echo "#define NO_OPTION_NAME_WARNINGS 1" >>confdefs.h
6191
6192 esac
6193
6194 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC supports __attribute__((...))" >&5
6195 $as_echo_n "checking if $CC supports __attribute__((...))... " >&6; }
6196 if ${ntp_cv_cc_attribute+:} false; then :
6197   $as_echo_n "(cached) " >&6
6198 else
6199   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6200 /* end confdefs.h.  */
6201
6202 int
6203 main ()
6204 {
6205 void foo(void) __attribute__((__noreturn__));
6206
6207   ;
6208   return 0;
6209 }
6210 _ACEOF
6211 if ac_fn_c_try_compile "$LINENO"; then :
6212   ntp_cv_cc_attribute=yes
6213 else
6214   ntp_cv_cc_attribute=no
6215
6216 fi
6217 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6218
6219 fi
6220 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_cc_attribute" >&5
6221 $as_echo "$ntp_cv_cc_attribute" >&6; }
6222 case "$ntp_cv_cc_attribute" in
6223  yes)
6224
6225 $as_echo "#define HAVE___ATTRIBUTE__ /**/" >>confdefs.h
6226
6227 esac
6228
6229
6230 case "$GCC" in
6231  yes)
6232     SAVED_CFLAGS="$CFLAGS"
6233     CFLAGS="$CFLAGS -Wstrict-overflow"
6234     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC can handle -Wstrict-overflow" >&5
6235 $as_echo_n "checking if $CC can handle -Wstrict-overflow... " >&6; }
6236 if ${ntp_cv_gcc_Wstrict_overflow+:} false; then :
6237   $as_echo_n "(cached) " >&6
6238 else
6239   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6240 /* end confdefs.h.  */
6241
6242 int
6243 main ()
6244 {
6245
6246   ;
6247   return 0;
6248 }
6249 _ACEOF
6250 if ac_fn_c_try_compile "$LINENO"; then :
6251   ntp_cv_gcc_Wstrict_overflow=yes
6252 else
6253   ntp_cv_gcc_Wstrict_overflow=no
6254
6255 fi
6256 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6257
6258 fi
6259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_gcc_Wstrict_overflow" >&5
6260 $as_echo "$ntp_cv_gcc_Wstrict_overflow" >&6; }
6261     #
6262     # $ntp_cv_gcc_Wstrict_overflow is tested later to add the
6263     # flag to CFLAGS.
6264     #
6265     CFLAGS="$SAVED_CFLAGS -Winit-self"
6266     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC can handle -Winit-self" >&5
6267 $as_echo_n "checking if $CC can handle -Winit-self... " >&6; }
6268 if ${ntp_cv_gcc_Winit_self+:} false; then :
6269   $as_echo_n "(cached) " >&6
6270 else
6271
6272             cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6273 /* end confdefs.h.  */
6274
6275 int
6276 main ()
6277 {
6278
6279   ;
6280   return 0;
6281 }
6282 _ACEOF
6283 if ac_fn_c_try_compile "$LINENO"; then :
6284   ntp_cv_gcc_Winit_self=yes
6285 else
6286   ntp_cv_gcc_Winit_self=no
6287
6288 fi
6289 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6290
6291
6292 fi
6293 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_gcc_Winit_self" >&5
6294 $as_echo "$ntp_cv_gcc_Winit_self" >&6; }
6295     CFLAGS="$SAVED_CFLAGS"
6296     { SAVED_CFLAGS=; unset SAVED_CFLAGS;}
6297     #
6298     # $ntp_cv_gcc_Winit_self is tested later to add the
6299     # flag to CFLAGS_NTP.
6300     #
6301     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linker supports omitting unused code and data" >&5
6302 $as_echo_n "checking if linker supports omitting unused code and data... " >&6; }
6303 if ${ntp_cv_gc_sections_runs+:} false; then :
6304   $as_echo_n "(cached) " >&6
6305 else
6306
6307                                                                                             origCFLAGS="$CFLAGS"
6308             CFLAGS="$CFLAGS -Wl,--gc-sections"
6309             cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6310 /* end confdefs.h.  */
6311
6312                         #include <stdlib.h>
6313                         #include <stdio.h>
6314
6315 int
6316 main ()
6317 {
6318
6319                         FILE *  fpC;
6320                         char    buf[32];
6321                         size_t  cch;
6322                         int     read_success_once;
6323
6324                         fpC = fopen("conftest.c", "r");
6325                         if (NULL == fpC)
6326                                 exit(1);
6327                         do {
6328                                 cch = fread(buf, sizeof(buf), 1, fpC);
6329                                 read_success_once |= (0 != cch);
6330                         } while (0 != cch);
6331                         if (!read_success_once)
6332                                 exit(2);
6333                         if (!feof(fpC))
6334                                 exit(3);
6335                         if (0 != fclose(fpC))
6336                                 exit(4);
6337
6338                         exit(EXIT_SUCCESS);
6339
6340
6341   ;
6342   return 0;
6343 }
6344 _ACEOF
6345 if ac_fn_c_try_link "$LINENO"; then :
6346
6347                     if test "X$cross_compiling" = "Xyes" || grep gc-sections conftest.err ; then
6348                         ntp_cv_gc_sections_runs=no
6349                     else
6350                         ntp_cv_gc_sections_runs=no
6351                         ./conftest >/dev/null 2>&1 && ntp_cv_gc_sections_runs=yes
6352                     fi
6353
6354 else
6355   ntp_cv_gc_sections_runs=no
6356
6357 fi
6358 rm -f core conftest.err conftest.$ac_objext \
6359     conftest$ac_exeext conftest.$ac_ext
6360             CFLAGS="$origCFLAGS"
6361             { origCFLAGS=; unset origCFLAGS;}
6362
6363
6364 fi
6365 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_gc_sections_runs" >&5
6366 $as_echo "$ntp_cv_gc_sections_runs" >&6; }
6367     case "$ntp_cv_gc_sections_runs" in
6368      yes)
6369         LDADD_LIBNTP="-Wl,--gc-sections"
6370         CFLAGS_NTP="$CFLAGS_NTP -ffunction-sections -fdata-sections"
6371         ;;
6372      no)
6373         LDADD_LIBNTP=
6374         ;;
6375     esac
6376     CFLAGS_NTP="$CFLAGS_NTP -Wall"
6377     CFLAGS_NTP="$CFLAGS_NTP -Wcast-align"
6378     CFLAGS_NTP="$CFLAGS_NTP -Wcast-qual"
6379     # CFLAGS_NTP="$CFLAGS_NTP -Wconversion"
6380     # CFLAGS_NTP="$CFLAGS_NTP -Werror"
6381     # CFLAGS_NTP="$CFLAGS_NTP -Wextra"
6382     # CFLAGS_NTP="$CFLAGS_NTP -Wfloat-equal"
6383     CFLAGS_NTP="$CFLAGS_NTP -Wmissing-prototypes"
6384     CFLAGS_NTP="$CFLAGS_NTP -Wpointer-arith"
6385     CFLAGS_NTP="$CFLAGS_NTP -Wshadow"
6386     # CFLAGS_NTP="$CFLAGS_NTP -Wtraditional"
6387     # CFLAGS_NTP="$CFLAGS_NTP -Wwrite-strings"
6388     case "$ntp_cv_gcc_Winit_self" in
6389      yes)
6390         CFLAGS_NTP="$CFLAGS_NTP -Winit-self"
6391     esac
6392     case "$ntp_cv_gcc_Wstrict_overflow" in
6393      yes)
6394         CFLAGS_NTP="$CFLAGS_NTP -Wstrict-overflow"
6395     esac
6396     # -W[no-]strict-prototypes might be added by NTP_OPENSSL
6397 esac
6398
6399
6400     { $as_echo "$as_me:${as_lineno-$LINENO}: checking additional compiler flags" >&5
6401 $as_echo_n "checking additional compiler flags... " >&6; }
6402     # allow ntp_os_flags to be preset to skip this stuff
6403     case "${ntp_os_cflags+set}" in
6404      set)
6405         ;;
6406      *)
6407         ntp_os_cflags=
6408         case "$host_os" in
6409          aix[1-3]*)
6410             ;;
6411          aix4.[0-2]*)
6412             # turn on additional headers
6413             ntp_os_cflags="-D_XOPEN_EXTENDED_SOURCE"
6414             ;;
6415          aix5.3*)
6416             # avoid circular dependencies in yp headers, and more
6417             ntp_os_cflags="-DHAVE_BAD_HEADERS -D_XOPEN_EXTENDED_SOURCE"
6418             ntp_os_cflags="${ntp_os_cflags} -D_USE_IRS -D_MSGQSUPPORT"
6419             ;;
6420          aix*)
6421             # XXX Only verified thru AIX6.
6422             # aix7 seems to need a different XOPEN_SOURCE_EXTENDED thing.
6423             # avoid circular dependencies in yp headers
6424             # _XOPEN_SOURCE=500 = X/Open 5: POSIX 1995
6425             # _XOPEN_SOURCE=600 = X/Open 6: POSIX 2004
6426             # _XOPEN_SOURCE=700 = X/Open 7: POSIX 2008
6427             ntp_os_cflags="-DHAVE_BAD_HEADERS -D_XOPEN_SOURCE=600"
6428             ntp_os_cflags="${ntp_os_cflags} -D_USE_IRS"
6429             ;;
6430          amigaos)
6431             ntp_os_cflags="-DSYS_AMIGA"
6432             ;;
6433          darwin*|macosx*|rhapsody*)
6434             ntp_os_cflags="-D_P1003_1B_VISIBLE"
6435             ;;
6436          hpux10.*)              # at least for hppa2.0-hp-hpux10.20
6437             case "$GCC" in
6438              yes)
6439                 ;;
6440              *)
6441                 # use Ansi compiler on HPUX, and some -Wp magic
6442                 ntp_os_cflags="-Ae -Wp,-H18816"
6443                 ;;
6444             esac
6445             ntp_os_cflags="${ntp_os_cflags} -D_HPUX_SOURCE"
6446             ;;
6447          hpux*)
6448             case "$GCC" in
6449              yes)
6450                 ;;
6451              *)
6452                 # use Ansi compiler on HPUX
6453                 ntp_os_cflags="-Ae"
6454             esac
6455             ntp_os_cflags="${ntp_os_cflags} -D_HPUX_SOURCE"
6456             ;;
6457          irix6*)
6458             case "$CC" in
6459              cc)
6460                 # do not use 64-bit compiler
6461                 ntp_os_cflags="-n32 -mips3 -Wl,-woff,84"
6462             esac
6463             ;;
6464          nextstep3)
6465             ntp_os_cflags="-posix"
6466             ;;
6467          solaris1*|solaris2.[0-5]|solaris2.5.*)
6468             ;;
6469          sunos[34]*|sunos5.[0-5]|sunos5.5.*)
6470             ;;
6471          solaris2*|sunos5*)
6472             # turn on 64-bit file offset interface
6473             ntp_os_cflags="-D_LARGEFILE64_SOURCE"
6474             ;;
6475          vxworks*)
6476             case "$build" in
6477              $host)
6478                 ;;
6479              *)
6480                 # Quick and dirty sanity check
6481                 case "$VX_KERNEL" in
6482                  '')
6483                     as_fn_error $? "See html/build/hints/vxworks.html" "$LINENO" 5
6484                 esac
6485                 ntp_os_cflags="-DSYS_VXWORKS"
6486             esac
6487             ;;
6488         esac
6489     esac
6490     case "$ntp_os_flags" in
6491      '')
6492         ntp_os_cflags_msg="none needed"
6493         ;;
6494      *)
6495         ntp_os_cflags_msg="$ntp_os_cflags"
6496     esac
6497     CFLAGS_NTP="$CFLAGS_NTP $ntp_os_cflags"
6498     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_os_cflags_msg" >&5
6499 $as_echo "$ntp_os_cflags_msg" >&6; }
6500     { ntp_os_cflags_msg=; unset ntp_os_cflags_msg;}
6501
6502
6503
6504  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
6505 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
6506 if ${ac_cv_c_bigendian+:} false; then :
6507   $as_echo_n "(cached) " >&6
6508 else
6509   ac_cv_c_bigendian=unknown
6510     # See if we're dealing with a universal compiler.
6511     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6512 /* end confdefs.h.  */
6513 #ifndef __APPLE_CC__
6514                not a universal capable compiler
6515              #endif
6516              typedef int dummy;
6517
6518 _ACEOF
6519 if ac_fn_c_try_compile "$LINENO"; then :
6520
6521         # Check for potential -arch flags.  It is not universal unless
6522         # there are at least two -arch flags with different values.
6523         ac_arch=
6524         ac_prev=
6525         for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
6526          if test -n "$ac_prev"; then
6527            case $ac_word in
6528              i?86 | x86_64 | ppc | ppc64)
6529                if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
6530                  ac_arch=$ac_word
6531                else
6532                  ac_cv_c_bigendian=universal
6533                  break
6534                fi
6535                ;;
6536            esac
6537            ac_prev=
6538          elif test "x$ac_word" = "x-arch"; then
6539            ac_prev=arch
6540          fi
6541        done
6542 fi
6543 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6544     if test $ac_cv_c_bigendian = unknown; then
6545       # See if sys/param.h defines the BYTE_ORDER macro.
6546       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6547 /* end confdefs.h.  */
6548 #include <sys/types.h>
6549              #include <sys/param.h>
6550
6551 int
6552 main ()
6553 {
6554 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
6555                      && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
6556                      && LITTLE_ENDIAN)
6557               bogus endian macros
6558              #endif
6559
6560   ;
6561   return 0;
6562 }
6563 _ACEOF
6564 if ac_fn_c_try_compile "$LINENO"; then :
6565   # It does; now see whether it defined to BIG_ENDIAN or not.
6566          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6567 /* end confdefs.h.  */
6568 #include <sys/types.h>
6569                 #include <sys/param.h>
6570
6571 int
6572 main ()
6573 {
6574 #if BYTE_ORDER != BIG_ENDIAN
6575                  not big endian
6576                 #endif
6577
6578   ;
6579   return 0;
6580 }
6581 _ACEOF
6582 if ac_fn_c_try_compile "$LINENO"; then :
6583   ac_cv_c_bigendian=yes
6584 else
6585   ac_cv_c_bigendian=no
6586 fi
6587 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6588 fi
6589 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6590     fi
6591     if test $ac_cv_c_bigendian = unknown; then
6592       # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
6593       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6594 /* end confdefs.h.  */
6595 #include <limits.h>
6596
6597 int
6598 main ()
6599 {
6600 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
6601               bogus endian macros
6602              #endif
6603
6604   ;
6605   return 0;
6606 }
6607 _ACEOF
6608 if ac_fn_c_try_compile "$LINENO"; then :
6609   # It does; now see whether it defined to _BIG_ENDIAN or not.
6610          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6611 /* end confdefs.h.  */
6612 #include <limits.h>
6613
6614 int
6615 main ()
6616 {
6617 #ifndef _BIG_ENDIAN
6618                  not big endian
6619                 #endif
6620
6621   ;
6622   return 0;
6623 }
6624 _ACEOF
6625 if ac_fn_c_try_compile "$LINENO"; then :
6626   ac_cv_c_bigendian=yes
6627 else
6628   ac_cv_c_bigendian=no
6629 fi
6630 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6631 fi
6632 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6633     fi
6634     if test $ac_cv_c_bigendian = unknown; then
6635       # Compile a test program.
6636       if test "$cross_compiling" = yes; then :
6637   # Try to guess by grepping values from an object file.
6638          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6639 /* end confdefs.h.  */
6640 short int ascii_mm[] =
6641                   { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
6642                 short int ascii_ii[] =
6643                   { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
6644                 int use_ascii (int i) {
6645                   return ascii_mm[i] + ascii_ii[i];
6646                 }
6647                 short int ebcdic_ii[] =
6648                   { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
6649                 short int ebcdic_mm[] =
6650                   { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
6651                 int use_ebcdic (int i) {
6652                   return ebcdic_mm[i] + ebcdic_ii[i];
6653                 }
6654                 extern int foo;
6655
6656 int
6657 main ()
6658 {
6659 return use_ascii (foo) == use_ebcdic (foo);
6660   ;
6661   return 0;
6662 }
6663 _ACEOF
6664 if ac_fn_c_try_compile "$LINENO"; then :
6665   if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
6666               ac_cv_c_bigendian=yes
6667             fi
6668             if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
6669               if test "$ac_cv_c_bigendian" = unknown; then
6670                 ac_cv_c_bigendian=no
6671               else
6672                 # finding both strings is unlikely to happen, but who knows?
6673                 ac_cv_c_bigendian=unknown
6674               fi
6675             fi
6676 fi
6677 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6678 else
6679   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6680 /* end confdefs.h.  */
6681 $ac_includes_default
6682 int
6683 main ()
6684 {
6685
6686              /* Are we little or big endian?  From Harbison&Steele.  */
6687              union
6688              {
6689                long int l;
6690                char c[sizeof (long int)];
6691              } u;
6692              u.l = 1;
6693              return u.c[sizeof (long int) - 1] == 1;
6694
6695   ;
6696   return 0;
6697 }
6698 _ACEOF
6699 if ac_fn_c_try_run "$LINENO"; then :
6700   ac_cv_c_bigendian=no
6701 else
6702   ac_cv_c_bigendian=yes
6703 fi
6704 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6705   conftest.$ac_objext conftest.beam conftest.$ac_ext
6706 fi
6707
6708     fi
6709 fi
6710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
6711 $as_echo "$ac_cv_c_bigendian" >&6; }
6712  case $ac_cv_c_bigendian in #(
6713    yes)
6714      $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
6715 ;; #(
6716    no)
6717       ;; #(
6718    universal)
6719
6720 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
6721
6722      ;; #(
6723    *)
6724      as_fn_error $? "unknown endianness
6725  presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
6726  esac
6727
6728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working volatile" >&5
6729 $as_echo_n "checking for working volatile... " >&6; }
6730 if ${ac_cv_c_volatile+:} false; then :
6731   $as_echo_n "(cached) " >&6
6732 else
6733   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6734 /* end confdefs.h.  */
6735
6736 int
6737 main ()
6738 {
6739
6740 volatile int x;
6741 int * volatile y = (int *) 0;
6742 return !x && !y;
6743   ;
6744   return 0;
6745 }
6746 _ACEOF
6747 if ac_fn_c_try_compile "$LINENO"; then :
6748   ac_cv_c_volatile=yes
6749 else
6750   ac_cv_c_volatile=no
6751 fi
6752 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6753 fi
6754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_volatile" >&5
6755 $as_echo "$ac_cv_c_volatile" >&6; }
6756 if test $ac_cv_c_volatile = no; then
6757
6758 $as_echo "#define volatile /**/" >>confdefs.h
6759
6760 fi
6761
6762 ac_ext=c
6763 ac_cpp='$CPP $CPPFLAGS'
6764 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6765 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6766 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6767 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
6768 $as_echo_n "checking how to run the C preprocessor... " >&6; }
6769 # On Suns, sometimes $CPP names a directory.
6770 if test -n "$CPP" && test -d "$CPP"; then
6771   CPP=
6772 fi
6773 if test -z "$CPP"; then
6774   if ${ac_cv_prog_CPP+:} false; then :
6775   $as_echo_n "(cached) " >&6
6776 else
6777       # Double quotes because CPP needs to be expanded
6778     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
6779     do
6780       ac_preproc_ok=false
6781 for ac_c_preproc_warn_flag in '' yes
6782 do
6783   # Use a header file that comes with gcc, so configuring glibc
6784   # with a fresh cross-compiler works.
6785   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6786   # <limits.h> exists even on freestanding compilers.
6787   # On the NeXT, cc -E runs the code through the compiler's parser,
6788   # not just through cpp. "Syntax error" is here to catch this case.
6789   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6790 /* end confdefs.h.  */
6791 #ifdef __STDC__
6792 # include <limits.h>
6793 #else
6794 # include <assert.h>
6795 #endif
6796                      Syntax error
6797 _ACEOF
6798 if ac_fn_c_try_cpp "$LINENO"; then :
6799
6800 else
6801   # Broken: fails on valid input.
6802 continue
6803 fi
6804 rm -f conftest.err conftest.i conftest.$ac_ext
6805
6806   # OK, works on sane cases.  Now check whether nonexistent headers
6807   # can be detected and how.
6808   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6809 /* end confdefs.h.  */
6810 #include <ac_nonexistent.h>
6811 _ACEOF
6812 if ac_fn_c_try_cpp "$LINENO"; then :
6813   # Broken: success on invalid input.
6814 continue
6815 else
6816   # Passes both tests.
6817 ac_preproc_ok=:
6818 break
6819 fi
6820 rm -f conftest.err conftest.i conftest.$ac_ext
6821
6822 done
6823 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6824 rm -f conftest.i conftest.err conftest.$ac_ext
6825 if $ac_preproc_ok; then :
6826   break
6827 fi
6828
6829     done
6830     ac_cv_prog_CPP=$CPP
6831
6832 fi
6833   CPP=$ac_cv_prog_CPP
6834 else
6835   ac_cv_prog_CPP=$CPP
6836 fi
6837 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
6838 $as_echo "$CPP" >&6; }
6839 ac_preproc_ok=false
6840 for ac_c_preproc_warn_flag in '' yes
6841 do
6842   # Use a header file that comes with gcc, so configuring glibc
6843   # with a fresh cross-compiler works.
6844   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6845   # <limits.h> exists even on freestanding compilers.
6846   # On the NeXT, cc -E runs the code through the compiler's parser,
6847   # not just through cpp. "Syntax error" is here to catch this case.
6848   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6849 /* end confdefs.h.  */
6850 #ifdef __STDC__
6851 # include <limits.h>
6852 #else
6853 # include <assert.h>
6854 #endif
6855                      Syntax error
6856 _ACEOF
6857 if ac_fn_c_try_cpp "$LINENO"; then :
6858
6859 else
6860   # Broken: fails on valid input.
6861 continue
6862 fi
6863 rm -f conftest.err conftest.i conftest.$ac_ext
6864
6865   # OK, works on sane cases.  Now check whether nonexistent headers
6866   # can be detected and how.
6867   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6868 /* end confdefs.h.  */
6869 #include <ac_nonexistent.h>
6870 _ACEOF
6871 if ac_fn_c_try_cpp "$LINENO"; then :
6872   # Broken: success on invalid input.
6873 continue
6874 else
6875   # Passes both tests.
6876 ac_preproc_ok=:
6877 break
6878 fi
6879 rm -f conftest.err conftest.i conftest.$ac_ext
6880
6881 done
6882 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6883 rm -f conftest.i conftest.err conftest.$ac_ext
6884 if $ac_preproc_ok; then :
6885
6886 else
6887   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
6888 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
6889 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
6890 See \`config.log' for more details" "$LINENO" 5; }
6891 fi
6892
6893 ac_ext=c
6894 ac_cpp='$CPP $CPPFLAGS'
6895 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6896 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6897 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6898
6899
6900
6901
6902
6903
6904 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for install dir and man conventions" >&5
6905 $as_echo_n "checking for install dir and man conventions... " >&6; }
6906
6907
6908 # Check whether --with-locfile was given.
6909 if test "${with_locfile+set}" = set; then :
6910   withval=$with_locfile;
6911 else
6912   with_locfile=no
6913
6914 fi
6915
6916
6917 (                                                                       \
6918     SENTINEL_DIR="$PWD" &&                                              \
6919     cd $srcdir/ &&                                                      \
6920     case "$with_locfile" in                                             \
6921      yes|no|'')                                                         \
6922         scripts/genLocInfo -d "$SENTINEL_DIR"                           \
6923         ;;                                                              \
6924      *)                                                                 \
6925         scripts/genLocInfo -d "$SENTINEL_DIR" -f "$with_locfile"        \
6926         ;;                                                              \
6927     esac                                                                \
6928 ) > genLocInfo.i 2> genLocInfo.err
6929 . ./genLocInfo.i
6930
6931 case "$GENLOCINFO" in
6932  OK)
6933     { $as_echo "$as_me:${as_lineno-$LINENO}: result: in file $GENLOCINFOFILE" >&5
6934 $as_echo "in file $GENLOCINFOFILE" >&6; }
6935     rm genLocInfo.err genLocInfo.i
6936     ;;
6937  *)
6938     { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed." >&5
6939 $as_echo "failed." >&6; }
6940     as_fn_error $? "Problem with genLocInfo!" "$LINENO" 5
6941     ;;
6942 esac
6943
6944  if test "$CALC_TICKADJ_MS" ; then
6945   WANT_CALC_TICKADJ_MS_TRUE=
6946   WANT_CALC_TICKADJ_MS_FALSE='#'
6947 else
6948   WANT_CALC_TICKADJ_MS_TRUE='#'
6949   WANT_CALC_TICKADJ_MS_FALSE=
6950 fi
6951
6952
6953
6954
6955
6956
6957
6958
6959
6960
6961
6962
6963
6964
6965
6966
6967
6968
6969
6970
6971
6972
6973
6974
6975
6976
6977
6978
6979
6980
6981
6982
6983
6984
6985
6986
6987
6988
6989
6990
6991
6992
6993
6994  if test -z "$NTPSWEEP_NI" ; then
6995   INSTALL_NTPSWEEP_TRUE=
6996   INSTALL_NTPSWEEP_FALSE='#'
6997 else
6998   INSTALL_NTPSWEEP_TRUE='#'
6999   INSTALL_NTPSWEEP_FALSE=
7000 fi
7001
7002
7003
7004
7005
7006
7007
7008
7009
7010
7011
7012
7013
7014
7015
7016
7017
7018
7019
7020
7021
7022
7023
7024
7025
7026
7027
7028
7029
7030
7031
7032
7033
7034
7035
7036
7037
7038
7039
7040
7041
7042  if test -z "$UPDATE_LEAP_NI" ; then
7043   INSTALL_UPDATE_LEAP_TRUE=
7044   INSTALL_UPDATE_LEAP_FALSE='#'
7045 else
7046   INSTALL_UPDATE_LEAP_TRUE='#'
7047   INSTALL_UPDATE_LEAP_FALSE=
7048 fi
7049
7050
7051
7052
7053
7054
7055
7056
7057 # Expose a cross-compilation indicator to makefiles
7058  if test $build != $host; then
7059   NTP_CROSSCOMPILE_TRUE=
7060   NTP_CROSSCOMPILE_FALSE='#'
7061 else
7062   NTP_CROSSCOMPILE_TRUE='#'
7063   NTP_CROSSCOMPILE_FALSE=
7064 fi
7065
7066
7067
7068 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
7069 $as_echo_n "checking for a sed that does not truncate output... " >&6; }
7070 if ${ac_cv_path_SED+:} false; then :
7071   $as_echo_n "(cached) " >&6
7072 else
7073             ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
7074      for ac_i in 1 2 3 4 5 6 7; do
7075        ac_script="$ac_script$as_nl$ac_script"
7076      done
7077      echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
7078      { ac_script=; unset ac_script;}
7079      if test -z "$SED"; then
7080   ac_path_SED_found=false
7081   # Loop through the user's path and test for each of PROGNAME-LIST
7082   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7083 for as_dir in $PATH
7084 do
7085   IFS=$as_save_IFS
7086   test -z "$as_dir" && as_dir=.
7087     for ac_prog in sed gsed; do
7088     for ac_exec_ext in '' $ac_executable_extensions; do
7089       ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
7090       { test -f "$ac_path_SED" && $as_test_x "$ac_path_SED"; } || continue
7091 # Check for GNU ac_path_SED and select it if it is found.
7092   # Check for GNU $ac_path_SED
7093 case `"$ac_path_SED" --version 2>&1` in
7094 *GNU*)
7095   ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
7096 *)
7097   ac_count=0
7098   $as_echo_n 0123456789 >"conftest.in"
7099   while :
7100   do
7101     cat "conftest.in" "conftest.in" >"conftest.tmp"
7102     mv "conftest.tmp" "conftest.in"
7103     cp "conftest.in" "conftest.nl"
7104     $as_echo '' >> "conftest.nl"
7105     "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
7106     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
7107     as_fn_arith $ac_count + 1 && ac_count=$as_val
7108     if test $ac_count -gt ${ac_path_SED_max-0}; then
7109       # Best one so far, save it but keep looking for a better one
7110       ac_cv_path_SED="$ac_path_SED"
7111       ac_path_SED_max=$ac_count
7112     fi
7113     # 10*(2^10) chars as input seems more than enough
7114     test $ac_count -gt 10 && break
7115   done
7116   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
7117 esac
7118
7119       $ac_path_SED_found && break 3
7120     done
7121   done
7122   done
7123 IFS=$as_save_IFS
7124   if test -z "$ac_cv_path_SED"; then
7125     as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
7126   fi
7127 else
7128   ac_cv_path_SED=$SED
7129 fi
7130
7131 fi
7132 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
7133 $as_echo "$ac_cv_path_SED" >&6; }
7134  SED="$ac_cv_path_SED"
7135   rm -f conftest.sed
7136
7137 test -z "$SED" && SED=sed
7138 Xsed="$SED -e 1s/^X//"
7139
7140
7141
7142
7143
7144
7145
7146
7147
7148
7149
7150 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
7151 $as_echo_n "checking for fgrep... " >&6; }
7152 if ${ac_cv_path_FGREP+:} false; then :
7153   $as_echo_n "(cached) " >&6
7154 else
7155   if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
7156    then ac_cv_path_FGREP="$GREP -F"
7157    else
7158      if test -z "$FGREP"; then
7159   ac_path_FGREP_found=false
7160   # Loop through the user's path and test for each of PROGNAME-LIST
7161   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7162 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
7163 do
7164   IFS=$as_save_IFS
7165   test -z "$as_dir" && as_dir=.
7166     for ac_prog in fgrep; do
7167     for ac_exec_ext in '' $ac_executable_extensions; do
7168       ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
7169       { test -f "$ac_path_FGREP" && $as_test_x "$ac_path_FGREP"; } || continue
7170 # Check for GNU ac_path_FGREP and select it if it is found.
7171   # Check for GNU $ac_path_FGREP
7172 case `"$ac_path_FGREP" --version 2>&1` in
7173 *GNU*)
7174   ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
7175 *)
7176   ac_count=0
7177   $as_echo_n 0123456789 >"conftest.in"
7178   while :
7179   do
7180     cat "conftest.in" "conftest.in" >"conftest.tmp"
7181     mv "conftest.tmp" "conftest.in"
7182     cp "conftest.in" "conftest.nl"
7183     $as_echo 'FGREP' >> "conftest.nl"
7184     "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
7185     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
7186     as_fn_arith $ac_count + 1 && ac_count=$as_val
7187     if test $ac_count -gt ${ac_path_FGREP_max-0}; then
7188       # Best one so far, save it but keep looking for a better one
7189       ac_cv_path_FGREP="$ac_path_FGREP"
7190       ac_path_FGREP_max=$ac_count
7191     fi
7192     # 10*(2^10) chars as input seems more than enough
7193     test $ac_count -gt 10 && break
7194   done
7195   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
7196 esac
7197
7198       $ac_path_FGREP_found && break 3
7199     done
7200   done
7201   done
7202 IFS=$as_save_IFS
7203   if test -z "$ac_cv_path_FGREP"; then
7204     as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
7205   fi
7206 else
7207   ac_cv_path_FGREP=$FGREP
7208 fi
7209
7210    fi
7211 fi
7212 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
7213 $as_echo "$ac_cv_path_FGREP" >&6; }
7214  FGREP="$ac_cv_path_FGREP"
7215
7216
7217 test -z "$GREP" && GREP=grep
7218
7219
7220
7221
7222
7223
7224
7225
7226
7227
7228
7229
7230
7231
7232
7233
7234
7235 ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
7236 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
7237 ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
7238
7239 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
7240 $as_echo_n "checking how to print strings... " >&6; }
7241 # Test print first, because it will be a builtin if present.
7242 if test "X`( print -r -- -n ) 2>/dev/null`" = X-n && \
7243    test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
7244   ECHO='print -r --'
7245 elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
7246   ECHO='printf %s\n'
7247 else
7248   # Use this function as a fallback that always works.
7249   func_fallback_echo ()
7250   {
7251     eval 'cat <<_LTECHO_EOF
7252 $1
7253 _LTECHO_EOF'
7254   }
7255   ECHO='func_fallback_echo'
7256 fi
7257
7258 # func_echo_all arg...
7259 # Invoke $ECHO with all args, space-separated.
7260 func_echo_all ()
7261 {
7262     $ECHO ""
7263 }
7264
7265 case "$ECHO" in
7266   printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5
7267 $as_echo "printf" >&6; } ;;
7268   print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5
7269 $as_echo "print -r" >&6; } ;;
7270   *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5
7271 $as_echo "cat" >&6; } ;;
7272 esac
7273
7274
7275
7276
7277
7278
7279
7280
7281
7282
7283
7284
7285
7286
7287 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
7288 if test "x$ac_cv_type_pid_t" = xyes; then :
7289
7290 else
7291
7292 cat >>confdefs.h <<_ACEOF
7293 #define pid_t int
7294 _ACEOF
7295
7296 fi
7297
7298 ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
7299 if test "x$ac_cv_type_size_t" = xyes; then :
7300
7301 else
7302
7303 cat >>confdefs.h <<_ACEOF
7304 #define size_t unsigned int
7305 _ACEOF
7306
7307 fi
7308
7309
7310             # Check whether --enable-c99-snprintf was given.
7311 if test "${enable_c99_snprintf+set}" = set; then :
7312   enableval=$enable_c99_snprintf; force_c99_snprintf=$enableval
7313 else
7314   force_c99_snprintf=no
7315
7316 fi
7317
7318     case "$force_c99_snprintf" in
7319      yes)
7320         hw_force_rpl_snprintf=yes
7321         hw_force_rpl_vsnprintf=yes
7322     esac
7323
7324
7325
7326
7327
7328
7329   for ac_header in $ac_header_list
7330 do :
7331   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
7332 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
7333 "
7334 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
7335   cat >>confdefs.h <<_ACEOF
7336 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
7337 _ACEOF
7338
7339 fi
7340
7341 done
7342
7343
7344
7345
7346
7347
7348
7349       ac_fn_c_check_func "$LINENO" "vsnprintf" "ac_cv_func_vsnprintf"
7350 if test "x$ac_cv_func_vsnprintf" = xyes; then :
7351   hw_cv_func_vsnprintf=yes
7352 else
7353   hw_cv_func_vsnprintf=no
7354 fi
7355
7356   if test "$hw_cv_func_vsnprintf" = yes; then :
7357   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether vsnprintf is C99 compliant" >&5
7358 $as_echo_n "checking whether vsnprintf is C99 compliant... " >&6; }
7359 if ${hw_cv_func_vsnprintf_c99+:} false; then :
7360   $as_echo_n "(cached) " >&6
7361 else
7362   if test "$cross_compiling" = yes; then :
7363   hw_cv_func_vsnprintf_c99=no
7364 else
7365   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7366 /* end confdefs.h.  */
7367 #if HAVE_STDARG_H
7368           #include <stdarg.h>
7369           #endif
7370           #include <stdio.h>
7371           static int testprintf(char *buf, size_t size, const char *format, ...)
7372           {
7373             int result;
7374             va_list ap;
7375             va_start(ap, format);
7376             result = vsnprintf(buf, size, format, ap);
7377             va_end(ap);
7378             return result;
7379           }
7380 int
7381 main ()
7382 {
7383 char buf[43];
7384           if (testprintf(buf, 4, "The answer is %27.2g.", 42.0) != 42 ||
7385               testprintf(buf, 0, "No, it's %32zu.", (size_t)42) != 42 ||
7386               buf[0] != 'T' || buf[3] != '\0')
7387             return 1;
7388   ;
7389   return 0;
7390 }
7391 _ACEOF
7392 if ac_fn_c_try_run "$LINENO"; then :
7393   hw_cv_func_vsnprintf_c99=yes
7394 else
7395   hw_cv_func_vsnprintf_c99=no
7396 fi
7397 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7398   conftest.$ac_objext conftest.beam conftest.$ac_ext
7399 fi
7400
7401 fi
7402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hw_cv_func_vsnprintf_c99" >&5
7403 $as_echo "$hw_cv_func_vsnprintf_c99" >&6; }
7404 else
7405   hw_cv_func_vsnprintf_c99=no
7406 fi
7407
7408 $as_echo "#define HAVE_VSNPRINTF 1" >>confdefs.h
7409
7410   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if C99-snprintf replacement vsnprintf will be used" >&5
7411 $as_echo_n "checking if C99-snprintf replacement vsnprintf will be used... " >&6; }
7412   if test "${hw_force_rpl_vsnprintf=no}" = yes -o "$hw_cv_func_vsnprintf_c99" = no; then :
7413   hw_use_rpl_vsnprintf=yes
7414 else
7415   hw_use_rpl_vsnprintf=no
7416 fi
7417   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hw_use_rpl_vsnprintf" >&5
7418 $as_echo "$hw_use_rpl_vsnprintf" >&6; }
7419   if test "$hw_use_rpl_vsnprintf" = yes; then :
7420
7421 $as_echo "#define HW_WANT_RPL_VSNPRINTF 1" >>confdefs.h
7422
7423     if test ${hw_nodef_vsnprintf=no} = no; then :
7424
7425 $as_echo "#define vsnprintf rpl_vsnprintf" >>confdefs.h
7426
7427 fi
7428     for ac_header in inttypes.h locale.h stddef.h stdint.h
7429 do :
7430   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
7431 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
7432 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
7433   cat >>confdefs.h <<_ACEOF
7434 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
7435 _ACEOF
7436
7437 fi
7438
7439 done
7440
7441     ac_fn_c_check_member "$LINENO" "struct lconv" "decimal_point" "ac_cv_member_struct_lconv_decimal_point" "#include <locale.h>
7442 "
7443 if test "x$ac_cv_member_struct_lconv_decimal_point" = xyes; then :
7444
7445 cat >>confdefs.h <<_ACEOF
7446 #define HAVE_STRUCT_LCONV_DECIMAL_POINT 1
7447 _ACEOF
7448
7449
7450 fi
7451 ac_fn_c_check_member "$LINENO" "struct lconv" "thousands_sep" "ac_cv_member_struct_lconv_thousands_sep" "#include <locale.h>
7452 "
7453 if test "x$ac_cv_member_struct_lconv_thousands_sep" = xyes; then :
7454
7455 cat >>confdefs.h <<_ACEOF
7456 #define HAVE_STRUCT_LCONV_THOUSANDS_SEP 1
7457 _ACEOF
7458
7459
7460 fi
7461
7462
7463   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double" >&5
7464 $as_echo_n "checking for long double... " >&6; }
7465 if ${ac_cv_type_long_double+:} false; then :
7466   $as_echo_n "(cached) " >&6
7467 else
7468   if test "$GCC" = yes; then
7469        ac_cv_type_long_double=yes
7470      else
7471        cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7472 /* end confdefs.h.  */
7473 /* The Stardent Vistra knows sizeof (long double), but does
7474                  not support it.  */
7475               long double foo = 0.0L;
7476 int
7477 main ()
7478 {
7479 static int test_array [1 - 2 * !(/* On Ultrix 4.3 cc, long double is 4 and double is 8.  */
7480               sizeof (double) <= sizeof (long double))];
7481 test_array [0] = 0
7482
7483   ;
7484   return 0;
7485 }
7486 _ACEOF
7487 if ac_fn_c_try_compile "$LINENO"; then :
7488   ac_cv_type_long_double=yes
7489 else
7490   ac_cv_type_long_double=no
7491 fi
7492 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7493      fi
7494 fi
7495 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_double" >&5
7496 $as_echo "$ac_cv_type_long_double" >&6; }
7497   if test $ac_cv_type_long_double = yes; then
7498
7499 $as_echo "#define HAVE_LONG_DOUBLE 1" >>confdefs.h
7500
7501   fi
7502
7503
7504   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
7505 $as_echo_n "checking for long long int... " >&6; }
7506 if ${ac_cv_type_long_long_int+:} false; then :
7507   $as_echo_n "(cached) " >&6
7508 else
7509   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7510 /* end confdefs.h.  */
7511
7512   /* For now, do not test the preprocessor; as of 2007 there are too many
7513          implementations with broken preprocessors.  Perhaps this can
7514          be revisited in 2012.  In the meantime, code should not expect
7515          #if to work with literals wider than 32 bits.  */
7516       /* Test literals.  */
7517       long long int ll = 9223372036854775807ll;
7518       long long int nll = -9223372036854775807LL;
7519       unsigned long long int ull = 18446744073709551615ULL;
7520       /* Test constant expressions.   */
7521       typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
7522                      ? 1 : -1)];
7523       typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
7524                      ? 1 : -1)];
7525       int i = 63;
7526 int
7527 main ()
7528 {
7529 /* Test availability of runtime routines for shift and division.  */
7530       long long int llmax = 9223372036854775807ll;
7531       unsigned long long int ullmax = 18446744073709551615ull;
7532       return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
7533               | (llmax / ll) | (llmax % ll)
7534               | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
7535               | (ullmax / ull) | (ullmax % ull));
7536   ;
7537   return 0;
7538 }
7539
7540 _ACEOF
7541 if ac_fn_c_try_link "$LINENO"; then :
7542                         if test "$cross_compiling" = yes; then :
7543   ac_cv_type_long_long_int=yes
7544 else
7545   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7546 /* end confdefs.h.  */
7547 #include <limits.h>
7548                #ifndef LLONG_MAX
7549                # define HALF \
7550                         (1LL << (sizeof (long long int) * CHAR_BIT - 2))
7551                # define LLONG_MAX (HALF - 1 + HALF)
7552                #endif
7553 int
7554 main ()
7555 {
7556 long long int n = 1;
7557                int i;
7558                for (i = 0; ; i++)
7559                  {
7560                    long long int m = n << i;
7561                    if (m >> i != n)
7562                      return 1;
7563                    if (LLONG_MAX / 2 < m)
7564                      break;
7565                  }
7566                return 0;
7567   ;
7568   return 0;
7569 }
7570 _ACEOF
7571 if ac_fn_c_try_run "$LINENO"; then :
7572   ac_cv_type_long_long_int=yes
7573 else
7574   ac_cv_type_long_long_int=no
7575 fi
7576 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7577   conftest.$ac_objext conftest.beam conftest.$ac_ext
7578 fi
7579
7580 else
7581   ac_cv_type_long_long_int=no
7582 fi
7583 rm -f core conftest.err conftest.$ac_objext \
7584     conftest$ac_exeext conftest.$ac_ext
7585 fi
7586 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
7587 $as_echo "$ac_cv_type_long_long_int" >&6; }
7588   if test $ac_cv_type_long_long_int = yes; then
7589
7590 $as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
7591
7592   fi
7593
7594
7595   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
7596 $as_echo_n "checking for unsigned long long int... " >&6; }
7597 if ${ac_cv_type_unsigned_long_long_int+:} false; then :
7598   $as_echo_n "(cached) " >&6
7599 else
7600   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7601 /* end confdefs.h.  */
7602
7603   /* For now, do not test the preprocessor; as of 2007 there are too many
7604          implementations with broken preprocessors.  Perhaps this can
7605          be revisited in 2012.  In the meantime, code should not expect
7606          #if to work with literals wider than 32 bits.  */
7607       /* Test literals.  */
7608       long long int ll = 9223372036854775807ll;
7609       long long int nll = -9223372036854775807LL;
7610       unsigned long long int ull = 18446744073709551615ULL;
7611       /* Test constant expressions.   */
7612       typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
7613                      ? 1 : -1)];
7614       typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
7615                      ? 1 : -1)];
7616       int i = 63;
7617 int
7618 main ()
7619 {
7620 /* Test availability of runtime routines for shift and division.  */
7621       long long int llmax = 9223372036854775807ll;
7622       unsigned long long int ullmax = 18446744073709551615ull;
7623       return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
7624               | (llmax / ll) | (llmax % ll)
7625               | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
7626               | (ullmax / ull) | (ullmax % ull));
7627   ;
7628   return 0;
7629 }
7630
7631 _ACEOF
7632 if ac_fn_c_try_link "$LINENO"; then :
7633   ac_cv_type_unsigned_long_long_int=yes
7634 else
7635   ac_cv_type_unsigned_long_long_int=no
7636 fi
7637 rm -f core conftest.err conftest.$ac_objext \
7638     conftest$ac_exeext conftest.$ac_ext
7639 fi
7640 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
7641 $as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
7642   if test $ac_cv_type_unsigned_long_long_int = yes; then
7643
7644 $as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
7645
7646   fi
7647
7648     ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
7649 if test "x$ac_cv_type_size_t" = xyes; then :
7650
7651 else
7652
7653 cat >>confdefs.h <<_ACEOF
7654 #define size_t unsigned int
7655 _ACEOF
7656
7657 fi
7658
7659
7660
7661   ac_fn_c_check_type "$LINENO" "intmax_t" "ac_cv_type_intmax_t" "$ac_includes_default"
7662 if test "x$ac_cv_type_intmax_t" = xyes; then :
7663
7664 $as_echo "#define HAVE_INTMAX_T 1" >>confdefs.h
7665
7666 else
7667   test $ac_cv_type_long_long_int = yes \
7668        && ac_type='long long int' \
7669        || ac_type='long int'
7670
7671 cat >>confdefs.h <<_ACEOF
7672 #define intmax_t $ac_type
7673 _ACEOF
7674
7675 fi
7676
7677
7678
7679
7680   ac_fn_c_check_type "$LINENO" "uintmax_t" "ac_cv_type_uintmax_t" "$ac_includes_default"
7681 if test "x$ac_cv_type_uintmax_t" = xyes; then :
7682
7683 $as_echo "#define HAVE_UINTMAX_T 1" >>confdefs.h
7684
7685 else
7686   test $ac_cv_type_unsigned_long_long_int = yes \
7687        && ac_type='unsigned long long int' \
7688        || ac_type='unsigned long int'
7689
7690 cat >>confdefs.h <<_ACEOF
7691 #define uintmax_t $ac_type
7692 _ACEOF
7693
7694 fi
7695
7696
7697
7698   ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default"
7699 if test "x$ac_cv_type_uintptr_t" = xyes; then :
7700
7701 $as_echo "#define HAVE_UINTPTR_T 1" >>confdefs.h
7702
7703 else
7704   for ac_type in 'unsigned int' 'unsigned long int' \
7705         'unsigned long long int'; do
7706        cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7707 /* end confdefs.h.  */
7708 $ac_includes_default
7709 int
7710 main ()
7711 {
7712 static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))];
7713 test_array [0] = 0
7714
7715   ;
7716   return 0;
7717 }
7718 _ACEOF
7719 if ac_fn_c_try_compile "$LINENO"; then :
7720
7721 cat >>confdefs.h <<_ACEOF
7722 #define uintptr_t $ac_type
7723 _ACEOF
7724
7725           ac_type=
7726 fi
7727 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7728        test -z "$ac_type" && break
7729      done
7730 fi
7731
7732
7733     ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default"
7734 if test "x$ac_cv_type_ptrdiff_t" = xyes; then :
7735
7736 cat >>confdefs.h <<_ACEOF
7737 #define HAVE_PTRDIFF_T 1
7738 _ACEOF
7739
7740
7741 fi
7742
7743     for ac_func in localeconv
7744 do :
7745   ac_fn_c_check_func "$LINENO" "localeconv" "ac_cv_func_localeconv"
7746 if test "x$ac_cv_func_localeconv" = xyes; then :
7747   cat >>confdefs.h <<_ACEOF
7748 #define HAVE_LOCALECONV 1
7749 _ACEOF
7750
7751 fi
7752 done
7753
7754
7755   if test "x$_hw_cv_func_xprintf_replace_done" != xyes; then :
7756   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
7757 $as_echo_n "checking for an ANSI C-conforming const... " >&6; }
7758 if ${ac_cv_c_const+:} false; then :
7759   $as_echo_n "(cached) " >&6
7760 else
7761   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7762 /* end confdefs.h.  */
7763
7764 int
7765 main ()
7766 {
7767 /* FIXME: Include the comments suggested by Paul. */
7768 #ifndef __cplusplus
7769   /* Ultrix mips cc rejects this.  */
7770   typedef int charset[2];
7771   const charset cs;
7772   /* SunOS 4.1.1 cc rejects this.  */
7773   char const *const *pcpcc;
7774   char **ppc;
7775   /* NEC SVR4.0.2 mips cc rejects this.  */
7776   struct point {int x, y;};
7777   static struct point const zero = {0,0};
7778   /* AIX XL C 1.02.0.0 rejects this.
7779      It does not let you subtract one const X* pointer from another in
7780      an arm of an if-expression whose if-part is not a constant
7781      expression */
7782   const char *g = "string";
7783   pcpcc = &g + (g ? g-g : 0);
7784   /* HPUX 7.0 cc rejects these. */
7785   ++pcpcc;
7786   ppc = (char**) pcpcc;
7787   pcpcc = (char const *const *) ppc;
7788   { /* SCO 3.2v4 cc rejects this.  */
7789     char *t;
7790     char const *s = 0 ? (char *) 0 : (char const *) 0;
7791
7792     *t++ = 0;
7793     if (s) return 0;
7794   }
7795   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
7796     int x[] = {25, 17};
7797     const int *foo = &x[0];
7798     ++foo;
7799   }
7800   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
7801     typedef const int *iptr;
7802     iptr p = 0;
7803     ++p;
7804   }
7805   { /* AIX XL C 1.02.0.0 rejects this saying
7806        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
7807     struct s { int j; const int *ap[3]; };
7808     struct s *b; b->j = 5;
7809   }
7810   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
7811     const int foo = 10;
7812     if (!foo) return 0;
7813   }
7814   return !cs[0] && !zero.x;
7815 #endif
7816
7817   ;
7818   return 0;
7819 }
7820 _ACEOF
7821 if ac_fn_c_try_compile "$LINENO"; then :
7822   ac_cv_c_const=yes
7823 else
7824   ac_cv_c_const=no
7825 fi
7826 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7827 fi
7828 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
7829 $as_echo "$ac_cv_c_const" >&6; }
7830 if test $ac_cv_c_const = no; then
7831
7832 $as_echo "#define const /**/" >>confdefs.h
7833
7834 fi
7835
7836
7837
7838
7839     case " $LIBOBJS " in
7840   *" snprintf.$ac_objext "* ) ;;
7841   *) LIBOBJS="$LIBOBJS snprintf.$ac_objext"
7842  ;;
7843 esac
7844
7845     _hw_cv_func_xprintf_replace_done=yes
7846 fi
7847
7848 fi
7849
7850
7851     ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
7852 if test "x$ac_cv_func_snprintf" = xyes; then :
7853   hw_cv_func_snprintf=yes
7854 else
7855   hw_cv_func_snprintf=no
7856 fi
7857
7858   if test "$hw_cv_func_snprintf" = yes; then :
7859   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether snprintf is C99 compliant" >&5
7860 $as_echo_n "checking whether snprintf is C99 compliant... " >&6; }
7861 if ${hw_cv_func_snprintf_c99+:} false; then :
7862   $as_echo_n "(cached) " >&6
7863 else
7864   if test "$cross_compiling" = yes; then :
7865   hw_cv_func_snprintf_c99=no
7866 else
7867   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7868 /* end confdefs.h.  */
7869 #include <stdio.h>
7870 int
7871 main ()
7872 {
7873 char buf[43];
7874           if (snprintf(buf, 4, "The answer is %27.2g.", 42.0) != 42 ||
7875               snprintf(buf, 0, "No, it's %32zu.", (size_t)42) != 42 ||
7876               buf[0] != 'T' || buf[3] != '\0')
7877             return 1;
7878   ;
7879   return 0;
7880 }
7881 _ACEOF
7882 if ac_fn_c_try_run "$LINENO"; then :
7883   hw_cv_func_snprintf_c99=yes
7884 else
7885   hw_cv_func_snprintf_c99=no
7886 fi
7887 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7888   conftest.$ac_objext conftest.beam conftest.$ac_ext
7889 fi
7890
7891 fi
7892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hw_cv_func_snprintf_c99" >&5
7893 $as_echo "$hw_cv_func_snprintf_c99" >&6; }
7894 else
7895   hw_cv_func_snprintf_c99=no
7896 fi
7897
7898 $as_echo "#define HAVE_SNPRINTF 1" >>confdefs.h
7899
7900   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if C99-snprintf replacement snprintf will be used" >&5
7901 $as_echo_n "checking if C99-snprintf replacement snprintf will be used... " >&6; }
7902   if test "${hw_force_rpl_snprintf=no}" = yes -o "$hw_cv_func_snprintf_c99" = no; then :
7903   hw_use_rpl_snprintf=yes
7904 else
7905   hw_use_rpl_snprintf=no
7906 fi
7907   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hw_use_rpl_snprintf" >&5
7908 $as_echo "$hw_use_rpl_snprintf" >&6; }
7909   if test "$hw_use_rpl_snprintf" = yes; then :
7910
7911 $as_echo "#define HW_WANT_RPL_SNPRINTF 1" >>confdefs.h
7912
7913     if test ${hw_nodef_snprintf=no} = no; then :
7914
7915 $as_echo "#define snprintf rpl_snprintf" >>confdefs.h
7916
7917 fi
7918
7919   if test "x$_hw_cv_func_xprintf_replace_done" != xyes; then :
7920   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
7921 $as_echo_n "checking for an ANSI C-conforming const... " >&6; }
7922 if ${ac_cv_c_const+:} false; then :
7923   $as_echo_n "(cached) " >&6
7924 else
7925   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7926 /* end confdefs.h.  */
7927
7928 int
7929 main ()
7930 {
7931 /* FIXME: Include the comments suggested by Paul. */
7932 #ifndef __cplusplus
7933   /* Ultrix mips cc rejects this.  */
7934   typedef int charset[2];
7935   const charset cs;
7936   /* SunOS 4.1.1 cc rejects this.  */
7937   char const *const *pcpcc;
7938   char **ppc;
7939   /* NEC SVR4.0.2 mips cc rejects this.  */
7940   struct point {int x, y;};
7941   static struct point const zero = {0,0};
7942   /* AIX XL C 1.02.0.0 rejects this.
7943      It does not let you subtract one const X* pointer from another in
7944      an arm of an if-expression whose if-part is not a constant
7945      expression */
7946   const char *g = "string";
7947   pcpcc = &g + (g ? g-g : 0);
7948   /* HPUX 7.0 cc rejects these. */
7949   ++pcpcc;
7950   ppc = (char**) pcpcc;
7951   pcpcc = (char const *const *) ppc;
7952   { /* SCO 3.2v4 cc rejects this.  */
7953     char *t;
7954     char const *s = 0 ? (char *) 0 : (char const *) 0;
7955
7956     *t++ = 0;
7957     if (s) return 0;
7958   }
7959   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
7960     int x[] = {25, 17};
7961     const int *foo = &x[0];
7962     ++foo;
7963   }
7964   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
7965     typedef const int *iptr;
7966     iptr p = 0;
7967     ++p;
7968   }
7969   { /* AIX XL C 1.02.0.0 rejects this saying
7970        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
7971     struct s { int j; const int *ap[3]; };
7972     struct s *b; b->j = 5;
7973   }
7974   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
7975     const int foo = 10;
7976     if (!foo) return 0;
7977   }
7978   return !cs[0] && !zero.x;
7979 #endif
7980
7981   ;
7982   return 0;
7983 }
7984 _ACEOF
7985 if ac_fn_c_try_compile "$LINENO"; then :
7986   ac_cv_c_const=yes
7987 else
7988   ac_cv_c_const=no
7989 fi
7990 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7991 fi
7992 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
7993 $as_echo "$ac_cv_c_const" >&6; }
7994 if test $ac_cv_c_const = no; then
7995
7996 $as_echo "#define const /**/" >>confdefs.h
7997
7998 fi
7999
8000
8001
8002
8003     case " $LIBOBJS " in
8004   *" snprintf.$ac_objext "* ) ;;
8005   *) LIBOBJS="$LIBOBJS snprintf.$ac_objext"
8006  ;;
8007 esac
8008
8009     _hw_cv_func_xprintf_replace_done=yes
8010 fi
8011
8012 fi
8013
8014
8015
8016
8017
8018 # HMS: Save $LIBS and empty it.
8019 # any LIBS we add here should go in to LDADD_LIBNTP
8020
8021 __LIBS=$LIBS
8022 LIBS=
8023
8024
8025
8026 # [Bug 2332] because we need to know if we are using GNU ld...
8027
8028
8029 # Check whether --with-gnu-ld was given.
8030 if test "${with_gnu_ld+set}" = set; then :
8031   withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
8032 else
8033   with_gnu_ld=no
8034 fi
8035
8036 ac_prog=ld
8037 if test "$GCC" = yes; then
8038   # Check if gcc -print-prog-name=ld gives a path.
8039   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
8040 $as_echo_n "checking for ld used by $CC... " >&6; }
8041   case $host in
8042   *-*-mingw*)
8043     # gcc leaves a trailing carriage return which upsets mingw
8044     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
8045   *)
8046     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
8047   esac
8048   case $ac_prog in
8049     # Accept absolute paths.
8050     [\\/]* | ?:[\\/]*)
8051       re_direlt='/[^/][^/]*/\.\./'
8052       # Canonicalize the pathname of ld
8053       ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
8054       while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
8055         ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
8056       done
8057       test -z "$LD" && LD="$ac_prog"
8058       ;;
8059   "")
8060     # If it fails, then pretend we aren't using GCC.
8061     ac_prog=ld
8062     ;;
8063   *)
8064     # If it is relative, then search for the first ld in PATH.
8065     with_gnu_ld=unknown
8066     ;;
8067   esac
8068 elif test "$with_gnu_ld" = yes; then
8069   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
8070 $as_echo_n "checking for GNU ld... " >&6; }
8071 else
8072   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
8073 $as_echo_n "checking for non-GNU ld... " >&6; }
8074 fi
8075 if ${lt_cv_path_LD+:} false; then :
8076   $as_echo_n "(cached) " >&6
8077 else
8078   if test -z "$LD"; then
8079   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
8080   for ac_dir in $PATH; do
8081     IFS="$lt_save_ifs"
8082     test -z "$ac_dir" && ac_dir=.
8083     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
8084       lt_cv_path_LD="$ac_dir/$ac_prog"
8085       # Check to see if the program is GNU ld.  I'd rather use --version,
8086       # but apparently some variants of GNU ld only accept -v.
8087       # Break only if it was the GNU/non-GNU ld that we prefer.
8088       case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
8089       *GNU* | *'with BFD'*)
8090         test "$with_gnu_ld" != no && break
8091         ;;
8092       *)
8093         test "$with_gnu_ld" != yes && break
8094         ;;
8095       esac
8096     fi
8097   done
8098   IFS="$lt_save_ifs"
8099 else
8100   lt_cv_path_LD="$LD" # Let the user override the test with a path.
8101 fi
8102 fi
8103
8104 LD="$lt_cv_path_LD"
8105 if test -n "$LD"; then
8106   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
8107 $as_echo "$LD" >&6; }
8108 else
8109   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8110 $as_echo "no" >&6; }
8111 fi
8112 test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
8113 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
8114 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
8115 if ${lt_cv_prog_gnu_ld+:} false; then :
8116   $as_echo_n "(cached) " >&6
8117 else
8118   # I'd rather use --version here, but apparently some GNU lds only accept -v.
8119 case `$LD -v 2>&1 </dev/null` in
8120 *GNU* | *'with BFD'*)
8121   lt_cv_prog_gnu_ld=yes
8122   ;;
8123 *)
8124   lt_cv_prog_gnu_ld=no
8125   ;;
8126 esac
8127 fi
8128 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
8129 $as_echo "$lt_cv_prog_gnu_ld" >&6; }
8130 with_gnu_ld=$lt_cv_prog_gnu_ld
8131
8132
8133
8134
8135
8136
8137
8138
8139
8140
8141
8142 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for directory path separator" >&5
8143 $as_echo_n "checking for directory path separator... " >&6; }
8144 if ${ntp_cv_dir_sep+:} false; then :
8145   $as_echo_n "(cached) " >&6
8146 else
8147
8148         case "$ntp_cv_dir_sep" in
8149          '')
8150             case "$host_os" in
8151              *djgpp | *mingw32* | *emx*)
8152                 ntp_cv_dir_sep="'\\'"
8153                 ;;
8154              *)
8155                 ntp_cv_dir_sep="'/'"
8156                 ;;
8157             esac
8158         esac
8159
8160
8161 fi
8162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_dir_sep" >&5
8163 $as_echo "$ntp_cv_dir_sep" >&6; }
8164
8165 cat >>confdefs.h <<_ACEOF
8166 #define DIR_SEP $ntp_cv_dir_sep
8167 _ACEOF
8168
8169
8170
8171     NTP_ORIG_LIBS="$LIBS"
8172
8173 # Check whether --with-lineeditlibs was given.
8174 if test "${with_lineeditlibs+set}" = set; then :
8175   withval=$with_lineeditlibs; use_lineeditlibs="$withval"
8176 else
8177   use_lineeditlibs="edit,editline"
8178
8179 fi
8180
8181     { $as_echo "$as_me:${as_lineno-$LINENO}: checking line editing libraries" >&5
8182 $as_echo_n "checking line editing libraries... " >&6; }
8183     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $use_lineeditlibs" >&5
8184 $as_echo "$use_lineeditlibs" >&6; }
8185     case "$use_lineeditlibs" in
8186      no)
8187         ntp_lib_lineedit=no
8188         ;;
8189      *)
8190         for lineedit_lib in `echo $use_lineeditlibs | sed -e 's/,/ /'`; do
8191             for term_lib in "" termcap curses ncurses; do
8192                 case "$term_lib" in
8193                  '')
8194                     TRY_LIB="-l$lineedit_lib"
8195                     ;;
8196                  *)
8197                     TRY_LIB="-l$lineedit_lib -l$term_lib"
8198                     ;;
8199                 esac
8200                 LIBS="$NTP_ORIG_LIBS $TRY_LIB"
8201                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for readline() with $TRY_LIB" >&5
8202 $as_echo_n "checking for readline() with $TRY_LIB... " >&6; }
8203                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8204 /* end confdefs.h.  */
8205
8206 /* Override any GCC internal prototype to avoid an error.
8207    Use char because int might match the return type of a GCC
8208    builtin and then its argument prototype would still apply.  */
8209 #ifdef __cplusplus
8210 extern "C"
8211 #endif
8212 char readline ();
8213 int
8214 main ()
8215 {
8216 return readline ();
8217   ;
8218   return 0;
8219 }
8220 _ACEOF
8221 if ac_fn_c_try_link "$LINENO"; then :
8222   ntp_lib_lineedit="$TRY_LIB"
8223 fi
8224 rm -f core conftest.err conftest.$ac_objext \
8225     conftest$ac_exeext conftest.$ac_ext
8226                 case "$ntp_lib_lineedit" in
8227                  '')
8228                     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8229 $as_echo "no" >&6; }
8230                     ;;
8231                  *)
8232                     # Use readline()
8233                     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8234 $as_echo "yes" >&6; }
8235                     break
8236                 esac
8237                 case "$term_lib" in
8238                  '')
8239                     # do not try el_gets without a terminal library
8240                     ;;
8241                  *)
8242                     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for el_gets() with $TRY_LIB" >&5
8243 $as_echo_n "checking for el_gets() with $TRY_LIB... " >&6; }
8244                     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8245 /* end confdefs.h.  */
8246
8247 /* Override any GCC internal prototype to avoid an error.
8248    Use char because int might match the return type of a GCC
8249    builtin and then its argument prototype would still apply.  */
8250 #ifdef __cplusplus
8251 extern "C"
8252 #endif
8253 char el_gets ();
8254 int
8255 main ()
8256 {
8257 return el_gets ();
8258   ;
8259   return 0;
8260 }
8261 _ACEOF
8262 if ac_fn_c_try_link "$LINENO"; then :
8263   ntp_lib_lineedit="$TRY_LIB"
8264 fi
8265 rm -f core conftest.err conftest.$ac_objext \
8266     conftest$ac_exeext conftest.$ac_ext
8267                     case "$ntp_lib_lineedit" in
8268                      '')
8269                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8270 $as_echo "no" >&6; }
8271                         ;;
8272                      *) # Use el_gets()
8273                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8274 $as_echo "yes" >&6; }
8275                         break
8276                         ;;
8277                     esac        # $ntp_lib_lineedit
8278                 esac            # $term_lib
8279             done
8280             case "$ntp_lib_lineedit" in
8281              '')
8282                 ;;
8283              *)
8284                 break
8285                 ;;
8286             esac
8287         done
8288         LIBS="$NTP_ORIG_LIBS"
8289         ;;
8290     esac        # $use_lineeditlibs
8291
8292     case "$ntp_lib_lineedit" in
8293      '')
8294         ntp_lib_lineedit="no"
8295         ;;
8296      no)
8297         ;;
8298      *)
8299         EDITLINE_LIBS="$ntp_lib_lineedit"
8300
8301         ;;
8302     esac        # $ntp_lib_lineedit
8303
8304     case "$ntp_lib_lineedit" in
8305      no)
8306         ;;
8307      *)
8308         for ac_header in readline.h readline/readline.h histedit.h
8309 do :
8310   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8311 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
8312 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
8313   cat >>confdefs.h <<_ACEOF
8314 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8315 _ACEOF
8316
8317 fi
8318
8319 done
8320
8321         for ac_header in history.h readline/history.h
8322 do :
8323   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8324 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
8325 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
8326   cat >>confdefs.h <<_ACEOF
8327 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8328 _ACEOF
8329
8330 fi
8331
8332 done
8333
8334
8335         case "$ac_cv_header_histedit_h" in
8336          yes)
8337             { $as_echo "$as_me:${as_lineno-$LINENO}: checking number of arguments to el_init()" >&5
8338 $as_echo_n "checking number of arguments to el_init()... " >&6; }
8339 if ${ntp_cv_el_init_args+:} false; then :
8340   $as_echo_n "(cached) " >&6
8341 else
8342   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8343 /* end confdefs.h.  */
8344
8345                             #include <stdio.h>
8346                             #include <histedit.h>
8347
8348 int
8349 main ()
8350 {
8351
8352                             el_init("conftest", stdin, stdout, stderr);
8353
8354
8355   ;
8356   return 0;
8357 }
8358 _ACEOF
8359 if ac_fn_c_try_compile "$LINENO"; then :
8360   ntp_cv_el_init_args=4
8361 else
8362   ntp_cv_el_init_args=3
8363
8364 fi
8365 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8366
8367 fi
8368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_el_init_args" >&5
8369 $as_echo "$ntp_cv_el_init_args" >&6; }
8370
8371 cat >>confdefs.h <<_ACEOF
8372 #define EL_INIT_ARGS $ntp_cv_el_init_args
8373 _ACEOF
8374
8375         esac
8376
8377         { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readline supports history" >&5
8378 $as_echo_n "checking whether readline supports history... " >&6; }
8379
8380         ntp_lib_lineedit_history="no"
8381         ORIG_LIBS="$LIBS"
8382         LIBS="$ORIG_LIBS $ntp_lib_lineedit"
8383         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8384 /* end confdefs.h.  */
8385
8386 /* Override any GCC internal prototype to avoid an error.
8387    Use char because int might match the return type of a GCC
8388    builtin and then its argument prototype would still apply.  */
8389 #ifdef __cplusplus
8390 extern "C"
8391 #endif
8392 char add_history ();
8393 int
8394 main ()
8395 {
8396 return add_history ();
8397   ;
8398   return 0;
8399 }
8400 _ACEOF
8401 if ac_fn_c_try_link "$LINENO"; then :
8402   ntp_lib_lineedit_history="yes"
8403 fi
8404 rm -f core conftest.err conftest.$ac_objext \
8405     conftest$ac_exeext conftest.$ac_ext
8406         LIBS="$ORIG_LIBS"
8407
8408         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_lib_lineedit_history" >&5
8409 $as_echo "$ntp_lib_lineedit_history" >&6; }
8410
8411         case "$ntp_lib_lineedit_history" in
8412          yes)
8413
8414 $as_echo "#define HAVE_READLINE_HISTORY 1" >>confdefs.h
8415
8416         esac
8417     esac        # $ntp_lib_lineedit
8418     { NTP_ORIG_LIBS=; unset NTP_ORIG_LIBS;}
8419     { ORIG_LIBS=; unset ORIG_LIBS;}
8420     { TRY_LIB=; unset TRY_LIB;}
8421     { use_lineeditlibs=; unset use_lineeditlibs;}
8422
8423
8424 LIBM=
8425 case "$host" in
8426  *-*-darwin*)
8427     ;;
8428  *)
8429     _libs=$LIBS
8430     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing cos" >&5
8431 $as_echo_n "checking for library containing cos... " >&6; }
8432 if ${ac_cv_search_cos+:} false; then :
8433   $as_echo_n "(cached) " >&6
8434 else
8435   ac_func_search_save_LIBS=$LIBS
8436 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8437 /* end confdefs.h.  */
8438
8439 /* Override any GCC internal prototype to avoid an error.
8440    Use char because int might match the return type of a GCC
8441    builtin and then its argument prototype would still apply.  */
8442 #ifdef __cplusplus
8443 extern "C"
8444 #endif
8445 char cos ();
8446 int
8447 main ()
8448 {
8449 return cos ();
8450   ;
8451   return 0;
8452 }
8453 _ACEOF
8454 for ac_lib in '' m; do
8455   if test -z "$ac_lib"; then
8456     ac_res="none required"
8457   else
8458     ac_res=-l$ac_lib
8459     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8460   fi
8461   if ac_fn_c_try_link "$LINENO"; then :
8462   ac_cv_search_cos=$ac_res
8463 fi
8464 rm -f core conftest.err conftest.$ac_objext \
8465     conftest$ac_exeext
8466   if ${ac_cv_search_cos+:} false; then :
8467   break
8468 fi
8469 done
8470 if ${ac_cv_search_cos+:} false; then :
8471
8472 else
8473   ac_cv_search_cos=no
8474 fi
8475 rm conftest.$ac_ext
8476 LIBS=$ac_func_search_save_LIBS
8477 fi
8478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_cos" >&5
8479 $as_echo "$ac_cv_search_cos" >&6; }
8480 ac_res=$ac_cv_search_cos
8481 if test "$ac_res" != no; then :
8482   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8483   LIBM="-lm"
8484 fi
8485
8486     LIBS=$_libs
8487     ;;
8488 esac
8489
8490 { _libs=; unset _libs;}
8491
8492
8493 for ac_header in vfork.h
8494 do :
8495   ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
8496 if test "x$ac_cv_header_vfork_h" = xyes; then :
8497   cat >>confdefs.h <<_ACEOF
8498 #define HAVE_VFORK_H 1
8499 _ACEOF
8500
8501 fi
8502
8503 done
8504
8505 for ac_func in fork vfork
8506 do :
8507   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
8508 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
8509 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
8510   cat >>confdefs.h <<_ACEOF
8511 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
8512 _ACEOF
8513
8514 fi
8515 done
8516
8517 if test "x$ac_cv_func_fork" = xyes; then
8518   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
8519 $as_echo_n "checking for working fork... " >&6; }
8520 if ${ac_cv_func_fork_works+:} false; then :
8521   $as_echo_n "(cached) " >&6
8522 else
8523   if test "$cross_compiling" = yes; then :
8524   ac_cv_func_fork_works=cross
8525 else
8526   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8527 /* end confdefs.h.  */
8528 $ac_includes_default
8529 int
8530 main ()
8531 {
8532
8533           /* By Ruediger Kuhlmann. */
8534           return fork () < 0;
8535
8536   ;
8537   return 0;
8538 }
8539 _ACEOF
8540 if ac_fn_c_try_run "$LINENO"; then :
8541   ac_cv_func_fork_works=yes
8542 else
8543   ac_cv_func_fork_works=no
8544 fi
8545 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8546   conftest.$ac_objext conftest.beam conftest.$ac_ext
8547 fi
8548
8549 fi
8550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
8551 $as_echo "$ac_cv_func_fork_works" >&6; }
8552
8553 else
8554   ac_cv_func_fork_works=$ac_cv_func_fork
8555 fi
8556 if test "x$ac_cv_func_fork_works" = xcross; then
8557   case $host in
8558     *-*-amigaos* | *-*-msdosdjgpp*)
8559       # Override, as these systems have only a dummy fork() stub
8560       ac_cv_func_fork_works=no
8561       ;;
8562     *)
8563       ac_cv_func_fork_works=yes
8564       ;;
8565   esac
8566   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
8567 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
8568 fi
8569 ac_cv_func_vfork_works=$ac_cv_func_vfork
8570 if test "x$ac_cv_func_vfork" = xyes; then
8571   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
8572 $as_echo_n "checking for working vfork... " >&6; }
8573 if ${ac_cv_func_vfork_works+:} false; then :
8574   $as_echo_n "(cached) " >&6
8575 else
8576   if test "$cross_compiling" = yes; then :
8577   ac_cv_func_vfork_works=cross
8578 else
8579   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8580 /* end confdefs.h.  */
8581 /* Thanks to Paul Eggert for this test.  */
8582 $ac_includes_default
8583 #include <sys/wait.h>
8584 #ifdef HAVE_VFORK_H
8585 # include <vfork.h>
8586 #endif
8587 /* On some sparc systems, changes by the child to local and incoming
8588    argument registers are propagated back to the parent.  The compiler
8589    is told about this with #include <vfork.h>, but some compilers
8590    (e.g. gcc -O) don't grok <vfork.h>.  Test for this by using a
8591    static variable whose address is put into a register that is
8592    clobbered by the vfork.  */
8593 static void
8594 #ifdef __cplusplus
8595 sparc_address_test (int arg)
8596 # else
8597 sparc_address_test (arg) int arg;
8598 #endif
8599 {
8600   static pid_t child;
8601   if (!child) {
8602     child = vfork ();
8603     if (child < 0) {
8604       perror ("vfork");
8605       _exit(2);
8606     }
8607     if (!child) {
8608       arg = getpid();
8609       write(-1, "", 0);
8610       _exit (arg);
8611     }
8612   }
8613 }
8614
8615 int
8616 main ()
8617 {
8618   pid_t parent = getpid ();
8619   pid_t child;
8620
8621   sparc_address_test (0);
8622
8623   child = vfork ();
8624
8625   if (child == 0) {
8626     /* Here is another test for sparc vfork register problems.  This
8627        test uses lots of local variables, at least as many local
8628        variables as main has allocated so far including compiler
8629        temporaries.  4 locals are enough for gcc 1.40.3 on a Solaris
8630        4.1.3 sparc, but we use 8 to be safe.  A buggy compiler should
8631        reuse the register of parent for one of the local variables,
8632        since it will think that parent can't possibly be used any more
8633        in this routine.  Assigning to the local variable will thus
8634        munge parent in the parent process.  */
8635     pid_t
8636       p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
8637       p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
8638     /* Convince the compiler that p..p7 are live; otherwise, it might
8639        use the same hardware register for all 8 local variables.  */
8640     if (p != p1 || p != p2 || p != p3 || p != p4
8641         || p != p5 || p != p6 || p != p7)
8642       _exit(1);
8643
8644     /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
8645        from child file descriptors.  If the child closes a descriptor
8646        before it execs or exits, this munges the parent's descriptor
8647        as well.  Test for this by closing stdout in the child.  */
8648     _exit(close(fileno(stdout)) != 0);
8649   } else {
8650     int status;
8651     struct stat st;
8652
8653     while (wait(&status) != child)
8654       ;
8655     return (
8656          /* Was there some problem with vforking?  */
8657          child < 0
8658
8659          /* Did the child fail?  (This shouldn't happen.)  */
8660          || status
8661
8662          /* Did the vfork/compiler bug occur?  */
8663          || parent != getpid()
8664
8665          /* Did the file descriptor bug occur?  */
8666          || fstat(fileno(stdout), &st) != 0
8667          );
8668   }
8669 }
8670 _ACEOF
8671 if ac_fn_c_try_run "$LINENO"; then :
8672   ac_cv_func_vfork_works=yes
8673 else
8674   ac_cv_func_vfork_works=no
8675 fi
8676 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8677   conftest.$ac_objext conftest.beam conftest.$ac_ext
8678 fi
8679
8680 fi
8681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
8682 $as_echo "$ac_cv_func_vfork_works" >&6; }
8683
8684 fi;
8685 if test "x$ac_cv_func_fork_works" = xcross; then
8686   ac_cv_func_vfork_works=$ac_cv_func_vfork
8687   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
8688 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
8689 fi
8690
8691 if test "x$ac_cv_func_vfork_works" = xyes; then
8692
8693 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
8694
8695 else
8696
8697 $as_echo "#define vfork fork" >>confdefs.h
8698
8699 fi
8700 if test "x$ac_cv_func_fork_works" = xyes; then
8701
8702 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
8703
8704 fi
8705
8706 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
8707 # for constant arguments.  Useless!
8708 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
8709 $as_echo_n "checking for working alloca.h... " >&6; }
8710 if ${ac_cv_working_alloca_h+:} false; then :
8711   $as_echo_n "(cached) " >&6
8712 else
8713   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8714 /* end confdefs.h.  */
8715 #include <alloca.h>
8716 int
8717 main ()
8718 {
8719 char *p = (char *) alloca (2 * sizeof (int));
8720                           if (p) return 0;
8721   ;
8722   return 0;
8723 }
8724 _ACEOF
8725 if ac_fn_c_try_link "$LINENO"; then :
8726   ac_cv_working_alloca_h=yes
8727 else
8728   ac_cv_working_alloca_h=no
8729 fi
8730 rm -f core conftest.err conftest.$ac_objext \
8731     conftest$ac_exeext conftest.$ac_ext
8732 fi
8733 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
8734 $as_echo "$ac_cv_working_alloca_h" >&6; }
8735 if test $ac_cv_working_alloca_h = yes; then
8736
8737 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
8738
8739 fi
8740
8741 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
8742 $as_echo_n "checking for alloca... " >&6; }
8743 if ${ac_cv_func_alloca_works+:} false; then :
8744   $as_echo_n "(cached) " >&6
8745 else
8746   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8747 /* end confdefs.h.  */
8748 #ifdef __GNUC__
8749 # define alloca __builtin_alloca
8750 #else
8751 # ifdef _MSC_VER
8752 #  include <malloc.h>
8753 #  define alloca _alloca
8754 # else
8755 #  ifdef HAVE_ALLOCA_H
8756 #   include <alloca.h>
8757 #  else
8758 #   ifdef _AIX
8759  #pragma alloca
8760 #   else
8761 #    ifndef alloca /* predefined by HP cc +Olibcalls */
8762 void *alloca (size_t);
8763 #    endif
8764 #   endif
8765 #  endif
8766 # endif
8767 #endif
8768
8769 int
8770 main ()
8771 {
8772 char *p = (char *) alloca (1);
8773                                     if (p) return 0;
8774   ;
8775   return 0;
8776 }
8777 _ACEOF
8778 if ac_fn_c_try_link "$LINENO"; then :
8779   ac_cv_func_alloca_works=yes
8780 else
8781   ac_cv_func_alloca_works=no
8782 fi
8783 rm -f core conftest.err conftest.$ac_objext \
8784     conftest$ac_exeext conftest.$ac_ext
8785 fi
8786 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
8787 $as_echo "$ac_cv_func_alloca_works" >&6; }
8788
8789 if test $ac_cv_func_alloca_works = yes; then
8790
8791 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
8792
8793 else
8794   # The SVR3 libPW and SVR4 libucb both contain incompatible functions
8795 # that cause trouble.  Some versions do not even contain alloca or
8796 # contain a buggy version.  If you still want to use their alloca,
8797 # use ar to extract alloca.o from them instead of compiling alloca.c.
8798
8799 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
8800
8801 $as_echo "#define C_ALLOCA 1" >>confdefs.h
8802
8803
8804 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5
8805 $as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; }
8806 if ${ac_cv_os_cray+:} false; then :
8807   $as_echo_n "(cached) " >&6
8808 else
8809   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8810 /* end confdefs.h.  */
8811 #if defined CRAY && ! defined CRAY2
8812 webecray
8813 #else
8814 wenotbecray
8815 #endif
8816
8817 _ACEOF
8818 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8819   $EGREP "webecray" >/dev/null 2>&1; then :
8820   ac_cv_os_cray=yes
8821 else
8822   ac_cv_os_cray=no
8823 fi
8824 rm -f conftest*
8825
8826 fi
8827 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
8828 $as_echo "$ac_cv_os_cray" >&6; }
8829 if test $ac_cv_os_cray = yes; then
8830   for ac_func in _getb67 GETB67 getb67; do
8831     as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
8832 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
8833 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
8834
8835 cat >>confdefs.h <<_ACEOF
8836 #define CRAY_STACKSEG_END $ac_func
8837 _ACEOF
8838
8839     break
8840 fi
8841
8842   done
8843 fi
8844
8845 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
8846 $as_echo_n "checking stack direction for C alloca... " >&6; }
8847 if ${ac_cv_c_stack_direction+:} false; then :
8848   $as_echo_n "(cached) " >&6
8849 else
8850   if test "$cross_compiling" = yes; then :
8851   ac_cv_c_stack_direction=0
8852 else
8853   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8854 /* end confdefs.h.  */
8855 $ac_includes_default
8856 int
8857 find_stack_direction ()
8858 {
8859   static char *addr = 0;
8860   auto char dummy;
8861   if (addr == 0)
8862     {
8863       addr = &dummy;
8864       return find_stack_direction ();
8865     }
8866   else
8867     return (&dummy > addr) ? 1 : -1;
8868 }
8869
8870 int
8871 main ()
8872 {
8873   return find_stack_direction () < 0;
8874 }
8875 _ACEOF
8876 if ac_fn_c_try_run "$LINENO"; then :
8877   ac_cv_c_stack_direction=1
8878 else
8879   ac_cv_c_stack_direction=-1
8880 fi
8881 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8882   conftest.$ac_objext conftest.beam conftest.$ac_ext
8883 fi
8884
8885 fi
8886 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
8887 $as_echo "$ac_cv_c_stack_direction" >&6; }
8888 cat >>confdefs.h <<_ACEOF
8889 #define STACK_DIRECTION $ac_cv_c_stack_direction
8890 _ACEOF
8891
8892
8893 fi
8894
8895 ac_fn_c_check_decl "$LINENO" "strerror_r" "ac_cv_have_decl_strerror_r" "$ac_includes_default"
8896 if test "x$ac_cv_have_decl_strerror_r" = xyes; then :
8897   ac_have_decl=1
8898 else
8899   ac_have_decl=0
8900 fi
8901
8902 cat >>confdefs.h <<_ACEOF
8903 #define HAVE_DECL_STRERROR_R $ac_have_decl
8904 _ACEOF
8905
8906 for ac_func in strerror_r
8907 do :
8908   ac_fn_c_check_func "$LINENO" "strerror_r" "ac_cv_func_strerror_r"
8909 if test "x$ac_cv_func_strerror_r" = xyes; then :
8910   cat >>confdefs.h <<_ACEOF
8911 #define HAVE_STRERROR_R 1
8912 _ACEOF
8913
8914 fi
8915 done
8916
8917 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strerror_r returns char *" >&5
8918 $as_echo_n "checking whether strerror_r returns char *... " >&6; }
8919 if ${ac_cv_func_strerror_r_char_p+:} false; then :
8920   $as_echo_n "(cached) " >&6
8921 else
8922
8923     ac_cv_func_strerror_r_char_p=no
8924     if test $ac_cv_have_decl_strerror_r = yes; then
8925       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8926 /* end confdefs.h.  */
8927 $ac_includes_default
8928 int
8929 main ()
8930 {
8931
8932           char buf[100];
8933           char x = *strerror_r (0, buf, sizeof buf);
8934           char *p = strerror_r (0, buf, sizeof buf);
8935           return !p || x;
8936
8937   ;
8938   return 0;
8939 }
8940 _ACEOF
8941 if ac_fn_c_try_compile "$LINENO"; then :
8942   ac_cv_func_strerror_r_char_p=yes
8943 fi
8944 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8945     else
8946       # strerror_r is not declared.  Choose between
8947       # systems that have relatively inaccessible declarations for the
8948       # function.  BeOS and DEC UNIX 4.0 fall in this category, but the
8949       # former has a strerror_r that returns char*, while the latter
8950       # has a strerror_r that returns `int'.
8951       # This test should segfault on the DEC system.
8952       if test "$cross_compiling" = yes; then :
8953   :
8954 else
8955   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8956 /* end confdefs.h.  */
8957 $ac_includes_default
8958         extern char *strerror_r ();
8959 int
8960 main ()
8961 {
8962 char buf[100];
8963           char x = *strerror_r (0, buf, sizeof buf);
8964           return ! isalpha (x);
8965   ;
8966   return 0;
8967 }
8968 _ACEOF
8969 if ac_fn_c_try_run "$LINENO"; then :
8970   ac_cv_func_strerror_r_char_p=yes
8971 fi
8972 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8973   conftest.$ac_objext conftest.beam conftest.$ac_ext
8974 fi
8975
8976     fi
8977
8978 fi
8979 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strerror_r_char_p" >&5
8980 $as_echo "$ac_cv_func_strerror_r_char_p" >&6; }
8981 if test $ac_cv_func_strerror_r_char_p = yes; then
8982
8983 $as_echo "#define STRERROR_R_CHAR_P 1" >>confdefs.h
8984
8985 fi
8986
8987
8988 ac_busted_vpath_in_make=no
8989 case "$build" in
8990  *-*-irix6.1*)  # 64 bit only
8991     # busted vpath?
8992     ;;
8993  *-*-irix6*)    # 6.2 (and later?)
8994     ac_busted_vpath_in_make=yes
8995     ;;
8996  *-*-solaris2.5.1)
8997     ac_busted_vpath_in_make=yes
8998     ;;
8999  *-*-unicosmp*)
9000     ac_busted_vpath_in_make=yes
9001     ;;
9002 esac
9003
9004 case "$ac_busted_vpath_in_make$srcdir" in
9005  yes.|no*)
9006     ;;
9007  *) case "`${MAKE-make} -v -f /dev/null 2>/dev/null | grep 'GNU Make'`" in
9008      '')
9009         as_fn_error $? "building outside of the main directory requires GNU make" "$LINENO" 5
9010     esac
9011     ;;
9012 esac
9013
9014 case "$host" in
9015  *-*-aix4*)
9016         # Bug 2516:
9017         # Was *-*-aix[[4-9]]*
9018         # XXX only verified thru AIX6.  But...
9019         # Ken Link says this is fine for AIX 5.3 and 7.1, and sees no reason
9020         # that this support would be in 5.3, removed in 6, and added back.
9021         #
9022         # (prr) aix 4.1 doesn't have clock_settime, but in aix 4.3 it's a stub
9023         # (returning ENOSYS).  I didn't check 4.2.  If, in the future,
9024         # IBM pulls its thumbs out long enough to implement clock_settime,
9025         # this conditional will need to change.  Maybe use AC_TRY_RUN
9026         # instead to try to set the time to itself and check errno.
9027     ;;
9028  *)
9029     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
9030 $as_echo_n "checking for library containing clock_gettime... " >&6; }
9031 if ${ac_cv_search_clock_gettime+:} false; then :
9032   $as_echo_n "(cached) " >&6
9033 else
9034   ac_func_search_save_LIBS=$LIBS
9035 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9036 /* end confdefs.h.  */
9037
9038 /* Override any GCC internal prototype to avoid an error.
9039    Use char because int might match the return type of a GCC
9040    builtin and then its argument prototype would still apply.  */
9041 #ifdef __cplusplus
9042 extern "C"
9043 #endif
9044 char clock_gettime ();
9045 int
9046 main ()
9047 {
9048 return clock_gettime ();
9049   ;
9050   return 0;
9051 }
9052 _ACEOF
9053 for ac_lib in '' rt; do
9054   if test -z "$ac_lib"; then
9055     ac_res="none required"
9056   else
9057     ac_res=-l$ac_lib
9058     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
9059   fi
9060   if ac_fn_c_try_link "$LINENO"; then :
9061   ac_cv_search_clock_gettime=$ac_res
9062 fi
9063 rm -f core conftest.err conftest.$ac_objext \
9064     conftest$ac_exeext
9065   if ${ac_cv_search_clock_gettime+:} false; then :
9066   break
9067 fi
9068 done
9069 if ${ac_cv_search_clock_gettime+:} false; then :
9070
9071 else
9072   ac_cv_search_clock_gettime=no
9073 fi
9074 rm conftest.$ac_ext
9075 LIBS=$ac_func_search_save_LIBS
9076 fi
9077 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
9078 $as_echo "$ac_cv_search_clock_gettime" >&6; }
9079 ac_res=$ac_cv_search_clock_gettime
9080 if test "$ac_res" != no; then :
9081   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
9082   case "$ac_cv_search_clock_gettime" in
9083  'none required') ;;
9084  no) ;;
9085  *) LDADD_LIBNTP="$ac_cv_search_clock_gettime $LDADD_LIBNTP" ;;
9086  esac
9087
9088 fi
9089
9090     for ac_func in clock_getres clock_gettime clock_settime
9091 do :
9092   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
9093 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
9094 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
9095   cat >>confdefs.h <<_ACEOF
9096 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
9097 _ACEOF
9098
9099 fi
9100 done
9101
9102     ;;
9103 esac
9104
9105 for ac_func in getclock stime timegm strlcpy strlcat
9106 do :
9107   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
9108 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
9109 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
9110   cat >>confdefs.h <<_ACEOF
9111 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
9112 _ACEOF
9113
9114 fi
9115 done
9116
9117
9118 # Bug 2713
9119 LDADD_LIBUTIL=
9120
9121 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing snprintb" >&5
9122 $as_echo_n "checking for library containing snprintb... " >&6; }
9123 if ${ac_cv_search_snprintb+:} false; then :
9124   $as_echo_n "(cached) " >&6
9125 else
9126   ac_func_search_save_LIBS=$LIBS
9127 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9128 /* end confdefs.h.  */
9129
9130 /* Override any GCC internal prototype to avoid an error.
9131    Use char because int might match the return type of a GCC
9132    builtin and then its argument prototype would still apply.  */
9133 #ifdef __cplusplus
9134 extern "C"
9135 #endif
9136 char snprintb ();
9137 int
9138 main ()
9139 {
9140 return snprintb ();
9141   ;
9142   return 0;
9143 }
9144 _ACEOF
9145 for ac_lib in '' util; do
9146   if test -z "$ac_lib"; then
9147     ac_res="none required"
9148   else
9149     ac_res=-l$ac_lib
9150     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
9151   fi
9152   if ac_fn_c_try_link "$LINENO"; then :
9153   ac_cv_search_snprintb=$ac_res
9154 fi
9155 rm -f core conftest.err conftest.$ac_objext \
9156     conftest$ac_exeext
9157   if ${ac_cv_search_snprintb+:} false; then :
9158   break
9159 fi
9160 done
9161 if ${ac_cv_search_snprintb+:} false; then :
9162
9163 else
9164   ac_cv_search_snprintb=no
9165 fi
9166 rm conftest.$ac_ext
9167 LIBS=$ac_func_search_save_LIBS
9168 fi
9169 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_snprintb" >&5
9170 $as_echo "$ac_cv_search_snprintb" >&6; }
9171 ac_res=$ac_cv_search_snprintb
9172 if test "$ac_res" != no; then :
9173   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
9174   case "$ac_cv_search_snprintb" in
9175  'none required') ;;
9176  no) ;;
9177  *) LDADD_LIBUTIL="$ac_cv_search_snprintb $LDADD_LIBUTIL" ;;
9178  esac
9179
9180 $as_echo "#define USE_SNPRINTB 1" >>confdefs.h
9181
9182 fi
9183
9184
9185 #
9186 for ac_header in errno.h sys/socket.h sys/types.h time.h
9187 do :
9188   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9189 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
9190 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
9191   cat >>confdefs.h <<_ACEOF
9192 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9193 _ACEOF
9194
9195 fi
9196
9197 done
9198
9199 for ac_header in net/if.h
9200 do :
9201   ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "
9202     #ifdef HAVE_SYS_SOCKET_H
9203     # include <sys/socket.h>
9204     #endif
9205
9206 "
9207 if test "x$ac_cv_header_net_if_h" = xyes; then :
9208   cat >>confdefs.h <<_ACEOF
9209 #define HAVE_NET_IF_H 1
9210 _ACEOF
9211
9212 fi
9213
9214 done
9215
9216 case "$host" in
9217  *-hp-hpux*)
9218     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if net/if.h requires mpinfou predeclaration" >&5
9219 $as_echo_n "checking if net/if.h requires mpinfou predeclaration... " >&6; }
9220 if ${ntp_cv_predecl_mpinfou+:} false; then :
9221   $as_echo_n "(cached) " >&6
9222 else
9223
9224             np_cv_predecl_mpinfou=no
9225             case "$ac_cv_header_net_if_h" in
9226              no)
9227                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9228 /* end confdefs.h.  */
9229
9230                             typedef union mpinfou {
9231                                     struct pdk_mpinfo *pdkptr;
9232                                     struct mpinfo *pikptr;
9233                             } mpinfou_t;
9234                             #ifdef HAVE_SYS_SOCKET_H
9235                             # include <sys/socket.h>
9236                             #endif
9237                             #include <net/if.h>
9238
9239 int
9240 main ()
9241 {
9242
9243
9244
9245   ;
9246   return 0;
9247 }
9248 _ACEOF
9249 if ac_fn_c_try_compile "$LINENO"; then :
9250
9251                         ntp_cv_predecl_mpinfou=yes
9252                         ac_cv_header_net_if_h=yes
9253
9254
9255 fi
9256 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9257             esac
9258
9259
9260 fi
9261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_predecl_mpinfou" >&5
9262 $as_echo "$ntp_cv_predecl_mpinfou" >&6; }
9263     case "$ntp_cv_predecl_mpinfou" in
9264      yes)
9265         cat >>confdefs.h <<_ACEOF
9266 #ifndef MPINFOU_PREDECLARED
9267 # define MPINFOU_PREDECLARED
9268 typedef union mpinfou {
9269         struct pdk_mpinfo *pdkptr;
9270         struct mpinfo *pikptr;
9271 } mpinfou_t;
9272 #endif
9273 _ACEOF
9274
9275     esac
9276 esac
9277
9278 case "$host" in
9279  *-linux*)
9280     for ac_header in linux/if_addr.h
9281 do :
9282   ac_fn_c_check_header_compile "$LINENO" "linux/if_addr.h" "ac_cv_header_linux_if_addr_h" "
9283         #ifdef HAVE_SYS_SOCKET_H
9284         # include <sys/socket.h>
9285         #endif
9286
9287 "
9288 if test "x$ac_cv_header_linux_if_addr_h" = xyes; then :
9289   cat >>confdefs.h <<_ACEOF
9290 #define HAVE_LINUX_IF_ADDR_H 1
9291 _ACEOF
9292
9293 fi
9294
9295 done
9296
9297 esac
9298
9299 for ac_header in arpa/nameser.h sys/param.h sys/time.h sys/timers.h
9300 do :
9301   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9302 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
9303 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
9304   cat >>confdefs.h <<_ACEOF
9305 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9306 _ACEOF
9307
9308 fi
9309
9310 done
9311
9312 # sys/sysctl.h depends on sys/param.h on OpenBSD - Bug 1576
9313 for ac_header in sys/sysctl.h
9314 do :
9315   ac_fn_c_check_header_compile "$LINENO" "sys/sysctl.h" "ac_cv_header_sys_sysctl_h" "
9316     #if defined HAVE_SYS_PARAM_H
9317     # include <sys/param.h>
9318     #endif
9319
9320 "
9321 if test "x$ac_cv_header_sys_sysctl_h" = xyes; then :
9322   cat >>confdefs.h <<_ACEOF
9323 #define HAVE_SYS_SYSCTL_H 1
9324 _ACEOF
9325
9326 fi
9327
9328 done
9329
9330 for ac_header in netinet/in_system.h netinet/in_systm.h netinet/in.h
9331 do :
9332   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9333 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
9334 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
9335   cat >>confdefs.h <<_ACEOF
9336 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9337 _ACEOF
9338
9339 fi
9340
9341 done
9342
9343
9344 for ac_header in resolv.h
9345 do :
9346   ac_fn_c_check_header_compile "$LINENO" "resolv.h" "ac_cv_header_resolv_h" "
9347     #ifdef HAVE_SYS_TYPES_H
9348     # include <sys/types.h>
9349     #endif
9350     #ifdef HAVE_NETINET_IN_H
9351     # include <netinet/in.h>
9352     #endif
9353     #ifdef HAVE_ARPA_NAMESER_H
9354     # include <arpa/nameser.h>
9355     #endif
9356
9357 "
9358 if test "x$ac_cv_header_resolv_h" = xyes; then :
9359   cat >>confdefs.h <<_ACEOF
9360 #define HAVE_RESOLV_H 1
9361 _ACEOF
9362
9363 fi
9364
9365 done
9366
9367
9368 for ac_header in net/if_var.h
9369 do :
9370   ac_fn_c_check_header_compile "$LINENO" "net/if_var.h" "ac_cv_header_net_if_var_h" "
9371     #if HAVE_SYS_TYPES_H
9372     # include <sys/types.h>
9373     #endif
9374     #ifdef HAVE_SYS_SOCKET_H
9375     # include <sys/socket.h>
9376     #endif
9377     #ifdef HAVE_NETINET_IN_H
9378     # include <netinet/in.h>
9379     #endif
9380     #ifdef HAVE_NET_IF_H
9381     # include <net/if.h>
9382     #endif
9383
9384 "
9385 if test "x$ac_cv_header_net_if_var_h" = xyes; then :
9386   cat >>confdefs.h <<_ACEOF
9387 #define HAVE_NET_IF_VAR_H 1
9388 _ACEOF
9389
9390 fi
9391
9392 done
9393
9394
9395 for ac_header in netinet/ip.h netinet/in_var.h
9396 do :
9397   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9398 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "
9399     #ifdef HAVE_SYS_TYPES_H
9400     # include <sys/types.h>
9401     #endif
9402     #ifdef HAVE_SYS_SOCKET_H
9403     # include <sys/socket.h>
9404     #endif
9405     #ifdef HAVE_NET_IF_H
9406     # include <net/if.h>
9407     #endif
9408     #ifdef HAVE_NETINET_IN_H
9409     # include <netinet/in.h>
9410     #endif
9411     #ifdef HAVE_NET_IF_VAR_H
9412     # include <net/if_var.h>
9413     #endif
9414     #ifdef HAVE_NETINET_IN_SYSTM_H
9415     # include <netinet/in_systm.h>
9416     #endif
9417
9418 "
9419 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
9420   cat >>confdefs.h <<_ACEOF
9421 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9422 _ACEOF
9423
9424 fi
9425
9426 done
9427
9428
9429 # HMS: Do we need to check for -lsocket before or after these tests?
9430 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing inet_pton" >&5
9431 $as_echo_n "checking for library containing inet_pton... " >&6; }
9432 if ${ac_cv_search_inet_pton+:} false; then :
9433   $as_echo_n "(cached) " >&6
9434 else
9435   ac_func_search_save_LIBS=$LIBS
9436 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9437 /* end confdefs.h.  */
9438
9439 /* Override any GCC internal prototype to avoid an error.
9440    Use char because int might match the return type of a GCC
9441    builtin and then its argument prototype would still apply.  */
9442 #ifdef __cplusplus
9443 extern "C"
9444 #endif
9445 char inet_pton ();
9446 int
9447 main ()
9448 {
9449 return inet_pton ();
9450   ;
9451   return 0;
9452 }
9453 _ACEOF
9454 for ac_lib in '' nsl; do
9455   if test -z "$ac_lib"; then
9456     ac_res="none required"
9457   else
9458     ac_res=-l$ac_lib
9459     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
9460   fi
9461   if ac_fn_c_try_link "$LINENO"; then :
9462   ac_cv_search_inet_pton=$ac_res
9463 fi
9464 rm -f core conftest.err conftest.$ac_objext \
9465     conftest$ac_exeext
9466   if ${ac_cv_search_inet_pton+:} false; then :
9467   break
9468 fi
9469 done
9470 if ${ac_cv_search_inet_pton+:} false; then :
9471
9472 else
9473   ac_cv_search_inet_pton=no
9474 fi
9475 rm conftest.$ac_ext
9476 LIBS=$ac_func_search_save_LIBS
9477 fi
9478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inet_pton" >&5
9479 $as_echo "$ac_cv_search_inet_pton" >&6; }
9480 ac_res=$ac_cv_search_inet_pton
9481 if test "$ac_res" != no; then :
9482   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
9483   case "$ac_cv_search_inet_pton" in
9484  'none required') ;;
9485  no) ;;
9486  *) LDADD_LIBNTP="$ac_cv_search_inet_pton $LDADD_LIBNTP" ;;
9487  esac
9488
9489 fi
9490
9491 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing inet_ntop" >&5
9492 $as_echo_n "checking for library containing inet_ntop... " >&6; }
9493 if ${ac_cv_search_inet_ntop+:} false; then :
9494   $as_echo_n "(cached) " >&6
9495 else
9496   ac_func_search_save_LIBS=$LIBS
9497 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9498 /* end confdefs.h.  */
9499
9500 /* Override any GCC internal prototype to avoid an error.
9501    Use char because int might match the return type of a GCC
9502    builtin and then its argument prototype would still apply.  */
9503 #ifdef __cplusplus
9504 extern "C"
9505 #endif
9506 char inet_ntop ();
9507 int
9508 main ()
9509 {
9510 return inet_ntop ();
9511   ;
9512   return 0;
9513 }
9514 _ACEOF
9515 for ac_lib in '' resolv; do
9516   if test -z "$ac_lib"; then
9517     ac_res="none required"
9518   else
9519     ac_res=-l$ac_lib
9520     LIBS="-l$ac_lib -lnsl $ac_func_search_save_LIBS"
9521   fi
9522   if ac_fn_c_try_link "$LINENO"; then :
9523   ac_cv_search_inet_ntop=$ac_res
9524 fi
9525 rm -f core conftest.err conftest.$ac_objext \
9526     conftest$ac_exeext
9527   if ${ac_cv_search_inet_ntop+:} false; then :
9528   break
9529 fi
9530 done
9531 if ${ac_cv_search_inet_ntop+:} false; then :
9532
9533 else
9534   ac_cv_search_inet_ntop=no
9535 fi
9536 rm conftest.$ac_ext
9537 LIBS=$ac_func_search_save_LIBS
9538 fi
9539 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inet_ntop" >&5
9540 $as_echo "$ac_cv_search_inet_ntop" >&6; }
9541 ac_res=$ac_cv_search_inet_ntop
9542 if test "$ac_res" != no; then :
9543   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
9544   case "$ac_cv_search_inet_ntop" in
9545  'none required') ;;
9546  no) ;;
9547  *) LDADD_LIBNTP="$ac_cv_search_inet_ntop $LDADD_LIBNTP" ;;
9548  esac
9549
9550 fi
9551
9552
9553 # [Bug 1628] On Solaris, we need -lxnet -lsocket.  Generalize this to
9554 # avoid keying on the OS name:  If we find socket functions in
9555 # libsocket, next try for them in libxnet without libsocket, if found,
9556 # list both.  If we simply tested libxnet first, we would find the
9557 # functions there and never add libsocket.  See also [Bug 660]
9558 # http://bugs.ntp.org/show_bug.cgi?id=660#c9
9559 saved_LIBS=$LIBS
9560 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing setsockopt" >&5
9561 $as_echo_n "checking for library containing setsockopt... " >&6; }
9562 if ${ac_cv_search_setsockopt+:} false; then :
9563   $as_echo_n "(cached) " >&6
9564 else
9565   ac_func_search_save_LIBS=$LIBS
9566 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9567 /* end confdefs.h.  */
9568
9569 /* Override any GCC internal prototype to avoid an error.
9570    Use char because int might match the return type of a GCC
9571    builtin and then its argument prototype would still apply.  */
9572 #ifdef __cplusplus
9573 extern "C"
9574 #endif
9575 char setsockopt ();
9576 int
9577 main ()
9578 {
9579 return setsockopt ();
9580   ;
9581   return 0;
9582 }
9583 _ACEOF
9584 for ac_lib in '' socket; do
9585   if test -z "$ac_lib"; then
9586     ac_res="none required"
9587   else
9588     ac_res=-l$ac_lib
9589     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
9590   fi
9591   if ac_fn_c_try_link "$LINENO"; then :
9592   ac_cv_search_setsockopt=$ac_res
9593 fi
9594 rm -f core conftest.err conftest.$ac_objext \
9595     conftest$ac_exeext
9596   if ${ac_cv_search_setsockopt+:} false; then :
9597   break
9598 fi
9599 done
9600 if ${ac_cv_search_setsockopt+:} false; then :
9601
9602 else
9603   ac_cv_search_setsockopt=no
9604 fi
9605 rm conftest.$ac_ext
9606 LIBS=$ac_func_search_save_LIBS
9607 fi
9608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_setsockopt" >&5
9609 $as_echo "$ac_cv_search_setsockopt" >&6; }
9610 ac_res=$ac_cv_search_setsockopt
9611 if test "$ac_res" != no; then :
9612   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
9613   case "$ac_cv_search_setsockopt" in
9614  'none required') ;;
9615  no) ;;
9616  *) LDADD_LIBNTP="$ac_cv_search_setsockopt $LDADD_LIBNTP" ;;
9617  esac
9618
9619 fi
9620
9621 case "$ac_cv_search_setsockopt" in
9622  -lsocket)
9623     LIBS="$saved_LIBS"
9624     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing getsockopt" >&5
9625 $as_echo_n "checking for library containing getsockopt... " >&6; }
9626 if ${ac_cv_search_getsockopt+:} false; then :
9627   $as_echo_n "(cached) " >&6
9628 else
9629   ac_func_search_save_LIBS=$LIBS
9630 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9631 /* end confdefs.h.  */
9632
9633 /* Override any GCC internal prototype to avoid an error.
9634    Use char because int might match the return type of a GCC
9635    builtin and then its argument prototype would still apply.  */
9636 #ifdef __cplusplus
9637 extern "C"
9638 #endif
9639 char getsockopt ();
9640 int
9641 main ()
9642 {
9643 return getsockopt ();
9644   ;
9645   return 0;
9646 }
9647 _ACEOF
9648 for ac_lib in '' xnet; do
9649   if test -z "$ac_lib"; then
9650     ac_res="none required"
9651   else
9652     ac_res=-l$ac_lib
9653     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
9654   fi
9655   if ac_fn_c_try_link "$LINENO"; then :
9656   ac_cv_search_getsockopt=$ac_res
9657 fi
9658 rm -f core conftest.err conftest.$ac_objext \
9659     conftest$ac_exeext
9660   if ${ac_cv_search_getsockopt+:} false; then :
9661   break
9662 fi
9663 done
9664 if ${ac_cv_search_getsockopt+:} false; then :
9665
9666 else
9667   ac_cv_search_getsockopt=no
9668 fi
9669 rm conftest.$ac_ext
9670 LIBS=$ac_func_search_save_LIBS
9671 fi
9672 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_getsockopt" >&5
9673 $as_echo "$ac_cv_search_getsockopt" >&6; }
9674 ac_res=$ac_cv_search_getsockopt
9675 if test "$ac_res" != no; then :
9676   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
9677   case "$ac_cv_search_getsockopt" in
9678  'none required') ;;
9679  no) ;;
9680  *) LDADD_LIBNTP="$ac_cv_search_getsockopt $LDADD_LIBNTP" ;;
9681  esac
9682
9683 fi
9684
9685     # XXX Possible trouble here - reading the comments above and looking at the
9686     # code below I wonder if we'll add -lxnet when we don't need it.
9687     # Also, do we need to add -lxnet to LDADD_LIBNTP, or perhaps see if it's
9688     # there when it is not needed?
9689     case "$ac_cv_search_getsockopt" in
9690      -lxnet)
9691         LIBS="-lxnet -lsocket $saved_LIBS"
9692         ;;
9693      *) LIBS="-lsocket $saved_LIBS"
9694         ;;
9695     esac
9696     ;;
9697 esac
9698 { saved_LIBS=; unset saved_LIBS;}
9699
9700 # Bug 2427 - look for recvmsg here.
9701 for ac_func in recvmsg
9702 do :
9703   ac_fn_c_check_func "$LINENO" "recvmsg" "ac_cv_func_recvmsg"
9704 if test "x$ac_cv_func_recvmsg" = xyes; then :
9705   cat >>confdefs.h <<_ACEOF
9706 #define HAVE_RECVMSG 1
9707 _ACEOF
9708
9709 fi
9710 done
9711
9712
9713 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
9714 $as_echo_n "checking for inline... " >&6; }
9715 if ${ac_cv_c_inline+:} false; then :
9716   $as_echo_n "(cached) " >&6
9717 else
9718   ac_cv_c_inline=no
9719 for ac_kw in inline __inline__ __inline; do
9720   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9721 /* end confdefs.h.  */
9722 #ifndef __cplusplus
9723 typedef int foo_t;
9724 static $ac_kw foo_t static_foo () {return 0; }
9725 $ac_kw foo_t foo () {return 0; }
9726 #endif
9727
9728 _ACEOF
9729 if ac_fn_c_try_compile "$LINENO"; then :
9730   ac_cv_c_inline=$ac_kw
9731 fi
9732 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9733   test "$ac_cv_c_inline" != no && break
9734 done
9735
9736 fi
9737 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
9738 $as_echo "$ac_cv_c_inline" >&6; }
9739
9740 case $ac_cv_c_inline in
9741   inline | yes) ;;
9742   *)
9743     case $ac_cv_c_inline in
9744       no) ac_val=;;
9745       *) ac_val=$ac_cv_c_inline;;
9746     esac
9747     cat >>confdefs.h <<_ACEOF
9748 #ifndef __cplusplus
9749 #define inline $ac_val
9750 #endif
9751 _ACEOF
9752     ;;
9753 esac
9754
9755
9756 case "$ac_cv_c_inline" in
9757  '')
9758     ;;
9759  *)
9760
9761 $as_echo "#define HAVE_INLINE 1" >>confdefs.h
9762
9763
9764 esac
9765
9766 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
9767 $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
9768 if ${ac_cv_header_time+:} false; then :
9769   $as_echo_n "(cached) " >&6
9770 else
9771   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9772 /* end confdefs.h.  */
9773 #include <sys/types.h>
9774 #include <sys/time.h>
9775 #include <time.h>
9776
9777 int
9778 main ()
9779 {
9780 if ((struct tm *) 0)
9781 return 0;
9782   ;
9783   return 0;
9784 }
9785 _ACEOF
9786 if ac_fn_c_try_compile "$LINENO"; then :
9787   ac_cv_header_time=yes
9788 else
9789   ac_cv_header_time=no
9790 fi
9791 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9792 fi
9793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
9794 $as_echo "$ac_cv_header_time" >&6; }
9795 if test $ac_cv_header_time = yes; then
9796
9797 $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
9798
9799 fi
9800
9801 # The cast to long int works around a bug in the HP C Compiler
9802 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9803 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9804 # This bug is HP SR number 8606223364.
9805 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of time_t" >&5
9806 $as_echo_n "checking size of time_t... " >&6; }
9807 if ${ac_cv_sizeof_time_t+:} false; then :
9808   $as_echo_n "(cached) " >&6
9809 else
9810   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (time_t))" "ac_cv_sizeof_time_t"        "$ac_includes_default"; then :
9811
9812 else
9813   if test "$ac_cv_type_time_t" = yes; then
9814      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9815 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9816 as_fn_error 77 "cannot compute sizeof (time_t)
9817 See \`config.log' for more details" "$LINENO" 5; }
9818    else
9819      ac_cv_sizeof_time_t=0
9820    fi
9821 fi
9822
9823 fi
9824 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_time_t" >&5
9825 $as_echo "$ac_cv_sizeof_time_t" >&6; }
9826
9827
9828
9829 cat >>confdefs.h <<_ACEOF
9830 #define SIZEOF_TIME_T $ac_cv_sizeof_time_t
9831 _ACEOF
9832
9833
9834 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether char is unsigned" >&5
9835 $as_echo_n "checking whether char is unsigned... " >&6; }
9836 if ${ac_cv_c_char_unsigned+:} false; then :
9837   $as_echo_n "(cached) " >&6
9838 else
9839   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9840 /* end confdefs.h.  */
9841 $ac_includes_default
9842 int
9843 main ()
9844 {
9845 static int test_array [1 - 2 * !(((char) -1) < 0)];
9846 test_array [0] = 0
9847
9848   ;
9849   return 0;
9850 }
9851 _ACEOF
9852 if ac_fn_c_try_compile "$LINENO"; then :
9853   ac_cv_c_char_unsigned=no
9854 else
9855   ac_cv_c_char_unsigned=yes
9856 fi
9857 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9858 fi
9859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_char_unsigned" >&5
9860 $as_echo "$ac_cv_c_char_unsigned" >&6; }
9861 if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then
9862   $as_echo "#define __CHAR_UNSIGNED__ 1" >>confdefs.h
9863
9864 fi
9865                 # The cast to long int works around a bug in the HP C Compiler
9866 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9867 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9868 # This bug is HP SR number 8606223364.
9869 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of signed char" >&5
9870 $as_echo_n "checking size of signed char... " >&6; }
9871 if ${ac_cv_sizeof_signed_char+:} false; then :
9872   $as_echo_n "(cached) " >&6
9873 else
9874   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (signed char))" "ac_cv_sizeof_signed_char"        "$ac_includes_default"; then :
9875
9876 else
9877   if test "$ac_cv_type_signed_char" = yes; then
9878      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9879 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9880 as_fn_error 77 "cannot compute sizeof (signed char)
9881 See \`config.log' for more details" "$LINENO" 5; }
9882    else
9883      ac_cv_sizeof_signed_char=0
9884    fi
9885 fi
9886
9887 fi
9888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_signed_char" >&5
9889 $as_echo "$ac_cv_sizeof_signed_char" >&6; }
9890
9891
9892
9893 cat >>confdefs.h <<_ACEOF
9894 #define SIZEOF_SIGNED_CHAR $ac_cv_sizeof_signed_char
9895 _ACEOF
9896
9897
9898 ac_fn_c_check_type "$LINENO" "s_char" "ac_cv_type_s_char" "$ac_includes_default"
9899 if test "x$ac_cv_type_s_char" = xyes; then :
9900
9901 cat >>confdefs.h <<_ACEOF
9902 #define HAVE_S_CHAR 1
9903 _ACEOF
9904
9905
9906 fi
9907 ac_fn_c_check_type "$LINENO" "long long" "ac_cv_type_long_long" "$ac_includes_default"
9908 if test "x$ac_cv_type_long_long" = xyes; then :
9909
9910 cat >>confdefs.h <<_ACEOF
9911 #define HAVE_LONG_LONG 1
9912 _ACEOF
9913
9914
9915 fi
9916
9917 # The cast to long int works around a bug in the HP C Compiler
9918 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9919 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9920 # This bug is HP SR number 8606223364.
9921 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5
9922 $as_echo_n "checking size of short... " >&6; }
9923 if ${ac_cv_sizeof_short+:} false; then :
9924   $as_echo_n "(cached) " >&6
9925 else
9926   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short))" "ac_cv_sizeof_short"        "$ac_includes_default"; then :
9927
9928 else
9929   if test "$ac_cv_type_short" = yes; then
9930      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9931 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9932 as_fn_error 77 "cannot compute sizeof (short)
9933 See \`config.log' for more details" "$LINENO" 5; }
9934    else
9935      ac_cv_sizeof_short=0
9936    fi
9937 fi
9938
9939 fi
9940 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5
9941 $as_echo "$ac_cv_sizeof_short" >&6; }
9942
9943
9944
9945 cat >>confdefs.h <<_ACEOF
9946 #define SIZEOF_SHORT $ac_cv_sizeof_short
9947 _ACEOF
9948
9949
9950 # The cast to long int works around a bug in the HP C Compiler
9951 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9952 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9953 # This bug is HP SR number 8606223364.
9954 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5
9955 $as_echo_n "checking size of int... " >&6; }
9956 if ${ac_cv_sizeof_int+:} false; then :
9957   $as_echo_n "(cached) " >&6
9958 else
9959   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int"        "$ac_includes_default"; then :
9960
9961 else
9962   if test "$ac_cv_type_int" = yes; then
9963      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9964 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9965 as_fn_error 77 "cannot compute sizeof (int)
9966 See \`config.log' for more details" "$LINENO" 5; }
9967    else
9968      ac_cv_sizeof_int=0
9969    fi
9970 fi
9971
9972 fi
9973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5
9974 $as_echo "$ac_cv_sizeof_int" >&6; }
9975
9976
9977
9978 cat >>confdefs.h <<_ACEOF
9979 #define SIZEOF_INT $ac_cv_sizeof_int
9980 _ACEOF
9981
9982
9983 # The cast to long int works around a bug in the HP C Compiler
9984 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
9985 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
9986 # This bug is HP SR number 8606223364.
9987 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
9988 $as_echo_n "checking size of long... " >&6; }
9989 if ${ac_cv_sizeof_long+:} false; then :
9990   $as_echo_n "(cached) " >&6
9991 else
9992   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long"        "$ac_includes_default"; then :
9993
9994 else
9995   if test "$ac_cv_type_long" = yes; then
9996      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
9997 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
9998 as_fn_error 77 "cannot compute sizeof (long)
9999 See \`config.log' for more details" "$LINENO" 5; }
10000    else
10001      ac_cv_sizeof_long=0
10002    fi
10003 fi
10004
10005 fi
10006 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
10007 $as_echo "$ac_cv_sizeof_long" >&6; }
10008
10009
10010
10011 cat >>confdefs.h <<_ACEOF
10012 #define SIZEOF_LONG $ac_cv_sizeof_long
10013 _ACEOF
10014
10015
10016
10017 case "$ac_cv_type_long_long" in
10018  no)
10019     ;;
10020  *)
10021     # The cast to long int works around a bug in the HP C Compiler
10022 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
10023 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
10024 # This bug is HP SR number 8606223364.
10025 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5
10026 $as_echo_n "checking size of long long... " >&6; }
10027 if ${ac_cv_sizeof_long_long+:} false; then :
10028   $as_echo_n "(cached) " >&6
10029 else
10030   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long"        "$ac_includes_default"; then :
10031
10032 else
10033   if test "$ac_cv_type_long_long" = yes; then
10034      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
10035 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
10036 as_fn_error 77 "cannot compute sizeof (long long)
10037 See \`config.log' for more details" "$LINENO" 5; }
10038    else
10039      ac_cv_sizeof_long_long=0
10040    fi
10041 fi
10042
10043 fi
10044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5
10045 $as_echo "$ac_cv_sizeof_long_long" >&6; }
10046
10047
10048
10049 cat >>confdefs.h <<_ACEOF
10050 #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
10051 _ACEOF
10052
10053
10054     ;;
10055 esac
10056
10057 case "$ac_cv_c_char_unsigned$ac_cv_sizeof_signed_char$ac_cv_type_s_char" in
10058  *yes)
10059     # We have a typedef for s_char.  Might as well believe it...
10060     ;;
10061  no0no)
10062     # We have signed chars, can't say 'signed char', no s_char typedef.
10063
10064 $as_echo "#define NEED_S_CHAR_TYPEDEF 1" >>confdefs.h
10065
10066     ;;
10067  no1no)
10068     # We have signed chars, can say 'signed char', no s_char typedef.
10069
10070 $as_echo "#define NEED_S_CHAR_TYPEDEF 1" >>confdefs.h
10071
10072     ;;
10073  yes0no)
10074     # We have unsigned chars, can't say 'signed char', no s_char typedef.
10075     as_fn_error $? "No way to specify a signed character!" "$LINENO" 5
10076     ;;
10077  yes1no)
10078     # We have unsigned chars, can say 'signed char', no s_char typedef.
10079
10080 $as_echo "#define NEED_S_CHAR_TYPEDEF 1" >>confdefs.h
10081
10082     ;;
10083 esac
10084
10085 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5
10086 $as_echo_n "checking for uid_t in sys/types.h... " >&6; }
10087 if ${ac_cv_type_uid_t+:} false; then :
10088   $as_echo_n "(cached) " >&6
10089 else
10090   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10091 /* end confdefs.h.  */
10092 #include <sys/types.h>
10093
10094 _ACEOF
10095 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10096   $EGREP "uid_t" >/dev/null 2>&1; then :
10097   ac_cv_type_uid_t=yes
10098 else
10099   ac_cv_type_uid_t=no
10100 fi
10101 rm -f conftest*
10102
10103 fi
10104 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5
10105 $as_echo "$ac_cv_type_uid_t" >&6; }
10106 if test $ac_cv_type_uid_t = no; then
10107
10108 $as_echo "#define uid_t int" >>confdefs.h
10109
10110
10111 $as_echo "#define gid_t int" >>confdefs.h
10112
10113 fi
10114
10115
10116
10117
10118
10119
10120 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we're including debugging code" >&5
10121 $as_echo_n "checking if we're including debugging code... " >&6; }
10122 # Check whether --enable-debugging was given.
10123 if test "${enable_debugging+set}" = set; then :
10124   enableval=$enable_debugging; ntp_ok=$enableval
10125 else
10126   ntp_ok=yes
10127
10128 fi
10129
10130 case "$ntp_ok" in
10131  yes)
10132
10133 $as_echo "#define DEBUG 1" >>confdefs.h
10134
10135 esac
10136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_ok" >&5
10137 $as_echo "$ntp_ok" >&6; }
10138
10139
10140
10141 # check if we can compile with pthreads
10142 for ac_header in semaphore.h
10143 do :
10144   ac_fn_c_check_header_mongrel "$LINENO" "semaphore.h" "ac_cv_header_semaphore_h" "$ac_includes_default"
10145 if test "x$ac_cv_header_semaphore_h" = xyes; then :
10146   cat >>confdefs.h <<_ACEOF
10147 #define HAVE_SEMAPHORE_H 1
10148 _ACEOF
10149
10150 fi
10151
10152 done
10153
10154 for ac_func in socketpair
10155 do :
10156   ac_fn_c_check_func "$LINENO" "socketpair" "ac_cv_func_socketpair"
10157 if test "x$ac_cv_func_socketpair" = xyes; then :
10158   cat >>confdefs.h <<_ACEOF
10159 #define HAVE_SOCKETPAIR 1
10160 _ACEOF
10161
10162 fi
10163 done
10164
10165 # Check whether --enable-thread-support was given.
10166 if test "${enable_thread_support+set}" = set; then :
10167   enableval=$enable_thread_support;
10168 else
10169   enable_thread_support=yes
10170
10171 fi
10172
10173 have_pthreads=no
10174 case "$enable_thread_support" in
10175  yes)
10176     ol_found_pthreads=no
10177
10178
10179
10180 ac_ext=c
10181 ac_cpp='$CPP $CPPFLAGS'
10182 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
10183 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
10184 ac_compiler_gnu=$ac_cv_c_compiler_gnu
10185
10186 # OpenLDAP --with-threads
10187
10188 # Check whether --with-threads was given.
10189 if test "${with_threads+set}" = set; then :
10190   withval=$with_threads;
10191         ol_arg=invalid
10192         for ol_val in auto nt posix mach pth lwp yes no manual  ; do
10193                 if test "$withval" = "$ol_val" ; then
10194                         ol_arg="$ol_val"
10195                 fi
10196         done
10197         if test "$ol_arg" = "invalid" ; then
10198                 as_fn_error $? "bad value $withval for --with-threads" "$LINENO" 5
10199         fi
10200         ol_with_threads="$ol_arg"
10201
10202 else
10203         ol_with_threads="auto"
10204 fi
10205 # end --with-threads
10206
10207
10208 case "$ol_with_threads$host" in
10209  auto*-*-solaris2.[0-6])
10210         ol_with_threads=no
10211     ;;
10212 esac
10213
10214
10215 ol_aix_threads=no
10216 case "$host" in
10217 *-*-aix*)       if test -z "$CC" ; then
10218                 case "$ol_with_threads" in
10219                 auto | yes |  posix) ol_aix_threads=yes ;;
10220                 esac
10221         fi
10222 ;;
10223 esac
10224
10225 if test $ol_aix_threads = yes ; then
10226         if test -z "${CC}" ; then
10227                 for ac_prog in cc_r xlc_r cc
10228 do
10229   # Extract the first word of "$ac_prog", so it can be a program name with args.
10230 set dummy $ac_prog; ac_word=$2
10231 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10232 $as_echo_n "checking for $ac_word... " >&6; }
10233 if ${ac_cv_prog_CC+:} false; then :
10234   $as_echo_n "(cached) " >&6
10235 else
10236   if test -n "$CC"; then
10237   ac_cv_prog_CC="$CC" # Let the user override the test.
10238 else
10239 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10240 for as_dir in $PATH
10241 do
10242   IFS=$as_save_IFS
10243   test -z "$as_dir" && as_dir=.
10244     for ac_exec_ext in '' $ac_executable_extensions; do
10245   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10246     ac_cv_prog_CC="$ac_prog"
10247     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10248     break 2
10249   fi
10250 done
10251   done
10252 IFS=$as_save_IFS
10253
10254 fi
10255 fi
10256 CC=$ac_cv_prog_CC
10257 if test -n "$CC"; then
10258   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
10259 $as_echo "$CC" >&6; }
10260 else
10261   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10262 $as_echo "no" >&6; }
10263 fi
10264
10265
10266   test -n "$CC" && break
10267 done
10268
10269
10270                 if test "$CC" = cc ; then
10271                                                 if test $ol_with_threads != auto ; then
10272                                 as_fn_error $? "--with-threads requires cc_r (or other suitable compiler) on AIX" "$LINENO" 5
10273                         else
10274                                 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: disabling threads, no cc_r on AIX" >&5
10275 $as_echo "$as_me: WARNING: disabling threads, no cc_r on AIX" >&2;}
10276                         fi
10277                         ol_with_threads=no
10278                 fi
10279         fi
10280
10281         case ${CC} in cc_r | xlc_r)
10282                 ol_with_threads=posix
10283                 ol_cv_pthread_create=yes
10284                 ;;
10285         esac
10286 fi
10287
10288 ol_link_threads=no
10289 # OpenLDAP --with-yielding_select
10290
10291 # Check whether --with-yielding_select was given.
10292 if test "${with_yielding_select+set}" = set; then :
10293   withval=$with_yielding_select;
10294         ol_arg=invalid
10295         for ol_val in auto yes no manual  ; do
10296                 if test "$withval" = "$ol_val" ; then
10297                         ol_arg="$ol_val"
10298                 fi
10299         done
10300         if test "$ol_arg" = "invalid" ; then
10301                 as_fn_error $? "bad value $withval for --with-yielding_select" "$LINENO" 5
10302         fi
10303         ol_with_yielding_select="$ol_arg"
10304
10305 else
10306         ol_with_yielding_select="auto"
10307 fi
10308 # end --with-yielding_select
10309
10310
10311 case $ol_with_threads in auto | yes | nt)
10312
10313
10314         ac_fn_c_check_func "$LINENO" "_beginthread" "ac_cv_func__beginthread"
10315 if test "x$ac_cv_func__beginthread" = xyes; then :
10316
10317 fi
10318
10319
10320         if test $ac_cv_func__beginthread = yes ; then
10321
10322 $as_echo "#define HAVE_NT_THREADS 1" >>confdefs.h
10323
10324                 ol_cv_nt_threads=yes
10325         fi
10326
10327
10328         if test "$ol_cv_nt_threads" = yes ; then
10329                 ol_link_threads=nt
10330                 ol_with_threads=found
10331                 ol_with_yielding_select=yes
10332
10333
10334 $as_echo "#define HAVE_NT_SERVICE_MANAGER 1" >>confdefs.h
10335
10336
10337 $as_echo "#define HAVE_NT_EVENT_LOG 1" >>confdefs.h
10338
10339         fi
10340
10341         if test $ol_with_threads = nt ; then
10342                 as_fn_error $? "could not locate NT Threads" "$LINENO" 5
10343         fi
10344         ;;
10345 esac
10346
10347 case $ol_with_threads in auto | yes | posix)
10348
10349         for ac_header in pthread.h
10350 do :
10351   ac_fn_c_check_header_mongrel "$LINENO" "pthread.h" "ac_cv_header_pthread_h" "$ac_includes_default"
10352 if test "x$ac_cv_header_pthread_h" = xyes; then :
10353   cat >>confdefs.h <<_ACEOF
10354 #define HAVE_PTHREAD_H 1
10355 _ACEOF
10356
10357 fi
10358
10359 done
10360
10361
10362         if test $ac_cv_header_pthread_h = yes ; then
10363                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking POSIX thread version" >&5
10364 $as_echo_n "checking POSIX thread version... " >&6; }
10365 if ${ol_cv_pthread_version+:} false; then :
10366   $as_echo_n "(cached) " >&6
10367 else
10368
10369         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10370 /* end confdefs.h.  */
10371
10372 #               include <pthread.h>
10373
10374 int
10375 main ()
10376 {
10377
10378                 int i = PTHREAD_CREATE_JOINABLE;
10379
10380   ;
10381   return 0;
10382 }
10383 _ACEOF
10384 if ac_fn_c_try_compile "$LINENO"; then :
10385
10386         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10387 /* end confdefs.h.  */
10388 #include <pthread.h>
10389
10390 _ACEOF
10391 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10392   $EGREP "pthread_detach" >/dev/null 2>&1; then :
10393   ol_cv_pthread_version=10
10394 else
10395   ol_cv_pthread_version=8
10396 fi
10397 rm -f conftest*
10398
10399 else
10400
10401         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10402 /* end confdefs.h.  */
10403
10404 #               include <pthread.h>
10405 #               ifdef PTHREAD_CREATE_UNDETACHED
10406                 draft7
10407 #               endif
10408
10409 _ACEOF
10410 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10411   $EGREP "draft7" >/dev/null 2>&1; then :
10412   ol_cv_pthread_version=7
10413 else
10414
10415         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10416 /* end confdefs.h.  */
10417 #include <pthread.h>
10418
10419 _ACEOF
10420 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10421   $EGREP "pthread_attr_init" >/dev/null 2>&1; then :
10422   ol_cv_pthread_version=6
10423 else
10424
10425         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10426 /* end confdefs.h.  */
10427
10428 #               include <pthread.h>
10429 #ifdef          PTHREAD_MUTEX_INITIALIZER
10430                 draft5
10431 #endif
10432
10433 _ACEOF
10434 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10435   $EGREP "draft5" >/dev/null 2>&1; then :
10436   ol_cv_pthread_version=5
10437 else
10438   ol_cv_pthread_version=4
10439 fi
10440 rm -f conftest*
10441
10442 fi
10443 rm -f conftest*
10444
10445 fi
10446 rm -f conftest*
10447
10448 fi
10449 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10450
10451 fi
10452 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_version" >&5
10453 $as_echo "$ol_cv_pthread_version" >&6; }
10454
10455
10456                 if test $ol_cv_pthread_version != 0 ; then
10457
10458 cat >>confdefs.h <<_ACEOF
10459 #define HAVE_PTHREADS $ol_cv_pthread_version
10460 _ACEOF
10461
10462                 else
10463                         as_fn_error $? "unknown pthread version" "$LINENO" 5
10464                 fi
10465
10466                 # consider threads found
10467                 ol_with_threads=found
10468
10469
10470         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LinuxThreads pthread.h" >&5
10471 $as_echo_n "checking for LinuxThreads pthread.h... " >&6; }
10472 if ${ol_cv_header_linux_threads+:} false; then :
10473   $as_echo_n "(cached) " >&6
10474 else
10475   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10476 /* end confdefs.h.  */
10477 #include <pthread.h>
10478 _ACEOF
10479 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10480   $EGREP "pthread_kill_other_threads_np" >/dev/null 2>&1; then :
10481   ol_cv_header_linux_threads=yes
10482 else
10483   ol_cv_header_linux_threads=no
10484 fi
10485 rm -f conftest*
10486
10487
10488 fi
10489 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_header_linux_threads" >&5
10490 $as_echo "$ol_cv_header_linux_threads" >&6; }
10491         if test $ol_cv_header_linux_threads = yes; then
10492
10493 $as_echo "#define HAVE_LINUX_THREADS 1" >>confdefs.h
10494
10495         fi
10496
10497
10498         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU Pth pthread.h" >&5
10499 $as_echo_n "checking for GNU Pth pthread.h... " >&6; }
10500 if ${ol_cv_header_gnu_pth_pthread_h+:} false; then :
10501   $as_echo_n "(cached) " >&6
10502 else
10503   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10504 /* end confdefs.h.  */
10505 #include <pthread.h>
10506 #ifdef _POSIX_THREAD_IS_GNU_PTH
10507         __gnu_pth__;
10508 #endif
10509
10510 _ACEOF
10511 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10512   $EGREP "__gnu_pth__" >/dev/null 2>&1; then :
10513   ol_cv_header_gnu_pth_pthread_h=yes
10514 else
10515   ol_cv_header_gnu_pth_pthread_h=no
10516 fi
10517 rm -f conftest*
10518
10519
10520 fi
10521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_header_gnu_pth_pthread_h" >&5
10522 $as_echo "$ol_cv_header_gnu_pth_pthread_h" >&6; }
10523
10524
10525                 if test $ol_cv_header_gnu_pth_pthread_h = no ; then
10526                         for ac_header in sched.h
10527 do :
10528   ac_fn_c_check_header_mongrel "$LINENO" "sched.h" "ac_cv_header_sched_h" "$ac_includes_default"
10529 if test "x$ac_cv_header_sched_h" = xyes; then :
10530   cat >>confdefs.h <<_ACEOF
10531 #define HAVE_SCHED_H 1
10532 _ACEOF
10533
10534 fi
10535
10536 done
10537
10538                 fi
10539
10540
10541                                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_create in default libraries" >&5
10542 $as_echo_n "checking for pthread_create in default libraries... " >&6; }
10543 if ${ol_cv_pthread_create+:} false; then :
10544   $as_echo_n "(cached) " >&6
10545 else
10546
10547                         if test "$cross_compiling" = yes; then :
10548   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10549 /* end confdefs.h.  */
10550
10551 /* pthread test headers */
10552 #include <pthread.h>
10553 #if HAVE_PTHREADS < 7
10554 #include <errno.h>
10555 #endif
10556 #ifndef NULL
10557 #define NULL (void*)0
10558 #endif
10559
10560 static void *task(p)
10561         void *p;
10562 {
10563         return (void *) (p == NULL);
10564 }
10565
10566 int
10567 main ()
10568 {
10569
10570         /* pthread test function */
10571 #ifndef PTHREAD_CREATE_DETACHED
10572 #define PTHREAD_CREATE_DETACHED 1
10573 #endif
10574         pthread_t t;
10575         int status;
10576         int detach = PTHREAD_CREATE_DETACHED;
10577
10578 #if HAVE_PTHREADS > 4
10579         /* Final pthreads */
10580         pthread_attr_t attr;
10581
10582         status = pthread_attr_init(&attr);
10583         if( status ) return status;
10584
10585 #if HAVE_PTHREADS < 7
10586         status = pthread_attr_setdetachstate(&attr, &detach);
10587         if( status < 0 ) status = errno;
10588 #else
10589         status = pthread_attr_setdetachstate(&attr, detach);
10590 #endif
10591         if( status ) return status;
10592         status = pthread_create( &t, &attr, task, NULL );
10593 #if HAVE_PTHREADS < 7
10594         if( status < 0 ) status = errno;
10595 #endif
10596         if( status ) return status;
10597 #else
10598         /* Draft 4 pthreads */
10599         status = pthread_create( &t, pthread_attr_default, task, NULL );
10600         if( status ) return errno;
10601
10602         /* give thread a chance to complete */
10603         /* it should remain joinable and hence detachable */
10604         sleep( 1 );
10605
10606         status = pthread_detach( &t );
10607         if( status ) return errno;
10608 #endif
10609
10610 #ifdef HAVE_LINUX_THREADS
10611         pthread_kill_other_threads_np();
10612 #endif
10613
10614         return 0;
10615
10616   ;
10617   return 0;
10618 }
10619 _ACEOF
10620 if ac_fn_c_try_link "$LINENO"; then :
10621   ol_cv_pthread_create=yes
10622 else
10623   ol_cv_pthread_create=no
10624 fi
10625 rm -f core conftest.err conftest.$ac_objext \
10626     conftest$ac_exeext conftest.$ac_ext
10627 else
10628   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10629 /* end confdefs.h.  */
10630
10631
10632 /* pthread test headers */
10633 #include <pthread.h>
10634 #if HAVE_PTHREADS < 7
10635 #include <errno.h>
10636 #endif
10637 #ifndef NULL
10638 #define NULL (void*)0
10639 #endif
10640
10641 static void *task(p)
10642         void *p;
10643 {
10644         return (void *) (p == NULL);
10645 }
10646
10647
10648 int main(argc, argv)
10649         int argc;
10650         char **argv;
10651 {
10652
10653         /* pthread test function */
10654 #ifndef PTHREAD_CREATE_DETACHED
10655 #define PTHREAD_CREATE_DETACHED 1
10656 #endif
10657         pthread_t t;
10658         int status;
10659         int detach = PTHREAD_CREATE_DETACHED;
10660
10661 #if HAVE_PTHREADS > 4
10662         /* Final pthreads */
10663         pthread_attr_t attr;
10664
10665         status = pthread_attr_init(&attr);
10666         if( status ) return status;
10667
10668 #if HAVE_PTHREADS < 7
10669         status = pthread_attr_setdetachstate(&attr, &detach);
10670         if( status < 0 ) status = errno;
10671 #else
10672         status = pthread_attr_setdetachstate(&attr, detach);
10673 #endif
10674         if( status ) return status;
10675         status = pthread_create( &t, &attr, task, NULL );
10676 #if HAVE_PTHREADS < 7
10677         if( status < 0 ) status = errno;
10678 #endif
10679         if( status ) return status;
10680 #else
10681         /* Draft 4 pthreads */
10682         status = pthread_create( &t, pthread_attr_default, task, NULL );
10683         if( status ) return errno;
10684
10685         /* give thread a chance to complete */
10686         /* it should remain joinable and hence detachable */
10687         sleep( 1 );
10688
10689         status = pthread_detach( &t );
10690         if( status ) return errno;
10691 #endif
10692
10693 #ifdef HAVE_LINUX_THREADS
10694         pthread_kill_other_threads_np();
10695 #endif
10696
10697         return 0;
10698
10699 }
10700
10701 _ACEOF
10702 if ac_fn_c_try_run "$LINENO"; then :
10703   ol_cv_pthread_create=yes
10704 else
10705   ol_cv_pthread_create=no
10706 fi
10707 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10708   conftest.$ac_objext conftest.beam conftest.$ac_ext
10709 fi
10710
10711 fi
10712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_create" >&5
10713 $as_echo "$ol_cv_pthread_create" >&6; }
10714
10715                 if test $ol_cv_pthread_create != no ; then
10716                         ol_link_threads=posix
10717                         ol_link_pthreads=""
10718                 fi
10719
10720                 # Pthread try link: -kthread (ol_cv_pthread_kthread)
10721 if test "$ol_link_threads" = no ; then
10722         # try -kthread
10723         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -kthread" >&5
10724 $as_echo_n "checking for pthread link with -kthread... " >&6; }
10725 if ${ol_cv_pthread_kthread+:} false; then :
10726   $as_echo_n "(cached) " >&6
10727 else
10728
10729                 # save the flags
10730                 ol_LIBS="$LIBS"
10731                 LIBS="-kthread $LIBS"
10732
10733                 if test "$cross_compiling" = yes; then :
10734   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10735 /* end confdefs.h.  */
10736
10737 /* pthread test headers */
10738 #include <pthread.h>
10739 #if HAVE_PTHREADS < 7
10740 #include <errno.h>
10741 #endif
10742 #ifndef NULL
10743 #define NULL (void*)0
10744 #endif
10745
10746 static void *task(p)
10747         void *p;
10748 {
10749         return (void *) (p == NULL);
10750 }
10751
10752 int
10753 main ()
10754 {
10755
10756         /* pthread test function */
10757 #ifndef PTHREAD_CREATE_DETACHED
10758 #define PTHREAD_CREATE_DETACHED 1
10759 #endif
10760         pthread_t t;
10761         int status;
10762         int detach = PTHREAD_CREATE_DETACHED;
10763
10764 #if HAVE_PTHREADS > 4
10765         /* Final pthreads */
10766         pthread_attr_t attr;
10767
10768         status = pthread_attr_init(&attr);
10769         if( status ) return status;
10770
10771 #if HAVE_PTHREADS < 7
10772         status = pthread_attr_setdetachstate(&attr, &detach);
10773         if( status < 0 ) status = errno;
10774 #else
10775         status = pthread_attr_setdetachstate(&attr, detach);
10776 #endif
10777         if( status ) return status;
10778         status = pthread_create( &t, &attr, task, NULL );
10779 #if HAVE_PTHREADS < 7
10780         if( status < 0 ) status = errno;
10781 #endif
10782         if( status ) return status;
10783 #else
10784         /* Draft 4 pthreads */
10785         status = pthread_create( &t, pthread_attr_default, task, NULL );
10786         if( status ) return errno;
10787
10788         /* give thread a chance to complete */
10789         /* it should remain joinable and hence detachable */
10790         sleep( 1 );
10791
10792         status = pthread_detach( &t );
10793         if( status ) return errno;
10794 #endif
10795
10796 #ifdef HAVE_LINUX_THREADS
10797         pthread_kill_other_threads_np();
10798 #endif
10799
10800         return 0;
10801
10802   ;
10803   return 0;
10804 }
10805 _ACEOF
10806 if ac_fn_c_try_link "$LINENO"; then :
10807   ol_cv_pthread_kthread=yes
10808 else
10809   ol_cv_pthread_kthread=no
10810 fi
10811 rm -f core conftest.err conftest.$ac_objext \
10812     conftest$ac_exeext conftest.$ac_ext
10813 else
10814   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10815 /* end confdefs.h.  */
10816
10817
10818 /* pthread test headers */
10819 #include <pthread.h>
10820 #if HAVE_PTHREADS < 7
10821 #include <errno.h>
10822 #endif
10823 #ifndef NULL
10824 #define NULL (void*)0
10825 #endif
10826
10827 static void *task(p)
10828         void *p;
10829 {
10830         return (void *) (p == NULL);
10831 }
10832
10833
10834 int main(argc, argv)
10835         int argc;
10836         char **argv;
10837 {
10838
10839         /* pthread test function */
10840 #ifndef PTHREAD_CREATE_DETACHED
10841 #define PTHREAD_CREATE_DETACHED 1
10842 #endif
10843         pthread_t t;
10844         int status;
10845         int detach = PTHREAD_CREATE_DETACHED;
10846
10847 #if HAVE_PTHREADS > 4
10848         /* Final pthreads */
10849         pthread_attr_t attr;
10850
10851         status = pthread_attr_init(&attr);
10852         if( status ) return status;
10853
10854 #if HAVE_PTHREADS < 7
10855         status = pthread_attr_setdetachstate(&attr, &detach);
10856         if( status < 0 ) status = errno;
10857 #else
10858         status = pthread_attr_setdetachstate(&attr, detach);
10859 #endif
10860         if( status ) return status;
10861         status = pthread_create( &t, &attr, task, NULL );
10862 #if HAVE_PTHREADS < 7
10863         if( status < 0 ) status = errno;
10864 #endif
10865         if( status ) return status;
10866 #else
10867         /* Draft 4 pthreads */
10868         status = pthread_create( &t, pthread_attr_default, task, NULL );
10869         if( status ) return errno;
10870
10871         /* give thread a chance to complete */
10872         /* it should remain joinable and hence detachable */
10873         sleep( 1 );
10874
10875         status = pthread_detach( &t );
10876         if( status ) return errno;
10877 #endif
10878
10879 #ifdef HAVE_LINUX_THREADS
10880         pthread_kill_other_threads_np();
10881 #endif
10882
10883         return 0;
10884
10885 }
10886
10887 _ACEOF
10888 if ac_fn_c_try_run "$LINENO"; then :
10889   ol_cv_pthread_kthread=yes
10890 else
10891   ol_cv_pthread_kthread=no
10892 fi
10893 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10894   conftest.$ac_objext conftest.beam conftest.$ac_ext
10895 fi
10896
10897
10898                 # restore the LIBS
10899                 LIBS="$ol_LIBS"
10900
10901 fi
10902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_kthread" >&5
10903 $as_echo "$ol_cv_pthread_kthread" >&6; }
10904
10905         if test $ol_cv_pthread_kthread = yes ; then
10906                 ol_link_pthreads="-kthread"
10907                 ol_link_threads=posix
10908         fi
10909 fi
10910
10911                 # Pthread try link: -pthread (ol_cv_pthread_pthread)
10912 if test "$ol_link_threads" = no ; then
10913         # try -pthread
10914         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -pthread" >&5
10915 $as_echo_n "checking for pthread link with -pthread... " >&6; }
10916 if ${ol_cv_pthread_pthread+:} false; then :
10917   $as_echo_n "(cached) " >&6
10918 else
10919
10920                 # save the flags
10921                 ol_LIBS="$LIBS"
10922                 LIBS="-pthread $LIBS"
10923
10924                 if test "$cross_compiling" = yes; then :
10925   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10926 /* end confdefs.h.  */
10927
10928 /* pthread test headers */
10929 #include <pthread.h>
10930 #if HAVE_PTHREADS < 7
10931 #include <errno.h>
10932 #endif
10933 #ifndef NULL
10934 #define NULL (void*)0
10935 #endif
10936
10937 static void *task(p)
10938         void *p;
10939 {
10940         return (void *) (p == NULL);
10941 }
10942
10943 int
10944 main ()
10945 {
10946
10947         /* pthread test function */
10948 #ifndef PTHREAD_CREATE_DETACHED
10949 #define PTHREAD_CREATE_DETACHED 1
10950 #endif
10951         pthread_t t;
10952         int status;
10953         int detach = PTHREAD_CREATE_DETACHED;
10954
10955 #if HAVE_PTHREADS > 4
10956         /* Final pthreads */
10957         pthread_attr_t attr;
10958
10959         status = pthread_attr_init(&attr);
10960         if( status ) return status;
10961
10962 #if HAVE_PTHREADS < 7
10963         status = pthread_attr_setdetachstate(&attr, &detach);
10964         if( status < 0 ) status = errno;
10965 #else
10966         status = pthread_attr_setdetachstate(&attr, detach);
10967 #endif
10968         if( status ) return status;
10969         status = pthread_create( &t, &attr, task, NULL );
10970 #if HAVE_PTHREADS < 7
10971         if( status < 0 ) status = errno;
10972 #endif
10973         if( status ) return status;
10974 #else
10975         /* Draft 4 pthreads */
10976         status = pthread_create( &t, pthread_attr_default, task, NULL );
10977         if( status ) return errno;
10978
10979         /* give thread a chance to complete */
10980         /* it should remain joinable and hence detachable */
10981         sleep( 1 );
10982
10983         status = pthread_detach( &t );
10984         if( status ) return errno;
10985 #endif
10986
10987 #ifdef HAVE_LINUX_THREADS
10988         pthread_kill_other_threads_np();
10989 #endif
10990
10991         return 0;
10992
10993   ;
10994   return 0;
10995 }
10996 _ACEOF
10997 if ac_fn_c_try_link "$LINENO"; then :
10998   ol_cv_pthread_pthread=yes
10999 else
11000   ol_cv_pthread_pthread=no
11001 fi
11002 rm -f core conftest.err conftest.$ac_objext \
11003     conftest$ac_exeext conftest.$ac_ext
11004 else
11005   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11006 /* end confdefs.h.  */
11007
11008
11009 /* pthread test headers */
11010 #include <pthread.h>
11011 #if HAVE_PTHREADS < 7
11012 #include <errno.h>
11013 #endif
11014 #ifndef NULL
11015 #define NULL (void*)0
11016 #endif
11017
11018 static void *task(p)
11019         void *p;
11020 {
11021         return (void *) (p == NULL);
11022 }
11023
11024
11025 int main(argc, argv)
11026         int argc;
11027         char **argv;
11028 {
11029
11030         /* pthread test function */
11031 #ifndef PTHREAD_CREATE_DETACHED
11032 #define PTHREAD_CREATE_DETACHED 1
11033 #endif
11034         pthread_t t;
11035         int status;
11036         int detach = PTHREAD_CREATE_DETACHED;
11037
11038 #if HAVE_PTHREADS > 4
11039         /* Final pthreads */
11040         pthread_attr_t attr;
11041
11042         status = pthread_attr_init(&attr);
11043         if( status ) return status;
11044
11045 #if HAVE_PTHREADS < 7
11046         status = pthread_attr_setdetachstate(&attr, &detach);
11047         if( status < 0 ) status = errno;
11048 #else
11049         status = pthread_attr_setdetachstate(&attr, detach);
11050 #endif
11051         if( status ) return status;
11052         status = pthread_create( &t, &attr, task, NULL );
11053 #if HAVE_PTHREADS < 7
11054         if( status < 0 ) status = errno;
11055 #endif
11056         if( status ) return status;
11057 #else
11058         /* Draft 4 pthreads */
11059         status = pthread_create( &t, pthread_attr_default, task, NULL );
11060         if( status ) return errno;
11061
11062         /* give thread a chance to complete */
11063         /* it should remain joinable and hence detachable */
11064         sleep( 1 );
11065
11066         status = pthread_detach( &t );
11067         if( status ) return errno;
11068 #endif
11069
11070 #ifdef HAVE_LINUX_THREADS
11071         pthread_kill_other_threads_np();
11072 #endif
11073
11074         return 0;
11075
11076 }
11077
11078 _ACEOF
11079 if ac_fn_c_try_run "$LINENO"; then :
11080   ol_cv_pthread_pthread=yes
11081 else
11082   ol_cv_pthread_pthread=no
11083 fi
11084 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11085   conftest.$ac_objext conftest.beam conftest.$ac_ext
11086 fi
11087
11088
11089                 # restore the LIBS
11090                 LIBS="$ol_LIBS"
11091
11092 fi
11093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_pthread" >&5
11094 $as_echo "$ol_cv_pthread_pthread" >&6; }
11095
11096         if test $ol_cv_pthread_pthread = yes ; then
11097                 ol_link_pthreads="-pthread"
11098                 ol_link_threads=posix
11099         fi
11100 fi
11101
11102                 # Pthread try link: -pthreads (ol_cv_pthread_pthreads)
11103 if test "$ol_link_threads" = no ; then
11104         # try -pthreads
11105         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -pthreads" >&5
11106 $as_echo_n "checking for pthread link with -pthreads... " >&6; }
11107 if ${ol_cv_pthread_pthreads+:} false; then :
11108   $as_echo_n "(cached) " >&6
11109 else
11110
11111                 # save the flags
11112                 ol_LIBS="$LIBS"
11113                 LIBS="-pthreads $LIBS"
11114
11115                 if test "$cross_compiling" = yes; then :
11116   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11117 /* end confdefs.h.  */
11118
11119 /* pthread test headers */
11120 #include <pthread.h>
11121 #if HAVE_PTHREADS < 7
11122 #include <errno.h>
11123 #endif
11124 #ifndef NULL
11125 #define NULL (void*)0
11126 #endif
11127
11128 static void *task(p)
11129         void *p;
11130 {
11131         return (void *) (p == NULL);
11132 }
11133
11134 int
11135 main ()
11136 {
11137
11138         /* pthread test function */
11139 #ifndef PTHREAD_CREATE_DETACHED
11140 #define PTHREAD_CREATE_DETACHED 1
11141 #endif
11142         pthread_t t;
11143         int status;
11144         int detach = PTHREAD_CREATE_DETACHED;
11145
11146 #if HAVE_PTHREADS > 4
11147         /* Final pthreads */
11148         pthread_attr_t attr;
11149
11150         status = pthread_attr_init(&attr);
11151         if( status ) return status;
11152
11153 #if HAVE_PTHREADS < 7
11154         status = pthread_attr_setdetachstate(&attr, &detach);
11155         if( status < 0 ) status = errno;
11156 #else
11157         status = pthread_attr_setdetachstate(&attr, detach);
11158 #endif
11159         if( status ) return status;
11160         status = pthread_create( &t, &attr, task, NULL );
11161 #if HAVE_PTHREADS < 7
11162         if( status < 0 ) status = errno;
11163 #endif
11164         if( status ) return status;
11165 #else
11166         /* Draft 4 pthreads */
11167         status = pthread_create( &t, pthread_attr_default, task, NULL );
11168         if( status ) return errno;
11169
11170         /* give thread a chance to complete */
11171         /* it should remain joinable and hence detachable */
11172         sleep( 1 );
11173
11174         status = pthread_detach( &t );
11175         if( status ) return errno;
11176 #endif
11177
11178 #ifdef HAVE_LINUX_THREADS
11179         pthread_kill_other_threads_np();
11180 #endif
11181
11182         return 0;
11183
11184   ;
11185   return 0;
11186 }
11187 _ACEOF
11188 if ac_fn_c_try_link "$LINENO"; then :
11189   ol_cv_pthread_pthreads=yes
11190 else
11191   ol_cv_pthread_pthreads=no
11192 fi
11193 rm -f core conftest.err conftest.$ac_objext \
11194     conftest$ac_exeext conftest.$ac_ext
11195 else
11196   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11197 /* end confdefs.h.  */
11198
11199
11200 /* pthread test headers */
11201 #include <pthread.h>
11202 #if HAVE_PTHREADS < 7
11203 #include <errno.h>
11204 #endif
11205 #ifndef NULL
11206 #define NULL (void*)0
11207 #endif
11208
11209 static void *task(p)
11210         void *p;
11211 {
11212         return (void *) (p == NULL);
11213 }
11214
11215
11216 int main(argc, argv)
11217         int argc;
11218         char **argv;
11219 {
11220
11221         /* pthread test function */
11222 #ifndef PTHREAD_CREATE_DETACHED
11223 #define PTHREAD_CREATE_DETACHED 1
11224 #endif
11225         pthread_t t;
11226         int status;
11227         int detach = PTHREAD_CREATE_DETACHED;
11228
11229 #if HAVE_PTHREADS > 4
11230         /* Final pthreads */
11231         pthread_attr_t attr;
11232
11233         status = pthread_attr_init(&attr);
11234         if( status ) return status;
11235
11236 #if HAVE_PTHREADS < 7
11237         status = pthread_attr_setdetachstate(&attr, &detach);
11238         if( status < 0 ) status = errno;
11239 #else
11240         status = pthread_attr_setdetachstate(&attr, detach);
11241 #endif
11242         if( status ) return status;
11243         status = pthread_create( &t, &attr, task, NULL );
11244 #if HAVE_PTHREADS < 7
11245         if( status < 0 ) status = errno;
11246 #endif
11247         if( status ) return status;
11248 #else
11249         /* Draft 4 pthreads */
11250         status = pthread_create( &t, pthread_attr_default, task, NULL );
11251         if( status ) return errno;
11252
11253         /* give thread a chance to complete */
11254         /* it should remain joinable and hence detachable */
11255         sleep( 1 );
11256
11257         status = pthread_detach( &t );
11258         if( status ) return errno;
11259 #endif
11260
11261 #ifdef HAVE_LINUX_THREADS
11262         pthread_kill_other_threads_np();
11263 #endif
11264
11265         return 0;
11266
11267 }
11268
11269 _ACEOF
11270 if ac_fn_c_try_run "$LINENO"; then :
11271   ol_cv_pthread_pthreads=yes
11272 else
11273   ol_cv_pthread_pthreads=no
11274 fi
11275 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11276   conftest.$ac_objext conftest.beam conftest.$ac_ext
11277 fi
11278
11279
11280                 # restore the LIBS
11281                 LIBS="$ol_LIBS"
11282
11283 fi
11284 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_pthreads" >&5
11285 $as_echo "$ol_cv_pthread_pthreads" >&6; }
11286
11287         if test $ol_cv_pthread_pthreads = yes ; then
11288                 ol_link_pthreads="-pthreads"
11289                 ol_link_threads=posix
11290         fi
11291 fi
11292
11293                 # Pthread try link: -mthreads (ol_cv_pthread_mthreads)
11294 if test "$ol_link_threads" = no ; then
11295         # try -mthreads
11296         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -mthreads" >&5
11297 $as_echo_n "checking for pthread link with -mthreads... " >&6; }
11298 if ${ol_cv_pthread_mthreads+:} false; then :
11299   $as_echo_n "(cached) " >&6
11300 else
11301
11302                 # save the flags
11303                 ol_LIBS="$LIBS"
11304                 LIBS="-mthreads $LIBS"
11305
11306                 if test "$cross_compiling" = yes; then :
11307   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11308 /* end confdefs.h.  */
11309
11310 /* pthread test headers */
11311 #include <pthread.h>
11312 #if HAVE_PTHREADS < 7
11313 #include <errno.h>
11314 #endif
11315 #ifndef NULL
11316 #define NULL (void*)0
11317 #endif
11318
11319 static void *task(p)
11320         void *p;
11321 {
11322         return (void *) (p == NULL);
11323 }
11324
11325 int
11326 main ()
11327 {
11328
11329         /* pthread test function */
11330 #ifndef PTHREAD_CREATE_DETACHED
11331 #define PTHREAD_CREATE_DETACHED 1
11332 #endif
11333         pthread_t t;
11334         int status;
11335         int detach = PTHREAD_CREATE_DETACHED;
11336
11337 #if HAVE_PTHREADS > 4
11338         /* Final pthreads */
11339         pthread_attr_t attr;
11340
11341         status = pthread_attr_init(&attr);
11342         if( status ) return status;
11343
11344 #if HAVE_PTHREADS < 7
11345         status = pthread_attr_setdetachstate(&attr, &detach);
11346         if( status < 0 ) status = errno;
11347 #else
11348         status = pthread_attr_setdetachstate(&attr, detach);
11349 #endif
11350         if( status ) return status;
11351         status = pthread_create( &t, &attr, task, NULL );
11352 #if HAVE_PTHREADS < 7
11353         if( status < 0 ) status = errno;
11354 #endif
11355         if( status ) return status;
11356 #else
11357         /* Draft 4 pthreads */
11358         status = pthread_create( &t, pthread_attr_default, task, NULL );
11359         if( status ) return errno;
11360
11361         /* give thread a chance to complete */
11362         /* it should remain joinable and hence detachable */
11363         sleep( 1 );
11364
11365         status = pthread_detach( &t );
11366         if( status ) return errno;
11367 #endif
11368
11369 #ifdef HAVE_LINUX_THREADS
11370         pthread_kill_other_threads_np();
11371 #endif
11372
11373         return 0;
11374
11375   ;
11376   return 0;
11377 }
11378 _ACEOF
11379 if ac_fn_c_try_link "$LINENO"; then :
11380   ol_cv_pthread_mthreads=yes
11381 else
11382   ol_cv_pthread_mthreads=no
11383 fi
11384 rm -f core conftest.err conftest.$ac_objext \
11385     conftest$ac_exeext conftest.$ac_ext
11386 else
11387   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11388 /* end confdefs.h.  */
11389
11390
11391 /* pthread test headers */
11392 #include <pthread.h>
11393 #if HAVE_PTHREADS < 7
11394 #include <errno.h>
11395 #endif
11396 #ifndef NULL
11397 #define NULL (void*)0
11398 #endif
11399
11400 static void *task(p)
11401         void *p;
11402 {
11403         return (void *) (p == NULL);
11404 }
11405
11406
11407 int main(argc, argv)
11408         int argc;
11409         char **argv;
11410 {
11411
11412         /* pthread test function */
11413 #ifndef PTHREAD_CREATE_DETACHED
11414 #define PTHREAD_CREATE_DETACHED 1
11415 #endif
11416         pthread_t t;
11417         int status;
11418         int detach = PTHREAD_CREATE_DETACHED;
11419
11420 #if HAVE_PTHREADS > 4
11421         /* Final pthreads */
11422         pthread_attr_t attr;
11423
11424         status = pthread_attr_init(&attr);
11425         if( status ) return status;
11426
11427 #if HAVE_PTHREADS < 7
11428         status = pthread_attr_setdetachstate(&attr, &detach);
11429         if( status < 0 ) status = errno;
11430 #else
11431         status = pthread_attr_setdetachstate(&attr, detach);
11432 #endif
11433         if( status ) return status;
11434         status = pthread_create( &t, &attr, task, NULL );
11435 #if HAVE_PTHREADS < 7
11436         if( status < 0 ) status = errno;
11437 #endif
11438         if( status ) return status;
11439 #else
11440         /* Draft 4 pthreads */
11441         status = pthread_create( &t, pthread_attr_default, task, NULL );
11442         if( status ) return errno;
11443
11444         /* give thread a chance to complete */
11445         /* it should remain joinable and hence detachable */
11446         sleep( 1 );
11447
11448         status = pthread_detach( &t );
11449         if( status ) return errno;
11450 #endif
11451
11452 #ifdef HAVE_LINUX_THREADS
11453         pthread_kill_other_threads_np();
11454 #endif
11455
11456         return 0;
11457
11458 }
11459
11460 _ACEOF
11461 if ac_fn_c_try_run "$LINENO"; then :
11462   ol_cv_pthread_mthreads=yes
11463 else
11464   ol_cv_pthread_mthreads=no
11465 fi
11466 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11467   conftest.$ac_objext conftest.beam conftest.$ac_ext
11468 fi
11469
11470
11471                 # restore the LIBS
11472                 LIBS="$ol_LIBS"
11473
11474 fi
11475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_mthreads" >&5
11476 $as_echo "$ol_cv_pthread_mthreads" >&6; }
11477
11478         if test $ol_cv_pthread_mthreads = yes ; then
11479                 ol_link_pthreads="-mthreads"
11480                 ol_link_threads=posix
11481         fi
11482 fi
11483
11484                 # Pthread try link: -thread (ol_cv_pthread_thread)
11485 if test "$ol_link_threads" = no ; then
11486         # try -thread
11487         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -thread" >&5
11488 $as_echo_n "checking for pthread link with -thread... " >&6; }
11489 if ${ol_cv_pthread_thread+:} false; then :
11490   $as_echo_n "(cached) " >&6
11491 else
11492
11493                 # save the flags
11494                 ol_LIBS="$LIBS"
11495                 LIBS="-thread $LIBS"
11496
11497                 if test "$cross_compiling" = yes; then :
11498   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11499 /* end confdefs.h.  */
11500
11501 /* pthread test headers */
11502 #include <pthread.h>
11503 #if HAVE_PTHREADS < 7
11504 #include <errno.h>
11505 #endif
11506 #ifndef NULL
11507 #define NULL (void*)0
11508 #endif
11509
11510 static void *task(p)
11511         void *p;
11512 {
11513         return (void *) (p == NULL);
11514 }
11515
11516 int
11517 main ()
11518 {
11519
11520         /* pthread test function */
11521 #ifndef PTHREAD_CREATE_DETACHED
11522 #define PTHREAD_CREATE_DETACHED 1
11523 #endif
11524         pthread_t t;
11525         int status;
11526         int detach = PTHREAD_CREATE_DETACHED;
11527
11528 #if HAVE_PTHREADS > 4
11529         /* Final pthreads */
11530         pthread_attr_t attr;
11531
11532         status = pthread_attr_init(&attr);
11533         if( status ) return status;
11534
11535 #if HAVE_PTHREADS < 7
11536         status = pthread_attr_setdetachstate(&attr, &detach);
11537         if( status < 0 ) status = errno;
11538 #else
11539         status = pthread_attr_setdetachstate(&attr, detach);
11540 #endif
11541         if( status ) return status;
11542         status = pthread_create( &t, &attr, task, NULL );
11543 #if HAVE_PTHREADS < 7
11544         if( status < 0 ) status = errno;
11545 #endif
11546         if( status ) return status;
11547 #else
11548         /* Draft 4 pthreads */
11549         status = pthread_create( &t, pthread_attr_default, task, NULL );
11550         if( status ) return errno;
11551
11552         /* give thread a chance to complete */
11553         /* it should remain joinable and hence detachable */
11554         sleep( 1 );
11555
11556         status = pthread_detach( &t );
11557         if( status ) return errno;
11558 #endif
11559
11560 #ifdef HAVE_LINUX_THREADS
11561         pthread_kill_other_threads_np();
11562 #endif
11563
11564         return 0;
11565
11566   ;
11567   return 0;
11568 }
11569 _ACEOF
11570 if ac_fn_c_try_link "$LINENO"; then :
11571   ol_cv_pthread_thread=yes
11572 else
11573   ol_cv_pthread_thread=no
11574 fi
11575 rm -f core conftest.err conftest.$ac_objext \
11576     conftest$ac_exeext conftest.$ac_ext
11577 else
11578   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11579 /* end confdefs.h.  */
11580
11581
11582 /* pthread test headers */
11583 #include <pthread.h>
11584 #if HAVE_PTHREADS < 7
11585 #include <errno.h>
11586 #endif
11587 #ifndef NULL
11588 #define NULL (void*)0
11589 #endif
11590
11591 static void *task(p)
11592         void *p;
11593 {
11594         return (void *) (p == NULL);
11595 }
11596
11597
11598 int main(argc, argv)
11599         int argc;
11600         char **argv;
11601 {
11602
11603         /* pthread test function */
11604 #ifndef PTHREAD_CREATE_DETACHED
11605 #define PTHREAD_CREATE_DETACHED 1
11606 #endif
11607         pthread_t t;
11608         int status;
11609         int detach = PTHREAD_CREATE_DETACHED;
11610
11611 #if HAVE_PTHREADS > 4
11612         /* Final pthreads */
11613         pthread_attr_t attr;
11614
11615         status = pthread_attr_init(&attr);
11616         if( status ) return status;
11617
11618 #if HAVE_PTHREADS < 7
11619         status = pthread_attr_setdetachstate(&attr, &detach);
11620         if( status < 0 ) status = errno;
11621 #else
11622         status = pthread_attr_setdetachstate(&attr, detach);
11623 #endif
11624         if( status ) return status;
11625         status = pthread_create( &t, &attr, task, NULL );
11626 #if HAVE_PTHREADS < 7
11627         if( status < 0 ) status = errno;
11628 #endif
11629         if( status ) return status;
11630 #else
11631         /* Draft 4 pthreads */
11632         status = pthread_create( &t, pthread_attr_default, task, NULL );
11633         if( status ) return errno;
11634
11635         /* give thread a chance to complete */
11636         /* it should remain joinable and hence detachable */
11637         sleep( 1 );
11638
11639         status = pthread_detach( &t );
11640         if( status ) return errno;
11641 #endif
11642
11643 #ifdef HAVE_LINUX_THREADS
11644         pthread_kill_other_threads_np();
11645 #endif
11646
11647         return 0;
11648
11649 }
11650
11651 _ACEOF
11652 if ac_fn_c_try_run "$LINENO"; then :
11653   ol_cv_pthread_thread=yes
11654 else
11655   ol_cv_pthread_thread=no
11656 fi
11657 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11658   conftest.$ac_objext conftest.beam conftest.$ac_ext
11659 fi
11660
11661
11662                 # restore the LIBS
11663                 LIBS="$ol_LIBS"
11664
11665 fi
11666 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_thread" >&5
11667 $as_echo "$ol_cv_pthread_thread" >&6; }
11668
11669         if test $ol_cv_pthread_thread = yes ; then
11670                 ol_link_pthreads="-thread"
11671                 ol_link_threads=posix
11672         fi
11673 fi
11674
11675
11676                 # Pthread try link: -lpthread -lmach -lexc -lc_r (ol_cv_pthread_lpthread_lmach_lexc_lc_r)
11677 if test "$ol_link_threads" = no ; then
11678         # try -lpthread -lmach -lexc -lc_r
11679         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthread -lmach -lexc -lc_r" >&5
11680 $as_echo_n "checking for pthread link with -lpthread -lmach -lexc -lc_r... " >&6; }
11681 if ${ol_cv_pthread_lpthread_lmach_lexc_lc_r+:} false; then :
11682   $as_echo_n "(cached) " >&6
11683 else
11684
11685                 # save the flags
11686                 ol_LIBS="$LIBS"
11687                 LIBS="-lpthread -lmach -lexc -lc_r $LIBS"
11688
11689                 if test "$cross_compiling" = yes; then :
11690   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11691 /* end confdefs.h.  */
11692
11693 /* pthread test headers */
11694 #include <pthread.h>
11695 #if HAVE_PTHREADS < 7
11696 #include <errno.h>
11697 #endif
11698 #ifndef NULL
11699 #define NULL (void*)0
11700 #endif
11701
11702 static void *task(p)
11703         void *p;
11704 {
11705         return (void *) (p == NULL);
11706 }
11707
11708 int
11709 main ()
11710 {
11711
11712         /* pthread test function */
11713 #ifndef PTHREAD_CREATE_DETACHED
11714 #define PTHREAD_CREATE_DETACHED 1
11715 #endif
11716         pthread_t t;
11717         int status;
11718         int detach = PTHREAD_CREATE_DETACHED;
11719
11720 #if HAVE_PTHREADS > 4
11721         /* Final pthreads */
11722         pthread_attr_t attr;
11723
11724         status = pthread_attr_init(&attr);
11725         if( status ) return status;
11726
11727 #if HAVE_PTHREADS < 7
11728         status = pthread_attr_setdetachstate(&attr, &detach);
11729         if( status < 0 ) status = errno;
11730 #else
11731         status = pthread_attr_setdetachstate(&attr, detach);
11732 #endif
11733         if( status ) return status;
11734         status = pthread_create( &t, &attr, task, NULL );
11735 #if HAVE_PTHREADS < 7
11736         if( status < 0 ) status = errno;
11737 #endif
11738         if( status ) return status;
11739 #else
11740         /* Draft 4 pthreads */
11741         status = pthread_create( &t, pthread_attr_default, task, NULL );
11742         if( status ) return errno;
11743
11744         /* give thread a chance to complete */
11745         /* it should remain joinable and hence detachable */
11746         sleep( 1 );
11747
11748         status = pthread_detach( &t );
11749         if( status ) return errno;
11750 #endif
11751
11752 #ifdef HAVE_LINUX_THREADS
11753         pthread_kill_other_threads_np();
11754 #endif
11755
11756         return 0;
11757
11758   ;
11759   return 0;
11760 }
11761 _ACEOF
11762 if ac_fn_c_try_link "$LINENO"; then :
11763   ol_cv_pthread_lpthread_lmach_lexc_lc_r=yes
11764 else
11765   ol_cv_pthread_lpthread_lmach_lexc_lc_r=no
11766 fi
11767 rm -f core conftest.err conftest.$ac_objext \
11768     conftest$ac_exeext conftest.$ac_ext
11769 else
11770   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11771 /* end confdefs.h.  */
11772
11773
11774 /* pthread test headers */
11775 #include <pthread.h>
11776 #if HAVE_PTHREADS < 7
11777 #include <errno.h>
11778 #endif
11779 #ifndef NULL
11780 #define NULL (void*)0
11781 #endif
11782
11783 static void *task(p)
11784         void *p;
11785 {
11786         return (void *) (p == NULL);
11787 }
11788
11789
11790 int main(argc, argv)
11791         int argc;
11792         char **argv;
11793 {
11794
11795         /* pthread test function */
11796 #ifndef PTHREAD_CREATE_DETACHED
11797 #define PTHREAD_CREATE_DETACHED 1
11798 #endif
11799         pthread_t t;
11800         int status;
11801         int detach = PTHREAD_CREATE_DETACHED;
11802
11803 #if HAVE_PTHREADS > 4
11804         /* Final pthreads */
11805         pthread_attr_t attr;
11806
11807         status = pthread_attr_init(&attr);
11808         if( status ) return status;
11809
11810 #if HAVE_PTHREADS < 7
11811         status = pthread_attr_setdetachstate(&attr, &detach);
11812         if( status < 0 ) status = errno;
11813 #else
11814         status = pthread_attr_setdetachstate(&attr, detach);
11815 #endif
11816         if( status ) return status;
11817         status = pthread_create( &t, &attr, task, NULL );
11818 #if HAVE_PTHREADS < 7
11819         if( status < 0 ) status = errno;
11820 #endif
11821         if( status ) return status;
11822 #else
11823         /* Draft 4 pthreads */
11824         status = pthread_create( &t, pthread_attr_default, task, NULL );
11825         if( status ) return errno;
11826
11827         /* give thread a chance to complete */
11828         /* it should remain joinable and hence detachable */
11829         sleep( 1 );
11830
11831         status = pthread_detach( &t );
11832         if( status ) return errno;
11833 #endif
11834
11835 #ifdef HAVE_LINUX_THREADS
11836         pthread_kill_other_threads_np();
11837 #endif
11838
11839         return 0;
11840
11841 }
11842
11843 _ACEOF
11844 if ac_fn_c_try_run "$LINENO"; then :
11845   ol_cv_pthread_lpthread_lmach_lexc_lc_r=yes
11846 else
11847   ol_cv_pthread_lpthread_lmach_lexc_lc_r=no
11848 fi
11849 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11850   conftest.$ac_objext conftest.beam conftest.$ac_ext
11851 fi
11852
11853
11854                 # restore the LIBS
11855                 LIBS="$ol_LIBS"
11856
11857 fi
11858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lpthread_lmach_lexc_lc_r" >&5
11859 $as_echo "$ol_cv_pthread_lpthread_lmach_lexc_lc_r" >&6; }
11860
11861         if test $ol_cv_pthread_lpthread_lmach_lexc_lc_r = yes ; then
11862                 ol_link_pthreads="-lpthread -lmach -lexc -lc_r"
11863                 ol_link_threads=posix
11864         fi
11865 fi
11866
11867                 # Pthread try link: -lpthread -lmach -lexc (ol_cv_pthread_lpthread_lmach_lexc)
11868 if test "$ol_link_threads" = no ; then
11869         # try -lpthread -lmach -lexc
11870         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthread -lmach -lexc" >&5
11871 $as_echo_n "checking for pthread link with -lpthread -lmach -lexc... " >&6; }
11872 if ${ol_cv_pthread_lpthread_lmach_lexc+:} false; then :
11873   $as_echo_n "(cached) " >&6
11874 else
11875
11876                 # save the flags
11877                 ol_LIBS="$LIBS"
11878                 LIBS="-lpthread -lmach -lexc $LIBS"
11879
11880                 if test "$cross_compiling" = yes; then :
11881   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11882 /* end confdefs.h.  */
11883
11884 /* pthread test headers */
11885 #include <pthread.h>
11886 #if HAVE_PTHREADS < 7
11887 #include <errno.h>
11888 #endif
11889 #ifndef NULL
11890 #define NULL (void*)0
11891 #endif
11892
11893 static void *task(p)
11894         void *p;
11895 {
11896         return (void *) (p == NULL);
11897 }
11898
11899 int
11900 main ()
11901 {
11902
11903         /* pthread test function */
11904 #ifndef PTHREAD_CREATE_DETACHED
11905 #define PTHREAD_CREATE_DETACHED 1
11906 #endif
11907         pthread_t t;
11908         int status;
11909         int detach = PTHREAD_CREATE_DETACHED;
11910
11911 #if HAVE_PTHREADS > 4
11912         /* Final pthreads */
11913         pthread_attr_t attr;
11914
11915         status = pthread_attr_init(&attr);
11916         if( status ) return status;
11917
11918 #if HAVE_PTHREADS < 7
11919         status = pthread_attr_setdetachstate(&attr, &detach);
11920         if( status < 0 ) status = errno;
11921 #else
11922         status = pthread_attr_setdetachstate(&attr, detach);
11923 #endif
11924         if( status ) return status;
11925         status = pthread_create( &t, &attr, task, NULL );
11926 #if HAVE_PTHREADS < 7
11927         if( status < 0 ) status = errno;
11928 #endif
11929         if( status ) return status;
11930 #else
11931         /* Draft 4 pthreads */
11932         status = pthread_create( &t, pthread_attr_default, task, NULL );
11933         if( status ) return errno;
11934
11935         /* give thread a chance to complete */
11936         /* it should remain joinable and hence detachable */
11937         sleep( 1 );
11938
11939         status = pthread_detach( &t );
11940         if( status ) return errno;
11941 #endif
11942
11943 #ifdef HAVE_LINUX_THREADS
11944         pthread_kill_other_threads_np();
11945 #endif
11946
11947         return 0;
11948
11949   ;
11950   return 0;
11951 }
11952 _ACEOF
11953 if ac_fn_c_try_link "$LINENO"; then :
11954   ol_cv_pthread_lpthread_lmach_lexc=yes
11955 else
11956   ol_cv_pthread_lpthread_lmach_lexc=no
11957 fi
11958 rm -f core conftest.err conftest.$ac_objext \
11959     conftest$ac_exeext conftest.$ac_ext
11960 else
11961   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11962 /* end confdefs.h.  */
11963
11964
11965 /* pthread test headers */
11966 #include <pthread.h>
11967 #if HAVE_PTHREADS < 7
11968 #include <errno.h>
11969 #endif
11970 #ifndef NULL
11971 #define NULL (void*)0
11972 #endif
11973
11974 static void *task(p)
11975         void *p;
11976 {
11977         return (void *) (p == NULL);
11978 }
11979
11980
11981 int main(argc, argv)
11982         int argc;
11983         char **argv;
11984 {
11985
11986         /* pthread test function */
11987 #ifndef PTHREAD_CREATE_DETACHED
11988 #define PTHREAD_CREATE_DETACHED 1
11989 #endif
11990         pthread_t t;
11991         int status;
11992         int detach = PTHREAD_CREATE_DETACHED;
11993
11994 #if HAVE_PTHREADS > 4
11995         /* Final pthreads */
11996         pthread_attr_t attr;
11997
11998         status = pthread_attr_init(&attr);
11999         if( status ) return status;
12000
12001 #if HAVE_PTHREADS < 7
12002         status = pthread_attr_setdetachstate(&attr, &detach);
12003         if( status < 0 ) status = errno;
12004 #else
12005         status = pthread_attr_setdetachstate(&attr, detach);
12006 #endif
12007         if( status ) return status;
12008         status = pthread_create( &t, &attr, task, NULL );
12009 #if HAVE_PTHREADS < 7
12010         if( status < 0 ) status = errno;
12011 #endif
12012         if( status ) return status;
12013 #else
12014         /* Draft 4 pthreads */
12015         status = pthread_create( &t, pthread_attr_default, task, NULL );
12016         if( status ) return errno;
12017
12018         /* give thread a chance to complete */
12019         /* it should remain joinable and hence detachable */
12020         sleep( 1 );
12021
12022         status = pthread_detach( &t );
12023         if( status ) return errno;
12024 #endif
12025
12026 #ifdef HAVE_LINUX_THREADS
12027         pthread_kill_other_threads_np();
12028 #endif
12029
12030         return 0;
12031
12032 }
12033
12034 _ACEOF
12035 if ac_fn_c_try_run "$LINENO"; then :
12036   ol_cv_pthread_lpthread_lmach_lexc=yes
12037 else
12038   ol_cv_pthread_lpthread_lmach_lexc=no
12039 fi
12040 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12041   conftest.$ac_objext conftest.beam conftest.$ac_ext
12042 fi
12043
12044
12045                 # restore the LIBS
12046                 LIBS="$ol_LIBS"
12047
12048 fi
12049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lpthread_lmach_lexc" >&5
12050 $as_echo "$ol_cv_pthread_lpthread_lmach_lexc" >&6; }
12051
12052         if test $ol_cv_pthread_lpthread_lmach_lexc = yes ; then
12053                 ol_link_pthreads="-lpthread -lmach -lexc"
12054                 ol_link_threads=posix
12055         fi
12056 fi
12057
12058
12059                 # Pthread try link: -lpthread -Wl,-woff,85 (ol_cv_pthread_lib_lpthread_woff)
12060 if test "$ol_link_threads" = no ; then
12061         # try -lpthread -Wl,-woff,85
12062         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthread -Wl,-woff,85" >&5
12063 $as_echo_n "checking for pthread link with -lpthread -Wl,-woff,85... " >&6; }
12064 if ${ol_cv_pthread_lib_lpthread_woff+:} false; then :
12065   $as_echo_n "(cached) " >&6
12066 else
12067
12068                 # save the flags
12069                 ol_LIBS="$LIBS"
12070                 LIBS="-lpthread -Wl,-woff,85 $LIBS"
12071
12072                 if test "$cross_compiling" = yes; then :
12073   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12074 /* end confdefs.h.  */
12075
12076 /* pthread test headers */
12077 #include <pthread.h>
12078 #if HAVE_PTHREADS < 7
12079 #include <errno.h>
12080 #endif
12081 #ifndef NULL
12082 #define NULL (void*)0
12083 #endif
12084
12085 static void *task(p)
12086         void *p;
12087 {
12088         return (void *) (p == NULL);
12089 }
12090
12091 int
12092 main ()
12093 {
12094
12095         /* pthread test function */
12096 #ifndef PTHREAD_CREATE_DETACHED
12097 #define PTHREAD_CREATE_DETACHED 1
12098 #endif
12099         pthread_t t;
12100         int status;
12101         int detach = PTHREAD_CREATE_DETACHED;
12102
12103 #if HAVE_PTHREADS > 4
12104         /* Final pthreads */
12105         pthread_attr_t attr;
12106
12107         status = pthread_attr_init(&attr);
12108         if( status ) return status;
12109
12110 #if HAVE_PTHREADS < 7
12111         status = pthread_attr_setdetachstate(&attr, &detach);
12112         if( status < 0 ) status = errno;
12113 #else
12114         status = pthread_attr_setdetachstate(&attr, detach);
12115 #endif
12116         if( status ) return status;
12117         status = pthread_create( &t, &attr, task, NULL );
12118 #if HAVE_PTHREADS < 7
12119         if( status < 0 ) status = errno;
12120 #endif
12121         if( status ) return status;
12122 #else
12123         /* Draft 4 pthreads */
12124         status = pthread_create( &t, pthread_attr_default, task, NULL );
12125         if( status ) return errno;
12126
12127         /* give thread a chance to complete */
12128         /* it should remain joinable and hence detachable */
12129         sleep( 1 );
12130
12131         status = pthread_detach( &t );
12132         if( status ) return errno;
12133 #endif
12134
12135 #ifdef HAVE_LINUX_THREADS
12136         pthread_kill_other_threads_np();
12137 #endif
12138
12139         return 0;
12140
12141   ;
12142   return 0;
12143 }
12144 _ACEOF
12145 if ac_fn_c_try_link "$LINENO"; then :
12146   ol_cv_pthread_lib_lpthread_woff=yes
12147 else
12148   ol_cv_pthread_lib_lpthread_woff=no
12149 fi
12150 rm -f core conftest.err conftest.$ac_objext \
12151     conftest$ac_exeext conftest.$ac_ext
12152 else
12153   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12154 /* end confdefs.h.  */
12155
12156
12157 /* pthread test headers */
12158 #include <pthread.h>
12159 #if HAVE_PTHREADS < 7
12160 #include <errno.h>
12161 #endif
12162 #ifndef NULL
12163 #define NULL (void*)0
12164 #endif
12165
12166 static void *task(p)
12167         void *p;
12168 {
12169         return (void *) (p == NULL);
12170 }
12171
12172
12173 int main(argc, argv)
12174         int argc;
12175         char **argv;
12176 {
12177
12178         /* pthread test function */
12179 #ifndef PTHREAD_CREATE_DETACHED
12180 #define PTHREAD_CREATE_DETACHED 1
12181 #endif
12182         pthread_t t;
12183         int status;
12184         int detach = PTHREAD_CREATE_DETACHED;
12185
12186 #if HAVE_PTHREADS > 4
12187         /* Final pthreads */
12188         pthread_attr_t attr;
12189
12190         status = pthread_attr_init(&attr);
12191         if( status ) return status;
12192
12193 #if HAVE_PTHREADS < 7
12194         status = pthread_attr_setdetachstate(&attr, &detach);
12195         if( status < 0 ) status = errno;
12196 #else
12197         status = pthread_attr_setdetachstate(&attr, detach);
12198 #endif
12199         if( status ) return status;
12200         status = pthread_create( &t, &attr, task, NULL );
12201 #if HAVE_PTHREADS < 7
12202         if( status < 0 ) status = errno;
12203 #endif
12204         if( status ) return status;
12205 #else
12206         /* Draft 4 pthreads */
12207         status = pthread_create( &t, pthread_attr_default, task, NULL );
12208         if( status ) return errno;
12209
12210         /* give thread a chance to complete */
12211         /* it should remain joinable and hence detachable */
12212         sleep( 1 );
12213
12214         status = pthread_detach( &t );
12215         if( status ) return errno;
12216 #endif
12217
12218 #ifdef HAVE_LINUX_THREADS
12219         pthread_kill_other_threads_np();
12220 #endif
12221
12222         return 0;
12223
12224 }
12225
12226 _ACEOF
12227 if ac_fn_c_try_run "$LINENO"; then :
12228   ol_cv_pthread_lib_lpthread_woff=yes
12229 else
12230   ol_cv_pthread_lib_lpthread_woff=no
12231 fi
12232 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12233   conftest.$ac_objext conftest.beam conftest.$ac_ext
12234 fi
12235
12236
12237                 # restore the LIBS
12238                 LIBS="$ol_LIBS"
12239
12240 fi
12241 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lib_lpthread_woff" >&5
12242 $as_echo "$ol_cv_pthread_lib_lpthread_woff" >&6; }
12243
12244         if test $ol_cv_pthread_lib_lpthread_woff = yes ; then
12245                 ol_link_pthreads="-lpthread -Wl,-woff,85"
12246                 ol_link_threads=posix
12247         fi
12248 fi
12249
12250
12251                 # Pthread try link: -lpthread (ol_cv_pthread_lpthread)
12252 if test "$ol_link_threads" = no ; then
12253         # try -lpthread
12254         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthread" >&5
12255 $as_echo_n "checking for pthread link with -lpthread... " >&6; }
12256 if ${ol_cv_pthread_lpthread+:} false; then :
12257   $as_echo_n "(cached) " >&6
12258 else
12259
12260                 # save the flags
12261                 ol_LIBS="$LIBS"
12262                 LIBS="-lpthread $LIBS"
12263
12264                 if test "$cross_compiling" = yes; then :
12265   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12266 /* end confdefs.h.  */
12267
12268 /* pthread test headers */
12269 #include <pthread.h>
12270 #if HAVE_PTHREADS < 7
12271 #include <errno.h>
12272 #endif
12273 #ifndef NULL
12274 #define NULL (void*)0
12275 #endif
12276
12277 static void *task(p)
12278         void *p;
12279 {
12280         return (void *) (p == NULL);
12281 }
12282
12283 int
12284 main ()
12285 {
12286
12287         /* pthread test function */
12288 #ifndef PTHREAD_CREATE_DETACHED
12289 #define PTHREAD_CREATE_DETACHED 1
12290 #endif
12291         pthread_t t;
12292         int status;
12293         int detach = PTHREAD_CREATE_DETACHED;
12294
12295 #if HAVE_PTHREADS > 4
12296         /* Final pthreads */
12297         pthread_attr_t attr;
12298
12299         status = pthread_attr_init(&attr);
12300         if( status ) return status;
12301
12302 #if HAVE_PTHREADS < 7
12303         status = pthread_attr_setdetachstate(&attr, &detach);
12304         if( status < 0 ) status = errno;
12305 #else
12306         status = pthread_attr_setdetachstate(&attr, detach);
12307 #endif
12308         if( status ) return status;
12309         status = pthread_create( &t, &attr, task, NULL );
12310 #if HAVE_PTHREADS < 7
12311         if( status < 0 ) status = errno;
12312 #endif
12313         if( status ) return status;
12314 #else
12315         /* Draft 4 pthreads */
12316         status = pthread_create( &t, pthread_attr_default, task, NULL );
12317         if( status ) return errno;
12318
12319         /* give thread a chance to complete */
12320         /* it should remain joinable and hence detachable */
12321         sleep( 1 );
12322
12323         status = pthread_detach( &t );
12324         if( status ) return errno;
12325 #endif
12326
12327 #ifdef HAVE_LINUX_THREADS
12328         pthread_kill_other_threads_np();
12329 #endif
12330
12331         return 0;
12332
12333   ;
12334   return 0;
12335 }
12336 _ACEOF
12337 if ac_fn_c_try_link "$LINENO"; then :
12338   ol_cv_pthread_lpthread=yes
12339 else
12340   ol_cv_pthread_lpthread=no
12341 fi
12342 rm -f core conftest.err conftest.$ac_objext \
12343     conftest$ac_exeext conftest.$ac_ext
12344 else
12345   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12346 /* end confdefs.h.  */
12347
12348
12349 /* pthread test headers */
12350 #include <pthread.h>
12351 #if HAVE_PTHREADS < 7
12352 #include <errno.h>
12353 #endif
12354 #ifndef NULL
12355 #define NULL (void*)0
12356 #endif
12357
12358 static void *task(p)
12359         void *p;
12360 {
12361         return (void *) (p == NULL);
12362 }
12363
12364
12365 int main(argc, argv)
12366         int argc;
12367         char **argv;
12368 {
12369
12370         /* pthread test function */
12371 #ifndef PTHREAD_CREATE_DETACHED
12372 #define PTHREAD_CREATE_DETACHED 1
12373 #endif
12374         pthread_t t;
12375         int status;
12376         int detach = PTHREAD_CREATE_DETACHED;
12377
12378 #if HAVE_PTHREADS > 4
12379         /* Final pthreads */
12380         pthread_attr_t attr;
12381
12382         status = pthread_attr_init(&attr);
12383         if( status ) return status;
12384
12385 #if HAVE_PTHREADS < 7
12386         status = pthread_attr_setdetachstate(&attr, &detach);
12387         if( status < 0 ) status = errno;
12388 #else
12389         status = pthread_attr_setdetachstate(&attr, detach);
12390 #endif
12391         if( status ) return status;
12392         status = pthread_create( &t, &attr, task, NULL );
12393 #if HAVE_PTHREADS < 7
12394         if( status < 0 ) status = errno;
12395 #endif
12396         if( status ) return status;
12397 #else
12398         /* Draft 4 pthreads */
12399         status = pthread_create( &t, pthread_attr_default, task, NULL );
12400         if( status ) return errno;
12401
12402         /* give thread a chance to complete */
12403         /* it should remain joinable and hence detachable */
12404         sleep( 1 );
12405
12406         status = pthread_detach( &t );
12407         if( status ) return errno;
12408 #endif
12409
12410 #ifdef HAVE_LINUX_THREADS
12411         pthread_kill_other_threads_np();
12412 #endif
12413
12414         return 0;
12415
12416 }
12417
12418 _ACEOF
12419 if ac_fn_c_try_run "$LINENO"; then :
12420   ol_cv_pthread_lpthread=yes
12421 else
12422   ol_cv_pthread_lpthread=no
12423 fi
12424 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12425   conftest.$ac_objext conftest.beam conftest.$ac_ext
12426 fi
12427
12428
12429                 # restore the LIBS
12430                 LIBS="$ol_LIBS"
12431
12432 fi
12433 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lpthread" >&5
12434 $as_echo "$ol_cv_pthread_lpthread" >&6; }
12435
12436         if test $ol_cv_pthread_lpthread = yes ; then
12437                 ol_link_pthreads="-lpthread"
12438                 ol_link_threads=posix
12439         fi
12440 fi
12441
12442                 # Pthread try link: -lc_r (ol_cv_pthread_lc_r)
12443 if test "$ol_link_threads" = no ; then
12444         # try -lc_r
12445         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lc_r" >&5
12446 $as_echo_n "checking for pthread link with -lc_r... " >&6; }
12447 if ${ol_cv_pthread_lc_r+:} false; then :
12448   $as_echo_n "(cached) " >&6
12449 else
12450
12451                 # save the flags
12452                 ol_LIBS="$LIBS"
12453                 LIBS="-lc_r $LIBS"
12454
12455                 if test "$cross_compiling" = yes; then :
12456   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12457 /* end confdefs.h.  */
12458
12459 /* pthread test headers */
12460 #include <pthread.h>
12461 #if HAVE_PTHREADS < 7
12462 #include <errno.h>
12463 #endif
12464 #ifndef NULL
12465 #define NULL (void*)0
12466 #endif
12467
12468 static void *task(p)
12469         void *p;
12470 {
12471         return (void *) (p == NULL);
12472 }
12473
12474 int
12475 main ()
12476 {
12477
12478         /* pthread test function */
12479 #ifndef PTHREAD_CREATE_DETACHED
12480 #define PTHREAD_CREATE_DETACHED 1
12481 #endif
12482         pthread_t t;
12483         int status;
12484         int detach = PTHREAD_CREATE_DETACHED;
12485
12486 #if HAVE_PTHREADS > 4
12487         /* Final pthreads */
12488         pthread_attr_t attr;
12489
12490         status = pthread_attr_init(&attr);
12491         if( status ) return status;
12492
12493 #if HAVE_PTHREADS < 7
12494         status = pthread_attr_setdetachstate(&attr, &detach);
12495         if( status < 0 ) status = errno;
12496 #else
12497         status = pthread_attr_setdetachstate(&attr, detach);
12498 #endif
12499         if( status ) return status;
12500         status = pthread_create( &t, &attr, task, NULL );
12501 #if HAVE_PTHREADS < 7
12502         if( status < 0 ) status = errno;
12503 #endif
12504         if( status ) return status;
12505 #else
12506         /* Draft 4 pthreads */
12507         status = pthread_create( &t, pthread_attr_default, task, NULL );
12508         if( status ) return errno;
12509
12510         /* give thread a chance to complete */
12511         /* it should remain joinable and hence detachable */
12512         sleep( 1 );
12513
12514         status = pthread_detach( &t );
12515         if( status ) return errno;
12516 #endif
12517
12518 #ifdef HAVE_LINUX_THREADS
12519         pthread_kill_other_threads_np();
12520 #endif
12521
12522         return 0;
12523
12524   ;
12525   return 0;
12526 }
12527 _ACEOF
12528 if ac_fn_c_try_link "$LINENO"; then :
12529   ol_cv_pthread_lc_r=yes
12530 else
12531   ol_cv_pthread_lc_r=no
12532 fi
12533 rm -f core conftest.err conftest.$ac_objext \
12534     conftest$ac_exeext conftest.$ac_ext
12535 else
12536   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12537 /* end confdefs.h.  */
12538
12539
12540 /* pthread test headers */
12541 #include <pthread.h>
12542 #if HAVE_PTHREADS < 7
12543 #include <errno.h>
12544 #endif
12545 #ifndef NULL
12546 #define NULL (void*)0
12547 #endif
12548
12549 static void *task(p)
12550         void *p;
12551 {
12552         return (void *) (p == NULL);
12553 }
12554
12555
12556 int main(argc, argv)
12557         int argc;
12558         char **argv;
12559 {
12560
12561         /* pthread test function */
12562 #ifndef PTHREAD_CREATE_DETACHED
12563 #define PTHREAD_CREATE_DETACHED 1
12564 #endif
12565         pthread_t t;
12566         int status;
12567         int detach = PTHREAD_CREATE_DETACHED;
12568
12569 #if HAVE_PTHREADS > 4
12570         /* Final pthreads */
12571         pthread_attr_t attr;
12572
12573         status = pthread_attr_init(&attr);
12574         if( status ) return status;
12575
12576 #if HAVE_PTHREADS < 7
12577         status = pthread_attr_setdetachstate(&attr, &detach);
12578         if( status < 0 ) status = errno;
12579 #else
12580         status = pthread_attr_setdetachstate(&attr, detach);
12581 #endif
12582         if( status ) return status;
12583         status = pthread_create( &t, &attr, task, NULL );
12584 #if HAVE_PTHREADS < 7
12585         if( status < 0 ) status = errno;
12586 #endif
12587         if( status ) return status;
12588 #else
12589         /* Draft 4 pthreads */
12590         status = pthread_create( &t, pthread_attr_default, task, NULL );
12591         if( status ) return errno;
12592
12593         /* give thread a chance to complete */
12594         /* it should remain joinable and hence detachable */
12595         sleep( 1 );
12596
12597         status = pthread_detach( &t );
12598         if( status ) return errno;
12599 #endif
12600
12601 #ifdef HAVE_LINUX_THREADS
12602         pthread_kill_other_threads_np();
12603 #endif
12604
12605         return 0;
12606
12607 }
12608
12609 _ACEOF
12610 if ac_fn_c_try_run "$LINENO"; then :
12611   ol_cv_pthread_lc_r=yes
12612 else
12613   ol_cv_pthread_lc_r=no
12614 fi
12615 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12616   conftest.$ac_objext conftest.beam conftest.$ac_ext
12617 fi
12618
12619
12620                 # restore the LIBS
12621                 LIBS="$ol_LIBS"
12622
12623 fi
12624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lc_r" >&5
12625 $as_echo "$ol_cv_pthread_lc_r" >&6; }
12626
12627         if test $ol_cv_pthread_lc_r = yes ; then
12628                 ol_link_pthreads="-lc_r"
12629                 ol_link_threads=posix
12630         fi
12631 fi
12632
12633
12634                 # Pthread try link: -threads (ol_cv_pthread_threads)
12635 if test "$ol_link_threads" = no ; then
12636         # try -threads
12637         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -threads" >&5
12638 $as_echo_n "checking for pthread link with -threads... " >&6; }
12639 if ${ol_cv_pthread_threads+:} false; then :
12640   $as_echo_n "(cached) " >&6
12641 else
12642
12643                 # save the flags
12644                 ol_LIBS="$LIBS"
12645                 LIBS="-threads $LIBS"
12646
12647                 if test "$cross_compiling" = yes; then :
12648   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12649 /* end confdefs.h.  */
12650
12651 /* pthread test headers */
12652 #include <pthread.h>
12653 #if HAVE_PTHREADS < 7
12654 #include <errno.h>
12655 #endif
12656 #ifndef NULL
12657 #define NULL (void*)0
12658 #endif
12659
12660 static void *task(p)
12661         void *p;
12662 {
12663         return (void *) (p == NULL);
12664 }
12665
12666 int
12667 main ()
12668 {
12669
12670         /* pthread test function */
12671 #ifndef PTHREAD_CREATE_DETACHED
12672 #define PTHREAD_CREATE_DETACHED 1
12673 #endif
12674         pthread_t t;
12675         int status;
12676         int detach = PTHREAD_CREATE_DETACHED;
12677
12678 #if HAVE_PTHREADS > 4
12679         /* Final pthreads */
12680         pthread_attr_t attr;
12681
12682         status = pthread_attr_init(&attr);
12683         if( status ) return status;
12684
12685 #if HAVE_PTHREADS < 7
12686         status = pthread_attr_setdetachstate(&attr, &detach);
12687         if( status < 0 ) status = errno;
12688 #else
12689         status = pthread_attr_setdetachstate(&attr, detach);
12690 #endif
12691         if( status ) return status;
12692         status = pthread_create( &t, &attr, task, NULL );
12693 #if HAVE_PTHREADS < 7
12694         if( status < 0 ) status = errno;
12695 #endif
12696         if( status ) return status;
12697 #else
12698         /* Draft 4 pthreads */
12699         status = pthread_create( &t, pthread_attr_default, task, NULL );
12700         if( status ) return errno;
12701
12702         /* give thread a chance to complete */
12703         /* it should remain joinable and hence detachable */
12704         sleep( 1 );
12705
12706         status = pthread_detach( &t );
12707         if( status ) return errno;
12708 #endif
12709
12710 #ifdef HAVE_LINUX_THREADS
12711         pthread_kill_other_threads_np();
12712 #endif
12713
12714         return 0;
12715
12716   ;
12717   return 0;
12718 }
12719 _ACEOF
12720 if ac_fn_c_try_link "$LINENO"; then :
12721   ol_cv_pthread_threads=yes
12722 else
12723   ol_cv_pthread_threads=no
12724 fi
12725 rm -f core conftest.err conftest.$ac_objext \
12726     conftest$ac_exeext conftest.$ac_ext
12727 else
12728   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12729 /* end confdefs.h.  */
12730
12731
12732 /* pthread test headers */
12733 #include <pthread.h>
12734 #if HAVE_PTHREADS < 7
12735 #include <errno.h>
12736 #endif
12737 #ifndef NULL
12738 #define NULL (void*)0
12739 #endif
12740
12741 static void *task(p)
12742         void *p;
12743 {
12744         return (void *) (p == NULL);
12745 }
12746
12747
12748 int main(argc, argv)
12749         int argc;
12750         char **argv;
12751 {
12752
12753         /* pthread test function */
12754 #ifndef PTHREAD_CREATE_DETACHED
12755 #define PTHREAD_CREATE_DETACHED 1
12756 #endif
12757         pthread_t t;
12758         int status;
12759         int detach = PTHREAD_CREATE_DETACHED;
12760
12761 #if HAVE_PTHREADS > 4
12762         /* Final pthreads */
12763         pthread_attr_t attr;
12764
12765         status = pthread_attr_init(&attr);
12766         if( status ) return status;
12767
12768 #if HAVE_PTHREADS < 7
12769         status = pthread_attr_setdetachstate(&attr, &detach);
12770         if( status < 0 ) status = errno;
12771 #else
12772         status = pthread_attr_setdetachstate(&attr, detach);
12773 #endif
12774         if( status ) return status;
12775         status = pthread_create( &t, &attr, task, NULL );
12776 #if HAVE_PTHREADS < 7
12777         if( status < 0 ) status = errno;
12778 #endif
12779         if( status ) return status;
12780 #else
12781         /* Draft 4 pthreads */
12782         status = pthread_create( &t, pthread_attr_default, task, NULL );
12783         if( status ) return errno;
12784
12785         /* give thread a chance to complete */
12786         /* it should remain joinable and hence detachable */
12787         sleep( 1 );
12788
12789         status = pthread_detach( &t );
12790         if( status ) return errno;
12791 #endif
12792
12793 #ifdef HAVE_LINUX_THREADS
12794         pthread_kill_other_threads_np();
12795 #endif
12796
12797         return 0;
12798
12799 }
12800
12801 _ACEOF
12802 if ac_fn_c_try_run "$LINENO"; then :
12803   ol_cv_pthread_threads=yes
12804 else
12805   ol_cv_pthread_threads=no
12806 fi
12807 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12808   conftest.$ac_objext conftest.beam conftest.$ac_ext
12809 fi
12810
12811
12812                 # restore the LIBS
12813                 LIBS="$ol_LIBS"
12814
12815 fi
12816 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_threads" >&5
12817 $as_echo "$ol_cv_pthread_threads" >&6; }
12818
12819         if test $ol_cv_pthread_threads = yes ; then
12820                 ol_link_pthreads="-threads"
12821                 ol_link_threads=posix
12822         fi
12823 fi
12824
12825
12826                 # Pthread try link: -lpthreads -lmach -lexc -lc_r (ol_cv_pthread_lpthreads_lmach_lexc_lc_r)
12827 if test "$ol_link_threads" = no ; then
12828         # try -lpthreads -lmach -lexc -lc_r
12829         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthreads -lmach -lexc -lc_r" >&5
12830 $as_echo_n "checking for pthread link with -lpthreads -lmach -lexc -lc_r... " >&6; }
12831 if ${ol_cv_pthread_lpthreads_lmach_lexc_lc_r+:} false; then :
12832   $as_echo_n "(cached) " >&6
12833 else
12834
12835                 # save the flags
12836                 ol_LIBS="$LIBS"
12837                 LIBS="-lpthreads -lmach -lexc -lc_r $LIBS"
12838
12839                 if test "$cross_compiling" = yes; then :
12840   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12841 /* end confdefs.h.  */
12842
12843 /* pthread test headers */
12844 #include <pthread.h>
12845 #if HAVE_PTHREADS < 7
12846 #include <errno.h>
12847 #endif
12848 #ifndef NULL
12849 #define NULL (void*)0
12850 #endif
12851
12852 static void *task(p)
12853         void *p;
12854 {
12855         return (void *) (p == NULL);
12856 }
12857
12858 int
12859 main ()
12860 {
12861
12862         /* pthread test function */
12863 #ifndef PTHREAD_CREATE_DETACHED
12864 #define PTHREAD_CREATE_DETACHED 1
12865 #endif
12866         pthread_t t;
12867         int status;
12868         int detach = PTHREAD_CREATE_DETACHED;
12869
12870 #if HAVE_PTHREADS > 4
12871         /* Final pthreads */
12872         pthread_attr_t attr;
12873
12874         status = pthread_attr_init(&attr);
12875         if( status ) return status;
12876
12877 #if HAVE_PTHREADS < 7
12878         status = pthread_attr_setdetachstate(&attr, &detach);
12879         if( status < 0 ) status = errno;
12880 #else
12881         status = pthread_attr_setdetachstate(&attr, detach);
12882 #endif
12883         if( status ) return status;
12884         status = pthread_create( &t, &attr, task, NULL );
12885 #if HAVE_PTHREADS < 7
12886         if( status < 0 ) status = errno;
12887 #endif
12888         if( status ) return status;
12889 #else
12890         /* Draft 4 pthreads */
12891         status = pthread_create( &t, pthread_attr_default, task, NULL );
12892         if( status ) return errno;
12893
12894         /* give thread a chance to complete */
12895         /* it should remain joinable and hence detachable */
12896         sleep( 1 );
12897
12898         status = pthread_detach( &t );
12899         if( status ) return errno;
12900 #endif
12901
12902 #ifdef HAVE_LINUX_THREADS
12903         pthread_kill_other_threads_np();
12904 #endif
12905
12906         return 0;
12907
12908   ;
12909   return 0;
12910 }
12911 _ACEOF
12912 if ac_fn_c_try_link "$LINENO"; then :
12913   ol_cv_pthread_lpthreads_lmach_lexc_lc_r=yes
12914 else
12915   ol_cv_pthread_lpthreads_lmach_lexc_lc_r=no
12916 fi
12917 rm -f core conftest.err conftest.$ac_objext \
12918     conftest$ac_exeext conftest.$ac_ext
12919 else
12920   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12921 /* end confdefs.h.  */
12922
12923
12924 /* pthread test headers */
12925 #include <pthread.h>
12926 #if HAVE_PTHREADS < 7
12927 #include <errno.h>
12928 #endif
12929 #ifndef NULL
12930 #define NULL (void*)0
12931 #endif
12932
12933 static void *task(p)
12934         void *p;
12935 {
12936         return (void *) (p == NULL);
12937 }
12938
12939
12940 int main(argc, argv)
12941         int argc;
12942         char **argv;
12943 {
12944
12945         /* pthread test function */
12946 #ifndef PTHREAD_CREATE_DETACHED
12947 #define PTHREAD_CREATE_DETACHED 1
12948 #endif
12949         pthread_t t;
12950         int status;
12951         int detach = PTHREAD_CREATE_DETACHED;
12952
12953 #if HAVE_PTHREADS > 4
12954         /* Final pthreads */
12955         pthread_attr_t attr;
12956
12957         status = pthread_attr_init(&attr);
12958         if( status ) return status;
12959
12960 #if HAVE_PTHREADS < 7
12961         status = pthread_attr_setdetachstate(&attr, &detach);
12962         if( status < 0 ) status = errno;
12963 #else
12964         status = pthread_attr_setdetachstate(&attr, detach);
12965 #endif
12966         if( status ) return status;
12967         status = pthread_create( &t, &attr, task, NULL );
12968 #if HAVE_PTHREADS < 7
12969         if( status < 0 ) status = errno;
12970 #endif
12971         if( status ) return status;
12972 #else
12973         /* Draft 4 pthreads */
12974         status = pthread_create( &t, pthread_attr_default, task, NULL );
12975         if( status ) return errno;
12976
12977         /* give thread a chance to complete */
12978         /* it should remain joinable and hence detachable */
12979         sleep( 1 );
12980
12981         status = pthread_detach( &t );
12982         if( status ) return errno;
12983 #endif
12984
12985 #ifdef HAVE_LINUX_THREADS
12986         pthread_kill_other_threads_np();
12987 #endif
12988
12989         return 0;
12990
12991 }
12992
12993 _ACEOF
12994 if ac_fn_c_try_run "$LINENO"; then :
12995   ol_cv_pthread_lpthreads_lmach_lexc_lc_r=yes
12996 else
12997   ol_cv_pthread_lpthreads_lmach_lexc_lc_r=no
12998 fi
12999 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13000   conftest.$ac_objext conftest.beam conftest.$ac_ext
13001 fi
13002
13003
13004                 # restore the LIBS
13005                 LIBS="$ol_LIBS"
13006
13007 fi
13008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lpthreads_lmach_lexc_lc_r" >&5
13009 $as_echo "$ol_cv_pthread_lpthreads_lmach_lexc_lc_r" >&6; }
13010
13011         if test $ol_cv_pthread_lpthreads_lmach_lexc_lc_r = yes ; then
13012                 ol_link_pthreads="-lpthreads -lmach -lexc -lc_r"
13013                 ol_link_threads=posix
13014         fi
13015 fi
13016
13017                 # Pthread try link: -lpthreads -lmach -lexc (ol_cv_pthread_lpthreads_lmach_lexc)
13018 if test "$ol_link_threads" = no ; then
13019         # try -lpthreads -lmach -lexc
13020         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthreads -lmach -lexc" >&5
13021 $as_echo_n "checking for pthread link with -lpthreads -lmach -lexc... " >&6; }
13022 if ${ol_cv_pthread_lpthreads_lmach_lexc+:} false; then :
13023   $as_echo_n "(cached) " >&6
13024 else
13025
13026                 # save the flags
13027                 ol_LIBS="$LIBS"
13028                 LIBS="-lpthreads -lmach -lexc $LIBS"
13029
13030                 if test "$cross_compiling" = yes; then :
13031   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13032 /* end confdefs.h.  */
13033
13034 /* pthread test headers */
13035 #include <pthread.h>
13036 #if HAVE_PTHREADS < 7
13037 #include <errno.h>
13038 #endif
13039 #ifndef NULL
13040 #define NULL (void*)0
13041 #endif
13042
13043 static void *task(p)
13044         void *p;
13045 {
13046         return (void *) (p == NULL);
13047 }
13048
13049 int
13050 main ()
13051 {
13052
13053         /* pthread test function */
13054 #ifndef PTHREAD_CREATE_DETACHED
13055 #define PTHREAD_CREATE_DETACHED 1
13056 #endif
13057         pthread_t t;
13058         int status;
13059         int detach = PTHREAD_CREATE_DETACHED;
13060
13061 #if HAVE_PTHREADS > 4
13062         /* Final pthreads */
13063         pthread_attr_t attr;
13064
13065         status = pthread_attr_init(&attr);
13066         if( status ) return status;
13067
13068 #if HAVE_PTHREADS < 7
13069         status = pthread_attr_setdetachstate(&attr, &detach);
13070         if( status < 0 ) status = errno;
13071 #else
13072         status = pthread_attr_setdetachstate(&attr, detach);
13073 #endif
13074         if( status ) return status;
13075         status = pthread_create( &t, &attr, task, NULL );
13076 #if HAVE_PTHREADS < 7
13077         if( status < 0 ) status = errno;
13078 #endif
13079         if( status ) return status;
13080 #else
13081         /* Draft 4 pthreads */
13082         status = pthread_create( &t, pthread_attr_default, task, NULL );
13083         if( status ) return errno;
13084
13085         /* give thread a chance to complete */
13086         /* it should remain joinable and hence detachable */
13087         sleep( 1 );
13088
13089         status = pthread_detach( &t );
13090         if( status ) return errno;
13091 #endif
13092
13093 #ifdef HAVE_LINUX_THREADS
13094         pthread_kill_other_threads_np();
13095 #endif
13096
13097         return 0;
13098
13099   ;
13100   return 0;
13101 }
13102 _ACEOF
13103 if ac_fn_c_try_link "$LINENO"; then :
13104   ol_cv_pthread_lpthreads_lmach_lexc=yes
13105 else
13106   ol_cv_pthread_lpthreads_lmach_lexc=no
13107 fi
13108 rm -f core conftest.err conftest.$ac_objext \
13109     conftest$ac_exeext conftest.$ac_ext
13110 else
13111   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13112 /* end confdefs.h.  */
13113
13114
13115 /* pthread test headers */
13116 #include <pthread.h>
13117 #if HAVE_PTHREADS < 7
13118 #include <errno.h>
13119 #endif
13120 #ifndef NULL
13121 #define NULL (void*)0
13122 #endif
13123
13124 static void *task(p)
13125         void *p;
13126 {
13127         return (void *) (p == NULL);
13128 }
13129
13130
13131 int main(argc, argv)
13132         int argc;
13133         char **argv;
13134 {
13135
13136         /* pthread test function */
13137 #ifndef PTHREAD_CREATE_DETACHED
13138 #define PTHREAD_CREATE_DETACHED 1
13139 #endif
13140         pthread_t t;
13141         int status;
13142         int detach = PTHREAD_CREATE_DETACHED;
13143
13144 #if HAVE_PTHREADS > 4
13145         /* Final pthreads */
13146         pthread_attr_t attr;
13147
13148         status = pthread_attr_init(&attr);
13149         if( status ) return status;
13150
13151 #if HAVE_PTHREADS < 7
13152         status = pthread_attr_setdetachstate(&attr, &detach);
13153         if( status < 0 ) status = errno;
13154 #else
13155         status = pthread_attr_setdetachstate(&attr, detach);
13156 #endif
13157         if( status ) return status;
13158         status = pthread_create( &t, &attr, task, NULL );
13159 #if HAVE_PTHREADS < 7
13160         if( status < 0 ) status = errno;
13161 #endif
13162         if( status ) return status;
13163 #else
13164         /* Draft 4 pthreads */
13165         status = pthread_create( &t, pthread_attr_default, task, NULL );
13166         if( status ) return errno;
13167
13168         /* give thread a chance to complete */
13169         /* it should remain joinable and hence detachable */
13170         sleep( 1 );
13171
13172         status = pthread_detach( &t );
13173         if( status ) return errno;
13174 #endif
13175
13176 #ifdef HAVE_LINUX_THREADS
13177         pthread_kill_other_threads_np();
13178 #endif
13179
13180         return 0;
13181
13182 }
13183
13184 _ACEOF
13185 if ac_fn_c_try_run "$LINENO"; then :
13186   ol_cv_pthread_lpthreads_lmach_lexc=yes
13187 else
13188   ol_cv_pthread_lpthreads_lmach_lexc=no
13189 fi
13190 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13191   conftest.$ac_objext conftest.beam conftest.$ac_ext
13192 fi
13193
13194
13195                 # restore the LIBS
13196                 LIBS="$ol_LIBS"
13197
13198 fi
13199 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lpthreads_lmach_lexc" >&5
13200 $as_echo "$ol_cv_pthread_lpthreads_lmach_lexc" >&6; }
13201
13202         if test $ol_cv_pthread_lpthreads_lmach_lexc = yes ; then
13203                 ol_link_pthreads="-lpthreads -lmach -lexc"
13204                 ol_link_threads=posix
13205         fi
13206 fi
13207
13208                 # Pthread try link: -lpthreads -lexc (ol_cv_pthread_lpthreads_lexc)
13209 if test "$ol_link_threads" = no ; then
13210         # try -lpthreads -lexc
13211         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthreads -lexc" >&5
13212 $as_echo_n "checking for pthread link with -lpthreads -lexc... " >&6; }
13213 if ${ol_cv_pthread_lpthreads_lexc+:} false; then :
13214   $as_echo_n "(cached) " >&6
13215 else
13216
13217                 # save the flags
13218                 ol_LIBS="$LIBS"
13219                 LIBS="-lpthreads -lexc $LIBS"
13220
13221                 if test "$cross_compiling" = yes; then :
13222   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13223 /* end confdefs.h.  */
13224
13225 /* pthread test headers */
13226 #include <pthread.h>
13227 #if HAVE_PTHREADS < 7
13228 #include <errno.h>
13229 #endif
13230 #ifndef NULL
13231 #define NULL (void*)0
13232 #endif
13233
13234 static void *task(p)
13235         void *p;
13236 {
13237         return (void *) (p == NULL);
13238 }
13239
13240 int
13241 main ()
13242 {
13243
13244         /* pthread test function */
13245 #ifndef PTHREAD_CREATE_DETACHED
13246 #define PTHREAD_CREATE_DETACHED 1
13247 #endif
13248         pthread_t t;
13249         int status;
13250         int detach = PTHREAD_CREATE_DETACHED;
13251
13252 #if HAVE_PTHREADS > 4
13253         /* Final pthreads */
13254         pthread_attr_t attr;
13255
13256         status = pthread_attr_init(&attr);
13257         if( status ) return status;
13258
13259 #if HAVE_PTHREADS < 7
13260         status = pthread_attr_setdetachstate(&attr, &detach);
13261         if( status < 0 ) status = errno;
13262 #else
13263         status = pthread_attr_setdetachstate(&attr, detach);
13264 #endif
13265         if( status ) return status;
13266         status = pthread_create( &t, &attr, task, NULL );
13267 #if HAVE_PTHREADS < 7
13268         if( status < 0 ) status = errno;
13269 #endif
13270         if( status ) return status;
13271 #else
13272         /* Draft 4 pthreads */
13273         status = pthread_create( &t, pthread_attr_default, task, NULL );
13274         if( status ) return errno;
13275
13276         /* give thread a chance to complete */
13277         /* it should remain joinable and hence detachable */
13278         sleep( 1 );
13279
13280         status = pthread_detach( &t );
13281         if( status ) return errno;
13282 #endif
13283
13284 #ifdef HAVE_LINUX_THREADS
13285         pthread_kill_other_threads_np();
13286 #endif
13287
13288         return 0;
13289
13290   ;
13291   return 0;
13292 }
13293 _ACEOF
13294 if ac_fn_c_try_link "$LINENO"; then :
13295   ol_cv_pthread_lpthreads_lexc=yes
13296 else
13297   ol_cv_pthread_lpthreads_lexc=no
13298 fi
13299 rm -f core conftest.err conftest.$ac_objext \
13300     conftest$ac_exeext conftest.$ac_ext
13301 else
13302   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13303 /* end confdefs.h.  */
13304
13305
13306 /* pthread test headers */
13307 #include <pthread.h>
13308 #if HAVE_PTHREADS < 7
13309 #include <errno.h>
13310 #endif
13311 #ifndef NULL
13312 #define NULL (void*)0
13313 #endif
13314
13315 static void *task(p)
13316         void *p;
13317 {
13318         return (void *) (p == NULL);
13319 }
13320
13321
13322 int main(argc, argv)
13323         int argc;
13324         char **argv;
13325 {
13326
13327         /* pthread test function */
13328 #ifndef PTHREAD_CREATE_DETACHED
13329 #define PTHREAD_CREATE_DETACHED 1
13330 #endif
13331         pthread_t t;
13332         int status;
13333         int detach = PTHREAD_CREATE_DETACHED;
13334
13335 #if HAVE_PTHREADS > 4
13336         /* Final pthreads */
13337         pthread_attr_t attr;
13338
13339         status = pthread_attr_init(&attr);
13340         if( status ) return status;
13341
13342 #if HAVE_PTHREADS < 7
13343         status = pthread_attr_setdetachstate(&attr, &detach);
13344         if( status < 0 ) status = errno;
13345 #else
13346         status = pthread_attr_setdetachstate(&attr, detach);
13347 #endif
13348         if( status ) return status;
13349         status = pthread_create( &t, &attr, task, NULL );
13350 #if HAVE_PTHREADS < 7
13351         if( status < 0 ) status = errno;
13352 #endif
13353         if( status ) return status;
13354 #else
13355         /* Draft 4 pthreads */
13356         status = pthread_create( &t, pthread_attr_default, task, NULL );
13357         if( status ) return errno;
13358
13359         /* give thread a chance to complete */
13360         /* it should remain joinable and hence detachable */
13361         sleep( 1 );
13362
13363         status = pthread_detach( &t );
13364         if( status ) return errno;
13365 #endif
13366
13367 #ifdef HAVE_LINUX_THREADS
13368         pthread_kill_other_threads_np();
13369 #endif
13370
13371         return 0;
13372
13373 }
13374
13375 _ACEOF
13376 if ac_fn_c_try_run "$LINENO"; then :
13377   ol_cv_pthread_lpthreads_lexc=yes
13378 else
13379   ol_cv_pthread_lpthreads_lexc=no
13380 fi
13381 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13382   conftest.$ac_objext conftest.beam conftest.$ac_ext
13383 fi
13384
13385
13386                 # restore the LIBS
13387                 LIBS="$ol_LIBS"
13388
13389 fi
13390 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lpthreads_lexc" >&5
13391 $as_echo "$ol_cv_pthread_lpthreads_lexc" >&6; }
13392
13393         if test $ol_cv_pthread_lpthreads_lexc = yes ; then
13394                 ol_link_pthreads="-lpthreads -lexc"
13395                 ol_link_threads=posix
13396         fi
13397 fi
13398
13399
13400                 # Pthread try link: -lpthreads (ol_cv_pthread_lib_lpthreads)
13401 if test "$ol_link_threads" = no ; then
13402         # try -lpthreads
13403         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread link with -lpthreads" >&5
13404 $as_echo_n "checking for pthread link with -lpthreads... " >&6; }
13405 if ${ol_cv_pthread_lib_lpthreads+:} false; then :
13406   $as_echo_n "(cached) " >&6
13407 else
13408
13409                 # save the flags
13410                 ol_LIBS="$LIBS"
13411                 LIBS="-lpthreads $LIBS"
13412
13413                 if test "$cross_compiling" = yes; then :
13414   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13415 /* end confdefs.h.  */
13416
13417 /* pthread test headers */
13418 #include <pthread.h>
13419 #if HAVE_PTHREADS < 7
13420 #include <errno.h>
13421 #endif
13422 #ifndef NULL
13423 #define NULL (void*)0
13424 #endif
13425
13426 static void *task(p)
13427         void *p;
13428 {
13429         return (void *) (p == NULL);
13430 }
13431
13432 int
13433 main ()
13434 {
13435
13436         /* pthread test function */
13437 #ifndef PTHREAD_CREATE_DETACHED
13438 #define PTHREAD_CREATE_DETACHED 1
13439 #endif
13440         pthread_t t;
13441         int status;
13442         int detach = PTHREAD_CREATE_DETACHED;
13443
13444 #if HAVE_PTHREADS > 4
13445         /* Final pthreads */
13446         pthread_attr_t attr;
13447
13448         status = pthread_attr_init(&attr);
13449         if( status ) return status;
13450
13451 #if HAVE_PTHREADS < 7
13452         status = pthread_attr_setdetachstate(&attr, &detach);
13453         if( status < 0 ) status = errno;
13454 #else
13455         status = pthread_attr_setdetachstate(&attr, detach);
13456 #endif
13457         if( status ) return status;
13458         status = pthread_create( &t, &attr, task, NULL );
13459 #if HAVE_PTHREADS < 7
13460         if( status < 0 ) status = errno;
13461 #endif
13462         if( status ) return status;
13463 #else
13464         /* Draft 4 pthreads */
13465         status = pthread_create( &t, pthread_attr_default, task, NULL );
13466         if( status ) return errno;
13467
13468         /* give thread a chance to complete */
13469         /* it should remain joinable and hence detachable */
13470         sleep( 1 );
13471
13472         status = pthread_detach( &t );
13473         if( status ) return errno;
13474 #endif
13475
13476 #ifdef HAVE_LINUX_THREADS
13477         pthread_kill_other_threads_np();
13478 #endif
13479
13480         return 0;
13481
13482   ;
13483   return 0;
13484 }
13485 _ACEOF
13486 if ac_fn_c_try_link "$LINENO"; then :
13487   ol_cv_pthread_lib_lpthreads=yes
13488 else
13489   ol_cv_pthread_lib_lpthreads=no
13490 fi
13491 rm -f core conftest.err conftest.$ac_objext \
13492     conftest$ac_exeext conftest.$ac_ext
13493 else
13494   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13495 /* end confdefs.h.  */
13496
13497
13498 /* pthread test headers */
13499 #include <pthread.h>
13500 #if HAVE_PTHREADS < 7
13501 #include <errno.h>
13502 #endif
13503 #ifndef NULL
13504 #define NULL (void*)0
13505 #endif
13506
13507 static void *task(p)
13508         void *p;
13509 {
13510         return (void *) (p == NULL);
13511 }
13512
13513
13514 int main(argc, argv)
13515         int argc;
13516         char **argv;
13517 {
13518
13519         /* pthread test function */
13520 #ifndef PTHREAD_CREATE_DETACHED
13521 #define PTHREAD_CREATE_DETACHED 1
13522 #endif
13523         pthread_t t;
13524         int status;
13525         int detach = PTHREAD_CREATE_DETACHED;
13526
13527 #if HAVE_PTHREADS > 4
13528         /* Final pthreads */
13529         pthread_attr_t attr;
13530
13531         status = pthread_attr_init(&attr);
13532         if( status ) return status;
13533
13534 #if HAVE_PTHREADS < 7
13535         status = pthread_attr_setdetachstate(&attr, &detach);
13536         if( status < 0 ) status = errno;
13537 #else
13538         status = pthread_attr_setdetachstate(&attr, detach);
13539 #endif
13540         if( status ) return status;
13541         status = pthread_create( &t, &attr, task, NULL );
13542 #if HAVE_PTHREADS < 7
13543         if( status < 0 ) status = errno;
13544 #endif
13545         if( status ) return status;
13546 #else
13547         /* Draft 4 pthreads */
13548         status = pthread_create( &t, pthread_attr_default, task, NULL );
13549         if( status ) return errno;
13550
13551         /* give thread a chance to complete */
13552         /* it should remain joinable and hence detachable */
13553         sleep( 1 );
13554
13555         status = pthread_detach( &t );
13556         if( status ) return errno;
13557 #endif
13558
13559 #ifdef HAVE_LINUX_THREADS
13560         pthread_kill_other_threads_np();
13561 #endif
13562
13563         return 0;
13564
13565 }
13566
13567 _ACEOF
13568 if ac_fn_c_try_run "$LINENO"; then :
13569   ol_cv_pthread_lib_lpthreads=yes
13570 else
13571   ol_cv_pthread_lib_lpthreads=no
13572 fi
13573 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13574   conftest.$ac_objext conftest.beam conftest.$ac_ext
13575 fi
13576
13577
13578                 # restore the LIBS
13579                 LIBS="$ol_LIBS"
13580
13581 fi
13582 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_lib_lpthreads" >&5
13583 $as_echo "$ol_cv_pthread_lib_lpthreads" >&6; }
13584
13585         if test $ol_cv_pthread_lib_lpthreads = yes ; then
13586                 ol_link_pthreads="-lpthreads"
13587                 ol_link_threads=posix
13588         fi
13589 fi
13590
13591
13592                 if test $ol_link_threads != no ; then
13593                         LTHREAD_LIBS="$LTHREAD_LIBS $ol_link_pthreads"
13594
13595                                                 save_CPPFLAGS="$CPPFLAGS"
13596                         save_LIBS="$LIBS"
13597                         LIBS="$LTHREAD_LIBS $LIBS"
13598
13599                                                                                                 for ac_func in sched_yield pthread_yield thr_yield
13600 do :
13601   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13602 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13603 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
13604   cat >>confdefs.h <<_ACEOF
13605 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13606 _ACEOF
13607
13608 fi
13609 done
13610
13611
13612                         if test $ac_cv_func_sched_yield = no &&
13613                            test $ac_cv_func_pthread_yield = no &&
13614                            test $ac_cv_func_thr_yield = no ; then
13615                                                                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sched_yield in -lrt" >&5
13616 $as_echo_n "checking for sched_yield in -lrt... " >&6; }
13617 if ${ac_cv_lib_rt_sched_yield+:} false; then :
13618   $as_echo_n "(cached) " >&6
13619 else
13620   ac_check_lib_save_LIBS=$LIBS
13621 LIBS="-lrt  $LIBS"
13622 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13623 /* end confdefs.h.  */
13624
13625 /* Override any GCC internal prototype to avoid an error.
13626    Use char because int might match the return type of a GCC
13627    builtin and then its argument prototype would still apply.  */
13628 #ifdef __cplusplus
13629 extern "C"
13630 #endif
13631 char sched_yield ();
13632 int
13633 main ()
13634 {
13635 return sched_yield ();
13636   ;
13637   return 0;
13638 }
13639 _ACEOF
13640 if ac_fn_c_try_link "$LINENO"; then :
13641   ac_cv_lib_rt_sched_yield=yes
13642 else
13643   ac_cv_lib_rt_sched_yield=no
13644 fi
13645 rm -f core conftest.err conftest.$ac_objext \
13646     conftest$ac_exeext conftest.$ac_ext
13647 LIBS=$ac_check_lib_save_LIBS
13648 fi
13649 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rt_sched_yield" >&5
13650 $as_echo "$ac_cv_lib_rt_sched_yield" >&6; }
13651 if test "x$ac_cv_lib_rt_sched_yield" = xyes; then :
13652   LTHREAD_LIBS="$LTHREAD_LIBS -lrt"
13653
13654 $as_echo "#define HAVE_SCHED_YIELD 1" >>confdefs.h
13655
13656                                         ac_cv_func_sched_yield=yes
13657 else
13658   ac_cv_func_sched_yield=no
13659 fi
13660
13661                         fi
13662                         if test $ac_cv_func_sched_yield = no &&
13663                            test $ac_cv_func_pthread_yield = no &&
13664                            test "$ac_cv_func_thr_yield" = no ; then
13665                                 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: could not locate sched_yield() or pthread_yield()" >&5
13666 $as_echo "$as_me: WARNING: could not locate sched_yield() or pthread_yield()" >&2;}
13667                         fi
13668
13669                                                 for ac_func in pthread_kill
13670 do :
13671   ac_fn_c_check_func "$LINENO" "pthread_kill" "ac_cv_func_pthread_kill"
13672 if test "x$ac_cv_func_pthread_kill" = xyes; then :
13673   cat >>confdefs.h <<_ACEOF
13674 #define HAVE_PTHREAD_KILL 1
13675 _ACEOF
13676
13677 fi
13678 done
13679
13680
13681                                                                         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_rwlock_destroy with <pthread.h>" >&5
13682 $as_echo_n "checking for pthread_rwlock_destroy with <pthread.h>... " >&6; }
13683 if ${ol_cv_func_pthread_rwlock_destroy+:} false; then :
13684   $as_echo_n "(cached) " >&6
13685 else
13686
13687                                                                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13688 /* end confdefs.h.  */
13689
13690 #include <pthread.h>
13691 pthread_rwlock_t rwlock;
13692
13693 int
13694 main ()
13695 {
13696 pthread_rwlock_destroy(&rwlock);
13697   ;
13698   return 0;
13699 }
13700 _ACEOF
13701 if ac_fn_c_try_link "$LINENO"; then :
13702   ol_cv_func_pthread_rwlock_destroy=yes
13703 else
13704   ol_cv_func_pthread_rwlock_destroy=no
13705 fi
13706 rm -f core conftest.err conftest.$ac_objext \
13707     conftest$ac_exeext conftest.$ac_ext
13708
13709 fi
13710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_func_pthread_rwlock_destroy" >&5
13711 $as_echo "$ol_cv_func_pthread_rwlock_destroy" >&6; }
13712                         if test $ol_cv_func_pthread_rwlock_destroy = yes ; then
13713
13714 $as_echo "#define HAVE_PTHREAD_RWLOCK_DESTROY 1" >>confdefs.h
13715
13716                         fi
13717
13718                                                                         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_detach with <pthread.h>" >&5
13719 $as_echo_n "checking for pthread_detach with <pthread.h>... " >&6; }
13720 if ${ol_cv_func_pthread_detach+:} false; then :
13721   $as_echo_n "(cached) " >&6
13722 else
13723
13724                                                                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13725 /* end confdefs.h.  */
13726
13727 #include <pthread.h>
13728 #ifndef NULL
13729 #define NULL (void*)0
13730 #endif
13731
13732 int
13733 main ()
13734 {
13735 pthread_detach(NULL);
13736   ;
13737   return 0;
13738 }
13739 _ACEOF
13740 if ac_fn_c_try_link "$LINENO"; then :
13741   ol_cv_func_pthread_detach=yes
13742 else
13743   ol_cv_func_pthread_detach=no
13744 fi
13745 rm -f core conftest.err conftest.$ac_objext \
13746     conftest$ac_exeext conftest.$ac_ext
13747
13748 fi
13749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_func_pthread_detach" >&5
13750 $as_echo "$ol_cv_func_pthread_detach" >&6; }
13751
13752                         if test $ol_cv_func_pthread_detach = no ; then
13753                                 as_fn_error $? "could not locate pthread_detach()" "$LINENO" 5
13754                         fi
13755
13756
13757 $as_echo "#define HAVE_PTHREAD_DETACH 1" >>confdefs.h
13758
13759
13760                                                 for ac_func in \
13761                                 pthread_setconcurrency \
13762                                 pthread_getconcurrency \
13763                                 thr_setconcurrency \
13764                                 thr_getconcurrency \
13765
13766 do :
13767   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13768 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13769 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
13770   cat >>confdefs.h <<_ACEOF
13771 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13772 _ACEOF
13773
13774 fi
13775 done
13776
13777
13778
13779         for ac_func in pthread_kill_other_threads_np
13780 do :
13781   ac_fn_c_check_func "$LINENO" "pthread_kill_other_threads_np" "ac_cv_func_pthread_kill_other_threads_np"
13782 if test "x$ac_cv_func_pthread_kill_other_threads_np" = xyes; then :
13783   cat >>confdefs.h <<_ACEOF
13784 #define HAVE_PTHREAD_KILL_OTHER_THREADS_NP 1
13785 _ACEOF
13786
13787 fi
13788 done
13789
13790         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LinuxThreads implementation" >&5
13791 $as_echo_n "checking for LinuxThreads implementation... " >&6; }
13792 if ${ol_cv_sys_linux_threads+:} false; then :
13793   $as_echo_n "(cached) " >&6
13794 else
13795   ol_cv_sys_linux_threads=$ac_cv_func_pthread_kill_other_threads_np
13796 fi
13797 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_sys_linux_threads" >&5
13798 $as_echo "$ol_cv_sys_linux_threads" >&6; }
13799
13800
13801
13802
13803         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LinuxThreads consistency" >&5
13804 $as_echo_n "checking for LinuxThreads consistency... " >&6; }
13805 if ${ol_cv_linux_threads+:} false; then :
13806   $as_echo_n "(cached) " >&6
13807 else
13808
13809                 if test $ol_cv_header_linux_threads = yes &&
13810                    test $ol_cv_sys_linux_threads = yes; then
13811                         ol_cv_linux_threads=yes
13812                 elif test $ol_cv_header_linux_threads = no &&
13813                      test $ol_cv_sys_linux_threads = no; then
13814                         ol_cv_linux_threads=no
13815                 else
13816                         ol_cv_linux_threads=error
13817                 fi
13818
13819 fi
13820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_linux_threads" >&5
13821 $as_echo "$ol_cv_linux_threads" >&6; }
13822
13823
13824                         if test $ol_cv_linux_threads = error; then
13825                                 as_fn_error $? "LinuxThreads header/library mismatch" "$LINENO" 5;
13826                         fi
13827
13828                         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if pthread_create() works" >&5
13829 $as_echo_n "checking if pthread_create() works... " >&6; }
13830 if ${ol_cv_pthread_create_works+:} false; then :
13831   $as_echo_n "(cached) " >&6
13832 else
13833
13834                         if test "$cross_compiling" = yes; then :
13835                                 ol_cv_pthread_create_works=yes
13836 else
13837   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13838 /* end confdefs.h.  */
13839
13840
13841 /* pthread test headers */
13842 #include <pthread.h>
13843 #if HAVE_PTHREADS < 7
13844 #include <errno.h>
13845 #endif
13846 #ifndef NULL
13847 #define NULL (void*)0
13848 #endif
13849
13850 static void *task(p)
13851         void *p;
13852 {
13853         return (void *) (p == NULL);
13854 }
13855
13856
13857 int main(argc, argv)
13858         int argc;
13859         char **argv;
13860 {
13861
13862         /* pthread test function */
13863 #ifndef PTHREAD_CREATE_DETACHED
13864 #define PTHREAD_CREATE_DETACHED 1
13865 #endif
13866         pthread_t t;
13867         int status;
13868         int detach = PTHREAD_CREATE_DETACHED;
13869
13870 #if HAVE_PTHREADS > 4
13871         /* Final pthreads */
13872         pthread_attr_t attr;
13873
13874         status = pthread_attr_init(&attr);
13875         if( status ) return status;
13876
13877 #if HAVE_PTHREADS < 7
13878         status = pthread_attr_setdetachstate(&attr, &detach);
13879         if( status < 0 ) status = errno;
13880 #else
13881         status = pthread_attr_setdetachstate(&attr, detach);
13882 #endif
13883         if( status ) return status;
13884         status = pthread_create( &t, &attr, task, NULL );
13885 #if HAVE_PTHREADS < 7
13886         if( status < 0 ) status = errno;
13887 #endif
13888         if( status ) return status;
13889 #else
13890         /* Draft 4 pthreads */
13891         status = pthread_create( &t, pthread_attr_default, task, NULL );
13892         if( status ) return errno;
13893
13894         /* give thread a chance to complete */
13895         /* it should remain joinable and hence detachable */
13896         sleep( 1 );
13897
13898         status = pthread_detach( &t );
13899         if( status ) return errno;
13900 #endif
13901
13902 #ifdef HAVE_LINUX_THREADS
13903         pthread_kill_other_threads_np();
13904 #endif
13905
13906         return 0;
13907
13908 }
13909
13910 _ACEOF
13911 if ac_fn_c_try_run "$LINENO"; then :
13912   ol_cv_pthread_create_works=yes
13913 else
13914   ol_cv_pthread_create_works=no
13915 fi
13916 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13917   conftest.$ac_objext conftest.beam conftest.$ac_ext
13918 fi
13919
13920 fi
13921 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_create_works" >&5
13922 $as_echo "$ol_cv_pthread_create_works" >&6; }
13923
13924                         if test $ol_cv_pthread_create_works = no ; then
13925                                 as_fn_error $? "pthread_create is not usable, check environment settings" "$LINENO" 5
13926                         fi
13927
13928                         ol_replace_broken_yield=no
13929
13930                         if test $ol_replace_broken_yield = yes ; then
13931
13932 $as_echo "#define REPLACE_BROKEN_YIELD 1" >>confdefs.h
13933
13934                         fi
13935
13936                                                 if test x$ol_with_yielding_select = xauto ; then
13937                                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if select yields when using pthreads" >&5
13938 $as_echo_n "checking if select yields when using pthreads... " >&6; }
13939 if ${ol_cv_pthread_select_yields+:} false; then :
13940   $as_echo_n "(cached) " >&6
13941 else
13942
13943                                 if test "$cross_compiling" = yes; then :
13944   ol_cv_pthread_select_yields=cross
13945 else
13946   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13947 /* end confdefs.h.  */
13948
13949 #include <sys/types.h>
13950 #include <sys/time.h>
13951 #include <unistd.h>
13952 #include <pthread.h>
13953 #ifndef NULL
13954 #define NULL (void*) 0
13955 #endif
13956
13957 static int fildes[2];
13958
13959 static void *task(p)
13960         void *p;
13961 {
13962         int i;
13963         struct timeval tv;
13964
13965         fd_set rfds;
13966
13967         tv.tv_sec=10;
13968         tv.tv_usec=0;
13969
13970         FD_ZERO(&rfds);
13971         FD_SET(fildes[0], &rfds);
13972
13973         /* we're not interested in any fds */
13974         i = select(FD_SETSIZE, &rfds, NULL, NULL, &tv);
13975
13976         if(i < 0) {
13977                 perror("select");
13978                 exit(10);
13979         }
13980
13981         exit(0); /* if we exit here, the select blocked the whole process */
13982 }
13983
13984 int main(argc, argv)
13985         int argc;
13986         char **argv;
13987 {
13988         pthread_t t;
13989
13990         /* create a pipe to select */
13991         if(pipe(&fildes[0])) {
13992                 perror("select");
13993                 exit(1);
13994         }
13995
13996 #ifdef HAVE_PTHREAD_SETCONCURRENCY
13997         (void) pthread_setconcurrency(2);
13998 #else
13999 #ifdef HAVE_THR_SETCONCURRENCY
14000         /* Set Solaris LWP concurrency to 2 */
14001         thr_setconcurrency(2);
14002 #endif
14003 #endif
14004
14005 #if HAVE_PTHREADS < 6
14006         pthread_create(&t, pthread_attr_default, task, NULL);
14007 #else
14008         pthread_create(&t, NULL, task, NULL);
14009 #endif
14010
14011         /* make sure task runs first */
14012 #ifdef HAVE_THR_YIELD
14013         thr_yield();
14014 #elif defined( HAVE_SCHED_YIELD )
14015         sched_yield();
14016 #elif defined( HAVE_PTHREAD_YIELD )
14017         pthread_yield();
14018 #endif
14019
14020         exit(2);
14021 }
14022 _ACEOF
14023 if ac_fn_c_try_run "$LINENO"; then :
14024   ol_cv_pthread_select_yields=no
14025 else
14026   ol_cv_pthread_select_yields=yes
14027 fi
14028 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14029   conftest.$ac_objext conftest.beam conftest.$ac_ext
14030 fi
14031
14032 fi
14033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_pthread_select_yields" >&5
14034 $as_echo "$ol_cv_pthread_select_yields" >&6; }
14035
14036                                 if test $ol_cv_pthread_select_yields = cross ; then
14037                                         as_fn_error $? "crossing compiling: use --with-yielding-select=yes|no|manual" "$LINENO" 5
14038                                 fi
14039
14040                                 if test $ol_cv_pthread_select_yields = yes ; then
14041                                         ol_with_yielding_select=yes
14042                                 fi
14043                         fi
14044
14045                                                 CPPFLAGS="$save_CPPFLAGS"
14046                         LIBS="$save_LIBS"
14047                 else
14048                         as_fn_error $? "could not locate usable POSIX Threads" "$LINENO" 5
14049                 fi
14050         fi
14051
14052         if test $ol_with_threads = posix ; then
14053                 as_fn_error $? "could not locate POSIX Threads" "$LINENO" 5
14054         fi
14055         ;;
14056 esac
14057
14058 case $ol_with_threads in auto | yes | mach)
14059
14060                 for ac_header in mach/cthreads.h cthreads.h
14061 do :
14062   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
14063 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
14064 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
14065   cat >>confdefs.h <<_ACEOF
14066 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
14067 _ACEOF
14068
14069 fi
14070
14071 done
14072
14073         if test $ac_cv_header_mach_cthreads_h = yes ; then
14074                 ol_with_threads=found
14075
14076                                 ac_fn_c_check_func "$LINENO" "cthread_fork" "ac_cv_func_cthread_fork"
14077 if test "x$ac_cv_func_cthread_fork" = xyes; then :
14078   ol_link_threads=yes
14079 fi
14080
14081
14082                 if test $ol_link_threads = no ; then
14083                                                                         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cthread_fork with -all_load" >&5
14084 $as_echo_n "checking for cthread_fork with -all_load... " >&6; }
14085 if ${ol_cv_cthread_all_load+:} false; then :
14086   $as_echo_n "(cached) " >&6
14087 else
14088
14089                                                                 save_LIBS="$LIBS"
14090                                 LIBS="-all_load $LIBS"
14091                                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14092 /* end confdefs.h.  */
14093 #include <mach/cthreads.h>
14094 int
14095 main ()
14096 {
14097
14098                                         cthread_fork((void *)0, (void *)0);
14099
14100   ;
14101   return 0;
14102 }
14103 _ACEOF
14104 if ac_fn_c_try_link "$LINENO"; then :
14105   ol_cv_cthread_all_load=yes
14106 else
14107   ol_cv_cthread_all_load=no
14108 fi
14109 rm -f core conftest.err conftest.$ac_objext \
14110     conftest$ac_exeext conftest.$ac_ext
14111                                                                 LIBS="$save_LIBS"
14112
14113 fi
14114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_cthread_all_load" >&5
14115 $as_echo "$ol_cv_cthread_all_load" >&6; }
14116
14117                         if test $ol_cv_cthread_all_load = yes ; then
14118                                 LTHREAD_LIBS="$LTHREAD_LIBS -all_load"
14119                                 ol_link_threads=mach
14120                                 ol_with_threads=found
14121                         fi
14122                 fi
14123
14124         elif test $ac_cv_header_cthreads_h = yes ; then
14125
14126                 ol_with_threads=found
14127
14128                                 save_LIBS="$LIBS"
14129                 LIBS="$LIBS -lthreads"
14130                 ac_fn_c_check_func "$LINENO" "cthread_fork" "ac_cv_func_cthread_fork"
14131 if test "x$ac_cv_func_cthread_fork" = xyes; then :
14132   ol_link_threads=yes
14133 fi
14134
14135                 LIBS="$save_LIBS"
14136
14137                 if test $ol_link_threads = yes ; then
14138                         LTHREAD_LIBS="-lthreads"
14139                         ol_link_threads=mach
14140                         ol_with_threads=found
14141                 else
14142                         as_fn_error $? "could not link with Mach CThreads" "$LINENO" 5
14143                 fi
14144
14145         elif test $ol_with_threads = mach ; then
14146                 as_fn_error $? "could not locate Mach CThreads" "$LINENO" 5
14147         fi
14148
14149         if test $ol_link_threads = mach ; then
14150
14151 $as_echo "#define HAVE_MACH_CTHREADS 1" >>confdefs.h
14152
14153         elif test $ol_with_threads = found ; then
14154                 as_fn_error $? "could not link with Mach CThreads" "$LINENO" 5
14155         fi
14156         ;;
14157 esac
14158
14159 case $ol_with_threads in auto | yes | pth)
14160
14161         for ac_header in pth.h
14162 do :
14163   ac_fn_c_check_header_mongrel "$LINENO" "pth.h" "ac_cv_header_pth_h" "$ac_includes_default"
14164 if test "x$ac_cv_header_pth_h" = xyes; then :
14165   cat >>confdefs.h <<_ACEOF
14166 #define HAVE_PTH_H 1
14167 _ACEOF
14168
14169 fi
14170
14171 done
14172
14173
14174         if test $ac_cv_header_pth_h = yes ; then
14175                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pth_version in -lpth" >&5
14176 $as_echo_n "checking for pth_version in -lpth... " >&6; }
14177 if ${ac_cv_lib_pth_pth_version+:} false; then :
14178   $as_echo_n "(cached) " >&6
14179 else
14180   ac_check_lib_save_LIBS=$LIBS
14181 LIBS="-lpth  $LIBS"
14182 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14183 /* end confdefs.h.  */
14184
14185 /* Override any GCC internal prototype to avoid an error.
14186    Use char because int might match the return type of a GCC
14187    builtin and then its argument prototype would still apply.  */
14188 #ifdef __cplusplus
14189 extern "C"
14190 #endif
14191 char pth_version ();
14192 int
14193 main ()
14194 {
14195 return pth_version ();
14196   ;
14197   return 0;
14198 }
14199 _ACEOF
14200 if ac_fn_c_try_link "$LINENO"; then :
14201   ac_cv_lib_pth_pth_version=yes
14202 else
14203   ac_cv_lib_pth_pth_version=no
14204 fi
14205 rm -f core conftest.err conftest.$ac_objext \
14206     conftest$ac_exeext conftest.$ac_ext
14207 LIBS=$ac_check_lib_save_LIBS
14208 fi
14209 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pth_pth_version" >&5
14210 $as_echo "$ac_cv_lib_pth_pth_version" >&6; }
14211 if test "x$ac_cv_lib_pth_pth_version" = xyes; then :
14212   have_pth=yes
14213 else
14214   have_pth=no
14215 fi
14216
14217
14218                 if test $have_pth = yes ; then
14219
14220 $as_echo "#define HAVE_GNU_PTH 1" >>confdefs.h
14221
14222                         LTHREAD_LIBS="$LTHREAD_LIBS -lpth"
14223                         ol_link_threads=pth
14224                         ol_with_threads=found
14225
14226                         if test x$ol_with_yielding_select = xauto ; then
14227                                 ol_with_yielding_select=yes
14228                         fi
14229                 fi
14230         fi
14231         ;;
14232 esac
14233
14234 case $ol_with_threads in auto | yes | lwp)
14235
14236                 for ac_header in thread.h synch.h
14237 do :
14238   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
14239 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
14240 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
14241   cat >>confdefs.h <<_ACEOF
14242 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
14243 _ACEOF
14244
14245 fi
14246
14247 done
14248
14249         if test $ac_cv_header_thread_h = yes &&
14250            test $ac_cv_header_synch_h = yes ; then
14251                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for thr_create in -lthread" >&5
14252 $as_echo_n "checking for thr_create in -lthread... " >&6; }
14253 if ${ac_cv_lib_thread_thr_create+:} false; then :
14254   $as_echo_n "(cached) " >&6
14255 else
14256   ac_check_lib_save_LIBS=$LIBS
14257 LIBS="-lthread  $LIBS"
14258 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14259 /* end confdefs.h.  */
14260
14261 /* Override any GCC internal prototype to avoid an error.
14262    Use char because int might match the return type of a GCC
14263    builtin and then its argument prototype would still apply.  */
14264 #ifdef __cplusplus
14265 extern "C"
14266 #endif
14267 char thr_create ();
14268 int
14269 main ()
14270 {
14271 return thr_create ();
14272   ;
14273   return 0;
14274 }
14275 _ACEOF
14276 if ac_fn_c_try_link "$LINENO"; then :
14277   ac_cv_lib_thread_thr_create=yes
14278 else
14279   ac_cv_lib_thread_thr_create=no
14280 fi
14281 rm -f core conftest.err conftest.$ac_objext \
14282     conftest$ac_exeext conftest.$ac_ext
14283 LIBS=$ac_check_lib_save_LIBS
14284 fi
14285 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_thread_thr_create" >&5
14286 $as_echo "$ac_cv_lib_thread_thr_create" >&6; }
14287 if test "x$ac_cv_lib_thread_thr_create" = xyes; then :
14288   have_thr=yes
14289 else
14290   have_thr=no
14291 fi
14292
14293
14294                 if test $have_thr = yes ; then
14295
14296 $as_echo "#define HAVE_THR 1" >>confdefs.h
14297
14298                         LTHREAD_LIBS="$LTHREAD_LIBS -lthread"
14299                         ol_link_threads=thr
14300
14301                         if test x$ol_with_yielding_select = xauto ; then
14302                                 ol_with_yielding_select=yes
14303                         fi
14304
14305                                                 for ac_func in \
14306                                 thr_setconcurrency \
14307                                 thr_getconcurrency \
14308
14309 do :
14310   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14311 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14312 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
14313   cat >>confdefs.h <<_ACEOF
14314 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14315 _ACEOF
14316
14317 fi
14318 done
14319
14320                 fi
14321         fi
14322
14323                 for ac_header in lwp/lwp.h
14324 do :
14325   ac_fn_c_check_header_mongrel "$LINENO" "lwp/lwp.h" "ac_cv_header_lwp_lwp_h" "$ac_includes_default"
14326 if test "x$ac_cv_header_lwp_lwp_h" = xyes; then :
14327   cat >>confdefs.h <<_ACEOF
14328 #define HAVE_LWP_LWP_H 1
14329 _ACEOF
14330
14331 fi
14332
14333 done
14334
14335         if test $ac_cv_header_lwp_lwp_h = yes ; then
14336                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lwp_create in -llwp" >&5
14337 $as_echo_n "checking for lwp_create in -llwp... " >&6; }
14338 if ${ac_cv_lib_lwp_lwp_create+:} false; then :
14339   $as_echo_n "(cached) " >&6
14340 else
14341   ac_check_lib_save_LIBS=$LIBS
14342 LIBS="-llwp  $LIBS"
14343 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14344 /* end confdefs.h.  */
14345
14346 /* Override any GCC internal prototype to avoid an error.
14347    Use char because int might match the return type of a GCC
14348    builtin and then its argument prototype would still apply.  */
14349 #ifdef __cplusplus
14350 extern "C"
14351 #endif
14352 char lwp_create ();
14353 int
14354 main ()
14355 {
14356 return lwp_create ();
14357   ;
14358   return 0;
14359 }
14360 _ACEOF
14361 if ac_fn_c_try_link "$LINENO"; then :
14362   ac_cv_lib_lwp_lwp_create=yes
14363 else
14364   ac_cv_lib_lwp_lwp_create=no
14365 fi
14366 rm -f core conftest.err conftest.$ac_objext \
14367     conftest$ac_exeext conftest.$ac_ext
14368 LIBS=$ac_check_lib_save_LIBS
14369 fi
14370 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lwp_lwp_create" >&5
14371 $as_echo "$ac_cv_lib_lwp_lwp_create" >&6; }
14372 if test "x$ac_cv_lib_lwp_lwp_create" = xyes; then :
14373   have_lwp=yes
14374 else
14375   have_lwp=no
14376 fi
14377
14378
14379                 if test $have_lwp = yes ; then
14380
14381 $as_echo "#define HAVE_LWP 1" >>confdefs.h
14382
14383                         LTHREAD_LIBS="$LTHREAD_LIBS -llwp"
14384                         ol_link_threads=lwp
14385
14386                         if test x$ol_with_yielding_select = xauto ; then
14387                                 ol_with_yielding_select=no
14388                         fi
14389                 fi
14390         fi
14391         ;;
14392 esac
14393
14394 if test $ol_with_yielding_select = yes ; then
14395
14396 $as_echo "#define HAVE_YIELDING_SELECT 1" >>confdefs.h
14397
14398 fi
14399
14400 if test $ol_with_threads = manual ; then
14401                 ol_link_threads=yes
14402
14403         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: thread defines and link options must be set manually" >&5
14404 $as_echo "$as_me: WARNING: thread defines and link options must be set manually" >&2;}
14405
14406         for ac_header in pthread.h sched.h
14407 do :
14408   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
14409 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
14410 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
14411   cat >>confdefs.h <<_ACEOF
14412 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
14413 _ACEOF
14414
14415 fi
14416
14417 done
14418
14419         for ac_func in sched_yield pthread_yield
14420 do :
14421   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14422 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14423 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
14424   cat >>confdefs.h <<_ACEOF
14425 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14426 _ACEOF
14427
14428 fi
14429 done
14430
14431
14432         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LinuxThreads pthread.h" >&5
14433 $as_echo_n "checking for LinuxThreads pthread.h... " >&6; }
14434 if ${ol_cv_header_linux_threads+:} false; then :
14435   $as_echo_n "(cached) " >&6
14436 else
14437   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14438 /* end confdefs.h.  */
14439 #include <pthread.h>
14440 _ACEOF
14441 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14442   $EGREP "pthread_kill_other_threads_np" >/dev/null 2>&1; then :
14443   ol_cv_header_linux_threads=yes
14444 else
14445   ol_cv_header_linux_threads=no
14446 fi
14447 rm -f conftest*
14448
14449
14450 fi
14451 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_header_linux_threads" >&5
14452 $as_echo "$ol_cv_header_linux_threads" >&6; }
14453         if test $ol_cv_header_linux_threads = yes; then
14454
14455 $as_echo "#define HAVE_LINUX_THREADS 1" >>confdefs.h
14456
14457         fi
14458
14459
14460         for ac_header in mach/cthreads.h
14461 do :
14462   ac_fn_c_check_header_mongrel "$LINENO" "mach/cthreads.h" "ac_cv_header_mach_cthreads_h" "$ac_includes_default"
14463 if test "x$ac_cv_header_mach_cthreads_h" = xyes; then :
14464   cat >>confdefs.h <<_ACEOF
14465 #define HAVE_MACH_CTHREADS_H 1
14466 _ACEOF
14467
14468 fi
14469
14470 done
14471
14472         for ac_header in lwp/lwp.h
14473 do :
14474   ac_fn_c_check_header_mongrel "$LINENO" "lwp/lwp.h" "ac_cv_header_lwp_lwp_h" "$ac_includes_default"
14475 if test "x$ac_cv_header_lwp_lwp_h" = xyes; then :
14476   cat >>confdefs.h <<_ACEOF
14477 #define HAVE_LWP_LWP_H 1
14478 _ACEOF
14479
14480 fi
14481
14482 done
14483
14484         for ac_header in thread.h synch.h
14485 do :
14486   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
14487 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
14488 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
14489   cat >>confdefs.h <<_ACEOF
14490 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
14491 _ACEOF
14492
14493 fi
14494
14495 done
14496
14497 fi
14498
14499 if test $ol_link_threads != no && test $ol_link_threads != nt ; then
14500
14501 $as_echo "#define REENTRANT 1" >>confdefs.h
14502
14503
14504 $as_echo "#define _REENTRANT 1" >>confdefs.h
14505
14506
14507 $as_echo "#define THREAD_SAFE 1" >>confdefs.h
14508
14509
14510 $as_echo "#define _THREAD_SAFE 1" >>confdefs.h
14511
14512
14513 $as_echo "#define THREADSAFE 1" >>confdefs.h
14514
14515
14516 $as_echo "#define _THREADSAFE 1" >>confdefs.h
14517
14518
14519 $as_echo "#define _SGI_MP_SOURCE 1" >>confdefs.h
14520
14521
14522                         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for thread specific errno" >&5
14523 $as_echo_n "checking for thread specific errno... " >&6; }
14524 if ${ol_cv_errno_thread_specific+:} false; then :
14525   $as_echo_n "(cached) " >&6
14526 else
14527
14528                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14529 /* end confdefs.h.  */
14530 #include <errno.h>
14531 int
14532 main ()
14533 {
14534 errno = 0;
14535   ;
14536   return 0;
14537 }
14538 _ACEOF
14539 if ac_fn_c_try_link "$LINENO"; then :
14540   ol_cv_errno_thread_specific=yes
14541 else
14542   ol_cv_errno_thread_specific=no
14543 fi
14544 rm -f core conftest.err conftest.$ac_objext \
14545     conftest$ac_exeext conftest.$ac_ext
14546
14547 fi
14548 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_errno_thread_specific" >&5
14549 $as_echo "$ol_cv_errno_thread_specific" >&6; }
14550
14551                         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for thread specific h_errno" >&5
14552 $as_echo_n "checking for thread specific h_errno... " >&6; }
14553 if ${ol_cv_h_errno_thread_specific+:} false; then :
14554   $as_echo_n "(cached) " >&6
14555 else
14556
14557                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14558 /* end confdefs.h.  */
14559 #include <netdb.h>
14560 int
14561 main ()
14562 {
14563 h_errno = 0;
14564   ;
14565   return 0;
14566 }
14567 _ACEOF
14568 if ac_fn_c_try_link "$LINENO"; then :
14569   ol_cv_h_errno_thread_specific=yes
14570 else
14571   ol_cv_h_errno_thread_specific=no
14572 fi
14573 rm -f core conftest.err conftest.$ac_objext \
14574     conftest$ac_exeext conftest.$ac_ext
14575
14576 fi
14577 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ol_cv_h_errno_thread_specific" >&5
14578 $as_echo "$ol_cv_h_errno_thread_specific" >&6; }
14579
14580         if test $ol_cv_errno_thread_specific != yes ||
14581            test $ol_cv_h_errno_thread_specific != yes ; then
14582                 LIBS="$LTHREAD_LIBS $LIBS"
14583                 LTHREAD_LIBS=""
14584         fi
14585
14586 fi
14587
14588 if test $ol_link_threads = no ; then
14589         if test $ol_with_threads = yes ; then
14590                 as_fn_error $? "no suitable thread support" "$LINENO" 5
14591         fi
14592
14593         if test $ol_with_threads = auto ; then
14594                 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no suitable thread support, disabling threads" >&5
14595 $as_echo "$as_me: WARNING: no suitable thread support, disabling threads" >&2;}
14596                 ol_with_threads=no
14597         fi
14598
14599
14600 $as_echo "#define NO_THREADS 1" >>confdefs.h
14601
14602         LTHREAD_LIBS=""
14603         BUILD_THREAD=no
14604 else
14605         BUILD_THREAD=yes
14606 fi
14607
14608 if test $ol_link_threads != no ; then
14609
14610 $as_echo "#define LDAP_API_FEATURE_X_OPENLDAP_THREAD_SAFE 1" >>confdefs.h
14611
14612 fi
14613
14614 # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
14615 case "$ol_with_threads" in
14616  no)
14617     ol_pthread_ok=no
14618
14619     ;;
14620  *)
14621     ol_found_pthreads=yes
14622     ;;
14623 esac
14624
14625 ac_ext=c
14626 ac_cpp='$CPP $CPPFLAGS'
14627 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
14628 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
14629 ac_compiler_gnu=$ac_cv_c_compiler_gnu
14630
14631
14632     case "$ol_found_pthreads" in
14633      yes)
14634         saved_LIBS="$LIBS"
14635         LIBS="$LTHREAD_LIBS $LIBS"
14636         saved_CFLAGS="$CFLAGS"
14637         CFLAGS="$PTHREAD_CFLAGS $CFLAGS"
14638         for ac_func in sem_timedwait
14639 do :
14640   ac_fn_c_check_func "$LINENO" "sem_timedwait" "ac_cv_func_sem_timedwait"
14641 if test "x$ac_cv_func_sem_timedwait" = xyes; then :
14642   cat >>confdefs.h <<_ACEOF
14643 #define HAVE_SEM_TIMEDWAIT 1
14644 _ACEOF
14645
14646 fi
14647 done
14648
14649         LIBS="$saved_LIBS"
14650         { saved_LIBS=; unset saved_LIBS;}
14651         CFLAGS="$saved_CFLAGS"
14652         { saved_CFLAGS=; unset saved_CFLAGS;}
14653         case "$ac_cv_func_sem_timedwait" in
14654          yes)
14655             PTHREAD_LIBS="$LTHREAD_LIBS"
14656             have_pthreads=yes
14657             # Bug 2332: With GCC we need to force a reference to libgcc_s
14658             # (if libgcc_s exists) or the combination of
14659             # threads + setuid + mlockall does not work on linux because
14660             # thread cancellation fails to load libgcc_s with dlopen().
14661             # We have to pass this all as linker options to avoid argument
14662             # reordering by libtool.
14663             case "$GCC$with_gnu_ld" in
14664             yesyes)
14665                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for exit in -lgcc_s" >&5
14666 $as_echo_n "checking for exit in -lgcc_s... " >&6; }
14667 if ${ac_cv_lib_gcc_s_exit+:} false; then :
14668   $as_echo_n "(cached) " >&6
14669 else
14670   ac_check_lib_save_LIBS=$LIBS
14671 LIBS="-lgcc_s  $LIBS"
14672 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14673 /* end confdefs.h.  */
14674
14675 /* Override any GCC internal prototype to avoid an error.
14676    Use char because int might match the return type of a GCC
14677    builtin and then its argument prototype would still apply.  */
14678 #ifdef __cplusplus
14679 extern "C"
14680 #endif
14681 char exit ();
14682 int
14683 main ()
14684 {
14685 return exit ();
14686   ;
14687   return 0;
14688 }
14689 _ACEOF
14690 if ac_fn_c_try_link "$LINENO"; then :
14691   ac_cv_lib_gcc_s_exit=yes
14692 else
14693   ac_cv_lib_gcc_s_exit=no
14694 fi
14695 rm -f core conftest.err conftest.$ac_objext \
14696     conftest$ac_exeext conftest.$ac_ext
14697 LIBS=$ac_check_lib_save_LIBS
14698 fi
14699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gcc_s_exit" >&5
14700 $as_echo "$ac_cv_lib_gcc_s_exit" >&6; }
14701 if test "x$ac_cv_lib_gcc_s_exit" = xyes; then :
14702   PTHREAD_LIBS="$LTHREAD_LIBS -Wl,--no-as-needed,-lgcc_s,--as-needed"
14703 fi
14704
14705                 ;;
14706             esac
14707         esac
14708     esac
14709 esac
14710
14711 case "$have_pthreads" in
14712  yes)
14713     CFLAGS_NTP="$CFLAGS_NTP $PTHREAD_CFLAGS"
14714     saved_LIBS="$LIBS"
14715     LIBS="$LTHREAD_LIBS $LIBS"
14716     saved_CFLAGS="$CFLAGS"
14717     CFLAGS="$PTHREAD_CFLAGS $CFLAGS"
14718     # The cast to long int works around a bug in the HP C Compiler
14719 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
14720 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
14721 # This bug is HP SR number 8606223364.
14722 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of pthread_t" >&5
14723 $as_echo_n "checking size of pthread_t... " >&6; }
14724 if ${ac_cv_sizeof_pthread_t+:} false; then :
14725   $as_echo_n "(cached) " >&6
14726 else
14727   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (pthread_t))" "ac_cv_sizeof_pthread_t"        "
14728             $ac_includes_default
14729             #include <pthread.h>
14730
14731
14732 "; then :
14733
14734 else
14735   if test "$ac_cv_type_pthread_t" = yes; then
14736      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
14737 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
14738 as_fn_error 77 "cannot compute sizeof (pthread_t)
14739 See \`config.log' for more details" "$LINENO" 5; }
14740    else
14741      ac_cv_sizeof_pthread_t=0
14742    fi
14743 fi
14744
14745 fi
14746 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_pthread_t" >&5
14747 $as_echo "$ac_cv_sizeof_pthread_t" >&6; }
14748
14749
14750
14751 cat >>confdefs.h <<_ACEOF
14752 #define SIZEOF_PTHREAD_T $ac_cv_sizeof_pthread_t
14753 _ACEOF
14754
14755
14756     LIBISC_PTHREADS_NOTHREADS=pthreads
14757
14758 $as_echo "#define ISC_PLATFORM_USETHREADS 1" >>confdefs.h
14759
14760     #
14761     # We'd like to use sigwait() too
14762     #
14763     ac_fn_c_check_func "$LINENO" "sigwait" "ac_cv_func_sigwait"
14764 if test "x$ac_cv_func_sigwait" = xyes; then :
14765   have_sigwait=yes
14766 else
14767   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigwait in -lc" >&5
14768 $as_echo_n "checking for sigwait in -lc... " >&6; }
14769 if ${ac_cv_lib_c_sigwait+:} false; then :
14770   $as_echo_n "(cached) " >&6
14771 else
14772   ac_check_lib_save_LIBS=$LIBS
14773 LIBS="-lc  $LIBS"
14774 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14775 /* end confdefs.h.  */
14776
14777 /* Override any GCC internal prototype to avoid an error.
14778    Use char because int might match the return type of a GCC
14779    builtin and then its argument prototype would still apply.  */
14780 #ifdef __cplusplus
14781 extern "C"
14782 #endif
14783 char sigwait ();
14784 int
14785 main ()
14786 {
14787 return sigwait ();
14788   ;
14789   return 0;
14790 }
14791 _ACEOF
14792 if ac_fn_c_try_link "$LINENO"; then :
14793   ac_cv_lib_c_sigwait=yes
14794 else
14795   ac_cv_lib_c_sigwait=no
14796 fi
14797 rm -f core conftest.err conftest.$ac_objext \
14798     conftest$ac_exeext conftest.$ac_ext
14799 LIBS=$ac_check_lib_save_LIBS
14800 fi
14801 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_sigwait" >&5
14802 $as_echo "$ac_cv_lib_c_sigwait" >&6; }
14803 if test "x$ac_cv_lib_c_sigwait" = xyes; then :
14804   have_sigwait=yes
14805 else
14806   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigwait in -lpthread" >&5
14807 $as_echo_n "checking for sigwait in -lpthread... " >&6; }
14808 if ${ac_cv_lib_pthread_sigwait+:} false; then :
14809   $as_echo_n "(cached) " >&6
14810 else
14811   ac_check_lib_save_LIBS=$LIBS
14812 LIBS="-lpthread  $LIBS"
14813 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14814 /* end confdefs.h.  */
14815
14816 /* Override any GCC internal prototype to avoid an error.
14817    Use char because int might match the return type of a GCC
14818    builtin and then its argument prototype would still apply.  */
14819 #ifdef __cplusplus
14820 extern "C"
14821 #endif
14822 char sigwait ();
14823 int
14824 main ()
14825 {
14826 return sigwait ();
14827   ;
14828   return 0;
14829 }
14830 _ACEOF
14831 if ac_fn_c_try_link "$LINENO"; then :
14832   ac_cv_lib_pthread_sigwait=yes
14833 else
14834   ac_cv_lib_pthread_sigwait=no
14835 fi
14836 rm -f core conftest.err conftest.$ac_objext \
14837     conftest$ac_exeext conftest.$ac_ext
14838 LIBS=$ac_check_lib_save_LIBS
14839 fi
14840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_sigwait" >&5
14841 $as_echo "$ac_cv_lib_pthread_sigwait" >&6; }
14842 if test "x$ac_cv_lib_pthread_sigwait" = xyes; then :
14843   have_sigwait=yes
14844 else
14845   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _Psigwait in -lpthread" >&5
14846 $as_echo_n "checking for _Psigwait in -lpthread... " >&6; }
14847 if ${ac_cv_lib_pthread__Psigwait+:} false; then :
14848   $as_echo_n "(cached) " >&6
14849 else
14850   ac_check_lib_save_LIBS=$LIBS
14851 LIBS="-lpthread  $LIBS"
14852 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14853 /* end confdefs.h.  */
14854
14855 /* Override any GCC internal prototype to avoid an error.
14856    Use char because int might match the return type of a GCC
14857    builtin and then its argument prototype would still apply.  */
14858 #ifdef __cplusplus
14859 extern "C"
14860 #endif
14861 char _Psigwait ();
14862 int
14863 main ()
14864 {
14865 return _Psigwait ();
14866   ;
14867   return 0;
14868 }
14869 _ACEOF
14870 if ac_fn_c_try_link "$LINENO"; then :
14871   ac_cv_lib_pthread__Psigwait=yes
14872 else
14873   ac_cv_lib_pthread__Psigwait=no
14874 fi
14875 rm -f core conftest.err conftest.$ac_objext \
14876     conftest$ac_exeext conftest.$ac_ext
14877 LIBS=$ac_check_lib_save_LIBS
14878 fi
14879 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread__Psigwait" >&5
14880 $as_echo "$ac_cv_lib_pthread__Psigwait" >&6; }
14881 if test "x$ac_cv_lib_pthread__Psigwait" = xyes; then :
14882   have_sigwait=yes
14883 else
14884   have_sigwait=no
14885
14886 fi
14887
14888
14889 fi
14890
14891
14892 fi
14893
14894
14895 fi
14896
14897     case "$host:$have_sigwait" in
14898      *-freebsd*:no)
14899         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigwait in -lc_r" >&5
14900 $as_echo_n "checking for sigwait in -lc_r... " >&6; }
14901 if ${ac_cv_lib_c_r_sigwait+:} false; then :
14902   $as_echo_n "(cached) " >&6
14903 else
14904   ac_check_lib_save_LIBS=$LIBS
14905 LIBS="-lc_r  $LIBS"
14906 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14907 /* end confdefs.h.  */
14908
14909 /* Override any GCC internal prototype to avoid an error.
14910    Use char because int might match the return type of a GCC
14911    builtin and then its argument prototype would still apply.  */
14912 #ifdef __cplusplus
14913 extern "C"
14914 #endif
14915 char sigwait ();
14916 int
14917 main ()
14918 {
14919 return sigwait ();
14920   ;
14921   return 0;
14922 }
14923 _ACEOF
14924 if ac_fn_c_try_link "$LINENO"; then :
14925   ac_cv_lib_c_r_sigwait=yes
14926 else
14927   ac_cv_lib_c_r_sigwait=no
14928 fi
14929 rm -f core conftest.err conftest.$ac_objext \
14930     conftest$ac_exeext conftest.$ac_ext
14931 LIBS=$ac_check_lib_save_LIBS
14932 fi
14933 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_r_sigwait" >&5
14934 $as_echo "$ac_cv_lib_c_r_sigwait" >&6; }
14935 if test "x$ac_cv_lib_c_r_sigwait" = xyes; then :
14936   have_sigwait=yes
14937
14938 fi
14939
14940     esac
14941     case "$have_sigwait" in
14942      yes)
14943         ac_cv_func_sigwait=yes
14944
14945 $as_echo "#define HAVE_SIGWAIT 1" >>confdefs.h
14946
14947     esac
14948
14949     for ac_func in pthread_attr_getstacksize
14950 do :
14951   ac_fn_c_check_func "$LINENO" "pthread_attr_getstacksize" "ac_cv_func_pthread_attr_getstacksize"
14952 if test "x$ac_cv_func_pthread_attr_getstacksize" = xyes; then :
14953   cat >>confdefs.h <<_ACEOF
14954 #define HAVE_PTHREAD_ATTR_GETSTACKSIZE 1
14955 _ACEOF
14956
14957 fi
14958 done
14959
14960     for ac_func in pthread_attr_setstacksize sysconf
14961 do :
14962   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14963 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14964 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
14965   cat >>confdefs.h <<_ACEOF
14966 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14967 _ACEOF
14968
14969 fi
14970 done
14971
14972
14973     case "$host" in
14974      *-freebsd5.[012]|*-freebsd5.[012].*)
14975         ;;
14976      *-freebsd5.[3456789]|*-freebsd5.[3456789].*|*-freebsd6.*)
14977
14978 $as_echo "#define NEED_PTHREAD_SCOPE_SYSTEM 1" >>confdefs.h
14979
14980         ;;
14981      *-bsdi3.*|*-bsdi4.0*)
14982
14983 $as_echo "#define NEED_PTHREAD_INIT 1" >>confdefs.h
14984
14985         ;;
14986      *-linux*)
14987
14988 $as_echo "#define HAVE_LINUXTHREADS 1" >>confdefs.h
14989
14990         ;;
14991      *-solaris*)
14992         $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
14993
14994         for ac_func in pthread_setconcurrency
14995 do :
14996   ac_fn_c_check_func "$LINENO" "pthread_setconcurrency" "ac_cv_func_pthread_setconcurrency"
14997 if test "x$ac_cv_func_pthread_setconcurrency" = xyes; then :
14998   cat >>confdefs.h <<_ACEOF
14999 #define HAVE_PTHREAD_SETCONCURRENCY 1
15000 _ACEOF
15001
15002 fi
15003 done
15004
15005         case "$ac_cv_func_pthread_setconcurrency" in
15006          yes)
15007
15008 $as_echo "#define CALL_PTHREAD_SETCONCURRENCY 1" >>confdefs.h
15009
15010         esac
15011         ;;
15012      *-sco-sysv*uw*|*-*-sysv*UnixWare*|*-*-sysv*OpenUNIX*)
15013
15014 $as_echo "#define HAVE_UNIXWARE_SIGWAIT 1" >>confdefs.h
15015
15016         ;;
15017     esac
15018     hack_shutup_pthreadonceinit=no
15019     case "$host" in
15020      *-aix5.[123].*)
15021         hack_shutup_pthreadonceinit=yes
15022         ;;
15023      *-solaris2.[89])
15024         hack_shutup_pthreadonceinit=yes
15025         ;;
15026      *-solaris2.1[0-9])
15027         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if extra braces are needed for PTHREAD_ONCE_INIT" >&5
15028 $as_echo_n "checking if extra braces are needed for PTHREAD_ONCE_INIT... " >&6; }
15029 if ${ntp_cv_braces_around_pthread_once_init+:} false; then :
15030   $as_echo_n "(cached) " >&6
15031 else
15032   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15033 /* end confdefs.h.  */
15034
15035                         #include <pthread.h>
15036
15037 int
15038 main ()
15039 {
15040
15041                         static pthread_once_t once_test =
15042                                                 PTHREAD_ONCE_INIT;
15043
15044
15045   ;
15046   return 0;
15047 }
15048 _ACEOF
15049 if ac_fn_c_try_compile "$LINENO"; then :
15050   ntp_cv_braces_around_pthread_once_init=no
15051 else
15052   ntp_cv_braces_around_pthread_once_init=yes
15053
15054 fi
15055 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15056
15057 fi
15058 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_braces_around_pthread_once_init" >&5
15059 $as_echo "$ntp_cv_braces_around_pthread_once_init" >&6; }
15060         case "$ntp_cv_braces_around_pthread_once_init" in
15061          yes)
15062             hack_shutup_pthreadonceinit=yes
15063         esac
15064         ;;
15065     esac
15066     case "$hack_shutup_pthreadonceinit" in
15067      yes)
15068
15069 $as_echo "#define ISC_PLATFORM_BRACEPTHREADONCEINIT 1" >>confdefs.h
15070
15071     esac
15072     LIBS="$saved_LIBS"
15073     { saved_LIBS=; unset saved_LIBS;}
15074     CFLAGS="$saved_CFLAGS"
15075     { saved_CFLAGS=; unset saved_CFLAGS;}
15076     ;;
15077  *)
15078     LIBISC_PTHREADS_NOTHREADS=nothreads
15079     ;;
15080 esac
15081
15082  if test "$have_pthreads" != "no"; then
15083   PTHREADS_TRUE=
15084   PTHREADS_FALSE='#'
15085 else
15086   PTHREADS_TRUE='#'
15087   PTHREADS_FALSE=
15088 fi
15089
15090
15091
15092
15093
15094
15095
15096 case "$hw_use_rpl_vsnprintf:$hw_cv_func_vsnprintf" in
15097  no:yes)
15098     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if vsnprintf expands \"%m\" to strerror(errno)" >&5
15099 $as_echo_n "checking if vsnprintf expands \"%m\" to strerror(errno)... " >&6; }
15100 if ${ntp_cv_vsnprintf_percent_m+:} false; then :
15101   $as_echo_n "(cached) " >&6
15102 else
15103   if test "$cross_compiling" = yes; then :
15104   ntp_cv_vsnprintf_percent_m=no
15105
15106 else
15107   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15108 /* end confdefs.h.  */
15109
15110                     #include <stdarg.h>
15111                     #include <errno.h>
15112                     #include <stdio.h>
15113                     #include <string.h>
15114
15115                     int call_vsnprintf(
15116                             char *      dst,
15117                             size_t      sz,
15118                             const char *fmt,
15119                             ...
15120                             );
15121
15122                     int call_vsnprintf(
15123                             char *      dst,
15124                             size_t      sz,
15125                             const char *fmt,
15126                             ...
15127                             )
15128                     {
15129                             va_list     ap;
15130                             int         rc;
15131
15132                             va_start(ap, fmt);
15133                             rc = vsnprintf(dst, sz, fmt, ap);
15134                             va_end(ap);
15135
15136                             return rc;
15137                     }
15138
15139 int
15140 main ()
15141 {
15142
15143                     char        sbuf[512];
15144                     char        pbuf[512];
15145                     int         slen;
15146
15147                     strcpy(sbuf, strerror(ENOENT));
15148                     errno = ENOENT;
15149                     slen = call_vsnprintf(pbuf, sizeof(pbuf), "%m",
15150                                           "wrong");
15151                     return strcmp(sbuf, pbuf);
15152
15153
15154   ;
15155   return 0;
15156 }
15157 _ACEOF
15158 if ac_fn_c_try_run "$LINENO"; then :
15159   ntp_cv_vsnprintf_percent_m=yes
15160 else
15161   ntp_cv_vsnprintf_percent_m=no
15162 fi
15163 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15164   conftest.$ac_objext conftest.beam conftest.$ac_ext
15165 fi
15166
15167
15168 fi
15169 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_vsnprintf_percent_m" >&5
15170 $as_echo "$ntp_cv_vsnprintf_percent_m" >&6; }
15171     case "$ntp_cv_vsnprintf_percent_m" in
15172      yes)
15173
15174 $as_echo "#define VSNPRINTF_PERCENT_M 1" >>confdefs.h
15175
15176     esac
15177 esac
15178
15179 for ac_header in sys/clockctl.h
15180 do :
15181   ac_fn_c_check_header_mongrel "$LINENO" "sys/clockctl.h" "ac_cv_header_sys_clockctl_h" "$ac_includes_default"
15182 if test "x$ac_cv_header_sys_clockctl_h" = xyes; then :
15183   cat >>confdefs.h <<_ACEOF
15184 #define HAVE_SYS_CLOCKCTL_H 1
15185 _ACEOF
15186
15187 fi
15188
15189 done
15190
15191
15192 # Check whether --enable-clockctl was given.
15193 if test "${enable_clockctl+set}" = set; then :
15194   enableval=$enable_clockctl; ntp_use_dev_clockctl=$enableval
15195 else
15196   ntp_use_dev_clockctl=$ac_cv_header_sys_clockctl_h
15197
15198 fi
15199
15200
15201 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should use /dev/clockctl" >&5
15202 $as_echo_n "checking if we should use /dev/clockctl... " >&6; }
15203 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_use_dev_clockctl" >&5
15204 $as_echo "$ntp_use_dev_clockctl" >&6; }
15205
15206
15207 for ac_header in sys/capability.h sys/prctl.h
15208 do :
15209   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
15210 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
15211 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
15212   cat >>confdefs.h <<_ACEOF
15213 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
15214 _ACEOF
15215
15216 fi
15217
15218 done
15219
15220
15221 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have linux capabilities (libcap)" >&5
15222 $as_echo_n "checking if we have linux capabilities (libcap)... " >&6; }
15223
15224 case "$ac_cv_header_sys_capability_h$ac_cv_header_sys_prctl_h" in
15225  yesyes)
15226     case "$host" in
15227      mips-sgi-irix*)
15228         ntp_have_linuxcaps=no
15229         ;;
15230      *) ntp_have_linuxcaps=yes
15231         ;;
15232     esac
15233     ;;
15234  *)
15235     ntp_have_linuxcaps=no
15236     ;;
15237 esac
15238
15239 # Check whether --enable-linuxcaps was given.
15240 if test "${enable_linuxcaps+set}" = set; then :
15241   enableval=$enable_linuxcaps; ntp_have_linuxcaps=$enableval
15242
15243 fi
15244
15245
15246 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_have_linuxcaps" >&5
15247 $as_echo "$ntp_have_linuxcaps" >&6; }
15248
15249 case "$ntp_have_linuxcaps" in
15250  yes)
15251
15252 $as_echo "#define HAVE_LINUX_CAPABILITIES 1" >>confdefs.h
15253
15254     LIBS="$LIBS -lcap"
15255     ;;
15256 esac
15257
15258
15259 for ac_header in priv.h
15260 do :
15261   ac_fn_c_check_header_mongrel "$LINENO" "priv.h" "ac_cv_header_priv_h" "$ac_includes_default"
15262 if test "x$ac_cv_header_priv_h" = xyes; then :
15263   cat >>confdefs.h <<_ACEOF
15264 #define HAVE_PRIV_H 1
15265 _ACEOF
15266
15267 fi
15268
15269 done
15270
15271
15272 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have solaris privileges" >&5
15273 $as_echo_n "checking if we have solaris privileges... " >&6; }
15274
15275 case "$ac_cv_header_priv_h" in
15276  yes)
15277     case "$host" in
15278      *-solaris*)
15279         ac_fn_c_check_func "$LINENO" "setppriv" "ac_cv_func_setppriv"
15280 if test "x$ac_cv_func_setppriv" = xyes; then :
15281   ntp_have_solarisprivs=yes
15282 else
15283   ntp_have_solarisprivs=no
15284
15285 fi
15286
15287         ;;
15288     esac
15289 esac
15290
15291 # Check whether --enable-solarisprivs was given.
15292 if test "${enable_solarisprivs+set}" = set; then :
15293   enableval=$enable_solarisprivs; ntp_have_solarisprivs=$enableval
15294
15295 fi
15296
15297
15298
15299 case "$ntp_have_solarisprivs" in
15300  yes)
15301
15302 $as_echo "#define HAVE_SOLARIS_PRIVS 1" >>confdefs.h
15303
15304 esac
15305
15306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_have_solarisprivs" >&5
15307 $as_echo "$ntp_have_solarisprivs" >&6; }
15308
15309 case "$ntp_use_dev_clockctl$ntp_have_linuxcaps$ntp_have_solarisprivs" in
15310  *yes*)
15311
15312 $as_echo "#define HAVE_DROPROOT 1" >>confdefs.h
15313
15314 esac
15315
15316 case "$host" in
15317  *-*-darwin*)
15318     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing res_9_init" >&5
15319 $as_echo_n "checking for library containing res_9_init... " >&6; }
15320 if ${ac_cv_search_res_9_init+:} false; then :
15321   $as_echo_n "(cached) " >&6
15322 else
15323   ac_func_search_save_LIBS=$LIBS
15324 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15325 /* end confdefs.h.  */
15326
15327 /* Override any GCC internal prototype to avoid an error.
15328    Use char because int might match the return type of a GCC
15329    builtin and then its argument prototype would still apply.  */
15330 #ifdef __cplusplus
15331 extern "C"
15332 #endif
15333 char res_9_init ();
15334 int
15335 main ()
15336 {
15337 return res_9_init ();
15338   ;
15339   return 0;
15340 }
15341 _ACEOF
15342 for ac_lib in '' resolv; do
15343   if test -z "$ac_lib"; then
15344     ac_res="none required"
15345   else
15346     ac_res=-l$ac_lib
15347     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
15348   fi
15349   if ac_fn_c_try_link "$LINENO"; then :
15350   ac_cv_search_res_9_init=$ac_res
15351 fi
15352 rm -f core conftest.err conftest.$ac_objext \
15353     conftest$ac_exeext
15354   if ${ac_cv_search_res_9_init+:} false; then :
15355   break
15356 fi
15357 done
15358 if ${ac_cv_search_res_9_init+:} false; then :
15359
15360 else
15361   ac_cv_search_res_9_init=no
15362 fi
15363 rm conftest.$ac_ext
15364 LIBS=$ac_func_search_save_LIBS
15365 fi
15366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_res_9_init" >&5
15367 $as_echo "$ac_cv_search_res_9_init" >&6; }
15368 ac_res=$ac_cv_search_res_9_init
15369 if test "$ac_res" != no; then :
15370   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
15371
15372 fi
15373
15374     ;;
15375  *) { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing res_init" >&5
15376 $as_echo_n "checking for library containing res_init... " >&6; }
15377 if ${ac_cv_search_res_init+:} false; then :
15378   $as_echo_n "(cached) " >&6
15379 else
15380   ac_func_search_save_LIBS=$LIBS
15381 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15382 /* end confdefs.h.  */
15383
15384 /* Override any GCC internal prototype to avoid an error.
15385    Use char because int might match the return type of a GCC
15386    builtin and then its argument prototype would still apply.  */
15387 #ifdef __cplusplus
15388 extern "C"
15389 #endif
15390 char res_init ();
15391 int
15392 main ()
15393 {
15394 return res_init ();
15395   ;
15396   return 0;
15397 }
15398 _ACEOF
15399 for ac_lib in '' resolv; do
15400   if test -z "$ac_lib"; then
15401     ac_res="none required"
15402   else
15403     ac_res=-l$ac_lib
15404     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
15405   fi
15406   if ac_fn_c_try_link "$LINENO"; then :
15407   ac_cv_search_res_init=$ac_res
15408 fi
15409 rm -f core conftest.err conftest.$ac_objext \
15410     conftest$ac_exeext
15411   if ${ac_cv_search_res_init+:} false; then :
15412   break
15413 fi
15414 done
15415 if ${ac_cv_search_res_init+:} false; then :
15416
15417 else
15418   ac_cv_search_res_init=no
15419 fi
15420 rm conftest.$ac_ext
15421 LIBS=$ac_func_search_save_LIBS
15422 fi
15423 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_res_init" >&5
15424 $as_echo "$ac_cv_search_res_init" >&6; }
15425 ac_res=$ac_cv_search_res_init
15426 if test "$ac_res" != no; then :
15427   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
15428
15429 fi
15430
15431     ;;
15432 esac
15433 for ac_header in sys/types.h netinet/in.h arpa/nameser.h netdb.h resolv.h
15434 do :
15435   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
15436 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "#ifdef HAVE_SYS_TYPES_H
15437 #  include <sys/types.h>
15438 #endif
15439 #ifdef HAVE_NETINET_IN_H
15440 #  include <netinet/in.h>   /* inet_ functions / structs */
15441 #endif
15442 #ifdef HAVE_ARPA_NAMESER_H
15443 #  include <arpa/nameser.h> /* DNS HEADER struct */
15444 #endif
15445 #ifdef HAVE_NETDB_H
15446 #  include <netdb.h>
15447 #endif
15448 "
15449 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
15450   cat >>confdefs.h <<_ACEOF
15451 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
15452 _ACEOF
15453
15454 fi
15455
15456 done
15457
15458
15459 #HMS: Why do we do this check so "early"?
15460 for ac_func in res_init
15461 do :
15462   ac_fn_c_check_func "$LINENO" "res_init" "ac_cv_func_res_init"
15463 if test "x$ac_cv_func_res_init" = xyes; then :
15464   cat >>confdefs.h <<_ACEOF
15465 #define HAVE_RES_INIT 1
15466 _ACEOF
15467
15468 else
15469   for ac_func in __res_init
15470 do :
15471   ac_fn_c_check_func "$LINENO" "__res_init" "ac_cv_func___res_init"
15472 if test "x$ac_cv_func___res_init" = xyes; then :
15473   cat >>confdefs.h <<_ACEOF
15474 #define HAVE___RES_INIT 1
15475 _ACEOF
15476
15477 fi
15478 done
15479
15480 fi
15481 done
15482
15483
15484 # We also need -lsocket, but we have tested for that already.
15485 ac_fn_c_check_func "$LINENO" "inet_ntop" "ac_cv_func_inet_ntop"
15486 if test "x$ac_cv_func_inet_ntop" = xyes; then :
15487
15488 else
15489
15490 $as_echo "#define ISC_PLATFORM_NEEDNTOP 1" >>confdefs.h
15491
15492 fi
15493
15494 ac_fn_c_check_func "$LINENO" "inet_pton" "ac_cv_func_inet_pton"
15495 if test "x$ac_cv_func_inet_pton" = xyes; then :
15496
15497 else
15498
15499 $as_echo "#define ISC_PLATFORM_NEEDPTON 1" >>confdefs.h
15500
15501 fi
15502
15503
15504 ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default"
15505 if test "x$ac_cv_type_uintptr_t" = xyes; then :
15506
15507 cat >>confdefs.h <<_ACEOF
15508 #define HAVE_UINTPTR_T 1
15509 _ACEOF
15510
15511
15512 fi
15513 ac_fn_c_check_type "$LINENO" "int32" "ac_cv_type_int32" "$ac_includes_default"
15514 if test "x$ac_cv_type_int32" = xyes; then :
15515
15516 cat >>confdefs.h <<_ACEOF
15517 #define HAVE_INT32 1
15518 _ACEOF
15519
15520
15521 fi
15522 ac_fn_c_check_type "$LINENO" "u_int32" "ac_cv_type_u_int32" "$ac_includes_default"
15523 if test "x$ac_cv_type_u_int32" = xyes; then :
15524
15525 cat >>confdefs.h <<_ACEOF
15526 #define HAVE_U_INT32 1
15527 _ACEOF
15528
15529
15530 fi
15531
15532
15533
15534
15535 case "$ac_cv_type_int32::$ac_cv_header_resolv_h" in
15536  no::yes)
15537     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for int32 with DNS headers included" >&5
15538 $as_echo_n "checking for int32 with DNS headers included... " >&6; }
15539 if ${ntp_cv_type_int32_with_dns+:} false; then :
15540   $as_echo_n "(cached) " >&6
15541 else
15542   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15543 /* end confdefs.h.  */
15544
15545                     #ifdef HAVE_ARPA_NAMESER_H
15546                     # include <arpa/nameser.h>
15547                     #endif
15548                     #include <resolv.h>
15549
15550 int
15551 main ()
15552 {
15553
15554                     size_t cb = sizeof(int32);
15555
15556
15557   ;
15558   return 0;
15559 }
15560 _ACEOF
15561 if ac_fn_c_try_compile "$LINENO"; then :
15562   ntp_cv_type_int32_with_dns=yes
15563 else
15564   ntp_cv_type_int32_with_dns=no
15565
15566 fi
15567 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15568
15569 fi
15570 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_type_int32_with_dns" >&5
15571 $as_echo "$ntp_cv_type_int32_with_dns" >&6; }
15572     case "$ntp_cv_type_int32_with_dns" in
15573      yes)
15574
15575 $as_echo "#define HAVE_INT32_ONLY_WITH_DNS 1" >>confdefs.h
15576
15577     esac
15578 esac
15579
15580 case "$ac_cv_type_u_int32::$ac_cv_header_resolv_h" in
15581  no::yes)
15582     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for u_int32 with DNS headers included" >&5
15583 $as_echo_n "checking for u_int32 with DNS headers included... " >&6; }
15584 if ${ntp_cv_type_u_int32_with_dns+:} false; then :
15585   $as_echo_n "(cached) " >&6
15586 else
15587   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15588 /* end confdefs.h.  */
15589
15590                     #ifdef HAVE_ARPA_NAMESER_H
15591                     # include <arpa/nameser.h>
15592                     #endif
15593                     #include <resolv.h>
15594
15595 int
15596 main ()
15597 {
15598
15599                     size_t cb = sizeof(u_int32);
15600
15601
15602   ;
15603   return 0;
15604 }
15605 _ACEOF
15606 if ac_fn_c_try_compile "$LINENO"; then :
15607   ntp_cv_type_u_int32_with_dns=yes
15608 else
15609   ntp_cv_type_u_int32_with_dns=no
15610
15611 fi
15612 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15613
15614 fi
15615 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_type_u_int32_with_dns" >&5
15616 $as_echo "$ntp_cv_type_u_int32_with_dns" >&6; }
15617     case "$ntp_cv_type_u_int32_with_dns" in
15618      yes)
15619
15620 $as_echo "#define HAVE_U_INT32_ONLY_WITH_DNS 1" >>confdefs.h
15621
15622     esac
15623 esac
15624
15625 for ac_header in sys/timepps.h
15626 do :
15627   ac_fn_c_check_header_compile "$LINENO" "sys/timepps.h" "ac_cv_header_sys_timepps_h" "
15628         #ifdef HAVE_SYS_TIME_H
15629         # include <sys/time.h>
15630         #endif
15631         #ifdef HAVE_ERRNO_H
15632         # include <errno.h>
15633         #endif
15634
15635
15636 "
15637 if test "x$ac_cv_header_sys_timepps_h" = xyes; then :
15638   cat >>confdefs.h <<_ACEOF
15639 #define HAVE_SYS_TIMEPPS_H 1
15640 _ACEOF
15641
15642 fi
15643
15644 done
15645
15646
15647 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec" >&5
15648 $as_echo_n "checking for struct timespec... " >&6; }
15649 if ${ntp_cv_struct_timespec+:} false; then :
15650   $as_echo_n "(cached) " >&6
15651 else
15652   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15653 /* end confdefs.h.  */
15654
15655                 #include <sys/time.h>
15656                 /* Under SunOS, timespec is in sys/timepps.h,
15657                    which needs errno.h and FRAC */
15658                 #ifdef HAVE_ERRNO_H
15659                 # include <errno.h>
15660                 #endif
15661                 #ifdef HAVE_SYS_TIMEPPS_H
15662                 # define FRAC 4294967296
15663                 # include <sys/timepps.h>
15664                 #endif
15665
15666 int
15667 main ()
15668 {
15669
15670                 struct timespec n;
15671
15672
15673   ;
15674   return 0;
15675 }
15676 _ACEOF
15677 if ac_fn_c_try_compile "$LINENO"; then :
15678   ntp_cv_struct_timespec=yes
15679 else
15680   ntp_cv_struct_timespec=no
15681
15682 fi
15683 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15684
15685 fi
15686 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_struct_timespec" >&5
15687 $as_echo "$ntp_cv_struct_timespec" >&6; }
15688 case "$ntp_cv_struct_timespec" in
15689  yes)
15690
15691 $as_echo "#define HAVE_STRUCT_TIMESPEC 1" >>confdefs.h
15692
15693 esac
15694
15695 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct ntptimeval" >&5
15696 $as_echo_n "checking for struct ntptimeval... " >&6; }
15697 if ${ntp_cv_struct_ntptimeval+:} false; then :
15698   $as_echo_n "(cached) " >&6
15699 else
15700   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15701 /* end confdefs.h.  */
15702
15703                 #include <sys/time.h>
15704                 #include <sys/timex.h>
15705
15706 int
15707 main ()
15708 {
15709
15710                 struct ntptimeval n;
15711
15712
15713   ;
15714   return 0;
15715 }
15716 _ACEOF
15717 if ac_fn_c_try_compile "$LINENO"; then :
15718   ntp_cv_struct_ntptimeval=yes
15719 else
15720   ntp_cv_struct_ntptimeval=no
15721
15722 fi
15723 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15724
15725 fi
15726 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_struct_ntptimeval" >&5
15727 $as_echo "$ntp_cv_struct_ntptimeval" >&6; }
15728 case "$ntp_cv_struct_ntptimeval" in
15729  yes)
15730
15731 $as_echo "#define HAVE_STRUCT_NTPTIMEVAL 1" >>confdefs.h
15732
15733 esac
15734
15735 for ac_header in md5.h
15736 do :
15737   ac_fn_c_check_header_compile "$LINENO" "md5.h" "ac_cv_header_md5_h" "
15738         #ifdef HAVE_SYS_TYPES_H
15739         # include <sys/types.h>
15740         #endif
15741
15742
15743 "
15744 if test "x$ac_cv_header_md5_h" = xyes; then :
15745   cat >>confdefs.h <<_ACEOF
15746 #define HAVE_MD5_H 1
15747 _ACEOF
15748
15749 fi
15750
15751 done
15752
15753
15754 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing MD5Init" >&5
15755 $as_echo_n "checking for library containing MD5Init... " >&6; }
15756 if ${ac_cv_search_MD5Init+:} false; then :
15757   $as_echo_n "(cached) " >&6
15758 else
15759   ac_func_search_save_LIBS=$LIBS
15760 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15761 /* end confdefs.h.  */
15762
15763 /* Override any GCC internal prototype to avoid an error.
15764    Use char because int might match the return type of a GCC
15765    builtin and then its argument prototype would still apply.  */
15766 #ifdef __cplusplus
15767 extern "C"
15768 #endif
15769 char MD5Init ();
15770 int
15771 main ()
15772 {
15773 return MD5Init ();
15774   ;
15775   return 0;
15776 }
15777 _ACEOF
15778 for ac_lib in '' md5 md; do
15779   if test -z "$ac_lib"; then
15780     ac_res="none required"
15781   else
15782     ac_res=-l$ac_lib
15783     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
15784   fi
15785   if ac_fn_c_try_link "$LINENO"; then :
15786   ac_cv_search_MD5Init=$ac_res
15787 fi
15788 rm -f core conftest.err conftest.$ac_objext \
15789     conftest$ac_exeext
15790   if ${ac_cv_search_MD5Init+:} false; then :
15791   break
15792 fi
15793 done
15794 if ${ac_cv_search_MD5Init+:} false; then :
15795
15796 else
15797   ac_cv_search_MD5Init=no
15798 fi
15799 rm conftest.$ac_ext
15800 LIBS=$ac_func_search_save_LIBS
15801 fi
15802 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_MD5Init" >&5
15803 $as_echo "$ac_cv_search_MD5Init" >&6; }
15804 ac_res=$ac_cv_search_MD5Init
15805 if test "$ac_res" != no; then :
15806   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
15807
15808 fi
15809
15810 for ac_func in MD5Init sysconf getdtablesize sigaction sigset sigvec
15811 do :
15812   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15813 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15814 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
15815   cat >>confdefs.h <<_ACEOF
15816 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15817 _ACEOF
15818
15819 fi
15820 done
15821
15822
15823 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SIGIO" >&5
15824 $as_echo_n "checking for SIGIO... " >&6; }
15825 if ${ntp_cv_hdr_def_sigio+:} false; then :
15826   $as_echo_n "(cached) " >&6
15827 else
15828   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15829 /* end confdefs.h.  */
15830
15831             #include <signal.h>
15832
15833             #ifndef SIGIO
15834             # error
15835             #endif
15836
15837 _ACEOF
15838 if ac_fn_c_try_cpp "$LINENO"; then :
15839   ntp_cv_hdr_def_sigio=yes
15840 else
15841   ntp_cv_hdr_def_sigio=no
15842
15843 fi
15844 rm -f conftest.err conftest.i conftest.$ac_ext
15845
15846 fi
15847 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_hdr_def_sigio" >&5
15848 $as_echo "$ntp_cv_hdr_def_sigio" >&6; }
15849
15850 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we want to use SIGIO" >&5
15851 $as_echo_n "checking if we want to use SIGIO... " >&6; }
15852 ans=no
15853 case "$ntp_cv_hdr_def_sigio" in
15854  yes)
15855     ans=yes
15856     case "$host" in
15857      alpha*-dec-osf4*|alpha*-dec-osf5*)
15858         ans=no
15859         ;;
15860      *-convex-*)
15861         ans=no
15862         ;;
15863      *-dec-*)
15864         ans=no
15865         ;;
15866      *-pc-cygwin*)
15867         ans=no
15868         ;;
15869      *-sni-sysv*)
15870         ans=no
15871         ;;
15872      *-univel-sysv*)
15873         ans=no
15874         ;;
15875      *-*-irix6*)
15876         ans=no
15877         ;;
15878      *-*-freebsd*)
15879         ans=no
15880         ;;
15881      *-*-*linux*)
15882         ans=no
15883         ;;
15884      *-*-unicosmp*)
15885         ans=no
15886         ;;
15887      *-*-kfreebsd*)
15888         ans=no
15889         ;;
15890      m68k-*-mint*)
15891         ans=no
15892         ;;
15893     esac
15894     ;;
15895 esac
15896 case "$ans" in
15897  yes)
15898
15899 $as_echo "#define HAVE_SIGNALED_IO 1" >>confdefs.h
15900
15901 esac
15902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
15903 $as_echo "$ans" >&6; }
15904
15905 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SIGPOLL" >&5
15906 $as_echo_n "checking for SIGPOLL... " >&6; }
15907 if ${ntp_cv_hdr_def_sigpoll+:} false; then :
15908   $as_echo_n "(cached) " >&6
15909 else
15910   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15911 /* end confdefs.h.  */
15912
15913             #include <signal.h>
15914
15915             #ifndef SIGPOLL
15916             # error
15917             #endif
15918
15919 _ACEOF
15920 if ac_fn_c_try_cpp "$LINENO"; then :
15921   ntp_cv_hdr_def_sigpoll=yes
15922 else
15923   ntp_cv_hdr_def_sigpoll=no
15924
15925 fi
15926 rm -f conftest.err conftest.i conftest.$ac_ext
15927
15928 fi
15929 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_hdr_def_sigpoll" >&5
15930 $as_echo "$ntp_cv_hdr_def_sigpoll" >&6; }
15931
15932 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can use SIGPOLL for UDP I/O" >&5
15933 $as_echo_n "checking if we can use SIGPOLL for UDP I/O... " >&6; }
15934 ans=no
15935 case "$ntp_cv_hdr_def_sigpoll" in
15936  yes)
15937     case "$host" in
15938      mips-sgi-irix*)
15939         ans=no
15940         ;;
15941      vax-dec-bsd)
15942         ans=no
15943         ;;
15944      *-pc-cygwin*)
15945         ans=no
15946         ;;
15947      *-sni-sysv*)
15948         ans=no
15949         ;;
15950      *-*-aix[4-9]*)
15951         # XXX Only verified thru AIX6
15952         ans=no
15953         ;;
15954      *-*-hpux*)
15955         ans=no
15956         ;;
15957      *-*-*linux*)
15958         ans=no
15959         ;;
15960      *-*-osf*)
15961         ans=no
15962         ;;
15963      *-*-qnx*)
15964         ans=no
15965         ;;
15966      *-*-sunos*)
15967         ans=no
15968         ;;
15969      *-*-solaris*)
15970         ans=no
15971         ;;
15972      *-*-ultrix*)
15973         ans=no
15974         ;;
15975      *-*-unicosmp*)
15976         ans=no
15977         ;;
15978      *-*-kfreebsd*)
15979         ans=no
15980         ;;
15981      *) ans=yes
15982         ;;
15983     esac
15984     ;;
15985 esac
15986 case "$ans" in
15987  yes)
15988
15989 $as_echo "#define USE_UDP_SIGPOLL 1" >>confdefs.h
15990
15991 esac
15992 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
15993 $as_echo "$ans" >&6; }
15994
15995 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can use SIGPOLL for TTY I/O" >&5
15996 $as_echo_n "checking if we can use SIGPOLL for TTY I/O... " >&6; }
15997 ans=no
15998 case "$ntp_cv_hdr_def_sigpoll" in
15999  yes)
16000     case "$host" in
16001      mips-sgi-irix*)
16002         ans=no
16003         ;;
16004      vax-dec-bsd)
16005         ans=no
16006         ;;
16007      *-pc-cygwin*)
16008         ans=no
16009         ;;
16010      *-sni-sysv*)
16011         ans=no
16012         ;;
16013      *-*-aix[4-9]*)
16014         # XXX Only verified thru AIX6
16015         ans=no
16016         ;;
16017      *-*-hpux*)
16018         ans=no
16019         ;;
16020      *-*-*linux*)
16021         ans=no
16022         ;;
16023      *-*-osf*)
16024         ans=no
16025         ;;
16026      *-*-sunos*)
16027         ans=no
16028         ;;
16029      *-*-ultrix*)
16030         ans=no
16031         ;;
16032      *-*-qnx*)
16033         ans=no
16034         ;;
16035      *-*-unicosmp*)
16036         ans=no
16037         ;;
16038      *-*-kfreebsd*)
16039         ans=no
16040         ;;
16041      *) ans=yes
16042         ;;
16043     esac
16044     ;;
16045 esac
16046 case "$ans" in
16047  yes)
16048
16049 $as_echo "#define USE_TTY_SIGPOLL 1" >>confdefs.h
16050
16051 esac
16052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
16053 $as_echo "$ans" >&6; }
16054
16055 { $as_echo "$as_me:${as_lineno-$LINENO}: checking number of arguments to gettimeofday()" >&5
16056 $as_echo_n "checking number of arguments to gettimeofday()... " >&6; }
16057 if ${ntp_cv_func_Xettimeofday_nargs+:} false; then :
16058   $as_echo_n "(cached) " >&6
16059 else
16060   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16061 /* end confdefs.h.  */
16062
16063                 #include <sys/time.h>
16064
16065 int
16066 main ()
16067 {
16068
16069                 gettimeofday(0, 0);
16070                 settimeofday(0, 0);
16071
16072
16073   ;
16074   return 0;
16075 }
16076 _ACEOF
16077 if ac_fn_c_try_compile "$LINENO"; then :
16078   ntp_cv_func_Xettimeofday_nargs=2
16079 else
16080   ntp_cv_func_Xettimeofday_nargs=1
16081
16082 fi
16083 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16084
16085 fi
16086 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_func_Xettimeofday_nargs" >&5
16087 $as_echo "$ntp_cv_func_Xettimeofday_nargs" >&6; }
16088 case "$ntp_cv_func_Xettimeofday_nargs" in
16089  1)
16090
16091 $as_echo "#define SYSV_TIMEOFDAY 1" >>confdefs.h
16092
16093 esac
16094
16095 for ac_func in settimeofday
16096 do :
16097   ac_fn_c_check_func "$LINENO" "settimeofday" "ac_cv_func_settimeofday"
16098 if test "x$ac_cv_func_settimeofday" = xyes; then :
16099   cat >>confdefs.h <<_ACEOF
16100 #define HAVE_SETTIMEOFDAY 1
16101 _ACEOF
16102
16103 else
16104
16105     case "$host" in
16106      *-*-mpeix*) ac_cv_func_settimeofday=yes
16107     esac
16108
16109 fi
16110 done
16111
16112
16113 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we'll use clock_settime or settimeofday or stime" >&5
16114 $as_echo_n "checking if we'll use clock_settime or settimeofday or stime... " >&6; }
16115 ntp_warning='GRONK'
16116 ans=none
16117 case "$ac_cv_func_clock_settime$ac_cv_func_settimeofday$ac_cv_func_stime" in
16118  yes*)
16119     ntp_warning=''
16120     ans='clock_settime()'
16121     ;;
16122  noyes*)
16123     ntp_warning='But clock_settime() would be better (if we had it)'
16124     ans='settimeofday()'
16125     ;;
16126  nonoyes)
16127     ntp_warning='Which is the worst of the three'
16128     ans='stime()'
16129     ;;
16130  *)
16131     case "$build" in
16132      $host)
16133         ntp_warning='Which leaves us with nothing to use!'
16134     esac
16135 esac
16136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ans" >&5
16137 $as_echo "$ans" >&6; }
16138 case "$ntp_warning" in
16139  '')
16140     ;;
16141  *)
16142     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** $ntp_warning ***" >&5
16143 $as_echo "$as_me: WARNING: *** $ntp_warning ***" >&2;}
16144     ;;
16145 esac
16146
16147
16148 LDADD_LIBNTP="$LDADD_LIBNTP $LIBS"
16149 LIBS=$__LIBS
16150 { __LIBS=; unset __LIBS;}
16151
16152
16153
16154 # Check whether --enable-shared was given.
16155 if test "${enable_shared+set}" = set; then :
16156   enableval=$enable_shared; p=${PACKAGE-default}
16157     case $enableval in
16158     yes) enable_shared=yes ;;
16159     no) enable_shared=no ;;
16160     *)
16161       enable_shared=no
16162       # Look at the argument we got.  We use all the common list separators.
16163       lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
16164       for pkg in $enableval; do
16165         IFS="$lt_save_ifs"
16166         if test "X$pkg" = "X$p"; then
16167           enable_shared=yes
16168         fi
16169       done
16170       IFS="$lt_save_ifs"
16171       ;;
16172     esac
16173 else
16174   enable_shared=no
16175 fi
16176
16177
16178
16179
16180
16181
16182
16183
16184
16185 case `pwd` in
16186   *\ * | *\     *)
16187     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5
16188 $as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;;
16189 esac
16190
16191
16192
16193 macro_version='2.4'
16194 macro_revision='1.3293'
16195
16196
16197
16198
16199
16200
16201
16202
16203
16204
16205
16206
16207
16208 ltmain="$ac_aux_dir/ltmain.sh"
16209
16210 # Backslashify metacharacters that are still active within
16211 # double-quoted strings.
16212 sed_quote_subst='s/\(["`$\\]\)/\\\1/g'
16213
16214 # Same as above, but do not quote variable references.
16215 double_quote_subst='s/\(["`\\]\)/\\\1/g'
16216
16217 # Sed substitution to delay expansion of an escaped shell variable in a
16218 # double_quote_subst'ed string.
16219 delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
16220
16221 # Sed substitution to delay expansion of an escaped single quote.
16222 delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
16223
16224 # Sed substitution to avoid accidental globbing in evaled expressions
16225 no_glob_subst='s/\*/\\\*/g'
16226
16227 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5
16228 $as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; }
16229 if ${lt_cv_path_NM+:} false; then :
16230   $as_echo_n "(cached) " >&6
16231 else
16232   if test -n "$NM"; then
16233   # Let the user override the test.
16234   lt_cv_path_NM="$NM"
16235 else
16236   lt_nm_to_check="${ac_tool_prefix}nm"
16237   if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
16238     lt_nm_to_check="$lt_nm_to_check nm"
16239   fi
16240   for lt_tmp_nm in $lt_nm_to_check; do
16241     lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
16242     for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
16243       IFS="$lt_save_ifs"
16244       test -z "$ac_dir" && ac_dir=.
16245       tmp_nm="$ac_dir/$lt_tmp_nm"
16246       if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
16247         # Check to see if the nm accepts a BSD-compat flag.
16248         # Adding the `sed 1q' prevents false positives on HP-UX, which says:
16249         #   nm: unknown option "B" ignored
16250         # Tru64's nm complains that /dev/null is an invalid object file
16251         case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
16252         */dev/null* | *'Invalid file or object type'*)
16253           lt_cv_path_NM="$tmp_nm -B"
16254           break
16255           ;;
16256         *)
16257           case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
16258           */dev/null*)
16259             lt_cv_path_NM="$tmp_nm -p"
16260             break
16261             ;;
16262           *)
16263             lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
16264             continue # so that we can try to find one that supports BSD flags
16265             ;;
16266           esac
16267           ;;
16268         esac
16269       fi
16270     done
16271     IFS="$lt_save_ifs"
16272   done
16273   : ${lt_cv_path_NM=no}
16274 fi
16275 fi
16276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5
16277 $as_echo "$lt_cv_path_NM" >&6; }
16278 if test "$lt_cv_path_NM" != "no"; then
16279   NM="$lt_cv_path_NM"
16280 else
16281   # Didn't find any BSD compatible name lister, look for dumpbin.
16282   if test -n "$DUMPBIN"; then :
16283     # Let the user override the test.
16284   else
16285     if test -n "$ac_tool_prefix"; then
16286   for ac_prog in dumpbin "link -dump"
16287   do
16288     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
16289 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
16290 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16291 $as_echo_n "checking for $ac_word... " >&6; }
16292 if ${ac_cv_prog_DUMPBIN+:} false; then :
16293   $as_echo_n "(cached) " >&6
16294 else
16295   if test -n "$DUMPBIN"; then
16296   ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test.
16297 else
16298 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16299 for as_dir in $PATH
16300 do
16301   IFS=$as_save_IFS
16302   test -z "$as_dir" && as_dir=.
16303     for ac_exec_ext in '' $ac_executable_extensions; do
16304   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
16305     ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog"
16306     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16307     break 2
16308   fi
16309 done
16310   done
16311 IFS=$as_save_IFS
16312
16313 fi
16314 fi
16315 DUMPBIN=$ac_cv_prog_DUMPBIN
16316 if test -n "$DUMPBIN"; then
16317   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5
16318 $as_echo "$DUMPBIN" >&6; }
16319 else
16320   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16321 $as_echo "no" >&6; }
16322 fi
16323
16324
16325     test -n "$DUMPBIN" && break
16326   done
16327 fi
16328 if test -z "$DUMPBIN"; then
16329   ac_ct_DUMPBIN=$DUMPBIN
16330   for ac_prog in dumpbin "link -dump"
16331 do
16332   # Extract the first word of "$ac_prog", so it can be a program name with args.
16333 set dummy $ac_prog; ac_word=$2
16334 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16335 $as_echo_n "checking for $ac_word... " >&6; }
16336 if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then :
16337   $as_echo_n "(cached) " >&6
16338 else
16339   if test -n "$ac_ct_DUMPBIN"; then
16340   ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test.
16341 else
16342 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16343 for as_dir in $PATH
16344 do
16345   IFS=$as_save_IFS
16346   test -z "$as_dir" && as_dir=.
16347     for ac_exec_ext in '' $ac_executable_extensions; do
16348   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
16349     ac_cv_prog_ac_ct_DUMPBIN="$ac_prog"
16350     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16351     break 2
16352   fi
16353 done
16354   done
16355 IFS=$as_save_IFS
16356
16357 fi
16358 fi
16359 ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN
16360 if test -n "$ac_ct_DUMPBIN"; then
16361   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5
16362 $as_echo "$ac_ct_DUMPBIN" >&6; }
16363 else
16364   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16365 $as_echo "no" >&6; }
16366 fi
16367
16368
16369   test -n "$ac_ct_DUMPBIN" && break
16370 done
16371
16372   if test "x$ac_ct_DUMPBIN" = x; then
16373     DUMPBIN=":"
16374   else
16375     case $cross_compiling:$ac_tool_warned in
16376 yes:)
16377 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
16378 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
16379 ac_tool_warned=yes ;;
16380 esac
16381     DUMPBIN=$ac_ct_DUMPBIN
16382   fi
16383 fi
16384
16385     case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in
16386     *COFF*)
16387       DUMPBIN="$DUMPBIN -symbols"
16388       ;;
16389     *)
16390       DUMPBIN=:
16391       ;;
16392     esac
16393   fi
16394
16395   if test "$DUMPBIN" != ":"; then
16396     NM="$DUMPBIN"
16397   fi
16398 fi
16399 test -z "$NM" && NM=nm
16400
16401
16402
16403
16404
16405
16406 { $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5
16407 $as_echo_n "checking the name lister ($NM) interface... " >&6; }
16408 if ${lt_cv_nm_interface+:} false; then :
16409   $as_echo_n "(cached) " >&6
16410 else
16411   lt_cv_nm_interface="BSD nm"
16412   echo "int some_variable = 0;" > conftest.$ac_ext
16413   (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5)
16414   (eval "$ac_compile" 2>conftest.err)
16415   cat conftest.err >&5
16416   (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
16417   (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
16418   cat conftest.err >&5
16419   (eval echo "\"\$as_me:$LINENO: output\"" >&5)
16420   cat conftest.out >&5
16421   if $GREP 'External.*some_variable' conftest.out > /dev/null; then
16422     lt_cv_nm_interface="MS dumpbin"
16423   fi
16424   rm -f conftest*
16425 fi
16426 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5
16427 $as_echo "$lt_cv_nm_interface" >&6; }
16428
16429 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
16430 $as_echo_n "checking whether ln -s works... " >&6; }
16431 LN_S=$as_ln_s
16432 if test "$LN_S" = "ln -s"; then
16433   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16434 $as_echo "yes" >&6; }
16435 else
16436   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
16437 $as_echo "no, using $LN_S" >&6; }
16438 fi
16439
16440 # find the maximum length of command line arguments
16441 { $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5
16442 $as_echo_n "checking the maximum length of command line arguments... " >&6; }
16443 if ${lt_cv_sys_max_cmd_len+:} false; then :
16444   $as_echo_n "(cached) " >&6
16445 else
16446     i=0
16447   teststring="ABCD"
16448
16449   case $build_os in
16450   msdosdjgpp*)
16451     # On DJGPP, this test can blow up pretty badly due to problems in libc
16452     # (any single argument exceeding 2000 bytes causes a buffer overrun
16453     # during glob expansion).  Even if it were fixed, the result of this
16454     # check would be larger than it should be.
16455     lt_cv_sys_max_cmd_len=12288;    # 12K is about right
16456     ;;
16457
16458   gnu*)
16459     # Under GNU Hurd, this test is not required because there is
16460     # no limit to the length of command line arguments.
16461     # Libtool will interpret -1 as no limit whatsoever
16462     lt_cv_sys_max_cmd_len=-1;
16463     ;;
16464
16465   cygwin* | mingw* | cegcc*)
16466     # On Win9x/ME, this test blows up -- it succeeds, but takes
16467     # about 5 minutes as the teststring grows exponentially.
16468     # Worse, since 9x/ME are not pre-emptively multitasking,
16469     # you end up with a "frozen" computer, even though with patience
16470     # the test eventually succeeds (with a max line length of 256k).
16471     # Instead, let's just punt: use the minimum linelength reported by
16472     # all of the supported platforms: 8192 (on NT/2K/XP).
16473     lt_cv_sys_max_cmd_len=8192;
16474     ;;
16475
16476   mint*)
16477     # On MiNT this can take a long time and run out of memory.
16478     lt_cv_sys_max_cmd_len=8192;
16479     ;;
16480
16481   amigaos*)
16482     # On AmigaOS with pdksh, this test takes hours, literally.
16483     # So we just punt and use a minimum line length of 8192.
16484     lt_cv_sys_max_cmd_len=8192;
16485     ;;
16486
16487   netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
16488     # This has been around since 386BSD, at least.  Likely further.
16489     if test -x /sbin/sysctl; then
16490       lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
16491     elif test -x /usr/sbin/sysctl; then
16492       lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
16493     else
16494       lt_cv_sys_max_cmd_len=65536       # usable default for all BSDs
16495     fi
16496     # And add a safety zone
16497     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
16498     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
16499     ;;
16500
16501   interix*)
16502     # We know the value 262144 and hardcode it with a safety zone (like BSD)
16503     lt_cv_sys_max_cmd_len=196608
16504     ;;
16505
16506   osf*)
16507     # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
16508     # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
16509     # nice to cause kernel panics so lets avoid the loop below.
16510     # First set a reasonable default.
16511     lt_cv_sys_max_cmd_len=16384
16512     #
16513     if test -x /sbin/sysconfig; then
16514       case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
16515         *1*) lt_cv_sys_max_cmd_len=-1 ;;
16516       esac
16517     fi
16518     ;;
16519   sco3.2v5*)
16520     lt_cv_sys_max_cmd_len=102400
16521     ;;
16522   sysv5* | sco5v6* | sysv4.2uw2*)
16523     kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
16524     if test -n "$kargmax"; then
16525       lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[  ]//'`
16526     else
16527       lt_cv_sys_max_cmd_len=32768
16528     fi
16529     ;;
16530   *)
16531     lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
16532     if test -n "$lt_cv_sys_max_cmd_len"; then
16533       lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
16534       lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
16535     else
16536       # Make teststring a little bigger before we do anything with it.
16537       # a 1K string should be a reasonable start.
16538       for i in 1 2 3 4 5 6 7 8 ; do
16539         teststring=$teststring$teststring
16540       done
16541       SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
16542       # If test is not a shell built-in, we'll probably end up computing a
16543       # maximum length that is only half of the actual maximum length, but
16544       # we can't tell.
16545       while { test "X"`func_fallback_echo "$teststring$teststring" 2>/dev/null` \
16546                  = "X$teststring$teststring"; } >/dev/null 2>&1 &&
16547               test $i != 17 # 1/2 MB should be enough
16548       do
16549         i=`expr $i + 1`
16550         teststring=$teststring$teststring
16551       done
16552       # Only check the string length outside the loop.
16553       lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
16554       teststring=
16555       # Add a significant safety factor because C++ compilers can tack on
16556       # massive amounts of additional arguments before passing them to the
16557       # linker.  It appears as though 1/2 is a usable value.
16558       lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
16559     fi
16560     ;;
16561   esac
16562
16563 fi
16564
16565 if test -n $lt_cv_sys_max_cmd_len ; then
16566   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5
16567 $as_echo "$lt_cv_sys_max_cmd_len" >&6; }
16568 else
16569   { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5
16570 $as_echo "none" >&6; }
16571 fi
16572 max_cmd_len=$lt_cv_sys_max_cmd_len
16573
16574
16575
16576
16577
16578
16579 : ${CP="cp -f"}
16580 : ${MV="mv -f"}
16581 : ${RM="rm -f"}
16582
16583 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands some XSI constructs" >&5
16584 $as_echo_n "checking whether the shell understands some XSI constructs... " >&6; }
16585 # Try some XSI features
16586 xsi_shell=no
16587 ( _lt_dummy="a/b/c"
16588   test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \
16589       = c,a/b,b/c, \
16590     && eval 'test $(( 1 + 1 )) -eq 2 \
16591     && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
16592   && xsi_shell=yes
16593 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $xsi_shell" >&5
16594 $as_echo "$xsi_shell" >&6; }
16595
16596
16597 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands \"+=\"" >&5
16598 $as_echo_n "checking whether the shell understands \"+=\"... " >&6; }
16599 lt_shell_append=no
16600 ( foo=bar; set foo baz; eval "$1+=\$2" && test "$foo" = barbaz ) \
16601     >/dev/null 2>&1 \
16602   && lt_shell_append=yes
16603 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_shell_append" >&5
16604 $as_echo "$lt_shell_append" >&6; }
16605
16606
16607 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
16608   lt_unset=unset
16609 else
16610   lt_unset=false
16611 fi
16612
16613
16614
16615
16616
16617 # test EBCDIC or ASCII
16618 case `echo X|tr X '\101'` in
16619  A) # ASCII based system
16620     # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
16621   lt_SP2NL='tr \040 \012'
16622   lt_NL2SP='tr \015\012 \040\040'
16623   ;;
16624  *) # EBCDIC based system
16625   lt_SP2NL='tr \100 \n'
16626   lt_NL2SP='tr \r\n \100\100'
16627   ;;
16628 esac
16629
16630
16631
16632
16633
16634
16635
16636
16637
16638 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to $host format" >&5
16639 $as_echo_n "checking how to convert $build file names to $host format... " >&6; }
16640 if ${lt_cv_to_host_file_cmd+:} false; then :
16641   $as_echo_n "(cached) " >&6
16642 else
16643   case $host in
16644   *-*-mingw* )
16645     case $build in
16646       *-*-mingw* ) # actually msys
16647         lt_cv_to_host_file_cmd=func_convert_file_msys_to_w32
16648         ;;
16649       *-*-cygwin* )
16650         lt_cv_to_host_file_cmd=func_convert_file_cygwin_to_w32
16651         ;;
16652       * ) # otherwise, assume *nix
16653         lt_cv_to_host_file_cmd=func_convert_file_nix_to_w32
16654         ;;
16655     esac
16656     ;;
16657   *-*-cygwin* )
16658     case $build in
16659       *-*-mingw* ) # actually msys
16660         lt_cv_to_host_file_cmd=func_convert_file_msys_to_cygwin
16661         ;;
16662       *-*-cygwin* )
16663         lt_cv_to_host_file_cmd=func_convert_file_noop
16664         ;;
16665       * ) # otherwise, assume *nix
16666         lt_cv_to_host_file_cmd=func_convert_file_nix_to_cygwin
16667         ;;
16668     esac
16669     ;;
16670   * ) # unhandled hosts (and "normal" native builds)
16671     lt_cv_to_host_file_cmd=func_convert_file_noop
16672     ;;
16673 esac
16674
16675 fi
16676
16677 to_host_file_cmd=$lt_cv_to_host_file_cmd
16678 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_host_file_cmd" >&5
16679 $as_echo "$lt_cv_to_host_file_cmd" >&6; }
16680
16681
16682
16683
16684
16685 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to convert $build file names to toolchain format" >&5
16686 $as_echo_n "checking how to convert $build file names to toolchain format... " >&6; }
16687 if ${lt_cv_to_tool_file_cmd+:} false; then :
16688   $as_echo_n "(cached) " >&6
16689 else
16690   #assume ordinary cross tools, or native build.
16691 lt_cv_to_tool_file_cmd=func_convert_file_noop
16692 case $host in
16693   *-*-mingw* )
16694     case $build in
16695       *-*-mingw* ) # actually msys
16696         lt_cv_to_tool_file_cmd=func_convert_file_msys_to_w32
16697         ;;
16698     esac
16699     ;;
16700 esac
16701
16702 fi
16703
16704 to_tool_file_cmd=$lt_cv_to_tool_file_cmd
16705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_to_tool_file_cmd" >&5
16706 $as_echo "$lt_cv_to_tool_file_cmd" >&6; }
16707
16708
16709
16710
16711
16712 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
16713 $as_echo_n "checking for $LD option to reload object files... " >&6; }
16714 if ${lt_cv_ld_reload_flag+:} false; then :
16715   $as_echo_n "(cached) " >&6
16716 else
16717   lt_cv_ld_reload_flag='-r'
16718 fi
16719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5
16720 $as_echo "$lt_cv_ld_reload_flag" >&6; }
16721 reload_flag=$lt_cv_ld_reload_flag
16722 case $reload_flag in
16723 "" | " "*) ;;
16724 *) reload_flag=" $reload_flag" ;;
16725 esac
16726 reload_cmds='$LD$reload_flag -o $output$reload_objs'
16727 case $host_os in
16728   cygwin* | mingw* | pw32* | cegcc*)
16729     if test "$GCC" != yes; then
16730       reload_cmds=false
16731     fi
16732     ;;
16733   darwin*)
16734     if test "$GCC" = yes; then
16735       reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
16736     else
16737       reload_cmds='$LD$reload_flag -o $output$reload_objs'
16738     fi
16739     ;;
16740 esac
16741
16742
16743
16744
16745
16746
16747
16748
16749
16750 if test -n "$ac_tool_prefix"; then
16751   # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
16752 set dummy ${ac_tool_prefix}objdump; ac_word=$2
16753 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16754 $as_echo_n "checking for $ac_word... " >&6; }
16755 if ${ac_cv_prog_OBJDUMP+:} false; then :
16756   $as_echo_n "(cached) " >&6
16757 else
16758   if test -n "$OBJDUMP"; then
16759   ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
16760 else
16761 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16762 for as_dir in $PATH
16763 do
16764   IFS=$as_save_IFS
16765   test -z "$as_dir" && as_dir=.
16766     for ac_exec_ext in '' $ac_executable_extensions; do
16767   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
16768     ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
16769     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16770     break 2
16771   fi
16772 done
16773   done
16774 IFS=$as_save_IFS
16775
16776 fi
16777 fi
16778 OBJDUMP=$ac_cv_prog_OBJDUMP
16779 if test -n "$OBJDUMP"; then
16780   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
16781 $as_echo "$OBJDUMP" >&6; }
16782 else
16783   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16784 $as_echo "no" >&6; }
16785 fi
16786
16787
16788 fi
16789 if test -z "$ac_cv_prog_OBJDUMP"; then
16790   ac_ct_OBJDUMP=$OBJDUMP
16791   # Extract the first word of "objdump", so it can be a program name with args.
16792 set dummy objdump; ac_word=$2
16793 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16794 $as_echo_n "checking for $ac_word... " >&6; }
16795 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
16796   $as_echo_n "(cached) " >&6
16797 else
16798   if test -n "$ac_ct_OBJDUMP"; then
16799   ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
16800 else
16801 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16802 for as_dir in $PATH
16803 do
16804   IFS=$as_save_IFS
16805   test -z "$as_dir" && as_dir=.
16806     for ac_exec_ext in '' $ac_executable_extensions; do
16807   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
16808     ac_cv_prog_ac_ct_OBJDUMP="objdump"
16809     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
16810     break 2
16811   fi
16812 done
16813   done
16814 IFS=$as_save_IFS
16815
16816 fi
16817 fi
16818 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
16819 if test -n "$ac_ct_OBJDUMP"; then
16820   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
16821 $as_echo "$ac_ct_OBJDUMP" >&6; }
16822 else
16823   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16824 $as_echo "no" >&6; }
16825 fi
16826
16827   if test "x$ac_ct_OBJDUMP" = x; then
16828     OBJDUMP="false"
16829   else
16830     case $cross_compiling:$ac_tool_warned in
16831 yes:)
16832 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
16833 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
16834 ac_tool_warned=yes ;;
16835 esac
16836     OBJDUMP=$ac_ct_OBJDUMP
16837   fi
16838 else
16839   OBJDUMP="$ac_cv_prog_OBJDUMP"
16840 fi
16841
16842 test -z "$OBJDUMP" && OBJDUMP=objdump
16843
16844
16845
16846
16847
16848
16849
16850
16851
16852 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5
16853 $as_echo_n "checking how to recognize dependent libraries... " >&6; }
16854 if ${lt_cv_deplibs_check_method+:} false; then :
16855   $as_echo_n "(cached) " >&6
16856 else
16857   lt_cv_file_magic_cmd='$MAGIC_CMD'
16858 lt_cv_file_magic_test_file=
16859 lt_cv_deplibs_check_method='unknown'
16860 # Need to set the preceding variable on all platforms that support
16861 # interlibrary dependencies.
16862 # 'none' -- dependencies not supported.
16863 # `unknown' -- same as none, but documents that we really don't know.
16864 # 'pass_all' -- all dependencies passed with no checks.
16865 # 'test_compile' -- check by making test program.
16866 # 'file_magic [[regex]]' -- check by looking for files in library path
16867 # which responds to the $file_magic_cmd with a given extended regex.
16868 # If you have `file' or equivalent on your system and you're not sure
16869 # whether `pass_all' will *always* work, you probably want this one.
16870
16871 case $host_os in
16872 aix[4-9]*)
16873   lt_cv_deplibs_check_method=pass_all
16874   ;;
16875
16876 beos*)
16877   lt_cv_deplibs_check_method=pass_all
16878   ;;
16879
16880 bsdi[45]*)
16881   lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
16882   lt_cv_file_magic_cmd='/usr/bin/file -L'
16883   lt_cv_file_magic_test_file=/shlib/libc.so
16884   ;;
16885
16886 cygwin*)
16887   # func_win32_libid is a shell function defined in ltmain.sh
16888   lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
16889   lt_cv_file_magic_cmd='func_win32_libid'
16890   ;;
16891
16892 mingw* | pw32*)
16893   # Base MSYS/MinGW do not provide the 'file' command needed by
16894   # func_win32_libid shell function, so use a weaker test based on 'objdump',
16895   # unless we find 'file', for example because we are cross-compiling.
16896   # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin.
16897   if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then
16898     lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
16899     lt_cv_file_magic_cmd='func_win32_libid'
16900   else
16901     # Keep this pattern in sync with the one in func_win32_libid.
16902     lt_cv_deplibs_check_method='file_magic file format (pei*-i386(.*architecture: i386)?|pe-arm-wince|pe-x86-64)'
16903     lt_cv_file_magic_cmd='$OBJDUMP -f'
16904   fi
16905   ;;
16906
16907 cegcc*)
16908   # use the weaker test based on 'objdump'. See mingw*.
16909   lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
16910   lt_cv_file_magic_cmd='$OBJDUMP -f'
16911   ;;
16912
16913 darwin* | rhapsody*)
16914   lt_cv_deplibs_check_method=pass_all
16915   ;;
16916
16917 freebsd* | dragonfly*)
16918   if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
16919     case $host_cpu in
16920     i*86 )
16921       # Not sure whether the presence of OpenBSD here was a mistake.
16922       # Let's accept both of them until this is cleared up.
16923       lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library'
16924       lt_cv_file_magic_cmd=/usr/bin/file
16925       lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
16926       ;;
16927     esac
16928   else
16929     lt_cv_deplibs_check_method=pass_all
16930   fi
16931   ;;
16932
16933 gnu*)
16934   lt_cv_deplibs_check_method=pass_all
16935   ;;
16936
16937 haiku*)
16938   lt_cv_deplibs_check_method=pass_all
16939   ;;
16940
16941 hpux10.20* | hpux11*)
16942   lt_cv_file_magic_cmd=/usr/bin/file
16943   case $host_cpu in
16944   ia64*)
16945     lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
16946     lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
16947     ;;
16948   hppa*64*)
16949     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]'
16950     lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
16951     ;;
16952   *)
16953     lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library'
16954     lt_cv_file_magic_test_file=/usr/lib/libc.sl
16955     ;;
16956   esac
16957   ;;
16958
16959 interix[3-9]*)
16960   # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
16961   lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$'
16962   ;;
16963
16964 irix5* | irix6* | nonstopux*)
16965   case $LD in
16966   *-32|*"-32 ") libmagic=32-bit;;
16967   *-n32|*"-n32 ") libmagic=N32;;
16968   *-64|*"-64 ") libmagic=64-bit;;
16969   *) libmagic=never-match;;
16970   esac
16971   lt_cv_deplibs_check_method=pass_all
16972   ;;
16973
16974 # This must be Linux ELF.
16975 linux* | k*bsd*-gnu | kopensolaris*-gnu)
16976   lt_cv_deplibs_check_method=pass_all
16977   ;;
16978
16979 netbsd*)
16980   if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
16981     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
16982   else
16983     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$'
16984   fi
16985   ;;
16986
16987 newos6*)
16988   lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
16989   lt_cv_file_magic_cmd=/usr/bin/file
16990   lt_cv_file_magic_test_file=/usr/lib/libnls.so
16991   ;;
16992
16993 *nto* | *qnx*)
16994   lt_cv_deplibs_check_method=pass_all
16995   ;;
16996
16997 openbsd*)
16998   if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
16999     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$'
17000   else
17001     lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
17002   fi
17003   ;;
17004
17005 osf3* | osf4* | osf5*)
17006   lt_cv_deplibs_check_method=pass_all
17007   ;;
17008
17009 rdos*)
17010   lt_cv_deplibs_check_method=pass_all
17011   ;;
17012
17013 solaris*)
17014   lt_cv_deplibs_check_method=pass_all
17015   ;;
17016
17017 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
17018   lt_cv_deplibs_check_method=pass_all
17019   ;;
17020
17021 sysv4 | sysv4.3*)
17022   case $host_vendor in
17023   motorola)
17024     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]'
17025     lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
17026     ;;
17027   ncr)
17028     lt_cv_deplibs_check_method=pass_all
17029     ;;
17030   sequent)
17031     lt_cv_file_magic_cmd='/bin/file'
17032     lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
17033     ;;
17034   sni)
17035     lt_cv_file_magic_cmd='/bin/file'
17036     lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
17037     lt_cv_file_magic_test_file=/lib/libc.so
17038     ;;
17039   siemens)
17040     lt_cv_deplibs_check_method=pass_all
17041     ;;
17042   pc)
17043     lt_cv_deplibs_check_method=pass_all
17044     ;;
17045   esac
17046   ;;
17047
17048 tpf*)
17049   lt_cv_deplibs_check_method=pass_all
17050   ;;
17051 esac
17052
17053 fi
17054 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
17055 $as_echo "$lt_cv_deplibs_check_method" >&6; }
17056
17057 file_magic_glob=
17058 want_nocaseglob=no
17059 if test "$build" = "$host"; then
17060   case $host_os in
17061   mingw* | pw32*)
17062     if ( shopt | grep nocaseglob ) >/dev/null 2>&1; then
17063       want_nocaseglob=yes
17064     else
17065       file_magic_glob=`echo aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ | $SED -e "s/\(..\)/s\/[\1]\/[\1]\/g;/g"`
17066     fi
17067     ;;
17068   esac
17069 fi
17070
17071 file_magic_cmd=$lt_cv_file_magic_cmd
17072 deplibs_check_method=$lt_cv_deplibs_check_method
17073 test -z "$deplibs_check_method" && deplibs_check_method=unknown
17074
17075
17076
17077
17078
17079
17080
17081
17082
17083
17084
17085
17086
17087
17088
17089
17090
17091
17092
17093
17094
17095
17096 if test -n "$ac_tool_prefix"; then
17097   # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
17098 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
17099 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17100 $as_echo_n "checking for $ac_word... " >&6; }
17101 if ${ac_cv_prog_DLLTOOL+:} false; then :
17102   $as_echo_n "(cached) " >&6
17103 else
17104   if test -n "$DLLTOOL"; then
17105   ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
17106 else
17107 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17108 for as_dir in $PATH
17109 do
17110   IFS=$as_save_IFS
17111   test -z "$as_dir" && as_dir=.
17112     for ac_exec_ext in '' $ac_executable_extensions; do
17113   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
17114     ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
17115     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17116     break 2
17117   fi
17118 done
17119   done
17120 IFS=$as_save_IFS
17121
17122 fi
17123 fi
17124 DLLTOOL=$ac_cv_prog_DLLTOOL
17125 if test -n "$DLLTOOL"; then
17126   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
17127 $as_echo "$DLLTOOL" >&6; }
17128 else
17129   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17130 $as_echo "no" >&6; }
17131 fi
17132
17133
17134 fi
17135 if test -z "$ac_cv_prog_DLLTOOL"; then
17136   ac_ct_DLLTOOL=$DLLTOOL
17137   # Extract the first word of "dlltool", so it can be a program name with args.
17138 set dummy dlltool; ac_word=$2
17139 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17140 $as_echo_n "checking for $ac_word... " >&6; }
17141 if ${ac_cv_prog_ac_ct_DLLTOOL+:} false; then :
17142   $as_echo_n "(cached) " >&6
17143 else
17144   if test -n "$ac_ct_DLLTOOL"; then
17145   ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
17146 else
17147 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17148 for as_dir in $PATH
17149 do
17150   IFS=$as_save_IFS
17151   test -z "$as_dir" && as_dir=.
17152     for ac_exec_ext in '' $ac_executable_extensions; do
17153   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
17154     ac_cv_prog_ac_ct_DLLTOOL="dlltool"
17155     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17156     break 2
17157   fi
17158 done
17159   done
17160 IFS=$as_save_IFS
17161
17162 fi
17163 fi
17164 ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
17165 if test -n "$ac_ct_DLLTOOL"; then
17166   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DLLTOOL" >&5
17167 $as_echo "$ac_ct_DLLTOOL" >&6; }
17168 else
17169   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17170 $as_echo "no" >&6; }
17171 fi
17172
17173   if test "x$ac_ct_DLLTOOL" = x; then
17174     DLLTOOL="false"
17175   else
17176     case $cross_compiling:$ac_tool_warned in
17177 yes:)
17178 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
17179 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
17180 ac_tool_warned=yes ;;
17181 esac
17182     DLLTOOL=$ac_ct_DLLTOOL
17183   fi
17184 else
17185   DLLTOOL="$ac_cv_prog_DLLTOOL"
17186 fi
17187
17188 test -z "$DLLTOOL" && DLLTOOL=dlltool
17189
17190
17191
17192
17193
17194
17195
17196
17197
17198
17199 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to associate runtime and link libraries" >&5
17200 $as_echo_n "checking how to associate runtime and link libraries... " >&6; }
17201 if ${lt_cv_sharedlib_from_linklib_cmd+:} false; then :
17202   $as_echo_n "(cached) " >&6
17203 else
17204   lt_cv_sharedlib_from_linklib_cmd='unknown'
17205
17206 case $host_os in
17207 cygwin* | mingw* | pw32* | cegcc*)
17208   # two different shell functions defined in ltmain.sh
17209   # decide which to use based on capabilities of $DLLTOOL
17210   case `$DLLTOOL --help 2>&1` in
17211   *--identify-strict*)
17212     lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib
17213     ;;
17214   *)
17215     lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib_fallback
17216     ;;
17217   esac
17218   ;;
17219 *)
17220   # fallback: assume linklib IS sharedlib
17221   lt_cv_sharedlib_from_linklib_cmd="$ECHO"
17222   ;;
17223 esac
17224
17225 fi
17226 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sharedlib_from_linklib_cmd" >&5
17227 $as_echo "$lt_cv_sharedlib_from_linklib_cmd" >&6; }
17228 sharedlib_from_linklib_cmd=$lt_cv_sharedlib_from_linklib_cmd
17229 test -z "$sharedlib_from_linklib_cmd" && sharedlib_from_linklib_cmd=$ECHO
17230
17231
17232
17233
17234
17235
17236
17237 if test -n "$ac_tool_prefix"; then
17238   for ac_prog in ar
17239   do
17240     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
17241 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
17242 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17243 $as_echo_n "checking for $ac_word... " >&6; }
17244 if ${ac_cv_prog_AR+:} false; then :
17245   $as_echo_n "(cached) " >&6
17246 else
17247   if test -n "$AR"; then
17248   ac_cv_prog_AR="$AR" # Let the user override the test.
17249 else
17250 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17251 for as_dir in $PATH
17252 do
17253   IFS=$as_save_IFS
17254   test -z "$as_dir" && as_dir=.
17255     for ac_exec_ext in '' $ac_executable_extensions; do
17256   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
17257     ac_cv_prog_AR="$ac_tool_prefix$ac_prog"
17258     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17259     break 2
17260   fi
17261 done
17262   done
17263 IFS=$as_save_IFS
17264
17265 fi
17266 fi
17267 AR=$ac_cv_prog_AR
17268 if test -n "$AR"; then
17269   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
17270 $as_echo "$AR" >&6; }
17271 else
17272   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17273 $as_echo "no" >&6; }
17274 fi
17275
17276
17277     test -n "$AR" && break
17278   done
17279 fi
17280 if test -z "$AR"; then
17281   ac_ct_AR=$AR
17282   for ac_prog in ar
17283 do
17284   # Extract the first word of "$ac_prog", so it can be a program name with args.
17285 set dummy $ac_prog; ac_word=$2
17286 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17287 $as_echo_n "checking for $ac_word... " >&6; }
17288 if ${ac_cv_prog_ac_ct_AR+:} false; then :
17289   $as_echo_n "(cached) " >&6
17290 else
17291   if test -n "$ac_ct_AR"; then
17292   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
17293 else
17294 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17295 for as_dir in $PATH
17296 do
17297   IFS=$as_save_IFS
17298   test -z "$as_dir" && as_dir=.
17299     for ac_exec_ext in '' $ac_executable_extensions; do
17300   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
17301     ac_cv_prog_ac_ct_AR="$ac_prog"
17302     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17303     break 2
17304   fi
17305 done
17306   done
17307 IFS=$as_save_IFS
17308
17309 fi
17310 fi
17311 ac_ct_AR=$ac_cv_prog_ac_ct_AR
17312 if test -n "$ac_ct_AR"; then
17313   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
17314 $as_echo "$ac_ct_AR" >&6; }
17315 else
17316   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17317 $as_echo "no" >&6; }
17318 fi
17319
17320
17321   test -n "$ac_ct_AR" && break
17322 done
17323
17324   if test "x$ac_ct_AR" = x; then
17325     AR="false"
17326   else
17327     case $cross_compiling:$ac_tool_warned in
17328 yes:)
17329 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
17330 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
17331 ac_tool_warned=yes ;;
17332 esac
17333     AR=$ac_ct_AR
17334   fi
17335 fi
17336
17337 : ${AR=ar}
17338 : ${AR_FLAGS=cru}
17339
17340
17341
17342
17343
17344
17345
17346
17347
17348
17349
17350 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for archiver @FILE support" >&5
17351 $as_echo_n "checking for archiver @FILE support... " >&6; }
17352 if ${lt_cv_ar_at_file+:} false; then :
17353   $as_echo_n "(cached) " >&6
17354 else
17355   lt_cv_ar_at_file=no
17356    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17357 /* end confdefs.h.  */
17358
17359 int
17360 main ()
17361 {
17362
17363   ;
17364   return 0;
17365 }
17366 _ACEOF
17367 if ac_fn_c_try_compile "$LINENO"; then :
17368   echo conftest.$ac_objext > conftest.lst
17369       lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&5'
17370       { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
17371   (eval $lt_ar_try) 2>&5
17372   ac_status=$?
17373   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
17374   test $ac_status = 0; }
17375       if test "$ac_status" -eq 0; then
17376         # Ensure the archiver fails upon bogus file names.
17377         rm -f conftest.$ac_objext libconftest.a
17378         { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$lt_ar_try\""; } >&5
17379   (eval $lt_ar_try) 2>&5
17380   ac_status=$?
17381   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
17382   test $ac_status = 0; }
17383         if test "$ac_status" -ne 0; then
17384           lt_cv_ar_at_file=@
17385         fi
17386       fi
17387       rm -f conftest.* libconftest.a
17388
17389 fi
17390 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17391
17392 fi
17393 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ar_at_file" >&5
17394 $as_echo "$lt_cv_ar_at_file" >&6; }
17395
17396 if test "x$lt_cv_ar_at_file" = xno; then
17397   archiver_list_spec=
17398 else
17399   archiver_list_spec=$lt_cv_ar_at_file
17400 fi
17401
17402
17403
17404
17405
17406
17407
17408 if test -n "$ac_tool_prefix"; then
17409   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
17410 set dummy ${ac_tool_prefix}strip; ac_word=$2
17411 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17412 $as_echo_n "checking for $ac_word... " >&6; }
17413 if ${ac_cv_prog_STRIP+:} false; then :
17414   $as_echo_n "(cached) " >&6
17415 else
17416   if test -n "$STRIP"; then
17417   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
17418 else
17419 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17420 for as_dir in $PATH
17421 do
17422   IFS=$as_save_IFS
17423   test -z "$as_dir" && as_dir=.
17424     for ac_exec_ext in '' $ac_executable_extensions; do
17425   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
17426     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
17427     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17428     break 2
17429   fi
17430 done
17431   done
17432 IFS=$as_save_IFS
17433
17434 fi
17435 fi
17436 STRIP=$ac_cv_prog_STRIP
17437 if test -n "$STRIP"; then
17438   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
17439 $as_echo "$STRIP" >&6; }
17440 else
17441   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17442 $as_echo "no" >&6; }
17443 fi
17444
17445
17446 fi
17447 if test -z "$ac_cv_prog_STRIP"; then
17448   ac_ct_STRIP=$STRIP
17449   # Extract the first word of "strip", so it can be a program name with args.
17450 set dummy strip; ac_word=$2
17451 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17452 $as_echo_n "checking for $ac_word... " >&6; }
17453 if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
17454   $as_echo_n "(cached) " >&6
17455 else
17456   if test -n "$ac_ct_STRIP"; then
17457   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
17458 else
17459 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17460 for as_dir in $PATH
17461 do
17462   IFS=$as_save_IFS
17463   test -z "$as_dir" && as_dir=.
17464     for ac_exec_ext in '' $ac_executable_extensions; do
17465   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
17466     ac_cv_prog_ac_ct_STRIP="strip"
17467     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17468     break 2
17469   fi
17470 done
17471   done
17472 IFS=$as_save_IFS
17473
17474 fi
17475 fi
17476 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
17477 if test -n "$ac_ct_STRIP"; then
17478   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
17479 $as_echo "$ac_ct_STRIP" >&6; }
17480 else
17481   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17482 $as_echo "no" >&6; }
17483 fi
17484
17485   if test "x$ac_ct_STRIP" = x; then
17486     STRIP=":"
17487   else
17488     case $cross_compiling:$ac_tool_warned in
17489 yes:)
17490 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
17491 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
17492 ac_tool_warned=yes ;;
17493 esac
17494     STRIP=$ac_ct_STRIP
17495   fi
17496 else
17497   STRIP="$ac_cv_prog_STRIP"
17498 fi
17499
17500 test -z "$STRIP" && STRIP=:
17501
17502
17503
17504
17505
17506
17507 if test -n "$ac_tool_prefix"; then
17508   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
17509 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
17510 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17511 $as_echo_n "checking for $ac_word... " >&6; }
17512 if ${ac_cv_prog_RANLIB+:} false; then :
17513   $as_echo_n "(cached) " >&6
17514 else
17515   if test -n "$RANLIB"; then
17516   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
17517 else
17518 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17519 for as_dir in $PATH
17520 do
17521   IFS=$as_save_IFS
17522   test -z "$as_dir" && as_dir=.
17523     for ac_exec_ext in '' $ac_executable_extensions; do
17524   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
17525     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
17526     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17527     break 2
17528   fi
17529 done
17530   done
17531 IFS=$as_save_IFS
17532
17533 fi
17534 fi
17535 RANLIB=$ac_cv_prog_RANLIB
17536 if test -n "$RANLIB"; then
17537   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
17538 $as_echo "$RANLIB" >&6; }
17539 else
17540   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17541 $as_echo "no" >&6; }
17542 fi
17543
17544
17545 fi
17546 if test -z "$ac_cv_prog_RANLIB"; then
17547   ac_ct_RANLIB=$RANLIB
17548   # Extract the first word of "ranlib", so it can be a program name with args.
17549 set dummy ranlib; ac_word=$2
17550 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
17551 $as_echo_n "checking for $ac_word... " >&6; }
17552 if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
17553   $as_echo_n "(cached) " >&6
17554 else
17555   if test -n "$ac_ct_RANLIB"; then
17556   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
17557 else
17558 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
17559 for as_dir in $PATH
17560 do
17561   IFS=$as_save_IFS
17562   test -z "$as_dir" && as_dir=.
17563     for ac_exec_ext in '' $ac_executable_extensions; do
17564   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
17565     ac_cv_prog_ac_ct_RANLIB="ranlib"
17566     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
17567     break 2
17568   fi
17569 done
17570   done
17571 IFS=$as_save_IFS
17572
17573 fi
17574 fi
17575 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
17576 if test -n "$ac_ct_RANLIB"; then
17577   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
17578 $as_echo "$ac_ct_RANLIB" >&6; }
17579 else
17580   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
17581 $as_echo "no" >&6; }
17582 fi
17583
17584   if test "x$ac_ct_RANLIB" = x; then
17585     RANLIB=":"
17586   else
17587     case $cross_compiling:$ac_tool_warned in
17588 yes:)
17589 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
17590 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
17591 ac_tool_warned=yes ;;
17592 esac
17593     RANLIB=$ac_ct_RANLIB
17594   fi
17595 else
17596   RANLIB="$ac_cv_prog_RANLIB"
17597 fi
17598
17599 test -z "$RANLIB" && RANLIB=:
17600
17601
17602
17603
17604
17605
17606 # Determine commands to create old-style static archives.
17607 old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
17608 old_postinstall_cmds='chmod 644 $oldlib'
17609 old_postuninstall_cmds=
17610
17611 if test -n "$RANLIB"; then
17612   case $host_os in
17613   openbsd*)
17614     old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
17615     ;;
17616   *)
17617     old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
17618     ;;
17619   esac
17620   old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
17621 fi
17622
17623 case $host_os in
17624   darwin*)
17625     lock_old_archive_extraction=yes ;;
17626   *)
17627     lock_old_archive_extraction=no ;;
17628 esac
17629
17630
17631
17632
17633
17634
17635
17636
17637
17638
17639
17640
17641
17642
17643
17644
17645
17646
17647
17648
17649
17650
17651
17652
17653
17654
17655
17656
17657
17658
17659
17660
17661
17662
17663
17664
17665
17666
17667
17668 # If no C compiler was specified, use CC.
17669 LTCC=${LTCC-"$CC"}
17670
17671 # If no C compiler flags were specified, use CFLAGS.
17672 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
17673
17674 # Allow CC to be a program name with arguments.
17675 compiler=$CC
17676
17677
17678 # Check for command to grab the raw symbol name followed by C symbol from nm.
17679 { $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5
17680 $as_echo_n "checking command to parse $NM output from $compiler object... " >&6; }
17681 if ${lt_cv_sys_global_symbol_pipe+:} false; then :
17682   $as_echo_n "(cached) " >&6
17683 else
17684
17685 # These are sane defaults that work on at least a few old systems.
17686 # [They come from Ultrix.  What could be older than Ultrix?!! ;)]
17687
17688 # Character class describing NM global symbol codes.
17689 symcode='[BCDEGRST]'
17690
17691 # Regexp to match symbols that can be accessed directly from C.
17692 sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
17693
17694 # Define system-specific variables.
17695 case $host_os in
17696 aix*)
17697   symcode='[BCDT]'
17698   ;;
17699 cygwin* | mingw* | pw32* | cegcc*)
17700   symcode='[ABCDGISTW]'
17701   ;;
17702 hpux*)
17703   if test "$host_cpu" = ia64; then
17704     symcode='[ABCDEGRST]'
17705   fi
17706   ;;
17707 irix* | nonstopux*)
17708   symcode='[BCDEGRST]'
17709   ;;
17710 osf*)
17711   symcode='[BCDEGQRST]'
17712   ;;
17713 solaris*)
17714   symcode='[BDRT]'
17715   ;;
17716 sco3.2v5*)
17717   symcode='[DT]'
17718   ;;
17719 sysv4.2uw2*)
17720   symcode='[DT]'
17721   ;;
17722 sysv5* | sco5v6* | unixware* | OpenUNIX*)
17723   symcode='[ABDT]'
17724   ;;
17725 sysv4)
17726   symcode='[DFNSTU]'
17727   ;;
17728 esac
17729
17730 # If we're using GNU nm, then use its standard symbol codes.
17731 case `$NM -V 2>&1` in
17732 *GNU* | *'with BFD'*)
17733   symcode='[ABCDGIRSTW]' ;;
17734 esac
17735
17736 # Transform an extracted symbol line into a proper C declaration.
17737 # Some systems (esp. on ia64) link data and code symbols differently,
17738 # so use this general approach.
17739 lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
17740
17741 # Transform an extracted symbol line into symbol name and symbol address
17742 lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\)[ ]*$/  {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/  {\"\2\", (void *) \&\2},/p'"
17743 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'"
17744
17745 # Handle CRLF in mingw tool chain
17746 opt_cr=
17747 case $build_os in
17748 mingw*)
17749   opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
17750   ;;
17751 esac
17752
17753 # Try without a prefix underscore, then with it.
17754 for ac_symprfx in "" "_"; do
17755
17756   # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
17757   symxfrm="\\1 $ac_symprfx\\2 \\2"
17758
17759   # Write the raw and C identifiers.
17760   if test "$lt_cv_nm_interface" = "MS dumpbin"; then
17761     # Fake it for dumpbin and say T for any non-static function
17762     # and D for any global variable.
17763     # Also find C++ and __fastcall symbols from MSVC++,
17764     # which start with @ or ?.
17765     lt_cv_sys_global_symbol_pipe="$AWK '"\
17766 "     {last_section=section; section=\$ 3};"\
17767 "     /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
17768 "     \$ 0!~/External *\|/{next};"\
17769 "     / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
17770 "     {if(hide[section]) next};"\
17771 "     {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
17772 "     {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
17773 "     s[1]~/^[@?]/{print s[1], s[1]; next};"\
17774 "     s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
17775 "     ' prfx=^$ac_symprfx"
17776   else
17777     lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[      ]\($symcode$symcode*\)[         ][      ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
17778   fi
17779   lt_cv_sys_global_symbol_pipe="$lt_cv_sys_global_symbol_pipe | sed '/ __gnu_lto/d'"
17780
17781   # Check to see that the pipe works correctly.
17782   pipe_works=no
17783
17784   rm -f conftest*
17785   cat > conftest.$ac_ext <<_LT_EOF
17786 #ifdef __cplusplus
17787 extern "C" {
17788 #endif
17789 char nm_test_var;
17790 void nm_test_func(void);
17791 void nm_test_func(void){}
17792 #ifdef __cplusplus
17793 }
17794 #endif
17795 int main(){nm_test_var='a';nm_test_func();return(0);}
17796 _LT_EOF
17797
17798   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
17799   (eval $ac_compile) 2>&5
17800   ac_status=$?
17801   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
17802   test $ac_status = 0; }; then
17803     # Now try to grab the symbols.
17804     nlist=conftest.nm
17805     if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5
17806   (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5
17807   ac_status=$?
17808   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
17809   test $ac_status = 0; } && test -s "$nlist"; then
17810       # Try sorting and uniquifying the output.
17811       if sort "$nlist" | uniq > "$nlist"T; then
17812         mv -f "$nlist"T "$nlist"
17813       else
17814         rm -f "$nlist"T
17815       fi
17816
17817       # Make sure that we snagged all the symbols we need.
17818       if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
17819         if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
17820           cat <<_LT_EOF > conftest.$ac_ext
17821 /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests.  */
17822 #if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE)
17823 /* DATA imports from DLLs on WIN32 con't be const, because runtime
17824    relocations are performed -- see ld's documentation on pseudo-relocs.  */
17825 # define LT_DLSYM_CONST
17826 #elif defined(__osf__)
17827 /* This system does not cope well with relocations in const data.  */
17828 # define LT_DLSYM_CONST
17829 #else
17830 # define LT_DLSYM_CONST const
17831 #endif
17832
17833 #ifdef __cplusplus
17834 extern "C" {
17835 #endif
17836
17837 _LT_EOF
17838           # Now generate the symbol file.
17839           eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
17840
17841           cat <<_LT_EOF >> conftest.$ac_ext
17842
17843 /* The mapping between symbol names and symbols.  */
17844 LT_DLSYM_CONST struct {
17845   const char *name;
17846   void       *address;
17847 }
17848 lt__PROGRAM__LTX_preloaded_symbols[] =
17849 {
17850   { "@PROGRAM@", (void *) 0 },
17851 _LT_EOF
17852           $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/  {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
17853           cat <<\_LT_EOF >> conftest.$ac_ext
17854   {0, (void *) 0}
17855 };
17856
17857 /* This works around a problem in FreeBSD linker */
17858 #ifdef FREEBSD_WORKAROUND
17859 static const void *lt_preloaded_setup() {
17860   return lt__PROGRAM__LTX_preloaded_symbols;
17861 }
17862 #endif
17863
17864 #ifdef __cplusplus
17865 }
17866 #endif
17867 _LT_EOF
17868           # Now try linking the two files.
17869           mv conftest.$ac_objext conftstm.$ac_objext
17870           lt_globsym_save_LIBS=$LIBS
17871           lt_globsym_save_CFLAGS=$CFLAGS
17872           LIBS="conftstm.$ac_objext"
17873           CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
17874           if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
17875   (eval $ac_link) 2>&5
17876   ac_status=$?
17877   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
17878   test $ac_status = 0; } && test -s conftest${ac_exeext}; then
17879             pipe_works=yes
17880           fi
17881           LIBS=$lt_globsym_save_LIBS
17882           CFLAGS=$lt_globsym_save_CFLAGS
17883         else
17884           echo "cannot find nm_test_func in $nlist" >&5
17885         fi
17886       else
17887         echo "cannot find nm_test_var in $nlist" >&5
17888       fi
17889     else
17890       echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
17891     fi
17892   else
17893     echo "$progname: failed program was:" >&5
17894     cat conftest.$ac_ext >&5
17895   fi
17896   rm -rf conftest* conftst*
17897
17898   # Do not use the global_symbol_pipe unless it works.
17899   if test "$pipe_works" = yes; then
17900     break
17901   else
17902     lt_cv_sys_global_symbol_pipe=
17903   fi
17904 done
17905
17906 fi
17907
17908 if test -z "$lt_cv_sys_global_symbol_pipe"; then
17909   lt_cv_sys_global_symbol_to_cdecl=
17910 fi
17911 if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
17912   { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
17913 $as_echo "failed" >&6; }
17914 else
17915   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
17916 $as_echo "ok" >&6; }
17917 fi
17918
17919 # Response file support.
17920 if test "$lt_cv_nm_interface" = "MS dumpbin"; then
17921   nm_file_list_spec='@'
17922 elif $NM --help 2>/dev/null | grep '[@]FILE' >/dev/null; then
17923   nm_file_list_spec='@'
17924 fi
17925
17926
17927
17928
17929
17930
17931
17932
17933
17934
17935
17936
17937
17938
17939
17940
17941
17942
17943
17944
17945
17946
17947
17948
17949
17950
17951
17952 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
17953 $as_echo_n "checking for sysroot... " >&6; }
17954
17955 # Check whether --with-sysroot was given.
17956 if test "${with_sysroot+set}" = set; then :
17957   withval=$with_sysroot;
17958 else
17959   with_sysroot=no
17960 fi
17961
17962
17963 lt_sysroot=
17964 case ${with_sysroot} in #(
17965  yes)
17966    if test "$GCC" = yes; then
17967      lt_sysroot=`$CC --print-sysroot 2>/dev/null`
17968    fi
17969    ;; #(
17970  /*)
17971    lt_sysroot=`echo "$with_sysroot" | sed -e "$sed_quote_subst"`
17972    ;; #(
17973  no|'')
17974    ;; #(
17975  *)
17976    { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_sysroot}" >&5
17977 $as_echo "${with_sysroot}" >&6; }
17978    as_fn_error $? "The sysroot must be an absolute path." "$LINENO" 5
17979    ;;
17980 esac
17981
17982  { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lt_sysroot:-no}" >&5
17983 $as_echo "${lt_sysroot:-no}" >&6; }
17984
17985
17986
17987
17988
17989 # Check whether --enable-libtool-lock was given.
17990 if test "${enable_libtool_lock+set}" = set; then :
17991   enableval=$enable_libtool_lock;
17992 fi
17993
17994 test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
17995
17996 # Some flags need to be propagated to the compiler or linker for good
17997 # libtool support.
17998 case $host in
17999 ia64-*-hpux*)
18000   # Find out which ABI we are using.
18001   echo 'int i;' > conftest.$ac_ext
18002   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
18003   (eval $ac_compile) 2>&5
18004   ac_status=$?
18005   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
18006   test $ac_status = 0; }; then
18007     case `/usr/bin/file conftest.$ac_objext` in
18008       *ELF-32*)
18009         HPUX_IA64_MODE="32"
18010         ;;
18011       *ELF-64*)
18012         HPUX_IA64_MODE="64"
18013         ;;
18014     esac
18015   fi
18016   rm -rf conftest*
18017   ;;
18018 *-*-irix6*)
18019   # Find out which ABI we are using.
18020   echo '#line '$LINENO' "configure"' > conftest.$ac_ext
18021   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
18022   (eval $ac_compile) 2>&5
18023   ac_status=$?
18024   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
18025   test $ac_status = 0; }; then
18026     if test "$lt_cv_prog_gnu_ld" = yes; then
18027       case `/usr/bin/file conftest.$ac_objext` in
18028         *32-bit*)
18029           LD="${LD-ld} -melf32bsmip"
18030           ;;
18031         *N32*)
18032           LD="${LD-ld} -melf32bmipn32"
18033           ;;
18034         *64-bit*)
18035           LD="${LD-ld} -melf64bmip"
18036         ;;
18037       esac
18038     else
18039       case `/usr/bin/file conftest.$ac_objext` in
18040         *32-bit*)
18041           LD="${LD-ld} -32"
18042           ;;
18043         *N32*)
18044           LD="${LD-ld} -n32"
18045           ;;
18046         *64-bit*)
18047           LD="${LD-ld} -64"
18048           ;;
18049       esac
18050     fi
18051   fi
18052   rm -rf conftest*
18053   ;;
18054
18055 x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \
18056 s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
18057   # Find out which ABI we are using.
18058   echo 'int i;' > conftest.$ac_ext
18059   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
18060   (eval $ac_compile) 2>&5
18061   ac_status=$?
18062   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
18063   test $ac_status = 0; }; then
18064     case `/usr/bin/file conftest.o` in
18065       *32-bit*)
18066         case $host in
18067           x86_64-*kfreebsd*-gnu)
18068             LD="${LD-ld} -m elf_i386_fbsd"
18069             ;;
18070           x86_64-*linux*)
18071             LD="${LD-ld} -m elf_i386"
18072             ;;
18073           ppc64-*linux*|powerpc64-*linux*)
18074             LD="${LD-ld} -m elf32ppclinux"
18075             ;;
18076           s390x-*linux*)
18077             LD="${LD-ld} -m elf_s390"
18078             ;;
18079           sparc64-*linux*)
18080             LD="${LD-ld} -m elf32_sparc"
18081             ;;
18082         esac
18083         ;;
18084       *64-bit*)
18085         case $host in
18086           x86_64-*kfreebsd*-gnu)
18087             LD="${LD-ld} -m elf_x86_64_fbsd"
18088             ;;
18089           x86_64-*linux*)
18090             LD="${LD-ld} -m elf_x86_64"
18091             ;;
18092           ppc*-*linux*|powerpc*-*linux*)
18093             LD="${LD-ld} -m elf64ppc"
18094             ;;
18095           s390*-*linux*|s390*-*tpf*)
18096             LD="${LD-ld} -m elf64_s390"
18097             ;;
18098           sparc*-*linux*)
18099             LD="${LD-ld} -m elf64_sparc"
18100             ;;
18101         esac
18102         ;;
18103     esac
18104   fi
18105   rm -rf conftest*
18106   ;;
18107
18108 *-*-sco3.2v5*)
18109   # On SCO OpenServer 5, we need -belf to get full-featured binaries.
18110   SAVE_CFLAGS="$CFLAGS"
18111   CFLAGS="$CFLAGS -belf"
18112   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5
18113 $as_echo_n "checking whether the C compiler needs -belf... " >&6; }
18114 if ${lt_cv_cc_needs_belf+:} false; then :
18115   $as_echo_n "(cached) " >&6
18116 else
18117   ac_ext=c
18118 ac_cpp='$CPP $CPPFLAGS'
18119 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
18120 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
18121 ac_compiler_gnu=$ac_cv_c_compiler_gnu
18122
18123      cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18124 /* end confdefs.h.  */
18125
18126 int
18127 main ()
18128 {
18129
18130   ;
18131   return 0;
18132 }
18133 _ACEOF
18134 if ac_fn_c_try_link "$LINENO"; then :
18135   lt_cv_cc_needs_belf=yes
18136 else
18137   lt_cv_cc_needs_belf=no
18138 fi
18139 rm -f core conftest.err conftest.$ac_objext \
18140     conftest$ac_exeext conftest.$ac_ext
18141      ac_ext=c
18142 ac_cpp='$CPP $CPPFLAGS'
18143 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
18144 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
18145 ac_compiler_gnu=$ac_cv_c_compiler_gnu
18146
18147 fi
18148 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5
18149 $as_echo "$lt_cv_cc_needs_belf" >&6; }
18150   if test x"$lt_cv_cc_needs_belf" != x"yes"; then
18151     # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
18152     CFLAGS="$SAVE_CFLAGS"
18153   fi
18154   ;;
18155 sparc*-*solaris*)
18156   # Find out which ABI we are using.
18157   echo 'int i;' > conftest.$ac_ext
18158   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
18159   (eval $ac_compile) 2>&5
18160   ac_status=$?
18161   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
18162   test $ac_status = 0; }; then
18163     case `/usr/bin/file conftest.o` in
18164     *64-bit*)
18165       case $lt_cv_prog_gnu_ld in
18166       yes*) LD="${LD-ld} -m elf64_sparc" ;;
18167       *)
18168         if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
18169           LD="${LD-ld} -64"
18170         fi
18171         ;;
18172       esac
18173       ;;
18174     esac
18175   fi
18176   rm -rf conftest*
18177   ;;
18178 esac
18179
18180 need_locks="$enable_libtool_lock"
18181
18182 if test -n "$ac_tool_prefix"; then
18183   # Extract the first word of "${ac_tool_prefix}mt", so it can be a program name with args.
18184 set dummy ${ac_tool_prefix}mt; ac_word=$2
18185 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18186 $as_echo_n "checking for $ac_word... " >&6; }
18187 if ${ac_cv_prog_MANIFEST_TOOL+:} false; then :
18188   $as_echo_n "(cached) " >&6
18189 else
18190   if test -n "$MANIFEST_TOOL"; then
18191   ac_cv_prog_MANIFEST_TOOL="$MANIFEST_TOOL" # Let the user override the test.
18192 else
18193 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18194 for as_dir in $PATH
18195 do
18196   IFS=$as_save_IFS
18197   test -z "$as_dir" && as_dir=.
18198     for ac_exec_ext in '' $ac_executable_extensions; do
18199   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
18200     ac_cv_prog_MANIFEST_TOOL="${ac_tool_prefix}mt"
18201     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18202     break 2
18203   fi
18204 done
18205   done
18206 IFS=$as_save_IFS
18207
18208 fi
18209 fi
18210 MANIFEST_TOOL=$ac_cv_prog_MANIFEST_TOOL
18211 if test -n "$MANIFEST_TOOL"; then
18212   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANIFEST_TOOL" >&5
18213 $as_echo "$MANIFEST_TOOL" >&6; }
18214 else
18215   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18216 $as_echo "no" >&6; }
18217 fi
18218
18219
18220 fi
18221 if test -z "$ac_cv_prog_MANIFEST_TOOL"; then
18222   ac_ct_MANIFEST_TOOL=$MANIFEST_TOOL
18223   # Extract the first word of "mt", so it can be a program name with args.
18224 set dummy mt; ac_word=$2
18225 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18226 $as_echo_n "checking for $ac_word... " >&6; }
18227 if ${ac_cv_prog_ac_ct_MANIFEST_TOOL+:} false; then :
18228   $as_echo_n "(cached) " >&6
18229 else
18230   if test -n "$ac_ct_MANIFEST_TOOL"; then
18231   ac_cv_prog_ac_ct_MANIFEST_TOOL="$ac_ct_MANIFEST_TOOL" # Let the user override the test.
18232 else
18233 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18234 for as_dir in $PATH
18235 do
18236   IFS=$as_save_IFS
18237   test -z "$as_dir" && as_dir=.
18238     for ac_exec_ext in '' $ac_executable_extensions; do
18239   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
18240     ac_cv_prog_ac_ct_MANIFEST_TOOL="mt"
18241     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18242     break 2
18243   fi
18244 done
18245   done
18246 IFS=$as_save_IFS
18247
18248 fi
18249 fi
18250 ac_ct_MANIFEST_TOOL=$ac_cv_prog_ac_ct_MANIFEST_TOOL
18251 if test -n "$ac_ct_MANIFEST_TOOL"; then
18252   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_MANIFEST_TOOL" >&5
18253 $as_echo "$ac_ct_MANIFEST_TOOL" >&6; }
18254 else
18255   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18256 $as_echo "no" >&6; }
18257 fi
18258
18259   if test "x$ac_ct_MANIFEST_TOOL" = x; then
18260     MANIFEST_TOOL=":"
18261   else
18262     case $cross_compiling:$ac_tool_warned in
18263 yes:)
18264 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
18265 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
18266 ac_tool_warned=yes ;;
18267 esac
18268     MANIFEST_TOOL=$ac_ct_MANIFEST_TOOL
18269   fi
18270 else
18271   MANIFEST_TOOL="$ac_cv_prog_MANIFEST_TOOL"
18272 fi
18273
18274 test -z "$MANIFEST_TOOL" && MANIFEST_TOOL=mt
18275 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $MANIFEST_TOOL is a manifest tool" >&5
18276 $as_echo_n "checking if $MANIFEST_TOOL is a manifest tool... " >&6; }
18277 if ${lt_cv_path_mainfest_tool+:} false; then :
18278   $as_echo_n "(cached) " >&6
18279 else
18280   lt_cv_path_mainfest_tool=no
18281   echo "$as_me:$LINENO: $MANIFEST_TOOL '-?'" >&5
18282   $MANIFEST_TOOL '-?' 2>conftest.err > conftest.out
18283   cat conftest.err >&5
18284   if $GREP 'Manifest Tool' conftest.out > /dev/null; then
18285     lt_cv_path_mainfest_tool=yes
18286   fi
18287   rm -f conftest*
18288 fi
18289 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_mainfest_tool" >&5
18290 $as_echo "$lt_cv_path_mainfest_tool" >&6; }
18291 if test "x$lt_cv_path_mainfest_tool" != xyes; then
18292   MANIFEST_TOOL=:
18293 fi
18294
18295
18296
18297
18298
18299
18300   case $host_os in
18301     rhapsody* | darwin*)
18302     if test -n "$ac_tool_prefix"; then
18303   # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args.
18304 set dummy ${ac_tool_prefix}dsymutil; ac_word=$2
18305 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18306 $as_echo_n "checking for $ac_word... " >&6; }
18307 if ${ac_cv_prog_DSYMUTIL+:} false; then :
18308   $as_echo_n "(cached) " >&6
18309 else
18310   if test -n "$DSYMUTIL"; then
18311   ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
18312 else
18313 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18314 for as_dir in $PATH
18315 do
18316   IFS=$as_save_IFS
18317   test -z "$as_dir" && as_dir=.
18318     for ac_exec_ext in '' $ac_executable_extensions; do
18319   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
18320     ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil"
18321     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18322     break 2
18323   fi
18324 done
18325   done
18326 IFS=$as_save_IFS
18327
18328 fi
18329 fi
18330 DSYMUTIL=$ac_cv_prog_DSYMUTIL
18331 if test -n "$DSYMUTIL"; then
18332   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
18333 $as_echo "$DSYMUTIL" >&6; }
18334 else
18335   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18336 $as_echo "no" >&6; }
18337 fi
18338
18339
18340 fi
18341 if test -z "$ac_cv_prog_DSYMUTIL"; then
18342   ac_ct_DSYMUTIL=$DSYMUTIL
18343   # Extract the first word of "dsymutil", so it can be a program name with args.
18344 set dummy dsymutil; ac_word=$2
18345 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18346 $as_echo_n "checking for $ac_word... " >&6; }
18347 if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then :
18348   $as_echo_n "(cached) " >&6
18349 else
18350   if test -n "$ac_ct_DSYMUTIL"; then
18351   ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test.
18352 else
18353 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18354 for as_dir in $PATH
18355 do
18356   IFS=$as_save_IFS
18357   test -z "$as_dir" && as_dir=.
18358     for ac_exec_ext in '' $ac_executable_extensions; do
18359   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
18360     ac_cv_prog_ac_ct_DSYMUTIL="dsymutil"
18361     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18362     break 2
18363   fi
18364 done
18365   done
18366 IFS=$as_save_IFS
18367
18368 fi
18369 fi
18370 ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL
18371 if test -n "$ac_ct_DSYMUTIL"; then
18372   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5
18373 $as_echo "$ac_ct_DSYMUTIL" >&6; }
18374 else
18375   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18376 $as_echo "no" >&6; }
18377 fi
18378
18379   if test "x$ac_ct_DSYMUTIL" = x; then
18380     DSYMUTIL=":"
18381   else
18382     case $cross_compiling:$ac_tool_warned in
18383 yes:)
18384 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
18385 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
18386 ac_tool_warned=yes ;;
18387 esac
18388     DSYMUTIL=$ac_ct_DSYMUTIL
18389   fi
18390 else
18391   DSYMUTIL="$ac_cv_prog_DSYMUTIL"
18392 fi
18393
18394     if test -n "$ac_tool_prefix"; then
18395   # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args.
18396 set dummy ${ac_tool_prefix}nmedit; ac_word=$2
18397 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18398 $as_echo_n "checking for $ac_word... " >&6; }
18399 if ${ac_cv_prog_NMEDIT+:} false; then :
18400   $as_echo_n "(cached) " >&6
18401 else
18402   if test -n "$NMEDIT"; then
18403   ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test.
18404 else
18405 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18406 for as_dir in $PATH
18407 do
18408   IFS=$as_save_IFS
18409   test -z "$as_dir" && as_dir=.
18410     for ac_exec_ext in '' $ac_executable_extensions; do
18411   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
18412     ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit"
18413     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18414     break 2
18415   fi
18416 done
18417   done
18418 IFS=$as_save_IFS
18419
18420 fi
18421 fi
18422 NMEDIT=$ac_cv_prog_NMEDIT
18423 if test -n "$NMEDIT"; then
18424   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5
18425 $as_echo "$NMEDIT" >&6; }
18426 else
18427   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18428 $as_echo "no" >&6; }
18429 fi
18430
18431
18432 fi
18433 if test -z "$ac_cv_prog_NMEDIT"; then
18434   ac_ct_NMEDIT=$NMEDIT
18435   # Extract the first word of "nmedit", so it can be a program name with args.
18436 set dummy nmedit; ac_word=$2
18437 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18438 $as_echo_n "checking for $ac_word... " >&6; }
18439 if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then :
18440   $as_echo_n "(cached) " >&6
18441 else
18442   if test -n "$ac_ct_NMEDIT"; then
18443   ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test.
18444 else
18445 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18446 for as_dir in $PATH
18447 do
18448   IFS=$as_save_IFS
18449   test -z "$as_dir" && as_dir=.
18450     for ac_exec_ext in '' $ac_executable_extensions; do
18451   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
18452     ac_cv_prog_ac_ct_NMEDIT="nmedit"
18453     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18454     break 2
18455   fi
18456 done
18457   done
18458 IFS=$as_save_IFS
18459
18460 fi
18461 fi
18462 ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT
18463 if test -n "$ac_ct_NMEDIT"; then
18464   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5
18465 $as_echo "$ac_ct_NMEDIT" >&6; }
18466 else
18467   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18468 $as_echo "no" >&6; }
18469 fi
18470
18471   if test "x$ac_ct_NMEDIT" = x; then
18472     NMEDIT=":"
18473   else
18474     case $cross_compiling:$ac_tool_warned in
18475 yes:)
18476 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
18477 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
18478 ac_tool_warned=yes ;;
18479 esac
18480     NMEDIT=$ac_ct_NMEDIT
18481   fi
18482 else
18483   NMEDIT="$ac_cv_prog_NMEDIT"
18484 fi
18485
18486     if test -n "$ac_tool_prefix"; then
18487   # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args.
18488 set dummy ${ac_tool_prefix}lipo; ac_word=$2
18489 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18490 $as_echo_n "checking for $ac_word... " >&6; }
18491 if ${ac_cv_prog_LIPO+:} false; then :
18492   $as_echo_n "(cached) " >&6
18493 else
18494   if test -n "$LIPO"; then
18495   ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
18496 else
18497 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18498 for as_dir in $PATH
18499 do
18500   IFS=$as_save_IFS
18501   test -z "$as_dir" && as_dir=.
18502     for ac_exec_ext in '' $ac_executable_extensions; do
18503   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
18504     ac_cv_prog_LIPO="${ac_tool_prefix}lipo"
18505     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18506     break 2
18507   fi
18508 done
18509   done
18510 IFS=$as_save_IFS
18511
18512 fi
18513 fi
18514 LIPO=$ac_cv_prog_LIPO
18515 if test -n "$LIPO"; then
18516   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
18517 $as_echo "$LIPO" >&6; }
18518 else
18519   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18520 $as_echo "no" >&6; }
18521 fi
18522
18523
18524 fi
18525 if test -z "$ac_cv_prog_LIPO"; then
18526   ac_ct_LIPO=$LIPO
18527   # Extract the first word of "lipo", so it can be a program name with args.
18528 set dummy lipo; ac_word=$2
18529 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18530 $as_echo_n "checking for $ac_word... " >&6; }
18531 if ${ac_cv_prog_ac_ct_LIPO+:} false; then :
18532   $as_echo_n "(cached) " >&6
18533 else
18534   if test -n "$ac_ct_LIPO"; then
18535   ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test.
18536 else
18537 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18538 for as_dir in $PATH
18539 do
18540   IFS=$as_save_IFS
18541   test -z "$as_dir" && as_dir=.
18542     for ac_exec_ext in '' $ac_executable_extensions; do
18543   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
18544     ac_cv_prog_ac_ct_LIPO="lipo"
18545     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18546     break 2
18547   fi
18548 done
18549   done
18550 IFS=$as_save_IFS
18551
18552 fi
18553 fi
18554 ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO
18555 if test -n "$ac_ct_LIPO"; then
18556   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5
18557 $as_echo "$ac_ct_LIPO" >&6; }
18558 else
18559   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18560 $as_echo "no" >&6; }
18561 fi
18562
18563   if test "x$ac_ct_LIPO" = x; then
18564     LIPO=":"
18565   else
18566     case $cross_compiling:$ac_tool_warned in
18567 yes:)
18568 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
18569 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
18570 ac_tool_warned=yes ;;
18571 esac
18572     LIPO=$ac_ct_LIPO
18573   fi
18574 else
18575   LIPO="$ac_cv_prog_LIPO"
18576 fi
18577
18578     if test -n "$ac_tool_prefix"; then
18579   # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args.
18580 set dummy ${ac_tool_prefix}otool; ac_word=$2
18581 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18582 $as_echo_n "checking for $ac_word... " >&6; }
18583 if ${ac_cv_prog_OTOOL+:} false; then :
18584   $as_echo_n "(cached) " >&6
18585 else
18586   if test -n "$OTOOL"; then
18587   ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
18588 else
18589 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18590 for as_dir in $PATH
18591 do
18592   IFS=$as_save_IFS
18593   test -z "$as_dir" && as_dir=.
18594     for ac_exec_ext in '' $ac_executable_extensions; do
18595   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
18596     ac_cv_prog_OTOOL="${ac_tool_prefix}otool"
18597     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18598     break 2
18599   fi
18600 done
18601   done
18602 IFS=$as_save_IFS
18603
18604 fi
18605 fi
18606 OTOOL=$ac_cv_prog_OTOOL
18607 if test -n "$OTOOL"; then
18608   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
18609 $as_echo "$OTOOL" >&6; }
18610 else
18611   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18612 $as_echo "no" >&6; }
18613 fi
18614
18615
18616 fi
18617 if test -z "$ac_cv_prog_OTOOL"; then
18618   ac_ct_OTOOL=$OTOOL
18619   # Extract the first word of "otool", so it can be a program name with args.
18620 set dummy otool; ac_word=$2
18621 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18622 $as_echo_n "checking for $ac_word... " >&6; }
18623 if ${ac_cv_prog_ac_ct_OTOOL+:} false; then :
18624   $as_echo_n "(cached) " >&6
18625 else
18626   if test -n "$ac_ct_OTOOL"; then
18627   ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test.
18628 else
18629 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18630 for as_dir in $PATH
18631 do
18632   IFS=$as_save_IFS
18633   test -z "$as_dir" && as_dir=.
18634     for ac_exec_ext in '' $ac_executable_extensions; do
18635   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
18636     ac_cv_prog_ac_ct_OTOOL="otool"
18637     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18638     break 2
18639   fi
18640 done
18641   done
18642 IFS=$as_save_IFS
18643
18644 fi
18645 fi
18646 ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL
18647 if test -n "$ac_ct_OTOOL"; then
18648   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5
18649 $as_echo "$ac_ct_OTOOL" >&6; }
18650 else
18651   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18652 $as_echo "no" >&6; }
18653 fi
18654
18655   if test "x$ac_ct_OTOOL" = x; then
18656     OTOOL=":"
18657   else
18658     case $cross_compiling:$ac_tool_warned in
18659 yes:)
18660 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
18661 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
18662 ac_tool_warned=yes ;;
18663 esac
18664     OTOOL=$ac_ct_OTOOL
18665   fi
18666 else
18667   OTOOL="$ac_cv_prog_OTOOL"
18668 fi
18669
18670     if test -n "$ac_tool_prefix"; then
18671   # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args.
18672 set dummy ${ac_tool_prefix}otool64; ac_word=$2
18673 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18674 $as_echo_n "checking for $ac_word... " >&6; }
18675 if ${ac_cv_prog_OTOOL64+:} false; then :
18676   $as_echo_n "(cached) " >&6
18677 else
18678   if test -n "$OTOOL64"; then
18679   ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test.
18680 else
18681 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18682 for as_dir in $PATH
18683 do
18684   IFS=$as_save_IFS
18685   test -z "$as_dir" && as_dir=.
18686     for ac_exec_ext in '' $ac_executable_extensions; do
18687   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
18688     ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64"
18689     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18690     break 2
18691   fi
18692 done
18693   done
18694 IFS=$as_save_IFS
18695
18696 fi
18697 fi
18698 OTOOL64=$ac_cv_prog_OTOOL64
18699 if test -n "$OTOOL64"; then
18700   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5
18701 $as_echo "$OTOOL64" >&6; }
18702 else
18703   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18704 $as_echo "no" >&6; }
18705 fi
18706
18707
18708 fi
18709 if test -z "$ac_cv_prog_OTOOL64"; then
18710   ac_ct_OTOOL64=$OTOOL64
18711   # Extract the first word of "otool64", so it can be a program name with args.
18712 set dummy otool64; ac_word=$2
18713 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
18714 $as_echo_n "checking for $ac_word... " >&6; }
18715 if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then :
18716   $as_echo_n "(cached) " >&6
18717 else
18718   if test -n "$ac_ct_OTOOL64"; then
18719   ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test.
18720 else
18721 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18722 for as_dir in $PATH
18723 do
18724   IFS=$as_save_IFS
18725   test -z "$as_dir" && as_dir=.
18726     for ac_exec_ext in '' $ac_executable_extensions; do
18727   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
18728     ac_cv_prog_ac_ct_OTOOL64="otool64"
18729     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
18730     break 2
18731   fi
18732 done
18733   done
18734 IFS=$as_save_IFS
18735
18736 fi
18737 fi
18738 ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64
18739 if test -n "$ac_ct_OTOOL64"; then
18740   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5
18741 $as_echo "$ac_ct_OTOOL64" >&6; }
18742 else
18743   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
18744 $as_echo "no" >&6; }
18745 fi
18746
18747   if test "x$ac_ct_OTOOL64" = x; then
18748     OTOOL64=":"
18749   else
18750     case $cross_compiling:$ac_tool_warned in
18751 yes:)
18752 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
18753 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
18754 ac_tool_warned=yes ;;
18755 esac
18756     OTOOL64=$ac_ct_OTOOL64
18757   fi
18758 else
18759   OTOOL64="$ac_cv_prog_OTOOL64"
18760 fi
18761
18762
18763
18764
18765
18766
18767
18768
18769
18770
18771
18772
18773
18774
18775
18776
18777
18778
18779
18780
18781
18782
18783
18784
18785
18786
18787
18788     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5
18789 $as_echo_n "checking for -single_module linker flag... " >&6; }
18790 if ${lt_cv_apple_cc_single_mod+:} false; then :
18791   $as_echo_n "(cached) " >&6
18792 else
18793   lt_cv_apple_cc_single_mod=no
18794       if test -z "${LT_MULTI_MODULE}"; then
18795         # By default we will add the -single_module flag. You can override
18796         # by either setting the environment variable LT_MULTI_MODULE
18797         # non-empty at configure time, or by adding -multi_module to the
18798         # link flags.
18799         rm -rf libconftest.dylib*
18800         echo "int foo(void){return 1;}" > conftest.c
18801         echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
18802 -dynamiclib -Wl,-single_module conftest.c" >&5
18803         $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
18804           -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
18805         _lt_result=$?
18806         if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then
18807           lt_cv_apple_cc_single_mod=yes
18808         else
18809           cat conftest.err >&5
18810         fi
18811         rm -rf libconftest.dylib*
18812         rm -f conftest.*
18813       fi
18814 fi
18815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5
18816 $as_echo "$lt_cv_apple_cc_single_mod" >&6; }
18817     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5
18818 $as_echo_n "checking for -exported_symbols_list linker flag... " >&6; }
18819 if ${lt_cv_ld_exported_symbols_list+:} false; then :
18820   $as_echo_n "(cached) " >&6
18821 else
18822   lt_cv_ld_exported_symbols_list=no
18823       save_LDFLAGS=$LDFLAGS
18824       echo "_main" > conftest.sym
18825       LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
18826       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18827 /* end confdefs.h.  */
18828
18829 int
18830 main ()
18831 {
18832
18833   ;
18834   return 0;
18835 }
18836 _ACEOF
18837 if ac_fn_c_try_link "$LINENO"; then :
18838   lt_cv_ld_exported_symbols_list=yes
18839 else
18840   lt_cv_ld_exported_symbols_list=no
18841 fi
18842 rm -f core conftest.err conftest.$ac_objext \
18843     conftest$ac_exeext conftest.$ac_ext
18844         LDFLAGS="$save_LDFLAGS"
18845
18846 fi
18847 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5
18848 $as_echo "$lt_cv_ld_exported_symbols_list" >&6; }
18849     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5
18850 $as_echo_n "checking for -force_load linker flag... " >&6; }
18851 if ${lt_cv_ld_force_load+:} false; then :
18852   $as_echo_n "(cached) " >&6
18853 else
18854   lt_cv_ld_force_load=no
18855       cat > conftest.c << _LT_EOF
18856 int forced_loaded() { return 2;}
18857 _LT_EOF
18858       echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5
18859       $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
18860       echo "$AR cru libconftest.a conftest.o" >&5
18861       $AR cru libconftest.a conftest.o 2>&5
18862       echo "$RANLIB libconftest.a" >&5
18863       $RANLIB libconftest.a 2>&5
18864       cat > conftest.c << _LT_EOF
18865 int main() { return 0;}
18866 _LT_EOF
18867       echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5
18868       $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
18869       _lt_result=$?
18870       if test -f conftest && test ! -s conftest.err && test $_lt_result = 0 && $GREP forced_load conftest 2>&1 >/dev/null; then
18871         lt_cv_ld_force_load=yes
18872       else
18873         cat conftest.err >&5
18874       fi
18875         rm -f conftest.err libconftest.a conftest conftest.c
18876         rm -rf conftest.dSYM
18877
18878 fi
18879 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5
18880 $as_echo "$lt_cv_ld_force_load" >&6; }
18881     case $host_os in
18882     rhapsody* | darwin1.[012])
18883       _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
18884     darwin1.*)
18885       _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
18886     darwin*) # darwin 5.x on
18887       # if running on 10.5 or later, the deployment target defaults
18888       # to the OS version, if on x86, and 10.4, the deployment
18889       # target defaults to 10.4. Don't you love it?
18890       case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
18891         10.0,*86*-darwin8*|10.0,*-darwin[91]*)
18892           _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
18893         10.[012]*)
18894           _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
18895         10.*)
18896           _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
18897       esac
18898     ;;
18899   esac
18900     if test "$lt_cv_apple_cc_single_mod" = "yes"; then
18901       _lt_dar_single_mod='$single_module'
18902     fi
18903     if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
18904       _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
18905     else
18906       _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
18907     fi
18908     if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then
18909       _lt_dsymutil='~$DSYMUTIL $lib || :'
18910     else
18911       _lt_dsymutil=
18912     fi
18913     ;;
18914   esac
18915
18916 for ac_header in dlfcn.h
18917 do :
18918   ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
18919 "
18920 if test "x$ac_cv_header_dlfcn_h" = xyes; then :
18921   cat >>confdefs.h <<_ACEOF
18922 #define HAVE_DLFCN_H 1
18923 _ACEOF
18924
18925 fi
18926
18927 done
18928
18929
18930
18931
18932
18933 # Set options
18934
18935
18936
18937         enable_dlopen=no
18938
18939
18940   enable_win32_dll=no
18941
18942
18943
18944   # Check whether --enable-static was given.
18945 if test "${enable_static+set}" = set; then :
18946   enableval=$enable_static; p=${PACKAGE-default}
18947     case $enableval in
18948     yes) enable_static=yes ;;
18949     no) enable_static=no ;;
18950     *)
18951      enable_static=no
18952       # Look at the argument we got.  We use all the common list separators.
18953       lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
18954       for pkg in $enableval; do
18955         IFS="$lt_save_ifs"
18956         if test "X$pkg" = "X$p"; then
18957           enable_static=yes
18958         fi
18959       done
18960       IFS="$lt_save_ifs"
18961       ;;
18962     esac
18963 else
18964   enable_static=yes
18965 fi
18966
18967
18968
18969
18970
18971
18972
18973
18974
18975
18976 # Check whether --with-pic was given.
18977 if test "${with_pic+set}" = set; then :
18978   withval=$with_pic; pic_mode="$withval"
18979 else
18980   pic_mode=default
18981 fi
18982
18983
18984 test -z "$pic_mode" && pic_mode=default
18985
18986
18987
18988
18989
18990
18991
18992   # Check whether --enable-fast-install was given.
18993 if test "${enable_fast_install+set}" = set; then :
18994   enableval=$enable_fast_install; p=${PACKAGE-default}
18995     case $enableval in
18996     yes) enable_fast_install=yes ;;
18997     no) enable_fast_install=no ;;
18998     *)
18999       enable_fast_install=no
19000       # Look at the argument we got.  We use all the common list separators.
19001       lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
19002       for pkg in $enableval; do
19003         IFS="$lt_save_ifs"
19004         if test "X$pkg" = "X$p"; then
19005           enable_fast_install=yes
19006         fi
19007       done
19008       IFS="$lt_save_ifs"
19009       ;;
19010     esac
19011 else
19012   enable_fast_install=yes
19013 fi
19014
19015
19016
19017
19018
19019
19020
19021
19022
19023
19024
19025 # This can be used to rebuild libtool when needed
19026 LIBTOOL_DEPS="$ltmain"
19027
19028 # Always use our own libtool.
19029 LIBTOOL='$(SHELL) $(top_builddir)/libtool'
19030
19031
19032
19033
19034
19035
19036
19037
19038
19039
19040
19041
19042
19043
19044
19045
19046
19047
19048
19049
19050
19051
19052
19053
19054
19055
19056 test -z "$LN_S" && LN_S="ln -s"
19057
19058
19059
19060
19061
19062
19063
19064
19065
19066
19067
19068
19069
19070
19071 if test -n "${ZSH_VERSION+set}" ; then
19072    setopt NO_GLOB_SUBST
19073 fi
19074
19075 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5
19076 $as_echo_n "checking for objdir... " >&6; }
19077 if ${lt_cv_objdir+:} false; then :
19078   $as_echo_n "(cached) " >&6
19079 else
19080   rm -f .libs 2>/dev/null
19081 mkdir .libs 2>/dev/null
19082 if test -d .libs; then
19083   lt_cv_objdir=.libs
19084 else
19085   # MS-DOS does not allow filenames that begin with a dot.
19086   lt_cv_objdir=_libs
19087 fi
19088 rmdir .libs 2>/dev/null
19089 fi
19090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5
19091 $as_echo "$lt_cv_objdir" >&6; }
19092 objdir=$lt_cv_objdir
19093
19094
19095
19096
19097
19098 cat >>confdefs.h <<_ACEOF
19099 #define LT_OBJDIR "$lt_cv_objdir/"
19100 _ACEOF
19101
19102
19103
19104
19105 case $host_os in
19106 aix3*)
19107   # AIX sometimes has problems with the GCC collect2 program.  For some
19108   # reason, if we set the COLLECT_NAMES environment variable, the problems
19109   # vanish in a puff of smoke.
19110   if test "X${COLLECT_NAMES+set}" != Xset; then
19111     COLLECT_NAMES=
19112     export COLLECT_NAMES
19113   fi
19114   ;;
19115 esac
19116
19117 # Global variables:
19118 ofile=libtool
19119 can_build_shared=yes
19120
19121 # All known linkers require a `.a' archive for static linking (except MSVC,
19122 # which needs '.lib').
19123 libext=a
19124
19125 with_gnu_ld="$lt_cv_prog_gnu_ld"
19126
19127 old_CC="$CC"
19128 old_CFLAGS="$CFLAGS"
19129
19130 # Set sane defaults for various variables
19131 test -z "$CC" && CC=cc
19132 test -z "$LTCC" && LTCC=$CC
19133 test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
19134 test -z "$LD" && LD=ld
19135 test -z "$ac_objext" && ac_objext=o
19136
19137 for cc_temp in $compiler""; do
19138   case $cc_temp in
19139     compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
19140     distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
19141     \-*) ;;
19142     *) break;;
19143   esac
19144 done
19145 cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
19146
19147
19148 # Only perform the check for file, if the check method requires it
19149 test -z "$MAGIC_CMD" && MAGIC_CMD=file
19150 case $deplibs_check_method in
19151 file_magic*)
19152   if test "$file_magic_cmd" = '$MAGIC_CMD'; then
19153     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5
19154 $as_echo_n "checking for ${ac_tool_prefix}file... " >&6; }
19155 if ${lt_cv_path_MAGIC_CMD+:} false; then :
19156   $as_echo_n "(cached) " >&6
19157 else
19158   case $MAGIC_CMD in
19159 [\\/*] |  ?:[\\/]*)
19160   lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
19161   ;;
19162 *)
19163   lt_save_MAGIC_CMD="$MAGIC_CMD"
19164   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
19165   ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
19166   for ac_dir in $ac_dummy; do
19167     IFS="$lt_save_ifs"
19168     test -z "$ac_dir" && ac_dir=.
19169     if test -f $ac_dir/${ac_tool_prefix}file; then
19170       lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file"
19171       if test -n "$file_magic_test_file"; then
19172         case $deplibs_check_method in
19173         "file_magic "*)
19174           file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
19175           MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
19176           if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
19177             $EGREP "$file_magic_regex" > /dev/null; then
19178             :
19179           else
19180             cat <<_LT_EOF 1>&2
19181
19182 *** Warning: the command libtool uses to detect shared libraries,
19183 *** $file_magic_cmd, produces output that libtool cannot recognize.
19184 *** The result is that libtool may fail to recognize shared libraries
19185 *** as such.  This will affect the creation of libtool libraries that
19186 *** depend on shared libraries, but programs linked with such libtool
19187 *** libraries will work regardless of this problem.  Nevertheless, you
19188 *** may want to report the problem to your system manager and/or to
19189 *** bug-libtool@gnu.org
19190
19191 _LT_EOF
19192           fi ;;
19193         esac
19194       fi
19195       break
19196     fi
19197   done
19198   IFS="$lt_save_ifs"
19199   MAGIC_CMD="$lt_save_MAGIC_CMD"
19200   ;;
19201 esac
19202 fi
19203
19204 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
19205 if test -n "$MAGIC_CMD"; then
19206   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
19207 $as_echo "$MAGIC_CMD" >&6; }
19208 else
19209   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19210 $as_echo "no" >&6; }
19211 fi
19212
19213
19214
19215
19216
19217 if test -z "$lt_cv_path_MAGIC_CMD"; then
19218   if test -n "$ac_tool_prefix"; then
19219     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5
19220 $as_echo_n "checking for file... " >&6; }
19221 if ${lt_cv_path_MAGIC_CMD+:} false; then :
19222   $as_echo_n "(cached) " >&6
19223 else
19224   case $MAGIC_CMD in
19225 [\\/*] |  ?:[\\/]*)
19226   lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
19227   ;;
19228 *)
19229   lt_save_MAGIC_CMD="$MAGIC_CMD"
19230   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
19231   ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
19232   for ac_dir in $ac_dummy; do
19233     IFS="$lt_save_ifs"
19234     test -z "$ac_dir" && ac_dir=.
19235     if test -f $ac_dir/file; then
19236       lt_cv_path_MAGIC_CMD="$ac_dir/file"
19237       if test -n "$file_magic_test_file"; then
19238         case $deplibs_check_method in
19239         "file_magic "*)
19240           file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
19241           MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
19242           if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
19243             $EGREP "$file_magic_regex" > /dev/null; then
19244             :
19245           else
19246             cat <<_LT_EOF 1>&2
19247
19248 *** Warning: the command libtool uses to detect shared libraries,
19249 *** $file_magic_cmd, produces output that libtool cannot recognize.
19250 *** The result is that libtool may fail to recognize shared libraries
19251 *** as such.  This will affect the creation of libtool libraries that
19252 *** depend on shared libraries, but programs linked with such libtool
19253 *** libraries will work regardless of this problem.  Nevertheless, you
19254 *** may want to report the problem to your system manager and/or to
19255 *** bug-libtool@gnu.org
19256
19257 _LT_EOF
19258           fi ;;
19259         esac
19260       fi
19261       break
19262     fi
19263   done
19264   IFS="$lt_save_ifs"
19265   MAGIC_CMD="$lt_save_MAGIC_CMD"
19266   ;;
19267 esac
19268 fi
19269
19270 MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
19271 if test -n "$MAGIC_CMD"; then
19272   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
19273 $as_echo "$MAGIC_CMD" >&6; }
19274 else
19275   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
19276 $as_echo "no" >&6; }
19277 fi
19278
19279
19280   else
19281     MAGIC_CMD=:
19282   fi
19283 fi
19284
19285   fi
19286   ;;
19287 esac
19288
19289 # Use C for the default configuration in the libtool script
19290
19291 lt_save_CC="$CC"
19292 ac_ext=c
19293 ac_cpp='$CPP $CPPFLAGS'
19294 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
19295 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
19296 ac_compiler_gnu=$ac_cv_c_compiler_gnu
19297
19298
19299 # Source file extension for C test sources.
19300 ac_ext=c
19301
19302 # Object file extension for compiled C test sources.
19303 objext=o
19304 objext=$objext
19305
19306 # Code to be used in simple compile tests
19307 lt_simple_compile_test_code="int some_variable = 0;"
19308
19309 # Code to be used in simple link tests
19310 lt_simple_link_test_code='int main(){return(0);}'
19311
19312
19313
19314
19315
19316
19317
19318 # If no C compiler was specified, use CC.
19319 LTCC=${LTCC-"$CC"}
19320
19321 # If no C compiler flags were specified, use CFLAGS.
19322 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
19323
19324 # Allow CC to be a program name with arguments.
19325 compiler=$CC
19326
19327 # Save the default compiler, since it gets overwritten when the other
19328 # tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
19329 compiler_DEFAULT=$CC
19330
19331 # save warnings/boilerplate of simple test code
19332 ac_outfile=conftest.$ac_objext
19333 echo "$lt_simple_compile_test_code" >conftest.$ac_ext
19334 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
19335 _lt_compiler_boilerplate=`cat conftest.err`
19336 $RM conftest*
19337
19338 ac_outfile=conftest.$ac_objext
19339 echo "$lt_simple_link_test_code" >conftest.$ac_ext
19340 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
19341 _lt_linker_boilerplate=`cat conftest.err`
19342 $RM -r conftest*
19343
19344
19345 ## CAVEAT EMPTOR:
19346 ## There is no encapsulation within the following macros, do not change
19347 ## the running order or otherwise move them around unless you know exactly
19348 ## what you are doing...
19349 if test -n "$compiler"; then
19350
19351 lt_prog_compiler_no_builtin_flag=
19352
19353 if test "$GCC" = yes; then
19354   case $cc_basename in
19355   nvcc*)
19356     lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;;
19357   *)
19358     lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;;
19359   esac
19360
19361   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
19362 $as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; }
19363 if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then :
19364   $as_echo_n "(cached) " >&6
19365 else
19366   lt_cv_prog_compiler_rtti_exceptions=no
19367    ac_outfile=conftest.$ac_objext
19368    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
19369    lt_compiler_flag="-fno-rtti -fno-exceptions"
19370    # Insert the option either (1) after the last *FLAGS variable, or
19371    # (2) before a word containing "conftest.", or (3) at the end.
19372    # Note that $ac_compile itself does not contain backslashes and begins
19373    # with a dollar sign (not a hyphen), so the echo should work correctly.
19374    # The option is referenced via a variable to avoid confusing sed.
19375    lt_compile=`echo "$ac_compile" | $SED \
19376    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
19377    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
19378    -e 's:$: $lt_compiler_flag:'`
19379    (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
19380    (eval "$lt_compile" 2>conftest.err)
19381    ac_status=$?
19382    cat conftest.err >&5
19383    echo "$as_me:$LINENO: \$? = $ac_status" >&5
19384    if (exit $ac_status) && test -s "$ac_outfile"; then
19385      # The compiler can only warn and ignore the option if not recognized
19386      # So say no if there are warnings other than the usual output.
19387      $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
19388      $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
19389      if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
19390        lt_cv_prog_compiler_rtti_exceptions=yes
19391      fi
19392    fi
19393    $RM conftest*
19394
19395 fi
19396 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
19397 $as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; }
19398
19399 if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then
19400     lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
19401 else
19402     :
19403 fi
19404
19405 fi
19406
19407
19408
19409
19410
19411
19412   lt_prog_compiler_wl=
19413 lt_prog_compiler_pic=
19414 lt_prog_compiler_static=
19415
19416
19417   if test "$GCC" = yes; then
19418     lt_prog_compiler_wl='-Wl,'
19419     lt_prog_compiler_static='-static'
19420
19421     case $host_os in
19422       aix*)
19423       # All AIX code is PIC.
19424       if test "$host_cpu" = ia64; then
19425         # AIX 5 now supports IA64 processor
19426         lt_prog_compiler_static='-Bstatic'
19427       fi
19428       ;;
19429
19430     amigaos*)
19431       case $host_cpu in
19432       powerpc)
19433             # see comment about AmigaOS4 .so support
19434             lt_prog_compiler_pic='-fPIC'
19435         ;;
19436       m68k)
19437             # FIXME: we need at least 68020 code to build shared libraries, but
19438             # adding the `-m68020' flag to GCC prevents building anything better,
19439             # like `-m68040'.
19440             lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
19441         ;;
19442       esac
19443       ;;
19444
19445     beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
19446       # PIC is the default for these OSes.
19447       ;;
19448
19449     mingw* | cygwin* | pw32* | os2* | cegcc*)
19450       # This hack is so that the source file can tell whether it is being
19451       # built for inclusion in a dll (and should export symbols for example).
19452       # Although the cygwin gcc ignores -fPIC, still need this for old-style
19453       # (--disable-auto-import) libraries
19454       lt_prog_compiler_pic='-DDLL_EXPORT'
19455       ;;
19456
19457     darwin* | rhapsody*)
19458       # PIC is the default on this platform
19459       # Common symbols not allowed in MH_DYLIB files
19460       lt_prog_compiler_pic='-fno-common'
19461       ;;
19462
19463     haiku*)
19464       # PIC is the default for Haiku.
19465       # The "-static" flag exists, but is broken.
19466       lt_prog_compiler_static=
19467       ;;
19468
19469     hpux*)
19470       # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
19471       # PA HP-UX.  On IA64 HP-UX, PIC is the default but the pic flag
19472       # sets the default TLS model and affects inlining.
19473       case $host_cpu in
19474       hppa*64*)
19475         # +Z the default
19476         ;;
19477       *)
19478         lt_prog_compiler_pic='-fPIC'
19479         ;;
19480       esac
19481       ;;
19482
19483     interix[3-9]*)
19484       # Interix 3.x gcc -fpic/-fPIC options generate broken code.
19485       # Instead, we relocate shared libraries at runtime.
19486       ;;
19487
19488     msdosdjgpp*)
19489       # Just because we use GCC doesn't mean we suddenly get shared libraries
19490       # on systems that don't support them.
19491       lt_prog_compiler_can_build_shared=no
19492       enable_shared=no
19493       ;;
19494
19495     *nto* | *qnx*)
19496       # QNX uses GNU C++, but need to define -shared option too, otherwise
19497       # it will coredump.
19498       lt_prog_compiler_pic='-fPIC -shared'
19499       ;;
19500
19501     sysv4*MP*)
19502       if test -d /usr/nec; then
19503         lt_prog_compiler_pic=-Kconform_pic
19504       fi
19505       ;;
19506
19507     *)
19508       lt_prog_compiler_pic='-fPIC'
19509       ;;
19510     esac
19511
19512     case $cc_basename in
19513     nvcc*) # Cuda Compiler Driver 2.2
19514       lt_prog_compiler_wl='-Xlinker '
19515       lt_prog_compiler_pic='-Xcompiler -fPIC'
19516       ;;
19517     esac
19518   else
19519     # PORTME Check for flag to pass linker flags through the system compiler.
19520     case $host_os in
19521     aix*)
19522       lt_prog_compiler_wl='-Wl,'
19523       if test "$host_cpu" = ia64; then
19524         # AIX 5 now supports IA64 processor
19525         lt_prog_compiler_static='-Bstatic'
19526       else
19527         lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp'
19528       fi
19529       ;;
19530
19531     mingw* | cygwin* | pw32* | os2* | cegcc*)
19532       # This hack is so that the source file can tell whether it is being
19533       # built for inclusion in a dll (and should export symbols for example).
19534       lt_prog_compiler_pic='-DDLL_EXPORT'
19535       ;;
19536
19537     hpux9* | hpux10* | hpux11*)
19538       lt_prog_compiler_wl='-Wl,'
19539       # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
19540       # not for PA HP-UX.
19541       case $host_cpu in
19542       hppa*64*|ia64*)
19543         # +Z the default
19544         ;;
19545       *)
19546         lt_prog_compiler_pic='+Z'
19547         ;;
19548       esac
19549       # Is there a better lt_prog_compiler_static that works with the bundled CC?
19550       lt_prog_compiler_static='${wl}-a ${wl}archive'
19551       ;;
19552
19553     irix5* | irix6* | nonstopux*)
19554       lt_prog_compiler_wl='-Wl,'
19555       # PIC (with -KPIC) is the default.
19556       lt_prog_compiler_static='-non_shared'
19557       ;;
19558
19559     linux* | k*bsd*-gnu | kopensolaris*-gnu)
19560       case $cc_basename in
19561       # old Intel for x86_64 which still supported -KPIC.
19562       ecc*)
19563         lt_prog_compiler_wl='-Wl,'
19564         lt_prog_compiler_pic='-KPIC'
19565         lt_prog_compiler_static='-static'
19566         ;;
19567       # icc used to be incompatible with GCC.
19568       # ICC 10 doesn't accept -KPIC any more.
19569       icc* | ifort*)
19570         lt_prog_compiler_wl='-Wl,'
19571         lt_prog_compiler_pic='-fPIC'
19572         lt_prog_compiler_static='-static'
19573         ;;
19574       # Lahey Fortran 8.1.
19575       lf95*)
19576         lt_prog_compiler_wl='-Wl,'
19577         lt_prog_compiler_pic='--shared'
19578         lt_prog_compiler_static='--static'
19579         ;;
19580       nagfor*)
19581         # NAG Fortran compiler
19582         lt_prog_compiler_wl='-Wl,-Wl,,'
19583         lt_prog_compiler_pic='-PIC'
19584         lt_prog_compiler_static='-Bstatic'
19585         ;;
19586       pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
19587         # Portland Group compilers (*not* the Pentium gcc compiler,
19588         # which looks to be a dead project)
19589         lt_prog_compiler_wl='-Wl,'
19590         lt_prog_compiler_pic='-fpic'
19591         lt_prog_compiler_static='-Bstatic'
19592         ;;
19593       ccc*)
19594         lt_prog_compiler_wl='-Wl,'
19595         # All Alpha code is PIC.
19596         lt_prog_compiler_static='-non_shared'
19597         ;;
19598       xl* | bgxl* | bgf* | mpixl*)
19599         # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
19600         lt_prog_compiler_wl='-Wl,'
19601         lt_prog_compiler_pic='-qpic'
19602         lt_prog_compiler_static='-qstaticlink'
19603         ;;
19604       *)
19605         case `$CC -V 2>&1 | sed 5q` in
19606         *Sun\ F* | *Sun*Fortran*)
19607           # Sun Fortran 8.3 passes all unrecognized flags to the linker
19608           lt_prog_compiler_pic='-KPIC'
19609           lt_prog_compiler_static='-Bstatic'
19610           lt_prog_compiler_wl=''
19611           ;;
19612         *Sun\ C*)
19613           # Sun C 5.9
19614           lt_prog_compiler_pic='-KPIC'
19615           lt_prog_compiler_static='-Bstatic'
19616           lt_prog_compiler_wl='-Wl,'
19617           ;;
19618         esac
19619         ;;
19620       esac
19621       ;;
19622
19623     newsos6)
19624       lt_prog_compiler_pic='-KPIC'
19625       lt_prog_compiler_static='-Bstatic'
19626       ;;
19627
19628     *nto* | *qnx*)
19629       # QNX uses GNU C++, but need to define -shared option too, otherwise
19630       # it will coredump.
19631       lt_prog_compiler_pic='-fPIC -shared'
19632       ;;
19633
19634     osf3* | osf4* | osf5*)
19635       lt_prog_compiler_wl='-Wl,'
19636       # All OSF/1 code is PIC.
19637       lt_prog_compiler_static='-non_shared'
19638       ;;
19639
19640     rdos*)
19641       lt_prog_compiler_static='-non_shared'
19642       ;;
19643
19644     solaris*)
19645       lt_prog_compiler_pic='-KPIC'
19646       lt_prog_compiler_static='-Bstatic'
19647       case $cc_basename in
19648       f77* | f90* | f95* | sunf77* | sunf90* | sunf95*)
19649         lt_prog_compiler_wl='-Qoption ld ';;
19650       *)
19651         lt_prog_compiler_wl='-Wl,';;
19652       esac
19653       ;;
19654
19655     sunos4*)
19656       lt_prog_compiler_wl='-Qoption ld '
19657       lt_prog_compiler_pic='-PIC'
19658       lt_prog_compiler_static='-Bstatic'
19659       ;;
19660
19661     sysv4 | sysv4.2uw2* | sysv4.3*)
19662       lt_prog_compiler_wl='-Wl,'
19663       lt_prog_compiler_pic='-KPIC'
19664       lt_prog_compiler_static='-Bstatic'
19665       ;;
19666
19667     sysv4*MP*)
19668       if test -d /usr/nec ;then
19669         lt_prog_compiler_pic='-Kconform_pic'
19670         lt_prog_compiler_static='-Bstatic'
19671       fi
19672       ;;
19673
19674     sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
19675       lt_prog_compiler_wl='-Wl,'
19676       lt_prog_compiler_pic='-KPIC'
19677       lt_prog_compiler_static='-Bstatic'
19678       ;;
19679
19680     unicos*)
19681       lt_prog_compiler_wl='-Wl,'
19682       lt_prog_compiler_can_build_shared=no
19683       ;;
19684
19685     uts4*)
19686       lt_prog_compiler_pic='-pic'
19687       lt_prog_compiler_static='-Bstatic'
19688       ;;
19689
19690     *)
19691       lt_prog_compiler_can_build_shared=no
19692       ;;
19693     esac
19694   fi
19695
19696 case $host_os in
19697   # For platforms which do not support PIC, -DPIC is meaningless:
19698   *djgpp*)
19699     lt_prog_compiler_pic=
19700     ;;
19701   *)
19702     lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
19703     ;;
19704 esac
19705
19706 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
19707 $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
19708 if ${lt_cv_prog_compiler_pic+:} false; then :
19709   $as_echo_n "(cached) " >&6
19710 else
19711   lt_cv_prog_compiler_pic=$lt_prog_compiler_pic
19712 fi
19713 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic" >&5
19714 $as_echo "$lt_cv_prog_compiler_pic" >&6; }
19715 lt_prog_compiler_pic=$lt_cv_prog_compiler_pic
19716
19717 #
19718 # Check to make sure the PIC flag actually works.
19719 #
19720 if test -n "$lt_prog_compiler_pic"; then
19721   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
19722 $as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; }
19723 if ${lt_cv_prog_compiler_pic_works+:} false; then :
19724   $as_echo_n "(cached) " >&6
19725 else
19726   lt_cv_prog_compiler_pic_works=no
19727    ac_outfile=conftest.$ac_objext
19728    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
19729    lt_compiler_flag="$lt_prog_compiler_pic -DPIC"
19730    # Insert the option either (1) after the last *FLAGS variable, or
19731    # (2) before a word containing "conftest.", or (3) at the end.
19732    # Note that $ac_compile itself does not contain backslashes and begins
19733    # with a dollar sign (not a hyphen), so the echo should work correctly.
19734    # The option is referenced via a variable to avoid confusing sed.
19735    lt_compile=`echo "$ac_compile" | $SED \
19736    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
19737    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
19738    -e 's:$: $lt_compiler_flag:'`
19739    (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
19740    (eval "$lt_compile" 2>conftest.err)
19741    ac_status=$?
19742    cat conftest.err >&5
19743    echo "$as_me:$LINENO: \$? = $ac_status" >&5
19744    if (exit $ac_status) && test -s "$ac_outfile"; then
19745      # The compiler can only warn and ignore the option if not recognized
19746      # So say no if there are warnings other than the usual output.
19747      $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
19748      $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
19749      if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
19750        lt_cv_prog_compiler_pic_works=yes
19751      fi
19752    fi
19753    $RM conftest*
19754
19755 fi
19756 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5
19757 $as_echo "$lt_cv_prog_compiler_pic_works" >&6; }
19758
19759 if test x"$lt_cv_prog_compiler_pic_works" = xyes; then
19760     case $lt_prog_compiler_pic in
19761      "" | " "*) ;;
19762      *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
19763      esac
19764 else
19765     lt_prog_compiler_pic=
19766      lt_prog_compiler_can_build_shared=no
19767 fi
19768
19769 fi
19770
19771
19772
19773
19774
19775
19776
19777
19778
19779
19780
19781 #
19782 # Check to make sure the static flag actually works.
19783 #
19784 wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\"
19785 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
19786 $as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
19787 if ${lt_cv_prog_compiler_static_works+:} false; then :
19788   $as_echo_n "(cached) " >&6
19789 else
19790   lt_cv_prog_compiler_static_works=no
19791    save_LDFLAGS="$LDFLAGS"
19792    LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
19793    echo "$lt_simple_link_test_code" > conftest.$ac_ext
19794    if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
19795      # The linker can only warn and ignore the option if not recognized
19796      # So say no if there are warnings
19797      if test -s conftest.err; then
19798        # Append any errors to the config.log.
19799        cat conftest.err 1>&5
19800        $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
19801        $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
19802        if diff conftest.exp conftest.er2 >/dev/null; then
19803          lt_cv_prog_compiler_static_works=yes
19804        fi
19805      else
19806        lt_cv_prog_compiler_static_works=yes
19807      fi
19808    fi
19809    $RM -r conftest*
19810    LDFLAGS="$save_LDFLAGS"
19811
19812 fi
19813 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5
19814 $as_echo "$lt_cv_prog_compiler_static_works" >&6; }
19815
19816 if test x"$lt_cv_prog_compiler_static_works" = xyes; then
19817     :
19818 else
19819     lt_prog_compiler_static=
19820 fi
19821
19822
19823
19824
19825
19826
19827
19828   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
19829 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
19830 if ${lt_cv_prog_compiler_c_o+:} false; then :
19831   $as_echo_n "(cached) " >&6
19832 else
19833   lt_cv_prog_compiler_c_o=no
19834    $RM -r conftest 2>/dev/null
19835    mkdir conftest
19836    cd conftest
19837    mkdir out
19838    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
19839
19840    lt_compiler_flag="-o out/conftest2.$ac_objext"
19841    # Insert the option either (1) after the last *FLAGS variable, or
19842    # (2) before a word containing "conftest.", or (3) at the end.
19843    # Note that $ac_compile itself does not contain backslashes and begins
19844    # with a dollar sign (not a hyphen), so the echo should work correctly.
19845    lt_compile=`echo "$ac_compile" | $SED \
19846    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
19847    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
19848    -e 's:$: $lt_compiler_flag:'`
19849    (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
19850    (eval "$lt_compile" 2>out/conftest.err)
19851    ac_status=$?
19852    cat out/conftest.err >&5
19853    echo "$as_me:$LINENO: \$? = $ac_status" >&5
19854    if (exit $ac_status) && test -s out/conftest2.$ac_objext
19855    then
19856      # The compiler can only warn and ignore the option if not recognized
19857      # So say no if there are warnings
19858      $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
19859      $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
19860      if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
19861        lt_cv_prog_compiler_c_o=yes
19862      fi
19863    fi
19864    chmod u+w . 2>&5
19865    $RM conftest*
19866    # SGI C++ compiler will create directory out/ii_files/ for
19867    # template instantiation
19868    test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
19869    $RM out/* && rmdir out
19870    cd ..
19871    $RM -r conftest
19872    $RM conftest*
19873
19874 fi
19875 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
19876 $as_echo "$lt_cv_prog_compiler_c_o" >&6; }
19877
19878
19879
19880
19881
19882
19883   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
19884 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
19885 if ${lt_cv_prog_compiler_c_o+:} false; then :
19886   $as_echo_n "(cached) " >&6
19887 else
19888   lt_cv_prog_compiler_c_o=no
19889    $RM -r conftest 2>/dev/null
19890    mkdir conftest
19891    cd conftest
19892    mkdir out
19893    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
19894
19895    lt_compiler_flag="-o out/conftest2.$ac_objext"
19896    # Insert the option either (1) after the last *FLAGS variable, or
19897    # (2) before a word containing "conftest.", or (3) at the end.
19898    # Note that $ac_compile itself does not contain backslashes and begins
19899    # with a dollar sign (not a hyphen), so the echo should work correctly.
19900    lt_compile=`echo "$ac_compile" | $SED \
19901    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
19902    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
19903    -e 's:$: $lt_compiler_flag:'`
19904    (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
19905    (eval "$lt_compile" 2>out/conftest.err)
19906    ac_status=$?
19907    cat out/conftest.err >&5
19908    echo "$as_me:$LINENO: \$? = $ac_status" >&5
19909    if (exit $ac_status) && test -s out/conftest2.$ac_objext
19910    then
19911      # The compiler can only warn and ignore the option if not recognized
19912      # So say no if there are warnings
19913      $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
19914      $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
19915      if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
19916        lt_cv_prog_compiler_c_o=yes
19917      fi
19918    fi
19919    chmod u+w . 2>&5
19920    $RM conftest*
19921    # SGI C++ compiler will create directory out/ii_files/ for
19922    # template instantiation
19923    test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
19924    $RM out/* && rmdir out
19925    cd ..
19926    $RM -r conftest
19927    $RM conftest*
19928
19929 fi
19930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
19931 $as_echo "$lt_cv_prog_compiler_c_o" >&6; }
19932
19933
19934
19935
19936 hard_links="nottested"
19937 if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then
19938   # do not overwrite the value of need_locks provided by the user
19939   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
19940 $as_echo_n "checking if we can lock with hard links... " >&6; }
19941   hard_links=yes
19942   $RM conftest*
19943   ln conftest.a conftest.b 2>/dev/null && hard_links=no
19944   touch conftest.a
19945   ln conftest.a conftest.b 2>&5 || hard_links=no
19946   ln conftest.a conftest.b 2>/dev/null && hard_links=no
19947   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
19948 $as_echo "$hard_links" >&6; }
19949   if test "$hard_links" = no; then
19950     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
19951 $as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
19952     need_locks=warn
19953   fi
19954 else
19955   need_locks=no
19956 fi
19957
19958
19959
19960
19961
19962
19963   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
19964 $as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
19965
19966   runpath_var=
19967   allow_undefined_flag=
19968   always_export_symbols=no
19969   archive_cmds=
19970   archive_expsym_cmds=
19971   compiler_needs_object=no
19972   enable_shared_with_static_runtimes=no
19973   export_dynamic_flag_spec=
19974   export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
19975   hardcode_automatic=no
19976   hardcode_direct=no
19977   hardcode_direct_absolute=no
19978   hardcode_libdir_flag_spec=
19979   hardcode_libdir_flag_spec_ld=
19980   hardcode_libdir_separator=
19981   hardcode_minus_L=no
19982   hardcode_shlibpath_var=unsupported
19983   inherit_rpath=no
19984   link_all_deplibs=unknown
19985   module_cmds=
19986   module_expsym_cmds=
19987   old_archive_from_new_cmds=
19988   old_archive_from_expsyms_cmds=
19989   thread_safe_flag_spec=
19990   whole_archive_flag_spec=
19991   # include_expsyms should be a list of space-separated symbols to be *always*
19992   # included in the symbol list
19993   include_expsyms=
19994   # exclude_expsyms can be an extended regexp of symbols to exclude
19995   # it will be wrapped by ` (' and `)$', so one must not match beginning or
19996   # end of line.  Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
19997   # as well as any symbol that contains `d'.
19998   exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
19999   # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
20000   # platforms (ab)use it in PIC code, but their linkers get confused if
20001   # the symbol is explicitly referenced.  Since portable code cannot
20002   # rely on this symbol name, it's probably fine to never include it in
20003   # preloaded symbol tables.
20004   # Exclude shared library initialization/finalization symbols.
20005   extract_expsyms_cmds=
20006
20007   case $host_os in
20008   cygwin* | mingw* | pw32* | cegcc*)
20009     # FIXME: the MSVC++ port hasn't been tested in a loooong time
20010     # When not using gcc, we currently assume that we are using
20011     # Microsoft Visual C++.
20012     if test "$GCC" != yes; then
20013       with_gnu_ld=no
20014     fi
20015     ;;
20016   interix*)
20017     # we just hope/assume this is gcc and not c89 (= MSVC++)
20018     with_gnu_ld=yes
20019     ;;
20020   openbsd*)
20021     with_gnu_ld=no
20022     ;;
20023   esac
20024
20025   ld_shlibs=yes
20026
20027   # On some targets, GNU ld is compatible enough with the native linker
20028   # that we're better off using the native interface for both.
20029   lt_use_gnu_ld_interface=no
20030   if test "$with_gnu_ld" = yes; then
20031     case $host_os in
20032       aix*)
20033         # The AIX port of GNU ld has always aspired to compatibility
20034         # with the native linker.  However, as the warning in the GNU ld
20035         # block says, versions before 2.19.5* couldn't really create working
20036         # shared libraries, regardless of the interface used.
20037         case `$LD -v 2>&1` in
20038           *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
20039           *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;;
20040           *\ \(GNU\ Binutils\)\ [3-9]*) ;;
20041           *)
20042             lt_use_gnu_ld_interface=yes
20043             ;;
20044         esac
20045         ;;
20046       *)
20047         lt_use_gnu_ld_interface=yes
20048         ;;
20049     esac
20050   fi
20051
20052   if test "$lt_use_gnu_ld_interface" = yes; then
20053     # If archive_cmds runs LD, not CC, wlarc should be empty
20054     wlarc='${wl}'
20055
20056     # Set some defaults for GNU ld with shared library support. These
20057     # are reset later if shared libraries are not supported. Putting them
20058     # here allows them to be overridden if necessary.
20059     runpath_var=LD_RUN_PATH
20060     hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
20061     export_dynamic_flag_spec='${wl}--export-dynamic'
20062     # ancient GNU ld didn't support --whole-archive et. al.
20063     if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
20064       whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
20065     else
20066       whole_archive_flag_spec=
20067     fi
20068     supports_anon_versioning=no
20069     case `$LD -v 2>&1` in
20070       *GNU\ gold*) supports_anon_versioning=yes ;;
20071       *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
20072       *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
20073       *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
20074       *\ 2.11.*) ;; # other 2.11 versions
20075       *) supports_anon_versioning=yes ;;
20076     esac
20077
20078     # See if GNU ld supports shared libraries.
20079     case $host_os in
20080     aix[3-9]*)
20081       # On AIX/PPC, the GNU linker is very broken
20082       if test "$host_cpu" != ia64; then
20083         ld_shlibs=no
20084         cat <<_LT_EOF 1>&2
20085
20086 *** Warning: the GNU linker, at least up to release 2.19, is reported
20087 *** to be unable to reliably create shared libraries on AIX.
20088 *** Therefore, libtool is disabling shared libraries support.  If you
20089 *** really care for shared libraries, you may want to install binutils
20090 *** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
20091 *** You will then need to restart the configuration process.
20092
20093 _LT_EOF
20094       fi
20095       ;;
20096
20097     amigaos*)
20098       case $host_cpu in
20099       powerpc)
20100             # see comment about AmigaOS4 .so support
20101             archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
20102             archive_expsym_cmds=''
20103         ;;
20104       m68k)
20105             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)'
20106             hardcode_libdir_flag_spec='-L$libdir'
20107             hardcode_minus_L=yes
20108         ;;
20109       esac
20110       ;;
20111
20112     beos*)
20113       if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
20114         allow_undefined_flag=unsupported
20115         # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
20116         # support --undefined.  This deserves some investigation.  FIXME
20117         archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
20118       else
20119         ld_shlibs=no
20120       fi
20121       ;;
20122
20123     cygwin* | mingw* | pw32* | cegcc*)
20124       # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
20125       # as there is no search path for DLLs.
20126       hardcode_libdir_flag_spec='-L$libdir'
20127       export_dynamic_flag_spec='${wl}--export-all-symbols'
20128       allow_undefined_flag=unsupported
20129       always_export_symbols=no
20130       enable_shared_with_static_runtimes=yes
20131       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'
20132       exclude_expsyms='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'
20133
20134       if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
20135         archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
20136         # If the export-symbols file already is a .def file (1st line
20137         # is EXPORTS), use it as is; otherwise, prepend...
20138         archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
20139           cp $export_symbols $output_objdir/$soname.def;
20140         else
20141           echo EXPORTS > $output_objdir/$soname.def;
20142           cat $export_symbols >> $output_objdir/$soname.def;
20143         fi~
20144         $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
20145       else
20146         ld_shlibs=no
20147       fi
20148       ;;
20149
20150     haiku*)
20151       archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
20152       link_all_deplibs=yes
20153       ;;
20154
20155     interix[3-9]*)
20156       hardcode_direct=no
20157       hardcode_shlibpath_var=no
20158       hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
20159       export_dynamic_flag_spec='${wl}-E'
20160       # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
20161       # Instead, shared libraries are loaded at an image base (0x10000000 by
20162       # default) and relocated if they conflict, which is a slow very memory
20163       # consuming and fragmenting process.  To avoid this, we pick a random,
20164       # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
20165       # time.  Moving up from 0x10000000 also allows more sbrk(2) space.
20166       archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
20167       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'
20168       ;;
20169
20170     gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu)
20171       tmp_diet=no
20172       if test "$host_os" = linux-dietlibc; then
20173         case $cc_basename in
20174           diet\ *) tmp_diet=yes;;       # linux-dietlibc with static linking (!diet-dyn)
20175         esac
20176       fi
20177       if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
20178          && test "$tmp_diet" = no
20179       then
20180         tmp_addflag=' $pic_flag'
20181         tmp_sharedflag='-shared'
20182         case $cc_basename,$host_cpu in
20183         pgcc*)                          # Portland Group C compiler
20184           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'
20185           tmp_addflag=' $pic_flag'
20186           ;;
20187         pgf77* | pgf90* | pgf95* | pgfortran*)
20188                                         # Portland Group f77 and f90 compilers
20189           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'
20190           tmp_addflag=' $pic_flag -Mnomain' ;;
20191         ecc*,ia64* | icc*,ia64*)        # Intel C compiler on ia64
20192           tmp_addflag=' -i_dynamic' ;;
20193         efc*,ia64* | ifort*,ia64*)      # Intel Fortran compiler on ia64
20194           tmp_addflag=' -i_dynamic -nofor_main' ;;
20195         ifc* | ifort*)                  # Intel Fortran compiler
20196           tmp_addflag=' -nofor_main' ;;
20197         lf95*)                          # Lahey Fortran 8.1
20198           whole_archive_flag_spec=
20199           tmp_sharedflag='--shared' ;;
20200         xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below)
20201           tmp_sharedflag='-qmkshrobj'
20202           tmp_addflag= ;;
20203         nvcc*)  # Cuda Compiler Driver 2.2
20204           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'
20205           compiler_needs_object=yes
20206           ;;
20207         esac
20208         case `$CC -V 2>&1 | sed 5q` in
20209         *Sun\ C*)                       # Sun C 5.9
20210           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'
20211           compiler_needs_object=yes
20212           tmp_sharedflag='-G' ;;
20213         *Sun\ F*)                       # Sun Fortran 8.3
20214           tmp_sharedflag='-G' ;;
20215         esac
20216         archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
20217
20218         if test "x$supports_anon_versioning" = xyes; then
20219           archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
20220             cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
20221             echo "local: *; };" >> $output_objdir/$libname.ver~
20222             $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
20223         fi
20224
20225         case $cc_basename in
20226         xlf* | bgf* | bgxlf* | mpixlf*)
20227           # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
20228           whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
20229           hardcode_libdir_flag_spec=
20230           hardcode_libdir_flag_spec_ld='-rpath $libdir'
20231           archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib'
20232           if test "x$supports_anon_versioning" = xyes; then
20233             archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
20234               cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
20235               echo "local: *; };" >> $output_objdir/$libname.ver~
20236               $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
20237           fi
20238           ;;
20239         esac
20240       else
20241         ld_shlibs=no
20242       fi
20243       ;;
20244
20245     netbsd*)
20246       if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
20247         archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
20248         wlarc=
20249       else
20250         archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
20251         archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
20252       fi
20253       ;;
20254
20255     solaris*)
20256       if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
20257         ld_shlibs=no
20258         cat <<_LT_EOF 1>&2
20259
20260 *** Warning: The releases 2.8.* of the GNU linker cannot reliably
20261 *** create shared libraries on Solaris systems.  Therefore, libtool
20262 *** is disabling shared libraries support.  We urge you to upgrade GNU
20263 *** binutils to release 2.9.1 or newer.  Another option is to modify
20264 *** your PATH or compiler configuration so that the native linker is
20265 *** used, and then restart.
20266
20267 _LT_EOF
20268       elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
20269         archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
20270         archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
20271       else
20272         ld_shlibs=no
20273       fi
20274       ;;
20275
20276     sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
20277       case `$LD -v 2>&1` in
20278         *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*)
20279         ld_shlibs=no
20280         cat <<_LT_EOF 1>&2
20281
20282 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
20283 *** reliably create shared libraries on SCO systems.  Therefore, libtool
20284 *** is disabling shared libraries support.  We urge you to upgrade GNU
20285 *** binutils to release 2.16.91.0.3 or newer.  Another option is to modify
20286 *** your PATH or compiler configuration so that the native linker is
20287 *** used, and then restart.
20288
20289 _LT_EOF
20290         ;;
20291         *)
20292           # For security reasons, it is highly recommended that you always
20293           # use absolute paths for naming shared libraries, and exclude the
20294           # DT_RUNPATH tag from executables and libraries.  But doing so
20295           # requires that you compile everything twice, which is a pain.
20296           if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
20297             hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
20298             archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
20299             archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
20300           else
20301             ld_shlibs=no
20302           fi
20303         ;;
20304       esac
20305       ;;
20306
20307     sunos4*)
20308       archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
20309       wlarc=
20310       hardcode_direct=yes
20311       hardcode_shlibpath_var=no
20312       ;;
20313
20314     *)
20315       if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
20316         archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
20317         archive_expsym_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
20318       else
20319         ld_shlibs=no
20320       fi
20321       ;;
20322     esac
20323
20324     if test "$ld_shlibs" = no; then
20325       runpath_var=
20326       hardcode_libdir_flag_spec=
20327       export_dynamic_flag_spec=
20328       whole_archive_flag_spec=
20329     fi
20330   else
20331     # PORTME fill in a description of your system's linker (not GNU ld)
20332     case $host_os in
20333     aix3*)
20334       allow_undefined_flag=unsupported
20335       always_export_symbols=yes
20336       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'
20337       # Note: this linker hardcodes the directories in LIBPATH if there
20338       # are no directories specified by -L.
20339       hardcode_minus_L=yes
20340       if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
20341         # Neither direct hardcoding nor static linking is supported with a
20342         # broken collect2.
20343         hardcode_direct=unsupported
20344       fi
20345       ;;
20346
20347     aix[4-9]*)
20348       if test "$host_cpu" = ia64; then
20349         # On IA64, the linker does run time linking by default, so we don't
20350         # have to do anything special.
20351         aix_use_runtimelinking=no
20352         exp_sym_flag='-Bexport'
20353         no_entry_flag=""
20354       else
20355         # If we're using GNU nm, then we don't want the "-C" option.
20356         # -C means demangle to AIX nm, but means don't demangle with GNU nm
20357         # Also, AIX nm treats weak defined symbols like other global
20358         # defined symbols, whereas GNU nm marks them as "W".
20359         if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
20360           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'
20361         else
20362           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'
20363         fi
20364         aix_use_runtimelinking=no
20365
20366         # Test if we are trying to use run time linking or normal
20367         # AIX style linking. If -brtl is somewhere in LDFLAGS, we
20368         # need to do runtime linking.
20369         case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
20370           for ld_flag in $LDFLAGS; do
20371           if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
20372             aix_use_runtimelinking=yes
20373             break
20374           fi
20375           done
20376           ;;
20377         esac
20378
20379         exp_sym_flag='-bexport'
20380         no_entry_flag='-bnoentry'
20381       fi
20382
20383       # When large executables or shared objects are built, AIX ld can
20384       # have problems creating the table of contents.  If linking a library
20385       # or program results in "error TOC overflow" add -mminimal-toc to
20386       # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
20387       # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
20388
20389       archive_cmds=''
20390       hardcode_direct=yes
20391       hardcode_direct_absolute=yes
20392       hardcode_libdir_separator=':'
20393       link_all_deplibs=yes
20394       file_list_spec='${wl}-f,'
20395
20396       if test "$GCC" = yes; then
20397         case $host_os in aix4.[012]|aix4.[012].*)
20398         # We only want to do this on AIX 4.2 and lower, the check
20399         # below for broken collect2 doesn't work under 4.3+
20400           collect2name=`${CC} -print-prog-name=collect2`
20401           if test -f "$collect2name" &&
20402            strings "$collect2name" | $GREP resolve_lib_name >/dev/null
20403           then
20404           # We have reworked collect2
20405           :
20406           else
20407           # We have old collect2
20408           hardcode_direct=unsupported
20409           # It fails to find uninstalled libraries when the uninstalled
20410           # path is not listed in the libpath.  Setting hardcode_minus_L
20411           # to unsupported forces relinking
20412           hardcode_minus_L=yes
20413           hardcode_libdir_flag_spec='-L$libdir'
20414           hardcode_libdir_separator=
20415           fi
20416           ;;
20417         esac
20418         shared_flag='-shared'
20419         if test "$aix_use_runtimelinking" = yes; then
20420           shared_flag="$shared_flag "'${wl}-G'
20421         fi
20422       else
20423         # not using gcc
20424         if test "$host_cpu" = ia64; then
20425         # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
20426         # chokes on -Wl,-G. The following line is correct:
20427           shared_flag='-G'
20428         else
20429           if test "$aix_use_runtimelinking" = yes; then
20430             shared_flag='${wl}-G'
20431           else
20432             shared_flag='${wl}-bM:SRE'
20433           fi
20434         fi
20435       fi
20436
20437       export_dynamic_flag_spec='${wl}-bexpall'
20438       # It seems that -bexpall does not export symbols beginning with
20439       # underscore (_), so it is better to generate a list of symbols to export.
20440       always_export_symbols=yes
20441       if test "$aix_use_runtimelinking" = yes; then
20442         # Warning - without using the other runtime loading flags (-brtl),
20443         # -berok will link without error, but may produce a broken library.
20444         allow_undefined_flag='-berok'
20445         # Determine the default libpath from the value encoded in an
20446         # empty executable.
20447         if test "${lt_cv_aix_libpath+set}" = set; then
20448   aix_libpath=$lt_cv_aix_libpath
20449 else
20450   if ${lt_cv_aix_libpath_+:} false; then :
20451   $as_echo_n "(cached) " >&6
20452 else
20453   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20454 /* end confdefs.h.  */
20455
20456 int
20457 main ()
20458 {
20459
20460   ;
20461   return 0;
20462 }
20463 _ACEOF
20464 if ac_fn_c_try_link "$LINENO"; then :
20465
20466   lt_aix_libpath_sed='
20467       /Import File Strings/,/^$/ {
20468           /^0/ {
20469               s/^0  *\([^ ]*\) *$/\1/
20470               p
20471           }
20472       }'
20473   lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
20474   # Check for a 64-bit object if we didn't find anything.
20475   if test -z "$lt_cv_aix_libpath_"; then
20476     lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
20477   fi
20478 fi
20479 rm -f core conftest.err conftest.$ac_objext \
20480     conftest$ac_exeext conftest.$ac_ext
20481   if test -z "$lt_cv_aix_libpath_"; then
20482     lt_cv_aix_libpath_="/usr/lib:/lib"
20483   fi
20484
20485 fi
20486
20487   aix_libpath=$lt_cv_aix_libpath_
20488 fi
20489
20490         hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
20491         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"
20492       else
20493         if test "$host_cpu" = ia64; then
20494           hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
20495           allow_undefined_flag="-z nodefs"
20496           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"
20497         else
20498          # Determine the default libpath from the value encoded in an
20499          # empty executable.
20500          if test "${lt_cv_aix_libpath+set}" = set; then
20501   aix_libpath=$lt_cv_aix_libpath
20502 else
20503   if ${lt_cv_aix_libpath_+:} false; then :
20504   $as_echo_n "(cached) " >&6
20505 else
20506   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20507 /* end confdefs.h.  */
20508
20509 int
20510 main ()
20511 {
20512
20513   ;
20514   return 0;
20515 }
20516 _ACEOF
20517 if ac_fn_c_try_link "$LINENO"; then :
20518
20519   lt_aix_libpath_sed='
20520       /Import File Strings/,/^$/ {
20521           /^0/ {
20522               s/^0  *\([^ ]*\) *$/\1/
20523               p
20524           }
20525       }'
20526   lt_cv_aix_libpath_=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
20527   # Check for a 64-bit object if we didn't find anything.
20528   if test -z "$lt_cv_aix_libpath_"; then
20529     lt_cv_aix_libpath_=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
20530   fi
20531 fi
20532 rm -f core conftest.err conftest.$ac_objext \
20533     conftest$ac_exeext conftest.$ac_ext
20534   if test -z "$lt_cv_aix_libpath_"; then
20535     lt_cv_aix_libpath_="/usr/lib:/lib"
20536   fi
20537
20538 fi
20539
20540   aix_libpath=$lt_cv_aix_libpath_
20541 fi
20542
20543          hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
20544           # Warning - without using the other run time loading flags,
20545           # -berok will link without error, but may produce a broken library.
20546           no_undefined_flag=' ${wl}-bernotok'
20547           allow_undefined_flag=' ${wl}-berok'
20548           if test "$with_gnu_ld" = yes; then
20549             # We only use this code for GNU lds that support --whole-archive.
20550             whole_archive_flag_spec='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
20551           else
20552             # Exported symbols can be pulled into shared objects from archives
20553             whole_archive_flag_spec='$convenience'
20554           fi
20555           archive_cmds_need_lc=yes
20556           # This is similar to how AIX traditionally builds its shared libraries.
20557           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'
20558         fi
20559       fi
20560       ;;
20561
20562     amigaos*)
20563       case $host_cpu in
20564       powerpc)
20565             # see comment about AmigaOS4 .so support
20566             archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
20567             archive_expsym_cmds=''
20568         ;;
20569       m68k)
20570             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)'
20571             hardcode_libdir_flag_spec='-L$libdir'
20572             hardcode_minus_L=yes
20573         ;;
20574       esac
20575       ;;
20576
20577     bsdi[45]*)
20578       export_dynamic_flag_spec=-rdynamic
20579       ;;
20580
20581     cygwin* | mingw* | pw32* | cegcc*)
20582       # When not using gcc, we currently assume that we are using
20583       # Microsoft Visual C++.
20584       # hardcode_libdir_flag_spec is actually meaningless, as there is
20585       # no search path for DLLs.
20586       case $cc_basename in
20587       cl*)
20588         # Native MSVC
20589         hardcode_libdir_flag_spec=' '
20590         allow_undefined_flag=unsupported
20591         always_export_symbols=yes
20592         file_list_spec='@'
20593         # Tell ltmain to make .lib files, not .a files.
20594         libext=lib
20595         # Tell ltmain to make .dll files, not .so files.
20596         shrext_cmds=".dll"
20597         # FIXME: Setting linknames here is a bad hack.
20598         archive_cmds='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
20599         archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
20600             sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
20601           else
20602             sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
20603           fi~
20604           $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
20605           linknames='
20606         # The linker will not automatically build a static lib if we build a DLL.
20607         # _LT_TAGVAR(old_archive_from_new_cmds, )='true'
20608         enable_shared_with_static_runtimes=yes
20609         export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1,DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
20610         # Don't use ranlib
20611         old_postinstall_cmds='chmod 644 $oldlib'
20612         postlink_cmds='lt_outputfile="@OUTPUT@"~
20613           lt_tool_outputfile="@TOOL_OUTPUT@"~
20614           case $lt_outputfile in
20615             *.exe|*.EXE) ;;
20616             *)
20617               lt_outputfile="$lt_outputfile.exe"
20618               lt_tool_outputfile="$lt_tool_outputfile.exe"
20619               ;;
20620           esac~
20621           if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
20622             $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
20623             $RM "$lt_outputfile.manifest";
20624           fi'
20625         ;;
20626       *)
20627         # Assume MSVC wrapper
20628         hardcode_libdir_flag_spec=' '
20629         allow_undefined_flag=unsupported
20630         # Tell ltmain to make .lib files, not .a files.
20631         libext=lib
20632         # Tell ltmain to make .dll files, not .so files.
20633         shrext_cmds=".dll"
20634         # FIXME: Setting linknames here is a bad hack.
20635         archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
20636         # The linker will automatically build a .lib file if we build a DLL.
20637         old_archive_from_new_cmds='true'
20638         # FIXME: Should let the user specify the lib program.
20639         old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
20640         enable_shared_with_static_runtimes=yes
20641         ;;
20642       esac
20643       ;;
20644
20645     darwin* | rhapsody*)
20646
20647
20648   archive_cmds_need_lc=no
20649   hardcode_direct=no
20650   hardcode_automatic=yes
20651   hardcode_shlibpath_var=unsupported
20652   if test "$lt_cv_ld_force_load" = "yes"; then
20653     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\"`'
20654   else
20655     whole_archive_flag_spec=''
20656   fi
20657   link_all_deplibs=yes
20658   allow_undefined_flag="$_lt_dar_allow_undefined"
20659   case $cc_basename in
20660      ifort*) _lt_dar_can_shared=yes ;;
20661      *) _lt_dar_can_shared=$GCC ;;
20662   esac
20663   if test "$_lt_dar_can_shared" = "yes"; then
20664     output_verbose_link_cmd=func_echo_all
20665     archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
20666     module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
20667     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}"
20668     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}"
20669
20670   else
20671   ld_shlibs=no
20672   fi
20673
20674       ;;
20675
20676     dgux*)
20677       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
20678       hardcode_libdir_flag_spec='-L$libdir'
20679       hardcode_shlibpath_var=no
20680       ;;
20681
20682     freebsd1*)
20683       ld_shlibs=no
20684       ;;
20685
20686     # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
20687     # support.  Future versions do this automatically, but an explicit c++rt0.o
20688     # does not break anything, and helps significantly (at the cost of a little
20689     # extra space).
20690     freebsd2.2*)
20691       archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
20692       hardcode_libdir_flag_spec='-R$libdir'
20693       hardcode_direct=yes
20694       hardcode_shlibpath_var=no
20695       ;;
20696
20697     # Unfortunately, older versions of FreeBSD 2 do not have this feature.
20698     freebsd2*)
20699       archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
20700       hardcode_direct=yes
20701       hardcode_minus_L=yes
20702       hardcode_shlibpath_var=no
20703       ;;
20704
20705     # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
20706     freebsd* | dragonfly*)
20707       archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
20708       hardcode_libdir_flag_spec='-R$libdir'
20709       hardcode_direct=yes
20710       hardcode_shlibpath_var=no
20711       ;;
20712
20713     hpux9*)
20714       if test "$GCC" = yes; then
20715         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'
20716       else
20717         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'
20718       fi
20719       hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
20720       hardcode_libdir_separator=:
20721       hardcode_direct=yes
20722
20723       # hardcode_minus_L: Not really in the search PATH,
20724       # but as the default location of the library.
20725       hardcode_minus_L=yes
20726       export_dynamic_flag_spec='${wl}-E'
20727       ;;
20728
20729     hpux10*)
20730       if test "$GCC" = yes && test "$with_gnu_ld" = no; then
20731         archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
20732       else
20733         archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
20734       fi
20735       if test "$with_gnu_ld" = no; then
20736         hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
20737         hardcode_libdir_flag_spec_ld='+b $libdir'
20738         hardcode_libdir_separator=:
20739         hardcode_direct=yes
20740         hardcode_direct_absolute=yes
20741         export_dynamic_flag_spec='${wl}-E'
20742         # hardcode_minus_L: Not really in the search PATH,
20743         # but as the default location of the library.
20744         hardcode_minus_L=yes
20745       fi
20746       ;;
20747
20748     hpux11*)
20749       if test "$GCC" = yes && test "$with_gnu_ld" = no; then
20750         case $host_cpu in
20751         hppa*64*)
20752           archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
20753           ;;
20754         ia64*)
20755           archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
20756           ;;
20757         *)
20758           archive_cmds='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
20759           ;;
20760         esac
20761       else
20762         case $host_cpu in
20763         hppa*64*)
20764           archive_cmds='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
20765           ;;
20766         ia64*)
20767           archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
20768           ;;
20769         *)
20770
20771           # Older versions of the 11.00 compiler do not understand -b yet
20772           # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
20773           { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5
20774 $as_echo_n "checking if $CC understands -b... " >&6; }
20775 if ${lt_cv_prog_compiler__b+:} false; then :
20776   $as_echo_n "(cached) " >&6
20777 else
20778   lt_cv_prog_compiler__b=no
20779    save_LDFLAGS="$LDFLAGS"
20780    LDFLAGS="$LDFLAGS -b"
20781    echo "$lt_simple_link_test_code" > conftest.$ac_ext
20782    if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
20783      # The linker can only warn and ignore the option if not recognized
20784      # So say no if there are warnings
20785      if test -s conftest.err; then
20786        # Append any errors to the config.log.
20787        cat conftest.err 1>&5
20788        $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
20789        $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
20790        if diff conftest.exp conftest.er2 >/dev/null; then
20791          lt_cv_prog_compiler__b=yes
20792        fi
20793      else
20794        lt_cv_prog_compiler__b=yes
20795      fi
20796    fi
20797    $RM -r conftest*
20798    LDFLAGS="$save_LDFLAGS"
20799
20800 fi
20801 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5
20802 $as_echo "$lt_cv_prog_compiler__b" >&6; }
20803
20804 if test x"$lt_cv_prog_compiler__b" = xyes; then
20805     archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
20806 else
20807     archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
20808 fi
20809
20810           ;;
20811         esac
20812       fi
20813       if test "$with_gnu_ld" = no; then
20814         hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
20815         hardcode_libdir_separator=:
20816
20817         case $host_cpu in
20818         hppa*64*|ia64*)
20819           hardcode_direct=no
20820           hardcode_shlibpath_var=no
20821           ;;
20822         *)
20823           hardcode_direct=yes
20824           hardcode_direct_absolute=yes
20825           export_dynamic_flag_spec='${wl}-E'
20826
20827           # hardcode_minus_L: Not really in the search PATH,
20828           # but as the default location of the library.
20829           hardcode_minus_L=yes
20830           ;;
20831         esac
20832       fi
20833       ;;
20834
20835     irix5* | irix6* | nonstopux*)
20836       if test "$GCC" = yes; then
20837         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'
20838         # Try to use the -exported_symbol ld option, if it does not
20839         # work, assume that -exports_file does not work either and
20840         # implicitly export all symbols.
20841         # This should be the same for all languages, so no per-tag cache variable.
20842         { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $host_os linker accepts -exported_symbol" >&5
20843 $as_echo_n "checking whether the $host_os linker accepts -exported_symbol... " >&6; }
20844 if ${lt_cv_irix_exported_symbol+:} false; then :
20845   $as_echo_n "(cached) " >&6
20846 else
20847   save_LDFLAGS="$LDFLAGS"
20848            LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
20849            cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20850 /* end confdefs.h.  */
20851 int foo (void) { return 0; }
20852 _ACEOF
20853 if ac_fn_c_try_link "$LINENO"; then :
20854   lt_cv_irix_exported_symbol=yes
20855 else
20856   lt_cv_irix_exported_symbol=no
20857 fi
20858 rm -f core conftest.err conftest.$ac_objext \
20859     conftest$ac_exeext conftest.$ac_ext
20860            LDFLAGS="$save_LDFLAGS"
20861 fi
20862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_irix_exported_symbol" >&5
20863 $as_echo "$lt_cv_irix_exported_symbol" >&6; }
20864         if test "$lt_cv_irix_exported_symbol" = yes; then
20865           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'
20866         fi
20867       else
20868         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'
20869         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'
20870       fi
20871       archive_cmds_need_lc='no'
20872       hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
20873       hardcode_libdir_separator=:
20874       inherit_rpath=yes
20875       link_all_deplibs=yes
20876       ;;
20877
20878     netbsd*)
20879       if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
20880         archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'  # a.out
20881       else
20882         archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags'      # ELF
20883       fi
20884       hardcode_libdir_flag_spec='-R$libdir'
20885       hardcode_direct=yes
20886       hardcode_shlibpath_var=no
20887       ;;
20888
20889     newsos6)
20890       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
20891       hardcode_direct=yes
20892       hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
20893       hardcode_libdir_separator=:
20894       hardcode_shlibpath_var=no
20895       ;;
20896
20897     *nto* | *qnx*)
20898       ;;
20899
20900     openbsd*)
20901       if test -f /usr/libexec/ld.so; then
20902         hardcode_direct=yes
20903         hardcode_shlibpath_var=no
20904         hardcode_direct_absolute=yes
20905         if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
20906           archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
20907           archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
20908           hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
20909           export_dynamic_flag_spec='${wl}-E'
20910         else
20911           case $host_os in
20912            openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
20913              archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
20914              hardcode_libdir_flag_spec='-R$libdir'
20915              ;;
20916            *)
20917              archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
20918              hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
20919              ;;
20920           esac
20921         fi
20922       else
20923         ld_shlibs=no
20924       fi
20925       ;;
20926
20927     os2*)
20928       hardcode_libdir_flag_spec='-L$libdir'
20929       hardcode_minus_L=yes
20930       allow_undefined_flag=unsupported
20931       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'
20932       old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
20933       ;;
20934
20935     osf3*)
20936       if test "$GCC" = yes; then
20937         allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
20938         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'
20939       else
20940         allow_undefined_flag=' -expect_unresolved \*'
20941         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'
20942       fi
20943       archive_cmds_need_lc='no'
20944       hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
20945       hardcode_libdir_separator=:
20946       ;;
20947
20948     osf4* | osf5*)      # as osf3* with the addition of -msym flag
20949       if test "$GCC" = yes; then
20950         allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
20951         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'
20952         hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
20953       else
20954         allow_undefined_flag=' -expect_unresolved \*'
20955         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'
20956         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~
20957         $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'
20958
20959         # Both c and cxx compiler support -rpath directly
20960         hardcode_libdir_flag_spec='-rpath $libdir'
20961       fi
20962       archive_cmds_need_lc='no'
20963       hardcode_libdir_separator=:
20964       ;;
20965
20966     solaris*)
20967       no_undefined_flag=' -z defs'
20968       if test "$GCC" = yes; then
20969         wlarc='${wl}'
20970         archive_cmds='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
20971         archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
20972           $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'
20973       else
20974         case `$CC -V 2>&1` in
20975         *"Compilers 5.0"*)
20976           wlarc=''
20977           archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
20978           archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
20979           $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
20980           ;;
20981         *)
20982           wlarc='${wl}'
20983           archive_cmds='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags'
20984           archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
20985           $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
20986           ;;
20987         esac
20988       fi
20989       hardcode_libdir_flag_spec='-R$libdir'
20990       hardcode_shlibpath_var=no
20991       case $host_os in
20992       solaris2.[0-5] | solaris2.[0-5].*) ;;
20993       *)
20994         # The compiler driver will combine and reorder linker options,
20995         # but understands `-z linker_flag'.  GCC discards it without `$wl',
20996         # but is careful enough not to reorder.
20997         # Supported since Solaris 2.6 (maybe 2.5.1?)
20998         if test "$GCC" = yes; then
20999           whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
21000         else
21001           whole_archive_flag_spec='-z allextract$convenience -z defaultextract'
21002         fi
21003         ;;
21004       esac
21005       link_all_deplibs=yes
21006       ;;
21007
21008     sunos4*)
21009       if test "x$host_vendor" = xsequent; then
21010         # Use $CC to link under sequent, because it throws in some extra .o
21011         # files that make .init and .fini sections work.
21012         archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
21013       else
21014         archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
21015       fi
21016       hardcode_libdir_flag_spec='-L$libdir'
21017       hardcode_direct=yes
21018       hardcode_minus_L=yes
21019       hardcode_shlibpath_var=no
21020       ;;
21021
21022     sysv4)
21023       case $host_vendor in
21024         sni)
21025           archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
21026           hardcode_direct=yes # is this really true???
21027         ;;
21028         siemens)
21029           ## LD is ld it makes a PLAMLIB
21030           ## CC just makes a GrossModule.
21031           archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
21032           reload_cmds='$CC -r -o $output$reload_objs'
21033           hardcode_direct=no
21034         ;;
21035         motorola)
21036           archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
21037           hardcode_direct=no #Motorola manual says yes, but my tests say they lie
21038         ;;
21039       esac
21040       runpath_var='LD_RUN_PATH'
21041       hardcode_shlibpath_var=no
21042       ;;
21043
21044     sysv4.3*)
21045       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
21046       hardcode_shlibpath_var=no
21047       export_dynamic_flag_spec='-Bexport'
21048       ;;
21049
21050     sysv4*MP*)
21051       if test -d /usr/nec; then
21052         archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
21053         hardcode_shlibpath_var=no
21054         runpath_var=LD_RUN_PATH
21055         hardcode_runpath_var=yes
21056         ld_shlibs=yes
21057       fi
21058       ;;
21059
21060     sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
21061       no_undefined_flag='${wl}-z,text'
21062       archive_cmds_need_lc=no
21063       hardcode_shlibpath_var=no
21064       runpath_var='LD_RUN_PATH'
21065
21066       if test "$GCC" = yes; then
21067         archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
21068         archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
21069       else
21070         archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
21071         archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
21072       fi
21073       ;;
21074
21075     sysv5* | sco3.2v5* | sco5v6*)
21076       # Note: We can NOT use -z defs as we might desire, because we do not
21077       # link with -lc, and that would cause any symbols used from libc to
21078       # always be unresolved, which means just about no library would
21079       # ever link correctly.  If we're not using GNU ld we use -z text
21080       # though, which does catch some bad symbols but isn't as heavy-handed
21081       # as -z defs.
21082       no_undefined_flag='${wl}-z,text'
21083       allow_undefined_flag='${wl}-z,nodefs'
21084       archive_cmds_need_lc=no
21085       hardcode_shlibpath_var=no
21086       hardcode_libdir_flag_spec='${wl}-R,$libdir'
21087       hardcode_libdir_separator=':'
21088       link_all_deplibs=yes
21089       export_dynamic_flag_spec='${wl}-Bexport'
21090       runpath_var='LD_RUN_PATH'
21091
21092       if test "$GCC" = yes; then
21093         archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
21094         archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
21095       else
21096         archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
21097         archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
21098       fi
21099       ;;
21100
21101     uts4*)
21102       archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
21103       hardcode_libdir_flag_spec='-L$libdir'
21104       hardcode_shlibpath_var=no
21105       ;;
21106
21107     *)
21108       ld_shlibs=no
21109       ;;
21110     esac
21111
21112     if test x$host_vendor = xsni; then
21113       case $host in
21114       sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
21115         export_dynamic_flag_spec='${wl}-Blargedynsym'
21116         ;;
21117       esac
21118     fi
21119   fi
21120
21121 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5
21122 $as_echo "$ld_shlibs" >&6; }
21123 test "$ld_shlibs" = no && can_build_shared=no
21124
21125 with_gnu_ld=$with_gnu_ld
21126
21127
21128
21129
21130
21131
21132
21133
21134
21135
21136
21137
21138
21139
21140
21141 #
21142 # Do we need to explicitly link libc?
21143 #
21144 case "x$archive_cmds_need_lc" in
21145 x|xyes)
21146   # Assume -lc should be added
21147   archive_cmds_need_lc=yes
21148
21149   if test "$enable_shared" = yes && test "$GCC" = yes; then
21150     case $archive_cmds in
21151     *'~'*)
21152       # FIXME: we may have to deal with multi-command sequences.
21153       ;;
21154     '$CC '*)
21155       # Test whether the compiler implicitly links with -lc since on some
21156       # systems, -lgcc has to come before -lc. If gcc already passes -lc
21157       # to ld, don't add -lc before -lgcc.
21158       { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
21159 $as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
21160 if ${lt_cv_archive_cmds_need_lc+:} false; then :
21161   $as_echo_n "(cached) " >&6
21162 else
21163   $RM conftest*
21164         echo "$lt_simple_compile_test_code" > conftest.$ac_ext
21165
21166         if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
21167   (eval $ac_compile) 2>&5
21168   ac_status=$?
21169   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
21170   test $ac_status = 0; } 2>conftest.err; then
21171           soname=conftest
21172           lib=conftest
21173           libobjs=conftest.$ac_objext
21174           deplibs=
21175           wl=$lt_prog_compiler_wl
21176           pic_flag=$lt_prog_compiler_pic
21177           compiler_flags=-v
21178           linker_flags=-v
21179           verstring=
21180           output_objdir=.
21181           libname=conftest
21182           lt_save_allow_undefined_flag=$allow_undefined_flag
21183           allow_undefined_flag=
21184           if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
21185   (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
21186   ac_status=$?
21187   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
21188   test $ac_status = 0; }
21189           then
21190             lt_cv_archive_cmds_need_lc=no
21191           else
21192             lt_cv_archive_cmds_need_lc=yes
21193           fi
21194           allow_undefined_flag=$lt_save_allow_undefined_flag
21195         else
21196           cat conftest.err 1>&5
21197         fi
21198         $RM conftest*
21199
21200 fi
21201 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5
21202 $as_echo "$lt_cv_archive_cmds_need_lc" >&6; }
21203       archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc
21204       ;;
21205     esac
21206   fi
21207   ;;
21208 esac
21209
21210
21211
21212
21213
21214
21215
21216
21217
21218
21219
21220
21221
21222
21223
21224
21225
21226
21227
21228
21229
21230
21231
21232
21233
21234
21235
21236
21237
21238
21239
21240
21241
21242
21243
21244
21245
21246
21247
21248
21249
21250
21251
21252
21253
21254
21255
21256
21257
21258
21259
21260
21261
21262
21263
21264
21265
21266
21267
21268
21269
21270
21271
21272
21273
21274
21275
21276
21277
21278
21279
21280
21281
21282
21283
21284
21285
21286
21287
21288
21289
21290
21291
21292
21293
21294
21295
21296
21297
21298
21299
21300
21301
21302
21303
21304
21305
21306
21307
21308
21309
21310
21311
21312
21313
21314
21315
21316
21317
21318
21319
21320
21321
21322
21323
21324
21325
21326
21327
21328
21329
21330
21331
21332
21333
21334
21335
21336
21337
21338
21339
21340
21341
21342
21343
21344
21345
21346
21347
21348
21349
21350
21351
21352
21353
21354
21355
21356
21357
21358
21359
21360
21361
21362
21363
21364
21365
21366   { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
21367 $as_echo_n "checking dynamic linker characteristics... " >&6; }
21368
21369 if test "$GCC" = yes; then
21370   case $host_os in
21371     darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
21372     *) lt_awk_arg="/^libraries:/" ;;
21373   esac
21374   case $host_os in
21375     mingw* | cegcc*) lt_sed_strip_eq="s,=\([A-Za-z]:\),\1,g" ;;
21376     *) lt_sed_strip_eq="s,=/,/,g" ;;
21377   esac
21378   lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
21379   case $lt_search_path_spec in
21380   *\;*)
21381     # if the path contains ";" then we assume it to be the separator
21382     # otherwise default to the standard path separator (i.e. ":") - it is
21383     # assumed that no part of a normal pathname contains ";" but that should
21384     # okay in the real world where ";" in dirpaths is itself problematic.
21385     lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
21386     ;;
21387   *)
21388     lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
21389     ;;
21390   esac
21391   # Ok, now we have the path, separated by spaces, we can step through it
21392   # and add multilib dir if necessary.
21393   lt_tmp_lt_search_path_spec=
21394   lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
21395   for lt_sys_path in $lt_search_path_spec; do
21396     if test -d "$lt_sys_path/$lt_multi_os_dir"; then
21397       lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
21398     else
21399       test -d "$lt_sys_path" && \
21400         lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
21401     fi
21402   done
21403   lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
21404 BEGIN {RS=" "; FS="/|\n";} {
21405   lt_foo="";
21406   lt_count=0;
21407   for (lt_i = NF; lt_i > 0; lt_i--) {
21408     if ($lt_i != "" && $lt_i != ".") {
21409       if ($lt_i == "..") {
21410         lt_count++;
21411       } else {
21412         if (lt_count == 0) {
21413           lt_foo="/" $lt_i lt_foo;
21414         } else {
21415           lt_count--;
21416         }
21417       }
21418     }
21419   }
21420   if (lt_foo != "") { lt_freq[lt_foo]++; }
21421   if (lt_freq[lt_foo] == 1) { print lt_foo; }
21422 }'`
21423   # AWK program above erroneously prepends '/' to C:/dos/paths
21424   # for these hosts.
21425   case $host_os in
21426     mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
21427       $SED 's,/\([A-Za-z]:\),\1,g'` ;;
21428   esac
21429   sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
21430 else
21431   sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
21432 fi
21433 library_names_spec=
21434 libname_spec='lib$name'
21435 soname_spec=
21436 shrext_cmds=".so"
21437 postinstall_cmds=
21438 postuninstall_cmds=
21439 finish_cmds=
21440 finish_eval=
21441 shlibpath_var=
21442 shlibpath_overrides_runpath=unknown
21443 version_type=none
21444 dynamic_linker="$host_os ld.so"
21445 sys_lib_dlsearch_path_spec="/lib /usr/lib"
21446 need_lib_prefix=unknown
21447 hardcode_into_libs=no
21448
21449 # when you set need_version to no, make sure it does not cause -set_version
21450 # flags to be left without arguments
21451 need_version=unknown
21452
21453 case $host_os in
21454 aix3*)
21455   version_type=linux
21456   library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
21457   shlibpath_var=LIBPATH
21458
21459   # AIX 3 has no versioning support, so we append a major version to the name.
21460   soname_spec='${libname}${release}${shared_ext}$major'
21461   ;;
21462
21463 aix[4-9]*)
21464   version_type=linux
21465   need_lib_prefix=no
21466   need_version=no
21467   hardcode_into_libs=yes
21468   if test "$host_cpu" = ia64; then
21469     # AIX 5 supports IA64
21470     library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
21471     shlibpath_var=LD_LIBRARY_PATH
21472   else
21473     # With GCC up to 2.95.x, collect2 would create an import file
21474     # for dependence libraries.  The import file would start with
21475     # the line `#! .'.  This would cause the generated library to
21476     # depend on `.', always an invalid library.  This was fixed in
21477     # development snapshots of GCC prior to 3.0.
21478     case $host_os in
21479       aix4 | aix4.[01] | aix4.[01].*)
21480       if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
21481            echo ' yes '
21482            echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
21483         :
21484       else
21485         can_build_shared=no
21486       fi
21487       ;;
21488     esac
21489     # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
21490     # soname into executable. Probably we can add versioning support to
21491     # collect2, so additional links can be useful in future.
21492     if test "$aix_use_runtimelinking" = yes; then
21493       # If using run time linking (on AIX 4.2 or later) use lib<name>.so
21494       # instead of lib<name>.a to let people know that these are not
21495       # typical AIX shared libraries.
21496       library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
21497     else
21498       # We preserve .a as extension for shared libraries through AIX4.2
21499       # and later when we are not doing run time linking.
21500       library_names_spec='${libname}${release}.a $libname.a'
21501       soname_spec='${libname}${release}${shared_ext}$major'
21502     fi
21503     shlibpath_var=LIBPATH
21504   fi
21505   ;;
21506
21507 amigaos*)
21508   case $host_cpu in
21509   powerpc)
21510     # Since July 2007 AmigaOS4 officially supports .so libraries.
21511     # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
21512     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
21513     ;;
21514   m68k)
21515     library_names_spec='$libname.ixlibrary $libname.a'
21516     # Create ${libname}_ixlibrary.a entries in /sys/libs.
21517     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'
21518     ;;
21519   esac
21520   ;;
21521
21522 beos*)
21523   library_names_spec='${libname}${shared_ext}'
21524   dynamic_linker="$host_os ld.so"
21525   shlibpath_var=LIBRARY_PATH
21526   ;;
21527
21528 bsdi[45]*)
21529   version_type=linux
21530   need_version=no
21531   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
21532   soname_spec='${libname}${release}${shared_ext}$major'
21533   finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
21534   shlibpath_var=LD_LIBRARY_PATH
21535   sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
21536   sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
21537   # the default ld.so.conf also contains /usr/contrib/lib and
21538   # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
21539   # libtool to hard-code these into programs
21540   ;;
21541
21542 cygwin* | mingw* | pw32* | cegcc*)
21543   version_type=windows
21544   shrext_cmds=".dll"
21545   need_version=no
21546   need_lib_prefix=no
21547
21548   case $GCC,$cc_basename in
21549   yes,*)
21550     # gcc
21551     library_names_spec='$libname.dll.a'
21552     # DLL is installed to $(libdir)/../bin by postinstall_cmds
21553     postinstall_cmds='base_file=`basename \${file}`~
21554       dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
21555       dldir=$destdir/`dirname \$dlpath`~
21556       test -d \$dldir || mkdir -p \$dldir~
21557       $install_prog $dir/$dlname \$dldir/$dlname~
21558       chmod a+x \$dldir/$dlname~
21559       if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
21560         eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
21561       fi'
21562     postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
21563       dlpath=$dir/\$dldll~
21564        $RM \$dlpath'
21565     shlibpath_overrides_runpath=yes
21566
21567     case $host_os in
21568     cygwin*)
21569       # Cygwin DLLs use 'cyg' prefix rather than 'lib'
21570       soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
21571
21572       sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"
21573       ;;
21574     mingw* | cegcc*)
21575       # MinGW DLLs use traditional 'lib' prefix
21576       soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
21577       ;;
21578     pw32*)
21579       # pw32 DLLs use 'pw' prefix rather than 'lib'
21580       library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
21581       ;;
21582     esac
21583     dynamic_linker='Win32 ld.exe'
21584     ;;
21585
21586   *,cl*)
21587     # Native MSVC
21588     libname_spec='$name'
21589     soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
21590     library_names_spec='${libname}.dll.lib'
21591
21592     case $build_os in
21593     mingw*)
21594       sys_lib_search_path_spec=
21595       lt_save_ifs=$IFS
21596       IFS=';'
21597       for lt_path in $LIB
21598       do
21599         IFS=$lt_save_ifs
21600         # Let DOS variable expansion print the short 8.3 style file name.
21601         lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
21602         sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
21603       done
21604       IFS=$lt_save_ifs
21605       # Convert to MSYS style.
21606       sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'`
21607       ;;
21608     cygwin*)
21609       # Convert to unix form, then to dos form, then back to unix form
21610       # but this time dos style (no spaces!) so that the unix form looks
21611       # like /cygdrive/c/PROGRA~1:/cygdr...
21612       sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
21613       sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
21614       sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
21615       ;;
21616     *)
21617       sys_lib_search_path_spec="$LIB"
21618       if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
21619         # It is most probably a Windows format PATH.
21620         sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
21621       else
21622         sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
21623       fi
21624       # FIXME: find the short name or the path components, as spaces are
21625       # common. (e.g. "Program Files" -> "PROGRA~1")
21626       ;;
21627     esac
21628
21629     # DLL is installed to $(libdir)/../bin by postinstall_cmds
21630     postinstall_cmds='base_file=`basename \${file}`~
21631       dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
21632       dldir=$destdir/`dirname \$dlpath`~
21633       test -d \$dldir || mkdir -p \$dldir~
21634       $install_prog $dir/$dlname \$dldir/$dlname'
21635     postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
21636       dlpath=$dir/\$dldll~
21637        $RM \$dlpath'
21638     shlibpath_overrides_runpath=yes
21639     dynamic_linker='Win32 link.exe'
21640     ;;
21641
21642   *)
21643     # Assume MSVC wrapper
21644     library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
21645     dynamic_linker='Win32 ld.exe'
21646     ;;
21647   esac
21648   # FIXME: first we should search . and the directory the executable is in
21649   shlibpath_var=PATH
21650   ;;
21651
21652 darwin* | rhapsody*)
21653   dynamic_linker="$host_os dyld"
21654   version_type=darwin
21655   need_lib_prefix=no
21656   need_version=no
21657   library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
21658   soname_spec='${libname}${release}${major}$shared_ext'
21659   shlibpath_overrides_runpath=yes
21660   shlibpath_var=DYLD_LIBRARY_PATH
21661   shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
21662
21663   sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"
21664   sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
21665   ;;
21666
21667 dgux*)
21668   version_type=linux
21669   need_lib_prefix=no
21670   need_version=no
21671   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
21672   soname_spec='${libname}${release}${shared_ext}$major'
21673   shlibpath_var=LD_LIBRARY_PATH
21674   ;;
21675
21676 freebsd1*)
21677   dynamic_linker=no
21678   ;;
21679
21680 freebsd* | dragonfly*)
21681   # DragonFly does not have aout.  When/if they implement a new
21682   # versioning mechanism, adjust this.
21683   if test -x /usr/bin/objformat; then
21684     objformat=`/usr/bin/objformat`
21685   else
21686     case $host_os in
21687     freebsd[123]*) objformat=aout ;;
21688     *) objformat=elf ;;
21689     esac
21690   fi
21691   version_type=freebsd-$objformat
21692   case $version_type in
21693     freebsd-elf*)
21694       library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
21695       need_version=no
21696       need_lib_prefix=no
21697       ;;
21698     freebsd-*)
21699       library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
21700       need_version=yes
21701       ;;
21702   esac
21703   shlibpath_var=LD_LIBRARY_PATH
21704   case $host_os in
21705   freebsd2*)
21706     shlibpath_overrides_runpath=yes
21707     ;;
21708   freebsd3.[01]* | freebsdelf3.[01]*)
21709     shlibpath_overrides_runpath=yes
21710     hardcode_into_libs=yes
21711     ;;
21712   freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
21713   freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
21714     shlibpath_overrides_runpath=no
21715     hardcode_into_libs=yes
21716     ;;
21717   *) # from 4.6 on, and DragonFly
21718     shlibpath_overrides_runpath=yes
21719     hardcode_into_libs=yes
21720     ;;
21721   esac
21722   ;;
21723
21724 gnu*)
21725   version_type=linux
21726   need_lib_prefix=no
21727   need_version=no
21728   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
21729   soname_spec='${libname}${release}${shared_ext}$major'
21730   shlibpath_var=LD_LIBRARY_PATH
21731   hardcode_into_libs=yes
21732   ;;
21733
21734 haiku*)
21735   version_type=linux
21736   need_lib_prefix=no
21737   need_version=no
21738   dynamic_linker="$host_os runtime_loader"
21739   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
21740   soname_spec='${libname}${release}${shared_ext}$major'
21741   shlibpath_var=LIBRARY_PATH
21742   shlibpath_overrides_runpath=yes
21743   sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
21744   hardcode_into_libs=yes
21745   ;;
21746
21747 hpux9* | hpux10* | hpux11*)
21748   # Give a soname corresponding to the major version so that dld.sl refuses to
21749   # link against other versions.
21750   version_type=sunos
21751   need_lib_prefix=no
21752   need_version=no
21753   case $host_cpu in
21754   ia64*)
21755     shrext_cmds='.so'
21756     hardcode_into_libs=yes
21757     dynamic_linker="$host_os dld.so"
21758     shlibpath_var=LD_LIBRARY_PATH
21759     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
21760     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
21761     soname_spec='${libname}${release}${shared_ext}$major'
21762     if test "X$HPUX_IA64_MODE" = X32; then
21763       sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
21764     else
21765       sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
21766     fi
21767     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
21768     ;;
21769   hppa*64*)
21770     shrext_cmds='.sl'
21771     hardcode_into_libs=yes
21772     dynamic_linker="$host_os dld.sl"
21773     shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
21774     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
21775     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
21776     soname_spec='${libname}${release}${shared_ext}$major'
21777     sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
21778     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
21779     ;;
21780   *)
21781     shrext_cmds='.sl'
21782     dynamic_linker="$host_os dld.sl"
21783     shlibpath_var=SHLIB_PATH
21784     shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
21785     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
21786     soname_spec='${libname}${release}${shared_ext}$major'
21787     ;;
21788   esac
21789   # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
21790   postinstall_cmds='chmod 555 $lib'
21791   # or fails outright, so override atomically:
21792   install_override_mode=555
21793   ;;
21794
21795 interix[3-9]*)
21796   version_type=linux
21797   need_lib_prefix=no
21798   need_version=no
21799   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
21800   soname_spec='${libname}${release}${shared_ext}$major'
21801   dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
21802   shlibpath_var=LD_LIBRARY_PATH
21803   shlibpath_overrides_runpath=no
21804   hardcode_into_libs=yes
21805   ;;
21806
21807 irix5* | irix6* | nonstopux*)
21808   case $host_os in
21809     nonstopux*) version_type=nonstopux ;;
21810     *)
21811         if test "$lt_cv_prog_gnu_ld" = yes; then
21812                 version_type=linux
21813         else
21814                 version_type=irix
21815         fi ;;
21816   esac
21817   need_lib_prefix=no
21818   need_version=no
21819   soname_spec='${libname}${release}${shared_ext}$major'
21820   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
21821   case $host_os in
21822   irix5* | nonstopux*)
21823     libsuff= shlibsuff=
21824     ;;
21825   *)
21826     case $LD in # libtool.m4 will add one of these switches to LD
21827     *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
21828       libsuff= shlibsuff= libmagic=32-bit;;
21829     *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
21830       libsuff=32 shlibsuff=N32 libmagic=N32;;
21831     *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
21832       libsuff=64 shlibsuff=64 libmagic=64-bit;;
21833     *) libsuff= shlibsuff= libmagic=never-match;;
21834     esac
21835     ;;
21836   esac
21837   shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
21838   shlibpath_overrides_runpath=no
21839   sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
21840   sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
21841   hardcode_into_libs=yes
21842   ;;
21843
21844 # No shared lib support for Linux oldld, aout, or coff.
21845 linux*oldld* | linux*aout* | linux*coff*)
21846   dynamic_linker=no
21847   ;;
21848
21849 # This must be Linux ELF.
21850 linux* | k*bsd*-gnu | kopensolaris*-gnu)
21851   version_type=linux
21852   need_lib_prefix=no
21853   need_version=no
21854   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
21855   soname_spec='${libname}${release}${shared_ext}$major'
21856   finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
21857   shlibpath_var=LD_LIBRARY_PATH
21858   shlibpath_overrides_runpath=no
21859
21860   # Some binutils ld are patched to set DT_RUNPATH
21861   if ${lt_cv_shlibpath_overrides_runpath+:} false; then :
21862   $as_echo_n "(cached) " >&6
21863 else
21864   lt_cv_shlibpath_overrides_runpath=no
21865     save_LDFLAGS=$LDFLAGS
21866     save_libdir=$libdir
21867     eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \
21868          LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\""
21869     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21870 /* end confdefs.h.  */
21871
21872 int
21873 main ()
21874 {
21875
21876   ;
21877   return 0;
21878 }
21879 _ACEOF
21880 if ac_fn_c_try_link "$LINENO"; then :
21881   if  ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then :
21882   lt_cv_shlibpath_overrides_runpath=yes
21883 fi
21884 fi
21885 rm -f core conftest.err conftest.$ac_objext \
21886     conftest$ac_exeext conftest.$ac_ext
21887     LDFLAGS=$save_LDFLAGS
21888     libdir=$save_libdir
21889
21890 fi
21891
21892   shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
21893
21894   # This implies no fast_install, which is unacceptable.
21895   # Some rework will be needed to allow for fast_install
21896   # before this can be enabled.
21897   hardcode_into_libs=yes
21898
21899   # Append ld.so.conf contents to the search path
21900   if test -f /etc/ld.so.conf; then
21901     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' ' '`
21902     sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
21903   fi
21904
21905   # We used to test for /lib/ld.so.1 and disable shared libraries on
21906   # powerpc, because MkLinux only supported shared libraries with the
21907   # GNU dynamic linker.  Since this was broken with cross compilers,
21908   # most powerpc-linux boxes support dynamic linking these days and
21909   # people can always --disable-shared, the test was removed, and we
21910   # assume the GNU/Linux dynamic linker is in use.
21911   dynamic_linker='GNU/Linux ld.so'
21912   ;;
21913
21914 netbsd*)
21915   version_type=sunos
21916   need_lib_prefix=no
21917   need_version=no
21918   if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
21919     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
21920     finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
21921     dynamic_linker='NetBSD (a.out) ld.so'
21922   else
21923     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
21924     soname_spec='${libname}${release}${shared_ext}$major'
21925     dynamic_linker='NetBSD ld.elf_so'
21926   fi
21927   shlibpath_var=LD_LIBRARY_PATH
21928   shlibpath_overrides_runpath=yes
21929   hardcode_into_libs=yes
21930   ;;
21931
21932 newsos6)
21933   version_type=linux
21934   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
21935   shlibpath_var=LD_LIBRARY_PATH
21936   shlibpath_overrides_runpath=yes
21937   ;;
21938
21939 *nto* | *qnx*)
21940   version_type=qnx
21941   need_lib_prefix=no
21942   need_version=no
21943   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
21944   soname_spec='${libname}${release}${shared_ext}$major'
21945   shlibpath_var=LD_LIBRARY_PATH
21946   shlibpath_overrides_runpath=no
21947   hardcode_into_libs=yes
21948   dynamic_linker='ldqnx.so'
21949   ;;
21950
21951 openbsd*)
21952   version_type=sunos
21953   sys_lib_dlsearch_path_spec="/usr/lib"
21954   need_lib_prefix=no
21955   # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
21956   case $host_os in
21957     openbsd3.3 | openbsd3.3.*)  need_version=yes ;;
21958     *)                          need_version=no  ;;
21959   esac
21960   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
21961   finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
21962   shlibpath_var=LD_LIBRARY_PATH
21963   if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
21964     case $host_os in
21965       openbsd2.[89] | openbsd2.[89].*)
21966         shlibpath_overrides_runpath=no
21967         ;;
21968       *)
21969         shlibpath_overrides_runpath=yes
21970         ;;
21971       esac
21972   else
21973     shlibpath_overrides_runpath=yes
21974   fi
21975   ;;
21976
21977 os2*)
21978   libname_spec='$name'
21979   shrext_cmds=".dll"
21980   need_lib_prefix=no
21981   library_names_spec='$libname${shared_ext} $libname.a'
21982   dynamic_linker='OS/2 ld.exe'
21983   shlibpath_var=LIBPATH
21984   ;;
21985
21986 osf3* | osf4* | osf5*)
21987   version_type=osf
21988   need_lib_prefix=no
21989   need_version=no
21990   soname_spec='${libname}${release}${shared_ext}$major'
21991   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
21992   shlibpath_var=LD_LIBRARY_PATH
21993   sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
21994   sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
21995   ;;
21996
21997 rdos*)
21998   dynamic_linker=no
21999   ;;
22000
22001 solaris*)
22002   version_type=linux
22003   need_lib_prefix=no
22004   need_version=no
22005   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
22006   soname_spec='${libname}${release}${shared_ext}$major'
22007   shlibpath_var=LD_LIBRARY_PATH
22008   shlibpath_overrides_runpath=yes
22009   hardcode_into_libs=yes
22010   # ldd complains unless libraries are executable
22011   postinstall_cmds='chmod +x $lib'
22012   ;;
22013
22014 sunos4*)
22015   version_type=sunos
22016   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
22017   finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
22018   shlibpath_var=LD_LIBRARY_PATH
22019   shlibpath_overrides_runpath=yes
22020   if test "$with_gnu_ld" = yes; then
22021     need_lib_prefix=no
22022   fi
22023   need_version=yes
22024   ;;
22025
22026 sysv4 | sysv4.3*)
22027   version_type=linux
22028   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
22029   soname_spec='${libname}${release}${shared_ext}$major'
22030   shlibpath_var=LD_LIBRARY_PATH
22031   case $host_vendor in
22032     sni)
22033       shlibpath_overrides_runpath=no
22034       need_lib_prefix=no
22035       runpath_var=LD_RUN_PATH
22036       ;;
22037     siemens)
22038       need_lib_prefix=no
22039       ;;
22040     motorola)
22041       need_lib_prefix=no
22042       need_version=no
22043       shlibpath_overrides_runpath=no
22044       sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
22045       ;;
22046   esac
22047   ;;
22048
22049 sysv4*MP*)
22050   if test -d /usr/nec ;then
22051     version_type=linux
22052     library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
22053     soname_spec='$libname${shared_ext}.$major'
22054     shlibpath_var=LD_LIBRARY_PATH
22055   fi
22056   ;;
22057
22058 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
22059   version_type=freebsd-elf
22060   need_lib_prefix=no
22061   need_version=no
22062   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
22063   soname_spec='${libname}${release}${shared_ext}$major'
22064   shlibpath_var=LD_LIBRARY_PATH
22065   shlibpath_overrides_runpath=yes
22066   hardcode_into_libs=yes
22067   if test "$with_gnu_ld" = yes; then
22068     sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
22069   else
22070     sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
22071     case $host_os in
22072       sco3.2v5*)
22073         sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
22074         ;;
22075     esac
22076   fi
22077   sys_lib_dlsearch_path_spec='/usr/lib'
22078   ;;
22079
22080 tpf*)
22081   # TPF is a cross-target only.  Preferred cross-host = GNU/Linux.
22082   version_type=linux
22083   need_lib_prefix=no
22084   need_version=no
22085   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
22086   shlibpath_var=LD_LIBRARY_PATH
22087   shlibpath_overrides_runpath=no
22088   hardcode_into_libs=yes
22089   ;;
22090
22091 uts4*)
22092   version_type=linux
22093   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
22094   soname_spec='${libname}${release}${shared_ext}$major'
22095   shlibpath_var=LD_LIBRARY_PATH
22096   ;;
22097
22098 *)
22099   dynamic_linker=no
22100   ;;
22101 esac
22102 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
22103 $as_echo "$dynamic_linker" >&6; }
22104 test "$dynamic_linker" = no && can_build_shared=no
22105
22106 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
22107 if test "$GCC" = yes; then
22108   variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
22109 fi
22110
22111 if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
22112   sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
22113 fi
22114 if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
22115   sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
22116 fi
22117
22118
22119
22120
22121
22122
22123
22124
22125
22126
22127
22128
22129
22130
22131
22132
22133
22134
22135
22136
22137
22138
22139
22140
22141
22142
22143
22144
22145
22146
22147
22148
22149
22150
22151
22152
22153
22154
22155
22156
22157
22158
22159
22160
22161
22162
22163
22164
22165
22166
22167
22168
22169
22170
22171
22172
22173
22174
22175
22176
22177
22178
22179
22180
22181
22182
22183
22184
22185
22186
22187
22188
22189
22190
22191
22192
22193
22194
22195
22196
22197
22198
22199
22200
22201
22202
22203
22204
22205
22206
22207
22208
22209   { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
22210 $as_echo_n "checking how to hardcode library paths into programs... " >&6; }
22211 hardcode_action=
22212 if test -n "$hardcode_libdir_flag_spec" ||
22213    test -n "$runpath_var" ||
22214    test "X$hardcode_automatic" = "Xyes" ; then
22215
22216   # We can hardcode non-existent directories.
22217   if test "$hardcode_direct" != no &&
22218      # If the only mechanism to avoid hardcoding is shlibpath_var, we
22219      # have to relink, otherwise we might link with an installed library
22220      # when we should be linking with a yet-to-be-installed one
22221      ## test "$_LT_TAGVAR(hardcode_shlibpath_var, )" != no &&
22222      test "$hardcode_minus_L" != no; then
22223     # Linking always hardcodes the temporary library directory.
22224     hardcode_action=relink
22225   else
22226     # We can link without hardcoding, and we can hardcode nonexisting dirs.
22227     hardcode_action=immediate
22228   fi
22229 else
22230   # We cannot hardcode anything, or else we can only hardcode existing
22231   # directories.
22232   hardcode_action=unsupported
22233 fi
22234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5
22235 $as_echo "$hardcode_action" >&6; }
22236
22237 if test "$hardcode_action" = relink ||
22238    test "$inherit_rpath" = yes; then
22239   # Fast installation is not supported
22240   enable_fast_install=no
22241 elif test "$shlibpath_overrides_runpath" = yes ||
22242      test "$enable_shared" = no; then
22243   # Fast installation is not necessary
22244   enable_fast_install=needless
22245 fi
22246
22247
22248
22249
22250
22251
22252   if test "x$enable_dlopen" != xyes; then
22253   enable_dlopen=unknown
22254   enable_dlopen_self=unknown
22255   enable_dlopen_self_static=unknown
22256 else
22257   lt_cv_dlopen=no
22258   lt_cv_dlopen_libs=
22259
22260   case $host_os in
22261   beos*)
22262     lt_cv_dlopen="load_add_on"
22263     lt_cv_dlopen_libs=
22264     lt_cv_dlopen_self=yes
22265     ;;
22266
22267   mingw* | pw32* | cegcc*)
22268     lt_cv_dlopen="LoadLibrary"
22269     lt_cv_dlopen_libs=
22270     ;;
22271
22272   cygwin*)
22273     lt_cv_dlopen="dlopen"
22274     lt_cv_dlopen_libs=
22275     ;;
22276
22277   darwin*)
22278   # if libdl is installed we need to link against it
22279     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
22280 $as_echo_n "checking for dlopen in -ldl... " >&6; }
22281 if ${ac_cv_lib_dl_dlopen+:} false; then :
22282   $as_echo_n "(cached) " >&6
22283 else
22284   ac_check_lib_save_LIBS=$LIBS
22285 LIBS="-ldl  $LIBS"
22286 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22287 /* end confdefs.h.  */
22288
22289 /* Override any GCC internal prototype to avoid an error.
22290    Use char because int might match the return type of a GCC
22291    builtin and then its argument prototype would still apply.  */
22292 #ifdef __cplusplus
22293 extern "C"
22294 #endif
22295 char dlopen ();
22296 int
22297 main ()
22298 {
22299 return dlopen ();
22300   ;
22301   return 0;
22302 }
22303 _ACEOF
22304 if ac_fn_c_try_link "$LINENO"; then :
22305   ac_cv_lib_dl_dlopen=yes
22306 else
22307   ac_cv_lib_dl_dlopen=no
22308 fi
22309 rm -f core conftest.err conftest.$ac_objext \
22310     conftest$ac_exeext conftest.$ac_ext
22311 LIBS=$ac_check_lib_save_LIBS
22312 fi
22313 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
22314 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
22315 if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
22316   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
22317 else
22318
22319     lt_cv_dlopen="dyld"
22320     lt_cv_dlopen_libs=
22321     lt_cv_dlopen_self=yes
22322
22323 fi
22324
22325     ;;
22326
22327   *)
22328     ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load"
22329 if test "x$ac_cv_func_shl_load" = xyes; then :
22330   lt_cv_dlopen="shl_load"
22331 else
22332   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
22333 $as_echo_n "checking for shl_load in -ldld... " >&6; }
22334 if ${ac_cv_lib_dld_shl_load+:} false; then :
22335   $as_echo_n "(cached) " >&6
22336 else
22337   ac_check_lib_save_LIBS=$LIBS
22338 LIBS="-ldld  $LIBS"
22339 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22340 /* end confdefs.h.  */
22341
22342 /* Override any GCC internal prototype to avoid an error.
22343    Use char because int might match the return type of a GCC
22344    builtin and then its argument prototype would still apply.  */
22345 #ifdef __cplusplus
22346 extern "C"
22347 #endif
22348 char shl_load ();
22349 int
22350 main ()
22351 {
22352 return shl_load ();
22353   ;
22354   return 0;
22355 }
22356 _ACEOF
22357 if ac_fn_c_try_link "$LINENO"; then :
22358   ac_cv_lib_dld_shl_load=yes
22359 else
22360   ac_cv_lib_dld_shl_load=no
22361 fi
22362 rm -f core conftest.err conftest.$ac_objext \
22363     conftest$ac_exeext conftest.$ac_ext
22364 LIBS=$ac_check_lib_save_LIBS
22365 fi
22366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
22367 $as_echo "$ac_cv_lib_dld_shl_load" >&6; }
22368 if test "x$ac_cv_lib_dld_shl_load" = xyes; then :
22369   lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"
22370 else
22371   ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
22372 if test "x$ac_cv_func_dlopen" = xyes; then :
22373   lt_cv_dlopen="dlopen"
22374 else
22375   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
22376 $as_echo_n "checking for dlopen in -ldl... " >&6; }
22377 if ${ac_cv_lib_dl_dlopen+:} false; then :
22378   $as_echo_n "(cached) " >&6
22379 else
22380   ac_check_lib_save_LIBS=$LIBS
22381 LIBS="-ldl  $LIBS"
22382 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22383 /* end confdefs.h.  */
22384
22385 /* Override any GCC internal prototype to avoid an error.
22386    Use char because int might match the return type of a GCC
22387    builtin and then its argument prototype would still apply.  */
22388 #ifdef __cplusplus
22389 extern "C"
22390 #endif
22391 char dlopen ();
22392 int
22393 main ()
22394 {
22395 return dlopen ();
22396   ;
22397   return 0;
22398 }
22399 _ACEOF
22400 if ac_fn_c_try_link "$LINENO"; then :
22401   ac_cv_lib_dl_dlopen=yes
22402 else
22403   ac_cv_lib_dl_dlopen=no
22404 fi
22405 rm -f core conftest.err conftest.$ac_objext \
22406     conftest$ac_exeext conftest.$ac_ext
22407 LIBS=$ac_check_lib_save_LIBS
22408 fi
22409 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
22410 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
22411 if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
22412   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
22413 else
22414   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5
22415 $as_echo_n "checking for dlopen in -lsvld... " >&6; }
22416 if ${ac_cv_lib_svld_dlopen+:} false; then :
22417   $as_echo_n "(cached) " >&6
22418 else
22419   ac_check_lib_save_LIBS=$LIBS
22420 LIBS="-lsvld  $LIBS"
22421 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22422 /* end confdefs.h.  */
22423
22424 /* Override any GCC internal prototype to avoid an error.
22425    Use char because int might match the return type of a GCC
22426    builtin and then its argument prototype would still apply.  */
22427 #ifdef __cplusplus
22428 extern "C"
22429 #endif
22430 char dlopen ();
22431 int
22432 main ()
22433 {
22434 return dlopen ();
22435   ;
22436   return 0;
22437 }
22438 _ACEOF
22439 if ac_fn_c_try_link "$LINENO"; then :
22440   ac_cv_lib_svld_dlopen=yes
22441 else
22442   ac_cv_lib_svld_dlopen=no
22443 fi
22444 rm -f core conftest.err conftest.$ac_objext \
22445     conftest$ac_exeext conftest.$ac_ext
22446 LIBS=$ac_check_lib_save_LIBS
22447 fi
22448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5
22449 $as_echo "$ac_cv_lib_svld_dlopen" >&6; }
22450 if test "x$ac_cv_lib_svld_dlopen" = xyes; then :
22451   lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"
22452 else
22453   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5
22454 $as_echo_n "checking for dld_link in -ldld... " >&6; }
22455 if ${ac_cv_lib_dld_dld_link+:} false; then :
22456   $as_echo_n "(cached) " >&6
22457 else
22458   ac_check_lib_save_LIBS=$LIBS
22459 LIBS="-ldld  $LIBS"
22460 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22461 /* end confdefs.h.  */
22462
22463 /* Override any GCC internal prototype to avoid an error.
22464    Use char because int might match the return type of a GCC
22465    builtin and then its argument prototype would still apply.  */
22466 #ifdef __cplusplus
22467 extern "C"
22468 #endif
22469 char dld_link ();
22470 int
22471 main ()
22472 {
22473 return dld_link ();
22474   ;
22475   return 0;
22476 }
22477 _ACEOF
22478 if ac_fn_c_try_link "$LINENO"; then :
22479   ac_cv_lib_dld_dld_link=yes
22480 else
22481   ac_cv_lib_dld_dld_link=no
22482 fi
22483 rm -f core conftest.err conftest.$ac_objext \
22484     conftest$ac_exeext conftest.$ac_ext
22485 LIBS=$ac_check_lib_save_LIBS
22486 fi
22487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5
22488 $as_echo "$ac_cv_lib_dld_dld_link" >&6; }
22489 if test "x$ac_cv_lib_dld_dld_link" = xyes; then :
22490   lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"
22491 fi
22492
22493
22494 fi
22495
22496
22497 fi
22498
22499
22500 fi
22501
22502
22503 fi
22504
22505
22506 fi
22507
22508     ;;
22509   esac
22510
22511   if test "x$lt_cv_dlopen" != xno; then
22512     enable_dlopen=yes
22513   else
22514     enable_dlopen=no
22515   fi
22516
22517   case $lt_cv_dlopen in
22518   dlopen)
22519     save_CPPFLAGS="$CPPFLAGS"
22520     test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
22521
22522     save_LDFLAGS="$LDFLAGS"
22523     wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
22524
22525     save_LIBS="$LIBS"
22526     LIBS="$lt_cv_dlopen_libs $LIBS"
22527
22528     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5
22529 $as_echo_n "checking whether a program can dlopen itself... " >&6; }
22530 if ${lt_cv_dlopen_self+:} false; then :
22531   $as_echo_n "(cached) " >&6
22532 else
22533           if test "$cross_compiling" = yes; then :
22534   lt_cv_dlopen_self=cross
22535 else
22536   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
22537   lt_status=$lt_dlunknown
22538   cat > conftest.$ac_ext <<_LT_EOF
22539 #line $LINENO "configure"
22540 #include "confdefs.h"
22541
22542 #if HAVE_DLFCN_H
22543 #include <dlfcn.h>
22544 #endif
22545
22546 #include <stdio.h>
22547
22548 #ifdef RTLD_GLOBAL
22549 #  define LT_DLGLOBAL           RTLD_GLOBAL
22550 #else
22551 #  ifdef DL_GLOBAL
22552 #    define LT_DLGLOBAL         DL_GLOBAL
22553 #  else
22554 #    define LT_DLGLOBAL         0
22555 #  endif
22556 #endif
22557
22558 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
22559    find out it does not work in some platform. */
22560 #ifndef LT_DLLAZY_OR_NOW
22561 #  ifdef RTLD_LAZY
22562 #    define LT_DLLAZY_OR_NOW            RTLD_LAZY
22563 #  else
22564 #    ifdef DL_LAZY
22565 #      define LT_DLLAZY_OR_NOW          DL_LAZY
22566 #    else
22567 #      ifdef RTLD_NOW
22568 #        define LT_DLLAZY_OR_NOW        RTLD_NOW
22569 #      else
22570 #        ifdef DL_NOW
22571 #          define LT_DLLAZY_OR_NOW      DL_NOW
22572 #        else
22573 #          define LT_DLLAZY_OR_NOW      0
22574 #        endif
22575 #      endif
22576 #    endif
22577 #  endif
22578 #endif
22579
22580 /* When -fvisbility=hidden is used, assume the code has been annotated
22581    correspondingly for the symbols needed.  */
22582 #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
22583 int fnord () __attribute__((visibility("default")));
22584 #endif
22585
22586 int fnord () { return 42; }
22587 int main ()
22588 {
22589   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
22590   int status = $lt_dlunknown;
22591
22592   if (self)
22593     {
22594       if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
22595       else
22596         {
22597           if (dlsym( self,"_fnord"))  status = $lt_dlneed_uscore;
22598           else puts (dlerror ());
22599         }
22600       /* dlclose (self); */
22601     }
22602   else
22603     puts (dlerror ());
22604
22605   return status;
22606 }
22607 _LT_EOF
22608   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
22609   (eval $ac_link) 2>&5
22610   ac_status=$?
22611   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
22612   test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then
22613     (./conftest; exit; ) >&5 2>/dev/null
22614     lt_status=$?
22615     case x$lt_status in
22616       x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
22617       x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
22618       x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;;
22619     esac
22620   else :
22621     # compilation failed
22622     lt_cv_dlopen_self=no
22623   fi
22624 fi
22625 rm -fr conftest*
22626
22627
22628 fi
22629 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5
22630 $as_echo "$lt_cv_dlopen_self" >&6; }
22631
22632     if test "x$lt_cv_dlopen_self" = xyes; then
22633       wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
22634       { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5
22635 $as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; }
22636 if ${lt_cv_dlopen_self_static+:} false; then :
22637   $as_echo_n "(cached) " >&6
22638 else
22639           if test "$cross_compiling" = yes; then :
22640   lt_cv_dlopen_self_static=cross
22641 else
22642   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
22643   lt_status=$lt_dlunknown
22644   cat > conftest.$ac_ext <<_LT_EOF
22645 #line $LINENO "configure"
22646 #include "confdefs.h"
22647
22648 #if HAVE_DLFCN_H
22649 #include <dlfcn.h>
22650 #endif
22651
22652 #include <stdio.h>
22653
22654 #ifdef RTLD_GLOBAL
22655 #  define LT_DLGLOBAL           RTLD_GLOBAL
22656 #else
22657 #  ifdef DL_GLOBAL
22658 #    define LT_DLGLOBAL         DL_GLOBAL
22659 #  else
22660 #    define LT_DLGLOBAL         0
22661 #  endif
22662 #endif
22663
22664 /* We may have to define LT_DLLAZY_OR_NOW in the command line if we
22665    find out it does not work in some platform. */
22666 #ifndef LT_DLLAZY_OR_NOW
22667 #  ifdef RTLD_LAZY
22668 #    define LT_DLLAZY_OR_NOW            RTLD_LAZY
22669 #  else
22670 #    ifdef DL_LAZY
22671 #      define LT_DLLAZY_OR_NOW          DL_LAZY
22672 #    else
22673 #      ifdef RTLD_NOW
22674 #        define LT_DLLAZY_OR_NOW        RTLD_NOW
22675 #      else
22676 #        ifdef DL_NOW
22677 #          define LT_DLLAZY_OR_NOW      DL_NOW
22678 #        else
22679 #          define LT_DLLAZY_OR_NOW      0
22680 #        endif
22681 #      endif
22682 #    endif
22683 #  endif
22684 #endif
22685
22686 /* When -fvisbility=hidden is used, assume the code has been annotated
22687    correspondingly for the symbols needed.  */
22688 #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
22689 int fnord () __attribute__((visibility("default")));
22690 #endif
22691
22692 int fnord () { return 42; }
22693 int main ()
22694 {
22695   void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
22696   int status = $lt_dlunknown;
22697
22698   if (self)
22699     {
22700       if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
22701       else
22702         {
22703           if (dlsym( self,"_fnord"))  status = $lt_dlneed_uscore;
22704           else puts (dlerror ());
22705         }
22706       /* dlclose (self); */
22707     }
22708   else
22709     puts (dlerror ());
22710
22711   return status;
22712 }
22713 _LT_EOF
22714   if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
22715   (eval $ac_link) 2>&5
22716   ac_status=$?
22717   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
22718   test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then
22719     (./conftest; exit; ) >&5 2>/dev/null
22720     lt_status=$?
22721     case x$lt_status in
22722       x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
22723       x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
22724       x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;;
22725     esac
22726   else :
22727     # compilation failed
22728     lt_cv_dlopen_self_static=no
22729   fi
22730 fi
22731 rm -fr conftest*
22732
22733
22734 fi
22735 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5
22736 $as_echo "$lt_cv_dlopen_self_static" >&6; }
22737     fi
22738
22739     CPPFLAGS="$save_CPPFLAGS"
22740     LDFLAGS="$save_LDFLAGS"
22741     LIBS="$save_LIBS"
22742     ;;
22743   esac
22744
22745   case $lt_cv_dlopen_self in
22746   yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
22747   *) enable_dlopen_self=unknown ;;
22748   esac
22749
22750   case $lt_cv_dlopen_self_static in
22751   yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
22752   *) enable_dlopen_self_static=unknown ;;
22753   esac
22754 fi
22755
22756
22757
22758
22759
22760
22761
22762
22763
22764
22765
22766
22767
22768
22769
22770
22771
22772 striplib=
22773 old_striplib=
22774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5
22775 $as_echo_n "checking whether stripping libraries is possible... " >&6; }
22776 if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
22777   test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
22778   test -z "$striplib" && striplib="$STRIP --strip-unneeded"
22779   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22780 $as_echo "yes" >&6; }
22781 else
22782 # FIXME - insert some real tests, host_os isn't really good enough
22783   case $host_os in
22784   darwin*)
22785     if test -n "$STRIP" ; then
22786       striplib="$STRIP -x"
22787       old_striplib="$STRIP -S"
22788       { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
22789 $as_echo "yes" >&6; }
22790     else
22791       { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22792 $as_echo "no" >&6; }
22793     fi
22794     ;;
22795   *)
22796     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
22797 $as_echo "no" >&6; }
22798     ;;
22799   esac
22800 fi
22801
22802
22803
22804
22805
22806
22807
22808
22809
22810
22811
22812
22813   # Report which library types will actually be built
22814   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5
22815 $as_echo_n "checking if libtool supports shared libraries... " >&6; }
22816   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5
22817 $as_echo "$can_build_shared" >&6; }
22818
22819   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5
22820 $as_echo_n "checking whether to build shared libraries... " >&6; }
22821   test "$can_build_shared" = "no" && enable_shared=no
22822
22823   # On AIX, shared libraries and static libraries use the same namespace, and
22824   # are all built from PIC.
22825   case $host_os in
22826   aix3*)
22827     test "$enable_shared" = yes && enable_static=no
22828     if test -n "$RANLIB"; then
22829       archive_cmds="$archive_cmds~\$RANLIB \$lib"
22830       postinstall_cmds='$RANLIB $lib'
22831     fi
22832     ;;
22833
22834   aix[4-9]*)
22835     if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
22836       test "$enable_shared" = yes && enable_static=no
22837     fi
22838     ;;
22839   esac
22840   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5
22841 $as_echo "$enable_shared" >&6; }
22842
22843   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5
22844 $as_echo_n "checking whether to build static libraries... " >&6; }
22845   # Make sure either enable_shared or enable_static is yes.
22846   test "$enable_shared" = yes || enable_static=yes
22847   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5
22848 $as_echo "$enable_static" >&6; }
22849
22850
22851
22852
22853 fi
22854 ac_ext=c
22855 ac_cpp='$CPP $CPPFLAGS'
22856 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
22857 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
22858 ac_compiler_gnu=$ac_cv_c_compiler_gnu
22859
22860 CC="$lt_save_CC"
22861
22862
22863
22864
22865
22866
22867
22868
22869
22870
22871
22872
22873
22874         ac_config_commands="$ac_config_commands libtool"
22875
22876
22877
22878
22879 # Only expand once:
22880
22881
22882
22883
22884
22885
22886 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if sntp will be built" >&5
22887 $as_echo_n "checking if sntp will be built... " >&6; }
22888
22889 # Check whether --with-sntp was given.
22890 if test "${with_sntp+set}" = set; then :
22891   withval=$with_sntp;
22892 else
22893   with_sntp="${withsntp=yes}"
22894
22895 fi
22896
22897 case "$with_sntp" in
22898  no)
22899     SNTP=
22900     ;;
22901  *)
22902     SNTP=sntp
22903     ;;
22904 esac
22905
22906  if test -n "$SNTP"; then
22907   BUILD_SNTP_TRUE=
22908   BUILD_SNTP_FALSE='#'
22909 else
22910   BUILD_SNTP_TRUE='#'
22911   BUILD_SNTP_FALSE=
22912 fi
22913
22914 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_sntp" >&5
22915 $as_echo "$with_sntp" >&6; }
22916
22917
22918
22919 case "$SNTP" in
22920  '')
22921     SNTP_DB=
22922     SNTP_DL=
22923     SNTP_DS=
22924     ;;
22925 esac
22926
22927 ###
22928
22929 # NTP has (so far) been relying on leading-edge autogen.
22930 # Therefore, by default:
22931 # - use the version we ship with
22932 # - do not install it
22933 # - build a static copy (AC_DISABLE_SHARED - done earlier)
22934 case "${enable_local_libopts+set}" in
22935  set) ;;
22936  *) enable_local_libopts=yes ;;
22937 esac
22938 case "${enable_libopts_install+set}" in
22939  set) ;;
22940  *) enable_libopts_install=no ;;
22941 esac
22942 enable_nls=no
22943
22944
22945   ac_header_dirent=no
22946 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
22947   as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
22948 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5
22949 $as_echo_n "checking for $ac_hdr that defines DIR... " >&6; }
22950 if eval \${$as_ac_Header+:} false; then :
22951   $as_echo_n "(cached) " >&6
22952 else
22953   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22954 /* end confdefs.h.  */
22955 #include <sys/types.h>
22956 #include <$ac_hdr>
22957
22958 int
22959 main ()
22960 {
22961 if ((DIR *) 0)
22962 return 0;
22963   ;
22964   return 0;
22965 }
22966 _ACEOF
22967 if ac_fn_c_try_compile "$LINENO"; then :
22968   eval "$as_ac_Header=yes"
22969 else
22970   eval "$as_ac_Header=no"
22971 fi
22972 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22973 fi
22974 eval ac_res=\$$as_ac_Header
22975                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
22976 $as_echo "$ac_res" >&6; }
22977 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
22978   cat >>confdefs.h <<_ACEOF
22979 #define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1
22980 _ACEOF
22981
22982 ac_header_dirent=$ac_hdr; break
22983 fi
22984
22985 done
22986 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
22987 if test $ac_header_dirent = dirent.h; then
22988   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
22989 $as_echo_n "checking for library containing opendir... " >&6; }
22990 if ${ac_cv_search_opendir+:} false; then :
22991   $as_echo_n "(cached) " >&6
22992 else
22993   ac_func_search_save_LIBS=$LIBS
22994 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22995 /* end confdefs.h.  */
22996
22997 /* Override any GCC internal prototype to avoid an error.
22998    Use char because int might match the return type of a GCC
22999    builtin and then its argument prototype would still apply.  */
23000 #ifdef __cplusplus
23001 extern "C"
23002 #endif
23003 char opendir ();
23004 int
23005 main ()
23006 {
23007 return opendir ();
23008   ;
23009   return 0;
23010 }
23011 _ACEOF
23012 for ac_lib in '' dir; do
23013   if test -z "$ac_lib"; then
23014     ac_res="none required"
23015   else
23016     ac_res=-l$ac_lib
23017     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
23018   fi
23019   if ac_fn_c_try_link "$LINENO"; then :
23020   ac_cv_search_opendir=$ac_res
23021 fi
23022 rm -f core conftest.err conftest.$ac_objext \
23023     conftest$ac_exeext
23024   if ${ac_cv_search_opendir+:} false; then :
23025   break
23026 fi
23027 done
23028 if ${ac_cv_search_opendir+:} false; then :
23029
23030 else
23031   ac_cv_search_opendir=no
23032 fi
23033 rm conftest.$ac_ext
23034 LIBS=$ac_func_search_save_LIBS
23035 fi
23036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
23037 $as_echo "$ac_cv_search_opendir" >&6; }
23038 ac_res=$ac_cv_search_opendir
23039 if test "$ac_res" != no; then :
23040   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
23041
23042 fi
23043
23044 else
23045   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
23046 $as_echo_n "checking for library containing opendir... " >&6; }
23047 if ${ac_cv_search_opendir+:} false; then :
23048   $as_echo_n "(cached) " >&6
23049 else
23050   ac_func_search_save_LIBS=$LIBS
23051 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23052 /* end confdefs.h.  */
23053
23054 /* Override any GCC internal prototype to avoid an error.
23055    Use char because int might match the return type of a GCC
23056    builtin and then its argument prototype would still apply.  */
23057 #ifdef __cplusplus
23058 extern "C"
23059 #endif
23060 char opendir ();
23061 int
23062 main ()
23063 {
23064 return opendir ();
23065   ;
23066   return 0;
23067 }
23068 _ACEOF
23069 for ac_lib in '' x; do
23070   if test -z "$ac_lib"; then
23071     ac_res="none required"
23072   else
23073     ac_res=-l$ac_lib
23074     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
23075   fi
23076   if ac_fn_c_try_link "$LINENO"; then :
23077   ac_cv_search_opendir=$ac_res
23078 fi
23079 rm -f core conftest.err conftest.$ac_objext \
23080     conftest$ac_exeext
23081   if ${ac_cv_search_opendir+:} false; then :
23082   break
23083 fi
23084 done
23085 if ${ac_cv_search_opendir+:} false; then :
23086
23087 else
23088   ac_cv_search_opendir=no
23089 fi
23090 rm conftest.$ac_ext
23091 LIBS=$ac_func_search_save_LIBS
23092 fi
23093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
23094 $as_echo "$ac_cv_search_opendir" >&6; }
23095 ac_res=$ac_cv_search_opendir
23096 if test "$ac_res" != no; then :
23097   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
23098
23099 fi
23100
23101 fi
23102
23103
23104   # =================
23105   # AC_CHECK_HEADERS
23106   # =================
23107   for ac_header in  \
23108       sys/mman.h    sys/param.h   sys/poll.h    sys/procset.h \
23109       sys/select.h  sys/socket.h  sys/stropts.h sys/time.h \
23110       sys/un.h      sys/wait.h    dlfcn.h       errno.h \
23111       fcntl.h       libgen.h      libintl.h     memory.h \
23112       netinet/in.h  setjmp.h      stdbool.h     sysexits.h \
23113       unistd.h      utime.h
23114 do :
23115   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
23116 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
23117 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
23118   cat >>confdefs.h <<_ACEOF
23119 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
23120 _ACEOF
23121
23122 fi
23123
23124 done
23125
23126
23127   for ac_header in stdarg.h     varargs.h
23128 do :
23129   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
23130 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
23131 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
23132   cat >>confdefs.h <<_ACEOF
23133 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
23134 _ACEOF
23135  lo_have_arg_hdr=true;break
23136 else
23137   lo_have_arg_hdr=false
23138 fi
23139
23140 done
23141
23142
23143   for ac_header in string.h     strings.h
23144 do :
23145   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
23146 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
23147 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
23148   cat >>confdefs.h <<_ACEOF
23149 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
23150 _ACEOF
23151  lo_have_str_hdr=true;break
23152 else
23153   lo_have_str_hdr=false
23154 fi
23155
23156 done
23157
23158
23159   for ac_header in limits.h     sys/limits.h  values.h
23160 do :
23161   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
23162 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
23163 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
23164   cat >>confdefs.h <<_ACEOF
23165 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
23166 _ACEOF
23167  lo_have_lim_hdr=true;break
23168 else
23169   lo_have_lim_hdr=false
23170 fi
23171
23172 done
23173
23174
23175   for ac_header in inttypes.h   stdint.h
23176 do :
23177   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
23178 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
23179 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
23180   cat >>confdefs.h <<_ACEOF
23181 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
23182 _ACEOF
23183  lo_have_typ_hdr=true;break
23184 else
23185   lo_have_typ_hdr=false
23186 fi
23187
23188 done
23189
23190
23191   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working stdnoreturn.h" >&5
23192 $as_echo_n "checking for working stdnoreturn.h... " >&6; }
23193 if ${gl_cv_header_working_stdnoreturn_h+:} false; then :
23194   $as_echo_n "(cached) " >&6
23195 else
23196   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23197 /* end confdefs.h.  */
23198 #include <stdlib.h>
23199             #include <stdnoreturn.h>
23200             /* Do not check for 'noreturn' after the return type.
23201                C11 allows it, but it's rarely done that way
23202                and circa-2012 bleeding-edge GCC rejects it when given
23203                -Werror=old-style-declaration.  */
23204             noreturn void foo1 (void) { exit (0); }
23205             _Noreturn void foo2 (void) { exit (0); }
23206             int testit (int argc, char **argv) {
23207               if (argc & 1)
23208                 return 0;
23209               (argv[0][0] ? foo1 : foo2) ();
23210             }
23211
23212 int
23213 main ()
23214 {
23215
23216   ;
23217   return 0;
23218 }
23219 _ACEOF
23220 if ac_fn_c_try_compile "$LINENO"; then :
23221   gl_cv_header_working_stdnoreturn_h=yes
23222 else
23223   gl_cv_header_working_stdnoreturn_h=no
23224 fi
23225 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23226 fi
23227 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdnoreturn_h" >&5
23228 $as_echo "$gl_cv_header_working_stdnoreturn_h" >&6; }
23229
23230   if test $gl_cv_header_working_stdnoreturn_h = yes; then
23231     STDNORETURN_H=''
23232   else
23233     STDNORETURN_H='stdnoreturn.h'
23234   fi
23235
23236
23237    if test -n "$STDNORETURN_H"; then
23238   GL_GENERATE_STDNORETURN_H_TRUE=
23239   GL_GENERATE_STDNORETURN_H_FALSE='#'
23240 else
23241   GL_GENERATE_STDNORETURN_H_TRUE='#'
23242   GL_GENERATE_STDNORETURN_H_FALSE=
23243 fi
23244
23245
23246
23247   # ----------------------------------------------------------------------
23248   # check for various programs used during the build.
23249   # On OS/X, "wchar.h" needs "runetype.h" to work properly.
23250   # ----------------------------------------------------------------------
23251   for ac_header in runetype.h wchar.h
23252 do :
23253   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
23254 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "
23255   $ac_includes_default
23256   #if HAVE_RUNETYPE_H
23257   # include <runetype.h>
23258   #endif
23259
23260 "
23261 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
23262   cat >>confdefs.h <<_ACEOF
23263 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
23264 _ACEOF
23265
23266 fi
23267
23268 done
23269
23270
23271   # Check whether --enable-nls was given.
23272 if test "${enable_nls+set}" = set; then :
23273   enableval=$enable_nls;
23274 fi
23275
23276   if test "x$enable_nls" != "xno" && \
23277   test "X${ac_cv_header_libintl_h}" = Xyes; then :
23278
23279
23280 $as_echo "#define ENABLE_NLS 1" >>confdefs.h
23281
23282 fi
23283
23284   # --------------------------------------------
23285   # Verify certain entries from AC_CHECK_HEADERS
23286   # --------------------------------------------
23287   ${lo_have_arg_hdr} || \
23288     as_fn_error $? "you must have stdarg.h or varargs.h on your system" "$LINENO" 5
23289
23290   ${lo_have_str_hdr} || \
23291     as_fn_error $? "you must have string.h or strings.h on your system" "$LINENO" 5
23292
23293   ${lo_have_lim_hdr} || \
23294     as_fn_error $? "you must have one of limits.h, sys/limits.h or values.h" "$LINENO" 5
23295
23296   ${lo_have_typ_hdr} || \
23297     as_fn_error $? "you must have inttypes.h or stdint.h on your system" "$LINENO" 5
23298
23299   for f in sys_types sys_param sys_stat string errno stdlib memory setjmp
23300   do eval as_ac_var=\${ac_cv_header_${f}_h}
23301      test "X${as_ac_var}" = Xyes || {
23302        as_fn_error $? "you must have ${f}.h on your system" "$LINENO" 5
23303      }
23304   done
23305   test "X${ac_cv_header_inttypes_h-no}" = Xyes || \
23306     echo '#include <stdint.h>' > inttypes.h
23307
23308   # ----------------------------------------------------------------------
23309   # Checks for typedefs
23310   # ----------------------------------------------------------------------
23311   ac_fn_c_check_type "$LINENO" "wchar_t" "ac_cv_type_wchar_t" "$ac_includes_default"
23312 if test "x$ac_cv_type_wchar_t" = xyes; then :
23313
23314 cat >>confdefs.h <<_ACEOF
23315 #define HAVE_WCHAR_T 1
23316 _ACEOF
23317
23318
23319 fi
23320
23321   ac_fn_c_check_type "$LINENO" "wint_t" "ac_cv_type_wint_t" "
23322     $ac_includes_default
23323     #if HAVE_RUNETYPE_H
23324     # include <runetype.h>
23325     #endif
23326     #if HAVE_WCHAR_H
23327     # include <wchar.h>
23328     #endif
23329
23330 "
23331 if test "x$ac_cv_type_wint_t" = xyes; then :
23332
23333 cat >>confdefs.h <<_ACEOF
23334 #define HAVE_WINT_T 1
23335 _ACEOF
23336
23337
23338 fi
23339
23340   ac_fn_c_check_type "$LINENO" "int8_t" "ac_cv_type_int8_t" "$ac_includes_default"
23341 if test "x$ac_cv_type_int8_t" = xyes; then :
23342
23343 cat >>confdefs.h <<_ACEOF
23344 #define HAVE_INT8_T 1
23345 _ACEOF
23346
23347
23348 fi
23349 ac_fn_c_check_type "$LINENO" "uint8_t" "ac_cv_type_uint8_t" "$ac_includes_default"
23350 if test "x$ac_cv_type_uint8_t" = xyes; then :
23351
23352 cat >>confdefs.h <<_ACEOF
23353 #define HAVE_UINT8_T 1
23354 _ACEOF
23355
23356
23357 fi
23358 ac_fn_c_check_type "$LINENO" "int16_t" "ac_cv_type_int16_t" "$ac_includes_default"
23359 if test "x$ac_cv_type_int16_t" = xyes; then :
23360
23361 cat >>confdefs.h <<_ACEOF
23362 #define HAVE_INT16_T 1
23363 _ACEOF
23364
23365
23366 fi
23367 ac_fn_c_check_type "$LINENO" "uint16_t" "ac_cv_type_uint16_t" "$ac_includes_default"
23368 if test "x$ac_cv_type_uint16_t" = xyes; then :
23369
23370 cat >>confdefs.h <<_ACEOF
23371 #define HAVE_UINT16_T 1
23372 _ACEOF
23373
23374
23375 fi
23376 ac_fn_c_check_type "$LINENO" "int32_t" "ac_cv_type_int32_t" "$ac_includes_default"
23377 if test "x$ac_cv_type_int32_t" = xyes; then :
23378
23379 cat >>confdefs.h <<_ACEOF
23380 #define HAVE_INT32_T 1
23381 _ACEOF
23382
23383
23384 fi
23385 ac_fn_c_check_type "$LINENO" "uint32_t" "ac_cv_type_uint32_t" "$ac_includes_default"
23386 if test "x$ac_cv_type_uint32_t" = xyes; then :
23387
23388 cat >>confdefs.h <<_ACEOF
23389 #define HAVE_UINT32_T 1
23390 _ACEOF
23391
23392
23393 fi
23394 ac_fn_c_check_type "$LINENO" "intptr_t" "ac_cv_type_intptr_t" "$ac_includes_default"
23395 if test "x$ac_cv_type_intptr_t" = xyes; then :
23396
23397 cat >>confdefs.h <<_ACEOF
23398 #define HAVE_INTPTR_T 1
23399 _ACEOF
23400
23401
23402 fi
23403 ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default"
23404 if test "x$ac_cv_type_uintptr_t" = xyes; then :
23405
23406 cat >>confdefs.h <<_ACEOF
23407 #define HAVE_UINTPTR_T 1
23408 _ACEOF
23409
23410
23411 fi
23412 ac_fn_c_check_type "$LINENO" "uint_t" "ac_cv_type_uint_t" "$ac_includes_default"
23413 if test "x$ac_cv_type_uint_t" = xyes; then :
23414
23415 cat >>confdefs.h <<_ACEOF
23416 #define HAVE_UINT_T 1
23417 _ACEOF
23418
23419
23420 fi
23421 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
23422 if test "x$ac_cv_type_pid_t" = xyes; then :
23423
23424 cat >>confdefs.h <<_ACEOF
23425 #define HAVE_PID_T 1
23426 _ACEOF
23427
23428
23429 fi
23430 ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
23431 if test "x$ac_cv_type_size_t" = xyes; then :
23432
23433 cat >>confdefs.h <<_ACEOF
23434 #define HAVE_SIZE_T 1
23435 _ACEOF
23436
23437
23438 fi
23439 ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default"
23440 if test "x$ac_cv_type_ptrdiff_t" = xyes; then :
23441
23442 cat >>confdefs.h <<_ACEOF
23443 #define HAVE_PTRDIFF_T 1
23444 _ACEOF
23445
23446
23447 fi
23448
23449   # The cast to long int works around a bug in the HP C Compiler
23450 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
23451 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
23452 # This bug is HP SR number 8606223364.
23453 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of char*" >&5
23454 $as_echo_n "checking size of char*... " >&6; }
23455 if ${ac_cv_sizeof_charp+:} false; then :
23456   $as_echo_n "(cached) " >&6
23457 else
23458   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (char*))" "ac_cv_sizeof_charp"        "$ac_includes_default"; then :
23459
23460 else
23461   if test "$ac_cv_type_charp" = yes; then
23462      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
23463 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
23464 as_fn_error 77 "cannot compute sizeof (char*)
23465 See \`config.log' for more details" "$LINENO" 5; }
23466    else
23467      ac_cv_sizeof_charp=0
23468    fi
23469 fi
23470
23471 fi
23472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_charp" >&5
23473 $as_echo "$ac_cv_sizeof_charp" >&6; }
23474
23475
23476
23477 cat >>confdefs.h <<_ACEOF
23478 #define SIZEOF_CHARP $ac_cv_sizeof_charp
23479 _ACEOF
23480
23481
23482   # The cast to long int works around a bug in the HP C Compiler
23483 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
23484 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
23485 # This bug is HP SR number 8606223364.
23486 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5
23487 $as_echo_n "checking size of int... " >&6; }
23488 if ${ac_cv_sizeof_int+:} false; then :
23489   $as_echo_n "(cached) " >&6
23490 else
23491   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int"        "$ac_includes_default"; then :
23492
23493 else
23494   if test "$ac_cv_type_int" = yes; then
23495      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
23496 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
23497 as_fn_error 77 "cannot compute sizeof (int)
23498 See \`config.log' for more details" "$LINENO" 5; }
23499    else
23500      ac_cv_sizeof_int=0
23501    fi
23502 fi
23503
23504 fi
23505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5
23506 $as_echo "$ac_cv_sizeof_int" >&6; }
23507
23508
23509
23510 cat >>confdefs.h <<_ACEOF
23511 #define SIZEOF_INT $ac_cv_sizeof_int
23512 _ACEOF
23513
23514
23515   # The cast to long int works around a bug in the HP C Compiler
23516 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
23517 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
23518 # This bug is HP SR number 8606223364.
23519 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
23520 $as_echo_n "checking size of long... " >&6; }
23521 if ${ac_cv_sizeof_long+:} false; then :
23522   $as_echo_n "(cached) " >&6
23523 else
23524   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long"        "$ac_includes_default"; then :
23525
23526 else
23527   if test "$ac_cv_type_long" = yes; then
23528      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
23529 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
23530 as_fn_error 77 "cannot compute sizeof (long)
23531 See \`config.log' for more details" "$LINENO" 5; }
23532    else
23533      ac_cv_sizeof_long=0
23534    fi
23535 fi
23536
23537 fi
23538 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
23539 $as_echo "$ac_cv_sizeof_long" >&6; }
23540
23541
23542
23543 cat >>confdefs.h <<_ACEOF
23544 #define SIZEOF_LONG $ac_cv_sizeof_long
23545 _ACEOF
23546
23547
23548   # The cast to long int works around a bug in the HP C Compiler
23549 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
23550 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
23551 # This bug is HP SR number 8606223364.
23552 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5
23553 $as_echo_n "checking size of short... " >&6; }
23554 if ${ac_cv_sizeof_short+:} false; then :
23555   $as_echo_n "(cached) " >&6
23556 else
23557   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short))" "ac_cv_sizeof_short"        "$ac_includes_default"; then :
23558
23559 else
23560   if test "$ac_cv_type_short" = yes; then
23561      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
23562 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
23563 as_fn_error 77 "cannot compute sizeof (short)
23564 See \`config.log' for more details" "$LINENO" 5; }
23565    else
23566      ac_cv_sizeof_short=0
23567    fi
23568 fi
23569
23570 fi
23571 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5
23572 $as_echo "$ac_cv_sizeof_short" >&6; }
23573
23574
23575
23576 cat >>confdefs.h <<_ACEOF
23577 #define SIZEOF_SHORT $ac_cv_sizeof_short
23578 _ACEOF
23579
23580
23581
23582   # ------------
23583   # AC_CHECK_LIB
23584   # ------------
23585   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pathfind in -lgen" >&5
23586 $as_echo_n "checking for pathfind in -lgen... " >&6; }
23587 if ${ac_cv_lib_gen_pathfind+:} false; then :
23588   $as_echo_n "(cached) " >&6
23589 else
23590   ac_check_lib_save_LIBS=$LIBS
23591 LIBS="-lgen  $LIBS"
23592 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23593 /* end confdefs.h.  */
23594
23595 /* Override any GCC internal prototype to avoid an error.
23596    Use char because int might match the return type of a GCC
23597    builtin and then its argument prototype would still apply.  */
23598 #ifdef __cplusplus
23599 extern "C"
23600 #endif
23601 char pathfind ();
23602 int
23603 main ()
23604 {
23605 return pathfind ();
23606   ;
23607   return 0;
23608 }
23609 _ACEOF
23610 if ac_fn_c_try_link "$LINENO"; then :
23611   ac_cv_lib_gen_pathfind=yes
23612 else
23613   ac_cv_lib_gen_pathfind=no
23614 fi
23615 rm -f core conftest.err conftest.$ac_objext \
23616     conftest$ac_exeext conftest.$ac_ext
23617 LIBS=$ac_check_lib_save_LIBS
23618 fi
23619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gen_pathfind" >&5
23620 $as_echo "$ac_cv_lib_gen_pathfind" >&6; }
23621 if test "x$ac_cv_lib_gen_pathfind" = xyes; then :
23622   cat >>confdefs.h <<_ACEOF
23623 #define HAVE_LIBGEN 1
23624 _ACEOF
23625
23626   LIBS="-lgen $LIBS"
23627
23628 fi
23629
23630   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gettext in -lintl" >&5
23631 $as_echo_n "checking for gettext in -lintl... " >&6; }
23632 if ${ac_cv_lib_intl_gettext+:} false; then :
23633   $as_echo_n "(cached) " >&6
23634 else
23635   ac_check_lib_save_LIBS=$LIBS
23636 LIBS="-lintl  $LIBS"
23637 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23638 /* end confdefs.h.  */
23639
23640 /* Override any GCC internal prototype to avoid an error.
23641    Use char because int might match the return type of a GCC
23642    builtin and then its argument prototype would still apply.  */
23643 #ifdef __cplusplus
23644 extern "C"
23645 #endif
23646 char gettext ();
23647 int
23648 main ()
23649 {
23650 return gettext ();
23651   ;
23652   return 0;
23653 }
23654 _ACEOF
23655 if ac_fn_c_try_link "$LINENO"; then :
23656   ac_cv_lib_intl_gettext=yes
23657 else
23658   ac_cv_lib_intl_gettext=no
23659 fi
23660 rm -f core conftest.err conftest.$ac_objext \
23661     conftest$ac_exeext conftest.$ac_ext
23662 LIBS=$ac_check_lib_save_LIBS
23663 fi
23664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_gettext" >&5
23665 $as_echo "$ac_cv_lib_intl_gettext" >&6; }
23666 if test "x$ac_cv_lib_intl_gettext" = xyes; then :
23667   cat >>confdefs.h <<_ACEOF
23668 #define HAVE_LIBINTL 1
23669 _ACEOF
23670
23671   LIBS="-lintl $LIBS"
23672
23673 fi
23674
23675   for ac_func in vprintf
23676 do :
23677   ac_fn_c_check_func "$LINENO" "vprintf" "ac_cv_func_vprintf"
23678 if test "x$ac_cv_func_vprintf" = xyes; then :
23679   cat >>confdefs.h <<_ACEOF
23680 #define HAVE_VPRINTF 1
23681 _ACEOF
23682
23683 ac_fn_c_check_func "$LINENO" "_doprnt" "ac_cv_func__doprnt"
23684 if test "x$ac_cv_func__doprnt" = xyes; then :
23685
23686 $as_echo "#define HAVE_DOPRNT 1" >>confdefs.h
23687
23688 fi
23689
23690 fi
23691 done
23692
23693
23694   for ac_header in vfork.h
23695 do :
23696   ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
23697 if test "x$ac_cv_header_vfork_h" = xyes; then :
23698   cat >>confdefs.h <<_ACEOF
23699 #define HAVE_VFORK_H 1
23700 _ACEOF
23701
23702 fi
23703
23704 done
23705
23706 for ac_func in fork vfork
23707 do :
23708   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
23709 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
23710 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
23711   cat >>confdefs.h <<_ACEOF
23712 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
23713 _ACEOF
23714
23715 fi
23716 done
23717
23718 if test "x$ac_cv_func_fork" = xyes; then
23719   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
23720 $as_echo_n "checking for working fork... " >&6; }
23721 if ${ac_cv_func_fork_works+:} false; then :
23722   $as_echo_n "(cached) " >&6
23723 else
23724   if test "$cross_compiling" = yes; then :
23725   ac_cv_func_fork_works=cross
23726 else
23727   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23728 /* end confdefs.h.  */
23729 $ac_includes_default
23730 int
23731 main ()
23732 {
23733
23734           /* By Ruediger Kuhlmann. */
23735           return fork () < 0;
23736
23737   ;
23738   return 0;
23739 }
23740 _ACEOF
23741 if ac_fn_c_try_run "$LINENO"; then :
23742   ac_cv_func_fork_works=yes
23743 else
23744   ac_cv_func_fork_works=no
23745 fi
23746 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23747   conftest.$ac_objext conftest.beam conftest.$ac_ext
23748 fi
23749
23750 fi
23751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
23752 $as_echo "$ac_cv_func_fork_works" >&6; }
23753
23754 else
23755   ac_cv_func_fork_works=$ac_cv_func_fork
23756 fi
23757 if test "x$ac_cv_func_fork_works" = xcross; then
23758   case $host in
23759     *-*-amigaos* | *-*-msdosdjgpp*)
23760       # Override, as these systems have only a dummy fork() stub
23761       ac_cv_func_fork_works=no
23762       ;;
23763     *)
23764       ac_cv_func_fork_works=yes
23765       ;;
23766   esac
23767   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
23768 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
23769 fi
23770 ac_cv_func_vfork_works=$ac_cv_func_vfork
23771 if test "x$ac_cv_func_vfork" = xyes; then
23772   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
23773 $as_echo_n "checking for working vfork... " >&6; }
23774 if ${ac_cv_func_vfork_works+:} false; then :
23775   $as_echo_n "(cached) " >&6
23776 else
23777   if test "$cross_compiling" = yes; then :
23778   ac_cv_func_vfork_works=cross
23779 else
23780   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23781 /* end confdefs.h.  */
23782 /* Thanks to Paul Eggert for this test.  */
23783 $ac_includes_default
23784 #include <sys/wait.h>
23785 #ifdef HAVE_VFORK_H
23786 # include <vfork.h>
23787 #endif
23788 /* On some sparc systems, changes by the child to local and incoming
23789    argument registers are propagated back to the parent.  The compiler
23790    is told about this with #include <vfork.h>, but some compilers
23791    (e.g. gcc -O) don't grok <vfork.h>.  Test for this by using a
23792    static variable whose address is put into a register that is
23793    clobbered by the vfork.  */
23794 static void
23795 #ifdef __cplusplus
23796 sparc_address_test (int arg)
23797 # else
23798 sparc_address_test (arg) int arg;
23799 #endif
23800 {
23801   static pid_t child;
23802   if (!child) {
23803     child = vfork ();
23804     if (child < 0) {
23805       perror ("vfork");
23806       _exit(2);
23807     }
23808     if (!child) {
23809       arg = getpid();
23810       write(-1, "", 0);
23811       _exit (arg);
23812     }
23813   }
23814 }
23815
23816 int
23817 main ()
23818 {
23819   pid_t parent = getpid ();
23820   pid_t child;
23821
23822   sparc_address_test (0);
23823
23824   child = vfork ();
23825
23826   if (child == 0) {
23827     /* Here is another test for sparc vfork register problems.  This
23828        test uses lots of local variables, at least as many local
23829        variables as main has allocated so far including compiler
23830        temporaries.  4 locals are enough for gcc 1.40.3 on a Solaris
23831        4.1.3 sparc, but we use 8 to be safe.  A buggy compiler should
23832        reuse the register of parent for one of the local variables,
23833        since it will think that parent can't possibly be used any more
23834        in this routine.  Assigning to the local variable will thus
23835        munge parent in the parent process.  */
23836     pid_t
23837       p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
23838       p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
23839     /* Convince the compiler that p..p7 are live; otherwise, it might
23840        use the same hardware register for all 8 local variables.  */
23841     if (p != p1 || p != p2 || p != p3 || p != p4
23842         || p != p5 || p != p6 || p != p7)
23843       _exit(1);
23844
23845     /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
23846        from child file descriptors.  If the child closes a descriptor
23847        before it execs or exits, this munges the parent's descriptor
23848        as well.  Test for this by closing stdout in the child.  */
23849     _exit(close(fileno(stdout)) != 0);
23850   } else {
23851     int status;
23852     struct stat st;
23853
23854     while (wait(&status) != child)
23855       ;
23856     return (
23857          /* Was there some problem with vforking?  */
23858          child < 0
23859
23860          /* Did the child fail?  (This shouldn't happen.)  */
23861          || status
23862
23863          /* Did the vfork/compiler bug occur?  */
23864          || parent != getpid()
23865
23866          /* Did the file descriptor bug occur?  */
23867          || fstat(fileno(stdout), &st) != 0
23868          );
23869   }
23870 }
23871 _ACEOF
23872 if ac_fn_c_try_run "$LINENO"; then :
23873   ac_cv_func_vfork_works=yes
23874 else
23875   ac_cv_func_vfork_works=no
23876 fi
23877 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23878   conftest.$ac_objext conftest.beam conftest.$ac_ext
23879 fi
23880
23881 fi
23882 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
23883 $as_echo "$ac_cv_func_vfork_works" >&6; }
23884
23885 fi;
23886 if test "x$ac_cv_func_fork_works" = xcross; then
23887   ac_cv_func_vfork_works=$ac_cv_func_vfork
23888   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
23889 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
23890 fi
23891
23892 if test "x$ac_cv_func_vfork_works" = xyes; then
23893
23894 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
23895
23896 else
23897
23898 $as_echo "#define vfork fork" >>confdefs.h
23899
23900 fi
23901 if test "x$ac_cv_func_fork_works" = xyes; then
23902
23903 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
23904
23905 fi
23906
23907   for ac_func in mmap canonicalize_file_name snprintf strdup strchr \
23908                  strrchr strsignal fchmod fstat chmod
23909 do :
23910   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
23911 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
23912 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
23913   cat >>confdefs.h <<_ACEOF
23914 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
23915 _ACEOF
23916
23917 fi
23918 done
23919
23920   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
23921 $as_echo_n "checking for a sed that does not truncate output... " >&6; }
23922 if ${ac_cv_path_SED+:} false; then :
23923   $as_echo_n "(cached) " >&6
23924 else
23925             ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
23926      for ac_i in 1 2 3 4 5 6 7; do
23927        ac_script="$ac_script$as_nl$ac_script"
23928      done
23929      echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
23930      { ac_script=; unset ac_script;}
23931      if test -z "$SED"; then
23932   ac_path_SED_found=false
23933   # Loop through the user's path and test for each of PROGNAME-LIST
23934   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
23935 for as_dir in $PATH
23936 do
23937   IFS=$as_save_IFS
23938   test -z "$as_dir" && as_dir=.
23939     for ac_prog in sed gsed; do
23940     for ac_exec_ext in '' $ac_executable_extensions; do
23941       ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
23942       { test -f "$ac_path_SED" && $as_test_x "$ac_path_SED"; } || continue
23943 # Check for GNU ac_path_SED and select it if it is found.
23944   # Check for GNU $ac_path_SED
23945 case `"$ac_path_SED" --version 2>&1` in
23946 *GNU*)
23947   ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
23948 *)
23949   ac_count=0
23950   $as_echo_n 0123456789 >"conftest.in"
23951   while :
23952   do
23953     cat "conftest.in" "conftest.in" >"conftest.tmp"
23954     mv "conftest.tmp" "conftest.in"
23955     cp "conftest.in" "conftest.nl"
23956     $as_echo '' >> "conftest.nl"
23957     "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
23958     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
23959     as_fn_arith $ac_count + 1 && ac_count=$as_val
23960     if test $ac_count -gt ${ac_path_SED_max-0}; then
23961       # Best one so far, save it but keep looking for a better one
23962       ac_cv_path_SED="$ac_path_SED"
23963       ac_path_SED_max=$ac_count
23964     fi
23965     # 10*(2^10) chars as input seems more than enough
23966     test $ac_count -gt 10 && break
23967   done
23968   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
23969 esac
23970
23971       $ac_path_SED_found && break 3
23972     done
23973   done
23974   done
23975 IFS=$as_save_IFS
23976   if test -z "$ac_cv_path_SED"; then
23977     as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
23978   fi
23979 else
23980   ac_cv_path_SED=$SED
23981 fi
23982
23983 fi
23984 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
23985 $as_echo "$ac_cv_path_SED" >&6; }
23986  SED="$ac_cv_path_SED"
23987   rm -f conftest.sed
23988
23989   while :
23990   do
23991       POSIX_SHELL=`which bash`
23992       test -x "$POSIX_SHELL" && break
23993       POSIX_SHELL=`which dash`
23994       test -x "$POSIX_SHELL" && break
23995       POSIX_SHELL=/usr/xpg4/bin/sh
23996       test -x "$POSIX_SHELL" && break
23997       POSIX_SHELL=`/bin/sh -c '
23998           exec 2>/dev/null
23999           if ! true ; then exit 1 ; fi
24000           echo /bin/sh'`
24001       test -x "$POSIX_SHELL" && break
24002       as_fn_error $? "cannot locate a working POSIX shell" "$LINENO" 5
24003   done
24004
24005 cat >>confdefs.h <<_ACEOF
24006 #define POSIX_SHELL "${POSIX_SHELL}"
24007 _ACEOF
24008
24009
24010
24011
24012
24013   LIBOPTS_BUILD_BLOCKED=''
24014
24015
24016   NEED_LIBOPTS_DIR=''
24017
24018   # Check whether --enable-local-libopts was given.
24019 if test "${enable_local_libopts+set}" = set; then :
24020   enableval=$enable_local_libopts;
24021     if test x$enableval = xyes ; then
24022        { $as_echo "$as_me:${as_lineno-$LINENO}: Using supplied libopts tearoff" >&5
24023 $as_echo "$as_me: Using supplied libopts tearoff" >&6;}
24024        LIBOPTS_CFLAGS='-I$(top_srcdir)/libopts'
24025        NEED_LIBOPTS_DIR=true
24026        LIBOPTS_LDADD='$(top_builddir)/libopts/libopts.la'
24027     fi
24028 fi
24029
24030
24031   # Check whether --enable-libopts-install was given.
24032 if test "${enable_libopts_install+set}" = set; then :
24033   enableval=$enable_libopts_install;
24034 fi
24035
24036    if test "X${enable_libopts_install}" = Xyes; then
24037   INSTALL_LIBOPTS_TRUE=
24038   INSTALL_LIBOPTS_FALSE='#'
24039 else
24040   INSTALL_LIBOPTS_TRUE='#'
24041   INSTALL_LIBOPTS_FALSE=
24042 fi
24043
24044
24045   if test -z "${NEED_LIBOPTS_DIR}" ; then
24046      { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether autoopts-config can be found" >&5
24047 $as_echo_n "checking whether autoopts-config can be found... " >&6; }
24048
24049 # Check whether --with-autoopts-config was given.
24050 if test "${with_autoopts_config+set}" = set; then :
24051   withval=$with_autoopts_config; lo_cv_with_autoopts_config=${with_autoopts_config}
24052 else
24053   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether autoopts-config is specified" >&5
24054 $as_echo_n "checking whether autoopts-config is specified... " >&6; }
24055 if ${lo_cv_with_autoopts_config+:} false; then :
24056   $as_echo_n "(cached) " >&6
24057 else
24058   if autoopts-config --help 2>/dev/null 1>&2
24059         then lo_cv_with_autoopts_config=autoopts-config
24060         elif libopts-config --help 2>/dev/null 1>&2
24061         then lo_cv_with_autoopts_config=libopts-config
24062         else lo_cv_with_autoopts_config=no ; fi
24063 fi
24064 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lo_cv_with_autoopts_config" >&5
24065 $as_echo "$lo_cv_with_autoopts_config" >&6; }
24066
24067 fi
24068  # end of AC_ARG_WITH
24069
24070      if ${lo_cv_test_autoopts+:} false; then :
24071   $as_echo_n "(cached) " >&6
24072 else
24073
24074         if test -z "${lo_cv_with_autoopts_config}" \
24075                 -o X"${lo_cv_with_autoopts_config}" = Xno
24076         then
24077            if autoopts-config --help 2>/dev/null 1>&2
24078            then lo_cv_with_autoopts_config=autoopts-config
24079            elif libopts-config --help 2>/dev/null 1>&2
24080            then lo_cv_with_autoopts_config=libopts-config
24081            else lo_cv_with_autoopts_config=false ; fi
24082         fi
24083         lo_cv_test_autoopts=`
24084             ${lo_cv_with_autoopts_config} --libs` 2> /dev/null
24085         if test $? -ne 0 -o -z "${lo_cv_test_autoopts}"
24086         then lo_cv_test_autoopts=no ; fi
24087
24088 fi
24089  # end of CACHE_VAL
24090      { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${lo_cv_test_autoopts}" >&5
24091 $as_echo "${lo_cv_test_autoopts}" >&6; }
24092
24093      if test "X${lo_cv_test_autoopts}" != Xno
24094      then
24095         LIBOPTS_LDADD="${lo_cv_test_autoopts}"
24096         LIBOPTS_CFLAGS="`${lo_cv_with_autoopts_config} --cflags`"
24097      else
24098         LIBOPTS_LDADD='$(top_builddir)/libopts/libopts.la'
24099         LIBOPTS_CFLAGS='-I$(top_srcdir)/libopts'
24100         NEED_LIBOPTS_DIR=true
24101      fi
24102   fi # end of if test -z "${NEED_LIBOPTS_DIR}"
24103   if test -n "${LIBOPTS_BUILD_BLOCKED}" ; then
24104     NEED_LIBOPTS_DIR=''
24105   fi
24106    if test -n "${NEED_LIBOPTS_DIR}"; then
24107   NEED_LIBOPTS_TRUE=
24108   NEED_LIBOPTS_FALSE='#'
24109 else
24110   NEED_LIBOPTS_TRUE='#'
24111   NEED_LIBOPTS_FALSE=
24112 fi
24113
24114
24115
24116   LIBOPTS_DIR=libopts
24117
24118
24119 # end of AC_DEFUN of LIBOPTS_CHECK_COMMON
24120
24121
24122     if test -z "$NEED_LIBOPTS_TRUE"; then :
24123
24124
24125
24126   # Check to see if a reg expr header is specified.
24127
24128
24129 # Check whether --with-regex-header was given.
24130 if test "${with_regex_header+set}" = set; then :
24131   withval=$with_regex_header; libopts_cv_with_regex_header=${with_regex_header}
24132 else
24133   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a reg expr header is specified" >&5
24134 $as_echo_n "checking whether a reg expr header is specified... " >&6; }
24135 if ${libopts_cv_with_regex_header+:} false; then :
24136   $as_echo_n "(cached) " >&6
24137 else
24138   libopts_cv_with_regex_header=no
24139 fi
24140 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_with_regex_header" >&5
24141 $as_echo "$libopts_cv_with_regex_header" >&6; }
24142
24143 fi
24144  # end of AC_ARG_WITH
24145   if test "X${libopts_cv_with_regex_header}" != Xno
24146   then
24147     cat >>confdefs.h <<_ACEOF
24148 #define REGEX_HEADER <${libopts_cv_with_regex_header}>
24149 _ACEOF
24150
24151   else
24152
24153 $as_echo "#define REGEX_HEADER <regex.h>" >>confdefs.h
24154
24155   fi
24156
24157
24158
24159   # Check to see if a working libregex can be found.
24160
24161
24162 # Check whether --with-libregex was given.
24163 if test "${with_libregex+set}" = set; then :
24164   withval=$with_libregex; libopts_cv_with_libregex_root=${with_libregex}
24165 else
24166   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether with-libregex was specified" >&5
24167 $as_echo_n "checking whether with-libregex was specified... " >&6; }
24168 if ${libopts_cv_with_libregex_root+:} false; then :
24169   $as_echo_n "(cached) " >&6
24170 else
24171   libopts_cv_with_libregex_root=no
24172 fi
24173 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_with_libregex_root" >&5
24174 $as_echo "$libopts_cv_with_libregex_root" >&6; }
24175
24176 fi
24177  # end of AC_ARG_WITH libregex
24178
24179   if test "${with_libregex+set}" = set && \
24180      test "X${withval}" = Xno
24181   then ## disabled by request
24182     libopts_cv_with_libregex_root=no
24183     libopts_cv_with_libregex_cflags=no
24184     libopts_cv_with_libregex_libs=no
24185   else
24186
24187
24188 # Check whether --with-libregex-cflags was given.
24189 if test "${with_libregex_cflags+set}" = set; then :
24190   withval=$with_libregex_cflags; libopts_cv_with_libregex_cflags=${with_libregex_cflags}
24191 else
24192   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether with-libregex-cflags was specified" >&5
24193 $as_echo_n "checking whether with-libregex-cflags was specified... " >&6; }
24194 if ${libopts_cv_with_libregex_cflags+:} false; then :
24195   $as_echo_n "(cached) " >&6
24196 else
24197   libopts_cv_with_libregex_cflags=no
24198 fi
24199 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_with_libregex_cflags" >&5
24200 $as_echo "$libopts_cv_with_libregex_cflags" >&6; }
24201
24202 fi
24203  # end of AC_ARG_WITH libregex-cflags
24204
24205
24206 # Check whether --with-libregex-libs was given.
24207 if test "${with_libregex_libs+set}" = set; then :
24208   withval=$with_libregex_libs; libopts_cv_with_libregex_libs=${with_libregex_libs}
24209 else
24210   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether with-libregex-libs was specified" >&5
24211 $as_echo_n "checking whether with-libregex-libs was specified... " >&6; }
24212 if ${libopts_cv_with_libregex_libs+:} false; then :
24213   $as_echo_n "(cached) " >&6
24214 else
24215   libopts_cv_with_libregex_libs=no
24216 fi
24217 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_with_libregex_libs" >&5
24218 $as_echo "$libopts_cv_with_libregex_libs" >&6; }
24219
24220 fi
24221  # end of AC_ARG_WITH libregex-libs
24222
24223   case "X${libopts_cv_with_libregex_cflags}" in
24224   Xyes|Xno|X )
24225     case "X${libopts_cv_with_libregex_root}" in
24226     Xyes|Xno|X ) libopts_cv_with_libregex_cflags=no ;;
24227     * )        libopts_cv_with_libregex_cflags=-I${libopts_cv_with_libregex_root}/include ;;
24228     esac
24229   esac
24230   case "X${libopts_cv_with_libregex_libs}" in
24231   Xyes|Xno|X )
24232     case "X${libopts_cv_with_libregex_root}" in
24233     Xyes|Xno|X ) libopts_cv_with_libregex_libs=no ;;
24234     * )        libopts_cv_with_libregex_libs="-L${libopts_cv_with_libregex_root}/lib -lregex";;
24235     esac
24236   esac
24237   libopts_save_CPPFLAGS="${CPPFLAGS}"
24238   libopts_save_LIBS="${LIBS}"
24239   case "X${libopts_cv_with_libregex_cflags}" in
24240   Xyes|Xno|X )
24241     libopts_cv_with_libregex_cflags="" ;;
24242   * ) CPPFLAGS="${CPPFLAGS} ${libopts_cv_with_libregex_cflags}" ;;
24243   esac
24244   case "X${libopts_cv_with_libregex_libs}" in
24245   Xyes|Xno|X )
24246     libopts_cv_with_libregex_libs="" ;;
24247   * )
24248     LIBS="${LIBS} ${libopts_cv_with_libregex_libs}" ;;
24249   esac
24250   LIBREGEX_CFLAGS=""
24251   LIBREGEX_LIBS=""
24252   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether libregex functions properly" >&5
24253 $as_echo_n "checking whether libregex functions properly... " >&6; }
24254   if ${libopts_cv_with_libregex+:} false; then :
24255   $as_echo_n "(cached) " >&6
24256 else
24257
24258   if test "$cross_compiling" = yes; then :
24259   libopts_cv_with_libregex=no
24260 else
24261   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24262 /* end confdefs.h.  */
24263 #include <stdio.h>
24264 #include <stdlib.h>
24265 #include <sys/types.h>
24266 #include REGEX_HEADER
24267 static regex_t re;
24268 void comp_re( char const* pzPat ) {
24269   int res = regcomp( &re, pzPat, REG_EXTENDED|REG_ICASE|REG_NEWLINE );
24270   if (res == 0) return;
24271   exit( res ); }
24272 int main() {
24273   regmatch_t m[2];
24274   comp_re( "^.*\$"   );
24275   comp_re( "()|no.*" );
24276   comp_re( "."       );
24277   if (regexec( &re, "X", 2, m, 0 ) != 0)  return 1;
24278   if ((m[0].rm_so != 0) || (m[0].rm_eo != 1)) {
24279     fputs( "error: regex -->.<-- did not match\n", stderr );
24280     return 1;
24281   }
24282   return 0; }
24283 _ACEOF
24284 if ac_fn_c_try_run "$LINENO"; then :
24285   libopts_cv_with_libregex=yes
24286 else
24287   libopts_cv_with_libregex=no
24288 fi
24289 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24290   conftest.$ac_objext conftest.beam conftest.$ac_ext
24291 fi
24292  # end of AC_RUN_IFELSE
24293
24294 fi
24295  # end of AC_CACHE_VAL for libopts_cv_with_libregex
24296   fi ## disabled by request
24297   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_with_libregex}" >&5
24298 $as_echo "${libopts_cv_with_libregex}" >&6; }
24299   if test "X${libopts_cv_with_libregex}" != Xno
24300   then
24301
24302 $as_echo "#define WITH_LIBREGEX 1" >>confdefs.h
24303
24304   else
24305     CPPFLAGS="${libopts_save_CPPFLAGS}"
24306     LIBS="${libopts_save_LIBS}"
24307     libopts_cv_with_libregex_root=no
24308 libopts_cv_with_libregex_cflags=no
24309 libopts_cv_with_libregex_libs=no
24310 libopts_cv_with_libregex=no
24311   fi
24312
24313
24314
24315   # Check to see if pathfind(3) works.
24316
24317   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pathfind(3) works" >&5
24318 $as_echo_n "checking whether pathfind(3) works... " >&6; }
24319   if ${libopts_cv_run_pathfind+:} false; then :
24320   $as_echo_n "(cached) " >&6
24321 else
24322
24323   if test "$cross_compiling" = yes; then :
24324   libopts_cv_run_pathfind=no
24325
24326 else
24327   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24328 /* end confdefs.h.  */
24329 #include <string.h>
24330 #include <stdlib.h>
24331 int main (int argc, char** argv) {
24332    char* pz = pathfind( getenv( "PATH" ), "sh", "x" );
24333    return (pz == 0) ? 1 : 0;
24334 }
24335 _ACEOF
24336 if ac_fn_c_try_run "$LINENO"; then :
24337   libopts_cv_run_pathfind=yes
24338 else
24339   libopts_cv_run_pathfind=no
24340 fi
24341 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24342   conftest.$ac_objext conftest.beam conftest.$ac_ext
24343 fi
24344  # end of RUN_IFELSE
24345
24346 fi
24347  # end of AC_CACHE_VAL for libopts_cv_run_pathfind
24348   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_pathfind}" >&5
24349 $as_echo "${libopts_cv_run_pathfind}" >&6; }
24350   if test "X${libopts_cv_run_pathfind}" != Xno
24351   then
24352
24353 $as_echo "#define HAVE_PATHFIND 1" >>confdefs.h
24354
24355   fi
24356
24357
24358
24359   # Check to see if /dev/zero is readable device.
24360
24361   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether /dev/zero is readable device" >&5
24362 $as_echo_n "checking whether /dev/zero is readable device... " >&6; }
24363   if ${libopts_cv_test_dev_zero+:} false; then :
24364   $as_echo_n "(cached) " >&6
24365 else
24366
24367     libopts_cv_test_dev_zero=`exec 2> /dev/null
24368 dzero=\`ls -lL /dev/zero | egrep ^c......r\`
24369 test -z "${dzero}" && exit 1
24370 echo ${dzero}`
24371     if test $? -ne 0 || test -z "$libopts_cv_test_dev_zero"
24372     then libopts_cv_test_dev_zero=no
24373     fi
24374
24375 fi
24376  # end of CACHE_VAL of libopts_cv_test_dev_zero
24377   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_test_dev_zero}" >&5
24378 $as_echo "${libopts_cv_test_dev_zero}" >&6; }
24379   if test "X${libopts_cv_test_dev_zero}" != Xno
24380   then
24381
24382 $as_echo "#define HAVE_DEV_ZERO 1" >>confdefs.h
24383
24384   fi
24385
24386
24387
24388   # Check to see if we have a functional realpath(3C).
24389
24390   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we have a functional realpath(3C)" >&5
24391 $as_echo_n "checking whether we have a functional realpath(3C)... " >&6; }
24392   if ${libopts_cv_run_realpath+:} false; then :
24393   $as_echo_n "(cached) " >&6
24394 else
24395
24396   if test "$cross_compiling" = yes; then :
24397   libopts_cv_run_realpath=no
24398
24399 else
24400   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24401 /* end confdefs.h.  */
24402 #include <limits.h>
24403 #include <stdlib.h>
24404 int main (int argc, char** argv) {
24405 #ifndef PATH_MAX
24406 choke me!!
24407 #else
24408    char zPath[PATH_MAX+1];
24409 #endif
24410    char *pz = realpath(argv[0], zPath);
24411    return (pz == zPath) ? 0 : 1;
24412 }
24413 _ACEOF
24414 if ac_fn_c_try_run "$LINENO"; then :
24415   libopts_cv_run_realpath=yes
24416 else
24417   libopts_cv_run_realpath=no
24418 fi
24419 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24420   conftest.$ac_objext conftest.beam conftest.$ac_ext
24421 fi
24422  # end of RUN_IFELSE
24423
24424 fi
24425  # end of AC_CACHE_VAL for libopts_cv_run_realpath
24426   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_realpath}" >&5
24427 $as_echo "${libopts_cv_run_realpath}" >&6; }
24428   if test "X${libopts_cv_run_realpath}" != Xno
24429   then
24430
24431 $as_echo "#define HAVE_REALPATH 1" >>confdefs.h
24432
24433   fi
24434
24435
24436
24437   # Check to see if strftime() works.
24438
24439   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strftime() works" >&5
24440 $as_echo_n "checking whether strftime() works... " >&6; }
24441   if ${libopts_cv_run_strftime+:} false; then :
24442   $as_echo_n "(cached) " >&6
24443 else
24444
24445   if test "$cross_compiling" = yes; then :
24446   libopts_cv_run_strftime=no
24447
24448 else
24449   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24450 /* end confdefs.h.  */
24451 #include <time.h>
24452 #include <string.h>
24453 char t_buf[ 64 ];
24454 int main() {
24455   static char const z[] = "Thursday Aug 28 240";
24456   struct tm tm;
24457   tm.tm_sec   = 36;  /* seconds after the minute [0, 61]  */
24458   tm.tm_min   = 44;  /* minutes after the hour [0, 59] */
24459   tm.tm_hour  = 12;  /* hour since midnight [0, 23] */
24460   tm.tm_mday  = 28;  /* day of the month [1, 31] */
24461   tm.tm_mon   =  7;  /* months since January [0, 11] */
24462   tm.tm_year  = 86;  /* years since 1900 */
24463   tm.tm_wday  =  4;  /* days since Sunday [0, 6] */
24464   tm.tm_yday  = 239; /* days since January 1 [0, 365] */
24465   tm.tm_isdst =  1;  /* flag for daylight savings time */
24466   strftime( t_buf, sizeof( t_buf ), "%A %b %d %j", &tm );
24467   return (strcmp( t_buf, z ) != 0); }
24468 _ACEOF
24469 if ac_fn_c_try_run "$LINENO"; then :
24470   libopts_cv_run_strftime=yes
24471 else
24472   libopts_cv_run_strftime=no
24473 fi
24474 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24475   conftest.$ac_objext conftest.beam conftest.$ac_ext
24476 fi
24477  # end of RUN_IFELSE
24478
24479 fi
24480  # end of AC_CACHE_VAL for libopts_cv_run_strftime
24481   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_strftime}" >&5
24482 $as_echo "${libopts_cv_run_strftime}" >&6; }
24483   if test "X${libopts_cv_run_strftime}" != Xno
24484   then
24485
24486 $as_echo "#define HAVE_STRFTIME 1" >>confdefs.h
24487
24488   fi
24489
24490
24491
24492   # Check to see if fopen accepts "b" mode.
24493
24494   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fopen accepts \"b\" mode" >&5
24495 $as_echo_n "checking whether fopen accepts \"b\" mode... " >&6; }
24496   if ${libopts_cv_run_fopen_binary+:} false; then :
24497   $as_echo_n "(cached) " >&6
24498 else
24499
24500   if test "$cross_compiling" = yes; then :
24501   libopts_cv_run_fopen_binary=no
24502
24503 else
24504   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24505 /* end confdefs.h.  */
24506 #include <stdio.h>
24507 int main (int argc, char** argv) {
24508 FILE* fp = fopen("conftest.$ac_ext", "rb");
24509 return (fp == NULL) ? 1 : fclose(fp); }
24510 _ACEOF
24511 if ac_fn_c_try_run "$LINENO"; then :
24512   libopts_cv_run_fopen_binary=yes
24513 else
24514   libopts_cv_run_fopen_binary=no
24515 fi
24516 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24517   conftest.$ac_objext conftest.beam conftest.$ac_ext
24518 fi
24519  # end of RUN_IFELSE
24520
24521 fi
24522  # end of AC_CACHE_VAL for libopts_cv_run_fopen_binary
24523   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_fopen_binary}" >&5
24524 $as_echo "${libopts_cv_run_fopen_binary}" >&6; }
24525   if test "X${libopts_cv_run_fopen_binary}" != Xno
24526   then
24527
24528 $as_echo "#define FOPEN_BINARY_FLAG \"b\"" >>confdefs.h
24529
24530   else
24531
24532 $as_echo "#define FOPEN_BINARY_FLAG \"\"" >>confdefs.h
24533
24534   fi
24535
24536
24537
24538   # Check to see if fopen accepts "t" mode.
24539
24540   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fopen accepts \"t\" mode" >&5
24541 $as_echo_n "checking whether fopen accepts \"t\" mode... " >&6; }
24542   if ${libopts_cv_run_fopen_text+:} false; then :
24543   $as_echo_n "(cached) " >&6
24544 else
24545
24546   if test "$cross_compiling" = yes; then :
24547   libopts_cv_run_fopen_text=no
24548
24549 else
24550   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24551 /* end confdefs.h.  */
24552 #include <stdio.h>
24553 int main (int argc, char** argv) {
24554 FILE* fp = fopen("conftest.$ac_ext", "rt");
24555 return (fp == NULL) ? 1 : fclose(fp); }
24556 _ACEOF
24557 if ac_fn_c_try_run "$LINENO"; then :
24558   libopts_cv_run_fopen_text=yes
24559 else
24560   libopts_cv_run_fopen_text=no
24561 fi
24562 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24563   conftest.$ac_objext conftest.beam conftest.$ac_ext
24564 fi
24565  # end of RUN_IFELSE
24566
24567 fi
24568  # end of AC_CACHE_VAL for libopts_cv_run_fopen_text
24569   { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${libopts_cv_run_fopen_text}" >&5
24570 $as_echo "${libopts_cv_run_fopen_text}" >&6; }
24571   if test "X${libopts_cv_run_fopen_text}" != Xno
24572   then
24573
24574 $as_echo "#define FOPEN_TEXT_FLAG \"t\"" >>confdefs.h
24575
24576   else
24577
24578 $as_echo "#define FOPEN_TEXT_FLAG \"\"" >>confdefs.h
24579
24580   fi
24581
24582
24583
24584   # Check to see if not wanting optional option args.
24585
24586   # Check whether --enable-optional-args was given.
24587 if test "${enable_optional_args+set}" = set; then :
24588   enableval=$enable_optional_args; libopts_cv_enable_optional_args=${enable_optional_args}
24589 else
24590   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether not wanting optional option args" >&5
24591 $as_echo_n "checking whether not wanting optional option args... " >&6; }
24592 if ${libopts_cv_enable_optional_args+:} false; then :
24593   $as_echo_n "(cached) " >&6
24594 else
24595   libopts_cv_enable_optional_args=yes
24596 fi
24597 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $libopts_cv_enable_optional_args" >&5
24598 $as_echo "$libopts_cv_enable_optional_args" >&6; }
24599
24600 fi
24601  # end of AC_ARG_ENABLE
24602   if test "X${libopts_cv_enable_optional_args}" = Xno
24603   then
24604
24605 $as_echo "#define NO_OPTIONAL_OPT_ARGS 1" >>confdefs.h
24606
24607   fi
24608
24609
24610
24611
24612
24613           fi
24614   ac_config_files="$ac_config_files libopts/Makefile"
24615
24616   # end of AC_DEFUN of LIBOPTS_CHECK
24617
24618
24619 # From when we only used libevent for sntp:
24620 #AM_COND_IF(
24621 #    [BUILD_SNTP],
24622 #    [NTP_LIBEVENT_CHECK],
24623 #    [NTP_LIBEVENT_CHECK_NOBUILD]
24624 #)
24625
24626
24627
24628 ntp_pkgconfig_min_version='0.15.0'
24629 if test -n "$ac_tool_prefix"; then
24630   # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
24631 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
24632 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24633 $as_echo_n "checking for $ac_word... " >&6; }
24634 if ${ac_cv_path_PKG_CONFIG+:} false; then :
24635   $as_echo_n "(cached) " >&6
24636 else
24637   case $PKG_CONFIG in
24638   [\\/]* | ?:[\\/]*)
24639   ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
24640   ;;
24641   *)
24642   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24643 for as_dir in $PATH
24644 do
24645   IFS=$as_save_IFS
24646   test -z "$as_dir" && as_dir=.
24647     for ac_exec_ext in '' $ac_executable_extensions; do
24648   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
24649     ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
24650     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
24651     break 2
24652   fi
24653 done
24654   done
24655 IFS=$as_save_IFS
24656
24657   ;;
24658 esac
24659 fi
24660 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
24661 if test -n "$PKG_CONFIG"; then
24662   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
24663 $as_echo "$PKG_CONFIG" >&6; }
24664 else
24665   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24666 $as_echo "no" >&6; }
24667 fi
24668
24669
24670 fi
24671 if test -z "$ac_cv_path_PKG_CONFIG"; then
24672   ac_pt_PKG_CONFIG=$PKG_CONFIG
24673   # Extract the first word of "pkg-config", so it can be a program name with args.
24674 set dummy pkg-config; ac_word=$2
24675 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
24676 $as_echo_n "checking for $ac_word... " >&6; }
24677 if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
24678   $as_echo_n "(cached) " >&6
24679 else
24680   case $ac_pt_PKG_CONFIG in
24681   [\\/]* | ?:[\\/]*)
24682   ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
24683   ;;
24684   *)
24685   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24686 for as_dir in $PATH
24687 do
24688   IFS=$as_save_IFS
24689   test -z "$as_dir" && as_dir=.
24690     for ac_exec_ext in '' $ac_executable_extensions; do
24691   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
24692     ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
24693     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
24694     break 2
24695   fi
24696 done
24697   done
24698 IFS=$as_save_IFS
24699
24700   ;;
24701 esac
24702 fi
24703 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
24704 if test -n "$ac_pt_PKG_CONFIG"; then
24705   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
24706 $as_echo "$ac_pt_PKG_CONFIG" >&6; }
24707 else
24708   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24709 $as_echo "no" >&6; }
24710 fi
24711
24712   if test "x$ac_pt_PKG_CONFIG" = x; then
24713     PKG_CONFIG=""
24714   else
24715     case $cross_compiling:$ac_tool_warned in
24716 yes:)
24717 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
24718 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
24719 ac_tool_warned=yes ;;
24720 esac
24721     PKG_CONFIG=$ac_pt_PKG_CONFIG
24722   fi
24723 else
24724   PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
24725 fi
24726
24727 { ac_cv_path_PKG_CONFIG=; unset ac_cv_path_PKG_CONFIG;}
24728 { ac_cv_path_ac_pt_PKG_CONFIG=; unset ac_cv_path_ac_pt_PKG_CONFIG;}
24729
24730 case "$PKG_CONFIG" in
24731  /*)
24732     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if pkg-config is at least version $ntp_pkgconfig_min_version" >&5
24733 $as_echo_n "checking if pkg-config is at least version $ntp_pkgconfig_min_version... " >&6; }
24734     if $PKG_CONFIG --atleast-pkgconfig-version $ntp_pkgconfig_min_version; then
24735         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
24736 $as_echo "yes" >&6; }
24737     else
24738         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24739 $as_echo "no" >&6; }
24740         PKG_CONFIG=""
24741     fi
24742     ;;
24743 esac
24744
24745
24746
24747
24748 # Check whether --enable-local-libevent was given.
24749 if test "${enable_local_libevent+set}" = set; then :
24750   enableval=$enable_local_libevent; ntp_use_local_libevent=$enableval
24751 else
24752   ntp_use_local_libevent=${ntp_use_local_libevent-detect}
24753
24754 fi
24755
24756
24757
24758
24759
24760
24761
24762
24763
24764
24765 ntp_libevent_min_version=2
24766 ntp_libevent_tearoff=libevent
24767
24768
24769
24770
24771 case "$ntp_use_local_libevent" in
24772  yes)
24773     ;;
24774  *) # If we have (a good enough) pkg-config, see if it can find libevent
24775     case "$PKG_CONFIG" in
24776      /*)
24777         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libevent $ntp_libevent_min_version or later is installed" >&5
24778 $as_echo_n "checking if libevent $ntp_libevent_min_version or later is installed... " >&6; }
24779         if $PKG_CONFIG --atleast-version=$ntp_libevent_min_version libevent
24780         then
24781             ntp_use_local_libevent=no
24782             { $as_echo "$as_me:${as_lineno-$LINENO}: Using the installed libevent" >&5
24783 $as_echo "$as_me: Using the installed libevent" >&6;}
24784             CPPFLAGS_LIBEVENT=`$PKG_CONFIG --cflags-only-I libevent`
24785             # HMS: I hope the following is accurate.
24786             # We don't need -levent, we only need  -levent_core.
24787             # While we could grab only the -L stuff, there *might* be
24788             # other flags there we want.  Originally we just removed -levent
24789             # but then somebody decided to install -levent-2.0
24790             # LDADD_LIBEVENT=`$PKG_CONFIG --libs libevent | sed 's:-levent::'`
24791             # So now we dance...
24792             LDADD_LIBEVENT=
24793             for i in `$PKG_CONFIG --libs libevent`
24794             do
24795                 case "$i" in
24796                  -levent*) ;;
24797                  *) case "$LDADD_LIBEVENT" in
24798                      '') LDADD_LIBEVENT="$i" ;;
24799                      *) LDADD_LIBEVENT="$LDADD_LIBEVENT $i" ;;
24800                     esac
24801                     ;;
24802                 esac
24803             done
24804             case "$LIBISC_PTHREADS_NOTHREADS" in
24805              pthreads)
24806                 LDADD_LIBEVENT="$LDADD_LIBEVENT -levent_pthreads"
24807             esac
24808             LDADD_LIBEVENT="$LDADD_LIBEVENT -levent_core"
24809             { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
24810 $as_echo "yes" >&6; }
24811         else
24812             ntp_use_local_libevent=yes
24813             { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
24814 $as_echo "no" >&6; }
24815         fi
24816         ;;
24817      *)
24818         ntp_use_local_libevent=yes
24819         ;;
24820     esac
24821     ;;
24822 esac
24823
24824 case "$ntp_use_local_libevent" in
24825  yes)
24826     { $as_echo "$as_me:${as_lineno-$LINENO}: Using libevent tearoff" >&5
24827 $as_echo "$as_me: Using libevent tearoff" >&6;}
24828     CPPFLAGS_LIBEVENT="-I\$(top_builddir)/$ntp_libevent_tearoff/include -I\$(top_srcdir)/$ntp_libevent_tearoff/include"
24829     case "$LIBISC_PTHREADS_NOTHREADS" in
24830      pthreads)
24831         LDADD_LIBEVENT="\$(top_builddir)/$ntp_libevent_tearoff/libevent_pthreads.la \$(top_builddir)/$ntp_libevent_tearoff/libevent_core.la"
24832         ;;
24833      *)
24834         LDADD_LIBEVENT="\$(top_builddir)/$ntp_libevent_tearoff/libevent_core.la"
24835     esac
24836 esac
24837
24838  if test "x$ntp_use_local_libevent" = "xyes"; then
24839   BUILD_LIBEVENT_TRUE=
24840   BUILD_LIBEVENT_FALSE='#'
24841 else
24842   BUILD_LIBEVENT_TRUE='#'
24843   BUILD_LIBEVENT_FALSE=
24844 fi
24845
24846
24847
24848
24849 case "$ntp_libevent_tearoff" in
24850  libevent)
24851     ;;
24852  *)
24853     as_fn_error $? "ntp_libevent.m4 dir must be libevent, not $ntp_libevent_tearoff" "$LINENO" 5
24854     ;;
24855 esac
24856
24857 case "$ntp_use_local_libevent" in
24858  yes)
24859                         ac_configure_args=" --disable-openssl${ac_configure_args}"
24860     ac_configure_args=" --disable-shared${ac_configure_args}"
24861     ac_configure_args=" --disable-libevent-regress${ac_configure_args}"
24862     ac_configure_args=" --disable-libevent-install${ac_configure_args}"
24863     ac_configure_args=" --enable-silent-rules${ac_configure_args}"
24864     ac_configure_args=" --enable-function-sections${ac_configure_args}"
24865     subdirs="$subdirs libevent"
24866
24867     ;;
24868  *)
24869     NTP_FORCE_LIBEVENT_DIST=libevent
24870     ;;
24871 esac
24872
24873
24874
24875 # Checks for libraries.
24876
24877
24878 LIB_SYSLOG=''
24879
24880 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing openlog" >&5
24881 $as_echo_n "checking for library containing openlog... " >&6; }
24882 if ${ac_cv_search_openlog+:} false; then :
24883   $as_echo_n "(cached) " >&6
24884 else
24885   ac_func_search_save_LIBS=$LIBS
24886 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24887 /* end confdefs.h.  */
24888
24889 /* Override any GCC internal prototype to avoid an error.
24890    Use char because int might match the return type of a GCC
24891    builtin and then its argument prototype would still apply.  */
24892 #ifdef __cplusplus
24893 extern "C"
24894 #endif
24895 char openlog ();
24896 int
24897 main ()
24898 {
24899 return openlog ();
24900   ;
24901   return 0;
24902 }
24903 _ACEOF
24904 for ac_lib in '' gen syslog; do
24905   if test -z "$ac_lib"; then
24906     ac_res="none required"
24907   else
24908     ac_res=-l$ac_lib
24909     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
24910   fi
24911   if ac_fn_c_try_link "$LINENO"; then :
24912   ac_cv_search_openlog=$ac_res
24913 fi
24914 rm -f core conftest.err conftest.$ac_objext \
24915     conftest$ac_exeext
24916   if ${ac_cv_search_openlog+:} false; then :
24917   break
24918 fi
24919 done
24920 if ${ac_cv_search_openlog+:} false; then :
24921
24922 else
24923   ac_cv_search_openlog=no
24924 fi
24925 rm conftest.$ac_ext
24926 LIBS=$ac_func_search_save_LIBS
24927 fi
24928 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_openlog" >&5
24929 $as_echo "$ac_cv_search_openlog" >&6; }
24930 ac_res=$ac_cv_search_openlog
24931 if test "$ac_res" != no; then :
24932   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
24933   case "$ac_cv_search_openlog" in
24934  'none required') ;;
24935  no) ;;
24936  *) LIB_SYSLOG="$ac_cv_search_openlog $LIB_SYSLOG" ;;
24937  esac
24938
24939 fi
24940
24941
24942 # Checks for header files.
24943 for ac_header in netdb.h string.h strings.h syslog.h
24944 do :
24945   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
24946 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
24947 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
24948   cat >>confdefs.h <<_ACEOF
24949 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
24950 _ACEOF
24951
24952 fi
24953
24954 done
24955
24956
24957
24958 for ac_header in sysexits.h
24959 do :
24960   ac_fn_c_check_header_mongrel "$LINENO" "sysexits.h" "ac_cv_header_sysexits_h" "$ac_includes_default"
24961 if test "x$ac_cv_header_sysexits_h" = xyes; then :
24962   cat >>confdefs.h <<_ACEOF
24963 #define HAVE_SYSEXITS_H 1
24964 _ACEOF
24965
24966 else
24967
24968
24969 $as_echo "#define EX_OK 0" >>confdefs.h
24970
24971
24972 $as_echo "#define EX_SOFTWARE 70" >>confdefs.h
24973
24974
24975 fi
24976
24977 done
24978
24979
24980
24981 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for facilitynames in syslog.h" >&5
24982 $as_echo_n "checking for facilitynames in syslog.h... " >&6; }
24983 if ${ac_cv_HAVE_SYSLOG_FACILITYNAMES+:} false; then :
24984   $as_echo_n "(cached) " >&6
24985 else
24986
24987 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24988 /* end confdefs.h.  */
24989
24990 #define SYSLOG_NAMES
24991 #include <stdlib.h>
24992 #include <syslog.h>
24993
24994 int
24995 main ()
24996 {
24997  void *fnames; fnames = facilitynames;
24998   ;
24999   return 0;
25000 }
25001 _ACEOF
25002 if ac_fn_c_try_compile "$LINENO"; then :
25003   ac_cv_HAVE_SYSLOG_FACILITYNAMES=yes
25004 else
25005   ac_cv_HAVE_SYSLOG_FACILITYNAMES=no
25006 fi
25007 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25008 fi
25009 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_HAVE_SYSLOG_FACILITYNAMES" >&5
25010 $as_echo "$ac_cv_HAVE_SYSLOG_FACILITYNAMES" >&6; }
25011 case "$ac_cv_HAVE_SYSLOG_FACILITYNAMES" in
25012  yes)
25013
25014 $as_echo "#define HAVE_SYSLOG_FACILITYNAMES 1" >>confdefs.h
25015
25016     ;;
25017  no)
25018     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: No facilitynames in <syslog.h>" >&5
25019 $as_echo "$as_me: WARNING: No facilitynames in <syslog.h>" >&2;}
25020     ;;
25021  cross)
25022     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: facilitynames in <syslog.h> - cross-compiling" >&5
25023 $as_echo "$as_me: WARNING: facilitynames in <syslog.h> - cross-compiling" >&2;}
25024     ;;
25025 esac
25026
25027
25028 # Checks for typedefs, structures, and compiler characteristics.
25029 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
25030 $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
25031 if ${ac_cv_header_stdbool_h+:} false; then :
25032   $as_echo_n "(cached) " >&6
25033 else
25034   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25035 /* end confdefs.h.  */
25036
25037 #include <stdbool.h>
25038 #ifndef bool
25039  "error: bool is not defined"
25040 #endif
25041 #ifndef false
25042  "error: false is not defined"
25043 #endif
25044 #if false
25045  "error: false is not 0"
25046 #endif
25047 #ifndef true
25048  "error: true is not defined"
25049 #endif
25050 #if true != 1
25051  "error: true is not 1"
25052 #endif
25053 #ifndef __bool_true_false_are_defined
25054  "error: __bool_true_false_are_defined is not defined"
25055 #endif
25056
25057         struct s { _Bool s: 1; _Bool t; } s;
25058
25059         char a[true == 1 ? 1 : -1];
25060         char b[false == 0 ? 1 : -1];
25061         char c[__bool_true_false_are_defined == 1 ? 1 : -1];
25062         char d[(bool) 0.5 == true ? 1 : -1];
25063         /* See body of main program for 'e'.  */
25064         char f[(_Bool) 0.0 == false ? 1 : -1];
25065         char g[true];
25066         char h[sizeof (_Bool)];
25067         char i[sizeof s.t];
25068         enum { j = false, k = true, l = false * true, m = true * 256 };
25069         /* The following fails for
25070            HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
25071         _Bool n[m];
25072         char o[sizeof n == m * sizeof n[0] ? 1 : -1];
25073         char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
25074         /* Catch a bug in an HP-UX C compiler.  See
25075            http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
25076            http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
25077          */
25078         _Bool q = true;
25079         _Bool *pq = &q;
25080
25081 int
25082 main ()
25083 {
25084
25085         bool e = &s;
25086         *pq |= q;
25087         *pq |= ! q;
25088         /* Refer to every declared value, to avoid compiler optimizations.  */
25089         return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
25090                 + !m + !n + !o + !p + !q + !pq);
25091
25092   ;
25093   return 0;
25094 }
25095 _ACEOF
25096 if ac_fn_c_try_compile "$LINENO"; then :
25097   ac_cv_header_stdbool_h=yes
25098 else
25099   ac_cv_header_stdbool_h=no
25100 fi
25101 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25102 fi
25103 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
25104 $as_echo "$ac_cv_header_stdbool_h" >&6; }
25105 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
25106 if test "x$ac_cv_type__Bool" = xyes; then :
25107
25108 cat >>confdefs.h <<_ACEOF
25109 #define HAVE__BOOL 1
25110 _ACEOF
25111
25112
25113 fi
25114
25115 if test $ac_cv_header_stdbool_h = yes; then
25116
25117 $as_echo "#define HAVE_STDBOOL_H 1" >>confdefs.h
25118
25119 fi
25120
25121
25122
25123
25124
25125 VER_SUFFIX=
25126
25127
25128
25129
25130 # Check whether --with-crypto was given.
25131 if test "${with_crypto+set}" = set; then :
25132   withval=$with_crypto;
25133 fi
25134
25135
25136 # Check whether --with-openssl-libdir was given.
25137 if test "${with_openssl_libdir+set}" = set; then :
25138   withval=$with_openssl_libdir;
25139 fi
25140
25141
25142 # Check whether --with-openssl-incdir was given.
25143 if test "${with_openssl_incdir+set}" = set; then :
25144   withval=$with_openssl_incdir;
25145 fi
25146
25147
25148 # Check whether --with-rpath was given.
25149 if test "${with_rpath+set}" = set; then :
25150   withval=$with_rpath;
25151 fi
25152
25153 ntp_openssl=no
25154 ntp_openssl_from_pkg_config=no
25155 with_crypto=${with_crypto:-openssl,libcrypto}
25156 case "$with_crypto" in
25157  yes)
25158     with_crypto=openssl,libcrypto
25159 esac
25160 case "$with_crypto:${PKG_CONFIG:+notempty}:${with_openssl_libdir-notgiven}:${with_openssl_incdir-notgiven}" in
25161  no:*) ;;
25162  *:notempty:notgiven:notgiven)
25163     for pkg in `echo $with_crypto | sed -e 's/,/ /'`; do
25164         { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config for $pkg" >&5
25165 $as_echo_n "checking pkg-config for $pkg... " >&6; }
25166         if $PKG_CONFIG --exists $pkg ; then
25167             CPPFLAGS_NTP="$CPPFLAGS_NTP `$PKG_CONFIG --cflags-only-I $pkg`"
25168             CFLAGS_NTP="$CFLAGS_NTP `$PKG_CONFIG --cflags-only-other $pkg`"
25169             LDADD_NTP="$LDADD_NTP `$PKG_CONFIG --libs-only-L $pkg`"
25170             LDADD_NTP="$LDADD_NTP `$PKG_CONFIG --libs-only-l $pkg`"
25171             LDFLAGS_NTP="$LDFLAGS_NTP `$PKG_CONFIG --libs-only-other $pkg`"
25172             VER_SUFFIX=o
25173             ntp_openssl=yes
25174             ntp_openssl_from_pkg_config=yes
25175             { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
25176 $as_echo "yes" >&6; }
25177
25178             break
25179         fi
25180         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25181 $as_echo "no" >&6; }
25182     done
25183 esac
25184 case "$with_crypto:$ntp_openssl" in
25185  no:*) ;;
25186  *:no)
25187     need_dash_r=
25188     need_dash_Wlrpath=
25189     case "${with_rpath-notgiven}" in
25190      yes)
25191         # Lame - what to do if we need -Wl... but not -R?
25192         need_dash_r=1
25193         ;;
25194      notgiven)
25195         case "$host" in
25196          *-*-linux*)
25197             # This may really only be true for gcc
25198             need_dash_Wlrpath=1
25199             ;;
25200          *-*-netbsd*)
25201             need_dash_r=1
25202             ;;
25203          *-*-solaris*)
25204             need_dash_r=1
25205             ;;
25206         esac
25207         ;;
25208     esac
25209
25210     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openssl library directory" >&5
25211 $as_echo_n "checking for openssl library directory... " >&6; }
25212     with_openssl_libdir=${with_openssl_libdir-notgiven}
25213     case "$with_openssl_libdir" in
25214      notgiven)
25215         case "$build" in
25216          $host)
25217             with_openssl_libdir=default
25218             ;;
25219          *)
25220             with_openssl_libdir=no
25221             ;;
25222         esac
25223     esac
25224     case "$with_openssl_libdir" in
25225      default)
25226         # Look in:
25227         with_openssl_libdir="/usr/lib /usr/lib/openssl /usr/sfw/lib"
25228         with_openssl_libdir="$with_openssl_libdir /usr/local/lib"
25229         with_openssl_libdir="$with_openssl_libdir /usr/local/ssl/lib /lib"
25230     esac
25231     case "$with_openssl_libdir" in
25232      no)
25233         ;;
25234      *) # Look for libcrypto.a and libssl.a:
25235         for i in $with_openssl_libdir no
25236         do
25237             case "$host" in
25238              *-*-darwin*)
25239                 test -f $i/libcrypto.dylib -a -f $i/libssl.dylib && break
25240                 ;;
25241              *)
25242                 test -f $i/libcrypto.so -a -f $i/libssl.so && break
25243                 test -f $i/libcrypto.a -a -f $i/libssl.a && break
25244                 ;;
25245             esac
25246         done
25247         openssl_libdir=$i
25248         ;;
25249     esac
25250     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $openssl_libdir" >&5
25251 $as_echo "$openssl_libdir" >&6; }
25252     case "$openssl_libdir" in
25253      no)
25254         openssl_libdir=
25255         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libcrypto and libssl not found in any of $with_openssl_libdir" >&5
25256 $as_echo "$as_me: WARNING: libcrypto and libssl not found in any of $with_openssl_libdir" >&2;}
25257     esac
25258
25259     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for openssl include directory" >&5
25260 $as_echo_n "checking for openssl include directory... " >&6; }
25261     with_openssl_incdir=${with_openssl_incdir-notgiven}
25262     case "$with_openssl_incdir" in
25263      notgiven)
25264         # Look in:
25265         with_openssl_incdir="/usr/include /usr/sfw/include"
25266         with_openssl_incdir="$with_openssl_incdir /usr/local/include"
25267         with_openssl_incdir="$with_openssl_incdir /usr/local/ssl/include"
25268     esac
25269     case "$with_openssl_incdir" in
25270      no)
25271         ;;
25272      *) # look for openssl/evp.h:
25273         for i in $with_openssl_incdir no
25274         do
25275             test -f $i/openssl/evp.h && break
25276         done
25277         openssl_incdir=$i
25278         ;;
25279     esac
25280     { i=; unset i;}
25281     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $openssl_incdir" >&5
25282 $as_echo "$openssl_incdir" >&6; }
25283     case "$openssl_incdir" in
25284      no)
25285         openssl_incdir=
25286         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: did not find openssl/evp.h in any of $with_openssl_incdir" >&5
25287 $as_echo "$as_me: WARNING: did not find openssl/evp.h in any of $with_openssl_incdir" >&2;}
25288     esac
25289     if test -z "$openssl_libdir" -o -z "$openssl_incdir"
25290     then
25291         ntp_openssl=no
25292     else
25293         ntp_openssl=yes
25294         VER_SUFFIX=o
25295     fi
25296     case "$ntp_openssl" in
25297      yes)
25298         # We have OpenSSL inc/lib dirs - use them.
25299         case "$openssl_incdir" in
25300          /usr/include)
25301             ;;
25302          *)
25303             CPPFLAGS_NTP="$CPPFLAGS_NTP -I$openssl_incdir"
25304             ;;
25305         esac
25306         case "$openssl_libdir" in
25307          /usr/lib)
25308             ;;
25309          *)
25310             LDADD_NTP="$LDADD_NTP -L$openssl_libdir"
25311             case "$need_dash_r" in
25312              1)
25313                 LDFLAGS_NTP="$LDFLAGS_NTP -R$openssl_libdir"
25314             esac
25315             case "$need_dash_Wlrpath" in
25316              1)
25317                 LDFLAGS_NTP="$LDFLAGS_NTP -Wl,-rpath,$openssl_libdir"
25318             esac
25319             ;;
25320         esac
25321         LDADD_NTP="$LDADD_NTP -lcrypto"
25322     esac
25323 esac
25324
25325 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we will use crypto" >&5
25326 $as_echo_n "checking if we will use crypto... " >&6; }
25327 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_openssl" >&5
25328 $as_echo "$ntp_openssl" >&6; }
25329
25330 case "$ntp_openssl" in
25331  yes)
25332
25333 $as_echo "#define OPENSSL /**/" >>confdefs.h
25334
25335     case "$VER_SUFFIX" in
25336      *o*) ;;
25337      *) as_fn_error $? "OPENSSL set but no 'o' in VER_SUFFIX!" "$LINENO" 5 ;;
25338     esac
25339     ;;
25340 esac
25341
25342 NTPO_SAVED_CPPFLAGS="$CPPFLAGS"
25343 CPPFLAGS="$CPPFLAGS $CPPFLAGS_NTP"
25344 NTPO_SAVED_LIBS="$LIBS"
25345
25346 #
25347 # check for linking with -lcrypto failure, and try -lcrypto -lz.
25348 # Helps m68k-atari-mint
25349 #
25350 case "$ntp_openssl:$ntp_openssl_from_pkg_config" in
25351  yes:no)
25352     LIBS="$NTPO_SAVED_LIBS $LDADD_NTP"
25353     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linking with -lcrypto alone works" >&5
25354 $as_echo_n "checking if linking with -lcrypto alone works... " >&6; }
25355 if ${ntp_cv_bare_lcrypto+:} false; then :
25356   $as_echo_n "(cached) " >&6
25357 else
25358   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25359 /* end confdefs.h.  */
25360
25361                     #include "openssl/err.h"
25362                     #include "openssl/evp.h"
25363
25364 int
25365 main ()
25366 {
25367
25368                     ERR_load_crypto_strings();
25369                     OpenSSL_add_all_algorithms();
25370
25371
25372   ;
25373   return 0;
25374 }
25375 _ACEOF
25376 if ac_fn_c_try_link "$LINENO"; then :
25377   ntp_cv_bare_lcrypto=yes
25378 else
25379   ntp_cv_bare_lcrypto=no
25380
25381 fi
25382 rm -f core conftest.err conftest.$ac_objext \
25383     conftest$ac_exeext conftest.$ac_ext
25384
25385 fi
25386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_bare_lcrypto" >&5
25387 $as_echo "$ntp_cv_bare_lcrypto" >&6; }
25388     case "$ntp_cv_bare_lcrypto" in
25389      no)
25390         LIBS="$NTPO_SAVED_LIBS $LDADD_NTP -lz"
25391         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linking with -lcrypto -lz works" >&5
25392 $as_echo_n "checking if linking with -lcrypto -lz works... " >&6; }
25393 if ${ntp_cv_lcrypto_lz+:} false; then :
25394   $as_echo_n "(cached) " >&6
25395 else
25396   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25397 /* end confdefs.h.  */
25398
25399                         #include "openssl/err.h"
25400                         #include "openssl/evp.h"
25401
25402 int
25403 main ()
25404 {
25405
25406                         ERR_load_crypto_strings();
25407                         OpenSSL_add_all_algorithms();
25408
25409
25410   ;
25411   return 0;
25412 }
25413 _ACEOF
25414 if ac_fn_c_try_link "$LINENO"; then :
25415   ntp_cv_lcrypto_lz=yes
25416 else
25417   ntp_cv_lcrypto_lz=no
25418
25419 fi
25420 rm -f core conftest.err conftest.$ac_objext \
25421     conftest$ac_exeext conftest.$ac_ext
25422
25423 fi
25424 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_lcrypto_lz" >&5
25425 $as_echo "$ntp_cv_lcrypto_lz" >&6; }
25426         case "$ntp_cv_lcrypto_lz" in
25427          yes)
25428              LDADD_NTP="$LDADD_NTP -lz"
25429         esac
25430     esac
25431 esac
25432
25433 #
25434 # Older OpenSSL headers have a number of callback prototypes inside
25435 # other function prototypes which trigger copious warnings with gcc's
25436 # -Wstrict-prototypes, which is included in -Wall.
25437 #
25438 # An example:
25439 #
25440 # int i2d_RSA_NET(const RSA *a, unsigned char **pp,
25441 #                 int (*cb)(), int sgckey);
25442 #                 ^^^^^^^^^^^
25443 #
25444 #
25445 #
25446 openssl_triggers_warnings=unknown
25447 NTPO_SAVED_CFLAGS="$CFLAGS"
25448
25449 case "$ntp_openssl:$GCC" in
25450  yes:yes)
25451     CFLAGS="$CFLAGS -Werror"
25452     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25453 /* end confdefs.h.  */
25454
25455
25456 int
25457 main ()
25458 {
25459
25460                 /* see if -Werror breaks gcc */
25461
25462
25463   ;
25464   return 0;
25465 }
25466 _ACEOF
25467 if ac_fn_c_try_compile "$LINENO"; then :
25468   gcc_handles_Werror=yes
25469 else
25470   gcc_handles_Werror=no
25471
25472 fi
25473 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25474     case "$gcc_handles_Werror" in
25475      no)
25476         # if this gcc doesn't do -Werror go ahead and use
25477         # -Wstrict-prototypes.
25478         openssl_triggers_warnings=yes
25479         ;;
25480      yes)
25481         CFLAGS="$CFLAGS -Wstrict-prototypes"
25482         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25483 /* end confdefs.h.  */
25484
25485                     #include "openssl/asn1_mac.h"
25486                     #include "openssl/bn.h"
25487                     #include "openssl/err.h"
25488                     #include "openssl/evp.h"
25489                     #include "openssl/pem.h"
25490                     #include "openssl/rand.h"
25491                     #include "openssl/x509v3.h"
25492
25493 int
25494 main ()
25495 {
25496
25497                     /* empty body */
25498
25499
25500   ;
25501   return 0;
25502 }
25503 _ACEOF
25504 if ac_fn_c_try_compile "$LINENO"; then :
25505   openssl_triggers_warnings=no
25506 else
25507   openssl_triggers_warnings=yes
25508
25509 fi
25510 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25511     esac
25512     case "$openssl_triggers_warnings" in
25513      yes)
25514         CFLAGS_NTP="$CFLAGS_NTP -Wno-strict-prototypes"
25515         ;;
25516      *)
25517         CFLAGS_NTP="$CFLAGS_NTP -Wstrict-prototypes"
25518     esac
25519     ;;
25520  no:yes)
25521     # gcc without OpenSSL
25522     CFLAGS_NTP="$CFLAGS_NTP -Wstrict-prototypes"
25523 esac
25524
25525 CFLAGS="$NTPO_SAVED_CFLAGS"
25526 CPPFLAGS="$NTPO_SAVED_CPPFLAGS"
25527 LIBS="$NTPO_SAVED_LIBS"
25528 { NTPO_SAVED_CFLAGS=; unset NTPO_SAVED_CFLAGS;}
25529 { NTPO_SAVED_CPPFLAGS=; unset NTPO_SAVED_CPPFLAGS;}
25530 { NTPO_SAVED_LIBS=; unset NTPO_SAVED_LIBS;}
25531 { openssl_triggers_warnings=; unset openssl_triggers_warnings;}
25532 { ntp_openssl_from_pkg_config=; unset ntp_openssl_from_pkg_config;}
25533
25534
25535
25536 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct sockaddr_storage" >&5
25537 $as_echo_n "checking for struct sockaddr_storage... " >&6; }
25538 if ${ntp_cv_sockaddr_storage+:} false; then :
25539   $as_echo_n "(cached) " >&6
25540 else
25541   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25542 /* end confdefs.h.  */
25543
25544                 #ifdef HAVE_SYS_TYPES_H
25545                 # include <sys/types.h>
25546                 #endif
25547                 #ifdef HAVE_SYS_SOCKET_H
25548                 # include <sys/socket.h>
25549                 #endif
25550                 #ifdef HAVE_NETINET_IN_H
25551                 # include <netinet/in.h>
25552                 #endif
25553
25554 int
25555 main ()
25556 {
25557
25558                 struct sockaddr_storage n;
25559
25560
25561   ;
25562   return 0;
25563 }
25564 _ACEOF
25565 if ac_fn_c_try_compile "$LINENO"; then :
25566   ntp_cv_sockaddr_storage=yes
25567 else
25568   ntp_cv_sockaddr_storage=no
25569
25570 fi
25571 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25572
25573 fi
25574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_sockaddr_storage" >&5
25575 $as_echo "$ntp_cv_sockaddr_storage" >&6; }
25576 case "$ntp_cv_sockaddr_storage" in
25577  yes)
25578
25579 $as_echo "#define HAVE_STRUCT_SOCKADDR_STORAGE 1" >>confdefs.h
25580
25581     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sockaddr_storage.__ss_family" >&5
25582 $as_echo_n "checking for sockaddr_storage.__ss_family... " >&6; }
25583 if ${ntp_cv_have___ss_family+:} false; then :
25584   $as_echo_n "(cached) " >&6
25585 else
25586   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25587 /* end confdefs.h.  */
25588
25589                     #ifdef HAVE_SYS_TYPES_H
25590                     # include <sys/types.h>
25591                     #endif
25592                     #ifdef HAVE_SYS_SOCKET_H
25593                     # include <sys/socket.h>
25594                     #endif
25595                     #ifdef HAVE_NETINET_IN_H
25596                     # include <netinet/in.h>
25597                     #endif
25598
25599 int
25600 main ()
25601 {
25602
25603                     struct sockaddr_storage s;
25604                     s.__ss_family = 1;
25605
25606
25607   ;
25608   return 0;
25609 }
25610 _ACEOF
25611 if ac_fn_c_try_compile "$LINENO"; then :
25612   ntp_cv_have___ss_family=yes
25613 else
25614   ntp_cv_have___ss_family=no
25615
25616 fi
25617 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25618
25619 fi
25620 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_have___ss_family" >&5
25621 $as_echo "$ntp_cv_have___ss_family" >&6; }
25622     case "$ntp_cv_have___ss_family" in
25623      yes)
25624
25625 $as_echo "#define HAVE___SS_FAMILY_IN_SS 1" >>confdefs.h
25626
25627     esac
25628
25629 esac
25630
25631
25632 #
25633 # Look for in_port_t.
25634 #
25635 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for in_port_t" >&5
25636 $as_echo_n "checking for in_port_t... " >&6; }
25637 if ${isc_cv_have_in_port_t+:} false; then :
25638   $as_echo_n "(cached) " >&6
25639 else
25640   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25641 /* end confdefs.h.  */
25642
25643                 #include <sys/types.h>
25644                 #include <netinet/in.h>
25645
25646 int
25647 main ()
25648 {
25649
25650                 in_port_t port = 25;
25651                 return (0);
25652
25653
25654   ;
25655   return 0;
25656 }
25657 _ACEOF
25658 if ac_fn_c_try_compile "$LINENO"; then :
25659   isc_cv_have_in_port_t=yes
25660 else
25661   isc_cv_have_in_port_t=no
25662
25663 fi
25664 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25665
25666 fi
25667 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_have_in_port_t" >&5
25668 $as_echo "$isc_cv_have_in_port_t" >&6; }
25669 case "$isc_cv_have_in_port_t" in
25670  no)
25671
25672 $as_echo "#define ISC_PLATFORM_NEEDPORTT 1" >>confdefs.h
25673
25674 esac
25675
25676 { $as_echo "$as_me:${as_lineno-$LINENO}: checking type of socklen arg for getsockname()" >&5
25677 $as_echo_n "checking type of socklen arg for getsockname()... " >&6; }
25678 if ${ntp_cv_getsockname_socklen_type+:} false; then :
25679   $as_echo_n "(cached) " >&6
25680 else
25681
25682     getsockname_socklen_type_found=no
25683     for getsockname_arg2 in 'struct sockaddr *' 'void *'; do
25684         for ntp_cv_getsockname_socklen_type in 'socklen_t' 'size_t' 'unsigned int' 'int'; do
25685             cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25686 /* end confdefs.h.  */
25687
25688                         #ifdef HAVE_SYS_TYPES_H
25689                         # include <sys/types.h>
25690                         #endif
25691                         #ifdef HAVE_SYS_SOCKET_H
25692                         # include <sys/socket.h>
25693                         #endif
25694
25695 int
25696 main ()
25697 {
25698
25699                         extern
25700                         getsockname(int, $getsockname_arg2,
25701                                 $ntp_cv_getsockname_socklen_type *);
25702
25703
25704   ;
25705   return 0;
25706 }
25707 _ACEOF
25708 if ac_fn_c_try_compile "$LINENO"; then :
25709   getsockname_socklen_type_found=yes ; break 2
25710 fi
25711 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25712         done
25713     done
25714     case "$getsockname_socklen_type_found" in
25715      no)
25716         ntp_cv_getsockname_socklen_type='socklen_t'
25717     esac
25718     { getsockname_arg2=; unset getsockname_arg2;}
25719     { getsockname_socklen_type_found=; unset getsockname_socklen_type_found;}
25720
25721
25722 fi
25723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_getsockname_socklen_type" >&5
25724 $as_echo "$ntp_cv_getsockname_socklen_type" >&6; }
25725
25726 cat >>confdefs.h <<_ACEOF
25727 #define GETSOCKNAME_SOCKLEN_TYPE $ntp_cv_getsockname_socklen_type
25728 _ACEOF
25729
25730
25731 { $as_echo "$as_me:${as_lineno-$LINENO}: checking struct sockaddr for sa_len" >&5
25732 $as_echo_n "checking struct sockaddr for sa_len... " >&6; }
25733 if ${isc_cv_platform_havesalen+:} false; then :
25734   $as_echo_n "(cached) " >&6
25735 else
25736   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25737 /* end confdefs.h.  */
25738
25739                 #include <sys/types.h>
25740                 #include <sys/socket.h>
25741
25742 int
25743 main ()
25744 {
25745
25746                 extern struct sockaddr *ps;
25747                 return ps->sa_len;
25748
25749
25750   ;
25751   return 0;
25752 }
25753 _ACEOF
25754 if ac_fn_c_try_compile "$LINENO"; then :
25755   isc_cv_platform_havesalen=yes
25756 else
25757   isc_cv_platform_havesalen=no
25758
25759 fi
25760 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25761
25762 fi
25763 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_platform_havesalen" >&5
25764 $as_echo "$isc_cv_platform_havesalen" >&6; }
25765 case "$isc_cv_platform_havesalen" in
25766  yes)
25767
25768 $as_echo "#define ISC_PLATFORM_HAVESALEN 1" >>confdefs.h
25769
25770 esac
25771
25772 # Check whether --enable-ipv6 was given.
25773 if test "${enable_ipv6+set}" = set; then :
25774   enableval=$enable_ipv6;
25775 fi
25776
25777
25778 case "$enable_ipv6" in
25779  yes|''|autodetect)
25780     case "$host" in
25781      powerpc-ibm-aix4*)
25782         ;;
25783      *)
25784
25785 $as_echo "#define WANT_IPV6 1" >>confdefs.h
25786
25787         ;;
25788     esac
25789     ;;
25790  no)
25791     ;;
25792 esac
25793
25794
25795 case "$host" in
25796  *-*-darwin*)
25797
25798 $as_echo "#define __APPLE_USE_RFC_3542 1" >>confdefs.h
25799
25800 esac
25801
25802
25803 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IPv6 structures" >&5
25804 $as_echo_n "checking for IPv6 structures... " >&6; }
25805 if ${isc_cv_found_ipv6+:} false; then :
25806   $as_echo_n "(cached) " >&6
25807 else
25808   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25809 /* end confdefs.h.  */
25810
25811                 #include <sys/types.h>
25812                 #include <sys/socket.h>
25813                 #include <netinet/in.h>
25814
25815 int
25816 main ()
25817 {
25818
25819                 struct sockaddr_in6 sin6;
25820
25821
25822   ;
25823   return 0;
25824 }
25825 _ACEOF
25826 if ac_fn_c_try_compile "$LINENO"; then :
25827   isc_cv_found_ipv6=yes
25828 else
25829   isc_cv_found_ipv6=no
25830
25831 fi
25832 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25833
25834 fi
25835 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_found_ipv6" >&5
25836 $as_echo "$isc_cv_found_ipv6" >&6; }
25837
25838 #
25839 # See whether IPv6 support is provided via a Kame add-on.
25840 # This is done before other IPv6 linking tests so LIBS is properly set.
25841 #
25842 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Kame IPv6 support" >&5
25843 $as_echo_n "checking for Kame IPv6 support... " >&6; }
25844
25845 # Check whether --with-kame was given.
25846 if test "${with_kame+set}" = set; then :
25847   withval=$with_kame; use_kame="$withval"
25848 else
25849   use_kame="no"
25850
25851 fi
25852
25853 case "$use_kame" in
25854  no)
25855     ;;
25856  yes)
25857     kame_path=/usr/local/v6
25858     ;;
25859  *)
25860     kame_path="$use_kame"
25861     ;;
25862 esac
25863 case "$use_kame" in
25864  no)
25865     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
25866 $as_echo "no" >&6; }
25867     ;;
25868  *)
25869     if test -f $kame_path/lib/libinet6.a; then
25870         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $kame_path/lib/libinet6.a" >&5
25871 $as_echo "$kame_path/lib/libinet6.a" >&6; }
25872         LIBS="-L$kame_path/lib -linet6 $LIBS"
25873     else
25874         as_fn_error $? "$kame_path/lib/libinet6.a not found.
25875
25876 Please choose the proper path with the following command:
25877
25878     configure --with-kame=PATH
25879 " "$LINENO" 5
25880     fi
25881     ;;
25882 esac
25883
25884 #
25885 # Whether netinet6/in6.h is needed has to be defined in isc/platform.h.
25886 # Including it on Kame-using platforms is very bad, though, because
25887 # Kame uses #error against direct inclusion.   So include it on only
25888 # the platform that is otherwise broken without it -- BSD/OS 4.0 through 4.1.
25889 # This is done before the in6_pktinfo check because that's what
25890 # netinet6/in6.h is needed for.
25891 #
25892 case "$host" in
25893  *-bsdi4.[01]*)
25894
25895 $as_echo "#define ISC_PLATFORM_NEEDNETINET6IN6H 1" >>confdefs.h
25896
25897     isc_netinet6in6_hack="#include <netinet6/in6.h>"
25898     ;;
25899  *)
25900     isc_netinet6in6_hack=""
25901     ;;
25902 esac
25903
25904 #
25905 # This is similar to the netinet6/in6.h issue.
25906 #
25907 case "$host" in
25908  *-sco-sysv*uw*|*-*-sysv*UnixWare*|*-*-sysv*OpenUNIX*)
25909
25910 $as_echo "#define ISC_PLATFORM_FIXIN6ISADDR 1" >>confdefs.h
25911
25912     isc_netinetin6_hack="#include <netinet/in6.h>"
25913     ;;
25914  *)
25915     isc_netinetin6_hack=""
25916     ;;
25917 esac
25918
25919
25920 case "$isc_cv_found_ipv6" in
25921  yes)
25922
25923 $as_echo "#define ISC_PLATFORM_HAVEIPV6 1" >>confdefs.h
25924
25925     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for in6_pktinfo" >&5
25926 $as_echo_n "checking for in6_pktinfo... " >&6; }
25927 if ${isc_cv_have_in6_pktinfo+:} false; then :
25928   $as_echo_n "(cached) " >&6
25929 else
25930   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25931 /* end confdefs.h.  */
25932
25933                     #include <sys/types.h>
25934                     #include <sys/socket.h>
25935                     #include <netinet/in.h>
25936                     $isc_netinetin6_hack
25937                     $isc_netinet6in6_hack
25938
25939 int
25940 main ()
25941 {
25942
25943                     struct in6_pktinfo xyzzy;
25944
25945
25946   ;
25947   return 0;
25948 }
25949 _ACEOF
25950 if ac_fn_c_try_compile "$LINENO"; then :
25951   isc_cv_have_in6_pktinfo=yes
25952 else
25953   isc_cv_have_in6_pktinfo=no
25954
25955 fi
25956 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25957
25958 fi
25959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_have_in6_pktinfo" >&5
25960 $as_echo "$isc_cv_have_in6_pktinfo" >&6; }
25961     case "$isc_cv_have_in6_pktinfo" in
25962      yes)
25963
25964 $as_echo "#define ISC_PLATFORM_HAVEIN6PKTINFO 1" >>confdefs.h
25965
25966     esac
25967
25968
25969     # HMS: Use HAVE_STRUCT_SOCKADDR_IN6_SIN6_SCOPE_ID instead?
25970     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sockaddr_in6.sin6_scope_id" >&5
25971 $as_echo_n "checking for sockaddr_in6.sin6_scope_id... " >&6; }
25972 if ${isc_cv_have_sin6_scope_id+:} false; then :
25973   $as_echo_n "(cached) " >&6
25974 else
25975   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25976 /* end confdefs.h.  */
25977
25978                     #include <sys/types.h>
25979                     #include <sys/socket.h>
25980                     #include <netinet/in.h>
25981                     $isc_netinetin6_hack
25982                     $isc_netinet6in6_hack
25983
25984 int
25985 main ()
25986 {
25987
25988                     struct sockaddr_in6 xyzzy;
25989                     xyzzy.sin6_scope_id = 0;
25990
25991
25992   ;
25993   return 0;
25994 }
25995 _ACEOF
25996 if ac_fn_c_try_compile "$LINENO"; then :
25997   isc_cv_have_sin6_scope_id=yes
25998 else
25999   isc_cv_have_sin6_scope_id=no
26000
26001 fi
26002 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26003
26004 fi
26005 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_have_sin6_scope_id" >&5
26006 $as_echo "$isc_cv_have_sin6_scope_id" >&6; }
26007
26008     case "$isc_cv_have_sin6_scope_id" in
26009      yes)
26010
26011 $as_echo "#define ISC_PLATFORM_HAVESCOPEID 1" >>confdefs.h
26012
26013     esac
26014 esac
26015
26016
26017 # We need this check run even without isc_cv_found_ipv6=yes
26018
26019 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for in6addr_any" >&5
26020 $as_echo_n "checking for in6addr_any... " >&6; }
26021 if ${isc_cv_in6addr_any_links+:} false; then :
26022   $as_echo_n "(cached) " >&6
26023 else
26024
26025         SAVED_LIBS="$LIBS"
26026         LIBS="$LDADD_LIBNTP $LIBS"
26027         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26028 /* end confdefs.h.  */
26029 $ac_includes_default
26030                     #include <sys/socket.h>
26031                     #include <netinet/in.h>
26032                     $isc_netinetin6_hack
26033                     $isc_netinet6in6_hack
26034
26035 int
26036 main ()
26037 {
26038
26039                     printf("%x", in6addr_any.s6_addr[15]);
26040
26041
26042   ;
26043   return 0;
26044 }
26045 _ACEOF
26046 if ac_fn_c_try_link "$LINENO"; then :
26047   isc_cv_in6addr_any_links=yes
26048 else
26049   isc_cv_in6addr_any_links=no
26050
26051 fi
26052 rm -f core conftest.err conftest.$ac_objext \
26053     conftest$ac_exeext conftest.$ac_ext
26054         LIBS="$SAVED_LIBS"
26055         { SAVED_LIBS=; unset SAVED_LIBS;}
26056
26057
26058 fi
26059 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_in6addr_any_links" >&5
26060 $as_echo "$isc_cv_in6addr_any_links" >&6; }
26061
26062 case "$isc_cv_in6addr_any_links" in
26063  no)
26064
26065 $as_echo "#define ISC_PLATFORM_NEEDIN6ADDRANY 1" >>confdefs.h
26066
26067 esac
26068
26069
26070 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct if_laddrconf" >&5
26071 $as_echo_n "checking for struct if_laddrconf... " >&6; }
26072 if ${isc_cv_struct_if_laddrconf+:} false; then :
26073   $as_echo_n "(cached) " >&6
26074 else
26075   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26076 /* end confdefs.h.  */
26077
26078                 #include <sys/types.h>
26079                 #include <net/if6.h>
26080
26081 int
26082 main ()
26083 {
26084
26085                 struct if_laddrconf a;
26086
26087
26088   ;
26089   return 0;
26090 }
26091 _ACEOF
26092 if ac_fn_c_try_compile "$LINENO"; then :
26093   isc_cv_struct_if_laddrconf=yes
26094 else
26095   isc_cv_struct_if_laddrconf=no
26096
26097 fi
26098 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26099
26100 fi
26101 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_struct_if_laddrconf" >&5
26102 $as_echo "$isc_cv_struct_if_laddrconf" >&6; }
26103
26104 case "$isc_cv_struct_if_laddrconf" in
26105  yes)
26106
26107 $as_echo "#define ISC_PLATFORM_HAVEIF_LADDRCONF 1" >>confdefs.h
26108
26109 esac
26110
26111 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct if_laddrreq" >&5
26112 $as_echo_n "checking for struct if_laddrreq... " >&6; }
26113 if ${isc_cv_struct_if_laddrreq+:} false; then :
26114   $as_echo_n "(cached) " >&6
26115 else
26116   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26117 /* end confdefs.h.  */
26118
26119                 #include <sys/types.h>
26120                 #include <net/if6.h>
26121
26122 int
26123 main ()
26124 {
26125
26126                 struct if_laddrreq a;
26127
26128
26129   ;
26130   return 0;
26131 }
26132 _ACEOF
26133 if ac_fn_c_try_compile "$LINENO"; then :
26134   isc_cv_struct_if_laddrreq=yes
26135 else
26136   isc_cv_struct_if_laddrreq=no
26137
26138 fi
26139 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26140
26141 fi
26142 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $isc_cv_struct_if_laddrreq" >&5
26143 $as_echo "$isc_cv_struct_if_laddrreq" >&6; }
26144
26145 case "$isc_cv_struct_if_laddrreq" in
26146  yes)
26147
26148 $as_echo "#define ISC_PLATFORM_HAVEIF_LADDRREQ 1" >>confdefs.h
26149
26150 esac
26151
26152 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for multicast IP support" >&5
26153 $as_echo_n "checking for multicast IP support... " >&6; }
26154 if ${ntp_cv_multicast+:} false; then :
26155   $as_echo_n "(cached) " >&6
26156 else
26157
26158         ntp_cv_multicast=no
26159         case "$host" in
26160          i386-sequent-sysv4)
26161             ;;
26162          *)
26163             cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26164 /* end confdefs.h.  */
26165
26166                         #ifdef HAVE_NETINET_IN_H
26167                         # include <netinet/in.h>
26168                         #endif
26169
26170 int
26171 main ()
26172 {
26173
26174                         struct ip_mreq ipmr;
26175                         ipmr.imr_interface.s_addr = 0;
26176
26177
26178   ;
26179   return 0;
26180 }
26181 _ACEOF
26182 if ac_fn_c_try_compile "$LINENO"; then :
26183   ntp_cv_multicast=yes
26184 fi
26185 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26186             ;;
26187         esac
26188
26189
26190 fi
26191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_multicast" >&5
26192 $as_echo "$ntp_cv_multicast" >&6; }
26193 case "$ntp_cv_multicast" in
26194  yes)
26195
26196 $as_echo "#define MCAST 1" >>confdefs.h
26197
26198     { $as_echo "$as_me:${as_lineno-$LINENO}: checking arg type needed for setsockopt() IP*_MULTICAST_LOOP" >&5
26199 $as_echo_n "checking arg type needed for setsockopt() IP*_MULTICAST_LOOP... " >&6; }
26200 if ${ntp_cv_typeof_ip_multicast_loop+:} false; then :
26201   $as_echo_n "(cached) " >&6
26202 else
26203
26204             case "$host" in
26205              *-*-netbsd*|*-*-*linux*)
26206                 ntp_cv_typeof_ip_multicast_loop=u_int
26207                 ;;
26208              *)
26209                 ntp_cv_typeof_ip_multicast_loop=u_char
26210                 ;;
26211             esac
26212
26213
26214 fi
26215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ntp_cv_typeof_ip_multicast_loop" >&5
26216 $as_echo "$ntp_cv_typeof_ip_multicast_loop" >&6; }
26217
26218 cat >>confdefs.h <<_ACEOF
26219 #define TYPEOF_IP_MULTICAST_LOOP $ntp_cv_typeof_ip_multicast_loop
26220 _ACEOF
26221
26222 esac
26223
26224 # Check whether --enable-getifaddrs was given.
26225 if test "${enable_getifaddrs+set}" = set; then :
26226   enableval=$enable_getifaddrs; want_getifaddrs="$enableval"
26227 else
26228   want_getifaddrs="yes"
26229
26230 fi
26231
26232
26233 case $want_getifaddrs in
26234  glibc)
26235     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --enable-getifaddrs=glibc is no longer required" >&5
26236 $as_echo "$as_me: WARNING: --enable-getifaddrs=glibc is no longer required" >&2;}
26237 esac
26238 case $want_getifaddrs in
26239  no)
26240     ;;
26241  *)
26242     SAVED_LIBS="$LIBS"
26243     LIBS="$LDADD_LIBNTP $LIBS"
26244     for ac_func in getifaddrs
26245 do :
26246   ac_fn_c_check_func "$LINENO" "getifaddrs" "ac_cv_func_getifaddrs"
26247 if test "x$ac_cv_func_getifaddrs" = xyes; then :
26248   cat >>confdefs.h <<_ACEOF
26249 #define HAVE_GETIFADDRS 1
26250 _ACEOF
26251
26252 fi
26253 done
26254
26255     LIBS="$SAVED_LIBS"
26256     { SAVED_LIBS=; unset SAVED_LIBS;}
26257     ;;
26258 esac
26259
26260 #
26261 # Check for if_nametoindex() for IPv6 scoped addresses support
26262 #
26263 case "$host" in
26264  *-hp-hpux*)
26265     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing if_nametoindex" >&5
26266 $as_echo_n "checking for library containing if_nametoindex... " >&6; }
26267 if ${ac_cv_search_if_nametoindex+:} false; then :
26268   $as_echo_n "(cached) " >&6
26269 else
26270   ac_func_search_save_LIBS=$LIBS
26271 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26272 /* end confdefs.h.  */
26273
26274 /* Override any GCC internal prototype to avoid an error.
26275    Use char because int might match the return type of a GCC
26276    builtin and then its argument prototype would still apply.  */
26277 #ifdef __cplusplus
26278 extern "C"
26279 #endif
26280 char if_nametoindex ();
26281 int
26282 main ()
26283 {
26284 return if_nametoindex ();
26285   ;
26286   return 0;
26287 }
26288 _ACEOF
26289 for ac_lib in '' ipv6; do
26290   if test -z "$ac_lib"; then
26291     ac_res="none required"
26292   else
26293     ac_res=-l$ac_lib
26294     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
26295   fi
26296   if ac_fn_c_try_link "$LINENO"; then :
26297   ac_cv_search_if_nametoindex=$ac_res
26298 fi
26299 rm -f core conftest.err conftest.$ac_objext \
26300     conftest$ac_exeext
26301   if ${ac_cv_search_if_nametoindex+:} false; then :
26302   break
26303 fi
26304 done
26305 if ${ac_cv_search_if_nametoindex+:} false; then :
26306
26307 else
26308   ac_cv_search_if_nametoindex=no
26309 fi
26310 rm conftest.$ac_ext
26311 LIBS=$ac_func_search_save_LIBS
26312 fi
26313 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_if_nametoindex" >&5
26314 $as_echo "$ac_cv_search_if_nametoindex" >&6; }
26315 ac_res=$ac_cv_search_if_nametoindex
26316 if test "$ac_res" != no; then :
26317   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
26318
26319 fi
26320
26321 esac
26322 SAVED_LIBS="$LIBS"
26323 LIBS="$LDADD_LIBNTP $LIBS"
26324 for ac_func in if_nametoindex
26325 do :
26326   ac_fn_c_check_func "$LINENO" "if_nametoindex" "ac_cv_func_if_nametoindex"
26327 if test "x$ac_cv_func_if_nametoindex" = xyes; then :
26328   cat >>confdefs.h <<_ACEOF
26329 #define HAVE_IF_NAMETOINDEX 1
26330 _ACEOF
26331
26332 fi
26333 done
26334
26335 LIBS="$SAVED_LIBS"
26336 { SAVED_LIBS=; unset SAVED_LIBS;}
26337 case "$ac_cv_func_if_nametoindex" in
26338  yes)
26339
26340 $as_echo "#define ISC_PLATFORM_HAVEIFNAMETOINDEX 1" >>confdefs.h
26341
26342 esac
26343
26344
26345
26346 ###
26347
26348 # Hacks
26349 # these need work if we're to move libntp under sntp
26350
26351 $as_echo "#define HAVE_NO_NICE 1" >>confdefs.h
26352
26353
26354 $as_echo "#define HAVE_TERMIOS 1" >>confdefs.h
26355
26356
26357 # Checks for library functions.
26358 for ac_func in socket
26359 do :
26360   ac_fn_c_check_func "$LINENO" "socket" "ac_cv_func_socket"
26361 if test "x$ac_cv_func_socket" = xyes; then :
26362   cat >>confdefs.h <<_ACEOF
26363 #define HAVE_SOCKET 1
26364 _ACEOF
26365
26366 fi
26367 done
26368
26369
26370 # HMS: if we don't find c++ we should not look for gtest.
26371 ac_ext=cpp
26372 ac_cpp='$CXXCPP $CPPFLAGS'
26373 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
26374 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
26375 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
26376 if test -z "$CXX"; then
26377   if test -n "$CCC"; then
26378     CXX=$CCC
26379   else
26380     if test -n "$ac_tool_prefix"; then
26381   for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
26382   do
26383     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
26384 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
26385 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
26386 $as_echo_n "checking for $ac_word... " >&6; }
26387 if ${ac_cv_prog_CXX+:} false; then :
26388   $as_echo_n "(cached) " >&6
26389 else
26390   if test -n "$CXX"; then
26391   ac_cv_prog_CXX="$CXX" # Let the user override the test.
26392 else
26393 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26394 for as_dir in $PATH
26395 do
26396   IFS=$as_save_IFS
26397   test -z "$as_dir" && as_dir=.
26398     for ac_exec_ext in '' $ac_executable_extensions; do
26399   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
26400     ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
26401     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
26402     break 2
26403   fi
26404 done
26405   done
26406 IFS=$as_save_IFS
26407
26408 fi
26409 fi
26410 CXX=$ac_cv_prog_CXX
26411 if test -n "$CXX"; then
26412   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
26413 $as_echo "$CXX" >&6; }
26414 else
26415   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26416 $as_echo "no" >&6; }
26417 fi
26418
26419
26420     test -n "$CXX" && break
26421   done
26422 fi
26423 if test -z "$CXX"; then
26424   ac_ct_CXX=$CXX
26425   for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
26426 do
26427   # Extract the first word of "$ac_prog", so it can be a program name with args.
26428 set dummy $ac_prog; ac_word=$2
26429 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
26430 $as_echo_n "checking for $ac_word... " >&6; }
26431 if ${ac_cv_prog_ac_ct_CXX+:} false; then :
26432   $as_echo_n "(cached) " >&6
26433 else
26434   if test -n "$ac_ct_CXX"; then
26435   ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
26436 else
26437 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
26438 for as_dir in $PATH
26439 do
26440   IFS=$as_save_IFS
26441   test -z "$as_dir" && as_dir=.
26442     for ac_exec_ext in '' $ac_executable_extensions; do
26443   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
26444     ac_cv_prog_ac_ct_CXX="$ac_prog"
26445     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
26446     break 2
26447   fi
26448 done
26449   done
26450 IFS=$as_save_IFS
26451
26452 fi
26453 fi
26454 ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
26455 if test -n "$ac_ct_CXX"; then
26456   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
26457 $as_echo "$ac_ct_CXX" >&6; }
26458 else
26459   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
26460 $as_echo "no" >&6; }
26461 fi
26462
26463
26464   test -n "$ac_ct_CXX" && break
26465 done
26466
26467   if test "x$ac_ct_CXX" = x; then
26468     CXX="g++"
26469   else
26470     case $cross_compiling:$ac_tool_warned in
26471 yes:)
26472 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
26473 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
26474 ac_tool_warned=yes ;;
26475 esac
26476     CXX=$ac_ct_CXX
26477   fi
26478 fi
26479
26480   fi
26481 fi
26482 # Provide some information about the compiler.
26483 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
26484 set X $ac_compile
26485 ac_compiler=$2
26486 for ac_option in --version -v -V -qversion; do
26487   { { ac_try="$ac_compiler $ac_option >&5"
26488 case "(($ac_try" in
26489   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26490   *) ac_try_echo=$ac_try;;
26491 esac
26492 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
26493 $as_echo "$ac_try_echo"; } >&5
26494   (eval "$ac_compiler $ac_option >&5") 2>conftest.err
26495   ac_status=$?
26496   if test -s conftest.err; then
26497     sed '10a\
26498 ... rest of stderr output deleted ...
26499          10q' conftest.err >conftest.er1
26500     cat conftest.er1 >&5
26501   fi
26502   rm -f conftest.er1 conftest.err
26503   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
26504   test $ac_status = 0; }
26505 done
26506
26507 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5
26508 $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
26509 if ${ac_cv_cxx_compiler_gnu+:} false; then :
26510   $as_echo_n "(cached) " >&6
26511 else
26512   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26513 /* end confdefs.h.  */
26514
26515 int
26516 main ()
26517 {
26518 #ifndef __GNUC__
26519        choke me
26520 #endif
26521
26522   ;
26523   return 0;
26524 }
26525 _ACEOF
26526 if ac_fn_cxx_try_compile "$LINENO"; then :
26527   ac_compiler_gnu=yes
26528 else
26529   ac_compiler_gnu=no
26530 fi
26531 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26532 ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
26533
26534 fi
26535 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
26536 $as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
26537 if test $ac_compiler_gnu = yes; then
26538   GXX=yes
26539 else
26540   GXX=
26541 fi
26542 ac_test_CXXFLAGS=${CXXFLAGS+set}
26543 ac_save_CXXFLAGS=$CXXFLAGS
26544 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
26545 $as_echo_n "checking whether $CXX accepts -g... " >&6; }
26546 if ${ac_cv_prog_cxx_g+:} false; then :
26547   $as_echo_n "(cached) " >&6
26548 else
26549   ac_save_cxx_werror_flag=$ac_cxx_werror_flag
26550    ac_cxx_werror_flag=yes
26551    ac_cv_prog_cxx_g=no
26552    CXXFLAGS="-g"
26553    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26554 /* end confdefs.h.  */
26555
26556 int
26557 main ()
26558 {
26559
26560   ;
26561   return 0;
26562 }
26563 _ACEOF
26564 if ac_fn_cxx_try_compile "$LINENO"; then :
26565   ac_cv_prog_cxx_g=yes
26566 else
26567   CXXFLAGS=""
26568       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26569 /* end confdefs.h.  */
26570
26571 int
26572 main ()
26573 {
26574
26575   ;
26576   return 0;
26577 }
26578 _ACEOF
26579 if ac_fn_cxx_try_compile "$LINENO"; then :
26580
26581 else
26582   ac_cxx_werror_flag=$ac_save_cxx_werror_flag
26583          CXXFLAGS="-g"
26584          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26585 /* end confdefs.h.  */
26586
26587 int
26588 main ()
26589 {
26590
26591   ;
26592   return 0;
26593 }
26594 _ACEOF
26595 if ac_fn_cxx_try_compile "$LINENO"; then :
26596   ac_cv_prog_cxx_g=yes
26597 fi
26598 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26599 fi
26600 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26601 fi
26602 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26603    ac_cxx_werror_flag=$ac_save_cxx_werror_flag
26604 fi
26605 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
26606 $as_echo "$ac_cv_prog_cxx_g" >&6; }
26607 if test "$ac_test_CXXFLAGS" = set; then
26608   CXXFLAGS=$ac_save_CXXFLAGS
26609 elif test $ac_cv_prog_cxx_g = yes; then
26610   if test "$GXX" = yes; then
26611     CXXFLAGS="-g -O2"
26612   else
26613     CXXFLAGS="-g"
26614   fi
26615 else
26616   if test "$GXX" = yes; then
26617     CXXFLAGS="-O2"
26618   else
26619     CXXFLAGS=
26620   fi
26621 fi
26622 ac_ext=c
26623 ac_cpp='$CPP $CPPFLAGS'
26624 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
26625 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
26626 ac_compiler_gnu=$ac_cv_c_compiler_gnu
26627
26628 depcc="$CXX"  am_compiler_list=
26629
26630 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
26631 $as_echo_n "checking dependency style of $depcc... " >&6; }
26632 if ${am_cv_CXX_dependencies_compiler_type+:} false; then :
26633   $as_echo_n "(cached) " >&6
26634 else
26635   if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
26636   # We make a subdir and do the tests there.  Otherwise we can end up
26637   # making bogus files that we don't know about and never remove.  For
26638   # instance it was reported that on HP-UX the gcc test will end up
26639   # making a dummy file named `D' -- because `-MD' means `put the output
26640   # in D'.
26641   mkdir conftest.dir
26642   # Copy depcomp to subdir because otherwise we won't find it if we're
26643   # using a relative directory.
26644   cp "$am_depcomp" conftest.dir
26645   cd conftest.dir
26646   # We will build objects and dependencies in a subdirectory because
26647   # it helps to detect inapplicable dependency modes.  For instance
26648   # both Tru64's cc and ICC support -MD to output dependencies as a
26649   # side effect of compilation, but ICC will put the dependencies in
26650   # the current directory while Tru64 will put them in the object
26651   # directory.
26652   mkdir sub
26653
26654   am_cv_CXX_dependencies_compiler_type=none
26655   if test "$am_compiler_list" = ""; then
26656      am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
26657   fi
26658   am__universal=false
26659   case " $depcc " in #(
26660      *\ -arch\ *\ -arch\ *) am__universal=true ;;
26661      esac
26662
26663   for depmode in $am_compiler_list; do
26664     # Setup a source with many dependencies, because some compilers
26665     # like to wrap large dependency lists on column 80 (with \), and
26666     # we should not choose a depcomp mode which is confused by this.
26667     #
26668     # We need to recreate these files for each test, as the compiler may
26669     # overwrite some of them when testing with obscure command lines.
26670     # This happens at least with the AIX C compiler.
26671     : > sub/conftest.c
26672     for i in 1 2 3 4 5 6; do
26673       echo '#include "conftst'$i'.h"' >> sub/conftest.c
26674       # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
26675       # Solaris 8's {/usr,}/bin/sh.
26676       touch sub/conftst$i.h
26677     done
26678     echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
26679
26680     # We check with `-c' and `-o' for the sake of the "dashmstdout"
26681     # mode.  It turns out that the SunPro C++ compiler does not properly
26682     # handle `-M -o', and we need to detect this.  Also, some Intel
26683     # versions had trouble with output in subdirs
26684     am__obj=sub/conftest.${OBJEXT-o}
26685     am__minus_obj="-o $am__obj"
26686     case $depmode in
26687     gcc)
26688       # This depmode causes a compiler race in universal mode.
26689       test "$am__universal" = false || continue
26690       ;;
26691     nosideeffect)
26692       # after this tag, mechanisms are not by side-effect, so they'll
26693       # only be used when explicitly requested
26694       if test "x$enable_dependency_tracking" = xyes; then
26695         continue
26696       else
26697         break
26698       fi
26699       ;;
26700     msvisualcpp | msvcmsys)
26701       # This compiler won't grok `-c -o', but also, the minuso test has
26702       # not run yet.  These depmodes are late enough in the game, and
26703       # so weak that their functioning should not be impacted.
26704       am__obj=conftest.${OBJEXT-o}
26705       am__minus_obj=
26706       ;;
26707     none) break ;;
26708     esac
26709     if depmode=$depmode \
26710        source=sub/conftest.c object=$am__obj \
26711        depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
26712        $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
26713          >/dev/null 2>conftest.err &&
26714        grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
26715        grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
26716        grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
26717        ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
26718       # icc doesn't choke on unknown options, it will just issue warnings
26719       # or remarks (even with -Werror).  So we grep stderr for any message
26720       # that says an option was ignored or not supported.
26721       # When given -MP, icc 7.0 and 7.1 complain thusly:
26722       #   icc: Command line warning: ignoring option '-M'; no argument required
26723       # The diagnosis changed in icc 8.0:
26724       #   icc: Command line remark: option '-MP' not supported
26725       if (grep 'ignoring option' conftest.err ||
26726           grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
26727         am_cv_CXX_dependencies_compiler_type=$depmode
26728         break
26729       fi
26730     fi
26731   done
26732
26733   cd ..
26734   rm -rf conftest.dir
26735 else
26736   am_cv_CXX_dependencies_compiler_type=none
26737 fi
26738
26739 fi
26740 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CXX_dependencies_compiler_type" >&5
26741 $as_echo "$am_cv_CXX_dependencies_compiler_type" >&6; }
26742 CXXDEPMODE=depmode=$am_cv_CXX_dependencies_compiler_type
26743
26744  if
26745   test "x$enable_dependency_tracking" != xno \
26746   && test "$am_cv_CXX_dependencies_compiler_type" = gcc3; then
26747   am__fastdepCXX_TRUE=
26748   am__fastdepCXX_FALSE='#'
26749 else
26750   am__fastdepCXX_TRUE='#'
26751   am__fastdepCXX_FALSE=
26752 fi
26753
26754
26755
26756
26757 func_stripname_cnf ()
26758 {
26759   case ${2} in
26760   .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
26761   *)  func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
26762   esac
26763 } # func_stripname_cnf
26764
26765       if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
26766     ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
26767     (test "X$CXX" != "Xg++"))) ; then
26768   ac_ext=cpp
26769 ac_cpp='$CXXCPP $CPPFLAGS'
26770 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
26771 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
26772 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
26773 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5
26774 $as_echo_n "checking how to run the C++ preprocessor... " >&6; }
26775 if test -z "$CXXCPP"; then
26776   if ${ac_cv_prog_CXXCPP+:} false; then :
26777   $as_echo_n "(cached) " >&6
26778 else
26779       # Double quotes because CXXCPP needs to be expanded
26780     for CXXCPP in "$CXX -E" "/lib/cpp"
26781     do
26782       ac_preproc_ok=false
26783 for ac_cxx_preproc_warn_flag in '' yes
26784 do
26785   # Use a header file that comes with gcc, so configuring glibc
26786   # with a fresh cross-compiler works.
26787   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
26788   # <limits.h> exists even on freestanding compilers.
26789   # On the NeXT, cc -E runs the code through the compiler's parser,
26790   # not just through cpp. "Syntax error" is here to catch this case.
26791   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26792 /* end confdefs.h.  */
26793 #ifdef __STDC__
26794 # include <limits.h>
26795 #else
26796 # include <assert.h>
26797 #endif
26798                      Syntax error
26799 _ACEOF
26800 if ac_fn_cxx_try_cpp "$LINENO"; then :
26801
26802 else
26803   # Broken: fails on valid input.
26804 continue
26805 fi
26806 rm -f conftest.err conftest.i conftest.$ac_ext
26807
26808   # OK, works on sane cases.  Now check whether nonexistent headers
26809   # can be detected and how.
26810   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26811 /* end confdefs.h.  */
26812 #include <ac_nonexistent.h>
26813 _ACEOF
26814 if ac_fn_cxx_try_cpp "$LINENO"; then :
26815   # Broken: success on invalid input.
26816 continue
26817 else
26818   # Passes both tests.
26819 ac_preproc_ok=:
26820 break
26821 fi
26822 rm -f conftest.err conftest.i conftest.$ac_ext
26823
26824 done
26825 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
26826 rm -f conftest.i conftest.err conftest.$ac_ext
26827 if $ac_preproc_ok; then :
26828   break
26829 fi
26830
26831     done
26832     ac_cv_prog_CXXCPP=$CXXCPP
26833
26834 fi
26835   CXXCPP=$ac_cv_prog_CXXCPP
26836 else
26837   ac_cv_prog_CXXCPP=$CXXCPP
26838 fi
26839 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5
26840 $as_echo "$CXXCPP" >&6; }
26841 ac_preproc_ok=false
26842 for ac_cxx_preproc_warn_flag in '' yes
26843 do
26844   # Use a header file that comes with gcc, so configuring glibc
26845   # with a fresh cross-compiler works.
26846   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
26847   # <limits.h> exists even on freestanding compilers.
26848   # On the NeXT, cc -E runs the code through the compiler's parser,
26849   # not just through cpp. "Syntax error" is here to catch this case.
26850   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26851 /* end confdefs.h.  */
26852 #ifdef __STDC__
26853 # include <limits.h>
26854 #else
26855 # include <assert.h>
26856 #endif
26857                      Syntax error
26858 _ACEOF
26859 if ac_fn_cxx_try_cpp "$LINENO"; then :
26860
26861 else
26862   # Broken: fails on valid input.
26863 continue
26864 fi
26865 rm -f conftest.err conftest.i conftest.$ac_ext
26866
26867   # OK, works on sane cases.  Now check whether nonexistent headers
26868   # can be detected and how.
26869   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26870 /* end confdefs.h.  */
26871 #include <ac_nonexistent.h>
26872 _ACEOF
26873 if ac_fn_cxx_try_cpp "$LINENO"; then :
26874   # Broken: success on invalid input.
26875 continue
26876 else
26877   # Passes both tests.
26878 ac_preproc_ok=:
26879 break
26880 fi
26881 rm -f conftest.err conftest.i conftest.$ac_ext
26882
26883 done
26884 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
26885 rm -f conftest.i conftest.err conftest.$ac_ext
26886 if $ac_preproc_ok; then :
26887
26888 else
26889   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
26890 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26891 as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check
26892 See \`config.log' for more details" "$LINENO" 5; }
26893 fi
26894
26895 ac_ext=c
26896 ac_cpp='$CPP $CPPFLAGS'
26897 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
26898 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
26899 ac_compiler_gnu=$ac_cv_c_compiler_gnu
26900
26901 else
26902   _lt_caught_CXX_error=yes
26903 fi
26904
26905 ac_ext=cpp
26906 ac_cpp='$CXXCPP $CPPFLAGS'
26907 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
26908 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
26909 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
26910
26911 archive_cmds_need_lc_CXX=no
26912 allow_undefined_flag_CXX=
26913 always_export_symbols_CXX=no
26914 archive_expsym_cmds_CXX=
26915 compiler_needs_object_CXX=no
26916 export_dynamic_flag_spec_CXX=
26917 hardcode_direct_CXX=no
26918 hardcode_direct_absolute_CXX=no
26919 hardcode_libdir_flag_spec_CXX=
26920 hardcode_libdir_flag_spec_ld_CXX=
26921 hardcode_libdir_separator_CXX=
26922 hardcode_minus_L_CXX=no
26923 hardcode_shlibpath_var_CXX=unsupported
26924 hardcode_automatic_CXX=no
26925 inherit_rpath_CXX=no
26926 module_cmds_CXX=
26927 module_expsym_cmds_CXX=
26928 link_all_deplibs_CXX=unknown
26929 old_archive_cmds_CXX=$old_archive_cmds
26930 reload_flag_CXX=$reload_flag
26931 reload_cmds_CXX=$reload_cmds
26932 no_undefined_flag_CXX=
26933 whole_archive_flag_spec_CXX=
26934 enable_shared_with_static_runtimes_CXX=no
26935
26936 # Source file extension for C++ test sources.
26937 ac_ext=cpp
26938
26939 # Object file extension for compiled C++ test sources.
26940 objext=o
26941 objext_CXX=$objext
26942
26943 # No sense in running all these tests if we already determined that
26944 # the CXX compiler isn't working.  Some variables (like enable_shared)
26945 # are currently assumed to apply to all compilers on this platform,
26946 # and will be corrupted by setting them based on a non-working compiler.
26947 if test "$_lt_caught_CXX_error" != yes; then
26948   # Code to be used in simple compile tests
26949   lt_simple_compile_test_code="int some_variable = 0;"
26950
26951   # Code to be used in simple link tests
26952   lt_simple_link_test_code='int main(int, char *[]) { return(0); }'
26953
26954   # ltmain only uses $CC for tagged configurations so make sure $CC is set.
26955
26956
26957
26958
26959
26960
26961 # If no C compiler was specified, use CC.
26962 LTCC=${LTCC-"$CC"}
26963
26964 # If no C compiler flags were specified, use CFLAGS.
26965 LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
26966
26967 # Allow CC to be a program name with arguments.
26968 compiler=$CC
26969
26970
26971   # save warnings/boilerplate of simple test code
26972   ac_outfile=conftest.$ac_objext
26973 echo "$lt_simple_compile_test_code" >conftest.$ac_ext
26974 eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
26975 _lt_compiler_boilerplate=`cat conftest.err`
26976 $RM conftest*
26977
26978   ac_outfile=conftest.$ac_objext
26979 echo "$lt_simple_link_test_code" >conftest.$ac_ext
26980 eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
26981 _lt_linker_boilerplate=`cat conftest.err`
26982 $RM -r conftest*
26983
26984
26985   # Allow CC to be a program name with arguments.
26986   lt_save_CC=$CC
26987   lt_save_CFLAGS=$CFLAGS
26988   lt_save_LD=$LD
26989   lt_save_GCC=$GCC
26990   GCC=$GXX
26991   lt_save_with_gnu_ld=$with_gnu_ld
26992   lt_save_path_LD=$lt_cv_path_LD
26993   if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
26994     lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
26995   else
26996     $as_unset lt_cv_prog_gnu_ld
26997   fi
26998   if test -n "${lt_cv_path_LDCXX+set}"; then
26999     lt_cv_path_LD=$lt_cv_path_LDCXX
27000   else
27001     $as_unset lt_cv_path_LD
27002   fi
27003   test -z "${LDCXX+set}" || LD=$LDCXX
27004   CC=${CXX-"c++"}
27005   CFLAGS=$CXXFLAGS
27006   compiler=$CC
27007   compiler_CXX=$CC
27008   for cc_temp in $compiler""; do
27009   case $cc_temp in
27010     compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
27011     distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
27012     \-*) ;;
27013     *) break;;
27014   esac
27015 done
27016 cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
27017
27018
27019   if test -n "$compiler"; then
27020     # We don't want -fno-exception when compiling C++ code, so set the
27021     # no_builtin_flag separately
27022     if test "$GXX" = yes; then
27023       lt_prog_compiler_no_builtin_flag_CXX=' -fno-builtin'
27024     else
27025       lt_prog_compiler_no_builtin_flag_CXX=
27026     fi
27027
27028     if test "$GXX" = yes; then
27029       # Set up default GNU C++ configuration
27030
27031
27032
27033 # Check whether --with-gnu-ld was given.
27034 if test "${with_gnu_ld+set}" = set; then :
27035   withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
27036 else
27037   with_gnu_ld=no
27038 fi
27039
27040 ac_prog=ld
27041 if test "$GCC" = yes; then
27042   # Check if gcc -print-prog-name=ld gives a path.
27043   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
27044 $as_echo_n "checking for ld used by $CC... " >&6; }
27045   case $host in
27046   *-*-mingw*)
27047     # gcc leaves a trailing carriage return which upsets mingw
27048     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
27049   *)
27050     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
27051   esac
27052   case $ac_prog in
27053     # Accept absolute paths.
27054     [\\/]* | ?:[\\/]*)
27055       re_direlt='/[^/][^/]*/\.\./'
27056       # Canonicalize the pathname of ld
27057       ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
27058       while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
27059         ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
27060       done
27061       test -z "$LD" && LD="$ac_prog"
27062       ;;
27063   "")
27064     # If it fails, then pretend we aren't using GCC.
27065     ac_prog=ld
27066     ;;
27067   *)
27068     # If it is relative, then search for the first ld in PATH.
27069     with_gnu_ld=unknown
27070     ;;
27071   esac
27072 elif test "$with_gnu_ld" = yes; then
27073   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
27074 $as_echo_n "checking for GNU ld... " >&6; }
27075 else
27076   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
27077 $as_echo_n "checking for non-GNU ld... " >&6; }
27078 fi
27079 if ${lt_cv_path_LD+:} false; then :
27080   $as_echo_n "(cached) " >&6
27081 else
27082   if test -z "$LD"; then
27083   lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
27084   for ac_dir in $PATH; do
27085     IFS="$lt_save_ifs"
27086     test -z "$ac_dir" && ac_dir=.
27087     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
27088       lt_cv_path_LD="$ac_dir/$ac_prog"
27089       # Check to see if the program is GNU ld.  I'd rather use --version,
27090       # but apparently some variants of GNU ld only accept -v.
27091       # Break only if it was the GNU/non-GNU ld that we prefer.
27092       case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
27093       *GNU* | *'with BFD'*)
27094         test "$with_gnu_ld" != no && break
27095         ;;
27096       *)
27097         test "$with_gnu_ld" != yes && break
27098         ;;
27099       esac
27100     fi
27101   done
27102   IFS="$lt_save_ifs"
27103 else
27104   lt_cv_path_LD="$LD" # Let the user override the test with a path.
27105 fi
27106 fi
27107
27108 LD="$lt_cv_path_LD"
27109 if test -n "$LD"; then
27110   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
27111 $as_echo "$LD" >&6; }
27112 else
27113   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27114 $as_echo "no" >&6; }
27115 fi
27116 test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
27117 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
27118 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
27119 if ${lt_cv_prog_gnu_ld+:} false; then :
27120   $as_echo_n "(cached) " >&6
27121 else
27122   # I'd rather use --version here, but apparently some GNU lds only accept -v.
27123 case `$LD -v 2>&1 </dev/null` in
27124 *GNU* | *'with BFD'*)
27125   lt_cv_prog_gnu_ld=yes
27126   ;;
27127 *)
27128   lt_cv_prog_gnu_ld=no
27129   ;;
27130 esac
27131 fi
27132 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
27133 $as_echo "$lt_cv_prog_gnu_ld" >&6; }
27134 with_gnu_ld=$lt_cv_prog_gnu_ld
27135
27136
27137
27138
27139
27140
27141
27142       # Check if GNU C++ uses GNU ld as the underlying linker, since the
27143       # archiving commands below assume that GNU ld is being used.
27144       if test "$with_gnu_ld" = yes; then
27145         archive_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
27146         archive_expsym_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
27147
27148         hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
27149         export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
27150
27151         # If archive_cmds runs LD, not CC, wlarc should be empty
27152         # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
27153         #     investigate it a little bit more. (MM)
27154         wlarc='${wl}'
27155
27156         # ancient GNU ld didn't support --whole-archive et. al.
27157         if eval "`$CC -print-prog-name=ld` --help 2>&1" |
27158           $GREP 'no-whole-archive' > /dev/null; then
27159           whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
27160         else
27161           whole_archive_flag_spec_CXX=
27162         fi
27163       else
27164         with_gnu_ld=no
27165         wlarc=
27166
27167         # A generic and very simple default shared library creation
27168         # command for GNU C++ for the case where it uses the native
27169         # linker, instead of GNU ld.  If possible, this setting should
27170         # overridden to take advantage of the native linker features on
27171         # the platform it is being used on.
27172         archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
27173       fi
27174
27175       # Commands to make compiler produce verbose output that lists
27176       # what "hidden" libraries, object files and flags are used when
27177       # linking a shared library.
27178       output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
27179
27180     else
27181       GXX=no
27182       with_gnu_ld=no
27183       wlarc=
27184     fi
27185
27186     # PORTME: fill in a description of your system's C++ link characteristics
27187     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
27188 $as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
27189     ld_shlibs_CXX=yes
27190     case $host_os in
27191       aix3*)
27192         # FIXME: insert proper C++ library support
27193         ld_shlibs_CXX=no
27194         ;;
27195       aix[4-9]*)
27196         if test "$host_cpu" = ia64; then
27197           # On IA64, the linker does run time linking by default, so we don't
27198           # have to do anything special.
27199           aix_use_runtimelinking=no
27200           exp_sym_flag='-Bexport'
27201           no_entry_flag=""
27202         else
27203           aix_use_runtimelinking=no
27204
27205           # Test if we are trying to use run time linking or normal
27206           # AIX style linking. If -brtl is somewhere in LDFLAGS, we
27207           # need to do runtime linking.
27208           case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
27209             for ld_flag in $LDFLAGS; do
27210               case $ld_flag in
27211               *-brtl*)
27212                 aix_use_runtimelinking=yes
27213                 break
27214                 ;;
27215               esac
27216             done
27217             ;;
27218           esac
27219
27220           exp_sym_flag='-bexport'
27221           no_entry_flag='-bnoentry'
27222         fi
27223
27224         # When large executables or shared objects are built, AIX ld can
27225         # have problems creating the table of contents.  If linking a library
27226         # or program results in "error TOC overflow" add -mminimal-toc to
27227         # CXXFLAGS/CFLAGS for g++/gcc.  In the cases where that is not
27228         # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
27229
27230         archive_cmds_CXX=''
27231         hardcode_direct_CXX=yes
27232         hardcode_direct_absolute_CXX=yes
27233         hardcode_libdir_separator_CXX=':'
27234         link_all_deplibs_CXX=yes
27235         file_list_spec_CXX='${wl}-f,'
27236
27237         if test "$GXX" = yes; then
27238           case $host_os in aix4.[012]|aix4.[012].*)
27239           # We only want to do this on AIX 4.2 and lower, the check
27240           # below for broken collect2 doesn't work under 4.3+
27241           collect2name=`${CC} -print-prog-name=collect2`
27242           if test -f "$collect2name" &&
27243              strings "$collect2name" | $GREP resolve_lib_name >/dev/null
27244           then
27245             # We have reworked collect2
27246             :
27247           else
27248             # We have old collect2
27249             hardcode_direct_CXX=unsupported
27250             # It fails to find uninstalled libraries when the uninstalled
27251             # path is not listed in the libpath.  Setting hardcode_minus_L
27252             # to unsupported forces relinking
27253             hardcode_minus_L_CXX=yes
27254             hardcode_libdir_flag_spec_CXX='-L$libdir'
27255             hardcode_libdir_separator_CXX=
27256           fi
27257           esac
27258           shared_flag='-shared'
27259           if test "$aix_use_runtimelinking" = yes; then
27260             shared_flag="$shared_flag "'${wl}-G'
27261           fi
27262         else
27263           # not using gcc
27264           if test "$host_cpu" = ia64; then
27265           # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
27266           # chokes on -Wl,-G. The following line is correct:
27267           shared_flag='-G'
27268           else
27269             if test "$aix_use_runtimelinking" = yes; then
27270               shared_flag='${wl}-G'
27271             else
27272               shared_flag='${wl}-bM:SRE'
27273             fi
27274           fi
27275         fi
27276
27277         export_dynamic_flag_spec_CXX='${wl}-bexpall'
27278         # It seems that -bexpall does not export symbols beginning with
27279         # underscore (_), so it is better to generate a list of symbols to
27280         # export.
27281         always_export_symbols_CXX=yes
27282         if test "$aix_use_runtimelinking" = yes; then
27283           # Warning - without using the other runtime loading flags (-brtl),
27284           # -berok will link without error, but may produce a broken library.
27285           allow_undefined_flag_CXX='-berok'
27286           # Determine the default libpath from the value encoded in an empty
27287           # executable.
27288           if test "${lt_cv_aix_libpath+set}" = set; then
27289   aix_libpath=$lt_cv_aix_libpath
27290 else
27291   if ${lt_cv_aix_libpath__CXX+:} false; then :
27292   $as_echo_n "(cached) " >&6
27293 else
27294   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27295 /* end confdefs.h.  */
27296
27297 int
27298 main ()
27299 {
27300
27301   ;
27302   return 0;
27303 }
27304 _ACEOF
27305 if ac_fn_cxx_try_link "$LINENO"; then :
27306
27307   lt_aix_libpath_sed='
27308       /Import File Strings/,/^$/ {
27309           /^0/ {
27310               s/^0  *\([^ ]*\) *$/\1/
27311               p
27312           }
27313       }'
27314   lt_cv_aix_libpath__CXX=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
27315   # Check for a 64-bit object if we didn't find anything.
27316   if test -z "$lt_cv_aix_libpath__CXX"; then
27317     lt_cv_aix_libpath__CXX=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
27318   fi
27319 fi
27320 rm -f core conftest.err conftest.$ac_objext \
27321     conftest$ac_exeext conftest.$ac_ext
27322   if test -z "$lt_cv_aix_libpath__CXX"; then
27323     lt_cv_aix_libpath__CXX="/usr/lib:/lib"
27324   fi
27325
27326 fi
27327
27328   aix_libpath=$lt_cv_aix_libpath__CXX
27329 fi
27330
27331           hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath"
27332
27333           archive_expsym_cmds_CXX='$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"
27334         else
27335           if test "$host_cpu" = ia64; then
27336             hardcode_libdir_flag_spec_CXX='${wl}-R $libdir:/usr/lib:/lib'
27337             allow_undefined_flag_CXX="-z nodefs"
27338             archive_expsym_cmds_CXX="\$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"
27339           else
27340             # Determine the default libpath from the value encoded in an
27341             # empty executable.
27342             if test "${lt_cv_aix_libpath+set}" = set; then
27343   aix_libpath=$lt_cv_aix_libpath
27344 else
27345   if ${lt_cv_aix_libpath__CXX+:} false; then :
27346   $as_echo_n "(cached) " >&6
27347 else
27348   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27349 /* end confdefs.h.  */
27350
27351 int
27352 main ()
27353 {
27354
27355   ;
27356   return 0;
27357 }
27358 _ACEOF
27359 if ac_fn_cxx_try_link "$LINENO"; then :
27360
27361   lt_aix_libpath_sed='
27362       /Import File Strings/,/^$/ {
27363           /^0/ {
27364               s/^0  *\([^ ]*\) *$/\1/
27365               p
27366           }
27367       }'
27368   lt_cv_aix_libpath__CXX=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
27369   # Check for a 64-bit object if we didn't find anything.
27370   if test -z "$lt_cv_aix_libpath__CXX"; then
27371     lt_cv_aix_libpath__CXX=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
27372   fi
27373 fi
27374 rm -f core conftest.err conftest.$ac_objext \
27375     conftest$ac_exeext conftest.$ac_ext
27376   if test -z "$lt_cv_aix_libpath__CXX"; then
27377     lt_cv_aix_libpath__CXX="/usr/lib:/lib"
27378   fi
27379
27380 fi
27381
27382   aix_libpath=$lt_cv_aix_libpath__CXX
27383 fi
27384
27385             hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath"
27386             # Warning - without using the other run time loading flags,
27387             # -berok will link without error, but may produce a broken library.
27388             no_undefined_flag_CXX=' ${wl}-bernotok'
27389             allow_undefined_flag_CXX=' ${wl}-berok'
27390             if test "$with_gnu_ld" = yes; then
27391               # We only use this code for GNU lds that support --whole-archive.
27392               whole_archive_flag_spec_CXX='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
27393             else
27394               # Exported symbols can be pulled into shared objects from archives
27395               whole_archive_flag_spec_CXX='$convenience'
27396             fi
27397             archive_cmds_need_lc_CXX=yes
27398             # This is similar to how AIX traditionally builds its shared
27399             # libraries.
27400             archive_expsym_cmds_CXX="\$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'
27401           fi
27402         fi
27403         ;;
27404
27405       beos*)
27406         if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
27407           allow_undefined_flag_CXX=unsupported
27408           # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
27409           # support --undefined.  This deserves some investigation.  FIXME
27410           archive_cmds_CXX='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
27411         else
27412           ld_shlibs_CXX=no
27413         fi
27414         ;;
27415
27416       chorus*)
27417         case $cc_basename in
27418           *)
27419           # FIXME: insert proper C++ library support
27420           ld_shlibs_CXX=no
27421           ;;
27422         esac
27423         ;;
27424
27425       cygwin* | mingw* | pw32* | cegcc*)
27426         case $GXX,$cc_basename in
27427         ,cl* | no,cl*)
27428           # Native MSVC
27429           # hardcode_libdir_flag_spec is actually meaningless, as there is
27430           # no search path for DLLs.
27431           hardcode_libdir_flag_spec_CXX=' '
27432           allow_undefined_flag_CXX=unsupported
27433           always_export_symbols_CXX=yes
27434           file_list_spec_CXX='@'
27435           # Tell ltmain to make .lib files, not .a files.
27436           libext=lib
27437           # Tell ltmain to make .dll files, not .so files.
27438           shrext_cmds=".dll"
27439           # FIXME: Setting linknames here is a bad hack.
27440           archive_cmds_CXX='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames='
27441           archive_expsym_cmds_CXX='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
27442               $SED -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp;
27443             else
27444               $SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp;
27445             fi~
27446             $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~
27447             linknames='
27448           # The linker will not automatically build a static lib if we build a DLL.
27449           # _LT_TAGVAR(old_archive_from_new_cmds, CXX)='true'
27450           enable_shared_with_static_runtimes_CXX=yes
27451           # Don't use ranlib
27452           old_postinstall_cmds_CXX='chmod 644 $oldlib'
27453           postlink_cmds_CXX='lt_outputfile="@OUTPUT@"~
27454             lt_tool_outputfile="@TOOL_OUTPUT@"~
27455             case $lt_outputfile in
27456               *.exe|*.EXE) ;;
27457               *)
27458                 lt_outputfile="$lt_outputfile.exe"
27459                 lt_tool_outputfile="$lt_tool_outputfile.exe"
27460                 ;;
27461             esac~
27462             func_to_tool_file "$lt_outputfile"~
27463             if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then
27464               $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1;
27465               $RM "$lt_outputfile.manifest";
27466             fi'
27467           ;;
27468         *)
27469           # g++
27470           # _LT_TAGVAR(hardcode_libdir_flag_spec, CXX) is actually meaningless,
27471           # as there is no search path for DLLs.
27472           hardcode_libdir_flag_spec_CXX='-L$libdir'
27473           export_dynamic_flag_spec_CXX='${wl}--export-all-symbols'
27474           allow_undefined_flag_CXX=unsupported
27475           always_export_symbols_CXX=no
27476           enable_shared_with_static_runtimes_CXX=yes
27477
27478           if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
27479             archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
27480             # If the export-symbols file already is a .def file (1st line
27481             # is EXPORTS), use it as is; otherwise, prepend...
27482             archive_expsym_cmds_CXX='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
27483               cp $export_symbols $output_objdir/$soname.def;
27484             else
27485               echo EXPORTS > $output_objdir/$soname.def;
27486               cat $export_symbols >> $output_objdir/$soname.def;
27487             fi~
27488             $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
27489           else
27490             ld_shlibs_CXX=no
27491           fi
27492           ;;
27493         esac
27494         ;;
27495       darwin* | rhapsody*)
27496
27497
27498   archive_cmds_need_lc_CXX=no
27499   hardcode_direct_CXX=no
27500   hardcode_automatic_CXX=yes
27501   hardcode_shlibpath_var_CXX=unsupported
27502   if test "$lt_cv_ld_force_load" = "yes"; then
27503     whole_archive_flag_spec_CXX='`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
27504   else
27505     whole_archive_flag_spec_CXX=''
27506   fi
27507   link_all_deplibs_CXX=yes
27508   allow_undefined_flag_CXX="$_lt_dar_allow_undefined"
27509   case $cc_basename in
27510      ifort*) _lt_dar_can_shared=yes ;;
27511      *) _lt_dar_can_shared=$GCC ;;
27512   esac
27513   if test "$_lt_dar_can_shared" = "yes"; then
27514     output_verbose_link_cmd=func_echo_all
27515     archive_cmds_CXX="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
27516     module_cmds_CXX="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
27517     archive_expsym_cmds_CXX="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}"
27518     module_expsym_cmds_CXX="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}"
27519        if test "$lt_cv_apple_cc_single_mod" != "yes"; then
27520       archive_cmds_CXX="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}"
27521       archive_expsym_cmds_CXX="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}"
27522     fi
27523
27524   else
27525   ld_shlibs_CXX=no
27526   fi
27527
27528         ;;
27529
27530       dgux*)
27531         case $cc_basename in
27532           ec++*)
27533             # FIXME: insert proper C++ library support
27534             ld_shlibs_CXX=no
27535             ;;
27536           ghcx*)
27537             # Green Hills C++ Compiler
27538             # FIXME: insert proper C++ library support
27539             ld_shlibs_CXX=no
27540             ;;
27541           *)
27542             # FIXME: insert proper C++ library support
27543             ld_shlibs_CXX=no
27544             ;;
27545         esac
27546         ;;
27547
27548       freebsd[12]*)
27549         # C++ shared libraries reported to be fairly broken before
27550         # switch to ELF
27551         ld_shlibs_CXX=no
27552         ;;
27553
27554       freebsd-elf*)
27555         archive_cmds_need_lc_CXX=no
27556         ;;
27557
27558       freebsd* | dragonfly*)
27559         # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
27560         # conventions
27561         ld_shlibs_CXX=yes
27562         ;;
27563
27564       gnu*)
27565         ;;
27566
27567       haiku*)
27568         archive_cmds_CXX='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
27569         link_all_deplibs_CXX=yes
27570         ;;
27571
27572       hpux9*)
27573         hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir'
27574         hardcode_libdir_separator_CXX=:
27575         export_dynamic_flag_spec_CXX='${wl}-E'
27576         hardcode_direct_CXX=yes
27577         hardcode_minus_L_CXX=yes # Not in the search PATH,
27578                                              # but as the default
27579                                              # location of the library.
27580
27581         case $cc_basename in
27582           CC*)
27583             # FIXME: insert proper C++ library support
27584             ld_shlibs_CXX=no
27585             ;;
27586           aCC*)
27587             archive_cmds_CXX='$RM $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
27588             # Commands to make compiler produce verbose output that lists
27589             # what "hidden" libraries, object files and flags are used when
27590             # linking a shared library.
27591             #
27592             # There doesn't appear to be a way to prevent this compiler from
27593             # explicitly linking system object files so we need to strip them
27594             # from the output so that they don't get included in the library
27595             # dependencies.
27596             output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
27597             ;;
27598           *)
27599             if test "$GXX" = yes; then
27600               archive_cmds_CXX='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
27601             else
27602               # FIXME: insert proper C++ library support
27603               ld_shlibs_CXX=no
27604             fi
27605             ;;
27606         esac
27607         ;;
27608
27609       hpux10*|hpux11*)
27610         if test $with_gnu_ld = no; then
27611           hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir'
27612           hardcode_libdir_separator_CXX=:
27613
27614           case $host_cpu in
27615             hppa*64*|ia64*)
27616               ;;
27617             *)
27618               export_dynamic_flag_spec_CXX='${wl}-E'
27619               ;;
27620           esac
27621         fi
27622         case $host_cpu in
27623           hppa*64*|ia64*)
27624             hardcode_direct_CXX=no
27625             hardcode_shlibpath_var_CXX=no
27626             ;;
27627           *)
27628             hardcode_direct_CXX=yes
27629             hardcode_direct_absolute_CXX=yes
27630             hardcode_minus_L_CXX=yes # Not in the search PATH,
27631                                                  # but as the default
27632                                                  # location of the library.
27633             ;;
27634         esac
27635
27636         case $cc_basename in
27637           CC*)
27638             # FIXME: insert proper C++ library support
27639             ld_shlibs_CXX=no
27640             ;;
27641           aCC*)
27642             case $host_cpu in
27643               hppa*64*)
27644                 archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
27645                 ;;
27646               ia64*)
27647                 archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
27648                 ;;
27649               *)
27650                 archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
27651                 ;;
27652             esac
27653             # Commands to make compiler produce verbose output that lists
27654             # what "hidden" libraries, object files and flags are used when
27655             # linking a shared library.
27656             #
27657             # There doesn't appear to be a way to prevent this compiler from
27658             # explicitly linking system object files so we need to strip them
27659             # from the output so that they don't get included in the library
27660             # dependencies.
27661             output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
27662             ;;
27663           *)
27664             if test "$GXX" = yes; then
27665               if test $with_gnu_ld = no; then
27666                 case $host_cpu in
27667                   hppa*64*)
27668                     archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
27669                     ;;
27670                   ia64*)
27671                     archive_cmds_CXX='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
27672                     ;;
27673                   *)
27674                     archive_cmds_CXX='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
27675                     ;;
27676                 esac
27677               fi
27678             else
27679               # FIXME: insert proper C++ library support
27680               ld_shlibs_CXX=no
27681             fi
27682             ;;
27683         esac
27684         ;;
27685
27686       interix[3-9]*)
27687         hardcode_direct_CXX=no
27688         hardcode_shlibpath_var_CXX=no
27689         hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
27690         export_dynamic_flag_spec_CXX='${wl}-E'
27691         # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
27692         # Instead, shared libraries are loaded at an image base (0x10000000 by
27693         # default) and relocated if they conflict, which is a slow very memory
27694         # consuming and fragmenting process.  To avoid this, we pick a random,
27695         # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
27696         # time.  Moving up from 0x10000000 also allows more sbrk(2) space.
27697         archive_cmds_CXX='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
27698         archive_expsym_cmds_CXX='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'
27699         ;;
27700       irix5* | irix6*)
27701         case $cc_basename in
27702           CC*)
27703             # SGI C++
27704             archive_cmds_CXX='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
27705
27706             # Archives containing C++ object files must be created using
27707             # "CC -ar", where "CC" is the IRIX C++ compiler.  This is
27708             # necessary to make sure instantiated templates are included
27709             # in the archive.
27710             old_archive_cmds_CXX='$CC -ar -WR,-u -o $oldlib $oldobjs'
27711             ;;
27712           *)
27713             if test "$GXX" = yes; then
27714               if test "$with_gnu_ld" = no; then
27715                 archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $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'
27716               else
27717                 archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib'
27718               fi
27719             fi
27720             link_all_deplibs_CXX=yes
27721             ;;
27722         esac
27723         hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
27724         hardcode_libdir_separator_CXX=:
27725         inherit_rpath_CXX=yes
27726         ;;
27727
27728       linux* | k*bsd*-gnu | kopensolaris*-gnu)
27729         case $cc_basename in
27730           KCC*)
27731             # Kuck and Associates, Inc. (KAI) C++ Compiler
27732
27733             # KCC will only create a shared library if the output file
27734             # ends with ".so" (or ".sl" for HP-UX), so rename the library
27735             # to its proper name (with version) after linking.
27736             archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
27737             archive_expsym_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib'
27738             # Commands to make compiler produce verbose output that lists
27739             # what "hidden" libraries, object files and flags are used when
27740             # linking a shared library.
27741             #
27742             # There doesn't appear to be a way to prevent this compiler from
27743             # explicitly linking system object files so we need to strip them
27744             # from the output so that they don't get included in the library
27745             # dependencies.
27746             output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
27747
27748             hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
27749             export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
27750
27751             # Archives containing C++ object files must be created using
27752             # "CC -Bstatic", where "CC" is the KAI C++ compiler.
27753             old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs'
27754             ;;
27755           icpc* | ecpc* )
27756             # Intel C++
27757             with_gnu_ld=yes
27758             # version 8.0 and above of icpc choke on multiply defined symbols
27759             # if we add $predep_objects and $postdep_objects, however 7.1 and
27760             # earlier do not add the objects themselves.
27761             case `$CC -V 2>&1` in
27762               *"Version 7."*)
27763                 archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
27764                 archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
27765                 ;;
27766               *)  # Version 8.0 or newer
27767                 tmp_idyn=
27768                 case $host_cpu in
27769                   ia64*) tmp_idyn=' -i_dynamic';;
27770                 esac
27771                 archive_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
27772                 archive_expsym_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
27773                 ;;
27774             esac
27775             archive_cmds_need_lc_CXX=no
27776             hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
27777             export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
27778             whole_archive_flag_spec_CXX='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
27779             ;;
27780           pgCC* | pgcpp*)
27781             # Portland Group C++ compiler
27782             case `$CC -V` in
27783             *pgCC\ [1-5].* | *pgcpp\ [1-5].*)
27784               prelink_cmds_CXX='tpldir=Template.dir~
27785                 rm -rf $tpldir~
27786                 $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~
27787                 compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"'
27788               old_archive_cmds_CXX='tpldir=Template.dir~
27789                 rm -rf $tpldir~
27790                 $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~
27791                 $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~
27792                 $RANLIB $oldlib'
27793               archive_cmds_CXX='tpldir=Template.dir~
27794                 rm -rf $tpldir~
27795                 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
27796                 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
27797               archive_expsym_cmds_CXX='tpldir=Template.dir~
27798                 rm -rf $tpldir~
27799                 $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
27800                 $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
27801               ;;
27802             *) # Version 6 and above use weak symbols
27803               archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
27804               archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
27805               ;;
27806             esac
27807
27808             hardcode_libdir_flag_spec_CXX='${wl}--rpath ${wl}$libdir'
27809             export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
27810             whole_archive_flag_spec_CXX='${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'
27811             ;;
27812           cxx*)
27813             # Compaq C++
27814             archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
27815             archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname  -o $lib ${wl}-retain-symbols-file $wl$export_symbols'
27816
27817             runpath_var=LD_RUN_PATH
27818             hardcode_libdir_flag_spec_CXX='-rpath $libdir'
27819             hardcode_libdir_separator_CXX=:
27820
27821             # Commands to make compiler produce verbose output that lists
27822             # what "hidden" libraries, object files and flags are used when
27823             # linking a shared library.
27824             #
27825             # There doesn't appear to be a way to prevent this compiler from
27826             # explicitly linking system object files so we need to strip them
27827             # from the output so that they don't get included in the library
27828             # dependencies.
27829             output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed'
27830             ;;
27831           xl* | mpixl* | bgxl*)
27832             # IBM XL 8.0 on PPC, with GNU ld
27833             hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
27834             export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
27835             archive_cmds_CXX='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
27836             if test "x$supports_anon_versioning" = xyes; then
27837               archive_expsym_cmds_CXX='echo "{ global:" > $output_objdir/$libname.ver~
27838                 cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
27839                 echo "local: *; };" >> $output_objdir/$libname.ver~
27840                 $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
27841             fi
27842             ;;
27843           *)
27844             case `$CC -V 2>&1 | sed 5q` in
27845             *Sun\ C*)
27846               # Sun C++ 5.9
27847               no_undefined_flag_CXX=' -zdefs'
27848               archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
27849               archive_expsym_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols'
27850               hardcode_libdir_flag_spec_CXX='-R$libdir'
27851               whole_archive_flag_spec_CXX='${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'
27852               compiler_needs_object_CXX=yes
27853
27854               # Not sure whether something based on
27855               # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
27856               # would be better.
27857               output_verbose_link_cmd='func_echo_all'
27858
27859               # Archives containing C++ object files must be created using
27860               # "CC -xar", where "CC" is the Sun C++ compiler.  This is
27861               # necessary to make sure instantiated templates are included
27862               # in the archive.
27863               old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs'
27864               ;;
27865             esac
27866             ;;
27867         esac
27868         ;;
27869
27870       lynxos*)
27871         # FIXME: insert proper C++ library support
27872         ld_shlibs_CXX=no
27873         ;;
27874
27875       m88k*)
27876         # FIXME: insert proper C++ library support
27877         ld_shlibs_CXX=no
27878         ;;
27879
27880       mvs*)
27881         case $cc_basename in
27882           cxx*)
27883             # FIXME: insert proper C++ library support
27884             ld_shlibs_CXX=no
27885             ;;
27886           *)
27887             # FIXME: insert proper C++ library support
27888             ld_shlibs_CXX=no
27889             ;;
27890         esac
27891         ;;
27892
27893       netbsd*)
27894         if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
27895           archive_cmds_CXX='$LD -Bshareable  -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
27896           wlarc=
27897           hardcode_libdir_flag_spec_CXX='-R$libdir'
27898           hardcode_direct_CXX=yes
27899           hardcode_shlibpath_var_CXX=no
27900         fi
27901         # Workaround some broken pre-1.5 toolchains
27902         output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
27903         ;;
27904
27905       *nto* | *qnx*)
27906         ld_shlibs_CXX=yes
27907         ;;
27908
27909       openbsd2*)
27910         # C++ shared libraries are fairly broken
27911         ld_shlibs_CXX=no
27912         ;;
27913
27914       openbsd*)
27915         if test -f /usr/libexec/ld.so; then
27916           hardcode_direct_CXX=yes
27917           hardcode_shlibpath_var_CXX=no
27918           hardcode_direct_absolute_CXX=yes
27919           archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
27920           hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
27921           if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
27922             archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib'
27923             export_dynamic_flag_spec_CXX='${wl}-E'
27924             whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
27925           fi
27926           output_verbose_link_cmd=func_echo_all
27927         else
27928           ld_shlibs_CXX=no
27929         fi
27930         ;;
27931
27932       osf3* | osf4* | osf5*)
27933         case $cc_basename in
27934           KCC*)
27935             # Kuck and Associates, Inc. (KAI) C++ Compiler
27936
27937             # KCC will only create a shared library if the output file
27938             # ends with ".so" (or ".sl" for HP-UX), so rename the library
27939             # to its proper name (with version) after linking.
27940             archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
27941
27942             hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
27943             hardcode_libdir_separator_CXX=:
27944
27945             # Archives containing C++ object files must be created using
27946             # the KAI C++ compiler.
27947             case $host in
27948               osf3*) old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' ;;
27949               *) old_archive_cmds_CXX='$CC -o $oldlib $oldobjs' ;;
27950             esac
27951             ;;
27952           RCC*)
27953             # Rational C++ 2.4.1
27954             # FIXME: insert proper C++ library support
27955             ld_shlibs_CXX=no
27956             ;;
27957           cxx*)
27958             case $host in
27959               osf3*)
27960                 allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*'
27961                 archive_cmds_CXX='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && func_echo_all "${wl}-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
27962                 hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
27963                 ;;
27964               *)
27965                 allow_undefined_flag_CXX=' -expect_unresolved \*'
27966                 archive_cmds_CXX='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
27967                 archive_expsym_cmds_CXX='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
27968                   echo "-hidden">> $lib.exp~
27969                   $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname ${wl}-input ${wl}$lib.exp  `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~
27970                   $RM $lib.exp'
27971                 hardcode_libdir_flag_spec_CXX='-rpath $libdir'
27972                 ;;
27973             esac
27974
27975             hardcode_libdir_separator_CXX=:
27976
27977             # Commands to make compiler produce verbose output that lists
27978             # what "hidden" libraries, object files and flags are used when
27979             # linking a shared library.
27980             #
27981             # There doesn't appear to be a way to prevent this compiler from
27982             # explicitly linking system object files so we need to strip them
27983             # from the output so that they don't get included in the library
27984             # dependencies.
27985             output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
27986             ;;
27987           *)
27988             if test "$GXX" = yes && test "$with_gnu_ld" = no; then
27989               allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*'
27990               case $host in
27991                 osf3*)
27992                   archive_cmds_CXX='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $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'
27993                   ;;
27994                 *)
27995                   archive_cmds_CXX='$CC -shared $pic_flag -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $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'
27996                   ;;
27997               esac
27998
27999               hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
28000               hardcode_libdir_separator_CXX=:
28001
28002               # Commands to make compiler produce verbose output that lists
28003               # what "hidden" libraries, object files and flags are used when
28004               # linking a shared library.
28005               output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
28006
28007             else
28008               # FIXME: insert proper C++ library support
28009               ld_shlibs_CXX=no
28010             fi
28011             ;;
28012         esac
28013         ;;
28014
28015       psos*)
28016         # FIXME: insert proper C++ library support
28017         ld_shlibs_CXX=no
28018         ;;
28019
28020       sunos4*)
28021         case $cc_basename in
28022           CC*)
28023             # Sun C++ 4.x
28024             # FIXME: insert proper C++ library support
28025             ld_shlibs_CXX=no
28026             ;;
28027           lcc*)
28028             # Lucid
28029             # FIXME: insert proper C++ library support
28030             ld_shlibs_CXX=no
28031             ;;
28032           *)
28033             # FIXME: insert proper C++ library support
28034             ld_shlibs_CXX=no
28035             ;;
28036         esac
28037         ;;
28038
28039       solaris*)
28040         case $cc_basename in
28041           CC* | sunCC*)
28042             # Sun C++ 4.2, 5.x and Centerline C++
28043             archive_cmds_need_lc_CXX=yes
28044             no_undefined_flag_CXX=' -zdefs'
28045             archive_cmds_CXX='$CC -G${allow_undefined_flag}  -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
28046             archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
28047               $CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
28048
28049             hardcode_libdir_flag_spec_CXX='-R$libdir'
28050             hardcode_shlibpath_var_CXX=no
28051             case $host_os in
28052               solaris2.[0-5] | solaris2.[0-5].*) ;;
28053               *)
28054                 # The compiler driver will combine and reorder linker options,
28055                 # but understands `-z linker_flag'.
28056                 # Supported since Solaris 2.6 (maybe 2.5.1?)
28057                 whole_archive_flag_spec_CXX='-z allextract$convenience -z defaultextract'
28058                 ;;
28059             esac
28060             link_all_deplibs_CXX=yes
28061
28062             output_verbose_link_cmd='func_echo_all'
28063
28064             # Archives containing C++ object files must be created using
28065             # "CC -xar", where "CC" is the Sun C++ compiler.  This is
28066             # necessary to make sure instantiated templates are included
28067             # in the archive.
28068             old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs'
28069             ;;
28070           gcx*)
28071             # Green Hills C++ Compiler
28072             archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
28073
28074             # The C++ compiler must be used to create the archive.
28075             old_archive_cmds_CXX='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
28076             ;;
28077           *)
28078             # GNU C++ compiler with Solaris linker
28079             if test "$GXX" = yes && test "$with_gnu_ld" = no; then
28080               no_undefined_flag_CXX=' ${wl}-z ${wl}defs'
28081               if $CC --version | $GREP -v '^2\.7' > /dev/null; then
28082                 archive_cmds_CXX='$CC -shared $pic_flag -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
28083                 archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
28084                   $CC -shared $pic_flag -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
28085
28086                 # Commands to make compiler produce verbose output that lists
28087                 # what "hidden" libraries, object files and flags are used when
28088                 # linking a shared library.
28089                 output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
28090               else
28091                 # g++ 2.7 appears to require `-G' NOT `-shared' on this
28092                 # platform.
28093                 archive_cmds_CXX='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
28094                 archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
28095                   $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
28096
28097                 # Commands to make compiler produce verbose output that lists
28098                 # what "hidden" libraries, object files and flags are used when
28099                 # linking a shared library.
28100                 output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
28101               fi
28102
28103               hardcode_libdir_flag_spec_CXX='${wl}-R $wl$libdir'
28104               case $host_os in
28105                 solaris2.[0-5] | solaris2.[0-5].*) ;;
28106                 *)
28107                   whole_archive_flag_spec_CXX='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
28108                   ;;
28109               esac
28110             fi
28111             ;;
28112         esac
28113         ;;
28114
28115     sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
28116       no_undefined_flag_CXX='${wl}-z,text'
28117       archive_cmds_need_lc_CXX=no
28118       hardcode_shlibpath_var_CXX=no
28119       runpath_var='LD_RUN_PATH'
28120
28121       case $cc_basename in
28122         CC*)
28123           archive_cmds_CXX='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
28124           archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
28125           ;;
28126         *)
28127           archive_cmds_CXX='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
28128           archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
28129           ;;
28130       esac
28131       ;;
28132
28133       sysv5* | sco3.2v5* | sco5v6*)
28134         # Note: We can NOT use -z defs as we might desire, because we do not
28135         # link with -lc, and that would cause any symbols used from libc to
28136         # always be unresolved, which means just about no library would
28137         # ever link correctly.  If we're not using GNU ld we use -z text
28138         # though, which does catch some bad symbols but isn't as heavy-handed
28139         # as -z defs.
28140         no_undefined_flag_CXX='${wl}-z,text'
28141         allow_undefined_flag_CXX='${wl}-z,nodefs'
28142         archive_cmds_need_lc_CXX=no
28143         hardcode_shlibpath_var_CXX=no
28144         hardcode_libdir_flag_spec_CXX='${wl}-R,$libdir'
28145         hardcode_libdir_separator_CXX=':'
28146         link_all_deplibs_CXX=yes
28147         export_dynamic_flag_spec_CXX='${wl}-Bexport'
28148         runpath_var='LD_RUN_PATH'
28149
28150         case $cc_basename in
28151           CC*)
28152             archive_cmds_CXX='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
28153             archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
28154             old_archive_cmds_CXX='$CC -Tprelink_objects $oldobjs~
28155               '"$old_archive_cmds_CXX"
28156             reload_cmds_CXX='$CC -Tprelink_objects $reload_objs~
28157               '"$reload_cmds_CXX"
28158             ;;
28159           *)
28160             archive_cmds_CXX='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
28161             archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
28162             ;;
28163         esac
28164       ;;
28165
28166       tandem*)
28167         case $cc_basename in
28168           NCC*)
28169             # NonStop-UX NCC 3.20
28170             # FIXME: insert proper C++ library support
28171             ld_shlibs_CXX=no
28172             ;;
28173           *)
28174             # FIXME: insert proper C++ library support
28175             ld_shlibs_CXX=no
28176             ;;
28177         esac
28178         ;;
28179
28180       vxworks*)
28181         # FIXME: insert proper C++ library support
28182         ld_shlibs_CXX=no
28183         ;;
28184
28185       *)
28186         # FIXME: insert proper C++ library support
28187         ld_shlibs_CXX=no
28188         ;;
28189     esac
28190
28191     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5
28192 $as_echo "$ld_shlibs_CXX" >&6; }
28193     test "$ld_shlibs_CXX" = no && can_build_shared=no
28194
28195     GCC_CXX="$GXX"
28196     LD_CXX="$LD"
28197
28198     ## CAVEAT EMPTOR:
28199     ## There is no encapsulation within the following macros, do not change
28200     ## the running order or otherwise move them around unless you know exactly
28201     ## what you are doing...
28202     # Dependencies to place before and after the object being linked:
28203 predep_objects_CXX=
28204 postdep_objects_CXX=
28205 predeps_CXX=
28206 postdeps_CXX=
28207 compiler_lib_search_path_CXX=
28208
28209 cat > conftest.$ac_ext <<_LT_EOF
28210 class Foo
28211 {
28212 public:
28213   Foo (void) { a = 0; }
28214 private:
28215   int a;
28216 };
28217 _LT_EOF
28218
28219
28220 _lt_libdeps_save_CFLAGS=$CFLAGS
28221 case "$CC $CFLAGS " in #(
28222 *\ -flto*\ *) CFLAGS="$CFLAGS -fno-lto" ;;
28223 *\ -fwhopr*\ *) CFLAGS="$CFLAGS -fno-whopr" ;;
28224 esac
28225
28226 if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
28227   (eval $ac_compile) 2>&5
28228   ac_status=$?
28229   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
28230   test $ac_status = 0; }; then
28231   # Parse the compiler output and extract the necessary
28232   # objects, libraries and library flags.
28233
28234   # Sentinel used to keep track of whether or not we are before
28235   # the conftest object file.
28236   pre_test_object_deps_done=no
28237
28238   for p in `eval "$output_verbose_link_cmd"`; do
28239     case ${prev}${p} in
28240
28241     -L* | -R* | -l*)
28242        # Some compilers place space between "-{L,R}" and the path.
28243        # Remove the space.
28244        if test $p = "-L" ||
28245           test $p = "-R"; then
28246          prev=$p
28247          continue
28248        fi
28249
28250        # Expand the sysroot to ease extracting the directories later.
28251        if test -z "$prev"; then
28252          case $p in
28253          -L*) func_stripname_cnf '-L' '' "$p"; prev=-L; p=$func_stripname_result ;;
28254          -R*) func_stripname_cnf '-R' '' "$p"; prev=-R; p=$func_stripname_result ;;
28255          -l*) func_stripname_cnf '-l' '' "$p"; prev=-l; p=$func_stripname_result ;;
28256          esac
28257        fi
28258        case $p in
28259        =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;;
28260        esac
28261        if test "$pre_test_object_deps_done" = no; then
28262          case ${prev} in
28263          -L | -R)
28264            # Internal compiler library paths should come after those
28265            # provided the user.  The postdeps already come after the
28266            # user supplied libs so there is no need to process them.
28267            if test -z "$compiler_lib_search_path_CXX"; then
28268              compiler_lib_search_path_CXX="${prev}${p}"
28269            else
28270              compiler_lib_search_path_CXX="${compiler_lib_search_path_CXX} ${prev}${p}"
28271            fi
28272            ;;
28273          # The "-l" case would never come before the object being
28274          # linked, so don't bother handling this case.
28275          esac
28276        else
28277          if test -z "$postdeps_CXX"; then
28278            postdeps_CXX="${prev}${p}"
28279          else
28280            postdeps_CXX="${postdeps_CXX} ${prev}${p}"
28281          fi
28282        fi
28283        prev=
28284        ;;
28285
28286     *.lto.$objext) ;; # Ignore GCC LTO objects
28287     *.$objext)
28288        # This assumes that the test object file only shows up
28289        # once in the compiler output.
28290        if test "$p" = "conftest.$objext"; then
28291          pre_test_object_deps_done=yes
28292          continue
28293        fi
28294
28295        if test "$pre_test_object_deps_done" = no; then
28296          if test -z "$predep_objects_CXX"; then
28297            predep_objects_CXX="$p"
28298          else
28299            predep_objects_CXX="$predep_objects_CXX $p"
28300          fi
28301        else
28302          if test -z "$postdep_objects_CXX"; then
28303            postdep_objects_CXX="$p"
28304          else
28305            postdep_objects_CXX="$postdep_objects_CXX $p"
28306          fi
28307        fi
28308        ;;
28309
28310     *) ;; # Ignore the rest.
28311
28312     esac
28313   done
28314
28315   # Clean up.
28316   rm -f a.out a.exe
28317 else
28318   echo "libtool.m4: error: problem compiling CXX test program"
28319 fi
28320
28321 $RM -f confest.$objext
28322 CFLAGS=$_lt_libdeps_save_CFLAGS
28323
28324 # PORTME: override above test on systems where it is broken
28325 case $host_os in
28326 interix[3-9]*)
28327   # Interix 3.5 installs completely hosed .la files for C++, so rather than
28328   # hack all around it, let's just trust "g++" to DTRT.
28329   predep_objects_CXX=
28330   postdep_objects_CXX=
28331   postdeps_CXX=
28332   ;;
28333
28334 linux*)
28335   case `$CC -V 2>&1 | sed 5q` in
28336   *Sun\ C*)
28337     # Sun C++ 5.9
28338
28339     # The more standards-conforming stlport4 library is
28340     # incompatible with the Cstd library. Avoid specifying
28341     # it if it's in CXXFLAGS. Ignore libCrun as
28342     # -library=stlport4 depends on it.
28343     case " $CXX $CXXFLAGS " in
28344     *" -library=stlport4 "*)
28345       solaris_use_stlport4=yes
28346       ;;
28347     esac
28348
28349     if test "$solaris_use_stlport4" != yes; then
28350       postdeps_CXX='-library=Cstd -library=Crun'
28351     fi
28352     ;;
28353   esac
28354   ;;
28355
28356 solaris*)
28357   case $cc_basename in
28358   CC* | sunCC*)
28359     # The more standards-conforming stlport4 library is
28360     # incompatible with the Cstd library. Avoid specifying
28361     # it if it's in CXXFLAGS. Ignore libCrun as
28362     # -library=stlport4 depends on it.
28363     case " $CXX $CXXFLAGS " in
28364     *" -library=stlport4 "*)
28365       solaris_use_stlport4=yes
28366       ;;
28367     esac
28368
28369     # Adding this requires a known-good setup of shared libraries for
28370     # Sun compiler versions before 5.6, else PIC objects from an old
28371     # archive will be linked into the output, leading to subtle bugs.
28372     if test "$solaris_use_stlport4" != yes; then
28373       postdeps_CXX='-library=Cstd -library=Crun'
28374     fi
28375     ;;
28376   esac
28377   ;;
28378 esac
28379
28380
28381 case " $postdeps_CXX " in
28382 *" -lc "*) archive_cmds_need_lc_CXX=no ;;
28383 esac
28384  compiler_lib_search_dirs_CXX=
28385 if test -n "${compiler_lib_search_path_CXX}"; then
28386  compiler_lib_search_dirs_CXX=`echo " ${compiler_lib_search_path_CXX}" | ${SED} -e 's! -L! !g' -e 's!^ !!'`
28387 fi
28388
28389
28390
28391
28392
28393
28394
28395
28396
28397
28398
28399
28400
28401
28402
28403
28404
28405
28406
28407
28408
28409
28410
28411
28412
28413
28414
28415
28416
28417
28418
28419     lt_prog_compiler_wl_CXX=
28420 lt_prog_compiler_pic_CXX=
28421 lt_prog_compiler_static_CXX=
28422
28423
28424   # C++ specific cases for pic, static, wl, etc.
28425   if test "$GXX" = yes; then
28426     lt_prog_compiler_wl_CXX='-Wl,'
28427     lt_prog_compiler_static_CXX='-static'
28428
28429     case $host_os in
28430     aix*)
28431       # All AIX code is PIC.
28432       if test "$host_cpu" = ia64; then
28433         # AIX 5 now supports IA64 processor
28434         lt_prog_compiler_static_CXX='-Bstatic'
28435       fi
28436       ;;
28437
28438     amigaos*)
28439       case $host_cpu in
28440       powerpc)
28441             # see comment about AmigaOS4 .so support
28442             lt_prog_compiler_pic_CXX='-fPIC'
28443         ;;
28444       m68k)
28445             # FIXME: we need at least 68020 code to build shared libraries, but
28446             # adding the `-m68020' flag to GCC prevents building anything better,
28447             # like `-m68040'.
28448             lt_prog_compiler_pic_CXX='-m68020 -resident32 -malways-restore-a4'
28449         ;;
28450       esac
28451       ;;
28452
28453     beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
28454       # PIC is the default for these OSes.
28455       ;;
28456     mingw* | cygwin* | os2* | pw32* | cegcc*)
28457       # This hack is so that the source file can tell whether it is being
28458       # built for inclusion in a dll (and should export symbols for example).
28459       # Although the cygwin gcc ignores -fPIC, still need this for old-style
28460       # (--disable-auto-import) libraries
28461       lt_prog_compiler_pic_CXX='-DDLL_EXPORT'
28462       ;;
28463     darwin* | rhapsody*)
28464       # PIC is the default on this platform
28465       # Common symbols not allowed in MH_DYLIB files
28466       lt_prog_compiler_pic_CXX='-fno-common'
28467       ;;
28468     *djgpp*)
28469       # DJGPP does not support shared libraries at all
28470       lt_prog_compiler_pic_CXX=
28471       ;;
28472     haiku*)
28473       # PIC is the default for Haiku.
28474       # The "-static" flag exists, but is broken.
28475       lt_prog_compiler_static_CXX=
28476       ;;
28477     interix[3-9]*)
28478       # Interix 3.x gcc -fpic/-fPIC options generate broken code.
28479       # Instead, we relocate shared libraries at runtime.
28480       ;;
28481     sysv4*MP*)
28482       if test -d /usr/nec; then
28483         lt_prog_compiler_pic_CXX=-Kconform_pic
28484       fi
28485       ;;
28486     hpux*)
28487       # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
28488       # PA HP-UX.  On IA64 HP-UX, PIC is the default but the pic flag
28489       # sets the default TLS model and affects inlining.
28490       case $host_cpu in
28491       hppa*64*)
28492         ;;
28493       *)
28494         lt_prog_compiler_pic_CXX='-fPIC'
28495         ;;
28496       esac
28497       ;;
28498     *qnx* | *nto*)
28499       # QNX uses GNU C++, but need to define -shared option too, otherwise
28500       # it will coredump.
28501       lt_prog_compiler_pic_CXX='-fPIC -shared'
28502       ;;
28503     *)
28504       lt_prog_compiler_pic_CXX='-fPIC'
28505       ;;
28506     esac
28507   else
28508     case $host_os in
28509       aix[4-9]*)
28510         # All AIX code is PIC.
28511         if test "$host_cpu" = ia64; then
28512           # AIX 5 now supports IA64 processor
28513           lt_prog_compiler_static_CXX='-Bstatic'
28514         else
28515           lt_prog_compiler_static_CXX='-bnso -bI:/lib/syscalls.exp'
28516         fi
28517         ;;
28518       chorus*)
28519         case $cc_basename in
28520         cxch68*)
28521           # Green Hills C++ Compiler
28522           # _LT_TAGVAR(lt_prog_compiler_static, CXX)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a"
28523           ;;
28524         esac
28525         ;;
28526       mingw* | cygwin* | os2* | pw32* | cegcc*)
28527         # This hack is so that the source file can tell whether it is being
28528         # built for inclusion in a dll (and should export symbols for example).
28529         lt_prog_compiler_pic_CXX='-DDLL_EXPORT'
28530         ;;
28531       dgux*)
28532         case $cc_basename in
28533           ec++*)
28534             lt_prog_compiler_pic_CXX='-KPIC'
28535             ;;
28536           ghcx*)
28537             # Green Hills C++ Compiler
28538             lt_prog_compiler_pic_CXX='-pic'
28539             ;;
28540           *)
28541             ;;
28542         esac
28543         ;;
28544       freebsd* | dragonfly*)
28545         # FreeBSD uses GNU C++
28546         ;;
28547       hpux9* | hpux10* | hpux11*)
28548         case $cc_basename in
28549           CC*)
28550             lt_prog_compiler_wl_CXX='-Wl,'
28551             lt_prog_compiler_static_CXX='${wl}-a ${wl}archive'
28552             if test "$host_cpu" != ia64; then
28553               lt_prog_compiler_pic_CXX='+Z'
28554             fi
28555             ;;
28556           aCC*)
28557             lt_prog_compiler_wl_CXX='-Wl,'
28558             lt_prog_compiler_static_CXX='${wl}-a ${wl}archive'
28559             case $host_cpu in
28560             hppa*64*|ia64*)
28561               # +Z the default
28562               ;;
28563             *)
28564               lt_prog_compiler_pic_CXX='+Z'
28565               ;;
28566             esac
28567             ;;
28568           *)
28569             ;;
28570         esac
28571         ;;
28572       interix*)
28573         # This is c89, which is MS Visual C++ (no shared libs)
28574         # Anyone wants to do a port?
28575         ;;
28576       irix5* | irix6* | nonstopux*)
28577         case $cc_basename in
28578           CC*)
28579             lt_prog_compiler_wl_CXX='-Wl,'
28580             lt_prog_compiler_static_CXX='-non_shared'
28581             # CC pic flag -KPIC is the default.
28582             ;;
28583           *)
28584             ;;
28585         esac
28586         ;;
28587       linux* | k*bsd*-gnu | kopensolaris*-gnu)
28588         case $cc_basename in
28589           KCC*)
28590             # KAI C++ Compiler
28591             lt_prog_compiler_wl_CXX='--backend -Wl,'
28592             lt_prog_compiler_pic_CXX='-fPIC'
28593             ;;
28594           ecpc* )
28595             # old Intel C++ for x86_64 which still supported -KPIC.
28596             lt_prog_compiler_wl_CXX='-Wl,'
28597             lt_prog_compiler_pic_CXX='-KPIC'
28598             lt_prog_compiler_static_CXX='-static'
28599             ;;
28600           icpc* )
28601             # Intel C++, used to be incompatible with GCC.
28602             # ICC 10 doesn't accept -KPIC any more.
28603             lt_prog_compiler_wl_CXX='-Wl,'
28604             lt_prog_compiler_pic_CXX='-fPIC'
28605             lt_prog_compiler_static_CXX='-static'
28606             ;;
28607           pgCC* | pgcpp*)
28608             # Portland Group C++ compiler
28609             lt_prog_compiler_wl_CXX='-Wl,'
28610             lt_prog_compiler_pic_CXX='-fpic'
28611             lt_prog_compiler_static_CXX='-Bstatic'
28612             ;;
28613           cxx*)
28614             # Compaq C++
28615             # Make sure the PIC flag is empty.  It appears that all Alpha
28616             # Linux and Compaq Tru64 Unix objects are PIC.
28617             lt_prog_compiler_pic_CXX=
28618             lt_prog_compiler_static_CXX='-non_shared'
28619             ;;
28620           xlc* | xlC* | bgxl[cC]* | mpixl[cC]*)
28621             # IBM XL 8.0, 9.0 on PPC and BlueGene
28622             lt_prog_compiler_wl_CXX='-Wl,'
28623             lt_prog_compiler_pic_CXX='-qpic'
28624             lt_prog_compiler_static_CXX='-qstaticlink'
28625             ;;
28626           *)
28627             case `$CC -V 2>&1 | sed 5q` in
28628             *Sun\ C*)
28629               # Sun C++ 5.9
28630               lt_prog_compiler_pic_CXX='-KPIC'
28631               lt_prog_compiler_static_CXX='-Bstatic'
28632               lt_prog_compiler_wl_CXX='-Qoption ld '
28633               ;;
28634             esac
28635             ;;
28636         esac
28637         ;;
28638       lynxos*)
28639         ;;
28640       m88k*)
28641         ;;
28642       mvs*)
28643         case $cc_basename in
28644           cxx*)
28645             lt_prog_compiler_pic_CXX='-W c,exportall'
28646             ;;
28647           *)
28648             ;;
28649         esac
28650         ;;
28651       netbsd*)
28652         ;;
28653       *qnx* | *nto*)
28654         # QNX uses GNU C++, but need to define -shared option too, otherwise
28655         # it will coredump.
28656         lt_prog_compiler_pic_CXX='-fPIC -shared'
28657         ;;
28658       osf3* | osf4* | osf5*)
28659         case $cc_basename in
28660           KCC*)
28661             lt_prog_compiler_wl_CXX='--backend -Wl,'
28662             ;;
28663           RCC*)
28664             # Rational C++ 2.4.1
28665             lt_prog_compiler_pic_CXX='-pic'
28666             ;;
28667           cxx*)
28668             # Digital/Compaq C++
28669             lt_prog_compiler_wl_CXX='-Wl,'
28670             # Make sure the PIC flag is empty.  It appears that all Alpha
28671             # Linux and Compaq Tru64 Unix objects are PIC.
28672             lt_prog_compiler_pic_CXX=
28673             lt_prog_compiler_static_CXX='-non_shared'
28674             ;;
28675           *)
28676             ;;
28677         esac
28678         ;;
28679       psos*)
28680         ;;
28681       solaris*)
28682         case $cc_basename in
28683           CC* | sunCC*)
28684             # Sun C++ 4.2, 5.x and Centerline C++
28685             lt_prog_compiler_pic_CXX='-KPIC'
28686             lt_prog_compiler_static_CXX='-Bstatic'
28687             lt_prog_compiler_wl_CXX='-Qoption ld '
28688             ;;
28689           gcx*)
28690             # Green Hills C++ Compiler
28691             lt_prog_compiler_pic_CXX='-PIC'
28692             ;;
28693           *)
28694             ;;
28695         esac
28696         ;;
28697       sunos4*)
28698         case $cc_basename in
28699           CC*)
28700             # Sun C++ 4.x
28701             lt_prog_compiler_pic_CXX='-pic'
28702             lt_prog_compiler_static_CXX='-Bstatic'
28703             ;;
28704           lcc*)
28705             # Lucid
28706             lt_prog_compiler_pic_CXX='-pic'
28707             ;;
28708           *)
28709             ;;
28710         esac
28711         ;;
28712       sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
28713         case $cc_basename in
28714           CC*)
28715             lt_prog_compiler_wl_CXX='-Wl,'
28716             lt_prog_compiler_pic_CXX='-KPIC'
28717             lt_prog_compiler_static_CXX='-Bstatic'
28718             ;;
28719         esac
28720         ;;
28721       tandem*)
28722         case $cc_basename in
28723           NCC*)
28724             # NonStop-UX NCC 3.20
28725             lt_prog_compiler_pic_CXX='-KPIC'
28726             ;;
28727           *)
28728             ;;
28729         esac
28730         ;;
28731       vxworks*)
28732         ;;
28733       *)
28734         lt_prog_compiler_can_build_shared_CXX=no
28735         ;;
28736     esac
28737   fi
28738
28739 case $host_os in
28740   # For platforms which do not support PIC, -DPIC is meaningless:
28741   *djgpp*)
28742     lt_prog_compiler_pic_CXX=
28743     ;;
28744   *)
28745     lt_prog_compiler_pic_CXX="$lt_prog_compiler_pic_CXX -DPIC"
28746     ;;
28747 esac
28748
28749 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
28750 $as_echo_n "checking for $compiler option to produce PIC... " >&6; }
28751 if ${lt_cv_prog_compiler_pic_CXX+:} false; then :
28752   $as_echo_n "(cached) " >&6
28753 else
28754   lt_cv_prog_compiler_pic_CXX=$lt_prog_compiler_pic_CXX
28755 fi
28756 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_CXX" >&5
28757 $as_echo "$lt_cv_prog_compiler_pic_CXX" >&6; }
28758 lt_prog_compiler_pic_CXX=$lt_cv_prog_compiler_pic_CXX
28759
28760 #
28761 # Check to make sure the PIC flag actually works.
28762 #
28763 if test -n "$lt_prog_compiler_pic_CXX"; then
28764   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works" >&5
28765 $as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works... " >&6; }
28766 if ${lt_cv_prog_compiler_pic_works_CXX+:} false; then :
28767   $as_echo_n "(cached) " >&6
28768 else
28769   lt_cv_prog_compiler_pic_works_CXX=no
28770    ac_outfile=conftest.$ac_objext
28771    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
28772    lt_compiler_flag="$lt_prog_compiler_pic_CXX -DPIC"
28773    # Insert the option either (1) after the last *FLAGS variable, or
28774    # (2) before a word containing "conftest.", or (3) at the end.
28775    # Note that $ac_compile itself does not contain backslashes and begins
28776    # with a dollar sign (not a hyphen), so the echo should work correctly.
28777    # The option is referenced via a variable to avoid confusing sed.
28778    lt_compile=`echo "$ac_compile" | $SED \
28779    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
28780    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
28781    -e 's:$: $lt_compiler_flag:'`
28782    (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
28783    (eval "$lt_compile" 2>conftest.err)
28784    ac_status=$?
28785    cat conftest.err >&5
28786    echo "$as_me:$LINENO: \$? = $ac_status" >&5
28787    if (exit $ac_status) && test -s "$ac_outfile"; then
28788      # The compiler can only warn and ignore the option if not recognized
28789      # So say no if there are warnings other than the usual output.
28790      $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
28791      $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
28792      if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
28793        lt_cv_prog_compiler_pic_works_CXX=yes
28794      fi
28795    fi
28796    $RM conftest*
28797
28798 fi
28799 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works_CXX" >&5
28800 $as_echo "$lt_cv_prog_compiler_pic_works_CXX" >&6; }
28801
28802 if test x"$lt_cv_prog_compiler_pic_works_CXX" = xyes; then
28803     case $lt_prog_compiler_pic_CXX in
28804      "" | " "*) ;;
28805      *) lt_prog_compiler_pic_CXX=" $lt_prog_compiler_pic_CXX" ;;
28806      esac
28807 else
28808     lt_prog_compiler_pic_CXX=
28809      lt_prog_compiler_can_build_shared_CXX=no
28810 fi
28811
28812 fi
28813
28814
28815
28816
28817
28818 #
28819 # Check to make sure the static flag actually works.
28820 #
28821 wl=$lt_prog_compiler_wl_CXX eval lt_tmp_static_flag=\"$lt_prog_compiler_static_CXX\"
28822 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
28823 $as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
28824 if ${lt_cv_prog_compiler_static_works_CXX+:} false; then :
28825   $as_echo_n "(cached) " >&6
28826 else
28827   lt_cv_prog_compiler_static_works_CXX=no
28828    save_LDFLAGS="$LDFLAGS"
28829    LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
28830    echo "$lt_simple_link_test_code" > conftest.$ac_ext
28831    if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
28832      # The linker can only warn and ignore the option if not recognized
28833      # So say no if there are warnings
28834      if test -s conftest.err; then
28835        # Append any errors to the config.log.
28836        cat conftest.err 1>&5
28837        $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
28838        $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
28839        if diff conftest.exp conftest.er2 >/dev/null; then
28840          lt_cv_prog_compiler_static_works_CXX=yes
28841        fi
28842      else
28843        lt_cv_prog_compiler_static_works_CXX=yes
28844      fi
28845    fi
28846    $RM -r conftest*
28847    LDFLAGS="$save_LDFLAGS"
28848
28849 fi
28850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works_CXX" >&5
28851 $as_echo "$lt_cv_prog_compiler_static_works_CXX" >&6; }
28852
28853 if test x"$lt_cv_prog_compiler_static_works_CXX" = xyes; then
28854     :
28855 else
28856     lt_prog_compiler_static_CXX=
28857 fi
28858
28859
28860
28861
28862     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
28863 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
28864 if ${lt_cv_prog_compiler_c_o_CXX+:} false; then :
28865   $as_echo_n "(cached) " >&6
28866 else
28867   lt_cv_prog_compiler_c_o_CXX=no
28868    $RM -r conftest 2>/dev/null
28869    mkdir conftest
28870    cd conftest
28871    mkdir out
28872    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
28873
28874    lt_compiler_flag="-o out/conftest2.$ac_objext"
28875    # Insert the option either (1) after the last *FLAGS variable, or
28876    # (2) before a word containing "conftest.", or (3) at the end.
28877    # Note that $ac_compile itself does not contain backslashes and begins
28878    # with a dollar sign (not a hyphen), so the echo should work correctly.
28879    lt_compile=`echo "$ac_compile" | $SED \
28880    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
28881    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
28882    -e 's:$: $lt_compiler_flag:'`
28883    (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
28884    (eval "$lt_compile" 2>out/conftest.err)
28885    ac_status=$?
28886    cat out/conftest.err >&5
28887    echo "$as_me:$LINENO: \$? = $ac_status" >&5
28888    if (exit $ac_status) && test -s out/conftest2.$ac_objext
28889    then
28890      # The compiler can only warn and ignore the option if not recognized
28891      # So say no if there are warnings
28892      $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
28893      $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
28894      if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
28895        lt_cv_prog_compiler_c_o_CXX=yes
28896      fi
28897    fi
28898    chmod u+w . 2>&5
28899    $RM conftest*
28900    # SGI C++ compiler will create directory out/ii_files/ for
28901    # template instantiation
28902    test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
28903    $RM out/* && rmdir out
28904    cd ..
28905    $RM -r conftest
28906    $RM conftest*
28907
28908 fi
28909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5
28910 $as_echo "$lt_cv_prog_compiler_c_o_CXX" >&6; }
28911
28912
28913
28914     { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
28915 $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
28916 if ${lt_cv_prog_compiler_c_o_CXX+:} false; then :
28917   $as_echo_n "(cached) " >&6
28918 else
28919   lt_cv_prog_compiler_c_o_CXX=no
28920    $RM -r conftest 2>/dev/null
28921    mkdir conftest
28922    cd conftest
28923    mkdir out
28924    echo "$lt_simple_compile_test_code" > conftest.$ac_ext
28925
28926    lt_compiler_flag="-o out/conftest2.$ac_objext"
28927    # Insert the option either (1) after the last *FLAGS variable, or
28928    # (2) before a word containing "conftest.", or (3) at the end.
28929    # Note that $ac_compile itself does not contain backslashes and begins
28930    # with a dollar sign (not a hyphen), so the echo should work correctly.
28931    lt_compile=`echo "$ac_compile" | $SED \
28932    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
28933    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
28934    -e 's:$: $lt_compiler_flag:'`
28935    (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
28936    (eval "$lt_compile" 2>out/conftest.err)
28937    ac_status=$?
28938    cat out/conftest.err >&5
28939    echo "$as_me:$LINENO: \$? = $ac_status" >&5
28940    if (exit $ac_status) && test -s out/conftest2.$ac_objext
28941    then
28942      # The compiler can only warn and ignore the option if not recognized
28943      # So say no if there are warnings
28944      $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
28945      $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
28946      if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
28947        lt_cv_prog_compiler_c_o_CXX=yes
28948      fi
28949    fi
28950    chmod u+w . 2>&5
28951    $RM conftest*
28952    # SGI C++ compiler will create directory out/ii_files/ for
28953    # template instantiation
28954    test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
28955    $RM out/* && rmdir out
28956    cd ..
28957    $RM -r conftest
28958    $RM conftest*
28959
28960 fi
28961 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5
28962 $as_echo "$lt_cv_prog_compiler_c_o_CXX" >&6; }
28963
28964
28965
28966
28967 hard_links="nottested"
28968 if test "$lt_cv_prog_compiler_c_o_CXX" = no && test "$need_locks" != no; then
28969   # do not overwrite the value of need_locks provided by the user
28970   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
28971 $as_echo_n "checking if we can lock with hard links... " >&6; }
28972   hard_links=yes
28973   $RM conftest*
28974   ln conftest.a conftest.b 2>/dev/null && hard_links=no
28975   touch conftest.a
28976   ln conftest.a conftest.b 2>&5 || hard_links=no
28977   ln conftest.a conftest.b 2>/dev/null && hard_links=no
28978   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
28979 $as_echo "$hard_links" >&6; }
28980   if test "$hard_links" = no; then
28981     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
28982 $as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
28983     need_locks=warn
28984   fi
28985 else
28986   need_locks=no
28987 fi
28988
28989
28990
28991     { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
28992 $as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
28993
28994   export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
28995   exclude_expsyms_CXX='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
28996   case $host_os in
28997   aix[4-9]*)
28998     # If we're using GNU nm, then we don't want the "-C" option.
28999     # -C means demangle to AIX nm, but means don't demangle with GNU nm
29000     # Also, AIX nm treats weak defined symbols like other global defined
29001     # symbols, whereas GNU nm marks them as "W".
29002     if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
29003       export_symbols_cmds_CXX='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
29004     else
29005       export_symbols_cmds_CXX='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
29006     fi
29007     ;;
29008   pw32*)
29009     export_symbols_cmds_CXX="$ltdll_cmds"
29010     ;;
29011   cygwin* | mingw* | cegcc*)
29012     case $cc_basename in
29013     cl*) ;;
29014     *)
29015       export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols'
29016       exclude_expsyms_CXX='[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'
29017       ;;
29018     esac
29019     ;;
29020   *)
29021     export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
29022     ;;
29023   esac
29024
29025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5
29026 $as_echo "$ld_shlibs_CXX" >&6; }
29027 test "$ld_shlibs_CXX" = no && can_build_shared=no
29028
29029 with_gnu_ld_CXX=$with_gnu_ld
29030
29031
29032
29033
29034
29035
29036 #
29037 # Do we need to explicitly link libc?
29038 #
29039 case "x$archive_cmds_need_lc_CXX" in
29040 x|xyes)
29041   # Assume -lc should be added
29042   archive_cmds_need_lc_CXX=yes
29043
29044   if test "$enable_shared" = yes && test "$GCC" = yes; then
29045     case $archive_cmds_CXX in
29046     *'~'*)
29047       # FIXME: we may have to deal with multi-command sequences.
29048       ;;
29049     '$CC '*)
29050       # Test whether the compiler implicitly links with -lc since on some
29051       # systems, -lgcc has to come before -lc. If gcc already passes -lc
29052       # to ld, don't add -lc before -lgcc.
29053       { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
29054 $as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
29055 if ${lt_cv_archive_cmds_need_lc_CXX+:} false; then :
29056   $as_echo_n "(cached) " >&6
29057 else
29058   $RM conftest*
29059         echo "$lt_simple_compile_test_code" > conftest.$ac_ext
29060
29061         if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
29062   (eval $ac_compile) 2>&5
29063   ac_status=$?
29064   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
29065   test $ac_status = 0; } 2>conftest.err; then
29066           soname=conftest
29067           lib=conftest
29068           libobjs=conftest.$ac_objext
29069           deplibs=
29070           wl=$lt_prog_compiler_wl_CXX
29071           pic_flag=$lt_prog_compiler_pic_CXX
29072           compiler_flags=-v
29073           linker_flags=-v
29074           verstring=
29075           output_objdir=.
29076           libname=conftest
29077           lt_save_allow_undefined_flag=$allow_undefined_flag_CXX
29078           allow_undefined_flag_CXX=
29079           if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds_CXX 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
29080   (eval $archive_cmds_CXX 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
29081   ac_status=$?
29082   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
29083   test $ac_status = 0; }
29084           then
29085             lt_cv_archive_cmds_need_lc_CXX=no
29086           else
29087             lt_cv_archive_cmds_need_lc_CXX=yes
29088           fi
29089           allow_undefined_flag_CXX=$lt_save_allow_undefined_flag
29090         else
29091           cat conftest.err 1>&5
29092         fi
29093         $RM conftest*
29094
29095 fi
29096 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc_CXX" >&5
29097 $as_echo "$lt_cv_archive_cmds_need_lc_CXX" >&6; }
29098       archive_cmds_need_lc_CXX=$lt_cv_archive_cmds_need_lc_CXX
29099       ;;
29100     esac
29101   fi
29102   ;;
29103 esac
29104
29105
29106
29107
29108
29109
29110
29111
29112
29113
29114
29115
29116
29117
29118
29119
29120
29121
29122
29123
29124
29125
29126
29127
29128
29129
29130
29131
29132
29133
29134
29135
29136
29137
29138
29139
29140
29141
29142
29143
29144
29145
29146
29147
29148
29149
29150
29151
29152
29153
29154
29155
29156
29157
29158
29159
29160
29161
29162
29163
29164
29165
29166
29167
29168     { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
29169 $as_echo_n "checking dynamic linker characteristics... " >&6; }
29170
29171 library_names_spec=
29172 libname_spec='lib$name'
29173 soname_spec=
29174 shrext_cmds=".so"
29175 postinstall_cmds=
29176 postuninstall_cmds=
29177 finish_cmds=
29178 finish_eval=
29179 shlibpath_var=
29180 shlibpath_overrides_runpath=unknown
29181 version_type=none
29182 dynamic_linker="$host_os ld.so"
29183 sys_lib_dlsearch_path_spec="/lib /usr/lib"
29184 need_lib_prefix=unknown
29185 hardcode_into_libs=no
29186
29187 # when you set need_version to no, make sure it does not cause -set_version
29188 # flags to be left without arguments
29189 need_version=unknown
29190
29191 case $host_os in
29192 aix3*)
29193   version_type=linux
29194   library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
29195   shlibpath_var=LIBPATH
29196
29197   # AIX 3 has no versioning support, so we append a major version to the name.
29198   soname_spec='${libname}${release}${shared_ext}$major'
29199   ;;
29200
29201 aix[4-9]*)
29202   version_type=linux
29203   need_lib_prefix=no
29204   need_version=no
29205   hardcode_into_libs=yes
29206   if test "$host_cpu" = ia64; then
29207     # AIX 5 supports IA64
29208     library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
29209     shlibpath_var=LD_LIBRARY_PATH
29210   else
29211     # With GCC up to 2.95.x, collect2 would create an import file
29212     # for dependence libraries.  The import file would start with
29213     # the line `#! .'.  This would cause the generated library to
29214     # depend on `.', always an invalid library.  This was fixed in
29215     # development snapshots of GCC prior to 3.0.
29216     case $host_os in
29217       aix4 | aix4.[01] | aix4.[01].*)
29218       if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
29219            echo ' yes '
29220            echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
29221         :
29222       else
29223         can_build_shared=no
29224       fi
29225       ;;
29226     esac
29227     # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
29228     # soname into executable. Probably we can add versioning support to
29229     # collect2, so additional links can be useful in future.
29230     if test "$aix_use_runtimelinking" = yes; then
29231       # If using run time linking (on AIX 4.2 or later) use lib<name>.so
29232       # instead of lib<name>.a to let people know that these are not
29233       # typical AIX shared libraries.
29234       library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
29235     else
29236       # We preserve .a as extension for shared libraries through AIX4.2
29237       # and later when we are not doing run time linking.
29238       library_names_spec='${libname}${release}.a $libname.a'
29239       soname_spec='${libname}${release}${shared_ext}$major'
29240     fi
29241     shlibpath_var=LIBPATH
29242   fi
29243   ;;
29244
29245 amigaos*)
29246   case $host_cpu in
29247   powerpc)
29248     # Since July 2007 AmigaOS4 officially supports .so libraries.
29249     # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
29250     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
29251     ;;
29252   m68k)
29253     library_names_spec='$libname.ixlibrary $libname.a'
29254     # Create ${libname}_ixlibrary.a entries in /sys/libs.
29255     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'
29256     ;;
29257   esac
29258   ;;
29259
29260 beos*)
29261   library_names_spec='${libname}${shared_ext}'
29262   dynamic_linker="$host_os ld.so"
29263   shlibpath_var=LIBRARY_PATH
29264   ;;
29265
29266 bsdi[45]*)
29267   version_type=linux
29268   need_version=no
29269   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
29270   soname_spec='${libname}${release}${shared_ext}$major'
29271   finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
29272   shlibpath_var=LD_LIBRARY_PATH
29273   sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
29274   sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
29275   # the default ld.so.conf also contains /usr/contrib/lib and
29276   # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
29277   # libtool to hard-code these into programs
29278   ;;
29279
29280 cygwin* | mingw* | pw32* | cegcc*)
29281   version_type=windows
29282   shrext_cmds=".dll"
29283   need_version=no
29284   need_lib_prefix=no
29285
29286   case $GCC,$cc_basename in
29287   yes,*)
29288     # gcc
29289     library_names_spec='$libname.dll.a'
29290     # DLL is installed to $(libdir)/../bin by postinstall_cmds
29291     postinstall_cmds='base_file=`basename \${file}`~
29292       dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
29293       dldir=$destdir/`dirname \$dlpath`~
29294       test -d \$dldir || mkdir -p \$dldir~
29295       $install_prog $dir/$dlname \$dldir/$dlname~
29296       chmod a+x \$dldir/$dlname~
29297       if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
29298         eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
29299       fi'
29300     postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
29301       dlpath=$dir/\$dldll~
29302        $RM \$dlpath'
29303     shlibpath_overrides_runpath=yes
29304
29305     case $host_os in
29306     cygwin*)
29307       # Cygwin DLLs use 'cyg' prefix rather than 'lib'
29308       soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
29309
29310       ;;
29311     mingw* | cegcc*)
29312       # MinGW DLLs use traditional 'lib' prefix
29313       soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
29314       ;;
29315     pw32*)
29316       # pw32 DLLs use 'pw' prefix rather than 'lib'
29317       library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
29318       ;;
29319     esac
29320     dynamic_linker='Win32 ld.exe'
29321     ;;
29322
29323   *,cl*)
29324     # Native MSVC
29325     libname_spec='$name'
29326     soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
29327     library_names_spec='${libname}.dll.lib'
29328
29329     case $build_os in
29330     mingw*)
29331       sys_lib_search_path_spec=
29332       lt_save_ifs=$IFS
29333       IFS=';'
29334       for lt_path in $LIB
29335       do
29336         IFS=$lt_save_ifs
29337         # Let DOS variable expansion print the short 8.3 style file name.
29338         lt_path=`cd "$lt_path" 2>/dev/null && cmd //C "for %i in (".") do @echo %~si"`
29339         sys_lib_search_path_spec="$sys_lib_search_path_spec $lt_path"
29340       done
29341       IFS=$lt_save_ifs
29342       # Convert to MSYS style.
29343       sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | sed -e 's|\\\\|/|g' -e 's| \\([a-zA-Z]\\):| /\\1|g' -e 's|^ ||'`
29344       ;;
29345     cygwin*)
29346       # Convert to unix form, then to dos form, then back to unix form
29347       # but this time dos style (no spaces!) so that the unix form looks
29348       # like /cygdrive/c/PROGRA~1:/cygdr...
29349       sys_lib_search_path_spec=`cygpath --path --unix "$LIB"`
29350       sys_lib_search_path_spec=`cygpath --path --dos "$sys_lib_search_path_spec" 2>/dev/null`
29351       sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
29352       ;;
29353     *)
29354       sys_lib_search_path_spec="$LIB"
29355       if $ECHO "$sys_lib_search_path_spec" | $GREP ';[c-zC-Z]:/' >/dev/null; then
29356         # It is most probably a Windows format PATH.
29357         sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
29358       else
29359         sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"`
29360       fi
29361       # FIXME: find the short name or the path components, as spaces are
29362       # common. (e.g. "Program Files" -> "PROGRA~1")
29363       ;;
29364     esac
29365
29366     # DLL is installed to $(libdir)/../bin by postinstall_cmds
29367     postinstall_cmds='base_file=`basename \${file}`~
29368       dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
29369       dldir=$destdir/`dirname \$dlpath`~
29370       test -d \$dldir || mkdir -p \$dldir~
29371       $install_prog $dir/$dlname \$dldir/$dlname'
29372     postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
29373       dlpath=$dir/\$dldll~
29374        $RM \$dlpath'
29375     shlibpath_overrides_runpath=yes
29376     dynamic_linker='Win32 link.exe'
29377     ;;
29378
29379   *)
29380     # Assume MSVC wrapper
29381     library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
29382     dynamic_linker='Win32 ld.exe'
29383     ;;
29384   esac
29385   # FIXME: first we should search . and the directory the executable is in
29386   shlibpath_var=PATH
29387   ;;
29388
29389 darwin* | rhapsody*)
29390   dynamic_linker="$host_os dyld"
29391   version_type=darwin
29392   need_lib_prefix=no
29393   need_version=no
29394   library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
29395   soname_spec='${libname}${release}${major}$shared_ext'
29396   shlibpath_overrides_runpath=yes
29397   shlibpath_var=DYLD_LIBRARY_PATH
29398   shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
29399
29400   sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
29401   ;;
29402
29403 dgux*)
29404   version_type=linux
29405   need_lib_prefix=no
29406   need_version=no
29407   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
29408   soname_spec='${libname}${release}${shared_ext}$major'
29409   shlibpath_var=LD_LIBRARY_PATH
29410   ;;
29411
29412 freebsd1*)
29413   dynamic_linker=no
29414   ;;
29415
29416 freebsd* | dragonfly*)
29417   # DragonFly does not have aout.  When/if they implement a new
29418   # versioning mechanism, adjust this.
29419   if test -x /usr/bin/objformat; then
29420     objformat=`/usr/bin/objformat`
29421   else
29422     case $host_os in
29423     freebsd[123]*) objformat=aout ;;
29424     *) objformat=elf ;;
29425     esac
29426   fi
29427   version_type=freebsd-$objformat
29428   case $version_type in
29429     freebsd-elf*)
29430       library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
29431       need_version=no
29432       need_lib_prefix=no
29433       ;;
29434     freebsd-*)
29435       library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
29436       need_version=yes
29437       ;;
29438   esac
29439   shlibpath_var=LD_LIBRARY_PATH
29440   case $host_os in
29441   freebsd2*)
29442     shlibpath_overrides_runpath=yes
29443     ;;
29444   freebsd3.[01]* | freebsdelf3.[01]*)
29445     shlibpath_overrides_runpath=yes
29446     hardcode_into_libs=yes
29447     ;;
29448   freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
29449   freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
29450     shlibpath_overrides_runpath=no
29451     hardcode_into_libs=yes
29452     ;;
29453   *) # from 4.6 on, and DragonFly
29454     shlibpath_overrides_runpath=yes
29455     hardcode_into_libs=yes
29456     ;;
29457   esac
29458   ;;
29459
29460 gnu*)
29461   version_type=linux
29462   need_lib_prefix=no
29463   need_version=no
29464   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
29465   soname_spec='${libname}${release}${shared_ext}$major'
29466   shlibpath_var=LD_LIBRARY_PATH
29467   hardcode_into_libs=yes
29468   ;;
29469
29470 haiku*)
29471   version_type=linux
29472   need_lib_prefix=no
29473   need_version=no
29474   dynamic_linker="$host_os runtime_loader"
29475   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
29476   soname_spec='${libname}${release}${shared_ext}$major'
29477   shlibpath_var=LIBRARY_PATH
29478   shlibpath_overrides_runpath=yes
29479   sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
29480   hardcode_into_libs=yes
29481   ;;
29482
29483 hpux9* | hpux10* | hpux11*)
29484   # Give a soname corresponding to the major version so that dld.sl refuses to
29485   # link against other versions.
29486   version_type=sunos
29487   need_lib_prefix=no
29488   need_version=no
29489   case $host_cpu in
29490   ia64*)
29491     shrext_cmds='.so'
29492     hardcode_into_libs=yes
29493     dynamic_linker="$host_os dld.so"
29494     shlibpath_var=LD_LIBRARY_PATH
29495     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
29496     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
29497     soname_spec='${libname}${release}${shared_ext}$major'
29498     if test "X$HPUX_IA64_MODE" = X32; then
29499       sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
29500     else
29501       sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
29502     fi
29503     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
29504     ;;
29505   hppa*64*)
29506     shrext_cmds='.sl'
29507     hardcode_into_libs=yes
29508     dynamic_linker="$host_os dld.sl"
29509     shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
29510     shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
29511     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
29512     soname_spec='${libname}${release}${shared_ext}$major'
29513     sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
29514     sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
29515     ;;
29516   *)
29517     shrext_cmds='.sl'
29518     dynamic_linker="$host_os dld.sl"
29519     shlibpath_var=SHLIB_PATH
29520     shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
29521     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
29522     soname_spec='${libname}${release}${shared_ext}$major'
29523     ;;
29524   esac
29525   # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
29526   postinstall_cmds='chmod 555 $lib'
29527   # or fails outright, so override atomically:
29528   install_override_mode=555
29529   ;;
29530
29531 interix[3-9]*)
29532   version_type=linux
29533   need_lib_prefix=no
29534   need_version=no
29535   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
29536   soname_spec='${libname}${release}${shared_ext}$major'
29537   dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
29538   shlibpath_var=LD_LIBRARY_PATH
29539   shlibpath_overrides_runpath=no
29540   hardcode_into_libs=yes
29541   ;;
29542
29543 irix5* | irix6* | nonstopux*)
29544   case $host_os in
29545     nonstopux*) version_type=nonstopux ;;
29546     *)
29547         if test "$lt_cv_prog_gnu_ld" = yes; then
29548                 version_type=linux
29549         else
29550                 version_type=irix
29551         fi ;;
29552   esac
29553   need_lib_prefix=no
29554   need_version=no
29555   soname_spec='${libname}${release}${shared_ext}$major'
29556   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
29557   case $host_os in
29558   irix5* | nonstopux*)
29559     libsuff= shlibsuff=
29560     ;;
29561   *)
29562     case $LD in # libtool.m4 will add one of these switches to LD
29563     *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
29564       libsuff= shlibsuff= libmagic=32-bit;;
29565     *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
29566       libsuff=32 shlibsuff=N32 libmagic=N32;;
29567     *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
29568       libsuff=64 shlibsuff=64 libmagic=64-bit;;
29569     *) libsuff= shlibsuff= libmagic=never-match;;
29570     esac
29571     ;;
29572   esac
29573   shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
29574   shlibpath_overrides_runpath=no
29575   sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
29576   sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
29577   hardcode_into_libs=yes
29578   ;;
29579
29580 # No shared lib support for Linux oldld, aout, or coff.
29581 linux*oldld* | linux*aout* | linux*coff*)
29582   dynamic_linker=no
29583   ;;
29584
29585 # This must be Linux ELF.
29586 linux* | k*bsd*-gnu | kopensolaris*-gnu)
29587   version_type=linux
29588   need_lib_prefix=no
29589   need_version=no
29590   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
29591   soname_spec='${libname}${release}${shared_ext}$major'
29592   finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
29593   shlibpath_var=LD_LIBRARY_PATH
29594   shlibpath_overrides_runpath=no
29595
29596   # Some binutils ld are patched to set DT_RUNPATH
29597   if ${lt_cv_shlibpath_overrides_runpath+:} false; then :
29598   $as_echo_n "(cached) " >&6
29599 else
29600   lt_cv_shlibpath_overrides_runpath=no
29601     save_LDFLAGS=$LDFLAGS
29602     save_libdir=$libdir
29603     eval "libdir=/foo; wl=\"$lt_prog_compiler_wl_CXX\"; \
29604          LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec_CXX\""
29605     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
29606 /* end confdefs.h.  */
29607
29608 int
29609 main ()
29610 {
29611
29612   ;
29613   return 0;
29614 }
29615 _ACEOF
29616 if ac_fn_cxx_try_link "$LINENO"; then :
29617   if  ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then :
29618   lt_cv_shlibpath_overrides_runpath=yes
29619 fi
29620 fi
29621 rm -f core conftest.err conftest.$ac_objext \
29622     conftest$ac_exeext conftest.$ac_ext
29623     LDFLAGS=$save_LDFLAGS
29624     libdir=$save_libdir
29625
29626 fi
29627
29628   shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
29629
29630   # This implies no fast_install, which is unacceptable.
29631   # Some rework will be needed to allow for fast_install
29632   # before this can be enabled.
29633   hardcode_into_libs=yes
29634
29635   # Append ld.so.conf contents to the search path
29636   if test -f /etc/ld.so.conf; then
29637     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' ' '`
29638     sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
29639   fi
29640
29641   # We used to test for /lib/ld.so.1 and disable shared libraries on
29642   # powerpc, because MkLinux only supported shared libraries with the
29643   # GNU dynamic linker.  Since this was broken with cross compilers,
29644   # most powerpc-linux boxes support dynamic linking these days and
29645   # people can always --disable-shared, the test was removed, and we
29646   # assume the GNU/Linux dynamic linker is in use.
29647   dynamic_linker='GNU/Linux ld.so'
29648   ;;
29649
29650 netbsd*)
29651   version_type=sunos
29652   need_lib_prefix=no
29653   need_version=no
29654   if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
29655     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
29656     finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
29657     dynamic_linker='NetBSD (a.out) ld.so'
29658   else
29659     library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
29660     soname_spec='${libname}${release}${shared_ext}$major'
29661     dynamic_linker='NetBSD ld.elf_so'
29662   fi
29663   shlibpath_var=LD_LIBRARY_PATH
29664   shlibpath_overrides_runpath=yes
29665   hardcode_into_libs=yes
29666   ;;
29667
29668 newsos6)
29669   version_type=linux
29670   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
29671   shlibpath_var=LD_LIBRARY_PATH
29672   shlibpath_overrides_runpath=yes
29673   ;;
29674
29675 *nto* | *qnx*)
29676   version_type=qnx
29677   need_lib_prefix=no
29678   need_version=no
29679   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
29680   soname_spec='${libname}${release}${shared_ext}$major'
29681   shlibpath_var=LD_LIBRARY_PATH
29682   shlibpath_overrides_runpath=no
29683   hardcode_into_libs=yes
29684   dynamic_linker='ldqnx.so'
29685   ;;
29686
29687 openbsd*)
29688   version_type=sunos
29689   sys_lib_dlsearch_path_spec="/usr/lib"
29690   need_lib_prefix=no
29691   # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
29692   case $host_os in
29693     openbsd3.3 | openbsd3.3.*)  need_version=yes ;;
29694     *)                          need_version=no  ;;
29695   esac
29696   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
29697   finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
29698   shlibpath_var=LD_LIBRARY_PATH
29699   if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
29700     case $host_os in
29701       openbsd2.[89] | openbsd2.[89].*)
29702         shlibpath_overrides_runpath=no
29703         ;;
29704       *)
29705         shlibpath_overrides_runpath=yes
29706         ;;
29707       esac
29708   else
29709     shlibpath_overrides_runpath=yes
29710   fi
29711   ;;
29712
29713 os2*)
29714   libname_spec='$name'
29715   shrext_cmds=".dll"
29716   need_lib_prefix=no
29717   library_names_spec='$libname${shared_ext} $libname.a'
29718   dynamic_linker='OS/2 ld.exe'
29719   shlibpath_var=LIBPATH
29720   ;;
29721
29722 osf3* | osf4* | osf5*)
29723   version_type=osf
29724   need_lib_prefix=no
29725   need_version=no
29726   soname_spec='${libname}${release}${shared_ext}$major'
29727   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
29728   shlibpath_var=LD_LIBRARY_PATH
29729   sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
29730   sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
29731   ;;
29732
29733 rdos*)
29734   dynamic_linker=no
29735   ;;
29736
29737 solaris*)
29738   version_type=linux
29739   need_lib_prefix=no
29740   need_version=no
29741   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
29742   soname_spec='${libname}${release}${shared_ext}$major'
29743   shlibpath_var=LD_LIBRARY_PATH
29744   shlibpath_overrides_runpath=yes
29745   hardcode_into_libs=yes
29746   # ldd complains unless libraries are executable
29747   postinstall_cmds='chmod +x $lib'
29748   ;;
29749
29750 sunos4*)
29751   version_type=sunos
29752   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
29753   finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
29754   shlibpath_var=LD_LIBRARY_PATH
29755   shlibpath_overrides_runpath=yes
29756   if test "$with_gnu_ld" = yes; then
29757     need_lib_prefix=no
29758   fi
29759   need_version=yes
29760   ;;
29761
29762 sysv4 | sysv4.3*)
29763   version_type=linux
29764   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
29765   soname_spec='${libname}${release}${shared_ext}$major'
29766   shlibpath_var=LD_LIBRARY_PATH
29767   case $host_vendor in
29768     sni)
29769       shlibpath_overrides_runpath=no
29770       need_lib_prefix=no
29771       runpath_var=LD_RUN_PATH
29772       ;;
29773     siemens)
29774       need_lib_prefix=no
29775       ;;
29776     motorola)
29777       need_lib_prefix=no
29778       need_version=no
29779       shlibpath_overrides_runpath=no
29780       sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
29781       ;;
29782   esac
29783   ;;
29784
29785 sysv4*MP*)
29786   if test -d /usr/nec ;then
29787     version_type=linux
29788     library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
29789     soname_spec='$libname${shared_ext}.$major'
29790     shlibpath_var=LD_LIBRARY_PATH
29791   fi
29792   ;;
29793
29794 sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
29795   version_type=freebsd-elf
29796   need_lib_prefix=no
29797   need_version=no
29798   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
29799   soname_spec='${libname}${release}${shared_ext}$major'
29800   shlibpath_var=LD_LIBRARY_PATH
29801   shlibpath_overrides_runpath=yes
29802   hardcode_into_libs=yes
29803   if test "$with_gnu_ld" = yes; then
29804     sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
29805   else
29806     sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
29807     case $host_os in
29808       sco3.2v5*)
29809         sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
29810         ;;
29811     esac
29812   fi
29813   sys_lib_dlsearch_path_spec='/usr/lib'
29814   ;;
29815
29816 tpf*)
29817   # TPF is a cross-target only.  Preferred cross-host = GNU/Linux.
29818   version_type=linux
29819   need_lib_prefix=no
29820   need_version=no
29821   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
29822   shlibpath_var=LD_LIBRARY_PATH
29823   shlibpath_overrides_runpath=no
29824   hardcode_into_libs=yes
29825   ;;
29826
29827 uts4*)
29828   version_type=linux
29829   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
29830   soname_spec='${libname}${release}${shared_ext}$major'
29831   shlibpath_var=LD_LIBRARY_PATH
29832   ;;
29833
29834 *)
29835   dynamic_linker=no
29836   ;;
29837 esac
29838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
29839 $as_echo "$dynamic_linker" >&6; }
29840 test "$dynamic_linker" = no && can_build_shared=no
29841
29842 variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
29843 if test "$GCC" = yes; then
29844   variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
29845 fi
29846
29847 if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
29848   sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
29849 fi
29850 if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
29851   sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
29852 fi
29853
29854
29855
29856
29857
29858
29859
29860
29861
29862
29863
29864
29865
29866
29867
29868
29869
29870
29871
29872
29873
29874
29875
29876
29877
29878
29879
29880
29881
29882
29883
29884
29885
29886
29887
29888
29889
29890
29891     { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
29892 $as_echo_n "checking how to hardcode library paths into programs... " >&6; }
29893 hardcode_action_CXX=
29894 if test -n "$hardcode_libdir_flag_spec_CXX" ||
29895    test -n "$runpath_var_CXX" ||
29896    test "X$hardcode_automatic_CXX" = "Xyes" ; then
29897
29898   # We can hardcode non-existent directories.
29899   if test "$hardcode_direct_CXX" != no &&
29900      # If the only mechanism to avoid hardcoding is shlibpath_var, we
29901      # have to relink, otherwise we might link with an installed library
29902      # when we should be linking with a yet-to-be-installed one
29903      ## test "$_LT_TAGVAR(hardcode_shlibpath_var, CXX)" != no &&
29904      test "$hardcode_minus_L_CXX" != no; then
29905     # Linking always hardcodes the temporary library directory.
29906     hardcode_action_CXX=relink
29907   else
29908     # We can link without hardcoding, and we can hardcode nonexisting dirs.
29909     hardcode_action_CXX=immediate
29910   fi
29911 else
29912   # We cannot hardcode anything, or else we can only hardcode existing
29913   # directories.
29914   hardcode_action_CXX=unsupported
29915 fi
29916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action_CXX" >&5
29917 $as_echo "$hardcode_action_CXX" >&6; }
29918
29919 if test "$hardcode_action_CXX" = relink ||
29920    test "$inherit_rpath_CXX" = yes; then
29921   # Fast installation is not supported
29922   enable_fast_install=no
29923 elif test "$shlibpath_overrides_runpath" = yes ||
29924      test "$enable_shared" = no; then
29925   # Fast installation is not necessary
29926   enable_fast_install=needless
29927 fi
29928
29929
29930
29931
29932
29933
29934
29935   fi # test -n "$compiler"
29936
29937   CC=$lt_save_CC
29938   CFLAGS=$lt_save_CFLAGS
29939   LDCXX=$LD
29940   LD=$lt_save_LD
29941   GCC=$lt_save_GCC
29942   with_gnu_ld=$lt_save_with_gnu_ld
29943   lt_cv_path_LDCXX=$lt_cv_path_LD
29944   lt_cv_path_LD=$lt_save_path_LD
29945   lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
29946   lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
29947 fi # test "$_lt_caught_CXX_error" != yes
29948
29949 ac_ext=c
29950 ac_cpp='$CPP $CPPFLAGS'
29951 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
29952 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
29953 ac_compiler_gnu=$ac_cv_c_compiler_gnu
29954
29955
29956
29957 gta=false
29958
29959 # Check whether --with-gtest was given.
29960 if test "${with_gtest+set}" = set; then :
29961   withval=$with_gtest; try_gtest=$withval
29962 else
29963   try_gtest=yes
29964
29965 fi
29966
29967 case "$try_gtest" in
29968  yes)
29969     # Extract the first word of "gtest-config", so it can be a program name with args.
29970 set dummy gtest-config; ac_word=$2
29971 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29972 $as_echo_n "checking for $ac_word... " >&6; }
29973 if ${ac_cv_path_GTEST_CONFIG+:} false; then :
29974   $as_echo_n "(cached) " >&6
29975 else
29976   case $GTEST_CONFIG in
29977   [\\/]* | ?:[\\/]*)
29978   ac_cv_path_GTEST_CONFIG="$GTEST_CONFIG" # Let the user override the test with a path.
29979   ;;
29980   *)
29981   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29982 for as_dir in $PATH
29983 do
29984   IFS=$as_save_IFS
29985   test -z "$as_dir" && as_dir=.
29986     for ac_exec_ext in '' $ac_executable_extensions; do
29987   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
29988     ac_cv_path_GTEST_CONFIG="$as_dir/$ac_word$ac_exec_ext"
29989     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29990     break 2
29991   fi
29992 done
29993   done
29994 IFS=$as_save_IFS
29995
29996   ;;
29997 esac
29998 fi
29999 GTEST_CONFIG=$ac_cv_path_GTEST_CONFIG
30000 if test -n "$GTEST_CONFIG"; then
30001   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTEST_CONFIG" >&5
30002 $as_echo "$GTEST_CONFIG" >&6; }
30003 else
30004   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
30005 $as_echo "no" >&6; }
30006 fi
30007
30008
30009     { ac_cv_path_GTEST_CONFIG=; unset ac_cv_path_GTEST_CONFIG;}
30010     case x${GTEST_CONFIG} in
30011      x) ;;
30012      *)
30013         { $as_echo "$as_me:${as_lineno-$LINENO}: checking gtest version" >&5
30014 $as_echo_n "checking gtest version... " >&6; }
30015         gtest_version_test=`$GTEST_CONFIG --min-version=1.5 || echo toolow`
30016         case "$gtest_version_test" in
30017          toolow*)
30018             ;;
30019          *)
30020             GTEST_LDFLAGS=`$GTEST_CONFIG --ldflags`
30021             GTEST_LIBS=`$GTEST_CONFIG --libs`
30022             GTEST_CXXFLAGS=`$GTEST_CONFIG --cxxflags`
30023             GTEST_CPPFLAGS=`$GTEST_CONFIG --cppflags`
30024
30025
30026
30027
30028             gta=true
30029             ;;
30030         esac
30031         gtest_version=`$GTEST_CONFIG --version`
30032         case "$gta" in
30033          true)
30034             { $as_echo "$as_me:${as_lineno-$LINENO}: result: ($gtest_version) ok" >&5
30035 $as_echo "($gtest_version) ok" >&6; }
30036             ;;
30037          *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: ($gtest_version) not ok" >&5
30038 $as_echo "($gtest_version) not ok" >&6; }
30039             ;;
30040         esac
30041         { gtest_version_test=; unset gtest_version_test;}
30042         { gtest_version=; unset gtest_version;}
30043     esac
30044 esac
30045  if $gta; then
30046   GTEST_AVAILABLE_TRUE=
30047   GTEST_AVAILABLE_FALSE='#'
30048 else
30049   GTEST_AVAILABLE_TRUE='#'
30050   GTEST_AVAILABLE_FALSE=
30051 fi
30052
30053
30054
30055
30056 # All libraries should be in various LIB_* variables now.
30057 #LIBS=
30058 # Sadly not.  There is a gettext() check somewhere, and on Solaris this pulls
30059 # in -lintl -lgen, outside our "scope".
30060
30061 ac_config_files="$ac_config_files Makefile"
30062
30063 ac_config_files="$ac_config_files include/Makefile"
30064
30065 ac_config_files="$ac_config_files scripts/Makefile"
30066
30067 ac_config_files="$ac_config_files tests/Makefile"
30068
30069
30070 cat >confcache <<\_ACEOF
30071 # This file is a shell script that caches the results of configure
30072 # tests run on this system so they can be shared between configure
30073 # scripts and configure runs, see configure's option --config-cache.
30074 # It is not useful on other systems.  If it contains results you don't
30075 # want to keep, you may remove or edit it.
30076 #
30077 # config.status only pays attention to the cache file if you give it
30078 # the --recheck option to rerun configure.
30079 #
30080 # `ac_cv_env_foo' variables (set or unset) will be overridden when
30081 # loading this file, other *unset* `ac_cv_foo' will be assigned the
30082 # following values.
30083
30084 _ACEOF
30085
30086 # The following way of writing the cache mishandles newlines in values,
30087 # but we know of no workaround that is simple, portable, and efficient.
30088 # So, we kill variables containing newlines.
30089 # Ultrix sh set writes to stderr and can't be redirected directly,
30090 # and sets the high bit in the cache file unless we assign to the vars.
30091 (
30092   for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
30093     eval ac_val=\$$ac_var
30094     case $ac_val in #(
30095     *${as_nl}*)
30096       case $ac_var in #(
30097       *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
30098 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
30099       esac
30100       case $ac_var in #(
30101       _ | IFS | as_nl) ;; #(
30102       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
30103       *) { eval $ac_var=; unset $ac_var;} ;;
30104       esac ;;
30105     esac
30106   done
30107
30108   (set) 2>&1 |
30109     case $as_nl`(ac_space=' '; set) 2>&1` in #(
30110     *${as_nl}ac_space=\ *)
30111       # `set' does not quote correctly, so add quotes: double-quote
30112       # substitution turns \\\\ into \\, and sed turns \\ into \.
30113       sed -n \
30114         "s/'/'\\\\''/g;
30115           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
30116       ;; #(
30117     *)
30118       # `set' quotes correctly as required by POSIX, so do not add quotes.
30119       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
30120       ;;
30121     esac |
30122     sort
30123 ) |
30124   sed '
30125      /^ac_cv_env_/b end
30126      t clear
30127      :clear
30128      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
30129      t end
30130      s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
30131      :end' >>confcache
30132 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
30133   if test -w "$cache_file"; then
30134     if test "x$cache_file" != "x/dev/null"; then
30135       { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
30136 $as_echo "$as_me: updating cache $cache_file" >&6;}
30137       if test ! -f "$cache_file" || test -h "$cache_file"; then
30138         cat confcache >"$cache_file"
30139       else
30140         case $cache_file in #(
30141         */* | ?:*)
30142           mv -f confcache "$cache_file"$$ &&
30143           mv -f "$cache_file"$$ "$cache_file" ;; #(
30144         *)
30145           mv -f confcache "$cache_file" ;;
30146         esac
30147       fi
30148     fi
30149   else
30150     { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
30151 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
30152   fi
30153 fi
30154 rm -f confcache
30155
30156 test "x$prefix" = xNONE && prefix=$ac_default_prefix
30157 # Let make expand exec_prefix.
30158 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
30159
30160 DEFS=-DHAVE_CONFIG_H
30161
30162 ac_libobjs=
30163 ac_ltlibobjs=
30164 U=
30165 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
30166   # 1. Remove the extension, and $U if already installed.
30167   ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
30168   ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
30169   # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
30170   #    will be set to the directory where LIBOBJS objects are built.
30171   as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
30172   as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
30173 done
30174 LIBOBJS=$ac_libobjs
30175
30176 LTLIBOBJS=$ac_ltlibobjs
30177
30178
30179  if test -n "$EXEEXT"; then
30180   am__EXEEXT_TRUE=
30181   am__EXEEXT_FALSE='#'
30182 else
30183   am__EXEEXT_TRUE='#'
30184   am__EXEEXT_FALSE=
30185 fi
30186
30187 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
30188   as_fn_error $? "conditional \"AMDEP\" was never defined.
30189 Usually this means the macro was only invoked conditionally." "$LINENO" 5
30190 fi
30191 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
30192   as_fn_error $? "conditional \"am__fastdepCC\" was never defined.
30193 Usually this means the macro was only invoked conditionally." "$LINENO" 5
30194 fi
30195 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
30196   as_fn_error $? "conditional \"am__fastdepCC\" was never defined.
30197 Usually this means the macro was only invoked conditionally." "$LINENO" 5
30198 fi
30199
30200 if test -z "${WANT_CALC_TICKADJ_MS_TRUE}" && test -z "${WANT_CALC_TICKADJ_MS_FALSE}"; then
30201   as_fn_error $? "conditional \"WANT_CALC_TICKADJ_MS\" was never defined.
30202 Usually this means the macro was only invoked conditionally." "$LINENO" 5
30203 fi
30204 if test -z "${INSTALL_NTPSWEEP_TRUE}" && test -z "${INSTALL_NTPSWEEP_FALSE}"; then
30205   as_fn_error $? "conditional \"INSTALL_NTPSWEEP\" was never defined.
30206 Usually this means the macro was only invoked conditionally." "$LINENO" 5
30207 fi
30208 if test -z "${INSTALL_UPDATE_LEAP_TRUE}" && test -z "${INSTALL_UPDATE_LEAP_FALSE}"; then
30209   as_fn_error $? "conditional \"INSTALL_UPDATE_LEAP\" was never defined.
30210 Usually this means the macro was only invoked conditionally." "$LINENO" 5
30211 fi
30212 if test -z "${NTP_CROSSCOMPILE_TRUE}" && test -z "${NTP_CROSSCOMPILE_FALSE}"; then
30213   as_fn_error $? "conditional \"NTP_CROSSCOMPILE\" was never defined.
30214 Usually this means the macro was only invoked conditionally." "$LINENO" 5
30215 fi
30216 if test -z "${PTHREADS_TRUE}" && test -z "${PTHREADS_FALSE}"; then
30217   as_fn_error $? "conditional \"PTHREADS\" was never defined.
30218 Usually this means the macro was only invoked conditionally." "$LINENO" 5
30219 fi
30220 if test -z "${BUILD_SNTP_TRUE}" && test -z "${BUILD_SNTP_FALSE}"; then
30221   as_fn_error $? "conditional \"BUILD_SNTP\" was never defined.
30222 Usually this means the macro was only invoked conditionally." "$LINENO" 5
30223 fi
30224 if test -z "${GL_GENERATE_STDNORETURN_H_TRUE}" && test -z "${GL_GENERATE_STDNORETURN_H_FALSE}"; then
30225   as_fn_error $? "conditional \"GL_GENERATE_STDNORETURN_H\" was never defined.
30226 Usually this means the macro was only invoked conditionally." "$LINENO" 5
30227 fi
30228 if test -z "${INSTALL_LIBOPTS_TRUE}" && test -z "${INSTALL_LIBOPTS_FALSE}"; then
30229   as_fn_error $? "conditional \"INSTALL_LIBOPTS\" was never defined.
30230 Usually this means the macro was only invoked conditionally." "$LINENO" 5
30231 fi
30232 if test -z "${NEED_LIBOPTS_TRUE}" && test -z "${NEED_LIBOPTS_FALSE}"; then
30233   as_fn_error $? "conditional \"NEED_LIBOPTS\" was never defined.
30234 Usually this means the macro was only invoked conditionally." "$LINENO" 5
30235 fi
30236 if test -z "${BUILD_LIBEVENT_TRUE}" && test -z "${BUILD_LIBEVENT_FALSE}"; then
30237   as_fn_error $? "conditional \"BUILD_LIBEVENT\" was never defined.
30238 Usually this means the macro was only invoked conditionally." "$LINENO" 5
30239 fi
30240 if test -z "${am__fastdepCXX_TRUE}" && test -z "${am__fastdepCXX_FALSE}"; then
30241   as_fn_error $? "conditional \"am__fastdepCXX\" was never defined.
30242 Usually this means the macro was only invoked conditionally." "$LINENO" 5
30243 fi
30244 if test -z "${GTEST_AVAILABLE_TRUE}" && test -z "${GTEST_AVAILABLE_FALSE}"; then
30245   as_fn_error $? "conditional \"GTEST_AVAILABLE\" was never defined.
30246 Usually this means the macro was only invoked conditionally." "$LINENO" 5
30247 fi
30248
30249 : "${CONFIG_STATUS=./config.status}"
30250 ac_write_fail=0
30251 ac_clean_files_save=$ac_clean_files
30252 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
30253 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
30254 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
30255 as_write_fail=0
30256 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
30257 #! $SHELL
30258 # Generated by $as_me.
30259 # Run this file to recreate the current configuration.
30260 # Compiler output produced by configure, useful for debugging
30261 # configure, is in config.log if it exists.
30262
30263 debug=false
30264 ac_cs_recheck=false
30265 ac_cs_silent=false
30266
30267 SHELL=\${CONFIG_SHELL-$SHELL}
30268 export SHELL
30269 _ASEOF
30270 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
30271 ## -------------------- ##
30272 ## M4sh Initialization. ##
30273 ## -------------------- ##
30274
30275 # Be more Bourne compatible
30276 DUALCASE=1; export DUALCASE # for MKS sh
30277 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
30278   emulate sh
30279   NULLCMD=:
30280   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
30281   # is contrary to our usage.  Disable this feature.
30282   alias -g '${1+"$@"}'='"$@"'
30283   setopt NO_GLOB_SUBST
30284 else
30285   case `(set -o) 2>/dev/null` in #(
30286   *posix*) :
30287     set -o posix ;; #(
30288   *) :
30289      ;;
30290 esac
30291 fi
30292
30293
30294 as_nl='
30295 '
30296 export as_nl
30297 # Printing a long string crashes Solaris 7 /usr/bin/printf.
30298 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
30299 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
30300 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
30301 # Prefer a ksh shell builtin over an external printf program on Solaris,
30302 # but without wasting forks for bash or zsh.
30303 if test -z "$BASH_VERSION$ZSH_VERSION" \
30304     && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
30305   as_echo='print -r --'
30306   as_echo_n='print -rn --'
30307 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
30308   as_echo='printf %s\n'
30309   as_echo_n='printf %s'
30310 else
30311   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
30312     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
30313     as_echo_n='/usr/ucb/echo -n'
30314   else
30315     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
30316     as_echo_n_body='eval
30317       arg=$1;
30318       case $arg in #(
30319       *"$as_nl"*)
30320         expr "X$arg" : "X\\(.*\\)$as_nl";
30321         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
30322       esac;
30323       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
30324     '
30325     export as_echo_n_body
30326     as_echo_n='sh -c $as_echo_n_body as_echo'
30327   fi
30328   export as_echo_body
30329   as_echo='sh -c $as_echo_body as_echo'
30330 fi
30331
30332 # The user is always right.
30333 if test "${PATH_SEPARATOR+set}" != set; then
30334   PATH_SEPARATOR=:
30335   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
30336     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
30337       PATH_SEPARATOR=';'
30338   }
30339 fi
30340
30341
30342 # IFS
30343 # We need space, tab and new line, in precisely that order.  Quoting is
30344 # there to prevent editors from complaining about space-tab.
30345 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
30346 # splitting by setting IFS to empty value.)
30347 IFS=" ""        $as_nl"
30348
30349 # Find who we are.  Look in the path if we contain no directory separator.
30350 as_myself=
30351 case $0 in #((
30352   *[\\/]* ) as_myself=$0 ;;
30353   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
30354 for as_dir in $PATH
30355 do
30356   IFS=$as_save_IFS
30357   test -z "$as_dir" && as_dir=.
30358     test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
30359   done
30360 IFS=$as_save_IFS
30361
30362      ;;
30363 esac
30364 # We did not find ourselves, most probably we were run as `sh COMMAND'
30365 # in which case we are not to be found in the path.
30366 if test "x$as_myself" = x; then
30367   as_myself=$0
30368 fi
30369 if test ! -f "$as_myself"; then
30370   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
30371   exit 1
30372 fi
30373
30374 # Unset variables that we do not need and which cause bugs (e.g. in
30375 # pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
30376 # suppresses any "Segmentation fault" message there.  '((' could
30377 # trigger a bug in pdksh 5.2.14.
30378 for as_var in BASH_ENV ENV MAIL MAILPATH
30379 do eval test x\${$as_var+set} = xset \
30380   && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
30381 done
30382 PS1='$ '
30383 PS2='> '
30384 PS4='+ '
30385
30386 # NLS nuisances.
30387 LC_ALL=C
30388 export LC_ALL
30389 LANGUAGE=C
30390 export LANGUAGE
30391
30392 # CDPATH.
30393 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
30394
30395
30396 # as_fn_error STATUS ERROR [LINENO LOG_FD]
30397 # ----------------------------------------
30398 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
30399 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
30400 # script with STATUS, using 1 if that was 0.
30401 as_fn_error ()
30402 {
30403   as_status=$1; test $as_status -eq 0 && as_status=1
30404   if test "$4"; then
30405     as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
30406     $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
30407   fi
30408   $as_echo "$as_me: error: $2" >&2
30409   as_fn_exit $as_status
30410 } # as_fn_error
30411
30412
30413 # as_fn_set_status STATUS
30414 # -----------------------
30415 # Set $? to STATUS, without forking.
30416 as_fn_set_status ()
30417 {
30418   return $1
30419 } # as_fn_set_status
30420
30421 # as_fn_exit STATUS
30422 # -----------------
30423 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
30424 as_fn_exit ()
30425 {
30426   set +e
30427   as_fn_set_status $1
30428   exit $1
30429 } # as_fn_exit
30430
30431 # as_fn_unset VAR
30432 # ---------------
30433 # Portably unset VAR.
30434 as_fn_unset ()
30435 {
30436   { eval $1=; unset $1;}
30437 }
30438 as_unset=as_fn_unset
30439 # as_fn_append VAR VALUE
30440 # ----------------------
30441 # Append the text in VALUE to the end of the definition contained in VAR. Take
30442 # advantage of any shell optimizations that allow amortized linear growth over
30443 # repeated appends, instead of the typical quadratic growth present in naive
30444 # implementations.
30445 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
30446   eval 'as_fn_append ()
30447   {
30448     eval $1+=\$2
30449   }'
30450 else
30451   as_fn_append ()
30452   {
30453     eval $1=\$$1\$2
30454   }
30455 fi # as_fn_append
30456
30457 # as_fn_arith ARG...
30458 # ------------------
30459 # Perform arithmetic evaluation on the ARGs, and store the result in the
30460 # global $as_val. Take advantage of shells that can avoid forks. The arguments
30461 # must be portable across $(()) and expr.
30462 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
30463   eval 'as_fn_arith ()
30464   {
30465     as_val=$(( $* ))
30466   }'
30467 else
30468   as_fn_arith ()
30469   {
30470     as_val=`expr "$@" || test $? -eq 1`
30471   }
30472 fi # as_fn_arith
30473
30474
30475 if expr a : '\(a\)' >/dev/null 2>&1 &&
30476    test "X`expr 00001 : '.*\(...\)'`" = X001; then
30477   as_expr=expr
30478 else
30479   as_expr=false
30480 fi
30481
30482 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
30483   as_basename=basename
30484 else
30485   as_basename=false
30486 fi
30487
30488 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
30489   as_dirname=dirname
30490 else
30491   as_dirname=false
30492 fi
30493
30494 as_me=`$as_basename -- "$0" ||
30495 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
30496          X"$0" : 'X\(//\)$' \| \
30497          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
30498 $as_echo X/"$0" |
30499     sed '/^.*\/\([^/][^/]*\)\/*$/{
30500             s//\1/
30501             q
30502           }
30503           /^X\/\(\/\/\)$/{
30504             s//\1/
30505             q
30506           }
30507           /^X\/\(\/\).*/{
30508             s//\1/
30509             q
30510           }
30511           s/.*/./; q'`
30512
30513 # Avoid depending upon Character Ranges.
30514 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
30515 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
30516 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
30517 as_cr_digits='0123456789'
30518 as_cr_alnum=$as_cr_Letters$as_cr_digits
30519
30520 ECHO_C= ECHO_N= ECHO_T=
30521 case `echo -n x` in #(((((
30522 -n*)
30523   case `echo 'xy\c'` in
30524   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
30525   xy)  ECHO_C='\c';;
30526   *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
30527        ECHO_T=' ';;
30528   esac;;
30529 *)
30530   ECHO_N='-n';;
30531 esac
30532
30533 rm -f conf$$ conf$$.exe conf$$.file
30534 if test -d conf$$.dir; then
30535   rm -f conf$$.dir/conf$$.file
30536 else
30537   rm -f conf$$.dir
30538   mkdir conf$$.dir 2>/dev/null
30539 fi
30540 if (echo >conf$$.file) 2>/dev/null; then
30541   if ln -s conf$$.file conf$$ 2>/dev/null; then
30542     as_ln_s='ln -s'
30543     # ... but there are two gotchas:
30544     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
30545     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
30546     # In both cases, we have to default to `cp -p'.
30547     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
30548       as_ln_s='cp -p'
30549   elif ln conf$$.file conf$$ 2>/dev/null; then
30550     as_ln_s=ln
30551   else
30552     as_ln_s='cp -p'
30553   fi
30554 else
30555   as_ln_s='cp -p'
30556 fi
30557 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
30558 rmdir conf$$.dir 2>/dev/null
30559
30560
30561 # as_fn_mkdir_p
30562 # -------------
30563 # Create "$as_dir" as a directory, including parents if necessary.
30564 as_fn_mkdir_p ()
30565 {
30566
30567   case $as_dir in #(
30568   -*) as_dir=./$as_dir;;
30569   esac
30570   test -d "$as_dir" || eval $as_mkdir_p || {
30571     as_dirs=
30572     while :; do
30573       case $as_dir in #(
30574       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
30575       *) as_qdir=$as_dir;;
30576       esac
30577       as_dirs="'$as_qdir' $as_dirs"
30578       as_dir=`$as_dirname -- "$as_dir" ||
30579 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30580          X"$as_dir" : 'X\(//\)[^/]' \| \
30581          X"$as_dir" : 'X\(//\)$' \| \
30582          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
30583 $as_echo X"$as_dir" |
30584     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30585             s//\1/
30586             q
30587           }
30588           /^X\(\/\/\)[^/].*/{
30589             s//\1/
30590             q
30591           }
30592           /^X\(\/\/\)$/{
30593             s//\1/
30594             q
30595           }
30596           /^X\(\/\).*/{
30597             s//\1/
30598             q
30599           }
30600           s/.*/./; q'`
30601       test -d "$as_dir" && break
30602     done
30603     test -z "$as_dirs" || eval "mkdir $as_dirs"
30604   } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
30605
30606
30607 } # as_fn_mkdir_p
30608 if mkdir -p . 2>/dev/null; then
30609   as_mkdir_p='mkdir -p "$as_dir"'
30610 else
30611   test -d ./-p && rmdir ./-p
30612   as_mkdir_p=false
30613 fi
30614
30615 if test -x / >/dev/null 2>&1; then
30616   as_test_x='test -x'
30617 else
30618   if ls -dL / >/dev/null 2>&1; then
30619     as_ls_L_option=L
30620   else
30621     as_ls_L_option=
30622   fi
30623   as_test_x='
30624     eval sh -c '\''
30625       if test -d "$1"; then
30626         test -d "$1/.";
30627       else
30628         case $1 in #(
30629         -*)set "./$1";;
30630         esac;
30631         case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
30632         ???[sx]*):;;*)false;;esac;fi
30633     '\'' sh
30634   '
30635 fi
30636 as_executable_p=$as_test_x
30637
30638 # Sed expression to map a string onto a valid CPP name.
30639 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
30640
30641 # Sed expression to map a string onto a valid variable name.
30642 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
30643
30644
30645 exec 6>&1
30646 ## ----------------------------------- ##
30647 ## Main body of $CONFIG_STATUS script. ##
30648 ## ----------------------------------- ##
30649 _ASEOF
30650 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
30651
30652 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30653 # Save the log message, to keep $0 and so on meaningful, and to
30654 # report actual input values of CONFIG_FILES etc. instead of their
30655 # values after options handling.
30656 ac_log="
30657 This file was extended by sntp $as_me 4.2.8p2, which was
30658 generated by GNU Autoconf 2.68.  Invocation command line was
30659
30660   CONFIG_FILES    = $CONFIG_FILES
30661   CONFIG_HEADERS  = $CONFIG_HEADERS
30662   CONFIG_LINKS    = $CONFIG_LINKS
30663   CONFIG_COMMANDS = $CONFIG_COMMANDS
30664   $ $0 $@
30665
30666 on `(hostname || uname -n) 2>/dev/null | sed 1q`
30667 "
30668
30669 _ACEOF
30670
30671 case $ac_config_files in *"
30672 "*) set x $ac_config_files; shift; ac_config_files=$*;;
30673 esac
30674
30675 case $ac_config_headers in *"
30676 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
30677 esac
30678
30679
30680 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30681 # Files that config.status was made for.
30682 config_files="$ac_config_files"
30683 config_headers="$ac_config_headers"
30684 config_commands="$ac_config_commands"
30685
30686 _ACEOF
30687
30688 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30689 ac_cs_usage="\
30690 \`$as_me' instantiates files and other configuration actions
30691 from templates according to the current configuration.  Unless the files
30692 and actions are specified as TAGs, all are instantiated by default.
30693
30694 Usage: $0 [OPTION]... [TAG]...
30695
30696   -h, --help       print this help, then exit
30697   -V, --version    print version number and configuration settings, then exit
30698       --config     print configuration, then exit
30699   -q, --quiet, --silent
30700                    do not print progress messages
30701   -d, --debug      don't remove temporary files
30702       --recheck    update $as_me by reconfiguring in the same conditions
30703       --file=FILE[:TEMPLATE]
30704                    instantiate the configuration file FILE
30705       --header=FILE[:TEMPLATE]
30706                    instantiate the configuration header FILE
30707
30708 Configuration files:
30709 $config_files
30710
30711 Configuration headers:
30712 $config_headers
30713
30714 Configuration commands:
30715 $config_commands
30716
30717 Report bugs to <http://bugs.ntp.org./>.
30718 sntp home page: <http://www.ntp.org./>."
30719
30720 _ACEOF
30721 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30722 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
30723 ac_cs_version="\\
30724 sntp config.status 4.2.8p2
30725 configured by $0, generated by GNU Autoconf 2.68,
30726   with options \\"\$ac_cs_config\\"
30727
30728 Copyright (C) 2010 Free Software Foundation, Inc.
30729 This config.status script is free software; the Free Software Foundation
30730 gives unlimited permission to copy, distribute and modify it."
30731
30732 ac_pwd='$ac_pwd'
30733 srcdir='$srcdir'
30734 INSTALL='$INSTALL'
30735 MKDIR_P='$MKDIR_P'
30736 AWK='$AWK'
30737 test -n "\$AWK" || AWK=awk
30738 _ACEOF
30739
30740 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30741 # The default lists apply if the user does not specify any file.
30742 ac_need_defaults=:
30743 while test $# != 0
30744 do
30745   case $1 in
30746   --*=?*)
30747     ac_option=`expr "X$1" : 'X\([^=]*\)='`
30748     ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
30749     ac_shift=:
30750     ;;
30751   --*=)
30752     ac_option=`expr "X$1" : 'X\([^=]*\)='`
30753     ac_optarg=
30754     ac_shift=:
30755     ;;
30756   *)
30757     ac_option=$1
30758     ac_optarg=$2
30759     ac_shift=shift
30760     ;;
30761   esac
30762
30763   case $ac_option in
30764   # Handling of the options.
30765   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
30766     ac_cs_recheck=: ;;
30767   --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
30768     $as_echo "$ac_cs_version"; exit ;;
30769   --config | --confi | --conf | --con | --co | --c )
30770     $as_echo "$ac_cs_config"; exit ;;
30771   --debug | --debu | --deb | --de | --d | -d )
30772     debug=: ;;
30773   --file | --fil | --fi | --f )
30774     $ac_shift
30775     case $ac_optarg in
30776     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
30777     '') as_fn_error $? "missing file argument" ;;
30778     esac
30779     as_fn_append CONFIG_FILES " '$ac_optarg'"
30780     ac_need_defaults=false;;
30781   --header | --heade | --head | --hea )
30782     $ac_shift
30783     case $ac_optarg in
30784     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
30785     esac
30786     as_fn_append CONFIG_HEADERS " '$ac_optarg'"
30787     ac_need_defaults=false;;
30788   --he | --h)
30789     # Conflict between --help and --header
30790     as_fn_error $? "ambiguous option: \`$1'
30791 Try \`$0 --help' for more information.";;
30792   --help | --hel | -h )
30793     $as_echo "$ac_cs_usage"; exit ;;
30794   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
30795   | -silent | --silent | --silen | --sile | --sil | --si | --s)
30796     ac_cs_silent=: ;;
30797
30798   # This is an error.
30799   -*) as_fn_error $? "unrecognized option: \`$1'
30800 Try \`$0 --help' for more information." ;;
30801
30802   *) as_fn_append ac_config_targets " $1"
30803      ac_need_defaults=false ;;
30804
30805   esac
30806   shift
30807 done
30808
30809 ac_configure_extra_args=
30810
30811 if $ac_cs_silent; then
30812   exec 6>/dev/null
30813   ac_configure_extra_args="$ac_configure_extra_args --silent"
30814 fi
30815
30816 _ACEOF
30817 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30818 if \$ac_cs_recheck; then
30819   set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
30820   shift
30821   \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
30822   CONFIG_SHELL='$SHELL'
30823   export CONFIG_SHELL
30824   exec "\$@"
30825 fi
30826
30827 _ACEOF
30828 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30829 exec 5>>config.log
30830 {
30831   echo
30832   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
30833 ## Running $as_me. ##
30834 _ASBOX
30835   $as_echo "$ac_log"
30836 } >&5
30837
30838 _ACEOF
30839 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30840 #
30841 # INIT-COMMANDS
30842 #
30843 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
30844
30845
30846 # The HP-UX ksh and POSIX shell print the target directory to stdout
30847 # if CDPATH is set.
30848 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
30849
30850 sed_quote_subst='$sed_quote_subst'
30851 double_quote_subst='$double_quote_subst'
30852 delay_variable_subst='$delay_variable_subst'
30853 SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`'
30854 Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`'
30855 GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`'
30856 EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`'
30857 FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`'
30858 SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`'
30859 ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`'
30860 LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`'
30861 enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`'
30862 macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`'
30863 macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`'
30864 enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`'
30865 pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`'
30866 enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`'
30867 host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`'
30868 host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`'
30869 host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`'
30870 build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`'
30871 build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`'
30872 build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`'
30873 NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`'
30874 LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`'
30875 max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`'
30876 ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`'
30877 exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
30878 lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
30879 lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
30880 lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
30881 lt_cv_to_host_file_cmd='`$ECHO "$lt_cv_to_host_file_cmd" | $SED "$delay_single_quote_subst"`'
30882 lt_cv_to_tool_file_cmd='`$ECHO "$lt_cv_to_tool_file_cmd" | $SED "$delay_single_quote_subst"`'
30883 reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`'
30884 reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`'
30885 OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`'
30886 deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`'
30887 file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`'
30888 file_magic_glob='`$ECHO "$file_magic_glob" | $SED "$delay_single_quote_subst"`'
30889 want_nocaseglob='`$ECHO "$want_nocaseglob" | $SED "$delay_single_quote_subst"`'
30890 DLLTOOL='`$ECHO "$DLLTOOL" | $SED "$delay_single_quote_subst"`'
30891 sharedlib_from_linklib_cmd='`$ECHO "$sharedlib_from_linklib_cmd" | $SED "$delay_single_quote_subst"`'
30892 AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`'
30893 AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`'
30894 archiver_list_spec='`$ECHO "$archiver_list_spec" | $SED "$delay_single_quote_subst"`'
30895 STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
30896 RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
30897 old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
30898 old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
30899 old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`'
30900 lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`'
30901 CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`'
30902 CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`'
30903 compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`'
30904 GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`'
30905 lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`'
30906 lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
30907 lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
30908 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"`'
30909 nm_file_list_spec='`$ECHO "$nm_file_list_spec" | $SED "$delay_single_quote_subst"`'
30910 lt_sysroot='`$ECHO "$lt_sysroot" | $SED "$delay_single_quote_subst"`'
30911 objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`'
30912 MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`'
30913 lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`'
30914 lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`'
30915 lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
30916 lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`'
30917 lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`'
30918 need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`'
30919 MANIFEST_TOOL='`$ECHO "$MANIFEST_TOOL" | $SED "$delay_single_quote_subst"`'
30920 DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
30921 NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
30922 LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
30923 OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`'
30924 OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`'
30925 libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`'
30926 shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`'
30927 extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
30928 archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`'
30929 enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`'
30930 export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`'
30931 whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`'
30932 compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`'
30933 old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`'
30934 old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
30935 archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`'
30936 archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`'
30937 module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`'
30938 module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`'
30939 with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`'
30940 allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`'
30941 no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`'
30942 hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`'
30943 hardcode_libdir_flag_spec_ld='`$ECHO "$hardcode_libdir_flag_spec_ld" | $SED "$delay_single_quote_subst"`'
30944 hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`'
30945 hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`'
30946 hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`'
30947 hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`'
30948 hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`'
30949 hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
30950 inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
30951 link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
30952 always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`'
30953 export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`'
30954 exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`'
30955 include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`'
30956 prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`'
30957 postlink_cmds='`$ECHO "$postlink_cmds" | $SED "$delay_single_quote_subst"`'
30958 file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
30959 variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
30960 need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
30961 need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`'
30962 version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`'
30963 runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`'
30964 shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`'
30965 shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`'
30966 libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`'
30967 library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`'
30968 soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`'
30969 install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`'
30970 postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`'
30971 postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
30972 finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`'
30973 finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`'
30974 hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`'
30975 sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`'
30976 sys_lib_dlsearch_path_spec='`$ECHO "$sys_lib_dlsearch_path_spec" | $SED "$delay_single_quote_subst"`'
30977 hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`'
30978 enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`'
30979 enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`'
30980 enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`'
30981 old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`'
30982 striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`'
30983 compiler_lib_search_dirs='`$ECHO "$compiler_lib_search_dirs" | $SED "$delay_single_quote_subst"`'
30984 predep_objects='`$ECHO "$predep_objects" | $SED "$delay_single_quote_subst"`'
30985 postdep_objects='`$ECHO "$postdep_objects" | $SED "$delay_single_quote_subst"`'
30986 predeps='`$ECHO "$predeps" | $SED "$delay_single_quote_subst"`'
30987 postdeps='`$ECHO "$postdeps" | $SED "$delay_single_quote_subst"`'
30988 compiler_lib_search_path='`$ECHO "$compiler_lib_search_path" | $SED "$delay_single_quote_subst"`'
30989 LD_CXX='`$ECHO "$LD_CXX" | $SED "$delay_single_quote_subst"`'
30990 reload_flag_CXX='`$ECHO "$reload_flag_CXX" | $SED "$delay_single_quote_subst"`'
30991 reload_cmds_CXX='`$ECHO "$reload_cmds_CXX" | $SED "$delay_single_quote_subst"`'
30992 old_archive_cmds_CXX='`$ECHO "$old_archive_cmds_CXX" | $SED "$delay_single_quote_subst"`'
30993 compiler_CXX='`$ECHO "$compiler_CXX" | $SED "$delay_single_quote_subst"`'
30994 GCC_CXX='`$ECHO "$GCC_CXX" | $SED "$delay_single_quote_subst"`'
30995 lt_prog_compiler_no_builtin_flag_CXX='`$ECHO "$lt_prog_compiler_no_builtin_flag_CXX" | $SED "$delay_single_quote_subst"`'
30996 lt_prog_compiler_pic_CXX='`$ECHO "$lt_prog_compiler_pic_CXX" | $SED "$delay_single_quote_subst"`'
30997 lt_prog_compiler_wl_CXX='`$ECHO "$lt_prog_compiler_wl_CXX" | $SED "$delay_single_quote_subst"`'
30998 lt_prog_compiler_static_CXX='`$ECHO "$lt_prog_compiler_static_CXX" | $SED "$delay_single_quote_subst"`'
30999 lt_cv_prog_compiler_c_o_CXX='`$ECHO "$lt_cv_prog_compiler_c_o_CXX" | $SED "$delay_single_quote_subst"`'
31000 archive_cmds_need_lc_CXX='`$ECHO "$archive_cmds_need_lc_CXX" | $SED "$delay_single_quote_subst"`'
31001 enable_shared_with_static_runtimes_CXX='`$ECHO "$enable_shared_with_static_runtimes_CXX" | $SED "$delay_single_quote_subst"`'
31002 export_dynamic_flag_spec_CXX='`$ECHO "$export_dynamic_flag_spec_CXX" | $SED "$delay_single_quote_subst"`'
31003 whole_archive_flag_spec_CXX='`$ECHO "$whole_archive_flag_spec_CXX" | $SED "$delay_single_quote_subst"`'
31004 compiler_needs_object_CXX='`$ECHO "$compiler_needs_object_CXX" | $SED "$delay_single_quote_subst"`'
31005 old_archive_from_new_cmds_CXX='`$ECHO "$old_archive_from_new_cmds_CXX" | $SED "$delay_single_quote_subst"`'
31006 old_archive_from_expsyms_cmds_CXX='`$ECHO "$old_archive_from_expsyms_cmds_CXX" | $SED "$delay_single_quote_subst"`'
31007 archive_cmds_CXX='`$ECHO "$archive_cmds_CXX" | $SED "$delay_single_quote_subst"`'
31008 archive_expsym_cmds_CXX='`$ECHO "$archive_expsym_cmds_CXX" | $SED "$delay_single_quote_subst"`'
31009 module_cmds_CXX='`$ECHO "$module_cmds_CXX" | $SED "$delay_single_quote_subst"`'
31010 module_expsym_cmds_CXX='`$ECHO "$module_expsym_cmds_CXX" | $SED "$delay_single_quote_subst"`'
31011 with_gnu_ld_CXX='`$ECHO "$with_gnu_ld_CXX" | $SED "$delay_single_quote_subst"`'
31012 allow_undefined_flag_CXX='`$ECHO "$allow_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`'
31013 no_undefined_flag_CXX='`$ECHO "$no_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`'
31014 hardcode_libdir_flag_spec_CXX='`$ECHO "$hardcode_libdir_flag_spec_CXX" | $SED "$delay_single_quote_subst"`'
31015 hardcode_libdir_flag_spec_ld_CXX='`$ECHO "$hardcode_libdir_flag_spec_ld_CXX" | $SED "$delay_single_quote_subst"`'
31016 hardcode_libdir_separator_CXX='`$ECHO "$hardcode_libdir_separator_CXX" | $SED "$delay_single_quote_subst"`'
31017 hardcode_direct_CXX='`$ECHO "$hardcode_direct_CXX" | $SED "$delay_single_quote_subst"`'
31018 hardcode_direct_absolute_CXX='`$ECHO "$hardcode_direct_absolute_CXX" | $SED "$delay_single_quote_subst"`'
31019 hardcode_minus_L_CXX='`$ECHO "$hardcode_minus_L_CXX" | $SED "$delay_single_quote_subst"`'
31020 hardcode_shlibpath_var_CXX='`$ECHO "$hardcode_shlibpath_var_CXX" | $SED "$delay_single_quote_subst"`'
31021 hardcode_automatic_CXX='`$ECHO "$hardcode_automatic_CXX" | $SED "$delay_single_quote_subst"`'
31022 inherit_rpath_CXX='`$ECHO "$inherit_rpath_CXX" | $SED "$delay_single_quote_subst"`'
31023 link_all_deplibs_CXX='`$ECHO "$link_all_deplibs_CXX" | $SED "$delay_single_quote_subst"`'
31024 always_export_symbols_CXX='`$ECHO "$always_export_symbols_CXX" | $SED "$delay_single_quote_subst"`'
31025 export_symbols_cmds_CXX='`$ECHO "$export_symbols_cmds_CXX" | $SED "$delay_single_quote_subst"`'
31026 exclude_expsyms_CXX='`$ECHO "$exclude_expsyms_CXX" | $SED "$delay_single_quote_subst"`'
31027 include_expsyms_CXX='`$ECHO "$include_expsyms_CXX" | $SED "$delay_single_quote_subst"`'
31028 prelink_cmds_CXX='`$ECHO "$prelink_cmds_CXX" | $SED "$delay_single_quote_subst"`'
31029 postlink_cmds_CXX='`$ECHO "$postlink_cmds_CXX" | $SED "$delay_single_quote_subst"`'
31030 file_list_spec_CXX='`$ECHO "$file_list_spec_CXX" | $SED "$delay_single_quote_subst"`'
31031 hardcode_action_CXX='`$ECHO "$hardcode_action_CXX" | $SED "$delay_single_quote_subst"`'
31032 compiler_lib_search_dirs_CXX='`$ECHO "$compiler_lib_search_dirs_CXX" | $SED "$delay_single_quote_subst"`'
31033 predep_objects_CXX='`$ECHO "$predep_objects_CXX" | $SED "$delay_single_quote_subst"`'
31034 postdep_objects_CXX='`$ECHO "$postdep_objects_CXX" | $SED "$delay_single_quote_subst"`'
31035 predeps_CXX='`$ECHO "$predeps_CXX" | $SED "$delay_single_quote_subst"`'
31036 postdeps_CXX='`$ECHO "$postdeps_CXX" | $SED "$delay_single_quote_subst"`'
31037 compiler_lib_search_path_CXX='`$ECHO "$compiler_lib_search_path_CXX" | $SED "$delay_single_quote_subst"`'
31038
31039 LTCC='$LTCC'
31040 LTCFLAGS='$LTCFLAGS'
31041 compiler='$compiler_DEFAULT'
31042
31043 # A function that is used when there is no print builtin or printf.
31044 func_fallback_echo ()
31045 {
31046   eval 'cat <<_LTECHO_EOF
31047 \$1
31048 _LTECHO_EOF'
31049 }
31050
31051 # Quote evaled strings.
31052 for var in SED \
31053 GREP \
31054 EGREP \
31055 FGREP \
31056 SHELL \
31057 ECHO \
31058 LD \
31059 NM \
31060 LN_S \
31061 lt_SP2NL \
31062 lt_NL2SP \
31063 reload_flag \
31064 OBJDUMP \
31065 deplibs_check_method \
31066 file_magic_cmd \
31067 file_magic_glob \
31068 want_nocaseglob \
31069 DLLTOOL \
31070 sharedlib_from_linklib_cmd \
31071 AR \
31072 AR_FLAGS \
31073 archiver_list_spec \
31074 STRIP \
31075 RANLIB \
31076 CC \
31077 CFLAGS \
31078 compiler \
31079 lt_cv_sys_global_symbol_pipe \
31080 lt_cv_sys_global_symbol_to_cdecl \
31081 lt_cv_sys_global_symbol_to_c_name_address \
31082 lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
31083 nm_file_list_spec \
31084 lt_prog_compiler_no_builtin_flag \
31085 lt_prog_compiler_pic \
31086 lt_prog_compiler_wl \
31087 lt_prog_compiler_static \
31088 lt_cv_prog_compiler_c_o \
31089 need_locks \
31090 MANIFEST_TOOL \
31091 DSYMUTIL \
31092 NMEDIT \
31093 LIPO \
31094 OTOOL \
31095 OTOOL64 \
31096 shrext_cmds \
31097 export_dynamic_flag_spec \
31098 whole_archive_flag_spec \
31099 compiler_needs_object \
31100 with_gnu_ld \
31101 allow_undefined_flag \
31102 no_undefined_flag \
31103 hardcode_libdir_flag_spec \
31104 hardcode_libdir_flag_spec_ld \
31105 hardcode_libdir_separator \
31106 exclude_expsyms \
31107 include_expsyms \
31108 file_list_spec \
31109 variables_saved_for_relink \
31110 libname_spec \
31111 library_names_spec \
31112 soname_spec \
31113 install_override_mode \
31114 finish_eval \
31115 old_striplib \
31116 striplib \
31117 compiler_lib_search_dirs \
31118 predep_objects \
31119 postdep_objects \
31120 predeps \
31121 postdeps \
31122 compiler_lib_search_path \
31123 LD_CXX \
31124 reload_flag_CXX \
31125 compiler_CXX \
31126 lt_prog_compiler_no_builtin_flag_CXX \
31127 lt_prog_compiler_pic_CXX \
31128 lt_prog_compiler_wl_CXX \
31129 lt_prog_compiler_static_CXX \
31130 lt_cv_prog_compiler_c_o_CXX \
31131 export_dynamic_flag_spec_CXX \
31132 whole_archive_flag_spec_CXX \
31133 compiler_needs_object_CXX \
31134 with_gnu_ld_CXX \
31135 allow_undefined_flag_CXX \
31136 no_undefined_flag_CXX \
31137 hardcode_libdir_flag_spec_CXX \
31138 hardcode_libdir_flag_spec_ld_CXX \
31139 hardcode_libdir_separator_CXX \
31140 exclude_expsyms_CXX \
31141 include_expsyms_CXX \
31142 file_list_spec_CXX \
31143 compiler_lib_search_dirs_CXX \
31144 predep_objects_CXX \
31145 postdep_objects_CXX \
31146 predeps_CXX \
31147 postdeps_CXX \
31148 compiler_lib_search_path_CXX; do
31149     case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
31150     *[\\\\\\\`\\"\\\$]*)
31151       eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
31152       ;;
31153     *)
31154       eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
31155       ;;
31156     esac
31157 done
31158
31159 # Double-quote double-evaled strings.
31160 for var in reload_cmds \
31161 old_postinstall_cmds \
31162 old_postuninstall_cmds \
31163 old_archive_cmds \
31164 extract_expsyms_cmds \
31165 old_archive_from_new_cmds \
31166 old_archive_from_expsyms_cmds \
31167 archive_cmds \
31168 archive_expsym_cmds \
31169 module_cmds \
31170 module_expsym_cmds \
31171 export_symbols_cmds \
31172 prelink_cmds \
31173 postlink_cmds \
31174 postinstall_cmds \
31175 postuninstall_cmds \
31176 finish_cmds \
31177 sys_lib_search_path_spec \
31178 sys_lib_dlsearch_path_spec \
31179 reload_cmds_CXX \
31180 old_archive_cmds_CXX \
31181 old_archive_from_new_cmds_CXX \
31182 old_archive_from_expsyms_cmds_CXX \
31183 archive_cmds_CXX \
31184 archive_expsym_cmds_CXX \
31185 module_cmds_CXX \
31186 module_expsym_cmds_CXX \
31187 export_symbols_cmds_CXX \
31188 prelink_cmds_CXX \
31189 postlink_cmds_CXX; do
31190     case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
31191     *[\\\\\\\`\\"\\\$]*)
31192       eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
31193       ;;
31194     *)
31195       eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
31196       ;;
31197     esac
31198 done
31199
31200 ac_aux_dir='$ac_aux_dir'
31201 xsi_shell='$xsi_shell'
31202 lt_shell_append='$lt_shell_append'
31203
31204 # See if we are running on zsh, and set the options which allow our
31205 # commands through without removal of \ escapes INIT.
31206 if test -n "\${ZSH_VERSION+set}" ; then
31207    setopt NO_GLOB_SUBST
31208 fi
31209
31210
31211     PACKAGE='$PACKAGE'
31212     VERSION='$VERSION'
31213     TIMESTAMP='$TIMESTAMP'
31214     RM='$RM'
31215     ofile='$ofile'
31216
31217
31218
31219
31220
31221
31222 _ACEOF
31223
31224 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
31225
31226 # Handling of arguments.
31227 for ac_config_target in $ac_config_targets
31228 do
31229   case $ac_config_target in
31230     "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;;
31231     "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
31232     "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;;
31233     "libopts/Makefile") CONFIG_FILES="$CONFIG_FILES libopts/Makefile" ;;
31234     "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
31235     "include/Makefile") CONFIG_FILES="$CONFIG_FILES include/Makefile" ;;
31236     "scripts/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/Makefile" ;;
31237     "tests/Makefile") CONFIG_FILES="$CONFIG_FILES tests/Makefile" ;;
31238
31239   *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
31240   esac
31241 done
31242
31243
31244 # If the user did not use the arguments to specify the items to instantiate,
31245 # then the envvar interface is used.  Set only those that are not.
31246 # We use the long form for the default assignment because of an extremely
31247 # bizarre bug on SunOS 4.1.3.
31248 if $ac_need_defaults; then
31249   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
31250   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
31251   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
31252 fi
31253
31254 # Have a temporary directory for convenience.  Make it in the build tree
31255 # simply because there is no reason against having it here, and in addition,
31256 # creating and moving files from /tmp can sometimes cause problems.
31257 # Hook for its removal unless debugging.
31258 # Note that there is a small window in which the directory will not be cleaned:
31259 # after its creation but before its name has been assigned to `$tmp'.
31260 $debug ||
31261 {
31262   tmp= ac_tmp=
31263   trap 'exit_status=$?
31264   : "${ac_tmp:=$tmp}"
31265   { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
31266 ' 0
31267   trap 'as_fn_exit 1' 1 2 13 15
31268 }
31269 # Create a (secure) tmp directory for tmp files.
31270
31271 {
31272   tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
31273   test -d "$tmp"
31274 }  ||
31275 {
31276   tmp=./conf$$-$RANDOM
31277   (umask 077 && mkdir "$tmp")
31278 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
31279 ac_tmp=$tmp
31280
31281 # Set up the scripts for CONFIG_FILES section.
31282 # No need to generate them if there are no CONFIG_FILES.
31283 # This happens for instance with `./config.status config.h'.
31284 if test -n "$CONFIG_FILES"; then
31285
31286
31287 ac_cr=`echo X | tr X '\015'`
31288 # On cygwin, bash can eat \r inside `` if the user requested igncr.
31289 # But we know of no other shell where ac_cr would be empty at this
31290 # point, so we can use a bashism as a fallback.
31291 if test "x$ac_cr" = x; then
31292   eval ac_cr=\$\'\\r\'
31293 fi
31294 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
31295 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
31296   ac_cs_awk_cr='\\r'
31297 else
31298   ac_cs_awk_cr=$ac_cr
31299 fi
31300
31301 echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
31302 _ACEOF
31303
31304
31305 {
31306   echo "cat >conf$$subs.awk <<_ACEOF" &&
31307   echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
31308   echo "_ACEOF"
31309 } >conf$$subs.sh ||
31310   as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
31311 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
31312 ac_delim='%!_!# '
31313 for ac_last_try in false false false false false :; do
31314   . ./conf$$subs.sh ||
31315     as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
31316
31317   ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
31318   if test $ac_delim_n = $ac_delim_num; then
31319     break
31320   elif $ac_last_try; then
31321     as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
31322   else
31323     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
31324   fi
31325 done
31326 rm -f conf$$subs.sh
31327
31328 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
31329 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
31330 _ACEOF
31331 sed -n '
31332 h
31333 s/^/S["/; s/!.*/"]=/
31334 p
31335 g
31336 s/^[^!]*!//
31337 :repl
31338 t repl
31339 s/'"$ac_delim"'$//
31340 t delim
31341 :nl
31342 h
31343 s/\(.\{148\}\)..*/\1/
31344 t more1
31345 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
31346 p
31347 n
31348 b repl
31349 :more1
31350 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
31351 p
31352 g
31353 s/.\{148\}//
31354 t nl
31355 :delim
31356 h
31357 s/\(.\{148\}\)..*/\1/
31358 t more2
31359 s/["\\]/\\&/g; s/^/"/; s/$/"/
31360 p
31361 b
31362 :more2
31363 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
31364 p
31365 g
31366 s/.\{148\}//
31367 t delim
31368 ' <conf$$subs.awk | sed '
31369 /^[^""]/{
31370   N
31371   s/\n//
31372 }
31373 ' >>$CONFIG_STATUS || ac_write_fail=1
31374 rm -f conf$$subs.awk
31375 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
31376 _ACAWK
31377 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
31378   for (key in S) S_is_set[key] = 1
31379   FS = "\a"
31380
31381 }
31382 {
31383   line = $ 0
31384   nfields = split(line, field, "@")
31385   substed = 0
31386   len = length(field[1])
31387   for (i = 2; i < nfields; i++) {
31388     key = field[i]
31389     keylen = length(key)
31390     if (S_is_set[key]) {
31391       value = S[key]
31392       line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
31393       len += length(value) + length(field[++i])
31394       substed = 1
31395     } else
31396       len += 1 + keylen
31397   }
31398
31399   print line
31400 }
31401
31402 _ACAWK
31403 _ACEOF
31404 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
31405 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
31406   sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
31407 else
31408   cat
31409 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
31410   || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
31411 _ACEOF
31412
31413 # VPATH may cause trouble with some makes, so we remove sole $(srcdir),
31414 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
31415 # trailing colons and then remove the whole line if VPATH becomes empty
31416 # (actually we leave an empty line to preserve line numbers).
31417 if test "x$srcdir" = x.; then
31418   ac_vpsub='/^[  ]*VPATH[        ]*=[    ]*/{
31419 h
31420 s///
31421 s/^/:/
31422 s/[      ]*$/:/
31423 s/:\$(srcdir):/:/g
31424 s/:\${srcdir}:/:/g
31425 s/:@srcdir@:/:/g
31426 s/^:*//
31427 s/:*$//
31428 x
31429 s/\(=[   ]*\).*/\1/
31430 G
31431 s/\n//
31432 s/^[^=]*=[       ]*$//
31433 }'
31434 fi
31435
31436 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
31437 fi # test -n "$CONFIG_FILES"
31438
31439 # Set up the scripts for CONFIG_HEADERS section.
31440 # No need to generate them if there are no CONFIG_HEADERS.
31441 # This happens for instance with `./config.status Makefile'.
31442 if test -n "$CONFIG_HEADERS"; then
31443 cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
31444 BEGIN {
31445 _ACEOF
31446
31447 # Transform confdefs.h into an awk script `defines.awk', embedded as
31448 # here-document in config.status, that substitutes the proper values into
31449 # config.h.in to produce config.h.
31450
31451 # Create a delimiter string that does not exist in confdefs.h, to ease
31452 # handling of long lines.
31453 ac_delim='%!_!# '
31454 for ac_last_try in false false :; do
31455   ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
31456   if test -z "$ac_tt"; then
31457     break
31458   elif $ac_last_try; then
31459     as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
31460   else
31461     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
31462   fi
31463 done
31464
31465 # For the awk script, D is an array of macro values keyed by name,
31466 # likewise P contains macro parameters if any.  Preserve backslash
31467 # newline sequences.
31468
31469 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
31470 sed -n '
31471 s/.\{148\}/&'"$ac_delim"'/g
31472 t rset
31473 :rset
31474 s/^[     ]*#[    ]*define[       ][      ]*/ /
31475 t def
31476 d
31477 :def
31478 s/\\$//
31479 t bsnl
31480 s/["\\]/\\&/g
31481 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
31482 D["\1"]=" \3"/p
31483 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2"/p
31484 d
31485 :bsnl
31486 s/["\\]/\\&/g
31487 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
31488 D["\1"]=" \3\\\\\\n"\\/p
31489 t cont
31490 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
31491 t cont
31492 d
31493 :cont
31494 n
31495 s/.\{148\}/&'"$ac_delim"'/g
31496 t clear
31497 :clear
31498 s/\\$//
31499 t bsnlc
31500 s/["\\]/\\&/g; s/^/"/; s/$/"/p
31501 d
31502 :bsnlc
31503 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
31504 b cont
31505 ' <confdefs.h | sed '
31506 s/'"$ac_delim"'/"\\\
31507 "/g' >>$CONFIG_STATUS || ac_write_fail=1
31508
31509 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
31510   for (key in D) D_is_set[key] = 1
31511   FS = "\a"
31512 }
31513 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
31514   line = \$ 0
31515   split(line, arg, " ")
31516   if (arg[1] == "#") {
31517     defundef = arg[2]
31518     mac1 = arg[3]
31519   } else {
31520     defundef = substr(arg[1], 2)
31521     mac1 = arg[2]
31522   }
31523   split(mac1, mac2, "(") #)
31524   macro = mac2[1]
31525   prefix = substr(line, 1, index(line, defundef) - 1)
31526   if (D_is_set[macro]) {
31527     # Preserve the white space surrounding the "#".
31528     print prefix "define", macro P[macro] D[macro]
31529     next
31530   } else {
31531     # Replace #undef with comments.  This is necessary, for example,
31532     # in the case of _POSIX_SOURCE, which is predefined and required
31533     # on some systems where configure will not decide to define it.
31534     if (defundef == "undef") {
31535       print "/*", prefix defundef, macro, "*/"
31536       next
31537     }
31538   }
31539 }
31540 { print }
31541 _ACAWK
31542 _ACEOF
31543 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
31544   as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
31545 fi # test -n "$CONFIG_HEADERS"
31546
31547
31548 eval set X "  :F $CONFIG_FILES  :H $CONFIG_HEADERS    :C $CONFIG_COMMANDS"
31549 shift
31550 for ac_tag
31551 do
31552   case $ac_tag in
31553   :[FHLC]) ac_mode=$ac_tag; continue;;
31554   esac
31555   case $ac_mode$ac_tag in
31556   :[FHL]*:*);;
31557   :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
31558   :[FH]-) ac_tag=-:-;;
31559   :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
31560   esac
31561   ac_save_IFS=$IFS
31562   IFS=:
31563   set x $ac_tag
31564   IFS=$ac_save_IFS
31565   shift
31566   ac_file=$1
31567   shift
31568
31569   case $ac_mode in
31570   :L) ac_source=$1;;
31571   :[FH])
31572     ac_file_inputs=
31573     for ac_f
31574     do
31575       case $ac_f in
31576       -) ac_f="$ac_tmp/stdin";;
31577       *) # Look for the file first in the build tree, then in the source tree
31578          # (if the path is not absolute).  The absolute path cannot be DOS-style,
31579          # because $ac_f cannot contain `:'.
31580          test -f "$ac_f" ||
31581            case $ac_f in
31582            [\\/$]*) false;;
31583            *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
31584            esac ||
31585            as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
31586       esac
31587       case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
31588       as_fn_append ac_file_inputs " '$ac_f'"
31589     done
31590
31591     # Let's still pretend it is `configure' which instantiates (i.e., don't
31592     # use $as_me), people would be surprised to read:
31593     #    /* config.h.  Generated by config.status.  */
31594     configure_input='Generated from '`
31595           $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
31596         `' by configure.'
31597     if test x"$ac_file" != x-; then
31598       configure_input="$ac_file.  $configure_input"
31599       { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
31600 $as_echo "$as_me: creating $ac_file" >&6;}
31601     fi
31602     # Neutralize special characters interpreted by sed in replacement strings.
31603     case $configure_input in #(
31604     *\&* | *\|* | *\\* )
31605        ac_sed_conf_input=`$as_echo "$configure_input" |
31606        sed 's/[\\\\&|]/\\\\&/g'`;; #(
31607     *) ac_sed_conf_input=$configure_input;;
31608     esac
31609
31610     case $ac_tag in
31611     *:-:* | *:-) cat >"$ac_tmp/stdin" \
31612       || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
31613     esac
31614     ;;
31615   esac
31616
31617   ac_dir=`$as_dirname -- "$ac_file" ||
31618 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
31619          X"$ac_file" : 'X\(//\)[^/]' \| \
31620          X"$ac_file" : 'X\(//\)$' \| \
31621          X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
31622 $as_echo X"$ac_file" |
31623     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
31624             s//\1/
31625             q
31626           }
31627           /^X\(\/\/\)[^/].*/{
31628             s//\1/
31629             q
31630           }
31631           /^X\(\/\/\)$/{
31632             s//\1/
31633             q
31634           }
31635           /^X\(\/\).*/{
31636             s//\1/
31637             q
31638           }
31639           s/.*/./; q'`
31640   as_dir="$ac_dir"; as_fn_mkdir_p
31641   ac_builddir=.
31642
31643 case "$ac_dir" in
31644 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
31645 *)
31646   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
31647   # A ".." for each directory in $ac_dir_suffix.
31648   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
31649   case $ac_top_builddir_sub in
31650   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
31651   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
31652   esac ;;
31653 esac
31654 ac_abs_top_builddir=$ac_pwd
31655 ac_abs_builddir=$ac_pwd$ac_dir_suffix
31656 # for backward compatibility:
31657 ac_top_builddir=$ac_top_build_prefix
31658
31659 case $srcdir in
31660   .)  # We are building in place.
31661     ac_srcdir=.
31662     ac_top_srcdir=$ac_top_builddir_sub
31663     ac_abs_top_srcdir=$ac_pwd ;;
31664   [\\/]* | ?:[\\/]* )  # Absolute name.
31665     ac_srcdir=$srcdir$ac_dir_suffix;
31666     ac_top_srcdir=$srcdir
31667     ac_abs_top_srcdir=$srcdir ;;
31668   *) # Relative name.
31669     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
31670     ac_top_srcdir=$ac_top_build_prefix$srcdir
31671     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
31672 esac
31673 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
31674
31675
31676   case $ac_mode in
31677   :F)
31678   #
31679   # CONFIG_FILE
31680   #
31681
31682   case $INSTALL in
31683   [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
31684   *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
31685   esac
31686   ac_MKDIR_P=$MKDIR_P
31687   case $MKDIR_P in
31688   [\\/$]* | ?:[\\/]* ) ;;
31689   */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
31690   esac
31691 _ACEOF
31692
31693 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
31694 # If the template does not know about datarootdir, expand it.
31695 # FIXME: This hack should be removed a few years after 2.60.
31696 ac_datarootdir_hack=; ac_datarootdir_seen=
31697 ac_sed_dataroot='
31698 /datarootdir/ {
31699   p
31700   q
31701 }
31702 /@datadir@/p
31703 /@docdir@/p
31704 /@infodir@/p
31705 /@localedir@/p
31706 /@mandir@/p'
31707 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
31708 *datarootdir*) ac_datarootdir_seen=yes;;
31709 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
31710   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
31711 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
31712 _ACEOF
31713 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
31714   ac_datarootdir_hack='
31715   s&@datadir@&$datadir&g
31716   s&@docdir@&$docdir&g
31717   s&@infodir@&$infodir&g
31718   s&@localedir@&$localedir&g
31719   s&@mandir@&$mandir&g
31720   s&\\\${datarootdir}&$datarootdir&g' ;;
31721 esac
31722 _ACEOF
31723
31724 # Neutralize VPATH when `$srcdir' = `.'.
31725 # Shell code in configure.ac might set extrasub.
31726 # FIXME: do we really want to maintain this feature?
31727 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
31728 ac_sed_extra="$ac_vpsub
31729 $extrasub
31730 _ACEOF
31731 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
31732 :t
31733 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
31734 s|@configure_input@|$ac_sed_conf_input|;t t
31735 s&@top_builddir@&$ac_top_builddir_sub&;t t
31736 s&@top_build_prefix@&$ac_top_build_prefix&;t t
31737 s&@srcdir@&$ac_srcdir&;t t
31738 s&@abs_srcdir@&$ac_abs_srcdir&;t t
31739 s&@top_srcdir@&$ac_top_srcdir&;t t
31740 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
31741 s&@builddir@&$ac_builddir&;t t
31742 s&@abs_builddir@&$ac_abs_builddir&;t t
31743 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
31744 s&@INSTALL@&$ac_INSTALL&;t t
31745 s&@MKDIR_P@&$ac_MKDIR_P&;t t
31746 $ac_datarootdir_hack
31747 "
31748 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
31749   >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
31750
31751 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
31752   { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
31753   { ac_out=`sed -n '/^[  ]*datarootdir[  ]*:*=/p' \
31754       "$ac_tmp/out"`; test -z "$ac_out"; } &&
31755   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
31756 which seems to be undefined.  Please make sure it is defined" >&5
31757 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
31758 which seems to be undefined.  Please make sure it is defined" >&2;}
31759
31760   rm -f "$ac_tmp/stdin"
31761   case $ac_file in
31762   -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
31763   *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
31764   esac \
31765   || as_fn_error $? "could not create $ac_file" "$LINENO" 5
31766  ;;
31767   :H)
31768   #
31769   # CONFIG_HEADER
31770   #
31771   if test x"$ac_file" != x-; then
31772     {
31773       $as_echo "/* $configure_input  */" \
31774       && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
31775     } >"$ac_tmp/config.h" \
31776       || as_fn_error $? "could not create $ac_file" "$LINENO" 5
31777     if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
31778       { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
31779 $as_echo "$as_me: $ac_file is unchanged" >&6;}
31780     else
31781       rm -f "$ac_file"
31782       mv "$ac_tmp/config.h" "$ac_file" \
31783         || as_fn_error $? "could not create $ac_file" "$LINENO" 5
31784     fi
31785   else
31786     $as_echo "/* $configure_input  */" \
31787       && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
31788       || as_fn_error $? "could not create -" "$LINENO" 5
31789   fi
31790 # Compute "$ac_file"'s index in $config_headers.
31791 _am_arg="$ac_file"
31792 _am_stamp_count=1
31793 for _am_header in $config_headers :; do
31794   case $_am_header in
31795     $_am_arg | $_am_arg:* )
31796       break ;;
31797     * )
31798       _am_stamp_count=`expr $_am_stamp_count + 1` ;;
31799   esac
31800 done
31801 echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
31802 $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
31803          X"$_am_arg" : 'X\(//\)[^/]' \| \
31804          X"$_am_arg" : 'X\(//\)$' \| \
31805          X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
31806 $as_echo X"$_am_arg" |
31807     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
31808             s//\1/
31809             q
31810           }
31811           /^X\(\/\/\)[^/].*/{
31812             s//\1/
31813             q
31814           }
31815           /^X\(\/\/\)$/{
31816             s//\1/
31817             q
31818           }
31819           /^X\(\/\).*/{
31820             s//\1/
31821             q
31822           }
31823           s/.*/./; q'`/stamp-h$_am_stamp_count
31824  ;;
31825
31826   :C)  { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
31827 $as_echo "$as_me: executing $ac_file commands" >&6;}
31828  ;;
31829   esac
31830
31831
31832   case $ac_file$ac_mode in
31833     "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
31834   # Autoconf 2.62 quotes --file arguments for eval, but not when files
31835   # are listed without --file.  Let's play safe and only enable the eval
31836   # if we detect the quoting.
31837   case $CONFIG_FILES in
31838   *\'*) eval set x "$CONFIG_FILES" ;;
31839   *)   set x $CONFIG_FILES ;;
31840   esac
31841   shift
31842   for mf
31843   do
31844     # Strip MF so we end up with the name of the file.
31845     mf=`echo "$mf" | sed -e 's/:.*$//'`
31846     # Check whether this is an Automake generated Makefile or not.
31847     # We used to match only the files named `Makefile.in', but
31848     # some people rename them; so instead we look at the file content.
31849     # Grep'ing the first line is not enough: some people post-process
31850     # each Makefile.in and add a new line on top of each file to say so.
31851     # Grep'ing the whole file is not good either: AIX grep has a line
31852     # limit of 2048, but all sed's we know have understand at least 4000.
31853     if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
31854       dirpart=`$as_dirname -- "$mf" ||
31855 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
31856          X"$mf" : 'X\(//\)[^/]' \| \
31857          X"$mf" : 'X\(//\)$' \| \
31858          X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
31859 $as_echo X"$mf" |
31860     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
31861             s//\1/
31862             q
31863           }
31864           /^X\(\/\/\)[^/].*/{
31865             s//\1/
31866             q
31867           }
31868           /^X\(\/\/\)$/{
31869             s//\1/
31870             q
31871           }
31872           /^X\(\/\).*/{
31873             s//\1/
31874             q
31875           }
31876           s/.*/./; q'`
31877     else
31878       continue
31879     fi
31880     # Extract the definition of DEPDIR, am__include, and am__quote
31881     # from the Makefile without running `make'.
31882     DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
31883     test -z "$DEPDIR" && continue
31884     am__include=`sed -n 's/^am__include = //p' < "$mf"`
31885     test -z "am__include" && continue
31886     am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
31887     # When using ansi2knr, U may be empty or an underscore; expand it
31888     U=`sed -n 's/^U = //p' < "$mf"`
31889     # Find all dependency output files, they are included files with
31890     # $(DEPDIR) in their names.  We invoke sed twice because it is the
31891     # simplest approach to changing $(DEPDIR) to its actual value in the
31892     # expansion.
31893     for file in `sed -n "
31894       s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
31895          sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
31896       # Make sure the directory exists.
31897       test -f "$dirpart/$file" && continue
31898       fdir=`$as_dirname -- "$file" ||
31899 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
31900          X"$file" : 'X\(//\)[^/]' \| \
31901          X"$file" : 'X\(//\)$' \| \
31902          X"$file" : 'X\(/\)' \| . 2>/dev/null ||
31903 $as_echo X"$file" |
31904     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
31905             s//\1/
31906             q
31907           }
31908           /^X\(\/\/\)[^/].*/{
31909             s//\1/
31910             q
31911           }
31912           /^X\(\/\/\)$/{
31913             s//\1/
31914             q
31915           }
31916           /^X\(\/\).*/{
31917             s//\1/
31918             q
31919           }
31920           s/.*/./; q'`
31921       as_dir=$dirpart/$fdir; as_fn_mkdir_p
31922       # echo "creating $dirpart/$file"
31923       echo '# dummy' > "$dirpart/$file"
31924     done
31925   done
31926 }
31927  ;;
31928     "libtool":C)
31929
31930     # See if we are running on zsh, and set the options which allow our
31931     # commands through without removal of \ escapes.
31932     if test -n "${ZSH_VERSION+set}" ; then
31933       setopt NO_GLOB_SUBST
31934     fi
31935
31936     cfgfile="${ofile}T"
31937     trap "$RM \"$cfgfile\"; exit 1" 1 2 15
31938     $RM "$cfgfile"
31939
31940     cat <<_LT_EOF >> "$cfgfile"
31941 #! $SHELL
31942
31943 # `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
31944 # Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
31945 # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
31946 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
31947 #
31948 #   Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
31949 #                 2006, 2007, 2008, 2009, 2010 Free Software Foundation,
31950 #                 Inc.
31951 #   Written by Gordon Matzigkeit, 1996
31952 #
31953 #   This file is part of GNU Libtool.
31954 #
31955 # GNU Libtool is free software; you can redistribute it and/or
31956 # modify it under the terms of the GNU General Public License as
31957 # published by the Free Software Foundation; either version 2 of
31958 # the License, or (at your option) any later version.
31959 #
31960 # As a special exception to the GNU General Public License,
31961 # if you distribute this file as part of a program or library that
31962 # is built using GNU Libtool, you may include this file under the
31963 # same distribution terms that you use for the rest of that program.
31964 #
31965 # GNU Libtool is distributed in the hope that it will be useful,
31966 # but WITHOUT ANY WARRANTY; without even the implied warranty of
31967 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
31968 # GNU General Public License for more details.
31969 #
31970 # You should have received a copy of the GNU General Public License
31971 # along with GNU Libtool; see the file COPYING.  If not, a copy
31972 # can be downloaded from http://www.gnu.org/licenses/gpl.html, or
31973 # obtained by writing to the Free Software Foundation, Inc.,
31974 # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
31975
31976
31977 # The names of the tagged configurations supported by this script.
31978 available_tags="CXX "
31979
31980 # ### BEGIN LIBTOOL CONFIG
31981
31982 # A sed program that does not truncate output.
31983 SED=$lt_SED
31984
31985 # Sed that helps us avoid accidentally triggering echo(1) options like -n.
31986 Xsed="\$SED -e 1s/^X//"
31987
31988 # A grep program that handles long lines.
31989 GREP=$lt_GREP
31990
31991 # An ERE matcher.
31992 EGREP=$lt_EGREP
31993
31994 # A literal string matcher.
31995 FGREP=$lt_FGREP
31996
31997 # Shell to use when invoking shell scripts.
31998 SHELL=$lt_SHELL
31999
32000 # An echo program that protects backslashes.
32001 ECHO=$lt_ECHO
32002
32003 # Whether or not to build shared libraries.
32004 build_libtool_libs=$enable_shared
32005
32006 # Which release of libtool.m4 was used?
32007 macro_version=$macro_version
32008 macro_revision=$macro_revision
32009
32010 # Whether or not to build static libraries.
32011 build_old_libs=$enable_static
32012
32013 # What type of objects to build.
32014 pic_mode=$pic_mode
32015
32016 # Whether or not to optimize for fast installation.
32017 fast_install=$enable_fast_install
32018
32019 # The host system.
32020 host_alias=$host_alias
32021 host=$host
32022 host_os=$host_os
32023
32024 # The build system.
32025 build_alias=$build_alias
32026 build=$build
32027 build_os=$build_os
32028
32029 # A BSD- or MS-compatible name lister.
32030 NM=$lt_NM
32031
32032 # Whether we need soft or hard links.
32033 LN_S=$lt_LN_S
32034
32035 # What is the maximum length of a command?
32036 max_cmd_len=$max_cmd_len
32037
32038 # Object file suffix (normally "o").
32039 objext=$ac_objext
32040
32041 # Executable file suffix (normally "").
32042 exeext=$exeext
32043
32044 # whether the shell understands "unset".
32045 lt_unset=$lt_unset
32046
32047 # turn spaces into newlines.
32048 SP2NL=$lt_lt_SP2NL
32049
32050 # turn newlines into spaces.
32051 NL2SP=$lt_lt_NL2SP
32052
32053 # convert \$build file names to \$host format.
32054 to_host_file_cmd=$lt_cv_to_host_file_cmd
32055
32056 # convert \$build files to toolchain format.
32057 to_tool_file_cmd=$lt_cv_to_tool_file_cmd
32058
32059 # An object symbol dumper.
32060 OBJDUMP=$lt_OBJDUMP
32061
32062 # Method to check whether dependent libraries are shared objects.
32063 deplibs_check_method=$lt_deplibs_check_method
32064
32065 # Command to use when deplibs_check_method = "file_magic".
32066 file_magic_cmd=$lt_file_magic_cmd
32067
32068 # How to find potential files when deplibs_check_method = "file_magic".
32069 file_magic_glob=$lt_file_magic_glob
32070
32071 # Find potential files using nocaseglob when deplibs_check_method = "file_magic".
32072 want_nocaseglob=$lt_want_nocaseglob
32073
32074 # DLL creation program.
32075 DLLTOOL=$lt_DLLTOOL
32076
32077 # Command to associate shared and link libraries.
32078 sharedlib_from_linklib_cmd=$lt_sharedlib_from_linklib_cmd
32079
32080 # The archiver.
32081 AR=$lt_AR
32082
32083 # Flags to create an archive.
32084 AR_FLAGS=$lt_AR_FLAGS
32085
32086 # How to feed a file listing to the archiver.
32087 archiver_list_spec=$lt_archiver_list_spec
32088
32089 # A symbol stripping program.
32090 STRIP=$lt_STRIP
32091
32092 # Commands used to install an old-style archive.
32093 RANLIB=$lt_RANLIB
32094 old_postinstall_cmds=$lt_old_postinstall_cmds
32095 old_postuninstall_cmds=$lt_old_postuninstall_cmds
32096
32097 # Whether to use a lock for old archive extraction.
32098 lock_old_archive_extraction=$lock_old_archive_extraction
32099
32100 # A C compiler.
32101 LTCC=$lt_CC
32102
32103 # LTCC compiler flags.
32104 LTCFLAGS=$lt_CFLAGS
32105
32106 # Take the output of nm and produce a listing of raw symbols and C names.
32107 global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
32108
32109 # Transform the output of nm in a proper C declaration.
32110 global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
32111
32112 # Transform the output of nm in a C name address pair.
32113 global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
32114
32115 # Transform the output of nm in a C name address pair when lib prefix is needed.
32116 global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
32117
32118 # Specify filename containing input files for \$NM.
32119 nm_file_list_spec=$lt_nm_file_list_spec
32120
32121 # The root where to search for dependent libraries,and in which our libraries should be installed.
32122 lt_sysroot=$lt_sysroot
32123
32124 # The name of the directory that contains temporary libtool files.
32125 objdir=$objdir
32126
32127 # Used to examine libraries when file_magic_cmd begins with "file".
32128 MAGIC_CMD=$MAGIC_CMD
32129
32130 # Must we lock files when doing compilation?
32131 need_locks=$lt_need_locks
32132
32133 # Manifest tool.
32134 MANIFEST_TOOL=$lt_MANIFEST_TOOL
32135
32136 # Tool to manipulate archived DWARF debug symbol files on Mac OS X.
32137 DSYMUTIL=$lt_DSYMUTIL
32138
32139 # Tool to change global to local symbols on Mac OS X.
32140 NMEDIT=$lt_NMEDIT
32141
32142 # Tool to manipulate fat objects and archives on Mac OS X.
32143 LIPO=$lt_LIPO
32144
32145 # ldd/readelf like tool for Mach-O binaries on Mac OS X.
32146 OTOOL=$lt_OTOOL
32147
32148 # ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4.
32149 OTOOL64=$lt_OTOOL64
32150
32151 # Old archive suffix (normally "a").
32152 libext=$libext
32153
32154 # Shared library suffix (normally ".so").
32155 shrext_cmds=$lt_shrext_cmds
32156
32157 # The commands to extract the exported symbol list from a shared archive.
32158 extract_expsyms_cmds=$lt_extract_expsyms_cmds
32159
32160 # Variables whose values should be saved in libtool wrapper scripts and
32161 # restored at link time.
32162 variables_saved_for_relink=$lt_variables_saved_for_relink
32163
32164 # Do we need the "lib" prefix for modules?
32165 need_lib_prefix=$need_lib_prefix
32166
32167 # Do we need a version for libraries?
32168 need_version=$need_version
32169
32170 # Library versioning type.
32171 version_type=$version_type
32172
32173 # Shared library runtime path variable.
32174 runpath_var=$runpath_var
32175
32176 # Shared library path variable.
32177 shlibpath_var=$shlibpath_var
32178
32179 # Is shlibpath searched before the hard-coded library search path?
32180 shlibpath_overrides_runpath=$shlibpath_overrides_runpath
32181
32182 # Format of library name prefix.
32183 libname_spec=$lt_libname_spec
32184
32185 # List of archive names.  First name is the real one, the rest are links.
32186 # The last name is the one that the linker finds with -lNAME
32187 library_names_spec=$lt_library_names_spec
32188
32189 # The coded name of the library, if different from the real name.
32190 soname_spec=$lt_soname_spec
32191
32192 # Permission mode override for installation of shared libraries.
32193 install_override_mode=$lt_install_override_mode
32194
32195 # Command to use after installation of a shared archive.
32196 postinstall_cmds=$lt_postinstall_cmds
32197
32198 # Command to use after uninstallation of a shared archive.
32199 postuninstall_cmds=$lt_postuninstall_cmds
32200
32201 # Commands used to finish a libtool library installation in a directory.
32202 finish_cmds=$lt_finish_cmds
32203
32204 # As "finish_cmds", except a single script fragment to be evaled but
32205 # not shown.
32206 finish_eval=$lt_finish_eval
32207
32208 # Whether we should hardcode library paths into libraries.
32209 hardcode_into_libs=$hardcode_into_libs
32210
32211 # Compile-time system search path for libraries.
32212 sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
32213
32214 # Run-time system search path for libraries.
32215 sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
32216
32217 # Whether dlopen is supported.
32218 dlopen_support=$enable_dlopen
32219
32220 # Whether dlopen of programs is supported.
32221 dlopen_self=$enable_dlopen_self
32222
32223 # Whether dlopen of statically linked programs is supported.
32224 dlopen_self_static=$enable_dlopen_self_static
32225
32226 # Commands to strip libraries.
32227 old_striplib=$lt_old_striplib
32228 striplib=$lt_striplib
32229
32230
32231 # The linker used to build libraries.
32232 LD=$lt_LD
32233
32234 # How to create reloadable object files.
32235 reload_flag=$lt_reload_flag
32236 reload_cmds=$lt_reload_cmds
32237
32238 # Commands used to build an old-style archive.
32239 old_archive_cmds=$lt_old_archive_cmds
32240
32241 # A language specific compiler.
32242 CC=$lt_compiler
32243
32244 # Is the compiler the GNU compiler?
32245 with_gcc=$GCC
32246
32247 # Compiler flag to turn off builtin functions.
32248 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
32249
32250 # Additional compiler flags for building library objects.
32251 pic_flag=$lt_lt_prog_compiler_pic
32252
32253 # How to pass a linker flag through the compiler.
32254 wl=$lt_lt_prog_compiler_wl
32255
32256 # Compiler flag to prevent dynamic linking.
32257 link_static_flag=$lt_lt_prog_compiler_static
32258
32259 # Does compiler simultaneously support -c and -o options?
32260 compiler_c_o=$lt_lt_cv_prog_compiler_c_o
32261
32262 # Whether or not to add -lc for building shared libraries.
32263 build_libtool_need_lc=$archive_cmds_need_lc
32264
32265 # Whether or not to disallow shared libs when runtime libs are static.
32266 allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes
32267
32268 # Compiler flag to allow reflexive dlopens.
32269 export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
32270
32271 # Compiler flag to generate shared objects directly from archives.
32272 whole_archive_flag_spec=$lt_whole_archive_flag_spec
32273
32274 # Whether the compiler copes with passing no objects directly.
32275 compiler_needs_object=$lt_compiler_needs_object
32276
32277 # Create an old-style archive from a shared archive.
32278 old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
32279
32280 # Create a temporary old-style archive to link instead of a shared archive.
32281 old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
32282
32283 # Commands used to build a shared archive.
32284 archive_cmds=$lt_archive_cmds
32285 archive_expsym_cmds=$lt_archive_expsym_cmds
32286
32287 # Commands used to build a loadable module if different from building
32288 # a shared archive.
32289 module_cmds=$lt_module_cmds
32290 module_expsym_cmds=$lt_module_expsym_cmds
32291
32292 # Whether we are building with GNU ld or not.
32293 with_gnu_ld=$lt_with_gnu_ld
32294
32295 # Flag that allows shared libraries with undefined symbols to be built.
32296 allow_undefined_flag=$lt_allow_undefined_flag
32297
32298 # Flag that enforces no undefined symbols.
32299 no_undefined_flag=$lt_no_undefined_flag
32300
32301 # Flag to hardcode \$libdir into a binary during linking.
32302 # This must work even if \$libdir does not exist
32303 hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
32304
32305 # If ld is used when linking, flag to hardcode \$libdir into a binary
32306 # during linking.  This must work even if \$libdir does not exist.
32307 hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld
32308
32309 # Whether we need a single "-rpath" flag with a separated argument.
32310 hardcode_libdir_separator=$lt_hardcode_libdir_separator
32311
32312 # Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
32313 # DIR into the resulting binary.
32314 hardcode_direct=$hardcode_direct
32315
32316 # Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
32317 # DIR into the resulting binary and the resulting library dependency is
32318 # "absolute",i.e impossible to change by setting \${shlibpath_var} if the
32319 # library is relocated.
32320 hardcode_direct_absolute=$hardcode_direct_absolute
32321
32322 # Set to "yes" if using the -LDIR flag during linking hardcodes DIR
32323 # into the resulting binary.
32324 hardcode_minus_L=$hardcode_minus_L
32325
32326 # Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
32327 # into the resulting binary.
32328 hardcode_shlibpath_var=$hardcode_shlibpath_var
32329
32330 # Set to "yes" if building a shared library automatically hardcodes DIR
32331 # into the library and all subsequent libraries and executables linked
32332 # against it.
32333 hardcode_automatic=$hardcode_automatic
32334
32335 # Set to yes if linker adds runtime paths of dependent libraries
32336 # to runtime path list.
32337 inherit_rpath=$inherit_rpath
32338
32339 # Whether libtool must link a program against all its dependency libraries.
32340 link_all_deplibs=$link_all_deplibs
32341
32342 # Set to "yes" if exported symbols are required.
32343 always_export_symbols=$always_export_symbols
32344
32345 # The commands to list exported symbols.
32346 export_symbols_cmds=$lt_export_symbols_cmds
32347
32348 # Symbols that should not be listed in the preloaded symbols.
32349 exclude_expsyms=$lt_exclude_expsyms
32350
32351 # Symbols that must always be exported.
32352 include_expsyms=$lt_include_expsyms
32353
32354 # Commands necessary for linking programs (against libraries) with templates.
32355 prelink_cmds=$lt_prelink_cmds
32356
32357 # Commands necessary for finishing linking programs.
32358 postlink_cmds=$lt_postlink_cmds
32359
32360 # Specify filename containing input files.
32361 file_list_spec=$lt_file_list_spec
32362
32363 # How to hardcode a shared library path into an executable.
32364 hardcode_action=$hardcode_action
32365
32366 # The directories searched by this compiler when creating a shared library.
32367 compiler_lib_search_dirs=$lt_compiler_lib_search_dirs
32368
32369 # Dependencies to place before and after the objects being linked to
32370 # create a shared library.
32371 predep_objects=$lt_predep_objects
32372 postdep_objects=$lt_postdep_objects
32373 predeps=$lt_predeps
32374 postdeps=$lt_postdeps
32375
32376 # The library search path used internally by the compiler when linking
32377 # a shared library.
32378 compiler_lib_search_path=$lt_compiler_lib_search_path
32379
32380 # ### END LIBTOOL CONFIG
32381
32382 _LT_EOF
32383
32384   case $host_os in
32385   aix3*)
32386     cat <<\_LT_EOF >> "$cfgfile"
32387 # AIX sometimes has problems with the GCC collect2 program.  For some
32388 # reason, if we set the COLLECT_NAMES environment variable, the problems
32389 # vanish in a puff of smoke.
32390 if test "X${COLLECT_NAMES+set}" != Xset; then
32391   COLLECT_NAMES=
32392   export COLLECT_NAMES
32393 fi
32394 _LT_EOF
32395     ;;
32396   esac
32397
32398
32399 ltmain="$ac_aux_dir/ltmain.sh"
32400
32401
32402   # We use sed instead of cat because bash on DJGPP gets confused if
32403   # if finds mixed CR/LF and LF-only lines.  Since sed operates in
32404   # text mode, it properly converts lines to CR/LF.  This bash problem
32405   # is reportedly fixed, but why not run on old versions too?
32406   sed '$q' "$ltmain" >> "$cfgfile" \
32407      || (rm -f "$cfgfile"; exit 1)
32408
32409   if test x"$xsi_shell" = xyes; then
32410   sed -e '/^func_dirname ()$/,/^} # func_dirname /c\
32411 func_dirname ()\
32412 {\
32413 \    case ${1} in\
32414 \      */*) func_dirname_result="${1%/*}${2}" ;;\
32415 \      *  ) func_dirname_result="${3}" ;;\
32416 \    esac\
32417 } # Extended-shell func_dirname implementation' "$cfgfile" > $cfgfile.tmp \
32418   && mv -f "$cfgfile.tmp" "$cfgfile" \
32419     || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
32420 test 0 -eq $? || _lt_function_replace_fail=:
32421
32422
32423   sed -e '/^func_basename ()$/,/^} # func_basename /c\
32424 func_basename ()\
32425 {\
32426 \    func_basename_result="${1##*/}"\
32427 } # Extended-shell func_basename implementation' "$cfgfile" > $cfgfile.tmp \
32428   && mv -f "$cfgfile.tmp" "$cfgfile" \
32429     || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
32430 test 0 -eq $? || _lt_function_replace_fail=:
32431
32432
32433   sed -e '/^func_dirname_and_basename ()$/,/^} # func_dirname_and_basename /c\
32434 func_dirname_and_basename ()\
32435 {\
32436 \    case ${1} in\
32437 \      */*) func_dirname_result="${1%/*}${2}" ;;\
32438 \      *  ) func_dirname_result="${3}" ;;\
32439 \    esac\
32440 \    func_basename_result="${1##*/}"\
32441 } # Extended-shell func_dirname_and_basename implementation' "$cfgfile" > $cfgfile.tmp \
32442   && mv -f "$cfgfile.tmp" "$cfgfile" \
32443     || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
32444 test 0 -eq $? || _lt_function_replace_fail=:
32445
32446
32447   sed -e '/^func_stripname ()$/,/^} # func_stripname /c\
32448 func_stripname ()\
32449 {\
32450 \    # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are\
32451 \    # positional parameters, so assign one to ordinary parameter first.\
32452 \    func_stripname_result=${3}\
32453 \    func_stripname_result=${func_stripname_result#"${1}"}\
32454 \    func_stripname_result=${func_stripname_result%"${2}"}\
32455 } # Extended-shell func_stripname implementation' "$cfgfile" > $cfgfile.tmp \
32456   && mv -f "$cfgfile.tmp" "$cfgfile" \
32457     || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
32458 test 0 -eq $? || _lt_function_replace_fail=:
32459
32460
32461   sed -e '/^func_split_long_opt ()$/,/^} # func_split_long_opt /c\
32462 func_split_long_opt ()\
32463 {\
32464 \    func_split_long_opt_name=${1%%=*}\
32465 \    func_split_long_opt_arg=${1#*=}\
32466 } # Extended-shell func_split_long_opt implementation' "$cfgfile" > $cfgfile.tmp \
32467   && mv -f "$cfgfile.tmp" "$cfgfile" \
32468     || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
32469 test 0 -eq $? || _lt_function_replace_fail=:
32470
32471
32472   sed -e '/^func_split_short_opt ()$/,/^} # func_split_short_opt /c\
32473 func_split_short_opt ()\
32474 {\
32475 \    func_split_short_opt_arg=${1#??}\
32476 \    func_split_short_opt_name=${1%"$func_split_short_opt_arg"}\
32477 } # Extended-shell func_split_short_opt implementation' "$cfgfile" > $cfgfile.tmp \
32478   && mv -f "$cfgfile.tmp" "$cfgfile" \
32479     || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
32480 test 0 -eq $? || _lt_function_replace_fail=:
32481
32482
32483   sed -e '/^func_lo2o ()$/,/^} # func_lo2o /c\
32484 func_lo2o ()\
32485 {\
32486 \    case ${1} in\
32487 \      *.lo) func_lo2o_result=${1%.lo}.${objext} ;;\
32488 \      *)    func_lo2o_result=${1} ;;\
32489 \    esac\
32490 } # Extended-shell func_lo2o implementation' "$cfgfile" > $cfgfile.tmp \
32491   && mv -f "$cfgfile.tmp" "$cfgfile" \
32492     || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
32493 test 0 -eq $? || _lt_function_replace_fail=:
32494
32495
32496   sed -e '/^func_xform ()$/,/^} # func_xform /c\
32497 func_xform ()\
32498 {\
32499     func_xform_result=${1%.*}.lo\
32500 } # Extended-shell func_xform implementation' "$cfgfile" > $cfgfile.tmp \
32501   && mv -f "$cfgfile.tmp" "$cfgfile" \
32502     || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
32503 test 0 -eq $? || _lt_function_replace_fail=:
32504
32505
32506   sed -e '/^func_arith ()$/,/^} # func_arith /c\
32507 func_arith ()\
32508 {\
32509     func_arith_result=$(( $* ))\
32510 } # Extended-shell func_arith implementation' "$cfgfile" > $cfgfile.tmp \
32511   && mv -f "$cfgfile.tmp" "$cfgfile" \
32512     || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
32513 test 0 -eq $? || _lt_function_replace_fail=:
32514
32515
32516   sed -e '/^func_len ()$/,/^} # func_len /c\
32517 func_len ()\
32518 {\
32519     func_len_result=${#1}\
32520 } # Extended-shell func_len implementation' "$cfgfile" > $cfgfile.tmp \
32521   && mv -f "$cfgfile.tmp" "$cfgfile" \
32522     || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
32523 test 0 -eq $? || _lt_function_replace_fail=:
32524
32525 fi
32526
32527 if test x"$lt_shell_append" = xyes; then
32528   sed -e '/^func_append ()$/,/^} # func_append /c\
32529 func_append ()\
32530 {\
32531     eval "${1}+=\\${2}"\
32532 } # Extended-shell func_append implementation' "$cfgfile" > $cfgfile.tmp \
32533   && mv -f "$cfgfile.tmp" "$cfgfile" \
32534     || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
32535 test 0 -eq $? || _lt_function_replace_fail=:
32536
32537
32538   sed -e '/^func_append_quoted ()$/,/^} # func_append_quoted /c\
32539 func_append_quoted ()\
32540 {\
32541 \    func_quote_for_eval "${2}"\
32542 \    eval "${1}+=\\\\ \\$func_quote_for_eval_result"\
32543 } # Extended-shell func_append_quoted implementation' "$cfgfile" > $cfgfile.tmp \
32544   && mv -f "$cfgfile.tmp" "$cfgfile" \
32545     || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
32546 test 0 -eq $? || _lt_function_replace_fail=:
32547
32548
32549   # Save a `func_append' function call where possible by direct use of '+='
32550   sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \
32551     && mv -f "$cfgfile.tmp" "$cfgfile" \
32552       || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
32553   test 0 -eq $? || _lt_function_replace_fail=:
32554 else
32555   # Save a `func_append' function call even when '+=' is not available
32556   sed -e 's%func_append \([a-zA-Z_]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \
32557     && mv -f "$cfgfile.tmp" "$cfgfile" \
32558       || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp")
32559   test 0 -eq $? || _lt_function_replace_fail=:
32560 fi
32561
32562 if test x"$_lt_function_replace_fail" = x":"; then
32563   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unable to substitute extended shell functions in $ofile" >&5
32564 $as_echo "$as_me: WARNING: Unable to substitute extended shell functions in $ofile" >&2;}
32565 fi
32566
32567
32568    mv -f "$cfgfile" "$ofile" ||
32569     (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
32570   chmod +x "$ofile"
32571
32572
32573     cat <<_LT_EOF >> "$ofile"
32574
32575 # ### BEGIN LIBTOOL TAG CONFIG: CXX
32576
32577 # The linker used to build libraries.
32578 LD=$lt_LD_CXX
32579
32580 # How to create reloadable object files.
32581 reload_flag=$lt_reload_flag_CXX
32582 reload_cmds=$lt_reload_cmds_CXX
32583
32584 # Commands used to build an old-style archive.
32585 old_archive_cmds=$lt_old_archive_cmds_CXX
32586
32587 # A language specific compiler.
32588 CC=$lt_compiler_CXX
32589
32590 # Is the compiler the GNU compiler?
32591 with_gcc=$GCC_CXX
32592
32593 # Compiler flag to turn off builtin functions.
32594 no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_CXX
32595
32596 # Additional compiler flags for building library objects.
32597 pic_flag=$lt_lt_prog_compiler_pic_CXX
32598
32599 # How to pass a linker flag through the compiler.
32600 wl=$lt_lt_prog_compiler_wl_CXX
32601
32602 # Compiler flag to prevent dynamic linking.
32603 link_static_flag=$lt_lt_prog_compiler_static_CXX
32604
32605 # Does compiler simultaneously support -c and -o options?
32606 compiler_c_o=$lt_lt_cv_prog_compiler_c_o_CXX
32607
32608 # Whether or not to add -lc for building shared libraries.
32609 build_libtool_need_lc=$archive_cmds_need_lc_CXX
32610
32611 # Whether or not to disallow shared libs when runtime libs are static.
32612 allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_CXX
32613
32614 # Compiler flag to allow reflexive dlopens.
32615 export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_CXX
32616
32617 # Compiler flag to generate shared objects directly from archives.
32618 whole_archive_flag_spec=$lt_whole_archive_flag_spec_CXX
32619
32620 # Whether the compiler copes with passing no objects directly.
32621 compiler_needs_object=$lt_compiler_needs_object_CXX
32622
32623 # Create an old-style archive from a shared archive.
32624 old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_CXX
32625
32626 # Create a temporary old-style archive to link instead of a shared archive.
32627 old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_CXX
32628
32629 # Commands used to build a shared archive.
32630 archive_cmds=$lt_archive_cmds_CXX
32631 archive_expsym_cmds=$lt_archive_expsym_cmds_CXX
32632
32633 # Commands used to build a loadable module if different from building
32634 # a shared archive.
32635 module_cmds=$lt_module_cmds_CXX
32636 module_expsym_cmds=$lt_module_expsym_cmds_CXX
32637
32638 # Whether we are building with GNU ld or not.
32639 with_gnu_ld=$lt_with_gnu_ld_CXX
32640
32641 # Flag that allows shared libraries with undefined symbols to be built.
32642 allow_undefined_flag=$lt_allow_undefined_flag_CXX
32643
32644 # Flag that enforces no undefined symbols.
32645 no_undefined_flag=$lt_no_undefined_flag_CXX
32646
32647 # Flag to hardcode \$libdir into a binary during linking.
32648 # This must work even if \$libdir does not exist
32649 hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_CXX
32650
32651 # If ld is used when linking, flag to hardcode \$libdir into a binary
32652 # during linking.  This must work even if \$libdir does not exist.
32653 hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_CXX
32654
32655 # Whether we need a single "-rpath" flag with a separated argument.
32656 hardcode_libdir_separator=$lt_hardcode_libdir_separator_CXX
32657
32658 # Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
32659 # DIR into the resulting binary.
32660 hardcode_direct=$hardcode_direct_CXX
32661
32662 # Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
32663 # DIR into the resulting binary and the resulting library dependency is
32664 # "absolute",i.e impossible to change by setting \${shlibpath_var} if the
32665 # library is relocated.
32666 hardcode_direct_absolute=$hardcode_direct_absolute_CXX
32667
32668 # Set to "yes" if using the -LDIR flag during linking hardcodes DIR
32669 # into the resulting binary.
32670 hardcode_minus_L=$hardcode_minus_L_CXX
32671
32672 # Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
32673 # into the resulting binary.
32674 hardcode_shlibpath_var=$hardcode_shlibpath_var_CXX
32675
32676 # Set to "yes" if building a shared library automatically hardcodes DIR
32677 # into the library and all subsequent libraries and executables linked
32678 # against it.
32679 hardcode_automatic=$hardcode_automatic_CXX
32680
32681 # Set to yes if linker adds runtime paths of dependent libraries
32682 # to runtime path list.
32683 inherit_rpath=$inherit_rpath_CXX
32684
32685 # Whether libtool must link a program against all its dependency libraries.
32686 link_all_deplibs=$link_all_deplibs_CXX
32687
32688 # Set to "yes" if exported symbols are required.
32689 always_export_symbols=$always_export_symbols_CXX
32690
32691 # The commands to list exported symbols.
32692 export_symbols_cmds=$lt_export_symbols_cmds_CXX
32693
32694 # Symbols that should not be listed in the preloaded symbols.
32695 exclude_expsyms=$lt_exclude_expsyms_CXX
32696
32697 # Symbols that must always be exported.
32698 include_expsyms=$lt_include_expsyms_CXX
32699
32700 # Commands necessary for linking programs (against libraries) with templates.
32701 prelink_cmds=$lt_prelink_cmds_CXX
32702
32703 # Commands necessary for finishing linking programs.
32704 postlink_cmds=$lt_postlink_cmds_CXX
32705
32706 # Specify filename containing input files.
32707 file_list_spec=$lt_file_list_spec_CXX
32708
32709 # How to hardcode a shared library path into an executable.
32710 hardcode_action=$hardcode_action_CXX
32711
32712 # The directories searched by this compiler when creating a shared library.
32713 compiler_lib_search_dirs=$lt_compiler_lib_search_dirs_CXX
32714
32715 # Dependencies to place before and after the objects being linked to
32716 # create a shared library.
32717 predep_objects=$lt_predep_objects_CXX
32718 postdep_objects=$lt_postdep_objects_CXX
32719 predeps=$lt_predeps_CXX
32720 postdeps=$lt_postdeps_CXX
32721
32722 # The library search path used internally by the compiler when linking
32723 # a shared library.
32724 compiler_lib_search_path=$lt_compiler_lib_search_path_CXX
32725
32726 # ### END LIBTOOL TAG CONFIG: CXX
32727 _LT_EOF
32728
32729  ;;
32730
32731   esac
32732 done # for ac_tag
32733
32734
32735 as_fn_exit 0
32736 _ACEOF
32737 ac_clean_files=$ac_clean_files_save
32738
32739 test $ac_write_fail = 0 ||
32740   as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
32741
32742
32743 # configure is writing to config.log, and then calls config.status.
32744 # config.status does its own redirection, appending to config.log.
32745 # Unfortunately, on DOS this fails, as config.log is still kept open
32746 # by configure, so config.status won't be able to write to it; its
32747 # output is simply discarded.  So we exec the FD to /dev/null,
32748 # effectively closing config.log, so it can be properly (re)opened and
32749 # appended to by config.status.  When coming back to configure, we
32750 # need to make the FD available again.
32751 if test "$no_create" != yes; then
32752   ac_cs_success=:
32753   ac_config_status_args=
32754   test "$silent" = yes &&
32755     ac_config_status_args="$ac_config_status_args --quiet"
32756   exec 5>/dev/null
32757   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
32758   exec 5>>config.log
32759   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
32760   # would make configure fail if this is the last instruction.
32761   $ac_cs_success || as_fn_exit 1
32762 fi
32763
32764 #
32765 # CONFIG_SUBDIRS section.
32766 #
32767 if test "$no_recursion" != yes; then
32768
32769   # Remove --cache-file, --srcdir, and --disable-option-checking arguments
32770   # so they do not pile up.
32771   ac_sub_configure_args=
32772   ac_prev=
32773   eval "set x $ac_configure_args"
32774   shift
32775   for ac_arg
32776   do
32777     if test -n "$ac_prev"; then
32778       ac_prev=
32779       continue
32780     fi
32781     case $ac_arg in
32782     -cache-file | --cache-file | --cache-fil | --cache-fi \
32783     | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
32784       ac_prev=cache_file ;;
32785     -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
32786     | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* \
32787     | --c=*)
32788       ;;
32789     --config-cache | -C)
32790       ;;
32791     -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
32792       ac_prev=srcdir ;;
32793     -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
32794       ;;
32795     -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
32796       ac_prev=prefix ;;
32797     -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
32798       ;;
32799     --disable-option-checking)
32800       ;;
32801     *)
32802       case $ac_arg in
32803       *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
32804       esac
32805       as_fn_append ac_sub_configure_args " '$ac_arg'" ;;
32806     esac
32807   done
32808
32809   # Always prepend --prefix to ensure using the same prefix
32810   # in subdir configurations.
32811   ac_arg="--prefix=$prefix"
32812   case $ac_arg in
32813   *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
32814   esac
32815   ac_sub_configure_args="'$ac_arg' $ac_sub_configure_args"
32816
32817   # Pass --silent
32818   if test "$silent" = yes; then
32819     ac_sub_configure_args="--silent $ac_sub_configure_args"
32820   fi
32821
32822   # Always prepend --disable-option-checking to silence warnings, since
32823   # different subdirs can have different --enable and --with options.
32824   ac_sub_configure_args="--disable-option-checking $ac_sub_configure_args"
32825
32826   ac_popdir=`pwd`
32827   for ac_dir in : $subdirs; do test "x$ac_dir" = x: && continue
32828
32829     # Do not complain, so a configure script can configure whichever
32830     # parts of a large source tree are present.
32831     test -d "$srcdir/$ac_dir" || continue
32832
32833     ac_msg="=== configuring in $ac_dir (`pwd`/$ac_dir)"
32834     $as_echo "$as_me:${as_lineno-$LINENO}: $ac_msg" >&5
32835     $as_echo "$ac_msg" >&6
32836     as_dir="$ac_dir"; as_fn_mkdir_p
32837     ac_builddir=.
32838
32839 case "$ac_dir" in
32840 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
32841 *)
32842   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
32843   # A ".." for each directory in $ac_dir_suffix.
32844   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
32845   case $ac_top_builddir_sub in
32846   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
32847   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
32848   esac ;;
32849 esac
32850 ac_abs_top_builddir=$ac_pwd
32851 ac_abs_builddir=$ac_pwd$ac_dir_suffix
32852 # for backward compatibility:
32853 ac_top_builddir=$ac_top_build_prefix
32854
32855 case $srcdir in
32856   .)  # We are building in place.
32857     ac_srcdir=.
32858     ac_top_srcdir=$ac_top_builddir_sub
32859     ac_abs_top_srcdir=$ac_pwd ;;
32860   [\\/]* | ?:[\\/]* )  # Absolute name.
32861     ac_srcdir=$srcdir$ac_dir_suffix;
32862     ac_top_srcdir=$srcdir
32863     ac_abs_top_srcdir=$srcdir ;;
32864   *) # Relative name.
32865     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
32866     ac_top_srcdir=$ac_top_build_prefix$srcdir
32867     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
32868 esac
32869 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
32870
32871
32872     cd "$ac_dir"
32873
32874     # Check for guested configure; otherwise get Cygnus style configure.
32875     if test -f "$ac_srcdir/configure.gnu"; then
32876       ac_sub_configure=$ac_srcdir/configure.gnu
32877     elif test -f "$ac_srcdir/configure"; then
32878       ac_sub_configure=$ac_srcdir/configure
32879     elif test -f "$ac_srcdir/configure.in"; then
32880       # This should be Cygnus configure.
32881       ac_sub_configure=$ac_aux_dir/configure
32882     else
32883       { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no configuration information is in $ac_dir" >&5
32884 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2;}
32885       ac_sub_configure=
32886     fi
32887
32888     # The recursion is here.
32889     if test -n "$ac_sub_configure"; then
32890       # Make the cache file name correct relative to the subdirectory.
32891       case $cache_file in
32892       [\\/]* | ?:[\\/]* ) ac_sub_cache_file=$cache_file ;;
32893       *) # Relative name.
32894         ac_sub_cache_file=$ac_top_build_prefix$cache_file ;;
32895       esac
32896
32897       { $as_echo "$as_me:${as_lineno-$LINENO}: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&5
32898 $as_echo "$as_me: running $SHELL $ac_sub_configure $ac_sub_configure_args --cache-file=$ac_sub_cache_file --srcdir=$ac_srcdir" >&6;}
32899       # The eval makes quoting arguments work.
32900       eval "\$SHELL \"\$ac_sub_configure\" $ac_sub_configure_args \
32901            --cache-file=\"\$ac_sub_cache_file\" --srcdir=\"\$ac_srcdir\"" ||
32902         as_fn_error $? "$ac_sub_configure failed for $ac_dir" "$LINENO" 5
32903     fi
32904
32905     cd "$ac_popdir"
32906   done
32907 fi
32908 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
32909   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
32910 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
32911 fi
32912